| Index: ui/display/win/screen_win.h
|
| diff --git a/ui/display/win/screen_win.h b/ui/display/win/screen_win.h
|
| index 51a221f6f65f190a30688c08d311c71a87284225..23bc57816074d951e652de8c97a5aeec4fb49b12 100644
|
| --- a/ui/display/win/screen_win.h
|
| +++ b/ui/display/win/screen_win.h
|
| @@ -111,6 +111,10 @@ class DISPLAY_EXPORT ScreenWin : public display::Screen {
|
| display::Display GetPrimaryDisplay() const override;
|
| void AddObserver(display::DisplayObserver* observer) override;
|
| void RemoveObserver(display::DisplayObserver* observer) override;
|
| + gfx::Rect ScreenToDIPRectInWindow(
|
| + gfx::NativeView view, const gfx::Rect& screen_rect) const override;
|
| + gfx::Rect DIPToScreenRectInWindow(
|
| + gfx::NativeView view, const gfx::Rect& dip_rect) const override;
|
|
|
| void UpdateFromDisplayInfos(const std::vector<DisplayInfo>& display_infos);
|
|
|
| @@ -138,11 +142,27 @@ class DISPLAY_EXPORT ScreenWin : public display::Screen {
|
| ScreenWinDisplay GetScreenWinDisplayNearestScreenPoint(
|
| const gfx::Point& screen_point) const;
|
|
|
| + // Returns the ScreenWinDisplay closest to or enclosing |dip_point|.
|
| + ScreenWinDisplay GetScreenWinDisplayNearestDIPPoint(
|
| + const gfx::Point& dip_point) const;
|
| +
|
| + // Returns the ScreenWinDisplay closest to or enclosing |dip_rect|.
|
| + ScreenWinDisplay GetScreenWinDisplayNearestDIPRect(
|
| + const gfx::Rect& dip_rect) const;
|
| +
|
| // Returns the ScreenWinDisplay corresponding to the primary monitor.
|
| ScreenWinDisplay GetPrimaryScreenWinDisplay() const;
|
|
|
| ScreenWinDisplay GetScreenWinDisplay(const MONITORINFOEX& monitor_info) const;
|
|
|
| + static float GetScaleFactorForHWND(HWND hwnd);
|
| +
|
| + // Returns the result of calling |getter| with |value| on the global
|
| + // ScreenWin if it exists, otherwise return the default ScreenWinDisplay.
|
| + template <typename Getter, typename GetterType>
|
| + static ScreenWinDisplay GetScreenWinDisplayVia(Getter getter,
|
| + GetterType value);
|
| +
|
| // Helper implementing the DisplayObserver handling.
|
| DisplayChangeNotifier change_notifier_;
|
|
|
|
|