|
Lines 38-43
Link Here
|
| 38 |
|
38 |
|
| 39 |
#include "tile.h" |
39 |
#include "tile.h" |
| 40 |
#include "application-tile.h" |
40 |
#include "application-tile.h" |
|
|
41 |
#include "bookmark-tile.h" |
| 41 |
#include "document-tile.h" |
42 |
#include "document-tile.h" |
| 42 |
#include "directory-tile.h" |
43 |
#include "directory-tile.h" |
| 43 |
#include "system-tile.h" |
44 |
#include "system-tile.h" |
|
Lines 61-80
Link Here
|
| 61 |
#define FILE_MGR_OPEN_GCONF_KEY ROOT_GCONF_DIR "/file-area/file_mgr_open_cmd" |
62 |
#define FILE_MGR_OPEN_GCONF_KEY ROOT_GCONF_DIR "/file-area/file_mgr_open_cmd" |
| 62 |
#define APP_BLACKLIST_GCONF_KEY ROOT_GCONF_DIR "/file-area/file_blacklist" |
63 |
#define APP_BLACKLIST_GCONF_KEY ROOT_GCONF_DIR "/file-area/file_blacklist" |
| 63 |
|
64 |
|
| 64 |
#define LOCKDOWN_GCONF_DIR ROOT_GCONF_DIR "/lock-down" |
65 |
#define LOCKDOWN_GCONF_DIR ROOT_GCONF_DIR "/lock-down" |
| 65 |
#define MORE_LINK_VIS_GCONF_KEY LOCKDOWN_GCONF_DIR "/application_browser_link_visible" |
66 |
#define MORE_LINK_VIS_GCONF_KEY LOCKDOWN_GCONF_DIR "/application_browser_link_visible" |
| 66 |
#define SEARCH_VIS_GCONF_KEY LOCKDOWN_GCONF_DIR "/search_area_visible" |
67 |
#define SEARCH_VIS_GCONF_KEY LOCKDOWN_GCONF_DIR "/search_area_visible" |
| 67 |
#define STATUS_VIS_GCONF_KEY LOCKDOWN_GCONF_DIR "/status_area_visible" |
68 |
#define STATUS_VIS_GCONF_KEY LOCKDOWN_GCONF_DIR "/status_area_visible" |
| 68 |
#define SYSTEM_VIS_GCONF_KEY LOCKDOWN_GCONF_DIR "/system_area_visible" |
69 |
#define SYSTEM_VIS_GCONF_KEY LOCKDOWN_GCONF_DIR "/system_area_visible" |
| 69 |
#define SHOWABLE_TYPES_GCONF_KEY LOCKDOWN_GCONF_DIR "/showable_file_types" |
70 |
#define SHOWABLE_TYPES_GCONF_KEY LOCKDOWN_GCONF_DIR "/showable_file_types" |
| 70 |
#define MODIFIABLE_SYSTEM_GCONF_KEY LOCKDOWN_GCONF_DIR "/user_modifiable_system_area" |
71 |
#define MODIFIABLE_SYSTEM_GCONF_KEY LOCKDOWN_GCONF_DIR "/user_modifiable_system_area" |
| 71 |
#define MODIFIABLE_APPS_GCONF_KEY LOCKDOWN_GCONF_DIR "/user_modifiable_apps" |
72 |
#define MODIFIABLE_APPS_GCONF_KEY LOCKDOWN_GCONF_DIR "/user_modifiable_apps" |
| 72 |
#define MODIFIABLE_DOCS_GCONF_KEY LOCKDOWN_GCONF_DIR "/user_modifiable_docs" |
73 |
#define MODIFIABLE_DOCS_GCONF_KEY LOCKDOWN_GCONF_DIR "/user_modifiable_docs" |
| 73 |
#define MODIFIABLE_DIRS_GCONF_KEY LOCKDOWN_GCONF_DIR "/user_modifiable_dirs" |
74 |
#define MODIFIABLE_BOOKMARKS_GCONF_KEY LOCKDOWN_GCONF_DIR "/user_modifiable_bookmarks" |
| 74 |
#define DISABLE_TERMINAL_GCONF_KEY "/desktop/gnome/lockdown/disable_command_line" |
75 |
#define DISABLE_TERMINAL_GCONF_KEY "/desktop/gnome/lockdown/disable_command_line" |
| 75 |
#define PANEL_LOCKDOWN_GCONF_DIR "/apps/panel/global" |
76 |
#define PANEL_LOCKDOWN_GCONF_DIR "/apps/panel/global" |
| 76 |
#define DISABLE_LOGOUT_GCONF_KEY PANEL_LOCKDOWN_GCONF_DIR "/disable_log_out" |
77 |
#define DISABLE_LOGOUT_GCONF_KEY PANEL_LOCKDOWN_GCONF_DIR "/disable_log_out" |
| 77 |
#define DISABLE_LOCKSCREEN_GCONF_KEY PANEL_LOCKDOWN_GCONF_DIR "/disable_lock_screen" |
78 |
#define DISABLE_LOCKSCREEN_GCONF_KEY PANEL_LOCKDOWN_GCONF_DIR "/disable_lock_screen" |
| 78 |
|
79 |
|
| 79 |
G_DEFINE_TYPE (MainMenuUI, main_menu_ui, G_TYPE_OBJECT) |
80 |
G_DEFINE_TYPE (MainMenuUI, main_menu_ui, G_TYPE_OBJECT) |
| 80 |
|
81 |
|
|
Lines 129-135
Link Here
|
| 129 |
guint modifiable_system_gconf_mntr_id; |
130 |
guint modifiable_system_gconf_mntr_id; |
| 130 |
guint modifiable_apps_gconf_mntr_id; |
131 |
guint modifiable_apps_gconf_mntr_id; |
| 131 |
guint modifiable_docs_gconf_mntr_id; |
132 |
guint modifiable_docs_gconf_mntr_id; |
| 132 |
guint modifiable_dirs_gconf_mntr_id; |
133 |
guint modifiable_bookmarks_gconf_mntr_id; |
| 133 |
guint disable_term_gconf_mntr_id; |
134 |
guint disable_term_gconf_mntr_id; |
| 134 |
guint disable_logout_gconf_mntr_id; |
135 |
guint disable_logout_gconf_mntr_id; |
| 135 |
guint disable_lockscreen_gconf_mntr_id; |
136 |
guint disable_lockscreen_gconf_mntr_id; |
|
Lines 142-162
Link Here
|
| 142 |
|
143 |
|
| 143 |
static void main_menu_ui_finalize (GObject *); |
144 |
static void main_menu_ui_finalize (GObject *); |
| 144 |
|
145 |
|
| 145 |
static void create_panel_button (MainMenuUI *); |
146 |
static void create_panel_button (MainMenuUI *); |
| 146 |
static void create_slab_window (MainMenuUI *); |
147 |
static void create_slab_window (MainMenuUI *); |
| 147 |
static void create_search_section (MainMenuUI *); |
148 |
static void create_search_section (MainMenuUI *); |
| 148 |
static void create_file_section (MainMenuUI *); |
149 |
static void create_file_section (MainMenuUI *); |
| 149 |
static void create_user_apps_section (MainMenuUI *); |
150 |
static void create_user_apps_section (MainMenuUI *); |
| 150 |
static void create_rct_apps_section (MainMenuUI *); |
151 |
static void create_rct_apps_section (MainMenuUI *); |
| 151 |
static void create_user_docs_section (MainMenuUI *); |
152 |
static void create_user_docs_section (MainMenuUI *); |
| 152 |
static void create_rct_docs_section (MainMenuUI *); |
153 |
static void create_rct_docs_section (MainMenuUI *); |
| 153 |
static void create_user_dirs_section (MainMenuUI *); |
154 |
static void create_user_bookmarks_section (MainMenuUI *); |
| 154 |
static void create_system_section (MainMenuUI *); |
155 |
static void create_system_section (MainMenuUI *); |
| 155 |
static void create_status_section (MainMenuUI *); |
156 |
static void create_status_section (MainMenuUI *); |
| 156 |
static void create_more_buttons (MainMenuUI *); |
157 |
static void create_more_buttons (MainMenuUI *); |
| 157 |
static void setup_file_tables (MainMenuUI *); |
158 |
static void setup_file_tables (MainMenuUI *); |
| 158 |
static void setup_bookmark_agents (MainMenuUI *); |
159 |
static void setup_bookmark_agents (MainMenuUI *); |
| 159 |
static void setup_lock_down (MainMenuUI *); |
160 |
static void setup_lock_down (MainMenuUI *); |
| 160 |
|
161 |
|
| 161 |
static void select_page (MainMenuUI *); |
162 |
static void select_page (MainMenuUI *); |
| 162 |
static void update_limits (MainMenuUI *); |
163 |
static void update_limits (MainMenuUI *); |
|
Lines 173-182
Link Here
|
| 173 |
static gboolean app_is_in_blacklist (const gchar *); |
174 |
static gboolean app_is_in_blacklist (const gchar *); |
| 174 |
|
175 |
|
| 175 |
static Tile *item_to_user_app_tile (BookmarkItem *, gpointer); |
176 |
static Tile *item_to_user_app_tile (BookmarkItem *, gpointer); |
|
|
177 |
static Tile *item_to_bookmark_tile (BookmarkItem *, gpointer); |
| 176 |
static Tile *item_to_recent_app_tile (BookmarkItem *, gpointer); |
178 |
static Tile *item_to_recent_app_tile (BookmarkItem *, gpointer); |
| 177 |
static Tile *item_to_user_doc_tile (BookmarkItem *, gpointer); |
179 |
static Tile *item_to_user_doc_tile (BookmarkItem *, gpointer); |
| 178 |
static Tile *item_to_recent_doc_tile (BookmarkItem *, gpointer); |
180 |
static Tile *item_to_recent_doc_tile (BookmarkItem *, gpointer); |
| 179 |
static Tile *item_to_dir_tile (BookmarkItem *, gpointer); |
|
|
| 180 |
static Tile *item_to_system_tile (BookmarkItem *, gpointer); |
181 |
static Tile *item_to_system_tile (BookmarkItem *, gpointer); |
| 181 |
static BookmarkItem *app_uri_to_item (const gchar *, gpointer); |
182 |
static BookmarkItem *app_uri_to_item (const gchar *, gpointer); |
| 182 |
static BookmarkItem *doc_uri_to_item (const gchar *, gpointer); |
183 |
static BookmarkItem *doc_uri_to_item (const gchar *, gpointer); |
|
Lines 237-243
Link Here
|
| 237 |
enum { |
238 |
enum { |
| 238 |
APPS_PAGE, |
239 |
APPS_PAGE, |
| 239 |
DOCS_PAGE, |
240 |
DOCS_PAGE, |
| 240 |
DIRS_PAGE |
241 |
BOOKMARKS_PAGE |
| 241 |
}; |
242 |
}; |
| 242 |
|
243 |
|
| 243 |
enum { |
244 |
enum { |
|
Lines 245-251
Link Here
|
| 245 |
RCNT_APPS_TABLE, |
246 |
RCNT_APPS_TABLE, |
| 246 |
USER_DOCS_TABLE, |
247 |
USER_DOCS_TABLE, |
| 247 |
RCNT_DOCS_TABLE, |
248 |
RCNT_DOCS_TABLE, |
| 248 |
USER_DIRS_TABLE |
249 |
USER_BOOKMARKS_TABLE |
| 249 |
}; |
250 |
}; |
| 250 |
|
251 |
|
| 251 |
enum { |
252 |
enum { |
|
Lines 277-302
Link Here
|
| 277 |
priv->panel_button_xml = glade_xml_new (glade_xml_path, "slab-panel-button-root", NULL); |
278 |
priv->panel_button_xml = glade_xml_new (glade_xml_path, "slab-panel-button-root", NULL); |
| 278 |
g_free (glade_xml_path); |
279 |
g_free (glade_xml_path); |
| 279 |
|
280 |
|
| 280 |
setup_bookmark_agents (this); |
281 |
setup_bookmark_agents (this); |
| 281 |
create_panel_button (this); |
282 |
create_panel_button (this); |
| 282 |
create_slab_window (this); |
283 |
create_slab_window (this); |
| 283 |
create_search_section (this); |
284 |
create_search_section (this); |
| 284 |
create_file_section (this); |
285 |
create_file_section (this); |
| 285 |
create_user_apps_section (this); |
286 |
create_user_apps_section (this); |
| 286 |
create_rct_apps_section (this); |
287 |
create_rct_apps_section (this); |
| 287 |
create_user_docs_section (this); |
288 |
create_user_docs_section (this); |
| 288 |
create_rct_docs_section (this); |
289 |
create_rct_docs_section (this); |
| 289 |
create_user_dirs_section (this); |
290 |
create_user_bookmarks_section (this); |
| 290 |
create_system_section (this); |
291 |
create_system_section (this); |
| 291 |
create_status_section (this); |
292 |
create_status_section (this); |
| 292 |
create_more_buttons (this); |
293 |
create_more_buttons (this); |
| 293 |
setup_file_tables (this); |
294 |
setup_file_tables (this); |
| 294 |
setup_lock_down (this); |
295 |
setup_lock_down (this); |
| 295 |
|
296 |
|
| 296 |
bind_beagle_search_key (this); |
297 |
bind_beagle_search_key (this); |
| 297 |
update_limits (this); |
298 |
update_limits (this); |
| 298 |
select_page (this); |
299 |
select_page (this); |
| 299 |
apply_lockdown_settings (this); |
300 |
apply_lockdown_settings (this); |
| 300 |
|
301 |
|
| 301 |
return this; |
302 |
return this; |
| 302 |
} |
303 |
} |
|
Lines 339-373
Link Here
|
| 339 |
priv->file_section = NULL; |
340 |
priv->file_section = NULL; |
| 340 |
priv->page_selectors [APPS_PAGE] = NULL; |
341 |
priv->page_selectors [APPS_PAGE] = NULL; |
| 341 |
priv->page_selectors [DOCS_PAGE] = NULL; |
342 |
priv->page_selectors [DOCS_PAGE] = NULL; |
| 342 |
priv->page_selectors [DIRS_PAGE] = NULL; |
343 |
priv->page_selectors [BOOKMARKS_PAGE] = NULL; |
| 343 |
priv->notebook_page_ids [APPS_PAGE] = 0; |
344 |
priv->notebook_page_ids [APPS_PAGE] = 0; |
| 344 |
priv->notebook_page_ids [DOCS_PAGE] = 0; |
345 |
priv->notebook_page_ids [DOCS_PAGE] = 0; |
| 345 |
priv->notebook_page_ids [DIRS_PAGE] = 0; |
346 |
priv->notebook_page_ids [BOOKMARKS_PAGE] = 0; |
| 346 |
|
347 |
|
| 347 |
priv->file_tables [USER_APPS_TABLE] = NULL; |
348 |
priv->file_tables [USER_APPS_TABLE] = NULL; |
| 348 |
priv->file_tables [RCNT_APPS_TABLE] = NULL; |
349 |
priv->file_tables [RCNT_APPS_TABLE] = NULL; |
| 349 |
priv->file_tables [USER_DOCS_TABLE] = NULL; |
350 |
priv->file_tables [USER_DOCS_TABLE] = NULL; |
| 350 |
priv->file_tables [RCNT_DOCS_TABLE] = NULL; |
351 |
priv->file_tables [RCNT_DOCS_TABLE] = NULL; |
| 351 |
priv->file_tables [USER_DIRS_TABLE] = NULL; |
352 |
priv->file_tables [USER_BOOKMARKS_TABLE] = NULL; |
| 352 |
priv->table_sections [USER_APPS_TABLE] = NULL; |
353 |
priv->table_sections [USER_APPS_TABLE] = NULL; |
| 353 |
priv->table_sections [RCNT_APPS_TABLE] = NULL; |
354 |
priv->table_sections [RCNT_APPS_TABLE] = NULL; |
| 354 |
priv->table_sections [USER_DOCS_TABLE] = NULL; |
355 |
priv->table_sections [USER_DOCS_TABLE] = NULL; |
| 355 |
priv->table_sections [RCNT_DOCS_TABLE] = NULL; |
356 |
priv->table_sections [RCNT_DOCS_TABLE] = NULL; |
| 356 |
priv->table_sections [USER_DIRS_TABLE] = NULL; |
357 |
priv->table_sections [USER_BOOKMARKS_TABLE] = NULL; |
| 357 |
priv->allowable_types [USER_APPS_TABLE] = TRUE; |
358 |
priv->allowable_types [USER_APPS_TABLE] = TRUE; |
| 358 |
priv->allowable_types [RCNT_APPS_TABLE] = TRUE; |
359 |
priv->allowable_types [RCNT_APPS_TABLE] = TRUE; |
| 359 |
priv->allowable_types [USER_DOCS_TABLE] = TRUE; |
360 |
priv->allowable_types [USER_DOCS_TABLE] = TRUE; |
| 360 |
priv->allowable_types [RCNT_DOCS_TABLE] = TRUE; |
361 |
priv->allowable_types [RCNT_DOCS_TABLE] = TRUE; |
| 361 |
priv->allowable_types [USER_DIRS_TABLE] = TRUE; |
362 |
priv->allowable_types [USER_BOOKMARKS_TABLE] = TRUE; |
| 362 |
|
363 |
|
| 363 |
priv->sys_table = NULL; |
364 |
priv->sys_table = NULL; |
| 364 |
|
365 |
|
| 365 |
priv->more_buttons [APPS_PAGE] = NULL; |
366 |
priv->more_buttons [APPS_PAGE] = NULL; |
| 366 |
priv->more_buttons [DOCS_PAGE] = NULL; |
367 |
priv->more_buttons [DOCS_PAGE] = NULL; |
| 367 |
priv->more_buttons [DIRS_PAGE] = NULL; |
368 |
priv->more_buttons [BOOKMARKS_PAGE] = NULL; |
| 368 |
priv->more_sections [APPS_PAGE] = NULL; |
369 |
priv->more_sections [APPS_PAGE] = NULL; |
| 369 |
priv->more_sections [DOCS_PAGE] = NULL; |
370 |
priv->more_sections [DOCS_PAGE] = NULL; |
| 370 |
priv->more_sections [DIRS_PAGE] = NULL; |
371 |
priv->more_sections [BOOKMARKS_PAGE] = NULL; |
| 371 |
|
372 |
|
| 372 |
priv->max_total_items = 8; |
373 |
priv->max_total_items = 8; |
| 373 |
|
374 |
|
|
Lines 386-392
Link Here
|
| 386 |
priv->modifiable_system_gconf_mntr_id = 0; |
387 |
priv->modifiable_system_gconf_mntr_id = 0; |
| 387 |
priv->modifiable_apps_gconf_mntr_id = 0; |
388 |
priv->modifiable_apps_gconf_mntr_id = 0; |
| 388 |
priv->modifiable_docs_gconf_mntr_id = 0; |
389 |
priv->modifiable_docs_gconf_mntr_id = 0; |
| 389 |
priv->modifiable_dirs_gconf_mntr_id = 0; |
390 |
priv->modifiable_bookmarks_gconf_mntr_id = 0; |
| 390 |
priv->disable_term_gconf_mntr_id = 0; |
391 |
priv->disable_term_gconf_mntr_id = 0; |
| 391 |
priv->disable_logout_gconf_mntr_id = 0; |
392 |
priv->disable_logout_gconf_mntr_id = 0; |
| 392 |
priv->disable_lockscreen_gconf_mntr_id = 0; |
393 |
priv->disable_lockscreen_gconf_mntr_id = 0; |
|
Lines 425-431
Link Here
|
| 425 |
libslab_gconf_notify_remove (priv->modifiable_system_gconf_mntr_id); |
426 |
libslab_gconf_notify_remove (priv->modifiable_system_gconf_mntr_id); |
| 426 |
libslab_gconf_notify_remove (priv->modifiable_apps_gconf_mntr_id); |
427 |
libslab_gconf_notify_remove (priv->modifiable_apps_gconf_mntr_id); |
| 427 |
libslab_gconf_notify_remove (priv->modifiable_docs_gconf_mntr_id); |
428 |
libslab_gconf_notify_remove (priv->modifiable_docs_gconf_mntr_id); |
| 428 |
libslab_gconf_notify_remove (priv->modifiable_dirs_gconf_mntr_id); |
429 |
libslab_gconf_notify_remove (priv->modifiable_bookmarks_gconf_mntr_id); |
| 429 |
libslab_gconf_notify_remove (priv->disable_term_gconf_mntr_id); |
430 |
libslab_gconf_notify_remove (priv->disable_term_gconf_mntr_id); |
| 430 |
libslab_gconf_notify_remove (priv->disable_logout_gconf_mntr_id); |
431 |
libslab_gconf_notify_remove (priv->disable_logout_gconf_mntr_id); |
| 431 |
libslab_gconf_notify_remove (priv->disable_lockscreen_gconf_mntr_id); |
432 |
libslab_gconf_notify_remove (priv->disable_lockscreen_gconf_mntr_id); |
|
Lines 607-618
Link Here
|
| 607 |
priv->main_menu_xml, "slab-page-selector-button-applications"); |
608 |
priv->main_menu_xml, "slab-page-selector-button-applications"); |
| 608 |
priv->page_selectors [DOCS_PAGE] = glade_xml_get_widget ( |
609 |
priv->page_selectors [DOCS_PAGE] = glade_xml_get_widget ( |
| 609 |
priv->main_menu_xml, "slab-page-selector-button-documents"); |
610 |
priv->main_menu_xml, "slab-page-selector-button-documents"); |
| 610 |
priv->page_selectors [DIRS_PAGE] = glade_xml_get_widget ( |
611 |
priv->page_selectors [BOOKMARKS_PAGE] = glade_xml_get_widget ( |
| 611 |
priv->main_menu_xml, "slab-page-selector-button-places"); |
612 |
priv->main_menu_xml, "slab-page-selector-button-places"); |
| 612 |
|
613 |
|
| 613 |
pages [APPS_PAGE] = glade_xml_get_widget (priv->main_menu_xml, "applications-page"); |
614 |
pages [APPS_PAGE] = glade_xml_get_widget (priv->main_menu_xml, "applications-page"); |
| 614 |
pages [DOCS_PAGE] = glade_xml_get_widget (priv->main_menu_xml, "documents-page"); |
615 |
pages [DOCS_PAGE] = glade_xml_get_widget (priv->main_menu_xml, "documents-page"); |
| 615 |
pages [DIRS_PAGE] = glade_xml_get_widget (priv->main_menu_xml, "places-page"); |
616 |
pages [BOOKMARKS_PAGE] = glade_xml_get_widget (priv->main_menu_xml, "places-page"); |
| 616 |
|
617 |
|
| 617 |
for (i = 0; i < 3; ++i) { |
618 |
for (i = 0; i < 3; ++i) { |
| 618 |
gtk_container_child_get ( |
619 |
gtk_container_child_get ( |
|
Lines 638-645
Link Here
|
| 638 |
priv->main_menu_xml, "user-docs-section"); |
639 |
priv->main_menu_xml, "user-docs-section"); |
| 639 |
priv->table_sections [RCNT_DOCS_TABLE] = glade_xml_get_widget ( |
640 |
priv->table_sections [RCNT_DOCS_TABLE] = glade_xml_get_widget ( |
| 640 |
priv->main_menu_xml, "recent-docs-section"); |
641 |
priv->main_menu_xml, "recent-docs-section"); |
| 641 |
priv->table_sections [USER_DIRS_TABLE] = glade_xml_get_widget ( |
642 |
priv->table_sections [USER_BOOKMARKS_TABLE] = glade_xml_get_widget ( |
| 642 |
priv->main_menu_xml, "user-dirs-section"); |
643 |
priv->main_menu_xml, "user-bookmarks-section"); |
| 643 |
} |
644 |
} |
| 644 |
|
645 |
|
| 645 |
static void |
646 |
static void |
|
Lines 790-796
Link Here
|
| 790 |
} |
791 |
} |
| 791 |
|
792 |
|
| 792 |
static void |
793 |
static void |
| 793 |
create_user_dirs_section (MainMenuUI *this) |
794 |
create_user_bookmarks_section (MainMenuUI *this) |
| 794 |
{ |
795 |
{ |
| 795 |
MainMenuUIPrivate *priv = PRIVATE (this); |
796 |
MainMenuUIPrivate *priv = PRIVATE (this); |
| 796 |
|
797 |
|
|
Lines 798-810
Link Here
|
| 798 |
|
799 |
|
| 799 |
|
800 |
|
| 800 |
ctnr = GTK_CONTAINER (glade_xml_get_widget ( |
801 |
ctnr = GTK_CONTAINER (glade_xml_get_widget ( |
| 801 |
priv->main_menu_xml, "user-dirs-table-container")); |
802 |
priv->main_menu_xml, "user-bookmarks-table-container")); |
| 802 |
|
803 |
|
| 803 |
priv->file_tables [USER_DIRS_TABLE] = TILE_TABLE (tile_table_new ( |
804 |
priv->file_tables [USER_BOOKMARKS_TABLE] = TILE_TABLE (tile_table_new ( |
| 804 |
priv->bm_agents [BOOKMARK_STORE_USER_DIRS], -1, 2, FALSE, FALSE, |
805 |
priv->bm_agents [BOOKMARK_STORE_USER_DIRS], -1, 2, FALSE, FALSE, |
| 805 |
item_to_dir_tile, this, NULL, NULL)); |
806 |
item_to_bookmark_tile, this, NULL, NULL)); |
| 806 |
|
807 |
|
| 807 |
gtk_container_add (ctnr, GTK_WIDGET (priv->file_tables [USER_DIRS_TABLE])); |
808 |
gtk_container_add (ctnr, GTK_WIDGET (priv->file_tables [USER_BOOKMARKS_TABLE])); |
| 808 |
} |
809 |
} |
| 809 |
|
810 |
|
| 810 |
static void |
811 |
static void |
|
Lines 831-837
Link Here
|
| 831 |
|
832 |
|
| 832 |
priv->more_sections [0] = glade_xml_get_widget (priv->main_menu_xml, "more-apps-section"); |
833 |
priv->more_sections [0] = glade_xml_get_widget (priv->main_menu_xml, "more-apps-section"); |
| 833 |
priv->more_sections [1] = glade_xml_get_widget (priv->main_menu_xml, "more-docs-section"); |
834 |
priv->more_sections [1] = glade_xml_get_widget (priv->main_menu_xml, "more-docs-section"); |
| 834 |
priv->more_sections [2] = glade_xml_get_widget (priv->main_menu_xml, "more-dirs-section"); |
835 |
priv->more_sections [2] = glade_xml_get_widget (priv->main_menu_xml, "more-bookmarks-section"); |
| 835 |
} |
836 |
} |
| 836 |
|
837 |
|
| 837 |
static void |
838 |
static void |
|
Lines 913-920
Link Here
|
| 913 |
MODIFIABLE_APPS_GCONF_KEY, lockdown_notify_cb, this); |
914 |
MODIFIABLE_APPS_GCONF_KEY, lockdown_notify_cb, this); |
| 914 |
priv->modifiable_docs_gconf_mntr_id = libslab_gconf_notify_add ( |
915 |
priv->modifiable_docs_gconf_mntr_id = libslab_gconf_notify_add ( |
| 915 |
MODIFIABLE_DOCS_GCONF_KEY, lockdown_notify_cb, this); |
916 |
MODIFIABLE_DOCS_GCONF_KEY, lockdown_notify_cb, this); |
| 916 |
priv->modifiable_dirs_gconf_mntr_id = libslab_gconf_notify_add ( |
917 |
priv->modifiable_bookmarks_gconf_mntr_id = libslab_gconf_notify_add ( |
| 917 |
MODIFIABLE_DIRS_GCONF_KEY, lockdown_notify_cb, this); |
918 |
MODIFIABLE_BOOKMARKS_GCONF_KEY, lockdown_notify_cb, this); |
| 918 |
priv->disable_term_gconf_mntr_id = libslab_gconf_notify_add ( |
919 |
priv->disable_term_gconf_mntr_id = libslab_gconf_notify_add ( |
| 919 |
DISABLE_TERMINAL_GCONF_KEY, lockdown_notify_cb, this); |
920 |
DISABLE_TERMINAL_GCONF_KEY, lockdown_notify_cb, this); |
| 920 |
priv->disable_logout_gconf_mntr_id = libslab_gconf_notify_add ( |
921 |
priv->disable_logout_gconf_mntr_id = libslab_gconf_notify_add ( |
|
Lines 1000-1008
Link Here
|
| 1000 |
} |
1001 |
} |
| 1001 |
|
1002 |
|
| 1002 |
static Tile * |
1003 |
static Tile * |
| 1003 |
item_to_dir_tile (BookmarkItem *item, gpointer data) |
1004 |
item_to_bookmark_tile (BookmarkItem *item, gpointer data) |
| 1004 |
{ |
1005 |
{ |
| 1005 |
return TILE (directory_tile_new (item->uri, item->title, item->icon)); |
1006 |
return TILE (bookmark_tile_new (item->uri, item->title, item->icon)); |
| 1006 |
} |
1007 |
} |
| 1007 |
|
1008 |
|
| 1008 |
static Tile * |
1009 |
static Tile * |
|
Lines 1184-1190
Link Here
|
| 1184 |
} |
1185 |
} |
| 1185 |
|
1186 |
|
| 1186 |
g_object_get ( |
1187 |
g_object_get ( |
| 1187 |
priv->file_tables [USER_DIRS_TABLE], |
1188 |
priv->file_tables [USER_BOOKMARKS_TABLE], |
| 1188 |
"n-rows", & n_rows, "n-columns", & n_cols, NULL); |
1189 |
"n-rows", & n_rows, "n-columns", & n_cols, NULL); |
| 1189 |
|
1190 |
|
| 1190 |
if (priv->max_total_items < (n_rows * n_cols)) |
1191 |
if (priv->max_total_items < (n_rows * n_cols)) |
|
Lines 1302-1311
Link Here
|
| 1302 |
else |
1303 |
else |
| 1303 |
gtk_widget_hide (priv->page_selectors [DOCS_PAGE]); |
1304 |
gtk_widget_hide (priv->page_selectors [DOCS_PAGE]); |
| 1304 |
|
1305 |
|
| 1305 |
if (GTK_WIDGET_VISIBLE (priv->table_sections [USER_DIRS_TABLE])) |
1306 |
if (GTK_WIDGET_VISIBLE (priv->table_sections [USER_BOOKMARKS_TABLE])) |
| 1306 |
gtk_widget_show (priv->page_selectors [DIRS_PAGE]); |
1307 |
gtk_widget_show (priv->page_selectors [BOOKMARKS_PAGE]); |
| 1307 |
else |
1308 |
else |
| 1308 |
gtk_widget_hide (priv->page_selectors [DIRS_PAGE]); |
1309 |
gtk_widget_hide (priv->page_selectors [BOOKMARKS_PAGE]); |
| 1309 |
} |
1310 |
} |
| 1310 |
|
1311 |
|
| 1311 |
static gchar ** |
1312 |
static gchar ** |
|
Lines 1517-1523
Link Here
|
| 1517 |
tile_table_reload (priv->file_tables [USER_APPS_TABLE]); |
1518 |
tile_table_reload (priv->file_tables [USER_APPS_TABLE]); |
| 1518 |
tile_table_reload (priv->file_tables [RCNT_APPS_TABLE]); |
1519 |
tile_table_reload (priv->file_tables [RCNT_APPS_TABLE]); |
| 1519 |
tile_table_reload (priv->file_tables [USER_DOCS_TABLE]); |
1520 |
tile_table_reload (priv->file_tables [USER_DOCS_TABLE]); |
| 1520 |
tile_table_reload (priv->file_tables [USER_DIRS_TABLE]); |
1521 |
tile_table_reload (priv->file_tables [USER_BOOKMARKS_TABLE]); |
| 1521 |
|
1522 |
|
| 1522 |
update_limits (this); |
1523 |
update_limits (this); |
| 1523 |
} |
1524 |
} |