Created
September 29, 2020 10:31
-
-
Save thoroc/bc17ab75c3f822015e4d6a48ffff7b68 to your computer and use it in GitHub Desktop.
Comments by a developer inside the Windows Media Player source code see https://pastebin.com/PTLeWhc2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[...] | |
/* RouteKeyPresses | |
* | |
* Reroutes cursor keys etc to track bar. | |
*/ | |
void RouteKeyPresses(PMSG pMsg) | |
{ | |
/* Hack for PowerPoint | |
* | |
* Mail from PaulWa: | |
* | |
* -------- | |
* Here's a problem you might consider fixing. | |
* Launching Media Player with certain keystrokes | |
* doesn't work right (e.g. arrow keys, page up/down, | |
* etc.). | |
* | |
* The problem is due to the fact that Media Player | |
* handles key up events. We use the key down event | |
* to launch the server in slideshow, but then the key | |
* up event is passed to the server. It would probably | |
* be best for Media Player to ignore key up events | |
* unless it had previously received a key down. | |
* If this is very difficult to fix in Media Player, | |
* then we can fix it in PP by launching servers on | |
* key up rather than key down. However, other container | |
* apps will see the same problem. | |
* -------- | |
* | |
* OK, in the spirit of cooperation, let's hack things | |
* so our PowerPoint friends can carry on with their | |
* dubious practices. | |
*/ | |
static WPARAM LastVKeyDown; | |
[...] | |
if (rMsg.message == WM_TIMER && rMsg.hwnd == NULL) { | |
#ifdef CHICAGO_PRODUCT | |
/* The reason for requiring the following test is now lost | |
* in the mists of time. Now this app is 32-bit, these | |
* bogus timer callbacks (if they really do still occur) | |
* could be 16-bit, so we need to add yet more ugliness | |
* in the form of assembler to an app which is already | |
* hardly a paragon of pulchritude. | |
* | |
* A plea: | |
* | |
* If you add some obscure code such as below, to this or | |
* any other app, even if it has only the teeniest chance | |
* of being less blindingly obvious to someone else than | |
* it is to you at the time of writing, please please please | |
* add a f***ing comment. | |
* | |
* Respectfully, | |
* A Developer | |
*/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment