summaryrefslogtreecommitdiffstats
path: root/views
diff options
context:
space:
mode:
authorsadrul@chromium.org <sadrul@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-04-14 19:36:33 +0000
committersadrul@chromium.org <sadrul@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-04-14 19:36:33 +0000
commit598080084e438cf5ca26f2a6a02e9153e4586c1d (patch)
treec07fb365c33ef8b2d9c555a37a3d6749548f168b /views
parente90befcc3d54378cb77ff399c4f0be7d4e33c458 (diff)
downloadchromium_src-598080084e438cf5ca26f2a6a02e9153e4586c1d.zip
chromium_src-598080084e438cf5ca26f2a6a02e9153e4586c1d.tar.gz
chromium_src-598080084e438cf5ca26f2a6a02e9153e4586c1d.tar.bz2
Some style changes (for readability).
BUG=none TEST=none Review URL: http://codereview.chromium.org/6675048 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@81623 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'views')
-rw-r--r--views/touchui/touch_factory.cc4
-rw-r--r--views/touchui/touch_factory.h12
-rw-r--r--views/view.h3
3 files changed, 11 insertions, 8 deletions
diff --git a/views/touchui/touch_factory.cc b/views/touchui/touch_factory.cc
index aeb1de2..c363492 100644
--- a/views/touchui/touch_factory.cc
+++ b/views/touchui/touch_factory.cc
@@ -55,7 +55,7 @@ TouchFactory::TouchFactory()
}
}
if (devlist)
- XFreeDeviceList(devlist);
+ XFreeDeviceList(devlist);
}
TouchFactory::~TouchFactory() {
@@ -77,7 +77,7 @@ void TouchFactory::SetTouchDeviceList(
}
}
-bool TouchFactory::IsTouchDevice(unsigned deviceid) {
+bool TouchFactory::IsTouchDevice(unsigned deviceid) const {
return deviceid < touch_device_lookup_.size() ?
touch_device_lookup_[deviceid] : false;
}
diff --git a/views/touchui/touch_factory.h b/views/touchui/touch_factory.h
index acd02f3..143a932 100644
--- a/views/touchui/touch_factory.h
+++ b/views/touchui/touch_factory.h
@@ -24,29 +24,29 @@ class TouchFactory {
// Returns the TouchFactory singleton.
static TouchFactory* GetInstance();
- // Keep a list of touch devices so that it is possible to determine if a
+ // Keeps a list of touch devices so that it is possible to determine if a
// pointer event is a touch-event or a mouse-event. The list is reset each
// time this is called.
void SetTouchDeviceList(const std::vector<unsigned int>& devices);
// Is the device a touch-device?
- bool IsTouchDevice(unsigned int deviceid);
+ bool IsTouchDevice(unsigned int deviceid) const;
- // Grab the touch devices for the specified window on the specified display.
+ // Grabs the touch devices for the specified window on the specified display.
// Returns if grab was successful for all touch devices.
bool GrabTouchDevices(Display* display, ::Window window);
- // Ungrab the touch devices. Returns if ungrab was successful for all touch
+ // Ungrabs the touch devices. Returns if ungrab was successful for all touch
// devices.
bool UngrabTouchDevices(Display* display);
- // Update the root window to show (or hide) the cursor. Also indicate whether
+ // Updates the root window to show (or hide) the cursor. Also indicate whether
// the timer should be started to automatically hide the cursor after a
// certain duration of inactivity (i.e. it is ignored if |show| is false).
void SetCursorVisible(bool show, bool start_timer);
// Whether the cursor is currently visible or not.
- bool is_cursor_visible() {
+ bool is_cursor_visible() const {
return is_cursor_visible_;
}
diff --git a/views/view.h b/views/view.h
index 6513003..5f98564 100644
--- a/views/view.h
+++ b/views/view.h
@@ -136,6 +136,9 @@ class DragController {
// It is up to the subclass to implement Painting and storage of subclass -
// specific properties and functionality.
//
+// Unless otherwise documented, views is not thread safe and should only be
+// accessed from the main thread.
+//
/////////////////////////////////////////////////////////////////////////////
class View : public AcceleratorTarget {
public: