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

Unified Diff: chrome/browser/ui/views/bookmarks/bookmark_drag_drop.h

Issue 12475013: bookmarks: Extract PerformBookmarkDrop() function out of bookmark_utils.h (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: chromeos fixes Created 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/bookmarks/bookmark_drag_drop.h
diff --git a/chrome/browser/ui/views/bookmarks/bookmark_drag_drop.h b/chrome/browser/ui/views/bookmarks/bookmark_drag_drop.h
deleted file mode 100644
index ea91263557dfb47ee2350ee4db24faf3efd914c7..0000000000000000000000000000000000000000
--- a/chrome/browser/ui/views/bookmarks/bookmark_drag_drop.h
+++ /dev/null
@@ -1,52 +0,0 @@
-// Copyright 2013 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef CHROME_BROWSER_UI_VIEWS_BOOKMARKS_BOOKMARK_DRAG_DROP_H_
-#define CHROME_BROWSER_UI_VIEWS_BOOKMARKS_BOOKMARK_DRAG_DROP_H_
-
-class BookmarkNode;
-struct BookmarkNodeData;
-class Profile;
-
-namespace content {
-class BrowserContext;
-}
-
-namespace ui {
-class DropTargetEvent;
-}
-
-namespace chrome {
-
-// Returns the drag operations for the specified node.
-int GetBookmarkDragOperation(content::BrowserContext* browser_context,
- const BookmarkNode* node);
-
-// Calculates the drop operation given |source_operations| and the ideal
-// set of drop operations (|operations|). This prefers the following ordering:
-// COPY, LINK then MOVE.
-int GetPreferredBookmarkDropOperation(int source_operations, int operations);
-
-// Returns the preferred drop operation on a bookmark menu/bar.
-// |parent| is the parent node the drop is to occur on and |index| the index the
-// drop is over.
-int GetBookmarkDropOperation(Profile* profile,
- const ui::DropTargetEvent& event,
- const BookmarkNodeData& data,
- const BookmarkNode* parent,
- int index);
-
-// Returns true if the bookmark data can be dropped on |drop_parent| at
-// |index|. A drop from a separate profile is always allowed, where as
-// a drop from the same profile is only allowed if none of the nodes in
-// |data| are an ancestor of |drop_parent| and one of the nodes isn't already
-// a child of |drop_parent| at |index|.
-bool IsValidBookmarkDropLocation(Profile* profile,
- const BookmarkNodeData& data,
- const BookmarkNode* drop_parent,
- int index);
-
-} // namespace chrome
-
-#endif // CHROME_BROWSER_UI_VIEWS_BOOKMARKS_BOOKMARK_DRAG_DROP_H_
« no previous file with comments | « chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc ('k') | chrome/browser/ui/views/bookmarks/bookmark_drag_drop.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698