Skip to content
This repository has been archived by the owner on Sep 15, 2023. It is now read-only.

Commit

Permalink
Develop (#9)
Browse files Browse the repository at this point in the history
* Ready to attempt store upload

* Added "favorites" functionality

* Improved quick paste options using new paste method to make it work in more applications.

* New store upload attempt.

* Improved paste action to also work in WPF applications. Modified to use WM_CHAR messages rather than a "paste from clipboard" action.

* Catch unexpected exceptions and hope to live on

* Added item preview

* Updated assembly version and screenshots.

* Update app store project accordingly

* Fixed relative location of preview overlay
  • Loading branch information
nicolaihenriksen authored Aug 5, 2017
1 parent 700f191 commit e576b16
Show file tree
Hide file tree
Showing 10 changed files with 36 additions and 8 deletions.
Binary file modified SimpleClipboardManager.Package/_scale-100.appx
Binary file not shown.
Binary file modified SimpleClipboardManager.Package/_scale-125.appx
Binary file not shown.
Binary file modified SimpleClipboardManager.Package/_scale-150.appx
Binary file not shown.
Binary file modified SimpleClipboardManager.Package/_scale-400.appx
Binary file not shown.
2 changes: 1 addition & 1 deletion SimpleClipboardManager.Package/package.appxmanifest
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<Package xmlns="http://schemas.microsoft.com/appx/manifest/foundation/windows10" xmlns:uap="http://schemas.microsoft.com/appx/manifest/uap/windows10" xmlns:desktop="http://schemas.microsoft.com/appx/manifest/desktop/windows10" xmlns:mp="http://schemas.microsoft.com/appx/2014/phone/manifest" xmlns:rescap="http://schemas.microsoft.com/appx/manifest/foundation/windows10/restrictedcapabilities" IgnorableNamespaces="uap rescap mp">
<Identity Name="21227NicolaiHenriksen.SimpleClipboardManager" ProcessorArchitecture="x64" Version="1.5.0.0" Publisher="CN=786B4C61-591E-4C79-AA02-E3FF377CBEB8" />
<Identity Name="21227NicolaiHenriksen.SimpleClipboardManager" ProcessorArchitecture="x64" Version="1.6.0.0" Publisher="CN=786B4C61-591E-4C79-AA02-E3FF377CBEB8" />
<mp:PhoneIdentity PhoneProductId="8192dabb-fcf6-4a62-bba6-799f81dd3851" PhonePublisherId="00000000-0000-0000-0000-000000000000" />
<Properties>
<DisplayName>Simple Clipboard Manager</DisplayName>
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions SimpleClipboardManager/Dialogs/PasteFromClipboardDialog.cs
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,10 @@ public PasteFromClipboardDialog(ClipboardManager manager, string activeAppTitle)
{
if (ClipboardItemList.SelectedItem is ClipboardItem item)
{
var listOffset = ClipboardItemList.LocationInForm();
var left = Width - _previewPanel.Width - 30;
var rect = ClipboardItemList.GetItemRectangle(ClipboardItemList.SelectedIndex);
var point = new Point(_previewPanel.Left, rect.Top + 43 + ClipboardItemList.ItemHeight / 2);
var point = new Point(left, listOffset.Y + rect.Top + ClipboardItemList.ItemHeight / 2);
_previewPanel.Location = point;
_previewPanel.PreviewText = item.PreviewString();
_previewPanel.Visible = _manager.Settings.ShowItemPreview;
Expand Down Expand Up @@ -133,8 +135,6 @@ public PasteFromClipboardDialog(ClipboardManager manager, string activeAppTitle)
BackColor = Color.LightGoldenrodYellow,
Width = 350,
Height = 108,
Top = 150,
Left = 420,
MaxPreviewLines = _manager.Settings.MaxPreviewLines,
Visible = _manager.Settings.ShowItemPreview
};
Expand Down
27 changes: 27 additions & 0 deletions SimpleClipboardManager/ExtensionMethods.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace SimpleClipboardManager
{
internal static class ExtensionMethods
{
internal static Point LocationInForm(this Control control, Form form = null)
{
if (form == null)
{
form = control.FindForm();
if (form == null)
throw new Exception("Form not found.");
}

Point cScreen = control.PointToScreen(control.Location);
Point fScreen = form.Location;
return new Point(cScreen.X - fScreen.X, cScreen.Y - fScreen.Y);
}
}
}
4 changes: 2 additions & 2 deletions SimpleClipboardManager/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,5 @@
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("786eae12-626d-4190-bbb0-41f26bfdfb22")]

[assembly: AssemblyVersion("1.5.0.0")]
[assembly: AssemblyFileVersion("1.5.0.0")]
[assembly: AssemblyVersion("1.6.0.0")]
[assembly: AssemblyFileVersion("1.6.0.0")]
1 change: 1 addition & 0 deletions SimpleClipboardManager/SimpleClipboardManager.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@
<Compile Include="Dialogs\SettingsDialog.Designer.cs">
<DependentUpon>SettingsDialog.cs</DependentUpon>
</Compile>
<Compile Include="ExtensionMethods.cs" />
<Compile Include="GraphicsExtension.cs" />
<Compile Include="HotKeyManager.cs" />
<Compile Include="Model\SettingsModel.cs" />
Expand Down

0 comments on commit e576b16

Please sign in to comment.