diff --git a/Configuration/LockManager.cs b/Configuration/LockManager.cs index 3b1ae2b5..1b69505b 100644 --- a/Configuration/LockManager.cs +++ b/Configuration/LockManager.cs @@ -3,7 +3,7 @@ using System.IO; using System.Threading; -namespace TweetDick.Configuration{ +namespace TweetDck.Configuration{ class LockManager{ private readonly string file; private FileStream lockStream; diff --git a/Configuration/UserConfig.cs b/Configuration/UserConfig.cs index 7e1bd3b2..10caf488 100644 --- a/Configuration/UserConfig.cs +++ b/Configuration/UserConfig.cs @@ -3,13 +3,14 @@ using System.IO; using System.Runtime.Serialization; using System.Runtime.Serialization.Formatters.Binary; -using System.Windows.Forms; -using TweetDick.Core.Handling; +using TweetDck.Core.Handling; -namespace TweetDick.Configuration{ +namespace TweetDck.Configuration{ [Serializable] sealed class UserConfig{ - private static readonly IFormatter Formatter = new BinaryFormatter(); + private static readonly IFormatter Formatter = new BinaryFormatter(){ + Binder = new SerializationCompatibilityHandler() + }; // START OF CONFIGURATION @@ -102,5 +103,12 @@ public static UserConfig Load(string file){ private static string GetBackupFile(string file){ return file+".bak"; } + + private class SerializationCompatibilityHandler : SerializationBinder{ + public override Type BindToType(string assemblyName, string typeName){ + typeName = typeName.Replace("TweetDick","TweetDck"); + return Type.GetType(string.Format("{0}, {1}",typeName,assemblyName)); + } + } } } diff --git a/Core/Controls/FlatProgressBar.Designer.cs b/Core/Controls/FlatProgressBar.Designer.cs index f467acef..4a9d1772 100644 --- a/Core/Controls/FlatProgressBar.Designer.cs +++ b/Core/Controls/FlatProgressBar.Designer.cs @@ -1,4 +1,4 @@ -namespace TweetDick.Core.Controls { +namespace TweetDck.Core.Controls { partial class FlatProgressBar { /// <summary> /// Required designer variable. diff --git a/Core/Controls/FlatProgressBar.cs b/Core/Controls/FlatProgressBar.cs index a532690f..9a9e5b6b 100644 --- a/Core/Controls/FlatProgressBar.cs +++ b/Core/Controls/FlatProgressBar.cs @@ -1,7 +1,7 @@ using System.Drawing; using System.Windows.Forms; -namespace TweetDick.Core.Controls{ +namespace TweetDck.Core.Controls{ public partial class FlatProgressBar : ProgressBar{ private SolidBrush brush; diff --git a/Core/Controls/RichTextLabel.Designer.cs b/Core/Controls/RichTextLabel.Designer.cs index b97603ac..58f5f7ed 100644 --- a/Core/Controls/RichTextLabel.Designer.cs +++ b/Core/Controls/RichTextLabel.Designer.cs @@ -1,4 +1,4 @@ -namespace TweetDick.Core.Controls { +namespace TweetDck.Core.Controls { partial class RichTextLabel { /// <summary> /// Required designer variable. diff --git a/Core/Controls/RichTextLabel.cs b/Core/Controls/RichTextLabel.cs index 0a02829b..cb52e143 100644 --- a/Core/Controls/RichTextLabel.cs +++ b/Core/Controls/RichTextLabel.cs @@ -1,7 +1,7 @@ using System; using System.Windows.Forms; -namespace TweetDick.Core.Controls{ +namespace TweetDck.Core.Controls{ public partial class RichTextLabel : RichTextBox{ /// <summary> /// Wraps the body of a RTF formatted string with default tags and formatting. diff --git a/Core/FormBrowser.Designer.cs b/Core/FormBrowser.Designer.cs index 8f38c341..e75b5f3b 100644 --- a/Core/FormBrowser.Designer.cs +++ b/Core/FormBrowser.Designer.cs @@ -1,4 +1,4 @@ -namespace TweetDick.Core { +namespace TweetDck.Core { sealed partial class FormBrowser { /// <summary> /// Required designer variable. @@ -30,7 +30,7 @@ private void InitializeComponent() { // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.Icon = TweetDick.Properties.Resources.icon; + this.Icon = TweetDck.Properties.Resources.icon; this.Location = new System.Drawing.Point(-32000, -32000); this.Name = "FormBrowser"; this.StartPosition = System.Windows.Forms.FormStartPosition.Manual; diff --git a/Core/FormBrowser.cs b/Core/FormBrowser.cs index 0b018fff..97a587c1 100644 --- a/Core/FormBrowser.cs +++ b/Core/FormBrowser.cs @@ -1,15 +1,15 @@ -using System.Windows.Forms; -using CefSharp.WinForms; -using System; -using System.Linq; -using TweetDick.Configuration; -using CefSharp; -using TweetDick.Core.Handling; -using TweetDick.Core.Other; +using System; using System.Drawing; -using TweetDick.Resources; +using System.Linq; +using System.Windows.Forms; +using CefSharp; +using CefSharp.WinForms; +using TweetDck.Configuration; +using TweetDck.Core.Handling; +using TweetDck.Core.Other; +using TweetDck.Resources; -namespace TweetDick.Core{ +namespace TweetDck.Core{ sealed partial class FormBrowser : Form{ private static UserConfig Config{ get{ diff --git a/Core/FormNotification.Designer.cs b/Core/FormNotification.Designer.cs index e5fc0d76..dd228ca1 100644 --- a/Core/FormNotification.Designer.cs +++ b/Core/FormNotification.Designer.cs @@ -1,4 +1,6 @@ -namespace TweetDick.Core { +using TweetDck.Core.Controls; + +namespace TweetDck.Core { sealed partial class FormNotification { /// <summary> /// Required designer variable. @@ -26,7 +28,7 @@ private void InitializeComponent() { this.components = new System.ComponentModel.Container(); this.panelBrowser = new System.Windows.Forms.Panel(); this.timerProgress = new System.Windows.Forms.Timer(this.components); - this.progressBarTimer = new TweetDick.Core.Controls.FlatProgressBar(); + this.progressBarTimer = new FlatProgressBar(); this.SuspendLayout(); // // panelBrowser diff --git a/Core/FormNotification.cs b/Core/FormNotification.cs index 641647fa..5028b34d 100644 --- a/Core/FormNotification.cs +++ b/Core/FormNotification.cs @@ -1,14 +1,14 @@ -using System.Windows.Forms; +using System; +using System.Collections.Generic; +using System.Drawing; +using System.Windows.Forms; using CefSharp; using CefSharp.WinForms; -using System.Drawing; -using System; -using System.Collections.Generic; -using TweetDick.Core.Handling; -using TweetDick.Configuration; -using TweetDick.Resources; +using TweetDck.Configuration; +using TweetDck.Core.Handling; +using TweetDck.Resources; -namespace TweetDick.Core{ +namespace TweetDck.Core{ sealed partial class FormNotification : Form{ public Func<bool> CanMoveWindow = () => true; diff --git a/Core/Handling/ContextMenuHandler.cs b/Core/Handling/ContextMenuHandler.cs index f704eb52..715ccbfe 100644 --- a/Core/Handling/ContextMenuHandler.cs +++ b/Core/Handling/ContextMenuHandler.cs @@ -1,6 +1,6 @@ using CefSharp; -namespace TweetDick.Core.Handling{ +namespace TweetDck.Core.Handling{ class ContextMenuHandler : IContextMenuHandler{ private const int MenuSettings = 26500; private const int MenuAbout = 26501; diff --git a/Core/Handling/TweetDeckBridge.cs b/Core/Handling/TweetDeckBridge.cs index b82e76ae..ef54ccde 100644 --- a/Core/Handling/TweetDeckBridge.cs +++ b/Core/Handling/TweetDeckBridge.cs @@ -1,6 +1,6 @@ using System.Diagnostics; -namespace TweetDick.Core.Handling{ +namespace TweetDck.Core.Handling{ class TweetDeckBridge{ private readonly FormBrowser form; diff --git a/Core/Handling/TweetNotification.cs b/Core/Handling/TweetNotification.cs index 75225f3b..67f46f2f 100644 --- a/Core/Handling/TweetNotification.cs +++ b/Core/Handling/TweetNotification.cs @@ -1,7 +1,7 @@ using System; using System.Text; -namespace TweetDick.Core.Handling{ +namespace TweetDck.Core.Handling{ sealed class TweetNotification{ private static string FontSizeClass { get; set; } private static string HeadTag { get; set; } diff --git a/Core/Other/FormAbout.Designer.cs b/Core/Other/FormAbout.Designer.cs index 80058df4..bfcbac8b 100644 --- a/Core/Other/FormAbout.Designer.cs +++ b/Core/Other/FormAbout.Designer.cs @@ -1,4 +1,6 @@ -namespace TweetDick.Core.Other { +using TweetDck.Core.Controls; + +namespace TweetDck.Core.Other { sealed partial class FormAbout { /// <summary> /// Required designer variable. @@ -23,7 +25,7 @@ protected override void Dispose(bool disposing) { /// the contents of this method with the code editor. /// </summary> private void InitializeComponent() { - this.labelAbout = new TweetDick.Core.Controls.RichTextLabel(); + this.labelAbout = new RichTextLabel(); this.SuspendLayout(); // // labelAbout diff --git a/Core/Other/FormAbout.cs b/Core/Other/FormAbout.cs index 8b166dc1..285145af 100644 --- a/Core/Other/FormAbout.cs +++ b/Core/Other/FormAbout.cs @@ -1,8 +1,8 @@ using System.Text; using System.Windows.Forms; -using TweetDick.Core.Controls; +using TweetDck.Core.Controls; -namespace TweetDick.Core.Other{ +namespace TweetDck.Core.Other{ sealed partial class FormAbout : Form{ public FormAbout(){ InitializeComponent(); diff --git a/Core/Other/FormBackgroundWork.Designer.cs b/Core/Other/FormBackgroundWork.Designer.cs index dee83ad5..a8b8535a 100644 --- a/Core/Other/FormBackgroundWork.Designer.cs +++ b/Core/Other/FormBackgroundWork.Designer.cs @@ -1,6 +1,6 @@ -using TweetDick.Core.Controls; +using TweetDck.Core.Controls; -namespace TweetDick.Core.Other { +namespace TweetDck.Core.Other { partial class FormBackgroundWork { /// <summary> /// Required designer variable. diff --git a/Core/Other/FormBackgroundWork.cs b/Core/Other/FormBackgroundWork.cs index 7177ce73..30d4a84c 100644 --- a/Core/Other/FormBackgroundWork.cs +++ b/Core/Other/FormBackgroundWork.cs @@ -1,8 +1,8 @@ using System; using System.Windows.Forms; -using TweetDick.Core.Controls; +using TweetDck.Core.Controls; -namespace TweetDick.Core.Other{ +namespace TweetDck.Core.Other{ partial class FormBackgroundWork : Form{ public FormBackgroundWork(){ InitializeComponent(); diff --git a/Core/Other/FormSettings.Designer.cs b/Core/Other/FormSettings.Designer.cs index d02d09dc..33187467 100644 --- a/Core/Other/FormSettings.Designer.cs +++ b/Core/Other/FormSettings.Designer.cs @@ -1,4 +1,4 @@ -namespace TweetDick.Core.Other { +namespace TweetDck.Core.Other { sealed partial class FormSettings { /// <summary> /// Required designer variable. @@ -272,7 +272,7 @@ private void InitializeComponent() { this.ClientSize = new System.Drawing.Size(384, 282); this.Controls.Add(this.tableLayout); this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle; - this.Icon = TweetDick.Properties.Resources.icon; + this.Icon = TweetDck.Properties.Resources.icon; this.MaximizeBox = false; this.MinimizeBox = false; this.Name = "FormSettings"; diff --git a/Core/Other/FormSettings.cs b/Core/Other/FormSettings.cs index ce640fad..d6d7cfc0 100644 --- a/Core/Other/FormSettings.cs +++ b/Core/Other/FormSettings.cs @@ -1,9 +1,9 @@ using System; using System.Windows.Forms; -using TweetDick.Configuration; -using TweetDick.Core.Handling; +using TweetDck.Configuration; +using TweetDck.Core.Handling; -namespace TweetDick.Core.Other{ +namespace TweetDck.Core.Other{ sealed partial class FormSettings : Form{ private static UserConfig Config{ get{ diff --git a/Migration/FormMigrationQuestion.Designer.cs b/Migration/FormMigrationQuestion.Designer.cs index 258eef00..27ed601c 100644 --- a/Migration/FormMigrationQuestion.Designer.cs +++ b/Migration/FormMigrationQuestion.Designer.cs @@ -1,6 +1,6 @@ -using TweetDick.Core.Controls; +using TweetDck.Core.Controls; -namespace TweetDick.Migration { +namespace TweetDck.Migration { partial class FormMigrationQuestion { /// <summary> /// Required designer variable. diff --git a/Migration/FormMigrationQuestion.cs b/Migration/FormMigrationQuestion.cs index bc392569..21f993c5 100644 --- a/Migration/FormMigrationQuestion.cs +++ b/Migration/FormMigrationQuestion.cs @@ -1,9 +1,9 @@ using System; using System.Drawing; using System.Windows.Forms; -using TweetDick.Core.Controls; +using TweetDck.Core.Controls; -namespace TweetDick.Migration{ +namespace TweetDck.Migration{ partial class FormMigrationQuestion : Form{ public MigrationDecision Decision { get; private set; } diff --git a/Migration/Helpers/LnkEditor.cs b/Migration/Helpers/LnkEditor.cs index ed9a7623..2ea6bc7c 100644 --- a/Migration/Helpers/LnkEditor.cs +++ b/Migration/Helpers/LnkEditor.cs @@ -1,8 +1,8 @@ using System; -using Shell32; using System.IO; +using Shell32; -namespace TweetDick.Migration.Helpers{ +namespace TweetDck.Migration.Helpers{ sealed class LnkEditor{ private readonly ShellLinkObject obj; diff --git a/Migration/Helpers/ProgramProcessSearch.cs b/Migration/Helpers/ProgramProcessSearch.cs index d5768e92..aebbda5c 100644 --- a/Migration/Helpers/ProgramProcessSearch.cs +++ b/Migration/Helpers/ProgramProcessSearch.cs @@ -2,7 +2,7 @@ using System.Diagnostics; using System.Linq; -namespace TweetDick.Migration.Helpers{ +namespace TweetDck.Migration.Helpers{ static class ProgramProcessSearch{ public static Process FindProcessWithWindowByName(string name){ try{ diff --git a/Migration/Helpers/ProgramRegistrySearch.cs b/Migration/Helpers/ProgramRegistrySearch.cs index b94fc37e..acdb4e5a 100644 --- a/Migration/Helpers/ProgramRegistrySearch.cs +++ b/Migration/Helpers/ProgramRegistrySearch.cs @@ -2,7 +2,7 @@ using System.Linq; using Microsoft.Win32; -namespace TweetDick.Migration.Helpers{ +namespace TweetDck.Migration.Helpers{ static class ProgramRegistrySearch{ public static string FindByDisplayName(string displayName){ Predicate<RegistryKey> predicate = key => displayName.Equals(key.GetValue("DisplayName") as string,StringComparison.OrdinalIgnoreCase); diff --git a/Migration/MigrationDecision.cs b/Migration/MigrationDecision.cs index bf057a75..ee54c452 100644 --- a/Migration/MigrationDecision.cs +++ b/Migration/MigrationDecision.cs @@ -1,4 +1,4 @@ -namespace TweetDick.Migration{ +namespace TweetDck.Migration{ enum MigrationDecision{ /// <summary> /// Copies the important files and then deletes the TweetDeck folder. diff --git a/Migration/MigrationManager.cs b/Migration/MigrationManager.cs index 80293ea2..878a205e 100644 --- a/Migration/MigrationManager.cs +++ b/Migration/MigrationManager.cs @@ -1,15 +1,15 @@ -using Microsoft.Win32; -using System; +using System; using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Threading; using System.Threading.Tasks; using System.Windows.Forms; -using TweetDick.Core.Other; -using TweetDick.Migration.Helpers; +using Microsoft.Win32; +using TweetDck.Core.Other; +using TweetDck.Migration.Helpers; -namespace TweetDick.Migration{ +namespace TweetDck.Migration{ static class MigrationManager{ private static readonly string TweetDeckPathParent = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData),"twitter"); private static readonly string TweetDeckPath = Path.Combine(TweetDeckPathParent,"TweetDeck"); diff --git a/Program.cs b/Program.cs index e5cc04cd..1c3bf735 100644 --- a/Program.cs +++ b/Program.cs @@ -1,17 +1,17 @@ -using CefSharp; -using System; +using System; using System.Diagnostics; using System.Globalization; using System.IO; using System.Runtime.InteropServices; using System.Text; using System.Windows.Forms; -using TweetDick.Configuration; -using TweetDick.Core; -using TweetDick.Migration; +using CefSharp; +using TweetDck.Configuration; +using TweetDck.Core; +using TweetDck.Migration; [assembly: CLSCompliant(true)] -namespace TweetDick{ +namespace TweetDck{ static class Program{ #if DUCK public const string BrandName = "TweetDuck"; diff --git a/Properties/AssemblyInfo.cs b/Properties/AssemblyInfo.cs index c1414676..6770f1fd 100644 --- a/Properties/AssemblyInfo.cs +++ b/Properties/AssemblyInfo.cs @@ -1,7 +1,7 @@ using System.Reflection; using System.Runtime.InteropServices; -using TweetDick; using System.Resources; +using TweetDck; // General Information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information diff --git a/Properties/Resources.Designer.cs b/Properties/Resources.Designer.cs index 0c984203..39a1017c 100644 --- a/Properties/Resources.Designer.cs +++ b/Properties/Resources.Designer.cs @@ -8,7 +8,7 @@ // </auto-generated> //------------------------------------------------------------------------------ -namespace TweetDick.Properties { +namespace TweetDck.Properties { using System; @@ -39,7 +39,7 @@ internal Resources() { internal static global::System.Resources.ResourceManager ResourceManager { get { if (object.ReferenceEquals(resourceMan, null)) { - global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("TweetDick.Properties.Resources", typeof(Resources).Assembly); + global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("TweetDck.Properties.Resources", typeof(Resources).Assembly); resourceMan = temp; } return resourceMan; diff --git a/Resources/ScriptLoader.cs b/Resources/ScriptLoader.cs index 554bfba8..22d41929 100644 --- a/Resources/ScriptLoader.cs +++ b/Resources/ScriptLoader.cs @@ -3,7 +3,7 @@ using System.Text; using System.Windows.Forms; -namespace TweetDick.Resources{ +namespace TweetDck.Resources{ static class ScriptLoader{ public static string LoadResource(string name){ try{ diff --git a/TweetDick.csproj b/TweetDick.csproj index 170499df..dd4085a6 100644 --- a/TweetDick.csproj +++ b/TweetDick.csproj @@ -9,7 +9,7 @@ <ProjectGuid>{2389A7CD-E0D3-4706-8294-092929A33A2D}</ProjectGuid> <OutputType>WinExe</OutputType> <AppDesignerFolder>Properties</AppDesignerFolder> - <RootNamespace>TweetDick</RootNamespace> + <RootNamespace>TweetDck</RootNamespace> <AssemblyName Condition=" '$(Configuration)' == 'Debug' ">TweetDick</AssemblyName> <AssemblyName Condition=" '$(Configuration)' == 'Release Dick' ">TweetDick</AssemblyName> <AssemblyName Condition=" '$(Configuration)' == 'Release Duck' ">TweetDuck</AssemblyName>