Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(779)

Side by Side Diff: ui/display/chromeos/x11/native_display_delegate_x11.cc

Issue 853073002: Update {virtual,override,final} to follow C++11 style in ui. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/display/chromeos/x11/native_display_delegate_x11.h" 5 #include "ui/display/chromeos/x11/native_display_delegate_x11.h"
6 6
7 #include <X11/Xatom.h> 7 #include <X11/Xatom.h>
8 #include <X11/Xlib.h> 8 #include <X11/Xlib.h>
9 #include <X11/extensions/dpms.h> 9 #include <X11/extensions/dpms.h>
10 #include <X11/extensions/Xrandr.h> 10 #include <X11/extensions/Xrandr.h>
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 72
73 } // namespace 73 } // namespace
74 74
75 //////////////////////////////////////////////////////////////////////////////// 75 ////////////////////////////////////////////////////////////////////////////////
76 // NativeDisplayDelegateX11::HelperDelegateX11 76 // NativeDisplayDelegateX11::HelperDelegateX11
77 77
78 class NativeDisplayDelegateX11::HelperDelegateX11 78 class NativeDisplayDelegateX11::HelperDelegateX11
79 : public NativeDisplayDelegateX11::HelperDelegate { 79 : public NativeDisplayDelegateX11::HelperDelegate {
80 public: 80 public:
81 HelperDelegateX11(NativeDisplayDelegateX11* delegate) : delegate_(delegate) {} 81 HelperDelegateX11(NativeDisplayDelegateX11* delegate) : delegate_(delegate) {}
82 virtual ~HelperDelegateX11() {} 82 ~HelperDelegateX11() override {}
83 83
84 // NativeDisplayDelegateX11::HelperDelegate overrides: 84 // NativeDisplayDelegateX11::HelperDelegate overrides:
85 virtual void UpdateXRandRConfiguration(const base::NativeEvent& event) 85 void UpdateXRandRConfiguration(const base::NativeEvent& event) override {
86 override {
87 XRRUpdateConfiguration(event); 86 XRRUpdateConfiguration(event);
88 } 87 }
89 virtual const std::vector<DisplaySnapshot*>& GetCachedDisplays() const 88 const std::vector<DisplaySnapshot*>& GetCachedDisplays() const override {
90 override {
91 return delegate_->cached_outputs_.get(); 89 return delegate_->cached_outputs_.get();
92 } 90 }
93 virtual void NotifyDisplayObservers() override { 91 void NotifyDisplayObservers() override {
94 FOR_EACH_OBSERVER( 92 FOR_EACH_OBSERVER(
95 NativeDisplayObserver, delegate_->observers_, OnConfigurationChanged()); 93 NativeDisplayObserver, delegate_->observers_, OnConfigurationChanged());
96 } 94 }
97 95
98 private: 96 private:
99 NativeDisplayDelegateX11* delegate_; 97 NativeDisplayDelegateX11* delegate_;
100 98
101 DISALLOW_COPY_AND_ASSIGN(HelperDelegateX11); 99 DISALLOW_COPY_AND_ASSIGN(HelperDelegateX11);
102 }; 100 };
103 101
(...skipping 538 matching lines...) Expand 10 before | Expand all | Expand 10 after
642 XSetForeground(display_, gc, color.pixel); 640 XSetForeground(display_, gc, color.pixel);
643 XSetFillStyle(display_, gc, FillSolid); 641 XSetFillStyle(display_, gc, FillSolid);
644 int width = DisplayWidth(display_, DefaultScreen(display_)); 642 int width = DisplayWidth(display_, DefaultScreen(display_));
645 int height = DisplayHeight(display_, DefaultScreen(display_)); 643 int height = DisplayHeight(display_, DefaultScreen(display_));
646 XFillRectangle(display_, window_, gc, 0, 0, width, height); 644 XFillRectangle(display_, window_, gc, 0, 0, width, height);
647 XFreeGC(display_, gc); 645 XFreeGC(display_, gc);
648 XFreeColors(display_, colormap, &color.pixel, 1, 0); 646 XFreeColors(display_, colormap, &color.pixel, 1, 0);
649 } 647 }
650 648
651 } // namespace ui 649 } // namespace ui
OLDNEW
« no previous file with comments | « ui/display/chromeos/x11/native_display_delegate_x11.h ('k') | ui/display/chromeos/x11/native_display_event_dispatcher_x11.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698