Fri, 18 Nov 2005 16:37:51 +0000
[gaim-migrate @ 14436]
SF Patch #1356575 from Kevin Stange (SimGuy)
"This patch moves buddy pounces out of the menu and into
a new dialog, as suggested by Sean. I'm not ready to
say this is finished, but it's a solid starting point
and it does work.
I changed the namespacing a little from gaim_gtkpounce
to gaim_gtk_pounce to be consistent with the rest of Gaim.
I wanted to try to get more information into the pounce
manager, but I wasn't sure how to display it. I
thought perhaps a column containing a row of icons
representing which events are being watched (so the
user can see which of several pounces for the same
buddy are which), however, while I know how to do this,
there aren't icons in Gaim suitable for representing
all the events. Like "returned from away" and
"idle/unidle", as far as I can see. I'm not sure what
else could be shown to make the manager dialog more
"informative."
The dialog updates automatically to show pounces only
for connected accounts and updates when a pounce is
added, changed, or removed in some other way than the
dialog.
I'd like to get feedback on it if anyone has anything
they think I should change or fix, I'll do that and
update this patch. Otherwise, feel free to commit. :)"
As ridingpigs commented in the tracker, this is "far better than the current menu thing."
I made a few small changes to this. I believe most of them were related to adding hooks to disable things if there were no accounts connected. I also sorte
d the Tools menu a bit and updated the docklet to match.
I wish the plugin action code could sort the items it added.
committer: Richard Laager <rlaager@pidgin.im>
| 5530 | 1 | /** |
| 2 | * @file gtkprefs.h GTK+ Preferences | |
| 3 | * @ingroup gtkui | |
| 4 | * | |
| 5 | * gaim | |
| 6 | * | |
| 8046 | 7 | * Gaim is the legal property of its developers, whose names are too numerous |
| 8 | * to list here. Please refer to the COPYRIGHT file distributed with this | |
| 9 | * source distribution. | |
| 5530 | 10 | * |
| 11 | * This program is free software; you can redistribute it and/or modify | |
| 12 | * it under the terms of the GNU General Public License as published by | |
| 13 | * the Free Software Foundation; either version 2 of the License, or | |
| 14 | * (at your option) any later version. | |
| 15 | * | |
| 16 | * This program is distributed in the hope that it will be useful, | |
| 17 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
| 18 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
| 19 | * GNU General Public License for more details. | |
| 20 | * | |
| 21 | * You should have received a copy of the GNU General Public License | |
| 22 | * along with this program; if not, write to the Free Software | |
| 23 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
| 24 | * | |
| 25 | */ | |
|
9713
bb37562302a1
[gaim-migrate @ 10574]
Mark Doliner <markdoliner@pidgin.im>
parents:
9422
diff
changeset
|
26 | #ifndef _GAIM_GTKPREFS_H_ |
|
bb37562302a1
[gaim-migrate @ 10574]
Mark Doliner <markdoliner@pidgin.im>
parents:
9422
diff
changeset
|
27 | #define _GAIM_GTKPREFS_H_ |
|
bb37562302a1
[gaim-migrate @ 10574]
Mark Doliner <markdoliner@pidgin.im>
parents:
9422
diff
changeset
|
28 | |
| 7976 | 29 | #include "prefs.h" |
| 5530 | 30 | |
| 31 | /** | |
| 32 | * Initializes all UI-specific preferences. | |
| 33 | */ | |
| 34 | void gaim_gtk_prefs_init(void); | |
| 35 | ||
| 36 | /** | |
| 37 | * Shows the preferences dialog. | |
| 38 | */ | |
| 39 | void gaim_gtk_prefs_show(void); | |
| 40 | ||
| 41 | /** | |
| 7976 | 42 | * Add a new checkbox for a boolean preference |
| 43 | * | |
| 44 | * @param title The text to be displayed as the checkbox label | |
| 45 | * @param key The key of the gaim bool pref that will be represented by the checkbox | |
| 46 | * @param page The page to which the new checkbox will be added | |
| 47 | */ | |
| 7987 | 48 | GtkWidget *gaim_gtk_prefs_checkbox(const char *title, const char *key, |
| 49 | GtkWidget *page); | |
| 7976 | 50 | |
| 51 | /** | |
| 52 | * Add a new spin button representing an int preference | |
| 53 | * | |
| 54 | * @param page The page to which the spin button will be added | |
| 55 | * @param title The text to be displayed as the spin button label | |
| 7987 | 56 | * @param key The key of the int pref that will be represented by the spin button |
| 7976 | 57 | * @param min The minimum value of the spin button |
| 58 | * @param max The maximum value of the spin button | |
| 59 | * @param sg If not NULL, the size group to which the spin button will be added | |
|
8238
f7d22f952df5
[gaim-migrate @ 8961]
Mark Doliner <markdoliner@pidgin.im>
parents:
8046
diff
changeset
|
60 | * @return An hbox containing both the label and the spinner. Can be |
|
8735
01248ea222d3
[gaim-migrate @ 9490]
Jonathan Champ <royanee@users.sourceforge.net>
parents:
8713
diff
changeset
|
61 | * used to set the widgets to sensitive or insensitive based on the |
|
8238
f7d22f952df5
[gaim-migrate @ 8961]
Mark Doliner <markdoliner@pidgin.im>
parents:
8046
diff
changeset
|
62 | * value of a checkbox. |
| 7976 | 63 | */ |
| 7987 | 64 | GtkWidget *gaim_gtk_prefs_labeled_spin_button(GtkWidget *page, |
| 10367 | 65 | const gchar *title, const char *key, int min, int max, GtkSizeGroup *sg); |
| 7976 | 66 | |
| 67 | /** | |
| 9422 | 68 | * Add a new entry representing a string preference |
| 69 | * | |
| 70 | * @param page The page to which the entry will be added | |
| 71 | * @param title The text to be displayed as the entry label | |
| 72 | * @param key The key of the string pref that will be represented by the entry | |
| 73 | * @param sg If not NULL, the size group to which the entry will be added | |
| 74 | * | |
| 75 | * @return An hbox containing both the label and the entry. Can be used to set | |
| 76 | * the widgets to sensitive or insensitive based on the value of a | |
| 77 | * checkbox. | |
| 78 | */ | |
| 79 | GtkWidget *gaim_gtk_prefs_labeled_entry(GtkWidget *page, const gchar *title, | |
| 10367 | 80 | const char *key, GtkSizeGroup *sg); |
| 9422 | 81 | |
| 82 | /** | |
| 7976 | 83 | * Add a new dropdown representing a preference of the specified type |
| 84 | * | |
| 7978 | 85 | * @param page The page to which the dropdown will be added |
| 86 | * @param title The text to be displayed as the dropdown label | |
| 7976 | 87 | * @param type The type of preference to be stored in the generated dropdown |
| 7987 | 88 | * @param key The key of the pref that will be represented by the dropdown |
| 8713 | 89 | * @param ... The choices to be added to the dropdown, choices should be |
| 90 | * paired as label/value | |
| 7976 | 91 | */ |
| 7987 | 92 | GtkWidget *gaim_gtk_prefs_dropdown(GtkWidget *page, const gchar *title, |
| 93 | GaimPrefType type, const char *key, ...); | |
| 7976 | 94 | |
| 95 | /** | |
| 96 | * Add a new dropdown representing a preference of the specified type | |
| 97 | * | |
| 7978 | 98 | * @param page The page to which the dropdown will be added |
| 99 | * @param title The text to be displayed as the dropdown label | |
| 7987 | 100 | * @param type The type of preference to be stored in the dropdown |
| 101 | * @param key The key of the pref that will be represented by the dropdown | |
| 8713 | 102 | * @param menuitems The choices to be added to the dropdown, choices should |
| 103 | * be paired as label/value | |
| 7976 | 104 | */ |
| 7987 | 105 | GtkWidget *gaim_gtk_prefs_dropdown_from_list(GtkWidget *page, |
| 106 | const gchar * title, GaimPrefType type, const char *key, | |
| 107 | GList *menuitems); | |
| 7976 | 108 | |
|
8905
cedfa637389f
[gaim-migrate @ 9674]
Mark Doliner <markdoliner@pidgin.im>
parents:
8900
diff
changeset
|
109 | /** |
|
cedfa637389f
[gaim-migrate @ 9674]
Mark Doliner <markdoliner@pidgin.im>
parents:
8900
diff
changeset
|
110 | * Rename legacy prefs and delete some that no longer exist. |
|
cedfa637389f
[gaim-migrate @ 9674]
Mark Doliner <markdoliner@pidgin.im>
parents:
8900
diff
changeset
|
111 | */ |
|
cedfa637389f
[gaim-migrate @ 9674]
Mark Doliner <markdoliner@pidgin.im>
parents:
8900
diff
changeset
|
112 | void gaim_gtk_prefs_update_old(); |
|
cedfa637389f
[gaim-migrate @ 9674]
Mark Doliner <markdoliner@pidgin.im>
parents:
8900
diff
changeset
|
113 | |
|
9713
bb37562302a1
[gaim-migrate @ 10574]
Mark Doliner <markdoliner@pidgin.im>
parents:
9422
diff
changeset
|
114 | #endif /* _GAIM_GTKPREFS_H_ */ |