Skip to content
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

Set BibEntry to "changed" state before setting a new entry type #5966

Merged
merged 2 commits into from
Feb 21, 2020

Conversation

dawidm
Copy link
Contributor

@dawidm dawidm commented Feb 20, 2020

fixes #5905

The issue happens because changed property in BibEntry is set after updating entry type, so property listeners get entry object with new entry type but changed value set to false. Because of that wrong bibtex code is generated by:
entry.typeProperty().addListener(listener -> updateCodeArea()); (SourceTab.java).

@calixtus
Copy link
Member

Cool, you found the problem. Thanks! LGTM

Copy link
Member

@tobiasdiez tobiasdiez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! That also explains why the error only occurs the first time.

Could you please add a changelog entry, then we can merge!

@koppor koppor added this to the v5.0 milestone Feb 20, 2020
@dawidm dawidm requested a review from tobiasdiez February 21, 2020 10:46
@Siedlerchr Siedlerchr merged commit 258dcef into JabRef:master Feb 21, 2020
@Siedlerchr
Copy link
Member

Thanks again for your contribution! 👍

Siedlerchr added a commit that referenced this pull request Mar 6, 2020
* upstream/master: (21 commits)
  Update module description (#5999)
  New Crowdin translations (#5990)
  Fix NPE in OpenAccessDoi (#5994)
  Move generate BibTeX keys to Edit menu (#5987)
  Fixed display of groups and links column in MainTable (#5985)
  Fixed loosing group if the most bottom one in list is dragged on itself (#5983)
  Dividers (#5975)
  Add initial section on code quality (#5991)
  Create .sonarcloud.properties
  Add new IntelliJ video tutorial to docs. (#5984)
  Fix checkstyle
  Optimize stream() code
  Use application/x-bibtex for Grobid instance
  New Crowdin translations (#5971)
  Set BibEntry to "changed" state before setting a new entry type (#5966)
  Rework tools menu (#5979)
  Help menu (#5976)
  Fixed formatting
  Refactored subtile changes to optics of library properties (#5969)
  Change grobid URL to jabref subdomain (#5972)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Changing entry type does not work when biblatex source is shown
5 participants