Changed to upgrade nupkg
This commit is contained in:
parent
dd2579e892
commit
bcac951ab4
@ -14,7 +14,7 @@
|
||||
<Copyright>Ray Lam</Copyright>
|
||||
<AssemblyVersion>1.0.0.0</AssemblyVersion>
|
||||
<FileVersion>1.0.0.0</FileVersion>
|
||||
<Version>0.7.0.255</Version>
|
||||
<Version>0.7.0.272</Version>
|
||||
<PackageId>bukkubuddy</PackageId>
|
||||
<RunAnalyzersDuringLiveAnalysis>True</RunAnalyzersDuringLiveAnalysis>
|
||||
<SupportedOSPlatformVersion>8.0</SupportedOSPlatformVersion>
|
||||
@ -149,8 +149,9 @@
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="HtmlAgilityPack" Version="1.12.4" />
|
||||
<PackageReference Include="RyzStudio" Version="10.1.0.128" />
|
||||
<PackageReference Include="RyzStudio.Windows.Forms" Version="10.1.0.140" />
|
||||
<PackageReference Include="RyzStudio" Version="10.1.1.261" />
|
||||
<PackageReference Include="RyzStudio.Windows.Forms" Version="10.3.0.97" />
|
||||
<PackageReference Include="RyzStudio.Windows.Forms.Themed" Version="10.3.0.72" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
@ -14,8 +14,8 @@ namespace BukkuBuddy.Forms
|
||||
{
|
||||
private Label label1;
|
||||
private RyzStudio.Windows.ThemedForms.Composite.DialogFooter dialogFooter1;
|
||||
private ThToolbarMemoBox memoBox1;
|
||||
private ThUserControl userControl1;
|
||||
private RyzStudio.Windows.ThemedForms.T3MemoBox memoBox1;
|
||||
private RyzStudio.Windows.ThemedForms.T3UserControl userControl1;
|
||||
private TProgressBar progressBar1;
|
||||
|
||||
private readonly WebPageService _webPageService;
|
||||
@ -29,7 +29,7 @@ namespace BukkuBuddy.Forms
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
UISetup.Dialog(this);
|
||||
this.SetupDialog();
|
||||
|
||||
_webPageService = new WebPageService(options.AllowUnsafeSSL, options.Timeout, options.AllowCookies, options.AllowRedirects);
|
||||
_rootPath = rootPath;
|
||||
@ -39,8 +39,8 @@ namespace BukkuBuddy.Forms
|
||||
{
|
||||
label1 = new Label();
|
||||
dialogFooter1 = new RyzStudio.Windows.ThemedForms.Composite.DialogFooter();
|
||||
memoBox1 = new ThToolbarMemoBox();
|
||||
userControl1 = new ThUserControl();
|
||||
memoBox1 = new T3MemoBox();
|
||||
userControl1 = new T3UserControl();
|
||||
progressBar1 = new TProgressBar();
|
||||
userControl1.SuspendLayout();
|
||||
SuspendLayout();
|
||||
@ -171,7 +171,7 @@ namespace BukkuBuddy.Forms
|
||||
{
|
||||
isBusy = value;
|
||||
|
||||
UIControl.SetEnable(memoBox1, !isBusy);
|
||||
UIControl.Invoke(memoBox1, (_) => memoBox1.Enabled = !isBusy);
|
||||
|
||||
dialogFooter1.IsBusy = isBusy;
|
||||
}
|
||||
|
||||
@ -4,14 +4,13 @@ using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
using BukkuBuddy.DTOs.SaveFile;
|
||||
using RyzStudio.Windows.Forms;
|
||||
using static System.Windows.Forms.VisualStyles.VisualStyleElement;
|
||||
|
||||
namespace BukkuBuddy.Forms
|
||||
{
|
||||
public class ClearIconsForm : Form
|
||||
{
|
||||
private TProgressBar progressBar1;
|
||||
private RyzStudio.Windows.ThemedForms.ThUserControl userControl1;
|
||||
private RyzStudio.Windows.ThemedForms.T3UserControl userControl1;
|
||||
private Label label1;
|
||||
private Label label2;
|
||||
|
||||
@ -22,7 +21,7 @@ namespace BukkuBuddy.Forms
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
UISetup.Dialog(this, true);
|
||||
this.SetupDialog();
|
||||
|
||||
this.Text = "Deleting Icons";
|
||||
|
||||
@ -33,7 +32,7 @@ namespace BukkuBuddy.Forms
|
||||
private void InitializeComponent()
|
||||
{
|
||||
progressBar1 = new TProgressBar();
|
||||
userControl1 = new RyzStudio.Windows.ThemedForms.ThUserControl();
|
||||
userControl1 = new RyzStudio.Windows.ThemedForms.T3UserControl();
|
||||
label1 = new Label();
|
||||
label2 = new Label();
|
||||
userControl1.SuspendLayout();
|
||||
@ -110,12 +109,12 @@ namespace BukkuBuddy.Forms
|
||||
progressBar1.Maximum = model.Count;
|
||||
progressBar1.Value = 0;
|
||||
|
||||
UIControl.SetText(label1, "Deleting...");
|
||||
UIControl.SetText(label2, "");
|
||||
UIControl.Invoke(label1, (_) => label1.Text = "Deleting...");
|
||||
UIControl.Invoke(label2, (_) => label2.Text = "");
|
||||
|
||||
foreach (var item in model)
|
||||
{
|
||||
UIControl.SetText(label2, "... " + item.Value.Title);
|
||||
UIControl.Invoke(label2, (_) => label2.Text = "... " + item.Value.Title);
|
||||
|
||||
progressBar1.Value++;
|
||||
|
||||
@ -132,8 +131,8 @@ namespace BukkuBuddy.Forms
|
||||
|
||||
_treeView.Clear(false, true);
|
||||
|
||||
UIControl.SetText(label1, "");
|
||||
UIControl.SetText(label2, "Done");
|
||||
UIControl.Invoke(label1, (_) => label1.Text = "");
|
||||
UIControl.Invoke(label2, (_) => label2.Text = "Done");
|
||||
});
|
||||
|
||||
this.DialogResult = DialogResult.OK;
|
||||
@ -151,8 +150,8 @@ namespace BukkuBuddy.Forms
|
||||
|
||||
public void Clear()
|
||||
{
|
||||
UIControl.SetText(label1, "Ready");
|
||||
UIControl.SetText(label2, "");
|
||||
UIControl.Invoke(label1, (_) => label1.Text = "Ready");
|
||||
UIControl.Invoke(label2, (_) => label2.Text = "");
|
||||
|
||||
progressBar1.Value = progressBar1.Maximum = 0;
|
||||
}
|
||||
|
||||
@ -8,22 +8,21 @@ using BukkuBuddy.Services;
|
||||
using RyzStudio;
|
||||
using RyzStudio.Windows.Forms;
|
||||
using RyzStudio.Windows.ThemedForms;
|
||||
using RyzStudio.Windows.ThemedForms.ButtonTextBox;
|
||||
|
||||
namespace BukkuBuddy.Forms
|
||||
{
|
||||
public class EditBookmarkForm : Form
|
||||
{
|
||||
private Label label1;
|
||||
private ThClearableTextBox textBox1;
|
||||
private RyzStudio.Windows.FontForms.TextBox.T4ClearTextBox textBox1;
|
||||
private Label label2;
|
||||
private Label label3;
|
||||
private ThToolbarMemoBox memoBox1;
|
||||
private RyzStudio.Windows.ThemedForms.T3MemoBox memoBox1;
|
||||
private Label label4;
|
||||
private ThIconButtonTextBox textBox2;
|
||||
private RyzStudio.Windows.ThemedForms.T4TextBox textBox2;
|
||||
private PictureBox pictureBox1;
|
||||
private System.ComponentModel.IContainer components;
|
||||
private ThClearableTextBox textBox3;
|
||||
private RyzStudio.Windows.FontForms.TextBox.T4ClearTextBox textBox3;
|
||||
private RyzStudio.Windows.ThemedForms.Composite.DialogFooter dialogFooter1;
|
||||
private THorizontalSeparator horizontalSeparator1;
|
||||
|
||||
@ -37,7 +36,7 @@ namespace BukkuBuddy.Forms
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
UISetup.Dialog(this);
|
||||
this.SetupDialog();
|
||||
|
||||
this.Text = (result == null) ? "Add Bookmark" : "Edit Bookmark";
|
||||
|
||||
@ -50,14 +49,14 @@ namespace BukkuBuddy.Forms
|
||||
{
|
||||
components = new Container();
|
||||
label1 = new Label();
|
||||
textBox1 = new ThClearableTextBox();
|
||||
textBox1 = new RyzStudio.Windows.FontForms.TextBox.T4ClearTextBox();
|
||||
label2 = new Label();
|
||||
label3 = new Label();
|
||||
memoBox1 = new ThToolbarMemoBox();
|
||||
memoBox1 = new T3MemoBox();
|
||||
label4 = new Label();
|
||||
textBox2 = new ThIconButtonTextBox();
|
||||
textBox2 = new RyzStudio.Windows.ThemedForms.T4TextBox();
|
||||
pictureBox1 = new PictureBox();
|
||||
textBox3 = new ThClearableTextBox();
|
||||
textBox3 = new RyzStudio.Windows.FontForms.TextBox.T4ClearTextBox();
|
||||
dialogFooter1 = new RyzStudio.Windows.ThemedForms.Composite.DialogFooter();
|
||||
horizontalSeparator1 = new THorizontalSeparator();
|
||||
((ISupportInitialize)pictureBox1).BeginInit();
|
||||
@ -161,7 +160,6 @@ namespace BukkuBuddy.Forms
|
||||
textBox2.Size = new Size(260, 32);
|
||||
textBox2.TabIndex = 1;
|
||||
textBox2.TabStop = false;
|
||||
textBox2.UseSystemPasswordChar = false;
|
||||
textBox2.OnButtonClick += textBox2_OnButtonClick;
|
||||
//
|
||||
// pictureBox1
|
||||
@ -316,10 +314,12 @@ namespace BukkuBuddy.Forms
|
||||
{
|
||||
isBusy = value;
|
||||
|
||||
UIControl.SetEnable(textBox1, !isBusy);
|
||||
UIControl.SetEnable(textBox2, !isBusy);
|
||||
UIControl.SetEnable(textBox3, !isBusy);
|
||||
UIControl.SetEnable(memoBox1, !isBusy);
|
||||
|
||||
UIControl.Invoke(textBox1, (_) => textBox1.Enabled = !isBusy);
|
||||
UIControl.Invoke(textBox2, (_) => textBox2.Enabled = !isBusy);
|
||||
UIControl.Invoke(textBox3, (_) => textBox3.Enabled = !isBusy);
|
||||
UIControl.Invoke(memoBox1, (_) => memoBox1.Enabled = !isBusy);
|
||||
|
||||
dialogFooter1.IsBusy = isBusy;
|
||||
}
|
||||
}
|
||||
@ -359,7 +359,7 @@ namespace BukkuBuddy.Forms
|
||||
|
||||
var image = await GetFavicon(textBox2.Text);
|
||||
|
||||
UIControl.SetImage(pictureBox1, image);
|
||||
UIControl.Invoke(pictureBox1, (_) => pictureBox1.Image = image);
|
||||
|
||||
this.IsBusy = false;
|
||||
});
|
||||
@ -487,8 +487,8 @@ namespace BukkuBuddy.Forms
|
||||
var title = _webPageService.ParseTitle(htmlDocument) ?? string.Empty;
|
||||
var description = _webPageService.ParseDescription(htmlDocument) ?? string.Empty;
|
||||
|
||||
UIControl.SetText(textBox1, title);
|
||||
UIControl.SetText(textBox3, description);
|
||||
UIControl.Invoke(textBox1, (_) => textBox1.Text = title);
|
||||
UIControl.Invoke(textBox3, (_) => textBox3.Text = description);
|
||||
|
||||
var faviconUrl = _webPageService.ParseFavicon(htmlDocument);
|
||||
if (!string.IsNullOrWhiteSpace(faviconUrl))
|
||||
@ -502,7 +502,7 @@ namespace BukkuBuddy.Forms
|
||||
}
|
||||
}
|
||||
|
||||
UIControl.SetImage(pictureBox1, favicon);
|
||||
UIControl.Invoke(pictureBox1, (_) => pictureBox1.Image = favicon);
|
||||
}
|
||||
|
||||
return MethodResult.Create();
|
||||
|
||||
@ -5,17 +5,16 @@ using System.Windows.Forms;
|
||||
using BukkuBuddy.DTOs.SaveFile;
|
||||
using RyzStudio.Windows.Forms;
|
||||
using RyzStudio.Windows.ThemedForms;
|
||||
using RyzStudio.Windows.ThemedForms.ButtonTextBox;
|
||||
|
||||
namespace BukkuBuddy.Forms
|
||||
{
|
||||
public class FindForm : Form
|
||||
{
|
||||
private Label label1;
|
||||
private ThButton button2;
|
||||
private RyzStudio.Windows.ThemedForms.T3Button button2;
|
||||
private THorizontalSeparator horizontalSeparator1;
|
||||
private ThButton button1;
|
||||
private ThClearableTextBox textBox1;
|
||||
private RyzStudio.Windows.ThemedForms.T3Button button1;
|
||||
private RyzStudio.Windows.FontForms.TextBox.T4ClearTextBox textBox1;
|
||||
|
||||
|
||||
private BookmarkTreeView treeView1 = null;
|
||||
@ -39,10 +38,10 @@ namespace BukkuBuddy.Forms
|
||||
private void InitializeComponent()
|
||||
{
|
||||
label1 = new Label();
|
||||
button2 = new ThButton();
|
||||
button2 = new T3Button();
|
||||
horizontalSeparator1 = new THorizontalSeparator();
|
||||
textBox1 = new ThClearableTextBox();
|
||||
button1 = new ThButton();
|
||||
textBox1 = new RyzStudio.Windows.FontForms.TextBox.T4ClearTextBox();
|
||||
button1 = new T3Button();
|
||||
SuspendLayout();
|
||||
//
|
||||
// label1
|
||||
@ -61,13 +60,10 @@ namespace BukkuBuddy.Forms
|
||||
//
|
||||
// button2
|
||||
//
|
||||
button2.ActiveImage = null;
|
||||
button2.Anchor = AnchorStyles.Bottom | AnchorStyles.Right;
|
||||
button2.BackColor = System.Drawing.Color.Transparent;
|
||||
button2.EnableMenuOnClick = false;
|
||||
button2.EnableMovable = false;
|
||||
button2.HoverImage = null;
|
||||
button2.IdleImage = null;
|
||||
//
|
||||
//
|
||||
//
|
||||
|
||||
@ -14,8 +14,8 @@ namespace BukkuBuddy.Forms
|
||||
public class LoadingForm : Form
|
||||
{
|
||||
private TProgressBar progressBar1;
|
||||
private RyzStudio.Windows.ThemedForms.ThUserControl userControl1;
|
||||
private RyzStudio.Windows.ThemedForms.ThUserControl userControl2;
|
||||
private RyzStudio.Windows.ThemedForms.T3UserControl userControl1;
|
||||
private RyzStudio.Windows.ThemedForms.T3UserControl userControl2;
|
||||
private TProgressBar progressBar2;
|
||||
private Label label1;
|
||||
private Label label2;
|
||||
@ -30,7 +30,7 @@ namespace BukkuBuddy.Forms
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
UISetup.Dialog(this, true);
|
||||
this.SetupDialog();
|
||||
|
||||
this.Text = "Loading";
|
||||
}
|
||||
@ -39,8 +39,8 @@ namespace BukkuBuddy.Forms
|
||||
private void InitializeComponent()
|
||||
{
|
||||
progressBar1 = new TProgressBar();
|
||||
userControl1 = new RyzStudio.Windows.ThemedForms.ThUserControl();
|
||||
userControl2 = new RyzStudio.Windows.ThemedForms.ThUserControl();
|
||||
userControl1 = new RyzStudio.Windows.ThemedForms.T3UserControl();
|
||||
userControl2 = new RyzStudio.Windows.ThemedForms.T3UserControl();
|
||||
progressBar2 = new TProgressBar();
|
||||
label1 = new Label();
|
||||
label2 = new Label();
|
||||
@ -141,8 +141,8 @@ namespace BukkuBuddy.Forms
|
||||
{
|
||||
this.Clear();
|
||||
|
||||
UIControl.SetText(label1, "Loading...");
|
||||
UIControl.SetText(label2, "... " + Path.GetFileName(loadFilename));
|
||||
UIControl.Invoke(label1, (_) => label1.Text = "Loading...");
|
||||
UIControl.Invoke(label2, (_) => label2.Text = "... " + Path.GetFileName(loadFilename));
|
||||
|
||||
var newSession = await LoadSaveSessionWithVersion(loadFilename);
|
||||
var isPack = Path.GetExtension(loadFilename).Equals(".jsnx", StringComparison.CurrentCultureIgnoreCase);
|
||||
@ -153,8 +153,8 @@ namespace BukkuBuddy.Forms
|
||||
progressBar1.Value = 0;
|
||||
progressBar2.Value = 0;
|
||||
|
||||
UIControl.SetText(label1, "Loading...");
|
||||
UIControl.SetText(label2, "");
|
||||
UIControl.Invoke(label1, (_) => label1.Text = "Loading...");
|
||||
UIControl.Invoke(label2, (_) => label2.Text = "");
|
||||
|
||||
foreach (var item in newSession?.Directories ?? new List<string>())
|
||||
{
|
||||
@ -163,7 +163,7 @@ namespace BukkuBuddy.Forms
|
||||
continue;
|
||||
}
|
||||
|
||||
UIControl.SetText(label2, "... " + Path.GetFileNameWithoutExtension(item));
|
||||
UIControl.Invoke(label2, (_) => label2.Text = "... " + Path.GetFileNameWithoutExtension(item));
|
||||
|
||||
progressBar1.Value++;
|
||||
|
||||
@ -172,7 +172,7 @@ namespace BukkuBuddy.Forms
|
||||
|
||||
foreach (var item in newSession?.Items ?? new List<App6Options.Item>())
|
||||
{
|
||||
UIControl.SetText(label2, "... " + item.Title);
|
||||
UIControl.Invoke(label2, (_) => label2.Text = "... " + item.Title);
|
||||
|
||||
progressBar2.Value++;
|
||||
|
||||
@ -197,8 +197,8 @@ namespace BukkuBuddy.Forms
|
||||
|
||||
result = newSession;
|
||||
|
||||
UIControl.SetText(label1, "");
|
||||
UIControl.SetText(label2, "Done");
|
||||
UIControl.Invoke(label1, (_) => label1.Text = "");
|
||||
UIControl.Invoke(label2, (_) => label2.Text = "Done");
|
||||
});
|
||||
|
||||
this.DialogResult = DialogResult.OK;
|
||||
@ -230,8 +230,8 @@ namespace BukkuBuddy.Forms
|
||||
|
||||
public void Clear()
|
||||
{
|
||||
UIControl.SetText(label1, "Ready");
|
||||
UIControl.SetText(label2, "");
|
||||
UIControl.Invoke(label1, (_) => label1.Text = "Ready");
|
||||
UIControl.Invoke(label2, (_) => label2.Text = "");
|
||||
|
||||
progressBar1.Value = progressBar1.Maximum = 0;
|
||||
progressBar2.Value = progressBar2.Maximum = 0;
|
||||
|
||||
@ -2,31 +2,30 @@
|
||||
using System.Windows.Forms;
|
||||
using BukkuBuddy.DTOs.SaveFile;
|
||||
using RyzStudio.Windows.Forms;
|
||||
using RyzStudio.Windows.ThemedForms.PickerBox;
|
||||
|
||||
namespace BukkuBuddy.Forms
|
||||
{
|
||||
public class OptionsForm : Form
|
||||
{
|
||||
private ThYesNoPickerBox pickerBox1;
|
||||
private RyzStudio.Windows.ThemedForms.T3YnPickerBox pickerBox1;
|
||||
private Label label2;
|
||||
private Label label1;
|
||||
private ThYesNoPickerBox pickerBox2;
|
||||
private RyzStudio.Windows.ThemedForms.T3YnPickerBox pickerBox2;
|
||||
private Label label3;
|
||||
private RyzStudio.Windows.ThemedForms.ButtonTextBox.ThClearableTextBox textBox1;
|
||||
private RyzStudio.Windows.FontForms.TextBox.T4ClearTextBox textBox1;
|
||||
private RyzStudio.Windows.ThemedForms.Composite.DialogFooter dialogFooter1;
|
||||
private FlowLayoutPanel flowLayoutPanel1;
|
||||
private TTogglePanel togglePanel1;
|
||||
private TTogglePanel togglePanel2;
|
||||
private Label label4;
|
||||
private ThYesNoPickerBox pickerBox3;
|
||||
private RyzStudio.Windows.ThemedForms.T3YnPickerBox pickerBox3;
|
||||
private TTogglePanel togglePanel3;
|
||||
private Label label5;
|
||||
private RyzStudio.Windows.ThemedForms.ThNumericBox numericBox1;
|
||||
private RyzStudio.Windows.ThemedForms.T4NumericBox numericBox1;
|
||||
private Label label6;
|
||||
private ThYesNoPickerBox pickerBox4;
|
||||
private RyzStudio.Windows.ThemedForms.T3YnPickerBox pickerBox4;
|
||||
private Label label7;
|
||||
private ThYesNoPickerBox pickerBox5;
|
||||
private RyzStudio.Windows.ThemedForms.T3YnPickerBox pickerBox5;
|
||||
private App6Options _appSession = null;
|
||||
|
||||
|
||||
@ -34,8 +33,8 @@ namespace BukkuBuddy.Forms
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
UISetup.Dialog(this, true);
|
||||
UISetup.AutoSizeChildren(flowLayoutPanel1);
|
||||
this.SetupDialog();
|
||||
flowLayoutPanel1.AutoSizeChildren();
|
||||
|
||||
_appSession = appSession;
|
||||
}
|
||||
@ -56,11 +55,11 @@ namespace BukkuBuddy.Forms
|
||||
|
||||
private void InitializeComponent()
|
||||
{
|
||||
pickerBox1 = new ThYesNoPickerBox();
|
||||
pickerBox1 = new RyzStudio.Windows.ThemedForms.T3YnPickerBox();
|
||||
label2 = new Label();
|
||||
pickerBox2 = new ThYesNoPickerBox();
|
||||
pickerBox2 = new RyzStudio.Windows.ThemedForms.T3YnPickerBox();
|
||||
label1 = new Label();
|
||||
textBox1 = new RyzStudio.Windows.ThemedForms.ButtonTextBox.ThClearableTextBox();
|
||||
textBox1 = new RyzStudio.Windows.FontForms.TextBox.T4ClearTextBox();
|
||||
label3 = new Label();
|
||||
dialogFooter1 = new RyzStudio.Windows.ThemedForms.Composite.DialogFooter();
|
||||
flowLayoutPanel1 = new FlowLayoutPanel();
|
||||
@ -68,13 +67,13 @@ namespace BukkuBuddy.Forms
|
||||
togglePanel2 = new TTogglePanel();
|
||||
togglePanel3 = new TTogglePanel();
|
||||
label6 = new Label();
|
||||
pickerBox4 = new ThYesNoPickerBox();
|
||||
numericBox1 = new RyzStudio.Windows.ThemedForms.ThNumericBox();
|
||||
pickerBox4 = new RyzStudio.Windows.ThemedForms.T3YnPickerBox();
|
||||
numericBox1 = new RyzStudio.Windows.ThemedForms.T4NumericBox();
|
||||
label4 = new Label();
|
||||
label5 = new Label();
|
||||
pickerBox3 = new ThYesNoPickerBox();
|
||||
pickerBox3 = new RyzStudio.Windows.ThemedForms.T3YnPickerBox();
|
||||
label7 = new Label();
|
||||
pickerBox5 = new ThYesNoPickerBox();
|
||||
pickerBox5 = new RyzStudio.Windows.ThemedForms.T3YnPickerBox();
|
||||
flowLayoutPanel1.SuspendLayout();
|
||||
togglePanel1.SuspendLayout();
|
||||
togglePanel2.SuspendLayout();
|
||||
|
||||
@ -13,7 +13,7 @@ namespace BukkuBuddy.Forms
|
||||
public class UpdateIconsForm : Form
|
||||
{
|
||||
private TProgressBar progressBar1;
|
||||
private RyzStudio.Windows.ThemedForms.ThUserControl userControl1;
|
||||
private RyzStudio.Windows.ThemedForms.T3UserControl userControl1;
|
||||
private Label label1;
|
||||
private Label label2;
|
||||
|
||||
@ -29,7 +29,7 @@ namespace BukkuBuddy.Forms
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
UISetup.Dialog(this, true);
|
||||
this.SetupDialog();
|
||||
|
||||
this.Text = "Updating Icons";
|
||||
|
||||
@ -43,7 +43,7 @@ namespace BukkuBuddy.Forms
|
||||
private void InitializeComponent()
|
||||
{
|
||||
progressBar1 = new TProgressBar();
|
||||
userControl1 = new RyzStudio.Windows.ThemedForms.ThUserControl();
|
||||
userControl1 = new RyzStudio.Windows.ThemedForms.T3UserControl();
|
||||
label1 = new Label();
|
||||
label2 = new Label();
|
||||
userControl1.SuspendLayout();
|
||||
@ -126,8 +126,8 @@ namespace BukkuBuddy.Forms
|
||||
progressBar1.Maximum = model.Count;
|
||||
progressBar1.Value = 0;
|
||||
|
||||
UIControl.SetText(label1, "Updating...");
|
||||
UIControl.SetText(label2, "");
|
||||
UIControl.Invoke(label1, (_) => label1.Text = "Updating...");
|
||||
UIControl.Invoke(label2, (_) => label2.Text = "");
|
||||
|
||||
foreach (var item in model)
|
||||
{
|
||||
@ -136,7 +136,7 @@ namespace BukkuBuddy.Forms
|
||||
break;
|
||||
}
|
||||
|
||||
UIControl.SetText(label2, "... " + item.Value.Title);
|
||||
UIControl.Invoke(label2, (_) => label2.Text = "... " + item.Value.Title);
|
||||
|
||||
progressBar1.Value++;
|
||||
|
||||
@ -190,8 +190,8 @@ namespace BukkuBuddy.Forms
|
||||
_treeView.UpdateNode(item.Key, newModel);
|
||||
}
|
||||
|
||||
UIControl.SetText(label1, "");
|
||||
UIControl.SetText(label2, "Done");
|
||||
UIControl.Invoke(label1, (_) => label1.Text = "");
|
||||
UIControl.Invoke(label2, (_) => label2.Text = "Done");
|
||||
});
|
||||
|
||||
this.DialogResult = DialogResult.OK;
|
||||
@ -207,7 +207,7 @@ namespace BukkuBuddy.Forms
|
||||
|
||||
if (!cancelRequested)
|
||||
{
|
||||
UIControl.SetText(label1, "Cancelling...");
|
||||
UIControl.Invoke(label1, (_) => label1.Text = "Cancelling...");
|
||||
|
||||
cancelRequested = true;
|
||||
}
|
||||
@ -217,8 +217,8 @@ namespace BukkuBuddy.Forms
|
||||
|
||||
public void Clear()
|
||||
{
|
||||
UIControl.SetText(label1, "Ready");
|
||||
UIControl.SetText(label2, "");
|
||||
UIControl.Invoke(label1, (_) => label1.Text = "Ready");
|
||||
UIControl.Invoke(label2, (_) => label2.Text = "");
|
||||
|
||||
progressBar1.Value = progressBar1.Maximum = 0;
|
||||
}
|
||||
|
||||
67
source/MainForm.Designer.cs
generated
67
source/MainForm.Designer.cs
generated
@ -56,7 +56,9 @@ namespace BukkuBuddy
|
||||
alwaysOnTopToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
toolsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
toolStripMenuItem12 = new System.Windows.Forms.ToolStripMenuItem();
|
||||
toolStripMenuItem9 = new System.Windows.Forms.ToolStripMenuItem();
|
||||
updateAllToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
toolStripSeparator3 = new System.Windows.Forms.ToolStripSeparator();
|
||||
clearToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
toolStripSeparator2 = new System.Windows.Forms.ToolStripSeparator();
|
||||
optionsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
@ -95,8 +97,6 @@ namespace BukkuBuddy
|
||||
moveUpToolStripMenuItem1 = new System.Windows.Forms.ToolStripMenuItem();
|
||||
moveDownToolStripMenuItem1 = new System.Windows.Forms.ToolStripMenuItem();
|
||||
treeView1 = new RyzStudio.Windows.Forms.BookmarkTreeView();
|
||||
toolStripMenuItem9 = new System.Windows.Forms.ToolStripMenuItem();
|
||||
toolStripSeparator3 = new System.Windows.Forms.ToolStripSeparator();
|
||||
menuStrip1.SuspendLayout();
|
||||
rootContextMenu.SuspendLayout();
|
||||
folderContextMenu.SuspendLayout();
|
||||
@ -129,7 +129,7 @@ namespace BukkuBuddy
|
||||
//
|
||||
newToolStripMenuItem.Name = "newToolStripMenuItem";
|
||||
newToolStripMenuItem.ShortcutKeys = System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.N;
|
||||
newToolStripMenuItem.Size = new System.Drawing.Size(146, 22);
|
||||
newToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
|
||||
newToolStripMenuItem.Text = "&New";
|
||||
newToolStripMenuItem.Click += newToolStripMenuItem_Click;
|
||||
//
|
||||
@ -138,52 +138,52 @@ namespace BukkuBuddy
|
||||
openToolStripMenuItem.Image = MainMenuResource.folder_minus;
|
||||
openToolStripMenuItem.Name = "openToolStripMenuItem";
|
||||
openToolStripMenuItem.ShortcutKeys = System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.O;
|
||||
openToolStripMenuItem.Size = new System.Drawing.Size(146, 22);
|
||||
openToolStripMenuItem.Text = "&Open";
|
||||
openToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
|
||||
openToolStripMenuItem.Text = "&Open...";
|
||||
openToolStripMenuItem.Click += openToolStripMenuItem_Click;
|
||||
//
|
||||
// toolStripMenuItem13
|
||||
//
|
||||
toolStripMenuItem13.Name = "toolStripMenuItem13";
|
||||
toolStripMenuItem13.Size = new System.Drawing.Size(143, 6);
|
||||
toolStripMenuItem13.Size = new System.Drawing.Size(177, 6);
|
||||
//
|
||||
// closeToolStripMenuItem
|
||||
//
|
||||
closeToolStripMenuItem.Name = "closeToolStripMenuItem";
|
||||
closeToolStripMenuItem.Size = new System.Drawing.Size(146, 22);
|
||||
closeToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
|
||||
closeToolStripMenuItem.Text = "&Close";
|
||||
closeToolStripMenuItem.Click += closeToolStripMenuItem_Click;
|
||||
//
|
||||
// toolStripMenuItem14
|
||||
//
|
||||
toolStripMenuItem14.Name = "toolStripMenuItem14";
|
||||
toolStripMenuItem14.Size = new System.Drawing.Size(143, 6);
|
||||
toolStripMenuItem14.Size = new System.Drawing.Size(177, 6);
|
||||
//
|
||||
// saveToolStripMenuItem
|
||||
//
|
||||
saveToolStripMenuItem.Image = MainMenuResource.save;
|
||||
saveToolStripMenuItem.Name = "saveToolStripMenuItem";
|
||||
saveToolStripMenuItem.ShortcutKeys = System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.S;
|
||||
saveToolStripMenuItem.Size = new System.Drawing.Size(146, 22);
|
||||
saveToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
|
||||
saveToolStripMenuItem.Text = "&Save";
|
||||
saveToolStripMenuItem.Click += saveToolStripMenuItem_Click;
|
||||
//
|
||||
// saveAsToolStripMenuItem
|
||||
//
|
||||
saveAsToolStripMenuItem.Name = "saveAsToolStripMenuItem";
|
||||
saveAsToolStripMenuItem.Size = new System.Drawing.Size(146, 22);
|
||||
saveAsToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
|
||||
saveAsToolStripMenuItem.Text = "Save &As...";
|
||||
saveAsToolStripMenuItem.Click += saveAsToolStripMenuItem_Click;
|
||||
//
|
||||
// toolStripMenuItem15
|
||||
//
|
||||
toolStripMenuItem15.Name = "toolStripMenuItem15";
|
||||
toolStripMenuItem15.Size = new System.Drawing.Size(143, 6);
|
||||
toolStripMenuItem15.Size = new System.Drawing.Size(177, 6);
|
||||
//
|
||||
// exitToolStripMenuItem2
|
||||
//
|
||||
exitToolStripMenuItem2.Name = "exitToolStripMenuItem2";
|
||||
exitToolStripMenuItem2.Size = new System.Drawing.Size(146, 22);
|
||||
exitToolStripMenuItem2.Size = new System.Drawing.Size(180, 22);
|
||||
exitToolStripMenuItem2.Text = "E&xit";
|
||||
exitToolStripMenuItem2.Click += exitToolStripMenuItem_Click;
|
||||
//
|
||||
@ -199,7 +199,7 @@ namespace BukkuBuddy
|
||||
findToolStripMenuItem.Image = MainMenuResource.search;
|
||||
findToolStripMenuItem.Name = "findToolStripMenuItem";
|
||||
findToolStripMenuItem.ShortcutKeys = System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.F;
|
||||
findToolStripMenuItem.Size = new System.Drawing.Size(137, 22);
|
||||
findToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
|
||||
findToolStripMenuItem.Text = "&Find";
|
||||
findToolStripMenuItem.Click += findToolStripMenuItem_Click;
|
||||
//
|
||||
@ -213,26 +213,26 @@ namespace BukkuBuddy
|
||||
// expandAllToolStripMenuItem
|
||||
//
|
||||
expandAllToolStripMenuItem.Name = "expandAllToolStripMenuItem";
|
||||
expandAllToolStripMenuItem.Size = new System.Drawing.Size(152, 22);
|
||||
expandAllToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
|
||||
expandAllToolStripMenuItem.Text = "&Expand All";
|
||||
expandAllToolStripMenuItem.Click += expandAllToolStripMenuItem_Click;
|
||||
//
|
||||
// collapseAllToolStripMenuItem
|
||||
//
|
||||
collapseAllToolStripMenuItem.Name = "collapseAllToolStripMenuItem";
|
||||
collapseAllToolStripMenuItem.Size = new System.Drawing.Size(152, 22);
|
||||
collapseAllToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
|
||||
collapseAllToolStripMenuItem.Text = "&Collapse All";
|
||||
collapseAllToolStripMenuItem.Click += collapseAllToolStripMenuItem_Click;
|
||||
//
|
||||
// toolStripSeparator1
|
||||
//
|
||||
toolStripSeparator1.Name = "toolStripSeparator1";
|
||||
toolStripSeparator1.Size = new System.Drawing.Size(149, 6);
|
||||
toolStripSeparator1.Size = new System.Drawing.Size(177, 6);
|
||||
//
|
||||
// alwaysOnTopToolStripMenuItem
|
||||
//
|
||||
alwaysOnTopToolStripMenuItem.Name = "alwaysOnTopToolStripMenuItem";
|
||||
alwaysOnTopToolStripMenuItem.Size = new System.Drawing.Size(152, 22);
|
||||
alwaysOnTopToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
|
||||
alwaysOnTopToolStripMenuItem.Text = "Always On &Top";
|
||||
alwaysOnTopToolStripMenuItem.Click += alwaysOnTopToolStripMenuItem_Click;
|
||||
//
|
||||
@ -250,6 +250,13 @@ namespace BukkuBuddy
|
||||
toolStripMenuItem12.Size = new System.Drawing.Size(180, 22);
|
||||
toolStripMenuItem12.Text = "&Icons";
|
||||
//
|
||||
// toolStripMenuItem9
|
||||
//
|
||||
toolStripMenuItem9.Name = "toolStripMenuItem9";
|
||||
toolStripMenuItem9.Size = new System.Drawing.Size(180, 22);
|
||||
toolStripMenuItem9.Text = "&Update";
|
||||
toolStripMenuItem9.Click += toolStripMenuItem9_Click_1;
|
||||
//
|
||||
// updateAllToolStripMenuItem
|
||||
//
|
||||
updateAllToolStripMenuItem.Name = "updateAllToolStripMenuItem";
|
||||
@ -257,6 +264,11 @@ namespace BukkuBuddy
|
||||
updateAllToolStripMenuItem.Text = "Update &All";
|
||||
updateAllToolStripMenuItem.Click += updateAllToolStripMenuItem_Click;
|
||||
//
|
||||
// toolStripSeparator3
|
||||
//
|
||||
toolStripSeparator3.Name = "toolStripSeparator3";
|
||||
toolStripSeparator3.Size = new System.Drawing.Size(177, 6);
|
||||
//
|
||||
// clearToolStripMenuItem
|
||||
//
|
||||
clearToolStripMenuItem.Name = "clearToolStripMenuItem";
|
||||
@ -275,7 +287,7 @@ namespace BukkuBuddy
|
||||
optionsToolStripMenuItem.Name = "optionsToolStripMenuItem";
|
||||
optionsToolStripMenuItem.ShortcutKeys = System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.F12;
|
||||
optionsToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
|
||||
optionsToolStripMenuItem.Text = "&Options";
|
||||
optionsToolStripMenuItem.Text = "&Options...";
|
||||
optionsToolStripMenuItem.Click += optionsToolStripMenuItem_Click;
|
||||
//
|
||||
// helpToolStripMenuItem1
|
||||
@ -290,19 +302,19 @@ namespace BukkuBuddy
|
||||
viewHelpToolStripMenuItem1.Image = MainMenuResource.help_circle;
|
||||
viewHelpToolStripMenuItem1.Name = "viewHelpToolStripMenuItem1";
|
||||
viewHelpToolStripMenuItem1.ShortcutKeys = System.Windows.Forms.Keys.F1;
|
||||
viewHelpToolStripMenuItem1.Size = new System.Drawing.Size(146, 22);
|
||||
viewHelpToolStripMenuItem1.Size = new System.Drawing.Size(180, 22);
|
||||
viewHelpToolStripMenuItem1.Text = "&View Help";
|
||||
viewHelpToolStripMenuItem1.Click += viewHelpToolStripMenuItem1_Click;
|
||||
//
|
||||
// toolStripMenuItem16
|
||||
//
|
||||
toolStripMenuItem16.Name = "toolStripMenuItem16";
|
||||
toolStripMenuItem16.Size = new System.Drawing.Size(143, 6);
|
||||
toolStripMenuItem16.Size = new System.Drawing.Size(177, 6);
|
||||
//
|
||||
// aboutToolStripMenuItem1
|
||||
//
|
||||
aboutToolStripMenuItem1.Name = "aboutToolStripMenuItem1";
|
||||
aboutToolStripMenuItem1.Size = new System.Drawing.Size(146, 22);
|
||||
aboutToolStripMenuItem1.Size = new System.Drawing.Size(180, 22);
|
||||
aboutToolStripMenuItem1.Text = "&About";
|
||||
aboutToolStripMenuItem1.Click += aboutToolStripMenuItem1_Click;
|
||||
//
|
||||
@ -514,22 +526,9 @@ namespace BukkuBuddy
|
||||
treeView1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
treeView1.Location = new System.Drawing.Point(0, 24);
|
||||
treeView1.Name = "treeView1";
|
||||
treeView1.OnChanged = null;
|
||||
treeView1.Size = new System.Drawing.Size(300, 556);
|
||||
treeView1.TabIndex = 5;
|
||||
//
|
||||
// toolStripMenuItem9
|
||||
//
|
||||
toolStripMenuItem9.Name = "toolStripMenuItem9";
|
||||
toolStripMenuItem9.Size = new System.Drawing.Size(180, 22);
|
||||
toolStripMenuItem9.Text = "&Update";
|
||||
toolStripMenuItem9.Click += toolStripMenuItem9_Click_1;
|
||||
//
|
||||
// toolStripSeparator3
|
||||
//
|
||||
toolStripSeparator3.Name = "toolStripSeparator3";
|
||||
toolStripSeparator3.Size = new System.Drawing.Size(177, 6);
|
||||
//
|
||||
// MainForm
|
||||
//
|
||||
AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F);
|
||||
|
||||
@ -12,8 +12,8 @@ using BukkuBuddy.DTOs.SaveFile;
|
||||
using BukkuBuddy.Forms;
|
||||
using BukkuBuddy.Resources;
|
||||
using RyzStudio;
|
||||
using RyzStudio.Services;
|
||||
using RyzStudio.Windows.Forms;
|
||||
using RyzStudio.Windows.ThemedForms;
|
||||
using static RyzStudio.Windows.Forms.BookmarkTreeView;
|
||||
|
||||
namespace BukkuBuddy
|
||||
@ -56,7 +56,7 @@ namespace BukkuBuddy
|
||||
{
|
||||
base.OnShown(e);
|
||||
|
||||
var args = WinApplication.GetCommandLine();
|
||||
var args = this.GetCommandLine();
|
||||
|
||||
string jsonfigFilename = args.Where(x => (x.Key.Equals("o") || x.Key.Equals("open"))).Select(x => x.Value).FirstOrDefault();
|
||||
//if (string.IsNullOrWhiteSpace(jsonfigFilename))
|
||||
@ -75,7 +75,7 @@ namespace BukkuBuddy
|
||||
//InvalidateOptions();
|
||||
}
|
||||
|
||||
UIControl.SetFocus(this);
|
||||
UIControl.Invoke(this, (_) => this.Focus());
|
||||
}
|
||||
|
||||
protected async override void OnFormClosing(FormClosingEventArgs e)
|
||||
@ -108,30 +108,30 @@ namespace BukkuBuddy
|
||||
{
|
||||
isBusy = value;
|
||||
|
||||
UIControl.SetEnable(treeView1, !isBusy);
|
||||
UIControl.Invoke(treeView1, (_) => treeView1.Enabled =!isBusy);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private void InvalidateOptions(bool resize)
|
||||
{
|
||||
UIControl.SetTopMost(this, this.CurrentSession.AlwaysOnTop);
|
||||
UIControl.Invoke(this, (_) => this.TopMost = this.CurrentSession.AlwaysOnTop);
|
||||
|
||||
if (resize)
|
||||
{
|
||||
if (!this.CurrentSession.StartPosition.IsEmpty)
|
||||
{
|
||||
UIControl.SetLocation(this, this.CurrentSession.StartPosition);
|
||||
UIControl.Invoke(this, (_) => this.Location = this.CurrentSession.StartPosition);
|
||||
}
|
||||
|
||||
if (this.CurrentSession.Width > 0)
|
||||
{
|
||||
UIControl.SetClientWidth(this, this.CurrentSession.Width);
|
||||
UIControl.Invoke(this, (_) => this.ClientSize = new Size(this.CurrentSession.Width, this.ClientSize.Height));
|
||||
}
|
||||
|
||||
if (this.CurrentSession.Height > 0)
|
||||
{
|
||||
UIControl.SetClientHeight(this, this.CurrentSession.Height);
|
||||
UIControl.Invoke(this, (_) => this.ClientSize = new Size(this.ClientSize.Width, this.CurrentSession.Height));
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -513,7 +513,7 @@ namespace BukkuBuddy
|
||||
/// <param name="e"></param>
|
||||
private void aboutToolStripMenuItem1_Click(object sender, EventArgs e)
|
||||
{
|
||||
var form = new RyzStudio.Windows.ThemedForms.AboutForm();
|
||||
var form = new RyzStudio.Forms.T3AboutForm();
|
||||
form.ProductURL = MainMenuResource.AppProductURL;
|
||||
form.AuthorURL = MainMenuResource.AppAuthorURL;
|
||||
form.CompanyURL = MainMenuResource.AppCompanyURL;
|
||||
@ -864,7 +864,7 @@ namespace BukkuBuddy
|
||||
}
|
||||
});
|
||||
|
||||
UIControl.SetFocus(treeView1);
|
||||
UIControl.Invoke(treeView1, (_) => treeView1.Focus());
|
||||
|
||||
sender.HasChanged = true;
|
||||
|
||||
@ -888,7 +888,7 @@ namespace BukkuBuddy
|
||||
this.InvalidateOptions(true);
|
||||
});
|
||||
|
||||
UIControl.SetFocus(treeView1);
|
||||
UIControl.Invoke(treeView1, (_) => treeView1.Focus());
|
||||
|
||||
sender.HasChanged = false;
|
||||
|
||||
@ -927,7 +927,7 @@ namespace BukkuBuddy
|
||||
this.CurrentSession.Directories = directoryList ?? new List<string>();
|
||||
this.CurrentSession.Items = bookmarkList.Select(x => x.Value)?.ToList() ?? new List<App6Options.Item>();
|
||||
|
||||
var result = GenericResult.Create();
|
||||
var result = MethodResult.Create();
|
||||
|
||||
switch (Path.GetExtension(filename?.ToLower()?.Trim() ?? string.Empty))
|
||||
{
|
||||
@ -938,54 +938,54 @@ namespace BukkuBuddy
|
||||
case ".jsnx":
|
||||
result = await RyzStudio.IO.Compression.ZFile.WriteFile(filename, "Document.json", this.CurrentSession);
|
||||
|
||||
if (result.IsSuccess)
|
||||
if (result.Success)
|
||||
{
|
||||
// Add icons to save file
|
||||
var result2 = AddImagesToZipFile(filename, bookmarkList);
|
||||
if (!result2.IsSuccess)
|
||||
if (!result2.Success)
|
||||
{
|
||||
if (showNotices)
|
||||
{
|
||||
ThMessageBox.Show(this, "Unable to save icons", "Save session", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
RyzStudio.Forms.T3MessageBox.Show(this, "Unable to save icons", "Save session", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
break;
|
||||
default:
|
||||
result = GenericResult.Fault("Format not supported");
|
||||
result = MethodResult.Error("Format not supported");
|
||||
break;
|
||||
}
|
||||
|
||||
if (result.IsSuccess)
|
||||
if (result.Success)
|
||||
{
|
||||
if (showNotices)
|
||||
{
|
||||
ThMessageBox.Show(this, "Session saved!", "Save session", MessageBoxButtons.OK, MessageBoxIcon.Information);
|
||||
RyzStudio.Forms.T3MessageBox.Show(this, "Session saved!", "Save session", MessageBoxButtons.OK, MessageBoxIcon.Information);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (showNotices)
|
||||
{
|
||||
ThMessageBox.Show(this, result.Message, "Save session");
|
||||
RyzStudio.Forms.T3MessageBox.Show(this, result.Message, "Save session");
|
||||
}
|
||||
}
|
||||
|
||||
isBusy = false;
|
||||
|
||||
if (result.IsSuccess)
|
||||
if (result.Success)
|
||||
{
|
||||
sender.HasChanged = false;
|
||||
}
|
||||
|
||||
return result.IsSuccess;
|
||||
return result.Success;
|
||||
});
|
||||
}
|
||||
|
||||
private async Task<bool> fileSessionManager_OnClearSession(FileSessionManager sender)
|
||||
{
|
||||
UIControl.Clear(treeView1);
|
||||
UIControl.Invoke(treeView1, (_) => treeView1.Nodes.Clear());
|
||||
|
||||
sender.HasChanged = false;
|
||||
|
||||
@ -999,13 +999,13 @@ namespace BukkuBuddy
|
||||
switch (sender.SessionState)
|
||||
{
|
||||
case FileSessionManager.SessionStateEnum.New:
|
||||
UIControl.SetText(this, "New Session - " + Application.ProductName);
|
||||
UIControl.Invoke(this, (_) => this.Text = "New Session - " + Application.ProductName);
|
||||
break;
|
||||
case FileSessionManager.SessionStateEnum.Open:
|
||||
UIControl.SetText(this, Path.GetFileNameWithoutExtension(filename) + " - " + Application.ProductName);
|
||||
UIControl.Invoke(this, (_) => this.Text = Path.GetFileNameWithoutExtension(filename) + " - " + Application.ProductName);
|
||||
break;
|
||||
case FileSessionManager.SessionStateEnum.Close:
|
||||
UIControl.SetText(this, Application.ProductName);
|
||||
UIControl.Invoke(this, (_) => this.Text = Application.ProductName);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
@ -1077,7 +1077,7 @@ namespace BukkuBuddy
|
||||
return;
|
||||
}
|
||||
|
||||
var model = UIControl.GetTag<App6Options.Item>(node);
|
||||
var model = node.GetTag<App6Options.Item>();
|
||||
if (model == null)
|
||||
{
|
||||
return;
|
||||
@ -1094,11 +1094,11 @@ namespace BukkuBuddy
|
||||
});
|
||||
}
|
||||
|
||||
private GenericResult AddImagesToZipFile(string zipFilename, List<KeyValuePair<TreeNode, App6Options.Item>> items)
|
||||
private MethodResult AddImagesToZipFile(string zipFilename, List<KeyValuePair<TreeNode, App6Options.Item>> items)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(zipFilename))
|
||||
{
|
||||
return GenericResult.Fault("Filename is blank");
|
||||
return MethodResult.Error("Filename is blank");
|
||||
}
|
||||
|
||||
var path = Path.GetDirectoryName(zipFilename);
|
||||
@ -1110,7 +1110,7 @@ namespace BukkuBuddy
|
||||
}
|
||||
catch (Exception exc)
|
||||
{
|
||||
return GenericResult.Fault(exc.Message);
|
||||
return MethodResult.Error(exc.Message);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1181,10 +1181,10 @@ namespace BukkuBuddy
|
||||
}
|
||||
catch (Exception exc)
|
||||
{
|
||||
return GenericResult.Fault(exc.Message);
|
||||
return MethodResult.Error(exc.Message);
|
||||
}
|
||||
|
||||
return GenericResult.Create();
|
||||
return MethodResult.Create();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
4
source/Resources/MainMenuResource.Designer.cs
generated
4
source/Resources/MainMenuResource.Designer.cs
generated
@ -79,7 +79,7 @@ namespace BukkuBuddy.Resources {
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to https://www.hiimray.co.uk/software-bookmark-manager.
|
||||
/// Looks up a localized string similar to https://git.hiimray.co.uk/HiImRay_Public/bukkubuddy-bookmark-manager.
|
||||
/// </summary>
|
||||
internal static string AppHelpURL {
|
||||
get {
|
||||
@ -88,7 +88,7 @@ namespace BukkuBuddy.Resources {
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to https://www.hiimray.co.uk/software-bookmark-manager.
|
||||
/// Looks up a localized string similar to https://git.hiimray.co.uk/HiImRay_Public/bukkubuddy-bookmark-manager.
|
||||
/// </summary>
|
||||
internal static string AppProductURL {
|
||||
get {
|
||||
|
||||
@ -124,10 +124,10 @@
|
||||
<value>https://www.hiimray.co.uk</value>
|
||||
</data>
|
||||
<data name="AppHelpURL" xml:space="preserve">
|
||||
<value>https://www.hiimray.co.uk/software-bookmark-manager</value>
|
||||
<value>https://git.hiimray.co.uk/HiImRay_Public/bukkubuddy-bookmark-manager</value>
|
||||
</data>
|
||||
<data name="AppProductURL" xml:space="preserve">
|
||||
<value>https://www.hiimray.co.uk/software-bookmark-manager</value>
|
||||
<value>https://git.hiimray.co.uk/HiImRay_Public/bukkubuddy-bookmark-manager</value>
|
||||
</data>
|
||||
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||
<data name="folder_minus" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
|
||||
@ -4,7 +4,6 @@ using System.ComponentModel;
|
||||
using System.Drawing;
|
||||
using System.Linq;
|
||||
using System.Windows.Forms;
|
||||
using BukkuBuddy;
|
||||
using BukkuBuddy.DTOs.SaveFile;
|
||||
using BukkuBuddy.Resources;
|
||||
|
||||
@ -146,7 +145,7 @@ namespace RyzStudio.Windows.Forms
|
||||
|
||||
break;
|
||||
case NodeType.Page:
|
||||
var viewModel = UIControl.GetTag<App6Options.Item>(this.SelectedNode);
|
||||
var viewModel = this.SelectedNode.GetTag<App6Options.Item>();
|
||||
if (viewModel != null)
|
||||
{
|
||||
try
|
||||
@ -320,7 +319,7 @@ namespace RyzStudio.Windows.Forms
|
||||
newNode.ImageKey = newNode.SelectedImageKey = model.Id.ToString();
|
||||
}
|
||||
|
||||
UIControl.Add(parentNode, newNode);
|
||||
UIControl.Invoke(parentNode.TreeView, (_) => parentNode.Nodes.Add(newNode));
|
||||
|
||||
this.HasChanged = true;
|
||||
|
||||
@ -374,7 +373,7 @@ namespace RyzStudio.Windows.Forms
|
||||
}
|
||||
else if (nodeType == NodeType.Page)
|
||||
{
|
||||
var model = UIControl.GetTag<App6Options.Item>(node);
|
||||
var model = node.GetTag<App6Options.Item>();
|
||||
model.Path = GetNodePath(node);
|
||||
|
||||
if (this.OnEditNode != null) this.OnEditNode(this, node, model);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user