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

Side by Side Diff: ui/base/cocoa/events_mac.mm

Issue 9599005: Coverity: Fix a pass-by-value. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | ui/base/events.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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 <Cocoa/Cocoa.h> 5 #include <Cocoa/Cocoa.h>
6 6
7 #include "ui/base/events.h" 7 #include "ui/base/events.h"
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/time.h" 10 #include "base/time.h"
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 // Touch is currently unsupported. 172 // Touch is currently unsupported.
173 return 0.0; 173 return 0.0;
174 } 174 }
175 175
176 bool GetScrollOffsets(const base::NativeEvent& native_event, 176 bool GetScrollOffsets(const base::NativeEvent& native_event,
177 float* x_offset, 177 float* x_offset,
178 float* y_offset) { 178 float* y_offset) {
179 return false; 179 return false;
180 } 180 }
181 181
182 bool IsNoopEvent(base::NativeEvent event) { 182 bool IsNoopEvent(const base::NativeEvent& event) {
183 return ([event type] == NSApplicationDefined && [event subtype] == 0); 183 return ([event type] == NSApplicationDefined && [event subtype] == 0);
184 } 184 }
185 185
186 base::NativeEvent CreateNoopEvent() { 186 base::NativeEvent CreateNoopEvent() {
187 return [NSEvent otherEventWithType:NSApplicationDefined 187 return [NSEvent otherEventWithType:NSApplicationDefined
188 location:NSZeroPoint 188 location:NSZeroPoint
189 modifierFlags:0 189 modifierFlags:0
190 timestamp:[NSDate timeIntervalSinceReferenceDate] 190 timestamp:[NSDate timeIntervalSinceReferenceDate]
191 windowNumber:0 191 windowNumber:0
192 context:nil 192 context:nil
193 subtype:0 193 subtype:0
194 data1:0 194 data1:0
195 data2:0]; 195 data2:0];
196 } 196 }
197 197
198 } // namespace ui 198 } // namespace ui
OLDNEW
« no previous file with comments | « no previous file | ui/base/events.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698