mirror of
https://github.com/ShareX/ShareX.git
synced 2024-09-29 08:51:36 +13:00
Added image history settings form
This commit is contained in:
parent
129fa2d39d
commit
63274f6482
61 changed files with 701 additions and 360 deletions
|
@ -35,16 +35,8 @@ private void InitializeComponent()
|
||||||
this.tslSearch = new System.Windows.Forms.ToolStripLabel();
|
this.tslSearch = new System.Windows.Forms.ToolStripLabel();
|
||||||
this.tstbSearch = new System.Windows.Forms.ToolStripTextBox();
|
this.tstbSearch = new System.Windows.Forms.ToolStripTextBox();
|
||||||
this.tsbSearch = new System.Windows.Forms.ToolStripButton();
|
this.tsbSearch = new System.Windows.Forms.ToolStripButton();
|
||||||
this.tsddbViewMode = new System.Windows.Forms.ToolStripDropDownButton();
|
this.tsbSettings = new System.Windows.Forms.ToolStripButton();
|
||||||
this.tsmiViewModeThumbnails = new System.Windows.Forms.ToolStripMenuItem();
|
this.tss1 = new System.Windows.Forms.ToolStripSeparator();
|
||||||
this.tsmiViewModeGallery = new System.Windows.Forms.ToolStripMenuItem();
|
|
||||||
this.tsmiViewModePane = new System.Windows.Forms.ToolStripMenuItem();
|
|
||||||
this.tsddbThumbnailSize = new System.Windows.Forms.ToolStripDropDownButton();
|
|
||||||
this.tsmiThumbnailSize75 = new System.Windows.Forms.ToolStripMenuItem();
|
|
||||||
this.tsmiThumbnailSize100 = new System.Windows.Forms.ToolStripMenuItem();
|
|
||||||
this.tsmiThumbnailSize150 = new System.Windows.Forms.ToolStripMenuItem();
|
|
||||||
this.tsmiThumbnailSize200 = new System.Windows.Forms.ToolStripMenuItem();
|
|
||||||
this.tsmiThumbnailSize250 = new System.Windows.Forms.ToolStripMenuItem();
|
|
||||||
this.tscMain.ContentPanel.SuspendLayout();
|
this.tscMain.ContentPanel.SuspendLayout();
|
||||||
this.tscMain.TopToolStripPanel.SuspendLayout();
|
this.tscMain.TopToolStripPanel.SuspendLayout();
|
||||||
this.tscMain.SuspendLayout();
|
this.tscMain.SuspendLayout();
|
||||||
|
@ -72,6 +64,11 @@ private void InitializeComponent()
|
||||||
this.ilvImages.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
|
this.ilvImages.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
|
||||||
this.ilvImages.CacheLimit = "100MB";
|
this.ilvImages.CacheLimit = "100MB";
|
||||||
this.ilvImages.ColumnHeaderFont = new System.Drawing.Font("Microsoft Sans Serif", 8.25F);
|
this.ilvImages.ColumnHeaderFont = new System.Drawing.Font("Microsoft Sans Serif", 8.25F);
|
||||||
|
this.ilvImages.Columns.AddRange(new Manina.Windows.Forms.ImageListView.ImageListViewColumnHeader[] {
|
||||||
|
new Manina.Windows.Forms.ImageListView.ImageListViewColumnHeader(Manina.Windows.Forms.ColumnType.Name, "", 100, 0, true),
|
||||||
|
new Manina.Windows.Forms.ImageListView.ImageListViewColumnHeader(Manina.Windows.Forms.ColumnType.FileSize, "", 100, 1, true),
|
||||||
|
new Manina.Windows.Forms.ImageListView.ImageListViewColumnHeader(Manina.Windows.Forms.ColumnType.Dimensions, "", 100, 2, true),
|
||||||
|
new Manina.Windows.Forms.ImageListView.ImageListViewColumnHeader(Manina.Windows.Forms.ColumnType.FilePath, "", 100, 3, true)});
|
||||||
resources.ApplyResources(this.ilvImages, "ilvImages");
|
resources.ApplyResources(this.ilvImages, "ilvImages");
|
||||||
this.ilvImages.GroupHeaderFont = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Bold);
|
this.ilvImages.GroupHeaderFont = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Bold);
|
||||||
this.ilvImages.Name = "ilvImages";
|
this.ilvImages.Name = "ilvImages";
|
||||||
|
@ -91,8 +88,8 @@ private void InitializeComponent()
|
||||||
this.tslSearch,
|
this.tslSearch,
|
||||||
this.tstbSearch,
|
this.tstbSearch,
|
||||||
this.tsbSearch,
|
this.tsbSearch,
|
||||||
this.tsddbViewMode,
|
this.tss1,
|
||||||
this.tsddbThumbnailSize});
|
this.tsbSettings});
|
||||||
this.tsMain.Name = "tsMain";
|
this.tsMain.Name = "tsMain";
|
||||||
this.tsMain.ShowItemToolTips = false;
|
this.tsMain.ShowItemToolTips = false;
|
||||||
//
|
//
|
||||||
|
@ -116,77 +113,17 @@ private void InitializeComponent()
|
||||||
this.tsbSearch.Name = "tsbSearch";
|
this.tsbSearch.Name = "tsbSearch";
|
||||||
this.tsbSearch.Click += new System.EventHandler(this.tsbSearch_Click);
|
this.tsbSearch.Click += new System.EventHandler(this.tsbSearch_Click);
|
||||||
//
|
//
|
||||||
// tsddbViewMode
|
// tsbSettings
|
||||||
//
|
//
|
||||||
this.tsddbViewMode.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text;
|
this.tsbSettings.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text;
|
||||||
this.tsddbViewMode.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
resources.ApplyResources(this.tsbSettings, "tsbSettings");
|
||||||
this.tsmiViewModeThumbnails,
|
this.tsbSettings.Name = "tsbSettings";
|
||||||
this.tsmiViewModeGallery,
|
this.tsbSettings.Click += new System.EventHandler(this.tsbSettings_Click);
|
||||||
this.tsmiViewModePane});
|
|
||||||
this.tsddbViewMode.Margin = new System.Windows.Forms.Padding(3, 1, 0, 2);
|
|
||||||
this.tsddbViewMode.Name = "tsddbViewMode";
|
|
||||||
resources.ApplyResources(this.tsddbViewMode, "tsddbViewMode");
|
|
||||||
//
|
//
|
||||||
// tsmiViewModeThumbnails
|
// tss1
|
||||||
//
|
//
|
||||||
this.tsmiViewModeThumbnails.Name = "tsmiViewModeThumbnails";
|
this.tss1.Name = "tss1";
|
||||||
resources.ApplyResources(this.tsmiViewModeThumbnails, "tsmiViewModeThumbnails");
|
resources.ApplyResources(this.tss1, "tss1");
|
||||||
this.tsmiViewModeThumbnails.Click += new System.EventHandler(this.tsmiViewModeThumbnails_Click);
|
|
||||||
//
|
|
||||||
// tsmiViewModeGallery
|
|
||||||
//
|
|
||||||
this.tsmiViewModeGallery.Name = "tsmiViewModeGallery";
|
|
||||||
resources.ApplyResources(this.tsmiViewModeGallery, "tsmiViewModeGallery");
|
|
||||||
this.tsmiViewModeGallery.Click += new System.EventHandler(this.tsmiViewModeGallery_Click);
|
|
||||||
//
|
|
||||||
// tsmiViewModePane
|
|
||||||
//
|
|
||||||
this.tsmiViewModePane.Name = "tsmiViewModePane";
|
|
||||||
resources.ApplyResources(this.tsmiViewModePane, "tsmiViewModePane");
|
|
||||||
this.tsmiViewModePane.Click += new System.EventHandler(this.tsmiViewModePane_Click);
|
|
||||||
//
|
|
||||||
// tsddbThumbnailSize
|
|
||||||
//
|
|
||||||
this.tsddbThumbnailSize.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text;
|
|
||||||
this.tsddbThumbnailSize.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
|
||||||
this.tsmiThumbnailSize75,
|
|
||||||
this.tsmiThumbnailSize100,
|
|
||||||
this.tsmiThumbnailSize150,
|
|
||||||
this.tsmiThumbnailSize200,
|
|
||||||
this.tsmiThumbnailSize250});
|
|
||||||
this.tsddbThumbnailSize.Margin = new System.Windows.Forms.Padding(3, 1, 0, 2);
|
|
||||||
this.tsddbThumbnailSize.Name = "tsddbThumbnailSize";
|
|
||||||
resources.ApplyResources(this.tsddbThumbnailSize, "tsddbThumbnailSize");
|
|
||||||
//
|
|
||||||
// tsmiThumbnailSize75
|
|
||||||
//
|
|
||||||
this.tsmiThumbnailSize75.Name = "tsmiThumbnailSize75";
|
|
||||||
resources.ApplyResources(this.tsmiThumbnailSize75, "tsmiThumbnailSize75");
|
|
||||||
this.tsmiThumbnailSize75.Click += new System.EventHandler(this.tsmiThumbnailSize75_Click);
|
|
||||||
//
|
|
||||||
// tsmiThumbnailSize100
|
|
||||||
//
|
|
||||||
this.tsmiThumbnailSize100.Name = "tsmiThumbnailSize100";
|
|
||||||
resources.ApplyResources(this.tsmiThumbnailSize100, "tsmiThumbnailSize100");
|
|
||||||
this.tsmiThumbnailSize100.Click += new System.EventHandler(this.tsmiThumbnailSize100_Click);
|
|
||||||
//
|
|
||||||
// tsmiThumbnailSize150
|
|
||||||
//
|
|
||||||
this.tsmiThumbnailSize150.Name = "tsmiThumbnailSize150";
|
|
||||||
resources.ApplyResources(this.tsmiThumbnailSize150, "tsmiThumbnailSize150");
|
|
||||||
this.tsmiThumbnailSize150.Click += new System.EventHandler(this.tsmiThumbnailSize150_Click);
|
|
||||||
//
|
|
||||||
// tsmiThumbnailSize200
|
|
||||||
//
|
|
||||||
this.tsmiThumbnailSize200.Name = "tsmiThumbnailSize200";
|
|
||||||
resources.ApplyResources(this.tsmiThumbnailSize200, "tsmiThumbnailSize200");
|
|
||||||
this.tsmiThumbnailSize200.Click += new System.EventHandler(this.tsmiThumbnailSize200_Click);
|
|
||||||
//
|
|
||||||
// tsmiThumbnailSize250
|
|
||||||
//
|
|
||||||
this.tsmiThumbnailSize250.Name = "tsmiThumbnailSize250";
|
|
||||||
resources.ApplyResources(this.tsmiThumbnailSize250, "tsmiThumbnailSize250");
|
|
||||||
this.tsmiThumbnailSize250.Click += new System.EventHandler(this.tsmiThumbnailSize250_Click);
|
|
||||||
//
|
//
|
||||||
// ImageHistoryForm
|
// ImageHistoryForm
|
||||||
//
|
//
|
||||||
|
@ -214,18 +151,10 @@ private void InitializeComponent()
|
||||||
private Manina.Windows.Forms.ImageListView ilvImages;
|
private Manina.Windows.Forms.ImageListView ilvImages;
|
||||||
private System.Windows.Forms.ToolStripContainer tscMain;
|
private System.Windows.Forms.ToolStripContainer tscMain;
|
||||||
private System.Windows.Forms.ToolStrip tsMain;
|
private System.Windows.Forms.ToolStrip tsMain;
|
||||||
private System.Windows.Forms.ToolStripDropDownButton tsddbThumbnailSize;
|
|
||||||
private System.Windows.Forms.ToolStripMenuItem tsmiThumbnailSize75;
|
|
||||||
private System.Windows.Forms.ToolStripMenuItem tsmiThumbnailSize100;
|
|
||||||
private System.Windows.Forms.ToolStripMenuItem tsmiThumbnailSize150;
|
|
||||||
private System.Windows.Forms.ToolStripMenuItem tsmiThumbnailSize200;
|
|
||||||
private System.Windows.Forms.ToolStripMenuItem tsmiThumbnailSize250;
|
|
||||||
private System.Windows.Forms.ToolStripDropDownButton tsddbViewMode;
|
|
||||||
private System.Windows.Forms.ToolStripMenuItem tsmiViewModeThumbnails;
|
|
||||||
private System.Windows.Forms.ToolStripMenuItem tsmiViewModeGallery;
|
|
||||||
private System.Windows.Forms.ToolStripMenuItem tsmiViewModePane;
|
|
||||||
private System.Windows.Forms.ToolStripLabel tslSearch;
|
private System.Windows.Forms.ToolStripLabel tslSearch;
|
||||||
private System.Windows.Forms.ToolStripTextBox tstbSearch;
|
private System.Windows.Forms.ToolStripTextBox tstbSearch;
|
||||||
private System.Windows.Forms.ToolStripButton tsbSearch;
|
private System.Windows.Forms.ToolStripButton tsbSearch;
|
||||||
|
private System.Windows.Forms.ToolStripSeparator tss1;
|
||||||
|
private System.Windows.Forms.ToolStripButton tsbSettings;
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -38,63 +38,28 @@ namespace ShareX.HistoryLib
|
||||||
public partial class ImageHistoryForm : Form
|
public partial class ImageHistoryForm : Form
|
||||||
{
|
{
|
||||||
public string HistoryPath { get; private set; }
|
public string HistoryPath { get; private set; }
|
||||||
public int ViewMode { get; set; }
|
public ImageHistorySettings Settings { get; private set; }
|
||||||
public Size ThumbnailSize { get; set; }
|
|
||||||
public string SearchText { get; set; }
|
public string SearchText { get; set; }
|
||||||
|
|
||||||
private HistoryManager history;
|
private HistoryManager history;
|
||||||
private HistoryItemManager him;
|
private HistoryItemManager him;
|
||||||
|
|
||||||
public ImageHistoryForm(string historyPath, int viewMode, Size thumbnailSize, Action<string> uploadFile = null, Action<string> editImage = null)
|
public ImageHistoryForm(string historyPath, ImageHistorySettings settings, Action<string> uploadFile = null, Action<string> editImage = null)
|
||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
Icon = ShareXResources.Icon;
|
Icon = ShareXResources.Icon;
|
||||||
|
|
||||||
HistoryPath = historyPath;
|
HistoryPath = historyPath;
|
||||||
|
Settings = settings;
|
||||||
|
|
||||||
tsMain.Renderer = new CustomToolStripProfessionalRenderer();
|
tsMain.Renderer = new CustomToolStripProfessionalRenderer();
|
||||||
ViewMode = viewMode.Between(0, 3);
|
ilvImages.View = (View)Settings.ViewMode;
|
||||||
ilvImages.View = (View)ViewMode;
|
ilvImages.ThumbnailSize = Settings.ThumbnailSize;
|
||||||
|
|
||||||
switch (ilvImages.View)
|
|
||||||
{
|
|
||||||
default:
|
|
||||||
case View.Thumbnails:
|
|
||||||
tsmiViewModeThumbnails.RadioCheck();
|
|
||||||
break;
|
|
||||||
case View.Gallery:
|
|
||||||
tsmiViewModeGallery.RadioCheck();
|
|
||||||
break;
|
|
||||||
case View.Pane:
|
|
||||||
tsmiViewModePane.RadioCheck();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
ThumbnailSize = thumbnailSize;
|
|
||||||
ilvImages.ThumbnailSize = ThumbnailSize;
|
|
||||||
|
|
||||||
switch (ThumbnailSize.Width)
|
|
||||||
{
|
|
||||||
case 75:
|
|
||||||
tsmiThumbnailSize75.RadioCheck();
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
case 100:
|
|
||||||
tsmiThumbnailSize100.RadioCheck();
|
|
||||||
break;
|
|
||||||
case 150:
|
|
||||||
tsmiThumbnailSize150.RadioCheck();
|
|
||||||
break;
|
|
||||||
case 200:
|
|
||||||
tsmiThumbnailSize200.RadioCheck();
|
|
||||||
break;
|
|
||||||
case 250:
|
|
||||||
tsmiThumbnailSize250.RadioCheck();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
him = new HistoryItemManager(uploadFile, editImage);
|
him = new HistoryItemManager(uploadFile, editImage);
|
||||||
him.GetHistoryItems += him_GetHistoryItems;
|
him.GetHistoryItems += him_GetHistoryItems;
|
||||||
|
|
||||||
|
Settings.WindowState.AutoHandleFormState(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void RefreshHistoryItems()
|
private void RefreshHistoryItems()
|
||||||
|
@ -181,60 +146,15 @@ private void tsbSearch_Click(object sender, EventArgs e)
|
||||||
RefreshHistoryItems();
|
RefreshHistoryItems();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void tsmiViewModeThumbnails_Click(object sender, EventArgs e)
|
private void tsbSettings_Click(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
tsmiViewModeThumbnails.RadioCheck();
|
using (ImageHistorySettingsForm form = new ImageHistorySettingsForm(Settings))
|
||||||
ilvImages.View = View.Thumbnails;
|
{
|
||||||
ViewMode = (int)ilvImages.View;
|
form.ShowDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void tsmiViewModeGallery_Click(object sender, EventArgs e)
|
ilvImages.View = (View)Settings.ViewMode;
|
||||||
{
|
ilvImages.ThumbnailSize = Settings.ThumbnailSize;
|
||||||
tsmiViewModeGallery.RadioCheck();
|
|
||||||
ilvImages.View = View.Gallery;
|
|
||||||
ViewMode = (int)ilvImages.View;
|
|
||||||
}
|
|
||||||
|
|
||||||
private void tsmiViewModePane_Click(object sender, EventArgs e)
|
|
||||||
{
|
|
||||||
tsmiViewModePane.RadioCheck();
|
|
||||||
ilvImages.View = View.Pane;
|
|
||||||
ViewMode = (int)ilvImages.View;
|
|
||||||
}
|
|
||||||
|
|
||||||
private void tsmiThumbnailSize75_Click(object sender, EventArgs e)
|
|
||||||
{
|
|
||||||
tsmiThumbnailSize75.RadioCheck();
|
|
||||||
ilvImages.ThumbnailSize = new Size(75, 75);
|
|
||||||
ThumbnailSize = ilvImages.ThumbnailSize;
|
|
||||||
}
|
|
||||||
|
|
||||||
private void tsmiThumbnailSize100_Click(object sender, EventArgs e)
|
|
||||||
{
|
|
||||||
tsmiThumbnailSize100.RadioCheck();
|
|
||||||
ilvImages.ThumbnailSize = new Size(100, 100);
|
|
||||||
ThumbnailSize = ilvImages.ThumbnailSize;
|
|
||||||
}
|
|
||||||
|
|
||||||
private void tsmiThumbnailSize150_Click(object sender, EventArgs e)
|
|
||||||
{
|
|
||||||
tsmiThumbnailSize150.RadioCheck();
|
|
||||||
ilvImages.ThumbnailSize = new Size(150, 150);
|
|
||||||
ThumbnailSize = ilvImages.ThumbnailSize;
|
|
||||||
}
|
|
||||||
|
|
||||||
private void tsmiThumbnailSize200_Click(object sender, EventArgs e)
|
|
||||||
{
|
|
||||||
tsmiThumbnailSize200.RadioCheck();
|
|
||||||
ilvImages.ThumbnailSize = new Size(200, 200);
|
|
||||||
ThumbnailSize = ilvImages.ThumbnailSize;
|
|
||||||
}
|
|
||||||
|
|
||||||
private void tsmiThumbnailSize250_Click(object sender, EventArgs e)
|
|
||||||
{
|
|
||||||
tsmiThumbnailSize250.RadioCheck();
|
|
||||||
ilvImages.ThumbnailSize = new Size(250, 250);
|
|
||||||
ThumbnailSize = ilvImages.ThumbnailSize;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void ilvImages_KeyDown(object sender, KeyEventArgs e)
|
private void ilvImages_KeyDown(object sender, KeyEventArgs e)
|
|
@ -220,7 +220,7 @@
|
||||||
<value>Search:</value>
|
<value>Search:</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tstbSearch.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="tstbSearch.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>200, 25</value>
|
<value>300, 25</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsbSearch.ImageTransparentColor" type="System.Drawing.Color, System.Drawing">
|
<data name="tsbSearch.ImageTransparentColor" type="System.Drawing.Color, System.Drawing">
|
||||||
<value>Magenta</value>
|
<value>Magenta</value>
|
||||||
|
@ -228,74 +228,41 @@
|
||||||
<data name="tsbSearch.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="tsbSearch.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>23, 22</value>
|
<value>23, 22</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsbSearch.Text" xml:space="preserve">
|
<data name="tsbSearch.ToolTipText" xml:space="preserve">
|
||||||
<value>toolStripButton1</value>
|
<value>Search</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsmiViewModeThumbnails.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="tss1.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>137, 22</value>
|
<value>6, 25</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsmiViewModeThumbnails.Text" xml:space="preserve">
|
<data name="tsbSettings.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
<value>Thumbnails</value>
|
<value>
|
||||||
|
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
||||||
|
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAIDSURBVDhPpZLrS5NhGMb3j4SWh0oRQVExD4gonkDpg4hG
|
||||||
|
YKxG6WBogkMZKgPNCEVJFBGdGETEvgwyO9DJE5syZw3PIlPEE9pgBCLZ5XvdMB8Ew8gXbl54nuf63dd9
|
||||||
|
0OGSnwCahxbPRNPAPMw9Xpg6ZmF46kZZ0xSKzJPIrhpDWsVnpBhGkKx3nAX8Pv7z1zg8OoY/cITdn4fw
|
||||||
|
bf/C0kYAN3Ma/w3gWfZL5kzTKBxjWyK2DftwI9tyMYCZKXbNHaD91bLYJrDXsYbrWfUKwJrPE9M2M1Oc
|
||||||
|
VzOOpHI7Jr376Hi9ogHqFIANO0/MmmmbmSmm9a8ze+I4MrNWAdjtoJgWcx+PSzg166yZZ8xM8XvXDix9
|
||||||
|
c4jIqFYAjoriBV9AhEPv1mH/sonogha0afbZMMZz+yreTGyhpusHwtNNCsA5U1zS4BLxzJIfg299qO32
|
||||||
|
Ir7UJtZfftyATqeT+8o2D8JSjQrAJblrncYL7ZJ2+bfaFnC/1S1NjL3diRat7qrO7wLRP3HjWsojBeCo
|
||||||
|
mDEo5mNjuweFGvjWg2EBhCbpkW78htSHHwRyNdmgAFzPEee2iFkzayy2OLXzT4gr6UdUnlXrullsxxQ+
|
||||||
|
kx0g8BTA3aZlButjSTyjODq/WcQcW/B/Je4OQhLvKQDnzN1mp0nnkvAhR8VuMzNrpm1mpjgkoVwB/v8D
|
||||||
|
TgDQASA1MVpwzwAAAABJRU5ErkJggg==
|
||||||
|
</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsmiViewModeGallery.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="tsbSettings.ImageTransparentColor" type="System.Drawing.Color, System.Drawing">
|
||||||
<value>137, 22</value>
|
<value>Magenta</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsmiViewModeGallery.Text" xml:space="preserve">
|
<data name="tsbSettings.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>Gallery</value>
|
<value>62, 22</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsmiViewModePane.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="tsbSettings.Text" xml:space="preserve">
|
||||||
<value>137, 22</value>
|
<value>Settings...</value>
|
||||||
</data>
|
|
||||||
<data name="tsmiViewModePane.Text" xml:space="preserve">
|
|
||||||
<value>Pane</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsddbViewMode.Size" type="System.Drawing.Size, System.Drawing">
|
|
||||||
<value>79, 22</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsddbViewMode.Text" xml:space="preserve">
|
|
||||||
<value>View mode</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsmiThumbnailSize75.Size" type="System.Drawing.Size, System.Drawing">
|
|
||||||
<value>121, 22</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsmiThumbnailSize75.Text" xml:space="preserve">
|
|
||||||
<value>75 x 75</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsmiThumbnailSize100.Size" type="System.Drawing.Size, System.Drawing">
|
|
||||||
<value>121, 22</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsmiThumbnailSize100.Text" xml:space="preserve">
|
|
||||||
<value>100 x 100</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsmiThumbnailSize150.Size" type="System.Drawing.Size, System.Drawing">
|
|
||||||
<value>121, 22</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsmiThumbnailSize150.Text" xml:space="preserve">
|
|
||||||
<value>150 x 150</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsmiThumbnailSize200.Size" type="System.Drawing.Size, System.Drawing">
|
|
||||||
<value>121, 22</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsmiThumbnailSize200.Text" xml:space="preserve">
|
|
||||||
<value>200 x 200</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsmiThumbnailSize250.Size" type="System.Drawing.Size, System.Drawing">
|
|
||||||
<value>121, 22</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsmiThumbnailSize250.Text" xml:space="preserve">
|
|
||||||
<value>250 x 250</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsddbThumbnailSize.Size" type="System.Drawing.Size, System.Drawing">
|
|
||||||
<value>100, 22</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsddbThumbnailSize.Text" xml:space="preserve">
|
|
||||||
<value>Thumbnail size</value>
|
|
||||||
</data>
|
</data>
|
||||||
<data name="tsMain.Location" type="System.Drawing.Point, System.Drawing">
|
<data name="tsMain.Location" type="System.Drawing.Point, System.Drawing">
|
||||||
<value>3, 0</value>
|
<value>3, 0</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsMain.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="tsMain.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>458, 25</value>
|
<value>441, 25</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsMain.TabIndex" type="System.Int32, mscorlib">
|
<data name="tsMain.TabIndex" type="System.Int32, mscorlib">
|
||||||
<value>0</value>
|
<value>0</value>
|
||||||
|
@ -369,65 +336,17 @@
|
||||||
<data name=">>tsbSearch.Type" xml:space="preserve">
|
<data name=">>tsbSearch.Type" xml:space="preserve">
|
||||||
<value>System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
<value>System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
</data>
|
</data>
|
||||||
<data name=">>tsddbViewMode.Name" xml:space="preserve">
|
<data name=">>tsbSettings.Name" xml:space="preserve">
|
||||||
<value>tsddbViewMode</value>
|
<value>tsbSettings</value>
|
||||||
</data>
|
</data>
|
||||||
<data name=">>tsddbViewMode.Type" xml:space="preserve">
|
<data name=">>tsbSettings.Type" xml:space="preserve">
|
||||||
<value>System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
<value>System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
</data>
|
</data>
|
||||||
<data name=">>tsmiViewModeThumbnails.Name" xml:space="preserve">
|
<data name=">>tss1.Name" xml:space="preserve">
|
||||||
<value>tsmiViewModeThumbnails</value>
|
<value>tss1</value>
|
||||||
</data>
|
</data>
|
||||||
<data name=">>tsmiViewModeThumbnails.Type" xml:space="preserve">
|
<data name=">>tss1.Type" xml:space="preserve">
|
||||||
<value>System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
<value>System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
</data>
|
|
||||||
<data name=">>tsmiViewModeGallery.Name" xml:space="preserve">
|
|
||||||
<value>tsmiViewModeGallery</value>
|
|
||||||
</data>
|
|
||||||
<data name=">>tsmiViewModeGallery.Type" xml:space="preserve">
|
|
||||||
<value>System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
|
||||||
</data>
|
|
||||||
<data name=">>tsmiViewModePane.Name" xml:space="preserve">
|
|
||||||
<value>tsmiViewModePane</value>
|
|
||||||
</data>
|
|
||||||
<data name=">>tsmiViewModePane.Type" xml:space="preserve">
|
|
||||||
<value>System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
|
||||||
</data>
|
|
||||||
<data name=">>tsddbThumbnailSize.Name" xml:space="preserve">
|
|
||||||
<value>tsddbThumbnailSize</value>
|
|
||||||
</data>
|
|
||||||
<data name=">>tsddbThumbnailSize.Type" xml:space="preserve">
|
|
||||||
<value>System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
|
||||||
</data>
|
|
||||||
<data name=">>tsmiThumbnailSize75.Name" xml:space="preserve">
|
|
||||||
<value>tsmiThumbnailSize75</value>
|
|
||||||
</data>
|
|
||||||
<data name=">>tsmiThumbnailSize75.Type" xml:space="preserve">
|
|
||||||
<value>System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
|
||||||
</data>
|
|
||||||
<data name=">>tsmiThumbnailSize100.Name" xml:space="preserve">
|
|
||||||
<value>tsmiThumbnailSize100</value>
|
|
||||||
</data>
|
|
||||||
<data name=">>tsmiThumbnailSize100.Type" xml:space="preserve">
|
|
||||||
<value>System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
|
||||||
</data>
|
|
||||||
<data name=">>tsmiThumbnailSize150.Name" xml:space="preserve">
|
|
||||||
<value>tsmiThumbnailSize150</value>
|
|
||||||
</data>
|
|
||||||
<data name=">>tsmiThumbnailSize150.Type" xml:space="preserve">
|
|
||||||
<value>System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
|
||||||
</data>
|
|
||||||
<data name=">>tsmiThumbnailSize200.Name" xml:space="preserve">
|
|
||||||
<value>tsmiThumbnailSize200</value>
|
|
||||||
</data>
|
|
||||||
<data name=">>tsmiThumbnailSize200.Type" xml:space="preserve">
|
|
||||||
<value>System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
|
||||||
</data>
|
|
||||||
<data name=">>tsmiThumbnailSize250.Name" xml:space="preserve">
|
|
||||||
<value>tsmiThumbnailSize250</value>
|
|
||||||
</data>
|
|
||||||
<data name=">>tsmiThumbnailSize250.Type" xml:space="preserve">
|
|
||||||
<value>System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
|
||||||
</data>
|
</data>
|
||||||
<data name=">>$this.Name" xml:space="preserve">
|
<data name=">>$this.Name" xml:space="preserve">
|
||||||
<value>ImageHistoryForm</value>
|
<value>ImageHistoryForm</value>
|
135
ShareX.HistoryLib/Forms/ImageHistorySettingsForm.Designer.cs
generated
Normal file
135
ShareX.HistoryLib/Forms/ImageHistorySettingsForm.Designer.cs
generated
Normal file
|
@ -0,0 +1,135 @@
|
||||||
|
namespace ShareX.HistoryLib
|
||||||
|
{
|
||||||
|
partial class ImageHistorySettingsForm
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Required designer variable.
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Clean up any resources being used.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region Windows Form Designer generated code
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Required method for Designer support - do not modify
|
||||||
|
/// the contents of this method with the code editor.
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(ImageHistorySettingsForm));
|
||||||
|
this.lblViewMode = new System.Windows.Forms.Label();
|
||||||
|
this.lblThumbnailSize = new System.Windows.Forms.Label();
|
||||||
|
this.lblMaximumImageLimit = new System.Windows.Forms.Label();
|
||||||
|
this.cbViewMode = new System.Windows.Forms.ComboBox();
|
||||||
|
this.nudThumbnailSize = new System.Windows.Forms.NumericUpDown();
|
||||||
|
this.nudMaximumImageLimit = new System.Windows.Forms.NumericUpDown();
|
||||||
|
this.lblThumbnailSizeUnit = new System.Windows.Forms.Label();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.nudThumbnailSize)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.nudMaximumImageLimit)).BeginInit();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// lblViewMode
|
||||||
|
//
|
||||||
|
resources.ApplyResources(this.lblViewMode, "lblViewMode");
|
||||||
|
this.lblViewMode.Name = "lblViewMode";
|
||||||
|
//
|
||||||
|
// lblThumbnailSize
|
||||||
|
//
|
||||||
|
resources.ApplyResources(this.lblThumbnailSize, "lblThumbnailSize");
|
||||||
|
this.lblThumbnailSize.Name = "lblThumbnailSize";
|
||||||
|
//
|
||||||
|
// lblMaximumImageLimit
|
||||||
|
//
|
||||||
|
resources.ApplyResources(this.lblMaximumImageLimit, "lblMaximumImageLimit");
|
||||||
|
this.lblMaximumImageLimit.Name = "lblMaximumImageLimit";
|
||||||
|
//
|
||||||
|
// cbViewMode
|
||||||
|
//
|
||||||
|
this.cbViewMode.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
|
this.cbViewMode.FormattingEnabled = true;
|
||||||
|
resources.ApplyResources(this.cbViewMode, "cbViewMode");
|
||||||
|
this.cbViewMode.Name = "cbViewMode";
|
||||||
|
this.cbViewMode.SelectedIndexChanged += new System.EventHandler(this.cbViewMode_SelectedIndexChanged);
|
||||||
|
//
|
||||||
|
// nudThumbnailSize
|
||||||
|
//
|
||||||
|
resources.ApplyResources(this.nudThumbnailSize, "nudThumbnailSize");
|
||||||
|
this.nudThumbnailSize.Maximum = new decimal(new int[] {
|
||||||
|
1000,
|
||||||
|
0,
|
||||||
|
0,
|
||||||
|
0});
|
||||||
|
this.nudThumbnailSize.Minimum = new decimal(new int[] {
|
||||||
|
50,
|
||||||
|
0,
|
||||||
|
0,
|
||||||
|
0});
|
||||||
|
this.nudThumbnailSize.Name = "nudThumbnailSize";
|
||||||
|
this.nudThumbnailSize.Value = new decimal(new int[] {
|
||||||
|
50,
|
||||||
|
0,
|
||||||
|
0,
|
||||||
|
0});
|
||||||
|
this.nudThumbnailSize.ValueChanged += new System.EventHandler(this.nudThumbnailSize_ValueChanged);
|
||||||
|
//
|
||||||
|
// nudMaximumImageLimit
|
||||||
|
//
|
||||||
|
resources.ApplyResources(this.nudMaximumImageLimit, "nudMaximumImageLimit");
|
||||||
|
this.nudMaximumImageLimit.Maximum = new decimal(new int[] {
|
||||||
|
10000,
|
||||||
|
0,
|
||||||
|
0,
|
||||||
|
0});
|
||||||
|
this.nudMaximumImageLimit.Name = "nudMaximumImageLimit";
|
||||||
|
this.nudMaximumImageLimit.ValueChanged += new System.EventHandler(this.nudMaximumImageLimit_ValueChanged);
|
||||||
|
//
|
||||||
|
// lblThumbnailSizeUnit
|
||||||
|
//
|
||||||
|
resources.ApplyResources(this.lblThumbnailSizeUnit, "lblThumbnailSizeUnit");
|
||||||
|
this.lblThumbnailSizeUnit.Name = "lblThumbnailSizeUnit";
|
||||||
|
//
|
||||||
|
// ImageHistorySettingsForm
|
||||||
|
//
|
||||||
|
resources.ApplyResources(this, "$this");
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.BackColor = System.Drawing.SystemColors.Window;
|
||||||
|
this.Controls.Add(this.lblThumbnailSizeUnit);
|
||||||
|
this.Controls.Add(this.nudMaximumImageLimit);
|
||||||
|
this.Controls.Add(this.nudThumbnailSize);
|
||||||
|
this.Controls.Add(this.cbViewMode);
|
||||||
|
this.Controls.Add(this.lblMaximumImageLimit);
|
||||||
|
this.Controls.Add(this.lblThumbnailSize);
|
||||||
|
this.Controls.Add(this.lblViewMode);
|
||||||
|
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
|
||||||
|
this.MaximizeBox = false;
|
||||||
|
this.Name = "ImageHistorySettingsForm";
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.nudThumbnailSize)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.nudMaximumImageLimit)).EndInit();
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
this.PerformLayout();
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private System.Windows.Forms.Label lblViewMode;
|
||||||
|
private System.Windows.Forms.Label lblThumbnailSize;
|
||||||
|
private System.Windows.Forms.Label lblMaximumImageLimit;
|
||||||
|
private System.Windows.Forms.ComboBox cbViewMode;
|
||||||
|
private System.Windows.Forms.NumericUpDown nudThumbnailSize;
|
||||||
|
private System.Windows.Forms.NumericUpDown nudMaximumImageLimit;
|
||||||
|
private System.Windows.Forms.Label lblThumbnailSizeUnit;
|
||||||
|
}
|
||||||
|
}
|
70
ShareX.HistoryLib/Forms/ImageHistorySettingsForm.cs
Normal file
70
ShareX.HistoryLib/Forms/ImageHistorySettingsForm.cs
Normal file
|
@ -0,0 +1,70 @@
|
||||||
|
#region License Information (GPL v3)
|
||||||
|
|
||||||
|
/*
|
||||||
|
ShareX - A program that allows you to take screenshots and share any file type
|
||||||
|
Copyright (c) 2007-2018 ShareX Team
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or
|
||||||
|
modify it under the terms of the GNU General Public License
|
||||||
|
as published by the Free Software Foundation; either version 2
|
||||||
|
of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with this program; if not, write to the Free Software
|
||||||
|
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||||
|
|
||||||
|
Optionally you can also view the license at <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#endregion License Information (GPL v3)
|
||||||
|
|
||||||
|
using ShareX.HelpersLib;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace ShareX.HistoryLib
|
||||||
|
{
|
||||||
|
public partial class ImageHistorySettingsForm : Form
|
||||||
|
{
|
||||||
|
public ImageHistorySettings Settings { get; private set; }
|
||||||
|
|
||||||
|
public ImageHistorySettingsForm(ImageHistorySettings settings)
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
Icon = ShareXResources.Icon;
|
||||||
|
|
||||||
|
Settings = settings;
|
||||||
|
cbViewMode.Items.AddRange(Enum.GetNames(typeof(Manina.Windows.Forms.View)));
|
||||||
|
cbViewMode.SelectedIndex = Settings.ViewMode;
|
||||||
|
nudThumbnailSize.SetValue(Settings.ThumbnailSize.Width);
|
||||||
|
nudMaximumImageLimit.SetValue(Settings.MaxItemCount);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void cbViewMode_SelectedIndexChanged(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
Settings.ViewMode = cbViewMode.SelectedIndex;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void nudThumbnailSize_ValueChanged(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
Settings.ThumbnailSize = new Size((int)nudThumbnailSize.Value, (int)nudThumbnailSize.Value);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void nudMaximumImageLimit_ValueChanged(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
Settings.MaxItemCount = (int)nudMaximumImageLimit.Value;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
321
ShareX.HistoryLib/Forms/ImageHistorySettingsForm.resx
Normal file
321
ShareX.HistoryLib/Forms/ImageHistorySettingsForm.resx
Normal file
|
@ -0,0 +1,321 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<assembly alias="mscorlib" name="mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||||
|
<data name="lblViewMode.AutoSize" type="System.Boolean, mscorlib">
|
||||||
|
<value>True</value>
|
||||||
|
</data>
|
||||||
|
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
||||||
|
<data name="lblViewMode.Location" type="System.Drawing.Point, System.Drawing">
|
||||||
|
<value>5, 8</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblViewMode.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
|
<value>62, 13</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblViewMode.TabIndex" type="System.Int32, mscorlib">
|
||||||
|
<value>0</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblViewMode.Text" xml:space="preserve">
|
||||||
|
<value>View mode:</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblViewMode.Name" xml:space="preserve">
|
||||||
|
<value>lblViewMode</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblViewMode.Type" xml:space="preserve">
|
||||||
|
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblViewMode.Parent" xml:space="preserve">
|
||||||
|
<value>$this</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblViewMode.ZOrder" xml:space="preserve">
|
||||||
|
<value>6</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblThumbnailSize.AutoSize" type="System.Boolean, mscorlib">
|
||||||
|
<value>True</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblThumbnailSize.Location" type="System.Drawing.Point, System.Drawing">
|
||||||
|
<value>5, 56</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblThumbnailSize.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
|
<value>80, 13</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblThumbnailSize.TabIndex" type="System.Int32, mscorlib">
|
||||||
|
<value>1</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblThumbnailSize.Text" xml:space="preserve">
|
||||||
|
<value>Thumbnail size:</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblThumbnailSize.Name" xml:space="preserve">
|
||||||
|
<value>lblThumbnailSize</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblThumbnailSize.Type" xml:space="preserve">
|
||||||
|
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblThumbnailSize.Parent" xml:space="preserve">
|
||||||
|
<value>$this</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblThumbnailSize.ZOrder" xml:space="preserve">
|
||||||
|
<value>5</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblMaximumImageLimit.AutoSize" type="System.Boolean, mscorlib">
|
||||||
|
<value>True</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblMaximumImageLimit.Location" type="System.Drawing.Point, System.Drawing">
|
||||||
|
<value>5, 104</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblMaximumImageLimit.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
|
<value>105, 13</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblMaximumImageLimit.TabIndex" type="System.Int32, mscorlib">
|
||||||
|
<value>2</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblMaximumImageLimit.Text" xml:space="preserve">
|
||||||
|
<value>Maximum image limit:</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblMaximumImageLimit.Name" xml:space="preserve">
|
||||||
|
<value>lblMaximumImageLimit</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblMaximumImageLimit.Type" xml:space="preserve">
|
||||||
|
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblMaximumImageLimit.Parent" xml:space="preserve">
|
||||||
|
<value>$this</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblMaximumImageLimit.ZOrder" xml:space="preserve">
|
||||||
|
<value>4</value>
|
||||||
|
</data>
|
||||||
|
<data name="cbViewMode.Location" type="System.Drawing.Point, System.Drawing">
|
||||||
|
<value>8, 24</value>
|
||||||
|
</data>
|
||||||
|
<data name="cbViewMode.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
|
<value>120, 21</value>
|
||||||
|
</data>
|
||||||
|
<data name="cbViewMode.TabIndex" type="System.Int32, mscorlib">
|
||||||
|
<value>3</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>cbViewMode.Name" xml:space="preserve">
|
||||||
|
<value>cbViewMode</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>cbViewMode.Type" xml:space="preserve">
|
||||||
|
<value>System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>cbViewMode.Parent" xml:space="preserve">
|
||||||
|
<value>$this</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>cbViewMode.ZOrder" xml:space="preserve">
|
||||||
|
<value>3</value>
|
||||||
|
</data>
|
||||||
|
<data name="nudThumbnailSize.Location" type="System.Drawing.Point, System.Drawing">
|
||||||
|
<value>8, 72</value>
|
||||||
|
</data>
|
||||||
|
<data name="nudThumbnailSize.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
|
<value>64, 20</value>
|
||||||
|
</data>
|
||||||
|
<data name="nudThumbnailSize.TabIndex" type="System.Int32, mscorlib">
|
||||||
|
<value>4</value>
|
||||||
|
</data>
|
||||||
|
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||||
|
<data name="nudThumbnailSize.TextAlign" type="System.Windows.Forms.HorizontalAlignment, System.Windows.Forms">
|
||||||
|
<value>Center</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>nudThumbnailSize.Name" xml:space="preserve">
|
||||||
|
<value>nudThumbnailSize</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>nudThumbnailSize.Type" xml:space="preserve">
|
||||||
|
<value>System.Windows.Forms.NumericUpDown, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>nudThumbnailSize.Parent" xml:space="preserve">
|
||||||
|
<value>$this</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>nudThumbnailSize.ZOrder" xml:space="preserve">
|
||||||
|
<value>2</value>
|
||||||
|
</data>
|
||||||
|
<data name="nudMaximumImageLimit.Location" type="System.Drawing.Point, System.Drawing">
|
||||||
|
<value>8, 120</value>
|
||||||
|
</data>
|
||||||
|
<data name="nudMaximumImageLimit.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
|
<value>64, 20</value>
|
||||||
|
</data>
|
||||||
|
<data name="nudMaximumImageLimit.TabIndex" type="System.Int32, mscorlib">
|
||||||
|
<value>5</value>
|
||||||
|
</data>
|
||||||
|
<data name="nudMaximumImageLimit.TextAlign" type="System.Windows.Forms.HorizontalAlignment, System.Windows.Forms">
|
||||||
|
<value>Center</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>nudMaximumImageLimit.Name" xml:space="preserve">
|
||||||
|
<value>nudMaximumImageLimit</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>nudMaximumImageLimit.Type" xml:space="preserve">
|
||||||
|
<value>System.Windows.Forms.NumericUpDown, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>nudMaximumImageLimit.Parent" xml:space="preserve">
|
||||||
|
<value>$this</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>nudMaximumImageLimit.ZOrder" xml:space="preserve">
|
||||||
|
<value>1</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblThumbnailSizeUnit.AutoSize" type="System.Boolean, mscorlib">
|
||||||
|
<value>True</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblThumbnailSizeUnit.Location" type="System.Drawing.Point, System.Drawing">
|
||||||
|
<value>77, 76</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblThumbnailSizeUnit.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
|
<value>18, 13</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblThumbnailSizeUnit.TabIndex" type="System.Int32, mscorlib">
|
||||||
|
<value>6</value>
|
||||||
|
</data>
|
||||||
|
<data name="lblThumbnailSizeUnit.Text" xml:space="preserve">
|
||||||
|
<value>px</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblThumbnailSizeUnit.Name" xml:space="preserve">
|
||||||
|
<value>lblThumbnailSizeUnit</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblThumbnailSizeUnit.Type" xml:space="preserve">
|
||||||
|
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblThumbnailSizeUnit.Parent" xml:space="preserve">
|
||||||
|
<value>$this</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>lblThumbnailSizeUnit.ZOrder" xml:space="preserve">
|
||||||
|
<value>0</value>
|
||||||
|
</data>
|
||||||
|
<metadata name="$this.Localizable" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<data name="$this.AutoScaleDimensions" type="System.Drawing.SizeF, System.Drawing">
|
||||||
|
<value>6, 13</value>
|
||||||
|
</data>
|
||||||
|
<data name="$this.ClientSize" type="System.Drawing.Size, System.Drawing">
|
||||||
|
<value>344, 226</value>
|
||||||
|
</data>
|
||||||
|
<data name="$this.StartPosition" type="System.Windows.Forms.FormStartPosition, System.Windows.Forms">
|
||||||
|
<value>CenterScreen</value>
|
||||||
|
</data>
|
||||||
|
<data name="$this.Text" xml:space="preserve">
|
||||||
|
<value>ShareX - Image history settings</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>$this.Name" xml:space="preserve">
|
||||||
|
<value>ImageHistorySettingsForm</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>$this.Type" xml:space="preserve">
|
||||||
|
<value>System.Windows.Forms.Form, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</data>
|
||||||
|
</root>
|
43
ShareX.HistoryLib/ImageHistorySettings.cs
Normal file
43
ShareX.HistoryLib/ImageHistorySettings.cs
Normal file
|
@ -0,0 +1,43 @@
|
||||||
|
#region License Information (GPL v3)
|
||||||
|
|
||||||
|
/*
|
||||||
|
ShareX - A program that allows you to take screenshots and share any file type
|
||||||
|
Copyright (c) 2007-2018 ShareX Team
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or
|
||||||
|
modify it under the terms of the GNU General Public License
|
||||||
|
as published by the Free Software Foundation; either version 2
|
||||||
|
of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with this program; if not, write to the Free Software
|
||||||
|
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||||
|
|
||||||
|
Optionally you can also view the license at <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#endregion License Information (GPL v3)
|
||||||
|
|
||||||
|
using ShareX.HelpersLib;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace ShareX.HistoryLib
|
||||||
|
{
|
||||||
|
public class ImageHistorySettings
|
||||||
|
{
|
||||||
|
public WindowState WindowState { get; set; } = new WindowState();
|
||||||
|
public int ViewMode { get; set; } = 3;
|
||||||
|
public Size ThumbnailSize { get; set; } = new Size(150, 150);
|
||||||
|
public int MaxItemCount { get; set; } = 250;
|
||||||
|
}
|
||||||
|
}
|
|
@ -76,6 +76,7 @@
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
|
<Reference Include="System.Data" />
|
||||||
<Reference Include="System.Drawing" />
|
<Reference Include="System.Drawing" />
|
||||||
<Reference Include="System.Windows.Forms" />
|
<Reference Include="System.Windows.Forms" />
|
||||||
<Reference Include="System.Xml.Linq" />
|
<Reference Include="System.Xml.Linq" />
|
||||||
|
@ -86,12 +87,19 @@
|
||||||
<Link>Properties\SharedAssemblyInfo.cs</Link>
|
<Link>Properties\SharedAssemblyInfo.cs</Link>
|
||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="HistoryItemManager_ContextMenu.cs" />
|
<Compile Include="HistoryItemManager_ContextMenu.cs" />
|
||||||
<Compile Include="ImageHistoryForm.cs">
|
<Compile Include="Forms\ImageHistoryForm.cs">
|
||||||
<SubType>Form</SubType>
|
<SubType>Form</SubType>
|
||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="ImageHistoryForm.Designer.cs">
|
<Compile Include="Forms\ImageHistoryForm.Designer.cs">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
<Compile Include="Forms\ImageHistorySettingsForm.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Forms\ImageHistorySettingsForm.Designer.cs">
|
||||||
|
<DependentUpon>ImageHistorySettingsForm.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="ImageHistorySettings.cs" />
|
||||||
<Compile Include="Properties\Resources.Designer.cs">
|
<Compile Include="Properties\Resources.Designer.cs">
|
||||||
<AutoGen>True</AutoGen>
|
<AutoGen>True</AutoGen>
|
||||||
<DesignTime>True</DesignTime>
|
<DesignTime>True</DesignTime>
|
||||||
|
@ -101,17 +109,17 @@
|
||||||
<SubType>Component</SubType>
|
<SubType>Component</SubType>
|
||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="Enums.cs" />
|
<Compile Include="Enums.cs" />
|
||||||
<Compile Include="HistoryForm.cs">
|
<Compile Include="Forms\HistoryForm.cs">
|
||||||
<SubType>Form</SubType>
|
<SubType>Form</SubType>
|
||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="HistoryForm.Designer.cs">
|
<Compile Include="Forms\HistoryForm.Designer.cs">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="HistoryItem.cs" />
|
<Compile Include="HistoryItem.cs" />
|
||||||
<Compile Include="HistoryItemInfoForm.cs">
|
<Compile Include="Forms\HistoryItemInfoForm.cs">
|
||||||
<SubType>Form</SubType>
|
<SubType>Form</SubType>
|
||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="HistoryItemInfoForm.Designer.cs">
|
<Compile Include="Forms\HistoryItemInfoForm.Designer.cs">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="HistoryItemManager.cs" />
|
<Compile Include="HistoryItemManager.cs" />
|
||||||
|
@ -126,141 +134,144 @@
|
||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<EmbeddedResource Include="HistoryForm.de.resx">
|
<EmbeddedResource Include="Forms\HistoryForm.de.resx">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryForm.es.resx">
|
<EmbeddedResource Include="Forms\HistoryForm.es.resx">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryForm.fr.resx">
|
<EmbeddedResource Include="Forms\HistoryForm.fr.resx">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryForm.hu.resx">
|
<EmbeddedResource Include="Forms\HistoryForm.hu.resx">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryForm.it-IT.resx">
|
<EmbeddedResource Include="Forms\HistoryForm.it-IT.resx">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryForm.ko-KR.resx">
|
<EmbeddedResource Include="Forms\HistoryForm.ko-KR.resx">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryForm.nl-NL.resx">
|
<EmbeddedResource Include="Forms\HistoryForm.nl-NL.resx">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryForm.pt-BR.resx">
|
<EmbeddedResource Include="Forms\HistoryForm.pt-BR.resx">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryForm.resx">
|
<EmbeddedResource Include="Forms\HistoryForm.resx">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryForm.ru.resx">
|
<EmbeddedResource Include="Forms\HistoryForm.ru.resx">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryForm.tr.resx">
|
<EmbeddedResource Include="Forms\HistoryForm.tr.resx">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryForm.uk.resx">
|
<EmbeddedResource Include="Forms\HistoryForm.uk.resx">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryForm.vi-VN.resx">
|
<EmbeddedResource Include="Forms\HistoryForm.vi-VN.resx">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryForm.zh-CN.resx">
|
<EmbeddedResource Include="Forms\HistoryForm.zh-CN.resx">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryForm.zh-TW.resx">
|
<EmbeddedResource Include="Forms\HistoryForm.zh-TW.resx">
|
||||||
<DependentUpon>HistoryForm.cs</DependentUpon>
|
<DependentUpon>HistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryItemInfoForm.de.resx">
|
<EmbeddedResource Include="Forms\HistoryItemInfoForm.de.resx">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryItemInfoForm.es.resx">
|
<EmbeddedResource Include="Forms\HistoryItemInfoForm.es.resx">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryItemInfoForm.fr.resx">
|
<EmbeddedResource Include="Forms\HistoryItemInfoForm.fr.resx">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryItemInfoForm.hu.resx">
|
<EmbeddedResource Include="Forms\HistoryItemInfoForm.hu.resx">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryItemInfoForm.it-IT.resx">
|
<EmbeddedResource Include="Forms\HistoryItemInfoForm.it-IT.resx">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryItemInfoForm.ko-KR.resx">
|
<EmbeddedResource Include="Forms\HistoryItemInfoForm.ko-KR.resx">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryItemInfoForm.nl-NL.resx">
|
<EmbeddedResource Include="Forms\HistoryItemInfoForm.nl-NL.resx">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryItemInfoForm.pt-BR.resx">
|
<EmbeddedResource Include="Forms\HistoryItemInfoForm.pt-BR.resx">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryItemInfoForm.resx">
|
<EmbeddedResource Include="Forms\HistoryItemInfoForm.resx">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryItemInfoForm.ru.resx">
|
<EmbeddedResource Include="Forms\HistoryItemInfoForm.ru.resx">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryItemInfoForm.tr.resx">
|
<EmbeddedResource Include="Forms\HistoryItemInfoForm.tr.resx">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryItemInfoForm.uk.resx">
|
<EmbeddedResource Include="Forms\HistoryItemInfoForm.uk.resx">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryItemInfoForm.vi-VN.resx">
|
<EmbeddedResource Include="Forms\HistoryItemInfoForm.vi-VN.resx">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryItemInfoForm.zh-CN.resx">
|
<EmbeddedResource Include="Forms\HistoryItemInfoForm.zh-CN.resx">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="HistoryItemInfoForm.zh-TW.resx">
|
<EmbeddedResource Include="Forms\HistoryItemInfoForm.zh-TW.resx">
|
||||||
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
<DependentUpon>HistoryItemInfoForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="ImageHistoryForm.de.resx">
|
<EmbeddedResource Include="Forms\ImageHistoryForm.de.resx">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="ImageHistoryForm.es.resx">
|
<EmbeddedResource Include="Forms\ImageHistoryForm.es.resx">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="ImageHistoryForm.fr.resx">
|
<EmbeddedResource Include="Forms\ImageHistoryForm.fr.resx">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="ImageHistoryForm.hu.resx">
|
<EmbeddedResource Include="Forms\ImageHistoryForm.hu.resx">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="ImageHistoryForm.it-IT.resx">
|
<EmbeddedResource Include="Forms\ImageHistoryForm.it-IT.resx">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="ImageHistoryForm.ko-KR.resx">
|
<EmbeddedResource Include="Forms\ImageHistoryForm.ko-KR.resx">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="ImageHistoryForm.nl-NL.resx">
|
<EmbeddedResource Include="Forms\ImageHistoryForm.nl-NL.resx">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="ImageHistoryForm.pt-BR.resx">
|
<EmbeddedResource Include="Forms\ImageHistoryForm.pt-BR.resx">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="ImageHistoryForm.resx">
|
<EmbeddedResource Include="Forms\ImageHistoryForm.resx">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="ImageHistoryForm.ru.resx">
|
<EmbeddedResource Include="Forms\ImageHistoryForm.ru.resx">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="ImageHistoryForm.tr.resx">
|
<EmbeddedResource Include="Forms\ImageHistoryForm.tr.resx">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="ImageHistoryForm.uk.resx">
|
<EmbeddedResource Include="Forms\ImageHistoryForm.uk.resx">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="ImageHistoryForm.vi-VN.resx">
|
<EmbeddedResource Include="Forms\ImageHistoryForm.vi-VN.resx">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="ImageHistoryForm.zh-CN.resx">
|
<EmbeddedResource Include="Forms\ImageHistoryForm.zh-CN.resx">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="ImageHistoryForm.zh-TW.resx">
|
<EmbeddedResource Include="Forms\ImageHistoryForm.zh-TW.resx">
|
||||||
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
<DependentUpon>ImageHistoryForm.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="Forms\ImageHistorySettingsForm.resx">
|
||||||
|
<DependentUpon>ImageHistorySettingsForm.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="Properties\Resources.de.resx" />
|
<EmbeddedResource Include="Properties\Resources.de.resx" />
|
||||||
<EmbeddedResource Include="Properties\Resources.es.resx" />
|
<EmbeddedResource Include="Properties\Resources.es.resx" />
|
||||||
<EmbeddedResource Include="Properties\Resources.fr.resx" />
|
<EmbeddedResource Include="Properties\Resources.fr.resx" />
|
||||||
|
|
|
@ -24,6 +24,7 @@ You should have received a copy of the GNU General Public License
|
||||||
#endregion License Information (GPL v3)
|
#endregion License Information (GPL v3)
|
||||||
|
|
||||||
using ShareX.HelpersLib;
|
using ShareX.HelpersLib;
|
||||||
|
using ShareX.HistoryLib;
|
||||||
using ShareX.ScreenCaptureLib;
|
using ShareX.ScreenCaptureLib;
|
||||||
using ShareX.UploadersLib;
|
using ShareX.UploadersLib;
|
||||||
using ShareX.UploadersLib.OtherServices;
|
using ShareX.UploadersLib.OtherServices;
|
||||||
|
@ -126,9 +127,7 @@ public ApplicationConfig()
|
||||||
public int HistoryMaxItemCount = 0;
|
public int HistoryMaxItemCount = 0;
|
||||||
public int HistorySplitterDistance = 550;
|
public int HistorySplitterDistance = 550;
|
||||||
|
|
||||||
public WindowState ImageHistoryWindowState = new WindowState();
|
public ImageHistorySettings ImageHistorySettings = new ImageHistorySettings();
|
||||||
public int ImageHistoryViewMode = 3;
|
|
||||||
public Size ImageHistoryThumbnailSize = new Size(150, 150);
|
|
||||||
|
|
||||||
#endregion History
|
#endregion History
|
||||||
|
|
||||||
|
|
|
@ -723,14 +723,8 @@ public static void OpenHistory()
|
||||||
|
|
||||||
public static void OpenImageHistory()
|
public static void OpenImageHistory()
|
||||||
{
|
{
|
||||||
ImageHistoryForm imageHistoryForm = new ImageHistoryForm(Program.HistoryFilePath, Program.Settings.ImageHistoryViewMode, Program.Settings.ImageHistoryThumbnailSize,
|
ImageHistoryForm imageHistoryForm = new ImageHistoryForm(Program.HistoryFilePath, Program.Settings.ImageHistorySettings,
|
||||||
filePath => UploadManager.UploadFile(filePath), filePath => AnnotateImageFromFile(filePath));
|
filePath => UploadManager.UploadFile(filePath), filePath => AnnotateImageFromFile(filePath));
|
||||||
Program.Settings.ImageHistoryWindowState.AutoHandleFormState(imageHistoryForm);
|
|
||||||
imageHistoryForm.FormClosed += (sender, e) =>
|
|
||||||
{
|
|
||||||
Program.Settings.ImageHistoryViewMode = imageHistoryForm.ViewMode;
|
|
||||||
Program.Settings.ImageHistoryThumbnailSize = imageHistoryForm.ThumbnailSize;
|
|
||||||
};
|
|
||||||
imageHistoryForm.Show();
|
imageHistoryForm.Show();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue