本文整理汇总了C#中Parameters.AddInt方法的典型用法代码示例。如果您正苦于以下问题:C# Parameters.AddInt方法的具体用法?C# Parameters.AddInt怎么用?C# Parameters.AddInt使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Parameters
的用法示例。
在下文中一共展示了Parameters.AddInt方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: OnEventGetMenu
private static void OnEventGetMenu()
{
if (GetMenu is EventGetMenu)
{
var menu = new List<Menu>();
GetMenu(menu);
if (IsRegistered)
{
using (var parameters = new Parameters())
{
parameters.AddInt((int)Function.GetMenu).AddInt((int)Id).AddInt(menu.Count);
for (int i = menu.Count - 1; i >= 0; i--)
{
parameters.AddStructure(menu[i]);
}
APICall(parameters);
}
}
}
}
示例2: AddFolderWatcher
public static void AddFolderWatcher(int FolderId, FolderWatcherActions Actions, string Folder)
{
if (IsRegistered)
{
using (var parameters = new Parameters())
{
APICall(parameters
.AddInt((int)Function.AddFolderWatcher)
.AddInt((int)Id)
.AddInt(FolderId)
.AddInt((int)Actions)
.AddString(Folder));
}
}
}
示例3: RemoveFolderWatcher
public static void RemoveFolderWatcher(int FolderId)
{
if (IsRegistered)
{
using (var parameters = new Parameters())
{
APICall(parameters
.AddInt((int)Function.RemoveFolderWatcher)
.AddInt((int)Id)
.AddInt(FolderId));
}
}
}
示例4: GetConfig
private static void GetConfig()
{
if (IsRegistered)
{
using (var parameters = new Parameters())
{
APICall(parameters
.AddInt((int)Function.GetConfig)
.AddInt((int)Id));
}
}
}
示例5: SetNotification
public static void SetNotification(bool Visible, string Text, NotificationPosition Position)
{
if (IsRegistered)
{
using (var parameters = new Parameters())
{
APICall(parameters
.AddInt((int)Function.SetNotification)
.AddInt((int)Id)
.AddInt((int)(Visible ? 1 : 0))
.AddString(Text)
.AddInt((int)Position));
}
}
}
示例6: SetConfig
private static void SetConfig()
{
if (IsRegistered)
{
using (var parameters = new Parameters())
{
APICall(parameters
.AddInt((int)Function.SetConfig)
.AddInt((int)Id)
.AddInt((int)(keepInDock ? 1 : 0))
.AddInt((int)(activatable ? 1 : 0))
.AddInt((int)(exposable ? 1 : 0))
.AddInt((int)(bounceable ? 1 : 0)));
}
}
}
示例7: BounceStop
public static void BounceStop()
{
if (IsRegistered)
{
using (var parameters = new Parameters())
{
APICall(parameters
.AddInt((int)Function.BounceStop)
.AddInt((int)Id));
}
}
}
示例8: Bounce
public static void Bounce(BounceType Type, int Count)
{
if (IsRegistered)
{
using (var parameters = new Parameters())
{
APICall(parameters
.AddInt((int)Function.Bounce)
.AddInt((int)Id)
.AddInt((int)Type)
.AddInt((int)Count));
}
}
}
示例9: Remove
public static void Remove()
{
if (IsRegistered)
{
using (var parameters = new Parameters())
{
APICall(parameters
.AddInt((int)Function.Remove)
.AddInt((int)Id));
}
Id = IntPtr.Zero;
UId = IntPtr.Zero;
}
}
示例10: Register
public static void Register(string DefaultIcon, string Title, bool Bounceable)
{
if (!IsRegistered)
{
Initilize();
iconName = DefaultIcon;
title = Title;
bounceable = Bounceable;
using (var parameters = new Parameters())
{
Id = APICall(parameters
.AddInt((int)Function.Register)
.AddString(Process.GetCurrentProcess().MainModule.FileName)
.AddInt(HwndSource.Handle.ToInt32())
.AddString(DefaultIcon)
.AddString(Title)
.AddInt((int)UId)
.AddInt(Bounceable ? 1 : 0));
}
using (var parameters = new Parameters())
{
UId = APICall(parameters
.AddInt((int)Function.GetUId)
.AddInt((int)Id));
}
}
}