Commit Graph

49 Commits

Author SHA1 Message Date
Shawn Hoffman 6a0c15491b Remove EmuState 2018-03-31 16:21:17 +02:00
JosJuice 1f1dae367d Unify ISOFile (wx) with GameFile (Qt) and put it in UICommon
The original reason I wanted to do this was so that we can replace
the Android-specific code with this in the future, but of course,
just deduplicating between DolphinWX and DolphinQt2 is nice too.

Fixes:

- DolphinQt2 showing the wrong size for split WBFS disc images.

- DolphinQt2 being case sensitive when checking if a file is a DOL/ELF.

- DolphinQt2 not detecting when a Wii banner has become available
after the game list cache was created.

Removes:

- DolphinWX's ability to load PNGs as custom banners. But it was
already rather broken (see https://bugs.dolphin-emu.org/issues/10365
and https://bugs.dolphin-emu.org/issues/10366). The reason I removed
this was because PNG decoding relied on wx code and we don't have any
good non-wx/Qt code for loading PNG files right now (let's not use
SOIL), but we should be able to use libpng directly to implement PNG
loading in the future.

- DolphinQt2's ability to ignore a cached game if the last modified
time differs. We currently don't have a non-wx/Qt way to get the time.
2018-03-09 13:08:38 +01:00
JosJuice 04cefc6ed3 DolphinWX: Use vector instead of list for game list cache
The advantage of std::list is that elements can be removed from the
middle efficiently, but we don't actually need that, because the
ordering of the elements doesn't matter for us. We can just replace the
element we want to remove with the last element and then call pop_back.

Replacing list with vector should speed up looping through the elements.
2018-01-04 17:14:35 +01:00
JosJuice e73de25a9e GameListCtrl: Put CACHE_REVISION in .cpp file
Reduces the number of files that have to be recompiled
when changing the cache revision.
2017-06-27 11:27:36 +02:00
Shawn Hoffman f51df62344 DolphinWX: properly sync EmuState and banner changes. 2017-06-26 12:35:40 -07:00
JosJuice b440dbd998 FileSystemGCWii: Use case insensitive comparison in FindFileInfo
This was a regression in f49b64c. Some games seem to name the
banner file OPENING.BNR instead of opening.bnr.

Should fix https://bugs.dolphin-emu.org/issues/10354
2017-06-24 14:06:31 +02:00
Shawn Hoffman c5fa470ad8 replace DoFileSearch with optimized version 2017-06-23 17:25:53 -07:00
Shawn Hoffman f16599f4a8 DolphinWX: defer gamelist scanning and switch to single-file cache. 2017-06-23 17:25:53 -07:00
Shawn Hoffman 79961b6f76 GameListCtrl: minor cleanup 2017-06-23 17:25:53 -07:00
Shawn Hoffman 668c6b5ce9 DolphinWX: rename CGameListCtrl -> GameListCtrl 2017-06-23 17:25:52 -07:00
spycrab 303b54a3a5 Refactor GameListCtrl 2017-04-28 17:35:23 +02:00
Steven Newbury 28f4793785 Always use visible text in GameList
Depending upon the desktop colour scheme, the light/dark
GameList backgrounds can cause the always white text
to become unreadble.

Use the common luminance approximation algorithm to
determine whether black text should be used instead.
2017-03-08 18:03:51 +00:00
Lioncash c2d00d25fe DolphinWX: Make the main config dialog modeless 2016-11-06 08:04:54 -05:00
EmptyChaos 3b11581aff WX: HiDPI: ISOProperties
And related ARCodeAddEdit/PatchAddEdit.

Change ISOFile to use wxImage instead of wxBitmap since bitmaps require
a screen context and banner images have a fixed resolution.
2016-10-04 13:47:21 +11:00
EmptyChaos 107d4afb08 WX: HiDPI: Dolphin Main UI (CFrame) 2016-10-04 13:47:21 +11:00
Shawn Hoffman 41e7c43d0d NetPlay: add one click host
Add a context menu entry in main game list to host a netplay game
based on saved settings.

Original commit:
commit 91aaa958e6
Author: Aestek <thib.gilles@gmail.com>
Date:   Sun Jul 24 14:51:37 2016 +0200
2016-10-03 15:34:49 -07:00
shuffle2 09fd2fd8e2 Merge pull request #4015 from EmptyChaos/wx-misc-fixes
WX: Fix pop-under (win) / game list garbage (win) / language support (Linux)
2016-10-02 22:46:14 -07:00
Lioncash 6e0e4646bd GameListCtrl: use unique_ptr for underlying game list items 2016-09-30 07:13:09 -04:00
EmptyChaos 9842cef13f GameListCtrl: Reimplement Custom Paint to remove column lines.
This leaves system themes enabled and instead just repaints the
list view background to eliminate the column ruler lines.
2016-08-31 14:32:39 +10:00
Pierre Bourdon 3570c7f03a Reformat all the things. Have fun with merge conflicts. 2016-06-24 10:43:46 +02:00
EmptyChaos 309d0e59f4 ISOProperties/GameListCtrl: Use Global INI Change event.
ISOProperties no longer needs its hack to refresh the game list, the
new INI Modified event can be used instead.
2016-05-30 00:49:11 +10:00
Rukai 4cd918caf1 DolphinWX: Disable 'maker' column hiding
This was done because showing a column was broken:
Showing a column repopulates the column with no regard for the sorted
order. This results in a seemingly random order.
(actually the order of m_ISO_FILES)
2016-04-17 10:19:25 +10:00
JosJuice 8cad70238c DolphinWX: Don't store compression progress in member variables
Just some extra cleanup.
2016-02-08 15:26:11 +01:00
JosJuice bd326ace5c DolphinWX: Replace GetSelectedISO hack for multiple selections 2016-01-30 13:32:57 +01:00
JosJuice dcde91cdd8 DolphinWX: Unify the condition for the game list being empty
When there are no games to display in the game list, DolphinWX shows a
message instead. Clicking the message will perform an action. If the game
list truly is empty, the message and action are for opening a browse
dialog, but if the user has hidden some games, they are instead for
unhiding all games. However, the condition for checking which message to
display lacked some parts that are in the condition for checking which
action to use, so the two could be different in rare cases. This PR fixes
that by breaking out the two conditions to a new unified function.
2016-01-06 22:25:30 +01:00
Markus Wick a3433e162a Merge pull request #3149 from ShadowsFriend/fname_column
DolphinWX: Add a filename column
2015-12-02 15:04:36 +01:00
Anthony Serna 013d55227b [DolphinWX] Added warning to Wii disc compression 2015-10-31 12:08:14 -07:00
Christian Widmer 3fdaf377b0 DolphinWX: Add a filename column 2015-10-11 05:29:01 +02:00
Christian Widmer 4d78aea41d DolphinWX: Add items to visible columns only
Before the columns of the gamelist were filled with content regardless
of their visibility. This led to display bugs when certain columns, for
example the region column, were hidden.

The first problem was the InsertItemInReportView() function because it
refilled all columns with content on every call to update() without
checking for their visibility. While this issue would have easily been solved
by adding conditionals before each column update, the maker column would
have still caused problems for it autohides on resize and those do not
call update(). Therefore it was necessary to move the column update logic
from InsertItemInReportView() to a new one that allows for seperate
modification of an item's columns.
2015-10-11 05:01:59 +02:00
Lioncash 633be0387d General: Remove unimplemented function prototypes 2015-09-05 22:01:07 -04:00
Tillmann Karras 30ebb2459e Set copyright year to when a file was created 2015-05-25 13:22:31 +02:00
Tillmann Karras cefcb0ace9 Update license headers to GPLv2+ 2015-05-25 13:22:31 +02:00
Lioncash a7e9aea797 DolphinWX: Remove unnecessary includes 2015-05-08 12:39:26 -04:00
Lioncash cb20589d7f Merge pull request #2341 from lioncash/fwd
DolphinWX: Remove unnecessary forward declarations
2015-05-08 09:54:23 -04:00
JosJuice df8e768b77 wx: Now that Wii doesn't support descriptions, rename Notes to Maker
I'm not sure if Maker is the best name (Developer? Publisher?
Company? Copyright?) but I went with it because it's
what the game properties window uses. For the sake of
backwards compatibility, the INI option wasn't renamed.
2015-05-03 16:13:55 +02:00
Lioncash 88f7536d81 DolphinWX: Remove unnecessary forward declarations
These are all fully defined
2015-04-28 17:32:38 -04:00
Unknown W. Brackets f2f83a0c60 DolphinWX: Allow cancelling gcz compression. 2014-11-27 07:53:28 -08:00
Lioncash ac387031a4 DolphinWX: Kill off trivial event tables
Also fixes some of the wonky stuff in Main where we would fire an event to do post-init stuff which isn't necessary anymore.
2014-11-09 00:08:33 -05:00
Steven Vascellaro b956be20e3 Replaced generalized instances of GCM with ISO
Renamed various commands to refer to ISO instead of GCM for consistency,
as the commands are used for both Wii and GameCube files.

