Bug 792207 - Part 6: Add simple code allow enabling browser recording. r=jrmuizel

This commit is contained in:
Bas Schouten 2012-09-24 15:02:50 +00:00
parent 1cbd658d18
commit 5acda0d600
2 changed files with 7 additions and 0 deletions

View File

@ -350,6 +350,11 @@ gfxPlatform::Init()
// ::Shutdown to be called.
nsCOMPtr<nsISupports> forceReg
= do_CreateInstance("@mozilla.org/gfx/init;1");
if (Preferences::GetBool("gfx.2d.recording", false)) {
gPlatform->mRecorder = Factory::CreateEventRecorderForFile("browserrecording.aer");
Factory::SetGlobalEventRecorder(gPlatform->mRecorder);
}
}
void

View File

@ -551,6 +551,8 @@ private:
mozilla::widget::GfxInfoCollector<gfxPlatform> mAzureCanvasBackendCollector;
bool mWorkAroundDriverBugs;
mozilla::RefPtr<mozilla::gfx::DrawEventRecorder> mRecorder;
};
#endif /* GFX_PLATFORM_H */