#include "chrome/browser/ui/bookmarks/bookmark_tab_helper.h"
#include "base/observer_list.h"
#include "build/build_config.h"
#include "build/chromeos_buildflags.h"
#include "chrome/browser/bookmarks/bookmark_model_factory.h"
#include "chrome/browser/defaults.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/search/search.h"
#include "chrome/browser/ui/bookmarks/bookmark_tab_helper_observer.h"
#include "chrome/browser/ui/bookmarks/bookmark_utils.h"
#include "chrome/browser/ui/sad_tab.h"
#include "chrome/browser/ui/tabs/saved_tab_groups/saved_tab_group_utils.h"
#include "chrome/browser/ui/webui/new_tab_page/new_tab_page_ui.h"
#include "chrome/browser/ui/webui/new_tab_page_third_party/new_tab_page_third_party_ui.h"
#include "chrome/browser/ui/webui/ntp/new_tab_ui.h"
#include "components/bookmarks/browser/bookmark_model.h"
#include "components/bookmarks/common/bookmark_pref_names.h"
#include "components/saved_tab_groups/saved_tab_group_model.h"
#include "components/sync_preferences/pref_service_syncable.h"
#include "content/public/browser/navigation_entry.h"
#include "content/public/browser/navigation_handle.h"
#include "content/public/browser/web_contents.h"
BookmarkModel;
BookmarkNode;
namespace {
bool IsNTP(content::WebContents* web_contents) { … }
}
BookmarkTabHelper::~BookmarkTabHelper() { … }
bool BookmarkTabHelper::ShouldShowBookmarkBar() const { … }
void BookmarkTabHelper::AddObserver(BookmarkTabHelperObserver* observer) { … }
void BookmarkTabHelper::RemoveObserver(BookmarkTabHelperObserver* observer) { … }
bool BookmarkTabHelper::HasObserver(BookmarkTabHelperObserver* observer) const { … }
BookmarkTabHelper::BookmarkTabHelper(content::WebContents* web_contents)
: … { … }
void BookmarkTabHelper::UpdateStarredStateForCurrentURL() { … }
void BookmarkTabHelper::BookmarkModelChanged() { … }
void BookmarkTabHelper::BookmarkModelLoaded(bool ids_reassigned) { … }
void BookmarkTabHelper::BookmarkNodeAdded(const BookmarkNode* parent,
size_t index,
bool added_by_user) { … }
void BookmarkTabHelper::BookmarkNodeRemoved(const BookmarkNode* parent,
size_t old_index,
const BookmarkNode* node,
const std::set<GURL>& removed_urls,
const base::Location& location) { … }
void BookmarkTabHelper::BookmarkAllUserNodesRemoved(
const std::set<GURL>& removed_urls,
const base::Location& location) { … }
void BookmarkTabHelper::BookmarkNodeChanged(const BookmarkNode* node) { … }
void BookmarkTabHelper::DidStartNavigation(
content::NavigationHandle* navigation_handle) { … }
void BookmarkTabHelper::DidFinishNavigation(
content::NavigationHandle* navigation_handle) { … }
WEB_CONTENTS_USER_DATA_KEY_IMPL(BookmarkTabHelper);