module SystemBrowser

Public Class Methods

start(debug: false, block: true) click to toggle source

Starts the system browser.

@param debug [Boolean] If true, prints debugging information @param nonblock [Boolean] If true, then creates a new thread. Otherwise

runs in the current thread

@return [Session.init]

# File lib/system_browser.rb, line 35
def self.start(debug: false, block: true)
  $DEBUG_SB = debug

  if $DEBUG_SB
    Thread.abort_on_exception = true
  end

  if block
    SLogger.debug('[browser] Initialising a session, blocking')

    Session.init
  else
    SLogger.debug('[browser] Initialising a session, NOT blocking')

    Thread.new { Session.init }
  end
end