Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrachytski <siarhei.rachytski@gmail.com>2011-11-11 16:57:07 +0400
committerAlex Zolotarev <alex@maps.me>2015-09-23 01:27:41 +0300
commit558f774247e8730bca3a5ae018545e26669e569d (patch)
tree02890ffc8e7bd3bcee4d32d4e796f284d722f965 /iphone/Maps/Classes
parentf79d2a3d588c87ae1cda987032eb94655df0312e (diff)
WindowHandle shouldn't control the lifetime of VideoTimer.
Diffstat (limited to 'iphone/Maps/Classes')
-rw-r--r--iphone/Maps/Classes/EAGLView.h2
-rw-r--r--iphone/Maps/Classes/EAGLView.mm4
2 files changed, 5 insertions, 1 deletions
diff --git a/iphone/Maps/Classes/EAGLView.h b/iphone/Maps/Classes/EAGLView.h
index 517c9551fc..72fef24cd1 100644
--- a/iphone/Maps/Classes/EAGLView.h
+++ b/iphone/Maps/Classes/EAGLView.h
@@ -32,6 +32,7 @@ typedef Framework<model::FeaturesFetcher> framework_t;
@public
framework_t * framework;
+ VideoTimer * videoTimer;
shared_ptr<iphone::RenderContext> renderContext;
shared_ptr<yg::gl::FrameBuffer> frameBuffer;
shared_ptr<iphone::RenderBuffer> renderBuffer;
@@ -41,6 +42,7 @@ typedef Framework<model::FeaturesFetcher> framework_t;
- (void) initRenderPolicy;
@property (nonatomic, assign) framework_t * framework;
+@property (nonatomic, assign) VideoTimer * videoTimer;
@property (nonatomic, assign) shared_ptr<iphone::RenderContext> renderContext;
@property (nonatomic, assign) shared_ptr<iphone::RenderBuffer> renderBuffer;
@property (nonatomic, assign) shared_ptr<yg::gl::FrameBuffer> frameBuffer;
diff --git a/iphone/Maps/Classes/EAGLView.mm b/iphone/Maps/Classes/EAGLView.mm
index 73ca18b726..6f62c7165b 100644
--- a/iphone/Maps/Classes/EAGLView.mm
+++ b/iphone/Maps/Classes/EAGLView.mm
@@ -17,6 +17,7 @@
@implementation EAGLView
@synthesize framework;
+@synthesize videoTimer;
@synthesize frameBuffer;
@synthesize renderContext;
@synthesize renderBuffer;
@@ -95,7 +96,7 @@
SEL drawFrameSel = @selector(drawFrame);
drawFrameFn drawFrameImpl = (drawFrameFn)[self methodForSelector:drawFrameSel];
- VideoTimer * videoTimer = CreateIOSVideoTimer(bind(drawFrameImpl, self, drawFrameSel));
+ videoTimer = CreateIOSVideoTimer(bind(drawFrameImpl, self, drawFrameSel));
renderPolicy = CreateRenderPolicy(videoTimer, p, renderContext);
@@ -151,6 +152,7 @@
- (void)dealloc
{
+ delete videoTimer;
// m_framework->SetRenderPolicy(0);
[EAGLContext setCurrentContext:nil];
[super dealloc];