summaryrefslogtreecommitdiff
path: root/Source/Core/Common/Src/FileUtil.cpp
AgeCommit message (Collapse)Author
2011-06-11Windows: Sets the cwd to the folder that dolphin.exe resides in.LPFaint99
Removes the ugliness that was the portable file, and now creating a shortcut or file association is less of a pain it is still necessary to modify the file association from ".../dolphin.exe" "%1" to ".../dolphin.exe" /e "%1" git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7593 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-05-24Adds the option to change the path to the wii nand rootLPFaint99
when nand root is changed the current sysconf is saved, and the sysconf in the new location is either loaded (if exists) or the default sysconf is created wii menu item is updated when the root changes small fix to saving gamelist paths to .ini paths that are removed from the gui are now removed from the ini instead of simply changing the number of paths git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7555 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-05-07Move the HLE hack of setting.txt file redirection to the BS2EmuLPFaint99
we already copy the file to memory here, now we also copy the file to 1/2/data/ This should really fix issue 4287. Thanks to hosigumayuugi for finding the exact cause of the issue git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7521 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-22Fixed some memory leaks. Only one was mine ;PJordan Woyak
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7392 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-11Wrapped fopen/close/read/write functions inside a simple "IOFile" class. ↵Jordan Woyak
Reading, writing, and error checking became simpler in most cases. It should be near impossible to forget to close a file now that the destructor takes care of it. (I hope this fixes Issue 3635) I have tested the functionality of most things, but it is possible I broke something. :p git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7328 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-01Pass std::string's by reference when possible.Glenn Rice
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7268 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-01More conversion from char * to std::string.Glenn Rice
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7266 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-28Convert GetUserPath to return a std::string instead of a const char *. This ↵Glenn Rice
simplifies its usage in most cases. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7265 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-11* Dump AVI output on every VI (fixes issue #4064).smelenchuk
* Add audio dumping (fixes issue #1638). git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7131 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-01Fixed vs2010 SVNRevGen project. (Also changed "make_svnrev.h.vbs" to jscript ↵Jordan Woyak
and gave it some comments :p) Removed some old plugin stuff. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7030 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-29Fix the Audio tab and merge the DSP config into one.sl1nk3.s
Unify the DSP settings into DSP.ini git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6955 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-15Clean up nowx and stop cocoaApp busy-waiting in the main loop.Soren Jorvang
Set up an exit(3) task to shut down real wiimotes. This shouldn't really be necessary, but we do currently handle a number of error conditions by calling exit(3). Retire the inputuicommon library. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6852 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-31fixed crash when compressing 4+gb isos on some buildsnitsuja-
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6700 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-21Fixes some file handling in IPC_HLEblubberdiblub
* change File::GetSize to fetch the size directly from the open file instead of stat'ing it when challed with a FILE* * use changed File::GetSize(FILE *f) instead of calling with file name in two places * remove "seek_pos % file_size" hack for ZTP, so one can seek to the end of file again. Please check Zelda: Twilight Princess for regressions * return error codes when reading or writing from/to a file A lot of those changes are from j4ck.fr0st, so kudos to him. I did not change the file open mode for ISFS_OPEN_WRITE to "wb". While that would probably be more correct, it says in the comment that it might affect Mario Kart Wii. I would prefer somebody with that game try that change locally first. Please check your games for regressions (or even improvement). Some games that may be affected are Zelda - Twilight Princess and Metroid Prime 3. Fixes issue 1749 git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6634 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-19Fix TextureDecoder.cl to work on both NVidia and ATI video cards.Glenn Rice
To do so I had to re-add the casting bloat removed in revision 6102. Also, for some odd reason the NVidia OpenCL drivers don't like 8 bit rotations, but are okay with 2, 4 bit rotations. These are apparently bugs in the NVidia drivers that are hopefully fixed in future versions. Also, on linux make sure the TextureDecoder.cl file is copied from the shared data directory to the users directory. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6611 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-05First pass at dealing with different size_t/off_t sizes in C90 environments.Soren Jorvang
Most of the code dealing with the LogTypes namespace was C which lead to a lot of nonsensical casting, so I have dumbed LOG_TYPE and LOG_LEVEL down to plain C even though the move of wiiuse into Source means we don't currently call GenericLog from C. Set logging threshold to MAX_LOGLEVEL at startup so debug builds will also p rint debugging messages before the GUI is running. For some reason the way we use SetDefaultStyle doesn't play nice with wx 2.9 so we just get the default black text on a black background. Using a gray background works around that problem, but I found it to also be much easier on the eyes so I have switched the background color on all versions. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6528 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-05allow gcc to check the format of args being passed to MsgAlert and ↵Shawn Hoffman
GenericLog. Fixed nearly all warnings that arose from this, as well as some preexisting ones (some were actually crashes and/or bugs...) git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6522 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-034.4BSD derived OS'es always have 64-bit file sizes.Soren Jorvang
XXX This should probably be in CommonFuncs.h or something. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6512 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-03Attempt to fix issue r3458. I don't have a 32bit linux install, however I ↵Shawn Hoffman
know it will at least fix compressing. Please test if uncompressed games run. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6510 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-11-10StringUtil cleanup. Nothing seems broken.Jordan Woyak
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6367 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-09-06Some work towards launching by titleid rather than content path,LPFaint99
update some var names in WII_IPC_HLE_Device_fs, filter out some spam logs from VolumeCommon git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6182 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-07-23Further *BSD portability.Soren Jorvang
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5958 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-07-22Prevent Python from stripping off the final newline of the main(){} Soren Jorvang
autoconfiguration tests. Some versions of gcc care enough about ANSI C to complain about this. Use the Linux install hierarchy conventions on other Unices as well. XKeysymToString returns NULL on unknown keysyms, which is not a valid std::string initializer. There appears to be some disagreement regarding the second parameter to iconv(). Some versions/installations have it as const, others don't. Unfortunately, due to wonderful C++ brain damage, implicit conversion from const to non-const doesn't work here. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5945 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-07-22Port to *BSD. It runs but isn't terribly useful without Cg.Soren Jorvang
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5934 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-07-20Prevent double inclusion of CommonPaths.h as pointed out by Glenn.Soren Jorvang
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5922 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-06-13Oops, that wasn't supposed to be in there.Glenn Rice
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5677 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-06-13Fix pad configuration dialog on linuxGlenn Rice
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5676 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-06-05Don't store the absolute pathname of plugins in the configuration file,Soren Jorvang
just the basename like libPlugin_foo.dylib. Dolphin then loads the plugins relative to the compiled-in plugins directory. This means that you won't have to reselect the plugins when running different builds (in different directories) and is most obviously beneficial on OS X where application bundles are not (should not) be expected to stay in the place where they are first installed. This is tested on OS X and Linux with local/global build options, but not Windows. I don't anticipate any problems on Windows, but that OS does have slightly different semantics with regard to path component separators and file suffixes, so it's something to watch out for. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5621 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-05-30De-inline StripTailDirSlashes() to work around a weird code generation bug.Soren Jorvang
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5549 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-05-12OSX fix Dolphin not actually using the Application Support path.Shawn Hoffman
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5445 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-05-06apply soren.jorvang's case-sensitivity patch (closes issue 2656) :Pluisr142004
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5436 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-04-08Random fixes and cleanupsNeoBrainX
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5297 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-04-06Fix wrong sprintf usage: the parameters use the restrict keyword so they may ↵NeoBrainX
not point to the same location. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5286 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-02-08make ESC quit the game instead of toggling out of/into full screen mode ↵luisr142004
(fixes issue 2246), implement proper window handling (d3d/sw) which i believe fixes a hang that occurs when a game is stopped (plz test this :)) + some minor stuff git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5030 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-02-03some cleanup, housekeeping for error cases and increased a few buffer sizes ↵j4ck.fr0st
that are overflown by its content. Thanks to Fatalis for the initial patch and pointing us to cppcheck. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5004 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-02-03Revert commit 4997 and fix in a way that is more consistent with the structureGlenn Rice
before the global build patch git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4999 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-02-02Linux global build. At least the basic footwork is done here.Glenn Rice
Basic usage: "sudo scons install=global install" Hopefully this doesn't break builds on Macs. I have tested this on linux and windows. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4994 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-02-01Fixes issue 1777.luisr142004
plus a fix for wiimote detection on win32 when using the default MS stack git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4989 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-01-29Fixes Issue 2176 (SysConf on OSX), plus some initialization order warning ↵j4ck.fr0st
fix in VolumeDirectory.cpp git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4985 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-10-31remove some newlines from FileUtil logs.Shawn Hoffman
add ___blank to HLE'd debug logging. add long long support to HLE_OS::GetStringVA take care of those annoying sdio 0x40 and 0x41 commands...not that they do much in the first place... some cleanup on the IPC net devices git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4488 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-09-21fix some path issues on OSX, also libao for osx only supports ↵Shawn Hoffman
44.1kHz...awesome...who calls writing the CoreAudio backend so we can kill libao? :D git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4311 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-09-13patch by Daco for extracting directory contents from a gcm (which also ↵LPFaint99
allows dumping an entire partion other than 0 from a wii disc) plus a small fix for File::GetSize log git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4258 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-08-06revert changes to GetSysDirectory from last commit, I was trying to fix my ↵Shawn Hoffman
issue with CWD going all wacky (unsuccessfully). git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3943 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-08-06misc cleanupShawn Hoffman
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3942 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-07-30dolphinwx and debuggerwx can now be compiled with unicodeLPFaint99
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3906 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-07-28Now ALL copyright dates are fixed to the legally correct year: The year in ↵XTra.KrazzY
which the project began. Now we don't have to change it every year :) git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3898 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-07-12Rearrange LogManager includes. The main purpose is to make it possible to ↵Nolan Check
modify Thread.h without recompiling the whole entire project. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3770 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-06-12Fix for tatsunoko vs capcom and those wii games getting corrupted memory errorsl1nk3.s
+ a couple of (serious...) fixes for some of my mistakes, and some warning fixes git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3411 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-05-04fix plugin dir for nongui version for osxtmator
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3155 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-04-25Completely fixed DSPTool, on all of its memory leaks, bad API and bad C++. ↵XTra.KrazzY
(compiling with include works perfectly) More small leftover fixes git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3071 8ced0084-cf51-0410-be5f-012b33b47a6e