bitwarden-android/src/Android/Services/AppInfoService.cs

17 lines
579 B
C#
Raw Normal View History

using Bit.App.Abstractions;
using AndroidApp = Android.App.Application;
namespace Bit.Android.Services
{
public class AppInfoService : IAppInfoService
{
public string Version => AndroidApp.Context.ApplicationContext.PackageManager
.GetPackageInfo(AndroidApp.Context.PackageName, 0).VersionName;
public string Build => AndroidApp.Context.ApplicationContext.PackageManager
.GetPackageInfo(AndroidApp.Context.PackageName, 0).VersionCode.ToString();
2017-02-01 08:38:35 +03:00
public bool AutofillServiceEnabled => AutofillService.Enabled;
}
}