The Clone function seem unused, the AcceptsFocus and HasFocus
functions are marked as const and Show is renamed to ShowAddr
to not conflict with unrelated functions.
[187/196] Building CXX object src/wx/CMakeFiles/visualboyadvance-m.dir/viewsupt.cpp.o
In file included from ../src/wx/viewsupt.cpp:1:
../src/wx/viewsupt.h:197:10: warning: 'Viewers::MemView::Show' hides overloaded virtual function [-Woverloaded-virtual]
void Show(uint32_t addr, bool force_update = false);
^
/usr/include/wx-3.0/wx/gtk/window.h:64:18: note: hidden overloaded virtual function 'wxWindow::Show' declared here: different number of parameters (1 vs 2)
virtual bool Show( bool show = true );
^
In file included from ../src/wx/viewsupt.cpp:1:
../src/wx/viewsupt.h:410:10: warning: 'Viewers::DispCheckBox::AcceptsFocus' hides overloaded virtual function [-Woverloaded-virtual]
bool AcceptsFocus()
^
/usr/include/wx-3.0/wx/window.h:724:18: note: hidden overloaded virtual function 'wxWindowBase::AcceptsFocus' declared here: different qualifiers ('const' vs unqualified)
virtual bool AcceptsFocus() const { return true; }
^
In file included from ../src/wx/viewsupt.cpp:3:
In file included from ../src/wx/wxvbam.h:14:
In file included from ../src/wx/widgets/wx/joyedit.h:9:
../src/wx/widgets/wx/sdljoy.h:115:14: warning: 'wxSDLJoyEvent::Clone' hides overloaded virtual function [-Woverloaded-virtual]
wxEvent* Clone();
^
/usr/include/wx-3.0/wx/event.h:1569:22: note: hidden overloaded virtual function 'wxCommandEvent::Clone' declared here: different qualifiers ('const' vs unqualified)
virtual wxEvent *Clone() const { return new wxCommandEvent(*this); }
^
In file included from ../src/wx/viewsupt.cpp:3:
../src/wx/wxvbam.h:286:10: warning: 'MainFrame::HasFocus' hides overloaded virtual function [-Woverloaded-virtual]
bool HasFocus()
^
/usr/include/wx-3.0/wx/window.h:715:18: note: hidden overloaded virtual function 'wxWindowBase::HasFocus' declared here: different qualifiers ('const' vs unqualified)
virtual bool HasFocus() const;
^
4 warnings generated.
[79/196] Building CXX object fex/CMakeFiles/fex.dir/fex/Zlib_Inflater.cpp.o
In file included from ../fex/fex/Zlib_Inflater.cpp:3:
In file included from ../fex/fex/Zlib_Inflater.h:7:
In file included from ../fex/fex/Data_Reader.h:7:
In file included from ../fex/fex/blargg_common.h:8:
In file included from /usr/include/assert.h:35:
/usr/include/features.h:382:4: warning: _FORTIFY_SOURCE requires compiling with optimization (-O) [-W#warnings]
^
1 warning generated.
Call `rtcEnableRumble(true);` always regardless of the `rtcEnabled`
option, because @negativeExponent points out that they are unrelated.
Check for at least SDL version `2.0.9` before using the
`SDL_JoystickRumble()` API, since it is not present in earlier versions.
Increase rumble duration to twice the poll time to keep the motors
running, subsequent poll events will cancel the rumble as necessary.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Call `rtcEnableRumble()` in the core if the rtc is enabled during ROM
loading.
On `systemCartridgeRumble(bool)` events from the core, set the state in
`wxSDLJoy` accordingly, to either rumbling or not rumbling based on the
boolean parameter.
On the `50ms` joystick poll events, use `SDL_JoystickRumble()` to enable
rumble on both the low and high frequencies at maximum for the poll time
of `50ms`, to be set or reset again on the next poll event.
Tested in Drill Dozer, rumbling is being activated. Will need testing
from users as well to see if this is implemented correctly.
Fix#522.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
All keys were being captured before being processed by any window of the
app to check for accelerators. This meant being impossible to use any
keys for input if they were saved for an accel.
- Fix#516.
The change to use an extern version variable in 24d83a12 produces a
linker error with Visual Studio due to the `version.c` source file being
compiled as C instead of C++.
Rename:
`version.c` -> `version.cpp`
`version_c.h` -> `version_cpp.h`
And update all references accordingly.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Make a `version.c` with `const char*` variables to store the version
strings used by other files, to make recompiles slightly faster when the
git state changes.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Pass `CC="$CC $CFLAGS"` to `make` for `libgsm`, so that the `-m32` is
passed for 32 bit builds.
For `mac_install_core_deps()` make sure brew is installed and install
brew perl, otherwise perl extensions cannot be built on Mojave for 32
bit.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Use git master for `graphite2` and a better cmake patch, with these
`DIST_ARGS`:
```
-DGRAPHITE2_NFILEFACE=ON -DGRAPHITE2_TESTS=OFF -DGRAPHITE2_DOCS=OFF
```
Use `DIST_CONFIGURE_OVERRIDES` instead of `DIST_ARGS` for `libvpx` and
`ffmpeg` because their configure scripts error on the `--sysconfdir`
arg.
Change all other references to `libvpx` and `ffmpeg` `DIST_ARGS` to use
`DIST_CONFIGURE_OVERRIDES` instead.
Add `-j1` to `xvidcore` `MAKE_ARGS` because it sometimes fails parallel
builds.
Change the `mkdir` commands to `mkdir -p` in `mingw.sh` because
`core.sh` now also makes those directories.
In `mingw.sh` for `libvpx` extra `CFLAGS`, add `-mstackrealign` for 32
bit builds and `-fno-asynchronous-unwind-tables` for 64 bit builds. The
latter is necessary to build, taken from the msys2 `libvpx` mingw
package.
Also add the `stdint.h` `-include` option to `CFLAGS` for libtheora and
ffmpeg because they use the `libogg` headers.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Update the following dists:
bzip2, xz, libiconv, gettext, ninja, meson, libgcrypt, libsecret, sdl2,
flac, libogg, libvorbis, wxwidgets
and the following ffmpeg deps:
graphite2, xvidcore, libgsm, opus, libsoxr, libass, libbluray, libvpx,
libx264, libx265
Enable ffmpeg for vbam again as we now have working recording code
thanks to @denisfa.
Disable graphviz and libzvbi for the time being since we don't really
need them.
For mp3lame use the msys2 patch to remove posix code instead of linking
to catgets.
For libogg and libvorbis on mac, add `-include /path/to/stdint.h` to
`CFLAGS` when building.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
When using the command line options, we had a circular issue:
- using `LoadConfig()` before `ReadOpts()` would mean the `--config` is
ignored.
- using `ReadOpts()` before `LoadConfig()` would mean the command line
options were ignored in favor of the default ones.
If we want to use a custom `vbam.ini`, we need to load it with
`--config`. Now we only consider params order on command line.
All this code protected by `#if 0` is implemented already one way or
another. Hence the decision to remove it, instead of commenting.
This also removes the need of the branch `arthur/sdl2`.
It happens due to our wxRadioButtons having 3 options (indexed by 0, 1
and 2) but we trying to get the index 7 (due to want to check every 7
days).
We should still implement something like WinSparkle for Windows.
- Fix#499.
We assign the `NOOP` id for every command disabled by the user, but not
the command name (just `NOOP`). When updating the configuration file,
any command with `NOOP` id is valid, even if the label does not match
`NOOP`. Hence this weird issue.
- Fix#502.
Pause before `pass` asks for the `gpg` passphrase to retrieve the
password to unlock the windows codesigning certificate.
This is so that the user does not have `gpg` time out waiting for the
passphrase.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Merging some work I was doing on trying to make a working mostly static
linux binary a year ago, with some additional minor refactoring.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Hopefully this will speed up the appveyor builds at least a little bit.
We really need to switch to ninja at some point though.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Add `-p:BuildInParallel=true` to the Visual Studio instructions for
`msbuild`, to build subprojects in parallel, without which the `-m`
option has no effect, both must be used.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Visual Studio 2017 only allows `/std:c++14` and higher, so remove the
`/std:c++11` option, we'll take the default of C++14 standard.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Check for the APPDATA environment variable if there is no LOCALAPPDATA
environment variable for things like reading the config file.
Fix#407.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
wxWidgets fails to translate some internal strings due to locale issues.
It is not clear how the current locale is detected, but it fails for
cases when the system is different from the set by the user. Eg: the
system is using `en_US`, but the user sets `LANG=pt_BR.utf8` for an
application. Some internal strings are translated because of `LANG`,
while others remain the same because `en_US`.
We could not use key shortcuts for this, since it was only checking if
the option was activated on menu. This only happens if you open the
menu and click it, so the key shortcut does not work.