add option to choose Icon Sets from other apk.

Created preliminary app for ancient icons
This commit is contained in:
Philipp Crocoll 2015-12-21 21:23:28 +01:00
parent bcd7aa722e
commit 169994eb06
353 changed files with 1286 additions and 189 deletions

View File

@ -0,0 +1,143 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{7F059603-7041-4BBB-93A2-DAA7AB5CA528}</ProjectGuid>
<ProjectTypeGuids>{EFBA0AD7-5A72-4C68-AF49-83D382785DCF};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>AncientIconSet</RootNamespace>
<AssemblyName>AncientIconSet</AssemblyName>
<FileAlignment>512</FileAlignment>
<AndroidApplication>true</AndroidApplication>
<AndroidResgenFile>Resources\Resource.Designer.cs</AndroidResgenFile>
<GenerateSerializationAssemblies>Off</GenerateSerializationAssemblies>
<AndroidUseLatestPlatformSdk>True</AndroidUseLatestPlatformSdk>
<TargetFrameworkVersion>v5.0</TargetFrameworkVersion>
<AndroidManifest>Properties\AndroidManifest.xml</AndroidManifest>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<AndroidLinkMode>None</AndroidLinkMode>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<AndroidUseSharedRuntime>False</AndroidUseSharedRuntime>
</PropertyGroup>
<ItemGroup>
<Reference Include="Mono.Android" />
<Reference Include="mscorlib" />
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="Resources\Resource.Designer.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<None Include="Resources\AboutResources.txt" />
<None Include="Assets\AboutAssets.txt" />
</ItemGroup>
<ItemGroup>
<AndroidResource Include="Resources\drawable\ic00.png" />
<AndroidResource Include="Resources\drawable\ic01.png" />
<AndroidResource Include="Resources\drawable\ic02.png" />
<AndroidResource Include="Resources\drawable\ic03.png" />
<AndroidResource Include="Resources\drawable\ic04.png" />
<AndroidResource Include="Resources\drawable\ic05.png" />
<AndroidResource Include="Resources\drawable\ic06.png" />
<AndroidResource Include="Resources\drawable\ic07.png" />
<AndroidResource Include="Resources\drawable\ic08.png" />
<AndroidResource Include="Resources\drawable\ic09.png" />
<AndroidResource Include="Resources\drawable\ic10.png" />
<AndroidResource Include="Resources\drawable\ic11.png" />
<AndroidResource Include="Resources\drawable\ic12.png" />
<AndroidResource Include="Resources\drawable\ic13.png" />
<AndroidResource Include="Resources\drawable\ic14.png" />
<AndroidResource Include="Resources\drawable\ic15.png" />
<AndroidResource Include="Resources\drawable\ic16.png" />
<AndroidResource Include="Resources\drawable\ic17.png" />
<AndroidResource Include="Resources\drawable\ic18.png" />
<AndroidResource Include="Resources\drawable\ic19.png" />
<AndroidResource Include="Resources\drawable\ic20.png" />
<AndroidResource Include="Resources\drawable\ic21.png" />
<AndroidResource Include="Resources\drawable\ic22.png" />
<AndroidResource Include="Resources\drawable\ic23.png" />
<AndroidResource Include="Resources\drawable\ic24.png" />
<AndroidResource Include="Resources\drawable\ic25.png" />
<AndroidResource Include="Resources\drawable\ic26.png" />
<AndroidResource Include="Resources\drawable\ic27.png" />
<AndroidResource Include="Resources\drawable\ic28.png" />
<AndroidResource Include="Resources\drawable\ic29.png" />
<AndroidResource Include="Resources\drawable\ic30.png" />
<AndroidResource Include="Resources\drawable\ic31.png" />
<AndroidResource Include="Resources\drawable\ic32.png" />
<AndroidResource Include="Resources\drawable\ic33.png" />
<AndroidResource Include="Resources\drawable\ic34.png" />
<AndroidResource Include="Resources\drawable\ic35.png" />
<AndroidResource Include="Resources\drawable\ic36.png" />
<AndroidResource Include="Resources\drawable\ic37.png" />
<AndroidResource Include="Resources\drawable\ic38.png" />
<AndroidResource Include="Resources\drawable\ic39.png" />
<AndroidResource Include="Resources\drawable\ic40.png" />
<AndroidResource Include="Resources\drawable\ic41.png" />
<AndroidResource Include="Resources\drawable\ic42.png" />
<AndroidResource Include="Resources\drawable\ic43.png" />
<AndroidResource Include="Resources\drawable\ic44.png" />
<AndroidResource Include="Resources\drawable\ic45.png" />
<AndroidResource Include="Resources\drawable\ic46.png" />
<AndroidResource Include="Resources\drawable\ic47.png" />
<AndroidResource Include="Resources\drawable\ic48.png" />
<AndroidResource Include="Resources\drawable\ic49.png" />
<AndroidResource Include="Resources\drawable\ic50.png" />
<AndroidResource Include="Resources\drawable\ic51.png" />
<AndroidResource Include="Resources\drawable\ic52.png" />
<AndroidResource Include="Resources\drawable\ic53.png" />
<AndroidResource Include="Resources\drawable\ic54.png" />
<AndroidResource Include="Resources\drawable\ic55.png" />
<AndroidResource Include="Resources\drawable\ic56.png" />
<AndroidResource Include="Resources\drawable\ic57.png" />
<AndroidResource Include="Resources\drawable\ic58.png" />
<AndroidResource Include="Resources\drawable\ic59.png" />
<AndroidResource Include="Resources\drawable\ic60.png" />
<AndroidResource Include="Resources\drawable\ic61.png" />
<AndroidResource Include="Resources\drawable\ic62.png" />
<AndroidResource Include="Resources\drawable\ic63.png" />
<AndroidResource Include="Resources\drawable\ic64.png" />
<AndroidResource Include="Resources\drawable\ic65.png" />
<AndroidResource Include="Resources\drawable\ic66.png" />
<AndroidResource Include="Resources\drawable\ic67.png" />
<AndroidResource Include="Resources\drawable\ic68.png" />
</ItemGroup>
<ItemGroup>
<AndroidResource Include="Resources\values\Strings.xml" />
</ItemGroup>
<ItemGroup>
<None Include="Properties\AndroidManifest.xml" />
</ItemGroup>
<Import Project="$(MSBuildExtensionsPath)\Xamarin\Android\Xamarin.Android.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
<ItemGroup>
<Folder Include="Resources\layout\" />
</ItemGroup>
</Project>

