Robbert van der Helm
49fc896d62
Remove Win32 effEditIdle() timer
...
Now Editor is completely decoupled from VST2.
2020-12-19 23:30:47 +01:00
Robbert van der Helm
a724b378fe
Move the editor handling back to Vst2Bridge
...
Since we can have multiple editors in Vst3Bridge.
2020-12-19 19:56:49 +01:00
Robbert van der Helm
d485aa296a
Fix VST2-only builds
2020-12-07 18:28:17 +01:00
Robbert van der Helm
76ad377522
Don't set __MINGW32__
...
This took me a few hours of non-stop headaches to figure out. Apparently
deep inside of Wine's headers having __MINGW32__ defined will cause some
GUIDs to be defined slightly differently. This normally wouldn't cause
issues, but when including `shellobj.h` or `objbase.h` this results in
multiple definition linking errors that are basically impossible to
diagnose.
2020-12-07 18:28:16 +01:00
Robbert van der Helm
715a95075b
Add required compiler args to the Wine VST3 dep
2020-12-07 18:28:16 +01:00
Robbert van der Helm
41da621e29
Add a todo for decoupling Editor from VST2
2020-12-07 18:28:16 +01:00
Robbert van der Helm
e08162fabf
Silence warnings on decltype() with Wine 5.22
...
There were already similar warnings on 32-bit winegcc, but now it also
happens on the 64-bit version. Instead of adding
`-Wno-ignored-attributes` we'll just sprinkle some warning ignores here
and there to prevent any other surprises.
2020-11-30 14:05:48 +01:00
Robbert van der Helm
a1e7142f17
Mark max_win32_messages as [[maybe_unused]]
...
ccls/clangd doesn't know that it's being used elsewhere.
2020-10-25 13:00:50 +01:00
Robbert van der Helm
3facdf532a
Fix fake dropdown menus in TDR plugins
...
These would close immediately when hovering over them with the new focus
grabbing method.
2020-10-19 14:34:52 +02:00
Robbert van der Helm
225d6a000e
Add a fallback for non-EWMH compliant WMs
...
I'm not sure how many people use WMs that don't implement
`_NET_ACTIVE_WINDOW`, but at least this will give those people some way
to grab input focus, even if it's not as good as the new method.
2020-10-09 14:35:43 +02:00
Robbert van der Helm
6ff61b1904
Rewrite how input focus grabbing works #38
2020-10-08 19:34:26 +02:00
Robbert van der Helm
e680f2eddd
Made the input focus grabbing even more aggressive
...
This fixes keyboard focus not returning when closing dialogs in Melda
plugins. I'll have to do some more testing to see if this does not
introduce any unwanted side effects.
2020-10-08 15:51:20 +02:00
Robbert van der Helm
8ae9c4d263
Made input focus grabbing more aggressive #38
...
This fixes keyboard input in REAPER, and I haven't found any downsides
to this approach yet.
2020-09-30 17:30:38 +02:00
Robbert van der Helm
becb73928e
Add a limit to all Win32 message loops #28
...
This works around Waves plugins causing an infinite message loop. Since
we run the loop 30 times per second anyways splitting the loop up into
chunks of 20 shouldn't be an issue.
2020-08-14 11:36:55 +02:00
Robbert van der Helm
b1dd301a98
Add an optional double editor embedding mode #27
...
This sounds like it would the simplest way to work around the issue of
E27 calculating its own coordinates based on the parent window's
coordinates. I have not noticed any weird issues with having this
enabled all the time, but less moving parts is always better so it's
still behind an option.
2020-07-23 16:56:10 +02:00
Robbert van der Helm
8202a6b250
Add missing const qualifiers to member functions
2020-06-06 13:44:26 +02:00
Robbert van der Helm
957da62137
Add missing type qualifiers
2020-06-06 13:44:23 +02:00
Robbert van der Helm
00bcdf8fca
Add a RAII wrapper around SetTimer()
2020-05-28 15:27:45 +02:00
Robbert van der Helm
276e4ac02f
Make the local coordinate fix more robust
...
Without this fix and when using plugin groups, hovering over an opened
window that has not yet been interacted with shows some weird behavior.
2020-05-27 14:29:31 +02:00
Robbert van der Helm
d65281d691
Clarify local coordinate fix function name
2020-05-27 13:50:52 +02:00
Robbert van der Helm
ab4d35886e
Add a fix for the keyboard focus in Bitwig 3.2
2020-05-26 19:39:51 +02:00
Robbert van der Helm
9a35023990
Split X11 and Win32 event handling
...
X11 events should always be handled since it's thread safe and they
don't block.
2020-05-26 11:11:34 +02:00
Robbert van der Helm
9c6fc78471
Fix editor window handling in Reaper
...
And other hosts that embed the parent window into another window.
2020-05-02 18:28:43 +02:00
Robbert van der Helm
8adb944445
Use maximum display resolution for the window size
...
Instead of it being hardcoded to 1440p.
2020-04-28 11:47:39 +02:00
Robbert van der Helm
4b84f663ab
Always run the event loop, fixing processing issue
...
Also remove any special `effEditIdle` handling.
Apparently plugins rely on the message loop for their internal tasks,
even for things that have nothing to do with GUIs, such as deferring
initialization.
2020-04-27 18:53:06 +02:00
Robbert van der Helm
0efdd1a790
Add missing license headers
2020-04-24 15:41:18 +02:00
Robbert van der Helm
d2bf5c35a4
Fix hanging when closing the editor
2020-04-21 16:56:36 +02:00
Robbert van der Helm
421ed21901
Get rid of now no longer needed synchronisation
...
This was mostly a workaround to get Serum to not crash when audio was
being processed during a specific point of its `WM_PAINT` message
handler. This is no longer needed when using `CreateThread` instead of
`std::thread`.
2020-04-20 23:36:17 +02:00
Robbert van der Helm
1a6a094c2b
Fix reopening closed editor windows
2020-04-19 20:36:39 +02:00
Robbert van der Helm
f235bdf9a1
Fix GUI related data races within Serum
2020-04-19 15:16:51 +02:00
Robbert van der Helm
03de09d77f
Clean up the editor implementation
2020-04-14 16:51:24 +02:00
Robbert van der Helm
266674a217
Get rid of all SetWindowPos() calls
...
This actually resizes the client area, but the experience feels way
better if we just leave it at its maximum size.
2020-04-13 13:54:34 +02:00
Robbert van der Helm
c0eafc85fd
Re-introduce window resizing while draggin
2020-04-12 19:42:12 +02:00
Robbert van der Helm
3850e39777
Resize the window together with ConfigureNotify
...
This way we need less hacks and things can't get out of sync.
2020-04-12 19:15:28 +02:00
Robbert van der Helm
e1cc342bd0
Work around local<->global coordinate issues
...
For reparented Wine windows. This is a similar approach as LinVST uses.
2020-04-12 18:24:33 +02:00
Robbert van der Helm
c2e62b30ca
Strip out everything related to XEmbed
...
We'll just go with the same workaroud LinVST uses isntead. It's not as
pretty but it does work a lot better.
2020-04-11 14:06:47 +02:00
Robbert van der Helm
e8fc990f0b
Add a less hacky workaround for the XEmbed issues
2020-04-09 18:21:16 +02:00
Robbert van der Helm
fa045fb770
Delay the XEmbed messages
...
This works, but we now have the same issues with flickering and resizing
found in some other implementations such as Airwave.
2020-03-30 00:47:46 +02:00
Robbert van der Helm
8ec0ed4c3c
Allow GUIs to optionally update on a timer
...
Otherwise plugins can't update their editors when the GUI is being blocked.
2020-03-28 18:03:20 +01:00
Robbert van der Helm
2e44de6f49
Add a function for sending XEMBED messages
2020-03-21 16:32:39 +01:00
Robbert van der Helm
50f26d1238
Implement part of the XEmbed protocol
2020-03-20 22:56:04 +01:00
Robbert van der Helm
4ae1f03e4c
Simplify GUI event handling
2020-03-19 21:37:16 +01:00
Robbert van der Helm
f1f7523248
Make the GUI embedding work
...
There's still a few things that need fixing.
2020-03-19 17:29:30 +01:00
Robbert van der Helm
ede14ece3b
Add the start of reparenting the editor windows
2020-03-17 23:04:09 +01:00
Robbert van der Helm
f3bf7879c6
Finish renaming win32-editor.h
2020-03-17 22:13:30 +01:00
Robbert van der Helm
f43c0bc78b
Fix xcb include
2020-03-17 22:11:57 +01:00
Robbert van der Helm
70ebb5d243
Replace Xlib with xcb
2020-03-17 22:08:44 +01:00
Robbert van der Helm
e2d8c0883f
Rename win32-editor.h -> editor.h
...
Since I no longer intent to do separate X11 handling on the plugin side
2020-03-17 21:37:53 +01:00