Cleanup dead code which is no longer needed or used. 73/305673/6
authorManjeet <manjeet.1@partner.samsung.com>
Tue, 6 Feb 2024 06:10:48 +0000 (11:40 +0530)
committerBot Blink <blinkbot@samsung.com>
Tue, 20 Feb 2024 11:21:41 +0000 (11:21 +0000)
Reference:
https://review.tizen.org/gerrit/#/c/290702

Change-Id: I033b9f6179f866d4ea07e9270fcd12c3de3ef411
Signed-off-by: Manjeet <manjeet.1@partner.samsung.com>
14 files changed:
chrome/test/chromedriver/BUILD.gn
content/shell/BUILD.gn
tizen_src/chromium_impl/chrome/chrome_tests_efl.gni [deleted file]
tizen_src/chromium_impl/content/content_efl.gni
tizen_src/chromium_impl/content/shell/browser/shell_efl.cc [deleted file]
tizen_src/chromium_impl/content/shell/browser/shell_main_efl.cc [deleted file]
tizen_src/chromium_impl/content/shell/browser/shell_platform_delegate_efl.cc [deleted file]
tizen_src/chromium_impl/content/shell/browser/shell_web_contents_view_delegate_efl.cc [deleted file]
tizen_src/chromium_impl/content/shell/shell_efl.gni [deleted file]
tizen_src/chromium_impl/device/battery/battery_status_manager_tizen.cc [deleted file]
tizen_src/chromium_impl/device/battery/battery_status_manager_tizen.h [deleted file]
tizen_src/chromium_impl/device/battery_tizen.gni [deleted file]
tizen_src/ewk/efl_integration/eweb_view.cc
tizen_src/ewk/efl_integration/eweb_view.h

index ab21244..0874c54 100644 (file)
@@ -12,10 +12,6 @@ import("//build/util/lastchange.gni")
 import("//testing/test.gni")
 import("//third_party/ffmpeg/ffmpeg_options.gni")
 
