diff options
Diffstat (limited to 'www/chromium-uc/patches/extra/ungoogled-chromium/add-flag-for-tabsearch-button.patch')
| -rw-r--r-- | www/chromium-uc/patches/extra/ungoogled-chromium/add-flag-for-tabsearch-button.patch | 43 |
1 files changed, 0 insertions, 43 deletions
diff --git a/www/chromium-uc/patches/extra/ungoogled-chromium/add-flag-for-tabsearch-button.patch b/www/chromium-uc/patches/extra/ungoogled-chromium/add-flag-for-tabsearch-button.patch deleted file mode 100644 index 317602c..0000000 --- a/www/chromium-uc/patches/extra/ungoogled-chromium/add-flag-for-tabsearch-button.patch +++ /dev/null | |||
| @@ -1,43 +0,0 @@ | |||
| 1 | --- chrome/browser/ui/browser_command_controller.cc.orig | ||
| 2 | +++ chrome/browser/ui/browser_command_controller.cc | ||
| 3 | @@ -1139,7 +1139,8 @@ void BrowserCommandController::InitComma | ||
| 4 | command_updater_.UpdateCommandEnabled(IDC_WINDOW_CLOSE_OTHER_TABS, | ||
| 5 | normal_window); | ||
| 6 | |||
| 7 | - const bool enable_tab_search_commands = browser_->is_type_normal(); | ||
| 8 | + const bool enable_tab_search_commands = browser_->is_type_normal() && | ||
| 9 | + !base::CommandLine::ForCurrentProcess()->HasSwitch("remove-tabsearch-button"); | ||
| 10 | command_updater_.UpdateCommandEnabled(IDC_TAB_SEARCH, | ||
| 11 | enable_tab_search_commands); | ||
| 12 | command_updater_.UpdateCommandEnabled(IDC_TAB_SEARCH_CLOSE, | ||
| 13 | --- chrome/browser/ui/views/frame/tab_strip_region_view.cc.orig | ||
| 14 | +++ chrome/browser/ui/views/frame/tab_strip_region_view.cc | ||
| 15 | @@ -5,6 +5,7 @@ | ||
| 16 | #include "chrome/browser/ui/views/frame/tab_strip_region_view.h" | ||
| 17 | |||
| 18 | #include "base/bind.h" | ||
| 19 | +#include "base/command_line.h" | ||
| 20 | #include "base/strings/utf_string_conversions.h" | ||
| 21 | #include "build/build_config.h" | ||
| 22 | #include "chrome/browser/themes/theme_properties.h" | ||
| 23 | @@ -132,7 +133,8 @@ TabStripRegionView::TabStripRegionView(s | ||
| 24 | return; | ||
| 25 | #endif | ||
| 26 | const Browser* browser = tab_strip_->controller()->GetBrowser(); | ||
| 27 | - if (browser && browser->is_type_normal()) { | ||
| 28 | + if (browser && browser->is_type_normal() && | ||
| 29 | + !base::CommandLine::ForCurrentProcess()->HasSwitch("remove-tabsearch-button")) { | ||
| 30 | auto tab_search_button = std::make_unique<TabSearchButton>(tab_strip_); | ||
| 31 | tab_search_button->SetTooltipText( | ||
| 32 | l10n_util::GetStringUTF16(IDS_TOOLTIP_TAB_SEARCH)); | ||
| 33 | --- chrome/browser/ungoogled_flag_entries.h.orig | ||
| 34 | +++ chrome/browser/ungoogled_flag_entries.h | ||
| 35 | @@ -68,4 +68,8 @@ | ||
| 36 | "Clear data on exit", | ||
| 37 | "Clears all browsing data on exit. ungoogled-chromium flag", | ||
| 38 | kOsDesktop, FEATURE_VALUE_TYPE(browsing_data::features::kClearDataOnExit)}, | ||
| 39 | + {"remove-tabsearch-button", | ||
| 40 | + "Remove Tabsearch Button", | ||
| 41 | + "Removes the tabsearch button from the tabstrip. ungoogled-chromium flag", | ||
| 42 | + kOsDesktop, SINGLE_VALUE_TYPE("remove-tabsearch-button")}, | ||
| 43 | #endif // CHROME_BROWSER_UNGOOGLED_FLAG_ENTRIES_H_ | ||
