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

Side by Side Diff: third_party/WebKit/Source/core/clipboard/DataTransfer.cpp

Issue 2883353002: Replace ASSERT with DCHECK_LE/GE/GT/LT/NE as appropriate (Closed)
Patch Set: DCHECK in BluetoothCharacteristicProperties.cpp Created 3 years, 7 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 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 362 matching lines...) Expand 10 before | Expand all | Expand 10 after
373 return policy_ == kDataTransferWritable; 373 return policy_ == kDataTransferWritable;
374 } 374 }
375 375
376 bool DataTransfer::CanSetDragImage() const { 376 bool DataTransfer::CanSetDragImage() const {
377 return policy_ == kDataTransferImageWritable || 377 return policy_ == kDataTransferImageWritable ||
378 policy_ == kDataTransferWritable; 378 policy_ == kDataTransferWritable;
379 } 379 }
380 380
381 DragOperation DataTransfer::SourceOperation() const { 381 DragOperation DataTransfer::SourceOperation() const {
382 DragOperation op = ConvertEffectAllowedToDragOperation(effect_allowed_); 382 DragOperation op = ConvertEffectAllowedToDragOperation(effect_allowed_);
383 ASSERT(op != kDragOperationPrivate); 383 DCHECK_NE(op, kDragOperationPrivate);
384 return op; 384 return op;
385 } 385 }
386 386
387 DragOperation DataTransfer::DestinationOperation() const { 387 DragOperation DataTransfer::DestinationOperation() const {
388 DragOperation op = ConvertEffectAllowedToDragOperation(drop_effect_); 388 DragOperation op = ConvertEffectAllowedToDragOperation(drop_effect_);
389 ASSERT(op == kDragOperationCopy || op == kDragOperationNone || 389 ASSERT(op == kDragOperationCopy || op == kDragOperationNone ||
390 op == kDragOperationLink || 390 op == kDragOperationLink ||
391 op == (DragOperation)(kDragOperationGeneric | kDragOperationMove) || 391 op == (DragOperation)(kDragOperationGeneric | kDragOperationMove) ||
392 op == kDragOperationEvery); 392 op == kDragOperationEvery);
393 return op; 393 return op;
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
498 } 498 }
499 } 499 }
500 500
501 DEFINE_TRACE(DataTransfer) { 501 DEFINE_TRACE(DataTransfer) {
502 visitor->Trace(data_object_); 502 visitor->Trace(data_object_);
503 visitor->Trace(drag_image_); 503 visitor->Trace(drag_image_);
504 visitor->Trace(drag_image_element_); 504 visitor->Trace(drag_image_element_);
505 } 505 }
506 506
507 } // namespace blink 507 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698