Compare commits

...
Author SHA1 Message Date
Tannin ac8f6dbdec added theme inspired by JetBrains Dracula (created by Kojoley on github) 2015-05-17 14:39:01 +02:00
Tannin d2ab10ecff reduced number of mods for which update information is requested at once 2015-05-17 14:32:01 +02:00
Tannin 883f4d9894 bugfix: MO requested update information for mods without mod-id 2015-05-17 14:31:38 +02:00
Tannin d3e904e9ad - bugfix (not released): double click on mod didn't work until a mod was checked/unchecked once 2015-05-17 14:31:07 +02:00
Tannin e38592da97 extended plugin interface. Plugins can now activate/deactivate mods, install mods
suggesting a name and retrieve a list of all installed mods
2015-05-17 14:30:14 +02:00
Tannin 268d2ffe8b - some code cleanup and modernization trying to fix "dr memory" reports
(though they were almost certainly false positives)
- there is now a 50ms timeout on logging messages
- bugfix: leaked handles after directory searches
2015-05-17 14:03:01 +02:00
Tannin 9d3364f4da fixes to make MO compile with mingw (also fixes some warnings generated by mingw) 2015-05-16 18:44:07 +02:00
Tannin 9ea5086c4c slight cleanup regarding steam log-in settings 2015-05-12 20:34:05 +02:00
Tannin 4c1155a6ab Merge 2015-05-12 19:00:41 +02:00
Tannin 90365041f4 workaround to prevent repeated checking of mods with the mouse was interpreted
as double click
2015-05-12 18:56:44 +02:00
Tannin 183b571560 minor stuff 2015-05-11 21:41:00 +02:00
Tannin 0f1271dd99 - bugfix: moving a mod didn't properly update conflict highlighting 2015-05-11 21:40:35 +02:00
Tannin dbdc2538f9 bugfix: upon closing the profiles dialog, the profile was changed to the
top-most profile and back
2015-05-11 21:39:56 +02:00
Tannin 5a908442d6 dropping an url on the download widget now attempts to download the url 2015-05-11 21:37:12 +02:00
Tannin 328244692b better type safety in accessing tool plugins 2015-05-11 18:05:01 +02:00
Tannin f32b4c3ce1 - language list in settings no longer contains english twice
- language names in settings are now in the native language
2015-05-10 16:01:07 +02:00
Tannin 83a896d0a9 - bugfix: case conversion could produce different local-dependent results
between the time the vfs lookup map is set up and later when querying it.
2015-05-10 16:00:15 +02:00
Tannin 209fe5cab5 esp list refresh is now delayed if the directory-structure is being updated. This
may have been causing the lists to be cleared.
2015-05-10 15:45:27 +02:00
Tom Tanner cd68c9d53c Merge from master 2015-05-10 12:35:52 +01:00
Tannin 65b64d111b Merge with branch1.2 2015-05-10 11:24:25 +02:00
Tannin 73fa7045b6 missed a file when dropping redundant report.h (changeset a2d809870347) 2015-05-10 11:22:50 +02:00
Tannin a25d889e78 - bugfix: shortcuts specifying a profile didn't work 2015-05-10 11:22:10 +02:00
Tannin 3680e37d39 Merge 2015-05-09 21:46:40 +02:00
Tannin abba182b1b dropped redundant report.h/report.cpp 2015-05-09 21:44:19 +02:00
Tom Tanner ffb470a380 Add in a tab to allow saving of steam username and password. 2015-05-09 18:10:38 +01:00
Tom Tanner 1403d51a82 Fix mod organiser not picking up stuff from a blank profile 2015-05-09 11:41:39 +01:00
Tom Tanner 89eabf3c4d added a 'yes to all' shellMove and made the drag-and-drop code use shellMove/shellCopy 2015-05-03 09:51:01 +01:00
Tom Tanner 26368df7a6 Retain 'backup' switch state on mod overwrite options 2015-05-03 08:43:12 +01:00
Tom Tanner 5f399f6a39 Another removal of redundant commentary 2015-04-29 21:18:43 +01:00
Tom Tanner c909f8ce4f remove redundant comments/code from drag'n'drop stuff 2015-04-29 21:14:46 +01:00
Tom Tanner ce925bc73e Allows drag-and-drop into the download tab 2015-04-26 09:44:57 +01:00
Tom Tanner 927504cbd9 1) reintroduce the report error when unpacking archives to avoid the error
message disappearing entirely
2) Allow very long filenames to be used when unpacking
2015-04-25 13:04:14 +01:00
Tom Tanner a44cb011a5 Small fixup to passing of argc/argv. 2015-04-19 21:10:32 +01:00
Tom Tanner 11e67d7a6c More fixing up of scons. Give up entirely with debugging python proxy 2015-04-19 21:10:03 +01:00
Tannin 0b58653e2d bugfix: filter on download list always filtered by file name, not by displayed name 2015-04-19 20:33:46 +02:00
Tannin e47e04dcf2 refactorings 2015-04-12 15:54:14 +02:00
Tannin fd584f8038 - operations not possible during directory refresh can now be delayed unit after
the refresh.
- will now rewrite the plugin list(s) immediately after running external
application
- changes missing from changeset 9f522a324341
2015-04-12 15:52:22 +02:00
Tannin 942bd04e5e bugfix: batch-activation/deactivation used non-persistent indices which seems to
be a problem nowadays (probably related to Qt5?)
2015-04-12 15:48:50 +02:00
Tannin 4b6e8ac51b safe file writer now ignores the hash if the file doesn't exist 2015-04-12 15:45:34 +02:00
Tannin 8c2e88b9c9 MO will no longer use the load order from an empty loadorder.txt because the
file should at least have a header.
2015-04-12 15:43:46 +02:00
Tannin ef39699d69 missing changes that belong into changeset 5eaf1e439403 2015-04-12 15:42:45 +02:00
Tannin 55eacfbd80 bugfix: save-dir monitoring is now disabled while editing a profile so that,
in case of local save games the active profile path isn't locked
2015-04-12 15:41:17 +02:00
Tannin 056acd03cd bugfix: when using a user-selected game path that path wasn't use for
auto-detecting executables
2015-04-12 15:39:16 +02:00
Tannin 9eb1a303a7 cosmetic changes and increased version number 2015-04-08 18:54:09 +02:00
Tannin a44c4bbdb2 enabling/disabling a plugin should now immediately cause a check for problems 2015-04-08 18:53:43 +02:00
Tannin 8cca47454a if overwriting the ModOrganizer.ini file fails, another attempt to store
settings is made, writing to the ini file directly.
2015-04-08 18:52:43 +02:00
Tannin a818688d3f bugfix: save games didn't show up in the transfer saves dialog 2015-04-08 18:30:22 +02:00
Tannin feaad36168 download directory, cache directory and mod directory are now only stored in the
ini file when they differ from the default. this should make moving MO easier
2015-04-08 18:30:02 +02:00
Tannin a6f7480ab9 bugfix: tutorial broken 2015-04-08 18:09:36 +02:00
Tannin 1ba140e0fa avoid saving plugin list during directory updates as they may be invalid 2015-03-31 18:32:46 +02:00
Tannin eed3664302 a signal is now emitted when the state (checked/unchecked) of a plugin changes 2015-03-31 18:31:54 +02:00
Tannin 35eb41daf9 will now avoid writing plugin lists if they would be empty (as its probably a bug) 2015-03-31 18:31:21 +02:00
Tannin 38eb03c306 bugfix: modlist automatically scrolled to the top after closing context menu 2015-03-31 17:48:07 +02:00
Tannin 6ff201385c bugfix: re-enabled alignment of content icons 2015-03-31 17:43:36 +02:00
Tom Tanner 0269fc36e6 If there are no Missing ESPs, say "None" rather than leaving an empty list. 2015-03-29 18:01:56 +01:00
Tom Tanner fa5d3cdaf3 Update readme with information about getting python proxy to work in a debug build. 2015-03-29 18:01:12 +01:00
Tom Tanner ab28c9631a Merge 2015-03-28 10:54:02 +00:00
Tom Tanner 04b6f2e475 Added json file dependency into moc scanner 2015-03-28 10:11:09 +00:00
Tannin 0d5197a3c8 Merge in changes by Tom Tanner 2015-03-27 18:24:37 +01:00
Tannin 8eb63a068c cleanup 2015-03-27 16:37:31 +01:00
Tannin 4d4a7713fb bugfix: not all icons showed up 2015-03-27 16:36:55 +01:00
Tannin 4161696527 bugfix: MO didn't use all parameters of preconfigured executables 2015-03-27 16:33:32 +01:00
Tannin 73eea93abb bugfix: "edit executables" dialog didn't actually save a modified executable when
confirming the save-on-close dialog
2015-03-27 16:31:26 +01:00
Tom Tanner db7c6e6006 Add in all the necessary stuff for scons 2015-03-25 22:35:53 +00:00
Tom Tanner 266a696429 Merge 2015-03-22 10:51:43 +00:00
Tom Tanner ea520baf4e Fix a meory leak with modules that error during loading
More Sconscript stuff
2015-03-22 10:49:15 +00:00
Tannin 07b8896f92 updated build instructions, version number, packaging scripts 2015-03-21 16:39:54 +01:00
Tannin 4a2e4652f4 - after closing the overwrite dialog the in-memory directory structure is updated again
- bugfix: crash on creating shortcuts
2015-03-21 16:37:49 +01:00
Tannin a9e1d44a2a changed the way the right-most column in the mod list is stretched to a way that is independent of the mod ordering 2015-03-21 16:35:10 +01:00
Tannin b210a2f083 MO will again remove obsolete files on startup 2015-03-21 16:31:54 +01:00
Tannin cbbc2d191d bugfix: crash when entering search terms for the mod list 2015-03-21 16:30:43 +01:00
Tannin cad7ed47be bugfix: sync-overwrite dialog didn't open 2015-03-21 16:29:55 +01:00
Tom Tanner a9cec9e5e2 Fixed Scons build for existing bits.
Changed pynedit.pro to fetch from 'standard' install location
Changed saveas code to use organizer report rather than uibase - this way it's
not dependant on the vagaries of the include path, and works the same as the
rest of the organiser directory
2015-03-20 10:34:30 +00:00
Tom Tanner 771dde7771 Merge 2015-03-19 16:48:21 +00:00
Tannin c6758e47c8 minor stuff (slight changes to the visual style, code refactorings, version increment) 2015-03-18 19:41:46 +01:00
Tannin 4a99cfe6ad bugfix: crash related to bad timing when filtering the mod list 2015-03-18 19:41:11 +01:00
Tannin f134c7ab4c - plugin list can now be sorted by flags
- sorting by mod index now puts the disabled mods to one end of the list
2015-03-18 19:40:12 +01:00
Tannin 03b029c613 - avoiding unnecessary meta.ini saves when checking mods for updates 2015-03-18 19:35:49 +01:00
Tom Tanner a1c8e529f7 Merge with branch1.2 2015-03-18 17:40:29 +00:00
Tom Tanner 39dd67f22f Refactoring and cleanup. 2015-03-18 14:16:04 +00:00
Tom Tanner de79d15980 Every plugin now built 2015-03-17 16:31:15 +00:00
Tom Tanner 16beb6f9b1 Abortive attempt to use official 'qt' tool
This resulted in some small cleanups but not much else
2015-03-16 10:14:00 +00:00
Tom Tanner a00a9a5bba Cleanup 2015-03-16 08:35:14 +00:00
Tom Tanner 4b1059f5a1 Building cleanly without patched versions. Doesn't do the plugins yet 2015-03-15 16:26:41 +00:00
Tom Tanner 2628dd3fb8 Yet more scons stuff. Now builds everything but the plugins, and installs all the dlls 2015-03-15 10:58:21 +00:00
Tom Tanner 2d20185e77 More sconscripts set up 2015-03-14 14:59:52 +00:00
Tannin 7a1ae9b0f1 Merge with branch1.2 2015-03-09 12:34:34 +01:00
Tannin d45ebf1348 added LocalPaths to ignore list 2015-03-09 12:33:37 +01:00
Tannin db2954e8eb minor cleanup 2015-03-09 12:22:13 +01:00
Tannin 8c0756bd9d - bugfix: changing the highlight in the modlist didn't always prompt an immediate update of overwrite markers 2015-03-09 12:18:25 +01:00
Tannin 026b97835e - when activating/deactivating a mod the contained esps are only activated/deactivated if no other
active mod provides the same plugins
2015-03-09 12:17:57 +01:00
Tom Tanner 97d6f7ce01 First attempt at using scons to build 2015-03-08 13:20:56 +00:00
Tom Tanner d80cdf726e Small typo fix 2015-03-01 13:16:27 +00:00
Thomas Tanner 9c8f0a2041 revert 2015-03-01 12:52:57 +00:00
Thomas Tanner 1b16897228 test 2015-03-01 12:24:04 +00:00
Thomas Tanner 4bd5df5ab4 Change readme to include sip install 2015-03-01 11:48:55 +00:00
Tannin d08e0ebab0 - some fixes to how file changes are signaled and delayed 2015-03-01 11:28:49 +01:00
Tannin 6479f972dc tons of code cleanup and minor fixes to harden the code (mostly suggestions from static code analysis) 2015-02-25 18:38:01 +01:00
Tannin e01ab940b0 bugfix: tooltips in dark style were too transparent 2015-02-25 18:11:31 +01:00
Tannin e9c937f909 bugfix: plugin list wasn't user-sortable 2015-02-25 18:03:26 +01:00
Tannin d87661a66f sorting by content now produces a more useful list 2015-02-25 18:02:39 +01:00
Tannin 3c030a28e9 bugfix: filtering by meta-categories (checked/unchecked, update available) didn't work 2015-02-25 18:01:49 +01:00
Tannin 6b4cb9ff4c bugfix: crash when trying to delete mods (issue #1016) 2015-02-25 18:00:46 +01:00
Tannin cbe84327c6 - added content icon for BSAs
- improved display of content icons (better scaling and some borders)
- bugfix: contains changes missing from changeset bc6b6430017b
2015-02-25 17:57:38 +01:00
Tannin ce228e512c - No longer setting the dll directory as a windows search folder for dlls because
that appears to remove another search folder AND the configured seach folders seem
to be inherited by processes started from MO (both confirmed only in windows 8.1)
2015-02-25 17:53:48 +01:00
Tannin 1579e4dcb0 - bugfix: detection of support for direct loading load mechanism was broken
- proxy dll load mechanism disabled since it seems to have been bugged for ages
and nobody noticed so it appears to be unneeded
2015-02-25 17:50:57 +01:00
Tannin 671d96383b icon delegates now use a pixmap cache to improve rendering performance 2015-02-25 17:48:37 +01:00
Tannin bdfd41a862 cleanup 2015-01-29 19:30:10 +01:00
Tannin 8aa6dc4c7d extended the game-plugin interface 2015-01-29 19:26:42 +01:00
Tannin c3a95bdef1 Merge with branch1.2 2015-01-24 19:34:12 +01:00
Tannin f756aede08 updated version number 2015-01-24 19:16:42 +01:00
Tannin 855e8bd737 fixed logging in case of changes and errors in the mod list 2015-01-22 19:55:41 +01:00
Tannin b0fe23a711 bugfix: When displaying the list of save games to delete the list is capped to 10 entries, otherwise the window may extend beyond the screen 2015-01-22 19:50:51 +01:00
Tannin c2edbcf90f bugfix: initialization order was wrong and so kept foreign language systems from correctly loading mod order if Unmanaged is translated
"Unmanaged" is no longer translatable as its used internally as an identifier
2015-01-22 19:47:18 +01:00
Tannin 2400e2c99e cleanup (mostly removing unused includes) 2015-01-22 19:44:38 +01:00
Tannin af1e3d0187 removed some obsolete code 2015-01-22 19:38:14 +01:00
Tannin 9ab9c072fc Added tag release v1.2.17 for changeset 2078ce371648 2015-01-22 19:02:47 +01:00
Tannin 30c016567f bugfix: first attempt at discovering java binary always failed 2015-01-11 11:28:02 +01:00
Tannin da27ec45da increased version number and minor stuff 2015-01-11 11:17:26 +01:00
Tannin 1321564a92 bugfix: priority couldn't be changed directly in plugin list (this change was apparently not copied to the branch) 2015-01-11 11:17:04 +01:00
Tannin 4d9795527d different way to check for file existence 2015-01-11 11:16:04 +01:00
Tannin 9f09c30e08 bugfix: translations for some plugins weren't loaded 2015-01-11 11:14:58 +01:00
Tannin caf31e72cc bugfix: executables with extensions other than .com, .cmd or .bat were started with cmd.exe (since 1.2.16) 2015-01-11 11:14:10 +01:00
Tannin f2ab6825bf Added tag release v1.2.16 for changeset a837623ea911 2015-01-11 11:10:21 +01:00
Tannin 25348238b2 bugfix: translations for configurator plugin weren't named correctly 2015-01-08 20:07:58 +01:00
Tannin 8b3a42bd17 bugfix: translations for plugins were not used 2015-01-08 20:07:32 +01:00
Tannin 6f1162c23f bugfix: showEvent contains initializion code that should be run only on first start of the application 2015-01-08 20:06:56 +01:00
Tannin 2b21463514 - download servers that haven't been available for over a month are now purged from the known servers list
- bugfix: encoding detection for fomod xmls could incorrectly interpret files as utf16 encoded
- bugfix: hashing algorithm for bsa files was wrong
- bugfix: nxmhandler reported non-issues as errors
- bugfix: nxmhandler tried to apply chrome fix on every start
- bugfix: "not endorsed" icon displayed for non-nexus mods
- bugfix: when drag&dropping within the overwrite dialog the file might still get moved to a mod (and probably not the intended one)
- bugfix: dropping files from overwrite on the modlist was refused when not sorting by priority (only in 1.2.15)
- bugfix: unmanaged mods couldn't be reordered (only in 1.2.15)
2015-01-07 23:13:40 +01:00
Tannin d20a26e0eb Added tag release v1.2.15 for changeset d1946676ce17 2015-01-07 23:09:58 +01:00
Tannin 9edc39633b - bugfixes
- moved more functionality to game-plugins
- further decoupled management functionality from the UI
- created another "tutorial" which is only a single page with relevant parts of
  the ui highlighted with info as tooltips
2015-01-06 19:31:53 +01:00
Tannin b415db619e Merge 2015-01-04 10:33:37 +01:00
Tannin bd8267993d - fixes after merge 2015-01-04 10:13:12 +01:00
Tannin f5c56efeb3 re-integrated changes missing from the merge 2015-01-03 16:18:38 +01:00
Tannin a16e25380f Merge with branch1.2 2015-01-03 15:58:52 +01:00
Tannin 459816ab71 updated packaging and build scripts 2015-01-03 15:09:25 +01:00
Tannin 9b5c238938 - repository info is now stored with the mod 2015-01-03 12:35:25 +01:00
Tannin e7b6a7cbdd - bugfix: no exec info returned for .exe
- bugfix: wide string conversion functions seem to have failed for empty string
2015-01-03 12:34:26 +01:00
Tannin ab925e1e7c added/updated translation files 2014-12-20 17:25:12 +01:00
Tannin 7bfb48d6ab cleanup 2014-12-20 14:45:08 +01:00
Tannin 88817c7f3b - drag&drop in the plugin list now also prompts a message instead of being impossible 2014-12-20 14:44:40 +01:00
Tannin ee0041ba18 - bugfix: file extensions when adding executables were treated case sensitive
- exe files are now started directly, not through cmd
2014-12-20 14:43:22 +01:00
Tannin 306ba78b0f bugfix: when merging mods with a custom installer, various ini settings (incl. category) were reset 2014-12-20 14:42:43 +01:00
Tannin e33406b4b5 endorsing is now only offered for mods with a valid nexus id 2014-12-20 14:42:00 +01:00
Tannin a5906f1044 workaround to prevent executables dialog from auto-selecting the top-most executable 2014-12-20 14:41:28 +01:00
Tannin ebfeb2fbf9 - mod-list can now be re-ordered with drag&drop while grouping is active
- drag&drop is not disabled when ordering by other columns than priority. MO will notify using messagedialog that it's impossible instead.
2014-12-14 18:25:26 +01:00
Tannin f666e3d835 when reinstalling a mod the existing mods name is used by default 2014-12-14 16:32:57 +01:00
Tannin 003cb6dec5 if a shortcut-started application is the same binary as a configured one, the corresponding steam app id is used 2014-12-14 16:32:30 +01:00
Tannin 7fb7207ac7 custom installers can now set the installation file (and the ncc installer now does) 2014-12-14 16:30:23 +01:00
Tannin 64eced4614 - NCC installer can now discover files in other mods (thanks Reunion!) and knows the script extender version 2014-12-13 16:47:11 +01:00
Tannin 8634b97bea all executables can now be repositioned, including auto-detected ones 2014-12-09 20:02:28 +01:00
Tannin 116a36b943 searching for steam process will no longer fail when more than 1024 processes are running (and steam is past the 1024th) 2014-12-09 18:35:32 +01:00
Tannin 479fdb3dcd removed use of ModInfo::internalName 2014-12-09 18:34:09 +01:00
Tannin acf35da699 now stored installed files with each mod 2014-12-09 18:09:11 +01:00
Tannin 6eb05396e4 bugfix: hitting the fix button in the diagnosis plugin could crash MO if the
line didn't have mouse focus
2014-12-04 19:30:07 +01:00
Tannin 9fcf34fec7 bugfix: ini tweaks were not applied in priority order 2014-12-04 19:27:55 +01:00
Tannin 6c1e63258c minor fixes 2014-12-04 19:25:07 +01:00
Tannin 226993eece - added error handling when a file can't be deleted from vfs
- minor bugfixes
2014-12-01 18:44:37 +01:00
Tannin b2d04d70fc accidentally removed loot_cli from build 2014-11-28 11:51:52 +01:00
Tannin 99de80e722 replaced all uses of NULL with nullptr
fixed a few placed where NULL was used as a number or boolean
2014-11-28 11:19:20 +01:00
Tannin 78f628e0af cleanup und bugfixes after refactoring 2014-11-28 11:06:28 +01:00
Tannin 78da5fc37f more bugfixes 2014-11-26 20:22:00 +01:00
Tannin ffef339e2b several bugfixes from the bugfix-wc that I forgot to backport 2014-11-26 20:21:33 +01:00
Tannin 4fa700bb55 undid some changes that accidentally made it to this branch 2014-11-26 20:19:07 +01:00
Tannin 45a46778fb Merge 2014-11-21 15:07:31 +01:00
Tannin cfb863f6c3 qt5 compatibility 2014-11-21 15:01:47 +01:00
Tannin f2f9e11fdd - started on a refactoring moving functionality out of the MainWindow class
- started on support for game-plugins
2014-11-21 14:45:30 +01:00
Tannin 9907437d93 - fixed manifest for qt5
- download messages can now be sent from different user accounts
2014-11-14 23:33:49 +01:00
Tannin d23466f036 - fixed manifest for qt5
- download messages can now be sent from different user accounts
2014-11-14 23:33:49 +01:00
Tannin 3b7a468f73 - updated staging script to use qt5 and to fetch translations from transifex
- removed call to function unavailable in Windows XP
2014-11-11 23:48:22 +01:00
Tannin 53896e66f1 - updated staging script to use qt5 and to fetch translations from transifex
- removed call to function unavailable in Windows XP
2014-11-11 23:48:22 +01:00
Tannin efc77930ad Merge 2014-11-11 21:52:50 +01:00
Tannin 01265e9b03 - re-enabled use of img-tags in bbcode converter
- addded a workaround for cases where, after a MO update, the stored modlist layout has no size for new columns
- using a webview again for the nexus view of the modinfo dialog
2014-11-11 21:46:16 +01:00
Tannin 9494938534 Merge 2014-11-11 21:42:18 +01:00
Tannin 0b14949d0e some work on installer scripts 2014-11-11 21:41:22 +01:00
Tannin 2237d7c103 - re-enabled use of img-tags in bbcode converter
- addded a workaround for cases where, after a MO update, the stored modlist layout has no size for new columns
- using a webview again for the nexus view of the modinfo dialog
2014-11-11 21:46:16 +01:00
Tannin 7c1273b246 some work on installer scripts 2014-11-11 21:41:22 +01:00
Tannin 9ab7bada1c - bsa parser will now cancel in case of a read error. Before, when attempting to parse a broken bsa it could take forever and continuously allocate memory
- better error message when bsa parsing fails
- slightly better support for font colors in bbcode converter
- configurator now also uses pyqt5
- bugfix: bsa hashing function converted backslashes to slashes instead of the other way around. hash calculation is still often wrong on folder names...
2014-11-09 14:01:48 +01:00
Tannin 1eea3bd90e - bsa parser will now cancel in case of a read error. Before, when attempting to parse a broken bsa it could take forever and continuously allocate memory
- better error message when bsa parsing fails
- slightly better support for font colors in bbcode converter
- configurator now also uses pyqt5
- bugfix: bsa hashing function converted backslashes to slashes instead of the other way around. hash calculation is still often wrong on folder names...
2014-11-09 14:01:48 +01:00
Tannin 10cc566081 Merge 2014-11-06 00:07:06 +01:00
Tannin 53d1f3e00e - workaround for GetModuleFileName-calls that supply wrong buffer size
- removed obsoleted calls to GetVersionEx
- bugfix: download urls were potentially not encoded correctly
- bugfixes to tls-based recursion protection
2014-11-06 00:03:44 +01:00
Tannin 20db939501 - workaround for GetModuleFileName-calls that supply wrong buffer size
- removed obsoleted calls to GetVersionEx
- bugfix: download urls were potentially not encoded correctly
- bugfixes to tls-based recursion protection
2014-11-06 00:03:44 +01:00
Tannin df0bd3331a - archive library can now query for password during extraction (seems to be necessary for rars)
- process blacklist is now taken from a file if there is one, not hardcoded
- removed workaround for the papyrus compiler
- updated loot client to work with the actual api
- loot client now links with loot32.dll at runtime
- loot client now produces its output in a (json-)file which includes all plugin messages and dirty flags
- fomod installer now tries to parse the xml with several encodings
- fomod installer will now display a diagnostics warning if the jpg imageformat isn't supported
- base preview plugin now tries to be a bit smarter about resizing images to fit the screen
- bugfix: fomod installer no longer tries to open an image even after detecting its invalid
- bugfix: potential null-pointer dereferentiation in getprivateprofile... hooks
- bugfix: potential null-pointer dereferentiation in download manager
- bugfix: internal origin name showed up in one more place
- bugfix: ToString function produced strings that were one (zero-termination-)character too long
2014-11-05 23:48:06 +01:00
Tannin db0e278817 - moved the hook-recursion-protection to tls
- some code cleanup and consolidation
- hook.dll will now report all of its own exceptions
- some more logging during startup
- changed the way urls are encoded for download requests
- now displaying (one of the) process name(s) while waiting for a program to end
- bugfix: spawned processes were forced to leave the job
2014-09-29 20:35:35 +02:00
Tannin bfa6c9ab1e - moved the hook-recursion-protection to tls
- some code cleanup and consolidation
- hook.dll will now report all of its own exceptions
- some more logging during startup
- changed the way urls are encoded for download requests
- now displaying (one of the) process name(s) while waiting for a program to end
- bugfix: spawned processes were forced to leave the job
2014-09-29 20:35:35 +02:00
Tannin 7a7c464b18 - archive library can now query for password during extraction (seems to be necessary for rars)
- process blacklist is now taken from a file if there is one, not hardcoded
- removed workaround for the papyrus compiler
- updated loot client to work with the actual api
- loot client now links with loot32.dll at runtime
- loot client now produces its output in a (json-)file which includes all plugin messages and dirty flags
- fomod installer now tries to parse the xml with several encodings
- fomod installer will now display a diagnostics warning if the jpg imageformat isn't supported
- base preview plugin now tries to be a bit smarter about resizing images to fit the screen
- bugfix: fomod installer no longer tries to open an image even after detecting its invalid
- bugfix: potential null-pointer dereferentiation in getprivateprofile... hooks
- bugfix: potential null-pointer dereferentiation in download manager
- bugfix: internal origin name showed up in one more place
- bugfix: ToString function produced strings that were one (zero-termination-)character too long
2014-11-05 23:48:06 +01:00
Tannin 2ce135e0bf updated minimum nmm compatible version number 2014-09-27 19:18:33 +02:00
Tannin 93bd29c13d - several style fixes suggested by static analysis
- will now support up to 4 levels of version numbers (major.minor.subminor.subsubminor
2014-09-24 19:51:51 +02:00
Tannin a62ecc5bf1 - several style fixes suggested by static analysis
- will now support up to 4 levels of version numbers (major.minor.subminor.subsubminor
2014-09-24 19:51:51 +02:00
Tannin 637ce6bcc1 - removed a use of wostringstream which seems to have been involved in a bug. Still not sure how
- rewrote widechar <-> multibyte conversion functions to handle arbitrary string lengths
2014-09-19 22:01:37 +02:00
Tannin 5f1022917b - removed a use of wostringstream which seems to have been involved in a bug. Still not sure how
- rewrote widechar <-> multibyte conversion functions to handle arbitrary string lengths
2014-09-19 22:01:37 +02:00
Tannin d3d7e30286 non-mo mods now have a constructed name that cannot conflict with a regular mod 2014-09-10 20:44:39 +02:00
Tannin b77dcb2206 non-mo mods now have a constructed name that cannot conflict with a regular mod 2014-09-10 20:44:39 +02:00
Tannin 7d27138086 when MO fails to overwrite its ini file it tries another method using qt functions 2014-09-10 20:43:33 +02:00
Tannin 430048d201 when MO fails to overwrite its ini file it tries another method using qt functions 2014-09-10 20:43:33 +02:00
Tannin 19cb2d4076 plugins can now query the list of masters for a plugin 2014-09-10 20:37:17 +02:00
Tannin 4c42a6fbf1 plugins can now query the list of masters for a plugin 2014-09-10 20:37:17 +02:00
Tannin 5aa5c90d39 profiles are now created with an (empty) archives.txt 2014-09-10 20:35:57 +02:00
Tannin 243b59c64c profiles are now created with an (empty) archives.txt 2014-09-10 20:35:57 +02:00
Tannin 12a57d7f6d - descriptions for plugin settings are now displayed 2014-09-10 20:34:31 +02:00
Tannin b0a4748da5 - descriptions for plugin settings are now displayed 2014-09-10 20:34:31 +02:00
Tannin 482f13a50b - re-enabled building of loot_cli and started developing against the new api
- extended set of default categories
- more tolerand bbcode parser
- added a few colors for the bbcode parser
- more fixes to qt5 compatibility
- started work on ability to unloading (and thus re-loading) of plugins
- names of plugins are no longer localizable (because those names are also used to store settings)
- added settings to disable individual diagnosis settings
- path of dependencies is now configured in a .pri file instead of environment variablees
- bugfix: if the modid-input is canceled, the id was saved as -1 and wasn't re-requested from the user
- bugfix: moving files with the SHFileOperation-Api didn't update the vfs correctly (still not perfect but better)
- bugfix: attempt to remove the deleter-file seems to have caused error messages for some users
- bugfix: fixed a couple of cases that might have caused the tutorial to hang
2014-09-08 20:37:23 +02:00
Tannin 9daeb9479b - re-enabled building of loot_cli and started developing against the new api
- extended set of default categories
- more tolerand bbcode parser
- added a few colors for the bbcode parser
- more fixes to qt5 compatibility
- started work on ability to unloading (and thus re-loading) of plugins
- names of plugins are no longer localizable (because those names are also used to store settings)
- added settings to disable individual diagnosis settings
- path of dependencies is now configured in a .pri file instead of environment variablees
- bugfix: if the modid-input is canceled, the id was saved as -1 and wasn't re-requested from the user
- bugfix: moving files with the SHFileOperation-Api didn't update the vfs correctly (still not perfect but better)
- bugfix: attempt to remove the deleter-file seems to have caused error messages for some users
- bugfix: fixed a couple of cases that might have caused the tutorial to hang
2014-09-08 20:37:23 +02:00
Tannin f481a7aae3 Merge 2014-08-28 18:21:51 +02:00
Tannin 15b9927cef minor fixes 2014-08-28 18:20:40 +02:00
Tannin cc42e76f54 - bugfix: MO would report invalid index errors when downloading while download list is sorted by filetime descending 2014-08-25 21:07:29 +02:00
Tannin 07bae15d7c - bugfix: MO would report invalid index errors when downloading while download list is sorted by filetime descending 2014-08-25 21:07:29 +02:00
Tannin 84598cbcbf - processes spawned from MO are now themselves allowed to break away from the job.
Without this the CEF (chromium embedded framework) seems to fail
- bugfix: Fixed an error message when installing a fomod wrapped in an archive
- bugfix: sorting plugins had no effect on non-skyrim games
- bugfix: fomod parser quit installing filelists after one file
- bugfix: function retrieving local appdata path read wrong directory
2014-08-25 20:12:25 +02:00
Tannin 778160cf0d - processes spawned from MO are now themselves allowed to break away from the job.
Without this the CEF (chromium embedded framework) seems to fail
- bugfix: Fixed an error message when installing a fomod wrapped in an archive
- bugfix: sorting plugins had no effect on non-skyrim games
- bugfix: fomod parser quit installing filelists after one file
- bugfix: function retrieving local appdata path read wrong directory
2014-08-25 20:12:25 +02:00
Tannin 02973be652 - bugfix: mods were specified by internal name in archive and data tab 2014-08-19 18:44:35 +02:00
Tannin 14106436ca - bugfix: mods were specified by internal name in archive and data tab 2014-08-19 18:44:35 +02:00
Tannin fc2591e028 - new plugin-api to determine the origin of a file 2014-08-18 23:01:25 +02:00
Tannin 4f509e365e - new plugin-api to determine the origin of a file 2014-08-18 23:01:25 +02:00
Tannin 9a97098cc3 - bugfix: text files weren't displayed in the mod-info-dialog 2014-08-18 23:01:02 +02:00
Tannin 4ebc8dc014 - bugfix: text files weren't displayed in the mod-info-dialog 2014-08-18 23:01:02 +02:00
Tannin 4b1e6683d2 - can now filter by mod content
- all files/directories that require write access can now be placed in AppData instead of the MO directory
2014-08-18 23:00:25 +02:00
Tannin 5d3c1f34f4 - login package now also uses a "proper" user-agent 2014-08-18 22:57:00 +02:00
Tannin 06701856f8 - login package now also uses a "proper" user-agent 2014-08-18 22:57:00 +02:00
Tannin 5d4a55c3a6 - performance optimizations for detection of file changes in mod directories
- added a workaround for download-link handling in chrome
- MO will now create a profile even if the game-launcher has never been run
- bugfix: files weren't cleanly removed from vfs file register
2014-08-01 12:10:49 +02:00
Tannin 844ba99892 - performance optimizations for detection of file changes in mod directories
- added a workaround for download-link handling in chrome
- MO will now create a profile even if the game-launcher has never been run
- bugfix: files weren't cleanly removed from vfs file register
2014-08-01 12:10:49 +02:00
Tannin 470b6ed0bf - browser dialog now has a hidden url-field (for testing only)
- loot_cli is no longer part of this project. I will probably create a fork of loot that allows command-line usage instead
- loot integration now works with such a modified loot version
- integrated loot will now also integrate incompatibility messages in the MO UI
- overwrite-markers are now updated as the list order is changed
- fnis checker will now always allow the user to ignore fnis errors
- plugin interface now has a function to wait for handles returned from startApplication (which can be job or process handles)
- bugfix: non-mo mods sharing the name with regular mods now have a different internal name
- bugfix: using hotkeys the vanilla game-plugins could be moved
2014-07-27 18:34:32 +02:00
Tannin 715623e790 - browser dialog now has a hidden url-field (for testing only)
- loot_cli is no longer part of this project. I will probably create a fork of loot that allows command-line usage instead
- loot integration now works with such a modified loot version
- integrated loot will now also integrate incompatibility messages in the MO UI
- overwrite-markers are now updated as the list order is changed
- fnis checker will now always allow the user to ignore fnis errors
- plugin interface now has a function to wait for handles returned from startApplication (which can be job or process handles)
- bugfix: non-mo mods sharing the name with regular mods now have a different internal name
- bugfix: using hotkeys the vanilla game-plugins could be moved
2014-07-27 18:34:32 +02:00
Tannin 0050cb0740 - download-list will no longer show a file as having incomplete data if there is no file version
- added a new mod column with icons displaying the content of the mod
- MO now differentiates between mods using an internal name that disambiguates between foreign and regular mods
2014-07-21 19:14:24 +02:00
Tannin 9879aae575 - download-list will no longer show a file as having incomplete data if there is no file version
- added a new mod column with icons displaying the content of the mod
- MO now differentiates between mods using an internal name that disambiguates between foreign and regular mods
2014-07-21 19:14:24 +02:00
Tannin f6ef5477e7 normalized eol style (all files should now have windows line endings) 2014-07-17 22:02:15 +02:00
Tannin cc9827cdda normalized eol style (all files should now have windows line endings) 2014-07-17 22:02:15 +02:00
Tannin e24f3fef77 - bugfix: broke qt4 compatibility in trying to support qt5
- bugfix: overwrite dialog displayed system drives if the overwrite directory didn't exist
- bugfix: ini tweak activation wasn't saved
2014-07-17 20:04:22 +02:00
Tannin 4e5a67fc06 - bugfix: broke qt4 compatibility in trying to support qt5
- bugfix: overwrite dialog displayed system drives if the overwrite directory didn't exist
- bugfix: ini tweak activation wasn't saved
2014-07-17 20:04:22 +02:00
Tannin 0a152ceadf Merge 2014-07-15 20:45:29 +02:00
Tannin 5718af3510 - Disabled compilation of loot_cli as the current loot version can't be compiled or linked against with vs 2010
- bugfix: some incompatibilities with non-skyrim games
- bugfix: incorrect handling of plurals in translateable strings
2014-07-15 20:37:10 +02:00
Tannin 434b6be69d merged changes by TheBloke 2014-07-15 17:48:43 +02:00
Tannin 67b0268e70 - qt 5 compatibility fixes
- detection for support of optimized find no longer depends on deprecated api
2014-07-15 17:31:44 +02:00
Tannin d412060d59 - qt 5 compatibility fixes
- detection for support of optimized find no longer depends on deprecated api
2014-07-15 17:31:44 +02:00
Tannin 84c66727bf - when highlighting a mod the overwritten and overwriting mods are now highlighted in the list
- when starting an external application MO now wraps the process in a job and waits on that instead. This way MO is not unlocked early when skyrim is started through skse
- mod info dialog no longer offers the esp tab for foreign mods because that caused confusion
- updated translation files
- download directory and mod directory are now created if necessary
- bugfix: staging script created unnecessary copies of translation files
- bugfix: potential invalid array access when trying to determine best mod order
- bugfix: deleter file wasn't removed after esp hiding was disabled
- bugfix: potential access to to un-initialized login reply
- bugfix: changed the initialization order to allow more ui controls to be localized
2014-07-14 21:22:44 +02:00
TheBloke bfb3385e49 deleteSavegame:
- Confirmation question shows number of saves to be deleted, when more than 1
2014-07-13 16:11:30 +01:00
TheBloke f59f52501c savegameList: more minor changes
- Context Menu - can do same job with fewer variables and assignments
- deleteSaveGame_clicked - const reference, not new value, in foreach loop
2014-07-13 15:45:19 +01:00
TheBloke 9b67e338e1 savegameList:
- Context menu bugfix, previous method of getting rows didn't work when items
 were selected in certain ways, e.g. Control-A
- Context menu now uses selectedIndexes(), which always works with all selections.
- Renamed enableFixMods to multipleSelected so same value can be used to decide
 whether to show single or plural version of "Delete save(s)"
2014-07-13 15:24:46 +01:00
TheBloke 7944bacfd9 savegameList: A few cleanups and minor code improvements
- Slight improvements over previous commits, using more appropriate methods and
 removing some unnecessary code. No functional changes.
2014-07-12 11:15:34 +01:00
TheBloke 1b4c07eb20 - savegameList: Improved save game handling from MainWindow
-- Save game deletion now does Recycle Bin delete (wishlist #675)
-- Save game deletion now also deletes .skse file (bug #687)
-- Can select and delete multiple save games (ExtendedSelection) (wishlist #675)
-- Uses new SaveGame->saveFiles() method to get filenames (eg .ess & .skse)
-- Context menu - "Fix Mods.." option only appears if 1 save is selected
-- Context menu - delete menu option labelled "Delete save" or "Delete saves",
 according to 1 or >1 saves selected.
-- Context menu - delete menu confirmation shows list of all selected saves
2014-07-11 01:46:42 +01:00
TheBloke d93df95dcf - Save game management: re-factored getting of filenames including .skse
-- New - SaveGame->saveFiles(), returns all filenames for save (eg. ess + skse)
-- Moved - SaveGameGameBryo->attachedFiles() to SaveGame->attachedFiles()
-- This allows the getting of save file names with just a SaveGame object, not
 a GameBryo object, which would do a full file read including plugins and image etc.
-- Therefore SaveGame is no longer abstract.

- Transfer Saves: re-factored to use new SaveGame->saveFiles() method
-- Removed - TransferSavesDialog->getFilesToProcess, now redundant as information
 is now provided by SaveGame class itself.
2014-07-11 01:29:33 +01:00
TheBloke 46a32ff3b7 Additional 'make install' step - install boost_python DLL to output(d)\DLLs
Extended the new ModOrganizer.pro 'make install' steps, to now also copy
  $$(BOOSTPATH)\stage\lib\boost_python-vc*-mt-1*.dll
 This is the final install step required, so that now ModOrganizer.exe works
  fully when a Qt-Creator "Run" step is performed.
 The wildcard should pick up the right version of the library regardless of
  MSVC compiler version used.

Updated Qt5 version check to the standardised greaterThan check.
2014-07-08 04:05:33 +01:00
TheBloke 0046d8710e Compilation dependency tracking enabled for organizer, hook, bsaExtractor, shared
Previously, qmake did not detect when code was changed in the static libraries
 So for example, changing code in shared/*.cpp and then Build, would not cause
  a re-link and re-deploy of ModOrganizer.exe.
 This has been fixed by adding PRE_TARGETDEPS references to each project that
  depend on static libraries provided by other sub-projects.
 These checks are conditional on debug|release, to point to the correct lib.

 List of currently configured static library dependency checks -
  organizer - mo_shared.lib, bsatk.lib
  hookdll - mo_shared.lib, bsatk.lib
  shared - bsatk.lib
  bsaExtractor - bsatk.lib

 I have tested to confirm that changing a shared file results in re-linking and
  re-deplomyent of both ModOrganizer.exe and hook.dll.

 Note that dependencies have not been configured for DLLs, as these are
  loaded dynamically and so recompilation is not required.
  But there could be an argument for configuring DLLs as dependencies too -
   as if you make a change in DLL code, you might want all clients of the DLL to
    be recompiled to check that they have not been broken by the changes?
  The downside of that would be extra re-compilation every time.
2014-07-08 04:01:24 +01:00
TheBloke 2b5748003d .pro files - formatting/consistency fixes
Many small formatting changes to the majority of .pro files
 Consistent style for Qt version checking, using greaterThan(QT_MAJOR_VERSION, 4)
  This seems safest, as would continue to work for a future Qt 6 etc.
  Note that this makes redudundant the commit before this one, to organizer.pro
 Consistent indenting
 Moved some file configuration sections to be together with related sections
 Moved some installation-related sections (e.g. OUTDIR/DSTDIR) to be at the bottom,
  immediately before the related POST_LINK install lines.
 Similarly, in some cases separated out CONFIG(debug,.. checks into separate
  LIB/INCLUDE sections (high in file) and installation directory sections (low
   in file)
2014-07-07 23:32:18 +01:00
TheBloke a49ed5c33c organizer.pro - tiny tweak to Qt5 version check
Directly checking QT_MAJOR_VERSION instead of pattern matching on QT_VERSION
2014-07-07 21:51:35 +01:00
TheBloke 62b0c07a93 Added 'make install' steps in ModOrganizer.pro -
Added config to install required libraries to output(d) directory
 If the user adds a Deploy step, that runs 'jom install', he will have the
  necessary libraries copied to output(d)\dlls
 These libraries are -
  7z.dll
  Qt4 Core Declarative Gui Network OpenGL Script Sql Svg Webkit Xml XmlPatterns
   Different set configured for Qt5, e.g. adding Widgets, Qml, Quick
   In a debug build, the 'd' DLLs will be used instead.
   Qt4 libraries are copied from system Qt4 installation directory.
 This allows the Qt-Creator user to hit "Run" in Qt-C and end up with a complete
  install, including all DLLs; no manual Exporer copying required.
 This therefore removes the need for post-build steps 10 & 11 in Readme.txt.
 Future thought - Update all current POST_LINK (x)copy steps to make install?

Fixed DESTDIR in ModOrganizer.pro
 It was pointing to source/output(d) before, should be ..\output(d)
 It was not used before so didn't matter, but is now referenced for install.
2014-07-07 21:39:27 +01:00
tomjobbins 05c58c8b3d Added tag release v1.2.9 for changeset d70ead9aea95 2014-07-07 20:23:52 +01:00
Tannin 9b33e0a970 Merge 2014-07-03 17:42:56 +02:00
Tannin b1ac479fb6 slight fixes to qt5 compatibility 2014-07-03 17:42:31 +02:00
Tannin 80b10107d9 - Disabled compilation of loot_cli as the current loot version can't be compiled or linked against with vs 2010
- bugfix: some incompatibilities with non-skyrim games
- bugfix: incorrect handling of plurals in translateable strings
2014-07-15 20:37:10 +02:00
TheBloke 1707941f6e deleteSavegame:
- Confirmation question shows number of saves to be deleted, when more than 1
2014-07-13 16:11:30 +01:00
TheBloke d0b75e8b25 savegameList: more minor changes
- Context Menu - can do same job with fewer variables and assignments
- deleteSaveGame_clicked - const reference, not new value, in foreach loop
2014-07-13 15:45:19 +01:00
TheBloke 4fc441b249 savegameList:
- Context menu bugfix, previous method of getting rows didn't work when items
 were selected in certain ways, e.g. Control-A
- Context menu now uses selectedIndexes(), which always works with all selections.
- Renamed enableFixMods to multipleSelected so same value can be used to decide
 whether to show single or plural version of "Delete save(s)"
2014-07-13 15:24:46 +01:00
TheBloke 581d065d7a savegameList: A few cleanups and minor code improvements
- Slight improvements over previous commits, using more appropriate methods and
 removing some unnecessary code. No functional changes.
2014-07-12 11:15:34 +01:00
TheBloke 5d2b5202af - savegameList: Improved save game handling from MainWindow
-- Save game deletion now does Recycle Bin delete (wishlist #675)
-- Save game deletion now also deletes .skse file (bug #687)
-- Can select and delete multiple save games (ExtendedSelection) (wishlist #675)
-- Uses new SaveGame->saveFiles() method to get filenames (eg .ess & .skse)
-- Context menu - "Fix Mods.." option only appears if 1 save is selected
-- Context menu - delete menu option labelled "Delete save" or "Delete saves",
 according to 1 or >1 saves selected.
-- Context menu - delete menu confirmation shows list of all selected saves
2014-07-11 01:46:42 +01:00
TheBloke 8044ef4f1d - Save game management: re-factored getting of filenames including .skse
-- New - SaveGame->saveFiles(), returns all filenames for save (eg. ess + skse)
-- Moved - SaveGameGameBryo->attachedFiles() to SaveGame->attachedFiles()
-- This allows the getting of save file names with just a SaveGame object, not
 a GameBryo object, which would do a full file read including plugins and image etc.
-- Therefore SaveGame is no longer abstract.

- Transfer Saves: re-factored to use new SaveGame->saveFiles() method
-- Removed - TransferSavesDialog->getFilesToProcess, now redundant as information
 is now provided by SaveGame class itself.
2014-07-11 01:29:33 +01:00
TheBloke 3d98491ebc Additional 'make install' step - install boost_python DLL to output(d)\DLLs
Extended the new ModOrganizer.pro 'make install' steps, to now also copy
  $$(BOOSTPATH)\stage\lib\boost_python-vc*-mt-1*.dll
 This is the final install step required, so that now ModOrganizer.exe works
  fully when a Qt-Creator "Run" step is performed.
 The wildcard should pick up the right version of the library regardless of
  MSVC compiler version used.

Updated Qt5 version check to the standardised greaterThan check.
2014-07-08 04:05:33 +01:00
TheBloke 923654961b Compilation dependency tracking enabled for organizer, hook, bsaExtractor, shared
Previously, qmake did not detect when code was changed in the static libraries
 So for example, changing code in shared/*.cpp and then Build, would not cause
  a re-link and re-deploy of ModOrganizer.exe.
 This has been fixed by adding PRE_TARGETDEPS references to each project that
  depend on static libraries provided by other sub-projects.
 These checks are conditional on debug|release, to point to the correct lib.

 List of currently configured static library dependency checks -
  organizer - mo_shared.lib, bsatk.lib
  hookdll - mo_shared.lib, bsatk.lib
  shared - bsatk.lib
  bsaExtractor - bsatk.lib

 I have tested to confirm that changing a shared file results in re-linking and
  re-deplomyent of both ModOrganizer.exe and hook.dll.

 Note that dependencies have not been configured for DLLs, as these are
  loaded dynamically and so recompilation is not required.
  But there could be an argument for configuring DLLs as dependencies too -
   as if you make a change in DLL code, you might want all clients of the DLL to
    be recompiled to check that they have not been broken by the changes?
  The downside of that would be extra re-compilation every time.
2014-07-08 04:01:24 +01:00
TheBloke 76c861ed12 .pro files - formatting/consistency fixes
Many small formatting changes to the majority of .pro files
 Consistent style for Qt version checking, using greaterThan(QT_MAJOR_VERSION, 4)
  This seems safest, as would continue to work for a future Qt 6 etc.
  Note that this makes redudundant the commit before this one, to organizer.pro
 Consistent indenting
 Moved some file configuration sections to be together with related sections
 Moved some installation-related sections (e.g. OUTDIR/DSTDIR) to be at the bottom,
  immediately before the related POST_LINK install lines.
 Similarly, in some cases separated out CONFIG(debug,.. checks into separate
  LIB/INCLUDE sections (high in file) and installation directory sections (low
   in file)
2014-07-07 23:32:18 +01:00
TheBloke 31cab54861 organizer.pro - tiny tweak to Qt5 version check
Directly checking QT_MAJOR_VERSION instead of pattern matching on QT_VERSION
2014-07-07 21:51:35 +01:00
TheBloke 2a16cc4262 Added 'make install' steps in ModOrganizer.pro -
Added config to install required libraries to output(d) directory
 If the user adds a Deploy step, that runs 'jom install', he will have the
  necessary libraries copied to output(d)\dlls
 These libraries are -
  7z.dll
  Qt4 Core Declarative Gui Network OpenGL Script Sql Svg Webkit Xml XmlPatterns
   Different set configured for Qt5, e.g. adding Widgets, Qml, Quick
   In a debug build, the 'd' DLLs will be used instead.
   Qt4 libraries are copied from system Qt4 installation directory.
 This allows the Qt-Creator user to hit "Run" in Qt-C and end up with a complete
  install, including all DLLs; no manual Exporer copying required.
 This therefore removes the need for post-build steps 10 & 11 in Readme.txt.
 Future thought - Update all current POST_LINK (x)copy steps to make install?

Fixed DESTDIR in ModOrganizer.pro
 It was pointing to source/output(d) before, should be ..\output(d)
 It was not used before so didn't matter, but is now referenced for install.
2014-07-07 21:39:27 +01:00
Tannin a5b6556d67 slight fixes to qt5 compatibility 2014-07-03 17:42:31 +02:00
Tannin af89733121 - bugfix: update.bsa is again treated like a regular bsa because hiding it from the archive-list made it impossible (in managed bsa mode) to overwrite files from update.bsa
- bugfix: disabled-state for mo management wasn't saved
- bugfix: when starting an application, settings were saved twice
- bugfix: origin ids and handles for directory updates were out of sync
2014-06-30 22:37:21 +02:00
Tannin baf1240be7 Added tag release v1.2.6 for changeset c40e9a70e99e 2014-06-29 15:09:55 +02:00
Tannin 6e4626852c - re-inserted code for bsa hiding (this was necessary to enforce expected bsa order after all)
- bsas from foreign bsas are now loaded as expected by hook.dll as well
- state of log-window-split is now saved
- auto completion in installer name boxes is now case-sensitive so that users can change casing of the mod names
- bugfix: self updater did enforce the skyrim url for MO updates but not the game_id
- bugfix: modinfo dialog didn't correctly read mod meta information on opening
- bugfix: MO didn't report on endorsement (for MO)
2014-06-29 15:09:45 +02:00
Tannin e8f56d65d2 Added tag release v1.2.5 for changeset 70663ff89a38 2014-06-25 23:51:39 +02:00
Tannin 5e7c875b29 - test-plugins accidentally distributed in the 1.2.5 release are now automatically deleted
- some fixes to the tutorial (mostly wording but also some actual problems)
- bugfix: could disable mods that aren't supposed to be disable-able
- bugfix: mod list wasn't saved on some changes
- bugfix: when trying to start directly to application, MO didn't start up correctly
- bugfix: hook.dll didn't load mod bsas into its directory structure and thus didn't allow bsas to overwrite loose files
- bugfix: in some constellations the tutorial files couldn't be found despite being in the right location
2014-06-25 23:51:29 +02:00
Tannin b2a7c7c223 Merge 2014-06-23 21:43:40 +02:00
Tannin 7b4582c1b1 - adjusted mod load order in hook.dll to match the one from the UI
- bugfix: fnis checker took files in archives into consideration for hashing
2014-06-23 20:23:59 +02:00
Tannin 5d7b23acef - bugfix: networkaccessmanager of browser dialog wasn't destroyed correctly. As a result the cookie jar doesn't get saved 2014-06-21 12:16:57 +02:00
Tannin 3628ec930b - changed the url used to login on nexus (the previous page was disabled)
- bugfix: download manager might have tried to read from a closed connection
2014-06-21 10:39:28 +02:00
Tannin e22aeca3ff - download read buffer is now limited to 1MB. Might prevent out-of-memory errors during download
- bugfix: plugins are now disabled when deactivating a mod  before the files are removed from the vfs
2014-06-17 18:36:28 +02:00
Tannin cbd6b288eb Merge 2014-06-16 21:50:53 +02:00
Tannin 484749e612 - added pseudo-categories to filter for mo-managed vs. unmanaged mods
- deleted mods are now moved to the recycle bin instead of being deleted permanently
- reduced modinfo dialog for foreign mods
- foreign mods are now displayed with a pseudo-category
- added a signal when a plugin is moved
- bugfix: refreshing of directory structure for mods with bsas didn't work correctly when enabling a mod and on changing display of foreign mods
- bugfix: one mod in the list was assigned the same priority on the directory structure as the data directory
- bugfix: conflicts tab in the mod info dialog offered the hide option for files in bsas
2014-06-16 21:49:57 +02:00
Tannin 5b3cdaa83b bugfix: the warning dialog upon changing the mod directory didn't have an effect, the process couldn't be canceled 2014-06-14 09:17:57 +02:00
Tannin 6d3f88b330 Added tag release v1.2.3 for changeset c503e48f97aa 2014-06-08 15:10:21 +02:00
220 changed files with 36036 additions and 77181 deletions
+24
View File
@@ -1,4 +1,6 @@
syntax: glob
scons_configure.py
scons-ModOrganizer-*
ModOrganizer-build-desktop*
outputd/*
output/*
@@ -18,5 +20,27 @@ staging_prepare/*
staging_trans/*
tools/python_zip/*
Makefile
html
*.vcxproj
*.pdb
*.dll
*.exp
*.tlog
*.user
*.obj
*.suo
*.sln
*.log
*.filters
*.lib
source/organizer/resources/contents/icons
source/plugins/build-*
*/GeneratedFiles/*
translations/*
source/LocalPaths.pri
source/*/Win32/Debug/*
source/plugins/*/Win32/Debug/*
*~
syntax: regexp
Makefile\.(Debug|Release)
source/.*/debug/.*
+94 -35
View File
@@ -10,7 +10,7 @@ Please note that if you only want to work on and build a plugin you can save you
Overview:
---------
As of December 2013 MO consists of the following subprojects:
As of July 2014 MO consists of the following subprojects:
- organizer: The main userinterface. heavy usage of various libraries
- hookdll: core library of the virtual file system
- uibase: interop between plugins and the main application as well as some reusable functionality
@@ -23,14 +23,15 @@ As of December 2013 MO consists of the following subprojects:
- archive: small wrapper library around 7zip for dealing with mod archives. Requires 7zip
- NCC: extension to NMM to provide a binary with command line interface for fomod installation. This is c# code and does not build with the rest of the project. Requires the rest of NMM
- bossdummy: dummy dll that looks like the boss.dll. This is used instead of the real boss dlls in NCC to save some disk space
- pythonrunner: library for embedding python code. Requires boost_python, python 2.7 and pyqt4
- pythonrunner: library for embedding python code. Requires boost_python, python 2.7 and pyqt5
- loot_cli: this is a command line client of loot. This can be better integrated with MO than the official loot client.
And various plugins:
- bsaExtractor: offers to extract bsas after a mod has been installed
- checkFNIS: Activates each time an application is started from MO and runs fnis if necessary
- diagnoseBasic: Various diagnostic checks on the game
- inieditor: minimalistic file editor for ini files
- installerBain: handles non-scripted bain installers
- installerBCF: no functionality. Supposed to eventually allow installations using bcfs (bain conversion file). python code
- installerBundle: handles installation of archives wrapped in archives
- installerFomod: handles installation of xml fomods
- installerManual: handles installations of archives that aren't supported by any other plugin (or if the user chooses to do the installation manually)
@@ -39,25 +40,30 @@ And various plugins:
- NMMImport: importer from existing nmm installation
- proxyPython: integrates pythonrunner as a plugin into MO
- pyniEdit: more user-friendly ini editor. python code
- previewBase: used for file previews. this plugin covers image formats supported by the qt installation (usually at least jpg, gif, png) and text files
- previewDDS: used to preview dds textures. uses code from the nif file format library
There are a few more plugins that are either broken or samples
- installerBCF: this was intended to use .bcf (bain conversion file) files as installation instructions but currently it is completely function-less
- helloWorldCpp: sample for cpp plugins. This should compile even without fulfilling most dependencies below
- pageTESAlliance: integrates the tes alliance page into MO. This integration is not nearly as tight as that of nexus.
Requirements:
-------------
Visual C++ compiler 2010 (VC 10.0) or up
- Included in visual c++ express 2010 or windows sdk 7.x
Visual C++ compiler 2013 (VC 12.0) or up
- Included in visual c++ express 2013
- Do install windows sdk too if only for the cdb debugger which is included in that package
Note: If you're having trouble installing the windows sdk, you may be affected by this bug: http://support.microsoft.com/kb/2717426
Qt Libraries 4.8.x (http://qt-project.org/downloads)
- i.e. "Qt libraries 4.8.5 for Windows (VS 2010, 235 MB)"
- tested: 4.8.5
- Qt5 is not yet supported but WIP. You will see a few conditional qt5 pathes
Qt Libraries 5.4.x (http://www.qt.io/download-open-source/#section-2)
- i.e. "Qt libraries 5.4.0 for Windows (VS 2013, 722 MB)"
- tested: 5.4.0 for Windows 32-bit (VS 2013, OpenGL, 695 MB)
- Install according to instruction
boost libraries (http://www.boost.org/)
- tested: 1.49
- Build according to their instructions (using vc++): http://www.boost.org/doc/libs/1_54_0/more/getting_started/windows.html
- tested: 1.56
- Build according to their instructions (using vc++): http://www.boost.org/doc/libs/1_57_0/more/getting_started/windows.html
- A few of the boost libraries need to be built (the rest is header-only). The only compiled libs MO needs (at the time of writing) are
boost_thread (for everything that links agains bsatk) and boost_python (for pythonrunner). You can disable the others to save yourself compile time (even on a modern system compiling boost can easily take an hour)
@@ -73,26 +79,27 @@ zlib (http://www.zlib.net/)
Python 2.7 (32-bit)
- only for pythonrunner
PyQt4 for Python 2.7
- tested: 4.10
PyQt5 for Python 2.7 (http://www.riverbankcomputing.co.uk/software/pyqt/download)
- tested: PyQt-gpl-5.4.zip
- only for pythonrunner
SIP (http://www.riverbankcomputing.com/software/sip/download)
- presumably only for pythonrunner as it's needed for PyQT5
Recommended:
------------
Qt Creator
- http://qt-project.org/downloads#qt-creator
- I.e. "Qt Creator 2.8.1 for Windows (53 MB)"
- included in Qt SDK
- With Qt Creator usually the rule is "the newer the better"
- Start Qt Creator and check if things are set up correctly:
1) Go to Tools > Options > Build & Run > Qt Versions
2.1) If the QtSDK 4.8.x you installed earlier is not auto-detected, click "Add" to add it manually
2.2) Navigate to your <your qt4 installation>\bin\qmake.exe
2.1) If the QtSDK 5.4.x you installed earlier is not auto-detected, click "Add" to add it manually
2.2) Navigate to your <your qt5 installation>\bin\qmake.exe
2.3) Restart qt creator
3) Go to Tools > Options > Build & Run > Kits
3.1) If no Kit is auto-detected (or the auto-detected ones have picked up the wrong qt or vc++ installation) click "Add"
3.2) Enter a Name (i.e. "Qt 4.8.5 MSVC2010 32bit")
3.2) Enter a Name (i.e. "Qt 5.4 MSVC2013 32bit")
3.3) In Compiler select the visual studio compiler installed earlier (may show up as "Microsoft Windows SDK for Windows x). Make sure you select the x86 variant
3.4) CDB should be auto-detected
3.5) Select the qt version set up earlier
@@ -101,25 +108,26 @@ Qt Creator
Set up (using Qt Creator):
--------------------------
1. Using Qt Creator open source/ModOrganizer.pro from your working copy
2. Open the "Projects" tab, open the "Details" for "Build Environment"
3a. Click "Add" to add a variable called "BOOSTPATH" with the path of your boost installation as the value (i.e. C:\code\boost_1_49_0)
3b. Click "Add" to add a variable called "ZLIBPATH" with the path of your zlib installation as the value (i.e. C:\code\zlib-1.2.7)
3c. Click "Add" to add a variable called "7ZIPPATH" with the path of your zlib installation as the value (i.e. C:\code\7zip)
3d. Click "Add" to add a variable called "PYTHONPATH" with the path of your zlib installation as the value (i.e. C:\code\python)
4. Switch the build configuration at the very top of the same page from "debug" to "release" (or vice versa) and repeat step 3
5. Compile the configuration(s) you want to use (debug and/or release) (Build All). This should compile correctly.
6. <reserved for future use. Maybe grab a coffee?>
7. return to the "projects" tab and switch to "Run Settings"
8. Determine the folder of the qt binaries in the package you downloaded. This could be "QtSDK\Desktop\Qt\4.8.5\msvc2010\bin" or "Qt4.8.5\bin"
1. Create a file called "LocalPaths.pri" in your ModOrganizer\source directory
2. Open that file with any text editor and enter (one entry per line)
2a. BOOSTPATH=<path to your boost installation> (i.e. C:\code\boost_1_56_0)
2b. LOOTPATH=C:/Users/Tannin/Documents/Projects/loot_api
2c. PYTHONPATH=D:/Python278
2d. SEVENZIPPATH=D:/Documents/Projects/7zip
2e. ZLIBPATH=D:/Documents/Projects/zlib-1.2.7
3. Using Qt Creator open source/ModOrganizer.pro from your working copy
4. Compile the configuration(s) you want to use (debug and/or release) (Build All). This should compile correctly (though right now it produces a lot of warnings in boost headers).
5. <reserved for future use. Maybe grab a coffee?>
6. return to the "projects" tab and switch to "Run Settings"
7. Determine the folder of the qt binaries in the package you downloaded. This could be "QtSDK\Desktop\Qt\5.4.0\msvc2013\bin" or "Qt5.4.0\bin"
For Release build:
9r. Add a "Run configuration" that points to <your working copy>\output\ModOrganizer.exe
10r. Copy "7z.dll" to <your working copy>\output\dlls
11r. From the qt binaries directory, copy the following files to <your working copy>\output\dlls: QtCore4.dll, QtDeclarative4.dll, QtGui4.dll, QtNetwork4.dll, QtScript4.dll, QtSql4.dll, QtWebkit4.dll, QtXml4.dll, QtXmlPatterns4.dll
8r. Add a "Run configuration" that points to <your working copy>\output\ModOrganizer.exe
9r. Copy "7z.dll" to <your working copy>\output\dlls
10r. From the qt binaries directory, copy the following files to <your working copy>\output\dlls: Qt5Core.dll, Qt5Declarative.dll, Qt5Gui.dll, Qt5Network.dll, Qt5Script.dll, Qt5Sql.dll, Qt5Webkit.dll, Qt5Xml.dll, Qt5XmlPatterns.dll
For Debug build:
9d. Add a "Run configuration" that points to <your working copy>\outputd\ModOrganizer.exe
10d. Copy "7z.dll" to <your working copy>\outputd\dlls
11d. From the qt binaries copy the following files to <your working copy>\outputd\dlls: QtCored4.dll, QtDeclaratived4.dll, QtGuid4.dll, QtNetworkd4.dll, QtScriptd4.dll, QtSqld4.dll, QtWebkitd4.dll, QtXmld4.dll, QtXmlPatternsd4.dll
8d. Add a "Run configuration" that points to <your working copy>\outputd\ModOrganizer.exe
9d. Copy "7z.dll" to <your working copy>\outputd\dlls
10d. From the qt binaries copy the following files to <your working copy>\outputd\dlls: Qt5Cored.dll, Qt5Declaratived.dll, Qt5Guid.dll, Qt5Networkd.dll, Qt5Scriptd.dll, Qt5Sqld.dll, Qt5Webkitd.dll, Qt5Xmld.dll, Qt5XmlPatternsd.dll
Now you should be able to compile and run Mod Organizer.
Please note that when you change anything apart from the "organizer" subproject, qt creator may not pick up on the changes
@@ -157,6 +165,8 @@ Troubleshooting (thanks to Ross):
./bsatk/bsatk.pro
./hookdll/hookdll.pro
Please note if building this, you need to switch OFF -DZLIB_WINAPI ...
2) After building, I try to open {MOPROJECTPATH}\outputd\ModOragnizer.exe and get this error
"The program can't start because QtDeclaratived4.dll is missing from your computer. Try reinstalling the program to fix this problem."
@@ -212,3 +222,52 @@ Troubleshooting (thanks to Ross):
Unlocker: http://www.filehippo.com/download_unlocker/ or http://www.emptyloop.com/unlocker/
Warning: With Unlocker v1.9.2, you must select "Advanced" then uncheck everything to
avoid having some Delta toolbar garbage installed...
5) Problem TT has seen:
Complains about 'qtwebkit4' missing. For some reason this seems to insist on
living with modorganiser.exe
6) Debugging the python proxy: I (TT) don't think this is possible unless you have a debug
build of PyQt. However, a debug build of PyQt requires a debug build of python. There doesn't
appear to be a half way house which is build wiht normal python but debug versions of QT libraries.
You can confuse pyqt by copying the debug QT DLLs to appropriate named files in the DLLs
directory, and removing QT from your project run path, which results in the python proxy
initialising succesfully, but causes mod organiser to crash in strange places.
-------------------
Building with scons
-------------------
1) Download scons from www.scons.org and install
2) Download QT4 (and/or QT5) from https://bitbucket.org/dirkbaechle/scons_qt4 and
https://bitbucket.org/dirkbaechle/scons_qt5. Install as per instructions
3) Copy scons_configure_template.py to scons_configure.py. Edit to point to your
boost/python/zlib/7zip/loot directories as appropriate.
4) Create build kits as follows:
Custom Process step:
Command: <python path>\Scripts\scons.bat
Arguments: -u .
Working directory: %{sourcedir}
Clean Custom Process step:
Command: <python path>\Scripts\scons.bat
Arguments: -c -u .
Working directory: %{sourcedir}
For the release build, add 'CONFIG=release' to the arguments.
If you want to do parallel builds, add -j and a number to the arguments.
However you may need to install pywin32 (but it seems to work OK for me).
-j 4 did the entire build in 2m 15s. scons uses -Z7 to store debugging
information in the .obj files which removes the issues with multiple
processes attempting to access one datafile.
Note. If you want to build a sub project separately, it seems to be better
to open the subproject, set that up with the scons kit and build that as a
project.
Please note: the generated (runnable) output files end up in the build directory,
in the '_ModOrganizer' subdirectory (not at the top level). Named like that
so you can see it! The scons build will also populate the directory with
all the necessary DLLs (but see note 6 above about your build tool path if
trying to debug).
+28
View File
@@ -0,0 +1,28 @@
# This python script contains the configuration for scons
# Copy this to scons_configure.py and adjust to taste.
# Path to your boost install - it should have a boost/ subdirectory and a stage/
# subdirectory. The scons script will use stage/lib if there, or the appropriate
# version for your compiler, if you installed the multiple-build version
BOOSTPATH = 'C:\\Apps\\boost_1_55_0'
# Version of Visual Studio to use, if you wish to use a specific version. If you
# don't specify a version, the latest will be picked.. See the scons manual for
# supported values.
#MSVC_VERSION = '10.0Exp'
# Path to your python install
# You don't really need to set this up but you might if (say) you have a 32- and
# 64-bit python install and scons has been installed for the 64 bit version
#PYTHONPATH=C:\Apps\Python
# Path to your QT install. This might constrain the version of MSVC you can use.
# This seems to be set by QTCreator
#QTDIR = 'C:\\Apps\\Qt\\4.8.6'
# Path to 7-zip sources
SEVENZIPPATH = 'C:\\Apps\\7-Zip\\7z920'
# Path to zlib. Please read the README file for more information about how this
# needs to be set up
ZLIBPATH = 'C:\\Apps\\zlib-1.2.8'
+1566 -1059
View File
File diff suppressed because it is too large Load Diff
+37 -8
View File
@@ -1,6 +1,5 @@
TEMPLATE = subdirs
SUBDIRS = bsatk \
shared \
uibase \
@@ -9,19 +8,49 @@ SUBDIRS = bsatk \
archive \
helper \
plugins \
proxydll \
nxmhandler \
BossDummy \
pythonRunner \
esptk \
loot_cli
loot_cli \
esptk
plugins.depends = pythonRunner
pythonRunner.depends = uibase
plugins.depends = pythonRunner uibase
hookdll.depends = shared
organizer.depends = shared uibase plugins loot_cli
organizer.depends = shared uibase plugins
CONFIG(debug, debug|release) {
DESTDIR = outputd
DESTDIR = $$PWD/../outputd
} else {
DESTDIR = output
DESTDIR = $$PWD/../output
}
STATICDATAPATH = $${DESTDIR}\\..\\tools\\static_data\\dlls
DLLSPATH = $${DESTDIR}\\dlls
otherlibs.path = $$DLLSPATH
otherlibs.files += $${STATICDATAPATH}\\7z.dll \
$${BOOSTPATH}\\stage\\lib\\boost_python-vc*-mt-1*.dll
qtlibs.path = $$DLLSPATH
greaterThan(QT_MAJOR_VERSION, 4) {
QTLIBNAMES += Core Gui Network OpenGL Script Sql Svg Qml Quick Webkit Widgets Xml XmlPatterns
} else {
QTLIBNAMES += Core Declarative Gui Network OpenGL Script Sql Svg Webkit Xml XmlPatterns
}
QTLIBSUFFIX = $${QT_MAJOR_VERSION}.dll
CONFIG(debug, debug|release): QTLIBSUFFIX = "d$${QTLIBSUFFIX}" # Can't use Debug: .. here, it ignores the line - no idea why, as it works in BossDummy.pro
for(QTNAME, QTLIBNAMES) {
QTFILE = Qt$${QTNAME}
qtlibs.files += $$[QT_INSTALL_BINS]\\$${QTFILE}$${QTLIBSUFFIX}
}
INSTALLS += qtlibs otherlibs
OTHER_FILES +=\
../SConstruct\
../scons_configure.py\
SConscript
+127
View File
@@ -0,0 +1,127 @@
import os
import subprocess
Import('qt_env')
env = qt_env.Clone()
modules = [
'Core',
'Gui',
'Network',
'Script',
'Sql',
'WebKit',
'Xml',
'XmlPatterns',
'Declarative'
]
if env['QT_MAJOR_VERSION'] > 4:
modules += [
'Widgets',
'Qml',
'WebKitWidgets'
]
env.EnableQtModules(*modules)
env.Uic(env.Glob('*.ui'))
env.RequireLibraries('uibase', 'shared', 'bsatk', 'esptk')
env.AppendUnique(LIBS = [
'shell32',
'user32',
'ole32',
'advapi32',
'gdi32',
'shlwapi',
'Psapi',
'Version'
])
# We have to 'persuade' moc to generate certain other targets and inject them
# into the list of cpps
other_sources = env.AddExtraMoc(env.Glob('*.h'))
for file in env.Glob('*.rc'):
# version.rc is included in app_icon.rc. Not sure why it's a separate file.
if file.name == 'version.rc':
continue
other_sources.append(env.RES(file))
# Note the order of this is important, or you can pick up the wrong report.h...
# Doing appendunique seems to throw the moc code into a tizzy
env['CPPPATH'] += [
'../archive',
# '../boss_modified/boss-api',
'../plugins/gamefeatures',
'.', # Why is this necessary?
'${LOOTPATH}',
'${BOOSTPATH}',
]
env.AppendUnique(CPPDEFINES = [
'_UNICODE',
'_CRT_SECURE_NO_WARNINGS',
'_SCL_SECURE_NO_WARNINGS',
'BOOST_DISABLE_ASSERTS',
'NDEBUG',
'QT_MESSAGELOGCONTEXT'
])
env.AppendUnique(CPPFLAGS = [ '-wd4100', '-wd4127', '-wd4512', '-wd4189' ])
env.AppendUnique(LINKFLAGS = [
'/SUBSYSTEM:WINDOWS',
'${EXE_MANIFEST_DEPENDENCY}'
])
# modeltest is optional and it doesn't compile anyway...
cpp_files = [
x for x in Glob('*.cpp')
if x.name != 'modeltest.cpp' and x.name != 'aboutdialog.cpp'
]
about_env = env.Clone()
try:
hgid = subprocess.check_output(['hg', 'id', '-i']).rstrip()
except:
hgid = 'Unknown version'
# FIXME: It'd be much easier to stringify this in the source code
about_env.AppendUnique(CPPDEFINES = [ 'HGID=\\"%s\\"' % hgid ])
other_sources.append(about_env.StaticObject('aboutdialog.cpp'))
env.AppendUnique(LIBPATH = "${ZLIBPATH}/build")
env.AppendUnique(LIBS = 'zlibstatic')
prog = env.Program('ModOrganizer',
cpp_files + env.Glob('*.qrc') + other_sources)
env.InstallModule(prog)
for subdir in ('tutorials', 'stylesheets'):
env.Install(os.path.join(env['INSTALL_PATH'], subdir),
env.Glob(os.path.join(subdir, '*')))
# FIXME Sort the translations. Except they don't exist on the 1.2 branch
res = env['QT_USED_MODULES']
Return('res')
"""
CONFIG(debug, debug|release) {
} else {
QMAKE_CXXFLAGS += /Zi /GL
QMAKE_LFLAGS += /DEBUG /LTCG /OPT:REF /OPT:ICF
}
TRANSLATIONS = organizer_en.ts
QMAKE_POST_LINK += xcopy /y /s /I $$quote($$BASEDIR\\*.qm) $$quote($$DSTDIR)\\translations $$escape_expand(\\n)
"""
+6 -6
View File
@@ -35,17 +35,17 @@ AboutDialog::AboutDialog(const QString &version, QWidget *parent)
m_LicenseFiles[LICENSE_BOOST] = "boost.txt";
m_LicenseFiles[LICENSE_CCBY3] = "by-sa3.txt";
m_LicenseFiles[LICENSE_ZLIB] = "zlib.txt";
m_LicenseFiles[LICENSE_APACHE2] = "apache-license-2.0.txt";
addLicense("Qt 4.8.5", LICENSE_LGPL3);
addLicense("Qt 5.4", LICENSE_LGPL3);
addLicense("Qt Json", LICENSE_GPL3);
addLicense("Boost Library", LICENSE_BOOST);
addLicense("Tango Icon Theme", LICENSE_NONE);
addLicense("RRZE Icon Set", LICENSE_CCBY3);
addLicense("7-zip", LICENSE_LGPL3);
addLicense("ZLib", LICENSE_ZLIB);
addLicense("NIF File Format Library", LICENSE_BSD3);
addLicense("BOSS (modified)", LICENSE_GPL3);
addLicense("Alphanum Algorithm", LICENSE_ZLIB);
addLicense("Tango Icon Theme", LICENSE_NONE);
addLicense("RRZE Icon Set", LICENSE_CCBY3);
addLicense("Icons by Lorc, Delapouite and sbed available on http://game-icons.net", LICENSE_CCBY3);
addLicense("Castle Core", LICENSE_APACHE2);
ui->nameLabel->setText(QString("<span style=\"font-size:12pt; font-weight:600;\">%1 %2</span>").arg(ui->nameLabel->text()).arg(version));
#ifdef HGID
+2 -1
View File
@@ -48,7 +48,8 @@ private:
LICENSE_BSD3,
LICENSE_BOOST,
LICENSE_CCBY3,
LICENSE_ZLIB
LICENSE_ZLIB,
LICENSE_APACHE2
};
private:
+15
View File
@@ -178,6 +178,11 @@
<string notr="true">tokcdk (Russian)</string>
</property>
</item>
<item>
<property name="text">
<string>Ren (Korean)</string>
</property>
</item>
</widget>
</item>
</layout>
@@ -214,6 +219,16 @@
<string notr="true">Bridger</string>
</property>
</item>
<item>
<property name="text">
<string>GamerPoet</string>
</property>
</item>
<item>
<property name="text">
<string>Gopher</string>
</property>
</item>
<item>
<property name="text">
<string notr="true">GSDFan</string>
+97 -97
View File
@@ -1,97 +1,97 @@
/*
Copyright (C) 2012 Sebastian Herbord. All rights reserved.
This file is part of Mod Organizer.
Mod Organizer is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Mod Organizer is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
*/
#include "activatemodsdialog.h"
#include "ui_activatemodsdialog.h"
#include <QComboBox>
#include <QLabel>
ActivateModsDialog::ActivateModsDialog(const std::map<QString, std::vector<QString> > &missingPlugins, QWidget *parent)
: TutorableDialog("ActivateMods", parent), ui(new Ui::ActivateModsDialog)
{
ui->setupUi(this);
QTableWidget *modsTable = findChild<QTableWidget*>("modsTable");
QHeaderView *headerView = modsTable->horizontalHeader();
#if QT_VERSION >= QT_VERSION_CHECK(5,0,0)
headerView->setSectionResizeMode(0, QHeaderView::Stretch);
headerView->setSectionResizeMode(1, QHeaderView::Interactive);
#else
headerView->setResizeMode(0, QHeaderView::Stretch);
headerView->setResizeMode(1, QHeaderView::Interactive);
#endif
int row = 0;
modsTable->setRowCount(missingPlugins.size());
for (std::map<QString, std::vector<QString> >::const_iterator espIter = missingPlugins.begin();
espIter != missingPlugins.end(); ++espIter, ++row) {
modsTable->setCellWidget(row, 0, new QLabel(espIter->first));
if (espIter->second.size() == 0) {
modsTable->setCellWidget(row, 1, new QLabel(tr("not found")));
} else {
QComboBox* combo = new QComboBox();
for (std::vector<QString>::const_iterator modIter = espIter->second.begin();
modIter != espIter->second.end(); ++modIter) {
combo->addItem(*modIter);
}
modsTable->setCellWidget(row, 1, combo);
}
}
}
ActivateModsDialog::~ActivateModsDialog()
{
delete ui;
}
std::set<QString> ActivateModsDialog::getModsToActivate()
{
std::set<QString> result;
QTableWidget *modsTable = findChild<QTableWidget*>("modsTable");
for (int row = 0; row < modsTable->rowCount(); ++row) {
QComboBox *comboBox = dynamic_cast<QComboBox*>(modsTable->cellWidget(row, 1));
if (comboBox != NULL) {
result.insert(comboBox->currentText());
}
}
return result;
}
std::set<QString> ActivateModsDialog::getESPsToActivate()
{
std::set<QString> result;
QTableWidget *modsTable = findChild<QTableWidget*>("modsTable");
for (int row = 0; row < modsTable->rowCount(); ++row) {
QComboBox *comboBox = dynamic_cast<QComboBox*>(modsTable->cellWidget(row, 1));
if (comboBox != NULL) {
QLabel *espName = dynamic_cast<QLabel*>(modsTable->cellWidget(row, 0));
result.insert(espName->text());
}
}
return result;
}
/*
Copyright (C) 2012 Sebastian Herbord. All rights reserved.
This file is part of Mod Organizer.
Mod Organizer is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Mod Organizer is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
*/
#include "activatemodsdialog.h"
#include "ui_activatemodsdialog.h"
#include <QComboBox>
#include <QLabel>
ActivateModsDialog::ActivateModsDialog(const std::map<QString, std::vector<QString> > &missingPlugins, QWidget *parent)
: TutorableDialog("ActivateMods", parent), ui(new Ui::ActivateModsDialog)
{
ui->setupUi(this);
QTableWidget *modsTable = findChild<QTableWidget*>("modsTable");
QHeaderView *headerView = modsTable->horizontalHeader();
#if QT_VERSION >= QT_VERSION_CHECK(5,0,0)
headerView->setSectionResizeMode(0, QHeaderView::Stretch);
headerView->setSectionResizeMode(1, QHeaderView::Interactive);
#else
headerView->setResizeMode(0, QHeaderView::Stretch);
headerView->setResizeMode(1, QHeaderView::Interactive);
#endif
int row = 0;
modsTable->setRowCount(missingPlugins.size());
for (std::map<QString, std::vector<QString> >::const_iterator espIter = missingPlugins.begin();
espIter != missingPlugins.end(); ++espIter, ++row) {
modsTable->setCellWidget(row, 0, new QLabel(espIter->first));
if (espIter->second.size() == 0) {
modsTable->setCellWidget(row, 1, new QLabel(tr("not found")));
} else {
QComboBox* combo = new QComboBox();
for (std::vector<QString>::const_iterator modIter = espIter->second.begin();
modIter != espIter->second.end(); ++modIter) {
combo->addItem(*modIter);
}
modsTable->setCellWidget(row, 1, combo);
}
}
}
ActivateModsDialog::~ActivateModsDialog()
{
delete ui;
}
std::set<QString> ActivateModsDialog::getModsToActivate()
{
std::set<QString> result;
QTableWidget *modsTable = findChild<QTableWidget*>("modsTable");
for (int row = 0; row < modsTable->rowCount(); ++row) {
QComboBox *comboBox = dynamic_cast<QComboBox*>(modsTable->cellWidget(row, 1));
if (comboBox != nullptr) {
result.insert(comboBox->currentText());
}
}
return result;
}
std::set<QString> ActivateModsDialog::getESPsToActivate()
{
std::set<QString> result;
QTableWidget *modsTable = findChild<QTableWidget*>("modsTable");
for (int row = 0; row < modsTable->rowCount(); ++row) {
QComboBox *comboBox = dynamic_cast<QComboBox*>(modsTable->cellWidget(row, 1));
if (comboBox != nullptr) {
QLabel *espName = dynamic_cast<QLabel*>(modsTable->cellWidget(row, 0));
result.insert(espName->text());
}
}
return result;
}
+70 -70
View File
@@ -1,70 +1,70 @@
/*
Copyright (C) 2012 Sebastian Herbord. All rights reserved.
This file is part of Mod Organizer.
Mod Organizer is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Mod Organizer is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef ACTIVATEMODSDIALOG_H
#define ACTIVATEMODSDIALOG_H
#include "tutorabledialog.h"
#include <map>
#include <set>
namespace Ui {
class ActivateModsDialog;
}
/**
* @brief Dialog that is used to batch activate/deactivate mods and plugins
**/
class ActivateModsDialog : public MOBase::TutorableDialog
{
Q_OBJECT
public:
/**
* @brief constructor
*
* @param missingPlugins a map containing missing plugins that need to be activated
* @param parent ... Defaults to 0.
**/
explicit ActivateModsDialog(const std::map<QString, std::vector<QString> > &missingPlugins, QWidget *parent = 0);
~ActivateModsDialog();
/**
* @brief get a list of mods that the user chose to activate
*
* @note This can of ocurse only be called after the dialog has been displayed
*
* @return set< QString > the mods to activate
**/
std::set<QString> getModsToActivate();
/**
* @brief get a list of plugins that should be activated
*
* @return set< QString > the plugins to activate. This contains only plugins that become available after enabling the mods retrieved with getModsToActivate
**/
std::set<QString> getESPsToActivate();
private slots:
private:
Ui::ActivateModsDialog *ui;
};
#endif // ACTIVATEMODSDIALOG_H
/*
Copyright (C) 2012 Sebastian Herbord. All rights reserved.
This file is part of Mod Organizer.
Mod Organizer is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Mod Organizer is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef ACTIVATEMODSDIALOG_H
#define ACTIVATEMODSDIALOG_H
#include "tutorabledialog.h"
#include <map>
#include <set>
namespace Ui {
class ActivateModsDialog;
}
/**
* @brief Dialog that is used to batch activate/deactivate mods and plugins
**/
class ActivateModsDialog : public MOBase::TutorableDialog
{
Q_OBJECT
public:
/**
* @brief constructor
*
* @param missingPlugins a map containing missing plugins that need to be activated
* @param parent ... Defaults to 0.
**/
explicit ActivateModsDialog(const std::map<QString, std::vector<QString> > &missingPlugins, QWidget *parent = 0);
~ActivateModsDialog();
/**
* @brief get a list of mods that the user chose to activate
*
* @note This can of ocurse only be called after the dialog has been displayed
*
* @return set< QString > the mods to activate
**/
std::set<QString> getModsToActivate();
/**
* @brief get a list of plugins that should be activated
*
* @return set< QString > the plugins to activate. This contains only plugins that become available after enabling the mods retrieved with getModsToActivate
**/
std::set<QString> getESPsToActivate();
private slots:
private:
Ui::ActivateModsDialog *ui;
};
#endif // ACTIVATEMODSDIALOG_H
+274 -234
View File
File diff suppressed because it is too large Load Diff
+40 -40
View File
@@ -1,40 +1,40 @@
/*
Copyright (C) 2012 Sebastian Herbord. All rights reserved.
This file is part of Mod Organizer.
Mod Organizer is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Mod Organizer is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef BBCODE_H
#define BBCODE_H
#include <QString>
namespace BBCode {
/**
* @brief convert a string with BB Code-Tags to HTML
* @param input the input string with BB tags
* @param replaceOccured if not NULL, this parameter will be set to true if any bb tags were replaced
* @return the same string in html representation
**/
QString convertToHTML(const QString &input);
}
#endif // BBCODE_H
/*
Copyright (C) 2012 Sebastian Herbord. All rights reserved.
This file is part of Mod Organizer.
Mod Organizer is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Mod Organizer is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef BBCODE_H
#define BBCODE_H
#include <QString>
namespace BBCode {
/**
* @brief convert a string with BB Code-Tags to HTML
* @param input the input string with BB tags
* @param replaceOccured if not nullptr, this parameter will be set to true if any bb tags were replaced
* @return the same string in html representation
**/
QString convertToHTML(const QString &input);
}
#endif // BBCODE_H
+296 -270
View File
File diff suppressed because it is too large Load Diff
+126 -124
View File
@@ -1,124 +1,126 @@
/*
Copyright (C) 2012 Sebastian Herbord. All rights reserved.
This file is part of Mod Organizer.
Mod Organizer is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Mod Organizer is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef BROWSERDIALOG_H
#define BROWSERDIALOG_H
#include "browserview.h"
#include "tutorialcontrol.h"
#include <QDialog>
#include <QProgressBar>
#include <QNetworkRequest>
#include <QNetworkReply>
#include <QTimer>
#include <QWebView>
#include <QQueue>
#include <QTabWidget>
#include <QAtomicInt>
namespace Ui {
class BrowserDialog;
}
/**
* @brief a dialog containing a webbrowser that is intended to browse the nexus network
**/
class BrowserDialog : public QDialog
{
Q_OBJECT
public:
/**
* @brief constructor
*
* @param accessManager the access manager to use for network requests
* @param parent parent widget
**/
explicit BrowserDialog(QWidget *parent = 0);
~BrowserDialog();
/**
* @brief set the url to open. If automatic login is enabled, the url is opened after login
*
* @param url the url to open
**/
void openUrl(const QUrl &url);
signals:
/**
* @brief emitted when the user starts a download
* @param pageUrl url of the current web site from which the download was started
* @param reply network reply of the started download
*/
void requestDownload(const QUrl &pageUrl, QNetworkReply *reply);
protected:
virtual void closeEvent(QCloseEvent *);
private slots:
void initTab(BrowserView *newView);
void openInNewTab(const QUrl &url);
void progress(int value);
void titleChanged(const QString &title);
void unsupportedContent(QNetworkReply *reply);
void downloadRequested(const QNetworkRequest &request);
void tabCloseRequested(int index);
void urlChanged(const QUrl &url);
void on_backBtn_clicked();
void on_fwdBtn_clicked();
void on_searchEdit_returnPressed();
void startSearch();
void on_refreshBtn_clicked();
void on_browserTabWidget_currentChanged(int index);
private:
QString guessFileName(const QString &url);
BrowserView *getCurrentView();
void maximizeWidth();
private:
Ui::BrowserDialog *ui;
QNetworkAccessManager *m_AccessManager;
QTabWidget *m_Tabs;
};
#endif // BROWSERDIALOG_H
/*
Copyright (C) 2012 Sebastian Herbord. All rights reserved.
This file is part of Mod Organizer.
Mod Organizer is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Mod Organizer is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef BROWSERDIALOG_H
#define BROWSERDIALOG_H
#include <QDialog>
#include <QNetworkRequest>
#include <QNetworkReply>
#include <QTimer>
#include <QWebView>
#include <QQueue>
#include <QTabWidget>
#include <QAtomicInt>
namespace Ui {
class BrowserDialog;
}
class BrowserView;
/**
* @brief a dialog containing a webbrowser that is intended to browse the nexus network
**/
class BrowserDialog : public QDialog
{
Q_OBJECT
public:
/**
* @brief constructor
*
* @param accessManager the access manager to use for network requests
* @param parent parent widget
**/
explicit BrowserDialog(QWidget *parent = 0);
~BrowserDialog();
/**
* @brief set the url to open. If automatic login is enabled, the url is opened after login
*
* @param url the url to open
**/
void openUrl(const QUrl &url);
virtual bool eventFilter(QObject *object, QEvent *event);
signals:
/**
* @brief emitted when the user starts a download
* @param pageUrl url of the current web site from which the download was started
* @param reply network reply of the started download
*/
void requestDownload(const QUrl &pageUrl, QNetworkReply *reply);
protected:
virtual void closeEvent(QCloseEvent *);
private slots:
void initTab(BrowserView *newView);
void openInNewTab(const QUrl &url);
void progress(int value);
void titleChanged(const QString &title);
void unsupportedContent(QNetworkReply *reply);
void downloadRequested(const QNetworkRequest &request);
void tabCloseRequested(int index);
void urlChanged(const QUrl &url);
void on_backBtn_clicked();
void on_fwdBtn_clicked();
void on_searchEdit_returnPressed();
void startSearch();
void on_refreshBtn_clicked();
void on_browserTabWidget_currentChanged(int index);
void on_urlEdit_returnPressed();
private:
QString guessFileName(const QString &url);
BrowserView *getCurrentView();
void maximizeWidth();
private:
Ui::BrowserDialog *ui;
QNetworkAccessManager *m_AccessManager;
QTabWidget *m_Tabs;
};
#endif // BROWSERDIALOG_H
+27 -2
View File
@@ -17,7 +17,16 @@
<property name="spacing">
<number>0</number>
</property>
<property name="margin">
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item>
@@ -180,7 +189,16 @@
<property name="spacing">
<number>6</number>
</property>
<property name="margin">
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item>
@@ -237,6 +255,13 @@
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="urlEdit">
<property name="enabled">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
+75 -76
View File
@@ -1,76 +1,75 @@
/*
Copyright (C) 2012 Sebastian Herbord. All rights reserved.
This file is part of Mod Organizer.
Mod Organizer is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Mod Organizer is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
*/
#include "browserview.h"
#include <QEvent>
#include <QKeyEvent>
#include <QWebFrame>
#include <QWebElement>
#include <QNetworkDiskCache>
#include <QMenu>
#include <Shlwapi.h>
#include "utility.h"
BrowserView::BrowserView(QWidget *parent)
: QWebView(parent)
{
installEventFilter(this);
page()->settings()->setMaximumPagesInCache(10);
}
QWebView *BrowserView::createWindow(QWebPage::WebWindowType)
{
BrowserView *newView = new BrowserView(parentWidget());
emit initTab(newView);
return newView;
}
bool BrowserView::eventFilter(QObject *obj, QEvent *event)
{
if (event->type() == QEvent::ShortcutOverride) {
QKeyEvent *keyEvent = static_cast<QKeyEvent*>(event);
if (keyEvent->matches(QKeySequence::Find)) {
emit startFind();
} else if (keyEvent->matches(QKeySequence::FindNext)) {
emit findAgain();
}
} else if (event->type() == QEvent::MouseButtonPress) {
QMouseEvent *mouseEvent = static_cast<QMouseEvent*>(event);
if (mouseEvent->button() == Qt::MidButton) {
mouseEvent->ignore();
return true;
}
} else if (event->type() == QEvent::MouseButtonRelease) {
QMouseEvent *mouseEvent = static_cast<QMouseEvent*>(event);
if (mouseEvent->button() == Qt::MidButton) {
QWebHitTestResult hitTest = page()->frameAt(mouseEvent->pos())->hitTestContent(mouseEvent->pos());
if (hitTest.linkUrl().isValid()) {
emit openUrlInNewTab(hitTest.linkUrl());
}
mouseEvent->ignore();
return true;
}
}
return QWebView::eventFilter(obj, event);
}
/*
Copyright (C) 2012 Sebastian Herbord. All rights reserved.
This file is part of Mod Organizer.
Mod Organizer is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Mod Organizer is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
*/
#include "browserview.h"
#include <QEvent>
#include <QKeyEvent>
#include <QWebFrame>
#include <QWebElement>
#include <QNetworkDiskCache>
#include <QMenu>
#include <Shlwapi.h>
#include "utility.h"
BrowserView::BrowserView(QWidget *parent)
: QWebView(parent)
{
installEventFilter(this);
page()->settings()->setMaximumPagesInCache(10);
}
QWebView *BrowserView::createWindow(QWebPage::WebWindowType)
{
BrowserView *newView = new BrowserView(parentWidget());
emit initTab(newView);
return newView;
}
bool BrowserView::eventFilter(QObject *obj, QEvent *event)
{
if (event->type() == QEvent::ShortcutOverride) {
QKeyEvent *keyEvent = static_cast<QKeyEvent*>(event);
if (keyEvent->matches(QKeySequence::Find)) {
emit startFind();
} else if (keyEvent->matches(QKeySequence::FindNext)) {
emit findAgain();
}
} else if (event->type() == QEvent::MouseButtonPress) {
QMouseEvent *mouseEvent = static_cast<QMouseEvent*>(event);
if (mouseEvent->button() == Qt::MidButton) {
mouseEvent->ignore();
return true;
}
} else if (event->type() == QEvent::MouseButtonRelease) {
QMouseEvent *mouseEvent = static_cast<QMouseEvent*>(event);
if (mouseEvent->button() == Qt::MidButton) {
QWebHitTestResult hitTest = page()->frameAt(mouseEvent->pos())->hitTestContent(mouseEvent->pos());
if (hitTest.linkUrl().isValid()) {
emit openUrlInNewTab(hitTest.linkUrl());
}
mouseEvent->ignore();
return true;
}
}
return QWebView::eventFilter(obj, event);
}
+79 -80
View File
@@ -1,80 +1,79 @@
/*
Copyright (C) 2012 Sebastian Herbord. All rights reserved.
This file is part of Mod Organizer.
Mod Organizer is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Mod Organizer is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef NEXUSVIEW_H
#define NEXUSVIEW_H
#include "finddialog.h"
#include <QWebView>
#include <QWebPage>
#include <QTabWidget>
/**
* @brief web view used to display a nexus page
**/
class BrowserView : public QWebView
{
Q_OBJECT
public:
explicit BrowserView(QWidget *parent = 0);
signals:
/**
* @brief emitted when the user opens a new window to be displayed in another tab
*
* @param newView the view for the newly opened window
**/
void initTab(BrowserView *newView);
/**
* @brief emitted when the user requests a link to be opened in a new tab by middle-clicking
*
* @param url the url to open
*/
void openUrlInNewTab(const QUrl &url);
/**
* @brief Ctrl-f was clicked. The containing dialog should activate its find-facility
*/
void startFind();
/**
* @brief F3 was pressed. The containing dialog should search again
*/
void findAgain();
protected:
virtual QWebView *createWindow(QWebPage::WebWindowType type);
virtual bool eventFilter(QObject *obj, QEvent *event);
private:
QString m_FindPattern;
bool m_MiddleClick;
};
#endif // NEXUSVIEW_H
/*
Copyright (C) 2012 Sebastian Herbord. All rights reserved.
This file is part of Mod Organizer.
Mod Organizer is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Mod Organizer is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef NEXUSVIEW_H
#define NEXUSVIEW_H
#include <QWebView>
#include <QWebPage>
#include <QTabWidget>
/**
* @brief web view used to display a nexus page
**/
class BrowserView : public QWebView
{
Q_OBJECT
public:
explicit BrowserView(QWidget *parent = 0);
signals:
/**
* @brief emitted when the user opens a new window to be displayed in another tab
*
* @param newView the view for the newly opened window
**/
void initTab(BrowserView *newView);
/**
* @brief emitted when the user requests a link to be opened in a new tab by middle-clicking
*
* @param url the url to open
*/
void openUrlInNewTab(const QUrl &url);
/**
* @brief Ctrl-f was clicked. The containing dialog should activate its find-facility
*/
void startFind();
/**
* @brief F3 was pressed. The containing dialog should search again
*/
void findAgain();
protected:
virtual QWebView *createWindow(QWebPage::WebWindowType type);
virtual bool eventFilter(QObject *obj, QEvent *event);
private:
QString m_FindPattern;
bool m_MiddleClick;
};
#endif // NEXUSVIEW_H
+319 -301
View File
File diff suppressed because it is too large Load Diff
+200 -198
View File
@@ -1,198 +1,200 @@
/*
Copyright (C) 2012 Sebastian Herbord. All rights reserved.
This file is part of Mod Organizer.
Mod Organizer is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Mod Organizer is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef CATEGORIES_H
#define CATEGORIES_H
#include <QString>
#include <vector>
#include <map>
#include <functional>
/**
* @brief Manage the available mod categories
* @warning member functions of this class currently use a wild mix of ids and indexes to look up categories,
* optimized to where the request comes from. Therefore be very careful which of the two you have available
**/
class CategoryFactory {
friend class CategoriesDialog;
public:
static const int CATEGORY_NONE = 0;
static const int CATEGORY_SPECIAL_FIRST = 10000;
static const int CATEGORY_SPECIAL_CHECKED = CATEGORY_SPECIAL_FIRST;
static const int CATEGORY_SPECIAL_UNCHECKED = 10001;
static const int CATEGORY_SPECIAL_UPDATEAVAILABLE = 10002;
static const int CATEGORY_SPECIAL_NOCATEGORY = 10003;
static const int CATEGORY_SPECIAL_CONFLICT = 10004;
static const int CATEGORY_SPECIAL_NOTENDORSED = 10005;
public:
struct Category {
Category(int sortValue, int id, const QString &name, const std::vector<int> &nexusIDs, int parentID)
: m_SortValue(sortValue), m_ID(id), m_Name(name), m_HasChildren(false),
m_NexusIDs(nexusIDs), m_ParentID(parentID) {}
int m_SortValue;
int m_ID;
int m_ParentID;
bool m_HasChildren;
QString m_Name;
std::vector<int> m_NexusIDs;
friend bool operator<(const Category &LHS, const Category &RHS) {
return LHS.m_SortValue < RHS.m_SortValue;
}
};
public:
/**
* @brief reset the list of categories
**/
void reset();
/**
* @brief save the categories to the categories.dat file
**/
void saveCategories();
/**
* @brief retrieve the number of available categories
*
* @return unsigned int number of categories
**/
unsigned numCategories() const { return m_Categories.size(); }
/**
* @brief count all categories that match a specified filter
* @param filter the filter to test
* @return number of matching categories
*/
unsigned int countCategories(std::tr1::function<bool (const Category &category)> filter);
/**
* @brief get the id of the parent category
*
* @param index the index to look up
* @return int id of the parent category
**/
int getParentID(unsigned int index) const;
/**
* @brief determine if a category exists (by id)
*
* @param id the id to check for existance
* @return true if the category exists, false otherwise
**/
bool categoryExists(int id) const;
/**
* @brief test if a category is child of a second one
* @param id the presumed child id
* @param parentID the parent id to test for
* @return true if id is a child of parentID
**/
bool isDecendantOf(int id, int parentID) const;
/**
* @brief test if the specified category has child categories
*
* @param index index of the category to look up
* @return bool true if the category has child categories
**/
bool hasChildren(unsigned int index) const;
/**
* @brief retrieve the name of a category
*
* @param index index of the category to look up
* @return QString name of the category
**/
QString getCategoryName(unsigned int index) const;
/**
* @brief look up the id of a category by its index
*
* @param index index of the category to look up
* @return int id of the category
**/
int getCategoryID(unsigned int index) const;
/**
* @brief look up the index of a category by its id
*
* @param id index of the category to look up
* @return unsigned int index of the category
**/
int getCategoryIndex(int ID) const;
/**
* @brief retrieve the index of a category by its nexus id
*
* @param nexusID nexus id of the category to look up
* @return unsigned int index of the category or 0 if no category matches
**/
unsigned int resolveNexusID(int nexusID) const;
public:
/**
* @brief retrieve a reference to the singleton instance
*
* @return the reference to the singleton
**/
static CategoryFactory &instance();
/**
* @return path to the file that contains the categories list
*/
static QString categoriesFilePath();
private:
CategoryFactory();
void loadDefaultCategories();
void addCategory(int id, const QString &name, const std::vector<int> &nexusID, int parentID);
void setParents();
static void cleanup();
private:
static CategoryFactory *s_Instance;
std::vector<Category> m_Categories;
std::map<int, unsigned int> m_IDMap;
std::map<int, unsigned int> m_NexusMap;
private:
};
#endif // CATEGORIES_H
/*
Copyright (C) 2012 Sebastian Herbord. All rights reserved.
This file is part of Mod Organizer.
Mod Organizer is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Mod Organizer is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef CATEGORIES_H
#define CATEGORIES_H
#include <QString>
#include <vector>
#include <map>
#include <functional>
/**
* @brief Manage the available mod categories
* @warning member functions of this class currently use a wild mix of ids and indexes to look up categories,
* optimized to where the request comes from. Therefore be very careful which of the two you have available
**/
class CategoryFactory {
friend class CategoriesDialog;
public:
static const int CATEGORY_NONE = 0;
static const int CATEGORY_SPECIAL_FIRST = 10000;
static const int CATEGORY_SPECIAL_CHECKED = CATEGORY_SPECIAL_FIRST;
static const int CATEGORY_SPECIAL_UNCHECKED = 10001;
static const int CATEGORY_SPECIAL_UPDATEAVAILABLE = 10002;
static const int CATEGORY_SPECIAL_NOCATEGORY = 10003;
static const int CATEGORY_SPECIAL_CONFLICT = 10004;
static const int CATEGORY_SPECIAL_NOTENDORSED = 10005;
static const int CATEGORY_SPECIAL_MANAGED = 10006;
static const int CATEGORY_SPECIAL_UNMANAGED = 10007;
public:
struct Category {
Category(int sortValue, int id, const QString &name, const std::vector<int> &nexusIDs, int parentID)
: m_SortValue(sortValue), m_ID(id), m_Name(name), m_HasChildren(false),
m_NexusIDs(nexusIDs), m_ParentID(parentID) {}
int m_SortValue;
int m_ID;
int m_ParentID;
bool m_HasChildren;
QString m_Name;
std::vector<int> m_NexusIDs;
friend bool operator<(const Category &LHS, const Category &RHS) {
return LHS.m_SortValue < RHS.m_SortValue;
}
};
public:
/**
* @brief reset the list of categories
**/
void reset();
/**
* @brief save the categories to the categories.dat file
**/
void saveCategories();
/**
* @brief retrieve the number of available categories
*
* @return unsigned int number of categories
**/
unsigned numCategories() const { return m_Categories.size(); }
/**
* @brief count all categories that match a specified filter
* @param filter the filter to test
* @return number of matching categories
*/
unsigned int countCategories(std::tr1::function<bool (const Category &category)> filter);
/**
* @brief get the id of the parent category
*
* @param index the index to look up
* @return int id of the parent category
**/
int getParentID(unsigned int index) const;
/**
* @brief determine if a category exists (by id)
*
* @param id the id to check for existance
* @return true if the category exists, false otherwise
**/
bool categoryExists(int id) const;
/**
* @brief test if a category is child of a second one
* @param id the presumed child id
* @param parentID the parent id to test for
* @return true if id is a child of parentID
**/
bool isDecendantOf(int id, int parentID) const;
/**
* @brief test if the specified category has child categories
*
* @param index index of the category to look up
* @return bool true if the category has child categories
**/
bool hasChildren(unsigned int index) const;
/**
* @brief retrieve the name of a category
*
* @param index index of the category to look up
* @return QString name of the category
**/
QString getCategoryName(unsigned int index) const;
/**
* @brief look up the id of a category by its index
*
* @param index index of the category to look up
* @return int id of the category
**/
int getCategoryID(unsigned int index) const;
/**
* @brief look up the index of a category by its id
*
* @param id index of the category to look up
* @return unsigned int index of the category
**/
int getCategoryIndex(int ID) const;
/**
* @brief retrieve the index of a category by its nexus id
*
* @param nexusID nexus id of the category to look up
* @return unsigned int index of the category or 0 if no category matches
**/
unsigned int resolveNexusID(int nexusID) const;
public:
/**
* @brief retrieve a reference to the singleton instance
*
* @return the reference to the singleton
**/
static CategoryFactory &instance();
/**
* @return path to the file that contains the categories list
*/
static QString categoriesFilePath();
private:
CategoryFactory();
void loadDefaultCategories();
void addCategory(int id, const QString &name, const std::vector<int> &nexusID, int parentID);
void setParents();
static void cleanup();
private:
static CategoryFactory *s_Instance;
std::vector<Category> m_Categories;
std::map<int, unsigned int> m_IDMap;
std::map<int, unsigned int> m_NexusMap;
private:
};
#endif // CATEGORIES_H

Some files were not shown because too many files have changed in this diff Show More