-if (use_efl) {
-  import("//tizen_src/chromium_impl/chrome/chrome_tests_efl.gni")
-}
-
 declare_args() {
   # Make macOS request permissions for the chrome binary instead of its parent
   # process (usually the Terminmal.app).
@@ -401,10 +397,6 @@ source_set("lib") {
     deps += [ ":buildflags" ]
     frameworks = [ "Carbon.framework" ]
   }
-
-  if (use_efl) {
-    sources -= external_exclude_chrome_test_driver_sources
-  }
 }
 
 if (is_linux) {
index bb0d245..84c03ae 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 2014 The Chromium Authors
+# Copyright 2014 The Chromium Author
 # Use of this source code is governed by a BSD-style license that can be
 # found in the LICENSE file.
 
@@ -34,9 +34,6 @@ if (is_android) {
 } else if (is_ios) {
   import("//build/config/ios/config.gni")
 }
-if (use_efl && !use_aura) {
-  import("//tizen_src/chromium_impl/content/shell/shell_efl.gni")
-}
 
 # TODO(crbug.com/1336055, spang): Investigate using shell_views with cast builds as
 # true.
@@ -250,9 +247,6 @@ static_library("content_shell_lib") {
     ":content_shell_lib_warnings",
     "//build/config:precompiled_headers",
   ]
-  if (use_efl && !use_aura) {
-    configs += external_content_shell_efl_configs
-  }
 
   defines = [
     "CONTENT_SHELL_VERSION=\"$content_shell_version\"",
@@ -351,9 +345,6 @@ static_library("content_shell_lib") {
       "//components/crash/core/app",
     ]
   }
-  if (use_efl && !use_aura) {
-    deps += external_content_shell_efl_deps
-  }
 
   if (enable_plugins) {
     sources += [
@@ -462,10 +453,6 @@ static_library("content_shell_lib") {
   if (use_ozone) {
     deps += [ "//ui/ozone" ]
   }
-
-  if (use_efl && !use_aura) {
-    sources += external_content_shell_lib_efl_sources
-  }
 }
 
 grit("content_shell_resources_grit") {
@@ -708,14 +695,6 @@ if (is_android) {
       # Set rpath to find our own libfreetype even in a non-component build.
       configs += [ "//build/config/gcc:rpath_for_built_shared_libraries" ]
     }
-
-    if (use_efl && !use_aura) {
-      deps += external_content_shell_efl_deps
-      configs += external_content_shell_efl_configs
-
-      sources += external_content_shell_efl_sources
-      sources -= external_exclude_content_shell_efl_sources
-    }
   }
 
   if (is_fuchsia) {
diff --git a/tizen_src/chromium_impl/chrome/chrome_tests_efl.gni b/tizen_src/chromium_impl/chrome/chrome_tests_efl.gni
deleted file mode 100644 (file)
index c21cc29..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-# Copyright (c) 2015 Samsung Electronics. All rights reserved.
-# Use of this source code is governed by a BSD-style license that can be
-# found in the LICENSE file.
-
-import("//tizen_src/build/config/tizen_features.gni")
-
-# For //chrome/test/chromedriver:lib target
-# It seems that keycode_text_conversion_win.cc is not used in gn files so no need to exclude it.
-external_exclude_chrome_test_driver_sources = []  #[ "test/chromedriver/keycode_text_conversion_win.cc" ]
-if (use_wayland) {
-  #external_exclude_chrome_test_driver_sources += [ "test/chromedriver/keycode_text_conversion_x.cc" ]
-}
index 6294320..718dc7c 100644 (file)
@@ -60,17 +60,6 @@ external_content_gpu_configs = [
   "//tizen_src/build:libevas",
 ]
 
-external_content_shell_configs = [
-  "//tizen_src/build:evas",
-  "//tizen_src/build:libevas",
-  "//tizen_src/build:ecore-evas",
-  "//tizen_src/build:libecore-evas",
-  "//tizen_src/build:elementary",
-  "//tizen_src/build:libelementary",
-]
-
-external_content_shell_deps = [ "//tizen_src/chromium_impl/efl:efl-init" ]
-
 if (is_tizen) {
   external_content_browser_configs += [
     "//tizen_src/build:vconf",
@@ -85,11 +74,7 @@ if (!use_wayland) {
   external_content_browser_configs += [ "//tizen_src/build:libx11" ]
   external_content_browser_extra_configs += [ "//tizen_src/build:ecore-x" ]
   external_content_browser_extra_configs += [ "//tizen_src/build:libecore-x" ]
-  external_content_shell_configs += [ "//tizen_src/build:ecore-x" ]
-  external_content_shell_configs += [ "//tizen_src/build:libecore-x" ]
 } else {
   external_content_common_configs += [ "//tizen_src/build:ecore-wayland" ]
   external_content_common_configs += [ "//tizen_src/build:libecore-wayland" ]
-  external_content_shell_configs += [ "//tizen_src/build:ecore-wayland" ]
-  external_content_shell_configs += [ "//tizen_src/build:libecore-wayland" ]
 }
diff --git a/tizen_src/chromium_impl/content/shell/browser/shell_efl.cc b/tizen_src/chromium_impl/content/shell/browser/shell_efl.cc
deleted file mode 100644 (file)
index b3cf1f7..0000000
+++ /dev/null
@@ -1,233 +0,0 @@
-// Copyright 2014 Samsung Electronics. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "content/shell/browser/shell.h"
-
-#include <Evas.h>
-#include <Ecore_Evas.h>
-#include <Elementary.h>
-
-#include "base/command_line.h"
-#include "base/strings/utf_string_conversions.h"
-#include "cc/base/switches.h"
-#include "components/js_dialogs_efl/javascript_dialog_manager_efl.h"
-#include "content/public/browser/render_view_host.h"
-#include "content/public/browser/web_contents.h"
-#include "content/public/common/content_switches.h"
-#include "content/shell/common/shell_switches.h"
-#include "content/web_test/browser/web_test_javascript_dialog_manager.h"
-#include "efl/window_factory.h"
-#include "ui/gl/gl_switches.h"
-
-namespace content {
-
-class Shell::Impl {
- public:
-  Impl(Shell* shell, Evas_Object* window)
-      : url_bar_(NULL),
-        refresh_btn_(NULL),
-        stop_btn_(NULL),
-        back_btn_(NULL),
-        forward_btn_(NULL),
-        shell_(shell) {
-    Evas_Object* box = elm_box_add(window);
-    evas_object_size_hint_align_set(box, EVAS_HINT_FILL, EVAS_HINT_FILL);
-    evas_object_size_hint_weight_set(box, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
-    elm_win_resize_object_add(window, box);
-    evas_object_show(box);
-
-    if (!switches::IsRunWebTestsSwitchPresent())
-      CreateURLBar(box);
-
-#if !defined(USE_AURA)
-    Evas_Object* view =
-        static_cast<Evas_Object*>(shell->web_contents()->GetNativeView());
-    evas_object_size_hint_align_set(view, EVAS_HINT_FILL, EVAS_HINT_FILL);
-    evas_object_size_hint_weight_set(view, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
-    elm_box_pack_end(box, view);
-#endif
-  }
-
-  void CreateURLBar(Evas_Object* box) {
-    Evas_Object* wrapper = elm_box_add(box);
-    elm_box_horizontal_set(wrapper, EINA_TRUE);
-    evas_object_size_hint_align_set(wrapper, EVAS_HINT_FILL, EVAS_HINT_FILL);
-    evas_object_size_hint_weight_set(wrapper, EVAS_HINT_EXPAND, 0.0f);
-    evas_object_show(wrapper);
-
-    Evas_Object* button_box = elm_box_add(wrapper);
-    elm_box_horizontal_set(button_box, EINA_TRUE);
-
-    Evas_Object* new_window_button = AddButton(button_box, "file", OnNewWindow);
-    back_btn_ = AddButton(button_box, "arrow_left", OnBack);
-    forward_btn_ = AddButton(button_box, "arrow_right", OnForward);
-    refresh_btn_ = AddButton(button_box, "refresh", OnRefresh);
-    stop_btn_ = AddButton(button_box, "close", OnStop);
-
-#if !BUILDFLAG(IS_TIZEN)
-    elm_object_text_set(new_window_button, "New Window");
-    elm_object_text_set(back_btn_, "Back");
-    elm_object_text_set(forward_btn_, "Forward");
-    elm_object_text_set(refresh_btn_, "Refresh");
-    elm_object_text_set(stop_btn_, "Stop");
-#else
-    (void)new_window_button;
-#endif
-
-    evas_object_show(button_box);
-    elm_box_pack_start(wrapper, button_box);
-
-    url_bar_ = elm_entry_add(wrapper);
-    elm_entry_single_line_set(url_bar_, EINA_TRUE);
-    elm_entry_scrollable_set(url_bar_, EINA_TRUE);
-    evas_object_size_hint_align_set(url_bar_, EVAS_HINT_FILL, EVAS_HINT_FILL);
-    evas_object_size_hint_weight_set(url_bar_, EVAS_HINT_EXPAND,
-                                     EVAS_HINT_EXPAND);
-    elm_entry_input_panel_layout_set(url_bar_, ELM_INPUT_PANEL_LAYOUT_URL);
-    evas_object_size_hint_weight_set(url_bar_, EVAS_HINT_EXPAND, 0.0f);
-    evas_object_size_hint_align_set(url_bar_, EVAS_HINT_FILL, EVAS_HINT_FILL);
-    evas_object_smart_callback_add(url_bar_, "activated", OnURLEntered, this);
-    elm_box_pack_end(wrapper, url_bar_);
-    evas_object_show(url_bar_);
-
-    elm_box_pack_end(box, wrapper);
-  }
-
-  Evas_Object* AddButton(Evas_Object* parent_box,
-                         const char* icon_name,
-                         Evas_Smart_Cb cb) {
-    Evas_Object* btn = elm_button_add(parent_box);
-    Evas_Object* icon = elm_icon_add(parent_box);
-    elm_icon_standard_set(icon, icon_name);
-    elm_object_part_content_set(btn, "icon", icon);
-    evas_object_smart_callback_add(btn, "clicked", cb, this);
-    elm_box_pack_end(parent_box, btn);
-    evas_object_show(btn);
-    return btn;
-  }
-
-  void SetAddressBarURL(const char* url) {
-    if (url_bar_)
-      elm_object_text_set(url_bar_, url);
-  }
-
-  void ToggleControl(ShellPlatformDelegate::UIControl control,
-                     bool is_enabled) {
-    if (control == ShellPlatformDelegate::BACK_BUTTON && back_btn_) {
-      elm_object_disabled_set(back_btn_, !is_enabled);
-    } else if (control == ShellPlatformDelegate::FORWARD_BUTTON &&
-               forward_btn_) {
-      elm_object_disabled_set(forward_btn_, !is_enabled);
-    } else if (control == ShellPlatformDelegate::STOP_BUTTON && stop_btn_) {
-      elm_object_disabled_set(stop_btn_, !is_enabled);
-    }
-  }
-
- private:
-  static void OnBack(void* data, Evas_Object*, void*) {
-    static_cast<Shell::Impl*>(data)->shell_->GoBackOrForward(-1);
-  }
-
-  static void OnNewWindow(void* data, Evas_Object*, void*) {
-    Shell* shell = static_cast<Shell::Impl*>(data)->shell_;
-    gfx::Size initial_size = Shell::GetShellDefaultSize();
-    Shell::CreateNewWindow(shell->web_contents()->GetBrowserContext(),
-                           GURL("https://www.google.com"), nullptr,
-                           initial_size);
-  }
-
-  static void OnForward(void* data, Evas_Object*, void*) {
-    static_cast<Shell::Impl*>(data)->shell_->GoBackOrForward(1);
-  }
-
-  static void OnRefresh(void* data, Evas_Object*, void*) {
-    static_cast<Shell::Impl*>(data)->shell_->Reload();
-  }
-
-  static void OnStop(void* data, Evas_Object*, void*) {
-    static_cast<Shell::Impl*>(data)->shell_->Stop();
-  }
-
-  static void OnURLEntered(void* data, Evas_Object* obj, void*) {
-    GURL url(elm_object_text_get(obj));
-    if (!url.has_scheme()) {
-      url = GURL(std::string("http://") + elm_object_text_get(obj));
-      elm_object_text_set(obj, url.spec().c_str());
-    }
-    static_cast<Shell::Impl*>(data)->shell_->LoadURL(url);
-  }
-
-  Evas_Object* url_bar_;
-  Evas_Object* refresh_btn_;
-  Evas_Object* stop_btn_;
-  Evas_Object* back_btn_;
-  Evas_Object* forward_btn_;
-
-  Shell* shell_;
-};
-
-namespace {
-void OnShellWindowDelRequest(void* data, Evas_Object*, void*) {
-  Shell* shell = static_cast<Shell*>(data);
-  shell->Close();
-}
-}
-
-#if !defined(EWK_BRINGUP)  // FIXME: m85 bringup
-// static
-void Shell::PlatformInitialize(const gfx::Size& default_window_size) {
-  elm_policy_set(ELM_POLICY_QUIT, ELM_POLICY_QUIT_LAST_WINDOW_CLOSED);
-  LOG(INFO) << "EFL Shell platform initialized";
-}
-
-void Shell::PlatformExit() {
-  LOG(INFO) << "EFL Shell platform exit";
-}
-
-void Shell::PlatformCleanUp() {}
-
-void Shell::PlatformEnableUIControl(UIControl control, bool is_enabled) {
-  impl_->ToggleControl(control, is_enabled);
-}
-
-void Shell::PlatformSetAddressBarURL(const GURL& url) {
-  impl_->SetAddressBarURL(url.spec().c_str());
-}
-
-void Shell::PlatformSetIsLoading(bool loading) {}
-
-void Shell::PlatformCreateWindow(int width, int height) {}
-
-void Shell::PlatformSetContents() {
-  Evas_Object* win = efl::WindowFactory::GetHostWindow(web_contents_.get());
-  evas_object_smart_callback_add(win, "delete,request", OnShellWindowDelRequest,
-                                 this);
-  gfx::Size initial_size = Shell::GetShellDefaultSize();
-  evas_object_resize(win, initial_size.width(), initial_size.height());
-  evas_object_show(win);
-  window_ = win;
-  impl_ = new Impl(this, static_cast<Evas_Object*>(window_));
-}
-
-void Shell::PlatformResizeSubViews() {}
-
-void Shell::PlatformSetTitle(const std::u16string& title) {
-  elm_win_title_set(static_cast<Evas_Object*>(window_),
-                    base::UTF16ToUTF8(title).c_str());
-}
-#endif
-
-JavaScriptDialogManager* Shell::GetJavaScriptDialogManager(
-    WebContents* source) {
-  if (!dialog_manager_) {
-    if (switches::IsRunWebTestsSwitchPresent()) {
-      dialog_manager_.reset(new WebTestJavaScriptDialogManager);
-    } else {
-      dialog_manager_.reset(new JavaScriptDialogManagerEfl);
-    }
-  }
-  return dialog_manager_.get();
-}
-
-}  // namespace content
diff --git a/tizen_src/chromium_impl/content/shell/browser/shell_main_efl.cc b/tizen_src/chromium_impl/content/shell/browser/shell_main_efl.cc
deleted file mode 100644 (file)
index bd3355c..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-// Copyright (c) 2012 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.
-
-#include "content/public/app/content_main.h"
-
-#include "base/at_exit.h"
-#include "content/shell/app/shell_main_delegate.h"
-#include "efl/init.h"
-
-int main(int argc, const char* argv[]) {
-  base::AtExitManager at_exit;
-  if (efl::Initialize(argc, argv))
-    return 1;
-
-  content::ShellMainDelegate delegate;
-
-  content::ContentMainParams prams(&delegate);
-  prams.argc = argc;
-  prams.argv = argv;
-  return content::ContentMain(prams);
-}
diff --git a/tizen_src/chromium_impl/content/shell/browser/shell_platform_delegate_efl.cc b/tizen_src/chromium_impl/content/shell/browser/shell_platform_delegate_efl.cc
deleted file mode 100644 (file)
index d5a5edc..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-// Copyright 2020 Samsung Electronics Inc. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "content/shell/browser/shell_platform_delegate.h"
-
-#include "content/public/browser/render_widget_host_view.h"
-#include "content/public/browser/web_contents.h"
-#include "content/shell/browser/shell.h"
-
-namespace content {
-
-struct ShellPlatformDelegate::ShellData {
-  gfx::NativeWindow window;
-};
-
-struct ShellPlatformDelegate::PlatformData {};
-
-ShellPlatformDelegate::ShellPlatformDelegate() = default;
-ShellPlatformDelegate::~ShellPlatformDelegate() = default;
-
-void ShellPlatformDelegate::Initialize(const gfx::Size& default_window_size) {
-  platform_ = std::make_unique<PlatformData>();
-}
-
-void ShellPlatformDelegate::CreatePlatformWindow(
-    Shell* shell,
-    const gfx::Size& initial_size) {}
-
-gfx::NativeWindow ShellPlatformDelegate::GetNativeWindow(Shell* shell) {
-  return gfx::NativeWindow();
-}
-
-void ShellPlatformDelegate::CleanUp(Shell* shell) {}
-
-void ShellPlatformDelegate::SetContents(Shell* shell) {}
-
-void ShellPlatformDelegate::ResizeWebContent(Shell* shell,
-                                             const gfx::Size& content_size) {}
-
-void ShellPlatformDelegate::EnableUIControl(Shell* shell,
-                                            UIControl control,
-                                            bool is_enabled) {}
-
-void ShellPlatformDelegate::SetAddressBarURL(Shell* shell, const GURL& url) {}
-
-void ShellPlatformDelegate::SetIsLoading(Shell* shell, bool loading) {}
-
-void ShellPlatformDelegate::SetTitle(Shell* shell,
-                                     const std::u16string& title) {}
-
-void ShellPlatformDelegate::MainFrameCreated(Shell* shell) {}
-
-bool ShellPlatformDelegate::DestroyShell(Shell* shell) {
-  return false;
-}
-
-}  // namespace content
diff --git a/tizen_src/chromium_impl/content/shell/browser/shell_web_contents_view_delegate_efl.cc b/tizen_src/chromium_impl/content/shell/browser/shell_web_contents_view_delegate_efl.cc
deleted file mode 100644 (file)
index 1489c8d..0000000
+++ /dev/null
@@ -1,165 +0,0 @@
-// Copyright 2013 The Chromium Authors. All rights reserved.
-// Copyright 2014 Samsung Electronics. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "content/shell/browser/shell_web_contents_view_delegate.h"
-
-#include <Evas.h>
-#include <Elementary.h>
-
-#include "base/command_line.h"
-#include "content/public/browser/render_view_host.h"
-#include "content/shell/browser/shell.h"
-#include "content/shell/browser/shell_browser_context.h"
-#include "content/shell/browser/shell_content_browser_client.h"
-#include "content/shell/browser/shell_devtools_frontend.h"
-#include "content/shell/common/shell_switches.h"
-#include "third_party/blink/public/common/context_menu_data/context_menu_data.h"
-#include "third_party/blink/public/common/context_menu_data/edit_flags.h"
-
-using blink::ContextMenuDataEditFlags;
-
-namespace content {
-
-namespace {
-
-static Evas_Object* g_context_menu = NULL;
-
-void OpenInNewWindow(void* data, Evas_Object*, void*) {
-  const ContextMenuParams* params = static_cast<const ContextMenuParams*>(data);
-  ShellBrowserContext* browser_context =
-      ShellContentBrowserClient::Get()->browser_context();
-  Shell::CreateNewWindow(browser_context, params->link_url, nullptr,
-                         gfx::Size());
-}
-
-void StartDragging(void* data, Evas_Object*, void*) {
-  WebContents* wc = static_cast<WebContents*>(data);
-  RenderViewHost* rvh = wc->GetRenderViewHost();
-#if !defined(EWK_BRINGUP)  // FIXME: m67 bringup
-  rvh->StartDragging();
-#endif
-}
-
-void Cut(void* data, Evas_Object*, void*) {
-  WebContents* wc = static_cast<WebContents*>(data);
-  wc->Cut();
-}
-
-void Copy(void* data, Evas_Object*, void*) {
-  WebContents* wc = static_cast<WebContents*>(data);
-  wc->Copy();
-}
-
-void Paste(void* data, Evas_Object*, void*) {
-  WebContents* wc = static_cast<WebContents*>(data);
-  wc->Paste();
-}
-
-void Delete(void* data, Evas_Object*, void*) {
-  WebContents* wc = static_cast<WebContents*>(data);
-  wc->Delete();
-}
-
-void Forward(void* data, Evas_Object*, void*) {
-  WebContents* wc = static_cast<WebContents*>(data);
-  wc->GetController().GoToOffset(1);
-  wc->Focus();
-}
-
-void Back(void* data, Evas_Object*, void*) {
-  WebContents* wc = static_cast<WebContents*>(data);
-  wc->GetController().GoToOffset(-1);
-  wc->Focus();
-}
-
-void Reload(void* data, Evas_Object*, void*) {
-  WebContents* wc = static_cast<WebContents*>(data);
-  wc->GetController().Reload(content::ReloadType::NORMAL, false);
-  wc->Focus();
-}
-}
-
-WebContentsViewDelegate* CreateShellWebContentsViewDelegate(
-    WebContents* web_contents) {
-  return new ShellWebContentsViewDelegate(web_contents);
-}
-
-ShellWebContentsViewDelegate::ShellWebContentsViewDelegate(
-    WebContents* web_contents)
-    : web_contents_(web_contents) {}
-
-ShellWebContentsViewDelegate::~ShellWebContentsViewDelegate() {}
-
-void ShellWebContentsViewDelegate::ShowContextMenu(
-    RenderFrameHost* render_frame_host,
-    const ContextMenuParams& params) {
-#if !defined(USE_AURA)
-  if (switches::IsRunWebTestsSwitchPresent())
-    return;
-
-  if (g_context_menu) {
-    elm_menu_close(g_context_menu);
-    evas_object_del(g_context_menu);
-  }
-
-  params_ = params;
-
-  bool has_link = !params.unfiltered_link_url.is_empty();
-  Evas_Object* parent =
-      static_cast<Evas_Object*>(web_contents_->GetContentNativeView());
-
-  Evas_Object* menu = elm_menu_add(parent);
-  Elm_Object_Item* menu_it = NULL;
-
-  if (has_link) {
-    elm_menu_item_add(menu, NULL, NULL, "Open in new window", OpenInNewWindow,
-                      &params_);
-    elm_menu_item_separator_add(menu, NULL);
-  }
-
-#if !defined(EWK_BRINGUP)  // FIXME: m67 bringup
-  if (params.is_draggable) {
-    elm_menu_item_add(menu, NULL, NULL, "Start dragging", StartDragging,
-                      web_contents_);
-  }
-#endif
-
-  if (params_.is_editable) {
-    menu_it = elm_menu_item_add(menu, NULL, NULL, "Cut", Cut, web_contents_);
-    elm_object_item_disabled_set(
-        menu_it, (params_.edit_flags & ContextMenuDataEditFlags::kCanCut) == 0);
-    menu_it = elm_menu_item_add(menu, NULL, NULL, "Copy", Copy, web_contents_);
-    elm_object_item_disabled_set(
-        menu_it,
-        (params_.edit_flags & ContextMenuDataEditFlags::kCanCopy) == 0);
-    menu_it =
-        elm_menu_item_add(menu, NULL, NULL, "Paste", Paste, web_contents_);
-    elm_object_item_disabled_set(
-        menu_it,
-        (params_.edit_flags & ContextMenuDataEditFlags::kCanPaste) == 0);
-    menu_it = elm_menu_item_add(menu, NULL, "delete", "Delete", Delete,
-                                web_contents_);
-    elm_object_item_disabled_set(
-        menu_it,
-        (params_.edit_flags & ContextMenuDataEditFlags::kCanDelete) == 0);
-    elm_menu_item_separator_add(menu, NULL);
-  }
-
-  menu_it = elm_menu_item_add(menu, NULL, "back", "Back", Back, web_contents_);
-  elm_object_item_disabled_set(menu_it,
-                               !web_contents_->GetController().CanGoBack());
-  menu_it = elm_menu_item_add(menu, NULL, "forward", "Forward", Forward,
-                              web_contents_);
-  elm_object_item_disabled_set(menu_it,
-                               !web_contents_->GetController().CanGoForward());
-  elm_menu_item_add(menu, NULL, "reload", "Reload", Reload, web_contents_);
-
-  g_context_menu = menu;
-  elm_menu_move(menu, params.x, params.y);
-  evas_object_show(menu);
-#endif
-}
-
-}  // namespace content
diff --git a/tizen_src/chromium_impl/content/shell/shell_efl.gni b/tizen_src/chromium_impl/content/shell/shell_efl.gni
deleted file mode 100644 (file)
index 69a38fb..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-# Copyright (c) 2015 Samsung Electronics. All rights reserved.
-# Use of this source code is governed by a BSD-style license that can be
-# found in the LICENSE file.
-
-import("//tizen_src/build/config/tizen_features.gni")
-import("//tizen_src/chromium_impl/components/components.gni")
-
-external_content_shell_efl_configs = [
-  "//tizen_src/build:evas",
-  "//tizen_src/build:libevas",
-  "//tizen_src/build:ecore-evas",
-  "//tizen_src/build:libecore-evas",
-  "//tizen_src/build:elementary",
-  "//tizen_src/build:libelementary",
-]
-
-if (use_wayland) {
-  external_content_shell_efl_configs += [
-    "//tizen_src/build:ecore-wayland",
-    "//tizen_src/build:libecore-wayland",
-  ]
-} else {
-  external_content_shell_efl_configs += [
-    "//tizen_src/build:ecore-x",
-    "//tizen_src/build:libecore-x",
-  ]
-}
-
-external_content_shell_efl_deps = [ "//tizen_src/chromium_impl/efl:efl-init" ]
-external_content_shell_efl_deps += js_dialog_efl_deps
-
-external_content_shell_lib_efl_sources = [
-  "//tizen_src/chromium_impl/content/shell/browser/shell_efl.cc",
-  "//tizen_src/chromium_impl/content/shell/browser/shell_platform_delegate_efl.cc",
-  "//tizen_src/chromium_impl/content/shell/browser/shell_web_contents_view_delegate_efl.cc",
-]
-
-external_content_shell_efl_sources =
-    [ "//tizen_src/chromium_impl/content/shell/browser/shell_main_efl.cc" ]
-
-external_exclude_content_shell_efl_sources = [ "app/shell_main.cc" ]
diff --git a/tizen_src/chromium_impl/device/battery/battery_status_manager_tizen.cc b/tizen_src/chromium_impl/device/battery/battery_status_manager_tizen.cc
deleted file mode 100644 (file)
index 7be6088..0000000
+++ /dev/null
@@ -1,267 +0,0 @@
-// Copyright 2014 Samsung Electronics. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "device/battery/battery_status_manager_tizen.h"
-
-#include <device/battery.h>
-#include <system/device.h>
-#include <vconf/vconf.h>
-
-namespace device {
-
-namespace {
-
-typedef void (*battery_remaining_time_changed_cb)(int time, void* data);
-
-battery_remaining_time_changed_cb timetofull_changed_cb = NULL;
-battery_remaining_time_changed_cb timetoempty_changed_cb = NULL;
-void* timetofull_cb_user_data = NULL;
-void* timetoempty_cb_user_data = NULL;
-
-void timetofull_vconf_cb(keynode_t* key, void* data) {
-  BatteryStatusManagerTizen* bsm =
-      static_cast<BatteryStatusManagerTizen*>(data);
-  if (!bsm || !timetofull_changed_cb)
-    return;
-
-  const char* keyname = vconf_keynode_get_name(key);
-  if (keyname == NULL)
-    return;
-
-  int time = 0;
-  if (strcmp(keyname, VCONFKEY_PM_BATTERY_TIMETOFULL) == 0 &&
-      bsm->GetRemainingTimeUntilFullyCharged(&time) == DEVICE_ERROR_NONE &&
-      time > 0) {
-    timetofull_changed_cb(time, timetofull_cb_user_data);
-  }
-}
-
-void timetoempty_vconf_cb(keynode_t* key, void* data) {
-  BatteryStatusManagerTizen* bsm =
-      static_cast<BatteryStatusManagerTizen*>(data);
-
-  if (!bsm || !timetoempty_changed_cb)
-    return;
-
-  const char* keyname = vconf_keynode_get_name(key);
-  if (keyname == NULL)
-    return;
-
-  int time = 0;
-  if (strcmp(keyname, VCONFKEY_PM_BATTERY_TIMETOEMPTY) == 0 &&
-      bsm->GetRemainingTimeUntilDischarged(&time) == DEVICE_ERROR_NONE &&
-      time > 0) {
-    timetoempty_changed_cb(time, timetoempty_cb_user_data);
-  }
-}
-
-void OnChargingStatusChanged(keynode_t* key, void* data) {
-  BatteryStatusManagerTizen* bsm =
-      static_cast<BatteryStatusManagerTizen*>(data);
-  if (!bsm)
-    return;
-
-  int charging = 0;
-  if (vconf_get_int(VCONFKEY_SYSMAN_BATTERY_CHARGE_NOW, &charging) < 0)
-    return;
-
-  BatteryStatus current_status = bsm->GetCurrentStatus();
-  current_status.charging = charging > 0;
-  current_status.charging_time = std::numeric_limits<double>::infinity();
-  current_status.discharging_time = std::numeric_limits<double>::infinity();
-
-  int left_time = 0;
-  if (current_status.charging) {
-    bsm->GetRemainingTimeUntilFullyCharged(&left_time);
-    if (left_time > 0)
-      current_status.charging_time = left_time;
-  } else {
-    bsm->GetRemainingTimeUntilDischarged(&left_time);
-    if (left_time > 0)
-      current_status.discharging_time = left_time;
-  }
-
-  bsm->SetCurrentStatus(current_status);
-  bsm->GetBatteryUpdateCallback().Run(current_status);
-}
-
-void OnLevelChanged(int percent, void* data) {
-  BatteryStatusManagerTizen* bsm =
-      static_cast<BatteryStatusManagerTizen*>(data);
-  if (!bsm)
-    return;
-
-  BatteryStatus current_status = bsm->GetCurrentStatus();
-  current_status.level = percent / 100.0;
-  bsm->SetCurrentStatus(current_status);
-  bsm->GetBatteryUpdateCallback().Run(current_status);
-}
-
-void OnChargingTimeChanged(int time, void* data) {
-  BatteryStatusManagerTizen* bsm =
-      static_cast<BatteryStatusManagerTizen*>(data);
-  if (!bsm)
-    return;
-
-  BatteryStatus current_status = bsm->GetCurrentStatus();
-  current_status.charging_time = time;
-  bsm->SetCurrentStatus(current_status);
-  bsm->GetBatteryUpdateCallback().Run(current_status);
-}
-
-void OnDischargingTimeChanged(int time, void* data) {
-  BatteryStatusManagerTizen* bsm =
-      static_cast<BatteryStatusManagerTizen*>(data);
-  if (!bsm)
-    return;
-
-  BatteryStatus current_status = bsm->GetCurrentStatus();
-  current_status.discharging_time = time;
-  bsm->SetCurrentStatus(current_status);
-  bsm->GetBatteryUpdateCallback().Run(current_status);
-}
-
-int SetRemainingTimeUntilFullyChargedCb(
-    battery_remaining_time_changed_cb callback, void* data) {
-  if (callback == NULL)
-    return DEVICE_ERROR_INVALID_PARAMETER;
-
-  if (vconf_notify_key_changed(VCONFKEY_PM_BATTERY_TIMETOFULL,
-                               timetofull_vconf_cb, NULL) < 0)
-    return DEVICE_ERROR_OPERATION_FAILED;
-
-  timetofull_changed_cb = callback;
-  timetofull_cb_user_data = data;
-  return DEVICE_ERROR_NONE;
-}
-
-int SetRemainingTimeUntilDischargedCb(
-    battery_remaining_time_changed_cb callback, void* data) {
-  if (callback == NULL)
-    return DEVICE_ERROR_INVALID_PARAMETER;
-
-  if (vconf_notify_key_changed(VCONFKEY_PM_BATTERY_TIMETOEMPTY,
-                               timetoempty_vconf_cb, NULL) < 0)
-    return DEVICE_ERROR_OPERATION_FAILED;
-
-  timetoempty_changed_cb = callback;
-  timetoempty_cb_user_data = data;
-  return DEVICE_ERROR_NONE;
-}
-
-int UnsetRemainingTimeUntilFullyChargedCb() {
-  if (vconf_ignore_key_changed(VCONFKEY_PM_BATTERY_TIMETOFULL,
-                               timetofull_vconf_cb) < 0)
-    return DEVICE_ERROR_OPERATION_FAILED;
-
-  timetofull_changed_cb = NULL;
-  timetofull_cb_user_data = NULL;
-  return DEVICE_ERROR_NONE;
-}
-
-int UnsetRemainingTimeUntilDischargedCb() {
-  if (vconf_ignore_key_changed(VCONFKEY_PM_BATTERY_TIMETOEMPTY,
-                               timetoempty_vconf_cb) < 0)
-    return DEVICE_ERROR_OPERATION_FAILED;
-
-  timetoempty_changed_cb = NULL;
-  timetoempty_cb_user_data = NULL;
-  return DEVICE_ERROR_NONE;
-}
-
-}  // namespace
-
-std::unique_ptr<BatteryStatusManager> BatteryStatusManager::Create(
-    const BatteryStatusService::BatteryUpdateCallback& callback) {
-  return std::unique_ptr<BatteryStatusManager>(
-      new BatteryStatusManagerTizen(callback));
-}
-
-BatteryStatusManagerTizen::BatteryStatusManagerTizen(
-    const BatteryStatusService::BatteryUpdateCallback& callback)
-    : callback_(callback) {
-}
-
-BatteryStatusManagerTizen::~BatteryStatusManagerTizen() {
-}
-
-int BatteryStatusManagerTizen::GetRemainingTimeUntilFullyCharged(
-    int* time) const {
-  DCHECK(time != NULL);
-  bool charging = false;
-  if (device_battery_is_charging(&charging) != DEVICE_ERROR_NONE ||
-      charging == false)
-    return DEVICE_ERROR_OPERATION_FAILED;
-
-  int temp_time = 0;
-  if (vconf_get_int(VCONFKEY_PM_BATTERY_TIMETOFULL, &temp_time) < 0 ||
-      temp_time < 0)
-    return DEVICE_ERROR_OPERATION_FAILED;
-
-  *time = temp_time;
-  return DEVICE_ERROR_NONE;
-}
-
-int BatteryStatusManagerTizen::GetRemainingTimeUntilDischarged(
-    int* time) const {
-  DCHECK(time != NULL);
-  bool charging = false;
-  if (device_battery_is_charging(&charging) != DEVICE_ERROR_NONE ||
-      charging == true)
-    return DEVICE_ERROR_OPERATION_FAILED;
-
-  int temp_time = 0;
-  if (vconf_get_int(VCONFKEY_PM_BATTERY_TIMETOEMPTY, time) < 0 ||
-      time < 0)
-    return DEVICE_ERROR_OPERATION_FAILED;
-
-  *time = temp_time;
-  return DEVICE_ERROR_NONE;
-}
-
-bool BatteryStatusManagerTizen::StartListeningBatteryChange() {
-#if !defined(EWK_BRINGUP)  // FIXME: m67 bringup
-  if (vconf_notify_key_changed(
-          VCONFKEY_SYSMAN_BATTERY_CHARGE_NOW, OnChargingStatusChanged, this) ||
-      device_battery_set_cb(OnLevelChanged, this) != DEVICE_ERROR_NONE ||
-      SetRemainingTimeUntilFullyChargedCb(OnChargingTimeChanged, this)
-          != DEVICE_ERROR_NONE ||
-      SetRemainingTimeUntilDischargedCb(OnDischargingTimeChanged, this)
-          != DEVICE_ERROR_NONE) {
-    StopListeningBatteryChange();
-    return false;
-  }
-#endif
-
-  int charging = 0;
-  if (vconf_get_int(VCONFKEY_SYSMAN_BATTERY_CHARGE_NOW, &charging) < 0)
-    return false;
-
-  int level = 0, charging_time = 0, discharging_time = 0;
-  device_battery_get_percent(&level);
-  GetRemainingTimeUntilFullyCharged(&charging_time);
-  GetRemainingTimeUntilDischarged(&discharging_time);
-
-  current_status_.charging = charging > 0;
-  current_status_.level = level / 100.0;
-  current_status_.charging_time = charging_time > 0 ? charging_time :
-      std::numeric_limits<double>::infinity();
-  current_status_.discharging_time = discharging_time > 0 ? discharging_time :
-      std::numeric_limits<double>::infinity();
-
-  callback_.Run(current_status_);
-  return true;
-}
-
-void BatteryStatusManagerTizen::StopListeningBatteryChange() {
-  UnsetRemainingTimeUntilFullyChargedCb();
-  UnsetRemainingTimeUntilDischargedCb();
-  vconf_ignore_key_changed(VCONFKEY_SYSMAN_BATTERY_CHARGE_NOW,
-      OnChargingStatusChanged);
-#if !defined(EWK_BRINGUP)  // FIXME: m67 bringup
-  device_battery_unset_cb();
-#endif
-}
-
-}  // namespace device
diff --git a/tizen_src/chromium_impl/device/battery/battery_status_manager_tizen.h b/tizen_src/chromium_impl/device/battery/battery_status_manager_tizen.h
deleted file mode 100644 (file)
index 63be660..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-// Copyright 2014 Samsung Electronics. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef DEVICE_BATTERY_BATTERY_STATUS_MANAGER_TIZEN_H_
-#define DEVICE_BATTERY_BATTERY_STATUS_MANAGER_TIZEN_H_
-
-#include "device/battery/battery_status_manager.h"
-
-namespace device {
-
-class BatteryStatusManagerTizen : public BatteryStatusManager {
- public:
-  explicit BatteryStatusManagerTizen(
-      const BatteryStatusService::BatteryUpdateCallback& callback);
-  ~BatteryStatusManagerTizen() override;
-
-  BatteryStatusManagerTizen(const BatteryStatusManagerTizen&) = delete;
-  BatteryStatusManagerTizen& operator=(const BatteryStatusManagerTizen&) =
-      delete;
-
-  BatteryStatus GetCurrentStatus() const { return current_status_; }
-  void SetCurrentStatus(BatteryStatus status) { current_status_ = status; }
-
-  BatteryStatusService::BatteryUpdateCallback GetBatteryUpdateCallback() const {
-    return callback_;
-  }
-
-  int GetRemainingTimeUntilFullyCharged(int* time) const;
-  int GetRemainingTimeUntilDischarged(int* time) const;
-
- private:
-  bool StartListeningBatteryChange() override;
-  void StopListeningBatteryChange() override;
-
-  BatteryStatus current_status_;
-  BatteryStatusService::BatteryUpdateCallback callback_;
-};
-
-}  // namespace content
-
-#endif // DEVICE_BATTERY_BATTERY_STATUS_MANAGER_TIZEN_H_
diff --git a/tizen_src/chromium_impl/device/battery_tizen.gni b/tizen_src/chromium_impl/device/battery_tizen.gni
deleted file mode 100644 (file)
index 0e5ee98..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-# Copyright (c) 2015 Samsung Electronics. All rights reserved.
-# Use of this source code is governed by a BSD-style license that can be
-# found in the LICENSE file.
-
-external_device_battery_configs = [
-  "//tizen_src/build:capi-system-device",
-  "//tizen_src/build:libcapi-system-device",
-  "//tizen_src/build:vconf",
-  "//tizen_src/build:libvconf",
-]
-
-external_device_battery_sources = [
-  "//tizen_src/chromium_impl/device/battery/battery_status_manager_tizen.cc",
-  "//tizen_src/chromium_impl/device/battery/battery_status_manager_tizen.h",
-]
index 2124d99..3dbb9fe 100644 (file)
@@ -303,16 +303,6 @@ EWebView* EWebView::FromEvasObject(Evas_Object* eo) {
   return WebViewDelegateEwk::GetInstance().GetWebViewFromEvasObject(eo);
 }
 
-void EWebView::OnViewFocusIn(void* data, Evas*, Evas_Object*, void*) {
-  auto view = static_cast<EWebView*>(data);
-  view->SetFocus(EINA_TRUE);
-}
-
-void EWebView::OnViewFocusOut(void* data, Evas*, Evas_Object*, void*) {
-  auto view = static_cast<EWebView*>(data);
-  view->SetFocus(EINA_FALSE);
-}
-
 void EWebView::VisibleContentChangedCallback(void* user_data,
                                              Evas_Object* /*object*/,
                                              void* event_info) {
@@ -369,10 +359,6 @@ EWebView::EWebView(Ewk_Context* context, Evas_Object* ewk_view)
                                    OnCustomScrollBeginCallback, this);
     evas_object_smart_callback_add(ewk_view_, kCustomScrollEndSignalName,
                                    OnCustomScrollEndCallback, this);
-    evas_object_event_callback_add(ewk_view_, EVAS_CALLBACK_FOCUS_IN,
-                                   OnViewFocusIn, this);
-    evas_object_event_callback_add(ewk_view_, EVAS_CALLBACK_FOCUS_OUT,
-                                   OnViewFocusOut, this);
 #if BUILDFLAG(IS_TIZEN)
     window_rotate_handler_ = ecore_event_handler_add(
       ECORE_WL2_EVENT_WINDOW_ROTATE, RotateWindowCb, this);
@@ -508,10 +494,6 @@ EWebView::~EWebView() {
   gin_native_bridge_dispatcher_host_.reset();
 
   if (ewk_view_) {
-    evas_object_event_callback_del(ewk_view_, EVAS_CALLBACK_FOCUS_IN,
-                                   OnViewFocusIn);
-    evas_object_event_callback_del(ewk_view_, EVAS_CALLBACK_FOCUS_OUT,
-                                   OnViewFocusOut);
     evas_object_smart_callback_del(ewk_view_, kVisibleContentChangedSignalName,
                                    VisibleContentChangedCallback);
     evas_object_smart_callback_del(ewk_view_, kCustomScrollBeginSignalName,
index 7d9f4f8..ccccd8f 100644 (file)
@@ -801,8 +801,6 @@ class EWebView {
                       const base::FilePath& file_path,
                       int64_t file_size);
 
-  static void OnViewFocusIn(void* data, Evas*, Evas_Object*, void*);
-  static void OnViewFocusOut(void* data, Evas*, Evas_Object*, void*);
   static void VisibleContentChangedCallback(void* user_data,
                                             Evas_Object* object,
                                             void* event_info);