Fixed updating connect button
This commit is contained in:
parent
3f321ee924
commit
a3de8c9394
|
@ -30,18 +30,8 @@
|
|||
#include "mcp/gm-mcp-package.h"
|
||||
#include "gm-searchable.h"
|
||||
#include "gm-tray.h"
|
||||
|
||||
//#include "if_world.h"
|
||||
//#include "if_worlds_listing.h"
|
||||
//#include "if_preferences.h"
|
||||
//#include "if_mcpconsole.h"
|
||||
|
||||
#include "gm-pixbuf.h"
|
||||
#include "gm-support.h"
|
||||
//#include "term.h"
|
||||
//#include "world.h"
|
||||
//#include "net.h"
|
||||
//#include "main.h"
|
||||
|
||||
void on_gm_app_view_entry_find_activate(GtkEntry *entry, GmAppView *view);
|
||||
void on_gm_app_view_entry_find_changed(GtkEditable *editable,
|
||||
|
@ -1724,7 +1714,19 @@ on_gm_app_view_world_active_changed(GmWorld *world, GParamSpec *pspec,
|
|||
gtk_notebook_set_current_page(view->priv->notebook,
|
||||
gtk_notebook_page_num(view->priv->notebook,
|
||||
GTK_WIDGET(world_view)));
|
||||
|
||||
gm_app_view_update_title(view);
|
||||
|
||||
switch (gm_world_state(world)) {
|
||||
case GM_NET_STATE_CONNECTING: case GM_NET_STATE_CONNECTED:
|
||||
gm_app_view_update_connect_button(view, TRUE);
|
||||
break;
|
||||
case GM_NET_STATE_DISCONNECTED:
|
||||
gm_app_view_update_connect_button(view, FALSE);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Reference in New Issue