[gnome-packagekit] Do not use an animated icon in gpk-application
- From: Richard Hughes <rhughes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-packagekit] Do not use an animated icon in gpk-application
- Date: Thu, 30 Sep 2010 21:07:38 +0000 (UTC)
commit 034ea9f0c59aaeba193640894f7b4456422d22e8
Author: Richard Hughes <richard hughsie com>
Date: Thu Sep 30 21:33:41 2010 +0100
Do not use an animated icon in gpk-application
data/gpk-application.ui | 49 +++++++++++++++++++++++++++++++++++++++-------
src/gpk-application.c | 17 +++------------
2 files changed, 45 insertions(+), 21 deletions(-)
---
diff --git a/data/gpk-application.ui b/data/gpk-application.ui
index cc9b84c..737843c 100644
--- a/data/gpk-application.ui
+++ b/data/gpk-application.ui
@@ -1,4 +1,4 @@
-<?xml version="1.0"?>
+<?xml version="1.0" encoding="UTF-8"?>
<interface>
<requires lib="gtk+" version="2.16"/>
<!-- interface-naming-policy toplevel-contextual -->
@@ -9,7 +9,6 @@
<child>
<object class="GtkVBox" id="vbox1">
<property name="visible">True</property>
- <property name="orientation">vertical</property>
<child>
<object class="GtkMenuBar" id="menubar1">
<property name="visible">True</property>
@@ -414,6 +413,7 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -423,11 +423,9 @@
<child>
<object class="GtkVBox" id="vbox2">
<property name="visible">True</property>
- <property name="orientation">vertical</property>
<child>
<object class="GtkVBox" id="vbox3">
<property name="visible">True</property>
- <property name="orientation">vertical</property>
<child>
<object class="GtkHBox" id="hbox7">
<property name="visible">True</property>
@@ -435,7 +433,6 @@
<child>
<object class="GtkVBox" id="vbox_groups">
<property name="visible">True</property>
- <property name="orientation">vertical</property>
<property name="spacing">6</property>
<child>
<object class="GtkHBox" id="hbox26">
@@ -445,9 +442,11 @@
<object class="GtkEntry" id="entry_text">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="invisible_char">●</property>
+ <property name="invisible_char">â??</property>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -460,6 +459,8 @@
<property name="use_underline">True</property>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -488,6 +489,8 @@
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -497,6 +500,7 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
@@ -504,6 +508,17 @@
<object class="GtkHBox" id="hbox_status">
<property name="spacing">6</property>
<child>
+ <object class="GtkImage" id="image_status">
+ <property name="visible">True</property>
+ <property name="stock">gtk-missing-image</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
<object class="GtkLabel" id="label_status">
<property name="visible">True</property>
<property name="label">Querying</property>
@@ -512,25 +527,26 @@
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
- <property name="position">0</property>
+ <property name="position">1</property>
</packing>
</child>
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">3</property>
</packing>
</child>
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkVBox" id="vbox4">
<property name="visible">True</property>
- <property name="orientation">vertical</property>
<property name="spacing">6</property>
<child>
<object class="GtkScrolledWindow" id="scrolledwindow_packages">
@@ -548,6 +564,8 @@
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -575,6 +593,8 @@
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -594,6 +614,8 @@
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -606,17 +628,23 @@
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="padding">6</property>
<property name="position">0</property>
</packing>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -685,18 +713,23 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="padding">6</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="padding">12</property>
<property name="position">0</property>
</packing>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="padding">6</property>
<property name="position">1</property>
</packing>
diff --git a/src/gpk-application.c b/src/gpk-application.c
index 6b3f9af..c56b1b9 100644
--- a/src/gpk-application.c
+++ b/src/gpk-application.c
@@ -34,7 +34,6 @@
#include "egg-string.h"
#include "egg-markdown.h"
-#include "gpk-animated-icon.h"
#include "gpk-application.h"
#include "gpk-cell-renderer-uri.h"
#include "gpk-common.h"
@@ -98,7 +97,6 @@ struct GpkApplicationPrivate
GpkSearchMode search_mode;
GpkActionMode action;
PkPackageSack *package_sack;
- GtkWidget *image_status;
GpkHelperRun *helper_run;
guint status_id;
PkStatusEnum status_last;
@@ -658,8 +656,10 @@ gpk_application_status_changed_timeout_cb (GpkApplication *application)
gtk_label_set_label (GTK_LABEL (widget), text);
/* set icon */
- gpk_set_animated_icon_from_status (GPK_ANIMATED_ICON (application->priv->image_status),
- application->priv->status_last, GTK_ICON_SIZE_LARGE_TOOLBAR);
+ widget = GTK_WIDGET (gtk_builder_get_object (application->priv->builder, "image_status"));
+ gtk_image_set_from_icon_name (GTK_IMAGE (widget),
+ gpk_status_enum_to_icon_name (application->priv->status_last),
+ GTK_ICON_SIZE_BUTTON);
/* show containing box */
widget = GTK_WIDGET (gtk_builder_get_object (application->priv->builder, "hbox_status"));
@@ -712,7 +712,6 @@ gpk_application_progress_cb (PkProgress *progress, PkProgressType type, GpkAppli
gtk_widget_hide (widget);
widget = GTK_WIDGET (gtk_builder_get_object (application->priv->builder, "progressbar_progress"));
gtk_widget_hide (widget);
- gpk_animated_icon_enable_animation (GPK_ANIMATED_ICON (application->priv->image_status), FALSE);
goto out;
}
@@ -3815,7 +3814,6 @@ gpk_application_init (GpkApplication *application)
GError *error = NULL;
GSList *array;
guint retval;
- GtkBox *box;
application->priv = GPK_APPLICATION_GET_PRIVATE (application);
application->priv->group = NULL;
@@ -3895,13 +3893,6 @@ gpk_application_init (GpkApplication *application)
goto out_build;
}
- /* add animated widget */
- application->priv->image_status = gpk_animated_icon_new ();
- box = GTK_BOX (gtk_builder_get_object (application->priv->builder, "hbox_status"));
- gtk_box_pack_start (box, application->priv->image_status, FALSE, FALSE, 0);
- gtk_box_reorder_child (box, application->priv->image_status, 0);
- gtk_widget_show (application->priv->image_status);
-
main_window = GTK_WIDGET (gtk_builder_get_object (application->priv->builder, "window_manager"));
/* helpers */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]