~ubuntu-branches/ubuntu/lucid/software-center/lucid

« back to all changes in this revision

Viewing changes to softwarecenter/distro/Ubuntu.py

  • Committer: Bazaar Package Importer
  • Author(s): Michael Vogt, Michael Vogt, Gary Lasker
  • Date: 2010-01-27 20:51:27 UTC
  • Revision ID: james.westby@ubuntu.com-20100127205127-ndmwuopgxchgjy7r
Tags: 1.1.10
[ Michael Vogt ]
* softwarecenter/distro/aptutils.py:
  - removed, moved into python-apt
* softwarecenter/view/appview.py:
  - ignore negative ratings (LP: #510409)
* softwarecenter/db/database.py:
  - assert we have a popcon_max value
* debian/control:
  - updated dependencies to latest python-apt
* softwarecenter/view/availablepane.py:
  - fix name for Search Results (LP: #504379)
* softwarecenter/view/installedpane.py:
  - add Search Results pathbar
* debian/control:
  - drop python-sexy from the dependencies
* softwarecenter/view/widgets/searchentry.py:
  - merge patch from Javier Jardón to use gtk.Entry instead
    of sexy.Entry (LP: #506811) - many thanks!
* merged from  lp:~gary-lasker/software-center/active_app,
  many thanks!
* softwarecenter/distro/Ubuntu.py:
  - add support for the new "Supported" tag in the Packages file
* merged lp:~mmcg069/software-center/bug-fixes with lots of nice
  fixes in the pathbar and appview code (many thanks!)

[ Gary Lasker ]
* softwarecenter/view/widgets/pathbar2.py,
  softwarecenter/app.py,
  data/ui/SoftwareCenter.ui:
  - add support for using backspace key to navigate up one
    level in the hierarchy (LP: #509783)
* softwarecenter/app.py, softwarecenter/view/installedpane.py,
  softwarecenter/view/softwarepane.py:
  - fixes in the on_application_selected() code
* softwarecenter/view/installedpane.py,
  softwarecenter/view/softwarepane.py:
  - remove is_search_in_progress, it's not needed 
* softwarecenter/view/appview.py:
  - comment out the install/remove button set insensitive
    call temporarily, will restore after we are cleanly
    setting it sensitive again after transaction completed

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
import locale
22
22
import subprocess
23
23
 
24
 
from aptutils import *
 
24
from apt.utils import *
25
25
from softwarecenter.distro import Distro
26
26
from gettext import gettext as _
27
27
 
127
127
            release_age = (now - release_date).days
128
128
            #print "release age: ", release_age
129
129
 
 
130
            # init with the default time
 
131
            support_month = 18
 
132
 
 
133
            # see if we have a "Supported" entry in the pkg record
 
134
            if (cache.has_key(pkgname) and
 
135
                cache[pkgname].candidate):
 
136
                support_time = cache[pkgname].candidate.record.get("Supported")
 
137
                if support_time:
 
138
                    if support_time.endswith("y"):
 
139
                        support_month = 12*int(support_time.strip("y"))
 
140
                    elif support_time.endswith("m"):
 
141
                        support_month = int(support_time.strip("m"))
 
142
                    else:
 
143
                        logging.warning("unsupported 'Supported' string '%s'" % support_time)
 
144
 
130
145
            # mvo: we do not define the end date very precisely
131
146
            #      currently this is why it will just display a end
132
147
            #      range
133
 
            (support_end_year, support_end_month) = get_maintenance_end_date(release_date, 18)
 
148
            (support_end_year, support_end_month) = get_maintenance_end_date(release_date, support_month)
134
149
            support_end_month_str = locale.nl_langinfo(getattr(locale,"MON_%d" % support_end_month))
135
150
             # check if the support has ended
136
151
            support_ended = (now.year >= support_end_year and