Ejemplo n.º 1
0
        /// <summary>
        /// 初始化
        /// </summary>
        /// <param name="arg"></param>
        public void init(ref Init_Param arg, bool open = true)
        {
            gchandld  = GCHandle.Alloc(this);
            iPtrThis_ = GCHandle.ToIntPtr(gchandld);
            arg.ctx   = iPtrThis_;
            arg.open  = open;
            if (arg.port == 0)
            {
                arg.port = 6001;
            }
            if (arg.listenCount == 0)
            {
                arg.listenCount = 60;
            }
            bool sus = rbt_win_init(ref arg);

            BindEvent();
        }
Ejemplo n.º 2
0
        /// <summary>
        /// 初始化
        /// </summary>
        /// <param name="arg"></param>
        public void init(ref Init_Param arg, bool open = true)
        {
            gchandld  = GCHandle.Alloc(this);
            iPtrThis_ = GCHandle.ToIntPtr(gchandld);
            arg.ctx   = iPtrThis_;
            arg.open  = open;
            if (arg.port == 0)
            {
                arg.port = 6001;
            }
            if (arg.listenCount == 0)
            {
                arg.listenCount = 60;
            }
            bool sus = rbt_win_init(ref arg);

            /*int size = Marshal.SizeOf(typeof(Init_Param));
             * System.Diagnostics.Debug.WriteLine(size);//*/

            onorigindatanew = new onOriginDataNew(originDataNotifyNew);
            rbt_win_set_origindata_cb(onorigindatanew);
            ondevicemac = new onDeviceMac(deviceMacNotify);
            rbt_win_set_devicemac_cb(ondevicemac);
            ondevicekeyPress = new onDeviceKeyPress(deviceKeyPress);
            rbt_win_set_devicekeypress_cb(ondevicekeyPress);
            ondeviceshowpagenew = new onDeviceShowPageNew(deviceShowPageNew);
            rbt_win_set_deviceshowpage_cb(ondeviceshowpagenew);
            ondevicedisconnect = new onDeviceDisconnect(deviceDisconnect);
            rbt_win_set_devivedisconnect_cb(ondevicedisconnect);
            ondeviceanswerresult = new onDeviceAnswerResult(deviceAnswerResult);
            rbt_win_set_deviceanswerresult_cb(ondeviceanswerresult);
            ondevicename = new onDeviceName(deviceNameNotify);
            rbt_win_set_devicename_cb(ondevicename);
            ondevicenameresult = new onDeviceNameResult(deviceNameResultNotify);
            rbt_win_set_devicenameresult_cb(ondevicenameresult);
            onerror = new onError(deviceError);
            rbt_win_set_error_cb(onerror);
            oncanvasid = new onCanvasID(deviceClearCanvas);
            rbt_win_set_canvasid_cb(oncanvasid);
            onoptimizedata = new onOptimizeData(optimizeData);
            rbt_win_set_optimizedata_cb(onoptimizedata);
        }
Ejemplo n.º 3
0
        /// <summary>
        /// 初始化
        /// </summary>
        /// <param name="arg"></param>
        public void init(ref Init_Param arg, bool open = true)
        {
            gchandld  = GCHandle.Alloc(this);
            iPtrThis_ = GCHandle.ToIntPtr(gchandld);
            arg.ctx   = iPtrThis_;
            arg.open  = open;
            if (arg.port == 0)
            {
                arg.port = 6001;
            }
            if (arg.listenCount == 0)
            {
                arg.listenCount = 60;
            }
            bool sus = rbt_win_init(ref arg);

            /*int size = Marshal.SizeOf(typeof(Init_Param));
             * System.Diagnostics.Debug.WriteLine(size);//*/

            BindEvent();
        }
Ejemplo n.º 4
0
 internal static extern bool rbt_win_init(ref Init_Param arg);