~ubuntu-branches/ubuntu/jaunty/gnome-system-tools/jaunty-proposed

« back to all changes in this revision

Viewing changes to src/network/callbacks.c

  • Committer: Bazaar Package Importer
  • Author(s): Emilio Pozuelo Monfort
  • Date: 2007-12-20 23:22:31 UTC
  • mfrom: (1.1.27 upstream)
  • Revision ID: james.westby@ubuntu.com-20071220232231-y4lyk1l7hpfgslri
Tags: 2.21.3-0ubuntu1
* New upstream release.
  - Network: Support PPPoE/GPRS/UMTS interfaces.
  - Shares: Handle SMB passwords.
  - Common: Improvements to UI locking
  - Ask whether to update config if the user is editing configuration
    and the backends detect some change
  - Translations
    + be@latin (Ihar Hrachyshka)
    + es (Jorge Gonzalez)
    + nb (Kjartan Maraas)
    + ru (Vasiliy Faronov)
    + sv (Daniel Nylander)

* debian/control:
  - Require liboobs >= 2.21.3 in build-depends.
* debian/patches/23_users_update_model.dpatch:
  - Updated for the new release.
* debian/patches/98_automake.dpatch:
  - Regenerated.

Show diffs side-by-side

added added

removed removed

Lines of Context:
59
59
      dialog = GST_NETWORK_TOOL (tool)->dialog;
60
60
      connection_dialog_prepare (dialog, iface);
61
61
      gtk_window_set_transient_for (GTK_WINDOW (dialog->dialog), GTK_WINDOW (tool->main_dialog));
 
62
 
 
63
      gst_dialog_add_edit_dialog (tool->main_dialog, dialog->dialog);
62
64
      gtk_widget_show (dialog->dialog);
63
65
    }
64
66
}
118
120
  g_free (method);
119
121
}
120
122
 
 
123
void
 
124
on_ppp_type_changed (GtkWidget *widget, gpointer data)
 
125
{
 
126
  GstConnectionDialog *dialog;
 
127
  gchar *type;
 
128
 
 
129
  dialog = GST_NETWORK_TOOL (tool)->dialog;
 
130
  type = connection_combo_get_value (GTK_COMBO_BOX (dialog->ppp_type_combo));
 
131
 
 
132
  on_dialog_changed (widget, data);
 
133
 
 
134
  if (!type)
 
135
    return;
 
136
 
 
137
  if (strcmp (type, "modem") == 0)
 
138
    {
 
139
      gtk_widget_show (dialog->modem_page);
 
140
      gtk_widget_show (dialog->isp_frame);
 
141
      gtk_widget_show (dialog->modem_settings_table);
 
142
      gtk_widget_show (dialog->modem_isp_table);
 
143
      gtk_widget_hide (dialog->pppoe_settings_table);
 
144
      gtk_widget_hide (dialog->gprs_isp_table);
 
145
    }
 
146
  else if (strcmp (type, "isdn") == 0)
 
147
    {
 
148
      gtk_widget_show (dialog->isp_frame);
 
149
      gtk_widget_show (dialog->modem_isp_table);
 
150
      gtk_widget_hide (dialog->modem_page);
 
151
      gtk_widget_hide (dialog->gprs_isp_table);
 
152
    }
 
153
  else if (strcmp (type, "pppoe") == 0)
 
154
    {
 
155
      gtk_widget_show (dialog->modem_page);
 
156
      gtk_widget_show (dialog->pppoe_settings_table);
 
157
      gtk_widget_show (dialog->modem_isp_table);
 
158
      gtk_widget_hide (dialog->isp_frame);
 
159
      gtk_widget_hide (dialog->modem_settings_table);
 
160
    }
 
161
  else if (strcmp (type, "gprs") == 0)
 
162
    {
 
163
      gtk_widget_show (dialog->modem_page);
 
164
      gtk_widget_show (dialog->isp_frame);
 
165
      gtk_widget_show (dialog->modem_settings_table);
 
166
      gtk_widget_show (dialog->gprs_isp_table);
 
167
      gtk_widget_hide (dialog->modem_isp_table);
 
168
      gtk_widget_hide (dialog->pppoe_settings_table);
 
169
    }
 
170
}
 
171
 
121
172
static void
122
173
cancel_connection_dialog (GstTool *tool)
123
174
{
198
249
                        gint       response,
199
250
                        gpointer   data)
200
251
{
 
252
  GstConnectionDialog *connection_dialog;
201
253
  GstDialog *dialog = GST_DIALOG (data);
202
254
  GstTool *tool = gst_dialog_get_tool (dialog);
203
255
 
205
257
    accept_connection_dialog (tool);
206
258
  else
207
259
    cancel_connection_dialog (tool);
 
260
 
 
261
  connection_dialog = GST_NETWORK_TOOL (tool)->dialog;
 
262
  gst_dialog_remove_edit_dialog (tool->main_dialog, connection_dialog->dialog);
208
263
}
209
264
 
210
265
void
332
387
void
333
388
on_host_aliases_add_clicked (GtkWidget *widget, gpointer data)
334
389
{
335
 
  host_aliases_run_dialog (NULL);
 
390
  host_aliases_run_dialog (GST_NETWORK_TOOL (tool), NULL);
336
391
}
337
392
 
338
393
void
347
402
  selection = gtk_tree_view_get_selection (list);
348
403
 
349
404
  if (gtk_tree_selection_get_selected (selection, &model, &iter))
350
 
    host_aliases_run_dialog (&iter);
 
405
    host_aliases_run_dialog (GST_NETWORK_TOOL (tool), &iter);
351
406
}
352
407
 
353
408
void