Multithread

Equo Chromium supports running Chromium in a "multi-threaded mode", which allows Chromium to manage its own internal event loop separately from the main UI thread.

This is useful for:

  • Drag and drop support on Linux

  • Performance improvements in how Chromium manages rendering and browser events

  • Running with the Standalone mode.

To enable Multithread, set the -Dchromium.multi_threaded_message_loop system property:

-Dchromium.multi_threaded_message_loop=true

By default, this feature is disabled to maintain compatibility with previous versions.

In the Standalone mode, enabling Multithread means you no longer need to explicitly call ChromiumBrowser.startBrowsers(). Normally, this method is required to start the browser event loop and block the main thread until all browser windows are closed.

On Windows, when using SWT as of version 128.0.9, enabling Multithread moves browser callbacks from OpenWindowListener and LocationListener off the main SWT UI thread. This design keeps your app responsive by ensuring that any lengthy operations inside those listeners cannot freeze the user interface. However, because these callbacks no longer execute on the UI thread, you must avoid updating SWT widgets directly or invoking syncExec within them. Calling syncExec from a non-UI thread will wait for the UI thread to respond, but since that thread is already busy, it can lead to a deadlock. Instead, always wrap your UI updates in asyncExec, which schedules them on the UI thread without blocking or risking a standstill in your application.