Merge branch '1.0'

This commit is contained in:
David Capello 2014-12-05 10:52:05 -03:00
commit 6f528f3cf2
5 changed files with 15 additions and 5 deletions

View File

@ -420,8 +420,6 @@ void App::run()
// Start shell to execute scripts. // Start shell to execute scripts.
if (m_isShell) { if (m_isShell) {
m_systemConsole.prepareShell();
if (m_modules->m_scriptingEngine.supportEval()) { if (m_modules->m_scriptingEngine.supportEval()) {
Shell shell; Shell shell;
shell.run(m_modules->m_scriptingEngine); shell.run(m_modules->m_scriptingEngine);

View File

@ -22,7 +22,6 @@
#include "base/signal.h" #include "base/signal.h"
#include "base/string.h" #include "base/string.h"
#include "base/system_console.h"
#include "base/unique_ptr.h" #include "base/unique_ptr.h"
#include "doc/pixel_format.h" #include "doc/pixel_format.h"
@ -95,7 +94,6 @@ namespace app {
static App* m_instance; static App* m_instance;
base::SystemConsole m_systemConsole;
base::UniquePtr<ui::GuiSystem> m_guiSystem; base::UniquePtr<ui::GuiSystem> m_guiSystem;
Modules* m_modules; Modules* m_modules;
LegacyModules* m_legacy; LegacyModules* m_legacy;

View File

@ -90,7 +90,11 @@ CheckUpdateThreadLauncher::CheckUpdateThreadLauncher()
, m_received(false) , m_received(false)
, m_inits(get_config_int("Updater", "Inits", 0)) , m_inits(get_config_int("Updater", "Inits", 0))
, m_exits(get_config_int("Updater", "Exits", 0)) , m_exits(get_config_int("Updater", "Exits", 0))
#ifdef _DEBUG
, m_isDeveloper(true)
#else
, m_isDeveloper(get_config_bool("Updater", "IsDeveloper", false)) , m_isDeveloper(get_config_bool("Updater", "IsDeveloper", false))
#endif
, m_timer(kMonitoringPeriod, NULL) , m_timer(kMonitoringPeriod, NULL)
{ {
// Get how many days we have to wait for the next "check for update" // Get how many days we have to wait for the next "check for update"

View File

@ -28,6 +28,7 @@
#include "base/exception.h" #include "base/exception.h"
#include "base/memory.h" #include "base/memory.h"
#include "base/memory_dump.h" #include "base/memory_dump.h"
#include "base/system_console.h"
#include "she/error.h" #include "she/error.h"
#include "she/scoped_handle.h" #include "she/scoped_handle.h"
#include "she/system.h" #include "she/system.h"
@ -68,7 +69,7 @@ int app_main(int argc, char* argv[])
try { try {
base::MemoryDump memoryDump; base::MemoryDump memoryDump;
MemLeak memleak; MemLeak memleak;
base::SystemConsole systemConsole;
app::AppOptions options(argc, const_cast<const char**>(argv)); app::AppOptions options(argc, const_cast<const char**>(argv));
she::ScopedHandle<she::System> system(she::create_system()); she::ScopedHandle<she::System> system(she::create_system());
app::App app; app::App app;
@ -81,6 +82,10 @@ int app_main(int argc, char* argv[])
} }
app.initialize(options); app.initialize(options);
if (options.startShell())
systemConsole.prepareShell();
app.run(); app.run();
return 0; return 0;
} }

View File

@ -128,6 +128,11 @@ public:
HttpResponse response(&body); HttpResponse response(&body);
request.send(response); request.send(response);
#ifdef _DEBUG
PRINTF("Checking updates: %s (User-Agent: %s)\n", url.c_str(), getUserAgent().c_str());
PRINTF("Response:\n--\n%s--\n", body.str().c_str());
#endif
CheckUpdateResponse data(body.str()); CheckUpdateResponse data(body.str());
delegate->onResponse(data); delegate->onResponse(data);
} }