| 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/extensions/api/bookmark_manager_private/bookmark_manage
r_private_api.h" | 5 #include "chrome/browser/extensions/api/bookmark_manager_private/bookmark_manage
r_private_api.h" |
| 6 | 6 |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/json/json_writer.h" | 9 #include "base/json/json_writer.h" |
| 10 #include "base/prefs/pref_service.h" | 10 #include "base/prefs/pref_service.h" |
| (...skipping 443 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 454 CHECK(web_ui); | 454 CHECK(web_ui); |
| 455 BookmarkManagerPrivateEventRouter* router = | 455 BookmarkManagerPrivateEventRouter* router = |
| 456 web_ui->bookmark_manager_private_event_router(); | 456 web_ui->bookmark_manager_private_event_router(); |
| 457 | 457 |
| 458 DCHECK(router); | 458 DCHECK(router); |
| 459 const BookmarkNodeData* drag_data = router->GetBookmarkNodeData(); | 459 const BookmarkNodeData* drag_data = router->GetBookmarkNodeData(); |
| 460 if (drag_data == NULL) { | 460 if (drag_data == NULL) { |
| 461 NOTREACHED() <<"Somehow we're dropping null bookmark data"; | 461 NOTREACHED() <<"Somehow we're dropping null bookmark data"; |
| 462 return false; | 462 return false; |
| 463 } | 463 } |
| 464 bookmark_utils::PerformBookmarkDrop(profile(), | 464 chrome::DropBookmarks(profile(), *drag_data, drop_parent, drop_index); |
| 465 *drag_data, | |
| 466 drop_parent, drop_index); | |
| 467 | 465 |
| 468 router->ClearBookmarkNodeData(); | 466 router->ClearBookmarkNodeData(); |
| 469 return true; | 467 return true; |
| 470 } else { | 468 } else { |
| 471 NOTREACHED(); | 469 NOTREACHED(); |
| 472 return false; | 470 return false; |
| 473 } | 471 } |
| 474 } | 472 } |
| 475 | 473 |
| 476 bool BookmarkManagerPrivateGetSubtreeFunction::RunImpl() { | 474 bool BookmarkManagerPrivateGetSubtreeFunction::RunImpl() { |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 521 #if defined(OS_WIN) | 519 #if defined(OS_WIN) |
| 522 if (win8::IsSingleWindowMetroMode()) | 520 if (win8::IsSingleWindowMetroMode()) |
| 523 can_open_new_windows = false; | 521 can_open_new_windows = false; |
| 524 #endif // OS_WIN | 522 #endif // OS_WIN |
| 525 | 523 |
| 526 SetResult(new base::FundamentalValue(can_open_new_windows)); | 524 SetResult(new base::FundamentalValue(can_open_new_windows)); |
| 527 return true; | 525 return true; |
| 528 } | 526 } |
| 529 | 527 |
| 530 } // namespace extensions | 528 } // namespace extensions |
| OLD | NEW |