options.Get(switches::kTitle, &title);
SetTitle(title);
- offscreen_ = false;
- options.Get(switches::kOffScreenRender, &offscreen_);
-
// Then show it.
bool show = true;
options.Get(switches::kShow, &show);
}
void NativeWindow::SetFrameSubscription(bool isOffscreen) {
- if (!isOffscreen && !offscreen_) return;
-
const auto view = web_contents()->GetRenderWidgetHostView();
if (view) {
} else {
view->EndFrameSubscription();
}
-
- offscreen_ = isOffscreen;
}
}
host->ForwardWheelEvent(*wheel_event);
}
-void NativeWindow::DidFinishLoad(content::RenderFrameHost* render_frame_host, const GURL& validated_url) {
- SetFrameSubscription(offscreen_);
-}
-
void NativeWindow::RenderViewCreated(
content::RenderViewHost* render_view_host) {
if (!transparent_)
// content::WebContentsObserver:
void RenderViewCreated(content::RenderViewHost* render_view_host) override;
- void DidFinishLoad(content::RenderFrameHost* render_frame_host, const GURL& validated_url) override;
void BeforeUnloadDialogCancelled() override;
void TitleWasSet(content::NavigationEntry* entry, bool explicit_set) override;
bool OnMessageReceived(const IPC::Message& message) override;
const SkBitmap& bitmap,
content::ReadbackResponse response);
- bool offscreen_;
-
// Whether window has standard frame.
bool has_frame_;
// The browser process app model ID
const char kAppUserModelId[] = "app-user-model-id";
-const char kOffScreenRender[] = "offscreen-render";
-
const char kModifiers[] = "modifiers";
const char kKeyCode[] = "code";
const char kNativeKeyCode[] = "native";
extern const char kAppUserModelId[];
-extern const char kOffScreenRender[];
-
extern const char kModifiers[];
extern const char kKeyCode[];
extern const char kNativeKeyCode[];