diff options
Diffstat (limited to '')
-rw-r--r-- | widget/android/nsNativeBasicThemeAndroid.cpp | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/widget/android/nsNativeBasicThemeAndroid.cpp b/widget/android/nsNativeBasicThemeAndroid.cpp new file mode 100644 index 0000000000..425baf6239 --- /dev/null +++ b/widget/android/nsNativeBasicThemeAndroid.cpp @@ -0,0 +1,15 @@ +/* -*- Mode: C++; tab-width: 40; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ + +#include "nsNativeBasicThemeAndroid.h" + +already_AddRefed<nsITheme> do_GetBasicNativeThemeDoNotUseDirectly() { + static StaticRefPtr<nsITheme> gInstance; + if (MOZ_UNLIKELY(!gInstance)) { + gInstance = new nsNativeBasicThemeAndroid(); + ClearOnShutdown(&gInstance); + } + return do_AddRef(gInstance); +} |