$ git clone http://tcclient.ion.nu/tc_client.git
commit c56561a051a0aaf76390f03e2224e8c9ead6c1fa
Author: Alicia <...>
Date:   Fri Nov 27 16:51:47 2015 +0100

    tc_client-gtk: added an option to automatically cam down when someone joins ("Shy mode")

diff --git a/ChangeLog b/ChangeLog
index 82d4ecc..afb1e93 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -6,6 +6,7 @@ modbot: added support for /mbpa (pause) and /mbpl (play/resume)
 modbot: check that videos can be embedded (for the flash client) before adding them to the queue.
 modbot: when skipping an unapproved video after 2 minutes, find the next approved video when it's time to play it (in case the queue has changed)
 irchack: changed WHOIS to use the new /whois command instead of /userinfo (which tinychat retired)
+tc_client-gtk: added an option to automatically cam down when someone joins ("Shy mode")
 0.35:
 Adjusted for tinychat authentication changes (both for joining the channel and to use moderator accounts)
 Send account username in AMF0 "connect" command at startup regardless of whether we are modded or not, as is now required for non-mod accounts (contributed by Jade)
diff --git a/gtkgui.glade b/gtkgui.glade
index bebe516..ca5fc0c 100644
--- a/gtkgui.glade
+++ b/gtkgui.glade
@@ -953,6 +953,51 @@
                 <property name="tab_fill">False</property>
               </packing>
             </child>
+            <child>
+              <object class="GtkScrolledWindow" id="scrolledwindow4">
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="shadow_type">in</property>
+                <child>
+                  <object class="GtkViewport" id="viewport5">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <child>
+                      <object class="GtkCheckButton" id="camdownonjoin">
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">False</property>
+                        <property name="xalign">0</property>
+                        <property name="draw_indicator">True</property>
+                        <child>
+                          <object class="GtkLabel" id="label19">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="label" translatable="yes">Automatically cam down when someone joins (or "Shy mode")</property>
+                            <property name="wrap">True</property>
+                            <property name="wrap_mode">word-char</property>
+                          </object>
+                        </child>
+                      </object>
+                    </child>
+                  </object>
+                </child>
+              </object>
+              <packing>
+                <property name="position">3</property>
+              </packing>
+            </child>
+            <child type="tab">
+              <object class="GtkLabel" id="label18">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Misc</property>
+              </object>
+              <packing>
+                <property name="position">3</property>
+                <property name="tab_fill">False</property>
+              </packing>
+            </child>
           </object>
           <packing>
             <property name="expand">True</property>
diff --git a/utilities/gtk/camviewer.c b/utilities/gtk/camviewer.c
index d839698..f51be67 100644
--- a/utilities/gtk/camviewer.c
+++ b/utilities/gtk/camviewer.c
@@ -341,6 +341,10 @@ gboolean handledata(GIOChannel* iochannel, GIOCondition condition, gpointer data
     {
       if(!strcmp(space, " entered the channel"))
       {
+        if(config_get_bool("camdownonjoin"))
+        {
+          gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(gtk_builder_get_object(gui, "menuitem_broadcast_camera")), 0);
+        }
         space[0]=0;
         adduser(nick);
       }
@@ -996,6 +1000,8 @@ int main(int argc, char** argv)
   // Youtube
   option=GTK_WIDGET(gtk_builder_get_object(gui, "youtuberadio_cmd"));
   g_signal_connect(option, "toggled", G_CALLBACK(toggle_youtubecmd), gui);
+  // Misc
+  option=GTK_WIDGET(gtk_builder_get_object(gui, "camdownonjoin"));
 
   GtkWidget* window=GTK_WIDGET(gtk_builder_get_object(gui, "main"));
   g_signal_connect(window, "configure-event", G_CALLBACK(handleresize), data);
diff --git a/utilities/gtk/gui.c b/utilities/gtk/gui.c
index d0a26da..8caa388 100644
--- a/utilities/gtk/gui.c
+++ b/utilities/gtk/gui.c
@@ -63,6 +63,9 @@ void settings_reset(GtkBuilder* gui)
   gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(option), config_get_bool("youtuberadio_cmd"));
   option=GTK_WIDGET(gtk_builder_get_object(gui, "youtubecmd"));
   gtk_entry_set_text(GTK_ENTRY(option), config_get_str("youtubecmd"));
+  // Misc
+  option=GTK_WIDGET(gtk_builder_get_object(gui, "camdownonjoin"));
+  gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(option), config_get_bool("camdownonjoin"));
 }
 
 void showsettings(GtkMenuItem* item, GtkBuilder* gui)
@@ -92,6 +95,9 @@ void savesettings(GtkButton* button, GtkBuilder* gui)
   config_set("youtubecmd", gtk_entry_get_text(GTK_ENTRY(youtubecmd)));
   GtkWidget* youtuberadio_cmd=GTK_WIDGET(gtk_builder_get_object(gui, "youtuberadio_cmd"));
   config_set("youtuberadio_cmd", gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(youtuberadio_cmd))?"True":"False");
+  // Misc
+  GtkWidget* option=GTK_WIDGET(gtk_builder_get_object(gui, "camdownonjoin"));
+  config_set("camdownonjoin", gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(option))?"True":"False");
 
   config_save();
   GtkWidget* settings=GTK_WIDGET(gtk_builder_get_object(gui, "settings"));