Еще рефакторинга
This commit is contained in:
@@ -81,7 +81,6 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Compile Include="DI\ContainerBuilder.cs" />
|
<Compile Include="DI\ContainerBuilder.cs" />
|
||||||
<Compile Include="Extensions\Extensions.cs" />
|
|
||||||
<Compile Include="JiraIntegration\IJiraDescriptionSource.cs" />
|
<Compile Include="JiraIntegration\IJiraDescriptionSource.cs" />
|
||||||
<Compile Include="JiraIntegration\JiraDescriptionSource.cs" />
|
<Compile Include="JiraIntegration\JiraDescriptionSource.cs" />
|
||||||
<Compile Include="Job.cs" />
|
<Compile Include="Job.cs" />
|
||||||
@@ -109,6 +108,8 @@
|
|||||||
<Compile Include="TaskTime\ITaskTimeDiscoverer.cs" />
|
<Compile Include="TaskTime\ITaskTimeDiscoverer.cs" />
|
||||||
<Compile Include="TaskTime\TaskTimeDiscoverer.cs" />
|
<Compile Include="TaskTime\TaskTimeDiscoverer.cs" />
|
||||||
<Compile Include="TaskTime\TaskTimeItem.cs" />
|
<Compile Include="TaskTime\TaskTimeItem.cs" />
|
||||||
|
<Compile Include="UI\ITrayMenu.cs" />
|
||||||
|
<Compile Include="UI\RestoreFromTray.cs" />
|
||||||
<Compile Include="UI\TrayMenu.cs" />
|
<Compile Include="UI\TrayMenu.cs" />
|
||||||
<EmbeddedResource Include="UI\frmMain.resx">
|
<EmbeddedResource Include="UI\frmMain.resx">
|
||||||
<DependentUpon>frmMain.cs</DependentUpon>
|
<DependentUpon>frmMain.cs</DependentUpon>
|
||||||
|
|||||||
@@ -0,0 +1,11 @@
|
|||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace JiraTimeBotForm.UI
|
||||||
|
{
|
||||||
|
public interface ITrayMenu
|
||||||
|
{
|
||||||
|
NotifyIcon Create(frmMain form);
|
||||||
|
void Show();
|
||||||
|
void Hide();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -2,10 +2,9 @@
|
|||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace JiraTimeBotForm.Extensions
|
namespace JiraTimeBotForm.UI
|
||||||
{
|
|
||||||
public static class Extensions
|
|
||||||
{
|
{
|
||||||
|
public static class RestoreFromTray {
|
||||||
[DllImport( "user32.dll" )]
|
[DllImport( "user32.dll" )]
|
||||||
private static extern int ShowWindow( IntPtr hWnd, uint Msg );
|
private static extern int ShowWindow( IntPtr hWnd, uint Msg );
|
||||||
|
|
||||||
@@ -48,14 +48,7 @@ namespace JiraTimeBotForm.UI
|
|||||||
form.Visible = true;
|
form.Visible = true;
|
||||||
form.Activate();
|
form.Activate();
|
||||||
form.BringToFront();
|
form.BringToFront();
|
||||||
Extensions.Extensions.Restore(form);
|
RestoreFromTray.Restore(form);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public interface ITrayMenu
|
|
||||||
{
|
|
||||||
NotifyIcon Create(frmMain form);
|
|
||||||
void Show();
|
|
||||||
void Hide();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user