Skip to content

Commit

Permalink
v0.3.0
Browse files Browse the repository at this point in the history
  • Loading branch information
lijy91 committed Nov 22, 2024
1 parent 12bd020 commit 2bbfab7
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 5 deletions.
2 changes: 1 addition & 1 deletion README-ZH.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@

```yaml
dependencies:
tray_manager: ^0.2.3
tray_manager: ^0.3.0
```
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ Add this to your package's pubspec.yaml file:

```yaml
dependencies:
tray_manager: ^0.2.3
tray_manager: ^0.3.0
```
Or
Expand Down
4 changes: 4 additions & 0 deletions packages/tray_manager/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 0.3.0

* chore: Add `bringAppToFront` param to `popUpContextMenu` method (#58)

## 0.2.4

* [windows][bug] fix the crash bug on windows targeting c++20 (#47)
Expand Down
2 changes: 2 additions & 0 deletions packages/tray_manager/example/lib/pages/home.dart
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// ignore_for_file: deprecated_member_use

import 'dart:async';
import 'dart:io';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import Cocoa
import FlutterMacOS

@NSApplicationMain
@main
class AppDelegate: FlutterAppDelegate {
override func applicationShouldTerminateAfterLastWindowClosed(_ sender: NSApplication) -> Bool {
return true
Expand Down
10 changes: 9 additions & 1 deletion packages/tray_manager/lib/src/tray_manager.dart
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,15 @@ class TrayManager {
}

/// Pops up the context menu of the tray icon.
Future<void> popUpContextMenu({bool bringAppToFront = false}) async {
///
/// [bringAppToFront] If true, the app will be brought to the front when the
/// context menu is shown. Only works on Windows.
Future<void> popUpContextMenu({
@Deprecated(
'This parameter is only supported on Windows and will be removed in the future.',
)
bool bringAppToFront = false,
}) async {
final Map<String, dynamic> arguments = {
'bringAppToFront': bringAppToFront,
};
Expand Down
2 changes: 1 addition & 1 deletion packages/tray_manager/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: tray_manager
description: This plugin allows Flutter desktop apps to defines system tray.
version: 0.2.4
version: 0.3.0
homepage: https://github.com/leanflutter/tray_manager

platforms:
Expand Down

0 comments on commit 2bbfab7

Please sign in to comment.