hot_key.dart 424 B

1234567891011121314151617
  1. import 'package:appflowy_editor/appflowy_editor.dart';
  2. import 'package:hotkey_manager/hotkey_manager.dart';
  3. import '../startup.dart';
  4. class HotKeyTask extends LaunchTask {
  5. const HotKeyTask();
  6. @override
  7. Future<void> initialize(LaunchContext context) async {
  8. // the hotkey manager is not supported on mobile
  9. if (PlatformExtension.isMobile) {
  10. return;
  11. }
  12. await hotKeyManager.unregisterAll();
  13. }
  14. }