From 11c897f3948c0b4864526e2671874fd662f85688 Mon Sep 17 00:00:00 2001 From: Stijn Buys Date: Tue, 26 Jul 2011 20:35:12 +0000 Subject: renamed client::WorldView to client::MainWindow --- src/client/client.cc | 37 +++++++++++++++++++------------------ 1 file changed, 19 insertions(+), 18 deletions(-) (limited to 'src/client/client.cc') diff --git a/src/client/client.cc b/src/client/client.cc index 7d4b7e6..4b27eb7 100644 --- a/src/client/client.cc +++ b/src/client/client.cc @@ -62,7 +62,7 @@ void Client::quit(int status) void Client::init(int count, char **arguments) { - client_worldview = 0; + client_mainwindow = 0; con_print << "^BInitializing client..." << std::endl; // initialize core @@ -103,8 +103,9 @@ void Client::init(int count, char **arguments) // initialize user interface ui::init(); - client_worldview = new WorldView(ui::root()); + client_mainwindow = new MainWindow(ui::root()); + // FIXME needs to be a mainwindow child client_testmodelview = new TestModelView(ui::root()); client_testmodelview->hide(); @@ -308,10 +309,10 @@ void Client::notify_connect() video::set_loader_message(); video::frame_loader(); - worldview()->clear(); + mainwindow()->clear(); ui::root()->hide_menu(); - video::set_caption(); + //video::set_caption(); } void Client::notify_disconnect() @@ -320,9 +321,9 @@ void Client::notify_disconnect() render::reset(); input::reset(); - worldview()->clear(); + mainwindow()->clear(); - video::set_caption(); + //video::set_caption(); } void Client::notify_zonechange() @@ -384,8 +385,8 @@ void Client::notify_message(const core::Message::Channel channel, const std::str break; } - if (worldview()) { - worldview()->event_text(message); + if (mainwindow()) { + mainwindow()->event_text(message); } con_print << message << std::endl; @@ -489,29 +490,29 @@ void Client::func_ui(std::string const &args) void Client::func_ui_chat(std::string const &args) { - if (client()->connected() && client()->worldview()->playerview()->visible()) { - client()->worldview()->playerview()->toggle_chat(); + if (client()->connected() && client()->mainwindow()->playerview()->visible()) { + client()->mainwindow()->playerview()->toggle_chat(); } } void Client::func_ui_chatbar(std::string const &args) { - if (client()->connected() && client()->worldview()->playerview()->visible()) { - client()->worldview()->playerview()->toggle_chatbar(); + if (client()->connected() && client()->mainwindow()->playerview()->visible()) { + client()->mainwindow()->playerview()->toggle_chatbar(); } } void Client::func_ui_inventory(std::string const &args) { - if (client()->connected() && client()->worldview()->playerview()->visible()) { - client()->worldview()->playerview()->toggle_inventory(); + if (client()->connected() && client()->mainwindow()->playerview()->visible()) { + client()->mainwindow()->playerview()->toggle_inventory(); } } void Client::func_ui_map(std::string const &args) { - if (client()->connected() && client()->worldview()->playerview()->visible()) { - client()->worldview()->playerview()->toggle_map(); + if (client()->connected() && client()->mainwindow()->playerview()->visible()) { + client()->mainwindow()->playerview()->toggle_map(); } } @@ -536,8 +537,8 @@ void Client::func_ui_menu(std::string const &args) // entity menus void Client::func_view(std::string const &args) { - if (client()->worldview()) { - client()->worldview()->playerview()->show_menu(args); + if (client()->mainwindow()) { + client()->mainwindow()->playerview()->show_menu(args); } } -- cgit v1.2.3