aboutsummaryrefslogtreecommitdiff
path: root/Src/Plugins/Input/in_flv/ExtendedInfo.cpp
diff options
context:
space:
mode:
authorJef <jef@targetspot.com>2024-09-24 08:54:57 -0400
committerJef <jef@targetspot.com>2024-09-24 08:54:57 -0400
commit20d28e80a5c861a9d5f449ea911ab75b4f37ad0d (patch)
tree12f17f78986871dd2cfb0a56e5e93b545c1ae0d0 /Src/Plugins/Input/in_flv/ExtendedInfo.cpp
parent537bcbc86291b32fc04ae4133ce4d7cac8ebe9a7 (diff)
downloadwinamp-20d28e80a5c861a9d5f449ea911ab75b4f37ad0d.tar.gz
Initial community commit
Diffstat (limited to 'Src/Plugins/Input/in_flv/ExtendedInfo.cpp')
-rw-r--r--Src/Plugins/Input/in_flv/ExtendedInfo.cpp29
1 files changed, 29 insertions, 0 deletions
diff --git a/Src/Plugins/Input/in_flv/ExtendedInfo.cpp b/Src/Plugins/Input/in_flv/ExtendedInfo.cpp
new file mode 100644
index 00000000..c7a807f0
--- /dev/null
+++ b/Src/Plugins/Input/in_flv/ExtendedInfo.cpp
@@ -0,0 +1,29 @@
+#include <bfc/platform/types.h>
+#include <windows.h>
+#include <strsafe.h>
+#include "api__in_flv.h"
+#include "resource.h"
+
+extern "C" __declspec(dllexport)
+ int winampGetExtendedFileInfoW(const wchar_t *fn, const char *data, wchar_t *dest, size_t destlen)
+{
+ if (!_stricmp(data, "type"))
+ {
+ dest[0]='1';
+ dest[1]=0;
+ return 1;
+ }
+ else if (!_stricmp(data, "family"))
+ {
+ int len;
+ const wchar_t *p;
+ if (!fn || !fn[0]) return 0;
+ len = lstrlenW(fn);
+ if (len < 4 || L'.' != fn[len - 4]) return 0;
+ p = &fn[len - 3];
+ if (!_wcsicmp(p, L"FLV") && S_OK == StringCchCopyW(dest, destlen, WASABI_API_LNGSTRINGW(IDS_FAMILY_STRING))) return 1;
+ return 0;
+ }
+
+ return 0;
+} \ No newline at end of file