Skip to content

Commit

Permalink
Merge branch 'main' of github.com:NativePHP/laravel
Browse files Browse the repository at this point in the history
  • Loading branch information
mpociot committed Jul 25, 2023
2 parents da62332 + f9accdf commit 42ce4e9
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/Commands/MigrateCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
namespace Native\Laravel\Commands;

use Illuminate\Contracts\Events\Dispatcher;
use Illuminate\Database\Console\Migrations\MigrateCommand as BaseMigrateCommand;
use Illuminate\Database\Migrations\Migrator;
use Native\Laravel\NativeServiceProvider;
use Illuminate\Database\Console\Migrations\MigrateCommand as BaseMigrateCommand;

class MigrateCommand extends BaseMigrateCommand
{
Expand Down
20 changes: 20 additions & 0 deletions src/Windows/Window.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ class Window
use HasDimensions;
use HasUrl;

protected bool $fullscreen = false;

protected bool $kiosk = false;

protected $rememberState = false;

protected bool $alwaysOnTop = false;
Expand Down Expand Up @@ -180,6 +184,20 @@ public function invisibleFrameless(): self
->hasShadow(false);
}

public function fullscreen($fullscreen = false): static
{
$this->fullscreen = $fullscreen;

return $this;
}

public function kiosk($kiosk = false): static
{
$this->kiosk = $kiosk;

return $this;
}

public function toArray()
{
return [
Expand Down Expand Up @@ -209,6 +227,8 @@ public function toArray()
'maximizable' => $this->maximizable,
'closable' => $this->closable,
'title' => $this->title,
'fullscreen' => $this->fullscreen,
'kiosk' => $this->kiosk,
];
}
}
7 changes: 7 additions & 0 deletions src/Windows/WindowManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,4 +57,11 @@ public function alwaysOnTop($alwaysOnTop = true, $id = null): void
'alwaysOnTop' => $alwaysOnTop,
]);
}

public function maximize($id = null): void
{
$this->client->post('window/maximize', [
'id' => $id ?? $this->detectId(),
]);
}
}

0 comments on commit 42ce4e9

Please sign in to comment.