diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 80abd99..3243461 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,11 +1,6 @@ ---- -# This is a basic workflow to help you get started with Actions name: CI -# Controls when the workflow will run on: - # Triggers the workflow on push or pull request - # events but only for the main branch push: branches: [main] paths-ignore: @@ -13,7 +8,6 @@ on: pull_request: branches: [main] - # Allows you to run this workflow manually from the Actions tab workflow_dispatch: jobs: @@ -22,7 +16,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [ubuntu-latest, windows-latest] + os: [ubuntu-latest] steps: - uses: actions/checkout@v2 - uses: actions/setup-java@v2 @@ -48,11 +42,11 @@ jobs: flutter create --platforms=linux . flutter build linux if: matrix.os == 'ubuntu-latest' - - name: Build (Windows) - run: | - flutter config --enable-windows-desktop - cd example - flutter create --platforms=windows . - flutter doctor - flutter build windows - if: matrix.os == 'windows-latest' + # - name: Build (Windows) + # run: | + # flutter config --enable-windows-desktop + # cd example + # flutter create --platforms=windows . + # flutter doctor + # flutter build windows + # if: matrix.os == 'windows-latest' diff --git a/CHANGELOG.md b/CHANGELOG.md index 2e99091..90e7f7f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,8 +1,12 @@ # Changelog +## 2.0.1 + +* Fix window action buttons not visible sometimes + ## 2.0.0 -* Add Windows & Mac os headerbar buttons (using `nativeControls` parameter) +* Add Windows & macOS headerbar buttons (using `nativeControls` parameter) * Add builder for `AdwPreferencesGroup` * Update Documentation for various widgets * Support Material 3 font naming scheme diff --git a/example/pubspec.lock b/example/pubspec.lock index 9ea378c..d4296d7 100644 --- a/example/pubspec.lock +++ b/example/pubspec.lock @@ -168,7 +168,7 @@ packages: path: ".." relative: true source: path - version: "2.0.0" + version: "2.0.1" libadwaita_core: dependency: transitive description: diff --git a/lib/src/widgets/adw/new/window_button.dart b/lib/src/widgets/adw/new/window_button.dart index be06577..cacb358 100644 --- a/lib/src/widgets/adw/new/window_button.dart +++ b/lib/src/widgets/adw/new/window_button.dart @@ -28,34 +28,34 @@ class AdwWindowButton extends StatelessWidget { @override Widget build(BuildContext context) { return onPressed != null - ? !nativeControls || Platform.isLinux - ? AdwButton.circular( - size: 24, - margin: const EdgeInsets.all(6), + ? nativeControls && Platform.isWindows + ? WindowCaptionButton( onPressed: onPressed, - child: Center( - child: SvgPicture.asset( - 'assets/icons/${buttonType.name}.svg', - width: 16, - package: 'libadwaita', - height: 16, - colorFilter: - ColorFilter.mode(context.textColor, BlendMode.srcIn), - ), - ), + brightness: Theme.of(context).brightness, + type: buttonType, ) - : Platform.isWindows - ? WindowCaptionButton( + : nativeControls && Platform.isMacOS + ? MacOSCaptionButton( onPressed: onPressed, - brightness: Theme.of(context).brightness, type: buttonType, ) - : Platform.isMacOS - ? MacOSCaptionButton( - onPressed: onPressed, - type: buttonType, - ) - : const SizedBox() + : AdwButton.circular( + size: 24, + margin: const EdgeInsets.all(6), + onPressed: onPressed, + child: Center( + child: SvgPicture.asset( + 'assets/icons/${buttonType.name}.svg', + width: 16, + package: 'libadwaita', + height: 16, + colorFilter: ColorFilter.mode( + context.textColor, + BlendMode.srcIn, + ), + ), + ), + ) : const SizedBox(); } } diff --git a/pubspec.yaml b/pubspec.yaml index 97c074d..d55a6bf 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,7 @@ name: libadwaita -description: Libadwaita's widgets for Flutter. Following Gnome HIG and available on all platforms. -version: 2.0.0 +description: Libadwaita's widgets for Flutter. + Following Gnome HIG and available on all platforms. +version: 2.0.1 homepage: https://github.com/gtk-flutter/libadwaita environment: