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

Side by Side Diff: ui/views/linux_ui/linux_ui.h

Issue 1868363002: Replace scoped_ptr with std::unique_ptr in //ui (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@scopedptrcc
Patch Set: scopedptrui: rebase-make_scoped_ptr Created 4 years, 8 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
« no previous file with comments | « ui/views/layout/box_layout_unittest.cc ('k') | ui/views/mouse_watcher.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #ifndef UI_VIEWS_LINUX_UI_LINUX_UI_H_ 5 #ifndef UI_VIEWS_LINUX_UI_LINUX_UI_H_
6 #define UI_VIEWS_LINUX_UI_LINUX_UI_H_ 6 #define UI_VIEWS_LINUX_UI_LINUX_UI_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 111
112 // Sets visual properties in the desktop environment related to download 112 // Sets visual properties in the desktop environment related to download
113 // progress, if available. 113 // progress, if available.
114 virtual void SetDownloadCount(int count) const = 0; 114 virtual void SetDownloadCount(int count) const = 0;
115 virtual void SetProgressFraction(float percentage) const = 0; 115 virtual void SetProgressFraction(float percentage) const = 0;
116 116
117 // Checks for platform support for status icons. 117 // Checks for platform support for status icons.
118 virtual bool IsStatusIconSupported() const = 0; 118 virtual bool IsStatusIconSupported() const = 0;
119 119
120 // Create a native status icon. 120 // Create a native status icon.
121 virtual scoped_ptr<StatusIconLinux> CreateLinuxStatusIcon( 121 virtual std::unique_ptr<StatusIconLinux> CreateLinuxStatusIcon(
122 const gfx::ImageSkia& image, 122 const gfx::ImageSkia& image,
123 const base::string16& tool_tip) const = 0; 123 const base::string16& tool_tip) const = 0;
124 124
125 // Returns the icon for a given content type from the icon theme. 125 // Returns the icon for a given content type from the icon theme.
126 // TODO(davidben): Add an observer for the theme changing, so we can drop the 126 // TODO(davidben): Add an observer for the theme changing, so we can drop the
127 // caches. 127 // caches.
128 virtual gfx::Image GetIconForContentType( 128 virtual gfx::Image GetIconForContentType(
129 const std::string& content_type, int size) const = 0; 129 const std::string& content_type, int size) const = 0;
130 130
131 // Builds a Border which paints the native button style. 131 // Builds a Border which paints the native button style.
132 virtual scoped_ptr<Border> CreateNativeBorder( 132 virtual std::unique_ptr<Border> CreateNativeBorder(
133 views::LabelButton* owning_button, 133 views::LabelButton* owning_button,
134 scoped_ptr<views::LabelButtonBorder> border) = 0; 134 std::unique_ptr<views::LabelButtonBorder> border) = 0;
135 135
136 // Notifies the observer about changes about how window buttons should be 136 // Notifies the observer about changes about how window buttons should be
137 // laid out. If the order is anything other than the default min,max,close on 137 // laid out. If the order is anything other than the default min,max,close on
138 // the right, will immediately send a button change event to the observer. 138 // the right, will immediately send a button change event to the observer.
139 virtual void AddWindowButtonOrderObserver( 139 virtual void AddWindowButtonOrderObserver(
140 WindowButtonOrderObserver* observer) = 0; 140 WindowButtonOrderObserver* observer) = 0;
141 141
142 // Removes the observer from the LinuxUI's list. 142 // Removes the observer from the LinuxUI's list.
143 virtual void RemoveWindowButtonOrderObserver( 143 virtual void RemoveWindowButtonOrderObserver(
144 WindowButtonOrderObserver* observer) = 0; 144 WindowButtonOrderObserver* observer) = 0;
(...skipping 15 matching lines...) Expand all
160 // recalculated. 160 // recalculated.
161 virtual void UpdateDeviceScaleFactor(float device_scale_factor) = 0; 161 virtual void UpdateDeviceScaleFactor(float device_scale_factor) = 0;
162 162
163 // Determines the device scale factor of the primary screen. 163 // Determines the device scale factor of the primary screen.
164 virtual float GetDeviceScaleFactor() const = 0; 164 virtual float GetDeviceScaleFactor() const = 0;
165 }; 165 };
166 166
167 } // namespace views 167 } // namespace views
168 168
169 #endif // UI_VIEWS_LINUX_UI_LINUX_UI_H_ 169 #endif // UI_VIEWS_LINUX_UI_LINUX_UI_H_
OLDNEW
« no previous file with comments | « ui/views/layout/box_layout_unittest.cc ('k') | ui/views/mouse_watcher.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698