View File

@ -0,0 +1,19 @@
Any raw assets you want to be deployed with your application can be placed in
this directory (and child directories) and given a Build Action of "AndroidAsset".
These files will be deployed with you package and will be accessible using Android's
AssetManager, like this:
public class ReadAsset : Activity
{
protected override void OnCreate (Bundle bundle)
{
base.OnCreate (bundle);
InputStream input = Assets.Open ("my_asset.txt");
}
}
Additionally, some Android functions will automatically load asset files:
Typeface tf = Typeface.CreateFromAsset (Context.Assets, "fonts/samplefont.ttf");

View File

@ -0,0 +1,31 @@
using System;
using Android.App;
using Android.Content;
using Android.Runtime;
using Android.Views;
using Android.Widget;
using Android.OS;
namespace AncientIconSet
{
[Activity(Label = "AncientIconSet", MainLauncher = true, Icon = "@drawable/icon")]
public class MainActivity : Activity
{
int count = 1;
protected override void OnCreate(Bundle bundle)
{
base.OnCreate(bundle);
// Set our view from the "main" layout resource
SetContentView(Resource.Layout.Main);
// Get our button from the layout resource,
// and attach an event to it
Button button = FindViewById<Button>(Resource.Id.MyButton);
button.Click += delegate { button.Text = string.Format("{0} clicks!", count++); };
}
}
}