CompressGCM --> CompressISO
DeleteGCM --> DeleteISO
MultiCompressGCM --> MultiCompressISO
MultiDecompressGCM --> MultiDecompressISO
SetDefaultGCM --> SetDefaultISO

Fixed COMPRESSISO

Fixed missing "COMPRESSISO"

Fixed more COMPRESSISO

Final fix for COMPRESSISO
2014-09-28 19:53:05 -04:00
Zhuowei Zhang 25bd5e237b Add Change Disc option to the right-click menu in the game list. For issue 7411. 2014-06-30 12:06:45 -07:00
Lioncash 10dc1ef135 Fix crashes when dragging and dropping files outside of the gamelist 2014-06-24 16:43:02 -04:00
Lioncash ce54c1e571 Kill off replaceable usages of s[n]printf. 2014-06-18 19:53:38 -04:00
yourgamesbeover 91840cb4c7 added option for selecting which column are displayed in the game list, added optional game id column, and added config entry to disable making compressed games blue 2014-06-05 15:34:20 -04:00
Tillmann Karras f28116b7da clang-modernize -add-override 2014-03-09 21:12:01 +01:00
Pierre Bourdon f344a43657 Make DolphinWX/ mostly IWYU clean. 2014-02-23 00:27:27 +01:00
Lioncash 2afe215271 Convert all includes to relative paths. 2014-02-18 02:19:10 -05:00
Lioncash 3fd87a7636 Second and final pass of clearing out tabs. 2014-02-17 02:19:41 -05:00
lioncash d2038049f5 Replace all include guard ifdefs with "#pragma once" 2014-02-10 18:07:16 -05:00
Jasper St. Pierre 34692ab826 Remove unnecessary Src/ folders 2013-12-31 14:03:19 -05:00