electron/shell/browser/extended_web_contents_observer.h
trop[bot] a7066af0f9
fix: modernize-use-equals-default warnings (#44944)
fix: use '= default' to define a trivial destructor [modernize-use-equals-default]

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2024-12-03 21:19:32 -06:00

34 lines
988 B
C++

// Copyright (c) 2020 Microsoft, Inc.
// Use of this source code is governed by the MIT license that can be
// found in the LICENSE file.
#ifndef ELECTRON_SHELL_BROWSER_EXTENDED_WEB_CONTENTS_OBSERVER_H_
#define ELECTRON_SHELL_BROWSER_EXTENDED_WEB_CONTENTS_OBSERVER_H_
#include <string>
#include "base/observer_list_types.h"
namespace gfx {
class Rect;
}
namespace electron {
// Certain events are only in WebContentsDelegate, so we provide our own
// Observer to dispatch those events.
class ExtendedWebContentsObserver : public base::CheckedObserver {
public:
virtual void OnSetContentBounds(const gfx::Rect& rect) {}
virtual void OnActivateContents() {}
virtual void OnPageTitleUpdated(const std::u16string& title,
bool explicit_set) {}
virtual void OnDevToolsResized() {}
protected:
~ExtendedWebContentsObserver() override = default;
};
} // namespace electron
#endif // ELECTRON_SHELL_BROWSER_EXTENDED_WEB_CONTENTS_OBSERVER_H_