Entropy/Notification Applet:

- update pixmaps (gfx)


git-svn-id: http://svn.sabayonlinux.org/projects/entropy/trunk@3014 cd1c1023-2f26-0410-ae45-c471fc1f0318
This commit is contained in:
lxnay
2009-02-10 20:34:08 +00:00
parent e21c716d74
commit cc45297622
9 changed files with 9 additions and 7 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 925 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

After

Width:  |  Height:  |  Size: 976 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 887 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.4 KiB

View File

@@ -114,16 +114,18 @@ class EntropyApplet:
elif new_state == "CRITICAL":
self.status_icon.set_blinking(True)
if self.never_viewed_notices:
self.change_icon("critical", "critical-blank")
self.change_icon("critical")
else:
self.set_displayed_image("critical")
elif new_state == "NOCONSENT":
if self.never_viewed_consent:
self.change_icon("noconsent", "noconsent-blank")
self.change_icon("noconsent")
else:
self.set_displayed_image("noconsent")
elif new_state == "DISCONNECTED":
self.change_icon("disconnect")
elif new_state == "DISABLE":
self.change_icon("disable")
elif new_state == "ERROR":
self.change_icon("error")
self.current_state = new_state
@@ -182,9 +184,8 @@ class EntropyApplet:
self.icons.add_file("error", "applet-error.png")
self.icons.add_file("busy", "applet-busy.png")
self.icons.add_file("critical", "applet-critical.png")
self.icons.add_file("critical-blank", "applet-critical-blank.png")
self.icons.add_file("disable", "applet-disable.png")
self.icons.add_file("noconsent", "applet-critical.png")
self.icons.add_file("noconsent-blank", "applet-critical-blank.png")
self.icons.add_file("disconnect", "applet-disconnect.png")
self.icons.add_file("spritz","spritz.png")
self.icons.add_file("about","applet-about.png")
@@ -293,7 +294,7 @@ class EntropyApplet:
elif name == "configure_applet":
pix = self.icons.best_match("configuration",22)
elif name == "disable_applet":
pix = self.icons.best_match("disconnect",22)
pix = self.icons.best_match("disable",22)
elif name == "enable_applet":
pix = self.icons.best_match("okay",22)
else:
@@ -362,7 +363,7 @@ class EntropyApplet:
def disable_applet(self, *args):
self.update_tooltip(_("Updates Notification Applet Disabled"))
self.disable_refresh_timer()
self.set_state("DISCONNECTED")
self.set_state("DISABLE")
etp_applet_config.settings['APPLET_ENABLED'] = 0
etp_applet_config.save_settings(etp_applet_config.settings)
self.menu_items['disable_applet'].hide()

View File

@@ -8,7 +8,7 @@
import os
import dumpTools
APPLET_STATES = [ "STARTUP", "NOCONSENT", "CONFIGURING", "OKAY", "CRITICAL", "BUSY", "ERROR", "DISCONNECTED" ]
APPLET_STATES = [ "STARTUP", "NOCONSENT", "CONFIGURING", "OKAY", "CRITICAL", "BUSY", "ERROR", "DISCONNECTED", "DISABLE" ]
APPLET_MENUS = [ "about", "update_now", "web_panel", "web_site", "configure_applet", "check_now" ]
APPLET_SENSITIVE_MENU = {
@@ -20,6 +20,7 @@ APPLET_SENSITIVE_MENU = {
"BUSY" : [ ],
"ERROR" : [ "about", "update_now", "check_now" ],
"DISCONNECTED": [ "about", "update_now", "check_now" ],
"DISABLE": [ "about", "update_now", "check_now" ],
}
RANDOM_REFRESH_DELTA = abs(hash(os.urandom(2)))%1800