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

Delta Between Two Patch Sets: src/engine/Main.cpp

Issue 11276031: FRP wrappers. "Update" menu item. (Closed)
Left Patch Set: Comments addressed Created Aug. 8, 2013, 2:18 p.m.
Right Patch Set: Handle incorrect parameters for UpdateAvailable as an error Created Aug. 9, 2013, 8:11 a.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
Right: Side by side diff | Download
« no previous file with change/comment | « no previous file | no next file » | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
(no file at all)
1 #include <AdblockPlus.h> 1 #include <AdblockPlus.h>
2 #include <functional> 2 #include <functional>
3 #include <vector> 3 #include <vector>
4 #include <Windows.h> 4 #include <Windows.h>
5 5
6 #include "../shared/AutoHandle.h" 6 #include "../shared/AutoHandle.h"
7 #include "../shared/Communication.h" 7 #include "../shared/Communication.h"
8 #include "../shared/Dictionary.h" 8 #include "../shared/Dictionary.h"
9 #include "../shared/Utils.h" 9 #include "../shared/Utils.h"
10 #include "../shared/Version.h" 10 #include "../shared/Version.h"
(...skipping 305 matching lines...) Expand 10 before | Expand all | Expand 10 after
316 activeConnections = 0; 316 activeConnections = 0;
317 exit(0); 317 exit(0);
318 } 318 }
319 } 319 }
320 320
321 return 0; 321 return 0;
322 } 322 }
323 323
324 void OnUpdateAvailable(AdblockPlus::JsValueList& params) 324 void OnUpdateAvailable(AdblockPlus::JsValueList& params)
325 { 325 {
326 updateAvailable = true;
327 if (params.size() < 1) 326 if (params.size() < 1)
328 { 327 {
329 Debug("updateAvailable event missing URL"); 328 Debug("updateAvailable event missing URL");
330 return; 329 return;
331 } 330 }
331 updateAvailable = true;
Oleksandr 2013/08/09 08:17:39 Probably the most discussed line of code
Felix Dahlke 2013/08/09 09:15:29 Quite definitely :D
332 332
333 updater->SetUrl(params[0]->AsString()); 333 updater->SetUrl(params[0]->AsString());
334 updater->Update(); 334 updater->Update();
335 } 335 }
336 } 336 }
337 337
338 std::auto_ptr<AdblockPlus::FilterEngine> CreateFilterEngine(const std::wstring& locale) 338 std::auto_ptr<AdblockPlus::FilterEngine> CreateFilterEngine(const std::wstring& locale)
339 { 339 {
340 AdblockPlus::AppInfo appInfo; 340 AdblockPlus::AppInfo appInfo;
341 appInfo.version = ToUtf8String(IEPLUGIN_VERSION); 341 appInfo.version = ToUtf8String(IEPLUGIN_VERSION);
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
401 } 401 }
402 catch (std::runtime_error e) 402 catch (std::runtime_error e)
403 { 403 {
404 DebugException(e); 404 DebugException(e);
405 return 1; 405 return 1;
406 } 406 }
407 } 407 }
408 408
409 return 0; 409 return 0;
410 } 410 }
LEFTRIGHT
« no previous file | no next file » | Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Toggle Comments ('s')

Powered by Google App Engine
This is Rietveld