diff options
author | John Ankarström <john@ankarstrom.se> | 2022-08-24 15:17:08 +0200 |
---|---|---|
committer | John Ankarström <john@ankarstrom.se> | 2022-08-24 15:17:33 +0200 |
commit | 6fd66a9264731bd7ee6d7602675965021d929a4a (patch) | |
tree | e94fc63efb823ad2f5c9ef6de6188da389a08d38 /c/wcharptr.h | |
parent | ff48d644a45dd71098ecb9007a41807fb37d0081 (diff) | |
download | EpisodeBrowser-6fd66a9264731bd7ee6d7602675965021d929a4a.tar.gz |
Remove Prolog dependency.
The only thing left to reimplement is the tracking of watched episodes
in MPC-HC.
Diffstat (limited to 'c/wcharptr.h')
-rw-r--r-- | c/wcharptr.h | 33 |
1 files changed, 0 insertions, 33 deletions
diff --git a/c/wcharptr.h b/c/wcharptr.h deleted file mode 100644 index 2267017..0000000 --- a/c/wcharptr.h +++ /dev/null @@ -1,33 +0,0 @@ -#ifndef WCHARPTR_H -#define WCHARPTR_H - -#include <windows.h> - -/* WcharPtr: Simple wrapper for wide C strings. */ -struct WcharPtr -{ - /* Named copy constructors (expensive). */ - static WcharPtr FromNarrow(const char* buf, int cp = CP_UTF8); - static WcharPtr Copy(const wchar_t* s); - - /* Non-explicit copies are disabled. */ - WcharPtr(WcharPtr& other) = delete; - WcharPtr& operator=(WcharPtr& other) = delete; - - WcharPtr() noexcept; - ~WcharPtr(); - operator wchar_t*() noexcept; - - WcharPtr(wchar_t* s) noexcept; - WcharPtr& operator=(wchar_t* s) noexcept; - - WcharPtr(WcharPtr&& other) noexcept; - WcharPtr& operator=(WcharPtr&& other) noexcept; - - /* Return pointer, releasing ownership. */ - wchar_t *Release() noexcept; -private: - wchar_t* m_p = nullptr; -}; - -#endif |