View File

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="keepass2android.AncientIconSet" android:versionCode="1" android:versionName="1.0">
<uses-sdk android:minSdkVersion="14" android:targetSdkVersion="19" />
<application android:label="Keepass2Android Ancient Icon Set" android:icon="@drawable/ic00"></application>
</manifest>

View File

@ -0,0 +1,30 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using Android.App;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("AncientIconSet")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("AncientIconSet")]
[assembly: AssemblyCopyright("Copyright © 2015")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
[assembly: ComVisible(false)]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]

View File

@ -0,0 +1,50 @@
Images, layout descriptions, binary blobs and string dictionaries can be included
in your application as resource files. Various Android APIs are designed to
operate on the resource IDs instead of dealing with images, strings or binary blobs
directly.
For example, a sample Android app that contains a user interface layout (main.xml),
an internationalization string table (strings.xml) and some icons (drawable-XXX/icon.png)
would keep its resources in the "Resources" directory of the application:
Resources/
drawable-hdpi/
icon.png
drawable-ldpi/
icon.png
drawable-mdpi/
icon.png
layout/
main.xml
values/
strings.xml
In order to get the build system to recognize Android resources, set the build action to
"AndroidResource". The native Android APIs do not operate directly with filenames, but
instead operate on resource IDs. When you compile an Android application that uses resources,
the build system will package the resources for distribution and generate a class called
"Resource" that contains the tokens for each one of the resources included. For example,
for the above Resources layout, this is what the Resource class would expose:
public class Resource {
public class drawable {
public const int icon = 0x123;
}
public class layout {
public const int main = 0x456;
}
public class strings {
public const int first_string = 0xabc;
public const int second_string = 0xbcd;
}
}
You would then use R.drawable.icon to reference the drawable/icon.png file, or Resource.layout.main
to reference the layout/main.xml file, or Resource.strings.first_string to reference the first
string in the dictionary file values/strings.xml.

View File

