| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 "app/gtk_dnd_util.h" | 5 #include "app/gtk_dnd_util.h" |
| 6 | 6 |
| 7 #include "base/string_util.h" | |
| 8 #include "base/logging.h" | 7 #include "base/logging.h" |
| 9 #include "base/pickle.h" | 8 #include "base/pickle.h" |
| 9 #include "base/utf_string_conversions.h" |
| 10 #include "googleurl/src/gurl.h" | 10 #include "googleurl/src/gurl.h" |
| 11 | 11 |
| 12 static const int kBitsPerByte = 8; | 12 static const int kBitsPerByte = 8; |
| 13 | 13 |
| 14 // static | 14 // static |
| 15 GdkAtom GtkDndUtil::GetAtomForTarget(int target) { | 15 GdkAtom GtkDndUtil::GetAtomForTarget(int target) { |
| 16 switch (target) { | 16 switch (target) { |
| 17 case CHROME_TAB: | 17 case CHROME_TAB: |
| 18 static GdkAtom tab_atom = gdk_atom_intern( | 18 static GdkAtom tab_atom = gdk_atom_intern( |
| 19 const_cast<char*>("application/x-chrome-tab"), false); | 19 const_cast<char*>("application/x-chrome-tab"), false); |
| (...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 182 | 182 |
| 183 for (size_t i = 0; uris[i] != NULL; ++i) { | 183 for (size_t i = 0; uris[i] != NULL; ++i) { |
| 184 GURL url(uris[i]); | 184 GURL url(uris[i]); |
| 185 if (url.is_valid()) | 185 if (url.is_valid()) |
| 186 urls->push_back(url); | 186 urls->push_back(url); |
| 187 } | 187 } |
| 188 | 188 |
| 189 g_strfreev(uris); | 189 g_strfreev(uris); |
| 190 return true; | 190 return true; |
| 191 } | 191 } |
| OLD | NEW |