From f7d4bd791398b3f7dccb9784193ae9c3f0dcfaec Mon Sep 17 00:00:00 2001 From: Travis Shirk Date: Sun, 12 Feb 2006 21:04:15 +0000 Subject: [PATCH] Added roles to some of the more often used windows. This should help WMs like ion "do their thing" easier. --- src/gtkgui.glade | 6 ++++++ src/message_window.py | 7 +++++++ 2 files changed, 13 insertions(+) diff --git a/src/gtkgui.glade b/src/gtkgui.glade index b2b151d32..5dea9f1ee 100644 --- a/src/gtkgui.glade +++ b/src/gtkgui.glade @@ -14,6 +14,7 @@ 400 True False + roster True False False @@ -414,6 +415,7 @@ 150 True False + accounts True False False @@ -2670,6 +2672,7 @@ 420 True False + Service Discovery True False False @@ -3271,6 +3274,7 @@ Agent JID - node False False False + preferences True False False @@ -9131,6 +9135,7 @@ Custom 350 True False + history True False False @@ -11674,6 +11679,7 @@ Static 540 True False + ace True False False diff --git a/src/message_window.py b/src/message_window.py index 510b5e609..c5c949593 100644 --- a/src/message_window.py +++ b/src/message_window.py @@ -687,12 +687,17 @@ class MessageWindowMgr: key = None win_acct = None win_type = None + win_role = 'messages' key = self._mode_to_key(contact, acct, type) if self.mode == self.ONE_MSG_WINDOW_PERACCT: win_acct = acct + win_role = acct elif self.mode == self.ONE_MSG_WINDOW_PERTYPE: win_type = type + win_role = type + elif self.mode == self.ONE_MSG_WINDOW_NEVER: + win_role = contact.jid win = None try: @@ -700,6 +705,8 @@ class MessageWindowMgr: except KeyError: win = self._new_window(win_acct, win_type) + win.window.set_role(win_role) + # Position and size window based on saved state and window mode if not self.one_window_opened(contact, acct, type): self._position_window(win, acct, type)