window: Remove remaining overview mentions
There is no overview anymore -- Settings is always visualizing a panel at any given time. I just noticed that the Alt+Left shortcut was always broken too. This will be fixed in a following commit.
This commit is contained in:
parent
f109289538
commit
52469cec7c
6 changed files with 7 additions and 47 deletions
|
@ -59,7 +59,6 @@ G_DEFINE_TYPE (CcApplication, cc_application, GTK_TYPE_APPLICATION)
|
||||||
const GOptionEntry all_options[] = {
|
const GOptionEntry all_options[] = {
|
||||||
{ "version", 0, 0, G_OPTION_ARG_NONE, NULL, N_("Display version number"), NULL },
|
{ "version", 0, 0, G_OPTION_ARG_NONE, NULL, N_("Display version number"), NULL },
|
||||||
{ "verbose", 'v', 0, G_OPTION_ARG_NONE, NULL, N_("Enable verbose mode"), NULL },
|
{ "verbose", 'v', 0, G_OPTION_ARG_NONE, NULL, N_("Enable verbose mode"), NULL },
|
||||||
{ "overview", 'o', 0, G_OPTION_ARG_NONE, NULL, N_("Show the overview"), NULL },
|
|
||||||
{ "search", 's', 0, G_OPTION_ARG_STRING, NULL, N_("Search for the string"), "SEARCH" },
|
{ "search", 's', 0, G_OPTION_ARG_STRING, NULL, N_("Search for the string"), "SEARCH" },
|
||||||
{ "list", 'l', 0, G_OPTION_ARG_NONE, NULL, N_("List possible panel names and exit"), NULL },
|
{ "list", 'l', 0, G_OPTION_ARG_NONE, NULL, N_("List possible panel names and exit"), NULL },
|
||||||
{ G_OPTION_REMAINING, '\0', 0, G_OPTION_ARG_FILENAME_ARRAY, NULL, N_("Panel to display"), N_("[PANEL] [ARGUMENT…]") },
|
{ G_OPTION_REMAINING, '\0', 0, G_OPTION_ARG_FILENAME_ARRAY, NULL, N_("Panel to display"), N_("[PANEL] [ARGUMENT…]") },
|
||||||
|
@ -168,10 +167,6 @@ cc_application_command_line (GApplication *application,
|
||||||
{
|
{
|
||||||
cc_window_set_search_item (self->window, search_str);
|
cc_window_set_search_item (self->window, search_str);
|
||||||
}
|
}
|
||||||
else if (g_variant_dict_contains (options, "overview"))
|
|
||||||
{
|
|
||||||
cc_window_set_overview_page (self->window);
|
|
||||||
}
|
|
||||||
else if (g_variant_dict_lookup (options, G_OPTION_REMAINING, "^a&ay", &start_panels))
|
else if (g_variant_dict_lookup (options, G_OPTION_REMAINING, "^a&ay", &start_panels))
|
||||||
{
|
{
|
||||||
const char *start_id;
|
const char *start_id;
|
||||||
|
|
|
@ -248,14 +248,6 @@ add_current_panel_to_history (CcShell *shell,
|
||||||
g_debug ("Added '%s' to the previous panels", self->current_panel_id);
|
g_debug ("Added '%s' to the previous panels", self->current_panel_id);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
|
||||||
shell_show_overview_page (CcWindow *self)
|
|
||||||
{
|
|
||||||
/* TODO: need design input on a possibly new overview page. For now,
|
|
||||||
* just go back to the main section of the panel list. */
|
|
||||||
cc_panel_list_set_view (CC_PANEL_LIST (self->panel_list), CC_PANEL_LIST_MAIN);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
update_list_title (CcWindow *self)
|
update_list_title (CcWindow *self)
|
||||||
{
|
{
|
||||||
|
@ -428,8 +420,6 @@ set_active_panel (CcWindow *shell,
|
||||||
/* set the new panel */
|
/* set the new panel */
|
||||||
if (panel)
|
if (panel)
|
||||||
shell->active_panel = g_object_ref (panel);
|
shell->active_panel = g_object_ref (panel);
|
||||||
else
|
|
||||||
shell_show_overview_page (shell);
|
|
||||||
|
|
||||||
g_object_notify (G_OBJECT (shell), "active-panel");
|
g_object_notify (G_OBJECT (shell), "active-panel");
|
||||||
}
|
}
|
||||||
|
@ -441,10 +431,10 @@ show_panel_cb (CcPanelList *panel_list,
|
||||||
const gchar *panel_id,
|
const gchar *panel_id,
|
||||||
CcWindow *self)
|
CcWindow *self)
|
||||||
{
|
{
|
||||||
if (panel_id)
|
if (!panel_id)
|
||||||
|
return;
|
||||||
|
|
||||||
set_active_panel_from_id (CC_SHELL (self), panel_id, NULL, NULL);
|
set_active_panel_from_id (CC_SHELL (self), panel_id, NULL, NULL);
|
||||||
else
|
|
||||||
shell_show_overview_page (self);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -519,17 +509,6 @@ window_map_event_cb (GtkWidget *widget,
|
||||||
return GDK_EVENT_PROPAGATE;
|
return GDK_EVENT_PROPAGATE;
|
||||||
}
|
}
|
||||||
|
|
||||||
static gboolean
|
|
||||||
window_button_release_event_cb (GtkWidget *win,
|
|
||||||
GdkEventButton *event,
|
|
||||||
CcWindow *self)
|
|
||||||
{
|
|
||||||
/* back button */
|
|
||||||
if (event->button == MOUSE_BACK_BUTTON)
|
|
||||||
shell_show_overview_page (self);
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
window_key_press_event_cb (GtkWidget *win,
|
window_key_press_event_cb (GtkWidget *win,
|
||||||
GdkEventKey *event,
|
GdkEventKey *event,
|
||||||
|
@ -789,7 +768,6 @@ cc_window_class_init (CcWindowClass *klass)
|
||||||
gtk_widget_class_bind_template_callback (widget_class, search_entry_activate_cb);
|
gtk_widget_class_bind_template_callback (widget_class, search_entry_activate_cb);
|
||||||
gtk_widget_class_bind_template_callback (widget_class, show_panel_cb);
|
gtk_widget_class_bind_template_callback (widget_class, show_panel_cb);
|
||||||
gtk_widget_class_bind_template_callback (widget_class, update_list_title);
|
gtk_widget_class_bind_template_callback (widget_class, update_list_title);
|
||||||
gtk_widget_class_bind_template_callback (widget_class, window_button_release_event_cb);
|
|
||||||
gtk_widget_class_bind_template_callback (widget_class, window_key_press_event_cb);
|
gtk_widget_class_bind_template_callback (widget_class, window_key_press_event_cb);
|
||||||
gtk_widget_class_bind_template_callback (widget_class, window_map_event_cb);
|
gtk_widget_class_bind_template_callback (widget_class, window_map_event_cb);
|
||||||
|
|
||||||
|
@ -851,17 +829,10 @@ cc_window_new (GtkApplication *application)
|
||||||
NULL);
|
NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
cc_window_set_overview_page (CcWindow *center)
|
|
||||||
{
|
|
||||||
shell_show_overview_page (center);
|
|
||||||
}
|
|
||||||
|
|
||||||
void
|
void
|
||||||
cc_window_set_search_item (CcWindow *center,
|
cc_window_set_search_item (CcWindow *center,
|
||||||
const char *search)
|
const char *search)
|
||||||
{
|
{
|
||||||
shell_show_overview_page (center);
|
|
||||||
gtk_search_bar_set_search_mode (GTK_SEARCH_BAR (center->search_bar), TRUE);
|
gtk_search_bar_set_search_mode (GTK_SEARCH_BAR (center->search_bar), TRUE);
|
||||||
gtk_entry_set_text (GTK_ENTRY (center->search_entry), search);
|
gtk_entry_set_text (GTK_ENTRY (center->search_entry), search);
|
||||||
gtk_editable_set_position (GTK_EDITABLE (center->search_entry), -1);
|
gtk_editable_set_position (GTK_EDITABLE (center->search_entry), -1);
|
||||||
|
|
|
@ -32,8 +32,6 @@ G_DECLARE_FINAL_TYPE (CcWindow, cc_window, CC, WINDOW, GtkApplicationWindow)
|
||||||
|
|
||||||
CcWindow *cc_window_new (GtkApplication *application);
|
CcWindow *cc_window_new (GtkApplication *application);
|
||||||
|
|
||||||
void cc_window_set_overview_page (CcWindow *center);
|
|
||||||
|
|
||||||
void cc_window_set_search_item (CcWindow *center,
|
void cc_window_set_search_item (CcWindow *center,
|
||||||
const char *search);
|
const char *search);
|
||||||
|
|
||||||
|
|
|
@ -8,18 +8,15 @@ _gnome_control_center()
|
||||||
prev=${COMP_WORDS[COMP_CWORD-1]}
|
prev=${COMP_WORDS[COMP_CWORD-1]}
|
||||||
|
|
||||||
case "$prev" in
|
case "$prev" in
|
||||||
-o|--overview)
|
|
||||||
command_list=""
|
|
||||||
;;
|
|
||||||
*)
|
*)
|
||||||
if [ $prev = "gnome-control-center" ] ; then
|
if [ $prev = "gnome-control-center" ] ; then
|
||||||
command_list="--overview --verbose --version"
|
command_list="--verbose --version"
|
||||||
command_list="$command_list @PANELS@"
|
command_list="$command_list @PANELS@"
|
||||||
elif [ $prev = "--verbose" ]; then
|
elif [ $prev = "--verbose" ]; then
|
||||||
command_list="@PANELS@"
|
command_list="@PANELS@"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
for i in --overview --version @PANELS@; do
|
for i in --version @PANELS@; do
|
||||||
if [ $i = $prev ]; then
|
if [ $i = $prev ]; then
|
||||||
case $i in
|
case $i in
|
||||||
keyboard)
|
keyboard)
|
||||||
|
|
|
@ -37,7 +37,7 @@
|
||||||
<object class="GtkShortcutsShortcut">
|
<object class="GtkShortcutsShortcut">
|
||||||
<property name="visible">1</property>
|
<property name="visible">1</property>
|
||||||
<property name="accelerator"><Alt>Left</property>
|
<property name="accelerator"><Alt>Left</property>
|
||||||
<property name="title" translatable="yes" context="shortcut window">Go back to the overview</property>
|
<property name="title" translatable="yes" context="shortcut window">Go back to previous panel</property>
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
|
|
|
@ -9,7 +9,6 @@
|
||||||
<signal name="notify::window" handler="gdk_window_set_cb" object="CcWindow" swapped="no" />
|
<signal name="notify::window" handler="gdk_window_set_cb" object="CcWindow" swapped="no" />
|
||||||
<signal name="map-event" handler="window_map_event_cb" object="CcWindow" swapped="no" />
|
<signal name="map-event" handler="window_map_event_cb" object="CcWindow" swapped="no" />
|
||||||
<signal name="key-press-event" handler="window_key_press_event_cb" object="CcWindow" swapped="no" after="yes" />
|
<signal name="key-press-event" handler="window_key_press_event_cb" object="CcWindow" swapped="no" after="yes" />
|
||||||
<signal name="button-release-event" handler="window_button_release_event_cb" object="CcWindow" swapped="no" />
|
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkBox" id="main_hbox">
|
<object class="GtkBox" id="main_hbox">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue