Skip to content

WMainMenuBar: Simplify and Fix PDF detection#22

Merged
ronso0 merged 2 commits into
ronso0:keyboard-shortcut-pdffrom
Holzhaus:keyboard-shortcut-pdf
Mar 30, 2021
Merged

WMainMenuBar: Simplify and Fix PDF detection#22
ronso0 merged 2 commits into
ronso0:keyboard-shortcut-pdffrom
Holzhaus:keyboard-shortcut-pdf

Conversation

@Holzhaus
Copy link
Copy Markdown

This makes the PDF detection code for WMainMenuBar easier to grasp and also fixes the issue that local PDFs are not detected when running mixxx from the build dir without an installation.

@Holzhaus Holzhaus force-pushed the keyboard-shortcut-pdf branch from c608dce to fb801a9 Compare March 30, 2021 00:00
Comment thread src/config.h.in
@@ -0,0 +1 @@
#cmakedefine MIXXX_INSTALL_DOCDIR_RELATIVE_TO_DATADIR "@MIXXX_INSTALL_DOCDIR_RELATIVE_TO_DATADIR@"
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

interesting, I wasn't aware that we can use cmake vars in the actual project code.
somehow I considered those two entirely separate 'things'

Copy link
Copy Markdown
Author

@Holzhaus Holzhaus Mar 30, 2021

Choose a reason for hiding this comment

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

We can use them via configure_file or target_compile_definitions. The #cmakedefine is like a regular #define except that it maps to undef if the variable is not set.

@ronso0
Copy link
Copy Markdown
Owner

ronso0 commented Mar 30, 2021

Thank you, works nicely!

admittedly I was just too lazy to separate the doc detection..thx

@ronso0 ronso0 merged commit 6e1d3f6 into ronso0:keyboard-shortcut-pdf Mar 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants