KP2A Offline release

This commit is contained in:
Philipp Crocoll 2013-12-26 06:31:40 +01:00
parent 1704e44afc
commit 7613af6c81
22 changed files with 284 additions and 100 deletions

View File

@ -31,6 +31,15 @@
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'ReleaseNoNet|AnyCPU'">
<OutputPath>bin\ReleaseNoNet\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<Optimize>true</Optimize>
<DebugType>pdbonly</DebugType>
<PlatformTarget>AnyCPU</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<ItemGroup> <ItemGroup>
<Reference Include="Mono.Android" /> <Reference Include="Mono.Android" />
<Reference Include="System" /> <Reference Include="System" />

View File

@ -28,7 +28,3 @@ using Android.App;
// [assembly: AssemblyVersion("1.0.*")] // [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")] [assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")] [assembly: AssemblyFileVersion("1.0.0.0")]
// Add some common permissions, these can be removed if not needed
[assembly: UsesPermission(Android.Manifest.Permission.Internet)]
[assembly: UsesPermission(Android.Manifest.Permission.WriteExternalStorage)]

View File

@ -31,6 +31,15 @@
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'ReleaseNoNet|AnyCPU'">
<OutputPath>bin\ReleaseNoNet\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<Optimize>true</Optimize>
<DebugType>pdbonly</DebugType>
<PlatformTarget>AnyCPU</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<ItemGroup> <ItemGroup>
<Reference Include="Mono.Android" /> <Reference Include="Mono.Android" />
<Reference Include="System" /> <Reference Include="System" />

View File

@ -28,7 +28,3 @@ using Android.App;
// [assembly: AssemblyVersion("1.0.*")] // [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")] [assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")] [assembly: AssemblyFileVersion("1.0.0.0")]
// Add some common permissions, these can be removed if not needed
[assembly: UsesPermission(Android.Manifest.Permission.Internet)]
[assembly: UsesPermission(Android.Manifest.Permission.WriteExternalStorage)]

View File

@ -31,6 +31,15 @@
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'ReleaseNoNet|AnyCPU'">
<OutputPath>bin\ReleaseNoNet\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<Optimize>true</Optimize>
<DebugType>pdbonly</DebugType>
<PlatformTarget>AnyCPU</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<ItemGroup> <ItemGroup>
<Reference Include="GooglePlayServicesFroyoLib"> <Reference Include="GooglePlayServicesFroyoLib">
<HintPath>..\Components\googleplayservicesfroyo-9.0\lib\android\GooglePlayServicesFroyoLib.dll</HintPath> <HintPath>..\Components\googleplayservicesfroyo-9.0\lib\android\GooglePlayServicesFroyoLib.dll</HintPath>

View File

@ -27,8 +27,4 @@ using Android.App;
// by using the '*' as shown below: // by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")] // [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")] [assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")] [assembly: AssemblyFileVersion("1.0.0.0")]
// Add some common permissions, these can be removed if not needed
[assembly: UsesPermission(Android.Manifest.Permission.Internet)]
[assembly: UsesPermission(Android.Manifest.Permission.WriteExternalStorage)]

View File

@ -222,8 +222,8 @@ Global
{48574278-4779-4B3A-A9E4-9CF1BC285D0B}.Release|x64.ActiveCfg = Release|Any CPU {48574278-4779-4B3A-A9E4-9CF1BC285D0B}.Release|x64.ActiveCfg = Release|Any CPU
{48574278-4779-4B3A-A9E4-9CF1BC285D0B}.ReleaseNoNet|Any CPU.ActiveCfg = Release|Any CPU {48574278-4779-4B3A-A9E4-9CF1BC285D0B}.ReleaseNoNet|Any CPU.ActiveCfg = Release|Any CPU
{48574278-4779-4B3A-A9E4-9CF1BC285D0B}.ReleaseNoNet|Any CPU.Build.0 = Release|Any CPU {48574278-4779-4B3A-A9E4-9CF1BC285D0B}.ReleaseNoNet|Any CPU.Build.0 = Release|Any CPU
{48574278-4779-4B3A-A9E4-9CF1BC285D0B}.ReleaseNoNet|Mixed Platforms.ActiveCfg = Release|Any CPU {48574278-4779-4B3A-A9E4-9CF1BC285D0B}.ReleaseNoNet|Mixed Platforms.ActiveCfg = ReleaseNoNet|Any CPU
{48574278-4779-4B3A-A9E4-9CF1BC285D0B}.ReleaseNoNet|Mixed Platforms.Build.0 = Release|Any CPU {48574278-4779-4B3A-A9E4-9CF1BC285D0B}.ReleaseNoNet|Mixed Platforms.Build.0 = ReleaseNoNet|Any CPU
{48574278-4779-4B3A-A9E4-9CF1BC285D0B}.ReleaseNoNet|Win32.ActiveCfg = Release|Any CPU {48574278-4779-4B3A-A9E4-9CF1BC285D0B}.ReleaseNoNet|Win32.ActiveCfg = Release|Any CPU
{48574278-4779-4B3A-A9E4-9CF1BC285D0B}.ReleaseNoNet|x64.ActiveCfg = Release|Any CPU {48574278-4779-4B3A-A9E4-9CF1BC285D0B}.ReleaseNoNet|x64.ActiveCfg = Release|Any CPU
{23233A28-D74F-4BF8-B4D8-834060840BD7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {23233A28-D74F-4BF8-B4D8-834060840BD7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
@ -240,8 +240,8 @@ Global
{23233A28-D74F-4BF8-B4D8-834060840BD7}.Release|x64.ActiveCfg = Release|Any CPU {23233A28-D74F-4BF8-B4D8-834060840BD7}.Release|x64.ActiveCfg = Release|Any CPU
{23233A28-D74F-4BF8-B4D8-834060840BD7}.ReleaseNoNet|Any CPU.ActiveCfg = Release|Any CPU {23233A28-D74F-4BF8-B4D8-834060840BD7}.ReleaseNoNet|Any CPU.ActiveCfg = Release|Any CPU
{23233A28-D74F-4BF8-B4D8-834060840BD7}.ReleaseNoNet|Any CPU.Build.0 = Release|Any CPU {23233A28-D74F-4BF8-B4D8-834060840BD7}.ReleaseNoNet|Any CPU.Build.0 = Release|Any CPU
{23233A28-D74F-4BF8-B4D8-834060840BD7}.ReleaseNoNet|Mixed Platforms.ActiveCfg = Release|Any CPU {23233A28-D74F-4BF8-B4D8-834060840BD7}.ReleaseNoNet|Mixed Platforms.ActiveCfg = ReleaseNoNet|Any CPU
{23233A28-D74F-4BF8-B4D8-834060840BD7}.ReleaseNoNet|Mixed Platforms.Build.0 = Release|Any CPU {23233A28-D74F-4BF8-B4D8-834060840BD7}.ReleaseNoNet|Mixed Platforms.Build.0 = ReleaseNoNet|Any CPU
{23233A28-D74F-4BF8-B4D8-834060840BD7}.ReleaseNoNet|Win32.ActiveCfg = Release|Any CPU {23233A28-D74F-4BF8-B4D8-834060840BD7}.ReleaseNoNet|Win32.ActiveCfg = Release|Any CPU
{23233A28-D74F-4BF8-B4D8-834060840BD7}.ReleaseNoNet|x64.ActiveCfg = Release|Any CPU {23233A28-D74F-4BF8-B4D8-834060840BD7}.ReleaseNoNet|x64.ActiveCfg = Release|Any CPU
{3C0F7FE5-639F-4422-A087-8B26CF862D1B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {3C0F7FE5-639F-4422-A087-8B26CF862D1B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
@ -258,8 +258,8 @@ Global
{3C0F7FE5-639F-4422-A087-8B26CF862D1B}.Release|x64.ActiveCfg = Release|Any CPU {3C0F7FE5-639F-4422-A087-8B26CF862D1B}.Release|x64.ActiveCfg = Release|Any CPU
{3C0F7FE5-639F-4422-A087-8B26CF862D1B}.ReleaseNoNet|Any CPU.ActiveCfg = Release|Any CPU {3C0F7FE5-639F-4422-A087-8B26CF862D1B}.ReleaseNoNet|Any CPU.ActiveCfg = Release|Any CPU
{3C0F7FE5-639F-4422-A087-8B26CF862D1B}.ReleaseNoNet|Any CPU.Build.0 = Release|Any CPU {3C0F7FE5-639F-4422-A087-8B26CF862D1B}.ReleaseNoNet|Any CPU.Build.0 = Release|Any CPU
{3C0F7FE5-639F-4422-A087-8B26CF862D1B}.ReleaseNoNet|Mixed Platforms.ActiveCfg = Release|Any CPU {3C0F7FE5-639F-4422-A087-8B26CF862D1B}.ReleaseNoNet|Mixed Platforms.ActiveCfg = ReleaseNoNet|Any CPU
{3C0F7FE5-639F-4422-A087-8B26CF862D1B}.ReleaseNoNet|Mixed Platforms.Build.0 = Release|Any CPU {3C0F7FE5-639F-4422-A087-8B26CF862D1B}.ReleaseNoNet|Mixed Platforms.Build.0 = ReleaseNoNet|Any CPU
{3C0F7FE5-639F-4422-A087-8B26CF862D1B}.ReleaseNoNet|Win32.ActiveCfg = Release|Any CPU {3C0F7FE5-639F-4422-A087-8B26CF862D1B}.ReleaseNoNet|Win32.ActiveCfg = Release|Any CPU
{3C0F7FE5-639F-4422-A087-8B26CF862D1B}.ReleaseNoNet|x64.ActiveCfg = Release|Any CPU {3C0F7FE5-639F-4422-A087-8B26CF862D1B}.ReleaseNoNet|x64.ActiveCfg = Release|Any CPU
EndGlobalSection EndGlobalSection

View File

@ -20,7 +20,7 @@
<DebugType>full</DebugType> <DebugType>full</DebugType>
<Optimize>False</Optimize> <Optimize>False</Optimize>
<OutputPath>bin\Debug</OutputPath> <OutputPath>bin\Debug</OutputPath>
<DefineConstants>DEBUG;EXCLUDE_TWOFISH;EXCLUDE_KEYBOARD;EXCLUDE_KEYTRANSFORM;EXCLUDE_FILECHOOSER;EXCLUDE_JAVAFILESTORAGE</DefineConstants> <DefineConstants>DEBUG;EXCLUDE_TWOFISH;INCLUDE_KEYBOARD;EXCLUDE_KEYTRANSFORM;INCLUDE_FILECHOOSER;INCLUDE_JAVAFILESTORAGE</DefineConstants>
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
<ConsolePause>False</ConsolePause> <ConsolePause>False</ConsolePause>

View File

@ -69,9 +69,11 @@ namespace keepass2android.Io
get get
{ {
yield return "file"; yield return "file";
#if !NoNet
yield return "ftp"; yield return "ftp";
yield return "http"; yield return "http";
yield return "https"; yield return "https";
#endif
} }
} }

View File

@ -20,7 +20,7 @@
<DebugType>full</DebugType> <DebugType>full</DebugType>
<Optimize>false</Optimize> <Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath> <OutputPath>bin\Debug\</OutputPath>
<DefineConstants>TRACE;DEBUG;EXCLUDE_TWOFISH;EXCLUDE_KEYBOARD;EXCLUDE_KEYTRANSFORM;EXCLUDE_FILECHOOSER;EXCLUDE_JAVAFILESTORAGE</DefineConstants> <DefineConstants>TRACE;DEBUG;EXCLUDE_TWOFISH;INCLUDE_KEYBOARD;EXCLUDE_KEYTRANSFORM;INCLUDE_FILECHOOSER;INCLUDE_JAVAFILESTORAGE</DefineConstants>
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
</PropertyGroup> </PropertyGroup>
@ -34,7 +34,7 @@
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'ReleaseNoNet|AnyCPU'"> <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'ReleaseNoNet|AnyCPU'">
<OutputPath>bin\ReleaseNoNet\</OutputPath> <OutputPath>bin\ReleaseNoNet\</OutputPath>
<DefineConstants>TRACE</DefineConstants> <DefineConstants>TRACE;NoNet</DefineConstants>
<Optimize>true</Optimize> <Optimize>true</Optimize>
<DebugType>pdbonly</DebugType> <DebugType>pdbonly</DebugType>
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>AnyCPU</PlatformTarget>

View File

@ -228,7 +228,7 @@ namespace keepass2android
string fileProviderAuthority = FileChooserFileProvider.TheAuthority; string fileProviderAuthority = FileChooserFileProvider.TheAuthority;
if (defaultPath.StartsWith("file://")) if (defaultPath.StartsWith("file://"))
{ {
fileProviderAuthority = "keepass2android.keepass2android.android-filechooser.localfile"; fileProviderAuthority = "keepass2android."+AppNames.PackagePart+".android-filechooser.localfile";
} }
Intent i = Keepass2android.Kp2afilechooser.Kp2aFileChooserBridge.GetLaunchFileChooserIntent(this, fileProviderAuthority, Intent i = Keepass2android.Kp2afilechooser.Kp2aFileChooserBridge.GetLaunchFileChooserIntent(this, fileProviderAuthority,
defaultPath); defaultPath);

View File

@ -39,6 +39,9 @@ namespace keepass2android
_protocolIds.Add("androidget"); _protocolIds.Add("androidget");
if (context.Intent.GetBooleanExtra(AllowThirdPartyAppSend, false)) if (context.Intent.GetBooleanExtra(AllowThirdPartyAppSend, false))
_protocolIds.Add("androidsend"); _protocolIds.Add("androidsend");
#if NoNet
_protocolIds.Add("kp2a");
#endif
} }
public override Object GetItem(int position) public override Object GetItem(int position)
@ -53,8 +56,16 @@ namespace keepass2android
public override View GetView(int position, View convertView, ViewGroup parent) public override View GetView(int position, View convertView, ViewGroup parent)
{ {
var view = new FileStorageView(_context, _protocolIds[position], position); if (_protocolIds[position] == "kp2a")
return view; {
return new FileStorageViewKp2a(_context);
}
else
{
var view = new FileStorageView(_context, _protocolIds[position], position);
return view;
}
} }
@ -66,6 +77,13 @@ namespace keepass2android
private void OnItemSelected(string protocolId) private void OnItemSelected(string protocolId)
{ {
if (protocolId == "kp2a")
{
//send user to market page of regular edition to get more protocols
Util.GotoUrl(this, GetString(Resource.String.MarketURL) + "keepass2android.keepass2android");
return;
}
var field = typeof(Resource.String).GetField("filestoragehelp_" + protocolId); var field = typeof(Resource.String).GetField("filestoragehelp_" + protocolId);
if (field == null) if (field == null)
{ {

View File

@ -1,11 +1,22 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" <manifest xmlns:android="http://schemas.android.com/apk/res/android"
android:versionCode="23" android:versionCode="31"
android:versionName="0.8.6" android:versionName="0.9.2"
package="keepass2android.keepass2android_nonet" package="keepass2android.keepass2android_nonet"
android:installLocation="auto"> android:installLocation="auto">
<uses-sdk android:minSdkVersion="8" android:targetSdkVersion="14" /> <uses-sdk android:minSdkVersion="8" android:targetSdkVersion="14" />
<application android:label="keepass2android" android:icon="@drawable/ic_launcher_offline"> <application android:label="keepass2android" android:icon="@drawable/ic_launcher_offline">
<provider android:name="group.pals.android.lib.ui.filechooser.providers.localfile.LocalFileProvider" android:authorities="keepass2android.keepass2android_nonet.android-filechooser.localfile" android:exported="false" />
<provider android:name="group.pals.android.lib.ui.filechooser.providers.history.HistoryProvider" android:authorities="keepass2android.keepass2android_nonet.android-filechooser.history" android:exported="false" />
<activity android:name="group.pals.android.lib.ui.filechooser.FileChooserActivity" android:configChanges="keyboard|keyboardHidden|orientation|screenSize" android:screenOrientation="user" android:theme="@style/Afc.Theme.Light">
<intent-filter>
<action android:name="android.intent.action.GET_CONTENT" />
<data android:mimeType="*/*" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.OPENABLE" />
</intent-filter>
</activity>
<activity android:configChanges="keyboardHidden|orientation" android:label="@string/app_name_nonet" android:theme="@style/Base" android:name="keepass2android.PasswordActivity" > <activity android:configChanges="keyboardHidden|orientation" android:label="@string/app_name_nonet" android:theme="@style/Base" android:name="keepass2android.PasswordActivity" >
<intent-filter android:label="@string/app_name"> <intent-filter android:label="@string/app_name">
<action android:name="android.intent.action.VIEW" /> <action android:name="android.intent.action.VIEW" />

View File

@ -3155,70 +3155,73 @@ namespace keepass2android
public const int filestorage_selection_listitem = 2130903099; public const int filestorage_selection_listitem = 2130903099;
// aapt resource value: 0x7f03003c // aapt resource value: 0x7f03003c
public const int generate_password = 2130903100; public const int filestorage_selection_listitem_kp2a = 2130903100;
// aapt resource value: 0x7f03003d // aapt resource value: 0x7f03003d
public const int group_add_entry = 2130903101; public const int generate_password = 2130903101;
// aapt resource value: 0x7f03003e // aapt resource value: 0x7f03003e
public const int group_edit = 2130903102; public const int group_add_entry = 2130903102;
// aapt resource value: 0x7f03003f // aapt resource value: 0x7f03003f
public const int group_empty = 2130903103; public const int group_edit = 2130903103;
// aapt resource value: 0x7f030040 // aapt resource value: 0x7f030040
public const int group_header = 2130903104; public const int group_empty = 2130903104;
// aapt resource value: 0x7f030041 // aapt resource value: 0x7f030041
public const int group_list_entry = 2130903105; public const int group_header = 2130903105;
// aapt resource value: 0x7f030042 // aapt resource value: 0x7f030042
public const int icon = 2130903106; public const int group_list_entry = 2130903106;
// aapt resource value: 0x7f030043 // aapt resource value: 0x7f030043
public const int icon_picker = 2130903107; public const int icon = 2130903107;
// aapt resource value: 0x7f030044 // aapt resource value: 0x7f030044
public const int input = 2130903108; public const int icon_picker = 2130903108;
// aapt resource value: 0x7f030045 // aapt resource value: 0x7f030045
public const int InViewButton = 2130903109; public const int input = 2130903109;
// aapt resource value: 0x7f030046 // aapt resource value: 0x7f030046
public const int password = 2130903110; public const int InViewButton = 2130903110;
// aapt resource value: 0x7f030047 // aapt resource value: 0x7f030047
public const int QuickUnlock = 2130903111; public const int password = 2130903111;
// aapt resource value: 0x7f030048 // aapt resource value: 0x7f030048
public const int QuickUnlock_Unused = 2130903112; public const int QuickUnlock = 2130903112;
// aapt resource value: 0x7f030049 // aapt resource value: 0x7f030049
public const int SaveButton = 2130903113; public const int QuickUnlock_Unused = 2130903113;
// aapt resource value: 0x7f03004a // aapt resource value: 0x7f03004a
public const int search = 2130903114; public const int SaveButton = 2130903114;
// aapt resource value: 0x7f03004b // aapt resource value: 0x7f03004b
public const int searchurlresults = 2130903115; public const int search = 2130903115;
// aapt resource value: 0x7f03004c // aapt resource value: 0x7f03004c
public const int searchurlresults_empty = 2130903116; public const int searchurlresults = 2130903116;
// aapt resource value: 0x7f03004d // aapt resource value: 0x7f03004d
public const int set_password = 2130903117; public const int searchurlresults_empty = 2130903117;
// aapt resource value: 0x7f03004e // aapt resource value: 0x7f03004e
public const int StartScreenButtons = 2130903118; public const int set_password = 2130903118;
// aapt resource value: 0x7f03004f // aapt resource value: 0x7f03004f
public const int support_simple_spinner_dropdown_item = 2130903119; public const int StartScreenButtons = 2130903119;
// aapt resource value: 0x7f030050 // aapt resource value: 0x7f030050
public const int text_with_help = 2130903120; public const int support_simple_spinner_dropdown_item = 2130903120;
// aapt resource value: 0x7f030051 // aapt resource value: 0x7f030051
public const int url_credentials = 2130903121; public const int text_with_help = 2130903121;
// aapt resource value: 0x7f030052
public const int url_credentials = 2130903122;
static Layout() static Layout()
{ {
@ -3361,53 +3364,53 @@ namespace keepass2android
// aapt resource value: 0x7f0801d0 // aapt resource value: 0x7f0801d0
public const int CannotMoveGroupHere = 2131231184; public const int CannotMoveGroupHere = 2131231184;
// aapt resource value: 0x7f0801fe // aapt resource value: 0x7f0801ff
public const int CertificateFailure = 2131231230; public const int CertificateFailure = 2131231231;
// aapt resource value: 0x7f0801fd // aapt resource value: 0x7f0801fe
public const int CertificateWarning = 2131231229; public const int CertificateWarning = 2131231230;
// aapt resource value: 0x7f08020d
public const int ChangeLog = 2131231245;
// aapt resource value: 0x7f08020c // aapt resource value: 0x7f08020c
public const int ChangeLog = 2131231244; public const int ChangeLog_0_7 = 2131231244;
// aapt resource value: 0x7f08020b
public const int ChangeLog_0_7 = 2131231243;
// aapt resource value: 0x7f080209
public const int ChangeLog_0_8 = 2131231241;
// aapt resource value: 0x7f080208
public const int ChangeLog_0_8_1 = 2131231240;
// aapt resource value: 0x7f080207
public const int ChangeLog_0_8_2 = 2131231239;
// aapt resource value: 0x7f080206
public const int ChangeLog_0_8_3 = 2131231238;
// aapt resource value: 0x7f080205
public const int ChangeLog_0_8_4 = 2131231237;
// aapt resource value: 0x7f080204
public const int ChangeLog_0_8_5 = 2131231236;
// aapt resource value: 0x7f080203
public const int ChangeLog_0_8_6 = 2131231235;
// aapt resource value: 0x7f080202
public const int ChangeLog_0_9 = 2131231234;
// aapt resource value: 0x7f080201
public const int ChangeLog_0_9_1 = 2131231233;
// aapt resource value: 0x7f080200
public const int ChangeLog_0_9_2 = 2131231232;
// aapt resource value: 0x7f08020a // aapt resource value: 0x7f08020a
public const int ChangeLog_keptDonate = 2131231242; public const int ChangeLog_0_8 = 2131231242;
// aapt resource value: 0x7f0801ff // aapt resource value: 0x7f080209
public const int ChangeLog_title = 2131231231; public const int ChangeLog_0_8_1 = 2131231241;
// aapt resource value: 0x7f080208
public const int ChangeLog_0_8_2 = 2131231240;
// aapt resource value: 0x7f080207
public const int ChangeLog_0_8_3 = 2131231239;
// aapt resource value: 0x7f080206
public const int ChangeLog_0_8_4 = 2131231238;
// aapt resource value: 0x7f080205
public const int ChangeLog_0_8_5 = 2131231237;
// aapt resource value: 0x7f080204
public const int ChangeLog_0_8_6 = 2131231236;
// aapt resource value: 0x7f080203
public const int ChangeLog_0_9 = 2131231235;
// aapt resource value: 0x7f080202
public const int ChangeLog_0_9_1 = 2131231234;
// aapt resource value: 0x7f080201
public const int ChangeLog_0_9_2 = 2131231233;
// aapt resource value: 0x7f08020b
public const int ChangeLog_keptDonate = 2131231243;
// aapt resource value: 0x7f080200
public const int ChangeLog_title = 2131231232;
// aapt resource value: 0x7f080095 // aapt resource value: 0x7f080095
public const int CheckForFileChangesOnSave_key = 2131230869; public const int CheckForFileChangesOnSave_key = 2131230869;
@ -4387,6 +4390,9 @@ namespace keepass2android
// aapt resource value: 0x7f0800f3 // aapt resource value: 0x7f0800f3
public const int generate_password = 2131230963; public const int generate_password = 2131230963;
// aapt resource value: 0x7f0801fd
public const int get_regular_version = 2131231229;
// aapt resource value: 0x7f0800f4 // aapt resource value: 0x7f0800f4
public const int group = 2131230964; public const int group = 2131230964;

View File

@ -0,0 +1,83 @@
<?xml version="1.0" encoding="utf-8"?>
<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:stretchColumns="1">
<TableRow
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical">
<ImageView
android:id="@+id/filestorage_logo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="5dp"
android:scaleType="fitXY"
android:src="@drawable/ic_launcher"
/>
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<ImageView
android:id="@+id/filestorage_logo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="5dp"
android:scaleType="fitXY"
android:src="@drawable/ic_storage_ftp"
/>
<ImageView
android:id="@+id/filestorage_logo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="5dp"
android:scaleType="fitXY"
android:src="@drawable/ic_storage_dropbox"
/>
<ImageView
android:id="@+id/filestorage_logo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="5dp"
android:scaleType="fitXY"
android:src="@drawable/ic_storage_gdrive"
/>
<ImageView
android:id="@+id/filestorage_logo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="5dp"
android:scaleType="fitXY"
android:src="@drawable/ic_storage_skydrive"
/>
</LinearLayout>
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<TextView
android:id="@+id/filestorage_label"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/get_regular_version"
android:padding="6dp"
android:textSize="14dp" >
</TextView>
</RelativeLayout>
</LinearLayout>
<View />
</TableRow>
</TableLayout>

View File

@ -378,6 +378,8 @@
<string name="loading">Loading…</string> <string name="loading">Loading…</string>
<string name="get_regular_version">Get more storage types</string>
<string name="CertificateWarning">Warning: Server certificate validation failed: %1$s. Install appropriate root certificate on your device or see settings!</string> <string name="CertificateWarning">Warning: Server certificate validation failed: %1$s. Install appropriate root certificate on your device or see settings!</string>
<string name="CertificateFailure">Error: Server certificate validation failed! Install appropriate root certificate on your device or see settings!</string> <string name="CertificateFailure">Error: Server certificate validation failed! Install appropriate root certificate on your device or see settings!</string>

View File

@ -153,7 +153,7 @@ namespace keepass2android
{ {
#if !EXCLUDE_FILECHOOSER #if !EXCLUDE_FILECHOOSER
const string fileProviderAuthority = "keepass2android.keepass2android.android-filechooser.localfile"; string fileProviderAuthority = act.PackageName+".android-filechooser.localfile";
Intent i = Keepass2android.Kp2afilechooser.Kp2aFileChooserBridge.GetLaunchFileChooserIntent(act, Intent i = Keepass2android.Kp2afilechooser.Kp2aFileChooserBridge.GetLaunchFileChooserIntent(act,
fileProviderAuthority, fileProviderAuthority,

View File

@ -394,10 +394,12 @@ namespace keepass2android
_fileStorages = new List<IFileStorage> _fileStorages = new List<IFileStorage>
{ {
#if !EXCLUDE_JAVAFILESTORAGE #if !EXCLUDE_JAVAFILESTORAGE
#if !NoNet
new DropboxFileStorage(Application.Context, this), new DropboxFileStorage(Application.Context, this),
new DropboxAppFolderFileStorage(Application.Context, this), new DropboxAppFolderFileStorage(Application.Context, this),
new GoogleDriveFileStorage(Application.Context, this), new GoogleDriveFileStorage(Application.Context, this),
new SkyDriveFileStorage(Application.Context, this), new SkyDriveFileStorage(Application.Context, this),
#endif
#endif #endif
new BuiltInFileStorage(this) new BuiltInFileStorage(this)
}; };

View File

@ -98,6 +98,13 @@ namespace keepass2android
{ {
SetContentView(Resource.Layout.file_selection_no_recent); SetContentView(Resource.Layout.file_selection_no_recent);
_fileSelectButtons = (view.FileSelectButtons)FindViewById(Resource.Id.file_select); _fileSelectButtons = (view.FileSelectButtons)FindViewById(Resource.Id.file_select);
#if NoNet
ImageView imgView = FindViewById(Resource.Id.imglogo) as ImageView;
if (imgView != null)
{
imgView.SetImageDrawable(Resources.GetDrawable(Resource.Drawable.ic_keepass2android_nonet));
}
#endif
} }
@ -198,6 +205,7 @@ namespace keepass2android
TextView textView = (TextView)view; TextView textView = (TextView)view;
IOConnectionInfo ioc = new IOConnectionInfo {Path = path}; IOConnectionInfo ioc = new IOConnectionInfo {Path = path};
textView.Text = app.GetFileStorage(ioc).GetDisplayName(ioc); textView.Text = app.GetFileStorage(ioc).GetDisplayName(ioc);
textView.Tag = ioc.Path;
return true; return true;
} }
@ -376,7 +384,7 @@ namespace keepass2android
string fileProviderAuthority = FileChooserFileProvider.TheAuthority; string fileProviderAuthority = FileChooserFileProvider.TheAuthority;
if (defaultPath.StartsWith("file://")) if (defaultPath.StartsWith("file://"))
{ {
fileProviderAuthority = "keepass2android.keepass2android.android-filechooser.localfile"; fileProviderAuthority = PackageName+".android-filechooser.localfile";
} }
Intent i = Keepass2android.Kp2afilechooser.Kp2aFileChooserBridge.GetLaunchFileChooserIntent(this, fileProviderAuthority, Intent i = Keepass2android.Kp2afilechooser.Kp2aFileChooserBridge.GetLaunchFileChooserIntent(this, fileProviderAuthority,
defaultPath); defaultPath);
@ -502,7 +510,7 @@ namespace keepass2android
AdapterView.AdapterContextMenuInfo acmi = (AdapterView.AdapterContextMenuInfo) item.MenuInfo; AdapterView.AdapterContextMenuInfo acmi = (AdapterView.AdapterContextMenuInfo) item.MenuInfo;
TextView tv = (TextView) acmi.TargetView; TextView tv = (TextView) acmi.TargetView;
String filename = tv.Text; String filename = (string) tv.Tag;
_dbHelper.DeleteFile(filename); _dbHelper.DeleteFile(filename);
RefreshList(); RefreshList();

View File

@ -123,6 +123,7 @@
<Compile Include="LockCloseListActivity.cs" /> <Compile Include="LockCloseListActivity.cs" />
<Compile Include="LockingListActivity.cs" /> <Compile Include="LockingListActivity.cs" />
<Compile Include="views\ClickView.cs" /> <Compile Include="views\ClickView.cs" />
<Compile Include="views\FileStorageViewKp2a.cs" />
<Compile Include="views\GroupView.cs" /> <Compile Include="views\GroupView.cs" />
<Compile Include="views\GroupRootView.cs" /> <Compile Include="views\GroupRootView.cs" />
<Compile Include="PwGroupListAdapter.cs" /> <Compile Include="PwGroupListAdapter.cs" />
@ -900,4 +901,7 @@
<ItemGroup> <ItemGroup>
<AndroidResource Include="Resources\drawable-hdpi\ic_storage_dropboxKP2A.png" /> <AndroidResource Include="Resources\drawable-hdpi\ic_storage_dropboxKP2A.png" />
</ItemGroup> </ItemGroup>
<ItemGroup>
<AndroidResource Include="Resources\layout\filestorage_selection_listitem_kp2a.xml" />
</ItemGroup>
</Project> </Project>

View File

@ -16,18 +16,11 @@ This file is part of Keepass2Android, Copyright 2013 Philipp Crocoll. This file
*/ */
using System; using System;
using Android.App; using Android.App;
using Android.Graphics;
using Android.Graphics.Drawables; using Android.Graphics.Drawables;
using Android.OS;
using Android.Runtime; using Android.Runtime;
using Android.Views; using Android.Views;
using Android.Widget; using Android.Widget;
using KeePassLib;
using Android.Text; using Android.Text;
using Android.Text.Style;
using Android.Preferences;
using keepass2android.Io;
using keepass2android.views;
namespace keepass2android.view namespace keepass2android.view
{ {

View File

@ -0,0 +1,40 @@
using System;
using Android.App;
using Android.Runtime;
using Android.Views;
namespace keepass2android.view
{
public sealed class FileStorageViewKp2a: ClickView
{
public FileStorageViewKp2a(IntPtr javaReference, JniHandleOwnership transfer) : base(javaReference, transfer)
{
}
public FileStorageViewKp2a(Activity activity)
: base(activity)
{
View ev = Inflate(activity, Resource.Layout.filestorage_selection_listitem_kp2a, null);
LayoutParams lp = new LayoutParams(ViewGroup.LayoutParams.FillParent, ViewGroup.LayoutParams.WrapContent);
AddView(ev, lp);
}
public override void OnClick()
{
}
public override void OnCreateMenu(IContextMenu menu, IContextMenuContextMenuInfo menuInfo)
{
}
public override bool OnContextItemSelected(IMenuItem item)
{
return false;
}
}
}