@@ -133,23 +133,19 @@ private void export(Path file, FileChooser.ExtensionFilter selectedExtensionFilt
133
133
return null ; // can not use BackgroundTask.wrap(Runnable) because Runnable.run() can't throw Exceptions
134
134
})
135
135
.onSuccess (save -> {
136
- boolean currentTabIsLibraryTab = tabSupplier .get () != null ;
137
- // libraryTab is null in case of Welcome Tab
138
- if (currentTabIsLibraryTab ) {
139
- LibraryTab .DatabaseNotification notificationPane = tabSupplier .get ().getNotificationPane ();
140
- notificationPane .notify (
141
- IconTheme .JabRefIcons .FOLDER .getGraphicNode (),
142
- Localization .lang ("Export operation finished successfully." ),
143
- List .of (new Action (Localization .lang ("Reveal in File Explorer" ), event -> {
144
- try {
145
- NativeDesktop .openFolderAndSelectFile (file , preferences .getExternalApplicationsPreferences (), dialogService );
146
- } catch (IOException e ) {
147
- LOGGER .error ("Could not open export folder." , e );
148
- }
149
- notificationPane .hide ();
150
- })),
151
- Duration .seconds (5 ));
152
- }
136
+ LibraryTab .DatabaseNotification notificationPane = tabSupplier .get ().getNotificationPane ();
137
+ notificationPane .notify (
138
+ IconTheme .JabRefIcons .FOLDER .getGraphicNode (),
139
+ Localization .lang ("Export operation finished successfully." ),
140
+ List .of (new Action (Localization .lang ("Reveal in File Explorer" ), event -> {
141
+ try {
142
+ NativeDesktop .openFolderAndSelectFile (file , preferences .getExternalApplicationsPreferences (), dialogService );
143
+ } catch (IOException e ) {
144
+ LOGGER .error ("Could not open export folder." , e );
145
+ }
146
+ notificationPane .hide ();
147
+ })),
148
+ Duration .seconds (5 ));
153
149
})
154
150
.onFailure (this ::handleError )
155
151
.executeWith (taskExecutor );
0 commit comments