Progress towards OSX agent, not ready yet.
This commit is contained in:
parent
832868c90e
commit
af28237901
Binary file not shown.
Binary file not shown.
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "meshcentral",
|
||||
"version": "0.2.2-x",
|
||||
"version": "0.2.3-a",
|
||||
"keywords": [
|
||||
"Remote Management",
|
||||
"Intel AMT",
|
||||
|
|
|
@ -1995,6 +1995,7 @@
|
|||
desk.m.showmouse = true;
|
||||
desk.m.onKvmData = function (data) { console.log('KVM Data received in multi-desktop mode, this is not supported.'); }; // KVM Data Channel not supported in multi-desktop right now.
|
||||
//desk.m.onScreenSizeChange = deskAdjust;
|
||||
if (debugmode > 0) { desk.m.onScreenSizeChange = mdeskAdjust; } // Multi-Desktop Adjust
|
||||
desk.Start(nodeid, 16994, '*', '*', 0);
|
||||
desk.contype = 2;
|
||||
multiDesktop[nodeid] = desk;
|
||||
|
@ -2009,6 +2010,7 @@
|
|||
desk.m.FrameRateTimer = multidesktopsettings.framerate;
|
||||
//desk.m.onDisplayinfo = deskDisplayInfo;
|
||||
//desk.m.onScreenSizeChange = deskAdjust;
|
||||
if (debugmode > 0) { desk.m.onScreenSizeChange = mdeskAdjust; } // Multi-Desktop Adjust
|
||||
desk.Start(nodeid);
|
||||
desk.contype = 1;
|
||||
multiDesktop[nodeid] = desk;
|
||||
|
@ -3967,6 +3969,26 @@
|
|||
}
|
||||
}
|
||||
|
||||
function mdeskAdjust(mod, sw, sh, cv) {
|
||||
if (!mod || !sw || !sh || !cv) return;
|
||||
|
||||
// Check if we are in single desktop mode
|
||||
if (cv.id == "Desk") { deskAdjust(); return; }
|
||||
|
||||
// Figure out and adjust the size to fill the width of the div
|
||||
var vsize = [{ x: 180, y: 101 }, { x: 302, y: 169 }, { x: 454, y: 255 }][Q('sizeselect').selectedIndex];
|
||||
var realw = vsize.x + 2, tw = Q('xdevices').clientWidth - 30, xw = Math.floor(tw / realw);
|
||||
xw = realw + Math.floor((tw - (xw * realw)) / xw);
|
||||
vsize.y = vsize.y * (xw / vsize.x);
|
||||
vsize.x = xw;
|
||||
var mh = vsize.y, mw = vsize.x;
|
||||
if (mod.State != 0) { mh = vsize.y; mw = (sw / sh) * vsize.y; }
|
||||
QS(cv.id)['max-height'] = mh + 'px';
|
||||
QS(cv.id)['max-width'] = mw + 'px';
|
||||
QS(cv.id)['margin-top'] = '0';
|
||||
QS(cv.id)['margin-bottom'] = '0';
|
||||
}
|
||||
|
||||
// Remote desktop special key combos for Windows
|
||||
function deskSendKeys() {
|
||||
if (xxdialogMode || desktop == null || desktop.State != 3) return;
|
||||
|
|
|
@ -1682,7 +1682,7 @@ module.exports.CreateWebServer = function (parent, db, args, certificates) {
|
|||
// Skip all folder entries
|
||||
zipfile.readEntry();
|
||||
} else {
|
||||
if (entry.fileName == 'Mesh Agent.mpkg/Contents/distribution.dist') {
|
||||
if (entry.fileName == 'Meshcentral_MeshAgent.mpkg/Contents/distribution.dist') {
|
||||
// This is a special file entry, we need to fix it.
|
||||
zipfile.openReadStream(entry, function (err, readStream) {
|
||||
readStream.on("data", function (data) { if (readStream.xxdata) { readStream.xxdata += data; } else { readStream.xxdata = data; } });
|
||||
|
@ -1704,8 +1704,8 @@ module.exports.CreateWebServer = function (parent, db, args, certificates) {
|
|||
}
|
||||
});
|
||||
zipfile.on("end", function () {
|
||||
archive.file(argentInfo.path, { name: "Mesh Agent.mpkg/Contents/Packages/meshagent.pkg/Contents/MeshAgent" });
|
||||
archive.append(meshsettings, { name: "Mesh Agent.mpkg/Contents/Packages/meshagent.pkg/Contents/MeshAgent.msh" });
|
||||
archive.file(argentInfo.path, { name: "Meshcentral_MeshAgent.mpkg/Contents/Packages/meshagentosx64.pkg/Contents/meshagent_osx64.bin" });
|
||||
archive.append(meshsettings, { name: "Meshcentral_MeshAgent.mpkg/Contents/Packages/meshagentosx64.pkg/Contents/meshagent_osx64.msh" });
|
||||
archive.finalize();
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue