def Create(self): # Init the LocalFirstBinaryManager if this is the first time we're creating # a browser. if local_first_binary_manager.LocalFirstBinaryManager.NeedsInit(): local_first_binary_manager.LocalFirstBinaryManager.Init( self._build_dir, None, 'linux', platform.machine(), # TODO(crbug.com/1084334): Remove crashpad_database_util once the # locally compiled version works. ignored_dependencies=['crashpad_database_util']) startup_args = self.GetBrowserStartupArgs(self._browser_options) browser_backend = cros_browser_backend.CrOSBrowserBackend( self._platform_backend, self._browser_options, self.browser_directory, self.profile_directory, self._is_guest, self._DEFAULT_CHROME_ENV, build_dir=self._build_dir) if self._browser_options.create_browser_with_oobe: return cros_browser_with_oobe.CrOSBrowserWithOOBE( browser_backend, self._platform_backend, startup_args) return browser.Browser(browser_backend, self._platform_backend, startup_args)
def Create(self): startup_args = self.GetBrowserStartupArgs(self._browser_options) browser_backend = cros_browser_backend.CrOSBrowserBackend( self._platform_backend, self._browser_options, self.browser_directory, self.profile_directory, self._is_guest) if self._browser_options.create_browser_with_oobe: return cros_browser_with_oobe.CrOSBrowserWithOOBE( browser_backend, self._platform_backend, startup_args) return browser.Browser(browser_backend, self._platform_backend, startup_args)
def Create(self, finder_options): if finder_options.browser_options.output_profile_path: raise NotImplementedError( 'Profile generation is not yet supported on CrOS.') browser_options = finder_options.browser_options browser_backend = cros_browser_backend.CrOSBrowserBackend( self._platform_backend, browser_options, self._platform_backend.cri, self._is_guest) if browser_options.create_browser_with_oobe: return cros_browser_with_oobe.CrOSBrowserWithOOBE( browser_backend, self._platform_backend) return browser.Browser(browser_backend, self._platform_backend)
def Create(self, clear_caches=False): # TODO(crbug.com/811244): Remove when callers no longer use this option. assert not clear_caches, 'Option no longer supported, see: crbug.com/811244' startup_args = self.GetBrowserStartupArgs(self._browser_options) browser_backend = cros_browser_backend.CrOSBrowserBackend( self._platform_backend, self._browser_options, self.browser_directory, self.profile_directory, self._is_guest) if self._browser_options.create_browser_with_oobe: return cros_browser_with_oobe.CrOSBrowserWithOOBE( browser_backend, self._platform_backend, startup_args) return browser.Browser( browser_backend, self._platform_backend, startup_args)
def Create(self, clear_caches=True): startup_args = self.GetBrowserStartupArgs(self._browser_options) browser_backend = cros_browser_backend.CrOSBrowserBackend( self._platform_backend, self._browser_options, self.browser_directory, self.profile_directory, self._is_guest) # TODO(crbug.com/811244): Remove when this is handled by shared state. if clear_caches: self._ClearCachesOnStart() if self._browser_options.create_browser_with_oobe: return cros_browser_with_oobe.CrOSBrowserWithOOBE( browser_backend, self._platform_backend, startup_args) return browser.Browser(browser_backend, self._platform_backend, startup_args)
def Create(self): startup_args = self.GetBrowserStartupArgs(self._browser_options) browser_backend = cros_browser_backend.CrOSBrowserBackend( self._platform_backend, self._browser_options, self.browser_directory, self.profile_directory, self._is_guest) self._ClearCachesOnStart() if self._browser_options.create_browser_with_oobe: return cros_browser_with_oobe.CrOSBrowserWithOOBE( browser_backend, self._platform_backend, startup_args) returned_browser = browser.Browser( browser_backend, self._platform_backend, startup_args) if self._browser_options.assert_gpu_compositing: gpu_compositing_checker.AssertGpuCompositingEnabled( returned_browser.GetSystemInfo()) return returned_browser
def Create(self, clear_caches=True): startup_args = self.GetBrowserStartupArgs(self._browser_options) browser_backend = cros_browser_backend.CrOSBrowserBackend( self._platform_backend, self._browser_options, self.browser_directory, self.profile_directory, self._is_guest) # TODO(crbug.com/811244): Remove when this is handled by shared state. if clear_caches: self._ClearCachesOnStart() if self._browser_options.create_browser_with_oobe: return cros_browser_with_oobe.CrOSBrowserWithOOBE( browser_backend, self._platform_backend, startup_args) returned_browser = browser.Browser(browser_backend, self._platform_backend, startup_args) if self._browser_options.assert_gpu_compositing: gpu_compositing_checker.AssertGpuCompositingEnabled( returned_browser.GetSystemInfo()) return returned_browser