@wireapp/avs 10.2.32 → 10.2.34

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -174,6 +174,10 @@ export declare class Wcall {
174
174
  audioRecord(wuser: number, path: string): number;
175
175
  poll(): void;
176
176
  setupEx(flags: number): number;
177
+ eventCreate(userid: string, clientid: string, incomingh: WcallIncomingHandler, missedh: WcallMissedHandler, closeh: WcallCloseHandler, arg?: number): number;
178
+ eventStart(wuser: number): void;
179
+ eventProcess(wuser: number, buf: string, len: number, curr_time: number, msg_time: number, convid: string, userid: string, clientid: string, conv_type: number): number;
180
+ eventEnd(wuser: number): void;
177
181
  setMode(mode: number): void;
178
182
  getMode(): number;
179
183
  setUserMediaHandler(userMediaHandler: UserMediaHandler): void;
package/dist/avs_wcall.js CHANGED
@@ -605,6 +605,55 @@ var Wcall = /** @class */ (function () {
605
605
  Wcall.prototype.setupEx = function (flags) {
606
606
  return this.em_module.ccall("wcall_setup_ex", "number", ["number"], [flags]);
607
607
  };
608
+ Wcall.prototype.eventCreate = function (userid, clientid, incomingh, missedh, closeh, arg) {
609
+ var _this = this;
610
+ if (arg === void 0) { arg = 0; }
611
+ var fn_incomingh = this.em_module.addFunction(function (convid, msg_time, userid, clientid, video_call, should_ring, conv_type, arg) {
612
+ if (incomingh) {
613
+ incomingh(convid == 0 ? null : _this.em_module.UTF8ToString(convid), msg_time, userid == 0 ? null : _this.em_module.UTF8ToString(userid), clientid == 0 ? null : _this.em_module.UTF8ToString(clientid), video_call, should_ring, conv_type, arg);
614
+ }
615
+ }, "viiiiiiii");
616
+ var fn_missedh = this.em_module.addFunction(function (convid, msg_time, userid, clientid, video_call, arg) {
617
+ if (missedh) {
618
+ missedh(convid == 0 ? null : _this.em_module.UTF8ToString(convid), msg_time, userid == 0 ? null : _this.em_module.UTF8ToString(userid), clientid == 0 ? null : _this.em_module.UTF8ToString(clientid), video_call, arg);
619
+ }
620
+ }, "viiiiii");
621
+ var fn_closeh = this.em_module.addFunction(function (reason, convid, msg_time, userid, clientid, arg) {
622
+ if (closeh) {
623
+ closeh(reason, convid == 0 ? null : _this.em_module.UTF8ToString(convid), msg_time, userid == 0 ? null : _this.em_module.UTF8ToString(userid), clientid == 0 ? null : _this.em_module.UTF8ToString(clientid), arg);
624
+ }
625
+ }, "viiiiii");
626
+ return this.em_module.ccall("wcall_event_create", "number", ["string", "string", "number", "number", "number", "number"], [userid, clientid, fn_incomingh, fn_missedh, fn_closeh, arg]);
627
+ };
628
+ Wcall.prototype.eventStart = function (wuser) {
629
+ this.em_module.ccall("wcall_event_start", "null", ["number"], [wuser]);
630
+ };
631
+ Wcall.prototype.eventProcess = function (wuser, buf, len, curr_time, msg_time, convid, userid, clientid, conv_type) {
632
+ return this.em_module.ccall("wcall_event_process", "number", [
633
+ "number",
634
+ "string",
635
+ "number",
636
+ "number",
637
+ "number",
638
+ "string",
639
+ "string",
640
+ "string",
641
+ "number",
642
+ ], [
643
+ wuser,
644
+ buf,
645
+ len,
646
+ curr_time,
647
+ msg_time,
648
+ convid,
649
+ userid,
650
+ clientid,
651
+ conv_type,
652
+ ]);
653
+ };
654
+ Wcall.prototype.eventEnd = function (wuser) {
655
+ this.em_module.ccall("wcall_event_end", "null", ["number"], [wuser]);
656
+ };
608
657
  Wcall.prototype.setMode = function (mode) {
609
658
  this.em_module.ccall("wcall_set_mode", "null", ["number"], [mode]);
610
659
  };
package/package.json CHANGED
@@ -27,5 +27,5 @@
27
27
  "prepack": "prettier -w src/avs_wcall.ts && tsc && cp src/*.js src/*.d.ts dist/",
28
28
  "test": "karma start"
29
29
  },
30
- "version": "10.2.32"
30
+ "version": "10.2.34"
31
31
  }