@ -0,0 +1,284 @@
#pragma warning disable 1591
//------------------------------------------------------------------------------
// <auto-generated>
// Dieser Code wurde von einem Tool generiert.
// Laufzeitversion:4.0.30319.42000
//
// Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
// der Code erneut generiert wird.
// </auto-generated>
//------------------------------------------------------------------------------
[assembly: global::Android.Runtime.ResourceDesignerAttribute("AncientIconSet.Resource", IsApplication=true)]
namespace AncientIconSet
{
[System.CodeDom.Compiler.GeneratedCodeAttribute("Xamarin.Android.Build.Tasks", "1.0.0.0")]
public partial class Resource
{
static Resource()
{
global::Android.Runtime.ResourceIdManager.UpdateIdValues();
}
public static void UpdateIdValues()
{
}
public partial class Attribute
{
static Attribute()
{
global::Android.Runtime.ResourceIdManager.UpdateIdValues();
}
private Attribute()
{
}
}
public partial class Drawable
{
// aapt resource value: 0x7f020000
public const int ic00 = 2130837504;
// aapt resource value: 0x7f020001
public const int ic01 = 2130837505;
// aapt resource value: 0x7f020002
public const int ic02 = 2130837506;
// aapt resource value: 0x7f020003
public const int ic03 = 2130837507;
// aapt resource value: 0x7f020004
public const int ic04 = 2130837508;
// aapt resource value: 0x7f020005
public const int ic05 = 2130837509;
// aapt resource value: 0x7f020006
public const int ic06 = 2130837510;
// aapt resource value: 0x7f020007
public const int ic07 = 2130837511;
// aapt resource value: 0x7f020008
public const int ic08 = 2130837512;
// aapt resource value: 0x7f020009
public const int ic09 = 2130837513;
// aapt resource value: 0x7f02000a
public const int ic10 = 2130837514;
// aapt resource value: 0x7f02000b
public const int ic11 = 2130837515;
// aapt resource value: 0x7f02000c
public const int ic12 = 2130837516;
// aapt resource value: 0x7f02000d
public const int ic13 = 2130837517;
// aapt resource value: 0x7f02000e
public const int ic14 = 2130837518;
// aapt resource value: 0x7f02000f
public const int ic15 = 2130837519;
// aapt resource value: 0x7f020010
public const int ic16 = 2130837520;
// aapt resource value: 0x7f020011
public const int ic17 = 2130837521;
// aapt resource value: 0x7f020012
public const int ic18 = 2130837522;
// aapt resource value: 0x7f020013
public const int ic19 = 2130837523;
// aapt resource value: 0x7f020014
public const int ic20 = 2130837524;
// aapt resource value: 0x7f020015
public const int ic21 = 2130837525;
// aapt resource value: 0x7f020016
public const int ic22 = 2130837526;
// aapt resource value: 0x7f020017
public const int ic23 = 2130837527;
// aapt resource value: 0x7f020018
public const int ic24 = 2130837528;
// aapt resource value: 0x7f020019
public const int ic25 = 2130837529;
// aapt resource value: 0x7f02001a
public const int ic26 = 2130837530;
// aapt resource value: 0x7f02001b
public const int ic27 = 2130837531;
// aapt resource value: 0x7f02001c
public const int ic28 = 2130837532;
// aapt resource value: 0x7f02001d
public const int ic29 = 2130837533;
// aapt resource value: 0x7f02001e
public const int ic30 = 2130837534;
// aapt resource value: 0x7f02001f
public const int ic31 = 2130837535;
// aapt resource value: 0x7f020020
public const int ic32 = 2130837536;
// aapt resource value: 0x7f020021
public const int ic33 = 2130837537;
// aapt resource value: 0x7f020022
public const int ic34 = 2130837538;
// aapt resource value: 0x7f020023
public const int ic35 = 2130837539;
// aapt resource value: 0x7f020024
public const int ic36 = 2130837540;
// aapt resource value: 0x7f020025
public const int ic37 = 2130837541;
// aapt resource value: 0x7f020026
public const int ic38 = 2130837542;
// aapt resource value: 0x7f020027
public const int ic39 = 2130837543;
// aapt resource value: 0x7f020028
public const int ic40 = 2130837544;
// aapt resource value: 0x7f020029
public const int ic41 = 2130837545;
// aapt resource value: 0x7f02002a
public const int ic42 = 2130837546;
// aapt resource value: 0x7f02002b
public const int ic43 = 2130837547;
// aapt resource value: 0x7f02002c
public const int ic44 = 2130837548;
// aapt resource value: 0x7f02002d
public const int ic45 = 2130837549;
// aapt resource value: 0x7f02002e
public const int ic46 = 2130837550;
// aapt resource value: 0x7f02002f
public const int ic47 = 2130837551;
// aapt resource value: 0x7f020030
public const int ic48 = 2130837552;
// aapt resource value: 0x7f020031
public const int ic49 = 2130837553;
// aapt resource value: 0x7f020032
public const int ic50 = 2130837554;
// aapt resource value: 0x7f020033
public const int ic51 = 2130837555;
// aapt resource value: 0x7f020034
public const int ic52 = 2130837556;
// aapt resource value: 0x7f020035
public const int ic53 = 2130837557;
// aapt resource value: 0x7f020036
public const int ic54 = 2130837558;
// aapt resource value: 0x7f020037
public const int ic55 = 2130837559;
// aapt resource value: 0x7f020038
public const int ic56 = 2130837560;
// aapt resource value: 0x7f020039
public const int ic57 = 2130837561;
// aapt resource value: 0x7f02003a
public const int ic58 = 2130837562;
// aapt resource value: 0x7f02003b
public const int ic59 = 2130837563;
// aapt resource value: 0x7f02003c
public const int ic60 = 2130837564;
// aapt resource value: 0x7f02003d
public const int ic61 = 2130837565;
// aapt resource value: 0x7f02003e
public const int ic62 = 2130837566;
// aapt resource value: 0x7f02003f
public const int ic63 = 2130837567;
// aapt resource value: 0x7f020040
public const int ic64 = 2130837568;
// aapt resource value: 0x7f020041
public const int ic65 = 2130837569;
// aapt resource value: 0x7f020042
public const int ic66 = 2130837570;
// aapt resource value: 0x7f020043
public const int ic67 = 2130837571;
// aapt resource value: 0x7f020044
public const int ic68 = 2130837572;
static Drawable()
{
global::Android.Runtime.ResourceIdManager.UpdateIdValues();
}
private Drawable()
{
}
}
public partial class String
{
// aapt resource value: 0x7f030001
public const int ApplicationName = 2130903041;
// aapt resource value: 0x7f030000
public const int kp2a_iconset_name = 2130903040;
static String()
{
global::Android.Runtime.ResourceIdManager.UpdateIdValues();
}
private String()
{
}
}
}
}
#pragma warning restore 1591

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1006 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 191 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 930 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 410 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 631 B

