added UI for opening a database with OTPs. Some TODOs and things not yet working!

This commit is contained in:
Philipp Crocoll
2013-11-17 07:17:15 +01:00
parent 59eace5834
commit c686cbeeb3
23 changed files with 2745 additions and 4945 deletions

View File

@@ -2,6 +2,7 @@
using System.Collections.Generic;
using System.Text;
using Java.IO;
using KeePassLib.Serialization;
namespace keepass2android.Io
{
@@ -30,5 +31,20 @@ namespace keepass2android.Io
}
public static IOConnectionInfo GetParentPath(IOConnectionInfo ioc)
{
var iocParent = ioc.CloneDeep();
if (iocParent.Path.EndsWith("/"))
iocParent.Path = iocParent.Path.Substring(0, iocParent.Path.Length - 1);
int slashPos = iocParent.Path.LastIndexOf("/", StringComparison.Ordinal);
if (slashPos == -1)
iocParent.Path = "";
else
{
iocParent.Path = iocParent.Path.Substring(0, slashPos);
}
return iocParent;
}
}
}