设置融合选项参数改为字符串类型
This commit is contained in:
parent
1862b885b3
commit
5f03edeb6c
|
@ -1476,8 +1476,8 @@ export default class ClientConnection {
|
||||||
}
|
}
|
||||||
|
|
||||||
public async SetBlendingOption(
|
public async SetBlendingOption(
|
||||||
id: number,
|
id: string,
|
||||||
value: number
|
value: string
|
||||||
) {
|
) {
|
||||||
return await this.doRpc<Protocol.NoneResponse>(
|
return await this.doRpc<Protocol.NoneResponse>(
|
||||||
new Protocol.SetBlendingOptionRequestEntity(
|
new Protocol.SetBlendingOptionRequestEntity(
|
||||||
|
|
|
@ -148,13 +148,13 @@
|
||||||
show_dialog.value = true;
|
show_dialog.value = true;
|
||||||
};
|
};
|
||||||
const send_hide_desktop = () => {
|
const send_hide_desktop = () => {
|
||||||
set?.SetBlendingOption(0, hide_desktop_value.value ? 1 : 0);
|
set?.SetBlendingOption(hide_desktop_value_id.value, hide_desktop_value.value ? "1" : "0");
|
||||||
};
|
};
|
||||||
const send_disable_blending_params = () => {
|
const send_disable_blending_params = () => {
|
||||||
set?.SetBlendingOption(1, disable_blending_params.value ? 1 : 0);
|
set?.SetBlendingOption(disable_blending_params_id.value, disable_blending_params.value ? "1" : "0");
|
||||||
};
|
};
|
||||||
const send_show_blending_grids = () => {
|
const send_show_blending_grids = () => {
|
||||||
set?.SetBlendingOption(1000, show_blending_grids.value ? 1 : 0);
|
set?.SetBlendingOption(show_blending_grids_id.value, show_blending_grids.value ? "1" : "0");
|
||||||
};
|
};
|
||||||
const resetall=()=>{
|
const resetall=()=>{
|
||||||
set?.ResetBlendingConfig()
|
set?.ResetBlendingConfig()
|
||||||
|
@ -163,8 +163,11 @@
|
||||||
const EnableBlending = ref(false);
|
const EnableBlending = ref(false);
|
||||||
let optionsstr = ref();
|
let optionsstr = ref();
|
||||||
optionsstr.value = "FusionLocale";
|
optionsstr.value = "FusionLocale";
|
||||||
const hide_desktop_value = ref(true);
|
const hide_desktop_value_id = ref("0");
|
||||||
|
const hide_desktop_value = ref(false);
|
||||||
|
const disable_blending_params_id = ref("1");
|
||||||
const disable_blending_params = ref(false);
|
const disable_blending_params = ref(false);
|
||||||
|
const show_blending_grids_id = ref("show_blending_grids");
|
||||||
const show_blending_grids = ref(false);
|
const show_blending_grids = ref(false);
|
||||||
const options = computed({
|
const options = computed({
|
||||||
get() {
|
get() {
|
||||||
|
@ -247,17 +250,18 @@
|
||||||
set?.GetBlendingConfig("").then((res) => {
|
set?.GetBlendingConfig("").then((res) => {
|
||||||
let tmp = JSON.parse(res ? res.config : "");
|
let tmp = JSON.parse(res ? res.config : "");
|
||||||
//console.log(tmp.options[0][1])
|
//console.log(tmp.options[0][1])
|
||||||
let local_options = [ [ref(0), hide_desktop_value], [ref(1), disable_blending_params], [ref(1000), show_blending_grids] ];
|
let local_options = [
|
||||||
|
[hide_desktop_value_id, hide_desktop_value],
|
||||||
|
[disable_blending_params_id, disable_blending_params],
|
||||||
|
[show_blending_grids_id, show_blending_grids]
|
||||||
|
];
|
||||||
let k:any;
|
let k:any;
|
||||||
for(k in local_options) {
|
for(k in local_options) {
|
||||||
let local_opt = local_options[k];
|
let local_opt = local_options[k];
|
||||||
let ii:any;
|
let opt = tmp.options[(<any>local_opt[0].value)];
|
||||||
for(ii in tmp.options){
|
if (opt)
|
||||||
let opt = tmp.options[ii];
|
{
|
||||||
if (2 == opt.length && local_opt[0].value == opt[0]){
|
local_opt[1].value = ("0" == opt || "false" == opt.toLowerCase() ? false : true);
|
||||||
local_opt[1].value = (opt[1] == 0 ? false : true);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
|
@ -3469,8 +3469,8 @@ export namespace Protocol {
|
||||||
|
|
||||||
export class SetBlendingOptionRequestEntity extends PacketEntity {
|
export class SetBlendingOptionRequestEntity extends PacketEntity {
|
||||||
constructor(
|
constructor(
|
||||||
id: number,
|
id: string,
|
||||||
value: number,
|
value: string,
|
||||||
rpc_id = 0
|
rpc_id = 0
|
||||||
) {
|
) {
|
||||||
super();
|
super();
|
||||||
|
@ -3478,10 +3478,10 @@ export namespace Protocol {
|
||||||
super.flag = PacketEntity.FLAG_REQUEST;
|
super.flag = PacketEntity.FLAG_REQUEST;
|
||||||
super.rpc_id = rpc_id;
|
super.rpc_id = rpc_id;
|
||||||
|
|
||||||
this.id = id ?? 0;
|
this.id = id ?? "";
|
||||||
this.value = value ?? 0;
|
this.value = value ?? "";
|
||||||
}
|
}
|
||||||
id = 0;
|
id;
|
||||||
value = 0;
|
value;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue