mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 21:31:04 +00:00
Bug 854446: Allow setting Moz2D recording destination. r=joedrew
This commit is contained in:
parent
50dd116a93
commit
f769e31c87
@ -379,7 +379,17 @@ gfxPlatform::Init()
|
||||
= do_CreateInstance("@mozilla.org/gfx/init;1");
|
||||
|
||||
if (Preferences::GetBool("gfx.2d.recording", false)) {
|
||||
gPlatform->mRecorder = Factory::CreateEventRecorderForFile("browserrecording.aer");
|
||||
|
||||
nsAutoCString fileName;
|
||||
nsAdoptingString prefFileName = Preferences::GetString("gfx.2d.recordingfile");
|
||||
|
||||
if (prefFileName) {
|
||||
fileName.Append(NS_ConvertUTF16toUTF8(prefFileName));
|
||||
} else {
|
||||
fileName.AssignLiteral("browserrecording.aer");
|
||||
}
|
||||
|
||||
gPlatform->mRecorder = Factory::CreateEventRecorderForFile(fileName.BeginReading());
|
||||
Factory::SetGlobalEventRecorder(gPlatform->mRecorder);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user