diff options
author | René Schümann <white06tiger@gmail.com> | 2014-04-10 23:34:27 +0000 |
---|---|---|
committer | René Schümann <white06tiger@gmail.com> | 2014-04-10 23:34:27 +0000 |
commit | 9a4d6d236bcd294d77884441494c2e32f3817b11 (patch) | |
tree | 60a7e4bb2caed036999c37e55a41db6c8c4b71ce /plugins/SendScreenshotPlus/src/Utils.cpp | |
parent | ab05a30ab1f725e421287bf8158508c3ba3eddd3 (diff) |
SendSS:
* improved GetFileName() to also handle Unix paths (Utils)
!* improved and fixed dialog, caused graphical issues before, also improved tab order (UMainForm, resource)
* improved resource.rc a bit. Now use defines for UInfoButtonClass styles
* replaced some mir_freeAndNil() calls with mir_free() where appreciated (UMainForm, UAboutForm)
* minor update to Dropbox support. no real change
git-svn-id: http://svn.miranda-ng.org/main/trunk@8939 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/SendScreenshotPlus/src/Utils.cpp')
-rw-r--r-- | plugins/SendScreenshotPlus/src/Utils.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/plugins/SendScreenshotPlus/src/Utils.cpp b/plugins/SendScreenshotPlus/src/Utils.cpp index 1da14993b2..19071611a8 100644 --- a/plugins/SendScreenshotPlus/src/Utils.cpp +++ b/plugins/SendScreenshotPlus/src/Utils.cpp @@ -329,28 +329,30 @@ TCHAR* SaveImage(FREE_IMAGE_FORMAT fif, FIBITMAP* dib, TCHAR* pszFilename, TCHAR //--------------------------------------------------------------------------- TCHAR* GetFileNameW(TCHAR* pszPath) { - TCHAR* slash = _tcsrchr(pszPath,_T('\\')); + TCHAR* slash=_tcsrchr(pszPath,_T('\\')); + if(!slash) slash=_tcsrchr(pszPath,_T('/')); if(slash) return mir_t2u(slash+1); else return mir_t2u(pszPath); } TCHAR* GetFileExtW(TCHAR* pszPath) { - TCHAR* slash = _tcsrchr(pszPath,_T('.')); + TCHAR* slash=_tcsrchr(pszPath,_T('.')); if(slash) return mir_t2u(slash); return NULL; } char* GetFileNameA(TCHAR* pszPath) { - TCHAR* slash = _tcsrchr(pszPath,_T('\\')); + TCHAR* slash=_tcsrchr(pszPath,_T('\\')); + if(!slash) slash=_tcsrchr(pszPath,_T('/')); if(slash) return mir_t2a(slash+1); else return mir_t2a(pszPath); } char* GetFileExtA(TCHAR* pszPath) { - TCHAR* slash = _tcsrchr(pszPath,_T('.')); + TCHAR* slash=_tcsrchr(pszPath,_T('.')); if(slash) return mir_t2a(slash); return NULL; |