Comment out code for later update

This commit is contained in:
Colin Liu 2016-02-18 19:32:48 +08:00
parent 934a41e414
commit f16804c0f8
6 changed files with 33 additions and 32 deletions

View File

@ -34,7 +34,7 @@ namespace Wox.CommandArgs
}
else
{
App.Window.ShowApp();
App.API.ShowApp();
}
}
}

View File

@ -16,9 +16,9 @@ namespace Wox.CommandArgs
if (args.Count > 0)
{
string query = args[0];
App.Window.ChangeQuery(query);
App.API.ChangeQuery(query);
}
App.Window.ShowApp();
App.API.ShowApp();
}
}
}

View File

@ -12,7 +12,7 @@ namespace Wox.CommandArgs
public void Execute(IList<string> args)
{
PluginManager.Init(App.Window);
PluginManager.Init(App.API);
}
}
}

View File

@ -11,7 +11,8 @@ namespace Wox.CommandArgs
public void Execute(IList<string> args)
{
App.Window.ToggleWox();
//TODO: Add ToggleWox Method
//App.API.ToggleWox();
}
}
}

View File

@ -44,11 +44,11 @@ namespace Wox
ActionKeyword = tbAction.Text
};
UserSettingStorage.Instance.CustomPluginHotkeys.Add(pluginHotkey);
settingWidow.MainWindow.SetHotkey(ctlHotkey.CurrentHotkey, delegate
{
settingWidow.MainWindow.ChangeQuery(pluginHotkey.ActionKeyword);
settingWidow.MainWindow.ShowApp();
});
//settingWidow.MainWindow.SetHotkey(ctlHotkey.CurrentHotkey, delegate
//{
// settingWidow.MainWindow.ChangeQuery(pluginHotkey.ActionKeyword);
// settingWidow.MainWindow.ShowApp();
//});
MessageBox.Show(InternationalizationManager.Instance.GetTranslation("succeed"));
}
else
@ -62,12 +62,12 @@ namespace Wox
updateCustomHotkey.ActionKeyword = tbAction.Text;
updateCustomHotkey.Hotkey = ctlHotkey.CurrentHotkey.ToString();
//remove origin hotkey
settingWidow.MainWindow.RemoveHotkey(oldHotkey);
settingWidow.MainWindow.SetHotkey(updateCustomHotkey.Hotkey, delegate
{
settingWidow.MainWindow.ShowApp();
settingWidow.MainWindow.ChangeQuery(updateCustomHotkey.ActionKeyword);
});
//settingWidow.MainWindow.RemoveHotkey(oldHotkey);
//settingWidow.MainWindow.SetHotkey(updateCustomHotkey.Hotkey, delegate
//{
// settingWidow.MainWindow.ShowApp();
// settingWidow.MainWindow.ChangeQuery(updateCustomHotkey.ActionKeyword);
//});
MessageBox.Show(InternationalizationManager.Instance.GetTranslation("succeed"));
}
@ -94,8 +94,8 @@ namespace Wox
private void BtnTestActionKeyword_OnClick(object sender, RoutedEventArgs e)
{
settingWidow.MainWindow.ShowApp();
settingWidow.MainWindow.ChangeQuery(tbAction.Text);
//settingWidow.MainWindow.ShowApp();
//settingWidow.MainWindow.ChangeQuery(tbAction.Text);
}
}
}

View File

@ -94,7 +94,7 @@ namespace Wox
{
UserSettingStorage.Instance.MaxResultsToShow = (int)comboMaxResultsToShow.SelectedItem;
UserSettingStorage.Instance.Save();
MainWindow.pnlResult.lbResults.GetBindingExpression(MaxHeightProperty).UpdateTarget();
//MainWindow.pnlResult.lbResults.GetBindingExpression(MaxHeightProperty).UpdateTarget();
};
cbHideWhenDeactive.IsChecked = UserSettingStorage.Instance.HideWhenDeactive;
@ -250,18 +250,18 @@ namespace Wox
{
if (ctlHotkey.CurrentHotkeyAvailable)
{
MainWindow.SetHotkey(ctlHotkey.CurrentHotkey, delegate
{
if (!MainWindow.IsVisible)
{
MainWindow.ShowApp();
}
else
{
MainWindow.HideApp();
}
});
MainWindow.RemoveHotkey(UserSettingStorage.Instance.Hotkey);
//MainWindow.SetHotkey(ctlHotkey.CurrentHotkey, delegate
//{
// if (!MainWindow.IsVisible)
// {
// MainWindow.ShowApp();
// }
// else
// {
// MainWindow.HideApp();
// }
//});
//MainWindow.RemoveHotkey(UserSettingStorage.Instance.Hotkey);
UserSettingStorage.Instance.Hotkey = ctlHotkey.CurrentHotkey.ToString();
UserSettingStorage.Instance.Save();
}
@ -289,7 +289,7 @@ namespace Wox
UserSettingStorage.Instance.CustomPluginHotkeys.Remove(item);
lvCustomHotkey.Items.Refresh();
UserSettingStorage.Instance.Save();
MainWindow.RemoveHotkey(item.Hotkey);
//MainWindow.RemoveHotkey(item.Hotkey);
}
}