* #2012: Fix palette position on the left frame panel. (marco)
This commit is contained in:
parent
a8d6ab3079
commit
33094dfa50
1
NEWS
1
NEWS
@ -1,3 +1,4 @@
|
|||||||
|
* #2012: Fix palette position on the left frame panel. (marco)
|
||||||
* #2297: Make activity name translatable. (danw)
|
* #2297: Make activity name translatable. (danw)
|
||||||
* #2695: Recognize text files as such. (tomeu)
|
* #2695: Recognize text files as such. (tomeu)
|
||||||
* #2669: Add a border to the inner of the frame. (marco)
|
* #2669: Add a border to the inner of the frame. (marco)
|
||||||
|
@ -16,22 +16,29 @@
|
|||||||
|
|
||||||
import hippo
|
import hippo
|
||||||
|
|
||||||
|
from sugar.graphics.palette import Palette
|
||||||
from sugar.graphics.canvasicon import CanvasIcon
|
from sugar.graphics.canvasicon import CanvasIcon
|
||||||
from sugar.graphics import style
|
from sugar.graphics import style
|
||||||
from sugar.presence import presenceservice
|
from sugar.presence import presenceservice
|
||||||
|
|
||||||
from view.BuddyIcon import BuddyIcon
|
from view.BuddyIcon import BuddyIcon
|
||||||
from model.BuddyModel import BuddyModel
|
from model.BuddyModel import BuddyModel
|
||||||
|
from view.frame.frameinvoker import FrameCanvasInvoker
|
||||||
|
|
||||||
class FriendIcon(BuddyIcon):
|
class FriendIcon(BuddyIcon):
|
||||||
def __init__(self, shell, buddy):
|
def __init__(self, shell, buddy):
|
||||||
BuddyIcon.__init__(self, shell, buddy)
|
BuddyIcon.__init__(self, shell, buddy)
|
||||||
self.get_palette().set_group_id('frame')
|
|
||||||
|
palette = self.get_palette()
|
||||||
|
palette.set_group_id('frame')
|
||||||
|
palette.props.position = Palette.AROUND
|
||||||
|
palette.props.invoker = FrameCanvasInvoker(self)
|
||||||
|
|
||||||
def prelight(self, enter):
|
def prelight(self, enter):
|
||||||
if enter:
|
if enter:
|
||||||
self.props.background_color = style.COLOR_BLACK.get_int()
|
self.props.background_color = style.COLOR_BLACK.get_int()
|
||||||
else:
|
else:
|
||||||
self.props.background_color = style.COLOR_TOOLBAR.GREY.get_int()
|
self.props.background_color = style.COLOR_TOOLBAR_GREY.get_int()
|
||||||
|
|
||||||
class FriendsBox(hippo.CanvasBox):
|
class FriendsBox(hippo.CanvasBox):
|
||||||
def __init__(self, shell):
|
def __init__(self, shell):
|
||||||
|
Loading…
Reference in New Issue
Block a user