PHP-GTK Client for Gemini Protocol
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

39 lines
718 B

8 months ago
<?php
// Load dependencies
require_once __DIR__ .
DIRECTORY_SEPARATOR . '..'.
DIRECTORY_SEPARATOR . 'vendor' .
DIRECTORY_SEPARATOR . 'autoload.php';
// Init filesystem
$filesystem = new \Yggverse\Yoda\Model\Filesystem(
(
getenv('HOME') ?? __DIR__ . DIRECTORY_SEPARATOR . '..'
) . DIRECTORY_SEPARATOR . '.yoda'
);
// Init database
$database = new \Yggverse\Yoda\Model\Database(
$filesystem->getAbsolute(
'database.sqlite'
)
);
// Init GTK
8 months ago
\Gtk::init();
// Init browser
$browser = new \Yggverse\Yoda\Entity\Browser(
$database
);
$browser->gtk->connect(
'destroy',
function()
{
\Gtk::main_quit();
}
);
8 months ago
\Gtk::main();