View File

@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<Button
android:id="@+id/MyButton"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="@string/Hello"
/>
</LinearLayout>

View File

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="kp2a_iconset_name">Ancient Icons</string>
<string name="ApplicationName">AncientIconSet</string>
</resources>

View File

@ -1,7 +1,7 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2012
VisualStudioVersion = 14.0.23107.0
VisualStudioVersion = 12.0.31101.0
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KeePassLib2Android", "KeePassLib2Android\KeePassLib2Android.csproj", "{545B4A6B-8BBA-4FBE-92FC-4AC060122A54}"
EndProject
@ -41,6 +41,10 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MaterialTest2", "MaterialTe
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AutoFillPlugin", "AutoFillPlugin\AutoFillPlugin.csproj", "{6FF440E6-E8FF-4E43-8221-9E3972F14812}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ResourceGrabberTest", "ResourceGrabberTest\ResourceGrabberTest.csproj", "{5020E3AD-C420-42D5-BD57-374EE3B7FE49}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AncientIconSet", "AncientIconSet\AncientIconSet.csproj", "{7F059603-7041-4BBB-93A2-DAA7AB5CA528}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@ -177,6 +181,30 @@ Global
{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|x64.ActiveCfg = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Debug|Any CPU.Build.0 = Debug|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Debug|Mixed Platforms.Deploy.0 = Debug|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Debug|Win32.ActiveCfg = Debug|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Debug|x64.ActiveCfg = Debug|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Release|Any CPU.ActiveCfg = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Release|Any CPU.Build.0 = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Release|Any CPU.Deploy.0 = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Release|Mixed Platforms.Deploy.0 = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Release|Win32.ActiveCfg = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.Release|x64.ActiveCfg = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.ReleaseNoNet|Any CPU.ActiveCfg = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.ReleaseNoNet|Any CPU.Build.0 = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.ReleaseNoNet|Any CPU.Deploy.0 = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.ReleaseNoNet|Mixed Platforms.ActiveCfg = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.ReleaseNoNet|Mixed Platforms.Build.0 = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.ReleaseNoNet|Mixed Platforms.Deploy.0 = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.ReleaseNoNet|Win32.ActiveCfg = Release|Any CPU
{5020E3AD-C420-42D5-BD57-374EE3B7FE49}.ReleaseNoNet|x64.ActiveCfg = Release|Any CPU
{53A9CB7F-6553-4BC0-B56B-9410BB2E59AA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{53A9CB7F-6553-4BC0-B56B-9410BB2E59AA}.Debug|Any CPU.Build.0 = Debug|Any CPU
{53A9CB7F-6553-4BC0-B56B-9410BB2E59AA}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
@ -313,6 +341,30 @@ Global
{70D3844A-D9FA-4A64-B205-A84C6A822196}.ReleaseNoNet|Mixed Platforms.Build.0 = ReleaseNoNet|Any CPU
{70D3844A-D9FA-4A64-B205-A84C6A822196}.ReleaseNoNet|Win32.ActiveCfg = Release|Any CPU
{70D3844A-D9FA-4A64-B205-A84C6A822196}.ReleaseNoNet|x64.ActiveCfg = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Debug|Win32.ActiveCfg = Debug|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Debug|Win32.Build.0 = Debug|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Debug|x64.ActiveCfg = Debug|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Debug|x64.Build.0 = Debug|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Release|Any CPU.Build.0 = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Release|Win32.ActiveCfg = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Release|Win32.Build.0 = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Release|x64.ActiveCfg = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.Release|x64.Build.0 = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.ReleaseNoNet|Any CPU.ActiveCfg = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.ReleaseNoNet|Any CPU.Build.0 = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.ReleaseNoNet|Mixed Platforms.ActiveCfg = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.ReleaseNoNet|Mixed Platforms.Build.0 = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.ReleaseNoNet|Win32.ActiveCfg = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.ReleaseNoNet|Win32.Build.0 = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.ReleaseNoNet|x64.ActiveCfg = Release|Any CPU
{7F059603-7041-4BBB-93A2-DAA7AB5CA528}.ReleaseNoNet|x64.Build.0 = Release|Any CPU
{96A3EA5A-7024-479F-A5B1-06654D0867A3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{96A3EA5A-7024-479F-A5B1-06654D0867A3}.Debug|Any CPU.Build.0 = Debug|Any CPU
{96A3EA5A-7024-479F-A5B1-06654D0867A3}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU

View File

@ -1,3 +1,4 @@
using Android.Content;
using Android.Widget;
using Android.Content.Res;
using KeePassLib;
@ -7,10 +8,11 @@ namespace keepass2android
{
public interface IDrawableFactory
{
void AssignDrawableTo (ImageView iv, Resources res, PwDatabase db, PwIcon icon, PwUuid customIconId, bool forGroup);
void AssignDrawableTo(ImageView iv, Context context, PwDatabase db, PwIcon icon, PwUuid customIconId, bool forGroup);
Drawable GetIconDrawable(Resources res, PwDatabase db, PwIcon icon, PwUuid customIconId, bool forGroup);
Drawable GetIconDrawable(Context context, PwDatabase db, PwIcon icon, PwUuid customIconId, bool forGroup);
bool IsWhiteIconSet { get; }
void Clear();
}

View File

@ -208,7 +208,7 @@ namespace keepass2android
if (State.SelectedIcon)
{
App.Kp2a.GetDb().DrawableFactory.AssignDrawableTo(iconButton, Resources, App.Kp2a.GetDb().KpDatabase, (PwIcon)State.SelectedIconId, State.SelectedCustomIconId, false);
App.Kp2a.GetDb().DrawableFactory.AssignDrawableTo(iconButton, this, App.Kp2a.GetDb().KpDatabase, (PwIcon)State.SelectedIconId, State.SelectedCustomIconId, false);
}
iconButton.Click += (sender, evt) => {
UpdateEntryFromUi(State.Entry);
@ -908,7 +908,7 @@ namespace keepass2android
private void FillData() {
ImageButton currIconButton = (ImageButton) FindViewById(Resource.Id.icon_button);
App.Kp2a.GetDb().DrawableFactory.AssignDrawableTo(currIconButton, Resources, App.Kp2a.GetDb().KpDatabase, State.Entry.IconId, State.Entry.CustomIconUuid, false);
App.Kp2a.GetDb().DrawableFactory.AssignDrawableTo(currIconButton, this, App.Kp2a.GetDb().KpDatabase, State.Entry.IconId, State.Entry.CustomIconUuid, false);
PopulateText(Resource.Id.entry_title, State.Entry.Strings.ReadSafe (PwDefs.TitleField));
PopulateText(Resource.Id.entry_user_name, State.Entry.Strings.ReadSafe (PwDefs.UserNameField));

View File

@ -45,6 +45,8 @@ namespace keepass2android
public const String KeyEntry = "entry";
public const String KeyMode = "mode";
private ActivityDesign _design;
public virtual void LaunchActivityForEntry(PwEntry pwEntry, int pos)
{
EntryActivity.Launch(this, pwEntry, pos, AppTask);
@ -52,7 +54,7 @@ namespace keepass2android
protected GroupBaseActivity ()
{
_design = new ActivityDesign(this);
}
protected GroupBaseActivity (IntPtr javaReference, JniHandleOwnership transfer)
@ -181,6 +183,7 @@ namespace keepass2android
protected override void OnResume() {
base.OnResume();
_design.ReapplyTheme();
AppTask.StartInGroupActivity(this);
AppTask.SetupGroupBaseActivityButtons(this);
@ -216,7 +219,7 @@ namespace keepass2android
protected override void OnCreate(Bundle savedInstanceState) {
base.OnCreate(savedInstanceState);
_design.ApplyTheme();
Android.Util.Log.Debug("KP2A", "Creating GBA");
AppTask = AppTask.GetTaskInOnCreate(savedInstanceState, Intent);
@ -314,7 +317,7 @@ namespace keepass2android
protected void SetGroupIcon() {
if (Group != null) {
Drawable drawable = App.Kp2a.GetDb().DrawableFactory.GetIconDrawable(Resources, App.Kp2a.GetDb().KpDatabase, Group.IconId, Group.CustomIconUuid, true);
Drawable drawable = App.Kp2a.GetDb().DrawableFactory.GetIconDrawable(this, App.Kp2a.GetDb().KpDatabase, Group.IconId, Group.CustomIconUuid, true);
SupportActionBar.SetDisplayShowHomeEnabled(true);
//SupportActionBar.SetIcon(drawable);
}

View File

@ -86,7 +86,8 @@ namespace keepass2android
IconPickerActivity.Launch (this);
};
_selectedIconId = (int) PwIcon.FolderOpen;
iconButton.SetImageResource(Icons.IconToResId((PwIcon)_selectedIconId, true));
iconButton.SetImageDrawable(App.Kp2a.GetDb().DrawableFactory.GetIconDrawable(this, App.Kp2a.GetDb().KpDatabase, (PwIcon)_selectedIconId, null, true));
Button okButton = (Button)FindViewById (Resource.Id.ok);
okButton.Click += (sender, e) => {
@ -119,7 +120,7 @@ namespace keepass2android
_selectedCustomIconId = _groupToEdit.CustomIconUuid;
TextView nameField = (TextView)FindViewById(Resource.Id.group_name);
nameField.Text = _groupToEdit.Name;
App.Kp2a.GetDb().DrawableFactory.AssignDrawableTo(iconButton, Resources, App.Kp2a.GetDb().KpDatabase, _groupToEdit.IconId, _groupToEdit.CustomIconUuid, false);
App.Kp2a.GetDb().DrawableFactory.AssignDrawableTo(iconButton, this, App.Kp2a.GetDb().KpDatabase, _groupToEdit.IconId, _groupToEdit.CustomIconUuid, false);
SetTitle(Resource.String.edit_group_title);
}
else
@ -149,7 +150,7 @@ namespace keepass2android
_selectedCustomIconId = new PwUuid(MemUtil.HexStringToByteArray(customIconIdString));
ImageButton currIconButton = (ImageButton) FindViewById(Resource.Id.icon_button);
App.Kp2a.GetDb().DrawableFactory.AssignDrawableTo(currIconButton, Resources, App.Kp2a.GetDb().KpDatabase, (PwIcon) _selectedIconId, _selectedCustomIconId, false);
App.Kp2a.GetDb().DrawableFactory.AssignDrawableTo(currIconButton, this, App.Kp2a.GetDb().KpDatabase, (PwIcon) _selectedIconId, _selectedCustomIconId, false);
break;
}
}

View File

@ -21,6 +21,7 @@ using Android.App;
using Android.Content;
using Android.Graphics;
using Android.OS;
using Android.Preferences;
using Android.Views;
using Android.Widget;
using KeePassLib;
@ -164,7 +165,7 @@ namespace keepass2android
{
get
{
return Icons.Count() + _db.CustomIcons.Count;
return (int)PwIcon.Count + _db.CustomIcons.Count;
}
}
@ -193,17 +194,26 @@ namespace keepass2android
TextView tv = (TextView) currView.FindViewById(Resource.Id.icon_text);
ImageView iv = (ImageView) currView.FindViewById(Resource.Id.icon_image);
if (position < Icons.Count())
if (position < (int)PwIcon.Count)
{
tv.Text = "" + position;
iv.SetImageResource(Icons.IconToResId((KeePassLib.PwIcon) position, false));
Android.Graphics.PorterDuff.Mode mMode = Android.Graphics.PorterDuff.Mode.SrcAtop;
Color color = new Color(189, 189, 189);
iv.SetColorFilter(color, mMode);
App.Kp2a.GetDb()
.DrawableFactory.AssignDrawableTo(iv, _act, App.Kp2a.GetDb().KpDatabase, (KeePassLib.PwIcon) position, null, false);
if (
PreferenceManager.GetDefaultSharedPreferences(currView.Context)
.GetString("IconSetKey", currView.Context.PackageName) == currView.Context.PackageName)
{
Android.Graphics.PorterDuff.Mode mMode = Android.Graphics.PorterDuff.Mode.SrcAtop;
Color color = new Color(189, 189, 189);
iv.SetImageDrawable(iv.Drawable.Mutate());
iv.SetColorFilter(color, mMode);
}
}
else
{
int pos = position - Icons.Count();
int pos = position - (int)PwIcon.Count;
var icon = _db.CustomIcons[pos];
tv.Text = pos.ToString();
iv.SetColorFilter(null);
@ -216,14 +226,14 @@ namespace keepass2android
public bool IsCustomIcon(int position)
{
return position >= Icons.Count();
return position >= (int)PwIcon.Count;
}
public PwCustomIcon GetCustomIcon(int position)
{
if (!IsCustomIcon(position))
return null;
return _db.CustomIcons[position - Icons.Count()];
return _db.CustomIcons[position - (int)PwIcon.Count];
}
}
}

View File

@ -1,12 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
android:versionCode="62"
android:versionName="0.9.9"
android:versionCode="63"
android:versionName="0.9.9b"
package="keepass2android.keepass2android"
android:installLocation="auto">
<uses-sdk android:minSdkVersion="14" android:targetSdkVersion="21" />
<permission android:description="@string/permission_desc" android:icon="@drawable/ic_launcher" android:label="KP2A internal file browsing" android:name="keepass2android.keepass2android.permission.KP2aInternalFileBrowsing" android:protectionLevel="signature" />
<application android:label="keepass2android" android:icon="@drawable/ic_launcher">
<permission android:description="@string/permission_desc" android:icon="@drawable/ic_launcher_online" android:label="KP2A internal file browsing" android:name="keepass2android.keepass2android.permission.KP2aInternalFileBrowsing" android:protectionLevel="signature" />
<application android:label="keepass2android" android:icon="@drawable/ic_launcher_online">
<activity android:name="com.dropbox.client2.android.AuthActivity" android:launchMode="singleTask" android:configChanges="orientation|keyboard">
<intent-filter>
<data android:scheme="db-i8shu7v1hgh7ynt" />

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8" ?>
<?xml version="1.0" encoding="UTF-8" ?>
<set xmlns:android="http://schemas.android.com/apk/res/android"
android:shareInterpolator="false">
<translate

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Some files were not shown because too many files have changed in this diff Show More