Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: src/engine/Main.cpp

Issue 5171515343503360: Issue #41 - Bring method of determining IE version up to date (Closed)
Patch Set: Created July 30, 2014, 1 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
OLDNEW
1 #include <AdblockPlus.h> 1 #include <AdblockPlus.h>
2 #include <functional> 2 #include <functional>
3 #include <vector> 3 #include <vector>
4 #include <thread> 4 #include <thread>
5 #include <Windows.h> 5 #include <Windows.h>
6 6
7 #include "../shared/AutoHandle.h" 7 #include "../shared/AutoHandle.h"
8 #include "../shared/Communication.h" 8 #include "../shared/Communication.h"
9 #include "../shared/Dictionary.h" 9 #include "../shared/Dictionary.h"
10 #include "../shared/Utils.h" 10 #include "../shared/Utils.h"
11 #include "../shared/Version.h" 11 #include "../shared/Version.h"
12 #include "../shared/CriticalSection.h" 12 #include "../shared/CriticalSection.h"
13 #include "../shared/IE_version.h"
13 #include "AdblockPlus.h" 14 #include "AdblockPlus.h"
14 #include "Debug.h" 15 #include "Debug.h"
15 #include "Updater.h" 16 #include "Updater.h"
16 17
17 namespace 18 namespace
18 { 19 {
19 std::auto_ptr<AdblockPlus::FilterEngine> filterEngine; 20 std::auto_ptr<AdblockPlus::FilterEngine> filterEngine;
20 std::auto_ptr<Updater> updater; 21 std::auto_ptr<Updater> updater;
21 int activeConnections = 0; 22 int activeConnections = 0;
22 CriticalSection activeConnectionsLock; 23 CriticalSection activeConnectionsLock;
(...skipping 376 matching lines...) Expand 10 before | Expand all | Expand 10 after
399 std::auto_ptr<AdblockPlus::FilterEngine> CreateFilterEngine(const std::wstring& locale) 400 std::auto_ptr<AdblockPlus::FilterEngine> CreateFilterEngine(const std::wstring& locale)
400 { 401 {
401 AdblockPlus::AppInfo appInfo; 402 AdblockPlus::AppInfo appInfo;
402 appInfo.version = ToUtf8String(IEPLUGIN_VERSION); 403 appInfo.version = ToUtf8String(IEPLUGIN_VERSION);
403 appInfo.name = "adblockplusie"; 404 appInfo.name = "adblockplusie";
404 #ifdef _WIN64 405 #ifdef _WIN64
405 appInfo.application = "msie64"; 406 appInfo.application = "msie64";
406 #else 407 #else
407 appInfo.application = "msie32"; 408 appInfo.application = "msie32";
408 #endif 409 #endif
409 // TODO: Set applicationVersion parameter 410 appInfo.applicationVersion = ToUtf8String(AdblockPlus::IE::InstalledVersionStr ing());
410 appInfo.locale = ToUtf8String(locale); 411 appInfo.locale = ToUtf8String(locale);
411 #ifdef ADBLOCK_PLUS_TEST_MODE 412 #ifdef ADBLOCK_PLUS_TEST_MODE
412 appInfo.developmentBuild = true; 413 appInfo.developmentBuild = true;
413 #else 414 #else
414 appInfo.developmentBuild = false; 415 appInfo.developmentBuild = false;
415 #endif 416 #endif
416 417
417 AdblockPlus::JsEnginePtr jsEngine = AdblockPlus::JsEngine::New(appInfo); 418 AdblockPlus::JsEnginePtr jsEngine = AdblockPlus::JsEngine::New(appInfo);
418 jsEngine->SetEventCallback("updateAvailable", &OnUpdateAvailable); 419 jsEngine->SetEventCallback("updateAvailable", &OnUpdateAvailable);
419 420
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
468 } 469 }
469 catch (const std::runtime_error& e) 470 catch (const std::runtime_error& e)
470 { 471 {
471 DebugException(e); 472 DebugException(e);
472 return 1; 473 return 1;
473 } 474 }
474 } 475 }
475 476
476 return 0; 477 return 0;
477 } 478 }
OLDNEW
« no previous file with comments | « adblockplus.gyp ('k') | src/plugin/AdblockPlusClient.h » ('j') | src/shared/IE_version.cpp » ('J')

Powered by Google App Engine
This is Rietveld