From bcebd9665a5154c4ccc54ba7b517208e6ba493b4 Mon Sep 17 00:00:00 2001 From: vng Date: Fri, 15 Jun 2012 23:14:04 -0700 Subject: [PATCH] Minor code style fixes. --- base/thread.hpp | 6 +++++- iphone/Maps/Classes/MapViewController.mm | 4 ++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/base/thread.hpp b/base/thread.hpp index 7f8467a5b2..6432205b60 100644 --- a/base/thread.hpp +++ b/base/thread.hpp @@ -14,13 +14,17 @@ namespace threads { private: bool m_isCancelled; + protected: - bool IsCancelled() { return m_isCancelled; } + inline bool IsCancelled() const { return m_isCancelled; } + public: IRoutine() : m_isCancelled(false) {} virtual ~IRoutine() {} + /// Performing the main task virtual void Do() = 0; + /// Implement this function to respond to the cancellation event. /// Cancellation means that IRoutine should exit as fast as possible. virtual void Cancel() { m_isCancelled = true; } diff --git a/iphone/Maps/Classes/MapViewController.mm b/iphone/Maps/Classes/MapViewController.mm index fba9042d0d..8f15c4f39c 100644 --- a/iphone/Maps/Classes/MapViewController.mm +++ b/iphone/Maps/Classes/MapViewController.mm @@ -161,8 +161,8 @@ // Helper to display/hide pin on screen tap m_bookmark = [[BalloonView alloc] initWithTarget:self andSelector:@selector(onBookmarkClicked)]; - // cyclic dependence, @TODO refactor. - // Here we're creating view and window handle in it, and later we should pass framework to the view + /// @TODO refactor cyclic dependence. + /// Here we're creating view and window handle in it, and later we should pass framework to the view. EAGLView * v = (EAGLView *)self.view; Framework & f = GetFramework();