[Pkg-cli-apps-commits] [keepass2] 02/04: refresh patches
Julian Taylor
jtaylor.debian at googlemail.com
Sun Aug 17 15:07:35 UTC 2014
This is an automated email from the git hooks/post-receive script.
jtaylor-guest pushed a commit to branch master
in repository keepass2.
commit a845085603160a17716d2d74b9444bca17e0461e
Author: Julian Taylor <jtaylor.debian at googlemail.com>
Date: Sun Aug 17 15:54:07 2014 +0200
refresh patches
remove upstream applied fix-webdav-storage-with-mono-2.11.patch
add fix-autotype-paste.patch from upstream
---
debian/patches/disable-autoupdate-dialog.patch | 2 +-
debian/patches/fix-autotype-paste.patch | 31 ++
.../fix-webdav-storage-with-mono-2.11.patch | 321 ---------------------
debian/patches/series | 2 +-
debian/patches/skip-sgen-run-during-build.patch | 2 +-
debian/patches/use-installed-ico-files.patch | 34 +--
6 files changed, 51 insertions(+), 341 deletions(-)
diff --git a/debian/patches/disable-autoupdate-dialog.patch b/debian/patches/disable-autoupdate-dialog.patch
index fac15c4..856fe13 100644
--- a/debian/patches/disable-autoupdate-dialog.patch
+++ b/debian/patches/disable-autoupdate-dialog.patch
@@ -10,7 +10,7 @@ Forwarded: not-needed
--- a/KeePass/App/Configuration/AceApplication.cs
+++ b/KeePass/App/Configuration/AceApplication.cs
-@@ -293,8 +293,8 @@ namespace KeePass.App.Configuration
+@@ -301,8 +301,8 @@ namespace KeePass.App.Configuration
set { m_bCheckForUpdate = value; }
}
diff --git a/debian/patches/fix-autotype-paste.patch b/debian/patches/fix-autotype-paste.patch
new file mode 100644
index 0000000..7d54135
--- /dev/null
+++ b/debian/patches/fix-autotype-paste.patch
@@ -0,0 +1,31 @@
+From: Julian Taylor <jtaylor.debian at googlemail.com>
+Date: Sun, 17 Aug 2014 15:51:37 +0200
+Subject: fix-autotype-paste
+
+Do not translate upper-case letters; on Windows, sending VK_A results in
+'a', and 'A' with Shift; on some Linux systems, only Ctrl+'v' pastes,
+not Ctrl+'V'
+
+Applied-upstream: 2.28
+Bug: http://sourceforge.net/p/keepass/discussion/329220/thread/bce61102/
+---
+ KeePass/Util/SendInputExt/SiCodes.cs | 8 ++++++--
+ 1 file changed, 6 insertions(+), 2 deletions(-)
+
+--- a/KeePass/Util/SendInputExt/SiCodes.cs
++++ b/KeePass/Util/SendInputExt/SiCodes.cs
+@@ -203,8 +203,12 @@ namespace KeePass.Util.SendInputExt
+ Debug.Assert(d['9'] == (int)Keys.D9);
+
+ Debug.Assert((int)Keys.A == (int)'A');
+- for(char ch = 'A'; ch <= 'Z'; ++ch)
+- d[ch] = (int)ch - (int)'A' + (int)Keys.A;
++ // Do not translate upper-case letters;
++ // on Windows, sending VK_A results in 'a', and 'A' with Shift;
++ // on some Linux systems, only Ctrl+'v' pastes, not Ctrl+'V':
++ // https://sourceforge.net/p/keepass/discussion/329220/thread/bce61102/
++ // for(char ch = 'A'; ch <= 'Z'; ++ch)
++ // d[ch] = (int)ch - (int)'A' + (int)Keys.A;
+ for(char ch = 'a'; ch <= 'z'; ++ch)
+ d[ch] = (int)ch - (int)'a' + (int)Keys.A;
+ Debug.Assert(d['z'] == (int)Keys.Z);
diff --git a/debian/patches/fix-webdav-storage-with-mono-2.11.patch b/debian/patches/fix-webdav-storage-with-mono-2.11.patch
deleted file mode 100644
index a7fbcd8..0000000
--- a/debian/patches/fix-webdav-storage-with-mono-2.11.patch
+++ /dev/null
@@ -1,321 +0,0 @@
-From: Julian Taylor <jtaylor.debian at googlemail.com>
-Date: Tue, 13 May 2014 19:14:00 +0200
-Subject: fix webdav storage with mono >= 2.11
-
-Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/keepass2/+bug/1315962
-Bug: http://sourceforge.net/p/keepass/bugs/1117/
-Applied-Upstream: 2.27
-
---- a/KeePass/Util/MonoWorkarounds.cs
-+++ b/KeePass/Util/MonoWorkarounds.cs
-@@ -42,6 +42,13 @@ namespace KeePass.Util
- // 5795:
- // https://bugzilla.xamarin.com/show_bug.cgi?id=5795
- // https://sourceforge.net/p/keepass/discussion/329220/thread/d23dc88b/
-+ // 10163:
-+ // https://bugzilla.xamarin.com/show_bug.cgi?id=10163
-+ // https://sourceforge.net/p/keepass/bugs/1117/
-+ // https://sourceforge.net/p/keepass/discussion/329221/thread/9422258c/
-+ // https://github.com/mono/mono/commit/8e67b8c2fc7cb66bff7816ebf7c1039fb8cfc43b
-+ // https://bugzilla.xamarin.com/show_bug.cgi?id=1512
-+ // https://sourceforge.net/p/keepass/patches/89/
- // 12525:
- // https://bugzilla.xamarin.com/show_bug.cgi?id=12525
- // https://sourceforge.net/p/keepass/discussion/329220/thread/54f61e9a/
-@@ -64,7 +71,16 @@ namespace KeePass.Util
- // https://sourceforge.net/p/keepass/discussion/329220/thread/d50a79d6/
- public static bool IsRequired(uint uBugID)
- {
-- return MonoWorkarounds.IsRequired();
-+ if(!MonoWorkarounds.IsRequired()) return false;
-+
-+ ulong v = NativeLib.MonoVersion;
-+ if(v != 0)
-+ {
-+ if(uBugID == 10163)
-+ return (v >= 0x0002000B00000000UL); // >= 2.11
-+ }
-+
-+ return true;
- }
-
- public static void ApplyTo(Form f)
---- a/KeePassLib/Native/NativeLib.cs
-+++ b/KeePassLib/Native/NativeLib.cs
-@@ -20,6 +20,7 @@
- using System;
- using System.Collections.Generic;
- using System.Text;
-+using System.Text.RegularExpressions;
- using System.Runtime.InteropServices;
- using System.Windows.Forms;
- using System.Threading;
-@@ -49,6 +50,43 @@ namespace KeePassLib.Native
- set { m_bAllowNative = value; }
- }
-
-+ public static ulong? m_ouMonoVersion = null;
-+ public static ulong MonoVersion
-+ {
-+ get
-+ {
-+ if(m_ouMonoVersion.HasValue) return m_ouMonoVersion.Value;
-+
-+ ulong uVersion = 0;
-+ try
-+ {
-+ Type t = Type.GetType("Mono.Runtime");
-+ if(t != null)
-+ {
-+ MethodInfo mi = t.GetMethod("GetDisplayName",
-+ BindingFlags.NonPublic | BindingFlags.Static);
-+ if(mi != null)
-+ {
-+ string strName = (mi.Invoke(null, null) as string);
-+ if(!string.IsNullOrEmpty(strName))
-+ {
-+ Match m = Regex.Match(strName, "\\d+(\\.\\d+)+");
-+ if(m.Success)
-+ uVersion = StrUtil.ParseVersion(m.Value);
-+ else { Debug.Assert(false); }
-+ }
-+ else { Debug.Assert(false); }
-+ }
-+ else { Debug.Assert(false); }
-+ }
-+ }
-+ catch(Exception) { Debug.Assert(false); }
-+
-+ m_ouMonoVersion = uVersion;
-+ return uVersion;
-+ }
-+ }
-+
- /// <summary>
- /// Determine if the native library is installed.
- /// </summary>
---- a/KeePassLib/Serialization/IOConnection.cs
-+++ b/KeePassLib/Serialization/IOConnection.cs
-@@ -22,6 +22,7 @@ using System.Collections.Generic;
- using System.Text;
- using System.IO;
- using System.Net;
-+using System.Reflection;
- using System.Diagnostics;
-
- #if (!KeePassLibSD && !KeePassRT)
-@@ -50,6 +51,175 @@ namespace KeePassLib.Serialization
- }
- #endif
-
-+ public abstract class WrapperStream : Stream
-+ {
-+ private readonly Stream m_s;
-+ protected Stream BaseStream
-+ {
-+ get { return m_s; }
-+ }
-+
-+ public override bool CanRead
-+ {
-+ get { return m_s.CanRead; }
-+ }
-+
-+ public override bool CanSeek
-+ {
-+ get { return m_s.CanSeek; }
-+ }
-+
-+ public override bool CanTimeout
-+ {
-+ get { return m_s.CanTimeout; }
-+ }
-+
-+ public override bool CanWrite
-+ {
-+ get { return m_s.CanWrite; }
-+ }
-+
-+ public override long Length
-+ {
-+ get { return m_s.Length; }
-+ }
-+
-+ public override long Position
-+ {
-+ get { return m_s.Position; }
-+ set { m_s.Position = value; }
-+ }
-+
-+ public override int ReadTimeout
-+ {
-+ get { return m_s.ReadTimeout; }
-+ set { m_s.ReadTimeout = value; }
-+ }
-+
-+ public override int WriteTimeout
-+ {
-+ get { return m_s.WriteTimeout; }
-+ set { m_s.WriteTimeout = value; }
-+ }
-+
-+ public WrapperStream(Stream sBase) : base()
-+ {
-+ if(sBase == null) throw new ArgumentNullException("sBase");
-+
-+ m_s = sBase;
-+ }
-+
-+ public override IAsyncResult BeginRead(byte[] buffer, int offset,
-+ int count, AsyncCallback callback, object state)
-+ {
-+ return m_s.BeginRead(buffer, offset, count, callback, state);
-+ }
-+
-+ public override IAsyncResult BeginWrite(byte[] buffer, int offset,
-+ int count, AsyncCallback callback, object state)
-+ {
-+ return BeginWrite(buffer, offset, count, callback, state);
-+ }
-+
-+ public override void Close()
-+ {
-+ m_s.Close();
-+ }
-+
-+ public override int EndRead(IAsyncResult asyncResult)
-+ {
-+ return m_s.EndRead(asyncResult);
-+ }
-+
-+ public override void EndWrite(IAsyncResult asyncResult)
-+ {
-+ m_s.EndWrite(asyncResult);
-+ }
-+
-+ public override void Flush()
-+ {
-+ m_s.Flush();
-+ }
-+
-+ public override int Read(byte[] buffer, int offset, int count)
-+ {
-+ return m_s.Read(buffer, offset, count);
-+ }
-+
-+ public override int ReadByte()
-+ {
-+ return m_s.ReadByte();
-+ }
-+
-+ public override long Seek(long offset, SeekOrigin origin)
-+ {
-+ return m_s.Seek(offset, origin);
-+ }
-+
-+ public override void SetLength(long value)
-+ {
-+ m_s.SetLength(value);
-+ }
-+
-+ public override void Write(byte[] buffer, int offset, int count)
-+ {
-+ m_s.Write(buffer, offset, count);
-+ }
-+
-+ public override void WriteByte(byte value)
-+ {
-+ m_s.WriteByte(value);
-+ }
-+ }
-+
-+ public sealed class IocStream : WrapperStream
-+ {
-+ private readonly bool m_bWrite; // Initially opened for writing
-+
-+ public IocStream(Stream sBase) : base(sBase)
-+ {
-+ m_bWrite = sBase.CanWrite;
-+ }
-+
-+ public override void Close()
-+ {
-+ base.Close();
-+
-+ if(m_bWrite)
-+ {
-+ try
-+ {
-+ Stream s = this.BaseStream;
-+ Type t = s.GetType();
-+ if(t.Name == "WebConnectionStream")
-+ {
-+ PropertyInfo pi = t.GetProperty("Request",
-+ BindingFlags.Instance | BindingFlags.NonPublic);
-+ if(pi != null)
-+ {
-+ WebRequest wr = (pi.GetValue(s, null) as WebRequest);
-+ if(wr != null)
-+ IOConnection.DisposeResponse(wr.GetResponse(), false);
-+ else { Debug.Assert(false); }
-+ }
-+ else { Debug.Assert(false); }
-+ }
-+ }
-+ catch(Exception) { Debug.Assert(false); }
-+ }
-+ }
-+
-+ public static Stream WrapIfRequired(Stream s)
-+ {
-+ if(s == null) { Debug.Assert(false); return null; }
-+
-+ if(s.CanWrite)
-+ return new IocStream(s);
-+
-+ return s;
-+ }
-+ }
-+
- public static class IOConnection
- {
- #if (!KeePassLibSD && !KeePassRT)
-@@ -244,7 +414,8 @@ namespace KeePassLib.Serialization
-
- if(ioc.IsLocalFile()) return OpenReadLocal(ioc);
-
-- return CreateWebClient(ioc).OpenRead(new Uri(ioc.Path));
-+ return IocStream.WrapIfRequired(CreateWebClient(ioc).OpenRead(
-+ new Uri(ioc.Path)));
- }
- #else
- public static Stream OpenRead(IOConnectionInfo ioc)
-@@ -271,15 +442,17 @@ namespace KeePassLib.Serialization
- if(ioc.IsLocalFile()) return OpenWriteLocal(ioc);
-
- Uri uri = new Uri(ioc.Path);
-+ Stream s;
-
- // Mono does not set HttpWebRequest.Method to POST for writes,
- // so one needs to set the method to PUT explicitly
- if(NativeLib.IsUnix() && (uri.Scheme.Equals(Uri.UriSchemeHttp,
- StrUtil.CaseIgnoreCmp) || uri.Scheme.Equals(Uri.UriSchemeHttps,
- StrUtil.CaseIgnoreCmp)))
-- return CreateWebClient(ioc).OpenWrite(uri, WebRequestMethods.Http.Put);
-+ s = CreateWebClient(ioc).OpenWrite(uri, WebRequestMethods.Http.Put);
-+ else s = CreateWebClient(ioc).OpenWrite(uri);
-
-- return CreateWebClient(ioc).OpenWrite(uri);
-+ return IocStream.WrapIfRequired(s);
- }
- #else
- public static Stream OpenWrite(IOConnectionInfo ioc)
-@@ -443,7 +616,7 @@ namespace KeePassLib.Serialization
- }
- #endif
-
-- private static void DisposeResponse(WebResponse wr, bool bGetStream)
-+ public static void DisposeResponse(WebResponse wr, bool bGetStream)
- {
- if(wr == null) return;
-
diff --git a/debian/patches/series b/debian/patches/series
index e18be3c..b6fdcc2 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -6,4 +6,4 @@ fix-XSL-search-path.patch
remove-ToolsVersion-3.5.patch
enable-local-help.patch
disable-autoupdate-dialog.patch
-fix-webdav-storage-with-mono-2.11.patch
+fix-autotype-paste.patch
diff --git a/debian/patches/skip-sgen-run-during-build.patch b/debian/patches/skip-sgen-run-during-build.patch
index b147e72..e378181 100644
--- a/debian/patches/skip-sgen-run-during-build.patch
+++ b/debian/patches/skip-sgen-run-during-build.patch
@@ -9,7 +9,7 @@ Forwarded: not-needed
--- a/KeePass/KeePass.csproj
+++ b/KeePass/KeePass.csproj
-@@ -1287,7 +1287,4 @@
+@@ -1294,7 +1294,4 @@
<Target Name="AfterBuild">
</Target>
-->
diff --git a/debian/patches/use-installed-ico-files.patch b/debian/patches/use-installed-ico-files.patch
index 6715b97..d122ce5 100644
--- a/debian/patches/use-installed-ico-files.patch
+++ b/debian/patches/use-installed-ico-files.patch
@@ -53,8 +53,8 @@ Forwarded: not-needed
KeePass/Forms/StatusLoggerForm.cs | 2 +-
KeePass/Forms/TanWizardForm.cs | 2 +-
KeePass/Forms/UpdateCheckForm.cs | 2 +-
- KeePass/Forms/UrlSchemeForm.cs | 2 +-
- KeePass/Forms/UrlSchemesForm.cs | 2 +-
+ KeePass/Forms/UrlOverrideForm.cs | 2 +-
+ KeePass/Forms/UrlOverridesForm.cs | 2 +-
KeePass/Forms/XmlReplaceForm.cs | 2 +-
48 files changed, 55 insertions(+), 55 deletions(-)
@@ -76,7 +76,7 @@ Forwarded: not-needed
m_lvComponents.Columns.Add(KPRes.Status + " / " + KPRes.Version, 100,
--- a/KeePass/Forms/AutoTypeCtxForm.cs
+++ b/KeePass/Forms/AutoTypeCtxForm.cs
-@@ -70,7 +70,7 @@ namespace KeePass.Forms
+@@ -72,7 +72,7 @@ namespace KeePass.Forms
m_lblText.Text = KPRes.AutoTypeEntrySelectionDescLong;
this.Text = KPRes.AutoTypeEntrySelection;
@@ -428,7 +428,7 @@ Forwarded: not-needed
// m_imgFileSaveAllEnabled = Properties.Resources.B16x16_File_SaveAll;
--- a/KeePass/Forms/MainForm_Functions.cs
+++ b/KeePass/Forms/MainForm_Functions.cs
-@@ -413,19 +413,19 @@ namespace KeePass.Forms
+@@ -417,19 +417,19 @@ namespace KeePass.Forms
strNtfText = strNtfPre + strFileDesc;
Icon icoDisposable, icoAssignable;
@@ -451,7 +451,7 @@ Forwarded: not-needed
ref m_kvpIcoTrayNormal, out icoAssignable, out icoDisposable);
m_ntfTray.Icon = icoAssignable;
if(icoDisposable != null) icoDisposable.Dispose();
-@@ -449,7 +449,7 @@ namespace KeePass.Forms
+@@ -453,7 +453,7 @@ namespace KeePass.Forms
m_docMgr.ActiveDatabase.IOConnectionInfo.Path, 63 - strNtfPre.Length);
Icon icoDisposable, icoAssignable;
@@ -460,7 +460,7 @@ Forwarded: not-needed
ref m_kvpIcoTrayNormal, out icoAssignable, out icoDisposable);
m_ntfTray.Icon = icoAssignable;
if(icoDisposable != null) icoDisposable.Dispose();
-@@ -473,7 +473,7 @@ namespace KeePass.Forms
+@@ -477,7 +477,7 @@ namespace KeePass.Forms
m_ntfTray.Text = StrUtil.CompactString3Dots(strNtfText, 63);
Icon icoToDispose, icoToAssign;
@@ -469,7 +469,7 @@ Forwarded: not-needed
ref m_kvpIcoMain, out icoToAssign, out icoToDispose))
this.Icon = icoToAssign;
if(icoToDispose != null) icoToDispose.Dispose();
-@@ -2544,7 +2544,7 @@ namespace KeePass.Forms
+@@ -2570,7 +2570,7 @@ namespace KeePass.Forms
m_bTaskbarButtonMessage = true;
}
// else if(m.Msg == DwmUtil.WM_DWMSENDICONICTHUMBNAIL)
@@ -478,7 +478,7 @@ Forwarded: not-needed
base.WndProc(ref m);
}
-@@ -3551,7 +3551,7 @@ namespace KeePass.Forms
+@@ -3632,7 +3632,7 @@ namespace KeePass.Forms
// wasn't fully constructed at that time yet)
// if(IsFileLocked(null))
// TaskbarList.SetOverlayIcon(this,
@@ -489,7 +489,7 @@ Forwarded: not-needed
if(Program.Config.MainWindow.MinimizeToTray) MinimizeToTray(true);
--- a/KeePass/Forms/OptionsForm.cs
+++ b/KeePass/Forms/OptionsForm.cs
-@@ -110,7 +110,7 @@ namespace KeePass.Forms
+@@ -111,7 +111,7 @@ namespace KeePass.Forms
GlobalWindowManager.AddWindow(this);
@@ -533,7 +533,7 @@ Forwarded: not-needed
if(pst == ProxyServerType.None) m_rbNoProxy.Checked = true;
--- a/KeePass/Forms/PwEntryForm.cs
+++ b/KeePass/Forms/PwEntryForm.cs
-@@ -597,7 +597,7 @@ namespace KeePass.Forms
+@@ -609,7 +609,7 @@ namespace KeePass.Forms
BannerFactory.CreateBannerEx(this, m_bannerImage,
KeePass.Properties.Resources.B48x48_KGPG_Sign, strTitle, strDesc);
@@ -608,26 +608,26 @@ Forwarded: not-needed
this.Text = KPRes.UpdateCheck + " - " + PwDefs.ShortProductName;
UIUtil.SetExplorerTheme(m_lvInfo, true);
---- a/KeePass/Forms/UrlSchemeForm.cs
-+++ b/KeePass/Forms/UrlSchemeForm.cs
+--- a/KeePass/Forms/UrlOverrideForm.cs
++++ b/KeePass/Forms/UrlOverrideForm.cs
@@ -51,7 +51,7 @@ namespace KeePass.Forms
GlobalWindowManager.AddWindow(this);
- this.Icon = Properties.Resources.KeePass;
+ this.Icon = new Icon("/usr/share/keepass2/KeePass.ico");
- this.Text = KPRes.UrlSchemeOverride;
+ this.Text = KPRes.UrlOverride;
m_tbScheme.Text = m_ovr.Scheme;
---- a/KeePass/Forms/UrlSchemesForm.cs
-+++ b/KeePass/Forms/UrlSchemesForm.cs
-@@ -54,7 +54,7 @@ namespace KeePass.Forms
+--- a/KeePass/Forms/UrlOverridesForm.cs
++++ b/KeePass/Forms/UrlOverridesForm.cs
+@@ -66,7 +66,7 @@ namespace KeePass.Forms
GlobalWindowManager.AddWindow(this);
- this.Icon = Properties.Resources.KeePass;
+ this.Icon = new Icon("/usr/share/keepass2/KeePass.ico");
- this.Text = KPRes.UrlSchemeOverrides;
+ this.Text = KPRes.UrlOverrides;
UIUtil.SetExplorerTheme(m_lvOverrides, false);
--- a/KeePass/Forms/XmlReplaceForm.cs
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-cli-apps/packages/keepass2.git
More information about the Pkg-cli-apps-commits
mailing list