From eba0fd70ebf937ad10f7bb1221268a9552d494fa Mon Sep 17 00:00:00 2001 From: Vincent Sanders Date: Sun, 10 Dec 2017 22:57:06 +0000 Subject: clean up toolbar configuration to be slightly less buggy --- frontends/gtk/res/options.gtk2.ui | 5809 +++++++++++++++++++------------------ frontends/gtk/res/toolbar.gtk2.ui | 183 +- frontends/gtk/res/toolbar.gtk3.ui | 242 +- frontends/gtk/scaffolding.c | 8 +- frontends/gtk/toolbar.c | 124 +- 5 files changed, 3157 insertions(+), 3209 deletions(-) (limited to 'frontends/gtk') diff --git a/frontends/gtk/res/options.gtk2.ui b/frontends/gtk/res/options.gtk2.ui index d5542ba5d..a1162585d 100644 --- a/frontends/gtk/res/options.gtk2.ui +++ b/frontends/gtk/res/options.gtk2.ui @@ -2,2822 +2,140 @@ - + + 0.10000000000000001 + 10 + 0.10000000000000001 + 0.10000000000000001 + 1 + + + 4096 + 1024 + 32 + 256 + + + 2048 + 16 + 4 + 16 + + + 999 + 28 + 1 + 10 + + + 100 + 1 + 1 + 10 + + + 1 + 100 + 10 + 1 + 10 + + + 1 + 100 + 1 + 1 + 10 + + + 1 + 99.900000000000006 + 16 + 0.10000000000000001 + 2 + + + 999 + 28 + 1 + 28 + + + 999 + 1 + 10 + + + 1 + 1000 + 100 + 1 + 10 + + + 1 + 65535 + 3128 + 1 + 10 + + + True False - 5 - preferencesTitle - center-on-parent - True - dialog - - - - - - True - False - 2 - - - True - False - edge - - - gtk-help - True - True - False - True - - - False - False - 0 - - - - - gtk-close - True - True - False - True - - - False - False - 1 - - - - - False - True - end - 0 - - - - - True - True - - - True - False - 6 - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 6 - - - True - False - 12 - - - True - False - preferencesStartupPage - - - False - False - 0 - - - - - True - True - - False - False - True - True - - - - - True - True - end - 1 - - - - - True - True - 0 - - - - - True - False - 6 - - - - - - preferencesStartupPageDefault - True - True - True - - - - False - False - end - 1 - - - - - preferencesStartupPageCurrent - True - True - True - - - - False - False - end - 2 - - - - - True - False - 1 - - - - - - - - - True - False - preferencesStartup - True - - - - - False - True - 6 - 0 - - - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 6 - - - preferencesSearchURLBar - True - True - False - True - - - - - True - True - 0 - - - - - True - False - 12 - - - True - False - preferencesSearchProvider - - - False - False - 0 - - - - - True - False - liststore_search_provider - - - - - - 0 - - - - - True - True - 1 - - - - - True - True - 1 - - - - - - - - - True - False - preferencesSearch - True - - - - - False - True - 6 - 1 - - - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 6 - - - preferencesDownloadsRemove - True - True - False - True - - - - - False - True - 0 - - - - - preferencesDownloadsConfirm - True - True - False - True - - - - - False - True - 1 - - - - - True - False - 12 - - - True - False - preferencesDownloadsLocation - - - False - True - 0 - - - - - True - False - select-folder - - - - - True - True - 1 - - - - - False - True - 2 - - - - - - - - - True - False - preferencesDownloads - True - - - - - False - True - 6 - 2 - - - - - - - True - False - preferencesMainTabtitle - - - False - - - - - True - False - 6 - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 6 - - - preferencesTabsAlways - True - True - False - True - - - - - True - True - 0 - - - - - preferencesTabsSwitch - True - True - False - True - - - - - True - True - 1 - - - - - preferencesTabsNewly - True - True - False - True - - - - - True - True - 2 - - - - - True - False - 12 - - - True - False - preferencesTabsPosition - - - False - False - 0 - - - - - True - False - liststore_tab_position - - - - - - 0 - - - - - True - True - 1 - - - - - True - True - 3 - - - - - - - - - True - False - preferencesTabs - True - - - - - False - True - 6 - 1 - - - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 6 - - - True - False - 6 - - - True - False - preferencesDeveloperView - - - False - True - 0 - - - - - True - False - liststore_developer_view - - - - - - 0 - - - - - True - True - 1 - - - - - True - True - 0 - - - - - - - - - True - False - preferencesTools - True - - - - - False - True - 6 - 2 - - - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 6 - - - preferencesURLbarDisplay - True - True - False - True - - - - - True - True - 0 - - - - - - - - - True - False - preferencesURLbar - True - - - - - False - True - 7 - 3 - - - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 6 - - - True - False - 6 - - - True - False - preferencesToolbarButtons - - - False - True - 0 - - - - - True - False - liststore_toolbar_buttontype - - - - - - 0 - - - - - True - True - 1 - - - - - True - True - 0 - - - - - - - - - True - False - preferencesToolbar - True - - - - - False - True - 6 - 4 - - - - - 1 - - - - - True - False - preferencesAppearanceTabtitle - - - 1 - False - - - - - True - False - 6 - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 6 - - - preferencesControlPrevent - True - True - False - True - - - - - False - False - 0 - - - - - preferencesControlHide - True - True - False - True - - - - - False - False - 1 - - - - - preferencesControlEnable - True - True - False - True - - - - - False - False - 2 - - - - - preferencesControlDisable - True - True - False - True - - - - - False - False - 3 - - - - - preferencesControlHigh - True - True - False - True - - - - - True - True - 4 - - - - - True - False - 6 - - - True - False - preferencesControlLoad - - - False - True - 0 - - - - - True - False - liststore_image_loading - - - - - - 0 - - - - - True - True - 1 - - - - - True - True - 5 - - - - - - - - - True - False - preferencesControl - True - - - - - False - True - 6 - 0 - - - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 6 - - - preferencesAnimationEnable - True - True - False - True - - - - - True - True - 0 - - - - - True - False - 12 - - - True - False - preferencesAnimationMinimum - - - False - True - 0 - - - - - True - True - True - preferencesAnimationMinimumTooltip - - False - False - True - True - adjustment_animation_time - 1 - 1 - True - if-valid - - - - - False - True - 1 - - - - - True - True - 1 - - - - - - - - - True - False - preferencesAnimation - True - - - - - False - True - 6 - 1 - - - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 12 - - - True - False - 6 - - - True - False - preferencesFontsDefault - - - False - True - 0 - - - - - True - False - liststore_defaultfont - - - - - - 0 - - - - - True - True - 1 - - - - - True - True - 0 - - - - - True - False - 6 - - - True - False - preferencesFontsSize - - - False - True - 0 - - - - - True - True - True - preferencesFontsSizeTooltip - 4 - - 4 - False - False - True - True - adjustment_font_default_size - 1 - 1 - True - - - - - False - True - 1 - - - - - False - True - 1 - - - - - preferencesFontsPreview - True - True - True - image1 - True - - - - False - True - 2 - - - - - - - - - True - False - preferencesFonts - True - - - - - False - True - 2 - - - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 6 - - - True - False - 12 - - - True - False - preferencesLanguagePreferred - - - False - True - 0 - - - - - True - False - True - preferencesLanguagePreferredTooltip - liststore_content_language - - - - - 0 - - - 1 - - - - - 1 - - - 0 - - - - - True - True - 1 - - - - - True - True - 0 - - - - - - - - - True - False - preferencesLanguage - True - - - - - False - True - 3 - - - - - 2 - - - - - True - False - preferencesContentTabtitle - - - 2 - False - - - - - True - False - 6 - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 6 - - - preferencesGeneralReferral - True - True - False - True - - - - - True - True - 0 - - - - - preferencesGeneralDNT - True - True - False - True - - - - - True - True - 1 - - - - - - - - - True - False - preferencesGeneral - True - - - - - False - True - 6 - 0 - - - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 6 - - - preferencesHistoryShow - True - True - False - True - - - - - True - True - 0 - - - - - True - False - 6 - - - True - False - preferencesHistoryRemember - - - False - True - 0 - - - - - True - True - 4 - - 4 - False - False - True - True - adjustment_history_age - 1 - True - if-valid - - - - - False - True - 1 - - - - - True - False - preferencesHistoryDays - - - False - True - 2 - - - - - True - True - 1 - - - - - - - - - True - False - preferencesHistory - True - - - - - False - True - 6 - 1 - - - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 6 - - - True - False - 3 - 3 - 6 - 6 - - - True - False - 0 - preferencesCacheMemory - - - GTK_FILL - - - - - True - False - 0 - preferencesCacheDisc - - - 1 - 2 - GTK_FILL - - - - - True - False - 0 - preferencesCacheExpire - - - 2 - 3 - GTK_FILL - - - - - True - True - - 5 - False - False - True - True - adjustment_cache_memory_size - 1 - True - - - - - 1 - 2 - GTK_FILL - - - - - True - True - - 5 - False - False - True - True - adjustment_cache_disc_size - 1 - True - - - - - 1 - 2 - 1 - 2 - GTK_FILL - - - - - True - True - - 3 - False - False - True - True - adjustment_disc_cache_age - 1 - True - - - - - 1 - 2 - 2 - 3 - GTK_FILL - - - - - True - False - 0 - MB - - - 2 - 3 - GTK_FILL - - - - - True - False - 0 - MB - - - 2 - 3 - 1 - 2 - GTK_FILL - - - - - True - False - 0 - preferencesHistoryDays - - - 2 - 3 - 2 - 3 - GTK_FILL - - - - - True - True - 0 - - - - - True - False - - - - - - preferencesCacheMaintenance - True - True - True - - - False - True - 1 - - - - - True - True - 1 - - - - - - - - - True - False - preferencesCache - True - - - - - False - True - 6 - 2 - - - - - 3 - - - - - True - False - preferencesPrivacyTabtitle - - - 3 - False - - - - - True - False - 6 - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 5 - 2 - 6 - 6 - - - True - False - 0 - preferencesProxyType - - - GTK_FILL - - - - - True - False - 0 - preferencesProxyHost - - - 1 - 2 - GTK_FILL - - - - - True - False - 0 - preferencesProxyUsername - - - 2 - 3 - GTK_FILL - - - - - True - False - 0 - preferencesProxyPassword - - - 3 - 4 - GTK_FILL - - - - - True - False - True - preferencesProxyTypeTooltip - liststore_proxy_type - - - - - - 0 - - - - - 1 - 2 - - - - - True - False - 6 - - - True - True - True - preferencesProxyHostTooltip - - False - False - True - True - - - - - True - True - 0 - - - - - True - False - : - - - False - True - 1 - - - - - True - True - True - preferencesProxyPortTooltip - 5 - - 5 - False - False - True - True - adjustment_proxy_port - 1 - True - if-valid - - - - - False - True - 2 - - - - - 1 - 2 - 1 - 2 - - - - - True - True - True - preferencesProxyUsernameTooltip - - False - False - True - True - - - - - 1 - 2 - 2 - 3 - - - - - True - True - True - preferencesProxyPasswordTooltip - False - - False - False - True - True - - - - - 1 - 2 - 3 - 4 - - - - - True - False - 0 - preferencesProxyNoproxy - - - 4 - 5 - GTK_FILL - - - - - True - True - True - preferencesProxyNoproxyTooltip - False - False - False - True - True - - - - - 1 - 2 - 4 - 5 - - - - - - - - - True - False - preferencesProxy - True - - - - - False - True - 6 - 0 - - - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 3 - 2 - 6 - 6 - - - True - False - 0 - preferencesFetchingMax - - - GTK_FILL - - - - - True - False - 0 - preferencesFetchingPerhost - - - 1 - 2 - GTK_FILL - - - - - True - False - 0 - preferencesFetchingCached - - - 2 - 3 - GTK_FILL - - - - - True - True - True - preferencesFetchingMaxTooltip - - 3 - False - False - True - True - adjustment_fetching_max - 1 - True - - - - - 1 - 2 - GTK_FILL - - - - - True - True - True - preferencesFetchingPerhostTooltip - - 3 - False - False - True - True - adjustment_fetching_perhost - 1 - True - - - - - 1 - 2 - 1 - 2 - GTK_FILL - - - - - True - True - True - preferencesFetchingCachedTooltip. - - 3 - False - False - True - True - adjustment_fetching_cached - 1 - True - - - - - 1 - 2 - 2 - 3 - GTK_FILL - - - - - - - - - True - False - preferencesFetching - True - - - - - False - True - 6 - 1 - - - - - 4 - - - - - True - False - preferencesNetworkTabtitle - - - 4 - False - - - - - True - False - 6 - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 6 - - - preferencesAppearanceImages - True - True - False - True - - - - - True - True - 0 - - - - - preferencesAppearanceBackground - True - True - False - True - - - - - True - True - 1 - - - - - preferencesAppearanceScalefit - True - True - False - True - - - - - True - True - 2 - - - - - True - False - 6 - - - True - False - preferencesAppearanceScale - - - False - True - 0 - - - - - True - True - 4 - - 4 - 1 - False - False - True - True - adjustment_pdf_scale - 1 - True - - - - - False - True - 1 - - - - - True - False - % - - - False - True - 2 - - - - - True - True - 3 - - - - - - - - - True - False - preferencesAppearance - True - - - - - False - True - 6 - 0 - - - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 6 - - - True - False - - - True - False - preferencesMarginsMeasurements - - - False - True - 0 - - - - - - - - True - True - 0 - - - - - True - False - 3 - 3 - - - - - - - - - - - - True - False - 6 - - - True - False - Top - - - False - True - 0 - - - - - True - True - 4 - - 5 - 1 - False - False - True - True - 1 - 1 - True - - - - - False - True - 1 - - - - - 1 - 2 - GTK_EXPAND - - - - - True - False - 6 - - - True - False - Left - - - False - True - 0 - - - - - True - True - 4 - - 5 - 1 - False - False - True - True - adjustment_pdf_lmargin - 1 - 1 - True - - - - - False - True - 1 - - - - - 1 - 2 - GTK_EXPAND - - - - - True - False - 6 - - - True - False - Bottom - - - False - True - 0 - - - - - True - True - 4 - - 5 - 1 - False - False - True - True - 1 - 1 - True - - - - - False - True - 1 - - - - - 1 - 2 - 2 - 3 - GTK_EXPAND - - - - - True - False - 6 - - - True - False - Right - - - False - True - 0 - - - - - True - True - 4 - - 5 - 1 - False - False - True - True - 1 - 1 - True - - - - - False - True - 1 - - - - - 2 - 3 - 1 - 2 - GTK_EXPAND - - - - - True - True - 1 - - - - - - - - - True - False - preferencesMargins - True - - - - - False - True - 6 - 1 - - - - - True - False - 0 - none - - - True - False - 6 - 12 - 12 - - - True - False - 7 - - - preferencesGenerationCompressed - True - True - False - True - - - - - True - True - 0 - - - - - preferencesGenerationPassword - True - True - False - True - - - - - True - True - 1 - - - - - - - - - True - False - preferencesGeneration - True - - - - - False - True - 6 - 2 - - - - - 5 - - - - - True - False - preferencesPDFTabtitle - - - 5 - False - - - - - True - True - 1 - - - - - - help - close - + 3 + gtk-apply - + - + + + - Google - - - Yahoo! - - - Microsoft Live - - - Buisiness.com - - - Omgili - - - BBC News - - - Ubuntu Packages - - - Creative Commons - - - Ask - - - Answers - - - Dictionary.com - - - YouTube - - - AeroMP3 - - - AOL - - - Baidu - - - Amazon - - - Ebay - - - IMBD - - - ESPN - - - Wikipedia - - - DuckDuckGo + en + English - + - + - preferencesTabLocTop + preferencesFonttypeSans - preferencesTabLocLeft + preferencesFonttypeSerif - preferencesTabLocRight + preferencesFonttypeMonospace - preferencesTabLocBottom + preferencesFonttypeCursive + + + preferencesFonttypeFantasy - + - preferencesButtonTypeSmall - - - preferencesButtonTypeLarge + preferencesDeveloperViewWindow - preferencesButtonTypeLargeText + preferencesDeveloperViewTab - preferencesButtonTypeText + preferencesDeveloperViewEditor @@ -2841,35 +159,6 @@ - - - - - - - - preferencesFonttypeSans - - - preferencesFonttypeSerif - - - preferencesFonttypeMonospace - - - preferencesFonttypeCursive - - - preferencesFonttypeFantasy - - - - - True - False - 3 - gtk-apply - @@ -2887,118 +176,2834 @@ preferencesProxyTypeNLTM - - - preferencesProxyTypeSystem - - - - - 0.10000000000000001 - 0.10000000000000001 - 10 - 0.10000000000000001 - 1 - - - 16 - 1 - 99.900000000000006 - 0.10000000000000001 - 2 - - - 28 - 999 - 1 - 28 - - - 16 - 2048 - 4 - 16 - - - 1024 - 4096 - 32 - 256 - - - 28 - 999 - 1 - 10 - - - 3128 - 1 - 65535 - 1 - 10 - - - 10 - 1 - 100 - 1 - 10 - - - 1 - 1 - 100 - 1 - 10 - - - 1 - 100 - 1 - 10 - - - 100 - 1 - 1000 - 1 - 10 - - - 999 - 1 - 10 + + + preferencesProxyTypeSystem + + - + - + - + + + + Google + + + Yahoo! + + + Microsoft Live + + + Buisiness.com + + + Omgili + + + BBC News + + + Ubuntu Packages + + + Creative Commons + + + Ask + + + Answers + + + Dictionary.com + + + YouTube + + + AeroMP3 + + + AOL + + + Baidu + + + Amazon + + + Ebay + + + IMBD + + + ESPN + + + Wikipedia + + + DuckDuckGo + + + + + + - en - English + preferencesTabLocTop + + + preferencesTabLocLeft + + + preferencesTabLocRight + + + preferencesTabLocBottom - + - preferencesDeveloperViewWindow + preferencesButtonTypeSmall - preferencesDeveloperViewTab + preferencesButtonTypeLarge - preferencesDeveloperViewEditor + preferencesButtonTypeLargeText + + + preferencesButtonTypeText + + False + 5 + preferencesTitle + center-on-parent + True + dialog + + + + + + True + False + 2 + + + True + False + edge + + + gtk-help + True + True + False + True + + + False + False + 0 + + + + + gtk-close + True + True + False + True + + + False + False + 1 + + + + + False + True + end + 0 + + + + + True + True + + + True + False + 6 + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 6 + + + True + False + 12 + + + True + False + preferencesStartupPage + + + False + False + 0 + + + + + True + True + + False + False + True + True + + + + + True + True + end + 1 + + + + + True + True + 0 + + + + + True + False + 6 + + + + + + preferencesStartupPageDefault + True + True + True + + + + False + False + end + 1 + + + + + preferencesStartupPageCurrent + True + True + True + + + + False + False + end + 2 + + + + + True + False + 1 + + + + + + + + + True + False + preferencesStartup + True + + + + + False + True + 6 + 0 + + + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 6 + + + preferencesSearchURLBar + True + True + False + True + + + + + True + True + 0 + + + + + True + False + 12 + + + True + False + preferencesSearchProvider + + + False + False + 0 + + + + + True + False + liststore_search_provider + + + + + + 0 + + + + + True + True + 1 + + + + + True + True + 1 + + + + + + + + + True + False + preferencesSearch + True + + + + + False + True + 6 + 1 + + + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 6 + + + preferencesDownloadsRemove + True + True + False + True + + + + + False + True + 0 + + + + + preferencesDownloadsConfirm + True + True + False + True + + + + + False + True + 1 + + + + + True + False + 12 + + + True + False + preferencesDownloadsLocation + + + False + True + 0 + + + + + True + False + select-folder + + + + + True + True + 1 + + + + + False + True + 2 + + + + + + + + + True + False + preferencesDownloads + True + + + + + False + True + 6 + 2 + + + + + + + True + False + preferencesMainTabtitle + + + False + + + + + True + False + 6 + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 6 + + + preferencesTabsAlways + True + True + False + True + + + + + True + True + 0 + + + + + preferencesTabsSwitch + True + True + False + True + + + + + True + True + 1 + + + + + preferencesTabsNewly + True + True + False + True + + + + + True + True + 2 + + + + + True + False + 12 + + + True + False + preferencesTabsPosition + + + False + False + 0 + + + + + True + False + liststore_tab_position + + + + + + 0 + + + + + True + True + 1 + + + + + True + True + 3 + + + + + + + + + True + False + preferencesTabs + True + + + + + False + True + 6 + 1 + + + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 6 + + + True + False + 6 + + + True + False + preferencesDeveloperView + + + False + True + 0 + + + + + True + False + liststore_developer_view + + + + + + 0 + + + + + True + True + 1 + + + + + True + True + 0 + + + + + + + + + True + False + preferencesTools + True + + + + + False + True + 6 + 2 + + + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 6 + + + preferencesURLbarDisplay + True + True + False + True + + + + + True + True + 0 + + + + + + + + + True + False + preferencesURLbar + True + + + + + False + True + 7 + 3 + + + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 6 + + + True + False + 6 + + + True + False + preferencesToolbarButtons + + + False + True + 0 + + + + + True + False + liststore_toolbar_buttontype + + + + + + 0 + + + + + True + True + 1 + + + + + True + True + 0 + + + + + + + + + True + False + preferencesToolbar + True + + + + + False + True + 6 + 4 + + + + + 1 + + + + + True + False + preferencesAppearanceTabtitle + + + 1 + False + + + + + True + False + 6 + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 6 + + + preferencesControlPrevent + True + True + False + True + + + + + False + False + 0 + + + + + preferencesControlHide + True + True + False + True + + + + + False + False + 1 + + + + + preferencesControlEnable + True + True + False + True + + + + + False + False + 2 + + + + + preferencesControlDisable + True + True + False + True + + + + + False + False + 3 + + + + + preferencesControlHigh + True + True + False + True + + + + + True + True + 4 + + + + + True + False + 6 + + + True + False + preferencesControlLoad + + + False + True + 0 + + + + + True + False + liststore_image_loading + + + + + + 0 + + + + + True + True + 1 + + + + + True + True + 5 + + + + + + + + + True + False + preferencesControl + True + + + + + False + True + 6 + 0 + + + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 6 + + + preferencesAnimationEnable + True + True + False + True + + + + + True + True + 0 + + + + + True + False + 12 + + + True + False + preferencesAnimationMinimum + + + False + True + 0 + + + + + True + True + True + preferencesAnimationMinimumTooltip + + False + False + True + True + adjustment_animation_time + 1 + 1 + True + if-valid + + + + + False + True + 1 + + + + + True + True + 1 + + + + + + + + + True + False + preferencesAnimation + True + + + + + False + True + 6 + 1 + + + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 12 + + + True + False + 6 + + + True + False + preferencesFontsDefault + + + False + True + 0 + + + + + True + False + liststore_defaultfont + + + + + + 0 + + + + + True + True + 1 + + + + + True + True + 0 + + + + + True + False + 6 + + + True + False + preferencesFontsSize + + + False + True + 0 + + + + + True + True + True + preferencesFontsSizeTooltip + 4 + + 4 + False + False + True + True + adjustment_font_default_size + 1 + 1 + True + + + + + False + True + 1 + + + + + False + True + 1 + + + + + preferencesFontsPreview + True + True + True + image1 + True + + + + False + True + 2 + + + + + + + + + True + False + preferencesFonts + True + + + + + False + True + 2 + + + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 6 + + + True + False + 12 + + + True + False + preferencesLanguagePreferred + + + False + True + 0 + + + + + True + False + True + preferencesLanguagePreferredTooltip + liststore_content_language + + + + + 0 + + + 1 + + + + + 1 + + + 0 + + + + + True + True + 1 + + + + + True + True + 0 + + + + + + + + + True + False + preferencesLanguage + True + + + + + False + True + 3 + + + + + 2 + + + + + True + False + preferencesContentTabtitle + + + 2 + False + + + + + True + False + 6 + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 6 + + + preferencesGeneralReferral + True + True + False + True + + + + + True + True + 0 + + + + + preferencesGeneralDNT + True + True + False + True + + + + + True + True + 1 + + + + + + + + + True + False + preferencesGeneral + True + + + + + False + True + 6 + 0 + + + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 6 + + + preferencesHistoryShow + True + True + False + True + + + + + True + True + 0 + + + + + True + False + 6 + + + True + False + preferencesHistoryRemember + + + False + True + 0 + + + + + True + True + 4 + + 4 + False + False + True + True + adjustment_history_age + 1 + True + if-valid + + + + + False + True + 1 + + + + + True + False + preferencesHistoryDays + + + False + True + 2 + + + + + True + True + 1 + + + + + + + + + True + False + preferencesHistory + True + + + + + False + True + 6 + 1 + + + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 6 + + + True + False + 3 + 3 + 6 + 6 + + + True + False + 0 + preferencesCacheMemory + + + GTK_FILL + + + + + True + False + 0 + preferencesCacheDisc + + + 1 + 2 + GTK_FILL + + + + + True + False + 0 + preferencesCacheExpire + + + 2 + 3 + GTK_FILL + + + + + True + True + + 5 + False + False + True + True + adjustment_cache_memory_size + 1 + True + + + + + 1 + 2 + GTK_FILL + + + + + True + True + + 5 + False + False + True + True + adjustment_cache_disc_size + 1 + True + + + + + 1 + 2 + 1 + 2 + GTK_FILL + + + + + True + True + + 3 + False + False + True + True + adjustment_disc_cache_age + 1 + True + + + + + 1 + 2 + 2 + 3 + GTK_FILL + + + + + True + False + 0 + MB + + + 2 + 3 + GTK_FILL + + + + + True + False + 0 + MB + + + 2 + 3 + 1 + 2 + GTK_FILL + + + + + True + False + 0 + preferencesHistoryDays + + + 2 + 3 + 2 + 3 + GTK_FILL + + + + + True + True + 0 + + + + + True + False + + + + + + preferencesCacheMaintenance + True + True + True + + + False + True + 1 + + + + + True + True + 1 + + + + + + + + + True + False + preferencesCache + True + + + + + False + True + 6 + 2 + + + + + 3 + + + + + True + False + preferencesPrivacyTabtitle + + + 3 + False + + + + + True + False + 6 + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 5 + 2 + 6 + 6 + + + True + False + 0 + preferencesProxyType + + + GTK_FILL + + + + + True + False + 0 + preferencesProxyHost + + + 1 + 2 + GTK_FILL + + + + + True + False + 0 + preferencesProxyUsername + + + 2 + 3 + GTK_FILL + + + + + True + False + 0 + preferencesProxyPassword + + + 3 + 4 + GTK_FILL + + + + + True + False + True + preferencesProxyTypeTooltip + liststore_proxy_type + + + + + + 0 + + + + + 1 + 2 + + + + + True + False + 6 + + + True + True + True + preferencesProxyHostTooltip + + False + False + True + True + + + + + True + True + 0 + + + + + True + False + : + + + False + True + 1 + + + + + True + True + True + preferencesProxyPortTooltip + 5 + + 5 + False + False + True + True + adjustment_proxy_port + 1 + True + if-valid + + + + + False + True + 2 + + + + + 1 + 2 + 1 + 2 + + + + + True + True + True + preferencesProxyUsernameTooltip + + False + False + True + True + + + + + 1 + 2 + 2 + 3 + + + + + True + True + True + preferencesProxyPasswordTooltip + False + + False + False + True + True + + + + + 1 + 2 + 3 + 4 + + + + + True + False + 0 + preferencesProxyNoproxy + + + 4 + 5 + GTK_FILL + + + + + True + True + True + preferencesProxyNoproxyTooltip + False + False + False + True + True + + + + + 1 + 2 + 4 + 5 + + + + + + + + + True + False + preferencesProxy + True + + + + + False + True + 6 + 0 + + + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 3 + 2 + 6 + 6 + + + True + False + 0 + preferencesFetchingMax + + + GTK_FILL + + + + + True + False + 0 + preferencesFetchingPerhost + + + 1 + 2 + GTK_FILL + + + + + True + False + 0 + preferencesFetchingCached + + + 2 + 3 + GTK_FILL + + + + + True + True + True + preferencesFetchingMaxTooltip + + 3 + False + False + True + True + adjustment_fetching_max + 1 + True + + + + + 1 + 2 + GTK_FILL + + + + + True + True + True + preferencesFetchingPerhostTooltip + + 3 + False + False + True + True + adjustment_fetching_perhost + 1 + True + + + + + 1 + 2 + 1 + 2 + GTK_FILL + + + + + True + True + True + preferencesFetchingCachedTooltip. + + 3 + False + False + True + True + adjustment_fetching_cached + 1 + True + + + + + 1 + 2 + 2 + 3 + GTK_FILL + + + + + + + + + True + False + preferencesFetching + True + + + + + False + True + 6 + 1 + + + + + 4 + + + + + True + False + preferencesNetworkTabtitle + + + 4 + False + + + + + False + 6 + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 6 + + + preferencesAppearanceImages + True + True + False + True + + + + + True + True + 0 + + + + + preferencesAppearanceBackground + True + True + False + True + + + + + True + True + 1 + + + + + preferencesAppearanceScalefit + True + True + False + True + + + + + True + True + 2 + + + + + True + False + 6 + + + True + False + preferencesAppearanceScale + + + False + True + 0 + + + + + True + True + 4 + + 4 + 1 + False + False + True + True + adjustment_pdf_scale + 1 + True + + + + + False + True + 1 + + + + + True + False + % + + + False + True + 2 + + + + + True + True + 3 + + + + + + + + + True + False + preferencesAppearance + True + + + + + False + True + 6 + 0 + + + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 6 + + + True + False + + + True + False + preferencesMarginsMeasurements + + + False + True + 0 + + + + + + + + True + True + 0 + + + + + True + False + 3 + 3 + + + + + + + + + + + + True + False + 6 + + + True + False + Top + + + False + True + 0 + + + + + True + True + 4 + + 5 + 1 + False + False + True + True + 1 + 1 + True + + + + + False + True + 1 + + + + + 1 + 2 + GTK_EXPAND + + + + + True + False + 6 + + + True + False + Left + + + False + True + 0 + + + + + True + True + 4 + + 5 + 1 + False + False + True + True + adjustment_pdf_lmargin + 1 + 1 + True + + + + + False + True + 1 + + + + + 1 + 2 + GTK_EXPAND + + + + + True + False + 6 + + + True + False + Bottom + + + False + True + 0 + + + + + True + True + 4 + + 5 + 1 + False + False + True + True + 1 + 1 + True + + + + + False + True + 1 + + + + + 1 + 2 + 2 + 3 + GTK_EXPAND + + + + + True + False + 6 + + + True + False + Right + + + False + True + 0 + + + + + True + True + 4 + + 5 + 1 + False + False + True + True + 1 + 1 + True + + + + + False + True + 1 + + + + + 2 + 3 + 1 + 2 + GTK_EXPAND + + + + + + + + + + + True + True + 1 + + + + + + + + + True + False + preferencesMargins + True + + + + + False + True + 6 + 1 + + + + + True + False + 0 + none + + + True + False + 6 + 12 + 12 + + + True + False + 7 + + + preferencesGenerationCompressed + True + True + False + True + + + + + True + True + 0 + + + + + preferencesGenerationPassword + True + True + False + True + + + + + True + True + 1 + + + + + + + + + True + False + preferencesGeneration + True + + + + + False + True + 6 + 2 + + + + + 5 + + + + + True + False + preferencesPDFTabtitle + + + 5 + False + + + + + True + True + 1 + + + + + + help + close + + diff --git a/frontends/gtk/res/toolbar.gtk2.ui b/frontends/gtk/res/toolbar.gtk2.ui index d84db5c8c..4e8805a6f 100644 --- a/frontends/gtk/res/toolbar.gtk2.ui +++ b/frontends/gtk/res/toolbar.gtk2.ui @@ -1,67 +1,84 @@ - - + - + + + 700 450 - - GTK_WINDOW_TOPLEVEL - GTK_WIN_POS_NONE - False - True - False - True - False - False - GDK_WINDOW_TYPE_HINT_NORMAL - GDK_GRAVITY_NORTH_WEST - True - False - - + False + 5 + gtkToolBarTitle + center-on-parent + True + dialog + + True - False - 0 + False + 2 - + True - Move items from store to toolbar Rearrange items in toolbar Move items from toolbar to store - False - False - GTK_JUSTIFY_LEFT - False - False - 0.5 - 0.5 - 0 - 0 - PANGO_ELLIPSIZE_NONE - -1 - False - 0 + False + True + + + True + False + Move items from store to toolbar + + + True + True + 0 + + + + + True + False + Rearrange items in toolbar + + + True + True + 1 + + + + + True + False + Move items from toolbar to store + + + True + True + 2 + + - 0 False True + 2 + 0 True - GTK_POLICY_AUTOMATIC - GTK_POLICY_AUTOMATIC - GTK_SHADOW_NONE - GTK_CORNER_TOP_LEFT + False + automatic + automatic True - GTK_SHADOW_IN + False True - False - 0 + False @@ -71,119 +88,85 @@ - 0 True True + 1 - - + + True - True - False - 0 + False + end - + True True - GTK_RELIEF_NORMAL - True + False True - False - 0 + False True + False gtk-refresh - 4 - 0.5 - 0.5 - 0 - 0 - 0 False True + 0 True + False Reset to defaults - False - False - GTK_JUSTIFY_LEFT - False - False - 0.5 - 0.5 - 0 - 0 - PANGO_ELLIPSIZE_NONE - -1 - False - 0 - 0 True True + 1 - 10 False True - - - - - - - - True - True - True - gtk-apply - True - GTK_RELIEF_NORMAL - True - - 10 - False - True + 0 - + + gtk-close True True - gtk-cancel + True True - GTK_RELIEF_NORMAL - True - 0 False - True + False + 1 - 0 False True + 2 + + reset + close + diff --git a/frontends/gtk/res/toolbar.gtk3.ui b/frontends/gtk/res/toolbar.gtk3.ui index d84db5c8c..1f1148703 100644 --- a/frontends/gtk/res/toolbar.gtk3.ui +++ b/frontends/gtk/res/toolbar.gtk3.ui @@ -1,186 +1,134 @@ - + + - + + + True + False + gtk-refresh + + 700 450 - - GTK_WINDOW_TOPLEVEL - GTK_WIN_POS_NONE - False - True - False - True - False - False - GDK_WINDOW_TYPE_HINT_NORMAL - GDK_GRAVITY_NORTH_WEST - True - False - - - True - False - 0 - - - True - Move items from store to toolbar Rearrange items in toolbar Move items from toolbar to store - False - False - GTK_JUSTIFY_LEFT - False - False - 0.5 - 0.5 - 0 - 0 - PANGO_ELLIPSIZE_NONE - -1 - False - 0 - - - 0 - False - True - - - - - True - GTK_POLICY_AUTOMATIC - GTK_POLICY_AUTOMATIC - GTK_SHADOW_NONE - GTK_CORNER_TOP_LEFT + False + gtkToolBarTitle + dialog + + + False + vertical + 2 + + + False + end - + + Reset To Defaults True - GTK_SHADOW_IN - - - True - False - 0 - - - - - + True + True + image2 + 0.52999997138977051 + True + + + True + True + 0 + + + + + gtk-close + True + True + True + True + + True + True + 1 + - 0 - True - True + False + False + 2 - + True - True - False - 0 + False + True - + True - True - GTK_RELIEF_NORMAL - True - - - True - False - 0 - - - True - gtk-refresh - 4 - 0.5 - 0.5 - 0 - 0 - - - 0 - False - True - - - - - True - Reset to defaults - False - False - GTK_JUSTIFY_LEFT - False - False - 0.5 - 0.5 - 0 - 0 - PANGO_ELLIPSIZE_NONE - -1 - False - 0 - - - 0 - True - True - - - - + False + Move items from store to toolbar - 10 - False - True + 0 + 0 - - - - + True - True - True - gtk-apply - True - GTK_RELIEF_NORMAL - True + False + Rearrange items in toolbar - 10 - False - True + 1 + 0 - + True - True - gtk-cancel - True - GTK_RELIEF_NORMAL - True + False + Move items from toolbar to store - 0 - False - True + 2 + 0 - 0 False True + 0 + + + + + True + True + + + True + False + + + True + False + + + + + + + + + + True + True + 2 diff --git a/frontends/gtk/scaffolding.c b/frontends/gtk/scaffolding.c index cbc46cbc5..6f81e91db 100644 --- a/frontends/gtk/scaffolding.c +++ b/frontends/gtk/scaffolding.c @@ -2073,7 +2073,7 @@ struct nsgtk_scaffolding *nsgtk_new_scaffolding(struct gui_window *toplevel) int i; GtkAccelGroup *group; - gs = malloc(sizeof(*gs)); + gs = calloc(1, sizeof(*gs)); if (gs == NULL) { return NULL; } @@ -2491,7 +2491,11 @@ gui_search_web_provider_update(const char *provider_name, /* set the search provider parameters up in each scaffold */ for (current = scaf_list; current != NULL; current = current->next) { - /* add ico to each window's toolbar */ + if (current->webSearchEntry == NULL) { + continue; + } + + /* add ico to each window's toolbar */ if (srch_pixbuf != NULL) { nsgtk_entry_set_icon_from_pixbuf(current->webSearchEntry, GTK_ENTRY_ICON_PRIMARY, diff --git a/frontends/gtk/toolbar.c b/frontends/gtk/toolbar.c index 0ca26c92d..e93bd49f9 100644 --- a/frontends/gtk/toolbar.c +++ b/frontends/gtk/toolbar.c @@ -26,6 +26,7 @@ #include "utils/log.h" #include "utils/messages.h" #include "utils/nsoption.h" +#include "utils/file.h" #include "gtk/gui.h" #include "gtk/warn.h" @@ -44,7 +45,7 @@ static bool edit_mode = false; struct nsgtk_toolbar_custom_store { GtkWidget *window; - GtkWidget *store_buttons[PLACEHOLDER_BUTTON]; + GtkWidget *store_buttons[PLACEHOLDER_BUTTON]; GtkWidget *widgetvbox; GtkWidget *currentbar; char numberh; /* current horizontal location while adding */ @@ -107,13 +108,13 @@ static char *remove_underscores(const char *s, bool replacespace) ret = malloc(len + 1); if (ret == NULL) { return NULL; - } + } for (i = 0, ii = 0; i < len; i++) { if (s[i] != '_') { ret[ii++] = s[i]; - } else if (replacespace) { + } else if (replacespace) { ret[ii++] = ' '; - } + } } ret[ii] = '\0'; return ret; @@ -208,18 +209,18 @@ nsgtk_theme_searchimage_default(nsgtk_search_buttons tbbutton, switch (tbbutton) { case (SEARCH_BACK_BUTTON): - image = GTK_IMAGE(nsgtk_image_new_from_stock(NSGTK_STOCK_GO_BACK, - iconsize)); + image = GTK_IMAGE(nsgtk_image_new_from_stock( + NSGTK_STOCK_GO_BACK, iconsize)); break; case (SEARCH_FORWARD_BUTTON): - image = GTK_IMAGE(nsgtk_image_new_from_stock(NSGTK_STOCK_GO_FORWARD, - iconsize)); + image = GTK_IMAGE(nsgtk_image_new_from_stock( + NSGTK_STOCK_GO_FORWARD, iconsize)); break; case (SEARCH_CLOSE_BUTTON): - image = GTK_IMAGE(nsgtk_image_new_from_stock(NSGTK_STOCK_CLOSE, - iconsize)); + image = GTK_IMAGE(nsgtk_image_new_from_stock( + NSGTK_STOCK_CLOSE, iconsize)); break; default: @@ -227,7 +228,8 @@ nsgtk_theme_searchimage_default(nsgtk_search_buttons tbbutton, } if (usedef && (image == NULL)) { - image = GTK_IMAGE(nsgtk_image_new_from_stock("gtk-missing-image", iconsize)); + image = GTK_IMAGE(nsgtk_image_new_from_stock( + "gtk-missing-image", iconsize)); } return image; @@ -255,7 +257,6 @@ static struct nsgtk_theme *nsgtk_theme_load(GtkIconSize iconsize, bool usedef) theme->image[btnloop] = nsgtk_theme_image_default(btnloop, iconsize, usedef); - } for (btnloop = SEARCH_BACK_BUTTON; @@ -823,8 +824,9 @@ static void nsgtk_toolbar_close(struct nsgtk_scaffolding *g) */ static gboolean nsgtk_toolbar_cancel_clicked(GtkWidget *widget, gpointer data) { - edit_mode = false; struct nsgtk_scaffolding *g = (struct nsgtk_scaffolding *)data; + + edit_mode = false; /* reset g->buttons->location */ for (int i = BACK_BUTTON; i < PLACEHOLDER_BUTTON; i++) { nsgtk_scaffolding_button(g, i)->location = @@ -950,6 +952,7 @@ void nsgtk_toolbar_customization_load(struct nsgtk_scaffolding *g) */ static nserror nsgtk_toolbar_customization_save(struct nsgtk_scaffolding *g) { + char *choices = NULL; char *order; int order_len = PLACEHOLDER_BUTTON * 12; /* length of order buffer */ int tbidx; @@ -981,6 +984,13 @@ static nserror nsgtk_toolbar_customization_save(struct nsgtk_scaffolding *g) nsoption_set_charp(toolbar_order, order); + /* ensure choices are saved */ + netsurf_mkpath(&choices, NULL, 2, nsgtk_config_home, "Choices"); + if (choices != NULL) { + nsoption_write(choices, NULL, NULL); + free(choices); + } + return NSERROR_OK; } @@ -990,8 +1000,9 @@ static nserror nsgtk_toolbar_customization_save(struct nsgtk_scaffolding *g) */ static gboolean nsgtk_toolbar_persist(GtkWidget *widget, gpointer data) { - edit_mode = false; struct nsgtk_scaffolding *g = (struct nsgtk_scaffolding *)data; + + edit_mode = false; /* save state to file, update toolbars for all windows */ nsgtk_toolbar_customization_save(g); nsgtk_toolbar_cast(g); @@ -1098,7 +1109,6 @@ nsgtk_toolbar_store_action(GtkWidget *widget, GdkDragContext *gdc, */ static void nsgtk_toolbar_window_open(struct nsgtk_scaffolding *g) { - int x = 0, y = 0; struct nsgtk_theme *theme; nserror res; @@ -1112,7 +1122,7 @@ static void nsgtk_toolbar_window_open(struct nsgtk_scaffolding *g) res = nsgtk_builder_new_from_resname("toolbar", &window->builder); if (res != NSERROR_OK) { NSLOG(netsurf, INFO, "Toolbar UI builder init failed"); - nsgtk_warning(messages_get("NoMemory"), 0); + nsgtk_warning("Toolbar UI builder init failed", 0); nsgtk_toolbar_cancel_clicked(NULL, g); free(theme); return; @@ -1120,8 +1130,8 @@ static void nsgtk_toolbar_window_open(struct nsgtk_scaffolding *g) gtk_builder_connect_signals(window->builder, NULL); - window->window = GTK_WIDGET(gtk_builder_get_object(window->builder, - "toolbarwindow")); + window->window = GTK_WIDGET(gtk_builder_get_object( + window->builder, "dialogToolbar")); if (window->window == NULL) { nsgtk_warning(messages_get("NoMemory"), 0); nsgtk_toolbar_cancel_clicked(NULL, g); @@ -1129,8 +1139,11 @@ static void nsgtk_toolbar_window_open(struct nsgtk_scaffolding *g) return; } - window->widgetvbox = GTK_WIDGET(gtk_builder_get_object(window->builder, - "widgetvbox")); + gtk_window_set_transient_for(GTK_WINDOW(window->window), + nsgtk_scaffolding_window(g)); + + window->widgetvbox = GTK_WIDGET(gtk_builder_get_object( + window->builder, "widgetvbox")); if (window->widgetvbox == NULL) { nsgtk_warning(messages_get("NoMemory"), 0); nsgtk_toolbar_cancel_clicked(NULL, g); @@ -1138,9 +1151,12 @@ static void nsgtk_toolbar_window_open(struct nsgtk_scaffolding *g) return; } - window->numberh = NSGTK_STORE_WIDTH; /* preset to width [in buttons] of */ + /* preset to width [in buttons] of */ + window->numberh = NSGTK_STORE_WIDTH; + /* store to cause creation of a new toolbar */ window->currentbutton = -1; + /* load toolbuttons */ /* add toolbuttons to window */ /* set event handlers */ @@ -1160,33 +1176,20 @@ static void nsgtk_toolbar_window_open(struct nsgtk_scaffolding *g) } free(theme); - gtk_window_set_transient_for(GTK_WINDOW(window->window), - nsgtk_scaffolding_window(g)); - gtk_window_set_title(GTK_WINDOW(window->window), messages_get( - "gtkToolBarTitle")); + gtk_window_set_accept_focus(GTK_WINDOW(window->window), FALSE); + gtk_drag_dest_set(GTK_WIDGET(window->window), GTK_DEST_DEFAULT_MOTION | GTK_DEST_DEFAULT_DROP, &entry, 1, GDK_ACTION_COPY); - gtk_widget_show_all(window->window); - gtk_window_set_position(GTK_WINDOW(window->window), - GTK_WIN_POS_CENTER_ON_PARENT); - gtk_window_get_position(nsgtk_scaffolding_window(g), &x, &y); - gtk_window_move(GTK_WINDOW(window->window), x, y + 100); - - g_signal_connect(GTK_WIDGET(gtk_builder_get_object(window->builder, - "cancelbutton")), - "clicked", - G_CALLBACK(nsgtk_toolbar_cancel_clicked), - g); - g_signal_connect(GTK_WIDGET(gtk_builder_get_object(window->builder, - "okbutton")), + g_signal_connect(GTK_WIDGET(gtk_builder_get_object( + window->builder, "close")), "clicked", G_CALLBACK(nsgtk_toolbar_persist), g); - g_signal_connect(GTK_WIDGET(gtk_builder_get_object(window->builder, - "resetbutton")), + g_signal_connect(GTK_WIDGET(gtk_builder_get_object( + window->builder, "reset")), "clicked", G_CALLBACK(nsgtk_toolbar_reset), g); @@ -1199,6 +1202,8 @@ static void nsgtk_toolbar_window_open(struct nsgtk_scaffolding *g) g_signal_connect(window->window, "drag-motion", G_CALLBACK(nsgtk_toolbar_store_action), g); + + gtk_widget_show_all(window->window); } /** @@ -1342,33 +1347,37 @@ nsgtk_toolbar_set_handler(struct nsgtk_scaffolding *g, nsgtk_toolbar_button i) case URL_BAR_ITEM: nsgtk_scaffolding_update_url_bar_ref(g); g_signal_connect(GTK_WIDGET(nsgtk_scaffolding_urlbar(g)), - "activate", G_CALLBACK( - nsgtk_window_url_activate_event), g); + "activate", G_CALLBACK( + nsgtk_window_url_activate_event), g); g_signal_connect(GTK_WIDGET(nsgtk_scaffolding_urlbar(g)), - "changed", G_CALLBACK( - nsgtk_window_url_changed), g); + "changed", G_CALLBACK( + nsgtk_window_url_changed), g); break; + case THROBBER_ITEM: nsgtk_scaffolding_update_throbber_ref(g); break; + case WEBSEARCH_ITEM: nsgtk_scaffolding_update_websearch_ref(g); g_signal_connect(GTK_WIDGET(nsgtk_scaffolding_websearch(g)), - "activate", G_CALLBACK( - nsgtk_websearch_activate), g); + "activate", G_CALLBACK( + nsgtk_websearch_activate), g); g_signal_connect(GTK_WIDGET(nsgtk_scaffolding_websearch(g)), - "button-press-event", G_CALLBACK( - nsgtk_websearch_clear), g); + "button-press-event", G_CALLBACK( + nsgtk_websearch_clear), g); break; + default: if ((nsgtk_scaffolding_button(g, i)->bhandler != NULL) && - (nsgtk_scaffolding_button(g, i)->button - != NULL)) - g_signal_connect(nsgtk_scaffolding_button(g, i)-> - button, "clicked", - G_CALLBACK(nsgtk_scaffolding_button(g, - i)->bhandler), g); - break; + (nsgtk_scaffolding_button(g, i)->button != NULL)) { + g_signal_connect( + nsgtk_scaffolding_button(g, i)->button, + "clicked", + G_CALLBACK(nsgtk_scaffolding_button( + g, i)->bhandler), g); + } + break; } } @@ -1460,7 +1469,8 @@ DATAHANDLER(prevtab, PREVTAB, window) DATAHANDLER(guide, GUIDE, window) DATAHANDLER(info, INFO, window) #undef DATAHANDLER -#define DATAHANDLER(p, q, r)\ + +#define DATAHANDLER(p, q, r) \ gboolean nsgtk_toolbar_##p##_button_data(GtkWidget *widget, GdkDragContext\ *cont, GtkSelectionData *selection, guint info, guint time,\ gpointer data)\ @@ -1481,5 +1491,3 @@ gboolean nsgtk_toolbar_##p##_toolbar_button_data(GtkWidget *widget,\ DATAHANDLER(throbber, THROBBER, window) DATAHANDLER(websearch, WEBSEARCH, window) #undef DATAHANDLER - - -- cgit v1.2.3