aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorCosimo Cecchi <cosimoc@gnome.org>2012-05-26 01:31:29 +0800
committerCosimo Cecchi <cosimoc@gnome.org>2012-06-01 04:18:03 +0800
commita402dd47a9f68e483806981b0b8feeb0cec44951 (patch)
treea8f3f00726fd6188bdf34ac709e56d447f882250 /src
parenta018456af6a36b1cb2b8b7b66825f40ac200dcd3 (diff)
downloadgsoc2013-empathy-a402dd47a9f68e483806981b0b8feeb0cec44951.tar
gsoc2013-empathy-a402dd47a9f68e483806981b0b8feeb0cec44951.tar.gz
gsoc2013-empathy-a402dd47a9f68e483806981b0b8feeb0cec44951.tar.bz2
gsoc2013-empathy-a402dd47a9f68e483806981b0b8feeb0cec44951.tar.lz
gsoc2013-empathy-a402dd47a9f68e483806981b0b8feeb0cec44951.tar.xz
gsoc2013-empathy-a402dd47a9f68e483806981b0b8feeb0cec44951.tar.zst
gsoc2013-empathy-a402dd47a9f68e483806981b0b8feeb0cec44951.zip
call-window: use a linked style for the OSD toolbar buttons
Pack the camera/volume/mic buttons in a GtkBox, so they get linked together by the theme. Also, use symbolic icons for the buttons in the toolbar, in GNOME 3 style. https://bugzilla.gnome.org/show_bug.cgi?id=676569
Diffstat (limited to 'src')
-rw-r--r--src/empathy-call-window.c24
-rw-r--r--src/empathy-call-window.ui63
2 files changed, 53 insertions, 34 deletions
diff --git a/src/empathy-call-window.c b/src/empathy-call-window.c
index a6f64da42..6286cab57 100644
--- a/src/empathy-call-window.c
+++ b/src/empathy-call-window.c
@@ -539,8 +539,8 @@ empathy_call_window_disable_camera_cb (GtkAction *action,
{
clutter_actor_destroy (self->priv->preview_hidden_button);
- gtk_toggle_tool_button_set_active (
- GTK_TOGGLE_TOOL_BUTTON (self->priv->camera_button), FALSE);
+ gtk_toggle_button_set_active (
+ GTK_TOGGLE_BUTTON (self->priv->camera_button), FALSE);
}
static void
@@ -2195,8 +2195,8 @@ empathy_call_window_constructed (GObject *object)
if (!empathy_call_handler_has_initial_video (priv->handler))
{
- gtk_toggle_tool_button_set_active (
- GTK_TOGGLE_TOOL_BUTTON (priv->camera_button), FALSE);
+ gtk_toggle_button_set_active (
+ GTK_TOGGLE_BUTTON (priv->camera_button), FALSE);
}
/* If call has InitialVideo, the preview will be started once the call has
* been started (start_call()). */
@@ -2557,8 +2557,8 @@ empathy_call_window_disconnected (EmpathyCallWindow *self,
gtk_widget_set_sensitive (priv->mic_button, FALSE);
/* Be sure that the mic button is enabled */
- gtk_toggle_tool_button_set_active (
- GTK_TOGGLE_TOOL_BUTTON (priv->mic_button), TRUE);
+ gtk_toggle_button_set_active (
+ GTK_TOGGLE_BUTTON (priv->mic_button), TRUE);
if (priv->camera_state == CAMERA_STATE_ON)
{
@@ -2847,8 +2847,8 @@ empathy_call_window_update_timer (gpointer user_data)
if (priv->call_state == HELD)
status = _("On hold");
- else if (!gtk_toggle_tool_button_get_active (
- GTK_TOGGLE_TOOL_BUTTON (priv->mic_button)))
+ else if (!gtk_toggle_button_get_active (
+ GTK_TOGGLE_BUTTON (priv->mic_button)))
status = _("Mute");
else
status = _("Duration");
@@ -3537,13 +3537,13 @@ start_call (EmpathyCallWindow *self)
s == TP_SENDING_STATE_SENDING)
{
/* Enable 'send video' buttons and display the preview */
- gtk_toggle_tool_button_set_active (
- GTK_TOGGLE_TOOL_BUTTON (priv->camera_button), TRUE);
+ gtk_toggle_button_set_active (
+ GTK_TOGGLE_BUTTON (priv->camera_button), TRUE);
}
else
{
- gtk_toggle_tool_button_set_active (
- GTK_TOGGLE_TOOL_BUTTON (priv->camera_button), FALSE);
+ gtk_toggle_button_set_active (
+ GTK_TOGGLE_BUTTON (priv->camera_button), FALSE);
if (priv->video_preview == NULL)
{
diff --git a/src/empathy-call-window.ui b/src/empathy-call-window.ui
index 2caa242b8..7149a3e8b 100644
--- a/src/empathy-call-window.ui
+++ b/src/empathy-call-window.ui
@@ -254,37 +254,56 @@
<object class="GtkToolbar" id="bottom_toolbar">
<property name="visible">True</property>
<property name="show_arrow">False</property>
- <property name="name">CallFloatingToolbar</property>
<child>
- <object class="GtkToggleToolButton" id="camera">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Send Video</property>
- <property name="icon_name">camera-web</property>
- <property name="sensitive">False</property>
- <property name="tooltip_text" translatable="yes">Toggle video transmission</property>
- </object>
- </child>
- <child>
- <object class="GtkToolItem" id="toolitem3">
+ <object class="GtkToolItem" id="toolitem_group">
<property name="visible">True</property>
<child>
- <object class="GtkVolumeButton" id="volume">
+ <object class="GtkBox" id="button_group">
+ <property name="orientation">horizontal</property>
+ <property name="spacing">0</property>
<property name="visible">True</property>
- <property name="value">1.0</property>
+ <child>
+ <object class="GtkToggleButton" id="camera">
+ <property name="visible">True</property>
+ <property name="sensitive">False</property>
+ <property name="tooltip_text" translatable="yes">Toggle video transmission</property>
+ <child>
+ <object class="GtkImage" id="camera_icon">
+ <property name="visible">True</property>
+ <property name="icon_name">camera-web-symbolic</property>
+ <property name="icon_size">1</property>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child>
+ <object class="GtkVolumeButton" id="volume">
+ <property name="visible">True</property>
+ <property name="value">1.0</property>
+ <property name="relief">normal</property>
+ <property name="use_symbolic">True</property>
+ <property name="size">1</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkToggleButton" id="microphone">
+ <property name="visible">True</property>
+ <property name="active">True</property>
+ <property name="tooltip_text" translatable="yes">Toggle audio transmission</property>
+ <child>
+ <object class="GtkImage" id="microphone_icon">
+ <property name="visible">True</property>
+ <property name="icon_name">audio-input-microphone-symbolic</property>
+ <property name="icon_size">1</property>
+ </object>
+ </child>
+ </object>
+ </child>
</object>
</child>
</object>
</child>
<child>
- <object class="GtkToggleToolButton" id="microphone">
- <property name="visible">True</property>
- <property name="active">True</property>
- <property name="label" translatable="yes">Send Audio</property>
- <property name="icon_name">gnome-stock-mic</property>
- <property name="tooltip_text" translatable="yes">Toggle audio transmission</property>
- </object>
- </child>
- <child>
<object class="GtkSeparatorToolItem" id="toolbutton2">
<property name="draw">False</property>
<property name="visible">True</property>