ekiga r6813 - in trunk: . src/gui
- From: dsandras svn gnome org
- To: svn-commits-list gnome org
- Subject: ekiga r6813 - in trunk: . src/gui
- Date: Wed, 3 Sep 2008 21:03:02 +0000 (UTC)
Author: dsandras
Date: Wed Sep 3 21:03:02 2008
New Revision: 6813
URL: http://svn.gnome.org/viewvc/ekiga?rev=6813&view=rev
Log:
Removed annoying account reordering. When toggling an account, clear
the previous status message.
Modified:
trunk/ChangeLog
trunk/src/gui/accounts.cpp
Modified: trunk/src/gui/accounts.cpp
==============================================================================
--- trunk/src/gui/accounts.cpp (original)
+++ trunk/src/gui/accounts.cpp Wed Sep 3 21:03:02 2008
@@ -314,6 +314,8 @@
GtkTreeSelection *selection = NULL;
GtkTreeIter iter;
+ bool fixed = false;
+
Ekiga::Account *account = NULL;
aw = gm_aw_get_aw (GTK_WIDGET (data));
@@ -327,11 +329,24 @@
if (gtk_tree_model_get_iter (model, &iter, path)) {
gtk_tree_model_get (model, &iter,
+ COLUMN_ACCOUNT_ENABLED, &fixed,
COLUMN_ACCOUNT, &account,
-1);
- bool enabled = account->is_enabled ();
- enabled ? account->disable () : account->enable ();
+ if (fixed) {
+
+ if (account->is_active ()) {
+ account->disable ();
+ }
+ }
+ else if (!account->is_active ()) {
+ account->enable ();
+ }
+
+ gtk_list_store_set (GTK_LIST_STORE (model), &iter,
+ COLUMN_ACCOUNT_ENABLED, fixed^1,
+ COLUMN_ACCOUNT_ERROR_MESSAGE, "",
+ -1);
}
gtk_tree_path_free (path);
@@ -507,7 +522,6 @@
GtkWidget *frame = NULL;
GtkWidget *hbox = NULL;
- GtkTreeModel *model = NULL;
GtkCellRenderer *renderer = NULL;
GtkListStore *list_store = NULL;
GtkTreeViewColumn *column = NULL;
@@ -605,11 +619,6 @@
gtk_tree_view_column_set_sort_column_id (column, i);
}
- model = gtk_tree_view_get_model (GTK_TREE_VIEW (aw->accounts_list));
- gtk_tree_sortable_set_sort_column_id (GTK_TREE_SORTABLE (model),
- COLUMN_ACCOUNT_ENABLED,
- GTK_SORT_DESCENDING);
-
g_signal_connect (G_OBJECT (aw->accounts_list), "event_after",
G_CALLBACK (account_clicked_cb), window);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]