-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Smooth shutdown #4109
Smooth shutdown #4109
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good so far. I just added some comments that came to my mind.
} | ||
// On Linux, Java FX fonts look blurry per default. This can be improved by using a non-default rendering | ||
// setting. See https://github.com/woky/javafx-hates-linux | ||
if (Globals.prefs.getBoolean(JabRefPreferences.FX_FONT_RENDERING_TWEAK)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a Linux switch anywhere?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, it is turned on by default only on Linux: defaults.put(FX_FONT_RENDERING_TWEAK, OS.LINUX);
|
||
private static final Logger LOGGER = LoggerFactory.getLogger(ClipBoardManager.class); | ||
public static final DataFormat XML = new DataFormat("application/xml"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this used anywhere?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, when we put xml in the clipboard (which may happen for copied citation styles)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, when we put xml in the clipboard (which may happen for copied citation styles)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have already a class DragAndDropDataFormats, maybe you could rename that and add it to the collection?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't want to interfere with your PR (especially, since I think it might completely remove the DragAndDropFormats
class or make it internal to the DragAndDropManager
).
import org.jabref.logic.l10n.Localization; | ||
import org.jabref.logic.util.BuildInfo; | ||
|
||
public class CopyVersionToClipboardAction extends AbstractAction { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Functionality totally removed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is still a "copy version" button in the about dialog but no separate menu entry. (I didn't change anything as part of this PR; this class was completely unused).
|
||
public class ClipBoardManagerTest { | ||
|
||
private ClipBoardManager clipBoardManager; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What about the tests?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The clipboard manager needs to run on the JavaFX thread to work, which is not easily achieved in a test. Thus, deleting these tests was easier than trying to rewrite them ;-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So we use this insetad of the PR of Christoph?!
client.trackSessionState(SessionState.End); | ||
client.flush(); | ||
|
||
// Workaround for bug https://github.com/Microsoft/ApplicationInsights-Java/issues/662 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add FIXME so we can revert this after they merged the bug fix.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I really would use my PR as a base. As this done does more than the initial necessary solution.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't understand the complication (including merge conflicts) but well it doesn't really matter. @Siedlerchr @stefan-kolb can I merge this PR?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Guess so.
Your PR caused this error now
|
And removing setting the font size without providing an alternative was not the good idea! |
Just revert If necessary.
Christoph <notifications@github.com> schrieb am Do., 14. Juni 2018, 12:28:
… And removing setting the font size without providing an alternative was
not the good idea!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#4109 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ACCtQ3fuo3W04385wQK074uTX3G36Wgeks5t8jqwgaJpZM4UcxAw>
.
|
Sorry, I was so used to failing tests against the maintable-branch that I ignored the red travis icon. Tests are now fixed in master. |
I tried to remove the
System.exit
call so that JabRef shutdown smoothly. However, currently an AWT-thread does not want to exit. In order to solve this problem, I removed most calls that would init the AWT toolkit. This includes:Moreover, the Azure telemetry SDK has a bug microsoft/ApplicationInsights-Java#662 that prevents certain threads from terminating. I added the workaround mentioned in this issue.