Disable forking of new process for navigation 05/190405/5
authorSuneel Kota <suneel.kota@samsung.com>
Mon, 1 Oct 2018 13:21:48 +0000 (18:51 +0530)
committerSuneel Kota <suneel.kota@samsung.com>
Mon, 22 Oct 2018 06:55:20 +0000 (12:25 +0530)
currently electron forks a new process for navigation
when http method is get, so navigation history is lost,
resulting in failure when we test back and forth
navigation.

Change-Id: I1e38e3c20f9d35cedfb0a7490c20447fd87f46e3
Signed-off-by: Suneel Kota <suneel.kota@samsung.com>
atom/renderer/atom_renderer_client.cc

index 2323f25c1265bd68cb154585da24e26309e0eea4..7fa37d4262a32a6c5d1a6b5cba4d08edbc53894b 100644 (file)
@@ -13,6 +13,7 @@
 #include "content/common/wrt/wrt_url_parse.h"
 #include "content/public/renderer/render_thread.h"
 #include "content/public/renderer/render_view.h"
+#include "tizen/common/application_data.h"
 #include "tizen_src/ewk/efl_integration/wrt/wrtwidget.h"
 #include "third_party/WebKit/public/web/WebView.h"
 #endif
@@ -219,6 +220,11 @@ bool AtomRendererClient::ShouldFork(blink::WebLocalFrame* frame,
                                     bool is_initial_navigation,
                                     bool is_server_redirect,
                                     bool* send_referrer) {
+#if defined(USE_EFL)
+  auto app_data = ::common::ApplicationDataManager::GetCurrentAppData();
+  if (app_data && !app_data->IsElectronApp())
+    return false;
+#endif
   // Handle all the navigations and reloads in browser.
   // FIXME We only support GET here because http method will be ignored when
   // the OpenURLFromTab is triggered, which means form posting would not work,