| OLD | NEW |
| 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 "chrome/browser/ui/views/extensions/browser_action_drag_data.h" | 5 #include "chrome/browser/ui/views/extensions/browser_action_drag_data.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "base/pickle.h" | 8 #include "base/pickle.h" |
| 9 #include "base/string_util.h" | 9 #include "base/strings/string_util.h" |
| 10 #include "chrome/browser/profiles/profile.h" | 10 #include "chrome/browser/profiles/profile.h" |
| 11 #include "ui/base/clipboard/clipboard.h" | 11 #include "ui/base/clipboard/clipboard.h" |
| 12 | 12 |
| 13 const char* BrowserActionDragData::kClipboardFormatString = | 13 const char* BrowserActionDragData::kClipboardFormatString = |
| 14 "chromium/x-browser-actions"; | 14 "chromium/x-browser-actions"; |
| 15 | 15 |
| 16 BrowserActionDragData::BrowserActionDragData() | 16 BrowserActionDragData::BrowserActionDragData() |
| 17 : profile_(NULL), index_(-1) { | 17 : profile_(NULL), index_(-1) { |
| 18 } | 18 } |
| 19 | 19 |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 79 if (!pickle->ReadString(&data_iterator, &id_)) | 79 if (!pickle->ReadString(&data_iterator, &id_)) |
| 80 return false; | 80 return false; |
| 81 | 81 |
| 82 uint64 index; | 82 uint64 index; |
| 83 if (!pickle->ReadUInt64(&data_iterator, &index)) | 83 if (!pickle->ReadUInt64(&data_iterator, &index)) |
| 84 return false; | 84 return false; |
| 85 index_ = static_cast<size_t>(index); | 85 index_ = static_cast<size_t>(index); |
| 86 | 86 |
| 87 return true; | 87 return true; |
| 88 } | 88 } |
| OLD | NEW |