Fix crash that happens when the PDF viewer is refreshed.
The root cause is the PdfViewerHandler instanceis destroyed but not removed from the list of observer in WebContentsZoomController
This commit is contained in:
parent
44f91e12e1
commit
9f3cfa2dbd
2 changed files with 19 additions and 8 deletions
|
@ -45,7 +45,8 @@ class PdfViewerHandler : public content::WebUIMessageHandler,
|
|||
void Reload(const base::ListValue* args);
|
||||
void OnZoomLevelChanged(content::WebContents* web_contents, double level,
|
||||
bool is_temporary);
|
||||
|
||||
void AddObserver();
|
||||
void RemoveObserver();
|
||||
std::unique_ptr<base::Value> initialize_callback_id_;
|
||||
content::StreamInfo* stream_;
|
||||
std::string original_url_;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue