Various cleanup and CR

This commit is contained in:
Zach Fox 2019-11-14 15:45:52 -08:00
parent e21ee20ff8
commit 5229b0c0f3
6 changed files with 24 additions and 46 deletions

View file

@ -889,10 +889,6 @@ bool setupEssentials(int& argc, char** argv, bool runningMarkerExisted) {
DependencyManager::set<ScriptCache>();
DependencyManager::set<SoundCache>();
DependencyManager::set<SoundCacheScriptingInterface>();
#ifdef HAVE_DDE
DependencyManager::set<DdeFaceTracker>();
#endif
DependencyManager::set<AudioClient>();
DependencyManager::set<AudioScope>();
DependencyManager::set<DeferredLightingEffect>();

View file

@ -1,5 +1,4 @@
<!--
screenshareApp.html
Created by Milad Nazeri, Rebecca Stankus, and Zach Fox 2019/11/13
@ -7,7 +6,6 @@ Copyright 2019 High Fidelity, Inc.
Distributed under the Apache License, Version 2.0.
See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
-->
<html>
@ -23,26 +21,13 @@ See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.
<div id="select_screen">
<div class="scrollbar" id="style-1">
<div class="force-overflow">
<div id="selects">
<!-- <div class="box"> -->
<!-- <div class="heading"> -->
<!-- <div class="circle"></div> -->
<!-- <span class=" abel">Screen 1</span> -->
<!-- </div> heading -->
<!-- <div class="image"> -->
<!-- </div> -->
<!-- </div> box -->
</div>
</div>
</div>
</div>
<div id="confirmation_screen" style="display: none;">
<div id="share_pick">
</div> <!-- share_pick -->
<div id="confirmation_text" style="color: white;">
<p>

View file

@ -112,12 +112,12 @@ function sortSources(){
} else {
applicationSources.push(source)
}
})
});
screenSources.sort((a, b) => {
let aNumber = a.name.replace(/[^\d]/, "");
let bNumber = b.name.replace(/[^\d]/, "");
return aNumber - bNumber;
})
});
let finalSources = [...screenSources, ...applicationSources];
return finalSources;
}
@ -158,6 +158,7 @@ function showSources() {
console.log("Error getting sources", error);
}
for (let source of sources) {
// change this to a regex - thanks milad
if (source.name.indexOf(SCREENSHARE_TITLE) > -1){
continue;
}
@ -191,7 +192,7 @@ function gotStream(stream) {
stream.onended = () => {
if (desktopSharing) {
toggle();
togglePage();
}
};
}
@ -287,11 +288,11 @@ ipcRenderer.on('connectionInfo', function(event, message){
token = connectionInfo.token;
initializeTokboxSession();
})
});
// Show the initial sources after the dom has loaded
// Sources come from electron.desktopCapturer
document.addEventListener("DOMContentLoaded", () => {
showSources();
})
});

View file

@ -11,7 +11,7 @@ const {app, BrowserWindow, ipcMain} = require('electron');
const gotTheLock = app.requestSingleInstanceLock()
const argv = require('yargs').argv;
// ./screenshare.exe --userName=miladN ...
const connectionInfo = {
token: argv.token || "token",
projectAPIKey: argv.projectAPIKey || "projectAPIKey",
@ -19,7 +19,7 @@ const connectionInfo = {
}
// Mac and Pc need slightly different width and height sizes.
// Mac and PC need slightly different width and height sizes.
const osType = require('os').type();
let width;
let height;

View file

@ -1,10 +1,6 @@
body {
background-color: black;
box-sizing: border-box;
/* display: -webkit-flex; */
/* -webkit-justify-content: center; */
/* -webkit-align-items: center; */
/* -webkit-flex-direction: column; */
font-family: "Graphik";
margin: 0px 22px 10px 22px;
}