Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .github/workflows/flutter-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,16 @@ jobs:
sudo snap install --dangerous
"${{ steps.snapcraft.outputs.snap }}"

- name: Verify GTK SVG icon loader
run: |
snap run --shell busymark -c '
test ! -e \
"$SNAP/usr/lib/$SNAP_LAUNCHER_ARCH_TRIPLET/librsvg-2.so.2"
query="$SNAP_DESKTOP_RUNTIME/usr/lib/$SNAP_LAUNCHER_ARCH_TRIPLET/gdk-pixbuf-2.0/gdk-pixbuf-query-loaders"
loader="$SNAP_DESKTOP_RUNTIME/usr/lib/$SNAP_LAUNCHER_ARCH_TRIPLET/gdk-pixbuf-2.0/2.10.0/loaders/libpixbufloader_svg.so"
"$query" "$loader" | grep -q "\"svg\" 6 \"gdk-pixbuf\""
'

- name: Exercise strict Snap visualization and PDF paths under X11
run: |
report="$HOME/snap/busymark/common/visualization-release-x11.json"
Expand Down
1 change: 1 addition & 0 deletions lib/l10n/app_ar.arb
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@
"@reading": {
"description": "Reading view label."
},
"removeFromRecent": "إزالة من الأخيرة",
"recent": "الأخيرة",
"@recent": {
"description": "Recent workspaces section title."
Expand Down
1 change: 1 addition & 0 deletions lib/l10n/app_de.arb
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@
"@reading": {
"description": "Reading view label."
},
"removeFromRecent": "Aus „Zuletzt verwendet“ entfernen",
"recent": "Zuletzt verwendet",
"@recent": {
"description": "Recent workspaces section title."
Expand Down
2 changes: 2 additions & 0 deletions lib/l10n/app_en.arb
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,8 @@
"@pasteWithoutFormatting": {"description": "Plain text paste command label."},
"reading": "Reading",
"@reading": {"description": "Reading view label."},
"removeFromRecent": "Remove from Recent",
"@removeFromRecent": {"description": "Action that removes a workspace from the Recent list without deleting its files."},
"recent": "Recent",
"@recent": {"description": "Recent workspaces section title."},
"redo": "Redo",
Expand Down
1 change: 1 addition & 0 deletions lib/l10n/app_es.arb
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@
"@reading": {
"description": "Reading view label."
},
"removeFromRecent": "Quitar de Recientes",
"recent": "Recientes",
"@recent": {
"description": "Recent workspaces section title."
Expand Down
1 change: 1 addition & 0 deletions lib/l10n/app_et.arb
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,7 @@
"@pasteWithoutFormatting": {"description": "Plain text paste command label."},
"reading": "Lugemisvaade",
"@reading": {"description": "Reading view label."},
"removeFromRecent": "Eemalda hiljutiste seast",
"recent": "Hiljutised",
"@recent": {"description": "Recent workspaces section title."},
"redo": "Tee uuesti",
Expand Down
1 change: 1 addition & 0 deletions lib/l10n/app_fa.arb
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@
"@reading": {
"description": "Reading view label."
},
"removeFromRecent": "حذف از موارد اخیر",
"recent": "موارد اخیر",
"@recent": {
"description": "Recent workspaces section title."
Expand Down
1 change: 1 addition & 0 deletions lib/l10n/app_fr.arb
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@
"@reading": {
"description": "Reading view label."
},
"removeFromRecent": "Retirer des éléments récents",
"recent": "Récents",
"@recent": {
"description": "Recent workspaces section title."
Expand Down
1 change: 1 addition & 0 deletions lib/l10n/app_hi.arb
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@
"@reading": {
"description": "Reading view label."
},
"removeFromRecent": "हालिया से हटाएँ",
"recent": "हालिया",
"@recent": {
"description": "Recent workspaces section title."
Expand Down
1 change: 1 addition & 0 deletions lib/l10n/app_it.arb
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@
"@reading": {
"description": "Reading view label."
},
"removeFromRecent": "Rimuovi dai recenti",
"recent": "Recenti",
"@recent": {
"description": "Recent workspaces section title."
Expand Down
1 change: 1 addition & 0 deletions lib/l10n/app_nb.arb
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@
"@reading": {
"description": "Reading view label."
},
"removeFromRecent": "Fjern fra nylige",
"recent": "Nylige",
"@recent": {
"description": "Recent workspaces section title."
Expand Down
1 change: 1 addition & 0 deletions lib/l10n/app_pl.arb
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@
"@reading": {
"description": "Reading view label."
},
"removeFromRecent": "Usuń z ostatnich",
"recent": "Ostatnie",
"@recent": {
"description": "Recent workspaces section title."
Expand Down
1 change: 1 addition & 0 deletions lib/l10n/app_pt.arb
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@
"@reading": {
"description": "Reading view label."
},
"removeFromRecent": "Remover dos recentes",
"recent": "Recentes",
"@recent": {
"description": "Recent workspaces section title."
Expand Down
1 change: 1 addition & 0 deletions lib/l10n/app_ru.arb
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@
"@reading": {
"description": "Reading view label."
},
"removeFromRecent": "Удалить из недавних",
"recent": "Недавние",
"@recent": {
"description": "Recent workspaces section title."
Expand Down
1 change: 1 addition & 0 deletions lib/l10n/app_uk.arb
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@
"@reading": {
"description": "Reading view label."
},
"removeFromRecent": "Вилучити з нещодавніх",
"recent": "Останні",
"@recent": {
"description": "Recent workspaces section title."
Expand Down
6 changes: 6 additions & 0 deletions lib/l10n/generated/app_localizations.dart
Original file line number Diff line number Diff line change
Expand Up @@ -609,6 +609,12 @@ abstract class AppLocalizations {
/// **'Reading'**
String get reading;

/// Action that removes a workspace from the Recent list without deleting its files.
///
/// In en, this message translates to:
/// **'Remove from Recent'**
String get removeFromRecent;

/// Recent workspaces section title.
///
/// In en, this message translates to:
Expand Down
3 changes: 3 additions & 0 deletions lib/l10n/generated/app_localizations_ar.dart
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,9 @@ class AppLocalizationsAr extends AppLocalizations {
@override
String get reading => 'وضع القراءة';

@override
String get removeFromRecent => 'إزالة من الأخيرة';

@override
String get recent => 'الأخيرة';

Expand Down
3 changes: 3 additions & 0 deletions lib/l10n/generated/app_localizations_de.dart
Original file line number Diff line number Diff line change
Expand Up @@ -270,6 +270,9 @@ class AppLocalizationsDe extends AppLocalizations {
@override
String get reading => 'Leseansicht';

@override
String get removeFromRecent => 'Aus „Zuletzt verwendet“ entfernen';

@override
String get recent => 'Zuletzt verwendet';

Expand Down
3 changes: 3 additions & 0 deletions lib/l10n/generated/app_localizations_en.dart
Original file line number Diff line number Diff line change
Expand Up @@ -267,6 +267,9 @@ class AppLocalizationsEn extends AppLocalizations {
@override
String get reading => 'Reading';

@override
String get removeFromRecent => 'Remove from Recent';

@override
String get recent => 'Recent';

Expand Down
3 changes: 3 additions & 0 deletions lib/l10n/generated/app_localizations_es.dart
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,9 @@ class AppLocalizationsEs extends AppLocalizations {
@override
String get reading => 'Lectura';

@override
String get removeFromRecent => 'Quitar de Recientes';

@override
String get recent => 'Recientes';

Expand Down
3 changes: 3 additions & 0 deletions lib/l10n/generated/app_localizations_et.dart
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,9 @@ class AppLocalizationsEt extends AppLocalizations {
@override
String get reading => 'Lugemisvaade';

@override
String get removeFromRecent => 'Eemalda hiljutiste seast';

@override
String get recent => 'Hiljutised';

Expand Down
3 changes: 3 additions & 0 deletions lib/l10n/generated/app_localizations_fa.dart
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,9 @@ class AppLocalizationsFa extends AppLocalizations {
@override
String get reading => 'حالت مطالعه';

@override
String get removeFromRecent => 'حذف از موارد اخیر';

@override
String get recent => 'موارد اخیر';

Expand Down
3 changes: 3 additions & 0 deletions lib/l10n/generated/app_localizations_fr.dart
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,9 @@ class AppLocalizationsFr extends AppLocalizations {
@override
String get reading => 'Lecture';

@override
String get removeFromRecent => 'Retirer des éléments récents';

@override
String get recent => 'Récents';

Expand Down
3 changes: 3 additions & 0 deletions lib/l10n/generated/app_localizations_hi.dart
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,9 @@ class AppLocalizationsHi extends AppLocalizations {
@override
String get reading => 'पठन दृश्य';

@override
String get removeFromRecent => 'हालिया से हटाएँ';

@override
String get recent => 'हालिया';

Expand Down
3 changes: 3 additions & 0 deletions lib/l10n/generated/app_localizations_it.dart
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,9 @@ class AppLocalizationsIt extends AppLocalizations {
@override
String get reading => 'Lettura';

@override
String get removeFromRecent => 'Rimuovi dai recenti';

@override
String get recent => 'Recenti';

Expand Down
3 changes: 3 additions & 0 deletions lib/l10n/generated/app_localizations_nb.dart
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,9 @@ class AppLocalizationsNb extends AppLocalizations {
@override
String get reading => 'Lesevisning';

@override
String get removeFromRecent => 'Fjern fra nylige';

@override
String get recent => 'Nylige';

Expand Down
3 changes: 3 additions & 0 deletions lib/l10n/generated/app_localizations_pl.dart
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,9 @@ class AppLocalizationsPl extends AppLocalizations {
@override
String get reading => 'Widok do czytania';

@override
String get removeFromRecent => 'Usuń z ostatnich';

@override
String get recent => 'Ostatnie';

Expand Down
3 changes: 3 additions & 0 deletions lib/l10n/generated/app_localizations_pt.dart
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,9 @@ class AppLocalizationsPt extends AppLocalizations {
@override
String get reading => 'Leitura';

@override
String get removeFromRecent => 'Remover dos recentes';

@override
String get recent => 'Recentes';

Expand Down
3 changes: 3 additions & 0 deletions lib/l10n/generated/app_localizations_ru.dart
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,9 @@ class AppLocalizationsRu extends AppLocalizations {
@override
String get reading => 'Режим чтения';

@override
String get removeFromRecent => 'Удалить из недавних';

@override
String get recent => 'Недавние';

Expand Down
3 changes: 3 additions & 0 deletions lib/l10n/generated/app_localizations_uk.dart
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,9 @@ class AppLocalizationsUk extends AppLocalizations {
@override
String get reading => 'Режим читання';

@override
String get removeFromRecent => 'Вилучити з нещодавніх';

@override
String get recent => 'Останні';

Expand Down
2 changes: 1 addition & 1 deletion lib/src/app/app_metadata.dart
Original file line number Diff line number Diff line change
@@ -1 +1 @@
const busyMarkAppVersion = '0.3.1';
const busyMarkAppVersion = '0.3.2';
11 changes: 11 additions & 0 deletions lib/src/app/app_settings.dart
Original file line number Diff line number Diff line change
Expand Up @@ -752,6 +752,17 @@ class AppSettingsController extends Notifier<AppSettings> {
return _mutate((settings) => settings.copyWith(recentWorkspaces: []));
}

Future<void> removeRecentWorkspace(String path) {
return _mutate(
(settings) => settings.copyWith(
recentWorkspaces: [
for (final item in settings.recentWorkspaces)
if (!p.equals(item.path, path)) item,
],
),
);
}

Future<void> _load() async {
AppSettings loaded;
try {
Expand Down
18 changes: 17 additions & 1 deletion lib/src/app/busymark_design.dart
Original file line number Diff line number Diff line change
Expand Up @@ -1088,6 +1088,7 @@ class BusyMarkCompactIconButton extends StatelessWidget {
this.size = BusyMarkSizes.compactIconButton,
this.glyphSize = BusyMarkSizes.compactIcon,
this.foregroundColor,
this.focusNode,
});

final String tooltip;
Expand All @@ -1096,6 +1097,7 @@ class BusyMarkCompactIconButton extends StatelessWidget {
final double size;
final double glyphSize;
final Color? foregroundColor;
final FocusNode? focusNode;

@override
Widget build(BuildContext context) {
Expand All @@ -1120,6 +1122,7 @@ class BusyMarkCompactIconButton extends StatelessWidget {
constraints: BoxConstraints.tightFor(width: size, height: size),
padding: EdgeInsets.zero,
style: semanticStyle.merge(yaruDefaults),
focusNode: focusNode,
onPressed: onPressed,
);
return YaruTheme.maybeOf(context)?.focusBorders == true
Expand Down Expand Up @@ -1714,7 +1717,8 @@ class _BusyMarkMenuButtonState<T> extends State<BusyMarkMenuButton<T>> {
if (!widget.enabled || event is! KeyDownEvent) {
return KeyEventResult.ignored;
}
if (event.logicalKey == LogicalKeyboardKey.arrowDown ||
if (isBusyMarkContextMenuKeyEvent(event) ||
event.logicalKey == LogicalKeyboardKey.arrowDown ||
event.logicalKey == LogicalKeyboardKey.enter ||
event.logicalKey == LogicalKeyboardKey.space) {
if (!_open) {
Expand Down Expand Up @@ -1789,6 +1793,18 @@ class _BusyMarkMenuButtonState<T> extends State<BusyMarkMenuButton<T>> {
}
}

/// Whether [event] is the standard desktop request for an item context menu.
///
/// Linux applications conventionally support both the Menu key and Shift+F10.
bool isBusyMarkContextMenuKeyEvent(KeyEvent event) {
if (event is! KeyDownEvent) {
return false;
}
return event.logicalKey == LogicalKeyboardKey.contextMenu ||
(event.logicalKey == LogicalKeyboardKey.f10 &&
HardwareKeyboard.instance.isShiftPressed);
}

class BusyMarkPopupSelectorOption<T> {
const BusyMarkPopupSelectorOption({
required this.value,
Expand Down
Loading
Loading