Skip to content

Commit 4fe2647

Browse files
committed
Add wide string version of SetAnalyticsLibraryPath and export
"publicly".
1 parent 4fcf299 commit 4fe2647

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

analytics/src/analytics_desktop.cc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,14 @@ void SetAnalyticsLibraryPath(const char* path) {
9999
g_analytics_dll_filename = ANALYTICS_DLL_DEFAULT_FILENAME;
100100
}
101101
}
102+
103+
void SetAnalyticsLibraryPath(const wchar_t* path) {
104+
if (path) {
105+
g_analytics_dll_filename = path;
106+
} else {
107+
g_analytics_dll_filename = ANALYTICS_DLL_DEFAULT_FILENAME;
108+
}
109+
}
102110
#endif
103111

104112
// Future data for analytics.

analytics/src/include/firebase/analytics.h

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -591,6 +591,22 @@ Future<int64_t> GetSessionId();
591591
/// app session.
592592
Future<int64_t> GetSessionIdLastResult();
593593

594+
595+
#ifdef INTERNAL_EXPERIMENTAL
596+
#if defined(_WIN32) || defined(DOXYGEN)
597+
/// Windows only: Specify the path to the Google Analytics Windows DLL.
598+
///
599+
/// @param path Path to the DLL, including filename, in UTF-8 format.
600+
void SetAnalyticsLibraryPath(const char* path);
601+
602+
/// Windows only: Specify the path to the Google Analytics Windows DLL.
603+
///
604+
/// @param path Path to the DLL, including filename, in UTF-16 format.
605+
void SetAnalyticsLibraryPath(const wchar_t* path);
606+
#endif
607+
#endif
608+
609+
594610
} // namespace analytics
595611
} // namespace firebase
596612

0 commit comments

Comments
 (0)