query
stringlengths
7
355k
document
stringlengths
9
341k
metadata
dict
negatives
sequencelengths
0
101
negative_scores
sequencelengths
0
101
document_score
stringlengths
3
10
document_rank
stringclasses
102 values
Reset the state of the current subunit. The following activities are performed while resetting the state of the current subunit. 1. Set the state of the tutor to READY. 2. Set the number of errors made to 0. 3. Clear the input textarea element.
function resetSubunit() { my.current.state = my.STATE.READY my.current.errors = 0 my.html.input.value = '' log('state', my.current.state.toUpperCase(), 'unit', my.current.unitNo + '.' + my.current.subunitNo, 'type', my.settings.unit) updatePracticePaneState() updatePracticePane() clearAdvice() clearResultTooltips() }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function reset() {\n\tstate.questionCounter = 0;\n\tstate.score = 0;\n\tstate.questions = [\n\t\t{\n\t\t\tid: 0,\n\t\t\tpregunta: 'Ets un/a Vilafranquí/ina de Tota la Vida? Prova el test!',\n\t\t\trespostes: [],\n\t\t\tcorrecte: null,\n\t\t},\n\t];\n\tstate.collectedAnswers = [];\n\tstate.comodinsLeft = state.comodinsInitial;\n\tstate.comodiUsedInQuestion = false;\n\tstate.comodiButtonExpanded = false;\n\t// display initial question\n\tdisplayInitialQuestion();\n}", "function resetAllStates() {\n // Set the timer back to 75\n time = 75;\n // Show the timer to the user\n shownTime.text(time);\n // Set endQuiz variable to false\n quizEnded = false;\n // Set the userAnswers array to be empty\n userAnswers = [];\n // Set the scoreboard input value to be empty\n userNameInput.val('');\n}", "function reset() {\n\tiQ = 0;\n\ttotal = iQ;\n\tnumCorrect = 0;\n\t$('.explanationBlock').text('');\n\tupdate();\n\tsetCurrent();\n\tsetZero();\n}", "function resetSettings()\n {\n my.settings.unit = my.UNIT.MAIN\n }", "resetStatus() {\n this.busy = false;\n this.errors.forget();\n this.successful = false;\n }", "reset() {\n this.interacted = false;\n if (this._completedOverride != null) {\n this._completedOverride = false;\n }\n if (this._customError != null) {\n this._customError = false;\n }\n if (this.stepControl) {\n this.stepControl.reset();\n }\n }", "reset() {\r\n this.currentState = this.initial;\r\n }", "function reset()\n\t{\n\t\tsetValue('')\n\t}", "reset(){\n this.enable();\n this.init();\n this.buildAll();\n }", "resetTimer() {\n this.timeSelected = 0;\n this.completeElapsed = 0;\n this.complete = false;\n }", "reset() {\n this.gameInProgress = true; // true if playing game, false if ended\n\n // 1.) available players\n this.createCharacters();\n this.displayAvailableCharacters(this.characters);\n\n // Number enemies defeated\n this.enemiesDefeated = 0;\n this.defeatedCharacters.length = 0;\n this.defeatedCharacters = [];\n this.displayDefeatedCharacters(this.defeatedCharacters);\n\n // get rid of player and enemy\n this.currentPlayer = undefined;\n this.currentEnemy = undefined;\n\n // Interact with the DOM\n this.displayGameStatus();\n }", "function reset() {\n tfInput.value = \"\";\n tfResultado.value = \"\";\n taLogArea.value = \"\";\n numPrevio = 0;\n numActual = 0;\n numAcumulado = 0;\n strOperacion = \"\";\n cOperador = \"\";\n}", "function reset() {\n\t setState(null);\n\t} // in case of reload", "reset() {\r\n this.activeState = this.config.initial;\r\n }", "function reset() {\n\n //clear enemies\n allEnemies.length = 0;\n //clear any text messages from the heads-up display.\n hud.textElements.length = 0;\n }", "reset() {\r\n this.currentState = this.config.initial;\r\n }", "reset() {\r\n this.state = this.initial;\r\n }", "reset() {\r\n this.currentState = this.initalState;\r\n this.clearHistory();\r\n }", "reset(){\n\t\tif(model.autoRunTimerId !== -1){\n\t\t\tclearInterval(model.autoRunTimerId) // stop autorun timer if it is started\n\t\t\t//document.getElementById('autoRunBtn').innerHTML='Autorun';\n\t\t}\n\n\t\t$(\"#infoBitNum\").prop('disabled', false);\n\t\t$(\"#parityBitNum\").prop('disabled', false);\n\t\t$(\"#cwBitNum\").prop('disabled', false);\n\t\t$(\"#errDetectNum\").prop('disabled', false);\n\t\t$(\"#selGenPolyBtn\").prop('disabled', false);\n\n\t\tthis.algorithm.reset();\n\t\tthis.stat.reset();\n\t\tthis.stat.remove();\n\t\tthis.layer.getStage().clear();\n\t\tthis.layer.destroy();\n\t\ttry{\n\t\t\t$(\".ui-dialog-content\").dialog(\"close\");\n\t\t} catch(e) {console.log(e)}\n\t}", "resetState() {\n this.state = states.WAITING_FOR_CHOICE;\n }", "reset() {\n this.resetFields();\n this.resetStatus();\n }", "function resetQuiz() {\n // Clear out what's in the results container\n resultsContainer.innerText = \"\";\n // Clear out the quiz container\n quizContainer.innerHTML = \"\";\n // Rebuild the quiz\n buildQuiz();\n }", "function resetWholeQuestion(){\n\t\tresetQuestion();\n\t\tresetChoices();\t\n\t}", "reset() {\r\n this.prevState=this.currentState;\r\n this.currentState = this.config.initial;\r\n }", "function reset () {\n answer = \"\";\n if (questionCount < questions.length) {\n $(\".game\").html(\"\");\n $(\"#choices\").html(\"\");\n questionSetup();\n time = 20;\n }\n else {\n finish();\n }\n }", "reset() {\r\n this.state=this.initial;\r\n this.statesStack.clear();\r\n\r\n }", "function resetAll() {\n playerMoney = 1000;\n winnings = 0;\n jackpot = 5000;\n turn = 0;\n playerBet = 5;\n maxBet = 20;\n winNumber = 0;\n lossNumber = 0;\n winRatio = false;\n\n resetText();\n\n setEnableSpin();\n}", "reset() {\n this._setTreeStatus('');\n this._checkedAutorollers = new Set();\n this._selectedTreeStatus = '';\n this.setAttribute('collapsed', '');\n this._render();\n }", "reset() {\n this._updateSelectedItemIndex(0);\n this.steps.forEach(step => step.reset());\n this._stateChanged();\n }", "function reset() {\n numAnsRight = 0;\n numAnsWrong = 0;\n numTimedOut = 0;\n questionCount = 0;\n nextQuestion();\n console.log(\"game started\");\n }", "function reset() {\n // Stop automatic resets\n clearTimeout(resetTimeout);\n\n // Reset complete status\n levelComplete = false;\n\n // Reset physics\n // flag.body.mass = 0; // Make it stay where it is\n flag.body.setZeroVelocity();\n flag.body.x = currentLevel.flag[0];\n flag.body.y = currentLevel.flag[1];\n\n // Set initial positions\n player.body.setZeroVelocity();\n player.body.x = currentLevel.player[0];\n player.body.y = currentLevel.player[1];\n\n mode = null;\n\n if (music) {\n game.sound.remove(music);\n }\n\n // Remove text\n if (levelText) {\n levelText.forEach(function(text) {\n text.destroy();\n });\n }\n\n if (startText) {\n startText.destroy();\n }\n\n // Play music\n music = game.add.audio(currentLevel.music);\n music.play();\n\n setSpriteDirection(player, currentLevel.facing);\n\n // Text for starting the game\n startText = drawText();\n\n // Disable input\n runDisabled = true;\n\n countDown = true;\n}", "function reset() {\n self.taskActionList([]);\n self.selectedTasklist([]);\n self.isTaskSelected(false);\n self.actionName('');\n self.actionComments('');\n self.showConfirmation('none');\n }", "reset() {\n this.stop();\n $(this._timerElemjQuery).text(\"00\");\n this._start = null;\n this._duration = 0;\n }", "reset() {\n this.stop();\n $(this._timerElemjQuery).text(\"00\");\n this._start = null;\n this._duration = 0;\n }", "function reset_all(){\n input = \"\";\n result = \"0\";\n history = \"0\";\n answer = \"\";\n setResult(\"0\");\n setHistory(\"0\");\n }", "reset() {\r\n this.setState(this.baseState);\r\n }", "function resetScreen() {\n currentOperationScreen.textContent = '0';\n lastOperationScreen.textContent = 'xxx';\n holdOne = '';\n holdTwo = '';\n currentOperation = null;\n}", "function reset() {\n // Reset (re-initalize) race object\n window[race_view].init();\n\n // reset spent resources display\n $(\"#\" + race_view + \"-supply\")\n .html(\n window[race_view].total_cost.supply.used + \n \" / \" +\n window[race_view].total_cost.supply.total\n );\n\n // Update mineral display\n $(\"#\" + race_view + \"-mineral\")\n .html(window[race_view].total_cost.mineral);\n\n // Update vespene display\n $(\"#\" + race_view + \"-vespene\")\n .html(window[race_view].total_cost.vespene);\n\n // Update time display\n $(\"#\" + race_view + \"-time\")\n .html(\"00:00\");\n \n // reset build view\n $(\"#\" + race_view + \"-build\")[0].innerHTML = \"\";\n}", "function reset() {\n \n $(\"#writeQuestion\").html('');\n $(\"#allAnswers\").html('');\n\n clock = 31;\n runClock();\n\n questionNum = 0;\n printQuestions();\n\n wins = 0;\n losses = 0;\n unanswer = 0;\n\n pickedAnswer();\n\n}", "Reset() {\n ui.Reset();\n\n pipeMan.Reset();\n state.Reset();\n scoreText.SetScore(0);\n\n player.Reset();\n player.StartScreenBob();\n\n //reset tiled bg\n bg.tilePositionX = 0;\n ground.tilePositionX = 0;\n }", "function reset(){\n questionCount = 0;\n unanswered = 0;\n wrong = 0;\n right = 0;\n $(\"#allQuestions\").html('');\n $(\"#score\").html('');\n $(\"#timeLeft\").html('');\n }", "function reset(){\n\tloading(false);\n\t$('#start').slideDown();\n\t$('#reset').slideUp();\n\t$('#mainDisplay').slideUp();\n\t$('input').val('');\n}", "reset()\n {\n super.reset();\n this._roomName = this._room.get().name;\n this._targets = this.UpdateEnegry();\n this._requiredCreeps = this.MakeRequirement();\n }", "function resetGame() {\n \n // reset varaibles\n wrong = 0;\n correct = 0;\n index = -1;\n \n // Update HTML\n clearContent();\n\n // Restart game\n loadQuestion();\n }", "reset() {\n this.life = 3;\n this.collected = 0;\n this.level = 0;\n this.score = 0;\n this.scoreWater = 0;\n this.collectedFly = 0;\n this.collectedDragonfly = 0;\n this.collectedButterfly = 0;\n levels.textContent = \"EGG\";\n lives.innerHTML = this.life;\n collectedItems.innerHTML = this.collected;\n collectedFlies.innerHTML = this.collectedFly;\n collectedDragonflies.innerHTML = this.collectedDragonfly;\n collectedButterflies.innerHTML = this.collectedButterfly;\n scoreboard.innerHTML = this.score;\n scoreboardWater.innerHTML = this.scoreWater;\n this.modalShow(startModal, startBtn);\n }", "function resetForm() {\n btwResult.innerHTML = \"\";\n totaalZonderBtwResult.innerHTML = \"\";\n result.innerHTML = \"\";\n bedragInput.value = \"\";\n totaal.value = \"\";\n totaalBedrag = 0;\n}", "function reset() {\n generateLevel(0);\n Resources.setGameOver(false);\n paused = false;\n score = 0;\n lives = 3;\n level = 1;\n changeRows = false;\n pressedKeys = {\n left: false,\n right: false,\n up: false,\n down: false\n };\n }", "reset(){\n\t\tif(!this.empty){\n\t\t\t$(this.element).val(\"\");\n\t\t\tthis.hideErrorMessage();\n\t\t\tthis.removeValidity();\n\t\t\tthis.setErrorMessage(this.emptyMassage);\n\t\t\tthis.insertErrorMessage();\n\t\t\tthis.setEmpty(true);\n\t\t}\n\t}", "function resetState() {\n clearStatusClass(document.body);\n nextButton.classList.add(\"hide\");\n while (answerButtonsElement.firstChild) {\n answerButtonsElement.removeChild(answerButtonsElement.firstChild);\n }\n // removes \"correct\" and \"wrong\" to remove styling for correct/wrong choices\n container.classList.remove(\"correct\");\n container.classList.remove(\"wrong\");\n}", "function resetArena(){\n resetSteps(); //resets the steps display to be blank\n resetStarted(); //sets all started booleans to be false\n done = false; \n started = false;\n sortSelector.disabled = false; //incase nextStep gets interrupred by hitting select\n resetColor(); //changes all colors back to default\n}", "reset() {\n this.completed = false;\n this.pieceDropped = null;\n this.pieceDroppedInto = null;\n this.refresh();\n //@ts-ignore\n if (!this.puzzle.options.disabled) {\n this.enable();\n }\n }", "reset() {\n store.dispatch('setIsUnsavedChanges', { isUnsavedChanges: true });\n this.data = {};\n this.activeIndex = 0;\n this.activeCaption = '';\n }", "function clearForm() {\n clearUnitDetails();\n clearUnits();\n }", "function resetQuiz() {\n state.correctCount = 0;\n state.currentQuestionIndex = 0;\n}", "reset(){\n this.setState({\n inputField: '',\n userInput: '',\n edits: [],\n savedInput: '',\n wrongWords: '',\n newEditState: '',\n })\n }", "function reset() {\n quizMetrics.changeState(\"results\", false);\n quizMetrics.numCorrect = 0;\n \n for(var i = 0; i < dataSvc.quizQuestions.length; i++) {\n var data = dataSvc.quizQuestions[i];\n \n data.selected = null;\n data.correct = null;\n }\n }", "reset() {\n if (!this._running) {\n this._currentState = undefined;\n }\n }", "function reset() {\n setSeconds(duration);\n setRunning(false);\n }", "_reset() {\n this.setState({\n error: null,\n progress: 0,\n step: 0,\n nameFirst: ``,\n nameLast: ``,\n email: ``,\n phone: ``,\n salary: ``\n });\n }", "reset() {\n state = createGameState();\n notifyListeners();\n }", "function reset(){\n wins = 0;\n loses = 0;\n i = 0;\n $(\".reset\").remove();\n displayQuestionAndSelections();\n }", "clearGame() {\n this.state.numberOfProblems = 0;\n this.state.numberOfProblemsSolved = 0;\n this.state.expressions = [];\n this.state.solutions = [];\n this.state.level = '';\n this.state.operators = [];\n this.state.currentTime = '0.0';\n }", "function resetState() {\n clearStatusClass(document.body)\n while (answerButtonsElement.firstChild) {\n answerButtonsElement.removeChild(answerButtonsElement.firstChild)\n }\n}", "reset() {\n this._setIsResetting(true);\n this._setFinish(false);\n this.activeStep = undefined;\n this.nextStep = undefined;\n for (let i = 0; i < this._steps.length; i++) {\n const step = this.getStepById(i);\n step.reset(this.openFirstStepOnStartup);\n }\n this._setIsResetting(false);\n }", "resetState() {\n this.setState({\n show: false,\n currCode: null,\n latest: 0,\n performance: 0,\n capital: 0,\n amount: 0,\n potential: 0,\n multiplier: 1.5,\n prediction: 1,\n err: false,\n err_msg: null\n })\n }", "reset() {\r\n this.state = this.config.initial;\r\n }", "resetToInitialState() {\n this._itemsManager.reset();\n this._directionsManager.reset();\n if(this._currentGuide) {\n this._currentGuide.finish();\n this._currentGuide = null;\n }\n }", "reset() {\n this.hideContent();\n this.hideChart();\n this.selectVars.html('');\n this.selectTarget.html('');\n this.chartField.xSelect.html('');\n this.chartField.ySelect.html('');\n this.chartField.tSelect.html('');\n this.notesInput.val('');\n }", "function reset() {\n resetButton.innerHTML = \"RESET\";\n winner.classList.add(\"hide\");\n numShotsOne.innerHTML = 0;\n numShotsTwo.innerHTML = 0;\n numGoalsOne.innerHTML = 0;\n numGoalsTwo.innerHTML = 0;\n resetSpan.classList.remove(\"hide\");\n leftDiv.classList.add(\"possessionIndicator\");\n rightDiv.classList.remove(\"possessionIndicator\");\n toggleTeamDivs();\n running = true;\n}", "function _reset() {\n //Clear console.\n $(\"#console-area\").val(\"\");\n\n //Show sign in boxes.\n $(\"#div-signin\").show();\n\n //Hide all API actions DIV until successful sign in.\n $(\"#actions\").hide();\n\n //Hide agent info DIV until successful sign in.\n $(\"#div-signout\").hide();\n\n //Reset agent info data.\n $(\"#span-agent-info\").html(\"\");\n\n //Clear the dial number field.\n $(\"#field-call-control-make-dialnum\").val(\"\");\n\n //Clear the callid field.\n $(\"#field-call-control-callid\").val(\"\");\n}", "function reset() { }", "reset() {\r\n this.state = this.config.initial;\r\n }", "function reset () {\n\tthis.num1 = 0;\n\tthis.num2 = 0;\n\tthis.operator = \"\";\n\tdisplayNum.innerHTML = 0;\n\tdecimal = 0;\n}", "function resetear() {\n eliminarIntegrantesAnteriores();\n ocultarbotonCalculo();\n ocultarIntegrantes();\n ocultarTextoResultado();\n vaciarValorInput();\n}", "function reset() {\n humanChoices = [];\n computerChoices = [];\n level = 0;\n gameOver = false;\n}", "function reset () {\r\n\t\t\tself.vehicle = {};\r\n\t\t\t$('#branch_name_value').val('');\r\n\t\t\t$('#vehicle_type_value').val('');\r\n\t\t\tself.heading = \"Master\";\r\n\t\t\tfetchAllVehicles();\r\n\t\t}", "function reset() {\n result = (\"\");\n choices = [];\n}", "function reset() {\n $(\"#startbtn\").show();\n $(\"#letsplay\").show();\n $(\"#trivia\").hide();\n $(\"#results\").hide();\n resetTimer();\n questionCount = 0;\n correctAnswers = 0;\n incorrectAnswers = 0;\n unansweredQuestions = 0;\n timeLeft = 15;\n }", "function reset() {\n setSeconds(0);\n setIsActive(false);\n }", "Reset () {\n this.reset = true\n }", "reset() {\n this.running = false;\n window.cancelAnimationFrame(this.frameReq);\n clearTimeout(this.timeout);\n this.els.seconds.textContent = this.duration / 1000;\n this.els.ticker.style.height = null;\n this.els.definition.textContent = ''; \n this.els.rhymes.textContent = ''; \n this.element.classList.remove('countdown--ended');\n }", "function reset() {\n student_name_input = 0;\n student_course_input = 0;\n student_grade_input = 0;\n student_grade_average = 0;\n updateData();\n updateStudentList()\n }", "function reset() {\n $(\"#resetQuest\").click(function () {\n $(\"#resetQuest\").css(\"visibility\", \"hidden\");\n $(\"#endScreen\").html(\" \");\n $(\"#questAns\").css(\"visibility\", \"visible\");\n $(\"#time\").css(\"visibility\", \"visible\");\n $(\"#countdown\").css(\"visibility\", \"visible\");\n $(\"#answers\").css(\"visibility\", \"visible\");\n $(\"#question\").css(\"visibility\", \"visible\");\n $(\"#endScreen\").css(\"visibility\", \"hidden\");\n timer = 30;\n timeCount = 30;\n rightCount = 0;\n wrongCount = 0;\n //starting question/answer combo\n questCount = 0;\n // a question/answer team appears\n $(\"#question\").html(questAns[questCount].question);\n console.log(questAns[questCount].question);\n getQ();\n\n }\n )\n }", "function reset() {\n setTitle(budget.title)\n setDescription(budget.description)\n setTotal(budget.total)\n setCategories(budget.Categories)\n setEditedCategories(budget.Categories)\n setNewCategories([])\n setCategoriesToDelete([])\n setNewCategoryTitle(\"\")\n setNewCategoryAmount(\"\")\n setError(\"\")\n }", "reset(){\n this.live = 3;\n this.score = 0;\n this.init();\n }", "function resetToInit(){\n updateCurrentState(INIT);\n customModeUiUpdate();\n updateClock(mode.work);\n timer.init(mode.work, updateClock, startReminder);\n}", "function reset() {\n noneDisplay.style.display = \"none\";\n tryagain.style.display = \"none\";\n info.classList.remove(\"rightChoice\");\n info.classList.remove(\"animated\");\n info.textContent = \"\";\n}", "_resetState () {\n this.ready = false\n this.configuring = false\n this.credentials = { addr: '' }\n this._selectedChatId = null\n this._showArchivedChats = false\n this._pages = 1\n this._query = ''\n }", "reset() {\n this.length = 0;\n this._subParamsLength = 0;\n this._rejectDigits = false;\n this._rejectSubDigits = false;\n this._digitIsSub = false;\n }", "function clearUnitDetails() {\n\n // Set the current Name\n $(\"#txtName\").val(\"\");\n\n // Set the current description\n $(\"#txtDescription\").val(\"\");\n\n // Clear the dimension check boxes\n $('#checkboxCollection input').each(function (index, value) {\n // reset the current checkbox\n $(value).prop('checked', false);\n });\n\n // Clear the Natural Unit and Dimension boxes\n// $(\"#NaturalUnitList\").empty();\n// $(\"#checkboxCollection\").empty();\n\n // Update the active flag\n $(\"#activeFlag\").prop('checked', false);\n\n }", "function reset(){\n\t\tquestionIndex = 0;\n\t\toptionIndex = 0;\n\t\t$(\"#option0, #option1, #option2, #option3\").show();\n\t\t$('#timeclock').show();\n\t\ttime();\n\t\tunanswered = 0;\n\t\twrongoption = 0;\n\t\ttotalscore = 0;\n\t\tgamestart();\n\t}", "function reset () {\n noty.clear();\n resetTimeout();\n }", "resetUI() {\n const self = this;\n\n clearInterval(self._updateInterval);\n\n self._timerEnd.innerText = '0:00';\n self._timerStart.innerText = '0:00';\n self._songName.innerText = 'Something';\n self._artist.innerText = 'Someone';\n\n self._playButton.style.backgroundImage = 'url(\"../src/img/play.png\")';\n self._progress.value = 0;\n\n self._albumCover.style.removeProperty('background-image');\n\n self._shuffle.style.backgroundImage = 'url(\"../src/img/shuffle.png\")';\n\n if (self._albumCoverImage) {\n self._albumCoverImage.src = ''; // <- Fails on purpose, gets handled in updateUI\n }\n\n if (self._currentlyPlaying) {\n self._currentlyPlaying.classList.remove('song-container-active');\n self._currentlyPlaying = undefined;\n }\n }", "_reset() {\n\n this.enemiesCurrentlyOnscreen = 0;\n this.enemiesLeftToSpawn = this.enemyList.total;\n this.spawnTimer = this.startWait;\n\n }", "function resetGameState() {\r\n\r\n // Reset difficulty and enemy speed.\r\n increaseDifficulty.difficulty = \"start\";\r\n Enemy.v = 4;\r\n toggleEnemySpawner.spawnRate = 2000;\r\n\r\n // Clear the list of game objects.\r\n observers = [];\r\n\r\n // Reset player.\r\n player = new Player();\r\n\r\n // Reset game state data.\r\n time = 90;\r\n document.getElementById(\"time-numeric\").innerHTML = time;\r\n Player.score = 100;\r\n document.getElementById(\"score-numeric\").innerHTML = Player.score;\r\n timeAt100 = 0;\r\n}", "function reset() {\n length = \"\";\n isLower = false;\n isUpper = false;\n isNumber = false;\n isSpecial = false;\n password = \"\";\n randomSelection = [];\n}", "reset () {\n this.setState({ message: '', isDraft: null, validMessage: null });\n }", "reset () {\n this.state.clear()\n this.redraw()\n }", "function resetState () {\n while (answerElement.firstChild) {\n answerElement.removeChild(answerElement.firstChild);\n }\n}", "resetForm() {\n this.bundle.reset();\n this.setState({\n hash: \"\",\n ipfsLocation: \"\",\n patentName: \"\",\n licencePrices: Array(Object.keys(licences).length).fill(''),\n licence: Object.keys(licences).length - 1,\n file: \"\",\n fileExt: '',\n fileState: FileStates.NOT_ENCRYPTED,\n waitingTransaction: false\n })\n }" ]
[ "0.643484", "0.6290009", "0.6285774", "0.6202145", "0.62011844", "0.61792785", "0.6145059", "0.6135676", "0.6133065", "0.6085142", "0.60610527", "0.6059029", "0.599889", "0.5981631", "0.59789747", "0.5977937", "0.5974269", "0.5968152", "0.5956023", "0.59373504", "0.59372663", "0.5925465", "0.59191865", "0.590948", "0.59015906", "0.5900781", "0.5895473", "0.58935714", "0.5888325", "0.5887031", "0.5883044", "0.5882811", "0.5882684", "0.5882684", "0.58805066", "0.58766645", "0.58737934", "0.58736694", "0.58682895", "0.58569944", "0.58559227", "0.5847595", "0.5847565", "0.5847397", "0.58427835", "0.58349967", "0.583365", "0.583057", "0.58243334", "0.581187", "0.5811579", "0.58113724", "0.580981", "0.5806466", "0.58036417", "0.58008534", "0.5799234", "0.579385", "0.579343", "0.579228", "0.5789576", "0.57870734", "0.5785463", "0.57800025", "0.5773989", "0.57642555", "0.57565707", "0.5754766", "0.57497835", "0.5749319", "0.57469165", "0.57468164", "0.5746", "0.5743003", "0.57421505", "0.5737551", "0.5726988", "0.5722773", "0.5722769", "0.571491", "0.5713748", "0.5712324", "0.57111084", "0.57065916", "0.57014626", "0.5697841", "0.5695618", "0.5694434", "0.56934935", "0.56933874", "0.5690716", "0.56871647", "0.5685438", "0.56753796", "0.5675024", "0.5669557", "0.5663516", "0.5658584", "0.5658077", "0.56574816" ]
0.88482547
0
Set the tutor properties for the specified unit and subunit numbers. Arguments: m Unit number n Subunit number
function setSubunit(m, n) { my.current.unitNo = m my.current.subunitNo = n my.current.unit = unit(m) my.current.subunitTitles.length = 0 for (var subunitTitle in my.current.unit.subunits) { my.current.subunitTitles.push(subunitTitle) } var subunitTitle = my.current.subunitTitles[n - 1] my.current.subunitText = my.current.unit.subunits[subunitTitle] }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "setUnits() {\n this.units = unitSystem.getUnits();\n }", "function setUnitInfoInfo(stroption) {\n UnitInfo = stroption;\n}", "function setTerreainUniformVariables() {\n // Terrain uniform variables\n terrainDeferred.bindTexToUnit(\"tex_Color\", terrain_diffuse, 0);\n terrainDeferred.bindTexToUnit(\"tex_Normal\", terrain_normal, 1);\n terrainDeferred.bindTexToUnit(\"tex_Specular\", terrain_specular, 2);\n terrainDeferred.bindTexToUnit(\"sand_Normal\", sand_normal, 3);\n terrainDeferred.bindTexToUnit(\"sand_Normal2\", sand_normal2, 4);\n terrainDeferred.setSandEdge(controls.SandEdge);\n terrainDeferred.setSandSteep(controls.SandSteep);\n terrainDeferred.setFlowEdge(controls.FlowEdge);\n terrainDeferred.setFlowSpeed(controls.FlowSpeed);\n terrainDeferred.setTime(timer.currentTime);\n terrainDeferred.setSandDiffuse(__WEBPACK_IMPORTED_MODULE_0_gl_matrix__[\"e\" /* vec4 */].fromValues(controls.SandDiffuse[0] / 255, controls.SandDiffuse[1] / 255, controls.SandDiffuse[2] / 255, 1.0));\n terrainDeferred.setCloudEdge(controls.CloudEdge);\n terrainDeferred.setCloudSize(controls.CloudSize);\n terrainDeferred.setCloudNoise(controls.CloudNoise);\n terrainDeferred.setCloudSpeed(controls.CloudSpeed);\n terrainDeferred.setCloudSpeed2(controls.CloudSpeed2);\n mounDeferred.bindTexToUnit(\"tex_Color\", moun_diffuse, 5);\n mounDeferred.bindTexToUnit(\"tex_Normal\", moun_normal, 6);\n mounDeferred.bindTexToUnit(\"tex_Specular\", moun_specular, 7);\n mounDeferred.bindTexToUnit(\"tex_Color2\", terrain_diffuse, 0);\n mounDeferred.bindTexToUnit(\"tex_Normal2\", terrain_normal, 1);\n mounDeferred.bindTexToUnit(\"tex_Specular2\", terrain_specular, 2);\n mounDeferred.setAmount(controls.EdgePow);\n //mounDeferred.setSandDiffuse(vec4.fromValues(controls.MounDiffuse[0]/255, controls.MounDiffuse[1]/255, controls.MounDiffuse[2]/255, 1.0));\n mounDeferred.setSandSpecular(__WEBPACK_IMPORTED_MODULE_0_gl_matrix__[\"e\" /* vec4 */].fromValues(controls.SandDiffuse[0] / 255, controls.SandDiffuse[1] / 255, controls.SandDiffuse[2] / 255, 1.0));\n mounDeferred.setSandEdge(controls.MounEdge);\n mounDeferred.setCloudEdge(controls.CloudEdge);\n mounDeferred.setCloudSize(controls.CloudSize);\n mounDeferred.setCloudNoise(controls.CloudNoise);\n mounDeferred.setCloudSpeed(controls.CloudSpeed);\n mounDeferred.setCloudSpeed2(controls.CloudSpeed2);\n mounDeferred.setTime(timer.currentTime);\n ribbonDeferred.bindTexToUnit(\"tex_Color\", moun_diffuse, 5);\n ribbonDeferred.bindTexToUnit(\"tex_Normal\", moun_normal, 6);\n ribbonDeferred.bindTexToUnit(\"tex_Specular\", moun_specular, 7);\n ribbonDeferred.setSandDiffuse(__WEBPACK_IMPORTED_MODULE_0_gl_matrix__[\"e\" /* vec4 */].fromValues(controls.RibbonDiffuse[0] / 255, controls.RibbonDiffuse[1] / 255, controls.RibbonDiffuse[2] / 255, 1.0));\n ribbonDeferred.setSandSpecular(__WEBPACK_IMPORTED_MODULE_0_gl_matrix__[\"e\" /* vec4 */].fromValues(controls.SandDiffuse[0] / 255, controls.SandDiffuse[1] / 255, controls.SandDiffuse[2] / 255, 1.0));\n ribbonDeferred.setSandEdge(controls.RibbonEdge);\n ribbonDeferred.setCloudEdge(controls.CloudEdge);\n ribbonDeferred.setCloudSize(controls.CloudSize);\n ribbonDeferred.setCloudNoise(controls.CloudNoise);\n ribbonDeferred.setCloudSpeed(controls.CloudSpeed);\n ribbonDeferred.setCloudSpeed2(controls.CloudSpeed2);\n ribbonDeferred.setTime(timer.currentTime);\n ribbonDeferred.setAmount(controls.RibbonAmount);\n ribbonDeferred.setAmount2(controls.RibbonAmount2);\n ribbonDeferred.setAmount3(controls.RibbonAmount3);\n }", "function m(t, n, r) {\n return t.units[n][r];\n }", "function unit(m)\n {\n if (alternateUnitAvailable(m) &&\n my.settings.unit == my.UNIT.ALTERNATE) {\n return Units.alternate[m - Units.alternateStart]\n } else {\n return Units.main[m - 1]\n }\n }", "function PropulsionUnit() {\n }", "function PropulsionUnit() {\n }", "function setUnits(){\n var units=JSON.parse(localStorage['units']);\n for (var i = 0; i < MAX_NUMBER_OF_UNITS; i++) {\n var trans = 0.3; // the rgba transparency\n var div = $('#unit'+i); // Select the unit div\n var img = $('#unit'+i+'> img'); // Select the unit img tag\n div.css('border','1px dotted green');\n \n if ( units[i] === undefined){ // Unit is unused\n div.css('display','none');\n break;\n }\n if(i == selected){ // The chosen Unit\n trans = 0.9;\n div.css('border','2px solid black'); \n } \n var rgba = \"rgba(\"+units[i].split(';')[2]+\",\"+trans+\")\";\n div.css('background',rgba);\n var type = units[i].split(';')[1];\n img.attr(\"src\",\"markers/\"+type+\"-icon.png\");\n img.attr('class',type);\n } \n }", "function PropulsionUnit() {\n\t}", "set testProperty(n)\n\t\t{\n\t\t\tmap.get(this)._SetTestProperty(n);\n\t\t}", "set units(enumUnits) {\n // TODO: Check licensed (or will obviously fail on the server)\n this.SetMarginMeasure(enumUnits);\n }", "setUTMData(utmData) {\n this.utmData = utmData;\n }", "static setUnitMetric(unit) {\n if (unit === 'm' || unit === 'metres') {\n return `&units=metric`;\n }\n return ``;\n }", "function nextSubunit()\n {\n var m = my.current.unitNo\n var n = my.current.subunitNo\n\n if (!currentSubunitIsTheLastSubunit()) {\n if (n == my.current.subunitTitles.length) {\n // If the user is at unit M.L where L is the last\n // subunit of unit M, then go to unit (M + 1).1.\n m++\n n = 1\n } else {\n // If the user is at unit M.N, then go to unit M.(N + 1).\n n++\n }\n }\n\n window.location.href = unitHref(m, n)\n }", "function setM(self, m) {\n self.m_ = m;\n self.lastCanvas_ = null;\n }", "setMasechtaNumber(masechtaNumber) {\n this.masechtaNumber = masechtaNumber;\n }", "async function getUnit() {\n const unitResponse = await microcredapi.get(`/student/${window.localStorage.getItem('userId')}/enrolled`)\n setUnit({'code': window.localStorage.getItem('unitId'), 'name': unitResponse.data.unitMap[window.localStorage.getItem('unitId')]})\n }", "function setEnrollDataForMoveOnUnitByUnitId($el, unit){\n if(!$el || !this[PRIVATE_LEVEL] || !this[PRIVATE_LEVEL].children) return;\n\n var levelInfo = this[PRIVATE_LEVEL].children,\n currCourseInfo;\n\n if(unit){\n currCourseInfo = $.grep(levelInfo, function(v, i){\n return v.id === unit.id;\n })[0];\n\n $el.data({\n \"enrollmentId\": \"student_course_enrollment!\" + TypeidParser.parseId(currCourseInfo.parent.parent.id),\n \"courseId\": currCourseInfo.parent.parent.id,\n \"levelId\": currCourseInfo.parent.id,\n \"unitId\": currCourseInfo.id\n });\n\n } else {\n $el.removeData(['enrollmentId' , 'courseId' , 'levelId', 'unitId']);\n }\n }", "function unitChange() {\n oldunits = units;\n if(document.getElementById('unit_SI').checked) {\n units = 'unit_SI';\n doseUnit = 'uSv/h';\n dosenorm = eps * 1e4 * 3600;\n lunit = cm;\n lunitname = 'cm';\n }\n else {\n units = 'unit_US';\n doseUnit = 'mrem/h';\n dosenorm = eps * 1e3 * 3600;\n lunit = inch;\n lunitname = 'inch';\n }\n\n // Update length unit\n var ltext = document.getElementsByClassName('lunit');\n for (var i = 0; i < ltext.length; i++) { \n ltext[i].innerHTML = lunitname;\n };\n\n // Update dose unit\n var dtext = document.getElementsByClassName('dunit');\n for (var i = 0; i < dtext.length; i++) {\n dtext[i].innerHTML = doseUnit;\n };\n\n autoConv = document.getElementById('autoConv').checked;\n if(autoConv) { // Covert length values according to the selected unit\n var linp = document.getElementsByClassName('inpL');\n var unitfactor;\n if(units=='unit_SI' && oldunits=='unit_US')\n unitfactor = inch/cm;\n else if(units=='unit_US' && oldunits=='unit_SI')\n unitfactor = cm/inch;\n else\n unitfactor = 1.0;\n for (var i = 0; i < linp.length; i++) {\n linp[i].value = (parseFloat(linp[i].value) * unitfactor).toFixed(2);\n };\n }\n updateAll();\n}", "function setMentor(mentor){\n mentorBio.info = mentor;\n mentorId = mentorBio.info.id;\n getProfiles();\n }", "setRoomProperties(dimensions, materials) {\n this.room.setProperties(dimensions, materials);\n }", "function convertToUTM(obj) {\n [obj.north, obj.east] = proj4(wgs84, utm, [obj.lat, obj.lng]);\n}", "function CSIRO_phiM(MC, U) {\n if(MC<12) {\n return Math.exp(-0.108*MC);\n } else if((MC>12) && (U<=10)) {\n return (0.684 - 0.0342*MC);\n } else {\n return (0.547 - 0.0228*MC);\n }\n}", "multiUnitParams(props = this.props) {\n return `?unit_ids=${this.unit_ids(props)}${this.getDateParams(props)}`\n }", "set Specular(value) {}", "function dlgSetUIUnit(nUIUnit)\n{\n\tg_nUIUnit\t= nUIUnit + 1;\n\tg_bDirty\t= true;\n\tdlgDisplayDurations();\n}", "function setTurns(number){\n\t\t\t\t\tif(number == 1){\n\t\t\t\t\t\tgame.gender = 'woman';\n\t\t\t\t\t\tgame.turnLimit = 82; //82;\n\t\t\t\t\t}else{\n\t\t\t\t\t\tgame.gender = 'man';\n\t\t\t\t\t\tgame.turnLimit = 79; //79;\n\t\t\t\t\t}\n\t\t\t\t}", "set useFileUnits(value) {}", "function LLtoUTM(EQUATORIAL_RADIUS, ECC_SQUARED) {\n return function (lat, lon, utmcoords, zone) {\n var squared = ECC_SQUARED,\n radius = EQUATORIAL_RADIUS,\n primeSquared = squared / (1 - squared),\n // utmcoords is a 2-D array declared by the calling routine\n // note: input of lon = 180 or -180 with zone 60 not allowed; use 179.9999\n lat = parseFloat(lat),\n lon = parseFloat(lon)\n\n // Constrain reporting USNG coords to the latitude range [80S .. 84N]\n if (lat > 84.0 || lat < -80.0) {\n return undefined\n } else {\n\n // sanity check on input - turned off when testing with Generic Viewer\n if (lon > 360 || lon < -180 || lat > 90 || lat < -90) {\n throw new Error(str('usng.js, LLtoUTM, invalid input. lat: ', toFixed(lat, 4), ' lon: ', toFixed(lon, 4)))\n }\n\n // Make sure the longitude is between -180.00 .. 179.99..\n // Convert values on 0-360 range to this range.\n var lonTemp = (lon + 180) - parseInt((lon + 180) / 360) * 360 - 180,\n latRad = lat * DEG_2_RAD,\n lonRad = lonTemp * DEG_2_RAD,\n\n // user-supplied zone number will force coordinates to be computed in a particular zone\n zoneNumber = (!zone) ? getZoneNumber(lat, lon) : zone,\n\n lonOrigin = dec(zoneNumber) * 6 - 180 + 3, // +3 puts origin in middle of zone\n lonOriginRad = lonOrigin * DEG_2_RAD,\n\n // compute the UTM Zone from the latitude and longitude\n UTMZone = str(zoneNumber, UTMLetterDesignator(lat), ' '),\n\n N = radius / sqrt(1 - squared * sin(latRad) * sin(latRad)),\n T = tan(latRad) * tan(latRad),\n C = primeSquared * cos(latRad) * cos(latRad),\n A = cos(latRad) * (lonRad - lonOriginRad),\n\n // Note that the term Mo drops out of the \"M\" equation, because phi\n // (latitude crossing the central meridian, lambda0, at the origin of the\n // x,y coordinates), is equal to zero for UTM.\n M = radius * ((1 - squared / 4\n - 3 * (squared * squared) / 64\n - 5 * (squared * squared * squared) / 256) * latRad\n - (3 * squared / 8 + 3 * squared * squared / 32\n + 45 * squared * squared * squared / 1024)\n * sin(2 * latRad) + (15 * squared * squared / 256\n + 45 * squared * squared * squared / 1024) * sin(4 * latRad)\n - (35 * squared * squared * squared / 3072) * sin(6 * latRad)),\n\n UTMEasting = (k0 * N * (A + (1 - T + C) * (A * A * A) / 6\n + (5 - 18 * T + T * T + 72 * C - 58 * primeSquared)\n * (A * A * A * A * A) / 120)\n + EASTING_OFFSET),\n\n UTMNorthing = (k0 * (M + N * tan(latRad) * ((A * A) / 2 + (5 - T + 9\n * C + 4 * C * C) * (A * A * A * A) / 24\n + (61 - 58 * T + T * T + 600 * C - 330 * primeSquared)\n * (A * A * A * A * A * A) / 720)))\n\n aset(utmcoords, 0, UTMEasting)\n aset(utmcoords, 1, UTMNorthing)\n aset(utmcoords, 2, zoneNumber)\n }\n }\n}", "function setPlayersPerRoom( nb ){\n playersPerRoom = nb;\n }", "function prop (start,end,tabmonth) {\nvar scriptProperties = PropertiesService.getScriptProperties();\n var newProperties = {start_date:start,end_date:end,tab:tabmonth};\nscriptProperties.setProperties(newProperties);\nvar test=1;\n}", "function zoomMuni(mun,coord){\n map.setCenter(coord);\n\t map.setZoom(14);\n\n}", "function translateFromMD2DUnits(properties, metadata) {\n if (!unitsTranslation) return properties;\n return mapValues(properties, function(key, value) {\n return unitsTranslation.translateFromModelUnits(value, metadata[key] && metadata[key].unitType);\n });\n }", "function setDisplayUnits(units) {\n if (units === 'nautical') {\n localStorage['displayUnits'] = \"nautical\";\n } else if (units === 'metric') {\n localStorage['displayUnits'] = \"metric\";\n } else if (units === 'imperial') {\n localStorage['displayUnits'] = \"imperial\";\n }\n onDisplayUnitsChanged();\n}", "mercuryExpect() {\n if (this.sex === \"male\") {\n this.mercExpect = Math.round(this.male / this.mercNum);\n }\n if(this.sex === \"female\"){\n this.mercExpect = Math.round(this.female / this.mercNum);\n }\n }", "function frmPatientSummary_setUnit() {\n frmPatientSummary.btnunits.text=frmPatientSummary.segunitslist.selectedItems[0].lblunit;\n measurementUnits = frmPatientSummary.segunitslist.selectedItems[0].lblunit;\n frmPatientSummary.fcunitslist.setVisibility(false);\n frmPatientSummary_addWoundSummarySegments();\n var selectedRange = kony.store.getItem(userInfo.userId+\"_summaryWeekRange\");\n if(selectedRange!=null){\n patientSummary_changeChartTimeLine(selectedRange,false);\n }else{\n patientSummary_changeChartTimeLine(12,false);\n }\n //patientSummary_changeChartTimeLine(12);\n frmPatientSummary_addWound360Column();\n frmPatientSummary_cancelTimer(\"timerToStorePreviousWoundSelection\");\n kony.timer.schedule(\"timerToStorePreviousWoundSelection\", frmPatientSummary_storePreviousWoundSelection, 0.2, false);\n\n}", "changeUnits(ev) {\n if(ev.target.getAttribute('value') === 'metric') this.unit = 0;\n else if(ev.target.getAttribute('value') === 'imperial') this.unit = 1;\n inputsRequired.forEach((input, i) => {\n input.label.innerHTML = (input.name + placeHolderTexts[i][this.unit === 0 ? 'metric' : 'imperial'])\n });\n }", "function setSquadre(t) {\r\n teams = t;\r\n for(var i=0;i < teams.length; i++){\r\n teamsIdByShortName[teams[i].shortName.toLowerCase()] = {\r\n \"id\": teams[i].id,\r\n \"name\": teams[i].name,\r\n \"shortName\": teams[i].shortName\r\n };\r\n\r\n teamsIdByName[teams[i].name] = {\r\n \"id\": teams[i].id,\r\n \"name\": teams[i].name,\r\n \"shortName\": teams[i].shortName.toLowerCase()\r\n };\r\n }\r\n}", "function gridTerrainVariableSet(){\n\t//Mountains\n\tgridSetMountains();\n}", "function units(num) {\n\treturn num*CELL_SIZE + UNIT_NAME;\n}", "set(n) {\n if (n === undefined) {\n return this // don't bother\n }\n if (typeof n === 'string') {\n n = parse(n).num\n }\n let m = this\n let res = m.map((val) => {\n let obj = parse(val)\n obj.num = n\n if (obj.num === null) {\n return val\n }\n let fmt = val.has('#Ordinal') ? 'Ordinal' : 'Cardinal'\n if (val.has('#TextValue')) {\n fmt = val.has('#Ordinal') ? 'TextOrdinal' : 'TextCardinal'\n }\n let str = format(obj, fmt)\n // add commas to number\n if (obj.hasComma && fmt === 'Cardinal') {\n str = Number(str).toLocaleString()\n }\n val = val.not('#Currency')\n val.replaceWith(str, { tags: true })\n // handle plural/singular unit\n // agreeUnits(agree, val, obj)\n return val\n })\n return new Numbers(res.document, res.pointer)\n }", "function _setPressure(pressure, milibar){\n\n var pressure1 = 0, pressure2 = 0;\n // pressure1: 5 units = 9 degrees\n // pressure2: 0.1 units = 6 degrees\n\n if (milibar !== true) {\n if (pressure >= 27.1 && pressure <= 33) {\n pressure1 = (925 - 33.8639 * pressure) * 1.8;\n pressure2 = (pressure - 27.1) * 60;\n }\n } else {\n if (pressure >= 925 && pressure <= 1120) {\n pressure1 = (925 - pressure) * 1.8;\n pressure2 = (pressure * 0.0295300 - 27.1) * 60;\n }\n }\n\n placeholder.each(function(){\n $(this).find('div.instrument.altimeter div.altimeter_pressurembar').css('transform', 'rotate(' + pressure1 + 'deg)');\n }); \n placeholder.each(function(){\n $(this).find('div.instrument.altimeter div.altimeter_pressureinhg').css('transform', 'rotate(' + -pressure2 + 'deg)');\n }); \n\n }", "function setMentorId(id){\n mentorId = id;\n getProfiles();\n }", "unitsInit()\n\t{\n\t\t//\n\t\t// Call parent method.\n\t\t//\n\t\tsuper.unitsInit();\n\t\t\n\t\t//\n\t\t// Instantiation tests.\n\t\t//\n\t\tthis.unitsInitInstantiation();\n\t\t\n\t\t//\n\t\t// Contents tests.\n\t\t//\n\t\tthis.unitsInitContent();\n\t\t\n\t\t//\n\t\t// Insert tests.\n\t\t//\n\t\tthis.unitsInitInsert();\n\t\t\n\t\t//\n\t\t// Resolve tests.\n\t\t//\n\t\tthis.unitsInitResolve();\n\t\t\n\t\t//\n\t\t// Replace tests.\n\t\t//\n\t\tthis.unitsInitReplace();\n\t\t\n\t\t//\n\t\t// Remove tests.\n\t\t//\n\t\tthis.unitsInitRemove();\n\t\t\n\t\t//\n\t\t// Custom tests.\n\t\t//\n\t\tthis.unitsInitCustom();\n\t\t\n\t\t//\n\t\t// Static tests.\n\t\t//\n\t\tthis.unitsInitStatic();\n\t\t\n\t}", "function previousSubunit()\n {\n var m = my.current.unitNo\n var n = my.current.subunitNo\n\n if (!currentSubunitIsTheFirstSubunit()) {\n if (n == 1) {\n // If the user is at unit M.1, go to unit (M - 1).L\n // where L is the last subunit of the previous unit.\n previousUnit = unit(m - 1)\n var previousSubunitTitles = []\n for (var subunitTitle in previousUnit.subunits) {\n previousSubunitTitles.push(subunitTitle)\n }\n\n m--\n n = previousSubunitTitles.length\n } else {\n // If the user is at unit M.N, go to unit M.(N - 1)\n n--\n }\n }\n\n window.location.href = unitHref(m, n)\n }", "function translateToMD2DUnits(properties, metadata) {\n if (!unitsTranslation) return properties;\n return mapValues(properties, function(key, value) {\n return unitsTranslation.translateToModelUnits(value, metadata[key] && metadata[key].unitType);\n });\n }", "get unit () {\n\t\treturn this._unit;\n\t}", "function doHumanization(ms, options) {\n let i; let len; let piece;\n\n // Make sure we have a positive number.\n // Has the nice sideffect of turning Number objects into primitives.\n ms = Math.abs(ms);\n\n const dictionary = options.languages[options.language] || languages[options.language];\n if (!dictionary) {\n throw new Error(`No language ${dictionary}.`);\n }\n\n const pieces = [];\n\n // Start at the top and keep removing units, bit by bit.\n let unitName; let unitMS; let \n unitCount;\n for (i = 0, len = options.units.length; i < len; i++) {\n unitName = options.units[i];\n unitMS = options.unitMeasures[unitName];\n\n // What's the number of full units we can fit?\n if (i + 1 === len) {\n unitCount = ms / unitMS;\n } else {\n unitCount = Math.floor(ms / unitMS);\n }\n\n // Add the string.\n pieces.push({\n unitCount,\n unitName,\n });\n\n // Remove what we just figured out.\n ms -= unitCount * unitMS;\n }\n\n let firstOccupiedUnitIndex = 0;\n for (i = 0; i < pieces.length; i++) {\n if (pieces[i].unitCount) {\n firstOccupiedUnitIndex = i;\n break;\n }\n }\n\n if (options.round) {\n let ratioToLargerUnit; let \n previousPiece;\n for (i = pieces.length - 1; i >= 0; i--) {\n piece = pieces[i];\n piece.unitCount = Math.round(piece.unitCount);\n\n if (i === 0) { break; }\n\n previousPiece = pieces[i - 1];\n\n ratioToLargerUnit = options.unitMeasures[previousPiece.unitName] / options.unitMeasures[piece.unitName];\n if ((piece.unitCount % ratioToLargerUnit) === 0 || (options.largest && ((options.largest - 1) < (i - firstOccupiedUnitIndex)))) {\n previousPiece.unitCount += piece.unitCount / ratioToLargerUnit;\n piece.unitCount = 0;\n }\n }\n }\n\n const result = [];\n for (i = 0, pieces.length; i < len; i++) {\n piece = pieces[i];\n if (piece.unitCount) {\n result.push(render(piece.unitCount, piece.unitName, dictionary, options));\n }\n\n if (result.length === options.largest) { break; }\n }\n\n if (result.length) {\n if (!options.conjunction || result.length === 1) {\n return result.join(options.delimiter);\n } else if (result.length === 2) {\n return result.join(options.conjunction);\n } else if (result.length > 2) {\n return result.slice(0, -1).join(options.delimiter) + (options.serialComma ? ',' : '') + options.conjunction + result.slice(-1);\n }\n } else {\n return render(0, options.units[options.units.length - 1], dictionary, options);\n }\n }", "configUnits(units) {\n this.units = '';\n if (units === 'm' || units === 'metric') {\n this.units = '&units=metric';\n }\n }", "marsExpectancy() {\n if (this.sex === \"male\") {\n this.marsExpect = Math.round(this.male / this.marsNum);\n }\n if(this.sex === \"female\"){\n this.marsExpect = Math.round(this.female / this.marsNum);\n }\n }", "function ytm(i,pv,c,n,m,auto_differ) {\n\t// m and c and pv do not necessarily need to be Duals\n var AD = auto_differ; \n\n\ti = Dual(i,1);\n\tvar func = AD.div(Dual(m),AD.pow(AD.add(Dual(1),i),Dual(n)));\t\n\tfor (var k = 1 ; k <= n ; k++) {\n\t\tAD.addAssign(func,AD.div(Dual(c),AD.pow(AD.add(Dual(1),i),Dual(k))));\n\t}\n\tAD.subAssign(func,Dual(pv));\n\n\treturn func;\n}", "function doHumanization (ms, options) {\n var i, len, piece\n\n // Make sure we have a positive number.\n // Has the nice sideffect of turning Number objects into primitives.\n ms = Math.abs(ms)\n\n var dictionary = options.languages[options.language] || languages[options.language]\n if (!dictionary) {\n throw new Error('No language ' + dictionary + '.')\n }\n\n var pieces = []\n\n // Start at the top and keep removing units, bit by bit.\n var unitName, unitMS, unitCount\n for (i = 0, len = options.units.length; i < len; i++) {\n unitName = options.units[i]\n unitMS = options.unitMeasures[unitName]\n\n // What's the number of full units we can fit?\n if (i + 1 === len) {\n unitCount = ms / unitMS\n } else {\n unitCount = Math.floor(ms / unitMS)\n }\n\n // Add the string.\n pieces.push({\n unitCount: unitCount,\n unitName: unitName\n })\n\n // Remove what we just figured out.\n ms -= unitCount * unitMS\n }\n\n var firstOccupiedUnitIndex = 0\n for (i = 0; i < pieces.length; i++) {\n if (pieces[i].unitCount) {\n firstOccupiedUnitIndex = i\n break\n }\n }\n\n if (options.round) {\n var ratioToLargerUnit, previousPiece\n for (i = pieces.length - 1; i >= 0; i--) {\n piece = pieces[i]\n piece.unitCount = Math.round(piece.unitCount)\n\n if (i === 0) { break }\n\n previousPiece = pieces[i - 1]\n\n ratioToLargerUnit = options.unitMeasures[previousPiece.unitName] / options.unitMeasures[piece.unitName]\n if ((piece.unitCount % ratioToLargerUnit) === 0 || (options.largest && ((options.largest - 1) < (i - firstOccupiedUnitIndex)))) {\n previousPiece.unitCount += piece.unitCount / ratioToLargerUnit\n piece.unitCount = 0\n }\n }\n }\n\n var result = []\n for (i = 0, pieces.length; i < len; i++) {\n piece = pieces[i]\n if (piece.unitCount) {\n result.push(render(piece.unitCount, piece.unitName, dictionary, options))\n }\n\n if (result.length === options.largest) { break }\n }\n\n if (result.length) {\n if (!options.conjunction || result.length === 1) {\n return result.join(options.delimiter)\n } else if (result.length === 2) {\n return result.join(options.conjunction)\n } else if (result.length > 2) {\n return result.slice(0, -1).join(options.delimiter) + (options.serialComma ? ',' : '') + options.conjunction + result.slice(-1)\n }\n } else {\n return render(0, options.units[options.units.length - 1], dictionary, options)\n }\n }", "function initCombatTestUnit() {\n Grid.units = [];\n\n const Rei = new Unit(listUnitPattern[0]);\n Rei.giveSpirit(listSpiritPattern[0]);\n const Shadow = new Unit(listUnitPattern[1]);\n\n const allyUnits = [Rei];\n const foeUnits = [Shadow];\n const availableAllyPos = [{x:4,y:2}];\n const availableFoePos = [{x:4,y:6}];\n\n generateGridPlacement(allyUnits,availableAllyPos,foeUnits,availableFoePos);\n initTurnOrder();\n}", "constructor(humanMass, plasticMass, year, notes) {\n this.humanMass = humanMass\n this.plasticMass = plasticMass\n this.year = year\n this.notes = notes\n\n this.group = undefined\n this.humanCube = undefined\n this.plasticCube = undefined\n }", "function Studentas(v, p, m) {\n Zmogus.call(this, v, p);\n this.m = m;\n}", "function updateUnit() {\n\t\tif (segments.length == 0) {\n\t\t\tthrow \"No segments supplied!\";\n\t\t}\n\t\tif (segments.length === 1) {\n\t\t\tweights = segments[0][1];\n\t\t} else {\n\t\t\tweights = EduMon.Math.sumOver(0, segments.length, function(i) {\n\t\t\t\treturn segments[i][1]\n\t\t\t});\n\t\t}\n\t\tunit = TAU / weights;\n\t}", "function t(e, t, n, i) {\n var r = {\n m: [\"eng Minutt\", \"enger Minutt\"],\n h: [\"eng Stonn\", \"enger Stonn\"],\n d: [\"een Dag\", \"engem Dag\"],\n M: [\"ee Mount\", \"engem Mount\"],\n y: [\"ee Joer\", \"engem Joer\"]\n };\n return t ? r[n][0] : r[n][1]\n }", "function t(e, t, n, i) {\n var r = {\n m: [\"eng Minutt\", \"enger Minutt\"],\n h: [\"eng Stonn\", \"enger Stonn\"],\n d: [\"een Dag\", \"engem Dag\"],\n M: [\"ee Mount\", \"engem Mount\"],\n y: [\"ee Joer\", \"engem Joer\"]\n };\n return t ? r[n][0] : r[n][1]\n }", "saisir(p,n,m,a){\r\n this.prenom = p;\r\n this.nom = n;\r\n this.mail = m;\r\n this.promotion = a;\r\n\r\n }", "function mortal() {\n Object.defineProperty(this,\"raza\",{value:\"\",writable:true});\n Object.defineProperty(this,\"origen\",{value:\"\",writable:true});\n Object.defineProperty(this,\"inteligencia\",{value:false,writable:true});\n\n Object.defineProperties(this,{\n \"obtenRaza\":{get: function(){return this.raza;}},\n \"obtenOrigen\":{get: function(){return this.origen;}},\n \"obtenInteligencia\":{get: function(){return this.inteligencia;}},\n \"setRaza\":{set: function(raza){this.raza = raza;}},\n \"setOrigen\":{set: function(origen){this.origen = origen;}},\n \"setInteligencia\":{set: function(intel){this.inteligencia = intel;}}\n });\n\n this.muerto = function(){\n if(this.obtenEdad == 0){\n return \"Muerto\";\n } else {\n return \"Vivo\";\n }\n };\n}", "function setRemUnit() { //将根元素的宽度划分成10份\n var rem = docEl.clientWidth / 10\n docE1.style.fontSize = rem + 'px'\n }", "function addUnitToTable(unit) {\n\n rows.push({\n title : \"<a href='#view=unit&amp;id=\" + unit.id + \"'>\" + unit.name + \"</a>\",\n exportTitle : safe_export_replace(unit.name),\n css : 'unit main',\n unit : unit,\n type : UNIT\n });\n\n rows.push({\n title : t(\"Activities Average\"),\n exportTitle : t(\"Activities Average\"),\n css : 'unit average',\n unit : unit,\n type : UNIT_AVERAGE\n });\n\n rows.push({\n title : t(\"Activities Coverage\"),\n exportTitle : t(\"Activities Coverage\"),\n css : 'unit coverage',\n unit : unit,\n type : UNIT_COVERAGE\n });\n\n // Actividades de la unidad\n var activities = unit.activities;\n for ( var i in activities) {\n\n var activity = activities[i];\n\n rows.push({\n title : \"<a class='partial' href='#view=activity&amp;id=\" + activity.id + \"'>\" + activity.name\n + \"</a>\",\n exportTitle : safe_export_replace(activity.name) + \" (\" + safe_export_replace(activity.code) + \")\",\n activity : activity,\n css : \"activity \" + getActivityType(activity.code),\n type : ACTIVITY\n });\n }\n\n }", "function resetSubunit()\n {\n my.current.state = my.STATE.READY\n my.current.errors = 0\n my.html.input.value = ''\n\n log('state', my.current.state.toUpperCase(),\n 'unit', my.current.unitNo + '.' + my.current.subunitNo,\n 'type', my.settings.unit)\n\n updatePracticePaneState()\n updatePracticePane()\n clearAdvice()\n clearResultTooltips()\n }", "setMatrixUniforms()\n\t{\n\t\t\tmat4.identity(mvMatrix);\n\t\t\tmat4.translate(mvMatrix, distCENTER);\n\t\t\tmat4.multiply(mvMatrix, rotMatrix);\n\n\t\t\t// mat4.identity(this.rMatrix);\n\t\t\t// mat4.identity(this.tMatrix);\n\t\t\t// mat4.translate(this.tMatrix, [0, 0.5, 0]);\n\t\t\t// mat4.rotate(this.rMatrix, this.rotObjY, [0, 0, 1]);\n\t\t\t// mat4.rotate(this.rMatrix, this.rotObjX, [1, 0, 0]);\n\n\t\t\tgl.uniformMatrix4fv(this.shader.rMatrixUniform, false, rotMatrix);\n\t\t\tgl.uniformMatrix4fv(this.shader.mvMatrixUniform, false, mvMatrix);\n\t\t\tgl.uniformMatrix4fv(this.shader.pMatrixUniform, false, pMatrix);\n\t\t\tgl.uniformMatrix4fv(this.shader.rObjMatrixUniform, false, this.rMatrix);\n\t\t\tgl.uniformMatrix4fv(this.shader.tObjMatrixUniform, false, this.tMatrix);\n\t}", "init(id, name, areaM, heightM, colorM) {\n\n this.id = id;\n this.name = name;\n this.areaMetric = areaM;\n this.heightMetric = heightM;\n this.colorMetric = colorM;\n\n }", "function setParameters() {\n params.viscosity = 0.02;\n params.u0 = -amplitude;\n params.one36th = 1 / 36;\n params.one9th = 1 / 9;\n params.four9ths = 4 / 9;\n params.gridSize = 5;\n params.m = int(height / params.gridSize);\n params.n = int(width / params.gridSize);\n}", "function setOrgUnit(_orgUnit){\n orgUnit = _orgUnit;\n //domAttr.set('orgUnitNameDiv', 'innerHTML', _orgUnit.name);\n }", "function initTimeUnits () {\n var divider = 1;\n timeUnits.forEach(function (unit) {\n divider = divider * unit[1];\n unit[1] = divider;\n });\n timeUnits.reverse();\n}", "setOperators(operators) {\n this.operatorUnits = operators;\n }", "function mass() {\n let mass1 = document.querySelector('#mass1').value;\n let mass2 = document.querySelector('#mass2').value;\n let number9 = document.querySelector('#number9').value;\n let number10 = document.querySelector('#number10').value;\n let m1 = document.querySelector('#m1');\n let m2 = document.querySelector('#m2');\n if ((mass1 === 't') && number10 !== '' && number9 !== ''){\n m1.innerHTML = ' t';\n switch (mass2) {\n case 't':\n document.querySelector('#number10').value = number9;\n m2.innerHTML = ' t';\n break;\n case 'tUK':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.9842065276).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t(UK)';\n break;\n case 'tUS':\n document.querySelector('#number10').value = (parseFloat(number9) * 1.1023113109).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t(US)';\n break;\n case 'lb':\n document.querySelector('#number10').value = (parseFloat(number9) * 2204.6226218488).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' lb';\n break;\n case 'oz':\n document.querySelector('#number10').value = (parseFloat(number9) * 35273.96194958).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' oz';\n break;\n case 'kg':\n document.querySelector('#number10').value = (parseFloat(number9) * 1000).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' kg';\n break;\n case 'g':\n document.querySelector('#number10').value = (parseFloat(number9) * 1000000).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' g';\n break;\n default:\n m1.innerHTML = '';\n m2.innerHTML = '';\n document.querySelector('#number9').value = 1;\n document.querySelector('#number10').value = 1;\n break;\n }\n }\n if ((mass1 === 'tUK') && number10 !== '' && number9 !== ''){\n m1.innerHTML = ' t(UK)';\n switch (mass2) {\n case 't':\n document.querySelector('#number10').value = (parseFloat(number9) * 1.0160469088).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t';\n break;\n case 'tUK':\n document.querySelector('#number10').value = number9;\n m2.innerHTML = ' t(UK)';\n break;\n case 'tUS':\n document.querySelector('#number10').value = (parseFloat(number9) * 1.12).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t(US)';\n break;\n case 'lb':\n document.querySelector('#number10').value = (parseFloat(number9) * 2204).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' lb';\n break;\n case 'oz':\n document.querySelector('#number10').value = (parseFloat(number9) * 35840).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' oz';\n break;\n case 'kg':\n document.querySelector('#number10').value = (parseFloat(number9) * 1016.0469088).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' kg';\n break;\n case 'g':\n document.querySelector('#number10').value = (parseFloat(number9) * 1016046.9088).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' g';\n break;\n default:\n m1.innerHTML = '';\n m2.innerHTML = '';\n document.querySelector('#number9').value = 1;\n document.querySelector('#number10').value = 1;\n break;\n }\n }\n if ((mass1 === 'tUS') && number10 !== '' && number9 !== ''){\n m1.innerHTML = ' t(US)';\n switch (mass2) {\n case 't':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.90718474).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t';\n break;\n case 'tUK':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.8928571429).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t(UK)';\n break;\n case 'tUS':\n document.querySelector('#number10').value = number9;\n m2.innerHTML = ' t(US)';\n break;\n case 'lb':\n document.querySelector('#number10').value = (parseFloat(number9) * 2000).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' lb';\n break;\n case 'oz':\n document.querySelector('#number10').value = (parseFloat(number9) * 32000).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' oz';\n break;\n case 'kg':\n document.querySelector('#number10').value = (parseFloat(number9) * 907.18474).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' kg';\n break;\n case 'g':\n document.querySelector('#number10').value = (parseFloat(number9) * 907184.74).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' g';\n break;\n default:\n m1.innerHTML = '';\n m2.innerHTML = '';\n document.querySelector('#number9').value = 1;\n document.querySelector('#number10').value = 1;\n break;\n }\n }\n if ((mass1 === 'lb') && number10 !== '' && number9 !== ''){\n m1.innerHTML = ' lb';\n switch (mass2) {\n case 't':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.0004535924).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t';\n break;\n case 'tUK':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.0004464286).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t(UK)';\n break;\n case 'tUS':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.0005).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t(US)';\n break;\n case 'lb':\n document.querySelector('#number10').value = number9;\n m2.innerHTML = ' lb';\n break;\n case 'oz':\n document.querySelector('#number10').value = (parseFloat(number9) * 16).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' oz';\n break;\n case 'kg':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.45359237).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' kg';\n break;\n case 'g':\n document.querySelector('#number10').value = (parseFloat(number9) * 453.59237).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' g';\n break;\n default:\n m1.innerHTML = '';\n m2.innerHTML = '';\n document.querySelector('#number9').value = 1;\n document.querySelector('#number10').value = 1;\n break;\n }\n }\n if ((mass1 === 'oz') && number10 !== '' && number9 !== ''){\n m1.innerHTML = ' oz';\n switch (mass2) {\n case 't':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.0000283495).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t';\n break;\n case 'tUK':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.0000279017).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t(UK)';\n break;\n case 'tUS':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.00003125).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t(US)';\n break;\n case 'lb':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.0625).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' lb';\n break;\n case 'oz':\n document.querySelector('#number10').value = number9;\n m2.innerHTML = ' oz';\n break;\n case 'kg':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.0283495231).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' kg';\n break;\n case 'g':\n document.querySelector('#number10').value = (parseFloat(number9) * 28.349523125).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' g';\n break;\n default:\n m1.innerHTML = '';\n m2.innerHTML = '';\n document.querySelector('#number9').value = 1;\n document.querySelector('#number10').value = 1;\n break;\n }\n }\n if ((mass1 === 'kg') && number10 !== '' && number9 !== ''){\n m1.innerHTML = ' kg';\n switch (mass2) {\n case 't':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.001).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t';\n break;\n case 'tUK':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.0009842065).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t(UK)';\n break;\n case 'tUS':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.0011023113).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t(US)';\n break;\n case 'lb':\n document.querySelector('#number10').value = (parseFloat(number9) * 2.2046226218).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' lb';\n break;\n case 'oz':\n document.querySelector('#number10').value = (parseFloat(number9) * 35.2739619496).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' oz';\n break;\n case 'kg':\n document.querySelector('#number10').value = number9;\n m2.innerHTML = ' kg';\n break;\n case 'g':\n document.querySelector('#number10').value = (parseFloat(number9) * 1000).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' g';\n break;\n default:\n m1.innerHTML = '';\n m2.innerHTML = '';\n document.querySelector('#number9').value = 1;\n document.querySelector('#number10').value = 1;\n break;\n }\n }\n if ((mass1 === 'g') && number10 !== '' && number9 !== ''){\n m1.innerHTML = ' g';\n switch (mass2) {\n case 't':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.000001).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t';\n break;\n case 'tUK':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.0000009842).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t(UK)';\n break;\n case 'tUS':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.0000011023).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' t(US)';\n break;\n case 'lb':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.0022046226).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' lb';\n break;\n case 'oz':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.0352739619).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' oz';\n break;\n case 'kg':\n document.querySelector('#number10').value = (parseFloat(number9) * 0.001).toFixed(document.querySelector('#empty').innerHTML);\n m2.innerHTML = ' kg';\n break;\n case 'g':\n document.querySelector('#number10').value = number9;\n m2.innerHTML = ' g';\n break;\n default:\n m1.innerHTML = '';\n m2.innerHTML = '';\n document.querySelector('#number9').value = 1;\n document.querySelector('#number10').value = 1;\n break;\n }\n } \n\n if ((mass1 === '')){\n m2.innerHTML = '';\n m1.innerHTML = '';\n document.querySelector('#number10').value = 1;\n document.querySelector('#number9').value = 1;\n }\n if ((mass2 === '')){\n m2.innerHTML = '';\n m1.innerHTML = '';\n document.querySelector('#number10').value = 1;\n document.querySelector('#number9').value = 1;\n}\n\n\n}", "get units() {\n return this._units;\n }", "function setActiveNaturalUnit(unit) {\n\n // Set the current Name\n $(\"#txtName\").val(unit.Name);\n\n // Set the current description\n $(\"#txtDescription\").val(unit.Description);\n\n // Update the active flag\n if (unit.isActive) {\n $(\"#activeFlag\").prop('checked', true);\n }\n else {\n $(\"#activeFlag\").prop('checked', false);\n }\n\n // Loop over the defined dimensions and set them active as apporpriate\n $('#checkboxCollection input').each(function (index, value) {\n // reset the current checkbox\n $(value).prop('checked', false);\n // loop over the values in the current unit dimension array\n var count = 0;\n while(count < unit.Dimensions.length){\n if ($(value).val() == unit.Dimensions[count].ID) {\n \n $(value).prop('checked',unit.Dimensions[count].isActive);\n break;\n }\n count++;\n }\n });\n\n }", "static get unitsPerInch() {\n var rv = {};\n\n rv['pt']=72.0;\n rv['px']=96.0;\n rv['em']=6.0;\n return rv;\n }", "function instantiateUnits() {\n var numSuccess = 0;\n for ( var i = 0; i < UNITS.length; ++ i ) {\n var u = UNITS[ i ];\n var model = getModelByName( u.modelName );\n if ( model ) {\n var clonedScene = SkeletonUtils.clone( model.scene );\n if ( clonedScene ) {\n numSuccess ++;\n worldScene.add( clonedScene );\n if ( u.position ) {\n clonedScene.position.set( u.position.x, u.position.y, u.position.z );\n }\n if ( u.scale ) {\n clonedScene.scale.set( u.scale, u.scale, u.scale );\n }\n }\n } else {\n console.error( \"Can not find model\", u.modelName );\n }\n }\n console.log( `Successfully instantiated ${numSuccess} units` );\n }", "function USNGtoUTM(zone, letter, sq1, sq2, east, north, ret) {\n oset(ret, 'N', parseInt(getNorthing(zone, letter, sq2, north)))\n oset(ret, 'E', parseInt(getEasting(sq1, east)))\n oset(ret, 'zone', zone)\n oset(ret, 'letter', letter)\n}", "function creeTypeMtchGrp2(g, j, m)\r{ // Les équipes sont accessibles depuis les numéros ci-dessous\r\tthis.g = g; // N° de groupe pour accès interne\r\tthis.j = j;// N° de journée\r\tthis.m = m; // N° de match dans la journée\r //----------\r // Résultats\r //----------\r \tthis.sm = [0, 0]; // Manches gagnées par les équipes\r \tthis.sd = [0, 0]; // dés gagnés par les équipes\r \tthis.affecte = mtchGrp2Affecte;\r \tthis.affiche = mtchGrp2Affiche;\r}", "function StepUnit(id, stepUnitNum, type, roleType, realNum, ele) {\n this.id = id;\n this.stepUnitNum = stepUnitNum;\n this.type = type;\n this.roleType = roleType;\n this.realNum = realNum;\n this.ele = ele\n}", "function setRemUnit() {\n var rem = docEl.clientWidth / 10\n docEl.style.fontSize = rem + 'px'\n }", "setAutor(autor){\r\n this.autor =autor;\r\n }", "function addProperties(melon = \"Canteloupe\", numPets = 0) {\n customer.set(\"Melon\", melon);\n customer.set(\"Pets\", numPets);\n\n}", "get_mult(units) {\n var mult = 0;\n if (units === 'minutes') {\n mult = 1;\n } else if (units === 'hours') {\n mult = 60;\n } else if (units === 'days') {\n mult = 60 * 24;\n } else if (units === 'months') {\n mult = 30 * 60 * 24;\n } else if (units === 'years') {\n mult = 365 * 60 * 24;\n } else {\n throw new TypeError;\n }\n return mult;\n }", "function forAllTeams(v, k, m) {\n m.get(k).set(\"Win Percentage\", (m.get(k).get(\"Wins\")+(m.get(k).get(\"Ties\") * 0.5))/m.get(k).get(\"Games played\"));\n }", "function updateProperties(properties) {\n var tilt = properties.tiltPercentage;\n simulationMode = properties.simulationMode;\n\n // Cancel simulation mode before we parse the incoming request.\n if (simulationTimerId) {\n clearTimeout(simulationTimerId);\n simulationTimerId = null;\n }\n\n if (simulationMode) {\n if (isNaN(tilt))\n solarProperties.tiltPercentage = 0;\n else\n solarProperties.tiltPercentage = tilt;\n\n solarProperties.lcd1 = new Date();\n var locationInfo;\n if (properties.lcd2)\n locationInfo = properties.lcd2.split(' ')[1];\n\n if (locationInfo && typeof locationInfo === 'string')\n solarProperties.locationInfo = locationInfo;\n else\n solarProperties.locationInfo = 'Europe/Helsinki';\n\n startSimulation();\n } else {\n updateSolarPanel(tilt, properties.lcd1, properties.lcd2);\n }\n}", "constructor(name, u, t){\n this.name = name;\n this.u = u;\n this.t = t;\n }", "function setTargetText() {\n\n // The target text should display at least one character\n var targetLength = Settings.TARGET_TEXT_LENGTH\n if (targetLength < 1) {\n targetLength = 1\n }\n\n // Length of the target text should be odd as equal number of\n // characters should be displayed on either side of the\n // character to be typed\n if (targetLength % 2 == 0) {\n targetLength--\n }\n\n // Number of characters on either side of the character to be\n // typed, assuming that the character to be typed is at the\n // centre\n var prefixLength = (targetLength - 1) / 2\n\n // Calculate the start index and the end index of the substring\n // to be selected from the subunit text to display as the target\n // text\n var i = my.current.correctInputLength\n var textLength = my.current.subunitText.length\n if (i <= prefixLength) {\n var startIndex = 0\n } else if (i >= textLength - 1 - prefixLength) {\n var startIndex = textLength - targetLength\n } else {\n var startIndex = i - prefixLength\n }\n var endIndex = startIndex + targetLength\n\n // Select prefix string\n var s = my.current.subunitText.substring(startIndex, i)\n my.current.targetPrefix = Util.visual(s)\n\n // Select target character\n if (i < textLength) {\n s = my.current.subunitText.charAt(i)\n my.current.targetChar = Util.visual(s)\n } else {\n my.current.targetChar = ''\n }\n\n // Select suffix string\n s = my.current.subunitText.substring(i + 1, endIndex)\n my.current.targetSuffix = Util.visual(s)\n }", "function Uf(a){this.m=a}", "function camSetPropulsionTypeLimit(num)\n{\n\tif (!camDef(num))\n\t{\n\t\t__camPropulsionTypeLimit = \"NO_USE\";\n\t}\n\telse if (num === 2)\n\t{\n\t\t__camPropulsionTypeLimit = \"02\";\n\t}\n\telse if (num === 3)\n\t{\n\t\t__camPropulsionTypeLimit = \"03\";\n\t}\n}", "function setCountryUnits() {\n // body... \n if (countryName === \"US\" || countryName === \"LY\") { // in year 2016 only USA and Libya not metric.\n\n countryUnits = \"imperial\";\n\n }\n }", "constructor(unit) {\r\n this.unit = unit;\r\n this.sequence = [];\r\n this.min = new Date(\"9999-12-31T23:59:59.999\");\r\n this.max = new Date(\"0001-01-01T00:00:00.000\");\r\n }", "get unit() {\n\t\treturn this.__unit;\n\t}", "function onPmChanged() {\n var val_str = document.getElementById(\"pm\").value;\n var val_good = check_unit( val_str, \"deg\", \"pm\" );\n if (val_good) {\n setPm( math.unit( document.getElementById(\"pm\").value ).toJSON().value ); // without toJSON it will return in radians\n } else {\n document.getElementById(\"pm\").value = math.unit(pll.pm,\"deg\").toString();\n return;\n }\n\n synthPll();\n}", "function updateUnitHandler() {\n var dim;\n\n var unit = new NaturalUnit();\n\n // update organization record\n unit.ID = $(\"#NaturalUnitList\").find('option:selected').val();\n unit.OrganizationID = currentOrg.ID;\n unit.Name = $(\"#txtName\").val();\n unit.Description = $(\"#txtDescription\").val();\n unit.isActive = 1;\n unit.isActive = $('#activeFlag').prop('checked');\n unit.UserID = UserID;\n\n updateNaturalUnit(unit, updateUnitDimensions, pmmodaErrorHandler)\n\n\n }", "'populate' (max_subdivisions) // detail is obtained. Project all new vertices to unit vectors (onto the unit sphere) and group them into triangles by \r\n { // following the predictable pattern of the recursion.\r\n this.positions.push([0, 0, -1], [0, .9428, .3333], [-.8165, -.4714, .3333], [.8165, -.4714, .3333]); // Start with this equilateral tetrahedron\r\n\r\n this.subdivideTriangle(0, 1, 2, max_subdivisions); // Begin recursion.\r\n this.subdivideTriangle(3, 2, 1, max_subdivisions);\r\n this.subdivideTriangle(1, 0, 3, max_subdivisions);\r\n this.subdivideTriangle(0, 2, 3, max_subdivisions);\r\n\r\n for (let p of this.positions) {\r\n this.normals.push(p.slice()); // Each point has a normal vector that simply goes to the point from the origin. Copy array value using slice().\r\n this.texture_coords.push(vec2(.5 + Math.atan2(p[2], p[0]) / 2 / Math.PI, .5 - 2 * Math.asin(p[1]) / 2 / Math.PI));\r\n }\r\n }", "function functPerim(){\n\n let longVal = parseFloat(long.value);\n const unitLongVal = unitLong.value;\n let largVal = parseFloat(larg.value);\n const unitLargVal = unitLarg.value;\n let def = false ;\n\n // const UNIT = {\"mm\":1000, \"cm\":100, \"dm\":10, \"m\":1};\n\n if (isNaN(longVal) || longVal <= 0 || isNaN(largVal) || largVal <= 0) {\n resultPerim.innerHTML = \"Veuillez rentrer une longueur et une largeur positive !\";\n } else {\n\n\n switch (unitLongVal) {\n case \"mm\":\n longVal /= 1000;\n break;\n case \"cm\":\n longVal /= 100;\n break;\n case \"dm\":\n longVal /= 10;\n break;\n case \"m\":\n longVal /= 1;\n break;\n default:\n def = true ;\n resultPerim.innerHTML = \"Veuillez rentrer une unité de longueur acceptable (\" + unitLongVal + \") !\";\n break;\n }\n\n switch (unitLargVal) {\n case \"mm\":\n largVal /= 1000;\n break;\n case \"cm\":\n largVal /= 100;\n break;\n case \"dm\":\n largVal /= 10;\n break;\n case \"m\":\n largVal /= 1;\n break;\n default:\n def = true ;\n resultPerim.innerHTML = \"Veuillez rentrer une unité de largeur acceptable (\" + unitLargVal + \") !\";\n break;\n } \n\n if( def === false){\n resultPerim.innerHTML = \"Le perimetre d'un surface de coté \" + longVal + unitLongVal + \" x \" + largVal + unitLargVal + \" est de \" + ((parseFloat(longVal) + parseFloat(largVal)) * 2).toFixed(2) + \" m \";\n }\n }\n\n}", "function creeTypeMtchGrp1(g, j, m)\r{ // Les équipes sont accessibles depuis les numéros ci-dessous\r\tthis.g = g; // N° de groupe pour accès interne\r\tthis.j = j;// N° de journée\r\tthis.m = m; // N° de match dans la journée\r //----------\r // Résultats\r //----------\r \tthis.sm = [0, 0]; // Manches gagnées par les équipes\r \tthis.sd = [0, 0]; // dés gagnés par les équipes\r \tthis.affecte = mtchGrp1Affecte;\r \tthis.affiche = mtchGrp1Affiche;\r}", "function setStartDegrees(unit) {\n const now = new Date();\n const sec = now.getSeconds();\n const min = now.getMinutes();\n if (unit === \"sec\") {\n // time = now.getSeconds();\n return (sec * (360 / 60) + 97);\n } else if (unit === \"min\") {\n // time = now.getMinutes();\n return (min * (360 / 60) + 90 + (sec/ 60) * 6); // 6 = degrees per minute\n } else if (unit === \"hour\") {\n time = now.getHours();\n return (time * (360 / 12) + 90 + ((min / 60) * 30)); // 30 = degrees per hour\n }\n}", "setTargetOrientation(fx, fy, fz, ux, uy, uz, t, dt) {\n this.setTarget(this.end.p[0], this.end.p[1], this.end.p[2], fx, fy, fz, ux, uy, uz, t, dt);\n }", "_setup_material_uniforms(material, uniformSetter) {\n // Setup custom user uniforms (in case of CustomShaderMaterial)\n if (material instanceof LOGI.CustomShaderMaterial) {\n let customUniforms = material._uniforms;\n\n // Set all of the custom uniforms if they are defined within the shader\n for (let name in customUniforms) {\n if (customUniforms.hasOwnProperty(name)) {\n if (uniformSetter[name] !== undefined) {\n uniformSetter[name].set(customUniforms[name]);\n }\n }\n }\n }\n else {\n if (uniformSetter[\"material.diffuse\"] !== undefined) {\n uniformSetter[\"material.diffuse\"].set(material.color.toArray());\n }\n\n if (uniformSetter[\"material.specular\"] !== undefined) {\n uniformSetter[\"material.specular\"].set(material.specular.toArray());\n }\n\n if (uniformSetter[\"material.shininess\"] !== undefined) {\n uniformSetter[\"material.shininess\"].set(material.shininess);\n }\n }\n\n // Setup texture uniforms (Are common for both predefined materials and custom shader material)\n let textures = material.maps;\n\n for (let i = 0; i < textures.length; i++) {\n const texture = \"material.texture\" + i;\n if (uniformSetter[texture] !== undefined) {\n uniformSetter[texture].set(this._glManager.getTexture(textures[i]), i);\n }\n }\n }", "function setSettings(t1Name, t2Name, timerMins, startingTeam)\n{\n t1_name = t1Name;\n t2_name = t2Name;\n timer_mins = timerMins;\n starting_team = startingTeam;\n\n document.getElementsByClassName(\"team-one\")[0].innerHTML = t1Name;\n T1.name = t1Name;\n\n document.getElementsByClassName(\"team-two\")[0].innerHTML = t2Name;\n T2.name = t2Name;\n\n document.getElementsByClassName(\"minutes\")[0].innerHTML = timer_mins;\n timer.minutes = timer_mins;\n\n document.getElementsByClassName(\"input-team\")[0].innerHTML = \"<b>Possession: \" + starting_team + \"</b>\";\n currTeam = starting_team;\n}", "setRightUnit(valueNew){let t=e.ValueConverter.toDimensionUnit(valueNew);null===t&&(t=this.getAttributeDefaultValueInternal(\"RightUnit\")),t!==this.__rightUnit&&(this.__rightUnit=t,e.EventProvider.raise(this.__id+\".onPropertyChanged\",{propertyName:\"RightUnit\"}),this.__processRightUnit())}" ]
[ "0.54758155", "0.52496386", "0.49302256", "0.49276233", "0.49223965", "0.49028546", "0.49028546", "0.4879682", "0.48509598", "0.4790742", "0.47573644", "0.4746591", "0.46574658", "0.46320707", "0.45933446", "0.45891666", "0.4576543", "0.45003316", "0.44828627", "0.4465418", "0.44550613", "0.4452959", "0.44489872", "0.4446852", "0.44393513", "0.441655", "0.440703", "0.43846184", "0.43820027", "0.4367751", "0.4367666", "0.43629238", "0.43519777", "0.4350593", "0.4350472", "0.4349981", "0.43423113", "0.43421423", "0.4342094", "0.43415183", "0.43388414", "0.43340474", "0.43321192", "0.43223834", "0.43092677", "0.43091854", "0.42995906", "0.42876205", "0.4284121", "0.4283415", "0.42792574", "0.42683053", "0.42663968", "0.42592707", "0.423536", "0.4233968", "0.4233422", "0.4233422", "0.42309204", "0.4229968", "0.42283577", "0.42265573", "0.42249858", "0.42211685", "0.42106527", "0.4203344", "0.41977885", "0.4183896", "0.41785046", "0.4176674", "0.417556", "0.41748717", "0.4171335", "0.41675362", "0.41561645", "0.4155377", "0.415058", "0.4132533", "0.41283238", "0.41254398", "0.41211826", "0.41172028", "0.41164264", "0.41157645", "0.41151875", "0.41075715", "0.41038626", "0.41027948", "0.40951118", "0.40852785", "0.40830636", "0.40812075", "0.4080267", "0.40788364", "0.40787202", "0.40783936", "0.40772194", "0.4070321", "0.40690857", "0.4065548" ]
0.75769377
0
Display the subunit links for the current unit.
function displaySubunitLinks() { // Delete all existing subunit links var linksDiv = my.html.subunitLinks while (linksDiv.firstChild && linksDiv.firstChild.className != 'stretch') { linksDiv.removeChild(linksDiv.firstChild) } // Create new subunit links for the unit m var numberOfSubunits = my.current.subunitTitles.length for (var i = numberOfSubunits - 1; i >= 0; i--) { // Insert whitespaces between div elements, otherwise they // would not be justified var whitespace = document.createTextNode('\n') linksDiv.insertBefore(whitespace, linksDiv.firstChild) var label = my.current.subunitTitles[i] var selected = (i + 1 == my.current.subunitNo) var href = unitHref(my.current.unitNo, i + 1) var subunitDiv = boxedLink(label, selected, href) subunitDiv.id = 'subunit' + (i + 1) subunitDiv.style.width = (95 / numberOfSubunits) + '%' linksDiv.insertBefore(subunitDiv, linksDiv.firstChild) } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function displayUnitLinks()\n {\n // Delete all existing unit links\n var linksDiv = my.html.unitLinks\n Util.removeChildren(linksDiv)\n\n // Create new unit links\n for (var i = 0; i < Units.main.length; i++) {\n var label = 'སློབ་མཚན། ' + (i + 1)\n var selected = (i + 1 == my.current.unitNo)\n var href = unitHref(i + 1)\n\n var divElement = boxedLink(label, selected, href)\n divElement.id = 'unit' + (i + 1)\n divElement.title = unit(i + 1).title\n\n linksDiv.appendChild(divElement)\n }\n }", "function displayAlternateUnitLinks()\n {\n // If alternate unit is not available for the current unit,\n // hide the alternate links element\n if (!alternateUnitAvailable(my.current.unitNo)) {\n alternateUnitLinks.style.visibility = 'hidden'\n return\n }\n\n // Delete all existing alternate unit links\n Util.removeChildren(alternateUnitLinks)\n\n // Create div elements for the main unit and alternate unit\n var mainUnitElement =\n boxedLink(Units.mainLabel,\n my.settings.unit == my.UNIT.MAIN,\n '#', toggleUnit)\n\n var alternateUnitElement =\n boxedLink(Units.alternateLabel,\n my.settings.unit == my.UNIT.ALTERNATE,\n '#', toggleUnit)\n\n alternateUnitLinks.appendChild(mainUnitElement)\n alternateUnitLinks.appendChild(alternateUnitElement)\n alternateUnitLinks.style.visibility = 'visible'\n }", "function currentSubunit()\n {\n var m = my.current.unitNo\n var n = my.current.subunitNo\n\n window.location.href = unitHref(m, n)\n }", "function updateNavigationLinks()\n {\n if (currentSubunitIsTheFirstSubunit()) {\n my.html.previousLink.style.visibility = 'hidden'\n my.html.nextLink.style.visibility = 'visible'\n } else if (currentSubunitIsTheLastSubunit()) {\n my.html.previousLink.style.visibility = 'visible'\n my.html.nextLink.style.visibility = 'hidden'\n } else {\n my.html.previousLink.style.visibility = 'visible'\n my.html.nextLink.style.visibility = 'visible'\n }\n }", "setupSubLinks() {\n for (let subLink in this.subLinks) {\n this.subLinks[subLink].addEventListener(\"click\", (e) => {\n let linkID = e.target.id;\n if (linkID === \"\") {\n linkID = e.target.parentNode.id;\n }\n let subViewToShow = linkID.slice(0, -5);\n this.showSubView(subViewToShow);\n });\n }\n }", "function displayUnitTitle() {\n\n // Parts of the unit title\n var unitNo = 'སློབ་མཚན། ' + my.current.unitNo +\n '.' + my.current.subunitNo\n var space = '\\u00a0\\u00a0'\n var title = '[' + my.current.unit.title + ']'\n\n Util.setChildren(my.html.unitTitle, unitNo, space, title)\n }", "function nextSubunit()\n {\n var m = my.current.unitNo\n var n = my.current.subunitNo\n\n if (!currentSubunitIsTheLastSubunit()) {\n if (n == my.current.subunitTitles.length) {\n // If the user is at unit M.L where L is the last\n // subunit of unit M, then go to unit (M + 1).1.\n m++\n n = 1\n } else {\n // If the user is at unit M.N, then go to unit M.(N + 1).\n n++\n }\n }\n\n window.location.href = unitHref(m, n)\n }", "showAll() {\n this.down(this.$element.find('[data-submenu]'));\n }", "show() {\n for (let node of this.nodes) {\n node.show();\n node.showLinks();\n }\n }", "populateUnitMenus() {\n\t\tlet category = this.m_catMenu.value;\n\t\tthis.m_unitAMenu.innerHTML = \"\";\n\t\tCONFIG[category].forEach(function(item) {\n\t\t\tGUI.m_unitAMenu.innerHTML += \"<option value=\\\"\" + item[0] + \"\\\">\" + item[1] + \"</option>\";\n\t\t});\n\t\t\n\t\tthis.m_unitBMenu.innerHTML = \"\";\n\t\tCONFIG[category].forEach(function(item) {\n\t\t\tGUI.m_unitBMenu.innerHTML += \"<option value=\\\"\" + item[0] + \"\\\">\" + item[1] + \"</option>\";\n\t\t});\n\t}", "function renderUnit(unit) {\n return crel('li',\n crel('span', {'class':'naam'}, unit.naam), \n crel('span', {'class':'afkorting'}, unit.afkorting),\n crel('span', {'class':'wikilink'},\n crel ('a', {'href':unit.wikilink},unit.wikilink)),\n crel('span', {'class':'wow'}, unit.wieofwat),\n crel('span', {'class':'foto'}, \n crel ('img', {'src': unit.foto})),\n )\n }", "function updateUnitFromURL()\n {\n // Default lesson is Unit 1.1\n var unitNo = 1\n var subunitNo = 1\n\n // Parse the fragment identifier in the URL and determine the\n // unit\n if (window.location.hash.length > 0) {\n var fragmentID = window.location.hash.slice(1)\n var tokens = fragmentID.split('.')\n unitNo = parseInt(tokens[0])\n if (tokens.length > 1)\n subunitNo = parseInt(tokens[1])\n }\n\n // Default to unit 1 if unit number could not be parsed\n // correctly from the URL\n if (isNaN(unitNo)) {\n unitNo = 1\n }\n\n // Default to subunit 1 if unit number could not be parsed\n // correctly from the URL\n if (isNaN(subunitNo)) {\n subunitNo = 1\n }\n\n setSubunit(unitNo, subunitNo)\n\n displayUnitLinks()\n displaySubunitLinks()\n displayAlternateUnitLinks()\n updateNavigationLinks()\n updateProgressTooltip()\n\n displayUnitTitle()\n displayGuide()\n\n resetSubunit()\n }", "function show()\r\n{\r\n // show the sub menu\r\n this.getElementsByTagName('ul')[0].style['visibility'] = 'visible';\r\n var currentNode=this;\r\n while(currentNode)\r\n {\r\n if( currentNode.nodeName=='LI')\r\n {\r\n currentNode.getElementsByTagName('a')[0].className = 'linkOver';\r\n }\r\n currentNode=currentNode.parentNode;\r\n }\r\n // clear the timeout\r\n eval ( \"clearTimeout( timeout\"+ this.id +\");\" );\r\n hideAllOthersUls( this );\r\n}", "function lijstSubMenuItem() {\n\n if ($mLess.text() == \"meer\") {\n $mLess.text(\"minder\")\n } else {\n $mLess.text(\"meer\");\n\n }\n $list.toggleClass('hidden')\n $resum.get(0).scrollIntoView('slow');\n event.preventDefault()\n }", "function displaySub(submenu){\n\n if (submenu == 'Nail Extensions'){\n $('#extensions-options').html(extensions_fills_sub);\n $('#fills-options').html('');\n $('#manicure-options').html('');\n }\n else if(submenu == 'Fills'){\n $('#extensions-options').html('');\n $('#fills-options').html(extensions_fills_sub);\n $('#manicure-options').html('');\n }\n\n else if(submenu == 'Manicure'){\n $('#extensions-options').html('');\n $('#fills-options').html('');\n $('#manicure-options').html(manicure_sub)\n\n }\n\n}", "function RMTLinkAsSub_onClick() {\n RMTLinkAsSubDerived(\"Sub\");\n}", "function setSubunit(m, n)\n {\n my.current.unitNo = m\n my.current.subunitNo = n\n\n my.current.unit = unit(m)\n\n my.current.subunitTitles.length = 0\n for (var subunitTitle in my.current.unit.subunits) {\n my.current.subunitTitles.push(subunitTitle)\n }\n\n var subunitTitle = my.current.subunitTitles[n - 1]\n my.current.subunitText = my.current.unit.subunits[subunitTitle]\n }", "function showUnits() {\n console.log(\"showUnits()\");\n units.forEach(unit => {\n /*\n // add unit names to page\n var unitName = document.createElement(\"h1\");\n unitName.innerText = unit.fields.name;\n document.body.appendChild(unitName);\n\n // add unit location to page\n unitLocation = document.createElement(\"p\");\n unitLocation.innerText = unit.fields.location;\n document.body.appendChild(unitLocation);\n\n // add image to page\n var unitImage = document.createElement(\"img\");\n unitImage.src = unit.fields.image[0].url;\n document.body.appendChild(unitImage); */\n\n // creating a new div container, where our unit info will go\n var unitContainer = document.createElement(\"div\");\n unitContainer.classList.add(\"unit-container\");\n document.querySelector(\".container\").append(unitContainer);\n\n // add unit names to unit container\n var unitName = document.createElement(\"h2\");\n unitName.classList.add(\"unit-name\");\n unitName.innerText = unit.fields.name;\n unitContainer.append(unitName);\n\n // add location to unit container\n var unitLocation = document.createElement(\"h3\");\n unitLocation.classList.add(\"unit-location\");\n unitLocation.innerText = unit.fields.location;\n unitLocation.style.color = \"#5F5C4F\";\n unitContainer.append(unitLocation);\n\n // add description to container\n var unitDescription = document.createElement(\"p\");\n unitDescription.classList.add(\"unit-description\");\n unitDescription.innerText = unit.fields.description;\n unitContainer.append(unitDescription);\n\n // add image to container\n var unitImage = document.createElement(\"img\");\n unitImage.classList.add(\"unit-image\");\n unitImage.src = unit.fields.image[0].url;\n unitContainer.append(unitImage);\n\n // add event listener\n // when user clicks on unit container\n // image and description will appear or disappear\n unitContainer.addEventListener(\"click\", function() {\n unitDescription.classList.toggle(\"active\");\n unitImage.classList.toggle(\"active\");\n });\n\n // add to each container as a class\n var unitCh = unit.fields.chapter;\n console.log(unitCh);\n unitContainer.classList.add(unitCh);\n\n // filter by chapter 2\n var filterCh2 = document.querySelector(\".ch2\");\n filterCh2.addEventListener(\"click\", function(){\n if(unitContainer.classList.contains(\"chapter2\")){\n unitContainer.style.background = \"#D7D2B5\";\n }\n else{\n unitContainer.style.background = \"#9f9b86\";\n }\n })\n\n var filterCh3 = document.querySelector(\".ch3\");\n filterCh3.addEventListener(\"click\", function(){\n if(unitContainer.classList.contains(\"chapter3\")){\n unitContainer.style.background = \"#D7D2B5\";\n }\n else{\n unitContainer.style.background = \"#9f9b86\";\n }\n })\n\n var filterCh4 = document.querySelector(\".ch4\");\n filterCh4.addEventListener(\"click\", function(){\n if(unitContainer.classList.contains(\"chapter4\")){\n unitContainer.style.background = \"#D7D2B5\";\n }\n else{\n unitContainer.style.background = \"#9f9b86\";\n }\n })\n\n var filterCh5 = document.querySelector(\".ch5\");\n filterCh5.addEventListener(\"click\", function(){\n if(unitContainer.classList.contains(\"chapter5\")){\n unitContainer.style.background = \"#D7D2B5\";\n }\n else{\n unitContainer.style.background = \"#9f9b86\";\n }\n })\n\n var filterCh6 = document.querySelector(\".ch6\");\n filterCh6.addEventListener(\"click\", function(){\n if(unitContainer.classList.contains(\"chapter6\")){\n unitContainer.style.background = \"#D7D2B5\";\n }\n else{\n unitContainer.style.background = \"#9f9b86\";\n }\n })\n\n var filterCh9 = document.querySelector(\".ch9\");\n filterCh9.addEventListener(\"click\", function(){\n if(unitContainer.classList.contains(\"chapter9\")){\n unitContainer.style.background = \"#D7D2B5\";\n }\n else{\n unitContainer.style.background = \"#9f9b86\";\n }\n })\n\n var filterCh13 = document.querySelector(\".ch13\");\n filterCh13.addEventListener(\"click\", function(){\n if(unitContainer.classList.contains(\"chapter13\")){\n unitContainer.style.background = \"#D7D2B5\";\n }\n else{\n unitContainer.style.background = \"#9f9b86\";\n }\n })\n\n var filterCh14 = document.querySelector(\".ch14\");\n filterCh14.addEventListener(\"click\", function(){\n if(unitContainer.classList.contains(\"chapter14\")){\n unitContainer.style.background = \"#D7D2B5\";\n }\n else{\n unitContainer.style.background = \"#9f9b86\";\n }\n })\n\n var filterCh17 = document.querySelector(\".ch17\");\n filterCh17.addEventListener(\"click\", function(){\n if(unitContainer.classList.contains(\"chapter17\")){\n unitContainer.style.background = \"#D7D2B5\";\n }\n else{\n unitContainer.style.background = \"#9f9b86\";\n }\n })\n\n var reset = document.querySelector(\".reset\");\n reset.addEventListener(\"click\", function(){\n unitContainer.style.background = \"#9f9b86\";\n })\n });\n}", "function showSubMenu() {\n\tvar objThis = this;\t\n\tfor (var i = 0; i < objThis.childNodes.length; i++) {\n\t\tif (objThis.childNodes.item(i).nodeName == \"UL\")\t{\t\t\t\t\t\t\t\n\t\t\tobjThis.childNodes.item(i).style.display = \"block\";\n\t\t}\t\t\n\t}\t\n}", "function renderSubLinks(){\n if(sublinks.length === 0){\n return null;\n }\n else{\n return(\n <React.Fragment>\n <div className=\"side-menu-links\">\n <SideMenu sublinks={sublinks}/>\n </div>\n <hr/>\n </React.Fragment>\n );\n }\n }", "function conservationCon() {\n console.log(\"Links Changed\")\n document.getElementById(\"subLinks\").innerHTML = \"\";\n document.getElementById(\"subLinks\").innerHTML = \"<h3>Conservation</h3><ul><li><a href='#'><h4>Carolinian Canada</h4></a></li><li><a href='#'><h4>Friends of the Thames / Thames River Cleanup</h4></a></li><li><a href='#'><h4>Nature London</h4></a></li><li><a href='#'><h4>North Shore Steelhead Association</h4></a></li><li><a href='#'><h4>Ontario Streams</h4></a></li><li><a href='#'><h4>Ontario Federation of Anglers and Hunters</h4></a></li><li><a href='#'><h4>Trout Unlimited Canada</h4></a></li></ul>\";\n}", "function showSubUL(img, subUL){\n $SC(img, 'fa-angle-down', 'fa-angle-up' ); \n $SC(subUL, 'hide-sub-ul' , 'show-sub-ul' );\n}", "function unit() {\n // Add more tests here.\n return linkUnit();\n}", "function previousSubunit()\n {\n var m = my.current.unitNo\n var n = my.current.subunitNo\n\n if (!currentSubunitIsTheFirstSubunit()) {\n if (n == 1) {\n // If the user is at unit M.1, go to unit (M - 1).L\n // where L is the last subunit of the previous unit.\n previousUnit = unit(m - 1)\n var previousSubunitTitles = []\n for (var subunitTitle in previousUnit.subunits) {\n previousSubunitTitles.push(subunitTitle)\n }\n\n m--\n n = previousSubunitTitles.length\n } else {\n // If the user is at unit M.N, go to unit M.(N - 1)\n n--\n }\n }\n\n window.location.href = unitHref(m, n)\n }", "link() {\n\t\t// Call super link to link members of Top Level (Identified)\n\t\tsuper.link();\n\t\t\n this._members = this._sbolDocument.lookupURIs(this._members);\n }", "function showSubpages(subpage1, subpage2, subpage3, subpage4, subpage5, subpage6) {\n var subpages = [subpage1, subpage2, subpage3, subpage4, subpage5, subpage6];\n var i = 0;\n var x;\n for(var i = 0; i < subpages.length; i++) {\n if(subpages[i] == null) {\n break;\n }\n x = document.getElementById(subpages[i]);\n if (x.className === \"subpage-button\") {\n x.className += \" open\";\n }\n else {\n x.className = \"subpage-button\";\n }\n }\n}", "get subPlanDisplay() {\n\t\treturn this.__subPlanDisplay;\n\t}", "levelUp() {\n\t\tthis.getActiveUnits().forEach(unit => {\n\t\t\tunit.levelUp();\n\t\t});\n\t}", "function showMobileSubLInks(link){ \n let icon=link.children[1];\n let childUL=link.children[2];\n if(childUL.classList.contains('hide-mobile-sub-ul')){ \n $SC(icon, 'fa-angle-down', 'fa-angle-up');\n $SC(childUL, 'hide-mobile-sub-ul', 'show-mobile-sub-ul');\n } else{ \n $SC(icon, 'fa-angle-up', 'fa-angle-down');\n $SC(childUL, 'show-mobile-sub-ul', 'hide-mobile-sub-ul');\n }\n}", "function _showSubscribersView() {\n\t\tif (RELAY_USER.isSuperAdmin()) {\n\t\t\t_subscriberProcessingStart();\n\t\t\t$('#subscribersView').fadeIn();\n\n\t\t\t// Pull entire list of subscribers (past and present)\n\t\t\t$.when(SUBSCRIBERS.getSubscribersXHR()).done(function (orgs) {\n\t\t\t\tvar tblBody = '';\n\t\t\t\t$.each(orgs, function (index, orgObj) {\n\t\t\t\t\t// `active` parameter\n\t\t\t\t\tvar $dropDownAccess = $('#tblDropdownTemplate').clone();\n\t\t\t\t\tswitch (orgObj.active) {\n\t\t\t\t\t\tcase \"1\":\n\t\t\t\t\t\t\t$dropDownAccess.find('.currentValue').text('Aktiv');\n\t\t\t\t\t\t\t$dropDownAccess.find('.dropdown-menu').append('<li style=\"cursor: pointer;\"><a class=\"btn-link btnDeactivateOrgAccess\" data-org=\"' + orgObj.org + '\">Steng tilgang</a></li>');\n\t\t\t\t\t\t\t$dropDownAccess.find('.btn').addClass('btn-success');\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase \"0\":\n\t\t\t\t\t\t\t$dropDownAccess.find('.currentValue').text('Stengt');\n\t\t\t\t\t\t\t$dropDownAccess.find('.dropdown-menu').append('<li style=\"cursor: pointer;\"><a class=\"btn-link btnActivateOrgAccess\" data-org=\"' + orgObj.org + '\">Aktiver tilgang</a></li>');\n\t\t\t\t\t\t\t$dropDownAccess.find('.btn').addClass('btn-danger');\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\t// `affiliation_access` parameter\n\t\t\t\t\tvar $dropDownAffiliation = $('#tblDropdownTemplate').clone();\n\t\t\t\t\t$dropDownAffiliation.find('.currentValue').text(orgObj.affiliation_access);\n\t\t\t\t\tswitch (orgObj.affiliation_access) {\n\t\t\t\t\t\tcase \"employee\":\n\t\t\t\t\t\t\t$dropDownAffiliation.find('.btn').addClass('btn-info');\n\t\t\t\t\t\t\t$dropDownAffiliation.find('.dropdown-menu').append('<li style=\"cursor: pointer;\"><a class=\"btn-link btnAddOrgStudentAccess\" data-org=\"' + orgObj.org + '\">Legg til studenttilgang</a></li>');\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase \"member\":\n\t\t\t\t\t\t\t$dropDownAffiliation.find('.btn').addClass('btn-primary');\n\t\t\t\t\t\t\t$dropDownAffiliation.find('.dropdown-menu').append('<li style=\"cursor: pointer;\"><a class=\"btn-link btnRemoveOrgStudentAccess\" data-org=\"' + orgObj.org + '\">Fjern studenttilgang</a></li>');\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\n\t\t\t\t\t// Add row to table\n\t\t\t\t\ttblBody += '<tr>' +\n\t\t\t\t\t\t'<td>' + orgObj.org + '</td>' +\n\t\t\t\t\t\t//'<td>' + orgObj.affiliation_access + '</td>' +\n\t\t\t\t\t\t'<td>' + $dropDownAffiliation.html() + '</td>' +\n\t\t\t\t\t\t//'<td>' + orgObj.active + '</td>' +\n\t\t\t\t\t\t'<td>' + $dropDownAccess.html() + '</td>' +\n\t\t\t\t\t\t'<td class=\"text-center\"><button class=\"btnDeleteOrg btn-link uninett-fontColor-red\" type=\"button\" data-org=\"' + orgObj.org + '\"><span class=\"glyphicon glyphicon-remove\"></span></button></td>' +\n\t\t\t\t\t\t'</tr>';\n\t\t\t\t});\n\t\t\t\t$('#tblSubscribers').find('tbody').html(tblBody);\n\t\t\t\t//\n\t\t\t\t_subscriberProcessingEnd()\n\t\t\t});\n\t\t}\n\t}", "link() {\n\t\t// Call super link to link members of Top Level (Identified)\n\t\tsuper.link();\n\n this._modules = this._sbolDocument.lookupURIs(this._modules);\n this._functionalComponents = this._sbolDocument.lookupURIs(this._functionalComponents);\n this._interactions = this._sbolDocument.lookupURIs(this._interactions);\n this._models = this._sbolDocument.lookupURIs(this._models);\n }", "function displayGuide() {\n my.html.guide.innerHTML = my.current.unit.guide\n }", "showSubMenu() {\n const item = this.selectedItem;\n const subMenu = this.getSubMenuFromItem(item);\n if (subMenu) {\n this.subMenu = subMenu;\n item.setAttribute('sub-menu-shown', 'shown');\n this.positionSubMenu_(item, subMenu);\n subMenu.show();\n subMenu.parentMenuItem = item;\n this.moveSelectionToSubMenu_(subMenu);\n }\n }", "function sb_writeSubsectionNav () {\n\tvar sHTML = \"\";\n\tvar currentLocation = location.href;\n\tcurrentLocation = currentLocation.slice(currentLocation.lastIndexOf(\"/\")+1);\n\tcurrentSection = -1;\n\tcurrentIndex = -1;\n\t\n\t//alert(\"currentIndex = \"+currentIndex);\n\t\n\tfor (i=0; (i<subsection.length) && (currentSection < 0); i++) {\n\t\tfor (j=0; (j<subsection[i].length) && (currentIndex < 0); j++) {\n\t\t\tif (subsection[i][j].indexOf(currentLocation) != -1) {\n\t\t\t\t//alert (\"index found at \"+j+\" - \"+i);\n\t\t\t\tcurrentIndex = j;\n\t\t\t\tcurrentSection = i;\n\t\t\t}\n\t\t}\n\t}\n\t\n\tsHTML += \"<table border=\\\"0\\\" cellspacing=\\\"0\\\" cellpadding=\\\"0\\\">\";\n\tsHTML += \"<tr>\";\n\tsHTML += \"<td><img src=\\\"/site_images/s.gif\\\" width=\\\"1\\\" height=\\\"10\\\" alt=\\\"\\\"/></td>\"\n\tsHTML += \"<td align=\\\"center\\\" valign=\\\"middle\\\" class=\\\"prevNext\\\" height=\\\"10\\\" nowrap>\";\n\t\n\tif ((currentIndex-1) < 0) {\n\t\tsHTML += \"<img src=\\\"/site_images/s.gif\\\" width=\\\"2\\\" height=\\\"1\\\" alt=\\\"\\\" /><span class=\\\"prevNextArrow\\\">&lt;</span><img src=\\\"/site_images/s.gif\\\" width=\\\"5\\\" height=\\\"1\\\" alt=\\\"\\\" />\" + prevText ;\n\t} else {\n\t\tsHTML += \"<img src=\\\"/site_images/s.gif\\\" width=\\\"2\\\" height=\\\"1\\\" alt=\\\"\\\" /><span class=\\\"prevNextArrow\\\">&lt;</span><img src=\\\"/site_images/s.gif\\\" width=\\\"5\\\" height=\\\"1\\\" alt=\\\"\\\" /><a href=\\\"\" + subsection[currentSection][currentIndex-1] + \"\\\" class=\\\"prevNextLink\\\">\" + prevText + \"</a>\";\n\t}\n\t\n\tif (subsectionIndex == \"\") {\n\t\tsHTML += \"<img src=\\\"/site_images/s.gif\\\" width=\\\"4\\\" height=\\\"1\\\" alt=\\\"\\\" />|<img src=\\\"/site_images/s.gif\\\" width=\\\"5\\\" height=\\\"1\\\" alt=\\\"\\\" />\";\n\t\tsHTML += \"Index\";\n\t\tsHTML += \"<img src=\\\"/site_images/s.gif\\\" width=\\\"4\\\" height=\\\"1\\\" alt=\\\"\\\" />|<img src=\\\"/site_images/s.gif\\\" width=\\\"5\\\" height=\\\"1\\\" alt=\\\"\\\" />\";\n\t} else {\n\t\tsHTML += \"<img src=\\\"/site_images/s.gif\\\" width=\\\"4\\\" height=\\\"1\\\" alt=\\\"\\\" />|<img src=\\\"/site_images/s.gif\\\" width=\\\"5\\\" height=\\\"1\\\" alt=\\\"\\\" />\";\n\t\tsHTML += \"<a href=\\\"\" + subsectionIndex + \"\\\" class=\\\"prevNextLink\\\">\" + indexText + \"</a>\";\n\t\tsHTML += \"<img src=\\\"/site_images/s.gif\\\" width=\\\"4\\\" height=\\\"1\\\" alt=\\\"\\\" />|<img src=\\\"/site_images/s.gif\\\" width=\\\"5\\\" height=\\\"1\\\" alt=\\\"\\\" />\";\n\t}\n\n\tif ( (currentIndex < 0) || (currentIndex > (subsection[currentSection].length - 2)) ) {\t\n\t\tsHTML += nextText + \"<img src=\\\"/site_images/s.gif\\\" width=\\\"4\\\" height=\\\"1\\\" alt=\\\"\\\" /><span class=\\\"prevNextArrow\\\">&gt;</span><img src=\\\"/site_images/s.gif\\\" width=\\\"3\\\" height=\\\"1\\\" alt=\\\"\\\" />\";\n\t} else {\n\t\tsHTML += \"<a href=\\\"\" + subsection[currentSection][currentIndex+1] + \"\\\" class=\\\"prevNextLink\\\">\" + nextText + \"</a><img src=\\\"/site_images/s.gif\\\" width=\\\"4\\\" height=\\\"1\\\" alt=\\\"\\\" /><span class=\\\"prevNextArrow\\\">&gt;</span><img src=\\\"/site_images/s.gif\\\" width=\\\"3\\\" height=\\\"1\\\" alt=\\\"\\\" />\";\n\t}\t\n\tsHTML += \"</td>\";\n\tsHTML += \"</tr>\";\n\tsHTML += \"</table>\";\n\n\t//alert(sHTML);\n\tdocument.write(sHTML);\n}", "function showSubresults(results){\n\t_checkedTerms = [];\n\tif(results.length==0){\n\t\t$(displayText).text(\"No Results\");\n\t\t$(\"#loader\").hide();\n\t\treturn;\n\t}\n\tif (_withSubterms){\n\t\t$(\"#show-subterms\").show();\n\t}\n\tSEARCH_TYPE = \"path-subresults\";\n\tmakeTables(results,tableLimit,0);\n\n\t$(loader).hide();\n\t$(\"#results\").show();\n\t$(\"#path-subresults\").show();\n\t$(\"#downloadform\").hide();\n\t$(\"#selections\").text(\"Choose the Intermediary Terms you want to search with\");\n\tsetFinishSearchHandler();\t\n}", "setup() {\n\t\t\tvar that = this;\n\t\t\tthis._forEach(this._activeTabs, function(index, tab) {\n\t\t\t\tthat._forEach(tab.children, function(index, child) {\n\t\t\t\t\tvar target = that.getTarget(child);\n\t\t\t\t\tthat.showPanel(child, target);\n\t\t\t\t});\n\t\t\t});\n\t\t}", "function addUnitToTable(unit) {\n\n rows.push({\n title : \"<a href='#view=unit&amp;id=\" + unit.id + \"'>\" + unit.name + \"</a>\",\n exportTitle : safe_export_replace(unit.name),\n css : 'unit main',\n unit : unit,\n type : UNIT\n });\n\n rows.push({\n title : t(\"Activities Average\"),\n exportTitle : t(\"Activities Average\"),\n css : 'unit average',\n unit : unit,\n type : UNIT_AVERAGE\n });\n\n rows.push({\n title : t(\"Activities Coverage\"),\n exportTitle : t(\"Activities Coverage\"),\n css : 'unit coverage',\n unit : unit,\n type : UNIT_COVERAGE\n });\n\n // Actividades de la unidad\n var activities = unit.activities;\n for ( var i in activities) {\n\n var activity = activities[i];\n\n rows.push({\n title : \"<a class='partial' href='#view=activity&amp;id=\" + activity.id + \"'>\" + activity.name\n + \"</a>\",\n exportTitle : safe_export_replace(activity.name) + \" (\" + safe_export_replace(activity.code) + \")\",\n activity : activity,\n css : \"activity \" + getActivityType(activity.code),\n type : ACTIVITY\n });\n }\n\n }", "function displaySubs(videoId, srtContents) {\n\t// Remove if existing\n\tlet existingElement = document.getElementById('netflix-srt-subs-container');\n\tif(existingElement !== null) {\n\t\texistingElement.outerHTML = '';\n\t}\n\n\tlet html = htmlToElement(`<div id=\"netflix-srt-subs-container\"></div>`);\n\tdocument.body.appendChild(html);\n\tlet subContainerElement = document.getElementById('netflix-srt-subs-container');\n\tlet offsetElement = document.getElementById('netflix-srt-subs-offset');\n\n\tlet subs = getSubtitleRecords(srtContents);\n\tsubs.sort((r1, r2) => r1['to'] - r2['to']); // Sort by from times (so we can efficiently handle overlaps)\n\n\t// Loop indefinitely for subs (indefinitely so that we still display correct subs even when we\n\t// seek in the video).\n\tintervalId = setInterval(() => {\n\t\tlet time = getTimeInVideo(videoId);\n\t\ttime += parseFloat(offsetElement.value);\n\n\t\t// Unfortunately, this can legit happen by simply loading the subs before the video has\n\t\t// loaded. There is no good way to detect if the video has failed to be detected.\n\t\tif(time === null) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Dumb approach: just loop through all the records\n\t\tlet currentSub = getSubtitlesForTime(subs, time);\n\n\t\t// Get the controls for nicer positioning\n\t\tlet controlsHeight = 0;\n\t\tlet controlsElements = document.getElementsByClassName('PlayerControlsNeo__bottom-controls');\n\t\tlet areControlsVisible = controlsElements.length === 1 &&\n\t\t\t\t!controlsElements[0].className.includes('PlayerControlsNeo__bottom-controls--faded');\n\t\tif(controlsElements.length === 0) {\n\t\t\tconsole.log('Could not find controls. Maybe Netflix broke this feature?');\n\t\t}\n\t\telse {\n\t\t\tcontrolsHeight = controlsElements[0].offsetHeight;\n\t\t}\n\n\t\tlet videoRealWidth = getVideoRealPixelWidth(videoId);\n\t\tsubContainerElement.style.width = `${videoRealWidth}px`;\n\n\t\tsubContainerElement.innerHTML = currentSub;\n\t\tif(currentSub === '') {\n\t\t\tsubContainerElement.style.display = 'none';\n\t\t}\n\t\telse {\n\t\t\tsubContainerElement.style.display = 'block';\n\n\t\t\tlet offsetFromTop = window.innerHeight;\n\t\t\tif(areControlsVisible) {\n\t\t\t\toffsetFromTop -= controlsHeight;\n\t\t\t}\n\t\t\toffsetFromTop -= offsetFromTop * SUBS_BOTTOM_PADDING_PERCENT;\n\t\t\tsubContainerElement.style.top = `${offsetFromTop}px`;\n\t\t}\n\n\t}, UPDATE_TIME)\n}", "function unitListVisible() {\n setVisible(!visible);\n }", "function initializePage() {\n\tDescartesScenes = new Array();\n\n\tvar navigationPanel = $(\"#\" + NavigationPanelName);\n\n\tfor(var unitIndex in DescartesUnits) {\n\t\tvar currentUnit = DescartesUnits[unitIndex];\n\t\tvar currentUnitIndexFile = currentUnit.Files[0];\n\t\tvar unitLink = createButton (DescartesScenes.length, unitIndex, currentUnit.Name);\n\n\t\tfor(var sceneIndex in currentUnit.Files) {\n\t\t\tDescartesScenes[DescartesScenes.length] = currentUnit.Files[sceneIndex];\n\t\t}\n\t\tnavigationPanel.append(unitLink);\n\t}\n\n\tContentFrameWidth = ContentFrameWidth == -1 ? \"100%\" : ContentFrameWidth;\n\t$(\"#\" + ContentFrameName).attr(\"width\", ContentFrameWidth);\n\n\tsetScene(0);\n}", "function getDetailUnits() {\n setLoading(true);\n setDetailUnits(detailBoxesFromCategory);\n setLoading(false);\n }", "link() {\n\t\t// Call super link to link members of Top Level (Identified)\n\t\tsuper.link();\n\t\t\n this._built = this._sbolDocument.lookupURI(this._built);\t\t\n }", "function showSubMenu(link){ \n let img=link.children[1];\n const subUL=link.children[2];\n \n if(subUL.classList.contains('hide-sub-ul')){\n showSubUL(img, subUL);\n } else {\n hideSubUL(img, subUL);\n }\n}", "display(){\n this.htmlBuilder.build();\n this.displayCityName();\n this.displayTodayWeather();\n this.displayWeekWeather();\n this.displayTimeSlots();\n }", "function openSub(evt, cityName, j) {\n\n // Declare all variables\n var i, tabcontent, tablinks;\n\n // Get all elements with class=\"tabcontent\" and hide them\n tabcontent = document.getElementsByClassName(\"subcontent\" + j);\n for (i = 0; i < tabcontent.length; i++) {\n tabcontent[i].style.display = \"none\";\n }\n\n // Get all elements with class=\"tablinks\" and remove the class \"active\"\n tablinks = document.getElementsByClassName(\"sublinks\" + j);\n for (i = 0; i < tablinks.length; i++) {\n tablinks[i].className = tablinks[i].className.replace(\" active\", \"\");\n }\n\n // Show the current tab, and add an \"active\" class to the link that opened the tab\n document.getElementById(cityName).style.display = \"block\";\n evt.currentTarget.className += \" active\";\n}", "list() {\n console.log(\"Our special menu for children:\");\n for (var index = 0; index < this.items.length; index++) {\n var element = this.items[index];\n console.log(element);\n }\n }", "function displayCategory() {\n displayHeading();\n displayList();\n}", "show_symptoms_in_sublocation(subloc_id, status, div_id) {\n var data = {\"language\": this.lang, \"format\": \"json\"};\n\n axios.get(this.url + \"symptoms/\" + subloc_id.toString() + \"/\" + status,\n {headers: this.headers, params: data})\n .then(response => {\n display_data(response.data, div_id);\n });\n }", "function displaySubs(the_sub){\r\n\t if (document.getElementById(the_sub).style.display==\"\"){\r\n\t document.getElementById(the_sub).style.display = \"none\";return\r\n }\r\n for (i=0;i<subs_array.length;i++){\r\n\t var my_sub = document.getElementById(subs_array[i]);\r\n\t my_sub.style.display = \"none\";\r\n\t }\r\n document.getElementById(the_sub).style.display = \"\";\r\n}", "function displayGenre() {\n let htmlContent = ''\n htmlContent += `<div class=\"list-group\" id=\"list-tab\" role=\"tablist\">`\n Object.keys(genre).forEach(index => {\n htmlContent += `\n <a class=\"list-group-item list-group-item-action\" id=\"list-genre-list\" data-toggle=\"list\"\n href=\"#list-genre\" role=\"tab\" aria-controls=\"genre\" data-index=\"${index}\">${genre[index]}</a>\n `\n })\n htmlContent += `</div>`\n genrePanel.innerHTML = htmlContent\n }", "mostrarTarefas() {\n printPlanejamentoAtual(this.getPlanejamentoAtual());\n printListaTarefa(this.listaQuadros());\n }", "function initialDisplay() {\n \tcountLinks();\n \tgetDropDowns();\n \tgetList(\"id\");\n }", "function frmPatientSummary_showSegUnits() {\n searchPatient_closeSearchList();\n kony.print(\"------frmPatientSummary_showSegUnits---->>\");\n if(frmPatientSummary.fcunitslist.isVisible) {\n frmPatientSummary.fcunitslist.setVisibility(false);\n } else {\n frmPatientSummary.fcunitslist.setVisibility(true);\n }\n frmPatientSummary.fcwoundslist.setVisibility(false);\n frmPatientSummary.forceLayout();\n}", "async function subDisplay(subs) {\n\tvar remSubs = (subs.slice(5))\n\tvar remSubLength = remSubs.length;\n\tvar listOfSubs = [];\n\tvar maxTries = 30;\n\tvar tryCount = 0; \n\n\n\tfor (var j=0; j < 5; j++){\n\t\tvar sub = subs[j];\n\t\tif(sub !== undefined) { addHTML(sub,$topRes);}\t\n\t}\n\n\t// Creates array of 5 unique array accesses\n\n\twhile(listOfSubs.length < 5){\n\n\t\ttryCount++;\n\t if (tryCount > maxTries) break;\n\t var randomnumber = Math.floor(Math.random()*remSubLength);\n\t if(listOfSubs.indexOf(randomnumber) > -1) continue;\n\n\t listOfSubs[listOfSubs.length] = randomnumber;\n\t \n\t}\n\n\tfor (var i=0; i < 5; i++){\n\n\t\tvar sub = remSubs[listOfSubs[i]];\n\t\tif(sub !== undefined) { addHTML(sub,$othRes); }\n \t\n\t}\n\tsaveValues(subs);\n}", "function list() {\n let string = '';\n for (let i = 0; i < currentNode.children.length; i++) {\n let child = currentNode.children[i];\n if (child.type === 'folder') {\n string = string + '<a class=\"blue\" onclick=\"changeDirectoryWalkthrough(absolutePathTo(nodeNamed(\\'' + child.name + '\\')))\">';\n string = string + child.name;\n string = string + '</a>';\n } else {\n string = string + '<a class=\"green\" onclick=\"concatenateWalkthrough(absolutePathTo(nodeNamed(\\'' + child.name + '\\')))\">';\n string = string + child.name;\n string = string + '</a>';\n }\n string = string + separator;\n }\n printLine(string);\n}", "hideAll() {\n this.up(this.$element.find('[data-submenu]'));\n }", "function createSublinks() {\n //removing all previous elements.\n var myNode = document.getElementById(\"page-sublinks\");\n while (myNode.firstChild) {\n myNode.removeChild(myNode.firstChild);\n }\n\n //adding sublinks\n var subpages = $('#subpages').text().split(',');\n for (let i = 0; i < subpages.length; i++) {\n $('#page-sublinks').append('<p class=\"navbar-element navbar-button\" onclick=\"transitionSubpage(\\'' + subpages[i] + '\\')\">' + subpages[i] + '</p>');\n }\n $('#subpages').remove();\n}", "function displayDocuManager() {\n\n\t// clear\n\t$(\".controlContentBlock[id=compare-manage] > ol\").empty();\n\n\t// show each corpus\n\tfor (let corpusName in _dataset) {\n\t\tif (typeof _dataset[corpusName] !== 'object') continue;\n\t\tlet manageItem = \"<li name=\\\"\" + corpusName + \"\\\">\" + corpusName + \"</li>\";\n\t\tlet className = (_dataset[corpusName].isShow) ?\"glyphicon-eye-open\" :\"glyphicon-eye-close\";\n\t\tlet hideBtn = \"<span class=\\\"glyphicon \" + className + \"\\\" name=\\\"\" + corpusName + \"\\\" onclick=\\\"hideOrShowCorpus(this, '\"+corpusName+\"')\\\"></span>\";\n\t\tlet deleteBtn = \"<span class=\\\"glyphicon glyphicon-trash\\\" name=\\\"\" + corpusName + \"\\\" onclick=\\\"deleteCorpus('\" + corpusName + \"')\\\"></span>\";\n\t\t$(\".controlContentBlock[id=compare-manage] > ol\").append(manageItem + hideBtn + deleteBtn);\n\t}\n}", "function goToUnitPage() {\n history.push(\"/selectunit\");\n }", "function ini_breadcrumb_getLink(root, subHref, title, typ) {\r\n\tswitch (typ) {\r\n\t\tcase \"head\": {\r\n\t\t\treturn \"<li><a href='\" + root + subHref + \"'>\" + title + \"</a></li>\";\r\n\t\t} break;\r\n\t\tcase \"mid\": {\r\n\t\t\treturn \"<li>&nbsp;>>&nbsp;&nbsp; <a href='\" + root + subHref + \"'>\" + title + \"</a></li>\";\r\n\t\t} break;\r\n\t\tcase \"tail\": {\r\n\t\t\treturn \"<li>&nbsp;>>&nbsp;&nbsp; <span>\" + title + \"</span></li>\";\r\n\t\t} break;\r\n\t}\r\n}", "function expandPlaceLink(vers_platz_link)\r\n{\r\n\tvar submenu = document.createElement(\"ul\");\r\n\tvar truppen = createLinkNode(\"game.php?\"+getUrlParam(\"village\")+\"&screen=place&mode=units\",\"\",\"Truppen\",\"\");\r\n\tvar sim = createLinkNode(\"game.php?\"+getUrlParam(\"village\")+\"&screen=place&mode=sim\",\"\",\"Simulator\",\"\");\r\n\tsubmenu.appendChild(truppen);\r\n\tsubmenu.appendChild(sim);\r\n\tvers_platz_link.appendChild(submenu);\r\n\treturn vers_platz_link;\r\n}", "function toggleSubNav (listObjID, linkObj) {\n var listObj = document.getElementById(listObjID);\n // If sub nav items are hidden, show them\n if (listObj.style.display === \"none\") {\n listObj.style.display = \"block\";\n linkObj.querySelector(\".expandPlusSign\").style.display = \"none\";\n linkObj.querySelector(\".collapseMinusSign\").style.display = \"inline-block\";\n linkObj.querySelector(\".grayArrowLine\").style.display = \"block\";\n linkObj.setAttribute(\"aria-expanded\", true);\n }\n // If sub nav items are shown, hide them\n else {\n listObj.style.display = \"none\";\n linkObj.querySelector(\".expandPlusSign\").style.display = \"inline-block\";\n linkObj.querySelector(\".collapseMinusSign\").style.display = \"none\";\n linkObj.querySelector(\".grayArrowLine\").style.display = \"none\";\n linkObj.setAttribute(\"aria-expanded\", false);\n }\n}", "get subGroupDisplay() {\n\t\treturn this.__subGroupDisplay;\n\t}", "display(grandParentElement, \n parentElementType, elementType, \n parentElementPrefix='Branch', // mainBranch, subBranch1, subBranch2...\n elementPrefix='leaf' ) { // <parentName>leafindex\n \n // main branch, then subbranches - componentize once working\n let mainUI = document.getElementById(`main${parentElementPrefix}`) ;\n if (!mainUI) {\n console.log(parentElementType);\n mainUI = document.createElement(parentElementType);\n mainUI.setAttribute('id',`main${parentElementPrefix}`)\n\n grandParentElement.appendChild(mainUI);\n }\n this.mainQueue.displayContinuous(mainUI,elementType,`main${parentElementPrefix}leaf`, \"Main Queue:\", 'mq');\n for (let m = 0 ; m < this.subQueues.length; m++){\n \n let branchUI = document.getElementById(`sub${parentElementPrefix}${m}`) ;\n if (!branchUI) {\n console.log(parentElementType);\n branchUI = document.createElement(parentElementType);\n branchUI.setAttribute('id',`sub${parentElementPrefix}${m}`);\n \n grandParentElement.appendChild(branchUI);\n }\n this.subQueues[m].displayContinuous(branchUI,elementType,`sub${parentElementPrefix}${m}leaf`, \"Sub Queue:\",`sq${m}`);\n \n }\n if (this.bulk && this.bulk.length > 0) {\n const intervalSpecs = { // seek a more appropriate name\n fillDummyRow: true,\n dummyRowElement:' - ',\n dummyRowTitle: 'Bulk Queue:',\n interval: this.subQueueLength,\n\n }\n let bulkUI = document.getElementById('bulkList') ;\n if (!bulkUI) {\n console.log(parentElementType);\n bulkUI = document.createElement(parentElementType);\n bulkUI.setAttribute('id','bulkList');\n \n grandParentElement.appendChild(bulkUI);\n }\n this.bulk.displayInterval(grandParentElement, parentElementType, bulkUI,elementType, intervalSpecs, ' ', \"Bulk =>\");\n }\n /*\n displayContinuous(parent, childType, idPrefix='leaf' ) {\n let childId = 0 ;\n\n let traversal = this.head ;\n let currentTail = this.length ;\n while(traversal !== null) {\n let leaf = document.getElementById(`${idPrefix}${childId}`)\n if (!leaf) {\n leaf = document.createElement(childType);\n leaf.setAttribute(\"id\",`${idPrefix}${childId}`);\n leaf.value = '___'\n parent.appendChild(leaf);\n }\n // alert(traversal.num);\n // leaf.innerHTML = '_'\n //let newContent = document.createTextNode(traversal.num.toString());\n leaf.innerHTML = traversal.num.toString() ; // appendChild(newContent);\n // leaf.value = traversal.num.toString();\n traversal = traversal.next;\n childId++;\n } \n while (currentTail < this.maxLength) {\n let leafBlank = document.getElementById(`${idPrefix}${childId}`)\n if (!leafBlank) {\n leafBlank = document.createElement(childType);\n leafBlank.setAttribute(\"id\",`${idPrefix}${childId}`);\n parent.appendChild(leafBlank);\n }\n leafBlank.innerHTML = '-' ;\n currentTail++;\n childId++ ;\n }\n }\n */\n }", "function UpdateLinks(Cont) {\n var ObjContainer = (Cont != undefined) ? Cont : MainMenu;\n // Do some init here.\n $(ObjContainer).children(\"ul\").find(\"li\").click(function (event) {\n var elem = $(this).children('a');\n if ($(MainContainer).find(\".menu\").filter(\":visible\").length > 1) {\n //console.log($(\".menu\").filter(\":visible\").length);\n return;\n }\n // Check if it has a child so we know if we execute the link or the child.\n event.preventDefault();\n event.stopPropagation();\n\n if (elem.data().smoothscroll) {\n if (!elem.data('onepage-section') && window.smoothScrollGetAnchors) {\n window.smoothScrollGetAnchors();\n }\n Visible = false;\n Self.Show(Visible);\n elem.trigger('click.onepage');\n return;\n }\n\n if (elem.parent().has(\"ul\").length) {\n Self.GoToSubmenu(\"\", elem);\n event.preventDefault();\n event.stopPropagation();\n } else {\n if (elem.length > 0 && elem.attr('href')) {\n window.location = elem.attr('href');\n }\n $(MenuButton).children(\"span.caption\").children(\"p.xtd_menu_ellipsis\").html(elem.children(\"p\").html());\n if (Visible) {\n Self.Show(Visible = !Visible);\n }\n }\n }\n ).on('touchstart', function () {\n $(this).addClass('clicked');\n }).on('touchend', function () {\n $(this).removeClass('clicked');\n }).on('touchmove', function () {\n $(this).removeClass('clicked');\n });\n }", "function loadSubnetDropdowns() {\n var dropdownContainer = $(\"#subnet-dropdowns\");\n var innerHTMLString = \"\";\n subnets.forEach(function(subnet, index) {\n innerHTMLString += '<li><a href=\"#\">' + subnet.name + '</a></li>';\n });\n dropdownContainer.html(innerHTMLString);\n\n $(\".dropdown-menu li a\").click(function() {\n var subnetName = $(this).text();\n $(this).parents(\".dropdown\").find(\".btn\").html(subnetName +\n '<span class=\"caret\"></span>');\n loadSubnetMembers(subnetName);\n });\n }", "viewNestedArea (baseUrl,username,spacename,area,child,query){\n browser.get(baseUrl + username + \"/\" + spacename +\"/areas/\" + area + \"/\" + child + \"/q=\" +query);\n }", "path() {\n this.displayFolderStructure();\n }", "load() {\n // set name\n loadUnitInfo(this.state.id)\n .then(({name}) => name)\n .then((name) => {\n this.setState({\n name: name,\n });\n });\n\n // get list\n const response = searchBy(\"parent.id\", this.state.id);\n response.then((unit) => {\n var result = unit.map(function (a) {\n return {\n name: a.displayName,\n id: a.id\n }\n });\n if (result.length > 0) {\n this.setState({\n unitInfo: result,\n });\n\n }\n\n })\n }", "function getAdministrativeUnits(){\n $scope.load = true;\n\n var params = {\n schoolSuperior: $scope.SystemRecipient.AdministrativeUnitSuperior[0],\n groupSid: $scope.VisionSystem.Id\n };\n\n HttpServices.getListUnitAdministrative(params,\n function(data){\n $scope.AdministrativeUnits = data;\n if($scope.AdministrativeUnits && $scope.AdministrativeUnits.length > 0) {\n $scope.showFilter.showDRE = false;\n $scope.showFilter.showShool = true;\n }else if($scope.AdministrativeUnits && $scope.AdministrativeUnits.listGroups == 0){\n toastr.warning(\"Não existe nenhuma lista de unidades administrativas cadastrada!\");\n }\n $scope.load = false;\n });\n }", "function displayReferent(unit) {\n if (unit.referent == null) {\n return;\n }\n unitSentDiv = document.getElementById('sentDiv'+unit.id);\n \n refImg = document.createElement('img');\n refImg.setAttribute('class', 'ref' + unit.id);\n refImg.setAttribute('src', 'gif/ref_arrow.gif');\n refImg.setAttribute('style', 'vertical-align: middle; height: 1em; width: 2em; margin-left: 2em; display: inline;');\n refImg.setAttribute('title', 'press to remove reference');\n refImg.setAttribute('onclick', 'removeReference('+unit.id+'); toggleAddReferent(null);');\n \n refDiv = document.createElement('span');\n refDiv.setAttribute('class', 'refUnit '+active_display_class+' ref'+unit.id);\n refDiv.setAttribute('id', 'refDiv'+unit.id);\n refDiv.setAttribute('title', 'CONTEXT: '+ unit.referent.parent.toString());\n\n refDiv.innerHTML = unit.referent.toString();\n \n unitSentDiv.appendChild(refImg);\n unitSentDiv.appendChild(refDiv);\n\n $('#refDiv'+unit.id).click(function() {\n edit(unit.referent);\n jump(unit.referent.id);\n });\n\n}", "function setup_metacpan_links() {\n $('a[href^=\"/dist/overview/\"]').each(\n function() {\n var module = this.href.match('/dist/overview/(.*)$')[1].replace('-', '::', 'g');\n console.log(\"module = \" + module);\n $(this).after('&nbsp;' + '<a href=\"http://metacpan.org/module/' + module + '\">' + metacpan_img + '</a>');\n });\n}", "function display_tests_list(){\n\tcall_webservice(9,\"&p=\"+currentProject);\n\tvar html=\"<table>\", oldType=\"\", type, nb=0;\n\t$(\"#tests_list\").html(\"\");\n\tif ( currentProjectType == 'JS' ){\n\t\t$(\"#tests #script_ctn\").html(\"\");\n\t\t$(\"#tests #script_ctn\").append(\"<script src='projets/\"+currentProjectFolder+\"/code/\"+currentProjectFolder+\".js'></script>\");\n\t\t$(\"#tests #script_ctn\").append(\"<script src='projets/\"+currentProjectFolder+\"/tests/tests.js'></script>\");\n\t}\n\t$(\"#tests .block_title span\").html(\"Tests (\"+dataRetourJSON.list.length+\")\");\n\tfor (i=0;i<dataRetourJSON.list.length;i++){\n\t\ttype = dataRetourJSON.list[i].type;\n\t\t\n\t\t// Nouvelle categorie\n\t\tif ( type != oldType ){\n\t\t\t\n\t\t\t// remplir la liste de test de la categorie precedente\n\t\t\tif ( oldType != \"\" ){\n\t\t\t\t$(\"#tests_\"+oldType+\"s\").html(html+\"</table>\");\n\t\t\t\t$(\"#section_\"+oldType+\" span\").html(oldType+\"s (\"+nb+\")\");\n\t\t\t\tnb = 0;\n\t\t\t}\n\t\t\thtml = \"<table cellspacing=0>\";\n\t\t\t\n\t\t\t// Ajouter la nouvelle categorie\n\t\t\t$(\"#tests_list\").append(\"<div class='section_title' id='section_\"+type+\"'> <span>\"+type+\"s (\"+nb+\")</span> &nbsp; <img width=18 height=18 src='img/run_test.png' onclick='run_tests(\\\"\"+type+\"\\\")' title='Lancer tous les tests \"+type+\"s'/></div>\");\n\t\t\t$(\"#tests_list\").append(\"<div id='tests_\"+type+\"s'></div>\");\n\t\t\toldType = type;\n\t\t}\n\t\thtml += \"<tr id='test_\"+dataRetourJSON.list[i].id+\"'><td class='test_name' title='\"+dataRetourJSON.list[i].desc+\"'>\"+dataRetourJSON.list[i].name+\"</td>\";\n\t\thtml += \"<td class='test_status'><img src='img/test\"+dataRetourJSON.list[i].status+\".png' title='\"+dataRetourJSON.list[i].debug+\"'/></td>\";\n\t\thtml += \"<td class='test_date'>\"+convert_datetime_to_fr(dataRetourJSON.list[i].last_run)+\"</td>\";\n\t\thtml += \"<td class='test_run'><img width=16 height=16 src='img/run_test.png' onclick='run_test(\\\"\"+dataRetourJSON.list[i].id+\"\\\",\\\"\"+type+\"\\\",\\\"\"+dataRetourJSON.list[i].name+\"\\\")' title='Lancer ce test'/></td></tr>\";\n\t\tnb++;\n\t}\n\t// remplir la liste de test de la categorie precedente\n\t$(\"#tests_\"+oldType+\"s\").html(html+\"</table>\");\n\t$(\"#section_\"+oldType+\" span\").html(oldType+\"s (\"+nb+\")\");\n}", "function showSubMenu( event ) {\n\n\t\t\t\t// If this has no sub item, there's nothing to do\n\t\t\t\tif( $sub === undefined ) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\n\t\t\t\t// If we have toggle buttons, we can let the click pass through\n\t\t\t\tif( $toggle !== undefined && $toggle.length !== 0 && isVisible( $toggle ) && event.type !== 'focus' ) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\n\t\t\t\t// If this sub menu is already visible, there's nothing to do\n\t\t\t\tif( isVisible( $sub ) ) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\t\t\t\t// If we made it here, we can capture the click and open the sub menu instead\n\t\t\t\tif( event.type !== 'focus' ) {\n\t\t\t\t\t$link.focus();\n\t\t\t\t}\n\t\t\t\tevent.preventDefault();\n\t\t\t\t$sub.addClass( 'focused' ).attr( 'aria-hidden', 'false' );\n\t\t\t\treturn false;\n\t\t\t}", "function showSubModules(moduleName, configData, appSettings) {\n var subModuleNames = getSubModuleNames(moduleName, configData, appSettings);\n\n var valueHtml = '';\n\n $.each(subModuleNames, function (key, value) {\n valueHtml += '<div class=\"collapsibleContainer\" name=\" ' + value + '\" >' + showActions(moduleName, value, configData, appSettings) + '</div>';\n });\n\n return valueHtml;\n }", "display(){\n cl(`${this.name} belongs to the 'ChildClass'`);\n }", "function toggleSublist(sub) {\n const sublist = document.getElementById('sublist');\n\n sublist.setAttribute('value', sub);\n displaySub(sublist);\n}", "function DeviceListView(){\n\tclearNav();\n\t\n\tclearSection();\n\tvar local_simulation = get_local_simulation();\n\tvar devices = getAllDeviceObjects(local_simulation);\n\tvar html = DevicesListTemplate(devices);\n\n\tgetContainer().innerHTML = html;\n\tremoveClass('active');\n\tdocument.getElementById('my-devices-link').className='active';\n}", "function ver_submenu(n) {\r\n document.getElementById(\"subseccion\"+n).style.display=\"block\"\r\n}", "function getSubChapterMenu(){\n\t\n}", "display() {\n this.supplies.forEach(supply => supply.display());\n }", "function ini_breadcrumb_genLink(root, name2href, name2title,\r\n\t\t\t\t\t\t\t\tind, ub, name) {\r\n\tvar typ = (ind == ub) ? \"tail\" : \"mid\";\r\n\treturn ini_breadcrumb_getLink(root, name2href[name], name2title[name], typ);\r\n}", "function hideSubs() {\n\t\tfor (var i = displayedSubmenuSelector.length - 1; i >= 0; i--) {\n\t\t\tdisplayedSubmenuSelector[i].setAttribute('style', 'display:none');\n\t\t}\n\n\t\t// clearing our temporary array\n\t\tdisplayedSubmenuSelector = [];\n\t\tconsole.log('hide subs!');\n\t}", "function gotAllUnits(err) {\n console.log(\"gotAllUnits()\");\n\n // report an error, you'd want to do something better than this in production\n if (err) {\n console.log(\"error loading units\");\n console.error(err);\n return;\n }\n\n // call functions to log and show the units\n consoleLogUnits();\n showUnits();\n}", "function setupSubViz(commits, authors, timeExtent, lineStats) {\n subNav = new SubNav([\n new SubNavItem('timeline',\n 'Timeline',\n 'All commits by top authors',\n () => timeline.renderTimeline(commits, authors, timeExtent, lineStats),\n () => timeline.transitionFromTimeline()),\n new SubNavItem('rhythm-hour',\n 'Hourly',\n 'What time of day do authors commit their work?',\n () => rhythms.renderRhythms(commits, authors, timeExtent, lineStats, setup.hourOfDayType),\n () => rhythms.transitionFromRhythm()),\n new SubNavItem('rhythm-week',\n 'Weekly',\n 'What day of the week do authors commit their work?',\n () => rhythms.renderRhythms(commits, authors, timeExtent, lineStats, setup.dayOfWeekType),\n () => rhythms.transitionFromRhythm())\n ])\n addSubNav(subNav)\n}", "function display() {\n\treturn {\n\t\tdisplayStores: function() {\n\t\t\tfor (var i = 0; i < stores.length; i++) {\n\t\t\t\t$('<a class=\"storeLink\"></a>').appendTo('#mainDiv').append($('<img>').attr('src', stores[i].src))\n\t\t\t}\n\n\t\t\t$('.storeLink').click(function() {\n\t\t\t\tnewPage();\n\t\t\t\t\tfor (var i = 0; i < products.length; i++) {\n\t\t\t\t\t\t$('#mainDiv').append($('<a id=\"productLink\"></a>')\n\t\t\t\t\t\t.append($('<img>').attr('src', products[i].src))).append(products[i].name + '\\n' + products[i].price + '\\n' + products[i].size, $('<input type=\"checkbox\">').attr('id',i))\n\t\t\t\t\t}\n\n\t\t\t\t$('#mainDiv').append(\n\t\t\t\t buttons()\n\t\t\t\t)\n\t\t\t});\n\t\t},\n\n\t\tdisplayMen: function() {\n\t\t\tnewPage();\n\t\t\tfor (var i = 0; i < products.length; i++) {\n\t\t\t\tif (products[i].cat === 'men') {\n\t\t\t\t\tconsole.log(i)\n\t\t\t\t\t$('#mainDiv').append($('<a id=\"productLink\"></a>')\n\t\t\t\t\t.append($('<img>').attr('src', products[i].src))).append(products[i].name + '\\n' + products[i].price + '\\n' +products[i].size)\n\t\t\t\t\t.append($('<input type=\"checkbox\">').attr('id', i))\n\t\t\t\t\t.append(buttons());\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\n\t\tdisplayWomen: function() {\n\t\t\tnewPage();\n\t\t\tfor (var i = 0; i < products.length; i++) {\n\t\t\t\tif (products[i].cat === 'women') {\n\t\t\t\t\t$('#mainDiv').append($('<a id=\"productLink\"></a>')\n\t\t\t\t\t.append($('<img>').attr('src', products[i].src))).append(products[i].name + '\\n' + products[i].price + '\\n' +products[i].size)\n\t\t\t\t\t.append($('<input type=\"checkbox\">').attr('id', i))\n\t\t\t\t\t.append(buttons());\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\n\t\tdisplayKids: function() {\n\t\t\tnewPage();\n\t\t\tfor (var i = 0; i < products.length; i++) {\n\t\t\t\tif (products[i].cat === 'kids') {\n\t\t\t\t\t$('#mainDiv').append($('<a id=\"productLink\"></a>')\n\t\t\t\t\t.append($('<img>').attr('src', products[i].src))).append(products[i].name + '\\n' + products[i].price + '\\n' +products[i].size)\n\t\t\t\t\t.append($('<input type=\"checkbox\">').attr('id', i))\n\t\t\t\t\t.append(buttons());\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}", "function renderSubCat(subCatItem) {\n const { container, subcategory, data, category, isHoverStyle, hasImages } = subCatItem;\n if ( category == null) return;\n const subheading = {\n \"Concerts\": `${data.subcategories.heading} ${subcategory}`,\n \"Sports\": `${subcategory} ${data.subcategories.heading}`,\n \"Arts & Theater\": data.subcategories.heading,\n \"Family\": data.subcategories.heading,\n \"More\": data.subcategories.heading,\n };\n \n container.innerHTML =\n `\n <p>${subheading[category]}</p>\n <ul class=\"sub-cat-menu ${hasImages ? 'sub-cat-images' : ''}\">\n ${ isHoverStyle ? generateListItems(data.subcategories.list[subcategory], category, subcategory) : generateListItems(data.subcategories.list, category) }\n </ul>\n `;\n }", "show_body_sublocations(body_location, div_id) {\n var data = {\"language\": this.lang, \"format\": \"json\", \"locationid\": body_location.toString()};\n\n axios.get(this.url + \"body/locations/\" + body_location.toString(), \n {headers: this.headers, params: data})\n .then(response => {\n display_data(response.data, div_id);\n });\n }", "function initiateSubCategories(subtopic) \n{\n\tdocument.getElementById('backBtn').removeAttribute(\"disabled\");\n\tdocument.getElementById('categoryTitle').innerHTML = subtopic;\n\tvar div = document.getElementById('categoryContainer');\n\tstrPath += \"/\" + subtopic; // Updated location string with subtopic\n\n\tclearButtons(div);\n\tsetCategories(strPath);\n}", "subscriptions () {\r\n events.on(\"url-change\", (data) => {\r\n if (data.state && data.state.selector) {\r\n const target = document.querySelector(data.state.selector);\r\n\r\n this.toggleActivePages(target);\r\n this.toggleActiveSubnav(data.state.index);\r\n }\r\n });\r\n }", "function showVli(index) {\n crt_oli.className = 'olishow';\n //url_adr = ''; // empties this variable\n if(nrvli > 0) {\n url_adr = ''; // empties this variable\n for(var i=0; i<nrvli; i++) {\n vli[i].className = 'vli';\n }\n if(index >= 0) {\n vli[index].className = 'vlishow';\n \n // if contains a link, calls the function setUrlAdr() to add its \"href\" value in $url_adr\n if(vli[index].getElementsByTagName('a').length > 0) setUrlAdr(vli[index].getElementsByTagName('a')[0]);\n \n // see what's in submenu\n document.getElementById(\"block\").innerHTML = \"submenu \" + vli[index].getElementsByTagName('a')[0] + \" parent74: \" + ih + \" sub: \" + iv;\n document.getElementById(\"url\").innerHTML = 'url 83: ' + url_adr;\n }\n } \n}", "function updateSubMenu(mainId, initialSubId) {\n \n var subMenu = d3.select(\".subMenu\");\n subMenu.html(\"\");\n \n var s = 0;\n\n for (var subId in globalMetadata[mainId].charts) {\n \n subMenu.append(\"span\")\n .classed(\"subMenuItem\", true)\n .classed(initialSubId == subId ? \"subMenuItemActive subMenuItemHover\" : \"subMenuItemNormal\", true)\n .attr (\"id\" , \"chartPath_\" + mainId + \"_\" +subId)\n .text(globalMetadata[mainId].charts[subId].title)\n .on(\"mouseover\", function () { \n d3.select(\".subMenuItemHover\").classed(\"subMenuItemHover\", false);\n d3.select(this).classed(\"subMenuItemHover\", true);\n })\n .on(\"mouseout\", function () {\n d3.select(this).classed(\"subMenuItemHover\",false);\n d3.select(\".subMenuItemActive\").classed(\"subMenuItemHover\",true);\n })\n .on(\"click\", function () { \n changeChart( {\"chartPath\" : d3.select(this).attr(\"id\").replace(\"chartPath_\", \"\") }); \n });\n s++;\n }\n}", "function createInitializedSubmenus(self) {\n var submenus = self.element.find('oj-menu:not(.oj-menu-submenu)');\n\n for (var i = 0; i < submenus.length; i++) {\n // element might not be upgraded so just toggle its visibility and wait to be upgraded\n $(submenus[i]).attr('aria-hidden', 'true').hide();\n var busyContext = Context.getContext(submenus[i]).getBusyContext();\n busyContext.whenReady().then(function (submenu) {\n submenu.refresh();\n }.bind(self, submenus[i]));\n }\n }", "function variants() {\n\t\tvar oList = document.getElementById(\"variantsList\"),\n\t\t\tmQueryOptions = {\n\t\t\t\tteam : mParameters.team,\n\t\t\t\tframes : mParameters.frames || 4\n\t\t\t};\n\n\t\tObject.keys(mVariants).forEach(function (sTitle) {\n\t\t\tvar oAnchor = document.createElement(\"a\"),\n\t\t\t\toItem = document.createElement(\"li\"),\n\t\t\t\tmVariantQueryOptions = Object.assign({}, mQueryOptions, mVariants[sTitle]),\n\t\t\t\tsQuery = Object.keys(mVariantQueryOptions).map(function (sKey) {\n\t\t\t\t\t\treturn sKey + \"=\" + mVariantQueryOptions[sKey];\n\t\t\t\t\t}).join(\"&\");\n\n\t\t\toAnchor.setAttribute(\"href\",\n\t\t\t\t\"test-resources/sap/ui/core/qunit/internal/BeforePush.html?\" + sQuery);\n\t\t\toAnchor.appendChild(document.createTextNode(sTitle));\n\t\t\toItem.appendChild(oAnchor);\n\t\t\toList.appendChild(oItem);\n\t\t});\n\t\tdocument.getElementById(\"variants\").classList.remove(\"hidden\");\n\t}", "render() {\n\n return (\n <div className=\"settings-subnav\">\n <Tabs.Tabs className=\"grid-one\">\n <Tabs.Tab label=\"General\">\n <section className=\"grid-one\">\n <div className=\"grid-item\"><BasicCard/></div>\n <div className=\"grid-item\"><BasicCard/></div>\n <div className=\"grid-item\"><Toggle label=\"Toggle Stuff\" defaultToggled={true}/></div>\n </section>\n </Tabs.Tab>\n <Tabs.Tab label=\"Design\" >\n </Tabs.Tab>\n <Tabs.Tab label=\"Modules\" />\n <Tabs.Tab label=\"Notify\" />\n <Tabs.Tab label=\"Priveleges\" />\n </Tabs.Tabs>\n </div>\n // <DropDownMenu menuItems={menuItems} onChange={this.transitionToRoute} />\n );\n }", "function renderSubText(data) {\n if (data.length > 0) {\n section.innerHTML = \"\";\n let currentBreed = window.location.hash.substring(1);\n let ul = document.createElement(\"ul\");\n section.appendChild(ul);\n for (let key of data){\n let li = document.createElement(\"li\");\n li.textContent = big(key);\n ul.appendChild(li);\n li.addEventListener('click', function (e) {\n window.location.hash = currentBreed + \"/\" + small(e.target.textContent);\n getBreedImg();\n });\n }\n } else {\n section.innerHTML = \"\";\n }\n}", "function onBusinessUnitClick(){\n var curTreeNode = View.panels.get(\"abScDefStdZhicBzTree\").lastNodeClicked;\n var zhic_bz_id = curTreeNode.data['sc_zhic_bz.zhic_bz_id'];\n View.controllers.get('abScDefStdZhic').curTreeNode = curTreeNode;\n if (!zhic_bz_id) {\n View.panels.get(\"abScDefStdZhicBz\").show(false);\n View.panels.get(\"abScDefStdZhic\").show(false);\n }\n else {\n var restriction = new Ab.view.Restriction();\n restriction.addClause(\"sc_zhic_bz.zhic_bz_id\", zhic_bz_id, '=');\n View.panels.get('zhicDetailTabs').selectTab(\"biaoZhunZhiChengTab\", restriction, false, false, false);\n }\n}", "function showUnitTestDetails(num, html_url, sparql_url)\n{\n var rdfaExtractorUrl = getRdfaExtractorUrl();\n var n3ExtractorUrl = \"http://www.w3.org/2007/08/pyRdfa/extract?format=n3&uri=\";\n\n document.getElementById('unit-test-details-' + num).innerHTML =\n \"Retreiving information...\";\n sendRequest('test-details?id=' + num +\n '&xhtml=' + html_url +\n '&sparql=' + sparql_url +\n '&rdfa-extractor=' + escape(rdfaExtractorUrl) +\n '&n3-extractor=' + escape(n3ExtractorUrl),\n displayUnitTestDetailsResult, num)\n}", "function printLanguageList(language_items) {\n\tvar language_list_parent = document.getElementById(\"language-items\");\n\tvar language_list = \"\";\n\tfor (i = 0; i < language_items.length; i++) {\n\t\tlanguage_list = language_list + \"<a class=\\\"dropdown-item\\\" role=\\\"presentation\\\" href=\\\"\" + language_items[i].link + \"\\\">\";\n\t\tlanguage_list = language_list + \"<img src=\\\"\" + language_items[i].img + \"\\\" class=\\\"icon-flag mr-2 img-fluid\\\" alt=\\\"Language Item\\\"/>\"\n\t\tlanguage_list = language_list + language_items[i].country + \" - \" + language_items[i].language;\n\t\tlanguage_list = language_list + \"</a>\";\n\t}\n\t\n\tlanguage_list_parent.innerHTML = language_list;\n}", "function loadSubCategory() {\n $.ajax({\n url: 'all-sub-category',\n type: 'GET',\n success: function(data) {\n $('#category_table').html(data);\n }\n });\n }" ]
[ "0.7663342", "0.68255967", "0.68116045", "0.6465879", "0.6303267", "0.6192426", "0.61063194", "0.5817894", "0.55888015", "0.5503396", "0.54560477", "0.54035646", "0.5357568", "0.5330761", "0.5311307", "0.5309545", "0.5302293", "0.5295641", "0.528613", "0.5247997", "0.52389777", "0.52320105", "0.5222548", "0.52167785", "0.5209261", "0.5149554", "0.51089853", "0.506512", "0.49731746", "0.49142888", "0.49086824", "0.49053714", "0.48979706", "0.4889152", "0.48671877", "0.48484457", "0.48471522", "0.48442918", "0.4839286", "0.48245737", "0.480872", "0.48024806", "0.48013082", "0.47986314", "0.47974017", "0.4795494", "0.47816113", "0.4780183", "0.47714722", "0.47631472", "0.475661", "0.4748778", "0.47395012", "0.47246918", "0.4717305", "0.47107854", "0.47055358", "0.470255", "0.46943092", "0.46943015", "0.46933174", "0.46901017", "0.46880803", "0.46833795", "0.46788818", "0.46711478", "0.46709743", "0.4659591", "0.46579373", "0.46529436", "0.46465307", "0.4640911", "0.46353987", "0.46352357", "0.4626569", "0.4624008", "0.46223348", "0.46133772", "0.46093613", "0.4606448", "0.46017238", "0.45887417", "0.4586009", "0.45845887", "0.45822307", "0.457758", "0.45702302", "0.4568046", "0.4562059", "0.4556395", "0.45504442", "0.45471647", "0.45418605", "0.45407158", "0.45357266", "0.45243958", "0.45235917", "0.45220962", "0.45207056", "0.45200458" ]
0.86291367
0
Display title for the current unit.
function displayUnitTitle() { // Parts of the unit title var unitNo = 'སློབ་མཚན། ' + my.current.unitNo + '.' + my.current.subunitNo var space = '\u00a0\u00a0' var title = '[' + my.current.unit.title + ']' Util.setChildren(my.html.unitTitle, unitNo, space, title) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "title() { return this.owner.name + \" - \" + this.label.replace('\\n', ' ') }", "showTitle() {\n this.log(_consts.SEPARATOR);\n\n if (!this.options.title) {\n const title = `${_consts.GENERATOR_NAME} v${_package.version}`;\n const subTitle = 'Add hook to existing API';\n this.log(\n _yosay(\n `Helm Chart Generator.\\n${_chalk.red(\n title\n )}\\n${_chalk.yellow(subTitle)}`\n )\n );\n } else {\n this.log(this.options.title);\n }\n }", "getTitle() {\n return `Title is: ${this.title}`;\n }", "function getTitle() {\n return chalk.blue(\n figlet.textSync(\"Weather app\", {\n horizontalLayout: \"full\",\n font: \"banner\",\n })\n );\n}", "getFormattedTitle() {\n return this.info.title.toUpperCase();\n }", "function title() {\r\n drawScene(gl);\r\n if (!cube_title.isScrambling)\r\n cube_title.scramble();\r\n moveCamera({ movementX: velX, movementY: velY });\r\n cube_title.update(1 / 60);\r\n cube_title.show(programInfo);\r\n titleAnimationRequest = requestAnimationFrame(title);\r\n }", "function displayTitle (event) {\n $display.textContent = listoftitles[event.target.getAttribute('id')-1]\n }", "_showTitle() {\n if (this._titleJqElem) {\n this._titleJqElem.find(\".chart-title-text:first\").text(this.controlOptions.chartTitle);\n }\n }", "function my_title_format (window) {\n return '{'+get_current_profile()+'} '+window.buffers.current.description;\n}", "function setTitle() {\n dt = formatDate(myDateFormat, appstate.date);\n dtextra = (appstate.date2 === null) ? '' : ' to ' + formatDate(myDateFormat, appstate.date2);\n $('#maptitle').html(\"Viewing \" + vartitle[appstate.ltype] +\n \" for \" + dt + \" \" + dtextra);\n $('#variable_desc').html(vardesc[appstate.ltype]);\n}", "function title() {\n var elm\n \n elm = d.find(\"title\");\n elm.innerText = g.title;\n \n elm = d.tags(\"title\");\n elm[0].innerText = g.title;\n }", "get title() {\n this._logger.trace(\"[getter] title\");\n\n return this._title;\n }", "function showTitle(title) {\n\n push();\n fill(0, 30);\n noStroke();\n textStyle(BOLD);\n textSize(50);\n textAlign(CENTER);\n text(title, width/2, 100);\n pop();\n\n}", "function Title(props) {\n\treturn <div id=\"title\">\n\t Steve's Neighborhood Map - <span id=\"city-name\">(Bethlehem, PA)</span>\n </div>\n}", "function titleSetup() {\n\t\t\t\t\tif(scope.title !== undefined) {\n\t\t\t\t\t\t// For now we don't display the title\n\t\t\t\t\t\t// sel.select(\"span.list-title\").text(scope.title);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tsel.select(\"span.list-title\").text(null);\n\t\t\t\t\t}\n\t\t\t\t}", "function setTitle() {\n\t\ttitle.selectAll(\"*\").remove();\n\n\t\t// All the hustle for enabling italics ^^\n\t\tvar tmp = document.createElement(\"text\");\n\t\ttmp.innerHTML = \"Terrorist Attacks Divided into <tspan style='font-style: italic;'>K=\" + focusK + \"</tspan> Partitions\";\n\t\tvar nodes = Array.prototype.slice.call(tmp.childNodes);\n\t\tnodes.forEach(function(node) {\n\t\t\ttitle.append(\"tspan\")\n\t\t\t\t.attr(\"style\", node.getAttribute && node.getAttribute(\"style\"))\n\t\t\t\t.text(node.textContent);\n\t\t});\n\t}", "async setTitle(_) {\n this.titleView = _;\n this._top.attr(\"title\", this.titleView);\n select(this.element).attr(\"titleView\", this.titleView);\n select(this.element.shadowRoot.querySelector(\".title\")).text(_);\n }", "title() {\n return cy.get(pop_up_title_locator)\n }", "_updateTitlePanelTitle() {\n let current = this.currentWidget;\n const inputElement = this._titleHandler.inputElement;\n inputElement.value = current ? current.title.label : '';\n inputElement.title = current ? current.title.caption : '';\n }", "get title() {\n\t\treturn this.__title;\n\t}", "get title() {\n\t\treturn this.__title;\n\t}", "get title() {\n\t\treturn this.__title;\n\t}", "get title() {\n\t\treturn this.__title;\n\t}", "get title() {\n\t\treturn this.__title;\n\t}", "static get title() {\n return 'Oops! You weren\\'t supposed to see this...';\n }", "static get defaultTitle() { return 'Tool'; }", "pageTitle() {\n if(this.props.currentContestId) {\n return this.currentContest().contestName;\n }\n return \"Naming Contests\";\n }", "get title () {\n\t\treturn this._title;\n\t}", "get title () {\n\t\treturn this._title;\n\t}", "get title () {\n\t\treturn this._title;\n\t}", "get title () {\n\t\treturn this._title;\n\t}", "get title () {\n\t\treturn this._title;\n\t}", "getTitle() {}", "GetTitleString() {\n\t\treturn this.Name + ' (' + Object.keys( this.Players ).length + ')';\n\t}", "function displayTitle(){\n push();\n textFont(`Blenny`);\n textSize(70);\n fill(breadFill.r, breadFill.g, breadFill.b);\n textLeading(53);\n text(`GET\\nTHAT\\nBREAD`, 1050, 612);\n pop();\n}", "title() {\n console.log(`fspop [Version ${pkg.version}]\\n`);\n }", "updateWindowTitle() {\n if (this.win) {\n const {translatableFlat} = this.core.make('osjs/locale');\n const prefix = translatableFlat(this.proc.metadata.title);\n const title = this._createTitle(prefix);\n\n this.win.setTitle(title);\n }\n }", "UpdateTitle() {\n var Key = this.TitleKey || this.Name;\n\n var self = this;\n tp.Res.GS(Key, function (Value, UserTag) {\n self.Title = Value;\n }, null, Key, this);\n\n }", "showTitle() {\n this.log(_consts.SEPARATOR);\n this.log('Create a REST API Resource:\\n');\n this.log();\n }", "function getTitle() {\r\n var carrier = story.getFrameValue();\r\n var index = carriers.indexOf(carrier) + 1;\r\n return \"#\" + (\"0\" + index).slice(-2)+ \" - \" + carrier;\r\n }", "function setTitle(title) {\r\n d3.select(\".timelapse-chart-title\")\r\n .attr(\"x\", chartSettings.width / 2)\r\n .attr(\"y\", -chartSettings.padding / 2)\r\n .text(title);\r\n\r\n return this;\r\n }", "function set_title(title){\n\t\t\tdocument.querySelector(\"#footertitle span\").innerText = title;\n\t\t}", "setTitle(title) {\n this._title = title;\n this.emit('titleChanged', title);\n this.emit('stateChanged');\n }", "set title( val ) {\n this.title_bar_text.innerText = val;\n }", "function updateProgressTooltip()\n {\n my.html.progress.title =\n 'This lesson contains ' + my.current.subunitText.length +\n ' characters.'\n }", "get title() { return \"Local Coding\"}", "get title() {\n return this._title;\n }", "function titleText(title) {\n pageTitle.textContent = title;\n}", "get title() {\n return this._title;\n }", "get title() {\n return this._title;\n }", "get title(){\n return this._title.toUpperCase();\n }", "function _title() {\n var title = \"\";\n\n title =\n \"\" +\n \" ----------------- ----------------- \\n\" +\n \"| A | | 7 |\\n\" +\n \"| | | |\\n\" +\n \"| | | /\\\\ /\\\\ |\\n\" +\n \"| | | \\\\/ \\\\/ |\\n\" +\n \"| / \\\\ | | /\\\\ /\\\\ /\\\\ |\\n\" +\n \"| (_ _) | VS | \\\\/ \\\\/ \\\\/ |\\n\" +\n \"| /_\\\\ | | /\\\\ /\\\\ |\\n\" +\n \"| | | \\\\/ \\\\/ |\\n\" +\n \"| | | |\\n\" +\n \"| A | | 7 |\\n\" +\n \" ----------------- ----------------- \\n\" +\n \"\\n\" +\n \" The Game of War \\n\" +\n \" Game: \" +\n _gameID +\n \" \\n\";\n\n _log(title);\n }", "updateDisplayString() {\n this.displayString = 'Increase ' + this.name + ' by ' + this.value + ' ' + this.measuringUnit;\n }", "static get title() {\n return __('About');\n }", "get theTitle()\n {\n return this.title;\n }", "function getPageTitle () {\n return title;\n }", "function ScreedTodoTaskTitle() {\n}", "function title_view(title) {\n var titleInput = gId(\"title\");\n gId('story_title').innerHTML = title;\n gId('story_title').style.display = \"block\";\n titleInput.style.display = \"none\";\n gId('add_title').style.display = \"none\";\n}", "function console_title(title) {\n console.log(`\\n// ${title}`)\n console.log(\"// ======================================\")\n}", "function title() {\n \t\ttitleDef = new image(DEMO_ROOT + \"/def/resources/title_def.png\");\t\t\t\t\t// Load images\n \t\ttitleDemo = new image(DEMO_ROOT + \"/def/resources/title_demo.png\");\n \t\ttitleDefScreen = SeniorDads.ScreenHandler.Codef(\t\t\t\t\t\t\t\t\t// Set up \"'Def\" canvas\n \t\t\t\ttitleDef.img.width,\n \t\t\t\ttitleDef.img.height,\n \t\t\t\tname, zIndex++, \n \t\t\t\t0,\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// Position on center left\n \t\t\t\t200 - (titleDef.img.height /2)\n \t\t\t\t);\n \t\ttitleDefScreen.hide();\n \t\ttitleDef.draw(titleDefScreen,0,0);\t\t\t\t\t\t\t\t\t\t\t\t\t// Draw image onto canvas\n \t\ttitleDemoScreen = SeniorDads.ScreenHandler.Codef(\t\t\t\t\t\t\t\t\t// Set up \"Demo\" canvas\n \t\t\t\ttitleDemo.img.width,\n \t\t\t\ttitleDemo.img.height,\n \t\t\t\tname, zIndex++, \n \t\t\t\t640 - (titleDemo.img.width),\t\t\t\t\t\t\t\t\t\t\t\t// Position on center right\n \t\t\t\t200 - (titleDemo.img.height /2)\n \t\t\t\t);\n \t\ttitleDemoScreen.hide();\n \t\ttitleDemo.draw(titleDemoScreen,0,0);\t\t\t\t\t\t\t\t\t\t\t\t// Draw image onto canvas\n \t}", "function shortenPageTitle() {\n document.getElementById('main-title').innerHTML = \"Fast & Furious\";\n }", "setTitle(title) {\r\n this.title = title;\r\n if (this.isActive) {\r\n this.router.updateTitle();\r\n }\r\n }", "function setTitle() {\n var dateString = dateFormat(new Date(), 'HH:MM:ss');\n document.title = title + ' - ' + APP_PACKAGE_INFO.version;\n }", "get title() { return this.title_; }", "function draw_title() {\n // Draw the red area\n display.fill(0, 0, display.getWidth(), 1, \"white\", \"red\", ' ');\n\n // Draw the title and author\n display.text(1, 0, \"Etch A Sketch\");\n display.text(display.getWidth() - 14, 0, \"by Ricky Rung\");\n}", "updateComponent() {\n this.shadowRoot.getElementById('myuw-help__title').innerHTML = this['myuw-help-title'];\n }", "ngOnInit() {\n this.title = 'Ingresar la lectura del Medidor';\n }", "set title(title) {\n this.setAttribute(\"title\", title);\n }", "get title() {\n return this.getText('title');\n }", "get title() {\n return this.getText('title');\n }", "get title() {\r\n return this.i.title;\r\n }", "get get_title () {\n return this._title;\n }", "title() {\n return `Number of live incidents: ${this.liveIncidents}`\n }", "function updateTitle(currentChapter) {\n var title = 'Breaking faith';\n if (currentChapter == 0) {\n title = 'Breaking faith';\n } else {\n title = 'Chapter ' + currentChapter ;\n }\n $(\".title\").html(title);\n }", "updateTitle() {\n let numReports = this.reports.length\n if(numReports >= 101) {\n this.title = 'Bestest Manager'\n } else if(numReports >= 51) {\n this.title = 'Manager Plus'\n } else if(numReports >= 11) {\n this.title = 'Manager'\n } else if(numReports >= 4) {\n this.title = 'Mostly Manager'\n } else if(numReports >= 1) {\n this.title = 'Barely Manager'\n } else {\n this.title = 'Not a Manager'\n }\n }", "getFormattedTitle(){\n //.....this key word used to apply conversion logic to code (uppercase letter)\n return this.info.title.toUpperCase()\n }", "function getTitle() {\n return document.getElementById( \"eow-title\" ).title;\n}", "function initTitle() {\n if (Vue.prototype.hasOwnProperty('$createTitle')) {\n return;\n }\n\n /**\n * Generates the document title out of the given VueComponent and parameters\n *\n * @param {String} [identifier = null]\n * @param {...String} additionalParams\n * @returns {string}\n */\n Vue.prototype.$createTitle = function createTitle(identifier = null, ...additionalParams) {\n const baseTitle = this.$tc('global.sw-admin-menu.textShopwareAdmin');\n const pageTitle = this.$tc(this.$route.meta.$module.title);\n\n const params = [baseTitle, pageTitle, identifier, ...additionalParams].filter((item) => {\n return item !== null && item.trim() !== '';\n });\n\n return params.reverse().join(' | ');\n };\n }", "getTitle() {\n return IsMorning(this.date) ? \"Sunrise - \" + this.date.toLocaleString() : \"Sunset - \" + this.date.toLocaleString();\n }", "function setTitle() {\n let niveau = getUrlParameter('level');\n $('#title').text(\"Niveau \" + niveau);\n}", "function popTitle(){\n\tvar x = \"Project Name: \" + currentProject.title;\n\tdocument.getElementById(\"projTitle\").innerHTML = x;\n}", "get title() {\n return this._data.title;\n }", "get title() {\n return this._data.title;\n }", "get title() { return this.Nls(\"Export_Title\"); }", "static title(_title) {\n document.title = _title;\n }", "setTitle(title) {\r\n this.title = siteTitle + title\r\n document.title = Site.info.siteName + ' ' + siteTitle + title\r\n }", "function showTitle() {\n if ($(\".sliderTitle#title\" + currentSlide).text().length > 0) {\n $(\"div.title\").stop();\n $(\"div.title\").fadeTo(titleFadeTime, titleOpacity);\n }\n }", "describe() {\n return \"You've walked into the \" + this._name + \", \" + this._description;\n }", "showTitle() {\n let title = document.createElement(\"h2\");\n title.innerHTML = \"Introduction\";\n\n this.main.appendChild(title);\n }", "function displayTitle() {\n // Set up all the styling elements\n push();\n textAlign(CENTER,CENTER);\n textSize(32);\n fill(255);\n stroke(255);\n // Display the text\n text(\"SPACELOVE!\",width/2,height/2);\n // Font size goes down\n textSize(16);\n // Display the instructions\n text(\"Press SPACE to play\\nUse WASD+CONTROL and ARROWS+SHIFT\",width/2,3*height/4);\n pop();\n\n // Check whether the spacebar was pressed to start the game...\n if (keyIsPressed && key === ' ') {\n // ... if it was, change the state to \"GAME\" so the switch statement in draw()\n // will display the game instead\n state = \"GAME\";\n }\n}", "function title(){\n\n}", "function chartTitle(options) {\n var titletext = $(\"<h1></h1>\").text(options.charttitle);\n titletext.attr(\"id\", \"title\");\n $(\"#chartcontainer\").append(titletext);\n $(\"#title\").css({\n \"color\": options.titlefontcolor,\n \"font-size\" : options.titlefontsize,\n \"padding\": \"5px\",\n \"text-align\": \"center\"\n });\n}", "function updateTitle(text) {\n $('title').html(\"Blacksmith - \" + text);\n}", "function pa_panel_create_title(title) {\n\tvar title_elem = pa_create_tag(\n\t\t'div',\n\t\t'pa-panel-title',\n\t\tdocument.body);\n\ttitle_elem.textContent = title;\n\ttitle_elem.className = 'bold';\n\tpa_add({\n\t\tid: 'pa-panel-title',\n\t\theight: 0.1,\n\t\tleft: 0.05,\n\t\tfontSize: PA_PANEL_FONT_SIZE,\n\t\ttop: 0.025\n\t});\n\treturn title_elem;\n}", "updateTitle() {\r\n let parentRouter = this.parent;\r\n if (parentRouter) {\r\n return parentRouter.updateTitle();\r\n }\r\n let currentInstruction = this.currentInstruction;\r\n if (currentInstruction) {\r\n currentInstruction._updateTitle();\r\n }\r\n return undefined;\r\n }", "title() {\n if (arguments.length) {\n title = arguments[0];\n return column;\n }\n return purifyHtml(title || name);\n }", "function updateTitle() {\n if ($('#expr').val()) {\n document.title = \"xen-calc: \" + $('#expr').val();\n }\n else {\n document.title = \"xen-calc\";\n }\n}", "display(title) {\r\n this.title.html(title);\r\n this.title.position(130, 0);\r\n if (this.playButton, this.inputbox) {\r\n this.inputbox.position(130, 160);\r\n\r\n this.playButton.position(250, 200);\r\n\r\n this.playButton.mousePressed(() => {\r\n this.inputbox.hide();\r\n this.playButton.hide();\r\n playerObj.name = this.inputbox.value();\r\n gameState = 1;\r\n this.greeting.html(\"Welcome \" + playerObj.name);\r\n this.greeting.position(200, 250);\r\n });\r\n }\r\n }", "function title() {\n push();\n textSize(30);\n fill(0, 198, 201);\n stroke(0);\n strokeWeight(5);\n textAlign(CENTER, CENTER);\n text(`Bubble Popper++`, width / 2, height / 2);\n textSize(15);\n fill(182, 207, 0);\n text(instructions, width / 2, height / 1.5);\n pop();\n}", "function setTitle(title) {\r\n\t\t var show = false;\r\n\t\t\tif (self.options.overrideTitle != null) {\r\n\t\t\t show = true;\r\n\t\t\t\tself.bbgCss.jq.title.html(self.options.overrideTitle);\r\n\t\t\t} else if (typeof(title) != 'undefined') {\r\n\t\t\t\tself.bbgCss.jq.title.html(title);\r\n\t\t\t\tshow = true;\r\n\t\t\t} else {\r\n\t\t\t\tself.bbgCss.jq.title.html('');\r\n\t\t\t}\r\n\t\t\tif (show) {\r\n\t\t\t\tself.bbgCss.jq.title.show();\r\n\t\t\t} else {\r\n\t\t\t\tself.bbgCss.jq.title.hide();\r\n\t\t\t}\r\n\t\t}" ]
[ "0.69369173", "0.6902636", "0.6851144", "0.68014085", "0.67773896", "0.6727385", "0.6676678", "0.6635912", "0.64873755", "0.6485262", "0.6455869", "0.6447169", "0.6438482", "0.64255977", "0.64178836", "0.6412323", "0.64063", "0.6403999", "0.6394279", "0.6350035", "0.6350035", "0.6350035", "0.6350035", "0.6350035", "0.63340473", "0.63295585", "0.6327297", "0.63001436", "0.63001436", "0.63001436", "0.63001436", "0.63001436", "0.62815386", "0.6266082", "0.6263666", "0.62570965", "0.6232492", "0.6226645", "0.6222059", "0.619941", "0.6175304", "0.6172738", "0.61695504", "0.6167614", "0.6161718", "0.6154664", "0.6153425", "0.61430186", "0.61429536", "0.61429536", "0.61403054", "0.61401963", "0.61355597", "0.61331654", "0.61209416", "0.61168694", "0.6116021", "0.6102479", "0.61016536", "0.60865945", "0.6083999", "0.6081604", "0.60633177", "0.605483", "0.6039027", "0.6036417", "0.60338145", "0.60309714", "0.60248786", "0.60248786", "0.6001056", "0.59958386", "0.59947205", "0.59942275", "0.5992311", "0.5987869", "0.5981455", "0.5972045", "0.59612423", "0.59521574", "0.5947089", "0.5928896", "0.5928896", "0.591882", "0.58985794", "0.58985716", "0.58978003", "0.58831584", "0.5882327", "0.58750695", "0.58745104", "0.58725595", "0.5869215", "0.586766", "0.5866881", "0.58625644", "0.58586013", "0.5855766", "0.5843981", "0.5841452" ]
0.8794409
0
Display guide for the current unit.
function displayGuide() { my.html.guide.innerHTML = my.current.unit.guide }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "updateDisplayString() {\n this.displayString = 'Increase ' + this.name + ' by ' + this.value + ' ' + this.measuringUnit;\n }", "function displayHelpText() {\n console.log();\n console.log(' Usage: astrum figma [command]');\n console.log();\n console.log(' Commands:');\n console.log(' info\\tdisplays current Figma settings');\n console.log(' edit\\tedits Figma settings');\n console.log();\n}", "function display() {\n lcd.clear();\n lcd.cursor(0, 0).print(displayDate());\n lcd.cursor(1, 0).print(displayMeasure());\n }", "function getGuideDisplay(res, mysql, context, complete) {\n mysql.pool.query(\"SELECT tour_guide.tourGuide_ID as guide_ID, CONCAT(tour_guide.first_name, ' ', tour_guide.last_name) as guide_full_name FROM tour_guide ORDER BY guide_full_name\",\n function (error, results, fields) {\n if (error) {\n res.write(JSON.stringify(error));\n res.end();\n }\n context.guide_display = results;\n complete();\n });\n }", "function Guide(oa){\n\t\tthis.objtype = 'guide';\n\n\t\tthis.type = oa.type || 'vertical';\n\t\tthis.name = oa.name || (this.type + ' guide');\n\t\tthis.location = isval(oa.location)? oa.location : 200;\n\t\tthis.angle = oa.angle || false;\n\t\tthis.color = oa.color || makeRandomSaturatedColor();\n\t\tthis.visible = isval(oa.visible)? oa.visible : true;\n\t\tthis.showname = isval(oa.showname)? oa.showname : true;\n\t\tthis.editable = isval(oa.editable)? oa.editable : true;\n\t}", "function displayUnitTitle() {\n\n // Parts of the unit title\n var unitNo = 'སློབ་མཚན། ' + my.current.unitNo +\n '.' + my.current.subunitNo\n var space = '\\u00a0\\u00a0'\n var title = '[' + my.current.unit.title + ']'\n\n Util.setChildren(my.html.unitTitle, unitNo, space, title)\n }", "getHelp ( input, output ) {\n output.standardOutput.writeLine( 'Usage:' );\n this.getUsage().split( '\\n' ).forEach( line => output.standardOutput.writeLine( line ) );\n output.standardOutput.writeLine( '' );\n\n if ( this.getDescription() ) {\n output.standardOutput.writeLine( 'Description:' );\n output.standardOutput.writeLine( this.getDescription() );\n }\n\n output.standardOutput.writeLine( '' );\n }", "get help() {\n\t\tlet response = \"\"\n\t\tif (this._description) { \n\t\t\tresponse = this._description; \n\t\t}\n\n\t\tresponse += \" - Usage: \" + this.format;\n\t\tresponse += \" - Ex: \" + this.example;\n\n\t\treturn response;\n\t}", "function DisplayDesc() {\n\t\tif (props.powerPro.boss === 0) {\n\t\t\treturn (\n\t\t\t\t<p>\n\t\t\t\t\tYou enter the generator room and are standing on a landing. You notice\n\t\t\t\t\ta catwalk stretching the length of the room. In the center of the room\n\t\t\t\t\tis a cyborg scientist working at a console.\n\t\t\t\t</p>\n\t\t\t);\n\t\t} else {\n\t\t\treturn (\n\t\t\t\t<p>\n\t\t\t\t\tYou return to the generator room. Dr. Crackle is working at his\n\t\t\t\t\tconsole once again.\n\t\t\t\t</p>\n\t\t\t);\n\t\t}\n\t}", "helpText(){\n\n if(this.getStep() === 0 ){\n return ` -== HELP ==-\n The first line is 1 integer, consisting of the number of the number of lines of source code (N).\n The second line is 1 integer, constiting of the number of queries (Q).\n The next N lines consiste of HRML source code, consisting of either an opening tag with zero or more attributes or a closing tag. \n Then the next Q lines contains the queries. \n Each line is a string that references an attribute in the HRML source code.`;\n\n }else if(this.getStep() === 1){\n return 'START';\n }\n }", "function info() {\n\tseperator();\n\tOutput('<span>>info:<span><br>');\n\tOutput('<span>Console simulator by Mario Duarte https://codepen.io/MarioDesigns/pen/JbOyqe</span></br>');\n}", "function getDescription(){\n\t\tvar str = \"Draw Tool\";\n\n\t\treturn str;\n\t}", "describe() {\n return \"You've walked into the \" + this._name + \", \" + this._description;\n }", "function showHelpText() {\n ctx.save();\n\n if (lastUsedInput === 'keyboard') {\n setFont(18);\n ctx.fillStyle = 'white';\n ctx.fillText(translation.spacebar + ' ' + translation.select, 28 - fontMeasurement, kontra.canvas.height - 25 + fontMeasurement / 2.5);\n }\n else if (lastUsedInput === 'gamepad') {\n drawAButton(28, kontra.canvas.height - 25);\n setFont(18);\n ctx.fillStyle = 'white';\n ctx.fillText(translation.select, 28 + fontMeasurement * 1.75, kontra.canvas.height - 25 + fontMeasurement / 2.5);\n }\n\n ctx.restore();\n}", "show() {\n if (this.curriculum === Curriculum.QUICK_ORIENTATION ||\n this.curriculum === Curriculum.TOUCH_ORIENTATION) {\n // If opening the tutorial from the OOBE, automatically show the first\n // lesson.\n this.updateIncludedLessons_();\n this.showLesson_(0);\n } else {\n this.showMainMenu_();\n }\n this.isVisible = true;\n }", "printHelp(obj){\n console.log();\n this.terminal.green(\"Usage: %s [options]\\n\", obj.cmd ? obj.cmd : \"\");\n if( obj.desc ){\n this.terminal.brightBlack(\"\\t%s\\n\", obj.desc);\n }\n if( obj.opts && obj.opts.length > 0 ){\n this.terminal.black(\"\\nOptions:\\n\");\n let opt;\n for( let i = 0; i < obj.opts.length; i++ ){\n opt = obj.opts[i];\n if( !opt.cmd )\n continue;\n\n this.terminal.green(\"%s\\t%s\\n\", opt.cmd, opt.desc ? opt.desc : \"\");\n }\n }\n }", "function help() {\n printLine('The following commands work. Hover them for more information.');\n printLine('' +\n ' <span class=\"yellow\" title=\"Explain the list of commands\">help</span>,' +\n ' <span class=\"yellow\" title=\"Clear the screen for freshness\">clear</span>,' +\n ' <span class=\"yellow\" title=\"List all the files in this directory\">ls</span>,' +\n ' <span class=\"yellow\" title=\"List all links on the website\">tree</span>,' +\n ' <span class=\"yellow\" title=\"Change directory to `dirname`\">cd </span>' +\n '<span class=\"blue\" title=\"Change directory to `dirname`\"><em>dirname</em></span>,' +\n ' <span class=\"yellow\" title=\"Show the contents of `filename`\">cat </span>' +\n '<span class=\"green\" title=\"Show the contents of `filename`\"><em>filename</em></span>'\n );\n printLine('<br>');\n printLine('You can also use the' +\n ' <kbd class=\"cyan\">Up</kbd> and' +\n ' <kbd class=\"cyan\">Down</kbd>' +\n ' keys to navigate through your command history.'\n );\n printLine('You can click on tree nodes if CLI is not your thing.' +\n ' You\\'ll still need to hit <kbd class=\"cyan\">Enter</kbd>.'\n );\n}", "function showInstructions() {\n\t\t\tclear();\n\t\t\tdiv.update('<span style=\"color: grey; font-style: italic;\">' + lang.instructions + '</span>');\n\t\t}", "lldisplayWordDefinition() {\r\n console.log(`\\nDefinition: ${this.definition}`);\r\n }", "helpInfo () {\n\t\tlet me = this;\n\n\t\treturn [\n\t\t\t$('<h3>').append(\n\t\t\t\tt('Adicionar um novo equipamento à aventura')\n\t\t\t),\n\t\t\tEquipament.helpTypeMeaning()\n\t\t];\n\t}", "updateDisplay() {\n $('#steps .value').text(this.stepCounter);\n }", "helpInformation() {\n let desc = [];\n\n if (this._description) {\n desc = [this._description, ''];\n const {\n argsDescription\n } = this;\n\n if (argsDescription && this._args.length) {\n const width = this.padWidth();\n desc.push('Arguments:');\n desc.push('');\n\n this._args.forEach(({\n name\n }) => {\n desc.push(` ${pad(name, width)} ${argsDescription[name]}`);\n });\n\n desc.push('');\n }\n }\n\n let cmdName = this._name;\n\n if (this._alias) {\n cmdName = `${cmdName}|${this._alias}`;\n }\n\n const usage = [`Usage: ${cmdName} ${this.getUsage()}`, ''];\n let cmds = [];\n const commandHelp = this.commandHelp();\n if (commandHelp) cmds = [commandHelp];\n const options = ['Options:', `${this.optionHelp().replace(/^/gm, ' ')}`, ''];\n return usage.concat(desc).concat(options).concat(cmds).join('\\n');\n }", "getDescription() {\n let desc = super.getDescription();\n\n if (this.hasMajor()) {\n desc += ` Their mayor is ${this.major}`;\n }\n\n return desc;\n }", "function Start() {\n\t\tvar text = GetComponentInChildren(TextMesh) as TextMesh;\n\t\ttext.text = ability.helpText;\n\t\t\n\t\t// if the unit is used, make sure you're grayed out\t\n\t//\tif(unit.used) {\n\t//\t\trenderer.material.color = Color.gray;\n\t//\t}\n\t}", "displayWordInfo() {\r\n this.displayHangman();\r\n this.displayLives();\r\n this.displayLetters();\r\n this.displayLettersToGuess();\r\n }", "function outputDeviceSummary(){\n console.log(\"============================\");\n console.log(\"Power: \" + pCurrent);\n console.log(\"Mode: \" + mCurrent);\n console.log(\"============================\");\n}", "function displayHelp() {\n /* eslint-disable no-console */\n console.log(\n /* eslint-disable indent */\n`Usage: node generate_full_demo.js [options]\nOptions:\n -h, --help Display this help\n -m, --minify Minify the built demo\n -p, --production-mode Build all files in production mode (less runtime checks, mostly).\n -w, --watch Re-build each time either the demo or library files change`,\n /* eslint-enable indent */\n );\n /* eslint-enable no-console */\n}", "show() {\n strokeWeight(this.stroke);\n fill(this.color);\n rect(this.x, this.y, this.w, this.h);\n\n if (this.dragging == false) {\n strokeWeight(1);\n fill(0);\n textSize(1 * this.h);\n text(`${this.length}`, UBoxUlcX+UBoxWidth-50, this.y + this.h);\n }\n }", "printHelpText() {\n const helpText = fs.readFileSync(\n path.join(__dirname, 'cli-help.txt'), 'utf8');\n logHelper.info(helpText);\n }", "get display() {\n\t\treturn this.__display;\n\t}", "constructor() {\n super('help', ['h']);\n this.setDescription('Do you really need to know how to ask for help?');\n }", "showStats(){\n console.log(\"Name:\", this.name, \"\\nStrength:\", this.strength, \"\\nSpeed:\", this.speed, \"\\nHealth:\", this.health);\n }", "displayInfo() {\n\t\t\tlet info = super.displayInfo() + ', разработчики: ' + this.getDevelopers() ;\n\t\t\tconsole.log( info );\n\t\t\treturn info\n\t\t\t}", "describeKimfer() {\n return `Meet ${this.name}! He has ${this.health} health points and a strength of ${this.strength}. He have ${this.xp} experience points`;\n }", "function getDescription(){\n\t\tvar str = \"Select Tool\";\n\n\t\treturn str;\n\t}", "show() {\n\t\tconsole.log(`Pokemon '${this.name}', level: ${this.level}`);\n\t}", "getDescription() {\n let description = super.getDescription();\n\n if(this.hasMajor()){\n description += `Their major is ${this.major}.`;\n }\n\n return description;\n }", "function help(){\n var fieldId = $(this).prev('input').attr('id');\n var format = getActiveOptionOn(fieldId);\n $.notify(helpFor(format));\n }", "describe() {\n return `${this.name} has ${this.health} health points, ${this\n .strength} as strength and ${this.xp} XP points`;\n }", "function help() {\n\tvar commandsArray = ['Help: List of available commands', '>help', '>about', '>contact', '>ping', '>time', '>clear', '>say'];\n\tfor (var i = 0; i < commandsArray.length; i++) {\n\t\tvar out = '<span>' + commandsArray[i] + '</span><br/>'\n\t\tOutput(out);\n\t}\n}", "quickFacts(){\n console.log(`${this.name} educates ${this.numberOfStudents} students at the ${this.level} level.`);\n }", "commandHelp() {\n if (!this.commands.length) return '';\n const commands = this.prepareCommands();\n const width = this.padWidth();\n return ['Commands:', commands.map(cmd => {\n const desc = cmd[1] ? ` ${cmd[1]}` : '';\n return (desc ? pad(cmd[0], width) : cmd[0]) + desc;\n }).join('\\n').replace(/^/gm, ' '), ''].join('\\n');\n }", "function deviceprint_display ()\n\t{\n\t\tt = \"\";\n\t\tif (self.screen)\n\t\t{\n\t\t\tt += screen.colorDepth +SEP+ screen.width +SEP+ screen.height +SEP+ screen.availHeight;\n\t\t}\n\t\treturn t;\n\t}", "function displayHelp()\n{\n // Replace the following call if you are modifying this file for your own use.\n dwscripts.displayDWHelp(HELP_DOC);\n}", "function displayHelp() {\n var pkg = require(__dirname + \"/../package.json\");\n grunt.log.writeln();\n grunt.log.writeln(pkg.description);\n grunt.log.writeln((\" \" + pkg.name + \" \").green.inverse\n + \" Version - \" + pkg.version);\n\n // Borrowed heavily from the Grunt help source.\n var col1len = 0;\n\n var opts = Object.keys(grunt.cli.optlist).map(function(long) {\n var o = grunt.cli.optlist[long];\n var col1 = '--' + (o.negate ? 'no-' : '') + long + (o.short ? ', -' + o.short : '');\n col1len = Math.max(col1len, col1.length);\n return [col1, o.info];\n });\n\n var widths = [1, col1len, 2, 76 - col1len];\n\n var gruntTasks = Object.keys(grunt.task._tasks).sort()\n // var tasksList = Object.keys(grunt.task._tasks).slice(8);\n\n if (gruntTasks.length) {\n displayTasks(\"Towelie\", gruntTasks);\n }\n \n // if (gruntTasks.length) {\n // displayTasks(\"Grunt\", gruntTasks);\n // }\n\n function displayTasks(name, tasksList) {\n var tasks = tasksList.map(function(name) {\n col1len = Math.max(col1len, name.length);\n var info = grunt.task._tasks[name].info;\n\n return [name, info.blue];\n });\n\n grunt.log.header((name + \" tasks:\").yellow);\n grunt.log.writeln();\n\n tasks.forEach(function(a) {\n grunt.log.writetableln(widths,\n ['', grunt.utils._.pad(a[0], col1len), '', a[1]]\n );\n });\n }\n\n grunt.log.writeln();\n}", "showDescription() {\n ui.toggleDescription();\n }", "drawHUD() {\n this.itemsInfo = `X ${this.collectableGroup.countLiving()}`;\n this.enemyInfo = `X ${this.enemies.total}`;\n\n this.itemsText.setText(this.itemsInfo);\n this.enemyText.setText(this.enemyInfo);\n }", "get display () {\n\t\treturn this._display;\n\t}", "get display () {\n\t\treturn this._display;\n\t}", "get display () {\n\t\treturn this._display;\n\t}", "help() {\n const lines = [];\n if (this.banner) { lines.unshift(`${this.banner}\\n`); }\n for (const rule of Array.from(this.rules)) {\n let spaces = 15 - rule.longFlag.length;\n spaces = spaces > 0 ? repeat(' ', spaces) : '';\n const letPart = rule.shortFlag ? `${rule.shortFlag}, ` : ' ';\n lines.push(` ${letPart}${rule.longFlag}${spaces}${rule.description}`);\n }\n return `\\n${lines.join('\\n')}\\n`;\n }", "function help() {\n\tvar commandsArray = ['Help: List of available commands',\n\t\t'<span class=\"green\">>about</span>',\n\t\t'<span class=\"yellow\">>contact</span>',\n\t\t'<span class=\"purple\">>projects</span>',\n\t\t'<span class=\"orange\">>skills</span>',\n\t\t'<span class=\"blue\">>experiences</span>',\n\t\t'>help',\n\t\t'>ping',\n\t\t'>time',\n\t\t'>clear',\n\t\t'>say',\n\t\t'>info',\n\t\t'>exit'];\n\tseperator();\n\tfor (var i = 0; i < commandsArray.length; i++) {\n\t\tvar out = '<span>' + commandsArray[i] + '</span><br/>'\n\t\tOutput(out);\n\t}\n}", "displayInfo() {\n\t\t\tlet info = super.displayInfo() + ', менеджер: ' + this.manager.name ;\n\t\t\tconsole.log( info );\n\t\t\treturn info\n\t\t\t}", "function toggleGuide()\n {\n if (guide.style.display == 'none') {\n return showGuide()\n } else {\n return hideGuide()\n }\n }", "renderPresenceHelp() {\n var cmds = require('@commands');\n var n = (this.getTotalCharacterCount() / 1000).toFixed(1);\n return cmds.command_char + `help, ${Number.isNaN(n) ? 0 : n}k chars`;\n }", "formatSynopsis() {\n if (this.demand) {\n return ` <${this.name}>`\n }\n return ` [${this.name}]`\n }", "function updateProgressTooltip()\n {\n my.html.progress.title =\n 'This lesson contains ' + my.current.subunitText.length +\n ' characters.'\n }", "display() {\n fill(this.color);\n\n triangle(this.x, this.y, this.x + 30, this.y - 55, this.x + 60, this.y);\n strokeWeight(7); //important for line to be visible\n strokeCap(SQUARE);\n stroke(this.color);\n\n //levitating line\n line(this.x, this.lineY - 30, this.x + 60, this.lineY - 30);\n\n //little eyes\n strokeWeight(3);\n stroke(\"white\");\n line(this.x + 10, this.y - 10, this.x + 20, this.y - 10);\n line(this.x + 30, this.y - 10, this.x + 40, this.y - 10);\n\n noStroke(); //reset so stroke doesn't carry into other creatures\n }", "function setUnitInfoInfo(stroption) {\n UnitInfo = stroption;\n}", "get targetDisplay() {}", "function displayHelp()\r\n{\r\n dwscripts.displayDWHelp(helpDoc);\r\n}", "instructions() {\n this.canvas[1].font = \"20px Arial\";\n this.canvas[1].fillText('Goal: Avoid the monsters. Reach the princess.',10,105);\n }", "function action_help_texts(section) {\n\t$('div.step1details div.tips').hide();\n\tvar open_section = $('div#sideinfo-'+ section);\n\topen_section.show();\n}", "function displayHelp()\r\n{\r\n dwscripts.displayDWHelp(HELP_DOC);\r\n}", "function displayHud() {\n // 2D screen-aligned rendering section\n easycam.beginHUD()\n // this._renderer._enableLighting = false // fix for issue #1\n let state = easycam.getState()\n\n // Render the background box for the HUD\n noStroke()\n fill(0)\n rect(x, y, 20, 100)\n fill(50, 50, 52, 200) // a bit of transparency\n rect(x + 20, y, 380, 100)\n\n // Render the labels\n fill(69, 161, 255)\n text(\"Distance:\", x + 35, y + 25)\n text(\"Center: \", x + 35, y + 25 + 20)\n text(\"Rotation:\", x + 35, y + 25 + 40)\n text(\"Framerate:\", x + 35, y + 25 + 60)\n\n // Render the state numbers\n fill(69, 161, 255)\n text(nfs(state.distance, 1, 2), x + 125, y + 25)\n text(nfs(state.center, 1, 2), x + 125, y + 25 + 20)\n text(nfs(state.rotation, 1, 3), x + 125, y + 25 + 40)\n text(nfs(frameRate(), 1, 2), x + 125, y + 25 + 60)\n easycam.endHUD()\n}", "function showHelp() {\n\t//Use figlet npm package to convert text to art/drawing.\n\tfiglet('LIRI help', function (err, data) {\n\t\tif (err) {\n\t\t\tconsole.log('Something went wrong...');\n\t\t\tconsole.dir(err);\n\t\t\treturn;\n\t\t}\n\t\tconsole.log(data)\n\t});\n\tvar helpInfo = \"Usage: node liri.js <command> [arguments]\"\n\tvar helpColumns = columnify([{\n\t\tCommand: 'my-tweets',\n\t\tDescription: \"Shows the last 20 tweets from Twitter timeline and when they were created.\"\n\t}, {\n\n\t\tCommand: \"movie-this [movie_name]\",\n\t\tDescription: \"Shows information about the specifid movie. If no movie is specified, Mr. Nobody is displayed by default.\"\n\t}, {\n\n\t\tCommand: \"spotify-this-song [song_name]\",\n\t\tDescription: \"Shows top 10 songs on Spotify that have specified name. If no song is specified, The Sign by Ace of Base is displayed by default.\"\n\t}, {\n\n\t\tCommand: 'do-what-it-says',\n\t\tDescription: \"Shows the top 10 songs on Spotify for the song, 'I want it that way.'\"\n\t}])\n\tconsole.log(\"==================================================================================================\");\n\tconsole.log(helpInfo);\n\tconsole.log(\"==================================================================================================\");\n\tconsole.log(helpColumns);\n}", "describe() {\n return `${this.name} has ${this.health} health points, \n ${this.strength} as strength and ${this.xp} XP points`;\n }", "static about() {\n return \"a vehicle is a means of transportion.\"\n }", "function displayHelp()\n{\n dwscripts.displayDWHelp(HELP_DOC);\n}", "getInfo() {\n return `${super.getInfo()} Their average grade is ${this.getAverageGrades()}`\n }", "get description () {\r\n // checking dialog stage\r\n if (!this.context.dialog) {\r\n this.context.dialog = 0;\r\n }\r\n // displaying text for the current stage\r\n return phrases[this.context.dialog];\r\n }", "get descripion() {\n return this._descripion\n }", "function help_menu() {\n console.log('Please use one of the following commands:')\n console.log('Summary: ./pandlss.sh -s <date> <time>')\n console.log('Breakdown: ./pandlss.sh -b <date> <time> <increment>')\n console.log('Breakdown one stock: ./pandlss.sh -b-os <stock> <date> <time> <increment>')\n}", "function help() {\n console.log(\"joy \\n\\\n \\n \\\n Usage:\\n \\\n joy new <name>...\\n \\\n joy build \\n \\\n joy serve \\n \\\n joy tidy \\n \\\n joy help \\n \\\n \\n \\\n joy -h | --help \\n \\\n joy --version \\n \\\n \\n \\\n Options: \\n \\\n -h --help Show this screen. \\n \\\n --version Show version.\\n \\\n \");\n}", "displayCmd() {\r\n var cmdText = \"Commands \\n\";\r\n for (let i = 0; i < this.cmdOrder.length; ++i) {\r\n cmdText += this.cmdOrder[i] + \": \";\r\n cmdText += keyboardMap[this.cmdKeyCode[this.cmdIdx[this.cmdOrder[i]]]];\r\n cmdText += \"\\n\";\r\n }\r\n this.document.getElementById('commands').innerText = cmdText;\r\n }", "show() {\n strokeWeight(2);\n fill(224, 65, 65);\n rect(this.x, this.y, this.w, this.h);\n\n // if the used job rectangle covers the text with the lane number \n // redraw the same text over everythin \n if (this.x + this.w > 35) {\n strokeWeight(.5);\n fill(0);\n text(`Lane ${this.lane + 1}`, lanes[this.lane].x + (.06 * lanes[this.lane].w), lanes[this.lane].y + (.5 * lanes[this.lane].h) + 3);\n }\n\n\n // Display the amount of space that is remaining in the lane \n strokeWeight(.5);\n fill(0);\n text(`Space Remaining: ${lanes[this.lane].remaining}`, lanes[this.lane].x + (.75 * lanes[this.lane].w), lanes[this.lane].y + (.5 * lanes[this.lane].h) + 3);\n }", "onTutorialDone() {\n this.show();\n this.app.message('The tutorial is always available in the settings menu at the bottom right.',5000)\n }", "display(){\n cl(`${this.name} belongs to the 'ChildClass'`);\n }", "get hud() {\n return canvas.hud.drawing;\n }", "showCard() {\n // console.log(`${this.name} of ${this.suit}`);\n }", "showFixtureClass() {\n }", "function displayAdvice()\n {\n // Calculate error rate (in percent)\n var error = Math.round(my.current.errorRate)\n\n var repeatSubunit = error > 0\n\n // Update remark and advice\n var anchorElement = document.createElement('a')\n if (repeatSubunit) {\n Util.addChildren(my.html.remark, 'Reduce error')\n my.html.remark.title = 'Your error rate should not ' +\n 'exceed 0%.'\n\n Util.addChildren(anchorElement, 'Try again')\n anchorElement.href = '#restart'\n anchorElement.title = 'Please practice this lesson again.'\n } else {\n Util.addChildren(my.html.remark, 'Well done!')\n my.html.remark.title = 'You have satisfactorily ' +\n 'completed this lesson.'\n\n Util.addChildren(anchorElement, 'Next lesson')\n anchorElement.href = '#next'\n anchorElement.title = 'Please proceed with the next lesson.'\n }\n\n // Do not display 'Next lesson' advice if the user is at the\n // last subunit; display advice otherwise\n if (repeatSubunit || !currentSubunitIsTheLastSubunit()) {\n my.html.advice.appendChild(anchorElement)\n anchorElement.focus()\n }\n }", "function displayDifficulty(difficulty) {\n $(\"#difficulty\").html(\"Difficulty: \" + difficulty + \n \" <b class=\\\"caret\\\"></b>\");\n }", "addHintToDisplay () {\n this.createSection([\"div\", \"p\", \"button\"], [\"id\", undefined, \"id\"],\n [\"hint\", \"hint\", \"get-hint\"], 'scoreboard');\n document.querySelector('#hint p')\n .textContent = \"click the button below to trade a heart for a hint\";\n document.querySelector('#hint button').textContent = \"hint\";\n document.getElementById('get-hint').addEventListener('click', this.buyHint)\n }", "function explainPuzzle(){\n\tlet ed = display.explanationDisplay;\n\ted.innerHTML = underground.selected.explanationDisplay();\n}", "display() {\n // game title\n this.canvas[1].font = \"30px Arial\";\n this.canvas[1].fillText('Classic Arcade Game',10,40);\n this.canvas[1].font = \"20px Arial\";\n this.canvas[1].fillText('- build with ECMAScript 6',10,65);\n this.canvas[1].fillText('- Game Engine by Raghavendra Mani',220,this.canvas[0].height-10);\n // game status\n this.canvas[1].font = \"20px Arial\";\n this.canvas[1].fillText('Active Monsters: '+this.activeEnemies.length,this.canvas[0].width*0.6,25);\n this.canvas[1].fillText('Game status: '+this.status(),this.canvas[0].width*0.6,50);\n this.canvas[1].fillText('Moves: '+this.score,this.canvas[0].width*0.6,75);\n this.canvas[1].fillText('Tries: '+this.tries,this.canvas[0].width*0.8,75);\n // game instructions\n this.instructions();\n // warning messages\n this.warning();\n }", "get usage () {\n\t\treturn this._usage;\n\t}", "get usage() {\n\t\treturn this.__usage;\n\t}", "function showHelpUsage() {\n let helpString = \"Hei, olen Relluassari! Yritän auttaa sinua relaatioiden ratkonnassa ;) \\n\" +\n \"<<< Koska olen vielä beta, älä pahastu jos en osaa jotain, tai kaadun kesken kaiken >>> \\n\" +\n \" \\n Miten kutsua minut apuun? \\n \" +\n \" TL;DR? Klikkaa tunnettua -> klikkaa tuntematonta -> klikkaa tuntematonta -> ... -> Repeat \\n\" +\n \" \\nEli miten? \\n\" +\n \" 1) Klikkaa graafista tunnettua sanaa \\n\" +\n \" -> Relluassari tekee Wikipediasta, Bingistä, Wiktionarystä ja Ratkojista lähdehaut ko. sanalla. \\n\" +\n \" 2) Kun haku valmis, klikkaa graafista tunnettuun kytkettyä tuntematonta sanaa \\n\" +\n \" -> Relluassari parsii hakutuloksista klikatun pituiset sanat ja brutettaa rellua niillä. \\n\" +\n \" 3) Kun brutetus valmis, klikkaa seuraavaa tunnettuun kytkettyä tuntematonta \\n\" +\n \" -> Relluassari parsii hakutuloksista klikatun pituiset sanat ja brutettaa rellua niillä. \\n\" +\n \" 4) Valitse uusi tunnettu sana lähteeksi ja siirry kohtaan 1) \\n\" +\n \"\\nAdvanced usage: \\n\" +\n \" Menu>Suorita lähdehaku (teemasana) - tekee lähdehaun vain teemasanalla \\n\" +\n \" Menu>Suorita lähdehaku (oma sana) - tekee lähdehaun syöttämälläsi sanalla/sanoilla (esim. usean sanan hakuun Bingistä) \\n\" +\n \" Menu>Parsi hakutulos sanoiksi - parsii hakutuloksesta *kaikkien* näkyvien tuntemattomien pituiset sanat \\n\" +\n \" Menu>Bruteta sanalista - brutettaa rellua sen hetken muistissa olevalla koko sanalistalla \\n\";\n alert(helpString);\n}", "createDisplay() {\n const { text, fontSize = 36, color = '#000000' } = this.conf;\n this.display = new ProxyObj();\n // this.setAnchor(0.5);\n this.display.text = text;\n this.display.updateStyle({ fontSize, fill: color });\n }", "displayInConsole() {\n console.log(\"{ name: \" + this.name + \", colors: \" + this.colors + \", manaCost: \" + this.manaCost + \", type: \" + this.modifier + \", TCGPlayer price: \" + this.tcgprice + \", Card Kingdom price: \" + this.ckprice);\n }", "function showWhatToExpect() {\n $(\"#start-screen\").hide();\n $(\"#what-to-expect\").show();\n $(\"#tips\").hide();\n $(\"#question-display\").hide();\n $(\"#question-result-display\").hide();\n $(\"#test-result-display\").hide();\n }", "function _display(){\n\t\t\t$(levelID).html(level);\n\t\t\t$(pointsID).html(points);\n\t\t\t$(linesID).html(lines);\n\t\t}", "static get defaultTitle() { return 'Tool'; }", "function help () {\n return `INSTRUCTIONS:\n Blacksmith is a simple text base game. \n \n As a blacksmith you convert ore and wood into swords and axes. You buy your resources using gold and sell your weapons for gold.\n \n COMMANDS:\n - buy(item)\n - make(item)\n - sell(item)\n - fire()\n - inventory()\n - help()`\n }", "get planDisplay() {\n\t\treturn this.__planDisplay;\n\t}", "display() {\n this.supplies.forEach(supply => supply.display());\n }", "updateComponent() {\n this.shadowRoot.getElementById('myuw-help__title').innerHTML = this['myuw-help-title'];\n }", "static help() {\n console.log(\n`Usage: \n\\nversion [ -v semver ] [-p [ 0 => PATCH, 1 => MINOR, 2 => MAJOR ] ]\nE.g version -v 0.2.3 -p 1 ## 0.3.3\n\nversion [ -f file ] [ -d delimeter ]\n `);\n }", "function toggleWithDown() {\r\n if (guideContainer[this.id].style.display === \"block\") {\r\n guideContainer[this.id].style.display = \"none\";\r\n detail[this.id].style.display = \"block\";\r\n } else {\r\n guideContainer[this.id].style.display = \"block\";\r\n detail[this.id].style.display = \"none\";\r\n }\r\n}" ]
[ "0.59519535", "0.5727213", "0.559132", "0.5571523", "0.55665183", "0.5551647", "0.55430514", "0.55373716", "0.55318224", "0.5527445", "0.55033475", "0.55029726", "0.54797006", "0.5464949", "0.5432987", "0.5432799", "0.54291075", "0.5413121", "0.54024214", "0.5394989", "0.53793067", "0.5342624", "0.5322632", "0.5320708", "0.5315983", "0.53125954", "0.5287781", "0.5262568", "0.5252287", "0.5240082", "0.52082956", "0.5205421", "0.5200578", "0.5187916", "0.51855487", "0.5176131", "0.51717204", "0.5163657", "0.5163563", "0.51607984", "0.5158542", "0.5157768", "0.5157266", "0.5129143", "0.51212066", "0.51147884", "0.511469", "0.51139", "0.51139", "0.51139", "0.5101341", "0.5100022", "0.50953496", "0.50871015", "0.508583", "0.50840956", "0.50825214", "0.507963", "0.5077919", "0.50734216", "0.5066138", "0.5062123", "0.505217", "0.5050785", "0.5037262", "0.5031451", "0.50287706", "0.5020687", "0.50146484", "0.50139815", "0.50100315", "0.50083953", "0.50053316", "0.5004219", "0.4990489", "0.49880642", "0.4969107", "0.49687016", "0.49686185", "0.49657014", "0.4958832", "0.4957293", "0.4955801", "0.49522656", "0.49499175", "0.49497578", "0.49463266", "0.4944454", "0.4941795", "0.49391884", "0.4937747", "0.49321043", "0.49311277", "0.49271137", "0.4918826", "0.49170217", "0.49166334", "0.49087006", "0.49084935", "0.49047592" ]
0.8241103
0
Set the target text to be typed. The target text consits of three parts: 1. Prefix 2. Target character 3. Suffix The target character is the character the user should type to move ahead in the subunit. The prefix and the suffix offer some context around the target character to be typed. These three parts combined, in the specified order above, is a substring from the subunit's text from units.js.
function setTargetText() { // The target text should display at least one character var targetLength = Settings.TARGET_TEXT_LENGTH if (targetLength < 1) { targetLength = 1 } // Length of the target text should be odd as equal number of // characters should be displayed on either side of the // character to be typed if (targetLength % 2 == 0) { targetLength-- } // Number of characters on either side of the character to be // typed, assuming that the character to be typed is at the // centre var prefixLength = (targetLength - 1) / 2 // Calculate the start index and the end index of the substring // to be selected from the subunit text to display as the target // text var i = my.current.correctInputLength var textLength = my.current.subunitText.length if (i <= prefixLength) { var startIndex = 0 } else if (i >= textLength - 1 - prefixLength) { var startIndex = textLength - targetLength } else { var startIndex = i - prefixLength } var endIndex = startIndex + targetLength // Select prefix string var s = my.current.subunitText.substring(startIndex, i) my.current.targetPrefix = Util.visual(s) // Select target character if (i < textLength) { s = my.current.subunitText.charAt(i) my.current.targetChar = Util.visual(s) } else { my.current.targetChar = '' } // Select suffix string s = my.current.subunitText.substring(i + 1, endIndex) my.current.targetSuffix = Util.visual(s) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function displayTargetText()\n {\n // Create target character element\n var targetCharElement = document.createElement('span')\n var targetChar = document.createTextNode(my.current.targetChar)\n targetCharElement.className = 'targetChar'\n targetCharElement.appendChild(targetChar)\n\n // Set new target text\n Util.setChildren(my.html.target, my.current.targetPrefix,\n targetCharElement,\n my.current.targetSuffix)\n }", "function typeString($target, index, cursorPosition, callback) {\n // Get text\n var text = settings.text[index];\n // Get placeholder, type next character\n var placeholder = $target.attr('placeholder');\n $target.attr('placeholder', placeholder + text[cursorPosition]);\n // Type next character\n if (cursorPosition < text.length - 1) {\n setTimeout(function () {\n typeString($target, index, cursorPosition + 1, callback);\n }, settings.delay);\n return true;\n }\n // Callback if animation is finished\n callback();\n }", "function setSubunit(m, n)\n {\n my.current.unitNo = m\n my.current.subunitNo = n\n\n my.current.unit = unit(m)\n\n my.current.subunitTitles.length = 0\n for (var subunitTitle in my.current.unit.subunits) {\n my.current.subunitTitles.push(subunitTitle)\n }\n\n var subunitTitle = my.current.subunitTitles[n - 1]\n my.current.subunitText = my.current.unit.subunits[subunitTitle]\n }", "function onTextPost(prefix, target, text)\n{\n text = stripTextDecoration(text);\n\n var cfgCmd = new RegExp('^' + scriptName + '/([^ \\t]+)[ \\t]*(.*)[ \\t]*');\n if (prefix.nick == myNick && text.match(cfgCmd)) {\n cmd = RegExp.$1;\n arg = RegExp.$2.replace(/\\s+/g, ' ').split(' ');\n if (arg.length == 1 && arg[0] == '')\n arg.length = 0;\n scriptCfgCmd(prefix, target, cmd, arg)\n }\n\n if (!chList[target.toLowerCase()])\n return;\n\n if (text.match(/^\\.cl\\s+(.*)/)) {\n if (target == '#TASers') // FIXME: poor hack\n cl(prefix, target, RegExp.$1, 'ja');\n else\n cl(prefix, target, RegExp.$1, 'en');\n }\n}", "wrapText (start, end, prefix, suffix) {\n let replace = this.text.slice(start, end);\n let edit = {\n start,\n end,\n insert: prefix + replace + suffix,\n replace,\n preSelection: this.selection,\n postSelection: {\n start: start + prefix.length,\n end: end + prefix.length,\n isCollapsed: start === end,\n backwards: this.selection.backwards\n }\n };\n this.edit(edit);\n this.editHistory.push(edit);\n this.redoStack = [];\n }", "set text(value) {}", "set text(value) {}", "function setTextInput(text) {\n setText(text);\n }", "function setSelectedText( data )\n{\n /**\n * Source: https://stackoverflow.com/a/11077016/3829526\n */\n\n if( activeInput.selectionStart || activeInput.selectionStart == '0' )\n {\n let startPos = activeInput.selectionStart;\n let endPos = activeInput.selectionEnd;\n\n activeInput.value = activeInput.value.substring( 0, startPos )\n + data\n + activeInput.value.substring( endPos, activeInput.value.length );\n } \n \n else\n activeInput.value += data;\n}", "function setTextId(num) {\n text = num;\n multiphrase = '';\n lastused_phrase = '';\n}", "function typeText(text){\n var chars = text.split('');\n chars.forEach(function(char, index){\n $(settings.el).delay(settings.speed).queue(function (next){\n var text = $(this).html() + char;\n $(this).html(text);\n next();\n\n // we are done, remove from queue\n if(index === chars.length - 1){\n settings.queue = settings.queue - 1;\n $(settings.mainel).trigger('typewriteTyped', text);\n }\n });\n }, this);\n }", "substituteText() {\n const proxyObj = this.display;\n this.display = new Text();\n this.display.substitute(proxyObj);\n }", "function updateText(ev) {\n setText(ev.target.value);\n }", "set setText (text) {\n this.text = text;\n }", "set text(text) {\n\t\tthis._text = text;\n\t}", "updateText(target, text) {\n this.changedFlag();\n\n var targetnotfound = true;\n var i = 0;\n var targets = target.trim().split(' ');\n\n //find which part of the target refers to the element ID\n while (targetnotfound && (i < targets.length)) {\n if (this.elemmap.has(targets[i])) {\n targetnotfound = false;\n } else {\n i++;\n }\n }\n if (targetnotfound) {\n return false;\n }\n \n var id = targets.splice(i, 1)[0];\n\n //store target element index, while also removing element ID from array of targets\n var targindex = this.elemmap.get(id);\n\n\n //use remaining target array to put text change in correct object parameter\n try {\n this.data.elements[targindex][targets[0]] = text;\n } catch {\n return false;\n }\n\n return true;\n\n }", "function type() {\n // Type as long as there are characters left in phrase\n if (char_index <= text[text_index].length) {\n if (!typing) set_typing(true);\n set_typed_text(text[text_index].substring(0, char_index++));\n setTimeout(type, type_delay);\n }\n // Call erase when finished\n else {\n set_typing(false);\n setTimeout(erase, new_delay);\n }\n }", "constructor(_text, _option1, _target1, _option2, _target2) {\n this.text = _text;\n this.option1 = _option1;\n this.target1 = _target1;\n this.option2 = _option2;\n this.target2 = _target2;\n }", "function displayTarget(){\n findTarget();\n if(isPlaying===true){\n $('#target-letter').text(\"'\" + targetLet + \"'\");\n }\n}", "function XSetInputControl(InputId, targetId, WordIdPrefix, punctuation) {\n //alert('Input function');\n var inst = $(InputId).mobiscroll('getInst');//Get instance of the tree control for the page you are switching to\n\n // inst.hide();\n\n //if the setValue function exists\n if (Object.keys(inst).some(function (k) { return ~k.indexOf(\"setValue\") })) {\n\n try {\n inst.setValue(LastSentenceSelections, true); //set values to match the last sentence\n }\n catch (err) {\n alert(err);\n }\n\n }\n //inst.show();//Trigger OnShow Event \n\n //Update Sentence\n DisplaySentence(targetId, WordIdPrefix, punctuation);\n}", "moveThrough(units) {\n this.units = units;\n this.text.text = this.units.toString();\n }", "function selectText(target) {\n const range = document.createRange();\n range.selectNodeContents(target);\n\n const selection = window.getSelection();\n selection.removeAllRanges();\n selection.addRange(range);\n}", "function typing_effect_subfunc(caption,boxed,end,captionLength) {\r\n\taudio_cursor.play();\r\n boxed.html(caption.substr(0, captionLength++));\r\n if(captionLength < caption.length+1 ) {\r\n\t\tsetTimeout(function() {typing_effect_subfunc(caption,boxed,end,captionLength);},100);\r\n //setTimeout('typero(caption,boxed)', 100);\r\n } else if (end==false){\r\n\t\tboxed.html(caption+'<br\\>');\r\n //captionLength = 0;\r\n //caption = '';\r\n\t\t//console.log(\"was here1\");\r\n }\r\n\telse{\r\n\t\t//boxed.html(caption+'<br\\>');\r\n //captionLength = 0;\r\n //caption = '';\r\n\t\t//console.log(\"was here2\");\r\n }\r\n}", "update(text, start, end) {\n this.lineOffsets = undefined;\n const content = this.getText();\n this.setText(content.slice(0, start) + text + content.slice(end));\n }", "text (state, text) {\n state.text = text\n }", "function updateCharCount(target) {\n var length = target.value.length;\n displayMessage(length + \" characters\");\n}", "function changeText() {\n \n }", "insertAtCaret(e, toIns='') {\n let textarea = document.getElementById('editor');\n const posStart = textarea.selectionStart;\n const posEnd = textarea.selectionEnd;\n const text = textarea.value;\n \n textarea.focus();\n //If the previous same length substring is the same as the text to insert, then remove it\n if ( text.substring( posEnd - toIns.length , posEnd) === toIns ) {\n textarea.value = text.substring(0, posEnd - toIns.length) + text.substring(posEnd);\n textarea.setSelectionRange(posStart, posStart);\n }\n //Else insert the string\n else {\n \n textarea.value = `${text.substring(0, posEnd)}${toIns}${text.substring(posEnd)}`;\n \n textarea.setSelectionRange(posEnd, posEnd + toIns.length );\n }\n //Trigger the redux action dispatch\n this.editorTextChange();\n }", "function targetLettersLogged() {\n for (i = 0; i < playingWord.targetWord.length; i++) {\n playingWord.addLetter(playingWord.targetWord[i], false);\n }\n}", "recursivelyUpdateText(target, ab, from, to) {\n if (ab.landwalk == from) {\n ab.landwalk = to;\n ab.modified = true;\n }\n for (let modif of ab.effect.modification.parts) {\n if (modif instanceof AddAbilityModification) {\n let aam = modif;\n this.recursivelyUpdateText(target, aam.addWhat, from, to);\n }\n if (modif instanceof ChangeLandTypeModification) {\n let cltm = modif;\n if (cltm.from == from)\n cltm.from = to;\n if (cltm.to == from)\n cltm.to = to;\n ab.modified = true;\n }\n }\n }", "updateText(text) {\n\t\tthis.text = text;\n\t}", "function replaceInputText( element, text, startPos, endPos ) {\ntext = text || \"\";\nvar value = element.value;\nvar preText = value.substring( 0, startPos );\nvar postText = value.substring( endPos, value.length );\nvar selectionPos = startPos + text.length;\nelement.value = preText + text + postText;\nelement.selectionStart = selectionPos;\nelement.selectionEnd = selectionPos;\n}", "function typeInTextarea(newText) {\n var el = document.querySelector(\"#msgEdit\");\n var start = el.selectionStart\n var end = el.selectionEnd\n var text = el.value\n var before = text.substring(0, start)\n var after = text.substring(end, text.length)\n el.value = (before + newText + after)\n el.selectionStart = el.selectionEnd = start + newText.length\n el.focus()\n }", "function addLetter(newText, callback)\n{\n var curVarName = $(\"#var-name\").html();\n var newVarName = curVarName + newText.substr(curVarName.length, 1);\n $(\"#var-name\").html(newVarName);\n\n if (newVarName.length < newText.length)\n {\n setTimeout(() => \n {\n addLetter(newText, callback);\n }, typeSpeed);\n }\n else\n {\n callback();\n }\n}", "function replaceWithMeasure(text, measureConfig) {\n var measureLocation = measureConfig.measureLocation,\n prefix = measureConfig.prefix,\n targetText = measureConfig.targetText,\n selectionStart = measureConfig.selectionStart,\n split = measureConfig.split; // Before text will append one space if have other text\n\n var beforeMeasureText = text.slice(0, measureLocation);\n\n if (beforeMeasureText[beforeMeasureText.length - split.length] === split) {\n beforeMeasureText = beforeMeasureText.slice(0, beforeMeasureText.length - split.length);\n }\n\n if (beforeMeasureText) {\n beforeMeasureText = \"\".concat(beforeMeasureText).concat(split);\n } // Cut duplicate string with current targetText\n\n\n var restText = reduceText(text.slice(selectionStart), targetText.slice(selectionStart - measureLocation - prefix.length), split);\n\n if (restText.slice(0, split.length) === split) {\n restText = restText.slice(split.length);\n }\n\n var connectedStartText = \"\".concat(beforeMeasureText).concat(prefix).concat(targetText).concat(split);\n return {\n text: \"\".concat(connectedStartText).concat(restText),\n selectionLocation: connectedStartText.length\n };\n}", "function replaceWithMeasure(text, measureConfig) {\n var measureLocation = measureConfig.measureLocation,\n prefix = measureConfig.prefix,\n targetText = measureConfig.targetText,\n selectionStart = measureConfig.selectionStart,\n split = measureConfig.split; // Before text will append one space if have other text\n\n var beforeMeasureText = text.slice(0, measureLocation);\n\n if (beforeMeasureText[beforeMeasureText.length - split.length] === split) {\n beforeMeasureText = beforeMeasureText.slice(0, beforeMeasureText.length - split.length);\n }\n\n if (beforeMeasureText) {\n beforeMeasureText = \"\".concat(beforeMeasureText).concat(split);\n } // Cut duplicate string with current targetText\n\n\n var restText = reduceText(text.slice(selectionStart), targetText.slice(selectionStart - measureLocation - prefix.length), split);\n\n if (restText.slice(0, split.length) === split) {\n restText = restText.slice(split.length);\n }\n\n var connectedStartText = \"\".concat(beforeMeasureText).concat(prefix).concat(targetText).concat(split);\n return {\n text: \"\".concat(connectedStartText).concat(restText),\n selectionLocation: connectedStartText.length\n };\n}", "function replaceWithMeasure(text, measureConfig) {\n var measureLocation = measureConfig.measureLocation,\n prefix = measureConfig.prefix,\n targetText = measureConfig.targetText,\n selectionStart = measureConfig.selectionStart,\n split = measureConfig.split; // Before text will append one space if have other text\n\n var beforeMeasureText = text.slice(0, measureLocation);\n\n if (beforeMeasureText[beforeMeasureText.length - split.length] === split) {\n beforeMeasureText = beforeMeasureText.slice(0, beforeMeasureText.length - split.length);\n }\n\n if (beforeMeasureText) {\n beforeMeasureText = \"\".concat(beforeMeasureText).concat(split);\n } // Cut duplicate string with current targetText\n\n\n var restText = reduceText(text.slice(selectionStart), targetText.slice(selectionStart - measureLocation - prefix.length), split);\n\n if (restText.slice(0, split.length) === split) {\n restText = restText.slice(split.length);\n }\n\n var connectedStartText = \"\".concat(beforeMeasureText).concat(prefix).concat(targetText).concat(split);\n return {\n text: \"\".concat(connectedStartText).concat(restText),\n selectionLocation: connectedStartText.length\n };\n}", "function replaceWithMeasure(text, measureConfig) {\n var measureLocation = measureConfig.measureLocation,\n prefix = measureConfig.prefix,\n targetText = measureConfig.targetText,\n selectionStart = measureConfig.selectionStart,\n split = measureConfig.split; // Before text will append one space if have other text\n\n var beforeMeasureText = text.slice(0, measureLocation);\n\n if (beforeMeasureText[beforeMeasureText.length - split.length] === split) {\n beforeMeasureText = beforeMeasureText.slice(0, beforeMeasureText.length - split.length);\n }\n\n if (beforeMeasureText) {\n beforeMeasureText = \"\".concat(beforeMeasureText).concat(split);\n } // Cut duplicate string with current targetText\n\n\n var restText = reduceText(text.slice(selectionStart), targetText.slice(selectionStart - measureLocation - prefix.length), split);\n\n if (restText.slice(0, split.length) === split) {\n restText = restText.slice(split.length);\n }\n\n var connectedStartText = \"\".concat(beforeMeasureText).concat(prefix).concat(targetText).concat(split);\n return {\n text: \"\".concat(connectedStartText).concat(restText),\n selectionLocation: connectedStartText.length\n };\n}", "function replaceWithMeasure(text, measureConfig) {\n var measureLocation = measureConfig.measureLocation,\n prefix = measureConfig.prefix,\n targetText = measureConfig.targetText,\n selectionStart = measureConfig.selectionStart,\n split = measureConfig.split; // Before text will append one space if have other text\n\n var beforeMeasureText = text.slice(0, measureLocation);\n\n if (beforeMeasureText[beforeMeasureText.length - split.length] === split) {\n beforeMeasureText = beforeMeasureText.slice(0, beforeMeasureText.length - split.length);\n }\n\n if (beforeMeasureText) {\n beforeMeasureText = \"\".concat(beforeMeasureText).concat(split);\n } // Cut duplicate string with current targetText\n\n\n var restText = reduceText(text.slice(selectionStart), targetText.slice(selectionStart - measureLocation - prefix.length), split);\n\n if (restText.slice(0, split.length) === split) {\n restText = restText.slice(split.length);\n }\n\n var connectedStartText = \"\".concat(beforeMeasureText).concat(prefix).concat(targetText).concat(split);\n return {\n text: \"\".concat(connectedStartText).concat(restText),\n selectionLocation: connectedStartText.length\n };\n}", "textChange() {\n core.dxp.log.debug('Inside textChange');\n this.assignPlaceholderText();\n }", "set text (value) {\n\t\tlet textStr = value + '';\n\t\tthis._text = textStr;\n\n\t\t// is there a negative sign magnitude character?\n\t\tlet isSignMagnitude = this._text.indexOf('-') > -ONE;\n\t\tthis.isSignMagnitude = isSignMagnitude;\n\t\tif (isSignMagnitude) {\n\t\t\ttextStr = textStr.replace('-', '');\n\t\t\tthis.signLabel.alpha = ONE;\n\t\t\tthis.glowSignLabel.alpha = ZERO;\n\t\t} else {\n\t\t\tthis.signLabel.alpha = ZERO;\n\t\t}\n\n\t\tconst textNumber = Number(textStr);\n\t\tconst isNumber = !isNaN(textNumber);\n\n\t\t// Number​.prototype​.toLocale​String() https://developer.mozilla.org/es/docs/Web/JavaScript/Referencia/Objetos_globales/Number/toLocaleString\n\t\tconst formatOptions = {};\n\t\tif (isNumber) formatOptions.minimumFractionDigits = numOfDecimals(textStr);\n\t\tconst formatedTextString = isNumber ? textNumber.toLocaleString(this.arena.theme.locale, formatOptions) : textStr;\n\n\t\t// default text\n\t\tthis.textLabel.text = formatedTextString;\n\n\t\t// glow label\n\t\tthis.glowLabel.text = formatedTextString;\n\t\tthis.glowLabel.alpha = ZERO;\n\n\t\t// update positions\n\t\tthis.calculateChildPositions();\n\n\t\tthis.calculateSize();\n\t}", "function singleTouchWord() {\n try {\n var range = document.caretRangeFromPoint(android.selection.lastTouchPoint.x, android.selection.lastTouchPoint.y);\n\n range.expand(\"word\");\n\n var preSelectionRange = range.cloneRange();\n preSelectionRange.selectNodeContents(document.getElementsByTagName('body')[0]);\n preSelectionRange.setEnd(range.startContainer, range.startOffset);\n\n// Get start/end position\n var start = preSelectionRange.toString().length;\n var end = start + range.toString().length;\n\n\n window.TextSelection.onSingleTouchWord(start, end);\n } catch (e) {\n window.TextSelection.jsError(\"Single touch error\\n\" + e);\n }\n}", "function handleTextChange(e) {\n const updatedText = e.target.value\n\n setText(updatedText)\n }", "function createText()\n\t{\n\t\ttextWidget = that.add('text', {\n\t\t\ttype: that.id + '_text',\n\t\t\tid: that.id + '_0',\n\t\t\tx: that.x,\n\t\t\ty: that.y,\n\t\t\tw: that.w,\n\t\t\ttext: that.text,\n\t\t\tfont: style.unitFont,\n\t\t\tcolor: style.sectionTextColor,\n\t\t\thidden: that.hidden,\n\t\t\tcursor: 'pointer',\n\t\t\tdepth: that.depth\n\t\t});\n\n\t\tcurY = that.y + textWidget.height() + style.unitTextGap;\n\t}", "function updateText(event) {\n let vv = event.target.value;\n\n ch_push(vv); // used to be ch_push(Number: vv)});\n\n// setText(vv); COMMENTED OUT FOR CH_PUSH\n }", "function option3(input, output) {\n console.log(\"option3\");\n output.value = 'First name has ' + input.value.indexOf(' ') + ' characters';\n}", "function replaceWithMeasure(text, measureConfig) {\n var measureLocation = measureConfig.measureLocation,\n prefix = measureConfig.prefix,\n targetText = measureConfig.targetText,\n selectionStart = measureConfig.selectionStart,\n split = measureConfig.split;\n // Before text will append one space if have other text\n var beforeMeasureText = text.slice(0, measureLocation);\n if (beforeMeasureText[beforeMeasureText.length - split.length] === split) {\n beforeMeasureText = beforeMeasureText.slice(0, beforeMeasureText.length - split.length);\n }\n if (beforeMeasureText) {\n beforeMeasureText = \"\".concat(beforeMeasureText).concat(split);\n }\n // Cut duplicate string with current targetText\n var restText = reduceText(text.slice(selectionStart), targetText.slice(selectionStart - measureLocation - prefix.length), split);\n if (restText.slice(0, split.length) === split) {\n restText = restText.slice(split.length);\n }\n var connectedStartText = \"\".concat(beforeMeasureText).concat(prefix).concat(targetText).concat(split);\n return {\n text: \"\".concat(connectedStartText).concat(restText),\n selectionLocation: connectedStartText.length\n };\n}", "function doneTyping () {\nvar content = document.getElementById(\"first\");\ncontent.textContent += \"and I am from\";\ncontent.innerHTML += \"&nbsp;\"\n\n\n\nconsole.log(\"im typinggggg\");\nvar newSpan = document.createElement('span');\ndocument.getElementById('first').appendChild(newSpan);\nnewSpan.contentEditable =\"true\";\nnewSpan.setAttribute(\"contenteditable\" , \"true\");\nnewSpan.setAttribute(\"id\", \"edit2\");\nnewSpan.onkeyup = myListener;\n}", "function displayText(recognized) {\n document.querySelector('#mytext').setAttribute('value', recognized);\n}", "function speak() {\n\n var defaultTxt = \"When you have arrived at your destination, double tap the middle of your screen.\"; \n var inputTxt = defaultTxt + getCurrDirection();\n audio(inputTxt);\n\n}", "function insertCompletionText(state$1, text, from, to) {\n let { main } = state$1.selection, fromOff = from - main.from, toOff = to - main.from;\n return Object.assign(Object.assign({}, state$1.changeByRange(range => {\n if (range != main && from != to &&\n state$1.sliceDoc(range.from + fromOff, range.from + toOff) != state$1.sliceDoc(from, to))\n return { range };\n return {\n changes: { from: range.from + fromOff, to: to == main.from ? range.to : range.from + toOff, insert: text },\n range: state.EditorSelection.cursor(range.from + fromOff + text.length)\n };\n })), { userEvent: \"input.complete\" });\n}", "function testy(){\n\n document.getElementById('word1').value = 'fast';\n document.getElementById('word2').value = 'memory';\n document.getElementById('number').value = 511;\n\n}", "function guied_insert_wikitext_tag(txtarea, tagOpen, tagClose, sampleText)\n{\n\t// IE\n\tif (document.selection && !is_gecko) {\n\t\tvar theSelection = document.selection.createRange().text;\n\t\tif (!theSelection)\n\t\t\ttheSelection=sampleText;\n\t\ttxtarea.focus();\n\t\tif (theSelection.charAt(theSelection.length - 1) == \" \") { // exclude ending space char, if any\n\t\t\ttheSelection = theSelection.substring(0, theSelection.length - 1);\n\t\t\tdocument.selection.createRange().text = tagOpen + theSelection + tagClose + \" \";\n\t\t} else {\n\t\t\tdocument.selection.createRange().text = tagOpen + theSelection + tagClose;\n\t\t}\n\n\t// Mozilla\n\t} else if(txtarea.selectionStart || txtarea.selectionStart == '0') {\n\t\tvar replaced = false;\n\t\tvar startPos = txtarea.selectionStart;\n\t\tvar endPos = txtarea.selectionEnd;\n\t\tif (endPos-startPos)\n\t\t\treplaced = true;\n\t\tvar scrollTop = txtarea.scrollTop;\n\t\tvar myText = (txtarea.value).substring(startPos, endPos);\n\t\tif (!myText)\n\t\t\tmyText=sampleText;\n\t\tif (myText.charAt(myText.length - 1) == \" \") { // exclude ending space char, if any\n\t\t\tsubst = tagOpen + myText.substring(0, (myText.length - 1)) + tagClose + \" \";\n\t\t} else {\n\t\t\tsubst = tagOpen + myText + tagClose;\n\t\t}\n\t\ttxtarea.value = txtarea.value.substring(0, startPos) + subst +\n\t\t\ttxtarea.value.substring(endPos, txtarea.value.length);\n\t\ttxtarea.focus();\n\t\t//set new selection\n\t\tif (replaced) {\n\t\t\tvar cPos = startPos+(tagOpen.length+myText.length+tagClose.length);\n\t\t\ttxtarea.selectionStart = cPos;\n\t\t\ttxtarea.selectionEnd = cPos;\n\t\t} else {\n\t\t\ttxtarea.selectionStart = startPos+tagOpen.length;\n\t\t\ttxtarea.selectionEnd = startPos+tagOpen.length+myText.length;\n\t\t}\n\t\ttxtarea.scrollTop = scrollTop;\n\n\t// All other browsers get no toolbar.\n\t}\n\t// reposition cursor if possible\n\tif (txtarea.createTextRange)\n\t\ttxtarea.caretPos = document.selection.createRange().duplicate();\n}", "function changeTyped(text1,text2) {\n\ttyped.destroy();\n\t\ttyped = new Typed(\".typed\", {\n\t\tstrings: [text1, text2],\n\t\ttypeSpeed: 70,\n\t\tloop: true,\n\t\tstartDelay: 1000,\n\t\tshowCursor: false\n\t});\n}", "function Target(elt, symbols){\n\tvar _HTMLElt = elt;\n\tvar _caret = new Caret();\n\tvar _diffChar;\n\tvar _symbols = symbols;\n\tvar _typed;\n\n\tthis.node = elt;\n\n\tthis.insertSymbols = function insertSymbols(){\n\n\t\tvar newText = this.getValue();\n\n\t\tfor(var key in _symbols){\n\t\t\tvar symbol = _symbols[key];\n\n\t\t\tnewText = this.insertSymbol(newText, symbol);\n\n\t\t\tif(symbol.matched){\n\t\t\t\t_diffChar = symbol.textInserted.length - symbol.typed.length;\n\t\t\t\t_typed = symbol.typed;\n\t\t\t\tthis.setValue(newText);\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t};\n\n\tthis.insertSymbol = function insertSymbol(text, symbol){\n\t\tvar newText = text;\n\n\t\tvar plainText = utils.convertToText(text);\n\n\t\tvar pattern = '([^\\\\\\\\]|^)'+'('+symbol.pattern+')';\n\n\t\tvar regexp = new RegExp(pattern);\n\n\t\tvar replacedMatched = regexp.exec(newText);\n\n\t\tsymbol.typed = '';\n\n\t\tif(replacedMatched){\n\t\t\tsymbol.typed = utils.convertToText(replacedMatched[2]);\n\t\t}\n\n\t\tsymbol.matched = false;\n\n\t\t//replace replaced with symbol\n\t\tif(typeof symbol.limit == 'number'){\n\t\t\tvar count = this.getSymbolCount(symbol);\n\n\t\t\t//if unescaped replaced chars are present but not replaced by their symbol\n\t\t\t//they will be replaced by their symbol until limit is reached\n\t\t\twhile(count.unreplacedCount > 0 && count.symbolCount < symbol.limit){\n\t\t\t\tnewText = newText.replace(regexp, '$1'+symbol.inserted);\n\t\t\t\tcount = this.getSymbolCount(symbol, newText);\n\t\t\t\tsymbol.matched = true;\n\t\t\t}\n\n\t\t}else{\n\t\t\tsymbol.matched = regexp.test(newText);\n\t\t\tnewText = newText.replace(regexp, '$1'+symbol.inserted);\n\t\t}\n\n\t\treturn newText;\n\t};\n\n\tthis.getSymbolCount = function getSymbolCount(symbol, txt){\n\t\t//in this function we deal only with plain text to avoid evaluating tags when counting symbols\n\t\tvar res = {};\n\t\tvar text = utils.convertToText(txt || this.getValue());\n\n\t\tvar rawEncodedHtml = encodeURIComponent(text);\n\t\t//get escaped replaced chars to exclude them from unreplaced count\n\t\tvar pattern = '\\\\\\\\'+utils.convertToText(symbol.pattern);\n\t\tvar regexp = new RegExp(pattern, 'g');\n\n\t\tres.symbolCount = utils.getCountChar(symbol.encoded, rawEncodedHtml);\n\t\t//symbol.replaced is plain text chars\n\t\tres.unreplacedCount = utils.getCountChar(symbol.replaced, text.replace(regexp, ''));\n\t\tres.symbol = symbol.key;\n\n\t\treturn res;\n\t};\n\n\t//gets the count of symbols, and text entered in target\n\tthis.getStatus = function getStatus(){\n\t\tvar text = this.getValue();\n\t\tvar res = { count : {}};\n\t\tvar rawEncodedHtml = encodeURIComponent(text);\n\t\tvar resText = '';\n\n\t\tfor(var key in _symbols){\n\t\t\tvar symbol = _symbols[key];\n\t\t\tvar symbolPattern = '('+symbol.encoded+')';\n\t\t\tvar escapedPattern = '(\\\\\\\\)('+symbol.pattern+')';\n\t\t\tvar regexpEscaped = new RegExp(escapedPattern, 'g');\n\t\t\tvar regexpSymbol = new RegExp(symbolPattern, 'g');\n\n\t\t\tres.count[key] = utils.getCountChar(symbol.encoded, rawEncodedHtml);\n\n\t\t\trawEncodedHtml = rawEncodedHtml.replace(regexpSymbol, '');\n\n\t\t\tresText = utils.htmlTrim(decodeURIComponent(rawEncodedHtml));\n\n\t\t\tresText = resText.replace(regexpEscaped, '$2');\n\n\t\t\trawEncodedHtml = encodeURIComponent(resText);\n\t\t}\n\n\t\tres.rawText = utils.convertToText(resText);\n\t\tres.fullText = utils.convertToText(text);\n\t\tres.targetId = this.node.id;\n\n\t\treturn res;\n\t};\n\n\tthis.setValue = function setValue(text){\n\t\t//this gets executed only when a symbol was matched and needs to be inserted\n\t\tvar caretPos = _caret.getPosition(_HTMLElt);\n\t\t//position of the typed chars to be replaced in the endcontainer the caret will be repositioned in\n\t\tvar typedIndex = caretPos.textContainer.indexOf(_typed);\n\t\t//caretPos.value <= typedIndex when you delete and unreplaced chars have to be replaced forward\n\t\t//when we delete, it always counts as 1 char = 1 symbol\n\t\t//when you insert caretPos.value > typedIndex\n\t\tvar pos = caretPos.value > typedIndex ? caretPos.value + _diffChar : caretPos.value;\n\n\t\tif(this.isContentEditable){\n\t\t\t_HTMLElt.innerHTML = text;\n\t\t}else{\n\t\t\t_HTMLElt.value = text;\n\t\t}\n\n\t\t_caret.setPosition(pos, caretPos.path);\n\t};\n\n\tthis.getValue = function getValue(){\n\t\tif(this.isContentEditable){\n\t\t\treturn _HTMLElt.innerHTML;\n\t\t}else{\n\t\t\treturn _HTMLElt.value;\n\t\t}\n\t};\n\n\tthis.isContentEditable = utils.isContentEditable(_HTMLElt);\n\n}", "function setText(txtId, text) {\n var txt = getTextById(txtId);\n txt.text = text;\n}", "nameChange(event) {\n /*console.log(event); in the console open event ->target->validity->value*/\n this.text = event.target.value;\n //console.log(this.textChange);\n this.text = this.text.replace(/i/g, \"!\");\n this.text = this.text.replace(/s/g, \"$\");\n this.text = this.text.replace(/a/g, \"@\");\n }", "setProgram(basicProgram) {\n const parts = [];\n for (const element of basicProgram.elements) {\n if (element.elementType === trs80_base_1.ElementType.LINE_NUMBER && parts.length > 0) {\n parts.push(\"\\n\");\n }\n // Convert to the font we're using.\n parts.push(element.asAnotherMansTreasure());\n }\n const fullText = parts.join(\"\");\n if (fullText !== this.textarea.value) {\n // Try to keep the selection where it is.\n const selectionStart = this.textarea.selectionStart;\n const selectionEnd = this.textarea.selectionEnd;\n this.textarea.value = fullText;\n this.textarea.selectionStart = selectionStart;\n this.textarea.selectionEnd = selectionEnd;\n }\n }", "function addSubTextNode(element, word, additionalClass) {\n if (element === undefined || word === undefined) {\n return;\n }\n element\n .append('tspan')\n .attr('class', additionalClass)\n .classed('text', true)\n .classed('subtext', true)\n .attr('x', 0)\n .attr('y', function() {\n return (element.property('childNodes').length - 1) * SPACE_BETWEEN_SPANS;\n })\n .text(word);\n }", "SetText(str)\n\t{\n\t\tthis.textContent = str;\n\t}", "termChanged({ currentTarget: t }) {\n this.setState({ term: t.value });\n }", "async sGetTxt ({ sourceName, sourceUnit }) {\n const key = `${sourceName}|||${sourceUnit}`\n let value = await txtController.getTxt(key)\n\n if (!value) {\n value = {\n key,\n sourceName,\n sourceUnit,\n name: sourceName.split('(')[0].trim(),\n unit: sourceUnit,\n ratio: 1,\n choose: true\n }\n\n await txtController.setTxt(key, value)\n }\n\n return value\n }", "function setText(name, textX, textY, value, color, fontSize) {\n var text = new createjs.Text(value, \"bold \" + fontSize + \"em Tahoma, Geneva, sans-serif\", color);\n text.x = textX;\n text.y = textY;\n text.textBaseline = \"alphabetic\";\n text.name = name;\n text.text = value;\n text.color = color;\n\t/** Adding text to the stage */\n compound_pendulam_stage.addChild(text); \n}", "function onTextChange() {\n displayText = textEl.value;\n}", "_setText(text) {\n // Reset the dialog\n if (this.text) this.text.destroy();\n\n const x = this.padding + 10;\n const y = this._getGameHeight() - this.windowHeight - this.padding + 10;\n\n this.text = this.scene.make.text({\n x,\n y,\n text,\n style: {\n wordWrap: { width: this._getGameWidth() - (this.padding * 2) - 25 }\n }\n });\n }", "function typeText(id, text) {\n if (i < text.length) {\n document.getElementById(id).innerHTML += text.charAt(i);\n i++;\n setTimeout(typeText.bind(null, id, text), speed);\n }\n}", "setTextParts(result, textParts) {\n return textParts.prefix + result + textParts.suffix;\n }", "function up(text) {\n var x = text;\n x.value = x.value.toUpperCase();\n}", "function editText(tweetText) {\n const parent = tweetText.parentElement;\n tweet1.value = parent.textContent.slice(0, -11);\n updateChar();\n parent.remove();\n}", "function setText(name, textX, textY, value, color, fontSize) {\n var _text = new createjs.Text(value, \"bold \" + fontSize + \"em Tahoma, Geneva, sans-serif\", color);\n _text.x = textX;\n _text.y = textY;\n _text.textBaseline = \"alphabetic\";\n _text.name = name;\n _text.text = value;\n _text.color = color;\n\tif ( name==\"voltmeter_txt\" || name==\"ammeter_txt\" ) {\n\t\t_text.font = \"2em digiface\";\n\t}\n electrogravimetric_stage.addChild(_text); /** Adding text to the stage */\n}", "function setText(name, textX, textY, value, color, fontSize, container){\n var text = new createjs.Text(value, + fontSize + \"em Tahoma, Geneva, sans-serif\", color);\n text.x = textX;\n text.y = textY;\n text.textBaseline = \"alphabetic\";\n text.name = name;\n text.text = value;\n text.color = color;\n stage.addChild(thread_anim_rect);\n container.addChild(text); /** Adding text to the container */\n stage.update();\n}", "onCreateText(e) {\n e.preventDefault()\n\n let newSel;\n this.transaction(function(tx) {\n let container = tx.get(this.props.containerId)\n let textType = tx.getSchema().getDefaultTextType()\n let node = tx.create({\n id: uuid(textType),\n type: textType,\n content: ''\n })\n container.show(node.id)\n\n newSel = tx.createSelection({\n type: 'property',\n path: [ node.id, 'content'],\n startOffset: 0,\n endOffset: 0\n })\n }.bind(this))\n this.rerender()\n this.setSelection(newSel)\n }", "function charByChar(text, index, target, isComment){\t\n\tvar periodAddition = 0;\n\tif (index < text.length){\n\t\tcurrChar = text[index];\n\t\tif (currChar == '&'){\n\t\t\tcurrChar = '&nbsp;';\n\t\t}\n\t\tif (currChar == openValue){ \n\t\t\ttarget = colonCase(currChar, target);\n\t\t}\n\t\t$(target).append(currChar);\n\n\t\tif (currChar == closeValue){\n\t\t\ttarget = targetBuff;\n\t\t}\n\t\tif (isComment && (currChar == '.' || currChar == '!')){\n\t\t\tperiodAddition = interval * periodStopMultiply;\n\t\t}\n\t\tindex++;\n\t}\n\t\ttotalInterval = interval + periodAddition;\n\t\tsetTimeout(function(){charByChar(text, index, target, isComment);}, totalInterval);\n\t\tmultiplier = 1;\n}", "function typo(font, size, message, startX, startY){\n fill(200, 0, 200);\n // here we set the font as whatever font is passed through the function as a parameter\n textFont(font);\n // here we set the size as whatever font is passed through the function as a parameter\n textSize(size);\n // use the alingn fuction to adjust where the text is drawn\n textAlign(RIGHT);\n // here we set the font as whatever message, and starting coordinates are passed through the function as a parameter\n text(message, startX, startY);\n}", "function setText(name, textX, textY, value, color, fontSize, container){\n var text = new createjs.Text(value, \"bold \" + fontSize + \"em Tahoma, Geneva, sans-serif\", color);\n text.x = textX;\n text.y = textY;\n text.textBaseline = \"alphabetic\";\n text.name = name;\n text.text = value;\n text.color = color;\n container.addChild(text); /** Adding text to the container */\n stage.update();\n}", "function setText(name, textX, textY, value, color, fontSize, container){\n var text = new createjs.Text(value, \"bold \" + fontSize + \"em Tahoma, Geneva, sans-serif\", color);\n text.x = textX;\n text.y = textY;\n text.textBaseline = \"alphabetic\";\n text.name = name;\n text.text = value;\n text.color = color;\n container.addChild(text); /** Adding text to the container */\n stage.update();\n}", "function setText(name, textX, textY, value, color, fontSize, container){\n var text = new createjs.Text(value, \"bold \" + fontSize + \"em Tahoma, Geneva, sans-serif\", color);\n text.x = textX;\n text.y = textY;\n text.textBaseline = \"alphabetic\";\n text.name = name;\n text.text = value;\n text.color = color;\n container.addChild(text); /** Adding text to the container */\n stage.update();\n}", "function startGame(){\n runTyping(\"Immer einmal mehr wie du...\");\n inputTextElement.value ='sag was'; \n}", "function merge(targetText, inputChangeset){\n var inputCharBank = '';\n var inputCharBankIndex = 0;\n var inputInitialLength;\n var outputText = '';\n var targetIndex = 0;\n var instructionList = [];\n\n extractOperationSet(inputChangeset,instructionList);\n inputInitialLength = extractNumber(instructionList.shift());\n instructionList.shift();\n\n inputCharBank = instructionList.pop();\n if(inputCharBank.length > 1){\n inputCharBank = inputCharBank.slice(1);\n }\n\n while(instructionList.length>0){\n\n if(instructionList[0][0] === '='){\n var startIndex = targetIndex;\n targetIndex += extractNumber(instructionList.shift());\n\n outputText += targetText.slice(startIndex,targetIndex);\n }\n else if(instructionList[0][0] === '-'){\n targetIndex += extractNumber(instructionList.shift());\n }\n else if(instructionList[0][0] === '+'){\n var startIndex = inputCharBankIndex;\n inputCharBankIndex += extractNumber(instructionList.shift());\n outputText += inputCharBank.slice(startIndex,inputCharBankIndex);\n }\n }\n\n return outputText;\n }", "function setElementSelection(that, start, end) {\n if (that.selectionStart === undefined) {\n that.focus();\n var r = that.createTextRange();\n r.collapse(true);\n r.moveEnd('character', end);\n r.moveStart('character', start);\n r.select();\n } else {\n that.selectionStart = start;\n that.selectionEnd = end;\n }\n }", "function setElementSelection(that, start, end) {\n if (that.selectionStart === undefined) {\n that.focus();\n var r = that.createTextRange();\n r.collapse(true);\n r.moveEnd('character', end);\n r.moveStart('character', start);\n r.select();\n } else {\n that.selectionStart = start;\n that.selectionEnd = end;\n }\n }", "function setElementSelection(that, start, end) {\n if (that.selectionStart === undefined) {\n that.focus();\n var r = that.createTextRange();\n r.collapse(true);\n r.moveEnd('character', end);\n r.moveStart('character', start);\n r.select();\n } else {\n that.selectionStart = start;\n that.selectionEnd = end;\n }\n }", "function type(element, text) {\n [...text].forEach(x => {\n act(() => {\n userEvent.type(element, x);\n });\n });\n}", "function setNewText(newText){\n\twordCounter = 0;\n\tcharCounter = 0;\n\ttxt = newText.trim().split(\" \");\n\n}", "function showNewText(text) {\n firstText.innerHTML = `${text}`;\n gsap.to(\".m402-text-relative\", {\n duration: 0.3,\n opacity: 1\n });\n}", "function showNewText(text) {\n firstText.innerHTML = `${text}`;\n gsap.to(\".m402-text-relative\", {\n duration: 0.3,\n opacity: 1\n });\n}", "setText(newTextContent) {\n this.textContent = newTextContent;\n }", "function option4(input, output) {\n console.log(\"option4\");\n output.value = 'The middle name is ' + input.value.substring(input.value.indexOf(' '), input.value.lastIndexOf(' ')) + ', starts at ' + (input.value.indexOf(' ')+1) + ' and ends at ' + (input.value.lastIndexOf(' ')-1);\n}", "function targetWithPos(pos) {\n return [\n {\n selector: [{ type: 'TextPositionSelector', start: pos }],\n },\n ];\n }", "function addPrefixSuffix() {\n let text = $( \"#inputText\" ).val().trim().split( \"\\n\" ); //The input text\n let replace = $( \"#replace\" ).val(); //The text it will be replaced with\n let option = $( \"#prefixSuffix\" ).val() //To find out what user has selected. Prefix or Suffix\n let replacedText = []; //Array for the final Result\n let regString = \"\"; //Initializing variable for Regex string\n\n //If statement to check if we need to add suffix or prefix. Then regex string is defined accordingly\n if ( option === \"prefix\" ) {\n regString = /^/g; //Regex string for Prefix\n } else if ( option === \"suffix\" ) {\n regString = /$/g; //Regex string for the Suffix\n }\n\n //For loop to add Prefix and Suffix depending on the above if statement. \n for ( let i = 0; i < text.length; i++ ) {\n replacedText.push( text[ i ].replace( regString, replace ) );\n }\n\n //Converts the array back to string with line breaks. It is needed for the output.\n replacedText = replacedText.join( \"\\n\" );\n\n $( \"#inputLabel\" ).html( \"Output:\" ); //Label changed from Input to Output\n $( \"#inputText\" ).val( replacedText ); //Printing out the results in the same box.\n}", "function addTextToField(elem, text) {\r\n if (elem.selectionStart || elem.selectionStart === 0) {\r\n var startPos = elem.selectionStart;\r\n var endPos = elem.selectionEnd;\r\n elem.value = elem.value.substring(0, startPos)\r\n + text\r\n + elem.value.substring(endPos, elem.value.length);\r\n } else {\r\n elem.value += text;\r\n }\r\n }", "function handleText() {\n if (index < text.length) {\n id(\"output\").innerText = \"\";\n let curWord = text[index];\n id(\"output\").innerText = curWord;\n index++;\n } else {\n endGame();\n }\n }", "function UnbInsertText(what, replace)\r\n{\r\n\tif (replace == null) replace = 0;\r\n\t\r\n// changes for pragmaMx\r\n\tif (openerdoc) {\r\n\t\tcurdoc = openerdoc;\r\n\t} else {\r\n\t\tcurdoc = document;\r\n\t}\r\n// end changes for pragmaMx\r\n\r\n\tif (textbox.createTextRange)\r\n\t{\r\n\t\ttextbox.focus();\r\n\t\tcurdoc.selection.createRange().duplicate().text = what;\r\n\t\ttextbox.focus();\r\n\t}\r\n\telse if (textbox.selectionStart >= 0)\r\n\t{\r\n\t\t// Mozilla without selected text\r\n\t\tvar start_selection = textbox.selectionStart;\r\n\t\tvar end_selection = textbox.selectionEnd;\r\n\t\tvar scroll_top = textbox.scrollTop;\r\n\t\tvar scroll_left = textbox.scrollLeft;\r\n\r\n\t\t// fetch everything from start of text area to selection start\r\n\t\tvar start = textbox.value.substring(0, start_selection - replace);\r\n\t\t// fetch everything from end of selection to end of text area\r\n\t\tvar end = textbox.value.substring(end_selection, textbox.textLength);\r\n\r\n\t\ttextbox.value = start + what + end;\r\n\r\n\t\ttextbox.selectionStart = textbox.selectionEnd = start_selection - replace + what.length;\r\n\t\ttextbox.focus();\r\n\t\ttextbox.scrollTop = scroll_top;\r\n\t\ttextbox.scrollLeft = scroll_left;\r\n\t}\r\n\telse\r\n\t{\r\n\t\ttextbox.value += what;\r\n\t\ttextbox.focus();\r\n\t}\r\n// changes for pragmaMx\r\n\tif (openerdoc) {\r\n\t\twindow.focus();\r\n\t}\r\n// end changes for pragmaMx\r\n}", "function changeMemeText(elInput) {\n var idxStr = elInput.id;\n var width = getCanvasWidth();\n var idx = getIdxFromStr(idxStr);\n gMeme.txts[idx].line = elInput.value;\n\n renderMeme(gMeme);\n}", "function addChar(event, char, dest) {\n\n var destElement, text, textBefore, textAfter, selectionStart, selectionEnd, textBox;\n\n // convert to uppercase\n if (event.shiftKey) char = char.toUpperCase();\n\n destElement = $(\"#\" + dest);\n textBox = destElement[0];\n text = destElement.val();\n\n // Get caret/selection\n selectionStart = textBox.selectionStart;\n selectionEnd = textBox.selectionEnd;\n\n textBefore = text.substring(0, selectionStart);\n textAfter = text.substring(selectionEnd);\n text = textBefore + char + textAfter;\n destElement.val(text);\n\n // Set caret to previous position + 1\n textBox.selectionStart = selectionStart + 1;\n textBox.selectionEnd = selectionStart + 1;\n\n // Return focus to element\n destElement.focus();\n}", "SetValue(str)\n\t{\n\t\tthis._componentText.SetValue(str);\n\t}", "function OAndOuKarModification(field, CH1, CH2)\r\n{\r\n\tif (document.selection) \r\n\t{\r\n\t\tfield.focus();\r\n\t\tsel = document.selection.createRange();\r\n\t\tif (field.value.length >= 1)\r\n\t\t\tsel.moveStart('character', -1); \r\n\t\tif(sel.text.charAt(0) == 'ে')\r\n\t\t\tsel.text = CH1;\r\n\t\telse\r\n\t\t\tsel.text = sel.text.charAt(0) + CH2;\r\n\t\tsel.collapse(true);\r\n\t\tsel.select();\r\n\t}\r\n\telse if (field.selectionStart || field.selectionStart == 0)\r\n\t{\r\n\t\tvar startPos = field.selectionStart-1;\r\n\t\tvar endPos = field.selectionEnd;\r\n\t\tvar scrollTop = field.scrollTop;\r\n\t\tvar CH;\r\n\t\tstartPos = (startPos == -1 ? field.value.length : startPos );\r\n\t\tif(field.value.substring(startPos, startPos+1) == \"ে\")\r\n\t\t\tCH = CH1;\r\n\t\telse\r\n\t\t{\r\n\t\t\tstartPos=startPos+1;\r\n\t\t\tCH = CH2;\r\n\t\t}\r\n\t\tfield.value = field.value.substring(0, startPos)\r\n\t\t\t+ CH\r\n\t\t\t+ field.value.substring(endPos, field.value.length);\r\n\t\tfield.focus();\r\n\t\tfield.selectionStart = startPos + CH.length;\r\n\t\tfield.selectionEnd = startPos + CH.length;\r\n\t\tfield.scrollTop = scrollTop;\r\n\t}\r\n\r\n}", "function updateText(elementID, text){\n \n}", "function drawTypo (obj, string1, string2, string3) {\n \n // Creates an array of numbers to modify y position with, to simulate floating\n let floatValueArray = [0, 0, -1, -1, -2, -2, -3, -4, -5, -5, -4, -3, -2, -2, -1, -1]\n \n // Passes the current index value to the modifier variable\n let floatValue = floatValueArray[obj.textFrameIndex]\n \n // Set font/size\n ctx.font = '20px Fredoka One'\n \n // Get total width of the text, so that the text can be centered above the object generating it\n let textLength = ctx.measureText(string1).width + ctx.measureText(string2).width + ctx.measureText(string3).width\n \n // Find the center of the total width\n let textCenter = (obj.x+(obj.width/2)) - (textLength/2)\n \n // Draw first half of the sentence\n drawStrokeText(string1, textCenter, obj.y - 3 + floatValue, 'white', 'Fredoka One', 20, 'left')\n drawFillText(string1, textCenter, obj.y - 5 + floatValue, 'grey', 'Fredoka One', 20, 'left')\n \n // Draw typo in the sentence\n drawStrokeText(string2, textCenter + ctx.measureText(string1).width, obj.y - 3 + floatValue, 'white', 'Fredoka One', 20, 'left')\n drawFillText(string2, textCenter + ctx.measureText(string1).width, obj.y - 5 + floatValue, 'hotpink', 'Fredoka One', 20, 'left')\n \n // Draw second half of the sentence\n drawStrokeText(string3, textCenter + ctx.measureText(string1).width + ctx.measureText(string2).width, obj.y - 5 + floatValue, 'white', 'Fredoka One', 20, 'left')\n drawFillText(string3, textCenter + ctx.measureText(string1).width + ctx.measureText(string2).width, obj.y - 5 + floatValue, 'grey', 'Fredoka One', 20, 'left')\n \n // Increment float array index, so as to move the text into the next position when it is drawn\n obj.textFrameIndex++\n \n // Reset the index if it has reached the end of the array\n if (obj.textFrameIndex === floatValueArray.length) {obj.textFrameIndex = 0}\n}", "function showText(txt) {\n labelText = txt;\n}" ]
[ "0.60048664", "0.5775657", "0.56695825", "0.56505764", "0.55948794", "0.5434984", "0.5434984", "0.5361348", "0.5334576", "0.52660495", "0.518258", "0.5154124", "0.51522535", "0.51208586", "0.51101273", "0.5055028", "0.5045333", "0.50254977", "0.5013132", "0.5006947", "0.49945083", "0.49866375", "0.49791938", "0.4977379", "0.49736243", "0.49437115", "0.49388146", "0.4928043", "0.49188653", "0.49185315", "0.49175507", "0.49167898", "0.49039027", "0.48995236", "0.4888817", "0.4888817", "0.4888817", "0.4888817", "0.4888817", "0.48887652", "0.48718125", "0.48609564", "0.48576152", "0.4855353", "0.48345786", "0.48278388", "0.48272735", "0.48122033", "0.48070973", "0.4787847", "0.4774797", "0.4773486", "0.4770419", "0.4757915", "0.4751571", "0.47465515", "0.4744407", "0.47427735", "0.47418854", "0.47411162", "0.47341722", "0.47293228", "0.47236782", "0.4721956", "0.47190014", "0.4718537", "0.47136685", "0.4703135", "0.4698953", "0.46915", "0.46831933", "0.46824738", "0.46824226", "0.46792752", "0.46717912", "0.46717912", "0.46717912", "0.46642894", "0.46586558", "0.46546888", "0.46546888", "0.46546888", "0.4649298", "0.46478817", "0.46461764", "0.46461764", "0.46456888", "0.46414572", "0.46395543", "0.4626501", "0.46246696", "0.46238506", "0.46196437", "0.46189478", "0.46188313", "0.46172404", "0.46091017", "0.46081558", "0.4602512", "0.4592257" ]
0.83831364
0
Display the current target text
function displayTargetText() { // Create target character element var targetCharElement = document.createElement('span') var targetChar = document.createTextNode(my.current.targetChar) targetCharElement.className = 'targetChar' targetCharElement.appendChild(targetChar) // Set new target text Util.setChildren(my.html.target, my.current.targetPrefix, targetCharElement, my.current.targetSuffix) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function displayTarget(){\n findTarget();\n if(isPlaying===true){\n $('#target-letter').text(\"'\" + targetLet + \"'\");\n }\n}", "function setTargetText() {\n\n // The target text should display at least one character\n var targetLength = Settings.TARGET_TEXT_LENGTH\n if (targetLength < 1) {\n targetLength = 1\n }\n\n // Length of the target text should be odd as equal number of\n // characters should be displayed on either side of the\n // character to be typed\n if (targetLength % 2 == 0) {\n targetLength--\n }\n\n // Number of characters on either side of the character to be\n // typed, assuming that the character to be typed is at the\n // centre\n var prefixLength = (targetLength - 1) / 2\n\n // Calculate the start index and the end index of the substring\n // to be selected from the subunit text to display as the target\n // text\n var i = my.current.correctInputLength\n var textLength = my.current.subunitText.length\n if (i <= prefixLength) {\n var startIndex = 0\n } else if (i >= textLength - 1 - prefixLength) {\n var startIndex = textLength - targetLength\n } else {\n var startIndex = i - prefixLength\n }\n var endIndex = startIndex + targetLength\n\n // Select prefix string\n var s = my.current.subunitText.substring(startIndex, i)\n my.current.targetPrefix = Util.visual(s)\n\n // Select target character\n if (i < textLength) {\n s = my.current.subunitText.charAt(i)\n my.current.targetChar = Util.visual(s)\n } else {\n my.current.targetChar = ''\n }\n\n // Select suffix string\n s = my.current.subunitText.substring(i + 1, endIndex)\n my.current.targetSuffix = Util.visual(s)\n }", "function showCurrentText() {\n\tunselectAll();\n\thideAll();\n\tshowAllHeaders();\n\t$(\"#pano\" + currentpanonum).addClass('selected').children().show(5,scrollTo(currentpanonum));\n}", "set targetDisplay(value) {}", "function showText(txt) {\n labelText = txt;\n}", "function showNewText(text) {\n firstText.innerHTML = `${text}`;\n gsap.to(\".m402-text-relative\", {\n duration: 0.3,\n opacity: 1\n });\n}", "function showNewText(text) {\n firstText.innerHTML = `${text}`;\n gsap.to(\".m402-text-relative\", {\n duration: 0.3,\n opacity: 1\n });\n}", "function updateDisplay(target, str) {\n var container = $(target);\n if (str === undefined)\n return container.text() || \"\";\n else {\n container.text(str);\n return str;\n }\n }", "function showText(i) {\n Shiny.onInputChange('text_contents', el.data[i-1].longtext);\n }", "get targetDisplay() {}", "printInfo(text) {\n const targetName = this.context.isTestTarget ? 'test' : 'build';\n this.logger.info(`- ${this.context.projectName}@${targetName}: ${text}`);\n }", "function msg(target) {\n $(\"#textText\").html(\"You tapped \" + tapCount +\", double tapped \" + doubleTapCount + \" and long tapped \" + longTapCount + \" times on \" + $(target).attr(\"id\"));\n }", "substituteText() {\n const proxyObj = this.display;\n this.display = new Text();\n this.display.substitute(proxyObj);\n }", "function displayFactText(currentFact, positionId) {\n document.getElementById(positionId).innerHTML = currentFact.text;\n}", "showTarget(point) {\n let target = ConnectionTool.getTarget(this.lastPoint);\n Registry.viewManager.updateTarget(this.typeString, this.setString, target);\n }", "function updateText() {\n\t \tvar actionButton = document.getElementById(\"capture\");\n\t \t/* Check player's state. */\n\t \tif( _Nimbb.getState() == \"recording\" ) {\n\t \t \t/* Update link text. */\n\t \t \tactionButton.innerHTML = \"stop (\" + _Count + \")\";\n\t \t} else {\n\t \t \tactionButton.innerHTML = \"record\";\n\t \t}\n\t}", "function showText(e){\n $(e).html($(e).find('span').html());\n}", "function reflectCurrent() {\n document.getElementById('current-'+ activePlayer).textContent = current;\n }", "function changeText() {\n \n }", "function displayText(myText){\n document.getElementById(\"myText\").innerHTML = myText;\n}", "mainText() {\n return 'Long-Live *as* ' + this.fullName();\n }", "function showText() {\n // TODO\n document.getElementById(\"text\").style.display = \"block\";\n document.getElementById(\"more\").innerHTML = \"\";\n }", "function showInfo(event){\n console.log(`Mi currentTarget es ${event.currentTarget.id}`);\n console.log(`Mi target es ${event.target.id}`);\n}", "function onTextChange() {\n displayText = textEl.value;\n}", "function gText(e) {\n displayValue = (document.all) ? document.selection.createRange().text : document.getSelection();\n document.getElementById('input').value = displayValue \n}", "function getItemText(target) {\n\n\n var source = sourceCtrl;\n\n //We try and find the caret that was clicked so we can display the path up to that level. The first step is to find the text for that caret level.\n var selectedCaretText = getSelectedTextForBreadCrumbItem(target);\n\n //Completed will be set to true if we find the max level we have to display in the lookup\n var completed = false;\n var text = \"\";\n\n //we get all items\n var id = \"#\" + $(source).attr(\"id\");\n\n $(id + \" .ds-bc-nav-lu-item\").not(\".ds-bc-defaultitem\").each(function (i) {\n\n if (completed == false) {\n\n var txt = $(this).text().trim();\n\n if (txt.length > 0) {\n text = text + txt + \"\\\\\";\n }\n\n\n if (selectedCaretText.length > 0 && (selectedCaretText.toLowerCase() == txt.toLowerCase() || selectedCaretText == \"\\\\\")) {\n completed = true;\n }\n }\n\n });\n\n\n return text;\n }", "function displayText(text) {\n\tdocument.getElementById('imageLabel').innerHTML = text;\n}", "function updateText(ev) {\n setText(ev.target.value);\n }", "function displayTargetText(){\r\n\tvar targetText = document.createElement(\"img\");\r\n\ttargetText.src = \"graphics/target.png\";\r\n\ttargetText.style = \"position:absolute; top:24%\";\r\n\ttargetText.style.marginLeft = \"31%\";\r\n\ttargetText.setAttribute (\"width\", \"5%\");\r\n\ttargetText.setAttribute (\"height\", \"5%\");\r\n\tdocument.body.appendChild(targetText);\r\n}", "function showOutput(text) {\n document.getElementById('output').innerHTML = text;\n}", "function showPerson(){\n const item = story[currentItem];\n text.textContent = item.text;\n heading.textContent = item.heading;\n}", "displayDialogText() {\n //If the box is not on its landing position, don't show the text\n if (this.dialogBox.textBox.position.y <= this.dialogBox.textBox.landingPosition.y) {\n this.dialogBox.textBox.fullTextDisplayed = true //Defines to true so buttons can appear (made that way to add a typewriter effect in the future)\n //display text\n push();\n textAlign(LEFT);\n textFont(this.dialogBox.textBox.font);\n textSize(this.dialogBox.textBox.textSize)\n fill(this.dialogBox.textBox.textFill.r, this.dialogBox.textBox.textFill.g, this.dialogBox.textBox.textFill.b);\n text(this.dialogBox.textBox.string, this.dialogBox.textBox.textPosition.x, this.dialogBox.textBox.textPosition.y, this.dialogBox.textBox.textPosition.x2, this.dialogBox.textBox.textPosition.y2);\n pop();\n }\n }", "function printDisplay(text) {\n $('#display').text(text);\n}", "text (state, text) {\n state.text = text\n }", "function displayText(recognized) {\n document.querySelector('#mytext').setAttribute('value', recognized);\n}", "function callText(){\n $(\".ShowText\").click(function(){\n $(\".box-option-click\").show();\n });\n $(\".box-option-click .third-list li a\").click(function(){\n $(\".ShowText\").text(\"\");\n var text = $(this).text();\n $(\".ShowText\").text(text);\n $(\".box-option-click\").hide();\n });\n }", "function setText(text) {\n\t\tclearText();\n\t\tslides.innerHTML = '<li class=\"basic slide active\"><span class=\"content\">' + text + '</span></li>';\n\t}", "get displayText PS_displayText() {\n var {matchedName: sentence, _arguments: args} = this._verb;\n for (let x in args) {\n let obj = x === \"direct_object\";\n let {text} = this._argSuggs[x] || 0;\n if (text) sentence += (\" \" +\n (obj ? \"\" : args[x].flag + \" \") +\n (obj ? \"[ \" + text + \" ]\" : text));\n }\n return sentence;\n }", "function changeText() {\n\t\tflipDisableOption();\n\t\trunning = true;\n\t\tcurrentFrames = $(\"text-area\").value;\n\t\tcurrentInterval = setInterval(insertFrame, currentSpeed);\n\t}", "function info(text) {\n\tdocument.getElementById('info').innerText = text;\n}", "getSelectedText() {\n return window.getSelection().toString();\n }", "function UpdateDisplay(msg) {\n console.log(msg);\n var target = document.getElementById(\"maintext\");\n console.log(target);\n target.value = msg + \"\\n\\n\";\n }", "function reveal_text() {\n reveal_by_class(\"hidden-text\", \"block\");\n}", "function displayText(match) {\n hide(matchesList);\n infoElement.textContent = '';\n queryInfoElement.textContent = '';\n const query = queryInput.value;\n // add history entry for the query when the user has tapped/clicked a match\n history.pushState({isSearchResults: true, query: query}, null,\n `${window.location.origin}#${query}`);\n // match.l is a citation for a play or poem, e.g. Ham.3.3.2, Son.4.11, Ven.140\n // scene title matches only have act and scene number, e.g. Ham.3.3\n history.pushState({isSearchResults: false}, null,\n `${window.location.origin}#${match.l}`);\n document.title = `Search Shakespeare: ${match.l}`;\n const location = match.l.split('.');\n const text = location[0];\n fetch(`${HTML_DIR}${text}.html`).then(response => {\n return response.text();\n }).then(html => {\n textDiv.innerHTML = html;\n textDiv.onmouseover = addWordSearch;\n show(textDiv);\n highlightMatch(match, location);\n });\n}", "addPhraseToDisplay(){\r\n this.setupLetterToBeDisplayed()\r\n }", "text () {\n\n }", "function displayGuide() {\n my.html.guide.innerHTML = my.current.unit.guide\n }", "function displayScene() {\n var para = document.querySelector (\"#descrip\");\n para.textContent = \"You are in the \" + player.currLoc.name + \"-\" + \"\\n\" + \n player.currLoc.description + \".\" + \"\\n\" +\n \"The items you can take are: \" + player.currLoc.items \n}", "function print(e){\n \n let text = e.innerText;\n let out = document.getElementById(\"visor\");\n \n out.innerText+=text;\n\n displayContent += text;\n \n}", "function displaySelectedTextDialog( event ) \n {\n if (! (element && element == this)) \n {\n return;\n }\n element = null;\n \n var selectedText = getSelectedText();\n if ( '' == selectedText ) \n { \n return;\n }\n selectedText = cleanText(selectedText);\n \n var $container = makeDialog(selectedText, event);\n selectTextAgain($container);\n }", "function displayContents(txt) {\n textContainer.innerHTML = txt;\n}", "function updateCurrentText() {\n currentEl.innerText = `${currentActiveCard + 1 }/${cardsEl.length}`;\n }", "function displayText(match) {\n hide(creditElement);\n hide(infoElement);\n hide(matchesList);\n hide(queryInfoElement);\n // match.l is a citation within a play or poem,\n // e.g. Ham.3.3.2, Son.4.11, Ven.140\n // scene title matches only have act and scene number, e.g. Ham.3.3\n history.pushState({type: 'text'}, null,\n `${window.location.origin}#${formatCitation(match)}`);\n document.title =\n `Search Shakespeare: ${formatCitation(match)}`;\n const location = match.l.split('.');\n const abbreviation = location[0];\n // TODO: Factor to a function.\n fetch(`${HTML_DIR}${abbreviation}.html`).then((response) => {\n return response.text();\n }).then((html) => {\n textDiv.innerHTML = html;\n textDiv.onmouseover = addWordSearch;\n show(textDiv);\n show(creditElement);\n highlightMatch(match, location);\n }).catch((error) => {\n console.error(`Error or timeout fetching ${abbreviation}: ${error}`);\n displayInfo(`There was a problem downloading ` +\n `<em>${texts[abbreviation].title}.</em><br><br>` +\n 'Check that you\\'re online, or try refreshing the page.<br><br>' +\n 'You can download texts when you\\'re online by selecting the ' +\n '<strong>Download all</strong> checkboxes from ' +\n '<strong>Search options</strong>.');\n });\n}", "function giveName(state) {\n text_entry.show();\n}", "retriveText() {\n let exactText;\n let currentElement;\n if (!isNullOrUndefined(this.currentContextInfo) && this.currentContextInfo.element) {\n currentElement = this.currentContextInfo.element;\n exactText = this.currentContextInfo.element.text;\n this.viewer.selection.start = currentElement.start;\n this.viewer.selection.end = currentElement.end;\n }\n else {\n let startPosition = this.viewer.selection.start;\n let offset = startPosition.offset;\n let startIndex = 0;\n let startInlineObj = startPosition.currentWidget.getInline(offset, startIndex);\n currentElement = startInlineObj.element;\n exactText = startInlineObj.element.text;\n }\n return { 'text': exactText, 'element': currentElement };\n }", "function print(txt) {\r\n sigcaptx_1.HTMLTags.txtDisplay.value += txt + \"\\n\";\r\n sigcaptx_1.HTMLTags.txtDisplay.scrollTop = sigcaptx_1.HTMLTags.txtDisplay.scrollHeight; // scroll to end\r\n }", "function itemprint(t){\n\t\t\tdebugger;\n\t\t\tvar newtext = $(\"<p style=display:none>\")\n\t\t\t// var statusvar = current.effects[0].status\n\t\t\tvar effectcheck = window[(current.effects[0].status)]\n\t\t\t// var currenteffect = caction.effectvar\n\t\t\t// if(effectcheck === undefined){};\n\t\t\tif(effectcheck === false || effectcheck === undefined){\n\t\t\t\tnewtext\n\t\t\t\t\t.text(current[t] + current.item[0].idesc + current.effects[0].efalse)\n\t\t\t\t\t.appendTo(\".textarea\")\n\t\t\t\t\t.fadeIn(3000)\n\t\t\t};\n\t\t\tif(effectcheck === true){\n\t\t\t\tnewtext\n\t\t\t\t\t.text(current[t] + current.item[0].idesc + current.effects[0].etrue)\n\t\t\t\t\t.appendTo(\".textarea\")\n\t\t\t\t\t.fadeIn(3000)\n\t\t\t};\n\t\t\t$(\".textarea\").animate({scrollTop: 9000}, 3000);\n\t\t}", "function showcase(section) {\n var sectionShowcase = section.target.innerHTML;\n outputEl.innerHTML = 'You clicked on the ' + sectionShowcase + ' section!'\n}", "function displayText1() {\n let t1 = createElement('span', 'Logic for Visualizing Seismic Events');\n t1.parent('text1');\n t1.class('large'); \n}", "function revealConfirmation () {\n console.log('show text now');\n document.querySelector('.copy-btn-label').innerHTML = 'Copied!';\n}", "function overText(x){\n x.innerText = \"created by Timothy Joe Axford II\"\n}", "function drawText()\n\t{\n\t\t// Figure out the correct text\n\t\tvar text = getText();\n\n\t\twid = that.add('text', {\n\t\t\ttext: text,\n\t\t\tcolor: style.color,\n\t\t\tfont: style.font,\n\t\t\tcursor: 'pointer'\n\t\t});\n\n\t\t// Set the width of the widget\n\t\tthat.w = wid.width();\n\n\t\t// Assign a toggler\n\t\twid.applyAction('click', {\n\t\t\tclick: toggleMode\n\t\t});\n\t}", "startTextMode() {\n if (this.getCurrentState() !== states.TEXT) {\n this._state = states.TEXT;\n\n this._getModule(modules.TEXT).start({\n mousedown: this._onFabricMouseDown.bind(this),\n select: this._onFabricSelect.bind(this),\n selectClear: this._onFabricSelectClear.bind(this),\n dbclick: this._onDBClick.bind(this),\n remove: this._handlers.removedObject\n });\n }\n }", "function changetext(){\n $('h2').text('say your name');\n}", "updateDisplay() {\n this.currentText.innerText = this.formatNumber(this.currentTextValue);\n if (this.operation !== undefined) {\n this.previousText.innerText = `${this.previousTextValue} ${this.operation} `;\n } else {\n this.previousText.innerText = \"\";\n }\n }", "function onClickTextEjercise5() {\n document.querySelector(\"#text-exercise-5\").innerHTML =\n \"5. This text was changed!!\";\n}", "function display(result) {\n let displayArea = document.querySelector('#display-text');\n displayArea.textContent = result;\n}", "function drawDistributionTarget(tree) {\n var left = getX(tree, \"center\");\n var top = document.getElementById(\"mathDisplay\").offsetTop;\n var target = drawTarget(top, left, \"&#8595;\", {tx:60, ty:54});\n target.value = \"Distribute!\"; \n return target; \n}", "function textChange(e) {\n e.target.innerHTML = \"The mouse has left the element\";\n}", "function switchtext(){\n\t\t$(\"h1\").html(\"jQuery Ninja\");\n\t\n\t}", "function setInfoText(infoText) {\n var textBar = document.getElementById(\"informationText\");\n textBar.textContent = infoText;\n}", "function showText() {\n\tfiglet('Twitch', function(err, data) {\n\t if (err) {\n\t console.log('Something went wrong...');\n\t console.dir(err);\n\t return;\n\t }\n\t console.log(data);\n\t console.log(' Twitch streamers status '.inverse + '\\r\\n');\n\t //console.log('loading...');\n\t});\n}", "function showText(){ \r\n var attr = $(this).children().attr('src');\r\n if(typeof attr !== typeof undefined && attr !== false){\r\n $(this).children().clone().appendTo($(\"#progress\"));\r\n }\r\n else{\r\n $(\"#progress\").append($(this).text()+\" \");\r\n }\r\n $(\"#progress\").append(\" \");\r\n }", "function XDisplaySentence(targetId, WordIdPrefix, punctuation) {\n //alert('Display Function');\n //Build the Sentence\n var sentence = \"\".concat($(WordIdPrefix + LastSentenceSelections[0]).text(), \" \", $(WordIdPrefix + LastSentenceSelections[1]).text(), \" \", $(WordIdPrefix + LastSentenceSelections[2]).text(), \" \", $(WordIdPrefix + LastSentenceSelections[3]).text(), punctuation);\n\n $(targetId).text(sentence);//Display the sentence in the header\n}", "function displayHelpText() {\n console.log();\n console.log(' Usage: astrum figma [command]');\n console.log();\n console.log(' Commands:');\n console.log(' info\\tdisplays current Figma settings');\n console.log(' edit\\tedits Figma settings');\n console.log();\n}", "render(): void {\n // Render text for current page\n const startAt = (this._page - 1) * this._numCharsPage;\n const pageText = this._text.substr(startAt, this._numCharsPage);\n output.cursorTo(0, output.contentStartRow);\n console.log(pageText);\n }", "updateLabel() {\n this.text = this._text;\n }", "updateLabel() {\n this.text = this._text;\n }", "function display(ipsum) {\n\tif(ipsum) {\n\t\tif(ipsum) {\n\t\t\tvar ipsumText = document.getElementById('ipsum-text');\n\t\t\tipsumText.innerText = processIpsum(ipsum);\n\t\t}\n\n\t\tvar ipsumLink = document.getElementById('ipsum-link');\n\t\tipsumLink.innerHTML = settings[selected_ipsum].name;\n\t\tipsumLink.href = settings[selected_ipsum].url;\n\t} else {\n\t\tvar ipsumText = document.getElementById('ipsum-text');\n\t\tipsumText.innerText = 'Error';\n\t}\n\n\t// copy ipsum text easily:\n\n\tvar textareaButton = document.querySelector('.js-textareacutbtn');\n\n\ttextareaButton.addEventListener('click', function(event) { \n\t var textToCopy = document.getElementById('ipsum-text'); \n\t textToCopy.select();\n\t document.execCommand('copy'); \n\t});\n}", "function reproduccionActual(texto){\n\tdocument.getElementById('currentPlay').innerText=texto\n}", "function showHelpText() {\n ctx.save();\n\n if (lastUsedInput === 'keyboard') {\n setFont(18);\n ctx.fillStyle = 'white';\n ctx.fillText(translation.spacebar + ' ' + translation.select, 28 - fontMeasurement, kontra.canvas.height - 25 + fontMeasurement / 2.5);\n }\n else if (lastUsedInput === 'gamepad') {\n drawAButton(28, kontra.canvas.height - 25);\n setFont(18);\n ctx.fillStyle = 'white';\n ctx.fillText(translation.select, 28 + fontMeasurement * 1.75, kontra.canvas.height - 25 + fontMeasurement / 2.5);\n }\n\n ctx.restore();\n}", "function displayMessage(text) {\n $(\"gameOutputField\").innerHTML = $(\"gameOutputField\").innerHTML + text + \"<br>\";\n $(\"gameOutputField\").scrollTop = $(\"gameOutputField\").scrollHeight;\n }", "static dispcurr(data) {\n current.innerText = data;\n return;\n }", "function reproduccionActual(texto){\r\n\tdocument.getElementById('currentPlay').innerText=texto\r\n}", "function display(target) {\r\n // check that if target contain operator class\r\n if (target.classList.contains(\"operator\")) {\r\n // check if result section is not an Error or empty string\r\n if (\r\n displayResult.textContent != \"\" &&\r\n displayResult.textContent != \"Error\"\r\n ) {\r\n // check that if the last char of result screen is an operator\r\n if (/(×|÷|\\+|-|%)$/.test(displayResult.textContent)) {\r\n displayResult.textContent = displayResult.textContent.replace(\r\n /(×|÷|\\+|-|%)$/,\r\n target.textContent\r\n );\r\n } else {\r\n displayResult.textContent += target.textContent;\r\n }\r\n //show live result\r\n showLiveResult(displayResult.textContent);\r\n } //if users entered button was a number, it will be added to the last of the result string\r\n } else if (\r\n target.classList.contains(\"number\") &&\r\n displayResult.textContent != \"Error\"\r\n ) {\r\n if (target.textContent == \"+/-\") {\r\n //let user use (- only once in numbers before an operator\r\n if (check.indexOf(\"(-\") != -1) {\r\n } else {\r\n displayResult.textContent += \"(-\";\r\n check += \"(-\";\r\n }\r\n //if users button wasnt (- , the number will be added to the result\r\n } else {\r\n displayResult.textContent += target.textContent;\r\n check += target.textContent;\r\n showLiveResult(displayResult.textContent);\r\n } //user can use . in numbers before operator once\r\n } else if (\r\n target.classList.contains(\"dot\") &&\r\n displayResult.textContent != \"Error\"\r\n ) {\r\n if (check.indexOf(\".\") != -1) {\r\n } else {\r\n displayResult.textContent += \".\";\r\n check += \".\";\r\n }\r\n }\r\n}", "function myText(text){\r\n document.getElementById(\"ex10-3\").innerHTML = text;\r\n}", "function displayTitle (event) {\n $display.textContent = listoftitles[event.target.getAttribute('id')-1]\n }", "function display(target)\n\t{\n\t\tif ( $(target).hasClass('more-reviews') )\n\t\t{\n\t\t\treturn toggleAllReviews(target);\t\n\t\t}\n\n\t\tif ( $(target).hasClass('region-hotels') )\n\t\t{\n\t\t\treturn toggleHotels();\n\t\t\t\n\n\t\t}\n\t}", "function setText(text) {\n document.getElementById(\"result\").innerHTML = text;\n}", "function handleMouseOverText(e) {\n\t\t\t\te.currentTarget.addClassName('active');\n\t\t\t\tvar parent = $(e.currentTarget).parent().get(0);\n\n\t\t\t\ttheInterface.emit('ui:emphElement', {\n\t\t\t\t\tid : e.currentTarget.getAttribute('id'),\n\t\t\t\t\tlayer : parent.getAttribute('data-layer')\n\t\t\t\t});\n\t\t\t}", "get_displayedText() {\n return this.liveFunc._displayedText;\n }", "function showAction(text){\n\t\t\t$(\".actiontext\").html(text).show().animate({\n\t\t\t\t\"font-size\" : \"700%\",\n\t\t\t\t\"opacity\" : 0\n\t\t\t}, 1300, function(){\n\t\t\t\t$(\".actiontext\").hide().css({\n\t\t\t\t\t\"font-size\" : \"100%\",\n\t\t\t\t\t\"opacity\" : 1\n\t\t\t\t});\n\t\t\t});\n\t\t}", "function info(txt) {\n $(\"#info\").text(txt);\n}", "function selectText(target) {\n const range = document.createRange();\n range.selectNodeContents(target);\n\n const selection = window.getSelection();\n selection.removeAllRanges();\n selection.addRange(range);\n}", "function updateCurrentStep() {\ncurrent_step_text.innerHTML = recipe[current_step];\n}", "function eShow(target) {\n if (target.constructor == Text) return;\n\n if (isArray(target) || isNodeList(target)) {\n for (var i = 0; i < target.length; i++) {\n eShow(target[i]);\n }\n } else if (eHasClass(target, 'hidden')) {\n target.className = target.className.replace(/ hidden/, '');\n }\n}", "function showText() {\n $(\"#textDisplay\").empty();\n $(\"#instructions\").empty();\n randomWords = [];\n for (var i = 0; i < wordCount; i++) {\n var ranWord = wordList[Math.floor(Math.random() * wordList.length)];\n if (wordList[wordList.length - 1] !== ranWord || wordList[wordList.length - 1] === undefined) {\n randomWords.push(ranWord);\n }\n }\n randomWords.forEach(function(word){\n $(\"#textDisplay\").append($(\"<span>\",{\"text\": word + \" \",\"class\":\"word\"}));\n });\n textDisplay.firstChild.classList.add(\"highlightedWord\")\n }", "function displayText(){\r\n $('#browserInfo').removeClass('notDisplay').addClass('display');\r\n}", "function displayPlaintext(text,loc=mainTV) {\n\thtmldata = '<div class=\"plaintext\">' + text + '</div>';\n\t\n\tloc.innerHTML += htmldata;\n\tMathJax.Hub.Queue([\"Typeset\",MathJax.Hub]);\n}", "function echo(text) {\n document.getElementById(\"lblScope\").innerHTML += text + \"<br />\";\n }" ]
[ "0.7295878", "0.7170134", "0.68684554", "0.6815694", "0.66996807", "0.6583383", "0.6583383", "0.64378256", "0.6414652", "0.6315669", "0.62590045", "0.6213346", "0.6204112", "0.6199924", "0.61949795", "0.61788446", "0.61720175", "0.61701274", "0.6166431", "0.61591864", "0.614656", "0.61163616", "0.6088094", "0.60782313", "0.60629815", "0.6048719", "0.60479", "0.60419977", "0.6024392", "0.5988648", "0.5982946", "0.5981322", "0.5977906", "0.59445727", "0.59354544", "0.5934704", "0.5928285", "0.59161776", "0.5914043", "0.5911105", "0.59021026", "0.58972293", "0.5871313", "0.58598477", "0.58446115", "0.5835922", "0.58229893", "0.58053964", "0.58044773", "0.5798065", "0.57799023", "0.5765511", "0.5765235", "0.5764235", "0.57528764", "0.57522696", "0.57510376", "0.5749653", "0.57441366", "0.5741357", "0.5734272", "0.57330066", "0.57303506", "0.57297546", "0.5728135", "0.5713341", "0.5709705", "0.57023484", "0.5701727", "0.5699811", "0.5695759", "0.56931204", "0.5686681", "0.56861156", "0.56808573", "0.567942", "0.56776416", "0.56776416", "0.56745934", "0.56677186", "0.56636655", "0.56630945", "0.5657723", "0.56548303", "0.56530446", "0.56503564", "0.56489414", "0.5645159", "0.5644732", "0.56328183", "0.56262714", "0.56240046", "0.56235576", "0.5623395", "0.5619366", "0.56191367", "0.560913", "0.5606518", "0.55965716", "0.5596451" ]
0.86897904
0
Update practice pane after evaluating the user's input. The input typed by the user is evaluated for correctness and then the practice pane is updated.
function updatePracticePane() { evaluateInput() setTargetText() displayTargetText() updateProgress() updateSpeed() updateError() updateSmiley() if (my.current.state == my.STATE.COMPLETED) { displayAdvice() setResultTooltips() log('state', my.current.state.toUpperCase(), 'unit', my.current.unitNo + '.' + my.current.subunitNo, 'type', my.settings.unit, 'wpm', my.current.wpm, 'error', my.current.errorRate.toFixed(1)) } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function evaluateInput()\n {\n var inputText = my.html.input.value\n var inputLength = inputText.length\n\n // If the tutor is in READY state, and input has been entered,\n // then set it to RUNNING STATE.\n if (my.current.state == my.STATE.READY && inputLength > 0) {\n\n my.current.startTime = new Date().getTime()\n my.current.state = my.STATE.RUNNING\n updatePracticePaneState()\n\n log('state', my.current.state.toUpperCase(),\n 'unit', my.current.unitNo + '.' + my.current.subunitNo,\n 'type', my.settings.unit)\n }\n\n // Number of characters correctly typed by the user\n var goodChars = Util.common(my.current.subunitText, inputText)\n my.current.correctInputLength = goodChars\n\n // Validate the input\n if (goodChars == inputLength) {\n\n // Clear error if any\n if (my.current.state == my.STATE.ERROR) {\n\n my.current.state = my.STATE.RUNNING\n updatePracticePaneState()\n }\n } else {\n\n // Set and display error\n if (my.current.state == my.STATE.RUNNING) {\n my.current.state = my.STATE.ERROR\n my.current.errors++\n updatePracticePaneState()\n } else if (my.current.state == my.STATE.ERROR) {\n processInputCommand()\n }\n }\n\n // Update error rate\n if (goodChars == 0) {\n if (my.current.errors == 0) {\n my.current.errorRate = 0\n } else {\n my.current.errorRate = Number.POSITIVE_INFINITY\n }\n } else {\n my.current.errorRate = 100 * my.current.errors / goodChars\n }\n\n // Check if the complete target text has been typed successfully\n if (goodChars == my.current.subunitText.length) {\n my.current.state = my.STATE.COMPLETED\n updatePracticePaneState()\n }\n }", "function updatePracticePaneState()\n {\n switch (my.current.state) {\n\n case my.STATE.READY:\n my.html.practicePane.className = ''\n my.html.input.disabled = false\n my.html.input.focus()\n Util.setChildren(my.html.status, 'READY')\n my.html.status.title = 'Type in the input box below ' +\n 'to begin this lesson.'\n my.html.restartLink.style.visibility = 'hidden'\n break\n\n case my.STATE.RUNNING:\n my.html.practicePane.className = ''\n my.html.input.disabled = false\n my.html.input.focus()\n Util.setChildren(my.html.status, '')\n my.html.status.title = ''\n my.html.restartLink.style.visibility = 'visible'\n break\n\n case my.STATE.ERROR:\n my.html.practicePane.className = 'error'\n my.html.input.disabled = false\n my.html.input.focus()\n my.html.restartLink.style.visibility = 'visible'\n Util.setChildren(my.html.status, 'ERROR!')\n my.html.status.title = 'Fix errors in the input box ' +\n 'by pressing the backspace key.'\n break\n\n case my.STATE.COMPLETED:\n my.html.practicePane.className = 'completed'\n my.html.input.disabled = true\n my.html.input.blur()\n my.html.restartLink.style.visibility = 'visible'\n Util.setChildren(my.html.status, 'COMPLETED')\n my.html.status.title = 'You have completed this lesson.'\n break\n }\n\n }", "update() {\n this.scoreHTML.innerText = this.score;\n // show modal if you score 12\n if(this.score == 12){\n this.win();\n }\n }", "function updateDisplay () {\n if (isGameOver()) {\n $('h1').text(' gameover. winner is ' + whoWon())\n } else {\n $('h1').text(quiz.currentQuestion + ') ' + quiz.questions[quiz.currentQuestion].prompt)\n // hard coded display, only has 4 answers at a time. Each is displayed as a button, so can use the order (eg) that they appear in the dom to select them\n $('button').eq(0).text(quiz.questions[quiz.currentQuestion].choices[0])\n $('button').eq(1).text(quiz.questions[quiz.currentQuestion].choices[1])\n $('button').eq(2).text(quiz.questions[quiz.currentQuestion].choices[2])\n $('button').eq(3).text(quiz.questions[quiz.currentQuestion].choices[3])\n }\n // update player scores regardless\n $('h3').eq(0).text('Player1: ' + quiz.player1Points)\n $('h3').eq(1).text('Player2: ' + quiz.player2Points)\n}", "function proceed(difficultyLvl) {\n randomWords();\n input.value = \"\";\n showInput.innerText = \"Value displays here\";\n input.focus();\n switch (difficultyLvl) {\n case \"Easy\":\n s += 4;\n break;\n case \"Hard\":\n s += 3;\n break;\n case \"Very Hard\":\n s += 2;\n break;\n default:\n s += 4;\n }\n console.log(s);\n score += 3;\n scoreSheet.innerText = score;\n}", "function clickedCorrect() {\n $(\"#correctInput\").show();\n $(\"#wrongInput\").hide();\n if (clickedCorrect) {\n yourScore +=10;\n };\n }", "function answerIsCorrect () {\r\n feedbackForCorrect();\r\n updateScore();\r\n}", "function processInputCommand()\n {\n var inputText = my.html.input.value\n var goodChars = my.current.correctInputLength\n\n if (inputCommandIs('restart') || inputCommandIs('rst')) {\n location.href = '#restart'\n } else if (inputCommandIs('fix') || inputCommandIs('xxx')){\n my.html.input.value = inputText.substring(0, goodChars)\n updatePracticePane()\n } else if (inputCommandIs('qtpi')) {\n qtpi()\n }\n }", "function whenCorrect() {\n //clear container class html\n //display \"CORRECT!\"\n $(\".container\").html(\"<h2>CORRECT!<h2>\");\n //display correct answer\n displayCorrect();\n //increase score\n correct++;\n answered++;\n }", "function saveInput() {\r\n\t\t\tif (document.getElementById(\"check\").innerHTML == \"New Phrase!\") {\r\n\r\n \tdocument.getElementById(\"result1\").innerHTML= \"A Screwdriver\";\r\n \tdocument.getElementById(\"result2\").innerHTML= \"Ask Rude Arrive Her\";\r\n }\r\n\t\r\n var input = document.getElementById(\"userInput\").value;\r\n document.getElementById(\"result1\").style.visibility = \"visible\";\r\n document.getElementById(\"result2\").style.visibility = \"visible\";\r\n document.getElementById(\"check\").innerText= \"New Phrase!\";\r\n document.getElementById(\"userInput\").value = '';\r\n \t// document.getElementById(\"userInput\").style.border=\"3.5px solid #ff4d4d\";\r\n \t// document.getElementById(\"correct\").style.display = \"none\";\r\n \t// document.getElementById(\"incorrect\").style.display = \"block\";\r\n}", "function results() {\n selectedAnswers = $(displayTest.find(\"input:checked\"));\n //if user is correct\n if (\n selectedAnswers[0].value === testSetup[currentQuestion - 1].questionAnswer\n ) {\n //add to correct score and display on element\n correct++;\n $(\"#correct\").text(\"Answers right: \" + correct);\n } else {\n //if user is wrong then add to wrong score and display on element\n wrong++;\n $(\"#incorrect\").text(\"Wrong answers: \" + wrong);\n }\n //check to see if the user has reached the end of the test\n if (currentQuestion === 10) {\n //toggle finalize modal at end of test to display score\n $(\"#modalMatch\").modal(\"toggle\");\n $(\"#testScore\").text(\n \"End of test! You scored a \" + (parseFloat(correct) / 10) * 100 + \"%\"\n );\n //show postTest element\n $(\"#postTest\").show();\n $(\"#submitTest\").hide();\n }\n }", "function evaluate() {\n $('#quizBoard').hide();\n $('#results').show();\n if ($('#q1f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q2t').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q3f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q4f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q5t').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q6t').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q7f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q8f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q9f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n $('#corr').html(correct)\n $('#incorr').html(incorrect)\n $('#percent').html(correct/9)\n}", "function update() {\n type = textInput.value();\n shapeWidth = shapeSlider.value();\n density = densitySlider.value();\n shapeOpacity = opacitySlider.value();\n let size = fontSizeOptions.value();\n fontSize = int(size);\n fontStyle = fontStyleOptions.value();\n shape = radioShape.value();\n fillInitially = radioFill.value();\n shake = shakeCheckBox.checked();\n move = moveCheckBox.checked();\n colourInitially = radioColour.value();\n\n setUpText();\n}", "function handlecorrectAnswer(){\n $('.QAform').html(`\n <img class = \"icon circle\" src = \"https://github.com/katngo/catquiz/blob/master/cat-broke-vase.jpg?raw=true\" alt = \"cat broke the vase\"></img>\n <p>Hmm...you're not bad at all</p>\n <button type = \"button\" class = \"nextButton\">Next</button>`);\n updateScore();\n}", "function userCorrectAnswerSubmitted(answer) {\n store.score++;\n $('.correct-updater').html('Correct!');\n}", "function updateDisplay(msg){\n\t\t//displays story\n\t\tvar target=document.getElementById(\"OutputTxtBox\");\n\t\ttarget.value=msg+\"\\n\"+target.value;\n\t\t//displays score\n\t\tdocument.getElementById(\"OutputScore\").value=score;\n\t}", "function check_if_update(){\n if(total_results_past == total_results){\n read_speech(\"Here's a hint. You're supposed to say: \" + window.paragraph_list[window.curr_paragraph])\n } else{\n if(flip){\n if(conf_score == conf_score_past){\n read_speech(\"You seem lost. You're supposed to say: \" + window.paragraph_list[window.curr_paragraph])\n }\n conf_score_past = conf_score\n }\n }\n total_results_past = total_results\n flip = !flip;\n}", "function change () {\n setAnswer(this.value)\n // If the appearance is 'quick', then also progress to the next field\n if (fieldProperties.APPEARANCE.includes('quick') === true) {\n goToNextField()\n }\n}", "function updateScore(){\n\tdocument.getElementById(\"correct\").innerHTML = \"Correct Answers: \" + counters.correct;\n\tdocument.getElementById(\"incorrect\").innerHTML= \"Incorrect Answers: \" + counters.incorrect;\n\tdocument.getElementById(\"unanswered\").innerHTML= \"Unanswered: \" + counters.unanswered;\n}", "function updateDisplay () {\n if (isGameOver()) {\n if (whoWon() === 1) {\n $('#gameStatus').text('Gameover. The winner is Player1!')\n } else if (whoWon() === 2) {\n $('#gameStatus').text('Gameover. The winner is Player2!')\n } else {\n $('#gameStatus').text('Gameover. It\\'s a draw!')\n }\n }\n\n if (!isGameOver()) {\n $('#gameStatus').text('Q' + (quiz.currentQuestion + 1) + ') ' + 'It\\'s Player' + (quiz.currentQuestion % 2 + 1) + '\\'s turn')\n // update question\n var flagIndex = quiz.currentQuestion + 1\n $('#flag').css('background-image', 'url(./img/flag' + flagIndex + '.gif)')\n $('#choice1').text(quiz.questions[quiz.currentQuestion].choices[0])\n $('#choice2').text(quiz.questions[quiz.currentQuestion].choices[1])\n $('#choice3').text(quiz.questions[quiz.currentQuestion].choices[2])\n $('#choice4').text(quiz.questions[quiz.currentQuestion].choices[3])\n // update sccore\n $('#player1Score').text(quiz.player1Score)\n $('#player2Score').text(quiz.player2Score)\n }\n}", "function beginQuiz(){\n endQuiz.style.display = \"none\";\n if (currentQuestionSpot === finalQuestion){\n return finalScore();\n } \n var currentQuestion = quizQuestions[currentQuestionSpot];\n questionsEl.innerHTML = \"<p>\" + currentQuestion.question + \"</p>\";\n choiceA.innerHTML = currentQuestion.optionA;\n choiceB.innerHTML = currentQuestion.optionB;\n choiceC.innerHTML = currentQuestion.optionC;\n choiceD.innerHTML = currentQuestion.optionD;\n}", "function inputChange (e) {\n var isCorrect = game.check(this.value),\n wordObj,\n i,\n l = game.wordsByIndex.length;\n if (isCorrect) {\n // TODO: run correct animation & move to the next stage\n game.level++;\n game.currentSceneIndex++;\n // sound\n game.soundInstance = createjs.Sound.play(\"Correct\"); // play using id. Could also use full sourcepath or event.src.\n //game.soundInstance.addEventListener(\"complete\", createjs.proxy(this.handleComplete, this));\n game.soundInstance.volume = 0.5;\n window.alert('Correct!');\n loadScene(game.currentSceneIndex)\n this.value='';\n } else if (this.value.length > game.minimumWordLength) {\n for (i = 0; i < l; i++) {\n wordObj = game.wordsByIndex[i];\n if (wordsAreEqual(wordObj.spl, this.value)) {\n game.level--;\n setPopupContent(i, 500, 100);\n // show mask\n jQuery('#mask').show();\n // show pop-up\n jQuery('#popup').show();\n this.value='';\n }\n }\n }\n}", "function correct() {\n score = score + 5;\n document.getElementById(\"score\").innerHTML = score;\n color_confusion();\n}", "function displayInputMade() {\n var guessesDisplay = document.querySelector(\"#guessesDisplay\");\n guessesDisplay.textContent = incorrectInputEntered;\n\n var inputMadeDisplay = document.querySelector(\"#inputMadeDisplay\");\n inputMadeDisplay.textContent = incorrectInputEntered;\n}", "function correctAnswer(){\n\tscore += addScore(time);\n\tupdateScore();\n if(++level == 10){\n difficulty = 1;\n } else if(level == 20){\n difficulty = 2;\n }\n document.getElementById('level').innerHTML = \"Level : \" + level;\n\tresetComponent();\n}", "function solvePart2(){\n\n // Display the answer\n document.getElementById(\"answer2\").innerHTML = \"fill me in\"\n }", "function userAnswerCorrect () {\n userCorrectFeedback();\n updateScore();\n $('.js-CorrectHidden').css('display', 'flex');\n}", "function updateScore() {\n\t$(\"#wordsCorrect\").html(\"<h5>Words Guessed Correctly: </h5><h3>\" + scoreCorrect + \"</h3>\");\n\t$(\"#wordsSkipped\").html(\"<h5>Words Skipped: </h5><h3>\" + scoreSkipped + \"</h3>\");\n}", "function problem_1() {\n\n problemNumber.innerHTML = 'Problem 1';\n input1.style.visibility = 'visible';\n input1.style.width = '200px';\n input1.placeholder = 'Enter \"number\"';\n\n jsConsole.writeLine('Problem 1. Odd or Even');\n jsConsole.writeLine(' - Write an expression that checks if given integer is odd or even.');\n solutionText();\n\n submit.onclick = function () {\n var num = input1.value * 1;\n\n if (!isNaN(num)) {\n\n var result;\n if (num % 2 === 0) {\n result = 'Even';\n } else {\n result = 'Odd';\n }\n printResult();\n } else {\n\n incorrectInput();\n }\n\n function printResult() {\n jsConsole.writeLine(num + ' is ' + result);\n playWhat();\n }\n }\n}", "function updateDisplay () {\n if (isGameOver()) {\n\n } else {\n $('h1.question').text(quiz.questions[quiz.currentQuestion].qn)\n $('h2.answer').text(quiz.questions[quiz.currentQuestion].factMsg)\n // hard coded display, only has 4 answers at a time. Each is displayed as a button, so can use the order (eg) that they appear in the dom to select them\n $('button').eq(0).text(quiz.questions[quiz.currentQuestion].options[0])\n $('button').eq(1).text(quiz.questions[quiz.currentQuestion].options[1])\n if (quiz.questions[quiz.currentQuestion].options[2]) {\n $('button').eq(2).text(quiz.questions[quiz.currentQuestion].options[2])\n } else {\n }\n $('button').eq(3).text(quiz.questions[quiz.currentQuestion].options[3])\n }\n}", "function finalScorePage() {\n $(\".userAnswer\").remove();\n $(\".answerCheck\").hide();\n $(\"h1\").text(\n \"You got \" +\n scoreTracker +\n \" out of \" +\n quizquestions.length +\n \" correct\"\n );\n $(\"h1\").css(\"text-align\", \"center\");\n var pQuote = $(\"<p>\");\n pQuote.addClass(\"percentRight\");\n var percent = 100 * (scoreTracker / quizquestions.length);\n pQuote.text(percent + \"%\");\n $(\"main\").append(pQuote);\n\n var label = $(\"<p>\");\n label.addClass(\"label\");\n label.text(\"Please enter your initals\");\n $(\"main\").append(label);\n\n var input = $(\"<input>\");\n input.attr(\"id\", \"input\");\n input.addClass(\"userInitials\");\n $(\"main\").append(input);\n\n var submitbtn = $(\"<button>\");\n submitbtn.addClass(\"submitBtn\");\n submitbtn.text(\"Submit\");\n $(\"main\").append(submitbtn);\n }", "function updateQuestionAndScore() {\r\n const html = $(`<ul class=\"question-score\">\r\n <li id=\"js-answered\">Questions Number: ${STORE.currentQuestion + 1}/${STORE.questions.length}</li>\r\n <li id=\"js-score\">Score: ${STORE.score}/${STORE.questions.length}</li>\r\n </ul>`);\r\n $(\".question-and-score\").html(html);\r\n }", "function update() {\n element.winsDoc.textContent = \"Wins: \" + score.win.toString();\n element.losesDoc.textContent = \"Losses: \" + score.lose.toString();\n element.guesses.textContent = \"Guesses Left: \" + score.letterGuess.toString();\n element.wordGuess.textContent = guessedWord;\n}", "function displayAnswerEvaluation(p_totalCorrect, p_totalIncorrect){\n\t // see if correct....\n\t var tTotalCorrect = p_totalCorrect;\n\t\t var tTotalIncorrect = p_totalIncorrect;\n\t\t \n\t\t // catch if this is the last attempt\n\t\t var tLastAttempt = false;\n\t\t if (_currVars.myVars.attemptsAllowed === 0){\n\t\t\tvar tLastAttempt = true;\n\t\t }\n\t\t\n\t\t // ANSWER IS CORRECT\n\t\t if ((tTotalCorrect === _currVars.myVars.correctAnswerCount) && (tTotalIncorrect === 0) ){\n\t\t\t\n\t\t\tconsole.log(\"correct -- feedback_correct_vo_1 or feedback_correct_vo_2\");\n\t\t\t\n\t\t\t//_currVars.myVars.checkbuttonstates.\n\t\t _currVars.myVars.checkbuttonstates.currState =\t_currVars.myVars.checkbuttonstates.COMPLETED_CORRECT;\n\t\t _myDispatcher.setCheckButtonToCorrect();\n\t\t\n\t\t _currVars.myVars.allowCheckbuttonInteraction = false;\n\t\t\n\t\t sendState();\n\t\t\n\t\t turnAllClickHandlersOff();\n\n\t\t playFeedBack(\"feedback_correct\",\"getsoundcallback\",tLastAttempt );\n\t\t \n\t\t\t\n\t\t } else if (_currVars.myVars.attemptsAllowed === 1000){\n\t\t\t/* FEEDBACK_LAST_ATTEMPT ************************************************************************ REPLACE THIS */\n\t\t\t// REMOVE THIS AREA\n\t\t\t//console.log(\"game over- incorrect - see you teacher -- feedback_last_attempt\");\n\t\t\t\n\t\t\t//_myDispatcher.setCheckButtonToIncorrect();\n\t\t\t//_currVars.myVars.checkbuttonstates.currState =\t_currVars.myVars.checkbuttonstates.COMPLETED_INCORRECT;\n\t\t\t//turnAllClickHandlersOff();\n\n\t\t\t//playFeedBack(\"feedback_last_attempt\",\"getsoundcallback\");\n\t\t\t\n\t\t\t\n\t\t } else if (_currVars.myVars.feedbackSetup === \"single\" ){\n\n\t\t //console.log(\"that is not correct - feedback_incorrect\");\n\n\t\t\tif (tLastAttempt === true){\n\t\t\t\tsetScreenToIncorrect()\n\t\t\t\tplayFeedBack(\"feedback_incorrect\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\t\t} else{\n\t\t\t\t_currVars.myVars.setButtonToActiveAfterFeedback = true;\n\t\t\t\tsendState();\n\t\t\t\tplayFeedBack(\"feedback_incorrect\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\n\t\t\t}\n\t\t\n\t\t\n\t\t\n\t\t\t\n\t\t } else if ((tTotalCorrect < _currVars.myVars.correctAnswerCount)&& ( tTotalIncorrect === 0)){\n\n\t\t\tconsole.log(\"you need to choose more answers -- feedback_not_all_correct\");\n\n\t\t\tif (tLastAttempt === true){\n\t\t\t\tsetScreenToIncorrect()\n\t\t\t\tplayFeedBack(\"feedback_not_all_correct\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\t\t} else{\n\t\t\t\t_currVars.myVars.setButtonToActiveAfterFeedback = true;\n\t\t\t\tsendState();\n\t\t\t\tplayFeedBack(\"feedback_not_all_correct\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\n\t\t\t}\n\t\t\t\n\t } else if(tTotalIncorrect === 1){\n\n\t\t console.log(\"one of your answers is incorrect - feedback_one_wrong\");\n\n\t\t if (tLastAttempt === true){\n\t\t\t\tsetScreenToIncorrect()\n\t\t\t\tplayFeedBack(\"feedback_one_wrong\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\t\t} else{\n\t\t\t\t_currVars.myVars.setButtonToActiveAfterFeedback = true;\n\t\t\t\tsendState();\n\t\t\t\tplayFeedBack(\"feedback_one_wrong\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\n\t\t\t}\n\n\t\t\n\t } else if(tTotalIncorrect < (tTotalIncorrect + tTotalCorrect) ){\n\n\t\t\tconsole.log(\"some of your answers are incorrect -- feedback_some_wrong\");\n\n\t\t\tif (tLastAttempt === true){\n\t\t\t\tsetScreenToIncorrect()\n\t\t\t\tplayFeedBack(\"feedback_some_wrong\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\t\t} else{\n\t\t\t\t_currVars.myVars.setButtonToActiveAfterFeedback = true;\n\t\t\t\tsendState();\n\t\t\t\tplayFeedBack(\"feedback_some_wrong\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t\n\t } else{\n\n\t\t if (tLastAttempt === true){\n\t\t\t\tsetScreenToIncorrect()\n\t\t\t\tplayFeedBack(\"feedback_all_wrong\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\t\t} else{\n\t\t\t\t_currVars.myVars.setButtonToActiveAfterFeedback = true;\n\t\t\t\tsendState();\n\t\t\t\tplayFeedBack(\"feedback_all_wrong\",\"getsoundcallback\",tLastAttempt);\n\t\t\t}\n\t\t\n\t }\t \t\t\n }", "function correctAnswer() {\n $('.checkBox').html(\n `<h3 class=\"correctHeading\">Good answer Kid!</h3>\n <img src=\"images/GKMC-cover-art.jpg\" alt=\"good kid maad city cover\" class=\"checkImg\">\n <p class=\"questionAndScore checkText\">Keep it up fam!</p>\n <button type=\"button\" class=\"nextButton button\">Next one</button>`\n );\n updateScore();\n // console.log('correctAnswer ran')\n // console.log(score);\n }", "function correct() {\n outcome.textContent = \"Correct!\";\n reveal(outcome);\n score += 5;\n}", "function displayQuestion () {\r\n //displays score after user answers final question\r\n if (questionIndex === finalQuestion){\r\n return displayScore();\r\n} \r\n var currentQuestion = myQuestions[questionIndex];\r\n question.innerHTML = \"<p>\" + currentQuestion.question + \"</p>\";\r\n answerA.innerHTML = myQuestions[questionIndex].answers.a;\r\n answerB.innerHTML = myQuestions[questionIndex].answers.b;\r\n answerC.innerHTML = myQuestions[questionIndex].answers.c;\r\n answerD.innerHTML = myQuestions[questionIndex].answers.d;\r\n }", "function scoreQuiz() {\n\t\t//fix button state\n\t\tvar button = buttonControl;\n\t\tbutton.value=\"Start\";\n\t\tbutton.disabled = true;\n\n\t\tanswerScore = []; //clear scoring\n\t\tfor (var i=0; i<NUMPROBLEMS; i++) {\n\t\t\tanswerScore.push(0);\n\t\t\t//each key(=term) defaults to wrong until checked\n\t\t}\n\t\tvar definitionsContainer = $.get(\"definitionsContainer\");\n\t\tvar assignedTerms = definitionsContainer.getElementsByClassName(\"termWidget\");\n\t\tfor (var i=0; i<assignedTerms.length; i++) {\n\t\t\t//calc scoring\n\t\t\tlet term = assignedTerms[i]; //term being evaluated\n\t\t\tlet termIndex = term.getAttribute(\"index\"); //index of term\n\t\t\tlet correctDefIndex = answerMap[termIndex]; //index of correct definition\n\t\t\tlet userDefIndex = term.parentNode.getAttribute(\"index\"); //index of user's definition\n\t\t\tif (userDefIndex==correctDefIndex) {\n\t\t\t\tanswerScore[termIndex] = 1; //score as correct\n\t\t\t\tterm.setAttribute(\"correct\", true);\n\t\t\t}\n\t\t\telse {\n\t\t\t\tterm.setAttribute(\"correct\", false);\n\t\t\t}\n\n\t\t}\n\t\tscoreText.innerText = scoreMessage(); //update score text area on page\n\n\t\t//check if enough questions to continue, then prompt user\n\t\tsetTimeout( function() {\n\t\t\tif (Object.keys(quizJson).length >= NUMPROBLEMS && window.confirm(\"Would you like to play again?\") ) {\n\t\t\t\tsetupQuiz();\n\t\t\t\tscoreText.innerText = \"\";\n\t\t\t}\n\t\t}, 3000);\n\n\t}", "function updateScore (input) {\n scoreText.innerText = score;\n pointsRemainingText.innerText = updateRemaining();\n let buttons = document.getElementById(\"buttonGroup\").children;\n for (let i=0; i<buttons.length; i++){\n buttons[i].innerText=balls[i].quantity;\n }\n updateBar();\n}", "function redraw()\n{\n\tmodifyOverallRatingViewing();\n\tmodifyDetailedRatingsDisplayRepeat();\n\t// Only when editing recognized-type scorecard:\n\tif (hasSelector('.note-button') && hasSelector('#' + modifierPersistentContainerId)) \n\t{\n\t\tdoOnSelector('.notes .note-container', function (container)\n\t\t{\n\t\t\t// Resize textareas to fit text\n\t\t\tvar inputControl = container.querySelector('textarea');\n\t\t\tif (inputControl)\n\t\t\t{\n\t\t\t\tfitTextarea(inputControl);\n\t\t\t}\n\t\t});\n\t}\n}", "function updateInputCorrect(listText, positionCurrent, countNumberCorrect, countNumberInput) {\n // update color text\n listText[positionCurrent].style.color = '#0abf00'\n listText[positionCurrent].style.textDecoration = ''\n // update percent\n const percent = countNumberCorrect / countNumberInput * 100\n document.getElementById('__number-percent').innerHTML = parseFloat(Math.round(percent * 100) / 100).toFixed(2)\n}", "function updateFacialExpression(correctPrediction) {\n\tif (correctPrediction) {\n\t\twinStreak = winStreak >= 0 ? winStreak + 1 : 0;\n\t} else {\n\t\twinStreak = winStreak <= 0 ? winStreak - 1 : 0;\n\t}\n\n\tlet face = 4;\n\tif (winStreak <= -5) {\n\t\tface = 0;\n\t} else if (winStreak <= -2) {\n\t\tface = 1;\n\t} else if (winStreak <= 2) {\n\t\tface = 2;\n\t} else if (winStreak <= 5) {\n\t\tface = 3;\n\t}\n\n\t$(\".pyotr-face\").hide();\n\t$(`#face-${face}`).show();\n}", "function useInput() {\n checkVar(getInput.value);\n // console.log(getInput.value);\n outputP.innerText = getInput.value;\n getInput.value = \"\";\n \n\n}", "function update_question_result(correct) {\n if (correct == true) {\n score++;\n return displayQuestionResult.innerText = \"Success!\";\n } else {\n return displayQuestionResult.innerText = \"Incorrect!\";\n }\n}", "function checkAnswer() {\r\n STORE.view = 'feedback';\r\n let userSelectedAnswer = STORE.userAnswer;\r\n let correctAnswer = STORE.questions[STORE.questionNumber].correctAnswer;\r\n console.log('Checking answer...');\r\n if (userSelectedAnswer == correctAnswer) {\r\n STORE.score++;\r\n STORE.correctAnswer = true;\r\n }\r\n else {\r\n STORE.correctAnswer = false;\r\n }\r\n}", "function checkAnswer() {\n\t\tif (answerChoice == currentQuestion.rightAnswer) {\n\t\t\t$(\"#hint\").text(currentQuestion.congratulations);\n\t\t\tcurrentQuestion.correct = true;\n\t\t\tupdateScore();\n\t\t} else {\n\t\t\tconsole.log('incorrect');\n\t\t\t$(\"#hint\").text(currentQuestion.sorry);\n\t\t};\n\t}", "function viewFinalScore() { \n quizQuestionPage.style.display = \"none\"; \n highScoreButtons.style.display = \"none\"; \n finalScore.style.display = \"block\"; \n finalScoreIs.style.display = \"block\" \n initials.style.display = \"block\" \n initialButton.style.display = \"block\" \n initialInput.style.display = \"block\" \n \n finalScoreIs.textContent = \"Your final score is \" + score + \" and your time remaining is \" + secondsLeft + \"!\";\n initialButton.textContent = \"Submit\"; \n initials.textContent = \"Enter Your Initials: \"; \n }", "function updateScore() {\n totalScore = totalScore + 10; // add 10 points to the score\n $score.text(totalScore); // displays the new score on the screen\n console.log(totalScore); // logs the new score in the console\n }", "function updateScore() {\r\n percentage = 100 * (correct / (correct + wrong));\r\n if (isNaN(percentage)) {\r\n percentage = 0;\r\n }\r\n document.getElementById(\"score\").innerHTML =\r\n \"Score: \" + correct + \"/\" + (correct + wrong) + \" - \" + percentage.toFixed(0) + \"%\";\r\n document.getElementById(\"score\").style.visibility = \"visible\";\r\n}", "function correctPrompt() {\n // show the notification alert\n const notif = document.getElementById(\"notification\");\n notif.style.display = \"\";\n\n // if the user types in syntatically correct code\n // this is just checks if it is syntactically correct, not that it is the right code\n if (checkCode(editor.getValue())) {\n // give the user feedback that they're right\n notif.innerHTML = \"That's right!\";\n notif.className = \"success\";\n\n // hide the make corrections div since we're done correcting\n document.getElementById(\"makeCorrections\").style.display = \"none\";\n\n // generate a new problem\n promptText = generateProblem();\n setPrompt(promptText);\n\n // add ten to score for correct answer\n setScore(10);\n }\n else {\n // give the user feedback that they're wrong\n notif.innerHTML = \"That's wrong.\";\n notif.className = \"failure\";\n\n // take away five points for incorrect answer\n setScore(-5);\n }\n\n // hide the notification alert after 1 second\n setTimeout(() => notif.style.display = \"none\", 1000);\n}", "function checkAnswer() {\n disableAnswerBtns();\n const userAnswer = this.firstElementChild.innerText;\n const correctAnswer = startRound()\n \n if (userAnswer === correctAnswer[\"category\"]) {\n updateScore();\n showFeedbackModal(true, correctAnswer)\n } else {\n showFeedbackModal(false, correctAnswer)\n }\n}", "function populate() {\n if (quiz.isEnded()) {\n var finishTime = new Date().toISOString();\n showScore(finishTime);\n storeScore(finishTime);\n }\n else {\n // show question\n var element = document.getElementById(\"question\");\n element.innerHTML = quiz.getQuestionIndex().text;\n // show choices \n var choices = quiz.getQuestionIndex().choices;\n for (var i = 0; i < choices.length; i++) {\n var element = document.getElementById(\"choice\" + i);\n element.innerHTML = choices[i];\n guess(\"btn\" + i, choices[i]);\n }\n showProgress();\n }\n}", "function updateScore() {\n scoreDom.innerHTML = score;\n }", "function renderQuestion() {\n document.getElementById(\"start\").addEventListener(\"click\", startQuiz) \n test = get(\"button\");\n if (position >= window.question) {\n test.innerHTML = \"<h2>You got \" + correct + \" of \" + questions.length + \" questions correct</h2>\";\n get(\"submission\").innerHTML = \"Test completed\";\n //resets variable for quiz restart\n position = 0;\n correct = 0;\n //stops renderQuestion function when test is complete\n return false;\n }\n get(\"quest\").innerHTML = \"Question \" + (position + 1) + \" of \" + questions.length;\n\n question = questions[position].question;\n chA = questions[position].a;\n chB = questions[position].b;\n chC = questions[position].c;\n chD = questions[position].d;\n console.log(\"these are the questions\")\n // display the question\n question.innerHTML = \"<h3>\" + question + \"</h3>\";\n console.log(\"this is the question\")\n // display the answer options\n get \n // document.getElementById(\"userinput1\").value = \"chA\";\n // document.getElementById(\"userinput2\").value = \"chB\";\n // document.getElementById(\"userinput3\").value = \"chC\";\n // document.getElementById(\"userinput4\").value = \"chD\";\n\n}", "function checkAnswer() {\n const answer = currentUserAnswer(); // answerVal.value\n if (answer.toLowerCase() !== null && answer.toLowerCase() === newArrayQuestions[index].answer) {\n userPuntos(index, 1, 1);\n changeCorrectAnswerLetterColor();\n if (soundToggleChekbox) {\n playCorrectAnswerSound();\n }\n } else {\n userPuntos(index, 0, 1);\n changeIncorrectAnswerLetterColor();\n if (soundToggleChekbox) {\n playNoCorrectAnswerSound();\n }\n }\n showScores();\n checkArrayQuestionsForFin();\n if (rankingTable.classList.contains(\"hideElement\")) { // If the game has not been stopped\n updateLetter();\n updateAnswer(); // answerVal.value = ''\n changeActivLetterColor();\n showNextQuestion();\n }\n}", "function showFinalResults() {\n $(\".correctAnswer\").hide();\n $(\".incorrectAnswer\").hide();\n\n let message = \"\";\n\n if (currentScore < 3) {\n message = \"Cayde would be disappointed. Try again!\";\n } else if (currentScore == 3 || currentScore == 4) {\n message = \"You did ok, Guardian!\";\n } else {\n message = \"You got a perfect score! Shaxx would be proud!\";\n }\n\n\n $(\".quizForm\").html(`<p class=\"finalMessage\">Your final score is ${currentScore}/5. ${message}</p>`);\n\n $(\".quizForm\").append(`<button type=button class=\"retakeQuiz\">Retake Quiz</button>`)\n\n currentQuestionNumber = 0;\n currentScore = 0;\n\n $(\".retakeQuiz\").focus();\n\n\n\n\n}", "function updateWindowAfterResolve() {\n\trightPane.innerHTML = templates.renderQuestionForm();\n\tif(getStoredQuestions().length < 1) addTemporaryQuestion();\n }", "function updatePage(){\n\t\tvar totalVotes = goodVotes+badVotes;\n\t\t//a fancy way to do console.log()\n\t\tif(x>0){ $('#judgement').text('Good Haircut'); }\n\t\telse if(x<0){ $('#judgement').text('Bad Haircut'); }\n\t\telse{ $('#judgement').text('Unknown'); }\n\t\t$('#confidence>span').text(confidence);\n\t\t$('#agreementValue').text(agreement);\n\t\t$('#numberOfVotes').text(totalVotes);\n\t\t$('#runningTotal').text(x);\n\t\tif(goodVotes>0) $('#goodVotes').text(\"(\"+goodVotes+\")\");\n\t\tif(badVotes>0) $('#badVotes').text(\"(\"+badVotes+\")\");\n\t}", "function runQuiz(userLevel, userScore){\n\n\n\n // loads full question page up based on userLevel\n function displayQuestion(userLevel, userScore) {\n \n // resets question number and loads correct question number based on user level\n document.getElementById(\"question-number\").innerHTML = '';\n document.getElementById(\"question-number\").innerHTML += 'Question ' + (userLevel + 1);\n \n // sets the question\n // let q = \"What is blockchain technology?\"\n // var q = answers[0]\n\n ////// USER LEVEL TEST: POP-UP (WILL NOT WORK)\n window.alert(\"userLevel is \" + String(userLevel));\n\n\n // resets question ready to ask next question\n document.getElementById('question').innerHTML = '';\n\n // asks question in typewriter text\n const q = question[userLevel]\n let i = 0\n function askQuestion(){\n setTimeout(function() {\n document.getElementById('question').innerHTML += q.charAt(i);\n i++;\n if (i < q.length) {\n askQuestion();\n }\n }, 100)\n }\n askQuestion()\n\n // defines appear function for later use\n // appear function code adapted from https://stackoverflow.com/questions/2207586/how-do-you-make-something-to-appear-slowly-on-a-page-using-javascript\n // to appear: num = 0 step = positive / to disappear: num = 100 step = negative\n function appear(element, num, step, speed){\n var t_o;\n t_o = setInterval(function(){\n var opacity = num / 100;\n num = num + step; \n if(opacity > 1 | opacity < 0){\n clearInterval(t_o);\n return; \n }\n // modern browsers\n element.style.opacity = opacity;\n // older IE\n element.style.filter = 'alpha(opacity=' + opacity*100 + ')';\n }, speed);\n }\n \n // displays timer after 3 seconds\n function displayTimer() {\n document.getElementById('timer').innerHTML = '1:00';\n setTimeout(function() { \n appear(document.getElementById('timer-box'), 0, 10, 50)\n }, 3000)\n }\n displayTimer()\n\n // displays answers after 4 seconds\n function displayAnswer(userLevel) { \n \n // fades out previous answer on q2 and above, and then hides their shell\n if (userLevel > 0) {\n appear(answerBox[userLevel - 1], 100, -10, 50)\n setTimeout (function(){\n answerBox[userLevel - 1].style.display = \"none\";\n }, 600)\n answerBox[userLevel].style.display = \"block\";\n }\n // fades in answer after 4 seconds\n setTimeout(function() { \n appear(answerBox[userLevel], 0, 10, 50)\n }, 4000)\n }\n displayAnswer(userLevel)\n \n // starts timer once answer has loaded (5 seconds)\n function beginTimer () {\n setTimeout(function() {\n const seconds = 59\n setInterval(function(){\n if (seconds > 9) {\n document.getElementById('timer').innerHTML = '0:' + seconds;\n seconds-- ;\n }\n else if (seconds < 10 & seconds > 0){\n document.getElementById('timer').innerHTML = '0:0' + seconds;\n seconds-- ;\n }\n else {\n document.getElementById('timer').innerHTML = '&#128128';\n }\n }, 1000);\n }, 5000)\n }\n beginTimer()\n }\n displayQuestion(userLevel, userScore)\n\n // TEST FUNCTION\n document.getElementById(\"user-level\").innerHTML = ' userLevel is ' + String(userLevel);\n\n // assess whether correct and adjust user level/score or run fail modal\n function assessAnswer(userLevel, userScore) {\n let a = correctAnswer[userLevel];\n // targets input answer based on userLevel\n let aGiven = document.querySelector('input[name=\"' + answerSelector[userLevel] + '\"]:checked').value\n //let aGiven = document.querySelector('input[name=\"q1\"]:checked').value\n if (aGiven == a){\n userLevel ++;\n // userScore += seconds;\n\n // load next question\n // displayQuestion(userLevel, userScore)\n\n runQuiz(userLevel, userScore)\n }\n else {\n failModal()\n }\n }\n submitButton[userLevel].onclick = function(){\n assessAnswer(userLevel, userScore);\n} \n\n function failModal(userLevel, userScore) {\n // on run displays modal by adding inner html to elements based on userLevel/userScore info saved in array\n // modal also has button to begin quiz again reminding users of prize\n // opens modal on function run (closing modal not an option)\n document.getElementById(\"fmodal\").style.display = \"block\";\n }\n}", "function updateDisplay(input) {\n //if display is blank and input isn't zero or solution has been returned\n if ((display.innerHTML === \"0\" && input !== \"0\") || opChain === 0 || solutionReturned === true) {\n //if solution is displayed and input is an operator or display is blank and input is an operator\n if ((solutionReturned === true && !isNumeric(input)) || (display.innerHTML === \"0\" && !isNumeric(input))) {\n //set solution to false because operation chain is increasing\n solutionReturned = false;\n //add input to the chain\n chainOperation(input);\n //add input to the display\n display.innerHTML += input;\n } else {\n //if above conditions not met, clear the chain, input replaces blank display state of 0 and replaces default 0 in operation chain\n solutionReturned = false;\n clearOpChain();\n display.innerHTML = input;\n opChain.push(input);\n }\n } else {\n //if not starting from blank state, add input to display and operation chain\n display.innerHTML += input;\n chainOperation(input);\n }\n displaySub.innerHTML = opChain.join(\"\");\n}", "updateUI(){\n document.getElementById(\"theWord\").innerHTML = this._constructDisplayWord();\n document.getElementById(\"guessdLetter\").innerHTML = this._guessedLetter.toString().replace(/,/g, ' ');;\n document.getElementById(\"lives\").innerHTML = this._lives;\n document.getElementById(\"wins\").innerHTML = this._wins;\n }", "function populate() {\n if (quiz.isOver()) {\n\n showScore();\n } else {\n //show question\n var element = document.getElementById(\"question\");\n element.innerHTML = quiz.getQuestionIndex().text;\n\n //show choices\n var choices = quiz.getQuestionIndex().choices;\n for (var i = 0; i < choices.length; i++) {\n var element = document.getElementById(\"choice\" + i);\n element.innerHTML = choices[i];\n guessAnswer(\"btn\" + i, choices[i]);\n }\n showProgress();\n }\n}", "function update_question_result(correct) {\n if (correct === true) {\n correct_answers++;\n document.getElementById(\"question_result\").innerText = \"Success!\"\n } else {\n document.getElementById(\"question_result\").innerText = \"Wrong!\"\n }\n}", "function update_question_result(correct) {\n if (correct === true) {\n question_result.innerText = \"Success!\"\n } else {\n question_result.innerText = \"Wrong!\"\n }\n}", "function checkAnswer(){\n trueAnswer = returnCorrectAnswer();\n userAnswer = getInput();\n// this if statement is stating if user inputs the right answer what happens and if not what happens\n if(userAnswer === trueAnswer){\n var messageCorrect = array[global_index].messageCorrect;\n score ++;\n swal({\n title: messageCorrect,\n text: \"You got \" + score + \" out of 8 correct.\",\n });\n }\n else{\n var messageIncorrect = array[global_index].messageIncorrect;\n swal({\n title: messageIncorrect,\n text: \"You got \" + score + \" out of 8 correct.\",\n });\n }\n }", "function update() {\n var profit = parseInt(elems.price.value);\n var price = profit;\n var year = parseInt(elems.year.value);\n profit = Math.floor((profit / prices[year]) * 15000);\n if (profit && year) {\n elems.profit.innerText = format(profit);\n elems.sentence.innerText = 'If you bought ' + format(price) + ' worth of BitCoin in ' + year + ' it would be worth ' + format(profit) + ' today, minus your initial investment you would have a profit of ' + format(profit - price) + '!';\n } else {\n elems.profit.innerText = format(0);\n elems.sentence.innerText = 'You done messed up now...';\n }\n }", "function update(){\n let value = document.getElementById(\"input\").value;\n document.getElementById(\"demo\").innerHTML = value;\n }", "function updateInfo(){\n pickedFruitDisplay.innerHTML = basketFruit.repeat(pickedFruit.length) + oneFruit.repeat(collectedFruit.length);\n eatenFruitDisplay.innerHTML = oneFruit.repeat(eatenFruit.length);\n runsDisplay.innerHTML = runsMessage + ' <span>' + player.runs + '</span>';\n if (gameOver === true){\n scoreboard.appendChild(infoPanel);\n infoPanel.innerHTML = `<h2>${resultHeadline}</h2><p>${resultText}</p>`;\n infoPanel.appendChild(form);\n form.appendChild(startButton);\n startButton.innerHTML = \"play again\";\n startButton.focus();\n }\n}", "function update() {\n const display = document.querySelector('.input');\n display.value = calculate.display;\n}", "function updateDisplay()\n {\n //We need to build a string to show. The first item is the current running total:\n var string = runningTotal;\n\n //Then we add the operator if they have pressed this\n if(hasPressedOperator)\n string += \" \" + currentOperator;\n \n //And finally we add the right operand, the value to add when equals is pressed.\n if(hasPressedOperand)\n string += \" \" + currentOperand;\n \n //We then simply set the value of the output field to the string we built\n document.getElementById(\"output\").value = string;\n }", "function feedbackForAnswer(answer) {\n var curvature = TreeConstructor.root.curvature;\n var suffix = \". \" + CONTINUE_BUTTON;\n if (curvature == answer) {\n var message = \"The expression is \" + \n CURVATURE_DISPLAY_NAME[curvature] + suffix;\n $(TreeConstants.ERROR_DIV).html('<div class=\"alert alert-success\">' +\n '<span><strong>Correct!</strong> ' + message + '</span></div>')\n } else {\n var message = \"The expression is \" + CURVATURE_DISPLAY_NAME[curvature] + \n \", but you answered \" + CURVATURE_DISPLAY_NAME[answer] +\n suffix;\n $(TreeConstants.ERROR_DIV).html('<div class=\"alert alert-error\">' +\n '<span><strong>Incorrect!</strong> ' + message + '</span></div>')\n }\n // Increase/decrease difficulty\n updateLevel(curvature == answer);\n // Listen to new expression button.\n $(\"#newExpression\").click(loadNewExpression);\n }", "function updateMistakes() {\r\n document.getElementById('mistakes').innerHTML = mistakes;\r\n}", "function askQuestions() {\n if (currentQuestion === arrayOfQuestions.length) {\n questionSection.style.display = \"none\";\n initialsSection.style.display = \"block\";\n }\n presentQuestion.textContent = arrayOfQuestions[currentQuestion].quizQuestion;\n firstChoice.textContent = arrayOfQuestions[currentQuestion].potentialAnswers[0];\n secondChoice.textContent = arrayOfQuestions[currentQuestion].potentialAnswers[1];\n thirdChoice.textContent = arrayOfQuestions[currentQuestion].potentialAnswers[2];\n fourthChoice.textContent = arrayOfQuestions[currentQuestion].potentialAnswers[3]\n}", "function correctAnswer() {\n $('.response').html(correctAnswerHtml());\n\n updateScore();\n}", "function renderResults () {\r\n if (score >= 7) {\r\n $('.questionAnswerForm').html(`<div class=\"result\"><h3>Excellent work!</h3><p>You got ${score} / 10</p> <button class=\"restartButton\">Restart Quiz</button></div>`);\r\n } else {\r\n $('.questionAnswerForm').html(`<div class=\"result\"><h3>Keep practice more questions</h3><p>You got ${score} / 10</p><button class=\"restartButton\">Restart Quiz</button></div>`);\r\n }\r\n}", "function displayFinalScore(){\n $('.end-section').fadeIn(1000);\n $('.end-section h4').text(`Your Score is: ${score}/${questionsCount}`);\n $('.correct .count' ).text(score);\n $('.wrong .count').text(questionsCount - score);\n resetQuiz();\n}", "function updateScore() {\n score += questions[currentQuestionId - 1].worth;\n scoreElement.textContent = score;\n}", "function changeQCorrect() {\n changeQ();\n messageArea.textContent = \"CORRECT!\";\n }", "function renderScore(){\n // resetting the page\n questionEl.innerHTML = \"\";\n\n // adding content to the score page\n h3Result.textContent = \"You have completed the quiz!\";\n pResult.textContent = \"Your score is \" + timeLeft;\n\n // input field to enter initial\n var initialInput = document.createElement(\"input\");\n initialInput.setAttribute(\"id\",\"myInitial\")\n initialInput.setAttribute(\"value\", \"Enter your initial here...\")\n \n // submit button \n iniButt.className = \"initials-button\";\n iniButt.textContent = \"Submit\";\n\n resultEl.append(h3Result, pResult, initialInput, iniButt);\n main.appendChild(resultEl); \n}", "function renderIfCorrect() {\n $('.correctAnswerScreen').html(correctAnswer());\n }", "function userSelection() {\n stopCountdown();\n if ($(this).attr(\"data-name\") == correctAnswers[questionSelector]) {\n rightWrong = true;\n correct++;\n var newScore = score += points;\n $(\"#score\").text(newScore);\n } else {\n incorrect++ \n }\n showResult();\n nextQuestion();\n }", "function answerIsCorrect(){\r\n qscore++;\r\n score.innerHTML = \"<p>Score: \" + qscore + \"</p>\";\r\n}", "function handleCorrectAnswer() {\n $('<div>').attr('id', 'correct').text('Correct!').appendTo('#info');\n score += 1;\n $scoreboard.text(score);\n\n if (score === 10) {\n $winModal.css('display', 'block');\n }\n}", "function again() {\n result.innerHTML = \"Your result is ...\";\n questionCount = 0;\n athenaScore = 0;\n dionysusScore = 0;\n zeusScore = 0;\n aphroditeScore = 0;\n}", "function updateScores() {\n scope.$el.find('.js-score-value').text(model.prediction[team])\n }", "function putQuestion() {\r\n inputLabel.innerHTML = questions[position].question\r\n inputField.value = ''\r\n\tdocument.getElementById('inputField').placeholder = placeholders[position].place\r\n inputField.type = questions[position].type || 'text' \r\n inputField.focus()\r\n showCurrent()\r\n }", "function correct() {\n score += 20;\n document.getElementById(\"quizBody\").innerHTML = \" \";\n next();\n}", "function main() {\n if (done !== total) {\n if (this.textContent === questions[done].answer) {\n // answer is correct\n score++;\n message = \"Correct!\";\n } else {\n // answer is wrong\n message = \"Sorry, the correct answer was: \" + questions[done].answer;\n }\n done++\n notDone--;\n document.querySelector(\"#other-buttons\").classList.remove('hide');\n document.querySelector(\"#answer-buttons\").classList.add('hide');\n writeResults();\n }\n}", "function play(quiz) {\n var score = 0; // initialize score\n update($score, score);\n // initialize time and set up an interval that counts down every second\n var time = 20;\n update($timer, time);\n var interval = window.setInterval(countDown, 1000);\n // hide button and show form\n hide($start);\n show($form);\n // add event listener to form for when it's submitted\n $form.addEventListener('click', function (event) {\n event.preventDefault();\n check(event.target.value);\n }, false);\n var question; // current question\n chooseQuestion();\n\n // nested functions\n\n function chooseQuestion() {\n console.log(\"chooseQuestion() invoked\");\n\n // TODO: Filter the quiz.questions array into a new array\n // that only contains unasked questions.\n\n // TODO: Pick a random question from the filtered list.\n\n ask(question);\n }\n\n function ask(question) {\n console.log(\"ask() invoked\");\n\n // TODO: Remember the question so we don't ask it again.\n\n update($question, quiz.question + question.question + \"?\");\n\n // clear the previous options\n $form.innerHTML = \"\";\n\n // TODO: Generate a randomly ordered list of answers from the\n // correct answer and two incorrect answers.\n var options = [];\n }\n\n function check(answer) {\n console.log(\"check() invoked\");\n if (answer === question.answer) {\n update($feedback, \"Correct!\", \"correct\");\n // increase score by 1\n score++;\n update($score, score)\n } else {\n update($feedback, \"Wrong!\", \"wrong\");\n }\n chooseQuestion();\n }\n\n // this is called every second and decreases the time\n function countDown() {\n // decrease time by 1\n time--;\n // update the time displayed\n update($timer, time);\n // the game is over if the timer has reached 0\n if (time <= 0) {\n gameOver();\n }\n }\n\n function gameOver() {\n console.log(\"gameOver() invoked\");\n // inform the player that the game has finished and tell them how many points they have scored\n update($question, \"Game Over, you scored \" + score + \" points\");\n // stop the countdown interval\n window.clearInterval(interval);\n hide($form);\n show($start);\n }\n }", "function showResult() {\n info_box.classList.remove(\"activeInfo\");\n quiz_box.classList.remove(\"activeQuiz\");\n result_box.classList.add(\"activeResult\");\n const score_text = result_box.querySelector(\".score\");\n const total_score = result_box.querySelector(\".total-score\");\n if (quiz_score >= 0) {\n let score_tag =\n \"<span>You got<p>\" +\n quiz_score +\n \"</p>out of<p>\" +\n quiz_content.length +\n \"</p>Correct</span>\";\n\n let total_score_tag =\n \"<span>Your Score:<p>\" +\n quiz_score * (100 / quiz_content.length) +\n \"</p>/<p>100</p></span>\";\n\n score_text.innerHTML = score_tag;\n total_score.innerHTML = total_score_tag;\n }\n}", "function generateFeedback () {\n let chosen = $('input:checked').val();\n let correct = STORE[questionNum-1]['correctIndex'];\n let response = STORE[questionNum-1]['correctExplanation'];\n $('span.js-correct-answer').text(response);\n if (chosen == correct) {\n updateScore();\n $('.incorrect').addClass('js-hide');\n } else {\n $('.correct').addClass('js-hide');\n };\n}", "function showResult() {\n const questionElement = document.getElementById('question');\n const optionsElement = document.getElementById('options');\n const nextButton = document.getElementsByTagName('button')[0];\n \n // Hide options and next button\n optionsElement.style.display = 'none';\n nextButton.style.display = 'none';\n \n // Display final score\n questionElement.textContent = `You scored ${score} out of ${quiz.length}!`;\n }", "function updateScreen(result) {\n if (result === 'That is an invalid guess.') {\n // Handle invalid guess\n prompt.innerHTML = `Oops! ${input.value} is not a valid guess.`;\n message.innerHTML = 'Input a number between 1 to 100!';\n } else if (result === 'You have already guessed that number.') {\n // Handle previously guessed numbers\n prompt.innerHTML = result;\n message.innerHTML = 'Input a number between 1 to 100!';\n } else {\n // Prompt is the return value from Game object\n prompt.innerHTML = result;\n updateList(result);\n // Message to user to guide their next guess\n const higherOrLower = game.isLower() ? 'Higher' : 'Lower';\n message.innerHTML = `Guess ${higherOrLower}!`;\n }\n}", "function displayResult(playerChoice, computerChoice) {\n playerChoice = userOptions.options[playerChoice];\n computerChoice = userOptions.options[computerChoice];\n if (playerChoice === computerChoice) {\n output.innerText=\"Tie\";\n }\n else if ((playerChoice === \"Rock\" && computerChoice === \"Scissor\") || (playerChoice === \"Scissor\" && computerChoice === \"Paper\") || (playerChoice === \"Paper\" && computerChoice === \"Rock\")) {\n let currentPlayerScoreValue = +currentPlayerScore.innerText;\n currentPlayerScoreValue++;\n currentPlayerScore.innerText = currentPlayerScoreValue;\n output.innerText=\"Player Wins!!!\"\n }\n else {\n let currentComputerScoreValue = +currentComputerScore.innerText;\n currentComputerScoreValue++;\n currentComputerScore.innerText = currentComputerScoreValue;\n output.innerText=\"Computer Wins!!!\";\n }\n output.style.visibility=\"visible\";\n setTimeout(() => {\n output.style.visibility=\"hidden\";\n }, 1000);\n\n}", "function result(){\n $(\"#questionScreen\").hide();\n $(\"#resultScreen\").show();\n\n\n \n $(\"#attemptQuestion\").text(attempt);\n $(\"#correctAnswers\").text(score);\n}", "function processInput() {\r\n let construction = $(\"#opaqueThick\").val();\r\n let constructionType = $(\"#insulationOptions option:selected\").val();\r\n let window = $(\"#windowSlider\").val();\r\n let chapters = $(\"#chapters\").val()\r\n \r\n\r\n draw(construction, window);\r\n opaqueThick(construction, constructionType);\r\n calculateOutputBoxes(construction, window);\r\n concept();\r\n\r\n \r\n\r\n}", "refreshPage() {\n console.log(\n \"\\n\" +\n this.selectedWord.updateDisplay() +\n \"\\n\\nScore: \" +\n this.score +\n \"\\nGuesses Remaining: \" +\n this.guesses +\n \"\\nGuessed Letters: \" +\n this.guessedLetters\n );\n }", "function displayQuestion() {\n\n\t\tconsole.log(questionNumber);\n\t\tconsole.log(questionBank[questionNumber]);\n\n\t\tvar flag = 0;\t//To check when an option was pressed\n\t\tvar flag_correct = 0; //To check if the option selected was correct\n\n\t\tq1=questionBank[questionNumber][1];\n\t\tq2=questionBank[questionNumber][2];\n\t\tq3=questionBank[questionNumber][3];\n\t\tq4=questionBank[questionNumber][4];\n\t\texplanation=questionBank[questionNumber][6];\n\t\thint=questionBank[questionNumber][7];\n\n\t\t$(stage).append('<div class=\"questionText\">'+questionBank[questionNumber][0]+'</div><div id=\"1\" class=\"option\">'+q1+'</div><div id=\"2\" class=\"option\">'+q2+'</div><div id=\"3\" class=\"option\">'+q3+'</div><div id=\"4\" class=\"option\">'+q4+'</div>');\n\n\t\tif(typeof(hint)==='string') {\n\t\t\t$(stage).append('<br><br><div class=\"hintButton\"> Hint! <span class=\"hint\">'+hint+'</span> </div>');\n\t\t}\n\n\t\tfunction onTimer() {\n\t\t\ttimer.innerHTML = \"Timer: \" + timer_clock + \" seconds\";\n\t\t\ttimer_clock--;\n\t\t\tconsole.log(timer_clock);\n\t\t\tif (timer_clock < 0) {\n\t\t\t\talert('Time\\'s up');\n\t\t\t\ttimer_clock = 30;\t//Rest but no scores\n\t\t\t\treturn;\n\t\t\t}\n\t\t\telse if(flag == 1) {\t//An option was selected hence, stop and rest the timer\n\t\t\t\t\n\t\t\t\tif(flag_correct == 1) {\t\t//The correct option was selected\n\t\t\t\t\tif(timer_clock>=21 && timer_clock<=30) {\t//Answered within the first 10 seconds\n\t\t\t\t\t\toverall_score = overall_score + 15;\n\t\t\t\t\t} else if(timer_clock>=11 && timer_clock<=20) {\t\t//Took 10 to 20 seconds\n\t\t\t\t\t\toverall_score = overall_score + 10;\n\t\t\t\t\t} else if(timer_clock>=1 && timer_clock<=10) {\t\t//Took 20 to 30 seconds\n\t\t\t\t\t\toverall_score = overall_score + 5;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t//Took more than 30 seconds, no score awarded, do nothing\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\ttimer_clock = 30;\n\t\t\t\ttimer.innerHTML = \"Timer\";\n\t\t\t\treturn;\n\t\t\t}\n\t\t\telse {\n\t\t\t setTimeout(onTimer, 1000);\n\t\t\t}\n\t\t}\n\n\t\tonTimer();\t//Start the timer after displaying question\n\n\t\t$('.option').click(function() {\n\t\t\tflag = 1;\n\t\t\tif(questionLock == false) {\n\t\t\t\tquestionLock = true;\t\n\n\t\t\t\t//correct answer\n\t\t\t\tif(this.id==questionBank[questionNumber][5]) {\n\t\t\t\t\tflag_correct = 1;\n\t\t\t\t\t$(stage).append('<div class=\"feedback1\">CORRECT</div>');\n\t\t\t\t\tresult[resultNumber] = 1;\n\t\t\t\t\tresultNumber++;\n\t\t\t\t\tscore++;\n\t\t\t\t}\n\n\t\t\t\t//wrong answer\t\n\t\t\t\tif(this.id!=questionBank[questionNumber][5]) {\n\t\t\t\t\t$(stage).append('<div class=\"feedback2\">WRONG</div>');\n\t\t\t\t\tresult[resultNumber] = 0;\n\t\t\t\t\tresultNumber++;\n\t\t\t\t}\n\n\t\t\t\tdocument.getElementById(\"explanation\").innerHTML = explanation;\n\n\t\t\t\t// Get the modal\n\t\t\t\tvar modal = document.getElementById(\"myModal\");\n\n\t\t\t\t// Get the <span> element that closes the modal\n\t\t\t\tvar span = document.getElementsByClassName(\"close\")[0];\n\n\t\t\t\tmodal.style.display = \"block\";\n\n\t\t\t\t// When the user clicks on <span> (x), close the modal\n\t\t\t\tspan.onclick = function() {\n\t\t\t\t\tmodal.style.display = \"none\";\n\t\t\t\t\tsetTimeout(function(){changeQuestion()}, 1000);\n\t\t\t\t}\n\n\t\t\t\t// When the user clicks anywhere outside of the modal, close it\n\t\t\t\twindow.onclick = function(event) {\n\t\t\t\t\tif (event.target == modal) {\n\t\t\t\t\t\tmodal.style.display = \"none\";\n\t\t\t\t\t\tsetTimeout(function(){changeQuestion()}, 1000);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t})\n\t}", "function checkAnswer() {\n //console.log('Answer is being checked')\n const currentAnswer = $( \"input:checked\" ).val();\n const correctAnswerText = getCorrectAnswer();\n \n if (currentAnswer === correctAnswerText) {\n STORE.currentAnswer = 'correctAnswer';\n updateUserScore();\n } else {\n STORE.currentAnswer = 'wrongAnswer';\n } \n}", "function showCorrect() {\n console.log('correct answer submitted');\n updateScore ();\n if (questionIndex < 10) {\n $('main').html(`\n <section class=\"correct-answer\" role=\"main\">\n <h2>Correct!</h2>\n <div>\n <img class=\"feedback-image-correct\" src=\"https://github.com/hotdogmcgee/Thinkful-Quiz-App---Module-8.7-8/blob/master/images/Segovia%20-%20You%20Got%20it%20Right!.jpg?raw=true\" alt=\"Segovia Smiling\">\n </div>\n <button class=\"js-next-question submit-button\">Next Question</button>\n </section>\n `)\n } else {\n //provides See Results button\n //increaseQuestionIndex();\n $('main').html(`\n <section class=\"correct-answer\" role=\"main\">\n <h2>Correct!</h2>\n <div>\n <img class=\"feedback-image-correct\" src=\"https://github.com/hotdogmcgee/Thinkful-Quiz-App---Module-8.7-8/blob/master/images/Segovia%20-%20You%20Got%20it%20Right!.jpg?raw=true\" alt=\"Segovia Smiling\">\n </div>\n <button class=\"js-results-page submit-button\">See Results</button>\n </section>\n `)\n }\n}" ]
[ "0.72625816", "0.67071354", "0.5888808", "0.5870281", "0.5828073", "0.5824714", "0.58144224", "0.5802231", "0.577422", "0.56987923", "0.56887746", "0.56745684", "0.56663615", "0.5627791", "0.5627436", "0.5613489", "0.55984586", "0.55934066", "0.5570111", "0.5563535", "0.55629057", "0.55542916", "0.55504906", "0.55461013", "0.5532929", "0.55270463", "0.5526843", "0.5526558", "0.5516418", "0.55080324", "0.5504324", "0.5492039", "0.5481258", "0.54680884", "0.54664534", "0.54608005", "0.5453648", "0.5451552", "0.54507315", "0.54432666", "0.5442634", "0.54379946", "0.5436334", "0.54336816", "0.5432515", "0.54281247", "0.54236084", "0.5419256", "0.5417815", "0.54148734", "0.54052585", "0.54042935", "0.5401256", "0.540045", "0.53990364", "0.53939813", "0.53912777", "0.53872675", "0.53744966", "0.53733927", "0.53705966", "0.5367294", "0.5363864", "0.5362087", "0.53601485", "0.5356376", "0.5353235", "0.53507906", "0.53489757", "0.5347732", "0.53457147", "0.5344877", "0.53348845", "0.5330447", "0.53304344", "0.53288287", "0.53264403", "0.53251785", "0.53238827", "0.5323356", "0.5321957", "0.5320011", "0.5319908", "0.5315517", "0.5311674", "0.53049767", "0.5300917", "0.52989566", "0.5297634", "0.5291557", "0.5286994", "0.5282096", "0.5279757", "0.5277109", "0.52742213", "0.5273487", "0.5264213", "0.52639705", "0.52634335", "0.5261903" ]
0.770059
0
Evaluate the input typed by the user and change the practice panel state if necessary.
function evaluateInput() { var inputText = my.html.input.value var inputLength = inputText.length // If the tutor is in READY state, and input has been entered, // then set it to RUNNING STATE. if (my.current.state == my.STATE.READY && inputLength > 0) { my.current.startTime = new Date().getTime() my.current.state = my.STATE.RUNNING updatePracticePaneState() log('state', my.current.state.toUpperCase(), 'unit', my.current.unitNo + '.' + my.current.subunitNo, 'type', my.settings.unit) } // Number of characters correctly typed by the user var goodChars = Util.common(my.current.subunitText, inputText) my.current.correctInputLength = goodChars // Validate the input if (goodChars == inputLength) { // Clear error if any if (my.current.state == my.STATE.ERROR) { my.current.state = my.STATE.RUNNING updatePracticePaneState() } } else { // Set and display error if (my.current.state == my.STATE.RUNNING) { my.current.state = my.STATE.ERROR my.current.errors++ updatePracticePaneState() } else if (my.current.state == my.STATE.ERROR) { processInputCommand() } } // Update error rate if (goodChars == 0) { if (my.current.errors == 0) { my.current.errorRate = 0 } else { my.current.errorRate = Number.POSITIVE_INFINITY } } else { my.current.errorRate = 100 * my.current.errors / goodChars } // Check if the complete target text has been typed successfully if (goodChars == my.current.subunitText.length) { my.current.state = my.STATE.COMPLETED updatePracticePaneState() } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function updatePracticePane()\n {\n evaluateInput()\n setTargetText()\n displayTargetText()\n updateProgress()\n updateSpeed()\n updateError()\n updateSmiley()\n\n if (my.current.state == my.STATE.COMPLETED) {\n displayAdvice()\n setResultTooltips()\n\n log('state', my.current.state.toUpperCase(),\n 'unit', my.current.unitNo + '.' + my.current.subunitNo,\n 'type', my.settings.unit,\n 'wpm', my.current.wpm,\n 'error', my.current.errorRate.toFixed(1))\n }\n }", "function updatePracticePaneState()\n {\n switch (my.current.state) {\n\n case my.STATE.READY:\n my.html.practicePane.className = ''\n my.html.input.disabled = false\n my.html.input.focus()\n Util.setChildren(my.html.status, 'READY')\n my.html.status.title = 'Type in the input box below ' +\n 'to begin this lesson.'\n my.html.restartLink.style.visibility = 'hidden'\n break\n\n case my.STATE.RUNNING:\n my.html.practicePane.className = ''\n my.html.input.disabled = false\n my.html.input.focus()\n Util.setChildren(my.html.status, '')\n my.html.status.title = ''\n my.html.restartLink.style.visibility = 'visible'\n break\n\n case my.STATE.ERROR:\n my.html.practicePane.className = 'error'\n my.html.input.disabled = false\n my.html.input.focus()\n my.html.restartLink.style.visibility = 'visible'\n Util.setChildren(my.html.status, 'ERROR!')\n my.html.status.title = 'Fix errors in the input box ' +\n 'by pressing the backspace key.'\n break\n\n case my.STATE.COMPLETED:\n my.html.practicePane.className = 'completed'\n my.html.input.disabled = true\n my.html.input.blur()\n my.html.restartLink.style.visibility = 'visible'\n Util.setChildren(my.html.status, 'COMPLETED')\n my.html.status.title = 'You have completed this lesson.'\n break\n }\n\n }", "function processInputCommand()\n {\n var inputText = my.html.input.value\n var goodChars = my.current.correctInputLength\n\n if (inputCommandIs('restart') || inputCommandIs('rst')) {\n location.href = '#restart'\n } else if (inputCommandIs('fix') || inputCommandIs('xxx')){\n my.html.input.value = inputText.substring(0, goodChars)\n updatePracticePane()\n } else if (inputCommandIs('qtpi')) {\n qtpi()\n }\n }", "function readAndCheckInput(){\n\tanswerNumber = parseInt(inputField.value, toBase);\n\tif(answerNumber == problemNumber){\n\t\tproblem.style.color = 'green';\n\t\tproblem.innerHTML = 'Correct. \\n Press \"New Question\" to continue';\n\t}else{\n\t\tproblem.style.color = 'red';\n\t\tproblem.innerHTML =\n\t\t \"Wrong! \\nThe correct answer was \" \n\t\t + problemNumber.toString(toBase);\n\t}\n\tstate = TEXT_STATE;\n}", "function proceed(difficultyLvl) {\n randomWords();\n input.value = \"\";\n showInput.innerText = \"Value displays here\";\n input.focus();\n switch (difficultyLvl) {\n case \"Easy\":\n s += 4;\n break;\n case \"Hard\":\n s += 3;\n break;\n case \"Very Hard\":\n s += 2;\n break;\n default:\n s += 4;\n }\n console.log(s);\n score += 3;\n scoreSheet.innerText = score;\n}", "function userChoice(choice){\n setHulkChoice();\n evaluate(choice);\n}", "function inputChange (e) {\n var isCorrect = game.check(this.value),\n wordObj,\n i,\n l = game.wordsByIndex.length;\n if (isCorrect) {\n // TODO: run correct animation & move to the next stage\n game.level++;\n game.currentSceneIndex++;\n // sound\n game.soundInstance = createjs.Sound.play(\"Correct\"); // play using id. Could also use full sourcepath or event.src.\n //game.soundInstance.addEventListener(\"complete\", createjs.proxy(this.handleComplete, this));\n game.soundInstance.volume = 0.5;\n window.alert('Correct!');\n loadScene(game.currentSceneIndex)\n this.value='';\n } else if (this.value.length > game.minimumWordLength) {\n for (i = 0; i < l; i++) {\n wordObj = game.wordsByIndex[i];\n if (wordsAreEqual(wordObj.spl, this.value)) {\n game.level--;\n setPopupContent(i, 500, 100);\n // show mask\n jQuery('#mask').show();\n // show pop-up\n jQuery('#popup').show();\n this.value='';\n }\n }\n }\n}", "function checkAnswer(){\n trueAnswer = returnCorrectAnswer();\n userAnswer = getInput();\n// this if statement is stating if user inputs the right answer what happens and if not what happens\n if(userAnswer === trueAnswer){\n var messageCorrect = array[global_index].messageCorrect;\n score ++;\n swal({\n title: messageCorrect,\n text: \"You got \" + score + \" out of 8 correct.\",\n });\n }\n else{\n var messageIncorrect = array[global_index].messageIncorrect;\n swal({\n title: messageIncorrect,\n text: \"You got \" + score + \" out of 8 correct.\",\n });\n }\n }", "function UserInputs(action, input) {\n switch (action) {\n case \"concert-this\":\n runBandsInTown(input);\n fixString(input)\n break;\n case \"spotify-this-song\":\n runSpotify(input);\n fixString(input)\n break;\n case \"movie-this\":\n runOmdb(input);\n fixString(input)\n break;\n case \"do-what-it-says\":\n runRandom(input);\n break;\n default:\n console.log(\"\\n--------------------------------------------------------\");\n console.log(\n \"Please enter a valid argument, such as:\\n\\nnode liri.js movie-this [MOVIE TITLE]\\n\\nnode liri.js spotify-this-song [SONG TITLE]\\n\\nnode liri.js concert-this [ARTIST NAME]\\n\\nnode liri.js do-what-it-says\"\n );\n console.log(\n \"--------------------------------------------------------\\n\\n\"\n );\n }\n}", "function start() {\r\n let answer = document.getElementById(\"textInput\").value;\r\n console.log(\"Type OK to start\");\r\n if (\r\n answer === \"ok\" ||\r\n answer === \"OK\" ||\r\n answer === \"Ok\" ||\r\n answer === \"oK\"\r\n ) {\r\n document.getElementById(\"firstInput\").style.display = \"none\";\r\n document.getElementById(\"secondInput\").style.display = \"\";\r\n document.getElementById(\"textbox\").innerHTML =\r\n \"Pick Your Class: Barbarian, Rogue, Knight\";\r\n console.log(answer);\r\n } else {\r\n document.getElementById(\"textbox\").innerHTML = \"How did you fail? Type OK\";\r\n console.log(\"How did you fail? Type OK\");\r\n console.log(answer);\r\n }\r\n}", "function useInput() {\n checkVar(getInput.value);\n // console.log(getInput.value);\n outputP.innerText = getInput.value;\n getInput.value = \"\";\n \n\n}", "function problem_1() {\n\n problemNumber.innerHTML = 'Problem 1';\n input1.style.visibility = 'visible';\n input1.style.width = '200px';\n input1.placeholder = 'Enter \"number\"';\n\n jsConsole.writeLine('Problem 1. Odd or Even');\n jsConsole.writeLine(' - Write an expression that checks if given integer is odd or even.');\n solutionText();\n\n submit.onclick = function () {\n var num = input1.value * 1;\n\n if (!isNaN(num)) {\n\n var result;\n if (num % 2 === 0) {\n result = 'Even';\n } else {\n result = 'Odd';\n }\n printResult();\n } else {\n\n incorrectInput();\n }\n\n function printResult() {\n jsConsole.writeLine(num + ' is ' + result);\n playWhat();\n }\n }\n}", "function saveInput() {\r\n\t\t\tif (document.getElementById(\"check\").innerHTML == \"New Phrase!\") {\r\n\r\n \tdocument.getElementById(\"result1\").innerHTML= \"A Screwdriver\";\r\n \tdocument.getElementById(\"result2\").innerHTML= \"Ask Rude Arrive Her\";\r\n }\r\n\t\r\n var input = document.getElementById(\"userInput\").value;\r\n document.getElementById(\"result1\").style.visibility = \"visible\";\r\n document.getElementById(\"result2\").style.visibility = \"visible\";\r\n document.getElementById(\"check\").innerText= \"New Phrase!\";\r\n document.getElementById(\"userInput\").value = '';\r\n \t// document.getElementById(\"userInput\").style.border=\"3.5px solid #ff4d4d\";\r\n \t// document.getElementById(\"correct\").style.display = \"none\";\r\n \t// document.getElementById(\"incorrect\").style.display = \"block\";\r\n}", "function action () {\n userInput = document.getElementById('input').value\n userInput = parseInt(userInput)\n // when input is given, the input is stored\n if (userInput < 0) {\n document.getElementById('answer').innerHTML = 'negative'\n // this will display the message negative if the number is negative\n } else {\n document.getElementById('answer').innerHTML = 'positive'\n // this will display the postive message if the number is positive\n }\n}", "handleInputAlice() {\n if (this.state.phaseNumber === 1) {\n this.setState({comment:\"Click on a Word!\"});\n }\n else if (this.state.phaseNumber === 3) {\n //guess mystery word\n if (this.state.aliceInput.toLowerCase() === this.state.mysteryWords[(this.state.mysteryWordId-1)].toLowerCase()){\n this.updatePhaseHUD(4);\n this.setState({phaseNumber:4, comment:\"You got it now!\", aliceNumber: 1});\n this.updateRightGuess();\n } else {\n this.updatePhaseHUD(4);\n this.setState({phaseNumber:4, comment:\"Wrong Guess but still very noice!\"});\n this.updateWrongGuess();\n }\n }\n else if (this.state.phaseNumber === 4) {\n this.setState({comment:\"The Tutorial is already over!\"});\n }\n else {\n this.setState({comment:\"It's not Alice's Turn!\"});\n }\n }", "function incorrectInput() {\n showLevelOverlay();\n getId('currentLevel').style.display = \"none\";\n getId('passOrFail').style.display = \"none\";\n getId('scoreMultiplied').style.display = \"none\";\n getId('normalScore').style.display = \"none\";\n getId('pointsDivider').style.display = \"none\";\n getId('tutorialOrHearts').style.display = \"none\";\n getId('congrats').style.display = \"block\";\n getId('congratsText').style.color = \"#C4273C\";\n getId('congratsText').innerHTML = \"Please enter\";\n getId('highScore').style.display = \"block\";\n getId('highScoreText').style.color = \"#C4273C\";\n getId('highScoreText').innerHTML = \"YOUR NAME!\";\n getId('enterName').style.display = \"block\";\n getId('nameBoxContainer').style.display = \"block\";\n getId('buttonLeftText').innerHTML = \"Reset\";\n getId('buttonRightText').innerHTML = \"Submit\";\n}", "function exercise(input){\n if(input === 'running'){\n var statement = \"Today's excercise: \" + input ; \n }else if (input === 'swimming'){\n var statement = \"Today's excercise: \" + input ; \n }\n return statement; \n}", "function initialPrompt() {\n word = input.question(\"Let's play some scrabble!\\n\\nEnter a word to score: \");\n \n /*console.log('\\n' + scrabbleScore.scoring);\n console.log('\\n' + 'Simple Score: ' + simpleScore.scoring());\n console.log('\\n' + 'Vowel Bonus Score: ' + vowelBonusScore.scoring());*/\n \n}", "function evaluate() {\n $('#quizBoard').hide();\n $('#results').show();\n if ($('#q1f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q2t').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q3f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q4f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q5t').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q6t').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q7f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q8f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q9f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n $('#corr').html(correct)\n $('#incorr').html(incorrect)\n $('#percent').html(correct/9)\n}", "function processAnswer() {\r\n var answer = document.getElementById('answer');\r\n // if answer field is empty, do nothing\r\n if (answer.value == \"\") {\r\n return;\r\n }\r\n // increase score if correct\r\n addScore();\r\n checkSuccess();\r\n // take life if wrong\r\n takeLifeAway();\r\n // display gameover if lives = 0\r\n if(checkGameOver()) {\r\n hideGame();\r\n displayGameOver();\r\n }\r\n displayFactors();\r\n answer.value = \"\";\r\n}", "checkAnswer() {\n \n let currentQuestionAnswer = eval(propblems[this.state.currentProblemIndex].question);\n let nextString = null;\n\n if (currentQuestionAnswer == this.state.answerByUser) {\n nextString = \"Clear\";\n this.setState(state => ({\n score:state.score+1\n }))\n } else {\n nextString = \"Wrong\";\n }\n\n\n console.log(this.state.score);\n\n this.setState(state => ({\n currentDisplayingStr: nextString,\n currentProblemIndex: state.currentProblemIndex + 1,\n currentQuestionIndex: null,\n shouldShowInput: false\n }))\n\n this.initiateTest();\n }", "function evaluate(){\n var pc = randed, you = person();\n \n if(pc == you){ document.getElementById(\"eval\").innerHTML=\" Draw \"; }\n else if(pc == 1 && you == 2){document.getElementById(\"eval\").innerHTML=\" PC Scores \";}\n else if(pc== 1 && you == 3){document.getElementById(\"eval\").innerHTML=\" You Scores \";}\n else if(pc==2 && you ==1){document.getElementById(\"eval\").innerHTML=\" You Scores \";}\n else if(pc==2 && you==3){document.getElementById(\"eval\").innerHTML=\" PC Scores \";}\n else if(pc==3 && you==1){document.getElementById(\"eval\").innerHTML=\" PC Scores \";}\n else if(pc==3 && you==2){document.getElementById(\"eval\").innerHTML=\" You Scores \";}\n}", "function runProgram(){\n\n userWord=initialPrompt();\n\n\n\n transformStyle=scoreStylePrompt();\n\n console.log(userWord);\n console.log(transformStyle);\n \n}", "function askUser(){\n setRatingVars();\n checkEvents();\n if(outChooseVal == 1){\n console.log(chalk.cyan(\"\\nYour task has been completed. Select the a validator to continue...\\n\"));\n }\n if(canRate == true){\n giveRating();\n }\n else{\n if(prov == 0)\n inquirer.prompt([questions]).then(answers => {choiceMade(answers.whatToDo)});\n else\n inquirer.prompt([questions1]).then(answers => {choiceMade(answers.whatToDo1)});\n }\n}", "function initialPrompt() {\n let userInput = null;\n let boolean = false;\n while (boolean == false) {\n userInput = input.question(\"Let's play some scrabble! \\nEnter a word to score: \");\n boolean = validateInput(userInput);\n }\n return userInput;\n}", "function evaluator (userAnswer) {\n currentTour;\n correctAnswer;\n if (userAnswer === correctAnswer) {\n currentTour = currentTour + 1;\n console.log(\"User wrigt\");\n console.log(\"Tour\",currentTour)\n answerCorrect();\n quizExecutor(currentTour);\n } else {\n currentTour = currentTour + 1;\n console.log(\"User wrong\");\n console.log(\"Tour\",currentTour);\n answerWrong();\n quizExecutor(currentTour);\n };\n }", "function change () {\n setAnswer(this.value)\n // If the appearance is 'quick', then also progress to the next field\n if (fieldProperties.APPEARANCE.includes('quick') === true) {\n goToNextField()\n }\n}", "evaluate() {\n // If the last character in the\n // current display is a number\n // (For the case where an operator\n // was input last)\n if (this.state.display.match(/\\d$/)) {\n // Remove unnecessary operators\n let evaluate = this.state.display.replace(\n /[\\*\\-\\+\\/]+(?!\\-?\\d)/g,\n ''\n );\n // Evaluate answer\n let answer = eval(evaluate);\n // Update display to show answer\n // and formula to show the\n // evaluated equation\n this.setState({\n display: answer.toString(),\n formula: this.state.display + '=' + answer,\n });\n }\n }", "function userInputClick() {\n // Get input from user and store it in variable\n const age = parseInt(document.getElementById(\"age-entered\").value)\n const day = document.getElementById(\"day-entered\").value\n\n // Checks if user should go to the movies\n if ((day == \"tuesday\" || day == \"thursday\") || (age > 12 && age < 21)) {\n document.getElementById(\"output\").innerHTML = \"You should go to the museum because you will get a discount\"\n } else {\n document.getElementById(\"output\").innerHTML = \"You should not go to the museum today because you will not get a discount\"\n }\n}", "function getInput(){\n return prompt(\"Enter your score:\");\n}", "function introQ(evt){\nlet event = evt;\n if (evt == 'yes'){\n addScore('Compliant', 5)\n first.style.display = \"none\";\n ypage.style.display = \"inline-block\"; \n } else if (evt == \"y1\"){\n addScore('Compliant', 3)\n beginQuiz('y')\n }else if (evt == \"y2\"){\n addScore('Compliant', 2)\n beginQuiz('y')\n }else if (evt == \"y3\"){\n addScore('Compliant', 1)\n beginQuiz('y')\n }else if (evt == \"y4\"){\n addScore('Fool', 5)\n beginQuiz('y')\n } else if (evt == 'no'){\n addScore('Resistant', 5)\n addScore('Troll', 5)\n first.style.display = \"none\";\n npage.style.display = \"inline-block\";\n } else if (evt == \"n1\"){\n addScore('Resistant', 3)\n beginQuiz('n')\n } else if (evt == \"n2\"){\n addScore('Resistant', 2)\n beginQuiz('n')\n } else if (evt == \"n3\"){\n addScore('Resistant', 1)\n beginQuiz('n')\n } else if (evt == \"n4\"){\n addScore('Fool', 5)\n beginQuiz('n')\n } \n}", "function executeInput(event){\n // get input and put into array, filter out empty cell at end due to extra space\n let input = display.textContent.split(' ').filter(item => item !== '' && item);\n // if not enough inputs return immediately\n if (input.length < 3) {\n return;\n }\n // if the last input was an operator trim it off the end\n if (operators.includes(input[input.length - 1])) {\n input.splice(input.length - 1, 1);\n }\n // generate ratings array, element at each index will correspond to MDAS rating of each element in input array, numbers will be 0\n let ratings = input.map(item => operators.includes(item) ? mdas[item] : 0);\n // run calculations \n result = calculateResults(input, ratings);\n // if the result is a solid number display it, otheriwse trim to 5 decimal places then display, when sent as number to string it will also trim trailing zeros \n if (Number.isInteger(result)) {\n display.textContent = `${result} `;\n } else {\n display.textContent = `${Number(result.toFixed(5))} `;\n }\n }", "function doLogic() {\n \"use strict\";\n // Here we snatch values from the answer box....\n var Formula = document.getElementById(\"answerBox\").value;\n // Evaluate the formula....\n var Result = eval(\"(\" + Formula + \")\");\n // Display results!\n li(Result);\n\n // Check and handle any errors that occur during formula evaluation.\n if (answerBox.value === \"undefined\") {\n document.getElementById(\"answerBox\").value = \"Syntax Error\";\n }\n if (answerBox.value === \"NaN\") {\n document.getElementById(\"answerBox\").value = \"Not Possible!\";\n }\n}", "function processInput() {\n string = inputForm.value.toLowerCase();\n raiseError = checkInputError(string);\n\n if (raiseError) {\n showInputError();\n }\n else if (string != body.style.backgroundColor) {\n setColour(string);\n }\n}", "function university(){\n\n let study = prompt('In which university i have studied do you think \"JUST\" or \"YARMOUK\" ?').toUpperCase();\n if (study === 'JUST') {\n alert('TRUE ! I love it so much');\n score++;\n } else if (study === 'YARMOUK') {\n alert('lovely one but no ! try again ;)');\n prompt('which one do you think now ?');\n }\n \n}", "function displayAnswerEvaluation(p_totalCorrect, p_totalIncorrect){\n\t // see if correct....\n\t var tTotalCorrect = p_totalCorrect;\n\t\t var tTotalIncorrect = p_totalIncorrect;\n\t\t \n\t\t // catch if this is the last attempt\n\t\t var tLastAttempt = false;\n\t\t if (_currVars.myVars.attemptsAllowed === 0){\n\t\t\tvar tLastAttempt = true;\n\t\t }\n\t\t\n\t\t // ANSWER IS CORRECT\n\t\t if ((tTotalCorrect === _currVars.myVars.correctAnswerCount) && (tTotalIncorrect === 0) ){\n\t\t\t\n\t\t\tconsole.log(\"correct -- feedback_correct_vo_1 or feedback_correct_vo_2\");\n\t\t\t\n\t\t\t//_currVars.myVars.checkbuttonstates.\n\t\t _currVars.myVars.checkbuttonstates.currState =\t_currVars.myVars.checkbuttonstates.COMPLETED_CORRECT;\n\t\t _myDispatcher.setCheckButtonToCorrect();\n\t\t\n\t\t _currVars.myVars.allowCheckbuttonInteraction = false;\n\t\t\n\t\t sendState();\n\t\t\n\t\t turnAllClickHandlersOff();\n\n\t\t playFeedBack(\"feedback_correct\",\"getsoundcallback\",tLastAttempt );\n\t\t \n\t\t\t\n\t\t } else if (_currVars.myVars.attemptsAllowed === 1000){\n\t\t\t/* FEEDBACK_LAST_ATTEMPT ************************************************************************ REPLACE THIS */\n\t\t\t// REMOVE THIS AREA\n\t\t\t//console.log(\"game over- incorrect - see you teacher -- feedback_last_attempt\");\n\t\t\t\n\t\t\t//_myDispatcher.setCheckButtonToIncorrect();\n\t\t\t//_currVars.myVars.checkbuttonstates.currState =\t_currVars.myVars.checkbuttonstates.COMPLETED_INCORRECT;\n\t\t\t//turnAllClickHandlersOff();\n\n\t\t\t//playFeedBack(\"feedback_last_attempt\",\"getsoundcallback\");\n\t\t\t\n\t\t\t\n\t\t } else if (_currVars.myVars.feedbackSetup === \"single\" ){\n\n\t\t //console.log(\"that is not correct - feedback_incorrect\");\n\n\t\t\tif (tLastAttempt === true){\n\t\t\t\tsetScreenToIncorrect()\n\t\t\t\tplayFeedBack(\"feedback_incorrect\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\t\t} else{\n\t\t\t\t_currVars.myVars.setButtonToActiveAfterFeedback = true;\n\t\t\t\tsendState();\n\t\t\t\tplayFeedBack(\"feedback_incorrect\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\n\t\t\t}\n\t\t\n\t\t\n\t\t\n\t\t\t\n\t\t } else if ((tTotalCorrect < _currVars.myVars.correctAnswerCount)&& ( tTotalIncorrect === 0)){\n\n\t\t\tconsole.log(\"you need to choose more answers -- feedback_not_all_correct\");\n\n\t\t\tif (tLastAttempt === true){\n\t\t\t\tsetScreenToIncorrect()\n\t\t\t\tplayFeedBack(\"feedback_not_all_correct\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\t\t} else{\n\t\t\t\t_currVars.myVars.setButtonToActiveAfterFeedback = true;\n\t\t\t\tsendState();\n\t\t\t\tplayFeedBack(\"feedback_not_all_correct\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\n\t\t\t}\n\t\t\t\n\t } else if(tTotalIncorrect === 1){\n\n\t\t console.log(\"one of your answers is incorrect - feedback_one_wrong\");\n\n\t\t if (tLastAttempt === true){\n\t\t\t\tsetScreenToIncorrect()\n\t\t\t\tplayFeedBack(\"feedback_one_wrong\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\t\t} else{\n\t\t\t\t_currVars.myVars.setButtonToActiveAfterFeedback = true;\n\t\t\t\tsendState();\n\t\t\t\tplayFeedBack(\"feedback_one_wrong\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\n\t\t\t}\n\n\t\t\n\t } else if(tTotalIncorrect < (tTotalIncorrect + tTotalCorrect) ){\n\n\t\t\tconsole.log(\"some of your answers are incorrect -- feedback_some_wrong\");\n\n\t\t\tif (tLastAttempt === true){\n\t\t\t\tsetScreenToIncorrect()\n\t\t\t\tplayFeedBack(\"feedback_some_wrong\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\t\t} else{\n\t\t\t\t_currVars.myVars.setButtonToActiveAfterFeedback = true;\n\t\t\t\tsendState();\n\t\t\t\tplayFeedBack(\"feedback_some_wrong\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t\n\t } else{\n\n\t\t if (tLastAttempt === true){\n\t\t\t\tsetScreenToIncorrect()\n\t\t\t\tplayFeedBack(\"feedback_all_wrong\",\"getsoundcallback\",tLastAttempt);\n\t\t\t\t\t} else{\n\t\t\t\t_currVars.myVars.setButtonToActiveAfterFeedback = true;\n\t\t\t\tsendState();\n\t\t\t\tplayFeedBack(\"feedback_all_wrong\",\"getsoundcallback\",tLastAttempt);\n\t\t\t}\n\t\t\n\t }\t \t\t\n }", "function processInput(input) {\n switch (input) {\n case \"=\":\n calculate();\n break;\n case \"ce\":\n clearEntry();\n break;\n case \"ac\":\n clearAll();\n break;\n case \"/\":\n case \"*\":\n case \"+\":\n case \"-\":\n case \".\":\n case \"0\":\n validateInput(input);\n break;\n default:\n updateDisplay(input);\n }\n}", "function initialPrompt() {\n console.log(\"Let's play some scrabble!\");\n\n wordEntered = input.question(\"Enter a word to score: \");\n}", "function handlerGame(event) {\n //Need to prevent the default behaviour through the method:\n event.preventDefault();\n\n //Save user number each time \n const userTrial = (inputEl.value);\n //Converted to number (parsing)\n const userTrialParsed = parseInt(userTrial);\n // console.log(userTrial, userTrialParsed);\n\n //Call the function that evaluates the number and show results \n // evaluateNumber2(userTrial,userTrialParsed);\n evaluateNumber3(userTrialParsed);\n\n //Call the function that sets the accumulator according to the user's trials; \n countUserTrials();\n}", "function doAnswer() {\r\n\tif(checkAnswer()) {\r\n\t\tdocument.getElementById(\"err\").innerHTML = \"\";\r\n\t\tdocument.getElementById(\"notif\").innerHTML = \"CORRECT\";\r\n\t} else {\r\n\t\tdocument.getElementById(\"notif\").innerHTML = \"\";\r\n\t\tdocument.getElementById(\"err\").innerHTML = \"MISTAKE\";\r\n\t}\r\n\t//\tclear all user input text\r\n\tdocument.getElementById(\"answer\").value = \"\";\r\n\t\r\n\t//\tFocus on input\r\n\tdocument.getElementById(\"answer\").focus();\r\n}", "function topic_answered() {\n\t//do stuff like check validity and sending answer to db\n\tif (document.getElementById(\"answer-input\").value.replace(/^\\s+|\\s+$/g,\"\") === \"\"){\n\t\talert(\"Missing some text here\");\n\t}else{\n\t\tcheck_correctness();\n\t\tchange_topic();\n\t}\n}", "function checkAnswer() {\n //console.log('Answer is being checked')\n const currentAnswer = $( \"input:checked\" ).val();\n const correctAnswerText = getCorrectAnswer();\n \n if (currentAnswer === correctAnswerText) {\n STORE.currentAnswer = 'correctAnswer';\n updateUserScore();\n } else {\n STORE.currentAnswer = 'wrongAnswer';\n } \n}", "function Getstats()\n{\n if (input==0)\n {\n readline.question(\"\\n\\nPlease tell me your name. \", playername =>\n {\n console.log(\"\\nYou have chosen the name: %s. \", playername);\n playernamesw = 1;\n holdname = playername;\n health=100;\n mana=50;\n gold=10;\n playerlvl = 1;\n playerloc = [0, 0, 0];\n savedatasw = 1;\n input = 1;\n Save();\n Graphic2();\n Map();\n Hud();\n Commands();\n });\n }\n}", "function given_answer() {\n return userInput.value;\n}", "function evaluateAnswer(event) {\n event.preventDefault();\n\n evaluateDiv.classList.remove(\"off\");\n evaluateDiv.classList.add(\"on\");\n\n // If answer is right, show \"Correct!\" for a second.\n if (event.target.textContent === questions[currentQuestion].answer) {\n rightOrWrongEl.textContent = \"Correct!\";\n } // If answer is wrong, show \"Wrong!\" for a second.\n else {\n rightOrWrongEl.textContent = \"Wrong!\";\n\n // Time penalty for getting the answer wrong.\n if (secondsLeft > 10) {\n secondsLeft -= 10;\n timeEl.textContent = secondsLeft;\n }\n }\n currentQuestion++;\n\n // Make the evaluate div disappear\n setRightOrWrongTime();\n}", "function classPick() {\r\n let answer = document.getElementById(\"textInput\").value;\r\n if (\r\n (answer === \"rogue\") |\r\n (answer === \"Rogue\") | \r\n (answer === \"ROGUE\")) {\r\n document.getElementById(\"textbox\").innerHTML =\r\n \"You have chosen the quick but fragile Rogue\";\r\n health = 80;\r\n speed = 7;\r\n strength = 4;\r\n console.log(\"Pick Your Class: Barbarian, Rogue, Knight\");\r\n console.log(answer);\r\n console.log(\"You have chosen the quick but fragile Rogue\");\r\n console.log(\r\n \"Health: \" + health + \" Speed: \" + speed + \" Strength: \" + strength\r\n );\r\n document.getElementById(\"secondInput\").style.display = \"none\";\r\n document.getElementById(\"thirdInput\").style.display = \"\";\r\n characterClass = \"Rogue\"\r\n } else if (\r\n (answer === \"knight\") |\r\n (answer === \"Knight\") |\r\n (answer === \"KNIGHT\")\r\n ) {\r\n document.getElementById(\"textbox\").innerHTML =\r\n \"You have chosen the sturdy Knight\";\r\n\r\n health = 100;\r\n speed = 5;\r\n strength = 5;\r\n console.log(\"Pick Your Class: Barbarian, Rogue, Knight\");\r\n console.log(answer);\r\n console.log(\"You have chosen the sturdy Knight\");\r\n console.log(\r\n \"Health: \" + health + \" Speed: \" + speed + \" Strength: \" + strength\r\n );\r\n document.getElementById(\"secondInput\").style.display = \"none\";\r\n document.getElementById(\"thirdInput\").style.display = \"\";\r\n characterClass = \"Knight\"\r\n } else if (\r\n (answer === \"barbarian\") |\r\n (answer === \"Barbarian\") |\r\n (answer === \"BARBARIAN\")\r\n ) {\r\n document.getElementById(\"textbox\").innerHTML =\r\n \"You have chosen the mighty Barbarian\";\r\n health = 125;\r\n speed = 4;\r\n strength = 7;\r\n console.log(\"Pick Your Class: Barbarian, Rogue, Knight\");\r\n console.log(answer);\r\n console.log(\"You have chosen the mighty Barbarian\");\r\n console.log(\r\n \"Health: \" + health + \" Speed: \" + speed + \" Strength: \" + strength\r\n );\r\n document.getElementById(\"secondInput\").style.display = \"none\";\r\n document.getElementById(\"thirdInput\").style.display = \"\";\r\n } else {\r\n document.getElementById(\"textbox\").innerHTML =\r\n \"Type your class: Barbarian, Rouge, Knight\";\r\n console.log(\"Type your class: Barbarian, Rouge, Knight\");\r\n console.log(answer);\r\n characterClass = \"Barbarian\"\r\n }\r\n}", "onSubmit(state) {\n this.status = 'answered';\n var choice = this.opt.choices.where({ value: state.value })[0];\n this.answer = choice.short || choice.name;\n\n // Re-render prompt\n this.render();\n this.screen.done();\n this.done(state.value);\n }", "onSubmit(state) {\n this.status = 'answered';\n var choice = this.opt.choices.where({ value: state.value })[0];\n this.answer = choice.short || choice.name;\n\n // Re-render prompt\n this.render();\n this.screen.done();\n this.done(state.value);\n }", "function checkAnswer() {\r\n STORE.view = 'feedback';\r\n let userSelectedAnswer = STORE.userAnswer;\r\n let correctAnswer = STORE.questions[STORE.questionNumber].correctAnswer;\r\n console.log('Checking answer...');\r\n if (userSelectedAnswer == correctAnswer) {\r\n STORE.score++;\r\n STORE.correctAnswer = true;\r\n }\r\n else {\r\n STORE.correctAnswer = false;\r\n }\r\n}", "function runGame(gameType){\n\n document.getElementById(\"answer-box\").value = \"\";\n\n let num1 = Math.floor(Math.random() *25) + 1;\n let num2 = Math.floor(Math.random() *25) + 1;\n\n// DISPLAY QUESTION\n if(gameType === \"addition\"){\n displayAdditionQuestion(num1, num2);\n calculateCorrectAnswer();\n }else if(gameType === \"multiply\"){\n displayMultiplyQuestion(num1, num2);\n calculateCorrectAnswer();\n }else if(gameType === \"divide\"){\n displayDivideQuestion(num1, num2);\n calculateCorrectAnswer();\n}else if(gameType === \"substract\"){\ndisplaySubtractQuestion(num1, num2);\ncalculateCorrectAnswer();\n}else{\n alert(`Unknown game type: ${gameType}`);\n throw `Unknown game type: ${gameType}. Aborting!`;\n }\n\n}", "function processInput() {\r\n let construction = $(\"#opaqueThick\").val();\r\n let constructionType = $(\"#insulationOptions option:selected\").val();\r\n let window = $(\"#windowSlider\").val();\r\n let chapters = $(\"#chapters\").val()\r\n \r\n\r\n draw(construction, window);\r\n opaqueThick(construction, constructionType);\r\n calculateOutputBoxes(construction, window);\r\n concept();\r\n\r\n \r\n\r\n}", "function update_variables(state, input) {\n switch (state) {\n\n case 'digit':\n if (input == \".\" && decimal_clicked) {\n return;\n }\n if (input == \".\" && !decimal_clicked) {\n decimal_clicked = true;\n }\n\n new_operand += input;\n\n if (digit_click_num <= 1) {\n equation_array.push(new_operand);\n }\n else {\n equation_array[equation_array.length - 1] = new_operand;\n }\n break;\n\n case 'operator':\n new_operator = input;\n if (operator_click_num <= 1) {\n equation_array.push(new_operator);\n }\n else {\n equation_array.pop();\n equation_array.push(new_operator);\n }\n new_operand = '';\n new_operator = '';\n break;\n\n case 'parentheses':\n new_operator = input;\n equation_array.push(new_operator);\n new_operand = '';\n new_operator = '';\n break;\n\n\n }\n}", "function isUserInputCorrect(state, userInput) {\n // Creates userInput array\n // state.userChoice.push(userInput);\n\n state.lastQuestionCorrect = false;\n if(state.questions[state.currentQuestion].answer === parseInt(userInput,10)) {\n state.score++;\n state.lastQuestionCorrect = true;\n }\n updateViewToFeedbackPage(state, 'feedback');\n}", "function initialPrompt(data) {\n wordTobeScored = input.question(\"Let's play some scrabble! Enter a word:\");\n //console.log(oldScrabbleScorer(wordTobeScored));\n return wordTobeScored;\n\n}", "function initialPrompt() {\n console.log(\"Let's play some scrabble!\");\n return input.question(\"Enter a word to score:\");\n }", "function clickedCorrect() {\n $(\"#correctInput\").show();\n $(\"#wrongInput\").hide();\n if (clickedCorrect) {\n yourScore +=10;\n };\n }", "function evalChoice () {\n\t\tvar selection = $(\"input[type='radio']:checked\").val();\n\t\tvar defaultText = $(\".rank > p\").text(\"If you'd like a promotion, click NEW GAME below to try again.\");\n\t\t\t\tif(selection == questions[currentQuestion].correctAnswer) {\n\t\t\t\t\tnumCorrect++;\n\t\t\t\t\tconsole.log(numCorrect);\n\t\t\t\t\t//increment number of correct answers, tracks amount of correct answers\n\t\t\t\t\t$(\".feedback\").append(\"<h3>CORRECT</h3>\" + \"<p>\" + questions[currentQuestion].explanation + \"</p>\");\n\t\t\t\t\t//show feedback positive\n\t\t\t\t\tif (numCorrect == 1) {\n\t\t\t\t\t\t$(\"aside.score > #one\").removeClass().addClass(\"stars_appear\");\n\t\t\t\t\t\t $(\".rank > h4\").text(\"You've earned the rank of a BRIGADIER GENERAL!\");\n\t\t\t\t\t\t defaultText;\n\t\t\t\t\t}\n\t\t\t\t\telse if (numCorrect == 2) {\n\t\t\t\t\t\t$(\"aside.score > #two\").removeClass().addClass(\"stars_appear\"); \n\t\t\t\t\t\t$(\".rank > h4\").text(\"You've earned the rank of a MAJOR GENERAL!\");\n\t\t\t\t\t\tdefaultText;\n\t\t\t\t\t}\n\t\t\t\t\telse if (numCorrect == 3) {\n\t\t\t\t\t\t$(\"aside.score > #three\").removeClass().addClass(\"stars_appear\"); \n\t\t\t\t\t\t$(\".rank > h4\").text(\"You've earned the rank of a LIEUTENANT GENERAL!\");\n\t\t\t\t\t\tdefaultText;\n\t\t\t\t\t}\n\t\t\t\t\telse if (numCorrect == 4) {\n\t\t\t\t\t\t$(\"aside.score > #four\").removeClass().addClass(\"stars_appear\"); \n\t\t\t\t\t\t$(\".rank > h4\").text(\"You've earned the rank of a GENERAL!\");\n\t\t\t\t\t\tdefaultText;\n\t\t\t\t\t}\n\t\t\t\t\telse if (numCorrect == 5) {\n\t\t\t\t\t\t$(\"aside.score > #five\").removeClass().addClass(\"stars_appear\"); \n\t\t\t\t\t\t$(\".rank > h4\").text(\"You've earned the highest rank of a FIVE-STAR GENERAL!\");\n\t\t\t\t\t\t$(\".rank > p\").text(\"This rank is specially reserved for wartime generals. You're ready to join the ranks of only NINE Americans who have held this title!\");\n\t\t\t\t\t}\n\t\t\t\t\t//Star will appear if correct\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t$(\".feedback\").append(\"<h3>INCORRECT</h3>\" + \"<p>\" + questions[currentQuestion].explanation + \"</p>\");\n\t\t\t\t\t//show feedback negative\n\t\t\t\t\tif(numCorrect == 0) {\n\t\t\t\t\t\t$(\".rank > h4\").text(\"You've created a new rank which prevents you from leading troops into battle.\");\n\t\t\t\t\t\t$(\".rank > p\").text(\"If you'd like a promotion, click NEW GAME below to try again.\")\n\t\t\t\t\t}\n\t\t\t\t}\n\t}", "function startUp(userInput) { \nvar compuServe = computerChoice();\n \n if (compuServe === userInput) \n { \n result = document.getElementById('result').innerHTML = \"A tie is better than nothing\";\n \n }\n else if (userInput === \"Rock\") \n {\n if (compuServe === \"Paper\") \n {\n result = document.getElementById('result').innerHTML = \"You Lost\";\n\n \n }\n else \n {\n result = document.getElementById('result').innerHTML = \"You Won\";\n\n }\n } \n else if (userInput === \"Paper\") \n { \n \n if (compuServe === \"Scissor\") \n {\n result = document.getElementById('result').innerHTML = \"You Lost\";\n \n\n }\n else \n {\n result = document.getElementById('result').innerHTML = \"You Won\";\n\n } \n } \n else if (userInput === \"Scissor\") \n {\n if (compuServe === \"Rock\") \n {\n result = document.getElementById('result').innerHTML = \"You Lost\";\n\n }\n else \n {\n result = document.getElementById('result').innerHTML = \"You Won\";\n \n\n }\n }\n document.getElementById('you').innerHTML = userInput;\n document.getElementById('computer').innerHTML = compuServe;\n counter();\n \n\n \n}", "show() {\n this.printUi();\n this.rl.question(\"> \", term => {\n let matchingEntries = this.compareSearchWords(term, [\"go get milk\", \"something\", \"milk\", \"grab food\"]); //TODO connect to State**\n this.printResultsUi(term, matchingEntries);\n this.rl.question(\"Enter to return to the main screen. \", () => {\n const screen = new MainScreen(this.rl, this.state);\n screen.show();\n });\n });\n }", "function runGame(gameType) {\n\n document.getElementById(\"answer-box\").value = \"\";\n document.getElementById(\"answer-box\").focus();\n\n // Creates two random numbers between 1 and 25\n let num1 = Math.floor(Math.random() * 25) + 1;\n let num2 = Math.floor(Math.random() * 25) + 1;\n\n if (gameType === \"addition\") {\n displayAdditionQuestion(num1, num2);\n } else if (gameType === \"multiply\") {\n displayMultiplyQuestion(num1, num2);\n } else if (gameType === \"subtract\") {\n displaySubtractQuestion(num1, num2);\n }\n else {\n alert(`Unknown game type: ${gameType}`);\n throw `Unkown game type: ${gameType}. Aborting!`;\n }\n\n}", "function initialPrompt() {\n word=input.question(\"Let's play some scrabble! Enter a word to score:\");\n}", "function feedbackForAnswer(answer) {\n var curvature = TreeConstructor.root.curvature;\n var suffix = \". \" + CONTINUE_BUTTON;\n if (curvature == answer) {\n var message = \"The expression is \" + \n CURVATURE_DISPLAY_NAME[curvature] + suffix;\n $(TreeConstants.ERROR_DIV).html('<div class=\"alert alert-success\">' +\n '<span><strong>Correct!</strong> ' + message + '</span></div>')\n } else {\n var message = \"The expression is \" + CURVATURE_DISPLAY_NAME[curvature] + \n \", but you answered \" + CURVATURE_DISPLAY_NAME[answer] +\n suffix;\n $(TreeConstants.ERROR_DIV).html('<div class=\"alert alert-error\">' +\n '<span><strong>Incorrect!</strong> ' + message + '</span></div>')\n }\n // Increase/decrease difficulty\n updateLevel(curvature == answer);\n // Listen to new expression button.\n $(\"#newExpression\").click(loadNewExpression);\n }", "function OnCorrectChoice() {\n //Gets player name input: executes once\n if (!nameInputted) {\n if ($(\"name\").value !== \"\") {\n name = $(\"name\").value;\n //If inputted value is null, the character's name remains the default\n }\n nameInputted = true;\n }\n \n //Progresses game, executes for all stages of the game\n progressGame(tracker);\n}", "function userInput(option, input){\n switch (option) {\n case 'concert-this':\n concertInfo(input);\n break; \n \n case 'spotify-this-song': \n songInfo(input);\n break; \n \n case 'movie-this': \n movieInfo(input); \n\n break; \n\n case 'do-what-it-says':\n showInfo();\n break; \n\n default: \n log(\"Invalid\");\n }\n }", "function runQuiz(userLevel, userScore){\n\n\n\n // loads full question page up based on userLevel\n function displayQuestion(userLevel, userScore) {\n \n // resets question number and loads correct question number based on user level\n document.getElementById(\"question-number\").innerHTML = '';\n document.getElementById(\"question-number\").innerHTML += 'Question ' + (userLevel + 1);\n \n // sets the question\n // let q = \"What is blockchain technology?\"\n // var q = answers[0]\n\n ////// USER LEVEL TEST: POP-UP (WILL NOT WORK)\n window.alert(\"userLevel is \" + String(userLevel));\n\n\n // resets question ready to ask next question\n document.getElementById('question').innerHTML = '';\n\n // asks question in typewriter text\n const q = question[userLevel]\n let i = 0\n function askQuestion(){\n setTimeout(function() {\n document.getElementById('question').innerHTML += q.charAt(i);\n i++;\n if (i < q.length) {\n askQuestion();\n }\n }, 100)\n }\n askQuestion()\n\n // defines appear function for later use\n // appear function code adapted from https://stackoverflow.com/questions/2207586/how-do-you-make-something-to-appear-slowly-on-a-page-using-javascript\n // to appear: num = 0 step = positive / to disappear: num = 100 step = negative\n function appear(element, num, step, speed){\n var t_o;\n t_o = setInterval(function(){\n var opacity = num / 100;\n num = num + step; \n if(opacity > 1 | opacity < 0){\n clearInterval(t_o);\n return; \n }\n // modern browsers\n element.style.opacity = opacity;\n // older IE\n element.style.filter = 'alpha(opacity=' + opacity*100 + ')';\n }, speed);\n }\n \n // displays timer after 3 seconds\n function displayTimer() {\n document.getElementById('timer').innerHTML = '1:00';\n setTimeout(function() { \n appear(document.getElementById('timer-box'), 0, 10, 50)\n }, 3000)\n }\n displayTimer()\n\n // displays answers after 4 seconds\n function displayAnswer(userLevel) { \n \n // fades out previous answer on q2 and above, and then hides their shell\n if (userLevel > 0) {\n appear(answerBox[userLevel - 1], 100, -10, 50)\n setTimeout (function(){\n answerBox[userLevel - 1].style.display = \"none\";\n }, 600)\n answerBox[userLevel].style.display = \"block\";\n }\n // fades in answer after 4 seconds\n setTimeout(function() { \n appear(answerBox[userLevel], 0, 10, 50)\n }, 4000)\n }\n displayAnswer(userLevel)\n \n // starts timer once answer has loaded (5 seconds)\n function beginTimer () {\n setTimeout(function() {\n const seconds = 59\n setInterval(function(){\n if (seconds > 9) {\n document.getElementById('timer').innerHTML = '0:' + seconds;\n seconds-- ;\n }\n else if (seconds < 10 & seconds > 0){\n document.getElementById('timer').innerHTML = '0:0' + seconds;\n seconds-- ;\n }\n else {\n document.getElementById('timer').innerHTML = '&#128128';\n }\n }, 1000);\n }, 5000)\n }\n beginTimer()\n }\n displayQuestion(userLevel, userScore)\n\n // TEST FUNCTION\n document.getElementById(\"user-level\").innerHTML = ' userLevel is ' + String(userLevel);\n\n // assess whether correct and adjust user level/score or run fail modal\n function assessAnswer(userLevel, userScore) {\n let a = correctAnswer[userLevel];\n // targets input answer based on userLevel\n let aGiven = document.querySelector('input[name=\"' + answerSelector[userLevel] + '\"]:checked').value\n //let aGiven = document.querySelector('input[name=\"q1\"]:checked').value\n if (aGiven == a){\n userLevel ++;\n // userScore += seconds;\n\n // load next question\n // displayQuestion(userLevel, userScore)\n\n runQuiz(userLevel, userScore)\n }\n else {\n failModal()\n }\n }\n submitButton[userLevel].onclick = function(){\n assessAnswer(userLevel, userScore);\n} \n\n function failModal(userLevel, userScore) {\n // on run displays modal by adding inner html to elements based on userLevel/userScore info saved in array\n // modal also has button to begin quiz again reminding users of prize\n // opens modal on function run (closing modal not an option)\n document.getElementById(\"fmodal\").style.display = \"block\";\n }\n}", "checkInputResult(result, wordDisplay, input){\n\n // saves the individually correct letters by percent to the state\n this.setState({correctChars: result.percent})\n\n // if the gameover, set the timer back to 5 and the score to zero\n if(!this.gameStatus){\n this.setState({\n time : 5,\n score : 0\n }) \n }\n \n // check the characters percent and pass it to the slider\n this.state.correctChars == 95 ?\n slider(this.state.correctChars, false) : \n slider(this.state.correctChars, true)\n\n const typedWordDisplay = document.querySelector('.typedWords')\n const score = document.querySelector('.score')\n score.textContent = this.state.score\n\n // if the input value are the same with the given word\n if(result.same){\n let text = this.state.typedWords\n text.unshift(result.word)\n\n // set the values to the new state\n this.setState({\n time : 5,\n nextWord : this.state.nextWord + 1,\n score : this.state.score + 1,\n typedWords: text\n })\n \n // clear the input area\n input.value = ''\n // display the next word to the screen\n wordDisplay.textContent = this.state.words[this.state.nextWord]\n // flicker the score for effects\n flickNumber(score, this.state.score) \n }\n\n let samp = this.state.typedWords.join(' ')\n // console.log(this.state.typedWords)\n typedWordDisplay.textContent = samp\n }", "function input(e){\n\tlet code = e.keyCode;\n\tif(code == 38) // Up arrow\n\t{\n\t\tif(!started)\n\t\t{\n\t\t\tstarted = true;\n\t\t\tif(result != \"\")\n\t\t\t{\n\t\t\t\tAI.points = 0;\n\t\t\t\tplayer.points = 0;\n\t\t\t\tdocument.getElementById('computerScore').innerHTML = AI.points;\n\t\t\t\tdocument.getElementById('userScore').innerHTML = player.points;\n\t\t\t\tstressLevel = 50;\n\t\t\t\tstressLevelSystem();\n\t\t\t\tfor(i = 0; i < universityHidden.length; i++) universityHidden[i] = true;\n\t\t\t\tfor(i = 0; i < lifeHidden.length; i++) lifeHidden[i] = true;\n\t\t\t\tresult = \"\";\n\t\t\t}\n\t\t\tdocument.getElementById('gameInfo').style.color = 'rgba(0,0,0,0)';\n\t\t}\n\n\t\tplayer.vel = -10;\n\t}\n\telse if(code == 40) // Down arrow\n\t{\n\t\tif(!started)\n\t\t{\n\t\t\tstarted = true;\n\t\t\tif(result != \"\")\n\t\t\t{\n\t\t\t\tAI.points = 0;\n\t\t\t\tplayer.points = 0;\n\t\t\t\tdocument.getElementById('computerScore').innerHTML = AI.points;\n\t\t\t\tdocument.getElementById('userScore').innerHTML = player.points;\n\t\t\t\tstressLevel = 50;\n\t\t\t\tstressLevelSystem();\n\t\t\t\tfor(i = 0; i < universityHidden.length; i++) universityHidden[i] = true;\n\t\t\t\tfor(i = 0; i < lifeHidden.length; i++) lifeHidden[i] = true;\n\t\t\t\tresult = \"\";\n\t\t\t}\n\t\t\tdocument.getElementById('gameInfo').style.color = 'rgba(0,0,0,0)';\n\t\t}\n\t\tplayer.vel = 10;\n\t}\n}", "function checkAnswer() {\n disableAnswerBtns();\n const userAnswer = this.firstElementChild.innerText;\n const correctAnswer = startRound()\n \n if (userAnswer === correctAnswer[\"category\"]) {\n updateScore();\n showFeedbackModal(true, correctAnswer)\n } else {\n showFeedbackModal(false, correctAnswer)\n }\n}", "function onEqualsPress(event) {\n\t\t \n\tvar result = eval(currentInput);\n\n\t$(\".display\").val(result);\n\n\tcurrentInput = result;\n\n}", "function play(question,answer){\n let userAns = readline.question(question);\n\n if(userAns.toLowerCase()===answer.toLowerCase()){\n console.log(chalk.bgCyan(\"You are right!\"));\n console.log(\" \");\n score++;\n }else{\n console.log(chalk.bgMagenta(\"You are wrong!\"));\n console.log(\" \");\n score--;\n }\n \n}", "function initialPrompt() {\n let word = input.question(\"\\nLet's play some scrabble! Enter a word: \");\n //console.log(oldScrabbleScorer(word));\n return word; //Pass word to next.\n}", "function checkans(value) {\n if (game === \" \") {\n alert(\"Select a game\");\n }\n if (game === \"java\") {\n if (value === JavaAns[qcount]) {\n curr_score++;\n }\n }\n if (game === \"c\") {\n if (value === CAns[qcount]) {\n curr_score++;\n }\n }\n if (game === \"cplus\") {\n if (value === CPlusAns[qcount]) {\n curr_score++;\n }\n }\n if (game === \"python\") {\n if (value === PythonAns[qcount]) {\n curr_score++;\n }\n }\n qcount++;\n seconds=30;\n DisplayScore(curr_score);\n Quiz();\n}", "function showinput() {\n\tinit();\n\t$(\"#tab1\").addClass(\"filled\");\n\t$(\"#tab2\").addClass(\"filled\");\n $(\"#tab3\").addClass(\"filled\");\n $(\"#tab4\").addClass(\"filled\");\n\tif($('#' + irr).val() != \"\") {\n\t\tvar temp = $('#' + irr).val()*100;\n\t\t$('#' + irr).val(temp);\n\t\tdata[irr] = temp;\n\t}\n\txl2g.evalAllTargets();//updating the value\n}", "function chooseAnswer(event) {\n console.log('innerHTML ', event.target.innerHTML)\n console.log(playGame)\n if (playGame === true) {\n console.log(typeof event.target.innerHTML)\n console.log(correctAnswer)\n if (parseInt(event.target.innerHTML) === correctAnswer) {\n // if player chooses correct answer make sure try again window is hidden\n document.getElementById('try-again').style.display = 'none'\n console.log('good job!')\n //increment score\n score++\n //update innerHTML of score\n document.getElementById('score').innerHTML = `Score: ${score}`\n //invoke new QA\n newQA()\n } else {\n // if player chooses incorrect answer show try again window \n document.getElementById('try-again').style.display = \"inline-block\"\n //decrease score by 1\n score--\n //update innerHTML of score\n document.getElementById('score').innerHTML = `Score: ${score}`\n }\n }\n}", "function answerIsCorrect () {\r\n feedbackForCorrect();\r\n updateScore();\r\n}", "function evalAnswer() {\n console.log(\"chose: \" + this.value);\n console.log(\"answer was: \" + questions[Q].answer)\n if (this.value === questions[Q].answer) {\n console.log(\"correct\");\n secondsLeft += 5;\n score++;\n\n\n }\n else {\n console.log(\"wrong\");\n secondsLeft -= 10\n }\n \n // ending the quiz portion and stopping the clock\n if (Q === (questions.length - 1)) {\n endGameCard();\n clearInterval(timerInterval);\n }\n else {\n Q++;\n buildQuestionCard()\n }\n}", "function fabExp() {\n var fab = prompt('Do I have fabrication experience? Yes or no').toLowerCase();\n if (fab === 'yes') {\n alert('Correct! I was a fabricator for 6 years.');\n score++;\n } else if (fab === 'no') {\n alert('Actually, I fabricated scissor lift parts for 6 years.');\n }\n}", "function initialPrompt() {\n let word = input.question(\"Let's play some scrabble! \\n \\n Enter a word to score:\");\n // console.log(oldScrabbleScorer(word)\n return word\n}", "function gamestart() {\r\n let answer = document.getElementById(\"textInput\").value;\r\n document.body.style.backgroundImage = \"url('images/background2.gif')\"; \r\n document.getElementById(\"textbox\").innerHTML =\r\n \"For all you have remembered for the past century is falling, falling from the skies. Reason given this punishment long forgotten. \" + `All you remember is that you were a ${characterClass}. ` + \"You always wondered when it would end. having no hope for the past dozen years you suddenly realize the ground is coming near. The impact makes the land shake and kicks up a thick cloud of dirt. You stand up to find yourself in a forest caked in fog. You see a dim fiery light nearby. Your goal is to find who did this to you and why.\";\r\n document.getElementById(\"thirdInput\").style.display = \"none\";\r\n document.getElementById(\"fourthInput\").style.display = \"\";\r\n\r\n//4th input \r\n if (answer === 'examine area') {\r\n document.getElementById(\"textbox\").innerHTML = 'You examine the area carefully, as you are sifting through the dirt you feel something tough. You dig away the dirt that surrounds a stone pedastal the pedastal is splathered with blood all over, You notice some text and read what it says \"Those whom fell, those who do not belong. The collapsed. They are demonic beings of hatred filled with malice to the very soul\" There is a statue of a human being on the pedastal. The human is holding some sort of sword. You return back to your earlier position '\r\n } else if(answer === 'walk to light'){\r\n //call another function\r\n document.getElementById(\"textbox\").innerHTML = 'You start walking towards the light, although dimmed by the fog the ligh remains tracable. You walk for what feels like hours. You push through the leaves of a large tree. You walk to it to find about 10 standing torches wrapped in a circle in a clearing. You see many signs that there was activity here recently, you find abnormally sized footprints of some bipedal creature. In between the torches is a small wooden hatch. Yet there is also a path on the opposite side that you entered from, it is narrow and consist mostly of dirt and mud'\r\n }\r\n\r\n\r\n}", "function q6(){\n var fav_game_console = prompt('Whats your favorite gaming console? xbox, playstation, nintendo, or pc');\n console.log('what is the users fav game console');\n switch(fav_game_console){\n case 'xbox' :\n alert('Theres a smart man');\n break;\n case 'playstation' :\n alert('Well playstation has given us so many great titles havent they!');\n break;\n case 'nintendo' :\n alert('No matter what everyone loves nintendo');\n break;\n case 'pc' :\n alert('Master Race! Nothing else need be said.');\n break;\n default :\n alert('Try all lowercase in the spelling');\n break;\n }\n\n while(fav_game_console === '' || fav_game_console === null){\n fav_game_console = prompt('I know you can read');}\n console.log('user refuses to answer the question');\n}", "function checkAnswer() {\n const answer = currentUserAnswer(); // answerVal.value\n if (answer.toLowerCase() !== null && answer.toLowerCase() === newArrayQuestions[index].answer) {\n userPuntos(index, 1, 1);\n changeCorrectAnswerLetterColor();\n if (soundToggleChekbox) {\n playCorrectAnswerSound();\n }\n } else {\n userPuntos(index, 0, 1);\n changeIncorrectAnswerLetterColor();\n if (soundToggleChekbox) {\n playNoCorrectAnswerSound();\n }\n }\n showScores();\n checkArrayQuestionsForFin();\n if (rankingTable.classList.contains(\"hideElement\")) { // If the game has not been stopped\n updateLetter();\n updateAnswer(); // answerVal.value = ''\n changeActivLetterColor();\n showNextQuestion();\n }\n}", "function userInput() {\n checkedUpper = window.confirm('Do you want Upper Case Letters?');\n checkedLower = window.confirm('Do you want Lower Case Letters?');\n checkedNumbers = window.confirm('Do you want Numbers?');\n checkedSpecial = window.confirm('Do you want Special Characters?');\n if (!checkedUpper && !checkedLower && !checkedNumbers && !checkedSpecial) {\n alert(\"Must choose at least one\");\n userInput();\n }\n}", "function quiz() {\n render();\n handleStart();\n handleQuestion();\n handleScore();\n handleEnd();\n}", "function cat3GetQuestion() {\n var a = prompt('During prohibition this family of rum makers invited Americans to Cuba for weekend-long parties?')\n if (a.toLowerCase() === 'bacardi') {\n alert('Well Done. Correct answer')\n score += 200;\n scoreHtml.innerHTML = `Your score is ${score}`;\n\n }\n else {\n alert('Sorry, incorrect, it is Bacardi')\n }\n category3Button0.classList.add(\"disabled\");\n category3Button0.disabled = true;\n}", "function correctAnswer(){\n\tscore += addScore(time);\n\tupdateScore();\n if(++level == 10){\n difficulty = 1;\n } else if(level == 20){\n difficulty = 2;\n }\n document.getElementById('level').innerHTML = \"Level : \" + level;\n\tresetComponent();\n}", "function initialPrompt() {\n console.log(\"Let's play some scrabble!\\n\");\n return input.question(\"Enter a word to score: \"); \n}", "function getQuestion() {\n var a = prompt('During prohibition this family of rum makers invited Americans to Cuba for weekend-long parties?')\n if (a.toLowerCase() === 'bacardi') {\n alert('Well Done. Correct answer')\n score += 200;\n scoreHtml.innerHTML = `Your score is ${score}`;\n\n }\n else {\n alert('Sorry, incorrect, it is Bacardi')\n }\n category1Button0.classList.add(\"disabled\");\n category1Button0.disabled = true;\n}", "function cat2GetQuestion() {\n var a = prompt('During prohibition this family of rum makers invited Americans to Cuba for weekend-long parties?')\n if (a.toLowerCase() === 'bacardi') {\n alert('Well Done. Correct answer')\n score += 200;\n scoreHtml.innerHTML = `Your score is ${score}`;\n\n }\n else {\n alert('Sorry, incorrect, it is Bacardi')\n }\n category2Button0.classList.add(\"disabled\");\n category2Button0.disabled = true;\n}", "function userInput() {\n playButton.addEventListener('click', function() {\n let userInputName = document.getElementById('fname').value.trim();\n firstName = userInputName;\n if(!userInputName) {\n document.getElementById('message').innerHTML = '<span style=\"color:red\">Please enter your name to play!</span>';\n } else {\n gameSetUp();\n }\n });\n}", "function markSection(sectionNumber, firstQuestion) { \n let i = firstQuestion;\n let invalidInput = 0; // Defines that there are no \"invalid\" variables\n\n inputCheck(i, firstQuestion, invalidInput);\n alert(invalidInput);\n\n if (invalidInput == 0) {\n let sectionScore = 0;\n let input;\n\n while (i < (firstQuestion + 5)) { // Ensures that it only attempts to mark 5 questions\n input = document.querySelector(\"#answer\" + i).value;\n input = input.toLowerCase(); // This makes sure that if they answer \"A\" but the answer is \"a\" they can still get it correct\n\n if (input == ANSWERS[(i-1)]) { // If the input = the corect answer from the variable defined above...\n document.querySelector(\"#answer\" + i).style = \"background-color:#bcfcb0;\"; // Changes text input colour to green\n sectionScore++;\n } else {\n document.querySelector(\"#answer\" + i).style = \"background-color:#fcb0b0;\"; // Changes text input colour to red\n }\n i++;\n }\n\n allowContinue(sectionNumber, sectionScore);\n }\n}", "function questionSix() {\n console.log(\"question six function works\");\n var userTeam = document.getElementById('yourTeam');\n console.log(userTeam.value);\n var userResponse = userTeam.value.toLowerCase();\n\n if (userResponse === 'cubs') {\n var userGame = confirm('They are the best, click ok to win your prize.');\n console.log(userGame);\n\n if (userGame === true) {\n console.log('We are playing the game.');\n\n\n var numTeams = 2;\n var otherTeams = 'Tell me what other teams you like.';\n\n while (numTeams > 0) {\n var userInput = prompt(otherTeams + 'You have ' + numTeams + ' turns left.');\n if (userInput !== \"\") {\n if (user input === \"cubs\") {\n alert(\"That's my favorite team!\");\n break;\n } else {\n alert('Not a fan..')\n numTeams = numTeams - 1;\n }\n }\n\n\n\n }//closes while loop\n\n\n }//closes if user game is true\n\n\n } else {\n alert('No that is not the right team.');\n\n }//closes main if statement\n\n alert('Thanks for playing my game.');\n\n}//closes question six function", "function inputBox (){\n\tinput = document.getElementById(\"inputBox\").value;\n\tconsole.log(input);\n\n\tif (input === \"N\" || input === \"n\") {\n\t\tmoveNorth();\n\t\tdocument.getElementById(\"error\").innerHTML = \"\";\n\t}\n\telse if (input === \"S\" || input === \"s\") {\n\t\tmoveSouth();\n\t\tdocument.getElementById(\"error\").innerHTML = \"\";\n\n\t}\n\telse if (input === \"E\" || input === \"e\") {\n\t\tmoveEast();\n\t\tdocument.getElementById(\"error\").innerHTML = \"\";\n\n\t}\n\telse if (input === \"W\" || input === \"w\") {\n\t\tmoveWest();\n\t\tdocument.getElementById(\"error\").innerHTML = \"\";\n\t}\n\telse if (input === \"T\" || input === \"t\") {\n\t\ttakeButton();\t\n\t}\n\telse if (input === \"H\" || input === \"h\") {\n\t\thelp();\n\t} \n\telse if (input === \"X\" || input === \"x\") {\n\t\tsearchForItem();\n\t}\n\telse if (input === \"I'm ready\") {\n\t\tuserStaplePaper();\n\t}\n\t\n\telse {\n\t\tdocument.getElementById(\"error\").innerHTML = \"That is not a valid input. Please enter S, N, E, or W.\";\n\t}\n}", "function scorerPrompt(word) {\n\n let numEntered = -1;\n let newLine = '';\n \n while(!(numEntered === 0 || numEntered === 1 || numEntered === 2)){\n numEntered = input.question(\n`${newLine}Which scoring algorithm would you like to use?\n\n0 - Simple: One point per character\n1 - Vowel Bonus: Vowels are worth 3 points\n2 - Scrabble: Uses scabble point system\nEnter 0, 1, or 2: `);\n // Change string input to a number.\n numEntered = Number(numEntered);\n //Activate new line for susequent 'while' repeats.\n newLine = '\\n';\n\n } // end pf while\n //Return template/\n return `Score for '${word}': ${scoringAlgorithms[numEntered].scorerFunction(word)}`;\n \n}", "function initialPrompt() {\n console.log(\"Let's play some scrabble! \");\n\n let wordToScore = input.question(\"Enter a word to score:\");\n\n return wordToScore;\n}", "run() {\r\n let runOption = 0;\r\n do {\r\n console.clear();\r\n HangmanUtils.displayIntroduction();\r\n runOption = input.questionInt(\">> \");\r\n switch (runOption) {\r\n case 1:\r\n console.clear();\r\n HangmanUtils.displayRules();\r\n this.runGame();\r\n break;\r\n case 2:\r\n this.runStatistics();\r\n break;\r\n case 3:\r\n console.log(\"Good Bye! :)\");\r\n break;\r\n default:\r\n console.log(\"\\nPlease enter 1, 2 or 3 only!\");\r\n input.question(\"\\nPress \\\"Enter\\\" to proceed...\");\r\n }\r\n }\r\n while (runOption !== 3);\r\n }", "function takeInput() {\n\n // Asking the user if he's patient or User.\n r.question(\"Are you a\\n1. Patient or\\n2. User\\n\", function(ans1) {\n\n if (ans1.trim() == 1) {\n\n // If user enters 1, register the patient.\n registerPatient();\n } else {\n\n // If user enters 2, ask his purpose.\n purposeUser();\n }\n });\n}", "function input() {\n rl.question(\"Panjang sisi: \", (x) => {\n \n if (!isNaN(x) ) {\n console.log(`\\n Kubus: ${cubeFormula(x)}`);\n rl.close();\n } else {\n console.log(`sisi harus angka\\n`);\n input();\n }\n \n });\n}", "function initialPrompt() {\n // let enterWord = \"\";\n enterWord = input.question(\"Let's play some scrabble!\\nEnter a word to score: \"); //used the input syntax to ask a question \n\n // console.log(oldScrabbleScorer.enterWord); //for testing\n // console.log(oldScrabbleScorer(enterWord));\n return enterWord;\n}", "function checkAnswer(selected){\n let rightAnswer = questionsArray[questionCounter].correctAnswer;\n \n if(selected === rightAnswer){\n score++;\n displayPopup(true, rightAnswer);\n } \n else{\n displayPopup(false, rightAnswer);\n }\n}", "function tryAgain() {\n\tvar x = prompt(\"classroom or students\");\nvar lowerCase = x.toLowerCase();\nif ((lowerCase === \"classroom\") || (lowerCase === \"students\")) {\n window.alert(stem2[lowerCase])\n}\nelse {\n window.alert(\"You did not pay attention\");\n tryAgain();\n}\n}" ]
[ "0.6807743", "0.669007", "0.63524586", "0.6127466", "0.60732496", "0.5969236", "0.58497804", "0.58126897", "0.58098054", "0.5806892", "0.57868755", "0.5749469", "0.5738369", "0.56831956", "0.5662569", "0.5647252", "0.56438404", "0.56296617", "0.56276786", "0.5623167", "0.56001574", "0.5591893", "0.5570634", "0.55607116", "0.5559122", "0.5557966", "0.55572045", "0.5555474", "0.5555315", "0.5549991", "0.5532147", "0.5523811", "0.55237937", "0.552336", "0.5513587", "0.5512776", "0.54917085", "0.5485171", "0.54812247", "0.5476974", "0.54669535", "0.5462512", "0.54580367", "0.5449083", "0.54490423", "0.54421514", "0.54397553", "0.54397553", "0.5438149", "0.5437362", "0.5434166", "0.5433744", "0.5431692", "0.5429777", "0.54292053", "0.54269886", "0.542645", "0.54179627", "0.54100436", "0.5407486", "0.5406415", "0.54058266", "0.53939384", "0.53884745", "0.53836894", "0.5381869", "0.5372239", "0.53715605", "0.5371145", "0.5369346", "0.5366983", "0.5366352", "0.53651315", "0.53644264", "0.53636163", "0.5363264", "0.53627205", "0.53595865", "0.5351178", "0.53419983", "0.5340696", "0.53399485", "0.5334331", "0.5332823", "0.53265464", "0.531584", "0.5311443", "0.530537", "0.53045493", "0.53029937", "0.5298259", "0.52971846", "0.52937007", "0.5290066", "0.5287103", "0.5284038", "0.52828306", "0.52810985", "0.5277405", "0.52768457" ]
0.79498196
0
Update the state of the practice pane according to the current state of the unit.
function updatePracticePaneState() { switch (my.current.state) { case my.STATE.READY: my.html.practicePane.className = '' my.html.input.disabled = false my.html.input.focus() Util.setChildren(my.html.status, 'READY') my.html.status.title = 'Type in the input box below ' + 'to begin this lesson.' my.html.restartLink.style.visibility = 'hidden' break case my.STATE.RUNNING: my.html.practicePane.className = '' my.html.input.disabled = false my.html.input.focus() Util.setChildren(my.html.status, '') my.html.status.title = '' my.html.restartLink.style.visibility = 'visible' break case my.STATE.ERROR: my.html.practicePane.className = 'error' my.html.input.disabled = false my.html.input.focus() my.html.restartLink.style.visibility = 'visible' Util.setChildren(my.html.status, 'ERROR!') my.html.status.title = 'Fix errors in the input box ' + 'by pressing the backspace key.' break case my.STATE.COMPLETED: my.html.practicePane.className = 'completed' my.html.input.disabled = true my.html.input.blur() my.html.restartLink.style.visibility = 'visible' Util.setChildren(my.html.status, 'COMPLETED') my.html.status.title = 'You have completed this lesson.' break } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function updatePracticePane()\n {\n evaluateInput()\n setTargetText()\n displayTargetText()\n updateProgress()\n updateSpeed()\n updateError()\n updateSmiley()\n\n if (my.current.state == my.STATE.COMPLETED) {\n displayAdvice()\n setResultTooltips()\n\n log('state', my.current.state.toUpperCase(),\n 'unit', my.current.unitNo + '.' + my.current.subunitNo,\n 'type', my.settings.unit,\n 'wpm', my.current.wpm,\n 'error', my.current.errorRate.toFixed(1))\n }\n }", "function update_progress_section() {\n\t// Update the visual progress section (much of it temp for now)\n\t$('#questions_correct_level_count').text(questions_correct_level_count)\n\t$('#questions_incorrect_level_count').text(questions_incorrect_level_count)\n\t$('#questions_correct_total_count').text(questions_correct_total_count)\n\t$('#questions_incorrect_total_count').text(questions_incorrect_total_count)\n\t$('#progress_current_question').text(question_number)\n\t$('#questions_attempted_total_count').text(questions_attempted_count)\n\t$('#questions_correct_required').text(questions_correct_required)\n\t$('#questions_attempted_required').text(questions_attempted_required)\n}", "function setUpdatingState() {\n status.innerText = 'Updating arrangements...';\n status.style.color = 'black';\n playButton.disabled = true;\n alphaSlider.disabled = true;\n sampleButton1.disabled = true;\n sampleButton2.disabled = true;\n saveButton.disabled = true;\n changeChordsButton.disabled = true;\n chordInputs.forEach(c => c.disabled = true);\n chordInputs.forEach(c => c.style.color = 'gray');\n}", "updateUI(state, progress, answerValue = undefined, node = undefined) {\n // change background color of answer selection button\n if (node !== undefined) {\n let styleQuery = document.querySelector(`[data-key='${node}']`).style;\n if (answerValue === 'true') {\n styleQuery.backgroundColor = 'hsl(140, 100%, 30%)'; // red\n styleQuery.color = 'white';\n } else {\n styleQuery.backgroundColor = 'hsl(0, 100%, 55%)'; // green\n styleQuery.color = 'white';\n }\n }\n // this.validateUI(node);\n setTimeout(() => {\n this.header(progress);\n if (state === 'end') {\n this.end(progress);\n } else {\n this.main();\n }\n }, (answerValue === undefined) ? 100 : 2000)\n }", "updateUI() {\n document.getElementById(\"health\").innerHTML = this.currPlayerHealth;\n document.getElementById(\"food\").innerHTML = this.playerFood;\n document.getElementById(\"turn\").innerHTML = this.turnNum;\n document.getElementById(\"lvl\").innerHTML = this.currentLevel;\n document.getElementById(\"scr\").innerHTML = this.playerScore;\n\n }", "updateState(state) {\n $('#tournament-name').text(state.casters.tournament);\n $('#tournament-bracket').attr('format', state.tournament.bracket.format);\n\n this.bracket = state.tournament.bracket;\n\n $('#bracket-items').html('');\n for (const r in this.bracket.rounds) {\n $('#bracket-items').append(bracketItem(this.bracket.rounds[r]));\n }\n\n // final\n if ('Final' in this.bracket.rounds) {\n const final = this.bracket.rounds.Final;\n\n if (final.winner === 1) {\n $('#bracket-winner .name').text(final.team1);\n setCSSImage(\n $('#bracket-winner .logo'),\n final.team1Logo && final.team1Logo !== '' ? final.team1Logo : './images/default-logo.png',\n );\n }\n else if (final.winner === 2) {\n $('#bracket-winner .name').text(final.team2);\n setCSSImage(\n $('#bracket-winner .logo'),\n final.team2Logo && final.team2Logo !== '' ? final.team2Logo : './images/default-logo.png',\n );\n }\n else {\n $('#bracket-winner .name').text('');\n setCSSImage($('#bracket-winner .logo'), '');\n }\n }\n }", "update() {\n this.scoreHTML.innerText = this.score;\n // show modal if you score 12\n if(this.score == 12){\n this.win();\n }\n }", "function updateDisplay () {\n if (isGameOver()) {\n if (whoWon() === 1) {\n $('#gameStatus').text('Gameover. The winner is Player1!')\n } else if (whoWon() === 2) {\n $('#gameStatus').text('Gameover. The winner is Player2!')\n } else {\n $('#gameStatus').text('Gameover. It\\'s a draw!')\n }\n }\n\n if (!isGameOver()) {\n $('#gameStatus').text('Q' + (quiz.currentQuestion + 1) + ') ' + 'It\\'s Player' + (quiz.currentQuestion % 2 + 1) + '\\'s turn')\n // update question\n var flagIndex = quiz.currentQuestion + 1\n $('#flag').css('background-image', 'url(./img/flag' + flagIndex + '.gif)')\n $('#choice1').text(quiz.questions[quiz.currentQuestion].choices[0])\n $('#choice2').text(quiz.questions[quiz.currentQuestion].choices[1])\n $('#choice3').text(quiz.questions[quiz.currentQuestion].choices[2])\n $('#choice4').text(quiz.questions[quiz.currentQuestion].choices[3])\n // update sccore\n $('#player1Score').text(quiz.player1Score)\n $('#player2Score').text(quiz.player2Score)\n }\n}", "function evaluateInput()\n {\n var inputText = my.html.input.value\n var inputLength = inputText.length\n\n // If the tutor is in READY state, and input has been entered,\n // then set it to RUNNING STATE.\n if (my.current.state == my.STATE.READY && inputLength > 0) {\n\n my.current.startTime = new Date().getTime()\n my.current.state = my.STATE.RUNNING\n updatePracticePaneState()\n\n log('state', my.current.state.toUpperCase(),\n 'unit', my.current.unitNo + '.' + my.current.subunitNo,\n 'type', my.settings.unit)\n }\n\n // Number of characters correctly typed by the user\n var goodChars = Util.common(my.current.subunitText, inputText)\n my.current.correctInputLength = goodChars\n\n // Validate the input\n if (goodChars == inputLength) {\n\n // Clear error if any\n if (my.current.state == my.STATE.ERROR) {\n\n my.current.state = my.STATE.RUNNING\n updatePracticePaneState()\n }\n } else {\n\n // Set and display error\n if (my.current.state == my.STATE.RUNNING) {\n my.current.state = my.STATE.ERROR\n my.current.errors++\n updatePracticePaneState()\n } else if (my.current.state == my.STATE.ERROR) {\n processInputCommand()\n }\n }\n\n // Update error rate\n if (goodChars == 0) {\n if (my.current.errors == 0) {\n my.current.errorRate = 0\n } else {\n my.current.errorRate = Number.POSITIVE_INFINITY\n }\n } else {\n my.current.errorRate = 100 * my.current.errors / goodChars\n }\n\n // Check if the complete target text has been typed successfully\n if (goodChars == my.current.subunitText.length) {\n my.current.state = my.STATE.COMPLETED\n updatePracticePaneState()\n }\n }", "function resetSubunit()\n {\n my.current.state = my.STATE.READY\n my.current.errors = 0\n my.html.input.value = ''\n\n log('state', my.current.state.toUpperCase(),\n 'unit', my.current.unitNo + '.' + my.current.subunitNo,\n 'type', my.settings.unit)\n\n updatePracticePaneState()\n updatePracticePane()\n clearAdvice()\n clearResultTooltips()\n }", "function updateUI () {\n $(\".wins\").text(wins);\n $(\".losses\").text(losses);\n $(\".score-report\").text(totalScore);\n }", "updateDisplay() {\n $('#steps .value').text(this.stepCounter);\n }", "onCorrect () {\n if (this.state.category < 5) {\n this.updateCheese();\n this.updateBoard();\n }\n else {\n this.updateCheese();\n this.gameEnd();\n }\n }", "changeState(state) {\n // Game State\n if (state === 'game') {\n this.menu.style.display = 'none';\n this.canvas.style.display = 'block';\n\n // Instructions state\n } else if (state === 'instructions') {\n this.menu.style.display = 'none';\n this.instructions.style.display = 'block';\n\n // Menu state\n } else if (state === 'menu') {\n this.instructions.style.display = 'none';\n this.canvas.style.display = 'none';\n this.menu.style.display = 'block';\n\n // Winning State\n } else if (state === 'win') {\n this.canvas.style.display = 'none';\n this.winSection.style.display = 'block';\n\n // Not a state but displays the game state again\n } else if ('.play-again') {\n this.winSection.style.display = 'none';\n this.canvas.style.display = 'block';\n }\n }", "makeUI() {\n gameState.criteriaText = this.add.text(gameState.CENTER_X, gameState.CRITERIA_HEIGHT, `MULTIPLES OF ${gameState.criteriaNum}`, {\n font: gameState.INFO_FONT,\n fill: '#00ffff'\n }).setOrigin(0.5);\n gameState.creditsText = this.add.text(192, 684, `Created by Jon So, 2021`, {\n font: gameState.DECO_FONT,\n fill: '#ffffff'\n });\n gameState.scoreText = this.add.text(gameState.CENTER_X, gameState.SCORE_HEIGHT, `${gameState.score}`, {\n font: gameState.SCORE_FONT,\n fill: '#ffffff'\n }).setOrigin(0.5);\n gameState.levelText = this.add.text(3 * gameState.CENTER_X / 2, 3 * gameState.CENTER_Y / 2, `LV. ${gameState.level}: ${gameState.FLAVORS[gameState.colorFlavorIndex]}`, {\n font: gameState.INFO_FONT,\n fill: '#ffffff'\n }).setOrigin(0.5);\n gameState.readyPrompt = this.add.text(gameState.CENTER_X, 9 * gameState.CENTER_Y / 16, ``, {\n font: gameState.READY_FONT,\n fill: '#ff0000'\n }).setOrigin(0.5);\n gameState.comboCounterTextLeft = this.add.text(gameState.CENTER_X / 7 + 8, gameState.CENTER_Y - 32, `1x`, {\n font: gameState.COMBO_FONT,\n fill: '#ffffff',\n }).setOrigin(0.5).setFontStyle('bold italic');\n gameState.comboCounterTextRight = this.add.text(config.width - gameState.CENTER_X / 7 - 8, gameState.CENTER_Y - 32, `1x`, {\n font: gameState.COMBO_FONT,\n fill: '#ffffff',\n }).setOrigin(0.5).setFontStyle('bold italic');\n // Display the high score/highest level/ highest combo\n\t\tgameState.highText = this.add.text(gameState.CENTER_X, 16, \n\t\t\t`HI SCORE-${localStorage.getItem(gameState.LS_HISCORE_KEY)}\\t\\tHI COMBO-${localStorage.getItem(gameState.LS_HICOMBO_KEY)}\\t\\tHI LEVEL-${localStorage.getItem(gameState.LS_HILEVEL_KEY)}`, {\n\t\t\t\tfont: gameState.INFO_FONT,\n \tfill: '#ffffff'\n }).setOrigin(0.5).setTint(0xff0000).setFontStyle(\"bold\"); \n this.showReadyPrompt();\n gameState.levelText.setTint(gameState.COLOR_HEXS[gameState.colorFlavorIndex]);\n this.setupLivesDisplay();\n }", "function updateUI() {\n updatePlayerComponents(['points', 'teenagers', 'kettles', 'theaters', 'cps'])\n updatePriceComponents(['teenagers', 'kettles', 'theaters'])\n updateDoublePowerButton()\n}", "function updateDisplay () {\n if (isGameOver()) {\n $('h1').text(' gameover. winner is ' + whoWon())\n } else {\n $('h1').text(quiz.currentQuestion + ') ' + quiz.questions[quiz.currentQuestion].prompt)\n // hard coded display, only has 4 answers at a time. Each is displayed as a button, so can use the order (eg) that they appear in the dom to select them\n $('button').eq(0).text(quiz.questions[quiz.currentQuestion].choices[0])\n $('button').eq(1).text(quiz.questions[quiz.currentQuestion].choices[1])\n $('button').eq(2).text(quiz.questions[quiz.currentQuestion].choices[2])\n $('button').eq(3).text(quiz.questions[quiz.currentQuestion].choices[3])\n }\n // update player scores regardless\n $('h3').eq(0).text('Player1: ' + quiz.player1Points)\n $('h3').eq(1).text('Player2: ' + quiz.player2Points)\n}", "updateUI(){\n document.getElementById(\"theWord\").innerHTML = this._constructDisplayWord();\n document.getElementById(\"guessdLetter\").innerHTML = this._guessedLetter.toString().replace(/,/g, ' ');;\n document.getElementById(\"lives\").innerHTML = this._lives;\n document.getElementById(\"wins\").innerHTML = this._wins;\n }", "function changeTutorial() {\n\t\tcaptionTextIndex = 0;\n\t\tvar numSteps = captionText[tutorialIndex].length;;\n\t\tvar stepWidth = headerBar.size[0] / numSteps;// / numSteps - (0.4 * numSteps);\n\t\tvar content = '<div style=\"width:' + stepWidth + 'px;\" class=\"completedStep\"></div>';\n\t\tfor (var i=1; i < numSteps; i++) {\n\t\t\tcontent += '<div style=\"width:' + stepWidth + 'px;\" class=\"uncompletedStep\"></div>'\n\t\t}\n\t\tprogressBar.setContent('<div>'+content+'</div>');\n\t\tcaption.setContent(captionText[tutorialIndex][captionTextIndex]);\n\t\theaderBar.setContent(tutorialNames[tutorialIndex]);\n\t}", "function displayGuide() {\n my.html.guide.innerHTML = my.current.unit.guide\n }", "function indicateState() {\n setTutorialState(props.tutorialText);\n setShowModalState(true);\n }", "function update() {\n \n var object = editor.selected;\n if (object !== null) {\n object.visible = objectVisible.getValue();\n var selectObjectType = editor.getObjectType(object);\n var lineType = \"\";\n var scopeType = \"\";\n if (selectObjectType === 'line' || selectObjectType === 'hline' || selectObjectType === 'auline') {\n if (selectObjectType === 'line') {\n lineType = \"l\";\n }\n else if (selectObjectType === 'hline') {\n lineType = \"h\";\n }\n else {\n lineType = \"au\";\n }\n if (selectScope.dom.value == 1) {\n scopeType = \"unit\";\n }\n else {\n scopeType = \"area\";\n }\n console.log(\"upate\", objectName.getValue(), objectUserData.getValue(), materialColor.getHexValue(), selectType.getValue(), selectState.getValue(), scopeType, selectAParent.getValue(), lineType, objectLossRate.getValue());\n editor.updateAULineInfo(object, objectName.getValue(), objectUserData.getValue(), materialColor.getHexValue(), selectType.getValue(), selectState.getValue(), scopeType, selectAParent.getValue(), lineType, objectLossRate.getValue());\n } else {\n }\n }\n }", "function updateDisplay () {\n if (isGameOver()) {\n\n } else {\n $('h1.question').text(quiz.questions[quiz.currentQuestion].qn)\n $('h2.answer').text(quiz.questions[quiz.currentQuestion].factMsg)\n // hard coded display, only has 4 answers at a time. Each is displayed as a button, so can use the order (eg) that they appear in the dom to select them\n $('button').eq(0).text(quiz.questions[quiz.currentQuestion].options[0])\n $('button').eq(1).text(quiz.questions[quiz.currentQuestion].options[1])\n if (quiz.questions[quiz.currentQuestion].options[2]) {\n $('button').eq(2).text(quiz.questions[quiz.currentQuestion].options[2])\n } else {\n }\n $('button').eq(3).text(quiz.questions[quiz.currentQuestion].options[3])\n }\n}", "function updateGoals()\n{\n //Step 1: Stop timer\n startStopTimer();\n //Show goal scoring submenu -> allows entry for scorer + assists names\n document.getElementsByClassName(\"menu\")[0].style.display = \"none\";\n document.getElementsByClassName(\"scoring-menu\")[0].style.display = \"block\";\n \n\tif(currTeam == 1)\n\t{\n\t\tT1.goals += 1;\n\t\tdocument.getElementsByClassName(\"team-one-score\")[0].innerHTML = T1.goals;\n\t}\n\telse\n\t{\n\t\tT2.goals += 1;\n\t\tdocument.getElementsByClassName(\"team-two-score\")[0].innerHTML = T2.goals;\n\t}\n}", "updateDisplayString() {\n this.displayString = 'Increase ' + this.name + ' by ' + this.value + ' ' + this.measuringUnit;\n }", "function updateUI(){\n\t\n\t$('elapsed').innerText = timeElapsed();\n\t$('timer').innerText = countdown;\n\t$('shots').innerText = min_elapsed;\n\t$('bottles').innerText = toBottles(min_elapsed);\n\t$('ml').innerText = toMl(min_elapsed);\n\t$('oz').innerText = toOz(min_elapsed);\n\tif(paused){\n\t\t$('status').innerText = 'Play!';\n\t\t$('status').setStyle('color', '#'+Math.floor(Math.random()*16777215).toString(16));\n\t}\n\telse{\n\t\t$('status').innerText = 'Pause.';\n\t}\n\t$('interval').innerText = 'Game interval is ' + interval + ' seconds. Click to change.';\n}", "function update_unit_menu(value){\n value = parseInt(value);\n\n // GET THE UNIT DATA FOR THE SELECTED UNIT\n if (parseInt(get_num_value(document.getElementById(selected_unit).id)[0]) === p_color){\n // GET THE DATA FOR THE CIV THAT IS THE CURRENT PLAYER\n document.getElementById('unit_menu_name').innerHTML = civ_units[p_color][value].unit_Type;\n\n document.getElementById('unit_menu_stats').innerHTML = \"Movement \"+civ_units[p_color][value].unit_Movement_Remaining+\"/\"+civ_units[p_color][value].unit_Movement+\"<br>Health \"+civ_units[p_color][value].unit_Health+\"<br>Strength \"+civ_units[p_color][value].unit_Strength+\"<br>Class \" + civ_units[p_color][value].unit_Class\n\n if (civ_units[p_color][value].unit_Type === \"City\"){\n document.getElementById('unit_menu_actions').innerHTML = \"\\\n <a href='javascript:void(0);' onclick='city_menu()'><span href='javascript:void(0);' class='in-game_hotkey'>C</span>ity View</a>\\\n \"\n }\n\n if (civ_units[p_color][value].unit_Type === \"Settler\"){\n document.getElementById('unit_menu_actions').innerHTML = \"\\\n <a href='javascript:void(0);' onclick='unit_action(\"+value+\")'><span href='javascript:void(0);' class='in-game_hotkey'>B</span>uild City</a><br>\\\n <a href='javascript:void(0);' onclick='unit_action(\"+value+\", 0)'><span href='javascript:void(0);' class='in-game_hotkey'>D</span>elete Unit</a>\\\n \"\n }\n\n if ((civ_units[p_color][value].unit_Type === \"Warrior\") ||\n (civ_units[p_color][value].unit_Type === \"Horsemen\") ||\n (civ_units[p_color][value].unit_Type === \"Archers\")){ // value = 1 here\n document.getElementById('unit_menu_actions').innerHTML = \"\\\n <a href='javascript:void(0);' onclick='unit_attack = 1'><span href='javascript:void(0);' class='in-game_hotkey'>A</span>ttack</a><br>\\\n <a href='javascript:void(0);' onclick='unit_action(\"+value+\", 0)'><span href='javascript:void(0);' class='in-game_hotkey'>D</span>elete Unit</a>\\\n \"\n }\n } else{\n // GET DATA FOR THE OTHER CIVS THAT AREN'T THE CURRENT PLAYER\n for (var i = 0, length = player.length; i < length; i++){\n if (parseInt(get_num_value(document.getElementById(selected_unit).id)[0]) === i){\n //alert(\"p_color = \" + i);\n document.getElementById('unit_menu_name').innerHTML = civ_units[i][value].unit_Type;\n\n document.getElementById('unit_menu_stats').innerHTML = \"Movement \"+civ_units[i][value].unit_Movement_Remaining+\"/\"+civ_units[i][value].unit_Movement+\"<br>Health \"+civ_units[i][value].unit_Health+\"<br>Strength \"+civ_units[i][value].unit_Strength\n\n if (civ_units[i][value].unit_Type === \"City\"){\n document.getElementById('unit_menu_actions').innerHTML = \"\\\n <a href='javascript:void(0);' onclick='city_menu()'><span class='in-game_hotkey'>C</span>ity View</a>\\\n \"\n }\n\n if (civ_units[i][value].unit_Type === \"Settler\"){\n document.getElementById('unit_menu_actions').innerHTML = \"\\\n <a href='javascript:void(0);' onclick='unit_action(\"+value+\")'><span class='in-game_hotkey'>B</span>uild City</a>\\\n \"\n }\n\n if (civ_units[i][value].unit_Type === \"Warrior\"){\n document.getElementById('unit_menu_actions').innerHTML = \"NYI\"\n }\n }\n }\n }\n}", "function updateDisplay() {\n if (view == 'assignments') {\n $('#graded-items').hide();\n\n $('#assignments').show();\n $('.assignment-progress-bar').show();\n updateAssignments((a) => {\n assignments = a;\n displayAssignments(assignments);\n });\n } else if (view == 'gradedItems') {\n $('#assignments').hide();\n $('.assignment-progress-bar').hide();\n\n $('#graded-items').show();\n updateGradedItems((g) => {\n gradedItems = g;\n displayGradedItems(gradedItems);\n });\n }\n }", "winner() {\r\n this.state = STATES.win;\r\n this.htmlOverlay.innerHTML = \"<p>Congratulation you are the winner</p>\";\r\n this.htmlOverlay.style.display = \"block\";\r\n }", "function update(){\n updateSnakeMovement();\n updateGameFinishedState();\n updateFoodAcquiredState();\n }", "function updateCurrentStep() {\ncurrent_step_text.innerHTML = recipe[current_step];\n}", "updateSettings() {\n const unit = document.getElementById('marot-scoring-unit').value;\n this.charScoring = (unit == 'characters');\n const unitDisplay = document.getElementById('marot-scoring-unit-display');\n if (unitDisplay) {\n unitDisplay.innerHTML = (this.charScoring ? '100 source chars' : 'segment');\n }\n if (this.parseScoreSettings()) {\n this.setUpScoreSettings();\n }\n /**\n * Need to recompute metadata.segment.metrics['MQM'] for each segment first,\n * for use in subsequent filtering.\n */\n this.recomputeMQM();\n this.show();\n }", "displayBoard() {\n this.translateBoard();\n // if (this.states == STATES.DISPLAYED)\n this.updateScore();\n //}\n }", "function gameWinState() {\n crazySpace.update();\n }", "function uiUpdate(state) {\n\n gui.source.set(state._source)\n gui.phase.set(state._phase)\n gui.hand.set(state._hand)\n gui.manaPool.set(state._mana)\n gui.map.set(state._land.landMap)\n gui.map.setPlayer(state.playerHero, state._land.landPlayer)\n gui.resources(state)\n\n}", "function change () {\n setAnswer(this.value)\n // If the appearance is 'quick', then also progress to the next field\n if (fieldProperties.APPEARANCE.includes('quick') === true) {\n goToNextField()\n }\n}", "function renderWinState(state) {\n if(state === 0) {\n winDisplayEl.textContent = 'You Lose!';\n }\n if(state === 1) {\n winDisplayEl.textContent = \"Winner Winner Chicken Dinner!\";\n }\n if(state === -1) {\n winDisplayEl.textContent = \"\";\n }\n if(state === 2) {\n winDisplayEl.textContent = \"tie!\";\n }\n}", "changeDifficulty(state,cuadrados){\n state.cuadrados = cuadrados\n }", "function updateComponent_() {\n var size = {\n min: vm_.settlement.populationRange.min,\n max: vm_.settlement.populationRange.max\n };\n\n vm_.settlement.population = vm_.getPopulation(size.min, size.max);\n vm_.settlement.readyCash = vm_.getReadyCash(vm_.settlement.gpLimit, vm_.settlement.population);\n vm_.settlement.powerCenters = vm_.getPowerCenters(vm_.settlement.powerCenterQuantity);\n vm_.settlement.military = vm_.getMilitary(vm_.settlement.population);\n vm_.settlement.militia = vm_.getMilitia(vm_.settlement.population);\n vm_.settlement.racialDemographics = vm_.getRacialMix(vm_.selectedMix, vm_.settlement.population);\n vm_.settlement.racialDemographics = vm_.getAgeDemographics(vm_.settlement.racialDemographics);\n vm_.settlement.classDemographics = vm_.getClassDemographics(vm_.settlement.population);\n console.log(vm_.settlement);\n }", "function update() {\n\t$fraction.text(iQ + '/10');\n\t$percent.text(percentCorrect + '%');\n\n}", "function UpdatePageText()\n{\n\t// If the toggle is false, set to inches\n\tvar labelUnits = (_buttonState) ? _millimetersAbbrev : _inches;\n\tvar tipUnits = (_buttonState) ? _millimeters : _inches;\n\t\t\n\t// Clear out previous calculated value\n\tjQuery('.calculated-value').html(\"- -\");\n\t\n\t// Update input/output unit labels\n\tjQuery('.output-units').html(labelUnits);\n\tjQuery('.input-units').html(labelUnits);\n\t\n\t// Update tooltips\n\tjQuery('#item-length-tip').attr(\"tip\", \"Length, in \" + tipUnits + \", of the item you will be placing in the crate.\");\n\tjQuery('#item-width-tip').attr(\"tip\", \"Width, in \" + tipUnits + \", of the item you will be placing in the crate.\");\n\tjQuery('#item-height-tip').attr(\"tip\", \"Height, in \" + tipUnits + \", of the item you will be placing in the crate.\");\n\tjQuery('#plywood-thickness-tip').attr(\"tip\", (_buttonState) ? '9.5mm is recommended' : '3/8\" is recommended');\n\tjQuery('#frame-thickness-tip').attr(\"tip\", (_buttonState) ? '38mm is recommended' : '1.5\" is recommended');\n}", "updateState(state) {\n // tournament name\n $('#tournament-name').text(state.casters.tournament);\n }", "updateForm() {\n this.$step.innerText = this.currentStep;\n\n // TODO: Validation\n\n this.slides.forEach(slide => {\n slide.classList.remove(\"active\");\n\n if (slide.dataset.step == this.currentStep) {\n slide.classList.add(\"active\");\n }\n });\n\n this.$stepInstructions[0].parentElement.parentElement.hidden = this.currentStep >= 5;\n this.$step.parentElement.hidden = this.currentStep >= 5;\n\n // TODO: get data from inputs and show them in summary\n }", "function displayTrivia(){\n $(\"#feedback-wrapper\").hide();\n $(\"#time-remaining\").text(timer);\n startTimer();\n \n if (indexCount === trivia_questions.length){\n $(\"#right\").html(\"<h2>Total Correct: \"+ correct + \"</h2>\");\n $(\"#wrong\").html(\"<h2>Total Incorrect: \"+ incorrect + \"</h2>\");\n $(\"#unanswered\").html(\"<h2>Total Unanswered: \"+ unanswered + \"</h2>\");\n resetGame();\n return;\n }\n \n $(\"#trivia-question\").html(\"<h3>\" + trivia_questions[indexCount].question + \"</h3>\");\n //iterate through array of trivia and display question and answer as clickable event choices\n for (var j = 0; j < trivia_questions[indexCount].answerChoices.length; j++){\n var answerOption = $(\"<h2>\");\n answerOption.addClass(\"selection\");\n answerOption.text(trivia_questions[indexCount].answerChoices[j]);\n $(\"#trivia-choices\").append(answerOption);\n }\n\n triviaGamePlay();\n \n\n //allow user to select and answer\n //if correct answer is selected, update screen to show correct!,image associated with that question, and increment correct variable\n //reset timer to start again \n //if incorrect, update screen approptiately\n //if time over, update screen appropriately\n\n}", "function updateUI(){\n currentEvent = $(\"#cEvent\").text().trim();\n console.log(\"Current Event: \" + currentEvent);\n toggleButtons(currentEvent);\n switch (currentEvent) {\n case \"none\":\n break;\n\n case \"open\":\n break;\n\n case \"start\":\n myTimer.isReloading = true;\n myTimer.startTimer();\n break;\n\n case \"freetime\":\n myTimer.isReloading = true;\n myTimer.startTimer();\n break;\n\n case \"freezeLeaderboard\":\n myTimer.isReloading = true;\n myTimer.startTimer();\n break;\n\n case \"stop\":\n myTimer.displayElapsedTime();\n break;\n\n case \"close\":\n myTimer.displayElapsedTime();\n break;\n }\n}", "function toggleUnit()\n {\n var newUnit\n var confirmMessage\n\n if (my.settings.unit == my.UNIT.MAIN) {\n newUnit = my.UNIT.ALTERNATE\n confirmMessage = Units.alternateConfirmMessage\n } else {\n newUnit = my.UNIT.MAIN\n confirmMessage = Units.mainConfirmMessage\n }\n\n if (!confirm(confirmMessage)) {\n return false\n }\n\n localStorage.unit = newUnit\n loadSettings()\n updateUnitFromURL()\n return false\n }", "updateForm() {\n this.$step.innerText = this.currentStep;\n\n // TODO: Validation\n\n this.slides.forEach(slide => {\n slide.classList.remove(\"active\");\n\n if (slide.dataset.step == this.currentStep) {\n slide.classList.add(\"active\");\n }\n });\n\n this.$stepInstructions[0].parentElement.parentElement.hidden = this.currentStep >= 6;\n this.$step.parentElement.hidden = this.currentStep >= 6;\n\n // TODO: get data from inputs and show them in summary\n }", "function C012_AfterClass_Jennifer_TestChange() {\n\tif (!ActorIsRestrained()) {\n\t\tif ((ActorGetValue(ActorLove) >= 10) || (ActorGetValue(ActorSubmission) >= 10) || Common_ActorIsOwned || Common_ActorIsLover) {\n\t\t\tif (Common_ActorIsOwned) OverridenIntroText = GetText(\"AcceptChangeFromMistress\");\n\t\t\telse \n\t\t\t\tif (Common_ActorIsLover) OverridenIntroText = GetText(\"AcceptChangeFromLover\");\n\t\t\t\telse OverridenIntroText = GetText(\"AcceptChange\");\n\t\t\tC012_AfterClass_Jennifer_CurrentStage = 600;\n\t\t}\n\t\tC012_AfterClass_Jennifer_GaggedAnswer();\n\t} else OverridenIntroText = GetText(\"CannotActWhileRestrained\");\n}", "function changePetState(newState){\n if (newState >= 0 && newState < petStates.length){\n if (petState === 3){\n exploreButton.innerHTML = \"Explore\";\n }\n petState = newState;\n if (petState === 3){\n exploreButton.innerHTML = \"Stop Exploring\";\n }\n }\n petStateElement.textContent = petStates[petState];\n }", "update() {\n this.currTextViewer.innerHTML =\n this.getDisplay(this.currentOperand);\n if (this.operation != null) {\n this.prevTextViewer.innerHTML =\n `${this.getDisplay(this.previousOperand)} ${this.symbol}`;\n } else {\n this.prevTextViewer.innerHTML = `${this.currentOperand}`;\n this.total = `${this.currentOperand}`;\n }\n }", "updateBoard () {\n setTimeout(() => {\n let cat = this.state.category += 1;\n let current = this.state.currentQuestion += 1;\n this.setState({\n currentQuestion: cat,\n category: current,\n showModal: false\n });\n },2000)\n }", "function OnStateUpdate(self, state)\n {\n set_view(self, state)\n }", "function OnStateUpdate(self, state)\n {\n set_view(self, state)\n }", "function OnStateUpdate(self, state)\n {\n set_view(self, state)\n }", "display() {\n this.view.board.checkSelectedCells(this.selectedPiece);\n this.stateMachine();\n \n let ignore = true;\n if (this.checkSelected() == \"OK\")\n ignore = false;\n \n this.view.updateTimer();\n this.view.chronometer.display();\n this.view.marker.display();\n \n\n this.scene.pushMatrix();\n this.makePickingValidCells(null);\n\n this.view.board.display();\n if(this.state != 'START')\n this.makePickingPieces();\n else\n this.showPieces();\n\n\n this.scene.clearPickRegistration();\n this.scene.popMatrix();\n\n }", "updateAnswer(self){\n\t\tself.props.updateSelectedAnswer(self.props.letter);\n\t}", "changeHUnit(e) {\n // console.log(e);\n this.setState({ 'isCm': e });\n }", "function update(){\r\n\"use strict\";\r\ntotalCoins.textContent=\"Total Coins: \" + numTotalCoins;\r\ntotalPSB.textContent=\"Total PSB: \" + numTotalPSB;\r\ntotalRML.textContent=\"Total RML: \" + numTotalRML;\r\nratePSB.textContent=\"PSB per Run: \" + numRatePSB.toFixed(2);\r\nrateRML.textContent=\"RML per Run: \" + numRateRML.toFixed(2);\r\ntotalRuns.textContent=\"Total Runs: \" + numTotalRuns;\r\npFail.textContent= numPFail.toFixed(2)+\"%\";\r\np0.textContent= numP0.toFixed(2)+\"%\";\r\np1.textContent= numP1.toFixed(2)+\"%\";\r\np2.textContent= numP2.toFixed(2)+\"%\";\r\np3.textContent= numP3.toFixed(2)+\"%\";\r\np4.textContent= numP4.toFixed(2)+\"%\";\r\np5.textContent= numP5.toFixed(2)+\"%\";\r\neleNumFail.textContent=numFail;\r\neleNum0.textContent=num0;\r\neleNum1.textContent=num1;\r\neleNum2.textContent=num2;\r\neleNum3.textContent=num3;\r\neleNum4.textContent=num4;\r\neleNum5.textContent=num5;\r\n}", "function updateScore(){\n\tdocument.getElementById(\"correct\").innerHTML = \"Correct Answers: \" + counters.correct;\n\tdocument.getElementById(\"incorrect\").innerHTML= \"Incorrect Answers: \" + counters.incorrect;\n\tdocument.getElementById(\"unanswered\").innerHTML= \"Unanswered: \" + counters.unanswered;\n}", "function updateTally(outcome) {\n totalPoints += parseInt(outcome);\n \n // Draw tally using HTML\n tally = display_element.querySelector(\".tally\");\n tally.innerHTML = `Total Points: ${totalPoints}`\n \n }", "function state() {\r\n\r\n for(var key in views) {\r\n views[key].stage.visible = false;\r\n }\r\n\r\n character.visible = false;\r\n\r\n switch(CURR_STATE) {\r\n case STATES.TITLE_SCREEN:\r\n showView(views.title);\r\n break;\r\n\r\n case STATES.CREDITS_SCREEN: \r\n showView(views.credits);\r\n break;\r\n\r\n case STATES.PRESENT_LAB:\r\n showView(views.staticHUD);\r\n showView(views.presentLab);\r\n character.visible = true;\r\n break;\r\n }\r\n\r\n for(var key in views) {\r\n views[key].visible = views[key].stage.visible;\r\n }\r\n\r\n for(var key in keybinds) {\r\n if (keybinds[key].isDown) {\r\n keybinds[key].press();\r\n }\r\n }\r\n}", "function updateControllerHtml(){\n\tdocument.getElementById(\"control-population\").innerHTML = \"Population (\"+getPopulation()+\")\";\n\tdocument.getElementById(\"control-resources\").innerHTML = \"Food (\"+parseInt(food)+\") Wood (\"+parseInt(wood)+\") Stone (\"+parseInt(stone)+\")\";\n\tdocument.getElementById(\"control-speed\").innerHTML = \"Speed (\"+speeds[speedIndex].name+\")\";\n\tif (running){\n\t\tdocument.getElementById(\"control-pause-resume\").style.background = \"url(images/pause.png)\";\n\t} else {\n\t\tdocument.getElementById(\"control-pause-resume\").style.background = \"url(images/resume.png)\";\n\t}\n}", "function updateState(stateInformation, questions) {\n var state = document.getElementById('dropdown').value;\n\n // If we're already on selected state, do nothing.\n if (selectedState == state) {\n return;\n }\n selectedState = state;\n\n\n var selectedOptions = updateQuestions(state, stateInformation, questions, selectedOptions);\n updateBills(state, stateInformation);\n\n showQuestionDisplay(state, stateInformation, selectedOptions);\n\n // Update iframe\n if (pymChild) {\n pymChild.sendHeight();\n }\n}", "function updateState(square) {\n $(square).text(player());\n}", "function unitChange() {\n oldunits = units;\n if(document.getElementById('unit_SI').checked) {\n units = 'unit_SI';\n doseUnit = 'uSv/h';\n dosenorm = eps * 1e4 * 3600;\n lunit = cm;\n lunitname = 'cm';\n }\n else {\n units = 'unit_US';\n doseUnit = 'mrem/h';\n dosenorm = eps * 1e3 * 3600;\n lunit = inch;\n lunitname = 'inch';\n }\n\n // Update length unit\n var ltext = document.getElementsByClassName('lunit');\n for (var i = 0; i < ltext.length; i++) { \n ltext[i].innerHTML = lunitname;\n };\n\n // Update dose unit\n var dtext = document.getElementsByClassName('dunit');\n for (var i = 0; i < dtext.length; i++) {\n dtext[i].innerHTML = doseUnit;\n };\n\n autoConv = document.getElementById('autoConv').checked;\n if(autoConv) { // Covert length values according to the selected unit\n var linp = document.getElementsByClassName('inpL');\n var unitfactor;\n if(units=='unit_SI' && oldunits=='unit_US')\n unitfactor = inch/cm;\n else if(units=='unit_US' && oldunits=='unit_SI')\n unitfactor = cm/inch;\n else\n unitfactor = 1.0;\n for (var i = 0; i < linp.length; i++) {\n linp[i].value = (parseFloat(linp[i].value) * unitfactor).toFixed(2);\n };\n }\n updateAll();\n}", "function _update() {\r\n this.component[this.prop] = this.control[this.prop];\r\n }", "updateForm() {\n this.$step.innerText = this.currentStep;\n if (this.currentStep < 2) this.$prev.forEach(el => el.classList.add(\"hidden\"));\n if (this.currentStep === 2) this.$prev.forEach(el => el.classList.remove(\"hidden\"));\n if (this.currentStep > 4) this.$next.forEach(el => el.classList.add(\"hidden\"));\n if (this.currentStep === 4) this.$next.forEach(el => el.classList.remove(\"hidden\"));\n if (this.currentStep === 5) {\n this.updateSummary();\n this.$stepCounter.classList.add(\"hidden\");\n this.$agreeBtn.classList.remove(\"hidden\");\n\n }\n if (this.currentStep < 5) {\n this.$stepCounter.classList.remove(\"hidden\");\n this.$agreeBtn.classList.add(\"hidden\");\n }\n\n this.slides.forEach(slide => {\n slide.classList.remove(\"active\");\n if (slide.dataset.step == this.currentStep) {\n slide.classList.add(\"active\");\n }\n });\n\n }", "function setCurrent() {\n\t\tcurrentQ = allQ[iQ];\n\t\tcurrentA = allAns[iQ];\n\t\ttotal = iQ;\n\t\tpercentCorrect = parseInt((numCorrect/total)*100);\n}", "checkAnswer() {\n \n let currentQuestionAnswer = eval(propblems[this.state.currentProblemIndex].question);\n let nextString = null;\n\n if (currentQuestionAnswer == this.state.answerByUser) {\n nextString = \"Clear\";\n this.setState(state => ({\n score:state.score+1\n }))\n } else {\n nextString = \"Wrong\";\n }\n\n\n console.log(this.state.score);\n\n this.setState(state => ({\n currentDisplayingStr: nextString,\n currentProblemIndex: state.currentProblemIndex + 1,\n currentQuestionIndex: null,\n shouldShowInput: false\n }))\n\n this.initiateTest();\n }", "updateCurrentTileUi() {\n let theTile = this.map[this.player.getPositionKey()];\n currentTilePositionElement.innerText = `[${theTile.getPositionKey()}]`;\n if (theTile.hasBuilding()) {\n let buildingText = theTile.actor.getName() + \" \" + theTile.actor?.inventory?.getSummary();\n currentTileBuildingElement.innerText = buildingText;\n } else {\n currentTileBuildingElement.innerText = \"None\";\n }\n if (theTile.tileType != \"empty\") {\n currentTileResourcesElement.innerText = `${theTile.getType()}: ${theTile.countResources()}`;\n } else {\n currentTileResourcesElement.innerText = \"No Resources\";\n }\n }", "function addWin() {\n\ttotalCorrect++;\n\t$(\"#display\").html(\"<h3>Correct! The answer is: <h3 class='green'>\" + questionList[questionNumber].correctAnswer + \"</h3></h3>\");\n\tsetTimeout(nextQuestion, 3000); \n\n\t//test\n\tconsole.log(\"Correct: \" + totalCorrect);\n}", "componentDidUpdate() {\n switch (Actions.currentScene) {\n case (Actions.Frontpage.name):\n this.setState({ frontSelect: true, obsSelect: false });\n break;\n case (Actions.Observation.name):\n this.setState({ frontSelect: false, obsSelect: true });\n break;\n }\n }", "function updateDisplays() {\n $(\"#displayQuestion\").html(response.results[questionNum].question);\n $(\"#displayAnswer\" + answerOrder[0]).html(response.results[questionNum].incorrect_answers[0]);\n $(\"#displayAnswer\" + answerOrder[1]).html(response.results[questionNum].incorrect_answers[1]);\n $(\"#displayAnswer\" + answerOrder[2]).html(response.results[questionNum].incorrect_answers[2]);\n $(\"#displayAnswer\" + answerOrder[3]).html(response.results[questionNum].correct_answer);\n $(\"#displayQuestionNumber\").html(questionNum + 1);\n $(\"#displayIncorrect\").html(incorrectCounter);\n $(\"#displayCorrect\").html(correctCounter);\n $(\"#displayTimeOut\").html(timeoutCounter);\n }", "function updateState(stateName) {\n localStorage.setItem('stateName', stateName);\n stateArray = find(data, index => index.state === stateName);\n split = (stateArray) ? stateArray.split / 100 : 0;\n makeList(stateArray);\n\n //DISPLAYS SPLIT, CPL AND RIDER INFO TO MAIN SCREEN\n $('#split').text(`UW:${stateArray ? stateArray.UW : ''} split:${stateArray ? stateArray.split : ''} CPL:${stateArray ? stateArray.cpl : ''} Rider:${stateArray ? stateArray.pud : ''}`\n );\n display = (stateArray) ? stateArray.end : false;\n updateCustomAttributes(stateName)\n\n toggleEndorsementCalc(display);\n displayRiskRateDiv()\n checkCalc();\n\n\n}", "_updateScoreBox() {\n\t\tthis.scoreBox.changeText('SCORE: ' + this.score + '\\nHIGH: ' + this.high);\n\t}", "function updateScore (input) {\n scoreText.innerText = score;\n pointsRemainingText.innerText = updateRemaining();\n let buttons = document.getElementById(\"buttonGroup\").children;\n for (let i=0; i<buttons.length; i++){\n buttons[i].innerText=balls[i].quantity;\n }\n updateBar();\n}", "function updateDisplay()\n {\n //We need to build a string to show. The first item is the current running total:\n var string = runningTotal;\n\n //Then we add the operator if they have pressed this\n if(hasPressedOperator)\n string += \" \" + currentOperator;\n \n //And finally we add the right operand, the value to add when equals is pressed.\n if(hasPressedOperand)\n string += \" \" + currentOperand;\n \n //We then simply set the value of the output field to the string we built\n document.getElementById(\"output\").value = string;\n }", "setWindowState(state) {\n this.windowState = state;\n switch (state) {\n case 0:\n $(\"#user-input\").show();\n $(\"#details\").hide();\n $(\"#graphic\").hide();\n $(\".footer-row\").show();\n $(\"#user-input\").empty();\n $(\".nav-item[data-action='back-to-input']\").hide();\n var content = this.input.generateDetailsLabel();\n $(\"#user-input\").append(content.html);\n this.input.addListeners(content.id);\n if (this.input.isValid().value) {\n $(\"#send-input\").removeClass(\"disabled\");\n $(\"#ext-solution\").css(\"display\", \"inline-block\");\n } else {\n $(\"#send-input\").addClass(\"disabled\");\n $(\"#ext-solution\").css(\"display\", \"none\");\n }\n $(\"#solution-comparison\").hide();\n $(\".nav-item[data-action='leave']\").hide();\n break;\n case 1:\n $(\".nav-item[data-action='back-to-input']\").show();\n $(\"#user-input\").hide();\n $(\"#details\").show();\n $(\"#graphic\").show();\n $(\".footer-row\").hide();\n $(\"#solution-comparison\").hide();\n $(\".nav-item[data-action='leave']\").hide();\n break;\n case 2:\n $(\".nav-item[data-action='back-to-input']\").hide();\n $(\"#user-input\").hide();\n $(\"#details\").hide();\n $(\"#graphic\").hide();\n $(\".footer-row\").hide();\n $(\"#solution-comparison\").show();\n $(\".nav-item[data-action='leave']\").show();\n this.fillSolutionComparison();\n break;\n }\n }", "function updateState(place) {\n let value = player();\n $(place).text(value)\n}", "_updateScore () {\n this._scoreBoard.innerHTML = this._score;\n }", "function update() {\r\n\r\n // update game\r\n game.update();\r\n\r\n // toggle tower clickable depending on the user's money\r\n updateTowerStore();\r\n\r\n let { type, lives, money, level, difficulty } = game.getLevelStats();\r\n\r\n // update lives and money based on game stats \r\n livesLabel.innerHTML = 'Lives: ' + lives;\r\n moneyLabel.innerHTML = '$' + money;\r\n levelLabel.innerHTML = 'Level: ' + level; \r\n difficultyLabel.innerHTML = 'difficulty: ' + difficulty;\r\n nextLevelLabel.innerHTML = '';\r\n\r\n if (type) nextLevelLabel.appendChild(ENEMY_IMAGES[type]);\r\n else nextLevelLabel.style.display = 'none';\r\n\r\n // increase flashing transparency\r\n flashingTransparency = flashingTransparency + .2;\r\n}", "function scoreUpdate(){\r\n document.getElementById('score').innerText = piece.score;\r\n }", "function updateDisplays() {\n $(\"#wins-text\").text(wins);\n $(\"#losses-text\").text(losses);\n $(\"#crystal-core-text\").text(crystalValue);\n }", "function updateState(data) {\n updateVoteFinishArea(data.state);\n}", "updateView() {\n this.viewValue = this.getViewFromValue();\n this.renderView();\n }", "function StateManager_SetStateData(newState)\n{\n\t//update tutorial's current screen\n\tthis.CurrentState = newState;\n\t//update block variable\n\tthis.BlockUserInteraction = this.CurrentState.ControlSettings && Get_Bool(this.CurrentState.ControlSettings[__NEMESIS_ParamName_LessonBlockControl], false);\n}", "function setChordChangeState() {\n status.innerText = 'Change chords (triads only) then press Done.';\n status.style.color = 'black';\n playButton.disabled = true;\n alphaSlider.disabled = true;\n sampleButton1.disabled = true;\n sampleButton2.disabled = true;\n saveButton.disabled = true;\n changeChordsButton.innerText = 'Done';\n changeChordsButton.disabled = false;\n chordInputs.forEach(c => c.disabled = false);\n chordInputs.forEach(c => c.style.color = 'black');\n}", "function update()\n {\n\n\n if(currentScore < targetScore) {\n $(\"#State\").text(\"Scoreboard\");\n }\n if (currentScore > targetScore) {\n losses++;\n $(\"#State\").text(\"You Lose!\")\n Start();\n\n }\n\n \n\n if (currentScore == targetScore) {\n wins++;\n $(\"#State\").text(\"You Win!\")\n Start();\n }\n\n \n}", "function changeQCorrect() {\n changeQ();\n messageArea.textContent = \"CORRECT!\";\n }", "_onChangeUnderlay(underlayCategory, underlay) {return this.componentDidUpdate();}", "function update() {\n type = textInput.value();\n shapeWidth = shapeSlider.value();\n density = densitySlider.value();\n shapeOpacity = opacitySlider.value();\n let size = fontSizeOptions.value();\n fontSize = int(size);\n fontStyle = fontStyleOptions.value();\n shape = radioShape.value();\n fillInitially = radioFill.value();\n shake = shakeCheckBox.checked();\n move = moveCheckBox.checked();\n colourInitially = radioColour.value();\n\n setUpText();\n}", "updateDecks() {\n this.setState(HearthstoneStore.getComposedState());\n }", "function change_question() {\n self.questions[current_question_index].render(question_container);\n $('#prev-question-button').prop('disabled', current_question_index === 0);\n $('#next-question-button').prop('disabled', current_question_index === self.questions.length - 1);\n\n // When the question is changed, update the progress bar\n var barW; //bar width initially 0\n barW = 10 + current_question_index*10;\n progBar.style.width = barW + \"%\";\n\n // Determine if all questions have been answered\n var all_questions_answered = true;\n for (var i = 0; i < self.questions.length; i++) {\n if (self.questions[i].user_choice_index === null) {\n all_questions_answered = false;\n break;\n }\n }\n //$('#submit-button').prop('disabled', !all_questions_answered); //enable the 'submit' button if all of the questions have been answered\n }", "function update_units_move(value){\n play_sound(\"./sound/hello.mp3\");\n for(var i = 0, length = civ_units[p_color].length; i < length; i++){\n if (civ_units[p_color][i].unit_Type === \"City\"){\n civ_units[p_color][i].unit_Movement_Remaining = 0;\n }\n\n if (civ_units[p_color][i].unit_Type === \"Settler\"){\n civ_units[p_color][i].unit_Movement_Remaining = values_units.units[0].move;\n }\n\n if (civ_units[p_color][i].unit_Type === \"Warrior\"){\n civ_units[p_color][i].unit_Movement_Remaining = values_units.units[1].move;\n }\n\n if (civ_units[p_color][i].unit_Type === \"Horsemen\"){\n civ_units[p_color][i].unit_Movement_Remaining = values_units.units[2].move;\n }\n\n if (civ_units[p_color][i].unit_Type === \"Archers\"){\n civ_units[p_color][i].unit_Movement_Remaining = values_units.units[3].move;\n }\n\n // why is this here???\n //update_unit_menu(value);\n }\n }", "function uiRedraw(state) {\n\n if (!initialized) {\n gui = {}\n gui.question_cleanup = []\n\n document.getElementById(\"panel\").style.backgroundImage =\n \"url(\\\"../img/characters/\" + state.game.playerHero + \"/art.png\\\"\"\n\n gui.cards = newCards()\n gui.hand = newHand()\n gui.source = newSource()\n gui.manaPool = newManaPool()\n gui.map = newMap()\n gui.phase = newPhase()\n gui.combat = newCombat()\n gui.resources = newResources()\n initialized = true\n }\n\n\n uiUpdate(state.game)\n uiQuestions(state.questions)\n}", "function loadAllText() {\n\n scenarioRooms = adventureManager.states;\n resultsRooms = adventureManager.states;\n\n scenarioRooms[one].setText(\"Where to?\", \"You just lost the lease on your apartment. Where are you moving to?\");\n scenarioRooms[two].setText(\"Should you stay or should you go?\", \"You are looking for an apartment in Manhattan. However, since you do not already have OneWay installed into your body, the lifestyle is troublingly incompatible with your needs. You struggle to even submit a rental application without OneWay, let alone get in touch with real estate agents. What do you want to do?\");\n scenarioRooms[three].setText(\"Software update\", \"You bought OneWay and managed to secure a spot in Manhattan. BigInc has just released a software upgrade that cost nearly as much as the installation itself. This update will put you in deep debt, but is the only way to stay compatible with the technology in Manhattan. What do you do?\");\n resultsRooms[four].setText(\"Yikes\", \"You paid for the update in order to keep OneWay compatible. But, now you are very broke. You can’t even afford your current rent. You try to seek support from the government, but you do not qualify for any aid because having OneWay puts you in the highest bracket of income. You now have the most current technology, but are homeless.\");\n resultsRooms[five].setText(\"Congratulations\", \"You have left what is left of New York. You have escaped the pressure of Big Inc. For now that is…..\");\n scenarioRooms[six].setText(\"Should you stay or should you go?\", \"You are on Staten Island. In order to seek residency, you must commit to an anti-technology oath. The purists have banned all forms of smart devices and have reverted to pre-internet times of living in fear of the evolution of technology. Stay or go someplace else?\");\n scenarioRooms[seven].setText(\"Welcome to Staten Island\", \"You’ve decided to stay on Staten Island. You are having trouble getting accustomed to the tech-free lifestyle and you feel a lot of social pressure from the community on where you stand in response to BigInc taking over NYC. What do you do?\");\n resultsRooms[eight].setText(\"Yikes\", \"You have decided to commit the Purists, but have chosen the side of a losing battle. Your own community has started to lose faith in the cause, resulting in leadership taking unethical actions to keep the community pure. Naturally the community becomes corrupt and loses many members to BigInc.\");\n scenarioRooms[nine].setText(\"In or out?\", \"Big Inc just bought out abandoned buildings all over Brooklyn with plans to convert them to luxury apartments, OneWay compatible apartments with the hopes of inviting other wealthy communities to join their society. If you have OneWay installed, you’ll have the chance to be a part of the extended community and get in early at an up and coming area.\");\n scenarioRooms[ten].setText(\"Software update\",\"You bought OneWay and have been living in a poor quality building while waiting for your spot in the up and coming luxury apartments. BigInc has just released a software upgrade that cost nearly as much as the installation itself. This update will put you in deep debt, but is the only way to secure your spot on the waitlist. What do you do?\");\n resultsRooms[eleven].setText(\"Yikes\", \"The building you are currently living in just got bought out by BigInc. They are doing a complete remodel and kicking out all of the current residents. You can’t afford to live anywhere in Brooklyn anymore. You try to seek support from the government, but you do not qualify for any aid because having OneWay puts you in the highest bracket of income. You now have an outdated form of OneWay and are homeless.\");\n scenarioRooms[twelve].setText(\"In or out?\", \"The building you were living in just got bought out by BigInc. OneWay has taken over all of Brooklyn, displacing its current residents onto the streets. You feel like your only choices are to buy OneWay or leave NYC. What do you do?\");\n\n}", "function factChange() {\n $('.falseFact').text('True Fact');\n }", "function update() {\n element.winsDoc.textContent = \"Wins: \" + score.win.toString();\n element.losesDoc.textContent = \"Losses: \" + score.lose.toString();\n element.guesses.textContent = \"Guesses Left: \" + score.letterGuess.toString();\n element.wordGuess.textContent = guessedWord;\n}", "function updateDisplayAndGetState() {\n let state = getGridStateAndNumFilled();\n statusNumFilled.innerHTML = numCellsFilled\n let ci = currentClueIndex\n if (clues[ci] && clues[ci].parentClueIndex) {\n ci = clues[ci].parentClueIndex\n }\n let revOrphan = isOrphanWithReveals(ci)\n checkButton.disabled = (activeCells.length == 0) && !revOrphan\n let theClue = clues[ci]\n let haveReveals = (activeCells.length > 0 && !hasUnsolvedCells) ||\n (theClue && (theClue.anno || theClue.solution || revOrphan));\n if (!haveReveals && numCellsToOrphan > 0 && activeCells.length > 0) {\n let orphanClue = cellsToOrphan[JSON.stringify(activeCells)];\n if (orphanClue) {\n let oc = clues[orphanClue]\n haveReveals =\n oc && (oc.anno || oc.solution || isOrphanWithReveals(orphanClue));\n }\n }\n revealButton.disabled = !haveReveals;\n clearButton.disabled = revealButton.disabled && activeCells.length == 0;\n return state\n}", "function observeTheArea(){\n\tstory(\"You quickly observe the area for any danger close by or anything that would harm you and you see flashing lights in the distant by a dense forest.\");\n\tchoices = [\"Wake up\",\"Pass out\",\"Laugh it away\"];\n\tanswer = setOptions(choices);\n}" ]
[ "0.8052318", "0.57588446", "0.5743218", "0.56928384", "0.5668989", "0.5660109", "0.55661553", "0.55559504", "0.5511542", "0.55113316", "0.5503733", "0.5496617", "0.5492996", "0.546254", "0.54377234", "0.5434156", "0.54306704", "0.54262424", "0.5418253", "0.5390242", "0.5385376", "0.53657335", "0.53603494", "0.53505397", "0.53352255", "0.53305477", "0.5320918", "0.5308575", "0.52924037", "0.52922857", "0.528011", "0.52746034", "0.5271863", "0.5267576", "0.52669156", "0.52515525", "0.5250174", "0.52475184", "0.52470267", "0.524685", "0.5245136", "0.5243199", "0.5241763", "0.5240362", "0.5221315", "0.52176404", "0.52115077", "0.52100986", "0.5193565", "0.51913524", "0.51896995", "0.51876605", "0.51876605", "0.51876605", "0.51871544", "0.5181647", "0.5178793", "0.51768833", "0.5175693", "0.5165301", "0.5158751", "0.51550543", "0.5153839", "0.51526093", "0.5148935", "0.5147651", "0.51410204", "0.5139329", "0.51387566", "0.5134423", "0.5130944", "0.5123769", "0.5108971", "0.5107861", "0.51078343", "0.51056373", "0.5102652", "0.51006806", "0.5095695", "0.5094206", "0.5093515", "0.50912184", "0.50904244", "0.5089287", "0.50861126", "0.5085243", "0.50836295", "0.5083061", "0.50801647", "0.50759906", "0.50708866", "0.506797", "0.5061782", "0.5061479", "0.5055582", "0.5049025", "0.5048193", "0.5044458", "0.5043599", "0.50428057" ]
0.7647987
1
Update remark and advice link according to the current state of the tutor and the performance of the user.
function displayAdvice() { // Calculate error rate (in percent) var error = Math.round(my.current.errorRate) var repeatSubunit = error > 0 // Update remark and advice var anchorElement = document.createElement('a') if (repeatSubunit) { Util.addChildren(my.html.remark, 'Reduce error') my.html.remark.title = 'Your error rate should not ' + 'exceed 0%.' Util.addChildren(anchorElement, 'Try again') anchorElement.href = '#restart' anchorElement.title = 'Please practice this lesson again.' } else { Util.addChildren(my.html.remark, 'Well done!') my.html.remark.title = 'You have satisfactorily ' + 'completed this lesson.' Util.addChildren(anchorElement, 'Next lesson') anchorElement.href = '#next' anchorElement.title = 'Please proceed with the next lesson.' } // Do not display 'Next lesson' advice if the user is at the // last subunit; display advice otherwise if (repeatSubunit || !currentSubunitIsTheLastSubunit()) { my.html.advice.appendChild(anchorElement) anchorElement.focus() } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function Description(course) {\r\n let initialUpvotes = course.upvotes;\r\n let initialReputation = course.reputation;\r\n const [upvotes, setUpvotes] = useState(initialUpvotes);\r\n const [courseReputation, setCourseReputation] = useState(initialReputation);\r\n const {userDetails,setUserDetail}= useContext(UserContext);\r\n\r\n const handleVote = async(vote,contentId) =>{\r\n console.log(vote,contentId);\r\n const obj = {\r\n vote,\r\n contentId\r\n }\r\n const contentVote = await API('contentVote/','POST',obj,userDetails.Data[0].accessToken)\r\n course.setRefetch_(!course.refetch_)\r\n }\r\n \r\n function navigate() {\r\n window.location.href = course.courseURL;\r\n }\r\n\r\n\r\n const recommend = async(e) =>{\r\n const contentId = e.target.value;\r\n const obj = {\r\n contentId \r\n }\r\n\r\n // console.log(\"content id description: \", contentId);\r\n // console.log(\"access token description: \", userDetails.Data[0].accessToken);\r\n \r\n const response = await API('reputationCount/','POST',obj,userDetails.Data[0].accessToken);\r\n course.setRefetch_(!course.refetch_)\r\n }\r\n\r\n return (\r\n /* mb - margin below, p padding*/\r\n <div className=\"col p-4 flex-column position-static\">\r\n <strong className=\"d-inline-block mb-2 text-primary\">\r\n {course.category}\r\n </strong>\r\n {!course.status && (\r\n <strong className=\"status d-inline-block mb-2 text-danger\">\r\n Not Approved\r\n </strong>\r\n )}\r\n <h3 onClick={navigate} className=\"mb-0 link\">\r\n {course.name}\r\n </h3>\r\n <div className=\"mb-1 text-muted\">{course.date}</div>\r\n <p className=\"card-text mb-1\">{course.desc}</p>\r\n <div className=\"container-fluid\">\r\n {!course.status && (\r\n <button className=\"btn btn-outline-primary mt-2\" onClick={recommend} value = {course.id}>\r\n Recommend this!\r\n </button>\r\n )}\r\n {course.status && (\r\n <button className=\"submit-with-icon\" onClick={()=>handleVote('upvote',course.id)} value = {course.id}>\r\n <i className=\"icon1 fas fa-arrow-up\"></i>\r\n </button>\r\n )}\r\n &nbsp;\r\n {course.status && (\r\n <button className=\"submit-with-icon\" onClick={()=>handleVote('downvote',course.id)} value = {course.id}>\r\n <i className=\"icon2 fas fa-arrow-down\"></i>\r\n </button>\r\n )}\r\n &nbsp; &nbsp;\r\n {course.status && (\r\n <span className=\"text-muted\">{course.upvotes} upvotes</span>\r\n )}\r\n </div>\r\n </div>\r\n );\r\n}", "function onLinkRated() {\r\n\tvar taskIdx = selectedTaskIdx();\r\n\tvar search = getSearch(taskIdx, gCurrentSearch.query);\r\n\tif (search) {\r\n\t\tvar link = getLink(search, gCurrentSearch.url);\r\n\t\tif (link) {\r\n\t\t\tvar rating = this.id == \"helpful_button\" ? HELPFUL_RATING : UNHELPFUL_RATING;\r\n\t\t\taddLinkRated(taskIdx, search.query, link.url, link.title, rating, true);\r\n\t\t\tupdateSearchHistory();\r\n\t\t\tswitchToSearch();\r\n\t\t}\r\n\t}\r\n}", "function modifyOverallRatingSubmission()\n{\n\t// Hide \"Did the candidate pass the interview?\":\n\tvar nodes = Array.from(document.getElementsByClassName('overall-recommendation')[0].childNodes);\n\tnodes.forEach(function (node) { if (/candidate pass the interview/.test(node.textContent)) { node.textContent = ''; } });\n\n\t// Change labels:\n\tdoOnSelector('.overall-recommendation [data-rating-id]', function (ratingElt) \n\t{ \n\t\tvar ratingValue = parseInt(ratingElt.getAttribute('data-rating-id'));\n\t\tratingElt.innerText = mulesoftOverallRatings[ratingValue - 1];\n\t}); \n}", "function updateLearnerProfile(data){\n\tif(data.type == \"correctness feedback\"){\n\t\tconsole.log(\"update learner profiles here\");\n\t\tif(data.parameter == \"correct\"){\n\t\t\tconsole.log(\"correct solution, updating profile\");\n\t\t\tajax(APP.LEARNER_PROFILE_UPDATE + \"?correct=true\" + \"&stepList=\" + escape(JSON.stringify(APP.currentStepsList)) + \"&problemObj=\" + escape(JSON.stringify(APP.currentProblem)));\n\t\t\t// DEBUG\n\t\t\t// window.open(\"http://127.0.0.1:8000/mobileinterface/learnerprofile/index\");\n\t\t}\n\t\telse if(data.parameter == \"incorrect\"){\n\t\t\tconsole.log(\"incorrect solution, updating profile\");\n\t\t\t// TODO Jon implement\n\t\t\tvar check = JSON.stringify(APP.currentProblem)\n\t\t\tajax(APP.LEARNER_PROFILE_UPDATE + \"?correct=false\" + \"&stepList=\" + escape(JSON.stringify(APP.currentStepsList)) + \"&problemObj=\" + escape(JSON.stringify(APP.currentProblem)) + \"&data=\" + escape(JSON.stringify(data)) )\n\t\t}\n\t}\n\t// some other action is being performed, check for actions\n\telse if(data.type == \"moveDistance\" || data.type == \"turnAngle\" || data.type == \"plotPoint\"){\n\n\t}\n}", "async function updateStatistics(isRecommended) {\n let stats = await wixData.get('review-stats', itemID);\n\n if (stats) {\n stats.rating += parseInt($w('#ratingsInput1').value, 10); \n stats.count += 1; \n // stats.recommended += (isRecommended === \"true\") ? 1 : 0;\n return wixData.update('review-stats', stats)\n }\n \n stats = {\n _id: itemID,\n rating: parseInt($w('#ratingsInput1').value, 10),\n count: 1,\n // recommended: (isRecommended === \"true\") ? 1 : 0\n };\n return wixData.insert('review-stats', stats)\n}", "function updateAttention ($target, className) {\n var $associated;\n \n $('.expandable__form-explainer, .image-map_overlay').removeClass(className);\n \n if (typeof $target.attr('href') !== 'undefined') {\n $associated = $( $target.attr('href') );\n } else if ( typeof $target.attr('id') !== 'undefined' ) {\n $associated = $('[href=#'+$target.attr('id')+']');\n }\n \n if (typeof $associated !== 'undefined') {\n if (className === 'has-attention') {\n $target.removeClass('hover-has-attention');\n $associated.removeClass('hover-has-attention');\n }\n $target.addClass(className);\n $associated.addClass(className);\n }\n }", "function updateActivities () {\n showCost();\n strikeOutMatches();\n}", "function updateView(res){\n let user = res[0]\n const name = document.querySelector(\"#displayname\")\n const email = document.querySelector('#displayemail')\n const intro = document.querySelector('#displayintro')\n const table = document.querySelector('#coursetable')\n name.innerHTML = user.name + \" \" + \"<small>\" + \" \" + user.programs + \" \" + \"</small>\" + \"<small>\" + user.year + \" year student.\" +\"</small>\"\n email.innerText = user.email\n // program.innerText = user.programs\n // year.innerText = user.year\n intro.innerText = user.selfIntro\n addCourse(user, table)\n}", "function Reviews({ review }) {\n\n const history = useHistory();\n const reviewId = review.user;\n const name = review.name;\n const age = review.age;\n const sex = review.sex;\n const race = review.race;\n const symptom = review.symptom;\n const rating = review.rating;\n const reviewDescrip = review.review;\n const [likeNumber, setlikeNumber] = useState(review.likeNumber);\n const likeUsers = review.likeUsers;\n const time = review.time.toDate();\n\n //changing the time format into MM/DD/YYYY\n const timeFormat =\n (\"0\" + (time.getMonth() + 1)).slice(-2) +\n \"/\" +\n time.getDate() +\n \"/\" +\n time.getFullYear();\n\n //checking if user is logged in or not \n const { currentUser } = useAuth();\n const checkEmail = currentUser == null ? 'no email' : currentUser.email\n \n // hook to track of whether the current logged in user has liked a review\n const [likeState, setlikeState] = useState(\n likeUsers.includes(checkEmail) ? true : false\n );\n \n /* based on current user toggling the lieks button, updating the med's \"likes\" count and \n adding/removing the current user's email as a \"liker\" in the database */\n async function handleLiking() {\n\n // redirecting to log in page if user is not signing/unregistered with an account\n if (checkEmail === 'no email') {\n return history.push(\"/log-in\")\n } else {\n setlikeState(!likeState);\n \n // extracting medId from path URL to use later, as document ID when fetching from the firebase\n const location = window.location.href.split(\"/\");\n const medId = location[location.length - 1];\n\n const reviewRef = db\n .collection(\"drug\")\n .doc(medId)\n .collection(\"Review\")\n .doc(reviewId);\n \n // increment or decrement the like number and keep track of which user like the comment\n if (!likeState) {\n reviewRef.update({\n likeNumber: update.increment(1),\n });\n\n reviewRef.update({\n likeUsers: update.arrayUnion(currentUser.email),\n });\n\n setlikeNumber(likeNumber + 1);\n\n } else if (likeState) {\n reviewRef.update({\n likeNumber: update.increment(-1),\n });\n\n reviewRef.update({\n likeUsers: update.arrayRemove(currentUser.email),\n });\n\n setlikeNumber(likeNumber - 1);\n }\n\n const userRef = db\n .collection(\"User\")\n .doc(reviewId)\n .collection(\"Review\")\n .doc(medId);\n\n // update the like and which user like the comment in the user collection\n if (!likeState) {\n userRef.update({\n likeNumber: update.increment(1),\n });\n\n setlikeNumber(likeNumber + 1);\n\n } else if (likeState) {\n userRef.update({\n likeNumber: update.increment(-1),\n });\n\n setlikeNumber(likeNumber - 1);\n }\n }\n }\n\n return (\n <div className=\"bg-light p-4 w-75 border-bottom justify-contents-center\" style={{borderRadius:5}}>\n <Media as=\"li\">\n\n <AccountCircleIcon \n className=\"d-inline-block mb-3 mr-3\" \n style={{fontSize:'45px'}}\n />\n\n <Media.Body>\n <h5><Link to={\"/home/user/\" + reviewId}>{name}</Link></h5>\n\n <Box\n component=\"fieldset\"\n mb={2}\n borderColor=\"transparent\"\n style={{\n overflowWrap: \"break-word\",\n textOverflow: \"ellipsis\",\n width: \"80%\",\n }}\n >\n <Typography component=\"legend\"> {timeFormat} </Typography>\n <Typography component=\"legend\">\n <strong>Demographic:</strong> {age}, {sex}, {race}\n <br></br>\n <strong>Symptom:</strong> {symptom}\n </Typography>\n \n <Rating name=\"read-only\" value={rating} readOnly />\n\n <p>{reviewDescrip}</p>\n\n <IconButton\n aria-label=\"delete\"\n size = \"small\"\n edge = \"start\"\n onClick={handleLiking}\n className=\"likeButton\"\n style={{fontSize:'20px'}}\n >\n {likeState ? <ThumbUpIcon /> : <ThumbUpAltOutlinedIcon />}\n {likeNumber}\n </IconButton>\n </Box>\n </Media.Body>\n </Media>\n </div>\n );\n}", "update () {\n const url = this.options_.user.avatar;\n const timecode = formatTime(this.timecode, this.player_.duration());\n this.setSrc(url);\n this.tcEl_.innerHTML = `${timecode} ${this.user.nickname ? '- ' + this.user.nickname : ''}`;\n // If there's no poster source we should display:none on this component\n // so it's not still clickable or right-clickable\n if (url) {\n this.show();\n } else {\n this.hide();\n }\n }", "function updateWorkoutInfo(workoutState) {\n $('#timeLeft').val(deadlineToTimeRemaining(workoutState['deadline'], workoutState['server_time']));\n var hits = sortHits(workoutState['correct_hits']);\n var misses = sortHits(workoutState['incorrect_hits']);\n $(\"#rhit\").text(hits['r'].length);\n $(\"#chit\").text(hits['c'].length);\n $(\"#lhit\").text(hits['l'].length);\n $(\"#rtime\").text(getAverage(hits['r']));\n $(\"#ctime\").text(getAverage(hits['c']));\n $(\"#ltime\").text(getAverage(hits['l']));\n $(\"#rmiss\").text(misses['r'].length);\n $(\"#cmiss\").text(misses['c'].length);\n $(\"#lmiss\").text(misses['l'].length);\n }", "function directUserFromUpdateInfo () {\n if (nextStep == \"The role for an existing employee\") {\n updateEmployeeRole();\n }\n }", "function needReview() {\n self.showNeedReview = self.docModel.needs_review;\n self.reviewUser = \"\"; // reset value of review asign user\n }", "setRecommendations () {\n const self = this.market;\n\n if (this.prevDemand > 0) {\n self.recommendedProduction = 5.0 * this.prevDemand;\n } else {\n self.recommendedProduction = 0;\n }\n // Recommended price is previous price plus 1 percent of delta demand\n const recommendedPrice = self.manualPrice + 0.01 * this.deltaDemand;\n if (recommendedPrice > 0) {\n self.recommendedPrice = recommendedPrice;\n } else {\n self.recommendedPrice = 0;\n }\n }", "function updateCurrentScoreTag(){\n var score = sessionStorage.getItem('nbCorrectAnswers');\n var examNumber = sessionStorage.getItem('examNumber');\n $('.currentScore').text('Note courante :' + score +' / ' + examNumber);\n }", "function C001_BeforeClass_Sidney_PantiesRemark() {\n\tif (C001_BeforeClass_Sidney_PantiesRemark_Done == false) {\n\t\tC001_BeforeClass_Sidney_PantiesRemark_Done = true;\n\t\tActorChangeAttitude(0, 1);\n\t\tOverridenIntroText = GetText(\"Panties\");\n\t}\n}", "function updatePracticePane()\n {\n evaluateInput()\n setTargetText()\n displayTargetText()\n updateProgress()\n updateSpeed()\n updateError()\n updateSmiley()\n\n if (my.current.state == my.STATE.COMPLETED) {\n displayAdvice()\n setResultTooltips()\n\n log('state', my.current.state.toUpperCase(),\n 'unit', my.current.unitNo + '.' + my.current.subunitNo,\n 'type', my.settings.unit,\n 'wpm', my.current.wpm,\n 'error', my.current.errorRate.toFixed(1))\n }\n }", "function showRemediation() {\n\n // gather objectives\n if (_objectives) {\n\n var gatheredRemedationPages = [];\n\n _objectives.forEach( function(objective) {\n if (objective.pass !== true) {\n if (objective.remediationq) {\n gatheredRemedationPages = gatheredRemedationPages.concat(objective.remediationq)\n }\n }\n });\n\n // if remediation pages found trigger remediation\n if (gatheredRemedationPages.length > 0) {\n setTimeout(function() {\n RemediationActions.create(gatheredRemedationPages);\n }, 0.1);\n }\n }\n}", "function updateProfileBasics(userData) {\n $('.name').text(userData['name']);\n $('#email').text(userData['email']);\n buildAsLabels(`#interests`, userData['interests'], 'interests');\n buildAsLabels(`#skills`, userData['skills'], 'skills');\n populateExistingImage('profile', '#profile-picture-main');\n}", "updateReferral(referral, referralText) {\n this.setState({\n referral,\n referralText\n });\n }", "function set_booking_row_remark_in_hint(booking_id, new_remark){\n jQuery('#booking_row_'+booking_id + ' .booking-actions .remark_bk_link').attr('data-original-title', new_remark);\n\n var my_img = jQuery('#booking_row_'+booking_id + ' .booking-actions .remark_bk_link img').attr('src');\n var check_my_img = my_img.substr( my_img.length - 7);\n if (check_my_img !== '_rd.png') {\n my_img = my_img.substr(0, my_img.length - 4);\n jQuery('#booking_row_'+booking_id + ' .booking-actions .remark_bk_link img').attr('src', my_img+'_rd.png');\n } else {\n my_img = my_img.substr(0, my_img.length - 7);\n jQuery('#booking_row_'+booking_id + ' .booking-actions .remark_bk_link img').attr('src', my_img+'.png');\n }\n\n\n}", "function modifyLecture() {\n // Ensure a lecture is currently selected.\n if (!currentLecture)\n return;\n \n // Set the current lecture's values.\n currentLecture.courseTitle = $('#courseTitle')[0].value;\n currentLecture.lectureTitle = $('#lectureTitle')[0].value;\n currentLecture.instructor = $('#instructor')[0].value;\n \n // Save the current lecture.\n saveLecture();\n}", "function Recommendation($state) {\n\t\t\t/*jshint validthis: true */\n\t\t\tvar vm = this;\n\n\t\t\tvm.saveRecommendation = function(recommendation){\n\t\t\t\tconsole.log(\"inside save Recommendation method\");\n\t\t\t\t$state.go(\"home.quoteCreation\");\n\t\t\t};\n\n\t\t}", "function updateCurrentStudent(position){\n $('#studentName').text(peopleArray[position].name);\n $('#studentGithub').html(\"<a href='\" + peopleArray[position].github + \"'>\"+peopleArray[position].github+\"</a>\");\n $('#studentShoutout').text(peopleArray[position].shoutout);\n}", "function postRespec() {\n\taddTextSemantics();\n\tswapInDefinitions();\n\ttermTitles();\n\tlinkUnderstanding();\n}", "function updateSkillProficiencies() {\n const proficiency = document.querySelector('#proficiency-bonus');\n const proficiencyBonus = (proficiency.textContent.includes('+'))\n ? parseInt(proficiency.textContent.slice(1)) : parseInt(proficiency.textContent);\n let fullBonus = 0;\n\n const skills = [\"acrobatics\", \"animal-handling\", \"arcana\", \"athletics\", \"deception\", \"history\", \"insight\",\n \"intimidation\", \"investigation\", \"medicine\", \"nature\", \"perception\", \"performance\", \"persuasion\",\n \"religion\", \"sleight-of-hand\", \"stealth\", \"survival\"];\n const relevantAbilityScores = [\"dex\", \"wis\", \"int\", \"str\", \"cha\", \"int\", \"wis\",\n \"cha\", \"int\", \"wis\", \"int\", \"wis\", \"cha\", \"cha\",\n \"int\", \"dex\", \"dex\", \"wis\"];\n\n for (let i = 0; i < skills.length; i++) {\n const abilityModifierObj = document.querySelector('#' + relevantAbilityScores[i] + '-modifier');\n fullBonus = 0;\n fullBonus += (abilityModifierObj.textContent.includes('+')) ?\n parseInt(abilityModifierObj.textContent.slice(1)) : parseInt(abilityModifierObj.textContent);\n\n const proficiencyIndicator = document.querySelector('#' + skills[i]);\n switch (proficiencyIndicator.value) {\n default:\n case 'none':\n fullBonus += 0;\n break;\n case 'proficient':\n fullBonus += proficiencyBonus;\n break;\n case 'expertise':\n fullBonus += proficiencyBonus * 2;\n break;\n }\n\n const proficiencyNumber = document.querySelector('#' + skills[i] + '-proficiency');\n proficiencyNumber.textContent = (fullBonus >= 0) ? '+' + fullBonus : '' + fullBonus;\n }\n\n const passivePerception = document.querySelector('#passive-perception');\n const perceptionObj = document.querySelector('#perception-proficiency');\n const perceptionMod = (perceptionObj.textContent.includes('+')) ?\n parseInt(perceptionObj.textContent.slice(1)) : parseInt(perceptionObj.textContent);\n const passivePerceptionMod = 10 + perceptionMod;\n passivePerception.textContent = (passivePerceptionMod >= 0) ? '+' + passivePerceptionMod : '' + passivePerceptionMod;\n}", "function EditCV() {\n useEffect(() => {\n topFunction()\n }, [])\n\n const [editMode] = useState(true)\n const user = UserProfile.getUser();\n const [openLoading, setOpenLoading] = useState(true)\n const history = useHistory();\n \n // states\n const [name, setName] = useState('')\n const [owner, setOwner] = useState([])\n const [about, setAbout] = useState('')\n const [skills, setSkills] = useState([/*{ id: 0, content: '' }*/])\n const [interests, setInterests] = useState([])\n const [experience, setExperience] = useState([])\n const [education, setEducation] = useState([])\n const [contactInformation, setContactInformation] = useState([])\n // states\n\n useEffect(() => {\n db.collection('resume').doc(user?.uid)\n .onSnapshot((snapshot) => {\n if (!snapshot.empty) {\n let r = snapshot.data()\n if (r) {\n setName(r?.name)\n setOwner(r?.user)\n setAbout(r?.about)\n setSkills(r?.skills)\n setInterests(r?.interests)\n setExperience(r?.experience)\n setEducation(r?.education)\n setContactInformation(r?.contactInformation)\n }\n setOpenLoading(false)\n }else{ history.goBack() }\n })\n }, [history, user])\n\n const handleSubmit = async () => {\n setOpenLoading(true)\n let photoURL = user?.photoURLmax ? user?.photoURLmax : user?.photoURL;\n let data = {\n userName: user.userName,\n user: { uid: user?.uid, displayName: user?.displayName, userName: user?.userName, photoURL },\n name, about, skills, interests, experience, education, contactInformation\n }\n\n await db.collection('resume').doc(user?.uid).set(data)\n setOpenLoading(false)\n }\n\n // const prevCV = () => {\n // history.push(`/cv/${user.userName}`)\n\n // // const downloadParent = document.querySelector('.downloadParent');\n // // const mainCV = document.querySelector('#mainCV');\n // // const prevCV = document.querySelector('#prevCV');\n\n // // if (downloadParent) {\n // // downloadParent.style.display = 'none';\n // // }\n\n // // if (mainCV && prevCV) {\n // // html2canvas(mainCV).then((canvas) => {\n // // prevCV.appendChild(canvas);\n // // });\n // // }\n\n // // if (downloadParent) {\n // // downloadParent.style.display = 'block';\n // // }\n // }\n\n return (\n <div id=\"resumetab\" className={`resume-cv ${!editMode ? 'resume-cv-edit' : ''}`}>\n {openLoading && <div className=\"loader\" style={{ display: 'grid' }}>\n <img src=\"/images/loading.svg\" alt=\"\" />\n </div>}\n\n <Helmet>\n <title>{`${user && (user.displayName)?.replace(/\\b(\\w)/g, s => s.toUpperCase())} - Hairrrs`}</title>\n <meta name=\"description\" content=\"Everything Hairs\" />\n <meta property=\"og:title\" content={`${user && user.displayName} - Hairrrs`} />\n <meta property=\"og:url\" content={`https://ntutu-fdb00.web.app/profile`} />\n <meta property=\"og:type\" content=\"article\" />\n <meta property=\"og:description\" content=\"Everything Hairs\" />\n <meta property=\"og:image\" content=\"https://firebasestorage.googleapis.com/v0/b/ntutu-fdb00.appspot.com/o/hairrrs-Logo-original-resized.png?alt=media&token=b322368f-6abc-477b-aa10-13f3ed71e277\" />\n </Helmet>\n\n\n <div id=\"prevCV\"></div>\n\n\n <div className=\"container\" id=\"mainCV\">\n <div className=\"header\">\n <div className=\"logo\">\n {/* <Link to=\"/\"><img src=\"/images/hairrrs-Logo.png\" alt=\"Hairrrs\" /></Link> */}\n </div>\n <div className=\"shareclass\">\n <div className=\"share\">\n <img src=\"images/Icon material-print.icon ohyanga\" alt=\"\" />\n </div>\n <div className=\"share\">\n <img src=\"images/Icon awesome-share-alt.icon ohyanga\" alt=\"\" />\n </div>\n </div>\n </div>\n <div className=\"title\">Resume</div>\n <div className=\"accord-inline\">\n <div className=\"b-photo-1\" style={{\n marginRight: '50px'\n }}>\n {owner && <img src={owner ? owner.photoURL : owner.photoURLmax} alt={owner?.userName} />}\n </div>\n {/* <div className=\"watermark\">\n from Hairrrs\n </div> */}\n <div className=\"details\">\n <div className=\"CV-INFO\">\n <txt>Name</txt>\n <br />\n <input\n value={name}\n onChange={(e) => { editMode && setName(e.target.value) }}\n type=\"text\"\n style={{ width: '100%' }}\n className=\"TEXTAREA1\" />\n </div>\n <div className=\"CV-INFO\">\n <txt>About</txt>\n <br />\n <div className=\"ADDTEXT\">\n <textarea\n value={about}\n onChange={(e) => { editMode && setAbout(e.target.value) }}\n type=\"text\" style={{\n height: '125px',\n width: '100%',\n border: '1px solid #c5c5c56e',\n resize: 'none',\n padding: 15,\n fontSize: '1rem',\n fontFamily: 'sans-serif'\n }}></textarea>\n </div>\n </div>\n <div className=\"CV-INFO\">\n <txt>Skills</txt>\n <br />\n <div className=\"texthub\">\n <Attachment\n editMode={editMode}\n questions={skills} setQuestions={setSkills}\n />\n </div>\n </div>\n\n <div className=\"CV-INFO\">\n <txt>Interests</txt>\n <br />\n <div className=\"texthub\">\n <Attachment\n editMode={editMode}\n questions={interests} setQuestions={setInterests}\n />\n </div>\n </div>\n\n <div className=\"CV-INFO\">\n <txt>Experience</txt>\n <br />\n <div className=\"texthub\">\n <Attachment\n editMode={editMode}\n questions={experience} setQuestions={setExperience}\n />\n </div>\n </div>\n\n <div className=\"CV-INFO\">\n <txt>Education</txt>\n <br />\n <div className=\"texthub\">\n <Attachment\n editMode={editMode}\n questions={education} setQuestions={setEducation}\n />\n </div>\n </div>\n\n <div className=\"CV-INFO\">\n <txt>Contact information</txt>\n <br />\n <div className=\"texthub\">\n <Attachment\n editMode={editMode}\n questions={contactInformation} setQuestions={setContactInformation}\n />\n </div>\n </div>\n <br />\n <br />\n <br />\n\n {editMode && <div className=\"downloadParent\">\n <center>\n <span onClick={handleSubmit} style={{\n border: '1px solid red',\n padding: '10px 15px',\n cursor: 'pointer'\n }}>save</span>\n\n {/* <span onClick={prevCV} style={{\n border: '1px solid red',\n padding: '10px 15px',\n cursor: 'pointer'\n }}>prev cv</span> */}\n </center>\n\n <br />\n <br />\n <br />\n </div>}\n\n </div>\n </div>\n </div>\n </div>\n\n )\n}", "function modifyUserObject() {\n let starRate = document.querySelectorAll(\".full\").length;\n userObject.starRate = starRate;\n userObject.review = document.querySelector(\".reviews_add-input\").value;\n putReviews(userObject);\n}", "function showperson(person)\r\n{\r\n const item=reviews[person];\r\n img.scr=item.img;\r\n author.textcontent=item.job;\r\n info.textcontent=item.text;\r\n}", "function refreshRecommendations() {\n\t// only want to run these if we are on the home page\n\tif ($(\"#searchField\").length != 0) {\n\t\t$.ajax({\n\t\t\turl: \"/userInfo\",\n\t\t\tmethod: \"GET\",\n\t\t\tcache: false,\n\t\t\tsuccess: function(resp) {\n\t\t\t\t// would error if not logged in\n\t\t\t\tif (resp != \"error\") {\n\t\t\t\t\tcurrentLanguage = resp['language'];\n\t\t\t\t\tgetRecommended();\n\t\t\t\t\tgetWatched();\n\t\t\t\t\tgetSearch();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t}\n}", "updateLearningRate() {\n /* history must have more than 2 values */\n if (this.mseHistory.length < 2) {\n return;\n }\n /* MSE went up = bad update then devide by 2*/\n if (this.mseHistory[0] > this.mseHistory[1]) {\n this.options.learningRate /= 2;\n }\n /* MSE went down : it is right direction then multiply with 5% */\n else {\n this.options.learningRate *= 1.05\n }\n }", "function FairUseRationale() {\n\tif((wgPageName == 'Special:Upload' || wgPageName == 'Special:MultipleUpload') && document.getElementById('wpDestFile').value == '') {\n\t\tdocument.getElementById('wpUploadDescription').value = '{{Fair Use Rationale\\n| Description = \\n| Source = \\n| Portion = \\n| Purpose = \\n| Resolution = \\n| Replaceability = \\n| Other Information = \\n}}';\n\t}\n}", "function update() {\n displayed = false;\n prev_subject = curr_subject;\n curr_subject = select(\"#phrase\").value();\n loadJSON(api+curr_subject+access_token, gotData);\n}", "async function saveTeachers(e) {\n e.preventDefault();\n const newData = await API.updateStudentsTeachers(checkTeachers);\n console.log(\"Student's teachers updated...printing new data...\", newData.data);\n // setUserState({\n // type: newData.data.userType,\n // imageUrl: newData.data.imageUrl,\n // teachers: newData.data.teachers,\n // school: newData.data.school\n // });\n window.location.reload(false);\n }", "function updateNewRating(newRating) {\n\t$('#current-rating').text(newRating)\n}", "function setProfile (elem) {\n try {\n var tweet = elem.querySelectorAll('[data-testid=\"tweet\"]')[0].children[1];\n } catch (e) {\n return;\n }\n var tweetId = elem.querySelectorAll('[data-testid=\"tweet\"]')[0].querySelectorAll(\"a\")[2].getAttribute(\"href\");\n // Format: /{handle}/status/{id}\n tweetId = tweetId.split(\"/\")[3];\n var checkRetweetWithoutText = tweet.parentElement.parentElement.children[0].querySelectorAll(\"a\")[0];\n\n var subTweet, retweetedAuthor = \"\", retweetedHandle = \"\", retweetedDate = \"\", retweetedText = \"\";\n var tweetAuthor = \"\", tweetHandle = \"\", tweetDate = \"\", tweetText = \"\";\n var tempAuthor = \"\", tempHandle = \"\", tempDate = \"\", tempText = \"\";\n\n var tempAuthor = tweet.children[0].children[0].children[0].querySelectorAll(\"span\")[0].textContent;\n var tempHandle = tweet.children[0].children[0].querySelectorAll(\"a\")[0].getAttribute(\"href\");\n tempHandle = \"@\" + tempHandle.slice(1);\n var tempDate = tweet.children[0].children[0].children[2].getAttribute(\"title\");\n var tempText = tweet.children[1].textContent;\n\n if (checkRetweetWithoutText) {\n tweetHandle =checkRetweetWithoutText.getAttribute(\"href\");\n tweetHandle = \"@\" + tweetHandle.slice(1);\n tweetAuthor = tweet.parentElement.parentElement.children[0].querySelectorAll(\"span\")[1].textContent;\n retweetedHandle = tempHandle;\n retweetedAuthor = tempAuthor;\n retweetedDate = tempDate;\n retweetedText = tempText;\n }\n else {\n tweetAuthor = tempAuthor;\n tweetHandle = tempHandle;\n tweetDate = tempDate;\n tweetText = tempText;\n }\n\n try {\n subTweet = elem.querySelectorAll('[data-testid=\"tweet\"]')[0].children[1].querySelectorAll('[role=\"blockquote\"]')\n retweetedAuthor = subTweet[0].children[0].children[0].children[0].querySelectorAll(\"span\")[0].textContent;\n retweetedHandle = subTweet[0].querySelectorAll(\"span\")[2].textContent;\n retweetedDate = subTweet[0].children[0].children[0].children[1].textContent;\n retweetedText = subTweet[0].children[0].children[1].textContent;\n } catch (e) {\n\n }\n // Profile\n var profile = {\"tweetText\": tweetText,\n \"retweetedText\": retweetedText,\n \"tweetDate\": tweetDate + \" \" + retweetedDate,\n \"tweetAuthor\": tweetAuthor + \" \" + retweetedAuthor,\n \"tweetHandle\": tweetHandle + \" \" + retweetedHandle,\n \"tweetId\": tweetId};\n return profile;\n }", "linkToProfile() {\n const id = this.props.person.id;\n const isStudent = this.props.person.customer_id ? true : false\n\n /* Use the customer_id field to check whether the person is\n a student or a teacher. */\n\n if (isStudent) {\n window.location = RouteConstants.admin.studentProfile(id);\n } else {\n window.location = RouteConstants.admin.teacherProfile(id);\n }\n }", "updateProfile() {}", "function updateUserProfile() {\n // $('#profile-name)\n $(\"#show-name\").html(` ${currentUser.name}`);\n $(\"#show-username\").html(` ${currentUser.username}`);\n $(\"#show-date\").html(` ${currentUser.createdAt.slice(0, 10)}`);\n }", "static updateImproved() {\n improvedTimestamps.forEach((timestamp) => {\n timestamp.update();\n });\n if (navPanel.isMounted()) {\n navPanel.updateTimestampsInRefreshButtonTooltip();\n }\n }", "function showRemarkInHomepage(userToken) {\n\tvar news = document.querySelector(\"#dashboard > div.news\");\n\tvar userCount = document.querySelectorAll(\"div.flex-items-baseline > div > a[data-hovercard-type=user]\").length;\n\tvar observer = new MutationObserver(function (mutations, self) {\n\t\tvar users = document.querySelectorAll(\"div.flex-items-baseline > div > a[data-hovercard-type=user]\");\n\t\tif (userCount != users.length) {\n\t\t\tuserCount = users.length\n\t\t\tusers.forEach(function (element) {\n clearRemarkOfCurrentNode(element.parentNode);\n\t\t\t\tvar username = getMasterOfPage(element.href);\n\t\t\t\tgetRemark(userToken, username, function (remark) {\n var remarkEl = generateRemarkSpan('link-gray pl-1 github-remarks', userToken, username, remark);\n\t\t\t\t\tinsertAfter(remarkEl, element);\n\t\t\t\t});\n\t\t\t}, this);\n\t\t}\n\t});\n\tobserver.observe(news, { childList: true, subtree: true });\n}", "function proTips(setterID){\n \n if(document.getElementById)\n {\n var cDate = new Date();\n\t var val = cDate.getSeconds() % setterTips.length;\n\t \n\t //add link and styles\n\t var stTemp = \"<a href='../protips.html' style='\";\n\t \n\t for(i=0; i < stStyles.length; i++)\n\t {\n\t stTemp = stTemp + stStyles[i];\n\t }\n\t \n\t stTemp = stTemp + \"'>\" + setterTips[val] + \"</a>\";\n\t \n var stObject = document.getElementById(setterID);\n \n stObject.innerHTML = stTemp; \n } \n }", "function updatePageWithUserClass() {\n pageHandler.getUserClassifierProperties().then(response => {\n const properties = response.properties;\n $('userClassDescription').textContent = properties.userClassDescription;\n $('avgHoursBetweenViews').textContent = properties.avgHoursBetweenViews;\n $('avgHoursBetweenUses').textContent = properties.avgHoursBetweenUses;\n });\n}", "updateNLPInfo(newText) {\n this.spinRefresh(true);\n var oldText = this.state.query.text;\n\n this.props.updateQuery(\n this.state.query.id,\n oldText,\n newText,\n (updatedQuery) => {\n this.setState(\n {\n query: updatedQuery,\n editMode: false,\n },\n () => {\n this.colorEntities();\n this.spinRefresh(false);\n }\n );\n }\n );\n }", "function updateRelationships(){\n\t\tconsole.log('gonna updateRelationships')\n\t\t//post per aggiornare relazione tra past e current.\n\t\tdate = new Date(Date.now());\n\t\t$.post(\"/relation\",{\n\t\t\tprevious: pastPlayerVideoId,\n\t\t\tclicked: getCurrentPlayerId(),\n\t\t\trecommender: currentPlayerRecommender,\n\t\t\tlastSelected: date\n\t\t}).done((data)=>{\n\t\t\tconsole.log('Relations Updated');\n\t\t})\n\t}", "async overwriteOldEvaluation() {\n const {\n classID,\n studentID,\n evaluationID,\n notes,\n rating,\n selectedImprovementAreas,\n highlightedAyahs,\n highlightedWords\n } = this.state;\n\n this.setState({ isLoading: true });\n let evaluationDetails = {\n rating,\n notes,\n highlightedWords,\n highlightedAyahs,\n improvementAreas: selectedImprovementAreas,\n };\n \n await FirebaseFunctions.overwriteOldEvaluation(\n classID,\n studentID,\n evaluationID,\n evaluationDetails\n );\n\n const currentClass = await FirebaseFunctions.getClassByID(\n this.state.classID\n );\n this.props.navigation.push(\"TeacherStudentProfile\", {\n studentID: this.state.studentID,\n currentClass,\n userID: this.props.navigation.state.params.userID,\n classID: this.state.classID\n });\n }", "function updateUserView(user) {\n console.log(`updating view with user ${user ? user.displayName : ''}`);\n $(\".username\").html(user ? user.displayName : \"anonymous\");\n $(\".userpic\").attr(\"src\", user ? user.photoURL : \"//placehold.it/30x30\");\n}", "function updateResult(pAns,pAnsCorrect,time){\r\n\r\n\tpersonTrainingResult+=stimuliCurrentInfo.seriesLetter+\":\"+stimuliCurrentInfo.seriesNumber+\":\"+pAns+\":\"+pAnsCorrect+\":\"+time+\";\";\r\n\tcommit();\r\n}", "function updateProfile()\r\n{\r\n // obtaining the data\r\n let name = document.getElementById(\"name\").value;\r\n let surname = document.getElementById(\"surname\").value;\r\n let dob = document.getElementById(\"dob\").value;\r\n let gender = document.getElementById(\"gender\").value;\r\n let city = document.getElementById(\"city\").value;\r\n let country = document.getElementById(\"country\").value;\r\n let educLevel = document.getElementById(\"educLevel\").value;\r\n let studyArea = document.getElementById(\"studyArea\").value;\r\n let science = document.getElementById(\"science\");\r\n let medicine = document.getElementById(\"medicine\");\r\n let travel = document.getElementById(\"travel\");\r\n let education = document.getElementById(\"education\");\r\n let sports = document.getElementById(\"sports\");\r\n let nutrition = document.getElementById(\"nutrition\");\r\n let economy = document.getElementById(\"economy\");\r\n let environment = document.getElementById(\"environment\");\r\n let interests = \"\";\r\n let password = document.getElementById(\"password\").value;\r\n\r\n // checking which interests did the user select\r\n if (science.checked == true)\r\n {\r\n interests += \"science||\";\r\n }\r\n if (medicine.checked == true)\r\n {\r\n interests += \"medicine||\";\r\n }\r\n if (travel.checked == true)\r\n {\r\n interests += \"travel||\";\r\n }\r\n if (education.checked == true)\r\n {\r\n interests += \"education||\";\r\n }\r\n if (sports.checked == true)\r\n {\r\n interests += \"sports||\";\r\n }\r\n if (nutrition.checked == true)\r\n {\r\n interests += \"nutrition||\";\r\n }\r\n if (economy.checked == true)\r\n {\r\n interests += \"economy||\";\r\n }\r\n if (environment.checked == true)\r\n {\r\n interests += \"environment||\";\r\n }\r\n\r\n // if user entered all the required data - update user to the database and update the view\r\n if ( name && surname && dob && gender && city && country && educLevel && password)\r\n {\r\n let userId = sessionStorage.getItem(\"userId\");\r\n\r\n // add user to the database\r\n // create object with user data to send to the server\r\n let editObject = {\r\n _id: userId,\r\n _name: name,\r\n _surname: surname,\r\n _dob: dob,\r\n _gender: gender,\r\n _city: city,\r\n _country: country,\r\n _studyLevel: educLevel,\r\n _studyArea: studyArea,\r\n _interests: interests,\r\n _password: password\r\n };\r\n\r\n // sending xml request\r\n let xml = new XMLHttpRequest;\r\n\r\n // function that is called when reply received from server\r\n xml.onreadystatechange = () =>\r\n {\r\n if ((xml.readyState == 4) && (xml.status == 200))\r\n {\r\n let updateResult = xml.responseText;\r\n\r\n // update the view\r\n messageOne.innerHTML = \"Successfully Updated \" + updateResult + \" User\";\r\n messageOne.style.display = \"block\";\r\n\r\n viewTitle.style.display = \"none\";\r\n textboxOne.style.display = \"none\";\r\n textboxTwo.style.display = \"none\";\r\n rightContainer.style.display = \"none\";\r\n mainContainer.style.display = \"none\";\r\n // updating the text on the button and its functionality\r\n buttonOne.innerText = \"Log Out\";\r\n buttonOne.onclick = logout; \r\n // updating the text on the link and its functionality\r\n linkOne.innerText = \"Edit My Profile\";\r\n linkOne.onclick = editProfile;\r\n\r\n //clearing the local storage\r\n localStorage.clear();\r\n }\r\n };\r\n\r\n //Send new user data to server\r\n xml.open(\"POST\", \"/amendUser\", true);\r\n xml.setRequestHeader(\"Content-type\", \"application/json\");\r\n xml.send(JSON.stringify(editObject)); \r\n }\r\n \r\n // if user did not fill in all the entries\r\n else\r\n {\r\n document.getElementById(\"editFormMsg\").innerHTML = \"Enter all fields.\";\r\n return;\r\n } \r\n}", "function setData(){\n\n\t\t$.ajax({\n\t\t\turl : \"/currentTitle\",\n\t\t\tmethod: \"GET\",\n\t\t\tsuccess : function(foundNote){\n\t\t\t\tif(foundNote!==false){\n\t\t\t\t\t$('#title').val(foundNote.title);\n\t\t\t\t\t$('#note-view').val(foundNote.text);\n\t\t\t\t\t$('#course').val(foundNote.code);\n\t\t\t\t}\n\t\t\t\t$.ajax({\n\t\t\t\t\turl : \"/current\",\n\t\t\t\t\tmethod: \"GET\",\n\t\t\t\t\tsuccess : function(currentUser){\n\t\t\t\t\t\tif(currentUser!==false){\n\t\t\t\t\t\t\t\t$(\"#author\").text(currentUser);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t\t\n\t\t\t}\n\t\t});\n\t}", "update() {\n // Destructuring props\n const { teacher, teacherRef } = this.props;\n\n if (teacher.name !== '') {\n teacherRef.update({\n full_name: teacher.name ? teacher.name : 'Unknown',\n age: teacher.age ? teacher.age : '',\n gender: teacher.gender ? teacher.gender : '',\n email: teacher.email ? teacher.email : '',\n phone: teacher.phone ? teacher.phone : '',\n country: teacher.country ? teacher.country : '',\n });\n\n // show the confirmation message\n this.setState({\n showMessage: 'block',\n });\n // hide the confirmation message\n this.interval = setTimeout(() => {\n this.setState({\n showMessage: 'none',\n });\n }, 3000);\n }\n }", "function updateLink() {\n const url = urlInput.value;\n const name = nameInput.value;\n editBookmark({url, name, key}, () => {\n renderBookmarks(pagination.currentPage);\n cancelEdit();\n });\n }", "review() {\n if (this.complete) {\n this.complete = !this.complete;\n }\n }", "function ImprovementResultsCtrl($scope, $location, $routeParams, QuestionsNew, ResponsesPerUser, UserData, Store, Examples, Gebieden, Functions) {\n var storedGebied = Store.getResults().resultgebied;\n var storedTestnr = Store.getResults().testnr;\n var urlGebied = $routeParams.gebied;\n var urlTestnr = $routeParams.tid == 'null' ? null : $routeParams.tid;\n var mode = $routeParams.mode; // To edit existing results\n var now = new Date();\n var nowString = now.toISOString();\n\n // Define type\n if (Store.getResults().newontwikkel) getData('prefillednew', storedGebied, storedTestnr);\n else if (urlGebied !== undefined && urlTestnr !== undefined) getData('detailview', urlGebied, urlTestnr);\n else if (urlGebied !== undefined && urlTestnr == undefined) getData('gebiedview', urlGebied);\n else getData('home');\n\n // Return trait and high/low by calculating most extreme trait\n // TODO: set low (<-3), middle (-3<x<3) and high (>3) in general settings\n function getTrait(traits, personality){\n //console.log(personality);\n var traitDef = {trait: '', absScore: 0, highlow: ''};\n for (trait in traits){\n if (trait !== 'default'){\n var score = personality[trait].real / personality[trait].max;\n var highlow = score < 0 ? 'low' : 'high';\n var absScore = Math.abs(score);\n traitDef = absScore > traitDef.absScore ? {trait: trait, absScore: absScore, highlow: highlow} : traitDef;\n }\n }\n if (traitDef.absScore > 0.3) return {trait: traitDef.trait, highlow: traitDef.highlow};\n else return {trait: 'default'};\n }\n\n function stepsPerRoadmap(roadmap) {\n // Returns (1) steps in roadmap and (2) last unfinished step\n var steps = [];\n for (var i = 0; i < roadmap.length; i++) {\n steps.push(roadmap[i].step);\n if (roadmap[i].datum_start !== undefined) var lastStepDone = i;\n }\n var roadmapDone = lastStepDone == roadmap.length - 1 ? true : false;\n return {\n steps: steps,\n laststepdone: lastStepDone,\n roadmapdone: roadmapDone\n };\n }\n\n function getData(type, gebied, resultnr, onderdeel) {\n //console.log(type, gebied);\n var gebiedWf = urlGebied == 'functionering' ? 'functionering' : gebied;\n resultnr = urlGebied == 'functionering' ? parseInt(urlTestnr) : resultnr;\n\n Promise.all([QuestionsNew, ResponsesPerUser, UserData]).then(function(data) {\n // Role based: If demo user with expired account redirect\n var access = Functions.getAccess('allButDemoExpired', data[2].type, data[2].datum, now);\n if(!access) {\n $scope.$apply(function() {$location.path('/pagina/geen-toegang/demo-user'); })\n }\n else {\n var username = data[1].username;\n data[1].responses.then(function(responses) {\n var responses = responses.advies;\n var resultsObj = {};\n var lastResultsObj = {};\n // Last results are needed for any view because we want to display the tabs in any view.\n // But with current design responses loop is run twice in worst case. Once for getting last results and one to get metadata. For now okay.\n for (var gebiedInDB in responses) {\n var lrpg = Functions.lastResultPerGebied(responses, gebiedInDB, 'advies', 'started');\n lastResultsObj[gebiedInDB] = lrpg;\n if (gebiedInDB !== 'functionering') lastResultsObj[gebiedInDB].youtube = data[0].profile.youtube[gebiedInDB];\n }\n resultsObj.lastresults = lastResultsObj;\n switch (type) {\n case 'prefillednew':\n var resultStr = 'advies-' + resultnr;\n var results = responses !== undefined ? responses[gebiedWf] : undefined;\n results = results !== undefined ? responses[gebiedWf][resultStr] : undefined;\n var onderdelen = urlGebied !== 'functionering' ? Store.getResults().onderdelen[gebied].main : data[0].profile.ontwikkeling[gebied];\n var onderdeel = urlGebied !== 'functionering' ? Store.getResults().onderdelen[gebied].meta.lowest : 'functionering';\n var personality = Store.getResults().personality;\n\n // If there isn't a lowest onderdeel (all onderdelen above 0.5) and not coming from functionering then display movie\n if (!onderdeel) {\n $scope.playMovie('nolowest');\n $scope.ytId = data[0].profile.youtube[gebied];\n return;\n }\n // Make a new ontwikkeltraject if (1) there isn't a database entry for this gebied/resultnr combination or (2) nulltest for that gebied (overwrite existing traject)\n else if (results == undefined || resultStr == 'advies-null') {\n if (urlGebied !== 'functionering') var trait = getTrait(onderdelen[onderdeel], personality);\n else var trait = {trait: 'default'};\n var results = {newadv: true};\n if (trait.trait == 'default'){\n results.solution = onderdelen[onderdeel].default.solution;\n results.roadmap = Object.values(onderdelen[onderdeel].default.roadmap);\n }\n else {\n results.solution = onderdelen[onderdeel][trait.trait][trait.highlow].solution;\n results.roadmap = Object.values(onderdelen[onderdeel][trait.trait][trait.highlow].roadmap);\n }\n console.log(onderdelen, onderdeel);\n // Determine if personality test results are counted in or not (treshold is a max below 5 for extraversie en vriendelijkheid (completely random :-))\n if (urlGebied !== 'functionering') {\n if (personality.extraversie.max > 5 && personality.vriendelijkheid.max > 5) $scope.personalitydisplay = true;\n }\n }\n else type = 'detailview';\n resultsObj[gebied] = {\n resultnr: resultnr,\n results: results,\n resultstr: resultStr,\n youtube: data[0].profile.youtube[gebied]\n };\n break;\n case 'detailview':\n var resultStr = 'advies-' + resultnr;\n var results = responses[gebied][resultStr];\n resultsObj[gebied] = {\n resultnr: resultnr,\n results: results,\n resultstr: resultStr,\n youtube: data[0].profile.youtube[gebied]\n };\n break;\n case 'gebiedview':\n // resultsObj is different in this case; it contains metadata per result\n var mpr = Functions.metadataPerResult(responses, gebied, 'advies');\n resultsObj[gebied] = {\n metadata: mpr\n };\n break;\n }\n getViews(resultsObj, username, type);\n });\n }\n });\n }\n\n function getViews(resultsObj, username, type) {\n document.getElementById('spinner').style.display = 'none';\n if (Object.keys(resultsObj.lastresults).length == 0 && type !== 'prefillednew') $scope.noadvicedisplay = true;\n else {\n // Be sure that resultsObj.lastresults isn't empty in case of first ontwikkelttaject\n if (Object.keys(resultsObj.lastresults).length == 0) resultsObj.lastresults[storedGebied] = resultsObj[storedGebied];\n\n $scope.tabs = [];\n for (var gebied in resultsObj.lastresults) {\n if (resultsObj.lastresults[gebied] !== undefined) {\n // A view initial setting for display, active tab and youtube movie\n resultsObj.lastresults[gebied].display = $scope.tabs.length == 0 ? true : false;\n if (type == 'home') {\n resultsObj.lastresults[gebied].active = $scope.tabs.length == 0 ? true : false;\n if ($scope.tabs.length == 0) $scope.ytId = resultsObj.lastresults[gebied].youtube;\n }\n else resultsObj.lastresults[gebied].active = resultsObj[gebied] !== undefined ? true : false;\n resultsObj.lastresults[gebied].name = Gebieden.gebiedsnamen[gebied];\n $scope.tabs.push(Gebieden.gebiedsnamen[gebied]);\n }\n gebied = type == 'prefillednew' ? storedGebied : gebied;\n if (resultsObj[gebied] !== undefined) {\n $scope.gebied = gebied;\n $scope.gebiedsnaam = Gebieden.gebiedsnamen[gebied];\n }\n switch (type) {\n case 'detailview':\n case 'prefillednew':\n $scope.type = type;\n if (resultsObj[gebied] !== undefined) {\n $scope.solution = resultsObj[gebied].results.solution;\n $scope.roadmap = resultsObj[gebied].results.roadmap;\n var advStr = resultsObj[gebied].resultstr;\n $scope.ytId = resultsObj[gebied].youtube;\n $scope.editsolution = $scope.solution;\n $scope.editroadmap = $scope.roadmap;\n if (mode == 'edit') {\n $scope.editresultdisplay = true;\n // Add step function in edit mode. Takes into account that roadmap is not created yet\n $scope.addStep = function(type) {\n if (type == 'detailview') {\n if ($scope.roadmap == undefined) $scope.roadmap = [{step: '', feedback: ''}];\n else $scope.roadmap.push({step: '', feedback: ''});\n }\n else if (type == 'prefillednew') $scope.roadmap.push('');\n }\n $scope.removeStep = function() {\n $scope.roadmap.pop();\n //if ($scope.roadmap.length == 1) $scope.showbutton = false;\n };\n }\n else {\n if (type == 'detailview') $scope.viewresultdisplay = true;\n else $scope.playMovie('detail', type);\n }\n if (type == 'prefillednew') $scope.prefilleddisplay = true;\n }\n break;\n case 'gebiedview':\n if (resultsObj[gebied] !== undefined) {\n $scope.gebiedviewdisplay = true;\n $scope.metadatas = resultsObj[gebied].metadata;\n }\n break;\n case 'home':\n $scope.homedisplay = true;\n break;\n }\n\n // To view or edit result screen\n $scope.toResult = function(gebiedinp, resultnrinp, mode, parent) {\n gebied = gebiedinp !== undefined ? gebiedinp : gebied;\n gebied = urlGebied == 'functionering' ? urlGebied : gebied;\n if (type == 'prefillednew' && urlGebied == 'functionering') var resultnr = urlTestnr;\n else if (resultnrinp !== undefined) var resultnr = resultnrinp;\n else if (parent == 'home') var resultnr = resultsObj.lastresults[gebied].resultnr;\n else if (parent == 'detail') var resultnr = resultsObj[gebied].resultnr;\n console.log(gebied + ' : ' + resultnr);\n if (mode == 'edit') $location.path('/verbetertrajecten/' + gebied + '/' + resultnr + '/edit');\n else $location.path('/verbetertrajecten/' + gebied + '/' + resultnr);\n }\n\n // To archive of gebied\n $scope.toGebiedResults = function(gebied) {\n $location.path('/verbetertrajecten/' + gebied);\n }\n }\n $scope.results = resultsObj;\n //console.log($scope.results);\n\n // Put functionering last in tabs if exists\n var funcTabIndex = $scope.tabs.indexOf('functionering');\n var nrOfTabs = $scope.tabs.length;\n $scope.tabs.splice(nrOfTabs - 1, 0, $scope.tabs.splice(funcTabIndex, 1)[0]);\n }\n\n $scope.editResult = function(gebied, roadmap, type) {\n gebied = urlGebied == 'functionering' && type == 'prefillednew' ? urlGebied : gebied;\n advStr = urlGebied == 'functionering' && type == 'prefillednew' ? 'advies-' + urlTestnr : advStr;\n console.log(gebied, roadmap, type);\n firebase.database().ref().child('responses/' + username + '/advies/' + gebied + '/' + advStr + '/solution').set($scope.editsolution);\n firebase.database().ref().child('responses/' + username + '/advies/' + gebied + '/' + advStr + '/roadmap').remove();\n for (var i = 0; i < roadmap.length; i++) {\n if (roadmap[i].datum_start !== undefined) firebase.database().ref().child('responses/' + username + '/advies/' + gebied + '/' + advStr + '/roadmap/' + i + '/datum_start').set(roadmap[i].datum_start);\n if (roadmap[i].datum_end !== undefined) firebase.database().ref().child('responses/' + username + '/advies/' + gebied + '/' + advStr + '/roadmap/' + i + '/datum_end').set(roadmap[i].datum_end);\n var step = type == 'prefillednew' ? roadmap[i] : roadmap[i].step;\n if (step !== '') firebase.database().ref().child('responses/' + username + '/advies/' + gebied + '/' + advStr + '/roadmap/' + i + '/step').set(step);\n if(roadmap[i].feedback !== '' && roadmap[i].feedback !== undefined) firebase.database().ref().child('responses/' + username + '/advies/' + gebied + '/' + advStr + '/roadmap/' + i + '/feedback').set(roadmap[i].feedback);\n }\n if (type == 'prefillednew') {\n firebase.database().ref().child('responses/' + username + '/advies/' + gebied + '/' + advStr + '/datum_start').set(nowString);\n if (advStr !== 'advies-null') {\n $scope.setreminderdisplay = true;\n firebase.database().ref().child('responses/' + username + '/advies/' + gebied + '/' + advStr + '/status').set('unfinished');\n }\n else {\n $scope.roadmapsentdisplay = true;\n $scope.roadmapnulldisplay = true;\n var testStr = advStr.replace(\"advies\", \"test\");\n firebase.database().ref().child('responses/' + username + '/advies/' + gebied + '/' + advStr + '/status').set('closed');\n firebase.database().ref().child('responses/' + username + '/test/' + gebied + '/' + testStr + '/status').set('closed');\n }\n $scope.viewresultdisplay = false;\n $scope.editresultdisplay = false;\n }\n else $location.path('/verbetertrajecten/' + gebied + '/' + resultsObj[gebied].resultnr);\n }\n\n $scope.setReminder = function(notification, step, nrofsteps) {\n gebied = urlGebied == 'functionering' && type == 'prefillednew' ? urlGebied : gebied;\n advStr = urlGebied == 'functionering' && type == 'prefillednew' ? 'advies-' + urlTestnr : advStr;\n firebase.database().ref().child('responses/' + username + '/advies/' + gebied + '/' + advStr + '/roadmap/' + step + '/datum_start').set(nowString);\n if (notification !== 0){\n var datumRem = Functions.setWfDate('notification', parseInt(notification));\n firebase.database().ref().child('notifications/' + username + '/messageType').set('roadmap');\n firebase.database().ref().child('notifications/' + username + '/datum').set(datumRem);\n $scope.setreminderdisplay = false;\n $scope.roadmapsentdisplay = true;\n }\n else if (step >= nrofsteps - 1) {\n firebase.database().ref().child('responses/' + username + '/advies/' + gebied + '/' + advStr).remove();\n $scope.setreminderdisplay = false;\n $scope.roadmapsentdisplay = true;\n $scope.fallsavedisplay = true;\n }\n else {\n firebase.database().ref().child('responses/' + username + '/advies/' + gebied + '/' + advStr + '/roadmap/' + step + '/datum_end').set(nowString);\n $scope.step = step + 1;\n $scope.notification = undefined;\n // Get animation effect via css\n $scope.fadeOutIn = true;\n }\n // Reset animation class\n setTimeout(function() {\n $scope.fadeOutIn = false;\n }, 1000);\n }\n\n $scope.isActiveTab = function(gebiedsnaam) {\n var gebied = Functions.valToKey(gebiedsnaam, Gebieden.gebiedsnamen);\n return $scope.results.lastresults[gebied].active;\n }\n\n $scope.onClickTab = function(gebiedsnaam) {\n // First set all gebieden displays on false and inactive\n var gebied = Functions.valToKey(gebiedsnaam, Gebieden.gebiedsnamen);\n switch (type) {\n case 'home':\n for (var gebiedAll in $scope.results.lastresults) {\n if ($scope.results.lastresults[gebiedAll] !== undefined) {\n $scope.results.lastresults[gebiedAll].display = false;\n $scope.results.lastresults[gebiedAll].active = false;\n }\n }\n // Then set the clicked tab display on true and active\n $scope.results.lastresults[gebied].display = true;\n $scope.results.lastresults[gebied].active = true;\n $scope.ytId = $scope.results.lastresults[gebied].youtube;\n break;\n case 'gebiedview':\n case 'detailview':\n $location.path('/verbetertrajecten/' + gebied);\n break;\n }\n }\n }\n\n $scope.getHome = function() {\n $location.path('/');\n }\n\n $scope.getTrajecten = function() {\n $location.path('/verbetertrajecten');\n }\n\n // Play instruction movie\n $scope.playMovie = function(page, type) {\n $scope.playerVars = {showinfo: 0, autoplay: 1};\n $scope.moviedisplay = true;\n $scope.viewresultdisplay = $scope.homedisplay = false;\n if (type == 'prefillednew') $scope.fromtestsdisplay = true;\n $scope.page = page;\n }\n\n $scope.$on('youtube.player.ended', function($event, player) {\n $scope.moviedisplay = false;\n if (Store.getResults().onderdelen[urlGebied].meta.lowest) $scope.viewresultdisplay = true;\n else $scope.nolowestdisplay = true;;\n });\n\n // Skip instruction movie and show advice\n $scope.skipMovie = function(page) {\n $scope.moviedisplay = false;\n if (page == 'detail') $scope.viewresultdisplay = true;\n else if (page == 'nolowest') $scope.nolowestdisplay = true;\n else $scope.homedisplay = true;\n }\n}", "function updateBanner() {\n if (referenceTarget) {bannerDiv.innerHTML = '<h1>Click to destroy the target!</h1>'; }\n else if(targets_destroyed == 0) { bannerDiv.innerHTML = '<h1>Destroyed: 0</h1><h1>Avg Time: N/A</h1><h1>Accuracy: N/A</h1>'; }\n else { \n const time_per_target = target_times.avg();\n const accuracy = 100*hits / shots;\n bannerDiv.innerHTML = `<h1>Destroyed: ${targets_destroyed}</h1><h1>Avg Time: ${time_per_target.toFixed(3)}s</h1><h1>Accuracy: ${accuracy.toFixed(1)}%</h1>`; \n }\n}", "function updatePage(){\n\t\tvar totalVotes = goodVotes+badVotes;\n\t\t//a fancy way to do console.log()\n\t\tif(x>0){ $('#judgement').text('Good Haircut'); }\n\t\telse if(x<0){ $('#judgement').text('Bad Haircut'); }\n\t\telse{ $('#judgement').text('Unknown'); }\n\t\t$('#confidence>span').text(confidence);\n\t\t$('#agreementValue').text(agreement);\n\t\t$('#numberOfVotes').text(totalVotes);\n\t\t$('#runningTotal').text(x);\n\t\tif(goodVotes>0) $('#goodVotes').text(\"(\"+goodVotes+\")\");\n\t\tif(badVotes>0) $('#badVotes').text(\"(\"+badVotes+\")\");\n\t}", "sendLinks () {\n let { linkedin_link, website_link } = this.state\n updateStudent({ linkedin_link, website_link })\n }", "function ProfileLeftCol(props) {\n // Authenticated user's state\n const [userState, setUserState] = useState({});\n\n // Current state of teachersList array\n const [teachers, setTeachers] = useState([]);\n\n useEffect(() => {\n async function loadData() {\n if (props.type === \"teacher\") {\n const data = await API.getTeacher();\n setUserState({\n type: props.type,\n imageUrl: data.data.imageUrl\n })\n } else {\n const data = await API.getStudentData();\n console.log(\"Loading student's data...\", data.data);\n setUserState({\n type: props.type,\n imageUrl: data.data.imageUrl,\n teachers: data.data.teachers,\n school: data.data.school\n })\n // console.log(\"Printing data.data.teachers from getStudentData()...\", data.data.teachers);\n const teachers = await API.getTeachersBySchool(data.data.school);\n setTeachers(teachers.data);\n // console.log(\"Printing teachers.data...\", teachers.data);\n }\n }\n loadData();\n }, []);\n\n const [checkTeachers, setCheckTeachers] = useState([]);\n // Handle for checking checkboxes for teachers\n function handleCheckbox(e) {\n // console.log('checked', e.target.checked);\n // console.log('name', e.target.name);\n const newTeachers = [...checkTeachers];\n if (e.target.checked) {\n newTeachers.push(e.target.name);\n }\n else {\n const index = newTeachers.indexOf(e.target.name)\n newTeachers.splice(index, 1);\n }\n setCheckTeachers(newTeachers);\n }\n // Update student's list of teachers in the db\n async function saveTeachers(e) {\n e.preventDefault();\n const newData = await API.updateStudentsTeachers(checkTeachers);\n console.log(\"Student's teachers updated...printing new data...\", newData.data);\n // setUserState({\n // type: newData.data.userType,\n // imageUrl: newData.data.imageUrl,\n // teachers: newData.data.teachers,\n // school: newData.data.school\n // });\n window.location.reload(false);\n }\n\n let imageUrlRef = useRef();\n // Update user's imageUrl field with the new url\n const handleSave = async (e) => {\n e.preventDefault();\n\n // Make a put request to update user's data with the image\n if (props.type === \"teacher\") {\n await API.updateTeacher(props.id, {\n imageUrl: imageUrlRef.current.value\n })\n } else if (props.type === \"student\") {\n await API.updateStudent(props.id, {\n imageUrl: imageUrlRef.current.value\n })\n }\n setUserState({\n type: props.type,\n imageUrl: imageUrlRef.current.value\n })\n }\n\n //initialize i for incrememnting teacher emails in props\n var i = -1;\n return (\n\n <div className=\"left-col-container uk-align-left uk-flex uk-flex-column uk-padding\" >\n <div className=\"uk-text-large\">\n {props.name}\n </div>\n <div className=\"uk-text-small uk-margin-bottom\">\n {props.school}\n </div>\n <div className=\"uk-flex uk-flex-column image-and-info\">\n <div className=\"uk-inline-clip uk-transition-toggle uk-light profile-pic-container uk-flex uk-flex-center uk-flex-middle\" tabIndex=\"0\">\n <img src={userState.imageUrl || (props.type === \"teacher\" ? teacherImg : studentImg)} alt=\"Profile Avatar\" className=\"profile-picture\" />\n <div className=\"uk-position-center\">\n <span className=\"uk-transition-fade edit-pic-btn\" uk-icon=\"icon: pencil\" uk-toggle=\"target: #image-url-input\"></span>\n </div>\n </div>\n <div id=\"image-url-input\" uk-modal=\"true\">\n <div className=\"uk-modal-dialog uk-modal-body\">\n <button className=\"uk-modal-close-default\" type=\"button\" uk-close=\"true\"></button>\n <form className=\"uk-form-stacked uk-position-relative studentForm\" uk-height-viewport=\"expand: true\">\n <h3>Enter a hyperlink for your profile picture</h3>\n <div className=\"uk-margin\">\n <label className=\"uk-form-label uk-text\">Image Url</label>\n <div className=\"uk-form-controls\">\n <input className=\"uk-input uk-form-width-medium stuInput\" id=\"imageUrl\" type=\"text\" placeholder=\"https://www.image.com/image.png\" ref={imageUrlRef} />\n </div>\n </div>\n <p className=\"uk-text-right\">\n <button className=\"uk-button uk-modal-close uk-margin-small-right secondaryBtn\" type=\"button\">Cancel</button>\n <button className=\"uk-button uk-modal-close primaryBtn\" type=\"button\" onClick={handleSave}>Save</button>\n </p>\n </form>\n </div>\n </div>\n <div className=\"uk-flex uk-flex-column\">\n {props.teachers ? (\n <div className=\"uk-text-small uk-margin-top user-info\">\n <div className=\"uk-flex uk-flex-middle\">\n <div className=\"uk-text-small uk-margin-small-right\">Teachers</div>\n <button uk-icon=\"icon: pencil; ratio: .9\" type=\"button\" uk-toggle=\"target: #teachers-update\"></button>\n </div>\n <div id=\"teachers-update\" uk-modal=\"true\">\n <div className=\"uk-modal-dialog uk-modal-body\">\n <h2 className=\"uk-modal-title\">Update Teachers</h2>\n <div className=\"uk-margin uk-grid-small uk-child-width-auto uk-grid\">\n {\n teachers && teachers.length > 0 ? (\n teachers.map(teacher => {\n return <label key={teacher._id}>\n <input\n name={teacher._id}\n className=\"uk-checkbox\"\n type=\"checkbox\"\n onClick={handleCheckbox}\n />\n {teacher.name}\n </label>\n })\n ) : <p className=\"uk-text-danger\">No teachers found under this school.</p>\n }\n\n </div>\n <div className=\"uk-flex uk-flex-right uk-margin-large-top\">\n <button className=\"uk-button secondaryBtn uk-modal-close uk-margin-small-right\" type=\"button\">Cancel</button>\n <button className=\"uk-button primaryBtn\" type=\"button\" onClick={saveTeachers}>Save</button>\n </div>\n </div>\n </div>\n {props.teachers.map(item => {\n i++;\n return (\n <div uk-tooltip={props.teacheremails[i]} key={item}>{item}</div>\n )\n })}\n {/* {props.teachers.join(\", \")} */}\n </div>\n ) : <div></div>}\n {props.subjects ? (\n <div className=\"uk-margin-top\">\n <div className=\"uk-text-small\">Subjects</div>\n {props.subjects.join(\", \")}\n </div>\n ) : <div></div>}\n {props.email ? (\n <div className=\"uk-margin-small-top\">\n <div className=\"uk-text-small\">Email</div>\n {props.email}\n </div>\n ) : <div></div>}\n </div>\n </div>\n </div>\n )\n}", "function updateStatus(dueler,life,mana){\n\t\t\tvar lifeElm = docGet(dueler + \"Life\");\n\t\t\tvar manaElm = docGet(dueler + \"Mana\");\n\t\t\tlifeElm.innerHTML = toNumber(lifeElm.innerHTML) + life;\n\t\t\tmanaElm.innerHTML = toNumber(manaElm.innerHTML) + mana;\n\n\t\t}", "function updatePlanText() {\n const params = new URLSearchParams(window.location.search);\n if (params.has(\"anti_adblock_pass__already_donated\")) {\n $('.premium-success-details').hide();\n return;\n }\n const amount = params.get(\"from__amount\") || params.get(\"anti_adblock_pass__amount\") || $(\"button.option.selected\").attr(\"data-amount\");\n const prevSelectedCurrency = localStorage.getItem(\"selectedCurrency\");\n if (document.location.search.match(/thankyou/)) {\n if (prevSelectedCurrency && typeof prevSelectedCurrency === \"string\" && prevSelectedCurrency.length > 0) {\n selectedCurrency = prevSelectedCurrency;\n }\n localStorage.removeItem(\"selectedCurrency\");\n }\n const currencySymbol = _currency.getSymbol(selectedCurrency);\n const amountString = `${currencySymbol}${amount}`;\n const recurringFrequency = params.get(\"from__frequency\") || params.get(\"anti_adblock_pass__frequency\") || $(\"button.option.selected\").attr(\"data-recurring-frequency\");\n const recurringFrequencyWithoutLy = recurringFrequency.slice(0, -2); // slice off the \"ly\"\n const recurringFrequencyAbbreviation = { yearly: \"/yr\", monthly: \"/mo\" }[recurringFrequency];\n\n $(\"span.selected-plan-name\").each(function () {\n const recurringText = recurringFrequency[0].toUpperCase() + recurringFrequency.slice(1);\n $(this).text(`${recurringText} Plan`);\n });\n\n $(\"span.selected-plan-price\").each(function () {\n $(this).text(amountString);\n });\n\n // Update what gets displayed on payment success.\n $(\"span.amount-with-currency\").each(function () {\n $(this).text(amountString);\n });\n $(\"span.recurring-frequency\").each(function () {\n $(this).text(recurringFrequency);\n });\n $(\"span.recurring-frequency-no-ly\").each(function () {\n $(this).text(recurringFrequencyWithoutLy);\n });\n $(\"span.selected-plan-recurring-frequency-abbreviation\").each(function () {\n $(this).text(recurringFrequencyAbbreviation);\n });\n }", "updateItin() {\n const { id, editItinerary } = this.props;\n\n editItinerary(id);\n }", "async doSubmitRating() {\n let {\n rating,\n notes,\n selectedImprovementAreas,\n assignmentName,\n classID,\n studentID,\n assignmentLength,\n assignmentType,\n assignmentLocation,\n evaluationID,\n highlightedWords,\n highlightedAyahs\n } = this.state;\n\n notes = notes.trim();\n const submission = this.state.submission\n ? { submission: this.state.submission }\n : {};\n let evaluationDetails = {\n ID: evaluationID,\n name: assignmentName,\n assignmentLength,\n assignmentType: assignmentType,\n location: assignmentLocation,\n completionDate: new Date().toLocaleDateString(\"en-US\", {\n year: \"numeric\",\n month: \"2-digit\",\n day: \"2-digit\"\n }),\n evaluation: {\n rating,\n notes,\n highlightedWords,\n highlightedAyahs,\n improvementAreas: selectedImprovementAreas,\n },\n ...submission\n };\n try {\n await FirebaseFunctions.completeCurrentAssignment(\n classID,\n studentID,\n evaluationDetails\n );\n const currentClass = await FirebaseFunctions.getClassByID(\n this.state.classID\n );\n this.setState({\n currentPosition: \"0:00\",\n audioFile: -1\n });\n\n this.props.navigation.push(\"TeacherStudentProfile\", {\n studentID: this.state.studentID,\n currentClass,\n userID: this.props.navigation.state.params.userID,\n classID: this.state.classID\n });\n } catch (err) {\n Alert.alert(strings.SomethingWentWrong, strings.SomethingWentWrongDesc);\n }\n }", "function autorun(isPageLoad) {\r\n var rdf;\r\n var preferenceMap = RDFPreference.getMap();\r\n // TODO: deactivate all views for processing\r\n for (rdf in preferenceMap) {\r\n if (preferenceMap.hasOwnProperty(rdf)) {\r\n view.update(ISWASController, rdf);\r\n }\r\n }\r\n // update all resource descriptions found in the loaded map.\r\n for (rdf in preferenceMap) {\r\n if (preferenceMap.hasOwnProperty(rdf)) {\r\n runResourceDescription(rdf, RDFPreference.get(rdf).getAutorunPref(), isPageLoad);\r\n }\r\n }\r\n }", "toReviewed(peerId = this.props.reviewer.id, peer = this.props.reviewer) {\n const {\n currentSessionId,\n setReviewer,\n } = this.props;\n\n const url = `routes/reviewed/${currentSessionId}/${peerId}/`;\n $.ajax({\n url,\n success: reviewed => {\n setReviewer(peer, reviewed, READ_PEERS_REVIEWS_VIEW);\n },\n error: err => {\n console.error(err);\n },\n });\n }", "function initLearningStory() {\n if (props.learningStoryToEdit) {\n setTitle(props.learningStoryToEdit.title);\n setStoryContent(props.learningStoryToEdit.content);\n setSessionCount(props.learningStoryToEdit.sessionCount);\n setSubject(props.learningStoryToEdit.subject);\n setStartDate(\n DateTime.fromFormat(props.learningStoryToEdit.startDate, \"dd/MM/yyyy\")\n );\n setStartTime(props.learningStoryToEdit.startTime);\n setStoryStatus(props.learningStoryToEdit.status);\n setStoryNote(props.learningStoryToEdit.notes);\n setUrl(props.learningStoryToEdit.sessionLink);\n }\n }", "function updateInstructorInfo(nameMap, text, foundLocal) {\n\n\tvar tdIndexInstructor = nameMap.tdIndexInstructor;\n\tvar lname = nameMap.lname;\n\tvar name = nameMap.name;\n\n\tif(text.indexOf('No results were found') > -1) {\n\t\tfor(var tdIndex=0, tc = nameMap.td.length; tdIndex < tc; tdIndex++) {\n\t\t\tnameMap\n\t\t\t.td[tdIndex]\n\t\t\t.attr('title','No record found in the directory')\n\t\t}\n\t\tif(localStorage.getItem('sched.param(debug)') !== '0') {\n\t\t\tconsole.log('Employee directory has no record for \\'' + lname + '\\'');\n\t\t}\n\t}\n\telse {\n\t\tfor(var tdIndex=0, tc = nameMap.td.length; tdIndex < tc; tdIndex++) {\n\t\t\tnameMap\n\t\t\t.td[tdIndex]\n\t\t\t.addClass('td-tooltip')\n\t\t\t.empty();\n\t\t}\n\t\tvar tipContent =\n\t\t\t$('<div>')\n\t\t\t.addClass('name-tooltip')\n\t\t\t.append(text)\n\t\t\t.append(\n\t\t\t\t$('<span>')\n\t\t\t\t.html(\n\t\t\t\t\t'<br><br>See all employees having last name starting with \\'' +\n\t\t\t\t\t'<a href=\"https://gsw.edu/searchDirectory/employee/search.php?name=' + lname + '\" ' +\n\t\t\t\t\t'target=\"_blank\">' + lname + '</a>\\''\n\t\t\t\t)\n\t\t\t);\n\t\tvar a = $('<a>')\n\t\t\t.attr('href','')\n\t\t\t.click(function(){\n\t\t\t\t/*\n\t\t\t\tif($('#container').hasClass('blur')) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t\t*/\n\t\t\t\tvar clickElement = $(this);\n\t\t\t\t//-- Create tooltip container if does not exist\n\t\t\t\tif($('div.tooltip-container').length === 0) {\n\t\t\t\t\t$('#topOfThePage')\n\t\t\t\t\t.after(\n\t\t\t\t\t\t$('<div>')\n\t\t\t\t\t\t.addClass('tooltip-container')\n\t\t\t\t\t\t.addClass('no-print')\n\t\t\t\t\t\t.click(function(){\n\t\t\t\t\t\t\t$(this).remove();\n\t\t\t\t\t\t})\n\t\t\t\t\t)\n\t\t\t\t}\n\t\t\t\tvar toolTipContainer =\n\t\t\t\t\t$('div.tooltip-container')\n\t\t\t\t\t.html(tipContent)\n\t\t\t\t\t.css({\n\t\t\t\t\t\t'position' : 'absolute'\n\t\t\t\t\t})\n\t\t\t\tif(isMobile()) {\n\t\t\t\t\ttoolTipContainer\n\t\t\t\t\t.css({\n\t\t\t\t\t\t'left' : ($(window).width() - toolTipContainer.width())/2,\n\t\t\t\t\t\t'top' : ($(window).height() - toolTipContainer.height())/2 + $(window).scrollTop()\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\ttoolTipContainer\n\t\t\t\t\t.css({\n\t\t\t\t\t\t'top' : clickElement.offset().top - toolTipContainer.height(),\n\t\t\t\t\t\t'left' : clickElement.offset().left - toolTipContainer.width()\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\treturn false;\n\t\t\t})\n\t\t\t.text(name)\n\t\t\t.appendTo(nameMap.td);\n\t}\n}", "function updateCalories(){\n if(!update){\n $(\".footer .maintain\").append(maintainWeight(newUser.level,calcBMR(newUser.gender,newUser.feet,newUser.inches,newUser.weight,newUser.age,totalInches)));\n $(\".footer .lose\").append(maintainWeight(newUser.level,calcBMR(newUser.gender,newUser.feet,newUser.inches,newUser.weight,newUser.age,totalInches))-500);\n $(\".footer .gain\").append(maintainWeight(newUser.level,calcBMR(newUser.gender,newUser.feet,newUser.inches,newUser.weight,newUser.age,totalInches))+500);\n }\n update = true;\n }", "function setTutorName(tutorElement, tutorID) {\n var tutor;\n return getUser(tutorID).then(user => tutor = user).then(() => {\n // If the tutur is also a student get the information that relates to the tutor\n if (tutor.student != null) {\n tutor = tutor.tutor;\n }\n tutorElement.innerHTML = \"Tutoring Session with \" + tutor.name;\n });\n}", "function ShowEditResult(result, target) {\n target.id = result.id;\n target.title = result.title;\n target.location = result.location;\n target.description = result.description;\n target.path = result.path;\n target.userDate = {date:parseDateTime(result.userDate).date, time:parseDateTime(result.userDate).time};\n target.fileType = furtherSharing.fileType;\n target.furtherSharing = result.furtherSharing;\n target.dateUploaded = {date: parseDateTime(result.dateUploaded).date, time: parseDateTime(response.dateUploaded).time};\n target.embeddedVideoUrl = result.embeddedVideoUrl;\n target.videoThumbnail = service.videoThumbnail;\n target.videoFullSizeImg = service.videoFullSizeImg;\n target.videoHost = result.videoHost;\n target.expanded = result.expanded;\n target.notes = result.notes;\n target.mediaFileType = result.mediaFileType;\n target.viewingPermission = result.viewingPermission;\n target.keywords = result.keywords;\n }", "updateLinks(action, item) {\n let context = this;\n let username = context.get(\"session.data.authenticated.token_data.user_name\");\n let link = context.get(\"model.link\");\n let type = item.type.toLowerCase();\n let linkPrefixes = item.linkPrefixes;\n let prefixNum = item.prefixNum;\n let linkToSend;\n\n //Get link ready to send to API\n let prepareLink = function() {\n\n switch(type) {\n case \"facebook\":\n linkToSend = link.substring(25);\n break;\n case \"twitter\":\n linkToSend = link.substring(20);\n if(linkToSend.indexOf(\"?\") > 0){\n linkToSend = linkToSend.slice(0, linkToSend.indexOf(\"?\"));\n }\n break;\n case \"linkedin\":\n linkToSend = link.substring(28);\n if(linkToSend.slice(-1) === \"/\"){\n linkToSend = linkToSend.slice(0, -1);\n }\n break;\n case \"instagram\":\n linkToSend = link.substring(26);\n break;\n };\n\n linkToSend = encodeURIComponent(linkToSend);\n\n };\n\n // Send link to API\n let uploadLink = function(data) {\n let url = {\n [type]: data\n }\n return putAsync(\"/profiles/\" + type, url, context).catch((reason) => {\n showError(reason);\n });\n };\n\n // Make sure link passed starts with one of the specified link prefixes\n let errorChecks = function(){\n let passed = false;\n if(link.indexOf(linkPrefixes[prefixNum]) ===0 ){\n passed = true;\n }\n return passed;\n };\n\n // If error checks fail, display message to user to ask for another link\n let askAgain = function(){\n let reason = {\n responseText: \"Please use your \" + type + \" profile link\"\n }\n showError(reason);\n };\n\n // Display error to user\n let showError = function(result) {\n context.set(\"linksErrorMessage\", new Error(result.responseText));\n };\n\n // If link updates correctly show success message to user\n let showSuccess = function() {\n context.set(\"linksSuccessMessage\", \"You have \" + action + \" your \" + item.type + \" profile link!\");\n };\n\n // Change UI when link is changed\n let transition = function() {\n if(action ===\"updated\"){\n let linkToDisplay = decodeURIComponent(linkToSend);\n item.set(\"link\", linkToDisplay);\n }else {\n item.set(\"link\", null);\n }\n context.set(\"model.userInfo.\"+item.type, linkToSend);\n let form = context.get(\"lastForm\");\n if(form){\n form.addClass(\"hide\");\n }\n context.set(\"linksErrorMessage\", null);\n showSuccess();\n setTimeout(closeSuccessMessage, 10000);\n };\n\n let closeSuccessMessage = function() {\n context.set(\"phonePrivacySuccessMessage\", null);\n }\n\n // Run everything\n if(action === \"updated\"){\n if(errorChecks()){\n prepareLink();\n uploadLink(linkToSend)\n .then(transition);\n } else {\n askAgain();\n }\n } else {\n uploadLink(null)\n .then(transition);\n }\n }", "function editRemarks() {\n\tdocument.getElementById('canFinalize').value = 'NO';\n}", "updateUserDetails() {\n if (!activeUser()) return;\n $(conversations_area).find(`[data-user-id=\"${activeUser().id}\"] .sb-name,.sb-top > a`).html(activeUser().get('full_name'));\n $(conversations_area).find('.sb-user-details .sb-profile').setProfile();\n SBProfile.populate(activeUser(), $(conversations_area).find('.sb-profile-list'));\n }", "function updateStats(answer, isCorrect) {\n\t\tvar index = order[CURRENT_QNUM-1]-1;\n\t\tif (isCorrect) {\n\t\t\tvar reward = answer.reward * DIFFICULTY;\n\t\t\tif (index == 24) { // Pichu\n\t\t\t\treward += (34 * DIFFICULTY);\n\t\t\t}\n\t\t\tupdateQP(reward);\n\t\t\tNUM_CORRECT += 1;\n\t\t\treturn reward;\n\t\t} else {\n\t\t\t// Calculate damage\n\t\t\tvar damage = calcDamage(answer);\n\t\t\tif (index == 24) { // Pichu\n\t\t\t\tdamage += (-21 * DIFFICULTY);\n\t\t\t}\n\t\t\tupdateHP(damage);\n\t\t\treturn damage;\n\t\t}\n\t}", "function displayRecommendations(results) {\n\trecommendationsContainer.insertAdjacentHTML('beforeend', \"<h1> Recommendations </h1>\");\n\n\tvar green = results.green;\n\tvar yellow = results.yellow;\n\tvar red = results.red;\n\n\tvar result;\n\n\trecommendationsContainer.insertAdjacentHTML('beforeend', \"<p> RECOMMENDED: </p>\")\n\n\tfor (var i = 0; i < green.length; i ++) {\n\t\tresult = returnMethod(green[i].id);\n\t\tdisplayGreenResult(result);\n\t}\n\n\trecommendationsContainer.insertAdjacentHTML('beforeend', \"<p> OTHER POSSIBLE: </p>\")\n\n\n\tfor (i = 0; i < yellow.length; i ++) {\n\t\tresult = returnMethod(yellow[i].id);\n\t\tdisplayYellowResult(result);\n\t}\n\n\trecommendationsContainer.insertAdjacentHTML('beforeend', \"<p> NOT RECOMMENDED: </p>\")\n\n\tfor (i = 0; i < red.length; i ++) {\n\t\tresult = returnMethod(red[i].id);\n\t\tdisplayRedResult(result);\n\t}\n}", "function viewPostForUpdate(pst){\n\tvar singlePost = pst;\n\tvar main = $(\".note-container\");\n\tmain.html(\"\");\n\tvar userInformation = singlePost[0].user_info[0];\n\tvar postText = singlePost[0].post_text;\n\tvar postId = singlePost[0].post_id;\n\tvar postTitle = singlePost[0].post_title;\n\tvar postCategoryId = singlePost[0].category_id;\n\tvar firstName = userInformation.first_name;\n\tvar lastName = userInformation.last_name;\n\tvar imageId = userInformation.image;\n\tvar gender = userInformation.gender;\n\tvar userId = userInformation.user_id;\n\tvar postType = singlePost[0].post_type;\n\tvar imageLocation;\n\tvar likeClass = \"\";\n\tvar unlikeClass = \"\";\n\n\t$(\".user-name\").html(firstName+\" \"+lastName);\n\t$('[data-topicid~='+postCategoryId+']').addClass(\"selected\");\n\t$(\"#postTitle\").val(postTitle);\n\t$(\"#postId\").val(postId);\n\t$(\"#topicId\").val(postCategoryId);\n\t$(\"#userId\").val(userId);\n\t$(\".nicEdit-main\").html(postText);\n}", "function updateToy(event) {\n event.preventDefault();\n\n let toyID = event.target.parentElement.id;\n let toyLikes = parseInt(event.target.parentElement.querySelector('p').innerText.split(\" \")[0]) + 1;\n\n let toyFormData = {\n likes: toyLikes\n };\n\n let configObject = createFetchConfig(toyFormData, \"PATCH\");\n\n fetch(`${TOYSURL}` + `/${toyID}`, configObject)\n .then(response => response.json())\n\n event.target.parentElement.querySelector('p').innerText = `${toyLikes} likes`\n}", "function updateOverviewLinkWithResults(scanResult) {\r\n clearInterval(checkScanStatus);\r\n var linkEle = $(\".secretwarden-overview-link\");\r\n var labEle = $(\".secretwarden-overview-link .label\");\r\n\r\n linkEle.removeClass(\"incomplete\");\r\n\r\n var foundSecrets = scanResult[\"foundSecrets\"][\"foundSecrets\"];\r\n var prurl = navbuilder.currentPullRequest().addPathComponents('diff').build();\r\n prurl = prurl.substring(0, prurl.lastIndexOf(\"/\")); // Remove 'overview' from the URL\r\n\r\n var secretCount = foundSecrets.length;\r\n\r\n if (secretCount > 0) {\r\n linkEle.addClass(\"hassecrets\");\r\n labEle.text(secretCount + \" secrets found.\");\r\n setOnClickHandler(foundSecrets, prurl)\r\n\r\n } else if (secretCount === 0) {\r\n linkEle.addClass(\"nosecrets\");\r\n labEle.text(\"No secrets were found\");\r\n setOnClickHandler(foundSecrets, prurl)\r\n } else {\r\n updateOverviewLinkAsFailed();\r\n }\r\n }", "function viewRating(ratings, url) {\n changeState(\"search\");\n\n document.getElementById(\"professor\").value = ratings[\"name\"];\n\n var numberRatings = document.getElementById('numRatings');\n numberRatings.innerHTML = ratings[\"number-of-ratings\"];\n\n var overallRating = document.getElementById('overallRating');\n overallRating.innerHTML = ratings[\"overall-quality\"];\n\n var gradeRating = document.getElementById('gradeRating');\n gradeRating.innerHTML = ratings[\"average-grade\"];\n\n var helpRating = document.getElementById('helpRating');\n helpRating.innerHTML = ratings[\"helpfulness\"];\n\n var clarityRating = document.getElementById('clarityRating');\n clarityRating.innerHTML = ratings[\"clarity\"];\n\n var easyRating = document.getElementById('easyRating');\n easyRating.innerHTML = ratings[\"easiness\"];\n\n var commentsBox = document.getElementById('comments');\n commentsHTML = \"\";\n comments = ratings[\"comments\"];\n for(var i = 0; i < comments.length; i++) {\n commentsHTML += \"<div class=\\\"comment\\\"><div class=\\\"comment_rating\\\">\";\n commentsHTML += \"<span class=\\\"com_rating\\\">Date: \" + ratings[\"comments\"][i][\"date\"] + \"</span>\";\n commentsHTML += \"<span class=\\\"com_rating\\\">Class: \" + ratings[\"comments\"][i][\"class\"] + \"</span>\";\n commentsHTML += \"<span class=\\\"com_rating\\\">Helpfulness: \" + ratings[\"comments\"][i][\"helpfulness\"] + \"</span>\";\n commentsHTML += \"<span class=\\\"com_rating\\\">Easiness: \" + ratings[\"comments\"][i][\"easiness\"] + \"</span>\";\n commentsHTML += \"<span class=\\\"com_rating\\\">Clarity: \" + ratings[\"comments\"][i][\"clarity\"] + \"</span></div>\";\n commentsHTML += \"<div class=\\\"comment_text\\\">\" + ratings[\"comments\"][i][\"comment\"];\n commentsHTML += \"</div></div>\";\n }\n commentsBox.innerHTML = commentsHTML;\n\n var webLink = document.getElementById(\"webLink\");\n webLink.innerHTML = \"<a href=\" + url + \">View full review on RateMyProfessors.com</a>\";\n}", "function updateEditPage () {\n\n var nameMap = table.makePermissionMap(true);\n\n // todo: refactor these doubled 4 lines of code.\n // todo: refactor this doubled line of comments.\n var viewSummaryDiv = $(\"#permissions-view-summary\");\n var viewNames = [].concat(nameMap.group.view).concat(nameMap.user.view);\n if (viewNames.length) viewSummaryDiv.find(\".summary-content\").text(viewNames.join(\", \"));\n AJS.setVisible(viewSummaryDiv, viewNames.length);\n\n var editSummaryDiv = $(\"#permissions-edit-summary\");\n var editNames = [].concat(nameMap.group.edit).concat(nameMap.user.edit);\n if (editNames.length) editSummaryDiv.find(\".summary-content\").text(editNames.join(\", \"));\n AJS.setVisible(editSummaryDiv, editNames.length);\n\n /**\n * Updates the hidden fields that submit the edited permissions in the form. The fields are updated with the\n * data in the Permissions table.\n */\n permissionManager.permissionsEdited = false;\n var permissionStrs = permissionManager.makePermissionStrings();\n for (var key in permissionStrs) {\n var updatedPermStr = permissionStrs[key];\n $(\"#\" + key).val(updatedPermStr);\n\n if (permissionManager.originalPermissions[key] != updatedPermStr) {\n permissionManager.permissionsEdited = true;\n }\n }\n }", "function updateEditPage () {\n\n var nameMap = table.makePermissionMap(true);\n\n // todo: refactor these doubled 4 lines of code.\n // todo: refactor this doubled line of comments.\n var viewSummaryDiv = $(\"#permissions-view-summary\");\n var viewNames = [].concat(nameMap.group.view).concat(nameMap.user.view);\n if (viewNames.length) viewSummaryDiv.find(\".summary-content\").text(viewNames.join(\", \"));\n AJS.setVisible(viewSummaryDiv, viewNames.length);\n\n var editSummaryDiv = $(\"#permissions-edit-summary\");\n var editNames = [].concat(nameMap.group.edit).concat(nameMap.user.edit);\n if (editNames.length) editSummaryDiv.find(\".summary-content\").text(editNames.join(\", \"));\n AJS.setVisible(editSummaryDiv, editNames.length);\n\n /**\n * Updates the hidden fields that submit the edited permissions in the form. The fields are updated with the\n * data in the Permissions table.\n */\n permissionManager.permissionsEdited = false;\n var permissionStrs = permissionManager.makePermissionStrings();\n for (var key in permissionStrs) {\n var updatedPermStr = permissionStrs[key];\n $(\"#\" + key).val(updatedPermStr);\n\n if (permissionManager.originalPermissions[key] != updatedPermStr) {\n permissionManager.permissionsEdited = true;\n }\n }\n }", "markReviewHelpful(reviewId, index) {\n let prefix = 'review';\n\n // Check browser storage to see if this user has marked this\n // review as helpful before.\n let reviewsMarked = localStorage.getItem(prefix + reviewId);\n\n // If they have not previously marked this review\n if (!reviewsMarked) {\n\n this.apiMarkHelpful(reviewId)\n .then(()=>{\n // Update hepfulness number in local filtered review list\n let filteredReviews = this.state.filteredReviews.slice();\n let review = filteredReviews[index];\n review.helpfulness += 1;\n review = Object.assign({}, review); // Copy so React knows it changed\n filteredReviews[index] = review;\n\n localStorage.setItem(prefix + reviewId, true);\n this.setState({\n filteredReviews\n })\n })\n .catch((err) => {\n console.error(err);\n })\n }\n}", "function updateMostPopularAnimes(index, data) {\n console.log(index);\n\n //Get the information of the anime to display on the UI\n var title = data[\"title\"];\n var uid = data[\"uid\"];\n var syn = data[\"synopsis\"];\n var img = data[\"img_url\"];\n //Update the texual information\n var media_title = document.getElementById(\"title_popular_anime\" + \"_\" + index);\n media_title.innerHTML = title;\n media_title.href = \"./info.html\" + \"#\" + title;\n var media_syn = document.getElementById(\"syn_popular_anime\" + \"_\" + index);\n media_syn.innerHTML = syn;\n //Update the image\n var media_img = document.getElementById(\"img_popular_anime\" + \"_\" + index);\n media_img.src = img;\n media_img.href = \"./info.html\" + \"#\" + title;\n var media_img_url = document.getElementById(\"img_url_popular_anime\" + \"_\" + index);\n media_img_url.href = \"./info.html\" + \"#\" + title;;\n\n}", "scenarioThree() {\n const companyPreference = {\n c1: \"s1\",\n c2: \"s2\"\n };\n const studentPreference = {\n s1: \"c2\",\n s2: \"c1\"\n };\n InterviewScheduling.setInterview(companyPreference, studentPreference);\n }", "function updateResultsHdrs(dateInfo) {\n var userMsg;\n \n if (user === '') {\n userMsg = 'Timed results';\n } else {\n userMsg = 'Timed results for ' +user;\n }\n \n $(\"#scores_date\").text(dateInfo);\n $(\"#scores_numRange\").html('Number range: ' +\n 'Level ' + (model.diff + 1) + ', ' +\n model.nums[0] + ' through ' +\n model.nums[model.nums.length - 1]);\n\n if (typeof(user) !== 'undefined') {\n $('#test_user').empty().append(userMsg);\n $('#scores_user').text('Name: ' + user);\n }\n }", "update() {\n\t\t$('.js-login').prop('disabled', false);\n\t\tlet loggedIn = this.accessToken;\n\t\t$('.js-getMyself').prop('disabled', !loggedIn);\n\t\t$('.js-getRecents').prop('disabled', !loggedIn);\n\t}", "function RentProperty() {\n React.useEffect(() => {\n document.body.classList.add(\"index-page\");\n document.body.classList.add(\"sidebar-collapse\");\n document.documentElement.classList.remove(\"nav-open\");\n // window.scrollTo(0, 0);\n document.body.scrollTop = 0;\n return function cleanup() {\n document.body.classList.remove(\"index-page\");\n document.body.classList.remove(\"sidebar-collapse\");\n };\n });\n\n const [suggestiondata,setSuggestionData] = useState(undefined)\n const [data,setData] = useState(undefined)\n const {state,dispatch} = useContext(UserContext)\n useEffect(()=>{\n \n fetch(`/housesuggestions`,{\n headers:{\n \"Authorization\":\"Bearer \"+localStorage.getItem(\"jwt\")\n }\n })\n .then(res=>res.json())\n .then(result=>{\n console.log(result)\n let vals = []\n for(let i =0; i<6; i++){\n vals.push(result.posts[i])\n }\n setSuggestionData(vals)\n })\n \n fetch('/allpost',{\n headers:{\n \"Authorization\":\"Bearer \"+localStorage.getItem(\"jwt\")\n }\n }).then(res=>res.json())\n .then(result=>{\n console.log(result)\n setData(result.posts)\n })\n\n \n\n },[])\n\n const likePost1 = (id)=>{\n fetch('/like',{\n method:\"put\",\n headers:{\n \"Content-Type\":\"application/json\",\n \"Authorization\":\"Bearer \"+localStorage.getItem(\"jwt\")\n },\n body:JSON.stringify({\n postId:id\n })\n }).then(res=>res.json())\n .then(result=>{\n //console.log(result)\n const newData = suggestiondata.map(item=>{\n if(item._id==result._id)\n {\n return result\n }\n else{\n return item\n }\n })\n setSuggestionData(newData)\n }).catch(err=>{\n console.log(err)\n })\n }\n\n const unlikePost1 = (id)=>{\n fetch('/unlike',{\n method:\"put\",\n headers:{\n \"Content-Type\":\"application/json\",\n \"Authorization\":\"Bearer \"+localStorage.getItem(\"jwt\")\n },\n body:JSON.stringify({\n postId:id\n })\n }).then(res=>res.json())\n .then(result=>{\n //console.log(result)\n const newData = suggestiondata.map(item=>{\n if(item._id==result._id)\n {\n return result\n }\n else{\n return item\n }\n })\n setSuggestionData(newData)\n }).catch(err=>{\n console.log(err)\n })\n }\n\n const likePost = (id)=>{\n fetch('/like',{\n method:\"put\",\n headers:{\n \"Content-Type\":\"application/json\",\n \"Authorization\":\"Bearer \"+localStorage.getItem(\"jwt\")\n },\n body:JSON.stringify({\n postId:id\n })\n }).then(res=>res.json())\n .then(result=>{\n //console.log(result)\n const newData = data.map(item=>{\n if(item._id==result._id)\n {\n return result\n }\n else{\n return item\n }\n })\n setData(newData)\n }).catch(err=>{\n console.log(err)\n })\n }\n\n const unlikePost = (id)=>{\n fetch('/unlike',{\n method:\"put\",\n headers:{\n \"Content-Type\":\"application/json\",\n \"Authorization\":\"Bearer \"+localStorage.getItem(\"jwt\")\n },\n body:JSON.stringify({\n postId:id\n })\n }).then(res=>res.json())\n .then(result=>{\n //console.log(result)\n const newData = data.map(item=>{\n if(item._id==result._id)\n {\n return result\n }\n else{\n return item\n }\n })\n setData(newData)\n }).catch(err=>{\n console.log(err)\n })\n }\n\n const makeComment = (text,postId)=>{\n fetch('/comment',{\n method:\"put\",\n headers:{\n \"Content-Type\":\"application/json\",\n \"Authorization\":\"Bearer \"+localStorage.getItem(\"jwt\")\n },\n body:JSON.stringify({\n postId,\n text\n })\n }).then(res=>res.json())\n .then(result=>{\n console.log(result)\n const newData = data.map(item=>{\n if(item._id==result._id)\n {\n return result\n }\n else{\n return item\n }\n })\n setData(newData)\n }).catch(err=>{\n console.log(err)\n })\n }\n\n const deletePost = (postid)=>{\n fetch(`/deletepost/${postid}`,{\n method:\"delete\",\n headers:{\n Authorization:\"Bearer \"+localStorage.getItem(\"jwt\")\n }\n }).then(res=>res.json())\n .then(result=>{\n console.log(result)\n const newData = data.filter(item=>{\n return item._id !== result._id\n })\n setData(newData)\n })\n }\n \n return (\n <>\n <IndexNavbar />\n <div className=\"wrapper\">\n <PostPropertyHeader />\n <div className=\"main\">\n {data?\n <>\n\n <Container>\n\n <h1 style = {{ textAlign:\"center\", marginTop:\"200px\", marginBottom:\"60px\" }}>Rent Property</h1>\n\n\n <Row style = {{ marginTop: \"60px\", textAlign:\"center\" }}>\n \n <Col>\n <UncontrolledDropdown className=\"btn-group\">\n <DropdownToggle\n aria-expanded={false}\n aria-haspopup={true}\n caret\n color=\"info\"\n data-toggle=\"dropdown\"\n type=\"button\"\n >\n Distance\n </DropdownToggle>\n <DropdownMenu>\n <DropdownItem href=\"#pablo\" onClick={e => e.preventDefault()}>\n 5 - 15 kms\n </DropdownItem>\n <DropdownItem href=\"#pablo\" onClick={e => e.preventDefault()}>\n 15 - 60 kms\n </DropdownItem>\n <DropdownItem href=\"#pablo\" onClick={e => e.preventDefault()}>\n 60 - 120\n </DropdownItem>\n\n <DropdownItem href=\"#pablo\" onClick={e => e.preventDefault()}>\n 120 - 250\n </DropdownItem>\n </DropdownMenu>\n </UncontrolledDropdown>\n </Col>\n\n <Col>\n <UncontrolledDropdown className=\"btn-group\">\n <DropdownToggle\n aria-expanded={false}\n aria-haspopup={true}\n caret\n color=\"info\"\n data-toggle=\"dropdown\"\n type=\"button\"\n >\n Location\n </DropdownToggle>\n <DropdownMenu>\n <DropdownItem href=\"#pablo\" onClick={e => e.preventDefault()}>\n Pune\n </DropdownItem>\n <DropdownItem href=\"#pablo\" onClick={e => e.preventDefault()}>\n Mumbai\n </DropdownItem>\n <DropdownItem href=\"#pablo\" onClick={e => e.preventDefault()}>\n Bangalore\n </DropdownItem>\n \n <DropdownItem href=\"#pablo\" onClick={e => e.preventDefault()}>\n Hyderabad\n </DropdownItem>\n </DropdownMenu>\n </UncontrolledDropdown>\n </Col>\n\n <Col>\n <UncontrolledDropdown className=\"btn-group\">\n <DropdownToggle\n aria-expanded={false}\n aria-haspopup={true}\n caret\n color=\"info\"\n data-toggle=\"dropdown\"\n type=\"button\"\n >\n House Structure\n </DropdownToggle>\n <DropdownMenu>\n <DropdownItem href=\"#pablo\" onClick={e => e.preventDefault()}>\n Bungalow\n </DropdownItem>\n <DropdownItem href=\"#pablo\" onClick={e => e.preventDefault()}>\n Building\n </DropdownItem>\n <DropdownItem href=\"#pablo\" onClick={e => e.preventDefault()}>\n Row House\n </DropdownItem>\n <DropdownItem />\n </DropdownMenu>\n </UncontrolledDropdown>\n </Col>\n\n <Col>\n <UncontrolledDropdown className=\"btn-group\">\n <DropdownToggle\n aria-expanded={false}\n aria-haspopup={true}\n caret\n color=\"info\"\n data-toggle=\"dropdown\"\n type=\"button\"\n >\n House Type\n </DropdownToggle>\n <DropdownMenu>\n <DropdownItem href=\"#pablo\" onClick={e => e.preventDefault()}>\n Furnished\n </DropdownItem>\n <DropdownItem href=\"#pablo\" onClick={e => e.preventDefault()}>\n Unfurnished\n </DropdownItem>\n </DropdownMenu>\n </UncontrolledDropdown>\n </Col>\n </Row>\n \n <Row>\n\n <Col className=\"ml-auto mr-auto\" md=\"12\" style={{ textAlign:\"center\" }}>\n \n \n {\n suggestiondata.map(item=>{\n return(\n \n <Card style={{ width: \"20rem\", margin:\"20px 20px\" }}>\n <Link to={\"/property-detailed-page/\"+item._id }><CardImg alt=\"...\" src={item.pic1} top style={{ height:\"200px\", width:\"350px\" }}></CardImg></Link>\n <CardBody>\n\n {item.likes.includes(state._id)\n ? \n <i style={{ color:\"red\", padding:\"10px\", fontSize:\"20px\" }} className=\"now-ui-icons ui-2_favourite-28\" onClick={()=>{unlikePost1(item._id)}} >{item.likes.length}</i>\n :\n <i style={{ padding:\"10px\", fontSize:\"20px\" }} className=\"now-ui-icons ui-2_favourite-28\" onClick={()=>{likePost1(item._id)}}>{item.likes.length}</i>\n }\n\n {item.postedBy._id == state._id\n && \n <i style={{ padding:\"10px\", fontSize:\"20px\" }} className=\"now-ui-icons files_box\" onClick={()=>deletePost(item._id)}></i>\n }\n\n <CardTitle tag=\"h4\">{item.question6 + \" \" + item.question7}</CardTitle>\n {item.house_struct + \", \" + item.house_type}\n\n <Row style={{ marginTop:\"10px\", marginBottom:\"10px\" }}>\n <Col><i className=\"now-ui-icons health_ambulance\" style={{ fontSize:\"25px\" }}></i>{\" \"}5 km</Col>\n <Col><i className=\"now-ui-icons business_bank\" style={{ fontSize:\"20px\" }}></i>{\" \"}10 km</Col>\n </Row>\n\n <Row style={{ marginTop:\"10px\", marginBottom:\"10px\" }}>\n <Col><i className=\"now-ui-icons shopping_cart-simple\" style={{ fontSize:\"25px\" }}></i>{\" \"}15 km</Col>\n <Col><i className=\"now-ui-icons objects_spaceship\" style={{ fontSize:\"20px\" }}></i>{\" \"}12 km</Col>\n </Row>\n \n <CardText>\n {\"Rs \" + item.question3}\n <h6> - <Link to={item.postedBy._id !== state._id ? \"/profile/\"+item.postedBy._id :\"/profile/\"}>{item.postedBy.fullName}</Link></h6>\n </CardText>\n \n </CardBody>\n </Card>\n\n )\n })\n }\n\n {\n data.map(item=>{\n return(\n \n <Card style={{ width: \"20rem\", margin:\"20px 20px\" }}>\n <Link to={\"/property-detailed-page/\"+item._id }><CardImg alt=\"...\" src={item.pic1} top style={{ height:\"200px\", width:\"350px\" }}></CardImg></Link>\n <CardBody>\n\n {item.likes.includes(state._id)\n ? \n <i style={{ color:\"red\", padding:\"10px\", fontSize:\"20px\" }} className=\"now-ui-icons ui-2_favourite-28\" onClick={()=>{unlikePost(item._id)}} >{item.likes.length}</i>\n :\n <i style={{ padding:\"10px\", fontSize:\"20px\" }} className=\"now-ui-icons ui-2_favourite-28\" onClick={()=>{likePost(item._id)}}>{item.likes.length}</i>\n }\n\n {item.postedBy._id == state._id\n && \n <i style={{ padding:\"10px\", fontSize:\"20px\" }} className=\"now-ui-icons files_box\" onClick={()=>deletePost(item._id)}></i>\n }\n\n <CardTitle tag=\"h4\">{item.question6 + \" \" + item.question7}</CardTitle>\n {item.house_struct + \", \" + item.house_type}\n\n <Row style={{ marginTop:\"10px\", marginBottom:\"10px\" }}>\n <Col><i className=\"now-ui-icons health_ambulance\" style={{ fontSize:\"25px\" }}></i>{\" \"}5 km</Col>\n <Col><i className=\"now-ui-icons business_bank\" style={{ fontSize:\"20px\" }}></i>{\" \"}10 km</Col>\n </Row>\n\n <Row style={{ marginTop:\"10px\", marginBottom:\"10px\" }}>\n <Col><i className=\"now-ui-icons shopping_cart-simple\" style={{ fontSize:\"25px\" }}></i>{\" \"}15 km</Col>\n <Col><i className=\"now-ui-icons objects_spaceship\" style={{ fontSize:\"20px\" }}></i>{\" \"}12 km</Col>\n </Row>\n\n \n \n <CardText>\n {\"Rs \" + item.question3}\n <h6> - <Link to={item.postedBy._id !== state._id ? \"/profile/\"+item.postedBy._id :\"/profile/\"}>{item.postedBy.fullName}</Link></h6>\n </CardText>\n \n </CardBody>\n </Card>\n\n )\n })\n }\n\n \n </Col>\n </Row>\n \n </Container>\n </>\n\n : \n <Container>\n \n <Row>\n\n <Col className=\"ml-auto mr-auto\" md=\"12\" style={{ textAlign:\"center\" }}>\n <i style={{ marginLeft:\"auto\", marginRight:\"auto\", marginTop:\"200px\", fontSize:\"200px\" }} className=\"now-ui-icons loader_refresh\"></i>\n <h2 style={{ marginBottom:\"200px\" }}>Loading...</h2>\n </Col>\n </Row>\n </Container>\n }\n \n </div>\n <DarkFooter />\n </div>\n </>\n );\n}", "function updateUserEntry(rflEntries, username, results) {\n\tdocument.getElementById('username').innerText = username + '\\'s entry';\n\tdocument.getElementById('user-link').href = 'https://reddit.com' + rflEntries[username]['link'];\n\t// shorter comment link: https://www.reddit.com/comments/izsgs1/g6n6pkl/\n\n\t// Set rider names in user's entry on left\n\tconst riderCells = document.getElementsByClassName('user-rider');\n\tfor (let i = 0; i < riderCells.length; i++) {\n\t\triderCells[i].innerText = rflEntries[username]['entry'][i];\n\t}\n\t// Initialise race positions of user's riders on left\n\tconst positionCells = document.getElementsByClassName('user-position');\n\tfor (const cell of positionCells) {\n\t\tcell.innerText = '';\n\t}\n\n\t// Calculate score while setting multiplier and points per rider\n\tconst multiplierCells = document.getElementsByClassName('user-multiplier');\n\tconst userPointsCells = document.getElementsByClassName('user-points');\n\t// Some score calculation code repeated from calculateScores()\n\tlet score = 0;\n\tlet perfect = true;\n\tconst entry = simplifyEntry(rflEntries[username]['entry']);\n\tfor (let place = 0; place < results.length; place++) { // loop through positions in race result and check if each is in the entry\n\t\tconst multiplierElem = multiplierCells[place];\n\t\tconst userPointsElem = userPointsCells[place];\n\n\t\tmultiplierElem.classList.remove('incorrect');\n\t\tmultiplierElem.classList.remove('perfect-choice');\n\t\tmultiplierElem.classList.remove('correct');\n\t\tconst entryIndex = entry.indexOf(results[place]);\n\n\t\tif (entryIndex !== -1) {\n\t\t\tmultiplierElem.innerText = '(x' + multipliers[entryIndex].toFixed(1) + ')';\n\t\t\tmultiplierElem.classList.add('correct');\n\t\t\tif ((place === entryIndex || place > 4) && perfect === true) { // !! not quite right when you get down to the 1.0s. wait it is now?\n\t\t\t\tmultiplierElem.classList.add('perfect-choice');\n\t\t\t} else {\n\t\t\t\tperfect = false;\n\t\t\t}\n\t\t\tuserPointsElem.innerText = (points[place] * multipliers[entryIndex]).toFixed(1);\n\t\t\tpositionCells[entryIndex].innerText = place + 1;\n\t\t\tpositionCells[entryIndex].classList.add('correct');\n\t\t\tscore += points[place] * multipliers[entryIndex];\n\t\t} else {\n\t\t\tperfect = false;\n\t\t\tuserPointsElem.innerText = '';\n\t\t\tmultiplierElem.innerText = 'X';\n\t\t\tmultiplierElem.classList.add('incorrect');\n\t\t}\n\t}\n\tconsole.assert(score === rflEntries[username]['score'], 'updateUserEntry() score === rflEntries score');\n\tdocument.getElementById('user-score').innerText = score.toFixed(1);\n}", "markReviewHelpful(reviewId, index) {\n let prefix = 'review';\n\n // Check browser storage to see if this user has marked this\n // review as helpful before.\n let reviewsMarked = localStorage.getItem(prefix + reviewId);\n\n // If they have not previously marked this review\n if (!reviewsMarked) {\n api\n .reviewHelpful(reviewId)\n .then(() => {\n // Update hepfulness number in local filtered review list\n let filteredReviews = this.state.filteredReviews.slice();\n let review = filteredReviews[index];\n review.helpfulness += 1;\n review = Object.assign({}, review); // Copy so React knows it changed\n filteredReviews[index] = review;\n\n localStorage.setItem(prefix + reviewId, true);\n this.setState({\n filteredReviews,\n });\n })\n .catch((err) => {\n console.error(err);\n });\n }\n }", "function showPerson(){\n const item = reviews[currentItem]\n img.src = item.img\n author.textContent = item.name\n job.textContent = item.job\n info.textContent = item.text\n}", "async update(user, storyData) {\n const response = await axios({\n url: `${BASE_URL}/stories/${this.storyId}`,\n method: \"PATCH\",\n data: {\n token: user.loginToken,\n story: storyData\n }\n });\n\n const { author, title, url, updatedAt } = response.data.story;\n\n // these are the only fields that you can change with a PATCH update\n // so we don't need to worry about updating the others\n this.author = author;\n this.title = title;\n this.url = url;\n this.updatedAt = updatedAt;\n\n return this;\n }", "function updateUserPreferences(atts) {\n\t\t\tif (preferences.version == atts.version && preferences.language == atts.language && preferences.routingLanguage == atts.routingLanguage && preferences.distanceUnit == atts.distanceUnit) {\n\t\t\t\t//nothing changed...\n\t\t\t} else {\n\t\t\t\tupdateCookies(preferences.versionIdx, atts.version);\n\t\t\t\tupdateCookies(preferences.languageIdx, atts.language);\n\t\t\t\tupdateCookies(preferences.routingLanguageIdx, atts.routingLanguage);\n\t\t\t\tupdateCookies(preferences.distanceUnitIdx, atts.distanceUnit);\n\n\t\t\t\t//reload page to apply changed preferences (e.g. other site language)\n\t\t\t\tpreferences.reloadWithPerma();\n\t\t\t}\n\t\t}", "function updateRemark(data) {\n return $http.put(baseUrl + \"remark/\" + data.id, data,{headers:setHeaders()})\n }", "function EditTeam(props) {\n // //console.log(props)\n \n const[onviewc,setonviewc]=useState(true);\n const[onviewb,setonviewb]=useState(true);\n const[onviewp,setonviewp]=useState(true);\n const[onviewv,setonviewv]=useState(true);\n const [leads,setLeads]=useState({\"1\":false,\"2\":false,\"3\":false,\"4\":false});\n const [camp,setCamp]=useState({\"1\":false,\"2\":false,\"3\":false,\"4\":false});\n const [buy,setBuy]=useState({\"1\":false,\"2\":false,\"3\":false,\"4\":false});\n const [pub,setPub]=useState({\"1\":false,\"2\":false,\"3\":false,\"4\":false});\n const [vert,setVert]=useState({\"1\":false,\"2\":false,\"3\":false,\"4\":false});\n const [refresh,setRefresh]=useState({});\n useEffect(()=>{\n let user=(props.user);\n // //console.log(user,\"myuser*************************************************************************************\")\n setonviewb(true)\n setonviewc(true)\n setonviewp(true)\n setonviewv(true)\n\n let data=user.permission_ids;\n let leads3=leads\n let camp3=camp\n let buy3=buy\n let pub3=pub\n let vert3=vert\n // //console.log(data,\"data\")\n // //console.log(\"leads\",leads3)\n // //console.log(\"camp\",camp3)\n // //console.log(\"buy\",buy3)\n // //console.log(\"pub\",pub3)\n // //console.log(\"vert\",vert3)\n let leads1=Object.assign({},{\"1\":false,\"2\":false,\"3\":false,\"4\":false}) \n setLeads(leads1)\n let camp1=Object.assign({},{\"1\":false,\"2\":false,\"3\":false,\"4\":false})\n setCamp(camp1)\n let buy1=Object.assign({},{\"1\":false,\"2\":false,\"3\":false,\"4\":false})\n setBuy(buy1)\n let pub1=Object.assign({},{\"1\":false,\"2\":false,\"3\":false,\"4\":false})\n setPub(pub1)\n let vert1=Object.assign({},{\"1\":false,\"2\":false,\"3\":false,\"4\":false})\n setVert(vert1)\n // //console.log(data,\"data\")\n // //console.log(\"leads\",leads1)\n // //console.log(\"camp\",camp1)\n // //console.log(\"buy\",buy1)\n // //console.log(\"pub\",pub1)\n // //console.log(\"vert\",vert1)\n if(data){\n \n // //console.log(user,\"myuser####################################################################################*\")\n if(data.length>0 && user!={}){\n data=JSON.parse(data)\n // //console.log(data,\"data#####################################\")\n data.forEach(element => {\n // //console.log(element,\"ele\")\n if(element.module_id==2){\n // //console.log(element.module_id,\"element.module_id\")\n const canTick = (element) => element===1;\n if(element.actions.some(canTick)){\n \n element.actions.forEach(ele =>{\n \n \n // //console.log(ele,\" element.actions\")\n // leads1 = Object.assign({}, leads1, {\n // ele: true,\n // });\n leads1[ele]=true\n })\n }\n }\n if(element.module_id==3){\n const canTick = (element) => element===1;\n if(element.actions.some(canTick)){\n setonviewc(false)\n element.actions.forEach(ele =>{\n camp1[ele]=true\n // camp1 = Object.assign({}, camp1, {\n // ele: true,\n // });\n })\n }\n }\n if(element.module_id==4){\n const canTick = (element) => element===1;\n if(element.actions.some(canTick)){\n setonviewb(false)\n element.actions.forEach(ele =>{\n buy1[ele]=true\n // buy1 = Object.assign({}, buy1, {\n // ele: true,\n // });\n })\n }\n }\n if(element.module_id==5){\n const canTick = (element) => element===1;\n if(element.actions.some(canTick)){\n setonviewp(false)\n element.actions.forEach(ele =>{\n pub1[ele]=true\n // pub1 = Object.assign({}, pub1, {\n // ele: true,\n // });\n })\n }\n }\n if(element.module_id==6){\n const canTick = (element) => element===1;\n if(element.actions.some(canTick)){\n setonviewv(false)\n element.actions.forEach(ele =>{\n vert1[ele]=true\n // vert1 = Object.assign({}, vert1, {\n // ele: true,\n // });\n })\n }\n }\n \n });\n }}\n let leads2=Object.assign({},leads1)\n setLeads(leads2)\n let camp2=Object.assign({},camp1)\n setCamp(camp2)\n let buy2=Object.assign({},buy1)\n setBuy(buy2)\n let pub2=Object.assign({},pub1)\n setPub(pub2)\n let vert2=Object.assign({},vert1)\n setVert(vert2)\n // //console.log(\"AFTER C H A N G I N G\")\n // //console.log(\"leads\",leads1)\n // //console.log(\"camp\",camp1)\n // //console.log(\"buy\",buy1)\n // //console.log(\"pub\",pub1)\n // //console.log(\"vert\",vert1)\n \n },[props.user,props.id,props.show])\n \n return(\n <Modal\n id=\"main_modal\"\n {...props}\n size=\"md\"\n aria-labelledby=\"contained-modal-title-vcenter\"\n centered\n >\n <Modal.Header id=\"modal_head\">\n <div id=\"close_img2\" onClick={()=>{\n let leads2=Object.assign({},{})\n setLeads(leads2)\n let camp2=Object.assign({},{})\n setCamp(camp2)\n let buy2=Object.assign({},{})\n setBuy(buy2)\n let pub2=Object.assign({},{})\n setPub(pub2)\n let vert2=Object.assign({},{})\n setVert(vert2)\n \n let obj1=Object.assign({},{})\n setRefresh(obj1)\n setonviewb(true)\n setonviewc(true)\n setonviewp(true)\n setonviewv(true)\n props.onHide()\n }\n }>\n <IoIosClose />\n </div>\n </Modal.Header>\n <Modal.Body>\n {/* <p>{props.user.email}</p> */}\n <table\n id=\"dtBasicExample\"\n class=\"table table-striped table-sm\"\n cellspacing=\"0\"\n >\n <tr>\n {/* leads-2 \n camp-3\n buyers-4\n publishers-5\n verticals-6\n\n view-1\n create-2\n update-3\n delete-4\n \n */}\n <td></td>\n <th scope=\"col\">Lead</th>\n <th scope=\"col\">Campaign</th>\n \n <th scope=\"col\">Buyer</th>\n <th scope=\"col\">Publisher</th>\n <th scope=\"col\">Vertical</th>\n </tr>\n <tr>\n <th scope=\"row\">View</th>\n {/* 111111111 */}\n <td>\n {\" \"}\n {/* leads 222222 */}\n <input type=\"checkbox\" \n checked={leads[\"1\"]}\n onChange={(event) => {\n let temp=leads[\"1\"]\n let jk=Object.assign({},leads,{\"1\":!temp})\n setLeads(jk)\n }} />\n </td>\n <td>\n {\" \"}\n {/* Campaign 33333333 */}\n <input type=\"checkbox\" \n checked={camp[\"1\"]}\n onChange={() =>{\n let temp=camp[\"1\"]\n let jk=Object.assign({},camp,{\"1\":!temp})\n setCamp(jk)\n setonviewc(temp)\n } }/>\n </td>\n <td>\n {\" \"}\n {/* buyer 44444444*/}\n <input type=\"checkbox\" \n checked={buy[\"1\"]}\n onChange={() =>{\n let temp=buy[\"1\"]\n let jk=Object.assign({},buy,{\"1\":!temp})\n setBuy(jk)\n setonviewb(temp)\n } }/>\n </td>\n <td>\n {\" \"}\n {/* publisher 5555555 */}\n <input type=\"checkbox\" \n checked={pub[\"1\"]}\n onChange={() =>{\n let temp=pub[\"1\"]\n let jk=Object.assign({},pub,{\"1\":!temp})\n setPub(jk)\n setonviewp(temp)\n } }/>\n </td>\n <td>\n {\" \"}\n {/* vertical 6666666*/}\n <input type=\"checkbox\" \n checked={vert[\"1\"]}\n onChange={() =>{\n let temp=vert[\"1\"]\n let jk=Object.assign({},vert,{\"1\":!temp})\n setVert(jk)\n setonviewv(temp)\n } }/>\n </td>\n </tr>\n <tr>\n <th scope=\"row\">Create</th>\n {/* 222222222222 */}\n <td>\n {\" \"}\n {/* <input type=\"checkbox\" onChange={() => handlelead(2)} /> */}\n </td>\n <td>\n {\" \"}\n {/* campaigns 33333333333*/}\n <input type=\"checkbox\" \n checked={camp[\"2\"]}\n disabled={onviewc} \n onChange={() =>{\n let temp=camp[\"2\"]\n let jk=Object.assign({},camp,{\"2\":!temp})\n setCamp(jk)\n } }/>\n </td>\n <td>\n {\" \"}\n {/* buyers 4444444444444*/}\n <input type=\"checkbox\" \n checked={buy[\"2\"]}\n disabled={onviewb} \n onChange={() =>{\n let temp=buy[\"2\"]\n let jk=Object.assign({},buy,{\"2\":!temp})\n setBuy(jk)\n } }/>\n </td>\n <td>\n {\" \"}\n {/* publishers 5555555555*/}\n <input type=\"checkbox\" \n checked={pub[\"2\"]}\n disabled={onviewp} \n onChange={() =>{\n let temp=pub[\"2\"]\n let jk=Object.assign({},pub,{\"2\":!temp})\n setPub(jk)\n } }/>\n </td>\n <td>\n {\" \"}\n {/* verticals 666666666*/}\n <input type=\"checkbox\" \n checked={vert[\"2\"]}\n disabled={onviewv} \n onChange={() =>{\n let temp=vert[\"2\"]\n let jk=Object.assign({},vert,{\"2\":!temp})\n setVert(jk)\n } }/>\n </td>\n </tr>\n <tr>\n <th scope=\"row\">Update</th>\n {/* 3333333333333333 */}\n <td>\n {\" \"}\n {/* <input type=\"checkbox\" onChange={() => handlelead(3)} /> */}\n </td>\n <td>\n {\" \"}\n {/* campaigns 3333333 */}\n <input type=\"checkbox\" \n checked={camp[\"3\"]}\n disabled={onviewc} \n onChange={() =>{\n let temp=camp[\"3\"]\n let jk=Object.assign({},camp,{\"3\":!temp})\n setCamp(jk)\n } }/>\n </td>\n <td>\n {\" \"}\n {/* buyers 44444444 */}\n <input type=\"checkbox\" \n checked={buy[\"3\"]}\n disabled={onviewb} \n onChange={() =>{\n let temp=buy[\"3\"]\n let jk=Object.assign({},buy,{\"3\":!temp})\n setBuy(jk)\n } }/>\n </td>\n <td>\n {\" \"}\n {/* publishers 555555555*/}\n <input type=\"checkbox\" \n checked={pub[\"3\"]}\n disabled={onviewp} \n onChange={() =>{\n let temp=pub[\"3\"]\n let jk=Object.assign({},pub,{\"3\":!temp})\n setPub(jk)\n } }/>\n </td>\n <td>\n {\" \"}\n {/* verticals 6666666666 */}\n <input type=\"checkbox\" \n checked={vert[\"3\"]}\n disabled={onviewv} \n onChange={() =>{\n let temp=vert[\"3\"]\n let jk=Object.assign({},vert,{\"3\":!temp})\n setVert(jk)\n } }/>\n </td>\n </tr>\n <tr>\n <th scope=\"row\">Delete</th>\n {/* 44444444444444444 */}\n <td>\n {\" \"}\n {/* <input type=\"checkbox\" onChange={() => handlelead(4)} /> */}\n </td>\n <td>\n {\" \"}\n {/* campaigns 3333333333 */}\n <input type=\"checkbox\" \n checked={camp[\"4\"]}\n disabled={onviewc} \n onChange={() =>{\n let temp=camp[\"4\"]\n let jk=Object.assign({},camp,{\"4\":!temp})\n setCamp(jk)\n } }/>\n </td>\n <td>\n {\" \"}\n {/* buyers 44444444444 */}\n <input type=\"checkbox\" \n checked={buy[\"4\"]}\n disabled={onviewb} \n onChange={() =>{\n let temp=buy[\"4\"]\n let jk=Object.assign({},buy,{\"4\":!temp})\n setBuy(jk)\n } }/>\n </td>\n <td>\n {\" \"}\n {/* publishers 5555555555 */}\n <input type=\"checkbox\" \n checked={pub[\"4\"]}\n disabled={onviewp} \n onChange={() =>{\n let temp=pub[\"4\"]\n let jk=Object.assign({},pub,{\"4\":!temp})\n setPub(jk)\n } }/>\n </td>\n <td>\n {\" \"}\n {/* verticals 66666666 */}\n <input type=\"checkbox\" \n checked={vert[\"4\"]}\n disabled={onviewv} \n onChange={() =>{\n let temp=vert[\"4\"]\n let jk=Object.assign({},vert,{\"4\":!temp})\n setVert(jk)\n } }/>\n </td>\n </tr>\n </table>\n <Button onClick={()=>{\n //update roles for invited member\n let leadper=[]\n if(leads[\"1\"]==true)\n leadper.push(1)\n let campper=[]\n if(camp[\"1\"]==true){\n campper.push(1)\n if(camp[\"2\"]==true)\n campper.push(2)\n if(camp[\"3\"]==true)\n campper.push(3)\n if(camp[\"4\"]==true)\n campper.push(4)\n }\n let buyerper=[]\n if(buy[\"1\"]==true){\n buyerper.push(1)\n if(buy[\"2\"]==true)\n buyerper.push(2)\n if(buy[\"3\"]==true)\n buyerper.push(3)\n if(buy[\"4\"]==true)\n buyerper.push(4)\n }\n let pubper=[]\n if(pub[\"1\"]==true){\n pubper.push(1)\n if(pub[\"2\"]==true)\n pubper.push(2)\n if(pub[\"3\"]==true)\n pubper.push(3)\n if(pub[\"4\"]==true)\n pubper.push(4)\n }\n let vertiper=[]\n if(vert[\"1\"]==true){\n vertiper.push(1)\n if(vert[\"2\"]==true)\n vertiper.push(2)\n if(vert[\"3\"]==true)\n vertiper.push(3)\n if(vert[\"4\"]==true)\n vertiper.push(4)\n }\n const data = {\n usertype:1,\n user_id:props.user.id,\n permission_ids: [\n {\n module_id: 2,\n actions: leadper,\n },\n {\n module_id: 3,\n actions: campper,\n\n },\n {\n module_id: 4,\n actions: buyerper,\n\n },\n {\n module_id: 5,\n actions: pubper,\n\n },\n {\n module_id: 6,\n actions: vertiper,\n\n }\n \n ]\n };\n // //console.log(\"dataofinvite\",data)\n const updateinviteteammate = {\n url:\n API_URL+\"/user/save-permissions\",\n data: data,\n method: \"post\",\n headers: {\n \"Content-Type\": \"application/json\",\n Authorization: \"Bearer \" + localStorage.getItem(\"access_token\"),\n },\n };\n axios(updateinviteteammate)\n .then(response => {\n if (response.status == 200) {\n \n let leads2=Object.assign({},{})\n setLeads(leads2)\n let camp2=Object.assign({},{})\n setCamp(camp2)\n let buy2=Object.assign({},{})\n setBuy(buy2)\n let pub2=Object.assign({},{})\n setPub(pub2)\n let vert2=Object.assign({},{})\n setVert(vert2)\n \n let obj1=Object.assign({},{})\n setRefresh(obj1)\n setonviewb(true)\n setonviewc(true)\n setonviewp(true)\n setonviewv(true)\n props.getteamlistdata()\n props.onHide()\n ////console.log(response,\"success upadting roles of team member\")\n\n //props.onHide\n \n }\n\n })\n .catch(error => {\n \n if (error.response.status === 500) {\n // //console.log(\"error\",error)\n ////console.log(error.response,\"error upadting roles of team member\")\n alert(\"error\")\n //seterrormessage(\"Email Already exist\")\n } else {\n }\n });\n\n }}>UPDATE</Button>\n\n </Modal.Body>\n </Modal>\n );\n}", "function refreshResearchView() {\n const content = document.getElementById('researchConfigContent');\n if(research.hasResearch) {\n let liArcticles = ``;\n for (let a in research.arcticles) {\n liArcticles += `<li id=\"arcticle--${+a}\">${research.arcticles[a].title}</li> `\n }\n content.innerHTML =\n `\n <h1 class=\"session-title\">Research title</h1>\n <div id=\"researchViewTitle\">${research.title}</div>\n <h1 class=\"session-title\">Research author</h1>\n <div id=\"researchViewAuthor\">${research.author}</div>\n <h1 class=\"session-title\">Research Author's e-mail address</h1>\n <div id=\"researchViewAuthorEmail\">${research.authorEmail}</div>\n <h1 class=\"session-title\">Research Author's motivation</h1>\n <div id=\"researchViewAuthorMotivation\">${research.authorMotivation}</div>\n <h1 class=\"session-title\">Research Articles</h1>\n <div id=\"researchViewArcticles\"><ul>${liArcticles}</ul></div>\n `\n } else {\n content.innerText = \"There's no Research file yet.\"\n }\n}", "function show_male_stars() {\n\n // YOUR CODE GOES HERE\n let gender_list = stars_dataset[0];\n // console.log(gender_list);\n\n gender_list = Object.entries(gender_list);\n let count = 0;\n\n for(person of gender_list){\n console.log(person);\n let new_website_link = person[1][2];\n // console.log(website);\n count++;\n let name = person[0];\n \n let wiki_id = 'wiki' + count;\n // console.log(wiki_id);\n\n // New website link at navbar here\n let node = document.getElementById(wiki_id);\n node.innerText = name;\n // console.log(node.innerText);\n node.setAttribute('href',new_website_link);\n\n // Get image_id\n let image_id = 'image' + count;\n // console.log(person[1][0]);\n // New carousell items here.\n let new_image_link = \"images/\" + person[1][0]; \n document.getElementById(image_id).setAttribute(\"src\", new_image_link); \n\n let heading_id = \"slide_heading\"+count;\n document.getElementById(heading_id).innerText=name\n \n let quote = person[1][1];\n let slide_title = \"slide_title\"+count;\n document.getElementById(slide_title).innerText=quote\n }\n document.getElementById(\"male_button\").disabled = true;\n document.getElementById(\"female_button\").disabled = false;\n}", "update_annotation_mode() {\n jquery_default()(\"a.md-btn.sel\").attr(\"href\", \"#\");\n jquery_default()(\"a.md-btn.sel\").removeClass(\"sel\");\n jquery_default()(\"a#md-btn--\" + this.subtasks[this.state[\"current_subtask\"]][\"state\"][\"annotation_mode\"]).addClass(\"sel\");\n jquery_default()(\"a#md-btn--\" + this.subtasks[this.state[\"current_subtask\"]][\"state\"][\"annotation_mode\"]).removeAttr(\"href\");\n this.show_annotation_mode();\n }", "isReviewer() {\n return this.isLoggedIn() && this.user.settings.isReviewer\n }", "isReviewer() {\n return this.isLoggedIn() && this.user.settings.isReviewer\n }", "function renderProfile(person) {\n // 6. Ensure long profile shows details such as email, cell, and location/state\n let { picture, name, email, cell, location } = person;\n let { street, city, state, postcode, country } = location;\n main.innerHTML = \n `\n <article>\n <div class=\"tc\">\n <img src=\"${picture.large}\" class=\"br-100 h3 w3 dib\" title=\"\" />\n <h1 class=\"f4\">${name.first} ${name.last}</h1>\n <hr class=\"mw3 bb bw1 b--black-10\">\n </div>\n <div class=\"dtc v-mid pl3\">\n <p class=\"lh-copy measure center f6 black-70\">\n ${email}<br>\n ${cell}<br>\n ${street.number} ${street.name}, ${city}, ${state} ${postcode}, ${country}\n </p>\n </div>\n <div class=\"dtc v-mid pl6\">\n <form class=\"w-100 tr\">\n <button class=\"f6 grow no-underline br-pill ph3 pv2 mb2 dib white bg-dark-blue\" type=\"submit\">+ Follow</button>\n </form>\n </div>\n\n <form class=\"pa4 black-80\">\n <div>\n <textarea id=\"comment\" placeholder=\"What's happening?\" name=\"comment\" class=\"db border-box hover-black w-100 measure ba b--black-20 pa2 br2 mb2\" aria-describedby=\"comment-desc\"></textarea>\n <a id=\"tweet\" class=\"f6 link dim br1 ba bw2 ph3 pv2 mb2 dib dark-blue\" href=\"#0\">Tweet</a>\n </div>\n </form>\n </article>`;\n\n //Display the tweets if exists of current person\n if (person.tweets) {\n let tweetsHtml = person.tweets.map(tweet => {\n return `\n <div class=\"dt w-100 bb b--black-05 pb2 mt2\" href=\"#0\">\n <div class=\"dtc w2 w3-ns v-mid\">\n <img src=\"${person.picture.large}\" class=\"ba b--black-10 db br-100 w2 w3-ns h2 h3-ns\"/>\n </div>\n <div class=\"dtc v-mid pl3\">\n <p>${tweet}</p>\n </div>\n </div>\n `}).join('');\n main.innerHTML += tweetsHtml;\n }\n}", "function populateRate() {\n var postId = window.location.href.split('/')[window.location.href.split('/').length - 1].split('#')[0];\n var userRating = \"\";\n var postRating = \"\";\n var ratingContent = \"\";\n\n $.ajax({\n url: '/ratings/id/' + postId + '/' + readCookie('user'),\n dataType: 'json',\n async: false,\n success: function(dataUserRating) {\n if(dataUserRating != '' && dataUserRating != null) {\n userRating = dataUserRating.ratingPoint;\n }\n }\n });\n\n $.ajax({\n url: '/ratings/id/' + postId,\n dataType: 'json',\n async: false,\n success: function(dataRating) {\n postRating = dataRating;\n }\n });\n \n ratingContent = '<div class=\"row\" style=\"text-align:center;\">';\n if(userRating <= 0 && readCookie('user') != '')\n ratingContent += '<a data-toggle=\"tooltip\" title=\"Upvote\" class=\"linkupvotepost\" rel=\"' + postId + '\"><i class=\"glyphicon glyphicon-chevron-up\" style=\"font-size:15px;margin:10px;color:green\"></i></a>';\n ratingContent += '<br><span style=\"font-size: 25px\"><b>' + postRating + '</b></span><br>';\n if(userRating >= 0 && readCookie('user') != '')\n ratingContent += '<a data-toggle=\"tooltip\" data-placement=\"bottom\" title=\"Downvote\" class=\"linkdownvotepost\" rel=\"' + postId + '\"><i class=\"glyphicon glyphicon-chevron-down\" style=\"font-size:15px;margin:10px;color:red\"></i></a>';\n ratingContent += '</div>';\n\n $('#postRating').html(ratingContent);\n $('[data-toggle=\"tooltip\"]').tooltip(); \n}" ]
[ "0.56383204", "0.56011975", "0.5489353", "0.53817856", "0.51051044", "0.5086419", "0.50818425", "0.5067701", "0.5050999", "0.50234896", "0.501072", "0.49800426", "0.4972275", "0.4959148", "0.4954372", "0.4953436", "0.4937923", "0.4865306", "0.48645613", "0.48570627", "0.485453", "0.4851213", "0.48468882", "0.48458305", "0.48323268", "0.4831957", "0.4804063", "0.48032376", "0.48021033", "0.48009434", "0.47975954", "0.47914055", "0.47764498", "0.47688887", "0.4759865", "0.4753482", "0.47516447", "0.47496518", "0.47474307", "0.47466558", "0.47437966", "0.47326696", "0.47214216", "0.4713815", "0.47083995", "0.47025606", "0.4688159", "0.46766055", "0.4675856", "0.46741053", "0.46726647", "0.46670341", "0.46669075", "0.46623465", "0.4657676", "0.4655614", "0.46514598", "0.46500832", "0.4643348", "0.4642971", "0.46359357", "0.46321756", "0.46298727", "0.46247315", "0.4623072", "0.46228647", "0.46179956", "0.46139076", "0.4613111", "0.46105433", "0.46094233", "0.46082848", "0.46069947", "0.46036625", "0.4603644", "0.46007532", "0.45940617", "0.45921275", "0.45908877", "0.45908877", "0.4585208", "0.45802987", "0.45772526", "0.45695728", "0.45642373", "0.4563074", "0.45573837", "0.45571533", "0.45527673", "0.45468903", "0.45444056", "0.45423377", "0.45412806", "0.45398813", "0.45342276", "0.45222014", "0.45221302", "0.45221302", "0.45220476", "0.45219502" ]
0.53313476
4
Update the typing speed.
function updateSpeed() { // WPM and CPM does not need to be calculated on error if (my.current.state == my.STATE.ERROR) { return } var goodChars = my.current.correctInputLength // Determine the time elapsed since the user began typing var currentTime = new Date().getTime() var timeElapsed = currentTime - my.current.startTime my.current.timeElapsed = timeElapsed // Calculate WPM and CPM var wpm if (timeElapsed == 0) { wpm = goodChars == 0 ? 0 : '\u221e' } else { wpm = Math.round(60000 * goodChars / 5 / timeElapsed) my.current.wpm = wpm my.current.cpm = Math.round(60000 * goodChars / timeElapsed) } // Display WPM Util.setChildren(my.html.speed, wpm + ' wpm') }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function updateTyping () {\n if (connected) {\n if (!typing) {\n typing = true;\n socket.emit('typing', {\n target: target,\n });\n }\n lastTypingTime = (new Date()).getTime();\n\n setTimeout(function () {\n var typingTimer = (new Date()).getTime();\n var timeDiff = typingTimer - lastTypingTime;\n if (timeDiff >= TYPING_TIMER_LENGTH && typing) {\n socket.emit('stop typing', {\n target: target,\n });\n typing = false;\n }\n }, TYPING_TIMER_LENGTH);\n }\n }", "updateSpeed (speed) {\n this.speed = speed;\n }", "function updateSpeed() {\n\tif(!paused) {\n\t\tclearInterval(interval);\n\t\tinterval = setInterval(doTick, speed);\n\t}\n\t$('#speed-input').val(speed);\n\t$('#speed-text').html(speed);\n\n\tlet rotation = (speed / (MAX_SPEED - MIN_SPEED) ) * 180 - 90;\n\trotation *= -1;\n\t$('#speed-line').css('transform', 'rotate('+rotation+'deg)');\n}", "function updateTyping () {\n if (connected) {\n if (!typing) {\n typing = true;\n socket.emit('typing');\n }\n lastTypingTime = (new Date()).getTime();\n\n setTimeout(function () {\n var typingTimer = (new Date()).getTime();\n var timeDiff = typingTimer - lastTypingTime;\n if (timeDiff >= TYPING_TIMER_LENGTH && typing) {\n socket.emit('stop typing');\n typing = false;\n }\n }, TYPING_TIMER_LENGTH);\n }\n }", "function updateTyping () {\n if (connected) {\n if (!typing) {\n typing = true;\n socket.emit('typing');\n }\n lastTypingTime = (new Date()).getTime();\n\n setTimeout(function () {\n var typingTimer = (new Date()).getTime();\n var timeDiff = typingTimer - lastTypingTime;\n if (timeDiff >= TYPING_TIMER_LENGTH && typing) {\n socket.emit('stop typing');\n typing = false;\n }\n }, TYPING_TIMER_LENGTH);\n }\n }", "function updateTyping () {\n if (connected) {\n if (!typing) {\n typing = true;\n socket.emit('typing');\n }\n lastTypingTime = (new Date()).getTime();\n\n setTimeout(function () {\n var typingTimer = (new Date()).getTime();\n var timeDiff = typingTimer - lastTypingTime;\n if (timeDiff >= TYPING_TIMER_LENGTH && typing) {\n socket.emit('stop typing');\n typing = false;\n }\n }, TYPING_TIMER_LENGTH);\n }\n }", "function updateTyping () {\n if (connected) {\n if (!typing) {\n typing = true;\n socket.emit('typing');\n }\n lastTypingTime = (new Date()).getTime();\n\n setTimeout(function () {\n var typingTimer = (new Date()).getTime();\n var timeDiff = typingTimer - lastTypingTime;\n if (timeDiff >= TYPING_TIMER_LENGTH && typing) {\n socket.emit('stop typing');\n typing = false;\n }\n }, TYPING_TIMER_LENGTH);\n }\n }", "function updateTyping () {\n if (connected) {\n if (!typing) {\n typing = true;\n socket.emit('typing');\n }\n lastTypingTime = (new Date()).getTime();\n\n setTimeout(function () {\n var typingTimer = (new Date()).getTime();\n var timeDiff = typingTimer - lastTypingTime;\n if (timeDiff >= TYPING_TIMER_LENGTH && typing) {\n socket.emit('stop typing');\n typing = false;\n }\n }, TYPING_TIMER_LENGTH);\n }\n }", "function updateTyping () {\n \n if (!typing) {\n typing = true;\n socket.emit('typing', {name:username});\n }\n lastTypingTime = (new Date()).getTime();\n\n setTimeout(function () {\n var typingTimer = (new Date()).getTime();\n var timeDiff = typingTimer - lastTypingTime;\n if (timeDiff >= TYPING_TIMER_LENGTH && typing) {\n socket.emit('stop typing', {name:username});\n typing = false;\n }\n }, TYPING_TIMER_LENGTH);\n \n }", "_updateGenerationSpeed(speed) {\n this['generationSpeed'] = parseInt(speed, 10);\n this._layoutWords();\n }", "function sendUpdateTyping() {\n if (connected) {\n if (!typing) {\n typing = true;\n socket.emit('typing');\n }\n }\n lastTypingTime = (new Date()).getTime();\n $timeout(function () {\n var typingTimer = (new Date()).getTime();\n var timeDiff = typingTimer - lastTypingTime;\n if (timeDiff >= TYPING_TIMER_LENGTH && typing) {\n socket.emit('stop typing');\n typing = false;\n }\n }, TYPING_TIMER_LENGTH)\n }", "function changeSpeed() {\n if (id(\"start\").disabled) {\n clearInterval(timer);\n let speed = parseInt(id(\"speed\").value);\n timer = setInterval(handleText, speed);\n }\n }", "function setScrollingSpeed(value, type) {\n setVariableState('scrollingSpeed', value, type);\n }", "function setScrollingSpeed(value, type){\n setVariableState('scrollingSpeed', value, type);\n }", "function setScrollingSpeed(value, type){\n setVariableState('scrollingSpeed', value, type);\n }", "function setScrollingSpeed(value, type){\n setVariableState('scrollingSpeed', value, type);\n }", "function setScrollingSpeed(value, type){\n setVariableState('scrollingSpeed', value, type);\n }", "function setScrollingSpeed(value, type){\n setVariableState('scrollingSpeed', value, type);\n }", "function setScrollingSpeed(value, type){\r\n setVariableState('scrollingSpeed', value, type);\r\n }", "function setScrollingSpeed(value, type){\r\n setVariableState('scrollingSpeed', value, type);\r\n }", "function setScrollingSpeed(value, type){\r\n setVariableState('scrollingSpeed', value, type);\r\n }", "function setScrollingSpeed(value, type){\r\n setVariableState('scrollingSpeed', value, type);\r\n }", "function setScrollingSpeed(value, type){\r\n setVariableState('scrollingSpeed', value, type);\r\n }", "function update_speed() {\r\n\t\tvar new_speed = $(\"#speed_range\").val()\r\n\t\tif (new_speed != speed_input) {\r\n\t\t\tset_speed(new_speed)\r\n\t\t}\r\n\t}", "function setScrollingSpeed(value, type) {\n setVariableState('scrollingSpeed', value, type);\n }", "textBoxDidUpdate() {\n // user is typing because the value of the textbox just changed\n this.isTyping = true;\n this.lastTypingTime = (new Date()).getTime();\n // Create Timer event\n setTimeout(() => {this.checkTyping()}, this.typingTimeout);\n }", "typeAnimation(){\n\t\t//preserve a copy of all the text we're about to display incase we need to save\n\t\tthis.saveCopy();\n\t\t\n\t\tFileManager.writing = false; \n\t\t\n\t\t//figure out how fast we want to type the screen based on how much content needs typing \n\t\tvar letters = 0;\n\t\tfor (i=0; i< this.state.toShowText.length; i++){\t\t\t \n\t\t\tletters += this.state.toShowText[i].text.length;\n\t\t}\n\t\tvar scale = Math.floor(letters/20);\n\t\tif(scale < 1){\n\t\t\tscale = 1;\n\t\t}\n\t\t\n\t\t\n\t\t//do the actual typing\n\t\tthis.typeAnimationActual(scale);\n\t\t\n\t}", "increaseSpeed() {\n\n this.speed = Math.max(this.speed - Snake.SPEED_INCREMENT, Snake.MAX_SPEED);\n\n }", "function changeSpeed(s) {\n player.speed += s;\n}", "function SetSpeed(speed) {\n guiData.cursorSpeed = speed;\n}", "function ChangeTextSpeed(speed) {\n switch (speed) {\n case \"slow\":\n characterRevealDelay = 80;\n break;\n case \"fast\":\n characterRevealDelay = 20;\n break;\n // superfast is used by the skip button to make the text rapidly appear\n case \"superfast\":\n characterRevealDelay = 5;\n break; \n default:\n characterRevealDelay = 35;\n break;\n };\n}", "function updateSlow(distance){\n //calculate minutes and seconds from the milliseconds\n let seconds = Math.floor((distance % (1000 * 60)) / 1000);\n let minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));\n\n //edit label text\n slowLabel.text = `Slow: ${minutes}:${seconds}`;\n}", "function doSpeeding()\r\n{\r\n\tplaySound(\"speeding\");\r\n\tspeed += speedingIncrementSpeed;\r\n\tchangeInterval(speed);\r\n\taddMessage(\"Current Speed: \"+(speed), \"speed\");\r\n}", "function update() {\n // give browser time to add current letter\n setTimeout(function() {\n // prevent whitespace from being collapsed\n tag.html(element.val().replace(/ /g, '&nbsp'));\n // clamp length and prevent text from scrolling\n var size = Math.max(min, Math.min(max, tag.width() + offset));\n if (size < max)\n element.scrollLeft(0);\n // apply width to element\n element.width(size);\n settings_resize();\n }, 0);\n }", "function setSpeed() {\n if (isPause) {\n speedFactor = 0;\n return;\n }\n var val = inputSpeed.value;\n speedFactor = Math.pow(2, val);\n}", "Update() {\n this.txt.setText(Math.round((this.size/this.maxSize)*100)+'%');\n }", "function typing() {\n let options = {\n strings: [\"Hello, Adventurer... ^1000\", \"Shall we begin?\"],\n loop: false,\n smartBackspace: true,\n backSpeed: 50,\n typeSpeed: 100,\n showCursor: false\n }\n let typed = new Typed(\".type-intro\", options);\n \n setTimeout(function(){\n $(\".formy\").fadeIn(8000);\n }, 5000)\n}", "function updateSpeed() {\n let deltaX = (batX - lastX) * (batX - lastX);\n let deltaY = (batY - lastY) * (batY - lastY);\n let distance = Math.sqrt(deltaX + deltaY);\n if (currentFrame - lastFrame != 0) {\n speed = round(distance / (currentFrame - lastFrame));\n }\n if (lastX > batX) {\n velIsPos = false;\n } else {\n velIsPos = true;\n }\n //text(\"Speed: \" + speed, 20, 20);\n //text(\"MaxSpeed: \" + maxSpeed, 100, 20);\n //console.log(maxSpeed);\n}", "function autoType(elementClass, typingSpeed){\n var thhis = $(elementClass);\n thhis.css({\n \"position\": \"relative\",\n \"display\": \"inline-block\"\n });\n thhis.prepend('<div class=\"cursor\" style=\"right: initial; left:0;\"></div>');\n thhis = thhis.find(\".text-js\");\n var text = thhis.text().trim().split('');\n var amntOfChars = text.length;\n var newString = \"\";\n thhis.text(\"|\");\n setTimeout(function(){\n thhis.css(\"opacity\",1);\n thhis.prev().removeAttr(\"style\");\n thhis.text(\"\");\n for(var i = 0; i < amntOfChars; i++){\n (function(i,char){\n setTimeout(function() { \n newString += char;\n thhis.text(newString);\n },i*typingSpeed);\n })(i+1,text[i]);\n }\n },1500);\n}", "function changeSpeed() {\n\tif($video[0].playbackRate === 1) {\n\t\t$video[0].playbackRate = 2;\n\t\t$fastFwd.text(\"2x Speed\");\n\t} else if ($video[0].playbackRate === 2) {\n\t\t$video[0].playbackRate = 1;\n\t\t$fastFwd.text(\"1x Speed\");\t\t\t\t\n\t}\n}", "function updateTypingIndicator() {\n\t\t\t\tvar typingIndicationMessage='Typing: ';\n\t\t\t\t\n\t\t\t\tvar names = Array.from(typingMembers).slice(0,3);\n\t\t\t\t\n\t\t\t\tif (typingMembers.length) {\n\t\t\t\t\ttypingIndicationMessage += names.join(', ');\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (typingMembers.size > 3) {\n\t\t\t\t\ttypingIndicationMessage += ', and ' + (typingMembers.size-3) + 'more';\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (typingMembers.length) {\n\t\t\t\t\ttypingIndicationMessage += '...';\n\t\t\t\t} else {\n\t\t\t\t\ttypingIndicationMessage = '';\n\t\t\t\t}\n\t\t\t\t// console.log(this.typingIndicationMessage);\n\t\t\t\t$('#typing-indicator').text(typingIndicationMessage);\n\n}", "updateMe () {\n this.timeField.textContent = this.word + (++this.time) + this.seconds\n }", "update(){\n\t\tthis.position.add(this.velocity);\n\t\tthis.velocity.add(this.acceleration);\n\t\tthis.velocity.limit(this.maxSpeed);\n\t}", "type() {\n const current = this.wordIndex % this.words.length; // current Index of Word\n const fullTxt = this.words[current]; // get full text of current word\n\n // CHECK IF DELETING\n if (this.isDeleting) { \n this.txt = fullTxt.substring(0, this.txt.length - 1); // remove characters\n } else {\n this.txt = fullTxt.substring(0, this.txt.length + 1); // add characters\n }\n\n // INSERT TEXT INTO ELEMENT\n this.txtElement.html(`<span class=\"txt\">${this.txt}</span>`);\n let typeSpeed = \"255\"; // SET Typing Speed\n\n if (this.isDeleting) {\n typeSpeed = typeSpeed / 3; // SET Deleting Speed\n }\n\n // ON WORD COMPLETION\n if (!this.isDeleting && this.txt === fullTxt) {\n typeSpeed = this.wait; // makes pause at end\n this.isDeleting = true; // set delete to true\n } else if (this.isDeleting && this.txt === '') {\n this.isDeleting = false;\n // move to next word...\n this.wordIndex++;\n // Pause before restart typing \n typeSpeed = 500;\n }\n setTimeout(() => this.type(), typeSpeed);\n }", "update () {\n this.y += this.speed;\n }", "function changeSpeed() {\n\t\tcurrentSpeed = getSpeed();\n\t\tif (running) {\n\t\t\tclearInterval(currentInterval);\n\t\t\tcurrentInterval = setInterval(insertFrame, currentSpeed);\n\t\t}\n\t}", "function setSpeed(\r\n speed_)\r\n {\r\n speed = speed_;\r\n }", "setSpeed(speed) {\n this.speed = speed;\n }", "function set_speed(s) {\n\tspeed = s;\n}", "function increaseSpeed() {\n\tvideo.playbackRate *= 1.25;\n\tconsole.log(\"Speed is \"+ video.playbackRate);\n}", "function adjustSpeed(n) {\n\tsetSpeed(speed+n);\n}", "update () {\n\n this.prevTime = this.time;\n\n this.time = performance.now();\n\n this.elapsed = this.time - this.prevTime;\n\n }", "update() {\n // Update velocity\n this.velocity.add(this.acceleration);\n // Limit speed\n this.velocity.limit(this.maxspeed);\n this.position.add(this.velocity);\n // Reset acceleration to 0 each cycle\n this.acceleration.mult(1);\n }", "accelerate(){\n this.speed += 10;\n }", "function begin_typing() {\t\t\t\t\t\t/*FUNCTION CONTROLLING TYPEWRITING EFFECT ---- */\r\n\tif (i < txt[type_flag].length) {\r\n\t\tdocument.getElementById(\"my_info_p\").innerHTML += txt[type_flag].charAt(i);\r\n\t\ti++;\r\n\t\tsetTimeout(begin_typing, speed);\r\n\t}\r\n\tif (i == txt[type_flag].length) {\r\n\t\tdocument.getElementById(\"my_info_p\").innerHTML += '<br>';\r\n\t\ttype_flag++;\r\n\t\ti = 0;\r\n\t\tbegin_typing();\r\n\t}\r\n\r\n}", "update() {\r\n // Update velocity\r\n this.velocity.add(this.acceleration);\r\n // Limit speed\r\n this.velocity.limit(this.maxspeed);\r\n this.position.add(this.velocity);\r\n // Reset acceleration to 0 each cycle\r\n this.acceleration.mult(0);\r\n }", "function stopwatchUpdate() {\r\n rawTime += intervalRate;\r\n stopwatchTime.innerHTML = formatTime(rawTime);\r\n}", "updateGameSpeed() {\n const score = document.getElementById('score');\n const formattedScore = parseInt(score.innerHTML);\n if (formattedScore % 5 === 0 && this.speed > 100) {\n this.endGameTick();\n this.speed = this.speed - 100;\n this.startGameTick();\n }\n }", "function update() {\n me.stop(); // determine interval to refresh\n\n var scale = me.body.range.conversion(me.body.domProps.center.width).scale;\n var interval = 1 / scale / 10;\n if (interval < 30) interval = 30;\n if (interval > 1000) interval = 1000;\n me.redraw();\n me.body.emitter.emit('currentTimeTick'); // start a renderTimer to adjust for the new time\n\n me.currentTimeTimer = setTimeout$2(update, interval);\n }", "function updateTimeout() {\n\ttimeout /= 1.043;\n}", "function stopwatchUpdate(){\n rawTime += intervalRate\n stopwatchTime.innerHTML = formatTime(rawTime)\n}", "update() {\n this.deltaTime += deltaTime;\n }", "function frequencyTypeChanged() {\n if (this.value == 'ff') {\n all_data.forEach(function(character, i) {\n character.percentage = character.fanfiction_percentage;\n character.last_rank = i;\n });\n }\n else {\n all_data.forEach(function(character, i) {\n character.percentage = character.canon_percentage;\n character.last_rank = i;\n });\n }\n all_data.sort(function(a, b) {\n return b.percentage - a.percentage;\n });\n cur_display = all_data.slice(0,num_characters);\n\n update();\n }", "function incrementSpeed() {\n setInterval(function() {\n // This will work only when game is not paused or over.\n if (checkGamePause === false) {\n spikeSpeed = spikeSpeed + 0.05;\n otherCarsspeed = otherCarsspeed + 0.05;\n coinSpeed = coinSpeed + 0.05;\n // console.log(\"spike,car,coin: \"+spikeSpeed+\" \"+otherCarsspeed+\" \"+coinSpeed);\n }\n }, 4000);\n\n }", "function typeWriter() {\n if (i < txt.length) {\n document.getElementById(\"typing\").innerHTML += txt.charAt(i);\n i++;\n setTimeout(typeWriter, speed);\n }\n}", "update(dt) {\n this.x += this.speed*dt;\n }", "function speedUpdate() {\n\tvar r = this.rotation;\n\tif (r < 0) {\n\t\tspeed = 1+(r/150);\n\t} else {\n\t\tspeed = (r/25)+1;\n\t} \n\ttl.timeScale(speed.toFixed(2));\n}", "function type() {\n // Type as long as there are characters left in phrase\n if (char_index <= text[text_index].length) {\n if (!typing) set_typing(true);\n set_typed_text(text[text_index].substring(0, char_index++));\n setTimeout(type, type_delay);\n }\n // Call erase when finished\n else {\n set_typing(false);\n setTimeout(erase, new_delay);\n }\n }", "update() {\n this.time++;\n }", "function set_speed() {\r\n frameRate(speed_box.value * 1);\r\n}", "function update() {\n clock += change();\n render();\n }", "function typeWriter() {\n if (u < txt.length) {\n var x = document.getElementById(\"typed\").textContent += txt.charAt(u);\n u++;\n setTimeout(typeWriter, speed);\n console.log(x);\n }\n}", "function inc_speed()\n{\n if(speed == speed_normal)\n speed = speed_fast;\t\n}", "function timeupdate() {\n var lastBuffered = video.buffered.end(video.buffered.length-1);\n seekbar.min = video.startTime;\n seekbar.max = lastBuffered;\n seekbar.value = video.currentTime;\n $('#timer').html(formatTime(video.currentTime));\n if(review == true)\n {\n\t sk.min = video.startTime;\n\t sk.max = lastBuffered;\n\t sk.value = video.currentTime;\n\t reviewText();\n }\n}", "function update() {\n me.stop();\n\n // determine interval to refresh\n var scale = me.body.range.conversion(me.body.domProps.center.width).scale;\n var interval = 1 / scale / 10;\n if (interval < 30) interval = 30;\n if (interval > 1000) interval = 1000;\n\n me.redraw();\n me.body.emitter.emit('currentTimeTick');\n\n // start a renderTimer to adjust for the new time\n me.currentTimeTimer = setTimeout(update, interval);\n }", "function type()\n{\ndocument.getElementById('screen').innerHTML +=text.charAt(index);\nindex += 1;\nvar t = setTimeout('type()',100);\n// The time taken for each character here is 100ms. You can change it if you want.\n}", "function begin_typing_2() {\t\t\t\t\t\t/*FUNCTION CONTROLLING TYPEWRITING EFFECT ---- */\r\n\tif (i_2 < txt_2[type_flag_2].length) {\r\n\t\tdocument.getElementById(\"looking_for_info_p\").innerHTML += txt_2[type_flag_2].charAt(i_2);\r\n\t\ti_2++;\r\n\t\tsetTimeout(begin_typing_2, speed_2);\r\n\t}\r\n\tif (i_2 == txt_2[type_flag_2].length) {\r\n\t\tdocument.getElementById(\"looking_for_info_p\").innerHTML += '<br>';\r\n\t\ttype_flag_2++;\r\n\t\ti_2 = 0;\r\n\t\tbegin_typing_2();\r\n\t}\r\n\r\n}", "function update()\n\t\t{\n\t\t\tdocument.getElementById('songTime').innerHTML = millisToMins(player.currentTime);\n\t\t\tslider.value = player.currentTime;\n\t\t}", "function updateProgress(){\n $(\".line\").val( Player.audioObj.currentTime / Player.audioObj.duration );\n }", "function updateChar() {\n tweet1Count.textContent = tweet1.textLength;\n}", "function updateTimer() {\n\t\t\tvar timeString = formatTime(currentTime);\n\t\t\t$stopwatch.html(timeString);\n\t\t\tcurrentTime += incrementTime;\n\t\t}", "updateText(text) {\n this.setState({ text });\n\n if (text) {\n if (!this.isTyping) this.props.onStartTyping();\n this.isTyping = true;\n if (this.typingTimeout) clearTimeout(this.typingTimeout);\n\n this.typingTimeout = setTimeout(() => {\n this.isTyping = false;\n this.props.onEndTyping();\n }, 2000);\n } else {\n this.isTyping = false;\n clearTimeout(this.typingTimeout);\n this.props.onEndTyping();\n }\n }", "addSpeed(speedChange) {\n this.velocity.setMag(Math.max(0, this.velocity.mag() + speedChange));\n }", "update() {\n this.width = this.isSlide ? cnst.charSlideWidth : cnst.charWidth;\n this.height = this.isSlide ? cnst.charSlideHeight : cnst.charHeight;\n this.x = this.isSlide ? cnst.charSlideX : cnst.charX;\n this.y = this.isSlide ? cnst.charSlideY : cnst.charY;\n\n this.tickCount += 1;\n if (this.tickCount > this.ticksperFrame) {\n this.tickCount = 0;\n\n if (this.frameIndex < this.numberOfFrames - 1) {\n this.frameIndex +=1;\n } else {\n this.frameIndex = 0;\n }\n }\n }", "function changeSpeed(e) {\n const y = e.pageY - this.offsetTop;\n const percent = y / this.offsetHeight;\n const [max, min] = [4, 0.4];\n const playbackRate = (percent * (max - min) + min).toFixed(2);\n console.log(playbackRate);\n speedBar.style.height = `${Math.round(percent * 100)}%`;\n speedBar.textContent = `${playbackRate} ×`;\n video.playbackRate = playbackRate;\n}", "function typeWriter(txt, speed) {\n var text = arguments[0];\n var speed = arguments[1];\n var element = document.getElementById(\"paragraph-title\");\n console.log(speed);\n console.log(text);\n \n if (i < text.length) {\n element.innerHTML += text.charAt(i);\n i++;\n setTimeout(function () {\n typeWriter(text, speed);\n }, speed);\n \n \n }\n \n\n \n \n}", "function update() {\n if (get() - lastFPS > 1000) {\n this.fps = fpsCounter;\n fpsCounter = 0; // Reset the FPS counter\n lastFPS += 1000; // Add one second\n }\n fpsCounter++;\n\n let time = get();\n let deltaTime = (time - lastFrame);\n lastFrame = time;\n if (!(deltaTime >= time)) {\n this.delta = deltaTime;\n }\n }", "function updateSpeedOption() {\n var currText = 'Velocidad';\n var currValue = gameSpeed;\n $('#optSpeed').attr('value', currText + ' (' + currValue + ')');\n}", "function changeSpeed() {\n gameSpeed = (gameSpeed % 3) + 1;\n updateSpeedOption();\n}", "ChangeAlcaideSpeed(slow){\n this.alcaide.ChangeSpeed(slow);\n }", "function updateTime(distance){\n //calculate minutes and seconds from the milliseconds\n let seconds = Math.floor((distance % (1000 * 60)) / 1000);\n let minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));\n\n //edit label text\n timeLabel.text = `${minutes}:${seconds}`;\n}", "update() { \n this.text = this._parent.getRandomWord(); \n\n //csantos: randomize and update font size\n let scale = (window.innerWidth < 1280) ? window.innerWidth / 1280 : 1;\n this.style.fontSize = (16 + Math.random() * (50 - 16)) * scale; //min: 16, max: 50 \n }", "function speedUp() {\n\n\t\tif(this.sKey && this.baseSpeed) {\n\n\t\t\tthis.speedY*=10;\n\t\t\tthis.speedX*=10;\n\t\t\tthis.baseSpeed = false;\n\n\t\t} else if (!this.sKey && !this.baseSpeed) {\n\n\t\t\tthis.speedY = (this.speedY/10);\n\t\t\tthis.speedX = (this.speedX/10);\n\t\t\tthis.baseSpeed = true\n\n\t\t}\n\n\t}", "update() {\n // Update velocity\n this.velocity.add(this.acceleration);\n // Limit speed\n this.velocity.limit(this.maxspeed);\n this.position.add(this.velocity);\n // Reset accelerationelertion to 0 each cycle\n this.acceleration.mult(0);\n }", "function processInput(elapsedTime) {\r\n myKeyboard.update(elapsedTime);\r\n }", "update() {\n\t\t/* 50 second per frame */\n\t\tthis.worldTime = new Date(this.worldTime.getTime()+1000*this.speed);\n\t\tthis.domElement.textContent = this.HTML;\n\t}", "function displaySpeed(){\n $('#playSpeed').val(parseFloat(speed).toFixed(2));\n}", "update() {\n this.velocity.add(this.acceleration);\n this.velocity.limit(p.topspeed2);\n this.location.add(this.velocity);\n this.acceleration.mult(0);\n }", "function turboSpeed() {\r\n\t \tdelta = 500;\r\n\t}", "updateTime() {\n\t\tlet now = new Date().getTime();\n\t\tlet x = now - this.startTime;\n\t\tlet time = moment.duration(x);\n\t\tthis.elapsedTime = clc.xterm(242)(time.hours() + 'h ') + clc.xterm(242)(time.minutes() + 'm ') + clc.xterm(242)(time.seconds() + 's');\n\t}" ]
[ "0.7157912", "0.7022486", "0.7008835", "0.69932204", "0.69932204", "0.69932204", "0.69932204", "0.69932204", "0.6932238", "0.66575783", "0.6471192", "0.6457088", "0.6453484", "0.6439646", "0.6439646", "0.6439646", "0.6439646", "0.6439646", "0.6437958", "0.6437958", "0.6437958", "0.6437958", "0.6437958", "0.6429243", "0.6420516", "0.6411208", "0.63576484", "0.63570404", "0.6337781", "0.6288373", "0.6250012", "0.6226594", "0.61772126", "0.6165379", "0.615846", "0.6147969", "0.6146011", "0.61437184", "0.611935", "0.61155605", "0.61053145", "0.60846925", "0.606969", "0.6065563", "0.6063067", "0.60575086", "0.6022365", "0.6015815", "0.59934396", "0.5974014", "0.59466594", "0.5907301", "0.59033", "0.58984834", "0.589033", "0.5886321", "0.5881787", "0.5872997", "0.5870247", "0.58688325", "0.5868382", "0.5860014", "0.58498985", "0.58361834", "0.58310586", "0.58292586", "0.5826973", "0.58227724", "0.58154905", "0.5815238", "0.58042634", "0.5800733", "0.579971", "0.57993716", "0.579377", "0.5791808", "0.57907736", "0.5789476", "0.5789437", "0.57880044", "0.5779444", "0.5774921", "0.576066", "0.57545865", "0.57497543", "0.57468957", "0.57393557", "0.5729335", "0.5727469", "0.57252496", "0.5722986", "0.57152134", "0.5704226", "0.5699466", "0.56970435", "0.56964386", "0.5694283", "0.56942034", "0.5693436", "0.5693157" ]
0.7838378
0
Update the error rate.
function updateError() { var goodChars = my.current.correctInputLength var errorRate var errorRateTooltip var accuracyTooltip // Update error rate if (my.current.errorRate == Number.POSITIVE_INFINITY) { errorRate = '\u221e' } else { errorRate = Math.round(my.current.errorRate) } // Display error rate Util.setChildren(my.html.error, errorRate + '% error') }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "static set updateRate(value) {}", "updateLearningRate() {\n /* history must have more than 2 values */\n if (this.mseHistory.length < 2) {\n return;\n }\n /* MSE went up = bad update then devide by 2*/\n if (this.mseHistory[0] > this.mseHistory[1]) {\n this.options.learningRate /= 2;\n }\n /* MSE went down : it is right direction then multiply with 5% */\n else {\n this.options.learningRate *= 1.05\n }\n }", "function updateRate(deltaValue){\n if (Math.abs(deltaValue) > Math.abs(currentDelta)){\n // document.getElementById('rateOfChange').innerHTML=deltaValue;\n currentDelta = (delta) % deltaLimit;\n }\n }", "function updateTrendValue() {\n\t if (!$scope.trendMap) return;\n\t var av = $scope.aggregateValueAsXrp;\n\t for (var cur in $scope.trendMap) {if ($scope.trendMap.hasOwnProperty(cur)){\n\t var rate = ($scope.exchangeRates[cur] || 0);\n\t var sbAsXrp = $scope.trendMap[cur] * rate;\n\t av -= sbAsXrp;\n\t }}\n\t $scope.trendValueAsPercentage = ($scope.aggregateValueAsXrp - av) / av;\n\t }", "static get updateRate() {}", "function setError(reset) {\n\terror *= ramp;\n\tif (reset) error = 0.25;\n\tif (Math.random() < 0.5) error *= -1;\n}", "updateGrowthRate() {\n // TODO\n return 0;\n }", "function setReconnectionTimeIncreasingRate(value) {\n if (!Number.isFinite(value) || value <= 1) {\n throw new Error(`reconnection time's increasing rate must be greater than 1.0.`);\n }\n reconnectionTimeIncreasingRate = value;\n}", "function changeRate () {\n var usValue = allRates[currentBank][rateType];\n if (usValue == 0) usValue = 1;\n currentRate = mainCurrency == 'us' ? usValue: 1.0 / usValue;\n}", "function updatePrice(rate, quantity) {\n totalPrice += rate * quantity;\n console.log(totalPrice);\n updateDomPrice();\n }", "function updateSrcValue() {\n destAmount = document.getElementById('dest-amount').value\n srcAmount = destAmount * (1 / (expectedRate / (10 ** 18)));\n displaySrcAmount();\n}", "updateTotalScore() {\n this.score =\n this.calculatedRedScore +\n this.calculatedYellowScore +\n this.calculatedGreenScore +\n this.calculatedBlueScore -\n this.penaltyScore;\n this.displayCurrentScore();\n }", "function setError(err) {\n _error = err;\n component.forceUpdate();\n }", "UpdateMetrics() {\n }", "function setRate(tx){\n if (!tx.rate){\n // try to get rate from btcavg or from event as fallback\n try {\n tx['rate'] = btcavgLookup(tx.date);\n } catch(e) {\n throw Error('No rate given: '+JSON.stringify(tx));\n }\n }\n }", "function updateHitrate()\n{\n\tvar s1 = collect(makeProperJson(vdata[0]),['VBE'],undefined);\n\tvar tmp = [10, 100, 1000];\t\n\tfor (x in tmp ) {\n\t\ta = tmp[x];\n\t\tvar origa = a;\n\t\tif (vdatap.length-1 < a) {\n\t\t\ta = vdatap.length-1;\n\t\t}\n\t\tproper = makeProperJson(vdata[a]);\n\t\ts2 = collect(proper,['VBE'],undefined);\n\t\tstorage = collect(proper,['SMA','SMF'],'Transient');\n\t\thitrate[origa].d = a;\n\t\thitrate[origa].h = ((vdatap[0]['cache_hit'] - vdatap[a]['cache_hit']) / (vdatap[0]['client_req'] - vdatap[a]['client_req'])).toFixed(5);\n\t\thitrate[origa].b = (s1['beresp_hdrbytes'] + s1['beresp_bodybytes'] - \n\t\t\t\t s2['beresp_hdrbytes'] - s2['beresp_bodybytes']) / a;\n\t\thitrate[origa].f = (vdatap[0]['s_resp_hdrbytes'] + vdatap[0]['s_resp_bodybytes']\n\t\t\t\t- (vdatap[a]['s_resp_hdrbytes'] + vdatap[a]['s_resp_bodybytes']))/a;\n\t\tdocument.getElementById(\"hitrate\" + origa + \"d\").textContent = hitrate[origa].d;\n\t\tdocument.getElementById(\"hitrate\" + origa + \"v\").textContent = (hitrate[origa].h*100).toFixed(3) + \"%\";\n\t\tdocument.getElementById(\"bw\" + origa + \"v\").textContent = toHuman(hitrate[origa].b) + \"B/s\";\n\t\tdocument.getElementById(\"fbw\" + origa + \"v\").textContent = toHuman(hitrate[origa].f) + \"B/s\";\n\t\t\n\t\tdocument.getElementById(\"storage\" + origa + \"v\").textContent = toHuman(storage['g_bytes']);\n\n\t}\n\tdocument.getElementById(\"MAIN.uptime-1\").textContent = secToDiff(vdatap[0]['uptime']);\n\tdocument.getElementById(\"MGT.uptime-1\").textContent = secToDiff(vdatap[0]['MGT.uptime']);\n}", "function setError(error) {\n _error = \"(\" + _counter + \") \" + ioHelper.normalizeError(error);\n _counter++;\n _msg = \"\";\n component.forceUpdate();\n }", "function updateDifference() {\n // Adjust the base estimate vs adjusted estimate difference\n $scope.adjustedPercentage = (($scope.selectedEstimate - $scope.baseEstimate) / $scope.baseEstimate) * 100;\n }", "function setRate(\r\n rate_)\r\n {\r\n\t\tif(rate!=rate_){//允许任意设置\r\n\t\t\trate = rate_;\r\n\t\t\toldRatePosition = 0;\r\n\t\t\tnewRatePosition = 0;\r\n\t\t}\r\n }", "function updateElectricRate($scope,http,device,updateSurplus) {\n // Dates:\n var nowSeconds = Math.round(Date.now() / 1000);\n var minuteAgoSeconds = nowSeconds - 60;\n http.get(sodecUrl('events-in-range',\n [{p:'measurement',v:'electric_power'},\n {p:'device',v:device},\n {p:'start',v:minuteAgoSeconds},\n {p:'end',v:nowSeconds}]))\n .then(function(result){\n var events = result.data;\n if (events.length < 2){\n $scope.elec.rate[device] = false;\n } else {\n // in watt-seconds:\n var readingDiff = events[events.length - 1].r\n - events[events.length - 2].r;\n // in seconds:\n var timeDiff = (events[events.length -1].t\n - events[events.length - 2].t) / 1000;\n var watts = readingDiff / timeDiff;\n $scope.elec.rate[device] = {val:watts / 1000};\n if (updateSurplus){\n updateElectricSurplus($scope,'rate');\n }\n updateMissingPower($scope,'rate');\n }\n });\n }", "function changeRates() {\n for (const rate in rates) {\n min % 2 === 0 ? (rates[rate] -= 0.0001) : (rates[rate] += 0.0001);\n rates[rate] = parseFloat(rates[rate].toFixed(4));\n if (counter === 12) {\n min++;\n counter = 0;\n }\n }\n\n if (min === 5) {\n clearInterval(window.interval);\n }\n setState({ rates });\n changeBackground();\n }", "updateR() {\n if (this.lastRUpdate==0 || globalUpdateCount - this.lastRUpdate >= DAY_LENGTH) {\n let pts = this.fields.map(f => f.pts).reduce((acc, pts) => acc.concat(pts), [])\n pts.push(...this.sender.objs.map(o => o.point))\n \n let nInfectious = 0\n const val = pts\n .map(pt => {\n if (pt.isInfectious()) {\n nInfectious += 1\n const timeInfectious = globalUpdateCount - pt.lastStatusUpdate + (pt.status == Point.INFECTIOUS2) ? Point.infectious1Interval : 0\n if (timeInfectious>0) {\n const timeRemaining = Point.infectious2Interval + Point.infectious1Interval - timeInfectious\n return pt.nInfected/timeInfectious*timeRemaining // estimated infections over duration of illness\n } else return 0\n } else return 0\n })\n .reduce((sum, ei) => sum + ei)\n \n if (nInfectious>0) {\n this.rVal = val/nInfectious\n this.rMax = this.rMax < this.rVal ? this.rVal : this.rMax\n } else this.rVal = 0\n this.lastRUpdate = globalUpdateCount\n }\n }", "markGood() {\n this.usageCount += 1;\n\n if (this.errorScore > 0) {\n this.errorScore -= this.errorScoreDecrement;\n }\n }", "function updateTruckCost() {\n // Recalculate the truck cost estimate\n $scope.truckCost = $scope.baseEstimate * $scope.truckCostIncrements[$scope.truckCostIndex];\n }", "function updateExpPercentage(){\n let percentages = budget.getPercentages();\n ui.displayPercentage(percentages);\n }", "function handleRatingUpdate(event, currentRating, addedRating, totalRatings){\n event.preventDefault();\n var newTotalRatings = totalRatings + 1\n var updatedRating = (currentRating * totalRatings) / newTotalRatings;\n \n\n var updatedRatingInfo = {\n rating : updatedRating,\n totalRatings : newTotalRatings\n }\n \n updateRating(updatedRatingInfo);\n \n }", "function updateBandwidth() {\n let bandwidthCoeff = bandwidthCtl.getValue() >=1 ? bandwidthCtl.getValue()/10: 1;\n bandwidth[0].value = bandwidthCoeff * 0.5;\n bandwidth[1].value = bandwidthCoeff * 4;\n bandwidthLabel.setHTML(`bandwidth: ${bandwidthCoeff}px`);\n }", "function updateErrHandler(error, result) {\n\tif (error) {\n\t\tlog(\"cannot update data\")\n\t\tthrow error\n\t} else {\n\t\tlog(\"Update Success\") \n\t}\n}", "checkRateUpdate(){\n const dateUpdate = this.state.dateUpdate;\n \n if(typeof dateUpdate === \"number\"){\n const timeSinceLastUpdate = new Date() - dateUpdate;\n const timeMaxWithOutUpdate = 21600000 // 6h = 6 * 60 * 60 * 1000 = 21600000\n\n if (timeSinceLastUpdate > timeMaxWithOutUpdate)\n this.getTheRates();\n }\n }", "updateRadiusStep() {\n\n\t\tconst r = this.r / this.samples;\n\t\tthis.uniforms.get(\"radiusStep\").value.set(r, r).divide(this.resolution);\n\n\t}", "updateEtherPrice() {\n this.$store.dispatch('updateEtherPrice');\n axios.get(`${this.conversionURL}/?q=USD_PHP&compact=ultra&apiKey=${process.env.MIX_CURRENCY_CONVERSION_API}`)\n .then(res=> this.fee.php.rate = this.$store.state.prices.etherInUsd * res.data.USD_PHP);\n axios.get(`${this.conversionURL}/?q=USD_EUR&compact=ultra&apiKey=${process.env.MIX_CURRENCY_CONVERSION_API}`)\n .then(res=> this.fee.euro.rate = this.$store.state.prices.etherInUsd * res.data.USD_EUR);\n this.fee.usd.rate = this.$store.state.prices.etherInUsd;\n }", "set animationScaleError(value) {}", "function doUpdateRating() {\n var power = (oppRating - myRating)/400;\n var expectedScore = 1/(1 + Math.pow(10, power));\n var actualScore = 1; //win\n if (result === 'draw') actualScore = 0.5; //draw\n if (result === 'lose') actualScore = 0; //lose\n var k = 32; //k-factor\n\n var adjustedRating = myRating + k*(actualScore - expectedScore);\n console.log(\"oppRating:\", oppRating);\n console.log(\"myRating:\", myRating);\n console.log(\"my new rating:\", adjustedRating);\n console.log(\"net gain:\", adjustedRating - myRating);\n\n firebase.database().ref('leaderboard/'+gametype+'/'+userkey).update({ rating: adjustedRating});\n }", "function updateScore() {\n\t$(\".stars\").empty();\n\tconsole.log(\"error count: \" + errorCount);\n\tconsole.log((maxErrorCount - errorCount) / maxErrorCount);\n\tconsole.log((pairsCount - 1) / pairsCount);\n\tif (gameMode == 1) {\n\t\tif (remainTime / totalTime >= 0.6) {\n\t\t\t$(\".stars:last\").append(HTMLStar, HTMLStar, HTMLStar);\n\t\t} else if (remainTime / totalTime >= 0.5) {\n\t\t\t$(\".stars:last\").append(HTMLStar, HTMLStar, HTMLHalfStar);\n\t\t} else if (remainTime / totalTime >= 0.4) {\n\t\t\t$(\".stars:last\").append(HTMLStar, HTMLStar, HTMLEmptyStar);\n\t\t} else if (remainTime / totalTime >= 0.3) {\n\t\t\t$(\".stars:last\").append(HTMLStar, HTMLHalfStar, HTMLEmptyStar);\n\t\t} else if (remainTime / totalTime >= 0.2) {\n\t\t\t$(\".stars:last\").append(HTMLStar, HTMLEmptyStar, HTMLEmptyStar);\n\t\t} else if (remainTime / totalTime > 0) {\n\t\t\t$(\".stars:last\").append(HTMLHalfStar, HTMLEmptyStar, HTMLEmptyStar);\n\t\t} else {\n\t\t\t$(\".stars:last\").append(HTMLEmptyStar, HTMLEmptyStar, HTMLEmptyStar);\n\t\t}\t\n\t} else {\n\t\t// Normal mode or default rules\n\t\tif (errorCount / maxErrorCount >= (pairsCount - 1) / pairsCount) {\n\t\t\t$(\".stars:last\").append(HTMLStar, HTMLStar, HTMLStar);\n\t\t} else if (errorCount / maxErrorCount >= (pairsCount - 2) / pairsCount) {\n\t\t\t$(\".stars:last\").append(HTMLStar, HTMLStar, HTMLHalfStar);\n\t\t} else if (errorCount / maxErrorCount >= (pairsCount - 3) / pairsCount) {\n\t\t\t$(\".stars:last\").append(HTMLStar, HTMLStar, HTMLEmptyStar);\n\t\t} else if (errorCount / maxErrorCount >= (pairsCount - 4) / pairsCount) {\n\t\t\t$(\".stars:last\").append(HTMLStar, HTMLHalfStar, HTMLEmptyStar);\n\t\t} else if (errorCount / maxErrorCount >= (pairsCount - 5) / pairsCount) {\n\t\t\t$(\".stars:last\").append(HTMLStar, HTMLEmptyStar, HTMLEmptyStar);\n\t\t} else if (errorCount / maxErrorCount >= (pairsCount - 6) / pairsCount) {\n\t\t\t$(\".stars:last\").append(HTMLHalfStar, HTMLEmptyStar, HTMLEmptyStar);\n\t\t} else {\n\t\t\t$(\".stars:last\").append(HTMLEmptyStar, HTMLEmptyStar, HTMLEmptyStar);\n\t\t}\n\t}\n}", "update() {\n if (this.energy <= 0) {\n this.element.innerHTML = this.name + \" has run away because you don't know how to take care of anything.\";\n } else {\n this.energy--;\n this.report();\n this.element.innerHTML = this.name + \" has \" + this.energy + \" energy.\";\n }\n }", "baseRateUpdated(state, {rate}) {\n return {...state,\n baseExchangeRate: rate,\n };\n }", "recalculateValues() {\n this.remainingTime = this.startingTime;\n this.decreasePerInterval = this.startingProgressPercent / this.startingTime;\n }", "function updateScore() {\n totalScore = totalScore + 10; // add 10 points to the score\n $score.text(totalScore); // displays the new score on the screen\n console.log(totalScore); // logs the new score in the console\n }", "update() {\r\n let value =\r\n this.capacity * ((Math.random() - 0.5) * this.pctfree + this.pctfree);\r\n this.metric.labels(this.labels).set(value);\r\n }", "getMissRate() {\n return this.statistics.misses / this.statistics.total; \n }", "function changeDataRate(delta)\r\n{\t\r\n\ttimeWindow +=delta;\r\n\tif (timeWindow < 2000)\r\n\t{\r\n\t\ttimeWindow = 2000;\r\n\t}\r\n\t\r\n\tif (timeWindow > 10000)\r\n\t{\r\n\t\ttimeWindow = 10000;\r\n\t}\r\n\r\n\tif (sendingData)\r\n\t{\r\n\t\tvar rate = Math.floor(timeWindow / dataLength);\r\n\t\tdataSocket.send(\"rate:\" + rate);\r\n\t}\r\n\t\r\n\tformatWindowField();\r\n\tresizeGraphs();\r\n}", "function updatePrice() {\n var sum = 0;\n for(var i = 0; i < $scope.currentItems.length; i++) {\n sum += $scope.currentItems[i].price;\n }\n\n $scope.totalCost = sum + (sum * taxRate);\n $scope.totalCost = Math.floor($scope.totalCost);\n console.log($scope.totalCost);\n }", "function updatePerfChart() {\n if (isNaN(perf.avgPerf)) {\n //keep previous chart\n } else {\n //update chart\n let status;\n if (perf.avgPerf >= 60) {\n status = \"good\";\n } else if (perf.avgPerf <= 30) {\n status = \"bad\";\n } else if (perf.avgPerf > 30 && perf.avgPerf < 60) {\n status = \"okay\";\n }\n const color = {\n bad: \"#ED1C24\",\n okay: \"#F7931E\",\n good: \"#39B54A\"\n }[status];\n perfChart.data.datasets[0].data = [perf.avgPerf, 100 - perf.avgPerf];\n perfChart.data.datasets[0].backgroundColor = [color];\n perfChart.update();\n }\n}", "_updateValue(newValue) {\n this._numericProcessor.updateGaugeValue(newValue);\n }", "function increase() {\n setSeconds(seconds => seconds + 1)\n if (isSingle) setElixir(elixir => add_or_max(elixir, (1 / SINGLE_RATE), 10))\n else if (isDouble) setElixir(elixir => add_or_max(elixir, (1 / DOUBLE_RATE), 10))\n else if (isTriple) setElixir(elixir => add_or_max(elixir, (1 / TRIPLE_RATE), 10))\n }", "function updateExchangeRates() {\n\t var currencies = [];\n\t var hasNegative = false;\n\t for (var cur in $scope.balances) {if ($scope.balances.hasOwnProperty(cur)){\n\t var components = $scope.balances[cur].components;\n\t for (var issuer in components) {if (components.hasOwnProperty(issuer)){\n\t // While we're at it, check for negative balances:\n\t hasNegative || (hasNegative = components[issuer].is_negative());\n\t currencies.push({\n\t currency: cur,\n\t issuer: issuer\n\t });\n\t }}\n\t }}\n\t $scope.hasNegative = hasNegative;\n\t var pairs = currencies.map(function(c){\n\t return {\n\t base:c,\n\t counter:{currency:'XRP'}\n\t };\n\t });\n\t if (pairs.length) {\n\t $scope.exchangeRatesNonempty = false;\n\t $http.post('https://api.ripplecharts.com/api/exchangeRates', {pairs: pairs, last: true})\n\t .success(function(response){\n\t for (var i = 0; i < response.length; i++) {\n\t var pair = response[i];\n\t if (pair.last > 0) { // Disregard unmarketable assets\n\t $scope.exchangeRates[pair.base.currency + ':' + pair.base.issuer] = pair.last;\n\t }\n\t }\n\n\t $scope.exchangeRatesNonempty = true;\n\t console.log('Exchange Rates: ', $scope.exchangeRates);\n\t });\n\t } else {\n\t $scope.exchangeRatesNonempty = true;\n\t }\n\t }", "update(product_data) {\n this.rate = parseFloat(product_data.ask_price.toString())\n this.max_input = parseFloat(product_data.ask_size.toString())\n this.max_output = this.convert(this.max_input)\n this.listeners.forEach(listener => listener(this))\n }", "function updateSpeed()\n {\n // WPM and CPM does not need to be calculated on error\n if (my.current.state == my.STATE.ERROR) {\n return\n }\n\n var goodChars = my.current.correctInputLength\n\n // Determine the time elapsed since the user began typing\n var currentTime = new Date().getTime()\n var timeElapsed = currentTime - my.current.startTime\n my.current.timeElapsed = timeElapsed\n\n // Calculate WPM and CPM\n var wpm\n if (timeElapsed == 0) {\n wpm = goodChars == 0 ? 0 : '\\u221e'\n } else {\n wpm = Math.round(60000 * goodChars / 5 / timeElapsed)\n my.current.wpm = wpm\n my.current.cpm = Math.round(60000 * goodChars / timeElapsed)\n }\n\n // Display WPM\n Util.setChildren(my.html.speed, wpm + ' wpm')\n }", "function updateDestValue() {\n srcAmount = document.getElementById('src-amount').value\n destAmount = (srcAmount * (expectedRate / 10 ** 18));\n displayDestAmount();\n}", "UpdateScore(newScore){\n this.currentScore += newScore;\n }", "function update() {\n\t$fraction.text(iQ + '/10');\n\t$percent.text(percentCorrect + '%');\n\n}", "function getRate()\r\n {\r\n return rate;\r\n }", "function updateCostAndPrice() {\n $(\"#totalCostCalculated\").text(Math.round(totalCostCalculated * Math.pow(10, 2)) / Math.pow(10, 2));\n $(\"#sellingPriceAtSpan\").text($(\"#profitMarginInput\").val());\n $(\"#sellingPrice\").text((Math.round(sellingPrice * Math.pow(10, 2)) / Math.pow(10, 2)));\n alert('recalculated via updateCostAndPrice method');\n }", "function calculate() {\n var entry = Number(inputEntry.value);\n var result = entry * currentRate;\n displayResult.value = result.toFixed(2);\n}", "newRate(e){ \n let index = this.newProds.findIndex(prod => prod.Product__c === e.target.name)\n //this.newProds[index].Units_Required__c = this.dryUnits(this.newProds[index].Rate2__c, this.areaSize, this.newProds[index].Product_Size__c )\n window.clearTimeout(this.delay);\n // eslint-disable-next-line @lwc/lwc/no-async-operation\n this.delay = setTimeout(()=>{\n this.newProds[index].Rate2__c = e.detail.value;\n if(this.newProds[index].Unit_Area__c !== '' && this.newProds[index].Unit_Area__c !== null ){\n //console.log(this.newProds[index].OZ_M__c, this.areaSize ,this.Product_size__c);\n this.newProds[index].Units_Required__c = this.unitsRequired(this.newProds[index].Unit_Area__c, this.newProds[index].Rate2__c, this.areaSize, this.newProds[index].Product_Size__c ) \n this.newProds[index].Total_Price__c = Number(this.newProds[index].Units_Required__c * this.newProds[index].Unit_Price__c).toFixed(2)\n } \n },500 ) \n \n }", "async updateRate() {\n let avgPriceSrv = await this.client.avgPrice({symbol: this.pair});\n avgPriceSrv = Number(avgPriceSrv.price);\n let res = await this.client.trades({symbol: this.pair});\n let totalPrice = 0;\n res.forEach(el => totalPrice += Number(el.price));\n\n let totalPriceForWeight = 0;\n let totalDividerForWeight = 0;\n let weightBase = Number(res[0].qty); \n//{\"id\":268893991,\"price\":\"4523.21000000\",\"qty\":\"0.01888200\",\"quoteQty\":\"85.40725122\",\"time\":1584356745682,\"isBuyerMaker\":true,\"isBestMatch\":true}\n res.forEach(el => {\n let k = Number(el.qty) / weightBase;\n totalPriceForWeight += Number(el.price) * k; \n totalDividerForWeight += k;\n });\n\n let avgPriceWeighted = (totalPriceForWeight / totalDividerForWeight);\n\n/*\n openTime: 1508328900000,\n open: '0.05655000',\n high: '0.05656500',\n low: '0.05613200',\n close: '0.05632400',\n volume: '68.88800000',\n closeTime: 1508329199999,\n quoteAssetVolume: '2.29500857',\n trades: 85,\n baseAssetVolume: '40.61900000',\n*/\n let candles = await this.client.candles({symbol: this.pair, interval: '1m', limit: 1});\n let sum = 0;\n let sum1 = 0;\n let lastPrice = 0;\n /*candles.forEach(el => {\n let delta = Number(el.close) - Number(el.open);\n sum += delta * Number(el.volume);\n \n sum1 = delta * Number(el.volume);\n\n // let deltaEx = Number(el.close) - Number(el.open);\n lastPrice = el.close;\n });*/\n\n let el = candles[0];\n\n let fut = await this.futuresCalc(avgPriceWeighted);\n // let fut = await this.futuresCalc(el.close);\n\n console.log('delta [' + (Number(el.close) - Number(el.open)) + '] deltaMax [' + (Number(el.high) - Number(el.low)) + '] volume [' + el.quoteAssetVolume + ', ' + el.baseAssetVolume + '] : price ' + el.close, \n '[ fut+', fut.sellMass + '/' + fut.sellMass2 + ']', '[ fut-', fut.buyMass + '/' + fut.buyMass2 + ']', ' | avg', avgPriceWeighted);\n // console.log('trend 3 [' + sum + '] trend 1 [' + sum1 + '] : price ' + lastPrice, ' | avg', avgPriceWeighted);\n\n // this.data.arr.push({time: Date.now(), avg: avgPriceSrv, price: avgPriceWeighted});\n\n // this.saveFile(this.data);\n }", "function updateRate() \n{\n var rateval = document.getElementById(\"rate\").value;\n document.getElementById(\"rate_val\").innerText= rateval+\"%\";\n}", "function HandleAdminRate( request, response, instanceHash ) {\n if ( instanceHash ) {\n if ( request.method == 'POST' ) {\n var rateData = \"\";\n request.on( 'data', function ( data ) {\n rateData += data;\n if ( rateData.length > 1000 ) {\n rateData = \"\";\n response.writeHead( 413, { 'Content-Type': 'text/plain' } ).end( );\n request.connection.destroy();\n }\n } );\n request.on( 'end', function( ) {\n var parsedRate;\n parsedRate = parseFloat( rateData );\n if ( ( parsedRate ) && ( parsedRate > 0 ) ) {\n global.instances[ instanceHash ].rate = parsedRate;\n global.instances[ instanceHash ].play( );\n ServeTimeStateJSON( request, response, instanceHash );\n }\n } );\n return true;\n }\n }\n return false;\n}", "function setApiError() {\n apiError(true);\n}", "async updateParentCodeError () {\n\t\tif (!this.codeError) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst now = Date.now();\n\t\tconst op = { \n\t\t\t$set: {\n\t\t\t\tnumReplies: (this.codeError.get('numReplies') || 0) + 1,\n\t\t\t\tlastReplyAt: now,\n\t\t\t\tlastActivityAt: now,\n\t\t\t\tmodifiedAt: now\n\t\t\t}\n\t\t};\n\n\t\t// handle any followers that need to be added to the code error, as needed\n\t\tawait this.handleFollowers(this.codeError, op, { ignorePreferences: true });\n\n\t\tthis.transforms.updatedCodeErrors = this.transforms.updatedCodeErrors || [];\n\t\tconst codeErrorUpdate = await new ModelSaver({\n\t\t\trequest: this.request,\n\t\t\tcollection: this.data.codeErrors,\n\t\t\tid: this.codeError.id\n\t\t}).save(op);\n\t\tthis.transforms.updatedCodeErrors.push(codeErrorUpdate);\n\t}", "async applyRateControl() {\n await this.recordedRateController.applyRateControl();\n this.records[this.stats.getTotalSubmittedTx()] = Date.now() - this.stats.getRoundStartTime();\n }", "function updateTokenValue() {\n let tokenValue = currentAum / numTokens;\n document.getElementById('token-value').innerHTML = `$${tokenValue.toFixed(2)} USD`;\n}", "setError(state, newError) {\n state.error = newError;\n }", "function realtimeValidation() {\n if (lastChanged) {\n /* Get current error(s) for the currently edited field */\n const newError = checkFormValidity()[lastChanged];\n updateErrors(errors, lastChanged, newError);\n }\n }", "function update(){\r\n\"use strict\";\r\ntotalCoins.textContent=\"Total Coins: \" + numTotalCoins;\r\ntotalPSB.textContent=\"Total PSB: \" + numTotalPSB;\r\ntotalRML.textContent=\"Total RML: \" + numTotalRML;\r\nratePSB.textContent=\"PSB per Run: \" + numRatePSB.toFixed(2);\r\nrateRML.textContent=\"RML per Run: \" + numRateRML.toFixed(2);\r\ntotalRuns.textContent=\"Total Runs: \" + numTotalRuns;\r\npFail.textContent= numPFail.toFixed(2)+\"%\";\r\np0.textContent= numP0.toFixed(2)+\"%\";\r\np1.textContent= numP1.toFixed(2)+\"%\";\r\np2.textContent= numP2.toFixed(2)+\"%\";\r\np3.textContent= numP3.toFixed(2)+\"%\";\r\np4.textContent= numP4.toFixed(2)+\"%\";\r\np5.textContent= numP5.toFixed(2)+\"%\";\r\neleNumFail.textContent=numFail;\r\neleNum0.textContent=num0;\r\neleNum1.textContent=num1;\r\neleNum2.textContent=num2;\r\neleNum3.textContent=num3;\r\neleNum4.textContent=num4;\r\neleNum5.textContent=num5;\r\n}", "update() {\r\n const max = 0.0001;\r\n const min = 0.00001;\r\n let increment = Math.random() * (max - min) + min;\r\n this.metric.labels(this.labels).inc(increment);\r\n }", "setTargetRate() {\n\t\t// Do nothing.\n\t}", "markBad() {\n this.errorScore += 1;\n this.usageCount += 1;\n }", "function updateRatings(params, callback) {\n var user = params.user;\n var problem = params.problem;\n var result = params.result;\n var solve_time = params.solve_time;\n\n var ranking = new glicko2.Glicko2({\n tau: 0.5,\n rating: 1200,\n rd: 200,\n vol: 0.06\n });\n\n var p = ranking.makePlayer(problem.rating, problem.rating_deviation, problem.rating_volitility);\n var u = ranking.makePlayer(user.rating, user.rating_deviation, user.rating_volitility);\n\n var score = result ? 1 : 0;\n if(result && problem.answers.length > 1){ //todo modify so time penalty occurs when problem.sd becomes low\n var upper_bound = problem.average_solve_time + problem.sd_solve_time \n var lower_bound = problem.average_solve_time - problem.sd_solve_time \n\n if (solve_time < lower_bound) {\n score = 1.25; //bonus for faster than sd\n }else if(solve_time > upper_bound) {\n score = 0.5; //penalty for slower than sd\n } \n }\n var match = [u, p, score];\n\n\n ranking.updateRatings([match]);\n\n //update models\n user.rating_change = u.getRating() - user.rating;\n user.rating = u.getRating();\n user.rating_deviation = u.getRd();\n user.rating_volitility = u.getVol();\n user.ratings.push({\n rating: user.rating,\n date: new Date()\n });\n\n\n problem.rating_change = p.getRating() - user.rating;\n problem.rating = p.getRating();\n problem.rating_deviation = p.getRd();\n problem.rating_volitility = p.getVol();\n callback(null, {user: user, problem: problem});\n}", "updateTCUs() {\r\n this.calculateTCUs(-1, -1);\r\n }", "function update() {\n updateMonthly(calculateMonthlyPayment(getCurrentUIValues()));\n if (getCurrentUIValues().rate > 1) {\n alert(\n \"A rate greater than 1 was entered; operating on the assumption it was meant to be a percentage.\"\n );\n }\n if (getCurrentUIValues().years <= 1 / 12) {\n alert(\n \"Entered time is a month or less; the loan must be repaid in full the first month.\"\n );\n }\n}", "_recalculate() {\n const inputs = this._getInputs();\n const errors = validateInputs(inputs);\n if (Object.keys(errors).length) {\n this.setState({ errors });\n return;\n }\n\n const { backlogSize, velocity, startDate, endDate } = inputs;\n const duration = endDate.diff(startDate, 'days');\n const results = {\n isSuccessful: isSuccessful(backlogSize, velocity, duration),\n probability: successProbability(backlogSize, velocity, duration),\n completionDate: startDate.clone().add(successDuration(backlogSize, velocity), 'days'),\n backlogSize: successBacklogSize(velocity, duration),\n };\n\n this.setState({ results, errors });\n }", "function setRate(val) {\n rate = val;\n document.getElementById(\"rateOfInterest\").innerHTML = val + \"%\";\n}", "function displayExchangeRate() {\n // Calc expected Rate in ETH not Wei\n expectedRateEth = expectedRate / (10 ** 18);\n // Calcualte user Exchange rate\n expectedRateHTML.innerText = `1 ${srcSymbol} = ${expectedRateEth} ${destSymbol}`;\n // expectedRate / (10 ** 18)\n}", "function update() {\n\n var fluc = $rootScope.model.fluctuating;\n var rec = $rootScope.model.recurring;\n var inc = $rootScope.model.income;\n\n $rootScope.model.expTotal = 0;\n $rootScope.model.flucTotal = 0;\n $rootScope.model.recTotal = 0;\n $rootScope.model.inTotal = 0;\n\n if ((fluc !== undefined || rec !== undefined) && $rootScope.model.income != undefined) {\n\n fluc.forEach(function(entry) {\n if (entry)\n $rootScope.model.expTotal += entry.value;\n $rootScope.model.flucTotal += entry.value;\n });\n\n rec.forEach(function(entry) {\n if (entry)\n $rootScope.model.expTotal += entry.value;\n $rootScope.model.recTotal += entry.value;\n\n });\n\n inc.forEach(function(entry) {\n if (entry)\n $rootScope.model.inTotal += entry.value;\n\n });\n\n\n $rootScope.model.amountLeft = $rootScope.model.inTotal - $rootScope.model.expTotal;\n $rootScope.model.perDay = $rootScope.model.amountLeft / $rootScope.daysLeft;\n\t\t filterM();\n }\n }", "function updateShelterError(error) {\n vm.error = \"Could not update shelter at this time. Please try again later.\";\n scrollToError();\n }", "function updateCur1Update(){\n cur1Amnt= document.getElementById(\"cur1_amount\").value;\n\n cur1Type = document.getElementById(\"cur1_type\").value;\n cur2Type = document.getElementById(\"cur2_type\").value;\n\n var index1 = currList.indexOf(cur1Type);\n var index2 = currList.indexOf(cur2Type);\n var amnt = ((ratios[index2] / ratios[index1]) * cur1Amnt);\n\n if(amnt>0.01 && amnt<999999){\n amnt=amnt.toFixed(2);\n }\n else{\n amnt=amnt.toPrecision(2);\n }\n document.getElementById(\"cur2_amount\").value=amnt;\n\n updateLabels();\n}", "function setError(error) {\n\t\t\tself.error = error;\n\t\t}", "updateErrorState() {\n const oldState = this.errorState;\n const parent = this._parentFormGroup || this._parentForm;\n const matcher = this.errorStateMatcher || this._defaultErrorStateMatcher;\n const control = this.ngControl ? this.ngControl.control : null;\n const newState = matcher.isErrorState(control, parent);\n if (newState !== oldState) {\n this.errorState = newState;\n this.stateChanges.next();\n }\n }", "function updateExchangeRates() {\n var currencies = [];\n var hasNegative = false;\n for (var cur in $scope.balances) {if ($scope.balances.hasOwnProperty(cur)){\n var components = $scope.balances[cur].components;\n for (var issuer in components) {if (components.hasOwnProperty(issuer)){\n // While we're at it, check for negative balances:\n hasNegative || (hasNegative = components[issuer].is_negative());\n currencies.push({\n currency: cur,\n issuer: issuer\n });\n }}\n }}\n $scope.hasNegative = hasNegative;\n var pairs = currencies.map(function(c){\n return {\n base:c,\n counter:{currency:'XRP'}\n };\n });\n if (pairs.length) {\n $scope.exchangeRatesNonempty = false;\n $http.post('https://api.ripplecharts.com/api/exchangeRates', {pairs: pairs, last: true})\n .success(function(response){\n for (var i = 0; i < response.length; i++) {\n var pair = response[i];\n if (pair.last > 0) { // Disregard unmarketable assets\n $scope.exchangeRates[pair.base.currency + ':' + pair.base.issuer] = pair.last;\n }\n }\n\n $scope.exchangeRatesNonempty = true;\n console.log('Exchange Rates: ', $scope.exchangeRates);\n });\n } else {\n $scope.exchangeRatesNonempty = true;\n }\n }", "function setRating() {\n // make sure rating doesn't go below 1 star\n if (mismatches > 7) return;\n\n // decrease rating every 3 mismatches\n if ( (mismatches % 3) === 0 ) {\n rating--;\n ratingLabel.removeChild(ratingLabel.lastElementChild);\n }\n}", "function refreshSettings() {\n _valueUpperMultiplier = _valueMultiplier * _valueRange;\n _displayUpperMultiplier = _displayMultiplier * _displayRange;\n }", "function update() {\n calculateMonthlyPayment(values);\n updateMonthly(monthlyPayment);\n }", "recalibrate() {\n this.recalRequested = true;\n }", "updateSpeed (speed) {\n this.speed = speed;\n }", "updatePrice(){\n if( this.price > 0 ){\n this.price -= 1;\n }\n\n this.sellIn -= 1;\n\n if( this.sellIn < 0 ){\n if( this.price > 0 ) this.price -= 1;\n }\n }", "function updateCredits() {\n var remainingCredits = RED.options.getOption(\"startingCredits\") - calculateCredits();\n if (remainingCredits > 300) {\n // Low credits remaining: warn the user\n $( \"#node-remaining-credits\").removeClass(\"alert\");\n } else {\n $( \"#node-remaining-credits\").addClass(\"alert\");\n }\n $( \"#node-remaining-credits\").text(\"Remaining credits: \" + remainingCredits + \" cr\");\n }", "update() {\n this.$nonces.textContent = this.nonces;\n this.$hashes.textContent = this.totalHashes;\n this.$hashrate.textContent = this.hashrate || 'N/A';\n }", "function updater(fun, rate) {\n\t var timeout;\n\t var last = 0;\n\t var runnit = function () {\n\t if (last + rate > rnow()) {\n\t clearTimeout(timeout);\n\t timeout = setTimeout(runnit, rate);\n\t } else {\n\t last = rnow();\n\t fun();\n\t }\n\t };\n\n\t return runnit;\n\t}", "error (err) {\n return function (res, cb) {\n _setImmediate(() => {\n res.value += 10\n cb(err, res)\n })\n }\n }", "propagate(learningRate, target) {\n let error = 0;\n let isOutput = typeof target !== 'undefined';\n\n if (isOutput) {\n this.error.responsibility = this.error.projected = target - this.activation;\n } else {\n for (const connection of Object.keys(this.connections.projected)) {\n const projectedConnection = this.connections.projected[connection];\n const neuron = projectedConnection.to;\n\n error += neuron.error.responsibility * projectedConnection.weight;\n }\n\n this.error.responsibility = this.error.projected = this.derivative * error;\n }\n\n // adjust all the neuron's incoming connections\n for (const connection of Object.keys(this.connections.incoming)) {\n const incomingConnection = this.connections.incoming[connection];\n\n let gradient = this.error.projected;\n incomingConnection.weight += learningRate * gradient * incomingConnection.from.derivative;\n }\n\n this.bias += learningRate * this.error.responsibility;\n }", "function updateUiError() {\n showElements(statusMessage);\n statusMessage.textContent =\n \"Sorry you have entered invalid value, please try again!\";\n statusMessage.classList.remove(\"success\");\n statusMessage.classList.add(\"error\");\n}", "function refresh() {\n\tstate = Engine.new_scenario();\n\tEngine.update_min_weight_val();\n\tPlotError.update_error_line();\n\tPlotError.update_true_weight_line();\n PlotData.update_target_line();\n PlotData.update_hypothesis_line();\n\tPlotData.update_training_circles();\n\tupdate_sliders();\n\treset_sgd();\n\tPlotError.update_batch_error_line();\n}", "maxValueUpdated() {\n this.showFlyout(this.flyoutStatus.error, this.i18n.maxValueUpdatedStatus, true);\n }", "function updateProgress (){\n\tprogress.value += 30;\n}", "fundingRateChangedCallback(cb) {\n this.fundingRateChanged = cb;\n }", "function UpdateProgressMetrics(){\n // Calculate percentage of module progress\n perbaspro = baspro/20*100;\n perpospro = pospro/20*100;\n perfol1pro = fol1pro/20*100;\n perfol2pro = fol2pro/20*100;\n perbashrqpro = bashrqpro/6*100;\n perposhrqpro = poshrqpro/6*100;\n perfol1hrqpro = fol1hrqpro/6*100;\n perfol2hrqpro = fol2hrqpro/6*100;\n perbasmitakpro = basmitakpro/37*100;\n perposmitakpro = posmitakpro/37*100;\n perfol1mitakpro = fol1mitakpro/37*100;\n perfol2mitakpro = fol2mitakpro/37*100;\n permipro = mipro/6*100;\n peroarspro = oarspro/58*100;\n pertarpro = tarpro/33*100;\n perevokpro = evokpro/100*100;\n perplanpro = planpro/11*100;\n perfullmipro = fullmipro/1*100;\n \n // Calculate percentage of skill acquisition based on correct items\n affirmcount = UpdateProgressResponseCorrect(oarsanswercorrect5) + UpdateProgressResponseCorrect(oarsanswercorrect6);\n peraffirm = affirmcount/15*100;\n \n reflectcount = UpdateProgressResponseCorrect(oarsanswercorrect4) + UpdateProgressResponseCorrect(targetanswercorrect2);\n perreflect = reflectcount/11*100;\n \n openclosecount = UpdateProgressResponseCorrect(oarsanswercorrect1) + UpdateProgressResponseCorrect(oarsanswercorrect2) + UpdateProgressResponseCorrect(oarsanswercorrect3);\n peropenclose = openclosecount/39*100;\n \n targetcount = UpdateProgressResponseCorrect(targetanswercorrect1);\n pertarget = targetcount/13*100;\n \n changetalkcount = UpdateProgressResponseCorrect(evokanswercorrect1) + UpdateProgressResponseCorrect(evokanswercorrect2) + UpdateProgressResponseCorrect(evokanswercorrect3) + UpdateProgressResponseCorrect(evokanswercorrect4) + UpdateProgressResponseCorrect(evokanswercorrect5);\n perchangetalk = changetalkcount/88*100;\n \n}", "function updateRateLimits(\n limits,\n { statusCode, headers },\n now = Date.now(),\n) {\n const updatedRateLimits = {\n ...limits,\n };\n\n // \"The name is case-insensitive.\"\n // https://developer.mozilla.org/en-US/docs/Web/API/Headers/get\n const rateLimitHeader = headers && headers['x-sentry-rate-limits'];\n const retryAfterHeader = headers && headers['retry-after'];\n\n if (rateLimitHeader) {\n /**\n * rate limit headers are of the form\n * <header>,<header>,..\n * where each <header> is of the form\n * <retry_after>: <categories>: <scope>: <reason_code>\n * where\n * <retry_after> is a delay in seconds\n * <categories> is the event type(s) (error, transaction, etc) being rate limited and is of the form\n * <category>;<category>;...\n * <scope> is what's being limited (org, project, or key) - ignored by SDK\n * <reason_code> is an arbitrary string like \"org_quota\" - ignored by SDK\n */\n for (const limit of rateLimitHeader.trim().split(',')) {\n const [retryAfter, categories] = limit.split(':', 2);\n const headerDelay = parseInt(retryAfter, 10);\n const delay = (!isNaN(headerDelay) ? headerDelay : 60) * 1000; // 60sec default\n if (!categories) {\n updatedRateLimits.all = now + delay;\n } else {\n for (const category of categories.split(';')) {\n updatedRateLimits[category] = now + delay;\n }\n }\n }\n } else if (retryAfterHeader) {\n updatedRateLimits.all = now + parseRetryAfterHeader(retryAfterHeader, now);\n } else if (statusCode === 429) {\n updatedRateLimits.all = now + 60 * 1000;\n }\n\n return updatedRateLimits;\n}", "update() {\n for(let i=0; i<Simulation.speed; i++) {\n globalUpdateCount += 1\n this.fields.forEach(f => f.update())\n this.sender.auto()\n this.sender.update()\n this.updateR()\n this.chart.update(this.fields, this.sender)\n }\n }", "function updateClassStats() {\n\tvar len = studentListData.length;\n\tvar sum = 0;\n\tvar avg = 0;\n\n\t$.each(studentListData, function() {\n\t\tsum += this.classAverage;\n\t});\n\n\tavg = sum / len;\n\tavg = avg.toFixed(2);\n\t\n\n\tvar editData = { \n\t\taverage : avg,\n\t\tnumStudents : len\n\t};\n\n\t// updates class' classAverage\n\t$.ajax({\n\t\ttype: 'PUT',\n\t\turl: '/api/editclassstats',\n\t\tdata: editData,\n\t\tdataType: 'JSON'\n\t}).done(function(response) {\n\t\t\n\t\t// Check for success\n\t\tif (response.msg === '') {\n\n\t\t} else {\n\t\t\talert(response.msg);\n\t\t}\n\n\n\t});\n\n\n}" ]
[ "0.68976146", "0.6777766", "0.612367", "0.59151495", "0.590682", "0.5859789", "0.57602364", "0.56785697", "0.5597232", "0.55769384", "0.55600226", "0.548091", "0.54773706", "0.5463604", "0.5435289", "0.5433369", "0.5412823", "0.5403989", "0.53394127", "0.5322566", "0.53169334", "0.5304287", "0.5291295", "0.5285533", "0.52803606", "0.5271445", "0.52682203", "0.52477145", "0.5202698", "0.5199739", "0.51956755", "0.5187254", "0.5165843", "0.5145829", "0.5140523", "0.51271", "0.5123671", "0.5105005", "0.51025194", "0.5092166", "0.5079867", "0.5071008", "0.5060664", "0.50498414", "0.50426096", "0.5041893", "0.50350034", "0.5029632", "0.502704", "0.50247467", "0.5015349", "0.49843055", "0.4984262", "0.49827546", "0.49790475", "0.49749318", "0.4970227", "0.49655354", "0.49575052", "0.493762", "0.4937332", "0.49372658", "0.49331504", "0.49321014", "0.49293035", "0.4928171", "0.49254552", "0.4917484", "0.49151987", "0.49011636", "0.4887245", "0.48868692", "0.4883984", "0.48825732", "0.48818624", "0.48789442", "0.48779628", "0.4873294", "0.48719072", "0.48665458", "0.48645803", "0.4863738", "0.48500204", "0.48468018", "0.48442632", "0.48435685", "0.48395628", "0.48370612", "0.4836283", "0.4835888", "0.48345503", "0.4829316", "0.4827307", "0.4821764", "0.48211178", "0.4811033", "0.48089722", "0.48080146", "0.48055604", "0.48032054" ]
0.7552104
0
Update the smiley to reflect the user's performance.
function updateSmiley() { var errorRate = Math.round(my.current.errorRate) var smiley if (errorRate == 0) { if (my.current.wpm >= 40) { smiley = my.SMILEY.VERY_HAPPY } else { smiley = my.SMILEY.HAPPY } } else if (errorRate > 0 && errorRate <= 2) { smiley = my.SMILEY.UNHAPPY } else { smiley = my.SMILEY.SAD } Util.setChildren(my.html.smiley, smiley) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "updateEmoji(){\r\n if(this.rating < .2){\r\n this.emoji = \"media/verysad.png\"; \r\n }\r\n else if(this.rating < .4){\r\n this.emoji = \"media/sad.png\"; \r\n }\r\n else if(this.rating < .6){\r\n this.emoji = \"media/neutral.png\"; \r\n }\r\n else if(this.rating < .8){\r\n this.emoji = \"media/happy.webp\"; \r\n }\r\n else{\r\n this.emoji = \"media/veryhappy.png\"; \r\n }\r\n }", "updateUI() {\n this.scoreText.setText(`Score ${this.bumperPoint}`);\n\n const emojis = [];\n for (let i = 0; i < this.healthPoint; i++) {\n emojis.push('❤');\n }\n let healthHearts = emojis.join().replace(/\\,/g, ' ');\n this.healthText.setText(`Health ${healthHearts}`);\n }", "function update() {\r\n\r\n // update game\r\n game.update();\r\n\r\n // toggle tower clickable depending on the user's money\r\n updateTowerStore();\r\n\r\n let { type, lives, money, level, difficulty } = game.getLevelStats();\r\n\r\n // update lives and money based on game stats \r\n livesLabel.innerHTML = 'Lives: ' + lives;\r\n moneyLabel.innerHTML = '$' + money;\r\n levelLabel.innerHTML = 'Level: ' + level; \r\n difficultyLabel.innerHTML = 'difficulty: ' + difficulty;\r\n nextLevelLabel.innerHTML = '';\r\n\r\n if (type) nextLevelLabel.appendChild(ENEMY_IMAGES[type]);\r\n else nextLevelLabel.style.display = 'none';\r\n\r\n // increase flashing transparency\r\n flashingTransparency = flashingTransparency + .2;\r\n}", "function updateIcon(duration, currentTime) {\r\n\r\n\tduration = formatTime(duration, false)\r\n\tcurrentTime = formatTime(currentTime)\r\n\r\n\tvar height = 32\r\n\tvar width = 32\r\n\r\n\tvar c = document.createElement(\"canvas\")\r\n\tc.height = height\r\n\tc.width = width\r\n\r\n\tvar newIcon = c.getContext(\"2d\")\r\n\tnewIcon.font = \"15px Arial\"\r\n\tnewIcon.textAlign = \"center\"\r\n\tnewIcon.fillStyle = \"#\" + getTextColor() // \"rgb(180,0,0)\"\r\n\r\n\tnewIcon.fillText(currentTime, width/2, 12)\r\n\tnewIcon.fillText(duration, width/2, 31)\r\n\r\n\t// Draw horizontal line\r\n\tnewIcon.beginPath()\r\n\tnewIcon.lineWidth = 0\r\n\tnewIcon.strokeStyle = \"#\" + getTextColor() // \"rgb(100,0,0)\"; //\r\n\tnewIcon.moveTo(0, height/2)\r\n\tnewIcon.lineTo(width, height/2)\r\n\tnewIcon.stroke()\r\n\r\n\tchrome.browserAction.setIcon({imageData: newIcon.getImageData(0, 0, width, height)})\r\n\r\n}", "function updateHighScore() {\n if (isIdleMode) {\n highScoreElement.textContent = `Idle High Score: ${highScoreIdle}`;\n } else {\n highScoreElement.textContent = `Speedrun High Score: ${highScoreSpeedrun}`;\n }\n}", "function updateHighScore() {\n if (isIdleMode) {\n highScoreElement.textContent = `Idle High Score: ${highScoreIdle}`;\n } else {\n highScoreElement.textContent = `Speedrun High Score: ${highScoreSpeedrun}`;\n }\n}", "function updateSpeed()\n {\n // WPM and CPM does not need to be calculated on error\n if (my.current.state == my.STATE.ERROR) {\n return\n }\n\n var goodChars = my.current.correctInputLength\n\n // Determine the time elapsed since the user began typing\n var currentTime = new Date().getTime()\n var timeElapsed = currentTime - my.current.startTime\n my.current.timeElapsed = timeElapsed\n\n // Calculate WPM and CPM\n var wpm\n if (timeElapsed == 0) {\n wpm = goodChars == 0 ? 0 : '\\u221e'\n } else {\n wpm = Math.round(60000 * goodChars / 5 / timeElapsed)\n my.current.wpm = wpm\n my.current.cpm = Math.round(60000 * goodChars / timeElapsed)\n }\n\n // Display WPM\n Util.setChildren(my.html.speed, wpm + ' wpm')\n }", "function smiley(){\n vm.input = vm.input.concat(\"😁\");\n }", "function updateBlacksmith(){\n\t$(\"#bsmRandomWeaponCostText\").html(bsmRandomWeaponCost);\n\t$(\"#bsmStrengthenPercentText\").html(bsmStrengthenPercent);\n\t$(\"#bsmStrengthenCostText\").html(bsmStrengthenCost);\n\t$(\"#bsmStrengthenBladePercentText\").html(bsmStrengthenBladeBonus);\n\t$(\"#bsmStrengthenHiltPercentText\").html(bsmStrengthenHiltBonus);\n\t$(\"#bsmStrengthenPointPercentText\").html(bsmStrengthenPointBonus);\n\tupdateBlacksmithButtons();\n}", "function updateHPDisplay() {\n\t// Update the HP label\n\tvar temp = document.getElementById('currentHP');\n\ttemp.innerHTML = parseInt(displayedHP + 0.5);\n\n\t// Update the HP width\n\thpBoxCurrent.style.width = displayedHP / maxHP * 100 + '%';\n\n\t// Update the HP color\n\thpUpdateColor();\n}", "function updateSinglePlayerStatScreen(currTurn){\n console.log(\"updateSinglePlayerStatScreen\");\n singleGraphics.clear();\n //only redraw the health bar if we're on the single player stat screen\n if(!statScreen.ShowAll){\n updateSinglePlayerHealthBar(currTurn);\n }\n\n // update each Attribute String with data from the queue, and randomly switch each string to be \n // red (#ff0000) or green (#00ff00)\n // in the finished version the green or red will depend on a buff or debuff\n var characterArray = convertTurnToPlayerArray(currTurn); \n for(var attrStr in statScreen.SinglePlayer.AttributeStrings){\n if(statScreen.SinglePlayer.AttributeStrings.hasOwnProperty(attrStr)){\n //the attribute string with appropiate spacing if necessary\n //\"MovementSpeed\" --> \"Movement Speed\"\n var spacedAttrStr = attrStr;\n switch(attrStr){\n case \"MovementSpeed\":\n spacedAttrStr = \"Movement Speed\"\n break;\n case \"SpellPower\":\n spacedAttrStr = \"Spell Power\"\n break;\n default:\n break;\n }\n statScreen.SinglePlayer.AttributeStrings[attrStr]\n .setText(spacedAttrStr + \": \" + characterArray[statScreen.SinglePlayer.PlayerIndex].Attributes[attrStr]);\n statScreen.SinglePlayer.AttributeStrings[attrStr].setStyle({\n font: \"3em Arial\", \n fill: chooseColor(currTurn, statScreen.SinglePlayer.PlayerIndex, attrStr),\n });\n }\n }\n\n}", "function updateStats() {\n $(\"#fighterhealth\").text(\"HP:\\xa0\" + fighterHP);\n $(\"#defenderhealth\").text(\"HP:\\xa0\" + defenderHP);\n }", "function update() {\n document.getElementById('cheese-Count').innerText = cheese.toString();\n drawPerClickStat();\n}", "function updateStats() {\n var htmlString = \"\";\n htmlString += (\"<h1>\" + character.name + \"</h1>\");\n htmlString += (\"<h2 id='level'>Level \" + character.lvl + \"</h2>\");\n htmlString += (\"<p id='hp'>HP: \" + character.hp + \"/\" + character.maxhp + \"</p>\");\n htmlString += (\"<p id='xp'>XP: \" + character.xp + \"/\" + (character.lvl*character.lvl*150) + \"</p>\");\n htmlString += (\"<p id='energy'>Energy: \" + character.energy + \"/\" + character.maxenergy + \"</p>\");\n $('#stats').css('overflow-y', 'hidden');\n $('#stats').html(htmlString);\n }", "function updateHighScoreMC() {\r\n $('#mcGames h4 span span').html(highScoreMC);\r\n }", "updateGameSpeed() {\n const score = document.getElementById('score');\n const formattedScore = parseInt(score.innerHTML);\n if (formattedScore % 5 === 0 && this.speed > 100) {\n this.endGameTick();\n this.speed = this.speed - 100;\n this.startGameTick();\n }\n }", "function updateSkills(){\n\tvar skillName;\n\tvar mod = parseInt($('#charProficiency').val());\n\tvar stat; \n\n\tif(saved.getItem('skillBonus') != null)\n\t\tvar skillName = saved.getItem('skillBonus').split(':');\n\n\n\tfor(var i = 0;i < skillBonus.length;++i){\n\t\tstat = parseInt(saved.getItem(skillName[i]));\n\n\t\t// If user has not entered in a stat value\n\t\tif(isNaN(stat))\n\t\t\tstat = 0;\n\n\t\t$('#'+skillBonus[i]).val(stat + mod);\n\t}\n}", "function updateGameStats(score, size, speed) {\n document.getElementById('score').innerText = score;\n document.getElementById('size').innerText = size;\n document.getElementById('speed').innerText = speed.toFixed(2) + ' blocks/sec';\n}", "_updateScore() {\n\t\tthis._$scoreBoard.textContent= this._score+'';\n\t}", "update() {\n this.character.update();\n }", "_updateScore () {\n this._scoreBoard.innerHTML = this._score;\n }", "updateScore() {\n ctx.font = \"30px Verdana\";\n ctx.fillStyle = \"white\";\n ctx.fillText(`Kills:`, 90, 70);\n ctx.drawImage(zombieDieingImages[3], 160, 0, 80, 80);\n ctx.fillText(`x${this.score}`, 230, 70);\n }", "function smiley(icon) {\n comment = document.getElementById(\"comment\");\n\ticon = ' ' + icon + ' ';\n\tinsertAtCursor(comment, icon); // Added by Hiro\n\t//comment.value += icon; // Commented out by Hiro\n}", "updateBadge() {\n var numberOfUnwatchedLessons = this.lessons.filter(lesson => {\n return lesson.watched == false;\n }).length;\n\n Chrome.changeBadgeValue(numberOfUnwatchedLessons.toString());\n }", "function react () {\n lastInput = clock.getElapsedTime()\n intensity += 0.0008\n if (intensity > 0.005) { intensity = 0.005 }\n}", "function updateScore(value) {\n gState.score += value;\n document.querySelector('header > h3 > span').innerText = gState.score;\n displayVictory();\n}", "function stopwatchUpdate() {\r\n rawTime += intervalRate;\r\n stopwatchTime.innerHTML = formatTime(rawTime);\r\n}", "UpdateMetrics() {\n }", "function updateEnemyStats() {\n\t\t$(\"#enemyHealth\").html(\"HP: \" + enemyPicked.health + \"<br />Attack: \" + enemyPicked.attack);\n\t\t$(\"#enemyName\").html(enemyPicked.display);\n\t}", "function changeSword() {\n if (sword==0) {\n $('#swords').css({filter:'grayscale(0%)'});\n sword++;\n }\n else if (sword==1) {\n $('#swords').attr('src', 'images/item sprites/Green Sword.png');\n sword++;\n }\n else if (sword==2) {\n $('#swords').attr('src', 'images/item sprites/Red Sword.png');\n sword++;\n }\n else if(sword==3) {\n $('#swords').attr('src', 'images/item sprites/Blue Sword.png');\n sword++;\n }\n else if (sword==4) {\n $('#swords').attr('src', 'images/item sprites/Four Sword.png');\n sword++;\n }\n else {\n $('#swords').attr('src', \"images/item sprites/Smith's Sword.png\");\n $('#swords').css({filter:'grayscale(100%)'});\n sword=0;\n }\n}", "updateScore() {\n\t\tthis.score += 1;\n\t\tthis.gameinfoElement.childNodes[0].innerHTML = \"<h1>Score: \" + this.score + \"</h1>\";\n\t}", "function updateMoves() {\n if (moves === 1) {\n $(\"#movesText\").text(\" Move\");\n } else {\n $(\"#movesText\").text(\" Moves\");\n }\n $(\"#moves\").text(moves.toString());\n\n if (moves > 0 && moves < 16) { // gives star rating according the no of moves ,removes the class\n starRating = starRating;\n } else if (moves >= 16 && moves <= 20) {\n $(\"#starOne\").removeClass(\"fa-star\");\n starRating = \"2\";\n } else if (moves > 20) {\n $(\"#starTwo\").removeClass(\"fa-star\");\n starRating = \"1\";\n }\n}", "function updateWeaponInterface() {\n\tswitch(activeSecWeapon) {\n\t\tcase 0:\n\t\t\t\tguidedRock.hide();\n\t\t\t\tmigPic.hide();\n\t\t\t\twavePic.hide();\n\t\t\t\trocketPic.show();\n\t\t\t\tcurrentAmmo = rocketAmmo;\n\t\t\t\tmaxAmmo = MaxRocketAmmo;\n\t\t\t\tbreak;\n\t\tcase 1:\n\t\t\t\tguidedRock.hide();\n\t\t\t\trocketPic.hide();\n\t\t\t\twavePic.hide();\n\t\t\t\tmigPic.show();\n\t\t\t\tcurrentAmmo = MGAmmo;\n\t\t\t\tmaxAmmo = MaxMGAmmo;\n\t\t\t\tbreak;\n\t\tcase 2:\n\t\t\t\tguidedRock.hide();\n\t\t\t\trocketPic.hide();\n\t\t\t\tmigPic.hide();\n\t\t\t\twavePic.show();\n\t\t\t\tcurrentAmmo = shockwaveAmmo;\n\t\t\t\tmaxAmmo = maxShockwaveAmmo;\n\t\t\t\tbreak;\n\t\tcase 3:\n\t\t\t\twavePic.hide();\n\t\t\t\trocketPic.hide();\n\t\t\t\tmigPic.hide();\n\t\t\t\tguidedRock.show();\n\t\t\t\tcurrentAmmo = guidedMissileAmmo;\n\t\t\t\tmaxAmmo = maxGuidedMissileAmmo;\n\t\t\t\tbreak;\n\t\tdefault:\n\t\t\t\tcurrentAmmo = 42;\n\t\t\t\tmaxAmmo = 42;\n\t\t\t\tbreak;\n\t}\n\n\tdocument.getElementById('currentAmmo').innerHTML = currentAmmo;\n\tdocument.getElementById('maxAmmo').innerHTML = maxAmmo;\n}", "function updateStars(){\n if (incorrectGuesses === 10) {\n $('#star-10').attr('src','images/black-star.png');\n startingStars -= 1;\n }\n else if (incorrectGuesses === 20) {\n $('#star-20').attr('src','images/black-star.png');\n startingStars -= 1;\n }\n else if (incorrectGuesses === 30) {\n $('#star-30').attr('src','images/black-star.png');\n startingStars -= 1;\n }\n}", "swapSmiley() {\n this.setState({\n smileyVisible: !this.state.smileyVisible\n });\n }", "updateHp(hp1, hp2){\n $(\"div#player span.health\").text(hp1);\n $(\"div#enemy span.health\").text(hp2);\n }", "function scoreUpdate(){\r\n document.getElementById('score').innerText = piece.score;\r\n }", "function hud() {\n let missileCount = 5 - playerMissile.pCooldown;\n\n CONTEXT.fillStyle = \"yellow\";\n CONTEXT.font = \"20px Arial\";\n CONTEXT.textAlign = \"left\";\n CONTEXT.fillText(\"LEVEL \\\\\\\\ \" + level, 10, 20);\n CONTEXT.textAlign = \"center\";\n CONTEXT.fillText(\"LIVES \\\\\\\\ \" + playerLives, C_WIDTH / 2, 20);\n CONTEXT.textAlign = \"left\";\n CONTEXT.fillText(\"MISSLES \\\\\\\\ \" + missileCount, C_WIDTH - 130, 20);\n}", "refreshing(heal) {\n this.newLine();\n this.player.health += Number(heal);\n console.log(\"Ah, refreshing.\");\n }", "function updateScore() {\n\tvar elScore = document.querySelector('#score');\n\tvar sHTML = (gBallsColected === 1)? gBallsColected +' ball' : gBallsColected +' balls';\n\t\n\telScore.innerHTML = sHTML;\n}", "updateScore(){\n this.score += 10;\n CURRENT_SCORE.innerHTML = `Score: ${this.score}`;\n }", "update() {\n if (this.currentGold != this.characterData.gold) {\n // Play buy sfx\n this.audio.playSfx(\"purchase\");\n\n // Remove old gold info and re-add new\n this.goldText.destroy();\n this.goldImage.destroy();\n this.displayGold(this.characterData.gold);\n this.currentGold = this.characterData.gold;\n }\n }", "function stopwatchUpdate(){\n rawTime += intervalRate\n stopwatchTime.innerHTML = formatTime(rawTime)\n}", "function updateGraphics() {\n // Update the game boxes\n for(const box of divs.game_boxes) {\n if(box.getAttribute('state') == 0) {\n box.style.backgroundImage = \"\";\n box.style.opacity = \"1\";\n }\n else if(box.getAttribute('state') == 1) {\n box.style.backgroundImage = \"url('./assets/plant_evil.png')\";\n box.style.opacity = \"1\";\n }\n else if(box.getAttribute('state') == 2) {\n box.style.backgroundImage = \"url(./assets/plant_good.png)\";\n box.style.opacity = \"1\";\n }\n else {\n box.style.opacity = \"0.5\";\n }\n }\n\n // Update lives\n if(info.lives == 0) {\n for(const box of divs.live_boxes) {\n box.src = \"./assets/heart_broken.png\";\n box.style.opacity = \"0.9\";\n }\n }\n else if(info.lives == 1) {\n divs.live_boxes[0].src = \"./assets/heart_broken.png\";\n divs.live_boxes[0].style.opacity = \"0.9\";\n divs.live_boxes[1].src = \"./assets/heart_broken.png\";\n divs.live_boxes[1].style.opacity = \"0.9\";\n }\n else if(info.lives == 2) {\n divs.live_boxes[0].src = \"./assets/heart_broken.png\";\n divs.live_boxes[0].style.opacity = \"0.9\";\n }\n else {\n for(const box of divs.live_boxes) {\n box.src = \"./assets/heart.png\";\n box.style.opacity = \"1\";\n }\n }\n\n // Update score and level\n divs.score_div.innerText = info.score;\n divs.level_div.innerText = info.level;\n}", "function updateMultiPlayerStatScreen(currTurn){\n console.log(\"updateMultiPlayerStatScreen\");\n\n //update the color of the strings\n statScreen.MultiPlayer.forEach(function(player, index){\n for (var attrString in player[\"AttributeStrings\"]){\n //ignore AttackRange attribute\n if(player[\"AttributeStrings\"].hasOwnProperty(attrString) && attrString != \"AttackRange\"){ \n player[\"AttributeStrings\"][attrString].setStyle({\n font: \"2em Arial\", \n fill: chooseColor(currTurn, index, attrString) \n });\n }\n }\n }); \n\n //update healthbars only if we're on the multiplayer stat screen\n multiGraphics.clear();\n if(statScreen.ShowAll){\n multiGraphics.beginFill(HEALTH_BAR_COLOR);\n var startX = GAME_WIDTH + 20;\n var MULTI_HEALTHBAR_HEIGHT = 10;\n var strings;\n for (var player in statScreen.MultiPlayer){\n strings = statScreen.MultiPlayer[player].AttributeStrings;\n statScreen.MultiPlayer[player].HealthBar = multiGraphics.drawRect(\n startX, \n strings.MovementSpeed.y + strings.MovementSpeed.height, \n calcHealthBarWidth(currTurn, player),\n MULTI_HEALTHBAR_HEIGHT);\n }\n\n multiGraphics.endFill();\n }\n}", "function addStarBonusToScore(){\n let starBonus = endingStarBonus * 1000;\n $('#star-bonus').html(starBonus);\n score += starBonus;\n}", "function fastSpeed(){\n $(\"#counter\").text(coffeeMil);\n coffeeMil++;\n $('#coffeecounter').show();\n $(\"#info\").text('Great, another migraine for today.');\n console.log('Coffee counter with increased speed working.');\n\n }", "updateMana() {\n //Update each mana color\n for(let color in this.mana) {\n // Only display if there is some mana\n this.manaStatus[color].style.display = this.mana[color] > 0 ? 'block' : 'none';\n // Show the number of mana available\n this.manaStatus[color].amount.textContent = this.mana[color];\n }\n }", "function updateTime() {\n const toSecondStr = (ms) => (ms / 1000).toFixed(ROUND_DECIMALS);\n if (!isPlayingGame) return;\n id(\"score\").innerHTML = `Score: ${toSecondStr(timeElapsedMs)} seconds`;\n if (timeElapsedMs > highScore) {\n highScore = timeElapsedMs;\n }\n id(\"high-score\").innerHTML = `High score: ${toSecondStr(\n highScore\n )} seconds`;\n }", "function updateSwatch() {\n $lastSwatch = $swatch;\n widget._trigger( 'updatedswatch' );\n }", "function updatePlayerStats() {\n\t\t$(\"#playerHealth\").html(\"HP: \" + characterPicked.health + \"<br />Attack: \" + characterPicked.attack);\n\t\t$(\"#playerName\").html(characterPicked.display);\n\t}", "_updateGenerationSpeed(speed) {\n this['generationSpeed'] = parseInt(speed, 10);\n this._layoutWords();\n }", "function regularSpeed(){\n $(\"#counter\").text(coffeeMil);\n coffeeMil++;\n $('#coffeecounter').show();\n console.log('Regular coffee counter appeared and working.');\n }", "function updateNewRating(newRating) {\n\t$('#current-rating').text(newRating)\n}", "function updateMoves() {\n moves += 1;\n const move = document.querySelector(\".moves\");\n move.innerHTML = moves;\n if (moves === 16) {\n removeStar();\n starRating = 2;\n } else if (moves === 25) {\n removeStar();\n starRating = 1;\n }\n}", "function drawSmileyFace() {\n let op = document.getElementById(\"canvas5\").getContext(\"2d\");\n op.clearRect(0,0,1024,512);\n let radius;\n do {\n radius = Number(prompt(\"Radius\"));\n } while (isNaN(radius) || radius<1 || radius>250.5);\n op.beginPath();\n op.arc(radius+10, radius+10, radius, 0, Math.PI*2, true);\n op.moveTo(10+radius*.6, radius+10-radius/2);\n op.arc(radius+10-radius/2, radius+10-radius/2, radius*.1, 0, Math.PI*2, true);\n op.moveTo(10+radius*1.6, radius+10-radius/2);\n op.arc(radius+10+radius/2, radius+10-radius/2, radius*.1, 0, Math.PI*2, true);\n op.moveTo(10+radius*1.7, radius+10);\n op.arc(radius+10, radius+10, radius*.7, 0, Math.PI, false);\n op.stroke();\n op.closePath();\n}", "function updateGraphics() {\n\t\tupdateGraphicsHelper(false, false, false);\n\t}", "function update_interactiveness() {\n var interactive = document.getElementById('interactive').checked;\n// if (!(interactive)) { \n// eb.hide(); \n// } else {\n// eb.show();\n// }\n if (wt.instance.raw) { // && wt.filename) {\n var filename = wt.instance.filename;\n var path = wt.instance.path;\n var current_value = editor.getValue();\n var new_editor = set_data(null, current_value);\n new_editor.instance.filename = filename;\n new_editor.instance.path = path;\n }\n }", "function updateMagazine() {\n\tmagazineContainer.querySelector(\".magazine--text\").querySelector(\"#bullets\").innerHTML = `${\n\t\tmagazineSize - bulletsShot\n\t}`;\n\tmagazineContainer.querySelector(\".magazine--text\").querySelector(\"#magazine-size\").innerHTML = `${magazineSize}`;\n\n\tlet totalBulletIcons = 3;\n\tlet magazineRatio = floor(magazineSize / totalBulletIcons);\n\tlet iconBreakpointList = returnBreakpointArray(magazineRatio, totalBulletIcons);\n\tlet bulletsLeft = magazineSize - bulletsShot;\n\n\tif (bulletsLeft == iconBreakpointList[2]) changeOpacity([bulletIcons[2]], \"0.45\");\n\telse if (bulletsLeft <= iconBreakpointList[1]) {\n\t\treloadButton.style.background = \"var(--red)\";\n\t\treloadButton.innerHTML = \"reload\";\n\t\treloadButton.classList.remove(\"hide\");\n\t\tmagazineContainer.querySelector(\"#key-info\").classList.remove(\"hide\");\n\t\tchangeOpacity([bulletIcons[1], bulletIcons[2]], \"0.45\");\n\t} else if (bulletsLeft == iconBreakpointList[0]) changeOpacity([...bulletIcons], \"0.45\");\n\n\tfunction returnBreakpointArray(baseVal, n) {\n\t\tlet list = [];\n\t\tlet a = 0;\n\t\tfor (let i = 0; i < n; i++) {\n\t\t\tlist.push(a);\n\t\t\ta += baseVal;\n\t\t}\n\t\treturn list;\n\t}\n\n\tfunction changeOpacity(els, opacityValue) {\n\t\tfor (let i = 0; i < els.length; i++) {\n\t\t\tlet el = els[i];\n\t\t\tel.style.opacity = opacityValue;\n\t\t}\n\t}\n}", "function updateStats() {\n\t$(\"#stats\").text(JSON.stringify(ozpIwc.metrics.toJson(),null,2));\n}", "function onIncreaseFontSize() {\n increaseFontSize()\n let elFont = document.querySelector('.font-size-display')\n elFont.innerHTML = gMeme.currText.size\n draw()\n}", "function updateRating() {\n //Rating game based on move count\n if (numMoves == (moves_to_two_stars)) {\n stars[2].classList.remove(\"fa-star\");\n stars[2].classList.add(\"fa-star-o\");\n rating = 2;\n }\n else if (numMoves == (moves_to_one_star)) {\n stars[1].classList.remove(\"fa-star\");\n stars[1].classList.add(\"fa-star-o\");\n rating = 1;\n }\n}", "updateSize() {\n const _style = window.getComputedStyle(this.track);\n const inheritedFontSize = _style['font-size'];\n\n this.track.style.setProperty('--simple-switch_size', inheritedFontSize);\n }", "Update() {\n this.txt.setText(Math.round((this.size/this.maxSize)*100)+'%');\n }", "updateDisplayString() {\n this.displayString = 'Increase ' + this.name + ' by ' + this.value + ' ' + this.measuringUnit;\n }", "function updateScore(){\n $('#js-score').html(myGame.score);\n }", "function updateProficiencyBonus() {\n const level = document.querySelector('#level');\n const bonus = document.querySelector('#proficiency-bonus');\n if (!isNaN(level.value)) {\n const proficiencyBonus = 1 + Math.ceil((level.value) / 4);\n if (bonus.textContent !== '+' + proficiencyBonus) {\n bonus.textContent = '+' + proficiencyBonus;\n updateSavingThrows();\n updateSkillProficiencies();\n }\n }\n}", "function displayLoss() {\n $(\"#result-image\").attr(\"src\", \"https://media.giphy.com/media/ie76dJeem4xBDcf83e/giphy.gif\");\n $(\"#result-image\").attr(\"height\", \"250px\");\n $('#result').text(\"You Lose!!\");\n\n }", "function updateScore () {\n score++;\n $('.js-score').text(`${score} `);\n console.log(`updateScore ran and the score is ${score}`);\n}", "function updateStars() {\n if (moves > 10 && moves < 20) {\n starsList[4].setAttribute('class', 'fa fa-star-o');\n stars = 4;\n }\n if (moves >= 20 && moves < 30) {\n starsList[3].setAttribute('class', 'fa fa-star-o');\n stars = 3;\n }\n if (moves >= 30 && moves < 40) {\n starsList[2].setAttribute('class', 'fa fa-star-o');\n stars = 2;\n }\n if (moves >= 40) {\n starsList[1].setAttribute('class', 'fa fa-star-o');\n stars = 1;\n }\n }", "function PowerUpFireRate(ix, iy){\n\tthis.active = true;\n\n\tthis.hitboxWidth = 16;\n\tthis.hitboxHeight = 16;\n\n\tthis.height = 16;\n\tthis.width = 16;\n\n\tthis.x = ix;\n\tthis.y = iy;\n\n\tthis.spriteImage = new Image();\n\tthis.spriteImage.src = '../img/etank.gif';\n}", "function updateScore(increment){\n\t\tscore += increment;\n\t\tgameScoreDisplay.innerHTML = score;\n\t\tconsole.log(score);\n\t\tif (isHighScore){\n\t\t\thighScoreDisplay.innerHTML = score;\n\t\t}\n\t}", "refreshFontSize() {\n\t\tvar size = this.savedFontSize;\n\t\tsize = size * renko.getWindowScale();\n\t\tsize = size * (2 / window.devicePixelRatio);\n\t\tthis.style.fontSize = String(size) + \"px\";\n\t}", "updateSpeed (speed) {\n this.speed = speed;\n }", "function handleUpdate() {\n const suffix = this.dataset.sizing || ''; // const suffix gets the suffix for our CSS variables. These value is link to data-sizing in our HTML\n document.documentElement.style.setProperty(`--${this.name}`, this.value + suffix); //Sets the property to our element (--spacing, --blur), sets the value (10,20,) + and the suffix (px)\n}", "function updateIcon () {\n browser.browserAction.setIcon({\n path: currentBookmark\n ? {\n 19: '../public/star-filled-19.png',\n 38: '../public/star-filled-38.png'\n }\n : {\n 19: '../public/star-empty-19.png',\n 38: '../public/star-empty-38.png'\n },\n tabId: currentTab.id\n })\n browser.browserAction.setTitle({\n // Screen readers can see the title\n title: currentBookmark ? 'Unbookmark it!' : 'Bookmark it!',\n tabId: currentTab.id\n })\n}", "function updateStats() {\n $(\"#number-to-guess\").text(targetNumber);\n $(\"#user-score\").text(userScore);\n $(\"#wins\").text(wins);\n $(\"#losses\").text(losses);\n }", "updateExploreText(){\n console.log(this.isTome);\n if(this.board.isTome){\n return;\n }\n var text = \"\";\n if(this.board.game.gameData.gameMode == \"DOTS\"){\n text = \"path score: \" + this.hexesInPath.length + \" + \" + this.additionalHexes.size;\n\n }else{\n var loopModText = \"\";\n if(this.isLoop){\n if(this.hexesInPath.length>3){\n loopModText = \"+3\";\n }else{\n loopModText = \"+1\";\n }\n }\n var communityText = \"\";\n\n for(var i = 0; i<this.getNumDifferentInLoop(); i++){\n communityText+= \"+5\"\n }\n text = \"path score: \" + this.hexesInPath.length + loopModText + communityText;\n }\n\n this.board.exploreScoreText.setText(text);\n\n }", "function punch() {\n if (Player.health <= 0) {\n return;\n }\n Player.health -= 5 - (5 * Player.addMods());\n Player.damageMods();\n document.getElementById(\"armor-message\").innerText = \"\"\n //this is to keep the health bars current\n Player.hits++;\n update();\n}", "function changeUI() {\n //Show detected mood\n pageheader.innerHTML = \"You look like \" + age + \" years old. You feel like: \"; //Remember currentMood is a Mood object, which has a name and emoji linked to it. \n //Show mood emoji\n var img = $(\"#selected-img\")[0]; //getting a predefined area on our webpage to show the emoji\n img.src = recommendation.picture; //link that area to the emoji of our currentMood.\n img.style.display = \"block\"; //just some formating of the emoji's location\n //Display song refresh button\n refreshbtn.style.display = \"inline\";\n //Remove offset at the top\n pagecontainer.style.marginTop = \"20px\";\n}", "function updateScore() {\n $score.text(score);\n}", "update() {\n if (this.energy <= 0) {\n this.element.innerHTML = this.name + \" has run away because you don't know how to take care of anything.\";\n } else {\n this.energy--;\n this.report();\n this.element.innerHTML = this.name + \" has \" + this.energy + \" energy.\";\n }\n }", "function updateScore(){\r\n $('.score').text(`Score: ${score}`)\r\n}", "function changeGameSpeed() {\n if (gameSpeed != 5) {\n gameSpeed = gameSpeed + 1;\n } else {\n gameSpeed = 1;\n }\n document.getElementById(\"gamespeedbutton\").textContent = gameSpeed + \" Game Speed\";\n}", "function increaseFont() {\n\t\t\t\tif (localStorage.getItem(\"WatsonFontSize\") === null) {\t\t\t\t\t// this check isn't necessary (because I do it on page load), but I do it for safety\n\t\t\t\t\tlocalStorage.setItem(\"WatsonFontSize\", \"14\");\n\t\t\t\t\tcurFontSize = 14;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tcurFontSize = parseInt(localStorage.getItem(\"WatsonFontSize\"));\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tvar newFontSize = curFontSize + 1; // holds the new font size\t\t\t// now that we have the stored font, increase it\n\t\t\t\t$('.page-wrapper').css('font-size', newFontSize);\n\t\t\t\t\n\t\t\t\tlocalStorage.setItem(\"WatsonFontSize\", \"\" + newFontSize);\t\t\t\t// don't forget to save the new font size back to the data store\n\t\t\t}", "function updateTimer() {\n\t\t\tvar timeString = formatTime(currentTime);\n\t\t\t$stopwatch.html(timeString);\n\t\t\tcurrentTime += incrementTime;\n\t\t}", "update() {\n let pos = CosmoScout.state.pointerPosition;\n if (pos !== undefined) {\n this._pointerContainer.innerText =\n `${CosmoScout.utils.formatLongitude(pos[0]) + CosmoScout.utils.formatLatitude(pos[1])}(${\n CosmoScout.utils.formatHeight(pos[2])})`;\n } else {\n this._pointerContainer.innerText = ' - ';\n }\n\n pos = CosmoScout.state.observerLngLatHeight;\n if (pos !== undefined) {\n this._userContainer.innerText =\n `${CosmoScout.utils.formatLongitude(pos[0]) + CosmoScout.utils.formatLatitude(pos[1])}(${\n CosmoScout.utils.formatHeight(pos[2])})`;\n } else {\n this._userContainer.innerText = ' - ';\n }\n\n if (CosmoScout.state.observerSpeed !== undefined) {\n this._speedContainer.innerText = CosmoScout.utils.formatSpeed(CosmoScout.state.observerSpeed);\n }\n }", "function strikePower (){\n strike += 1;\n updatePower(strike);\n}", "function updateScreen() {\n var ctx = hangmanGame.canvas.getContext(\"2d\");\n ctx.font = \"50px Rock Salt\";\n ctx.fillStyle = fontColor;\n\n ctx.textAlign = \"center\";\n ctx.fillText(`${hangmanGame.wordStatus.join(\" \")}`, hangmanGame.canvas.width / 2, 400);\n\n if (hangmanGame.guessedLetters.length !== 0) {\n ctx.font = \"30px Rock Salt\";\n ctx.textAlign = \"start\";\n ctx.fillText(`${hangmanGame.guessedLetters.join(\" \")}`, 30, 470);\n }\n\n ctx.font = \"75px Rock Salt\";\n ctx.textAlign = \"center\";\n ctx.fillText(`${hangmanGame.guesses}`, 400, 300);\n ctx.font = \"20px Rock Salt\";\n ctx.fillText(\"guesses remaining\", 400, 350);\n}", "function refreshUserScore() {\n\t\t$(\"#userScore\").text(userScore);\n\t}", "function updateUI(){\n\t\n\t$('elapsed').innerText = timeElapsed();\n\t$('timer').innerText = countdown;\n\t$('shots').innerText = min_elapsed;\n\t$('bottles').innerText = toBottles(min_elapsed);\n\t$('ml').innerText = toMl(min_elapsed);\n\t$('oz').innerText = toOz(min_elapsed);\n\tif(paused){\n\t\t$('status').innerText = 'Play!';\n\t\t$('status').setStyle('color', '#'+Math.floor(Math.random()*16777215).toString(16));\n\t}\n\telse{\n\t\t$('status').innerText = 'Pause.';\n\t}\n\t$('interval').innerText = 'Game interval is ' + interval + ' seconds. Click to change.';\n}", "function updateIcon() {\n browser.browserAction.setIcon({\n path: currentBookmark ? {\n 19: \"icons/star-filled-19.png\",\n 38: \"icons/star-filled-38.png\"\n } : {\n 19: \"icons/star-empty-19.png\",\n 38: \"icons/star-empty-38.png\"\n } \n });\n browser.browserAction.setTitle({\n // Screen readers can see the title\n title: currentBookmark ? 'Acceptable' : 'Not Acceptable'\n }); \n}", "function statUpdateTick() {\n updateCurrentStats();\n }", "function updateScore() {\r\n shots--;\r\n trackCorrect ++;\r\n $('.shots').text(shots);\r\n}", "function updateCacheAndActive(size){\n dataCacheLocalStorage.put(fontSizeCacheKey, size);\n setActive($element, size, bodyElement);\n }", "function updateHeroHP() {\n\theroStats.hp = (heroStats.hp - defenderStats.cap);\n\t$(`#${heroID}-hp`).html(heroStats.hp);\n}", "function updateSlow(distance){\n //calculate minutes and seconds from the milliseconds\n let seconds = Math.floor((distance % (1000 * 60)) / 1000);\n let minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));\n\n //edit label text\n slowLabel.text = `Slow: ${minutes}:${seconds}`;\n}", "update() {\n //Apply changes\n super.update()\n //Execute action\n if (this.action in this) {\n this[this.action]()\n this.output.idle = 0\n }\n\n //Update animation speed\n if (this.alive) {\n this.sprite.animationSpeed = Entity.ANIMATION_SPEED * this.adaptability\n }\n //Sudden death\n if ((this.sudden_death)||(this.hp <= 0)) {\n this.die()\n }\n }", "function updateScreen() {\n _currSec = truncAtTwo(_currSec + _secPerRow);\n _progress = getProgress();\n updateProgress();\n drawCanvas();\n checkIfCompleted();\n }", "function UpdateScore() {\r\n recentScore.push(math.round(currentScore));\r\n recentScore.shift();\r\n var screenRecentScore = recentScore.join('&nbsp;&nbsp;&nbsp;&nbsp;'); \r\n if (feedbackVisible) {\r\n $('#recent-score').html(screenRecentScore);\r\n $('#current-score').html(math.round(currentScore));\r\n }\r\n else {\r\n $('#recent-score').html('N/A');\r\n $('#current-score').html('N/A');\r\n }\r\n cpaLine.map(function (element) {\r\n element.visible = true; \r\n return element\r\n })\r\n cpaCircle.map(function (element) {\r\n element.visible = true;\r\n return element\r\n }) \r\n $('#play-conflict-btn').prop('disabled', false);\r\n $('#play-resolution-btn').prop('disabled', false); \r\n}" ]
[ "0.6357531", "0.6007764", "0.58803296", "0.58789414", "0.5813852", "0.5813852", "0.5776564", "0.5775895", "0.57672244", "0.5700112", "0.56986904", "0.56731766", "0.56420135", "0.5633069", "0.5606887", "0.55965483", "0.5571476", "0.5565529", "0.55529016", "0.5541287", "0.5539472", "0.5529085", "0.55222493", "0.5519005", "0.5491551", "0.54904914", "0.5477656", "0.54747933", "0.54702455", "0.5465039", "0.54566085", "0.5452763", "0.5435912", "0.54301137", "0.54259306", "0.54212797", "0.54152626", "0.5409584", "0.54093623", "0.5395798", "0.5394369", "0.53919697", "0.53912723", "0.5387126", "0.5383761", "0.53802097", "0.53767806", "0.53711116", "0.5369646", "0.5366484", "0.53647727", "0.53641707", "0.5361632", "0.53561115", "0.5334737", "0.53294516", "0.53273547", "0.5326459", "0.5310895", "0.53093594", "0.5309284", "0.53063416", "0.53055483", "0.5300705", "0.530064", "0.529618", "0.52955735", "0.529453", "0.52899104", "0.5287028", "0.5280808", "0.5275972", "0.52727735", "0.52626425", "0.526123", "0.5254113", "0.5252929", "0.52482146", "0.52475065", "0.5241967", "0.524184", "0.5233581", "0.52262276", "0.5225332", "0.52158535", "0.52084905", "0.5206526", "0.5201164", "0.5197726", "0.51930076", "0.5191657", "0.51882356", "0.51868695", "0.51867294", "0.5184433", "0.51803786", "0.5172898", "0.51712525", "0.51702905", "0.5169077" ]
0.78108287
0
Clear the tooltips in the result pane.
function clearResultTooltips() { my.html.speed.title = '' my.html.error.title = '' }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function clear_tooltip() {\n\t$(\"#tooltip_container\").empty()\n\t$(\"#tooltip_container\").hide()\n}", "function hideTooltips() {\n\t\t\t\t\ttooltipObject.remove();\n\t\t\t\t}", "removeAllTooltips() {\n if (!this.activeToolTips?.length) {\n return;\n }\n for (let i = this.activeToolTips.length - 1; i > -1; i--) {\n this.activeToolTips[i].destroy();\n this.activeToolTips.splice(i, 1);\n }\n }", "clearTip() {\n if (this.tip) {\n this.tip.remove();\n }\n }", "function removeTooltips() {\r\n\t$('.tooltip').remove();\r\n}", "remove() { this.tooltip.remove(); this.element.remove(); }", "function hideToolTip(d, i) {\n tooltip.style({\n \"height\": 0,\n \"width\": 0,\n \"opacity\": 0\n }).html(\"\");\n }", "function hideTooltips() {\n\t\tif (tooltips_element) {\n\t\t\ttooltips_element.style.display = 'none';\n\t\t}\n\t}", "clearOptions(){\n let element = p5Instance.select(`#div_${this.id}`);\n if(element){\n element.remove();\n this.command.context.chain.strokeWeight(1);\n }\n\n //clear tips div\n let tipDiv = document.getElementById(`tip_${this.id}`);\n if(tipDiv){\n tipDiv.remove();\n }\n }", "function removeTooltip() {\t\t\t\r\n\t\t\t$('.popover').each(function() { $(this).remove(); });\r\n\t\t\treturn;\r\n\r\n\t\t}//end function removeTooltip ", "function clearMarkers() {\r\n\t\t\tif (_markers && _markers.length > 0) {\r\n\t\t\t\tfor (var i = 0; i < _markers.length; i++) {\r\n\t\t\t\t\tvar currMarker = _markers[i];\r\n\t\t\t\t\tcurrMarker.tooltip = null;\r\n\t\t\t\t\tcurrMarker.setMap(null);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\t_markers = [];\r\n\r\n\t\t} // clearMarkers", "reset () {\n this.displayPlot(null)\n this.displayStatistics(null, null)\n this.displayLog(null)\n this.displayError(null)\n this.results = new Map()\n }", "function clearResults() {\n selectedPoints = [];\n Map.layers().remove(Map.layers().get(2));\n var instructionsLabel = ui.Label('Select regions to compare population.');\n resultsPanel.widgets().reset([instructionsLabel]);\n}", "function quitarToolTipASelects() {\n $('.categoria_id, .talle_id, .proveedor_id, .genero').tooltip({\n disabled: true\n });\n }", "function reset() {\n $('#locator-loader').show();\n $('.sidebar-js-button').removeClass('active');\n $('.result-body').hide();\n $('.legend-inner-container').hide();\n $('.legend-body').html('');\n $('#result-list').html('');\n $('.result-dropdown select').html('');\n }", "function removeElements() {\n d3.selectAll('.svg-tooltip').remove();\n d3.selectAll('.y-axis').remove();\n d3.selectAll('.tooltip-container').remove();\n d3.selectAll('.title-container').remove();\n console.log('removed elements');\n }", "function clear() {\n contentVeil.reset();\n contentVeil.hide();\n removePreviewLegend();\n unwrapInterestingRange();\n }", "function removeTocTooltip(){\r\n $(\"#wh_publication_toc>.wh-tooltip-wrapper\").remove();\r\n }", "clear() {\n Array.prototype.forEach.call(this._el, function(profile) {\n profile.innerHTML = '';\n });\n }", "destroy() {\n //removing all qtip from DOM\n $('[id^=\"qtip\"]').remove();\n }", "function removeTooltip() {\n //Hide the tooltip\n $('.popover').each(function() {\n $(this).remove();\n }); \n}//function removeTooltip", "function removeToolTip() {\n preventTooltipHiding = !preventTooltipHiding;\n if (!preventTooltipHiding) {\n if (toolTipText == \"\") {\n hideToolTip();\n } else {\n showToolTip(toolTipText);\n preventTooltipHiding = !preventTooltipHiding;\n }\n }\n}", "function removeTooltip() { \n element.removeAttribute( ariaDescribedBy )\n ops.container.removeChild( tooltip )\n timer = null\n }", "function clearTip() {\n amount.value = \"\";\n percentage.value = \"\";\n numPeople.value = \"\"\n output.textContent = \"\";\n}", "function hideTooltip() {\n tt.style('opacity', 0.0);\n }", "function hide() {\n if (tooltip) {\n tooltip.parentNode.removeChild(tooltip);\n tooltip = null;\n }\n }", "function hideTooltip() {\n tt.style('opacity', 0.0);\n }", "function hideTooltip() {\n tt.style('opacity', 0.0);\n }", "function hideTooltip() {\n tt.style('opacity', 0.0);\n }", "function hideTooltip() {\n tt.style('opacity', 0.0);\n }", "reset() {\n this.hideContent();\n this.hideChart();\n this.selectVars.html('');\n this.selectTarget.html('');\n this.chartField.xSelect.html('');\n this.chartField.ySelect.html('');\n this.chartField.tSelect.html('');\n this.notesInput.val('');\n }", "destroy() {\n // Remove this instance from the list of tooltips\n const tooltipIndex = tooltipsList.indexOf( this );\n if ( tooltipIndex > -1 ) {\n tooltipsList.splice( tooltipIndex, 1 );\n // TODO: + Unbind all events\n }\n\n if ( tooltipsList.length === 0 ) removeTooltipElement();\n }", "function resetTip(){\r\n document.getElementById(\"single\").style.display = \"none\";\r\n document.getElementById(\"multiple\").style.display = \"none\";\r\n\r\n}", "function hideD3Tooltips() {\n $('.d3-tip').css({opacity: 0});\n }", "function hideTooltip() {\n tooltip.style(\"display\",\"none\");\n}", "function updateTooltips() {\n jQuery('.tooltip').tooltip({showURL: false });\n}", "function hideTooltip() {\n\t tooltip.style(\"display\",\"none\");\n\t}", "function clearResults() {\n\t$('.results').text('');\n}", "function hideAllTooltips() {\r\n let tooltips = document.getElementsByClassName('tooltip');\r\n\r\n if (tooltips != undefined) {\r\n for (let tooltip of tooltips) {\r\n hide(tooltip);\r\n }\r\n }\r\n}", "function resetHelps() {\n $(\".helpbox\").text(\"\");\n $(\".alt\").show();\n }", "function deactivate_tooltips() {\n clear_boxes();\n clearInterval(refreshID);\n controlsParent.appendChild(videoControls);\n}", "function HideToolTip (){\ntooltip\n .style(\"opacity\",0);\n}", "clearSummary() {\n var $this = this,\n mdl = $this._container;\n mdl.querySelectorAll('.venti-summary')[0].innerHTML = \"\";\n }", "function _clear() {\n\t\t// title\n\t\t$( \".panel-head\", $( \"#node\" , _sandbox.context ) ).text( \"Node\" );\n\t\t// body\n\t\t$( \"#node > section\", _sandbox.context ).html( \"<h2 class='prop-title nodes-blank'>Select a node to see its properties.</h2>\" );\n\t}", "function clearDisplay() {\n hideContainers();\n resetCopyNotes();\n resetClipboardNote();\n }", "function hideTooltip() {\n tooltip.style('opacity', 0.0);\n }", "function clearResults() {\n\t\t// Re-display loading icons\n\t\tdocument.getElementById(\"loadingmeaning\").style.display = \"inline\";\n\t\tdocument.getElementById(\"loadinggraph\").style.display = \"inline\";\n\t\tdocument.getElementById(\"loadingcelebs\").style.display = \"inline\";\n\t\t\n\t\t// Clear old results\n\t\tdocument.getElementById(\"meaning\").innerHTML = \"\";\n\t\tdocument.getElementById(\"graph\").innerHTML = \"\";\n\t\tdocument.getElementById(\"celebs\").innerHTML = \"\";\n\t\t\n\t\t// Hide \"no results\" error message\n\t\tdocument.getElementById(\"norankdata\").style.display = \"none\";\n\t}", "function reset(){\n $('#selection-area').empty();\n $('#species-info').empty().css('background-color', panelColor);\n $('#last-dropdown-area').empty();\n $('.counties').css('fill', mapColor);\n $('.labels').css('fill', panelColor);\n }", "function clearPopovers ($popover) {\n $(clearSelector).not($popover).popover('hide');\n }", "function ClearMessagePane() {}", "function clear() {\r\n\t\tcontentVeil.reset();\r\n\t\tcontentVeil.hide();\r\n\t\thideUrlElement();\r\n\t}", "clearAll() {\r\n \r\n // reset sample data\r\n this.sampleData = [];\r\n\r\n // reset distribution paramters\r\n this.mu = null;\r\n this.sigma = null;\r\n\r\n // update the plots\r\n this.ecdfChart.updatePlot([], []);\r\n this.histChart.updateChart([])\r\n \r\n }", "function clearResult() {\n $(\"#resultEl\").html(\"\");\n }", "function hideTooltip() {\n $(\"#tooltip\").remove();\n}", "function clearResults() {\r\n const clearResults = document.getElementsByClassName(\"show\");\r\n for (let i = clearResults.length - 1; i >= 0; i--) {\r\n clearResults[i].remove();\r\n }\r\n}", "function allClear() {\n var p_elements = document.getElementsByClassName('output-style');\n while (p_elements.length > 0) {\n p_elements[0].parentNode.removeChild(p_elements[0]);\n }\n\n var p_canvas = document.getElementsByClassName('p5Canvas');\n while(p_canvas.length > 0) {\n p_canvas[0].parentNode.removeChild(p_canvas[0]);\n }\n}", "function hideGraphToolTip()\n\t{\n\t\td3.select(\"#graphToolTip\")\n \t.style(\"display\", \"none\")\n\t}", "function removeTooltipFromDom() {\n\t\tif(tooltip.parentNode) {\n\t\t\ttooltip.parentNode.removeChild(tooltip);\n\t\t}\n\t}", "function updateTooltip() {\n d3.selectAll('.mouse-per-line')\n .remove();\n }", "function clearit() { \n jun.map.setFilter(\"points\", null)\n $('#region_select').multipleSelect(\"checkAll\");\n $('#Version_select').multipleSelect(\"checkAll\"); \n jun.map.flyTo({center : [jun.default_center_first, jun.default_center_second], zoom:1.1})\n \n $('.typeahead').typeahead('val', '')\n unfiltered_list_creator()\n\n document.getElementById(\"results_num\").innerText = Site_search.length\n document.getElementById('third_bar').click();\n}", "function clearDisplay() {\n rmNodes(document.getElementById('wolframAlphaResponses'));\n rmNodes(document.getElementById('progressDisplay'));\n}", "function clear() {\n $('#result-add').text(\"\");\n $('#result-mult').text(\"\");\n }", "removeMeasureTooltip_() {\n if (this.measureTooltipElement_ !== null) {\n this.measureTooltipElement_.parentNode.removeChild(\n this.measureTooltipElement_);\n this.measureTooltipElement_ = null;\n this.measureTooltip_ = null;\n }\n }", "resetView() {\n let result = document.querySelector(\".result\");\n result.classList.remove(\"result-active\");\n let cells = document.querySelectorAll(\".cross-circle\");\n for (let i = 0; i < cells.length; i++) {\n cells[i].remove();\n }\n }", "function resetInfoPaneDisplay() {\n gees.dom.setClass('poly_button', '');\n gees.dom.setClass('hand_button', 'clicked_button');\n gees.dom.setClass('CutButtonBlue', 'button blue');\n}", "function showTooltips(evt) {\n\t\tif (tooltips_element) {\n\t\t\ttooltips_element.style.display = '';\n\t\t}\n\t}", "function clearOptions(){\n view = tabsFrame.newView;\n var index = view.tableGroups.length - tabsFrame.selectedTableGroup - 1;\n var emptyArray = new Array();\n var curTgrp = view.tableGroups[index];\n \n resetChartOptions();\n if(curTgrp.hasOwnProperty('numberOfColumns')){\n \tdelete curTgrp.numberOfColumns;\n }\n\t \n curTgrp.title = getMessage('panelTitle');\n view.chartProperties = emptyArray;\n view.paginatedProperties = emptyArray;\n curTgrp.paginatedPanelProperties = new Object();\n view.tableGroups[index].measures = emptyArray;\n \n \n curTgrp = resetColumnReportOptions(curTgrp);\n createColumnReportSummaryTable(view, index);\n \n // clear action properties\n view.actionProperties[index] = new Object();\n \t\n\t$('logoImageFile').value = 'archibus-logo.gif';\n\ttabsFrame.newView = view;\n myTabsFrame.selectTab('page4f');\n}", "function titleClear(){\n document.querySelector(\".title\").style.display = \"none\";\n document.querySelector(\".line\").style.display = \"none\";\n document.querySelector(\".intro\").style.display = \"none\";\n document.querySelector(\".start\").style.display = \"none\";\n }", "function clear_boxes() {\n for (var tt of tooltips) { tt.remove(); tooltips.delete(tt); }\n for (var box of boxes) { box.remove(); boxes.delete(box); }\n while (vgvContainer.lastChild) { vgvContainer.remove(vgvContainer.lastChild); }\n}", "function clearAll() {\n typeaheads.origin.setValue('');\n typeaheads.destination.setValue('');\n $(options.selectors.origin).removeClass(options.selectors.errorClass);\n $(options.selectors.destination).removeClass(options.selectors.errorClass);\n $(options.selectors.alert).remove();\n }", "function clearChart() {\n\tfor(var i = 0; i < 3; i++) {\n\t\tchart.data.datasets[i].data = []\n\t\tchart.data.datasets[i].label = ''\n\t}\n\tchart.data.labels = []\n\tdocument.getElementById('message').innerHTML = ''\n\tchart.options.scales.yAxes[0].scaleLabel.labelString = ''\n\tchart.options.scales.yAxes[1].scaleLabel.labelString = ''\n\tdocument.getElementById('chartSelect').selectedIndex = 0\n\tdocument.getElementById('studySelect').selectedIndex = 0\n\tdocument.getElementById('compareSelect').selectedIndex = 0\n}", "function clearSearchesVisualization(){\n g.selectAll('*').remove();\n }", "function unannotateToolbarIcon() {\n $(\".toolbar-icon-tooltip\").remove();\n}", "function clearPreds() {\n let predImage = document.querySelector('.pred-image');\n let labelInfo = document.querySelector('.label-description');\n let slider = document.querySelector('.slider');\n slider.removeChild(predImage);\n slider.removeChild(labelInfo);\n document.querySelector('#get-predictions').style.display = 'block';\n document.querySelector('#clear-predictions').style.display = 'none';\n allSlides[current].style.display = 'block';\n}", "function resetData(){\n $(\".info-display\").each(function(){\n $(this).text(\"\");\n })\n}", "function HideTooltip() {\n var divElement = $(\"#toolTipScene\");\n if (divElement) {\n divElement.css({\n display: \"none\"\n });\n }\n }", "function tooltipOut(span) {\r\n\tspan.style.display = \"none\";\r\n}", "function clearMap() {\n\t\n\t// Junk data \n\tdata = google.visualization.arrayToDataTable([\n\t\t['Place', 'Searches'],\n\t\t['', 0]\n\t]);\n\t\n\t// Remove the selected topic on the right sidebar\n\t$(\".topItem\").removeClass('active');\n\t\n\t// Remove the current query\n\tcurrentQ = '';\n\t\n\t// Redraw the now empty chart\n\tchart.draw(data, defaultOptions);\n}", "function clearPieCharts() {\n\t$(\"#pies\").children().remove();\n\t$(\"#text text:last\").remove();\n}", "function reset () {\n svl.ui.popUpMessage.holder.css({ width: '', height: '' });\n svl.ui.popUpMessage.box.css({\n background: 'rgba(69,183,214,1)',\n border: '3px solid rgba(255,255,255,1)',\n color: 'white',\n left: '',\n top: '',\n width: '',\n height: '',\n zIndex: ''\n });\n\n svl.ui.popUpMessage.box.css('padding-bottom', '')\n setTitle('');\n setMessage('');\n\n for (var i = 0; i < buttons.length; i++ ){\n try {\n buttons[i].remove();\n } catch (e) {\n console.warning(\"Button does not exist.\", e);\n }\n }\n buttons = [];\n return this;\n }", "function hideTooltip() {\n if (angular.isUndefined(_tooltip)) {\n return;\n }\n\n $timeout.cancel(_hoverTimeout);\n\n _tooltip.remove();\n _tooltip = undefined;\n }", "function deActivate() { \n\tdocument.getElementById('ToolTip').style.display = \"none\"; \n}", "function resetSearchResult() {\r\n $('.show-results p.risultati').addClass('hidden');\r\n\r\n $('.movies .results-number').text('');\r\n $('.show-results .container.movies-results').html('');\r\n\r\n $('.tv-series .results-number').text('');\r\n $('.show-results .container.tv-series-results').html('');\r\n\r\n}", "reset() {\n this.dataset = [];\n this.svg.selectAll(\"circle\").remove();\n this.svg.selectAll(\"g\").remove();\n $(\"#metrics\").removeClass(\"visible\").addClass(\"invisible\");\n }", "function clearOutput() {\n outputDiv.hide().children().remove();\n outputDivOpen = false;\n }", "function setResultTooltips()\n {\n var textLength = my.current.subunitText.length\n var charNoun = textLength == 1 ? 'character' : 'characters'\n\n // Speed tooltip\n my.html.speed.title =\n 'You have typed ' + textLength + ' ' + charNoun +\n ' in\\n' +\n Util.prettyTime(my.current.timeElapsed) + '.\\n\\n' +\n 'Your typing speed is\\n' +\n my.current.wpm + ' words per minute, or\\n' +\n my.current.cpm + ' characters per minute.'\n\n\n // Error rate tooltip\n var errorRateTooltip\n var accuracyTooltip\n\n // Update error rate\n if (my.current.errorRate == Number.POSITIVE_INFINITY) {\n errorRateTooltip = '\\u221e'\n accuracyTooltip = 0\n } else {\n errorRateTooltip = parseFloat(my.current.errorRate.toFixed(1))\n accuracyTooltip = 100 - errorRateTooltip\n }\n\n var errorNoun = my.current.errors == 1 ? 'error' : 'errors'\n\n var title =\n 'You have typed ' + textLength + ' ' + charNoun +\n '.\\n' +\n 'You have made ' + my.current.errors + ' ' +\n errorNoun + '.\\n' +\n 'Your error rate is ' + errorRateTooltip + '%.\\n' +\n 'Your accuracy is ' + accuracyTooltip + '%.\\n'\n\n my.html.error.title = title\n }", "function setTooltips()\r\n{\r\n $(function()\r\n {\r\n if ($(\".tooltip\").length > 0)\r\n {\r\n $(\".tooltip\").tooltip({showURL: false});\r\n }\r\n });\r\n}", "function reset() {\n\t\tmarkers.reset();\n\t}", "function clearHint(){\n\tpulsating.forEach(function(cell){\n\t\tcell.classList.remove(\"pulsate\");\n\t});\n\tpulsating = [];\n}", "function displayReset() {\n\t\tremoveChildren();\n\t\tresultScnTitle.textContent = '';\n\t\ttitle.textContent = 'Scientific Taxonomy for Mammals of the World'; // why does this work?? why do we n ot need to remove child node to lose the unicorn?\n\t\twhile (resultScnList.firstChild) {\n\t\t\tresultScnList.removeChild(resultScnList.firstChild); // refreshes tracklist for repeadted searches\n\t\t}\n\t}", "function clearAll(forced) {\r\n setAlertVisible(\"normal-bmi-output\", SUCCESS_CLASS, false);\r\n setAlertVisible(\"warning-bmi-output\", WARNING_CLASS, false);\r\n setAlertVisible(\"error-bmi-output\", ERROR_CLASS, false);\r\n}", "function resetAll() {\n\t\thideGraphs();\n\t\tmyTimer = setInterval(resetHideWait, 100);\n\t}", "function clearMessages() {\n titleList.innerHTML = '';\n }", "function reset() {\n\t\tself.media.hide().empty();\n\t\tself.win.attr('class', 'el-finder-ql').css('z-index', self.fm.zIndex);\n\t\tself.title.empty();\n\t\tself.ico.attr('style', '').show();\n\t\tself.add.hide().empty();\n\t\tself._hash = '';\n\t}", "static clearTools() {\n\t\tdocument.getElementById(Page.pageToolsID).innerHTML = \"\";\n\t}", "function removePlots() {\n d3.selectAll(\".nodes\").remove();\n d3.selectAll(\".link\").remove();\n d3.selectAll(\".axis-label\").remove();\n }", "function clearResults() {\n document.getElementById(\"results\").innerHTML = \"\";\n}", "function HideToolTip(ele) {\n $(ele).tooltip('hide');\n}", "function HideToolTip(ele) {\n $(ele).tooltip('hide');\n}", "function _clearAllStyles() {\n\n $(\"ul.fed-footer-left-ul-collapsible\").show('fast');\n $('footer .footer-left .footer-left-inner .title').removeClass('hovered');\n $('footer .footer-left .footer-left-inner .title').addClass('un-hovered');\n }" ]
[ "0.72888374", "0.7272986", "0.71922415", "0.70528156", "0.7044061", "0.6836587", "0.6780974", "0.6755042", "0.67468494", "0.6684047", "0.6585681", "0.65823495", "0.6580139", "0.6493192", "0.6448353", "0.6445565", "0.6445071", "0.6443478", "0.64297915", "0.6418842", "0.6394975", "0.6381378", "0.6372761", "0.6366909", "0.6342811", "0.63369536", "0.63352585", "0.63048494", "0.63048494", "0.63048494", "0.6304612", "0.6280898", "0.6279821", "0.62509257", "0.62348783", "0.6232232", "0.6227217", "0.6191587", "0.61884135", "0.61653894", "0.6148282", "0.613593", "0.61314785", "0.61144984", "0.61069864", "0.6099276", "0.60931325", "0.60630214", "0.60533446", "0.6053042", "0.60228044", "0.5994068", "0.5986958", "0.5983588", "0.59818393", "0.59814394", "0.5962959", "0.5956895", "0.59544635", "0.5951976", "0.5937429", "0.59263545", "0.59247524", "0.5924712", "0.59063137", "0.5900766", "0.5899445", "0.5896774", "0.5878653", "0.58774275", "0.5868494", "0.58677185", "0.5837937", "0.58276343", "0.58254385", "0.58254075", "0.5825351", "0.5824178", "0.5816751", "0.58152884", "0.5801125", "0.579742", "0.5797396", "0.579707", "0.5794103", "0.5793973", "0.5784158", "0.5779994", "0.5772926", "0.5772333", "0.57704604", "0.57689923", "0.5766421", "0.5764326", "0.5761928", "0.57601607", "0.5759915", "0.5752332", "0.5752332", "0.57516354" ]
0.8378526
0
Set the tooltips in the result pane.
function setResultTooltips() { var textLength = my.current.subunitText.length var charNoun = textLength == 1 ? 'character' : 'characters' // Speed tooltip my.html.speed.title = 'You have typed ' + textLength + ' ' + charNoun + ' in\n' + Util.prettyTime(my.current.timeElapsed) + '.\n\n' + 'Your typing speed is\n' + my.current.wpm + ' words per minute, or\n' + my.current.cpm + ' characters per minute.' // Error rate tooltip var errorRateTooltip var accuracyTooltip // Update error rate if (my.current.errorRate == Number.POSITIVE_INFINITY) { errorRateTooltip = '\u221e' accuracyTooltip = 0 } else { errorRateTooltip = parseFloat(my.current.errorRate.toFixed(1)) accuracyTooltip = 100 - errorRateTooltip } var errorNoun = my.current.errors == 1 ? 'error' : 'errors' var title = 'You have typed ' + textLength + ' ' + charNoun + '.\n' + 'You have made ' + my.current.errors + ' ' + errorNoun + '.\n' + 'Your error rate is ' + errorRateTooltip + '%.\n' + 'Your accuracy is ' + accuracyTooltip + '%.\n' my.html.error.title = title }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "_addTooltips() {\n $(this.el.querySelectorAll('[title]')).tooltip({\n delay: { show: 500, hide: 0 }\n });\n }", "set tooltip(value) {}", "function initializeTooltips() {\n // Download document link\n $('.download-document').tooltip({\n 'show': true,\n 'placement': 'top',\n 'title': \"Download the document\"\n });\n\n // Delete document link\n $('.delete-document').tooltip({\n 'show': true,\n 'placement': 'top',\n 'title': \"Delete the document\"\n });\n\n // Upload document link\n $('.upload-document').tooltip({\n 'show': true,\n 'placement': 'top',\n 'title': \"Upload document\"\n });\n\n // Create new folder link\n $('.create-folder').tooltip({\n 'show': true,\n 'placement': 'top',\n 'title': \"Create new folder\"\n });\n}", "function setupTooltips() {\n var elements = getAllElementsWithAttribute(\"tooltip\");\n elements.forEach(function(element) {\n attachTooltip(element);\n });\n}", "function clearResultTooltips()\n {\n my.html.speed.title = ''\n my.html.error.title = ''\n }", "function updateTooltips() {\n jQuery('.tooltip').tooltip({showURL: false });\n}", "set Tooltip(value) {\n this._tooltip = value;\n }", "function tooltips() {\n removeTooltips();\n\n // Tooltips are added with options.tooltips in original order.\n scope_Tooltips = scope_Handles.map(addTooltip);\n\n bindEvent(\"update.tooltips\", function(values, handleNumber, unencoded) {\n if (!scope_Tooltips[handleNumber]) {\n return;\n }\n\n var formattedValue = values[handleNumber];\n\n if (options.tooltips[handleNumber] !== true) {\n formattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n }\n\n scope_Tooltips[handleNumber].innerHTML = formattedValue;\n });\n }", "function tooltips() {\n removeTooltips();\n\n // Tooltips are added with options.tooltips in original order.\n scope_Tooltips = scope_Handles.map(addTooltip);\n\n bindEvent(\"update.tooltips\", function(values, handleNumber, unencoded) {\n if (!scope_Tooltips[handleNumber]) {\n return;\n }\n\n var formattedValue = values[handleNumber];\n\n if (options.tooltips[handleNumber] !== true) {\n formattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n }\n\n scope_Tooltips[handleNumber].innerHTML = formattedValue;\n });\n }", "function tooltips() {\n removeTooltips();\n\n // Tooltips are added with options.tooltips in original order.\n scope_Tooltips = scope_Handles.map(addTooltip);\n\n bindEvent(\"update.tooltips\", function(values, handleNumber, unencoded) {\n if (!scope_Tooltips[handleNumber]) {\n return;\n }\n\n var formattedValue = values[handleNumber];\n\n if (options.tooltips[handleNumber] !== true) {\n formattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n }\n\n scope_Tooltips[handleNumber].innerHTML = formattedValue;\n });\n }", "function tooltips() {\n removeTooltips();\n\n // Tooltips are added with options.tooltips in original order.\n scope_Tooltips = scope_Handles.map(addTooltip);\n\n bindEvent(\"update.tooltips\", function(values, handleNumber, unencoded) {\n if (!scope_Tooltips[handleNumber]) {\n return;\n }\n\n var formattedValue = values[handleNumber];\n\n if (options.tooltips[handleNumber] !== true) {\n formattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n }\n\n scope_Tooltips[handleNumber].innerHTML = formattedValue;\n });\n }", "function initInstanceInfoTooltip() {\n jQuery('#instance-tooltip').tooltip();\n}", "function init() {\n setUpToolTip();\n}", "function setTooltips()\r\n{\r\n $(function()\r\n {\r\n if ($(\".tooltip\").length > 0)\r\n {\r\n $(\".tooltip\").tooltip({showURL: false});\r\n }\r\n });\r\n}", "function setupBootstrapTooltips() {\n\t$('[data-toggle=\"tooltip\"], .conceptPoint, #recommendSection .panel-heading, .btn-info').tooltip({\n\t\tcontainer: 'body',\n\t\thtml: true\n\t});\n}", "function tooltips() {\n removeTooltips();\n // Tooltips are added with options.tooltips in original order.\n scope_Tooltips = scope_Handles.map(addTooltip);\n bindEvent(\"update\" + INTERNAL_EVENT_NS.tooltips, function (values, handleNumber, unencoded) {\n if (!scope_Tooltips || !options.tooltips) {\n return;\n }\n if (scope_Tooltips[handleNumber] === false) {\n return;\n }\n var formattedValue = values[handleNumber];\n if (options.tooltips[handleNumber] !== true) {\n formattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n }\n scope_Tooltips[handleNumber].innerHTML = formattedValue;\n });\n }", "function tooltips() {\n\n // Tooltips are added with options.tooltips in original order.\n var tips = scope_Handles.map(addTooltip);\n\n bindEvent('update', function (values, handleNumber, unencoded) {\n\n if (!tips[handleNumber]) {\n return;\n }\n\n var formattedValue = values[handleNumber];\n\n if (options.tooltips[handleNumber] !== true) {\n formattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n }\n\n tips[handleNumber].innerHTML = formattedValue;\n });\n }", "function loadTooltips() {\n $('.hover-tooltip').tooltip({\n title: hoverGetData,\n html: true,\n container: 'body',\n placement: 'left',\n delay: {\n \"show\": 100,\n \"hide\": 1500\n }\n });\n}", "function tooltips ( ) {\r\n\r\n\t\t// Tooltips are added with options.tooltips in original order.\r\n\t\tvar tips = scope_Handles.map(addTooltip);\r\n\r\n\t\tbindEvent('update', function(values, handleNumber, unencoded) {\r\n\r\n\t\t\tif ( !tips[handleNumber] ) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tvar formattedValue = values[handleNumber];\r\n\r\n\t\t\tif ( options.tooltips[handleNumber] !== true ) {\r\n\t\t\t\tformattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\r\n\t\t\t}\r\n\r\n\t\t\ttips[handleNumber].innerHTML = formattedValue;\r\n\t\t});\r\n\t}", "function tooltips ( ) {\n\n\t\t// Tooltips are added with options.tooltips in original order.\n\t\tvar tips = scope_Handles.map(addTooltip);\n\n\t\tbindEvent('update', function(values, handleNumber, unencoded) {\n\n\t\t\tif ( !tips[handleNumber] ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar formattedValue = values[handleNumber];\n\n\t\t\tif ( options.tooltips[handleNumber] !== true ) {\n\t\t\t\tformattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n\t\t\t}\n\n\t\t\ttips[handleNumber].innerHTML = formattedValue;\n\t\t});\n\t}", "function tooltips ( ) {\n\n\t\t// Tooltips are added with options.tooltips in original order.\n\t\tvar tips = scope_Handles.map(addTooltip);\n\n\t\tbindEvent('update', function(values, handleNumber, unencoded) {\n\n\t\t\tif ( !tips[handleNumber] ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar formattedValue = values[handleNumber];\n\n\t\t\tif ( options.tooltips[handleNumber] !== true ) {\n\t\t\t\tformattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n\t\t\t}\n\n\t\t\ttips[handleNumber].innerHTML = formattedValue;\n\t\t});\n\t}", "function tooltips ( ) {\n\n\t\t// Tooltips are added with options.tooltips in original order.\n\t\tvar tips = scope_Handles.map(addTooltip);\n\n\t\tbindEvent('update', function(values, handleNumber, unencoded) {\n\n\t\t\tif ( !tips[handleNumber] ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar formattedValue = values[handleNumber];\n\n\t\t\tif ( options.tooltips[handleNumber] !== true ) {\n\t\t\t\tformattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n\t\t\t}\n\n\t\t\ttips[handleNumber].innerHTML = formattedValue;\n\t\t});\n\t}", "function tooltips ( ) {\n\n\t\t// Tooltips are added with options.tooltips in original order.\n\t\tvar tips = scope_Handles.map(addTooltip);\n\n\t\tbindEvent('update', function(values, handleNumber, unencoded) {\n\n\t\t\tif ( !tips[handleNumber] ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar formattedValue = values[handleNumber];\n\n\t\t\tif ( options.tooltips[handleNumber] !== true ) {\n\t\t\t\tformattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n\t\t\t}\n\n\t\t\ttips[handleNumber].innerHTML = formattedValue;\n\t\t});\n\t}", "function tooltips ( ) {\n\n\t\t// Tooltips are added with options.tooltips in original order.\n\t\tvar tips = scope_Handles.map(addTooltip);\n\n\t\tbindEvent('update', function(values, handleNumber, unencoded) {\n\n\t\t\tif ( !tips[handleNumber] ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar formattedValue = values[handleNumber];\n\n\t\t\tif ( options.tooltips[handleNumber] !== true ) {\n\t\t\t\tformattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n\t\t\t}\n\n\t\t\ttips[handleNumber].innerHTML = formattedValue;\n\t\t});\n\t}", "function tooltips ( ) {\n\n\t\t// Tooltips are added with options.tooltips in original order.\n\t\tvar tips = scope_Handles.map(addTooltip);\n\n\t\tbindEvent('update', function(values, handleNumber, unencoded) {\n\n\t\t\tif ( !tips[handleNumber] ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar formattedValue = values[handleNumber];\n\n\t\t\tif ( options.tooltips[handleNumber] !== true ) {\n\t\t\t\tformattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n\t\t\t}\n\n\t\t\ttips[handleNumber].innerHTML = formattedValue;\n\t\t});\n\t}", "function tooltips ( ) {\n\n\t\t// Tooltips are added with options.tooltips in original order.\n\t\tvar tips = scope_Handles.map(addTooltip);\n\n\t\tbindEvent('update', function(values, handleNumber, unencoded) {\n\n\t\t\tif ( !tips[handleNumber] ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar formattedValue = values[handleNumber];\n\n\t\t\tif ( options.tooltips[handleNumber] !== true ) {\n\t\t\t\tformattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n\t\t\t}\n\n\t\t\ttips[handleNumber].innerHTML = formattedValue;\n\t\t});\n\t}", "function tooltips ( ) {\n\n\t\t// Tooltips are added with options.tooltips in original order.\n\t\tvar tips = scope_Handles.map(addTooltip);\n\n\t\tbindEvent('update', function(values, handleNumber, unencoded) {\n\n\t\t\tif ( !tips[handleNumber] ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar formattedValue = values[handleNumber];\n\n\t\t\tif ( options.tooltips[handleNumber] !== true ) {\n\t\t\t\tformattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n\t\t\t}\n\n\t\t\ttips[handleNumber].innerHTML = formattedValue;\n\t\t});\n\t}", "function tooltips ( ) {\n\n\t\t// Tooltips are added with options.tooltips in original order.\n\t\tvar tips = scope_Handles.map(addTooltip);\n\n\t\tbindEvent('update', function(values, handleNumber, unencoded) {\n\n\t\t\tif ( !tips[handleNumber] ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar formattedValue = values[handleNumber];\n\n\t\t\tif ( options.tooltips[handleNumber] !== true ) {\n\t\t\t\tformattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n\t\t\t}\n\n\t\t\ttips[handleNumber].innerHTML = formattedValue;\n\t\t});\n\t}", "function tooltips ( ) {\n\n\t\t// Tooltips are added with options.tooltips in original order.\n\t\tvar tips = scope_Handles.map(addTooltip);\n\n\t\tbindEvent('update', function(values, handleNumber, unencoded) {\n\n\t\t\tif ( !tips[handleNumber] ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar formattedValue = values[handleNumber];\n\n\t\t\tif ( options.tooltips[handleNumber] !== true ) {\n\t\t\t\tformattedValue = options.tooltips[handleNumber].to(unencoded[handleNumber]);\n\t\t\t}\n\n\t\t\ttips[handleNumber].innerHTML = formattedValue;\n\t\t});\n\t}", "toggleTooltips() {\n self.enableTooltips = !self.enableTooltips;\n }", "function updateTooltips(){\r\n\t//Bind Tooltips with Buttons\r\n\t$(\"button[rel='tooltip']\").tooltip({\r\n\t\tplacement:'top',\r\n\t\ttrigger:'hover',\r\n\t\tanimation:'true'\r\n\t});\r\n}", "applyTooltips() {\n tippy(\".tipped\", {\n arrow: true,\n animateFill: false,\n size: \"small\",\n maxWidth: 200,\n interactiveBorder: 8\n });\n }", "function tooltips() {\r\n\t$('.tooltip-link').tooltip();\r\n}", "function init_tooltips(){\n \n $(\".tooltip-bot, .tooltip-bot a, .nav-social-links a\").tooltip({\n placement: \"bottom\"\n });\n \n $(\".tooltip-top, .tooltip-top a\").tooltip({\n placement: \"top\"\n });\n \n \n $(\".tooltip-right, .tooltip-right a\").tooltip({\n placement: \"right\"\n });\n \n \n $(\".tooltip-left, .tooltip-left a\").tooltip({\n placement: \"left\"\n });\n \n }", "get tooltip() {}", "function init_tooltips(){\n\n $(\".tooltip-bot, .tooltip-bot a, .nav-social-links a\").tooltip({\n placement: \"bottom\"\n });\n\n $(\".tooltip-top, .tooltip-top a\").tooltip({\n placement: \"top\"\n });\n\n }", "function initToolTips() {\n $(\"[title]:not([data-hasqtip])\").each(function() {\n var $this = $(this);\n $this.qtip({\n style: {\n classes: 'qtip-bootstrap',\n },\n position: {\n my: 'top center', // Position my top left...\n at: 'bottom center', // at the bottom right of...\n target: $this, // my target,\n viewport: $(window)\n },\n events: {\n render: function(event, api) {\n // Extract the title translation ID\n var transIDs = $this.data('i18n').split(';');\n var titleTransID = transIDs[0].split(']')[1];\n\n // Remove the translation data-i18ns for title (but not text node)\n if (transIDs.length === 1) {\n $this.removeAttr('data-i18n'); // Only had title, delete it\n } else if (transIDs.length === 2) {\n $this.attr('data-i18n', transIDs[1]); // Set to the main text ID\n }\n\n // Chuck the new title trans ID (without the [title]) onto the tooltip\n api.elements.content.attr('data-i18n', titleTransID);\n }\n }\n });\n });\n}", "function ActivateTooltips(container) {\n if (container && container.tooltip) {\n container.find('span[rel=\"tooltip\"]').tooltip();\n }\n }", "function setupBootstrapTooltips() {\n\t$('[data-toggle=\"tooltip\"]').tooltip({\n\t\tcontainer: 'body'\n\t});\n}", "function initTooltips() {\n $('span[class^=\"pl-\"]').each(function () {\n $(this).mouseenter(function () {\n showTooltip($(this));\n });\n\n $(this).mouseleave(function () {\n hideTooltip($(this));\n });\n });\n}", "function mouseOver() {\n tooltip\n .style(\"opacity\", 1)\n .style(\"display\",\"inherit\");\n}", "function addToolTip() {\n\t\t\tvar key;\n\t\t\tfor (key in btnList) {\n\t\t\t\tif (btnList.hasOwnProperty(key)) {\n\t\t\t\t\tbtnList[key].tooltip({placement: \"bottom\"});\n\t\t\t\t}\n\t\t\t}\n\t\t}", "function bindTooltip(){\n bindTooltipSkin(\".b-tooltip, .b-panel-icons-item a,.b-tool, .b-image-nav, .b-help, .b-title\",\"qtip-light\");\n }", "function SetupPlayerTooltip(){\n // http://qtip2.com/\n $('.icon').each(function() {\n $(this).qtip({\n content: {\n text: function (event, api) {\n $.ajax({\n url: '/players/tooltip/' + $(this).data('type') + '/' + $(this).data('id')\n })\n .then(function(content) {\n // Set the tooltip content upon successful retrieval\n api.set('content.text', content);\n }, function(xhr, status, error) {\n // Upon failure... set the tooltip content to error\n api.set('content.text', status + ': ' + error);\n });\n return '';\n }\n },\n position: { my: 'lefttop', at: 'rightmiddle' },\n style: { classes: 'playerTooltip' }\n });\n });\n}", "function enableToolTipForHeader(){\r\n\t$('#merchantUpload').tooltip({title: \"Upload new set of images for an application.\", animation: true,placement: \"auto\"});\r\n\t$('[href=\"/search\"]').tooltip({title: \"Search existing or previously uploaded application from the system.\", animation: true,placement: \"auto\"});\r\n\t$('[href=\"/followup\"]').tooltip({title: \"Search applications for document followup from Head office.\", animation: true,placement: \"auto\"});\r\n\t$('[href=\"/signup\"]').tooltip({title: \"Register new merchant promoter or staff in Online Submission Application.\", animation: true,placement: \"auto\"});\r\n\t$('[href=\"#logout\"]').tooltip({title: \"Logout to OSA-PH.\", animation: true,placement: \"auto\"});\r\n}", "function showTooltips(frame) {\n\n var tools = frame.tools;\n\n for (var i = 0; i < tools.length; i++) {\n var tool = tools[i];\n drawTip(tool, \"tool \" + i);\n saveTip(tool, i);\n }\n\n}", "function initializeTooltips(){\n\t$('.tooltip').tooltipster({\n\t\tcontentAsHTML: true, // set title content to html\n\t\ttrigger: 'custom', // add custom trigger\n\t\ttriggerOpen: { // open tooltip when element is clicked, tapped (mobile) or hovered\n\t\t mouseenter: true\n\t\t},\n\t\ttriggerClose: { // close tooltip when element is clicked again, tapped or when the mouse leaves it\n\t\t\tmouseleave: true\n\t\t},\n\t\ttheme: ['tooltipster-light'/*, 'tooltipster-light-custom'*/]\n \t});\n}", "function updateTips(t) {\n\t\ttips.text(t)\n\t}", "addHighlighTooltip () {\n }", "function toggleAllTooltips() {\n \ttooltip_active = true; //only set to true during programmatic triggering of events\n\n \t$.each(pegList, function( index1, arr ) {\n \t\t$.each(arr, function( index2, peg ) {\n\n \t\t\t//if the tooltips are not being shown, turn them on\n \t\t\tif (!tooltip_status) {\n \t\t\t\tpeg.shape.fire('mouseenter');\n \t\t\t}\n \t\t\t//if the tooltips are being shown, turn them off\n \t\t\telse if (tooltip_status) {\n \t\t\t\tpeg.shape.fire('mouseleave');\n \t\t\t}\n \t\t\t//else - Error\n \t\t\telse {\n \t\t\t\tconsole.log('Error with toggleAllTooltips');\n \t\t\t\talert('Error with toggling tooltips - tooltip_status reached unknown state');\n \t\t\t}\n\n \t\t});\n \t});\n \ttooltip_active = false; //set back to false to prevent non-programmatic event triggers\n \ttooltip_status = (!tooltip_status) ? true : false;\n }", "showToolTip_(event) {\n this.updateToolTip_(event);\n }", "function setupGroupTooltips(groupElem) {\n $.each(groupElem.find(\"[data-toggle=tooltip]\"), function(i, elem) {\n $(elem).tooltip({\n animation: false, // slows down tooltip removal\n delay: {\n show: 500,\n hide: 0\n },\n title: $(elem).attr(\"title\") || $(elem).data(\"ts-title\"),\n trigger: \"hover\"\n });\n });\n}", "function setTooltip(text) {\n if (text !== undefined) {\n // show tooltip with text\n $('#aToolTip').show();\n $('.aToolTipContent').text(text);\n optimalApp.tooltip = text;\n } else {\n // hide tooltip\n $('#aToolTip').hide();\n optimalApp.tooltip = null;\n }\n}", "function update_tooltips() {\n if (valid_pt) {\n g_error_pt.style('visibility', 'hidden');\n }\n else {\n g_error_pt.style('visibility', 'visible');\n }\n if (valid_pass) {\n g_error_comp8.style('visibility', 'hidden');\n }\n else {\n g_error_comp8.style('visibility', 'visible');\n }\n}", "function showTooltips(evt) {\n\t\tif (tooltips_element) {\n\t\t\ttooltips_element.style.display = '';\n\t\t}\n\t}", "function hideTooltips() {\n\t\t\t\t\ttooltipObject.remove();\n\t\t\t\t}", "setupTooltipHandlers() {\n this.button.onmouseenter = () => {\n this.tooltip.showTooltip();\n };\n\n this.button.onmouseleave = () => {\n this.tooltip.hideTooltip();\n };\n }", "function mouseOver() {\n\t\ttooltip.style(\"display\", \"block\")\n\t\t\t .style(\"visibility\", \"visible\");\n\t}", "get tooltipClass() { return this._tooltipClass; }", "function _setSeverityTooltips(labelType) {\n var sevTooltipOne = $('#severity-one');\n var sevTooltipThree = $('#severity-three');\n var sevTooltipFive = $('#severity-five');\n var sevImgUrlOne = `/assets/javascripts/SVLabel/img/severity_popups/${labelType}_Severity1.png`\n var sevImgUrlThree = `/assets/javascripts/SVLabel/img/severity_popups/${labelType}_Severity3.png`\n var sevImgUrlFive = `/assets/javascripts/SVLabel/img/severity_popups/${labelType}_Severity5.png`\n\n // Remove old tooltips.\n sevTooltipOne.tooltip('destroy');\n sevTooltipThree.tooltip('destroy');\n sevTooltipFive.tooltip('destroy');\n\n // Add severity tooltips for the current label type if we have images for them.\n util.getImage(sevImgUrlOne).then(img => {\n var tooltipHeader = i18next.t('center-ui.context-menu.severity-example', { n: 1 });\n var tooltipFooter = `<i>${i18next.t('center-ui.context-menu.severity-shortcuts')}</i>`\n sevTooltipOne.tooltip({\n placement: \"top\", html: true, delay: {\"show\": 300, \"hide\": 10},\n title: `${tooltipHeader}<br/><img src=${img} height=\"110\"/><br/>${tooltipFooter}`\n });\n });\n util.getImage(sevImgUrlThree).then(img => {\n var tooltipHeader = i18next.t('center-ui.context-menu.severity-example', { n: 3 });\n var tooltipFooter = `<i>${i18next.t('center-ui.context-menu.severity-shortcuts')}</i>`\n sevTooltipThree.tooltip({\n placement: \"top\", html: true, delay: {\"show\": 300, \"hide\": 10},\n title: `${tooltipHeader}<br/><img src=${img} height=\"110\"/><br/>${tooltipFooter}`\n });\n });\n util.getImage(sevImgUrlFive).then(img => {\n var tooltipHeader = i18next.t('center-ui.context-menu.severity-example', { n: 5 });\n var tooltipFooter = `<i>${i18next.t('center-ui.context-menu.severity-shortcuts')}</i>`\n sevTooltipFive.tooltip({\n placement: \"top\", html: true, delay: {\"show\": 300, \"hide\": 10},\n title: `${tooltipHeader}<br/><img src=${img} height=\"110\"/><br/>${tooltipFooter}`\n });\n });\n }", "function SetupPlayerMatchTooltip(){\n\n // http://qtip2.com/\n $('.matchIcon').each(function() {\n $(this).qtip({\n content: {\n text: function (event, api) {\n $.ajax({\n url: '/players/tooltip/matches/' + $(this).attr('id')\n })\n .then(function(content) {\n // Set the tooltip content upon successful retrieval\n api.set('content.text', content);\n }, function(xhr, status, error) {\n // Upon failure... set the tooltip content to error\n api.set('content.text', status + ': ' + error);\n });\n return '';\n }\n },\n position: { my: 'rightMiddle', at: 'leftMiddle' },\n style: { classes: 'matchTooltip' }\n });\n });\n}", "tooltipClicked() {}", "function hideTooltip() {\n tt.style('opacity', 0.0);\n }", "function setTooltip(uniqueID){\n\t\tvar tempObject = $fp.courseObject[uniqueID];\t\t\n\t\tvar courseID = tempObject.courseID;\n\t\tvar uniqueID = tempObject.uniqueID;\n\t\tvar courseNo = tempObject.courseNo;\n\t\tvar department = tempObject.department;\n\t\tvar name = tempObject.name;\n\t\tvar description = tempObject.description;\n\t\tvar noCredits = tempObject.noCredits;\n\t\tvar gradeOption = tempObject.gradeOption;\n\t\tvar prerequisites = tempObject.prerequisites;\n\t\tvar corequisites = tempObject.corequisites;\n\t\tvar countsAs = tempObject.countsAs;\n\t\tvar title = \"<div style='max-height: 150px; overflow: auto; position: relative;'>\";\n\t\t\n\t\ttitle += \"<b>Name:</b> <span class='editable' contenteditable='true' id='tooltip_name_\" + uniqueID + \"'>\" + name + \"</span><br>\";\n\t\ttitle += \"<b>Department & Course No:</b> <span class='editable' contenteditable='true' id='tooltip_department_course_\" + uniqueID + \"'>\" + department + \" \" + courseNo + \"</span><br>\";\n\t\ttitle += \"<b>Counts As:</b> <span class='editable' contenteditable='true' id='tooltip_countsAs_\" + uniqueID + \"'>\" + countsAs + \"</span><br>\";\n\t\ttitle += \"<b>Description:</b> <span class='editable' contenteditable='true' id='tooltip_description_\" + uniqueID + \"'>\" + description + \"</span><br>\";\n\t\ttitle += \"<b>No. Credits:</b> <span class='editable' contenteditable='true' id='tooltip_noCredits_\" + uniqueID + \"'>\" + noCredits + \"</span><br>\";\n\t\ttitle += \"<b>Grade Option:</b> <span class='editable' contenteditable='true' id='tooltip_gradeOption_\" + uniqueID + \"'>\";\n\t\tswitch (gradeOption){\n\t\t\tcase \"S\":\n\t\t\t\ttitle += \"(S)atisfactory/No Credit</span><br>\";\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\tcase \"L\":\n\t\t\t\ttitle += \"(L)etter Grade</span><br>\";\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\tcase \"B\":\n\t\t\t\ttitle += \"(B)oth S/NC or Letter Grade</span><br>\";\n\t\t\t\tbreak;\t\n\t\t\t\n\t\t\tcase \"O\":\n\t\t\t\ttitle += \"(O)ther</span><br>\";\n\t\t\t\tbreak;\n\t\t\t\n\t\t\tdefault:\n\t\t\t\ttitle += \"</span><br>\";\n\t\t\t\tbreak;\n\t\t}\n\t\t \n\t\ttitle += \"<b>Prerequisites:</b> <span class='editable' contenteditable='true' id='tooltip_prerequisites_\" + uniqueID + \"'>\" + prerequisites + \"</span><br>\";\n\t\ttitle += \"<b>Corequisites:</b> <span class='editable' contenteditable='true' id='tooltip_corequisites_\" + uniqueID + \"'>\" + corequisites + \"</span><br>\";\n\t\ttitle += \"<br></div>\";\n\t\t \n\t\t//updates the courseObject subobject for the unique course to reflect the correct data (replaces old object)\n\t\t\t\t\t\t\t\t\n\t\t$('#' + uniqueID).prop(\"title\",title);\n\t\t\n\t\t$('#' + uniqueID).tooltip({\n\t\t\tposition: \t'top center',\n\t\t\toffset:\t\t[10, 50],\n\t\t\ttipClass:\t'tooltip',\n\t\t\tevents: \t{\n\t\t\t\tdef:\t\t'click, mouseout mousedown'\t\n\t\t\t},\n\t\t\tonBeforeShow: function(){\n\t\t\t\tvar item = this.getTrigger();\n\t\t\t\t$(item).toggleClass('selected',true);\n\t\t\t},\n\t\t\t\n\t\t\tonHide: function(){\n\t\t\t\tvar item = this.getTrigger();\n\t\t\t\t$(item).toggleClass('selected',false);\n\t\t\t}\n\t\t});\n\t\t\n\t\t//function for editing\n\t\t$('[contenteditable]').live('focus', function() {\n \t\tvar $this = $(this);\n \t\t\t$this.data('before', $this.html());\n\t\t\t\n\t\t\tvar idArray = $this.attr(\"id\").split(\"_\");\n\t\t\t\t\n\t\t\tvar type = idArray[1];\n\t\t\tvar uniqueID = idArray[2];\n\t\t\t\n\t\t\tif (type == \"countsAs\"){\n\t\t\t\t$fp.courseObject[uniqueID].previousCountsAs = $this.html();\t\n\t\t\t}\n\t\t\t\n\t\t\treturn $this;\n\t\t}).live('blur keyup paste', function(event) {\n\t\t\tvar $this = $(this);\n \t\tif ($this.data('before') !== $this.html()) {\n \t\t\t\t\t\t\t\n\t\t\t\t$this.data('before', $this.html());\n\t\t\t\t\n\t\t\t\tvar change = jQuery.Event(\"change\");\n\t\t\t\t\n\t\t\t\t//**********<event_handling>**********//\n\t\t\t\t\t\n\t\t\t\tvar idArray = $this.attr(\"id\").split(\"_\");\n\t\t\t\t\n\t\t\t\tvar type = idArray[1];\n\t\t\t\tvar uniqueID = idArray[2];\n\t\t\t\tvar selector = \"#\" + uniqueID;\n\t\t\t\t\t\t\t\t\n\t\t\t\tif (type != \"corequisites\" && type != \"prerequisites\" && type != \"countsAs\"){\n\t\t\t\t\t$fp.courseObject[uniqueID][type] = $this.html();\t\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\telse if (type == \"countsAs\"){\n\t\t\t\t\t$fp.courseObject[uniqueID][type] = $this.html();\n\t\t\t\t\tvalidateOnCourse(uniqueID);\n\t\t\t\t\t$fp.courseObject[uniqueID].previousCountsAs = $this.html();\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\telse{\n\t\t\t\t\tvar tempString = $this.text();\n\t\t\t\t\tvar tempArray = tempString.split(\",\");\n\t\t\t\t\tfor (var req in tempArray){\n\t\t\t\t\t\tvar temp = tempArray[req].toUpperCase();\n\t\t\t\t\t\ttempArray[req] = trim(temp);\n\t\t\t\t\t}\n\t\t\t\t\t$fp.courseObject[uniqueID][type] = tempArray; \n\t\t\t\t\t\n\t\t\t\t\tvar currentLocation = $(selector).closest('ul').attr('id');\n\t\t\t\t\tvalidateCourse(uniqueID, currentLocation);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif ($this.text() == \"\"){\n\t\t\t\t\tvar blankFieldTimeout = setTimeout(function(){\n\t\t\t\t\t\tif ($this.text() == \"\") $this.text(\"n/a\");\n\t\t\t\t\t},1000);\n\t\t\t\t}\n\t\t\t\t \n\t\t\t\telse{\n\t\t\t\t\tif (window.blankFieldTimeout){\n\t\t\t\t\t\tclearTimeout(blankFieldTimeout);\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t//**********</event_handling>**********//\n \t\t}\n \t\t return $this;\n\t\t});\n}", "function tooltips ( ) {\n\n\t\tif ( options.dir ) {\n\t\t\toptions.tooltips.reverse();\n\t\t}\n\n\t\t// Tooltips are added with options.tooltips in original order.\n\t\tvar tips = scope_Handles.map(addTooltip);\n\n\t\tif ( options.dir ) {\n\t\t\ttips.reverse();\n\t\t\toptions.tooltips.reverse();\n\t\t}\n\n\t\tbindEvent('update', function(f, o, r) {\n\t\t\tif ( tips[o] ) {\n\t\t\t\ttips[o].innerHTML = options.tooltips[o] === true ? f[o] : options.tooltips[o].to(r[o]);\n\t\t\t}\n\t\t});\n\t}", "function tooltips ( ) {\n\n\t\tif ( options.dir ) {\n\t\t\toptions.tooltips.reverse();\n\t\t}\n\n\t\t// Tooltips are added with options.tooltips in original order.\n\t\tvar tips = scope_Handles.map(addTooltip);\n\n\t\tif ( options.dir ) {\n\t\t\ttips.reverse();\n\t\t\toptions.tooltips.reverse();\n\t\t}\n\n\t\tbindEvent('update', function(f, o, r) {\n\t\t\tif ( tips[o] ) {\n\t\t\t\ttips[o].innerHTML = options.tooltips[o] === true ? f[o] : options.tooltips[o].to(r[o]);\n\t\t\t}\n\t\t});\n\t}", "function SetupCompetitionTooltip(){\n\n // http://qtip2.com/\n $('.icon1').each(function() {\n $(this).qtip({\n content: {\n text: '<div class=\"tooltipText\">' + $(this).data(\"summary\") + '</div>'\n },\n position: { my: 'lefttop', at: 'rightmiddle' },\n style: { classes: 'playerTooltip' }\n });\n });\n}", "function ShowHelp() {\n $('img').tooltip('show');\n}", "function hideTooltip() {\n tt.style('opacity', 0.0);\n }", "function hideTooltip() {\n tt.style('opacity', 0.0);\n }", "function hideTooltip() {\n tt.style('opacity', 0.0);\n }", "function toolTipInit() {\n\t\n\t\t$('.menu li a').tooltip({\n\t\t\tplacement: 'right'\n\t\t});\n\t}", "setTooltip(valueNew){let t=e.ValueConverter.toString(valueNew);null===t&&(t=this.getAttributeDefaultValueInternal(\"Tooltip\")),t!==this.__tooltip&&(this.__tooltip=t,e.EventProvider.raise(this.__id+\".onPropertyChanged\",{propertyName:\"Tooltip\"}),this.__processTooltip())}", "function tooltips ( ) {\r\n\r\n\t\t\tif ( options.dir ) {\r\n\t\t\t\toptions.tooltips.reverse();\r\n\t\t\t}\r\n\r\n\t\t\t// Tooltips are added with options.tooltips in original order.\r\n\t\t\tvar tips = scope_Handles.map(addTooltip);\r\n\r\n\t\t\tif ( options.dir ) {\r\n\t\t\t\ttips.reverse();\r\n\t\t\t\toptions.tooltips.reverse();\r\n\t\t\t}\r\n\r\n\t\t\tbindEvent('update', function(f, o, r) {\r\n\t\t\t\tif ( tips[o] ) {\r\n\t\t\t\t\ttips[o].innerHTML = options.tooltips[o] === true ? f[o] : options.tooltips[o].to(r[o]);\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t}", "function enableTooltip() {\n $('[v-tooltip]').tooltip({trigger: \"hover\", 'delay': {show: 1000, hide: 100}});\n}", "function hideTooltip() {\n tt.style('opacity', 0.0);\n }", "setTooltip_() {\n this.tooltip = $('arc-event-band-tooltip');\n this.svg.onmouseover = this.showToolTip_.bind(this);\n this.svg.onmouseout = this.hideToolTip_.bind(this);\n this.svg.onmousemove = this.updateToolTip_.bind(this);\n this.svg.onclick = (event) => {\n showDetailedInfoForBand(this, event);\n };\n }", "function tooltip(){\r\n\t\ttry{\r\n\t\t\tvar tooltips = document.getElementsByClassName(\"inew-tooltiptext\");\r\n\t\t\tfor (var i = tooltips.length - 1; i >= 0; --i) {\r\n\t\t\t\tvar tooltipCount = tooltips[i].innerHTML.length;\r\n\t\t\t\tif (tooltipCount > 22){\r\n\t\t\t\t\ttooltips[i].className = \"inew-tooltiptext inew-tooltipLarge\";\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}catch (e){}\t\r\n\t}", "function tooltips ( ) {\n\t\n\t\t\tif ( options.dir ) {\n\t\t\t\toptions.tooltips.reverse();\n\t\t\t}\n\t\n\t\t\t// Tooltips are added with options.tooltips in original order.\n\t\t\tvar tips = scope_Handles.map(addTooltip);\n\t\n\t\t\tif ( options.dir ) {\n\t\t\t\ttips.reverse();\n\t\t\t\toptions.tooltips.reverse();\n\t\t\t}\n\t\n\t\t\tbindEvent('update', function(f, o, r) {\n\t\t\t\tif ( tips[o] ) {\n\t\t\t\t\ttips[o].innerHTML = options.tooltips[o] === true ? f[o] : options.tooltips[o].to(r[o]);\n\t\t\t\t}\n\t\t\t});\n\t\t}", "function quitarToolTipASelects() {\n $('.categoria_id, .talle_id, .proveedor_id, .genero').tooltip({\n disabled: true\n });\n }", "function tooltips ( ) {\r\n\r\n\t\tif ( options.dir ) {\r\n\t\t\toptions.tooltips.reverse();\r\n\t\t}\r\n\r\n\t\t// Tooltips are added with options.tooltips in original order.\r\n\t\tvar tips = scope_Handles.map(addTooltip);\r\n\r\n\t\tif ( options.dir ) {\r\n\t\t\ttips.reverse();\r\n\t\t\toptions.tooltips.reverse();\r\n\t\t}\r\n\r\n\t\tbindEvent('update', function(f, o, r) {\r\n\t\t\tif ( tips[o] ) {\r\n\t\t\t\ttips[o].innerHTML = options.tooltips[o] === true ? f[o] : options.tooltips[o].to(r[o]);\r\n\t\t\t}\r\n\t\t});\r\n\t}", "function MatTooltipDefaultOptions() {}", "function hideTooltips() {\n\t\tif (tooltips_element) {\n\t\t\ttooltips_element.style.display = 'none';\n\t\t}\n\t}", "function doTooltip(d, i) {\n\tvar commonname = toTitleCase(d['Common names (Eng)'].split(',')[0]);\n\tif (commonname=='') {\n\t\tcommonname = toTitleCase(d.Genus)+ \" \" +d.Species;\n\t//ttsciname.text(' ');\n \t//ttspecieslabel.text(toTitleCase(d.Genus)+ \" \" +d.Species);\n \t//ttthreatlabel.text(threatdict[d['Red List status']].toUpperCase())\n\t} \n\t\n\tttspecieslabel.text(commonname);\n \tttthreatlabel.text(threatdict[d['Red List status']].toUpperCase())\n\twordlen=Math.max(commonname.length, threatdict[d['Red List status']].length)\n\t\n\ttooltip\n\t\t.style(\"left\", getFocusXFromGenus(d[\"genus-order\"])-13+\"px\")//+focuswidth+8+\"px\")\n\t\t.style(\"top\", tooltipy0+\"px\")//(getSpeciesFocusY(d)+(classdata[currclassindex].focusheight/2.0))+\"px\")\n\t\t.style(\"display\", \"block\")\n\t\t//.style(\"width\", 10*wordlen+\"px\")\n}", "init() {\n tooltipsList.push( this );\n\n // First initiated tooltip -> add the global tooltip element\n if ( tooltipsList.length === 1 ) appendTooltipElement();\n }", "function initTooltip() {\n angular.element(elem).tooltip({\n title: scope.bsTip,\n placement: scope.bsTipPlacement\n });\n }", "function InitTooltips()\n{\n var show_tooltips = GetCookie('tooltips');\n if ((null != show_tooltips) && (0 == show_tooltips))\n {\n return;\n }\n\n // get all spans (tooltip containers)\n var spans = document.getElementsByTagName('SPAN');\n for (var i=0; spans.length > i; ++i)\n {\n // check if current span element is a tooltip container\n if (\"with_tooltip\" == spans.item(i).className)\n {\n // it contains a tooltip, add mouse event handlers for IE6\n if (spans.item(i).onmouseout)\n {\n var old_onmouseout = spans.item(i).onmouseout;\n spans.item(i).onmouseout = function() {ShowTooltip(this, false); old_onmouseout();};\n }\n else\n {\n spans.item(i).onmouseout = function() {ShowTooltip(this, false);};\n }\n if (spans.item(i).onmouseover)\n {\n var old_onmouseover = spans.item(i).onmouseover;\n spans.item(i).onmouseover = function() {ShowTooltip(this, true); old_onmouseover();};\n }\n else\n {\n spans.item(i).onmouseover = function() {ShowTooltip(this, true);};\n }\n }\n }\n spans = null;\n}", "function zoto_widget_tips(options) {\n\tthis.$uber(options);\n\tthis.type = 'zoto_widget_tips';\n\tthis.set_title('quick tips');\n}", "function enableTooltip() {\n\tvar hoverMsg = ( _sessLang == SESS_LANG_CHN ) ? \"如果選擇列表中沒有,選擇任何稱謂然後用“更改”的方式去更正!\" : \"If not found in the dropdown selection list, select any and then use Edit to correct it!\";\n\t$(document).tooltip({content: hoverMsg});\n\t$(document).tooltip(\"enable\");\n} // enableTooltip()", "function toolTipHTML() {\n return \"100\";\n }", "function HideToolTip (){\ntooltip\n .style(\"opacity\",0);\n}", "function load_tooltips() {\n $('[data-toggle=\"tooltip\"]').tooltip()\n}", "function showTocTooltip() {\r\n // Find the tooltip generated in the toc hierarchy\r\n \tvar originalTooltip = $(this).find(\".wh-tooltip\");\r\n \tif(originalTooltip.length > 0) {\r\n \t\t// Tooltip exists. Generate a container for the tooltip.\r\n \t var container = $(\"<div>\",{ \r\n \t class: \"wh-tooltip-wrapper\",\r\n \t \"data-tooltip-position\": $('.wh_publication_toc').attr(\"data-tooltip-position\")\r\n \t});\r\n \t// Clone the tooltip so that when is removed from dom, the original tooltip will not.\r\n \tvar tooltip = originalTooltip.clone();\r\n \ttooltip.removeClass(\"wh-tooltip\");\r\n \ttooltip.addClass(\"wh-toc-tooltip\");\r\n \tcontainer.append(tooltip);\r\n \t\tvar top = $(this).offset().top - $(\"#wh_publication_toc\").offset().top;\r\n \t\tvar left = $(this).offset().left - ($(\"#wh_publication_toc\").offset().left + parseInt($(\"#wh_publication_toc\").css(\"padding-left\")));\r\n \t container.css(\"position\", \"absolute\").css(\"top\", top).css(\"left\", left).css(\"width\", $(this).width() + left).css(\"height\", $(this).height()).css(\"float\", \"left\");\r\n \t domSanitizer.appendHtmlNode(container, $(\"#wh_publication_toc\"));\r\n \t \r\n \t setTimeout(function(){ $(\".wh-toc-tooltip\").addClass(\"wh-display-tooltip\"); }, 50);\r\n \t}\r\n }", "getTooltip(){return this.__tooltip}", "function ActivateTooltip() {\n // creates the tooltip to display the y point\n $(\"<div id='tooltip'></div>\").css({\n position: \"absolute\",\n display: \"none\",\n border: \"1px solid #fdd\",\n padding: \"2px\",\n \"background-color\": \"#fee\",\n opacity: 0.80\n }).appendTo(\"body\");\n // displays the tooltip on hover\n $(\"#placeholder\").bind(\"plothover\", function (event, pos, item) {\n if (item) {\n var x = item.datapoint[0].toFixed(2), y = item.datapoint[1].toFixed(2);\n $(\"#tooltip\").html(y)\n .css({ top: item.pageY + 5, left: item.pageX + 5 })\n .fadeIn(200);\n }\n else {\n $(\"#tooltip\").hide();\n }\n });\n }", "function toolTipInit() {\r\n\t\r\n\t\t$('.social-icon-top ul li a, ul.footer-social li a').tooltip({\r\n\t\t\tplacement: 'bottom'\r\n\t\t});\r\n\t}", "set_tooltip_html(html, childID=null) {\n this.tooltip.set_html(html, childID);\n }", "function init() { \n \n posHTML.setDragnDrop()\n \n //Tooltip\n $(\"a\").tooltip('show')\n $('a').tooltip({html: true}) \n $(\"a\").tooltip('hide') \n}", "function toggleToolTips() {\n canUseToolTips = !canUseToolTips;\n for(let i = 0; i < document.getElementsByClassName('tooltip-show').length; i++) {\n let e = document.getElementsByClassName('tooltip-show')[i];\n e.classList.remove('tooltip-show');\n e.classList.add('tooltip');\n }\n}", "function setTips(targetClass, position, trigger) {\n var $targets = $(targetClass);\n position = position || \"right\";\n trigger = trigger || \"hover\";\n $.each($targets, function(index, target) {\n var $target = $(target);\n makeTip($target, $target.data(\"content\"), position, trigger);\n });\n\n}" ]
[ "0.7334321", "0.73147136", "0.6849508", "0.68288565", "0.67945063", "0.65687245", "0.65527654", "0.6503227", "0.6503227", "0.6503227", "0.6503227", "0.64765465", "0.6445026", "0.64272773", "0.6391714", "0.6388349", "0.63838303", "0.63723147", "0.6370157", "0.63505405", "0.63505405", "0.63505405", "0.63505405", "0.63505405", "0.63505405", "0.63505405", "0.63505405", "0.63505405", "0.63505405", "0.6347971", "0.63472086", "0.6338514", "0.6315492", "0.6292964", "0.6209366", "0.61981606", "0.6190505", "0.6168588", "0.6137518", "0.61220044", "0.6105926", "0.6100628", "0.60567856", "0.6049631", "0.6047583", "0.6047489", "0.6044836", "0.6044793", "0.60171807", "0.60168713", "0.6006785", "0.5990012", "0.59893864", "0.5984359", "0.5979861", "0.5962578", "0.59104484", "0.5894395", "0.5879504", "0.5858176", "0.58560675", "0.58159834", "0.58107126", "0.5806332", "0.5805549", "0.5805549", "0.58023536", "0.5802286", "0.57992494", "0.57992494", "0.57992494", "0.57830787", "0.57808614", "0.5776375", "0.57724345", "0.5770234", "0.5769232", "0.57681394", "0.57633716", "0.5761275", "0.5753441", "0.5749859", "0.5749629", "0.572839", "0.57160664", "0.57118446", "0.5711612", "0.570867", "0.5704383", "0.5680756", "0.5679708", "0.5676278", "0.5674313", "0.56695414", "0.56568635", "0.56394005", "0.56275636", "0.56235486", "0.5623206", "0.5619313" ]
0.753394
0
Process command entered by the user in the input textarea element when the tutor is in error state. Once the tutor enters the error state, the supported commands are searched at the end of the erroneous input. If a supported command is found at the end of the erroneous input, the command is processed. The following is a list of the supported commands: restart restart the current subunit reset same as the 'restart' command fix remove errors from the input text xxx same as the 'fix' command
function processInputCommand() { var inputText = my.html.input.value var goodChars = my.current.correctInputLength if (inputCommandIs('restart') || inputCommandIs('rst')) { location.href = '#restart' } else if (inputCommandIs('fix') || inputCommandIs('xxx')){ my.html.input.value = inputText.substring(0, goodChars) updatePracticePane() } else if (inputCommandIs('qtpi')) { qtpi() } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function handleError(command, index, error) {\n // Record the reason for the command failure.\n if (command.func.name === 'throwError') {\n historyItem[index].status = 'Unrecognized';\n }\n else if (failHard) {\n historyItem[index].status = 'Skipped';\n }\n else {\n historyItem[index].status = 'Failed: ' + error.message;\n }\n\n // If the command was unrecognized or failed outright, log it.\n if (!failHard) {\n error.message = error.message.split('\\n').map(function(string) {\n return string = '\\t' + string;\n }).join('\\n');\n\n console.error(\"Editor command '\" + command.name\n + \"' failed with error:\\n\" + error.message);\n }\n\n // Skip remaining commands.\n failHard = true;\n }", "function editCommand() {\n \tconsole.log(\"Checking if command is valid.\");\n \tvar commandData = $(\"#editCommandData\").text().trim().toLowerCase();\n \tvar commandPoints = Number($(\"#editCommandPoints\").text());\n \tvar commandUses = Number($(\"#editCommandUses\").text());\n \tvar commandRank = document.getElementById(\"rankChoiceEdit\").value;\n \tvar repeat = document.getElementById(\"commandRepeatableChoiceEdit\").value\n\n \tcommandData = commandData.replace(new RegExp(\"^[\\!]+\"), \"\").trim();\n\n \tif (commandData.length >= 255) {\n \t//max length is 255.\n \terrorMessageCommandModal(\"The message is too long\", \"editCommandData\");\n \treturn\n \t} else if (commandData.length == 0) {\n \terrorMessageCommandModal(\"You must type a message\", \"editCommandData\");\n \treturn\n \t} else {\n \tcommandData = strip(commandData);\n \tresetMessageCommandModal(\"editCommandData\")\n \t}\n\n \tif (isNaN(commandPoints) == true) {\n \terrorMessageCommandModal(\"Points must be a number\", \"editCommandPoints\");\n \treturn\n \t} else if (Math.sign(parseFloat(commandPoints)) == -1) {\n \terrorMessageCommandModal(\"Points cannot be negative\", \"editCommandPoints\");\n \treturn\n \t} else {\n \tresetMessageCommandModal(\"editCommandPoints\")\n \t}\n\n \tif (isNaN(commandUses) == true) {\n \terrorMessageCommandModal(\"Uses must be a number\", \"editCommandUses\");\n \treturn\n \t} else if (Math.sign(parseFloat(commandUses)) == -1) {\n \terrorMessageCommandModal(\"Uses cannot be negative\", \"editCommandUses\");\n \treturn\n \t} else {\n \tresetMessageCommandModal(\"editCommandUses\")\n \t}\n\n \tif (repeat == \"false\") { repeat = false } else { repeat = true }\n\n \tconsole.log(commandData, commandPoints, commandUses, commandRank, repeat);\n \t// Adds it to the db and table\n \tCommandHandle.editCommand(commandToBeEdited, null, commandData, commandUses, commandPoints, commandRank, null, repeat); //Edit the DB\n \tCommandHandle.findCommand(commandToBeEdited).then(data => {\n \tif (data !== null) {\n \t\tvar filteredData = table //A set of functions that removes the command, adds it back, and redraws the table.\n \t.rows()\n \t.indexes()\n \t.filter(function (value, index) {\n \t\treturn table.row(value).data().commandName == commandToBeEdited;\n \t});\n \t\ttable.rows(filteredData).remove();\n \t\ttable.row.add({ commandName: commandToBeEdited, arguements: null, message: commandData, uses: commandUses, points: commandPoints, rank: commandRank });\n \t\ttable.draw();\n \t\t$(\"#modalEditCommand\").modal(\"hide\");\n \t\tdocument.getElementById(\"editModal\").innerHTML = editCommandModalEntry()\n \t}\n \t})\n\n \t// Shows an error in the modal\n \tfunction errorMessageCommandModal(message, errLocation) {\n \tvar editCommandName = document.getElementById(errLocation).parentElement;\n \tvar cmdErrorMessageEdit = document.getElementById(\"errorMessageEdit\")\n \teditCommandName.classList.add(\"errorClass\");\n \tcmdErrorMessageEdit.innerHTML = message;\n \tconsole.log(\"Command is not valid.\");\n \t}\n\n \t// Resets the errors\n \tfunction resetMessageCommandModal(toBeReset) {\n \ttry {\n \t\tdocument.getElementById(toBeReset).parentElement.classList.remove(\"errorClass\");\n \t\tdocument.getElementById(\"errorMessageEdit\").innerHTML = \"\";\n \t} catch (error) {\n \t\tconsole.log(error);\n \t}\n \t}\n}", "verifyCommandInputValidity() {\n if (this.mode == Editor.MODE_COMMAND) {\n if (this.commandInput.getContent()[0] != \":\")\n this.changeMode(Editor.MODE_GENERAL);\n }\n }", "function parseCommand(command) {\n console.log(currScene);\n // go through each action and try to run\n for (index in currScene.actions) {\n let condition = currScene.actions[index][0];\n let action = currScene.actions[index][1];\n\n if (checkCondition(command, condition)) {\n if (restart.includes(command)){\n reset_globals();\n }\n console.log(\"condition passed\");\n console.log(condition);\n console.log(\"---\");\n executeAction(action);\n return;\n }\n }\n\n // if we failed to parse execute the action Error\n narrate(`I don't know what \"${command}\" means.`);\n}", "_onCommand(e) {\n e.preventDefault();\n const command = this.commandInput.value;\n this.commandInput.value = \"\";\n // begin shout command\n if(command.startsWith(\"/shout \")) { \n const shout = command.substring(7);\n this._addMessage(`You shout \"${shout}\"`);\n } // end shout command\n\n // begin shout command\n else if(command.startsWith(\"/whisper \")) { \n const shout = command.substring(9);\n this._addMessage(`You whisper \"${shout}\"`);\n } // end shout command \n\n // begin logoff command \n else if (command.startsWith(\"/logoff\")) { \n this._onLogOut(); \n } // end logoff command\n\n // begin search command\n else if (command.startsWith(\"/search\")) {\n this._search();\n } // end search command \n\n // begin attack command\n else if (command.startsWith(\"/attack\")) {\n this._attack();\n } // end attack command\n\n // begin help command\n else if (command.startsWith(\"/help\")) {\n this._helpMessage();\n } // end help command\n\n // begin escape command\n else if (command.startsWith(\"/escape\"))\n {\n this._escape();\n } // end escape command\n\n // begin dam command\n else if(command.startsWith(\"/dam\")) {\n console.log(this._calculatePlayerDamage());\n } // end dam command\n\n // basic speech\n else {\n this._addMessage(`You say \"${command}\"`);\n }\n }", "function ManageErrors(commandcalledName, data) {\n selecteditem.error = Translate(\"Error\" + commandcalledName + data.error.errorCode);\n\n if (selecteditem.error.length === 0) {\n selecteditem.error = data.error.errorMessage; //to translate --> The Cannot prepare an ES ticket becouse scenario step id 2 is not valid.\n }\n }", "function checkNewCommand() {\n \tconsole.log(\"Checking if command is valid.\");\n \tvar commandName = $(\"#addCommandName\").text().trim().toLowerCase();\n \tvar commandData = $(\"#addCommandData\").text().trim();\n \tvar commandPoints = Number($(\"#addCommandPoints\").text());\n \tvar commandUses = Number($(\"#addCommandUses\").text());\n \tvar repeat = document.getElementById(\"commandRepeatableChoice\").value\n \tvar commandRank = document.getElementById(\"rankChoiceAdd\").value;\n\n \tcommandName = commandName.replace(new RegExp(\"^[\\!]+\"), \"\").trim();\n \tif (commandName.length == 0 || commandName == \"!\") {\n \terrorMessageCommandModal(\"You must enter a command name!\", \"addCommandName\")\n \treturn\n \t} else {\n \tCommandHandle.findCommand(commandName).then(data => {\n \t\tif (data !== null) {\n \t\tconsole.log(\"The command \" + commandName + \" already exists\");\n \t\tdocument.getElementById(\"addCommandName\").classList.add(\"errorClass\");\n \t\tdocument.getElementById(\"errorMessageAdd\").innerHTML = \"This command already exists\";\n \t\treturn\n \t\t}\n \t})\n \t}\n \tresetMessageCommandModal(\"addCommandName\");\n\n \tif (commandData.length >= 255) {\n \t//max length is 255\n \terrorMessageCommandModal(\"This message is too long.\", \"addCommandData\");\n \treturn\n \t} else if (commandData.length == 0) {\n \terrorMessageCommandModal(\"You must type a message.\", \"addCommandData\");\n \treturn\n \t} else {\n \tcommandData = strip(commandData);\n \tresetMessageCommandModal(\"addCommandData\");\n \t}\n\n \tif (isNaN(commandPoints) == true) {\n \terrorMessageCommandModal(\"Points must be a number\", \"addCommandPoints\");\n \treturn\n \t} else if (Math.sign(parseFloat(commandPoints)) == -1) {\n \terrorMessageCommandModal(\"Cannot be negative\", \"addCommandPoints\");\n \treturn\n \t} else {\n \tresetMessageCommandModal(\"addCommandPoints\")\n \t}\n\n \tif (isNaN(commandUses) == true) {\n \terrorMessageCommandModal(\"Uses must be a number\", \"addCommandUses\");\n \treturn\n \t} else if (Math.sign(parseFloat(commandUses)) == -1) {\n \terrorMessageCommandModal(\"Cannot be negative\", \"addCommandUses\");\n \treturn\n \t} else {\n \tresetMessageCommandModal(\"addCommandUses\")\n \t}\n\n \tcommandData = commandData.replace(new RegExp(\"^[\\!]+\"), \"\").trim();\n\n \tif (repeat == \"false\") { repeat = false } else { repeat = true }\n\n \tconsole.log(commandName, commandData, commandPoints, commandUses, commandRank, null, repeat);\n \t//Adds a command to the DB\n \tCommandHandle.addCommand(commandName, null, commandData, commandUses, commandPoints, commandRank, null, repeat);\n \t//adds a row to the table with the new command info\n \taddCommandTable(commandName, commandData, commandUses, commandPoints, commandRank)\n \t$(\"#modalCart\").modal(\"hide\");\n\n \t// Shows an error in the modal\n \tfunction errorMessageCommandModal(message, errLocation) {\n \tvar addCommandName = document.getElementById(errLocation).parentElement;\n \tvar cmdErrorMessage = document.getElementById(\"errorMessageAdd\")\n \taddCommandName.classList.add(\"errorClass\");\n \tcmdErrorMessage.innerHTML = message;\n \tconsole.log(\"Command is not valid.\");\n \t}\n\n \t// resets the errors\n \tfunction resetMessageCommandModal(toBeReset) {\n \ttry {\n \t\tdocument.getElementById(toBeReset).parentElement.classList.remove(\"errorClass\");\n \t\tdocument.getElementById(\"errorMessageAdd\").innerHTML = \"\";\n \t} catch (error) {\n \t\tconsole.log(error);\n \t}\n \t}\n}", "function shellInvalidCommand()\n{\n _StdIn.putText(\"Invalid Command. \");\n if (_MCPMode)\n {\n _StdIn.putText(\"Want me to slow down your power cycles for you?\");\n }\n else\n {\n _StdIn.putText(\"Type 'help' for user designed help.\");\n }\n}", "function resolveCommands_CMD(e) {\n var cmd = e.toLowerCase();\n \n Tempus_returnString.sw_append(td.minute+' '+td.day()+' '+td.month_txt()+' : '+cmd);\n /*\n * reference to the solarwinds object\n * format the string here from data entered/returned\n * pass to solarwinds\n * solarWindsRef.sw_append('<div>ass hat. man if i were any better at this it would be sinful</div>');\n */\n\n if (!loggedIn && cmd == 'root') {\n /*\n * looking for the correct loging command \n */\n currArray++;\n loggedIn = true;\n //temp password\n } else if (loggedIn && !passwordIn && cmd == 'asshat') {\n /*\n * if the correct login has been entered has the correct pasword been entered?\n */\n currArray++;\n passwordIn = true;\n } else if (loggedIn && passwordIn) {\n /*\n * bot the correct password and login was entered and stored so\n * we are ready to proceed\n */\n\n if (cmd == 'en') {\n switch (currArray) {\n case 2:\n currArray++;\n break;\n case 14:\n currArray++;\n break;\n case 32:\n currArray++;\n break;\n case 34:\n currArray++;\n break;\n case 36:\n currArray++;\n break;\n }\n\n }\n\n else if (cmd == \"password1\") {\n switch (currArray) {\n case 3:\n currArray++;\n break;\n case 31:\n currArray++;\n break;\n case 33:\n currArray++;\n break;\n case 35:\n currArray++;\n break;\n case 37:\n currArray++;\n break;\n }\n }\n\n else if (cmd == \"ping\") {\n switch (currArray) {\n case 4:\n currArray++;\n break;\n case 5:\n currArray++;\n break;\n case 44:\n currArray++;\n break;\n }\n }\n\n else if (cmd == \"copy st\" && currArray == 6) {\n currArray++;\n }\n else if (cmd == \"copy startup-config tftp\" && currArray == 7) {\n currArray++;\n }\n //temp command\n else if (currArray == 8 && cmd == \"j gibbens\") {\n\n currArray++;\n }\n else if (cmd == \"erase starup-config\" && currArray == 9) {\n currArray++;\n }\n else if (cmd == \"reload\" && currArray == 10) {\n currArray++;\n }\n else if (cmd == \"y\" && currArray == 11) {\n currArray++;\n }\n else if (cmd == \"ip address\" && currArray == 12) {\n currArray++;\n }\n else if (currArray == 13) {\n currArray++;\n }\n\n else if (cmd == \"#conf t\" && currArray == 15) {\n currArray++;\n }\n else if (cmd == \"#int\" && currArray == 16) {\n console.log(currArray);\n currArray++;\n }\n else if (cmd == \"#interface vlan1\" && currArray == 17) {\n currArray++;\n }\n else if (cmd == \"ip address\" && currArray == 18) {\n currArray++;\n }\n else if (cmd == \"no shut\" && currArray == 19) {\n currArray++;\n }\n else if (cmd == \"end\" && currArray == 20) {\n currArray++;\n }\n else if (cmd == \"copy tftp flash\" && currArray == 21) {\n currArray++;\n }\n else if (cmd == \"reload command\" && currArray == 22) {\n currArray++;\n }\n else if (cmd == \"filename\" && currArray == 23) {\n currArray++;\n }\n else if (cmd == \"y\" && currArray == 24) {\n currArray++;\n }\n else if (cmd == \"copy tftp start\" && currArray == 25) {\n currArray++;\n }\n //root\n else if (cmd == \"root\" && currArray == 26) {\n currArray++;\n }\n //paswordr\n else if (cmd == \"passwordxmar\" && currArray == 27) {\n currArray++;\n }\n //temp password\n else if (cmd == \"passwordxmar\" && currArray == 28) {\n currArray++;\n }else if (cmd == \"password\" && currArray == 29) {\n currArray++;\n }\n\n else if (cmd == \"password\" && currArray == 30) {\n currArray++;\n }\n else if (cmd == \"root\" && currArray == 31) {\n currArray++;\n }\n else if (cmd == \"config t\" && currArray == 38) {\n currArray++;\n }\n /*\n else if (cmd == \"cr\" && currArray == 39) {\n currArray++;\n }\n else if (cmd == \"crypto key gen\" && currArray == 40) {\n currArray++;\n }\n else if (cmd == \"crypto key generator rsa\" && currArray == 41) {\n currArray++;\n }\n else if (cmd == \"1024\" && currArray == 42) {\n currArray++;\n }\n\n else if (cmd == \"wr\" && currArray == 43) {\n currArray++;\n }\n else if (cmd == \"show flash\" && currArray == 44) {\n currArray++;\n }*/\n else {\n xmarCmd.updateError(errorsCMD(), 'dialogContent_xmarCMD');\n }\n \n // console.log(cmd);\n // console.log(currArray);\n }\n\n inc();\n }", "function commands(command) {\n try {\n var interpreter = interpreters.top();\n \n if (command == 'exit' && settings.exit) {\n if (interpreters.size() == 1) {\n if (settings.login) {\n logout();\n } else {\n var msg = 'You can exit from main interpeter';\n self.echo(msg);\n }\n } else {\n self.pop('exit');\n }\n } else {\n echo_command(command);\n if (command == 'clear' && settings.clear) {\n self.clear();\n } else {\n interpreter['eval'](command, self);\n }\n }\n \n } catch (e) {\n display_exception(e, 'USER');\n self.resume();\n throw e;\n }\n }", "function checkInput() {\n const ERR_MESS_SYNTAX = \"TODO: Bad Syntax\";\n const OUT_LIST = \"t ls\";\n const OUT_ADD = \"t a\";\n const OUT_CLEAR = \"clear\";\n const OUT_ADD_NUM = /^t do ([0-9]+)$/;\n const OUT_PRI = /^t p ([0-9] [A-Z])$/;\n var index;\n\n todocl.out.innerHTML = CLEAR;\n todocl.todoText = CLEAR;\n readFile(false);\n\n if (todocl.todoCommand === OUT_LIST) {\n readFile(true);\n } else if (todocl.todoCommand === OUT_ADD) {\n todocl.todoAdd = true;\n todocl.out.innerHTML = \"ADD\";\n } else if (todocl.todoCommand === OUT_CLEAR) {\n todocl.out.innerHTML = CLEAR;\n } else if (todocl.todoCommand.match(OUT_PRI)) {\n priTask(todocl.todoCommand.charAt(6), todocl.todoCommand.charAt(4));\n } else if (todocl.todoCommand.match(OUT_ADD_NUM)) {\n index = Number(todocl.todoCommand.charAt(5)) - 1;\n deleteTask(index);\n } else {\n todocl.out.innerHTML = ERR_MESS_SYNTAX;\n }\n }", "async function run() {\n let errors = '';\n try {\n const commands = core.getInput('run').split(/\\r?\\n/);\n const type = core.getInput('type');\n const files = core.getInput('files');\n\n // get changed files\n let changedFiles = [];\n if (files) {\n changedFiles = JSON.parse(files);\n }\n\n // get problem matcher\n const matcher = PROBLEM_MATCHERS[type];\n if (matcher === undefined) {\n throw new Error(`not supported problem matcher type: ${type}`);\n }\n\n // execute command\n const re = new RegExp(matcher['regexp']);\n for (const cmd of commands) {\n const ret = await exec(cmd.trim(), {env: process.env}, (line) => {\n const match = re.exec(line);\n if (match) {\n if (changedFiles.includes(getMatchedFile(matcher, match))) {\n console.log(line);\n }\n const severity = match[matcher['severity']];\n if (severity === 'error') {\n errors += line;\n }\n } else {\n console.log(line);\n }\n });\n if (ret !== 0) {\n throw new Error(`run process exited with code ${ret}`);\n }\n }\n } catch (error) {\n core.setFailed(error.message);\n console.error(error);\n }\n\n if (errors) {\n core.setOutput('errors', errors);\n }\n}", "handleTextChange(event) {\n this.runningBlockedInput = [];\n this.isValidCheck = true;\n if (this.symbolsNotAllowed != undefined || this.wordsNotAllowed != undefined) {\n this.interimValue = (event.target.value).toLowerCase();\n this.interimValue = this.interimValue.replace(/(<([^>]+)>)/ig, \"\");\n \n //Symbol check section\n if (this.symbolsNotAllowed != undefined) {\n let matchesSymbol = this.interimValue.match(this.symbolsNotAllowed);\n if (matchesSymbol != null && matchesSymbol.length > 0) {\n for(let i = 0; i < matchesSymbol.length; i++){\n this.runningBlockedInput.push(matchesSymbol[i]);\n }\n this.isValidCheck = false;\n } else {\n this.richText = event.target.value;\n }\n }\n\n if (this.wordsNotAllowed != undefined) {\n let matchesWords = this.interimValue.match(this.wordsNotAllowed);\n if (matchesWords != null && matchesWords.length > 0) {\n for(let i = 0; i < matchesWords.length; i++){\n this.runningBlockedInput.push(matchesWords[i]);\n }\n this.isValidCheck = false;\n } else {\n this.richText = event.target.value;\n }\n }\n } else {\n this.isValidCheck = true;\n this.richText = event.target.value;\n }\n this.characterCount = this.richText.length;\n if(this.characterCap && this.characterCount > this.characterLimit){\n this.isValidCheck = false;\n }\n //Display different message if warn only - validation also won't be enforced on Next.\n if(this.characterCap && this.characterCount > this.characterLimit){\n this.errorMessage = 'Error - Character Limit Exceeded';\n }else if(!this.warnOnly){\n this.errorMessage = 'Error - Invalid Symbols/Words found: '+this.runningBlockedInput.toString();\n }else{\n this.errorMessage = 'Warning - Invalid Symbols/Words found: '+this.runningBlockedInput.toString();\n }\n \n }", "function treatTextAreaErrors() {\n var errorMsg = errorInPuzzleString(textArea.value);\n document.getElementById('error-msg').textContent = errorMsg;\n }", "function commandTrigger() {\n var line = promptText;\n if (typeof config.commandValidate == 'function') {\n var ret = config.commandValidate(line);\n if (ret == true || ret == false) {\n if (ret) {\n handleCommand();\n }\n } else {\n commandResult(ret,\"jquery-console-message-error\");\n }\n } else {\n handleCommand();\n }\n }", "function initCommandParser() {\n var commandParser = {};\n commandParser.commandHolder = initCommandRamHolder();\n commandParser.createCommand = function (code) {\n console.log(code);\n //Код команди виглядає так:\n //addi $t1,$t2,$t3\n //var firstSpilt = code.split(\" \");\n var firstSpaceIndex = code.indexOf(\" \");\n var firstSplit = [code.substring(0,firstSpaceIndex),code.substring(firstSpaceIndex+1)];\n var end = [firstSplit[0]].concat(firstSplit[1].split(commandRegExp));\n console.log(code);\n return end;\n };\n commandParser.parse = function (splitedCode) {\n var code = splitedCode[0];\n switch (code) {\n //TImm Group\n case 'addi':\n case 'addiu':\n case 'andi':\n case 'ori':\n case 'slti':\n case 'sltiu':\n case 'xori':\n return cStart[code] + convertTSImm(splitedCode);\n break;\n //DST Group\n case 'add':\n case 'addu':\n case 'and':\n case 'or':\n case 'sllv':\n case 'slt':\n case 'sltu':\n case 'srlv':\n case 'sub':\n case 'subu':\n case 'xor':\n return cStart[code] + convertDST(splitedCode) + cEnd[code];\n break;\n //SOff Group\n case 'bgez':\n case 'bgezal':\n case 'bgtz':\n case 'blez':\n case 'bltz':\n case 'bltzal':\n var offsetLabel = splitedCode[2];\n if (!numberRegExp.test(offsetLabel)) {\n var currentCommandNumber = this.commandHolder.commandCodeList.length;\n var labelNumber = this.commandHolder.getLabel(offsetLabel);\n var offset = labelNumber - currentCommandNumber;\n splitedCode[2] = parseInt(offset);\n }\n return cStart[code] + convertSOff(splitedCode);\n break;\n //ST Group\n case 'div':\n case 'divu':\n case 'mult':\n case 'multu':\n return cStart[code] + convertST(splitedCode) + cEnd[code];\n break;\n //STOff Group\n case 'beq':\n case 'bne':\n offsetLabel = splitedCode[3];\n if (!numberRegExp.test(offsetLabel)) {\n currentCommandNumber = this.commandHolder.commandCodeList.length;\n labelNumber = this.commandHolder.getLabel(offsetLabel);\n offset = labelNumber - currentCommandNumber;\n splitedCode[3] = parseInt(offset);\n }\n return cStart[code] + convertSTOff(splitedCode);\n break;\n //Target Group\n case 'j':\n case 'jal':\n var targetLabel = splitedCode[1];\n if (!numberRegExp.test(targetLabel)){\n labelNumber = this.commandHolder.getLabel(targetLabel);\n splitedCode[1] = labelNumber;\n }\n return cStart[code] + convertTarget(splitedCode);\n break;\n //TOffS Group\n case 'lw':\n case 'sw':\n case 'lb':\n case 'sb':\n return cStart[code] + convertTOffS(splitedCode);\n break;\n //SorD Group\n case 'mfhi':\n case 'mflo':\n case 'jr':\n return cStart[code] + convertSorD(splitedCode) + cEnd[code];\n break;\n //TImm Group\n case 'lui':\n return cStart[code] + convertTImm(splitedCode);\n break;\n //DTH Group\n case 'sll':\n case 'sra':\n case 'srl':\n return cStart[code] + convertDTH(splitedCode) + cEnd[code];\n break;\n\n }\n };\n return commandParser;\n}", "static parseInputForCommands({domain=null,input=null,arrayIndex=-1})\n{\nlet cmds={};\n\n\n// Override commands from config/input\nif(Array.isArray(input.domain))\n{\nif(input.domain[arrayIndex].preflight_commands&&\nObject.keys(input.domain[arrayIndex].preflight_commands).length>0)\n{\ncmds=input.domain[arrayIndex].preflight_commands;\n}\n\nif(input.domain[arrayIndex].commands&&\nObject.keys(input.domain[arrayIndex].commands).length>0)\n{\n// If there were no preflight commands, override any previously specified commands\nif(!input.domain[arrayIndex].preflight_commands||\nObject.keys(input.domain[arrayIndex].preflight_commands).length<1)\n{\ncmds=input.domain[arrayIndex].commands;\n}else\n// or else add to the preflight commands\n{\ncmds=Object.assign(cmds,input.domain[arrayIndex].commands);\n}\n}\n\n\n}else\nif(input.domain[domain]&&Object.keys(input.domain[domain]).length>0)\n{\nif(input.domain[domain].preflight_commands&&\nObject.keys(input.domain[domain].preflight_commands).length>0)\n{\ncmds=input.domain[domain].preflight_commands;\n}\n\nif(input.domain[domain].commands&&\nObject.keys(input.domain[domain].commands).length>0)\n{\n// If there were no preflight commands, override any previously specified commands\nif(!input.domain[domain].preflight_commands||\nObject.keys(input.domain[domain].preflight_commands).length<1)\n{\ncmds=input.domain[domain].commands;\n}else\n// or else add to the preflight commands\n{\ncmds=Object.assign(cmds,input.domain[domain].commands);\n}\n}\n}\n\nreturn cmds;\n}", "checkForNextError() {\n if (!isNullOrUndefined(this.viewer)) {\n let errorWords = this.errorWordCollection;\n if (errorWords.length > 0) {\n for (let i = 0; i < errorWords.length; i++) {\n let errorElements = errorWords.get(errorWords.keys[i]);\n for (let j = 0; j < errorElements.length; j++) {\n if (errorElements[j] instanceof ErrorTextElementBox && !errorElements[j].ischangeDetected) {\n this.updateErrorElementTextBox(errorWords.keys[i], errorElements[j]);\n }\n else if (errorElements[j] instanceof TextElementBox) {\n let matchResults = this.getMatchedResultsFromElement(errorElements[j]);\n let results = matchResults.textResults;\n // tslint:disable-next-line:max-line-length\n let markIndex = (errorElements[j].ischangeDetected) ? errorElements[j].start.offset : errorElements[j].line.getOffset(errorElements[j], 0);\n // tslint:disable-next-line:max-line-length\n this.viewer.owner.searchModule.textSearch.updateMatchedTextLocation(matchResults.matches, results, matchResults.elementInfo, 0, errorElements[j], false, null, markIndex);\n for (let i = 0; i < results.length; i++) {\n let element = this.createErrorElementWithInfo(results.innerList[i], errorElements[j]);\n this.updateErrorElementTextBox(element.text, element);\n break;\n }\n }\n break;\n }\n break;\n }\n }\n else {\n this.viewer.clearSelectionHighlight();\n }\n }\n }", "function parseCommand(text){\n var words = text.split(\" \");\n for(var i=0; i < words.length; i++){\n if (words[i] in commandList){\n processCommand(words[i]);\n break;\n }\n }\n}", "function validateCommand(command) {\n if (commandVerbs.indexOf(command) == -1) {\n doNotUnderstand();\n } else {\n getNewAdventure(command);\n }\n }", "function processCommands(command, commandParam){\n\n\t//console.log(commandParam);\n\n\tswitch(command){\n\n\tcase 'spotify-this-song':\n\t\t//If user has not specified a song , use default\n\t\tif(commandParam === undefined){\n\t\t\tcommandParam = defaultSong;\n\t\t} \n\t\tspotifyThis(commandParam); break;\n\tcase 'movie-this':\n\t\t//If user has not specified a movie Name , use default\n\t\tif(commandParam === undefined){\n\t\t\tcommandParam = defaultMovie;\n\t\t} \n\t\tmovieThis(commandParam); break;\n\tcase 'do-what-it-says':\n\t\tdoWhatItSays(); break;\n\tdefault: \n\t\tconsole.log(\"Invalid command. Please type any of the following commands: spotify-this-song movie-this or do-what-it-says\");\n}\n\n\n}", "function history_edit_command(command) {\n remove_history_editor();\n \n history_current_editor = $('<form class=\"command\"><input type=\"text\"/></form>');\n $('input',history_current_editor).val(command.text());\n history_replaced_command = command;\n history_replaced_command.parent().addClass('selected');\n history_replaced_command.replaceWith(history_current_editor);\n \n $('input',history_current_editor).focus().keydown(function(event) {\n // Navigate up and down the command history.\n // 38 == UP key\n // 40 == DOWN key\n if (event.which != 38 && event.which != 40) {\n return;\n }\n event.preventDefault();\n \n var current_action = history_current_editor.parent();\n var next_action = $('.command', event.which == 38 ?\n current_action.prev() : current_action.next());\n \n if (next_action.length > 0) {\n history_edit_command(next_action);\n } else {\n if (event.which == 40) {\n $('#input').focus();\n } else {\n // TODO: Implement cleared history interface\n }\n }\n }).keydown(function (event) {\n // Remove the editor\n // 27 ESC key\n if (event.which == 27) {\n event.preventDefault();\n remove_history_editor();\n }\n }).keydown(function (event) {\n // Shift + ENTER sends the command\n // to a new output frame.\n if (event.which == 13 && event.shiftKey) {\n event.preventDefault();\n $('#input').val($(this).val());\n remove_history_editor();\n $('#go').click();\n }\n }).keydown(tab_completion);\n\n history_current_editor.submit(function(event) {\n event.preventDefault();\n if (working)\n return;\n \n var input = $('input', this);\n var container = $(this).parent();\n var cmd = $.trim(input.val());\n if (cmd.length == 0) return;\n \n if (execute_on_client(cmd,container)) {\n remove_history_editor();\n return;\n }\n \n setWorking(true);\n $.ajax({\n type: 'GET', url: '/cmd?' + escapeCommand(cmd),\n dataType: 'html',\n success: function (response) {\n history_replace_result(container,cmd,response);\n remove_history_editor();\n $('#input').focus();\n },\n error: function (request, message, exception) {\n history_replace_result(container,\n $('<div class=\"command\"><span class=\"failed\">' + cmd + '</span></div>'),\n $('<strong>HTTP ' + request.status\n + ' ' + request.statusText + '</strong>'\n + ' ' + request.responseText));\n },\n complete: function (request, message) {\n setWorking(false);\n last_request = request;\n }\n });\n });\n}", "function replyInvalidCommand(err=null){\n if(err){\n message.reply(err)\n }else{\n message.reply('Please enter valid command.\\nCommand for help: >help');\n }\n }", "function processInput() {\n var value = inputArea.value;\n /* split input in text area by newline */\n var lines = value.split('\\n');\n var output = parseLines(lines);\n /* Output is an object with two properties,\n 'outputLines' and 'errors' */\n var outputLines = output.outputLines;\n var errors = output.errors;\n /* Toggle visibility of errors section\n depending on if there are errors at all */\n if (errors.length == 0) {\n errorsContainer.classList.remove('visible');\n } else {\n errorsContainer.classList.add('visible');\n /* clear all errors before adding new ones */\n while (errorsUl.firstChild) {\n errorsUl.removeChild(errorsUl.firstChild);\n }\n errors.forEach(function(error) {\n addErrorToUl(error);\n });\n }\n /* actually set the output to pre element,\n join multiple lines with newline */\n outputPre.innerHTML = outputLines.join('\\n');\n }", "function validCommand() {\n console.log(\"\\n\" + \"Please enter a valid command from the following list:\");\n console.log(\"concert-this\");\n console.log(\"spotify-this-song\");\n console.log(\"movie-this\");\n console.log(\"do-what-it-says\" + \"\\n\");\n}", "function processInput(str) {\n str = typeof(str) == 'string' && str.trim().length > 0 ? str.trim() : false\n\n if(str) {\n str == 'list' || '?' || 'help'\n ? listOptions()\n : str == 'quit' || str == 'q'\n ? process.exit(0)\n : console.log(BLUE, 'No matching script')\n } else {\n console.log(RED, 'Invalid Input')\n }\n}", "function splitCommand() {\n // command is retrieved from the text box\n str = document.getElementById('tags').value;\n var name = document.getElementById('user_name').value;\n var listname = document.getElementById('list_id').value;\n // Error message is thrown if either user or list is not specified\n if (!name || !listname) {\n alert(\"Enter the command without ANY spelling or grammatical errors \\nEnter an '@' sign before entering the person's name \\nOne task can be allocated to one person at a time \\nType a '#' sign before the list name \\nIf entering the date directly follow dd/mm/yyyy format i.e. 29/12/2017 \\nDue date command should be able to fetch an exact date i.e. 'finish by the end of next week' will work whereas 'finish it next week' will not work \\nMention start date and end date explicitly (synonyms are accepted) i.e. Start today and submit it by next Monday \\nA week starts on Monday and finishes on Sunday (Public holidays and weekends are not considered) \\nDue date cannot be before start date \\nDescription of the task must be enclosed in '[ ]' \\nPercentage completed must be stated as number followed by percentage sign i.e. 25% \\nPlus symbol followed by 1 (high) or 2(medium) or 3(low) must be entered to indicate the priority of the task i.e. +1\");\n }\n // user and list are replaced with empty spaces in the command\n str = str.replace(document.getElementById('user_name').value, '').replace(document.getElementById('list_id').value, '');\n // empty spaces are removed\n cap = str.trim().toUpperCase();\n // the command is processed with endElements array to split the command into two halves if it has start date and end date\n for (var x = 0; x < endElements.length; x++) {\n if (cap.indexOf(endElements[x]) >= 0) {\n dateText.push(cap.substr(cap.indexOf(endElements[x]) - cap.charAt(0), cap.indexOf(endElements[x]) - 1));\n dateText.push(cap.substr(cap.indexOf(endElements[x]), cap.length));\n }\n }\n // priority is processed from the command\n if (cap.indexOf('+') > -1) {\n priority = cap.substr(cap.indexOf('+') + 1, 1);\n var priority_text;\n switch (priority) {\n case \"1\":\n priority_text = \"High\";\n break;\n case \"2\":\n priority_text = \"Medium\";\n break;\n case \"3\":\n priority_text = \"Low\";\n break;\n default:\n priority_text = \"high\";\n priority = \"1\";\n break;\n }\n resultArray['PRIORITY'] = \"(\" + priority + \") \" + priority_text;\n }\n // percentage is processed from the command\n if (cap.indexOf('%') > -1) {\n var cap1 = \" \" + cap;\n percentage = cap1.substr(cap1.indexOf('%') - 3, 3);\n percentage = percentage.replace(/\\D/g, '');\n percentage = percentage.trim();\n resultArray['PERCENTAGE'] = percentage;\n }\n // description is extracted from the command\n if (cap.indexOf('[') > -1) {\n desc = cap.substring(cap.lastIndexOf(\"[\") + 1, cap.lastIndexOf(\"]\"));\n desc = desc.trim();\n desc = desc.substring(0, 1).toUpperCase() + desc.substring(1).toLowerCase();\n resultArray['DESCRIPTION'] = desc;\n }\n // this loop gets the date by running the loop wrt length of dateText array\n for (var y1 = 0; y1 < dateText.length; y1++) {\n var res = dateText[y1].split(\" \");\n var dateValue = dateText[y1].substr(dateText[y1].indexOf('/') - 2, 10);\n // checks if the date entered matches the format dd/mm/yyyy\n var t = dateValue.match(/^(\\d{2})\\/(\\d{2})\\/(\\d{4})$/);\n if (t !== null) {\n var d = +t[1],\n m = +t[2],\n y = +t[3];\n var dateFull = new Date(y, m - 1, d);\n if (dateFull.getFullYear() === y && dateFull.getMonth() === m - 1) {\n // passes the date value to displayDate function where the date is displayed\n displayDate(dateFull);\n }\n }\n // If the date specified is not in the format of dd/mm/yyyy then the time and time adjectives are pushed into the array\n for (var i = 0; i < res.length; i++) {\n for (var l = 0; l < time.length; l++) {\n\n if (res[i] == time[l]) {\n timeElements.push(res[i]);\n }\n }\n for (var j = 0; j < timeAdj.length; j++) {\n if (res[i] == timeAdj[j]) {\n timeAdjEle.push(res[i]);\n }\n }\n }\n // this if condition will get executed if there are no time elements\n if (timeElements.length == 0) {\n displayFields();\n }\n // this if condition will get executed if there are no time adjective elements\n if (timeElements.length >= 1 && timeAdjEle.length == 0) {\n\n for (var i = 0; i < res.length; i++) {\n for (var l = 0; l < time.length; l++) {\n if (res[i] == time[l]) {\n timeFinal = res[i];\n // calculates today's date\n if (timeFinal == \"TODAY\") {\n var today = new Date();\n timeToAdd = today;\n }\n // calculates tomorrow's date\n if (timeFinal == \"TOMORROW\") {\n if ((res[i - 1] != \"AFTER\") || (res[i - 2] != \"DAY\")) {\n var tomorrow = new Date();\n tomorrow.setDate(tomorrow.getDate() + 1);\n timeToAdd = tomorrow;\n }\n }\n // calculates day after tomorrow's date\n if (timeFinal == \"TOMORROW\") {\n if ((res[i - 1] == \"AFTER\") && (res[i - 2] == \"DAY\")) {\n var tomorrow = new Date();\n tomorrow.setDate(tomorrow.getDate() + 2);\n timeToAdd = tomorrow;\n }\n }\n // calculates date values related to number of days\n if (timeFinal == \"DAY\" || timeFinal == \"DAYS\") {\n if (res[i - 2] == \"COUPLE\") {\n var day = new Date();\n day.setDate(day.getDate() + 2);\n timeToAdd = day;\n } else {\n // the position of the number entered is found out from the words string\n var pos = words.indexOf(res[i - 1].substring(0, 3).toLowerCase());\n var numberConverted = pos / 3 + 1;\n var days = numberConverted;\n var day = new Date();\n // number is added to along with today's date\n day.setDate(day.getDate() + days);\n timeToAdd = day;\n }\n }\n // calculates date values related to number of weeks\n if (timeFinal == \"WEEK\" || timeFinal == \"WEEKS\") {\n if (res[i - 2] == \"COUPLE\") {\n var week = new Date();\n week.setDate(week.getDate() + 14);\n timeToAdd = week;\n } else {\n var pos = words.indexOf(res[i - 1].substring(0, 3).toLowerCase());\n var numberConverted = pos / 3 + 1;\n var weeks = numberConverted * 7;\n var week = new Date();\n week.setDate(week.getDate() + weeks);\n timeToAdd = week;\n }\n }\n // calculates date values related to number of months\n if (timeFinal == \"MONTH\" || timeFinal == \"MONTHS\") {\n if (res[i - 2] == \"COUPLE\") {\n var month = new Date();\n month.setDate(month.getDate() + 61);\n timeToAdd = month;\n } else {\n var pos = words.indexOf(res[i - 1].substring(0, 3).toLowerCase());\n var numberConverted = pos / 3 + 1;\n var months = numberConverted * 30;\n var month = new Date();\n month.setDate(month.getDate() + months);\n timeToAdd = month;\n }\n }\n // calculates date values related to number of years\n if (timeFinal == \"YEAR\" || timeFinal == \"YEARS\") {\n if (res[i - 2] == \"COUPLE\") {\n var year = new Date();\n year.setDate(year.getDate() + 730);\n timeToAdd = year;\n } else {\n var pos = words.indexOf(res[i - 1].substring(0, 3).toLowerCase());\n var numberConverted = pos / 3 + 1;\n var years = numberConverted * 365;\n var year = new Date();\n year.setDate(year.getDate() + years);\n timeToAdd = year;\n }\n }\n }\n }\n }\n displayDate(timeToAdd);\n }\n\n if ((timeElements.length >= 1) && (timeAdjEle.length <= 1)) {\n if ((timeElements[0] == \"MONDAY\") || (timeElements[0] == \"TUESDAY\") || (timeElements[0] == \"WEDNESDAY\") || (timeElements[0] == \"THURSDAY\") || (timeElements[0] == \"FRIDAY\") || (timeElements[0] == \"SATURDAY\") || (timeElements[0] == \"SUNDAY\")) {\n // calculates date values related to this+weekday\n if ((timeAdjEle[0] == \"THIS\") || (timeAdjEle[1] == \"THIS\")) {\n var dayNum = dayFinder(timeElements[0]);\n if (dayNum >= date.getDay()) {\n var thisDay = new Date(date.getFullYear(), date.getMonth(), date.getDate() + (dayNum - date.getDay()));\n displayDate(thisDay);\n }\n if (dayNum < date.getDay()) {\n var thisDay = new Date(date.getFullYear(), date.getMonth(), date.getDate() + (7 - (date.getDay() - dayNum)));\n displayDate(thisDay);\n }\n }\n // calculates date values related to next+weekday\n if ((timeAdjEle[0] == \"NEXT\") || (timeAdjEle[1] == \"NEXT\")) {\n var dayNum = dayFinder(timeElements[0]);\n var thisDay = new Date(date.getFullYear(), date.getMonth(), date.getDate() + (7 - (date.getDay() - dayNum)));\n displayDate(thisDay);\n }\n }\n }\n\n if ((timeElements.length >= 1) && (timeAdjEle.length <= 2)) {\n if ((timeAdjEle[0] == \"WITHIN\") || (timeAdjEle[1] == \"WITHIN\")) {\n if ((timeAdjEle[0] == \"THIS\") || (timeAdjEle[1] == \"THIS\")) {\n // calculates date values related to within this month\n if (timeElements[0] == \"MONTH\") {\n lastDay = new Date(date.getFullYear(), date.getMonth() + 1, 0);\n finalTime = lastDay;\n displayDate(finalTime);\n }\n // calculates date values related to within this + (month)\n if ((timeElements[0] == \"JANUARY\") || (timeElements[0] == \"FEBRUARY\") || (timeElements[0] == \"MARCH\") || (timeElements[0] == \"APRIL\") || (timeElements[0] == \"MAY\") || (timeElements[0] == \"JUNE\") || (timeElements[0] == \"JULY\") || (timeElements[0] == \"AUGUST\") || (timeElements[0] == \"SEPTEMBER\") || (timeElements[0] == \"OCTOBER\") || (timeElements[0] == \"NOVEMBER\") || (timeElements[0] == \"DECEMBER\")) {\n monthCalculator(timeElements[0]);\n }\n // calculates date values related to within this week\n if (timeElements[0] == \"WEEK\") {\n var curr = new Date;\n lastDay = new Date(curr.setDate(curr.getDate() - curr.getDay() + 7));\n finalTime = lastDay;\n displayDate(finalTime);\n }\n // calculates date values related to within this year\n if (timeElements[0] == \"YEAR\") {\n var curr = new Date;\n lastDay = new Date(curr.getFullYear(), 11, 31);\n finalTime = lastDay;\n displayDate(finalTime);\n }\n }\n if ((timeAdjEle[0] == \"NEXT\") || (timeAdjEle[1] == \"NEXT\")) {\n // calculates date values related to within next month\n if (timeElements[0] == \"MONTH\") {\n lastDay = new Date(date.getFullYear(), date.getMonth() + 2, 0);\n finalTime = lastDay;\n displayDate(finalTime);\n }\n // calculates date values related to within next + (month)\n if ((timeElements[0] == \"JANUARY\") || (timeElements[0] == \"FEBRUARY\") || (timeElements[0] == \"MARCH\") || (timeElements[0] == \"APRIL\") || (timeElements[0] == \"MAY\") || (timeElements[0] == \"JUNE\") || (timeElements[0] == \"JULY\") || (timeElements[0] == \"AUGUST\") || (timeElements[0] == \"SEPTEMBER\") || (timeElements[0] == \"OCTOBER\") || (timeElements[0] == \"NOVEMBER\") || (timeElements[0] == \"DECEMBER\")) {\n monthCalculator(timeElements[0]);\n }\n // calculates date values related to within next week\n if (timeElements[0] == \"WEEK\") {\n var curr = new Date;\n lastDay = new Date(curr.setDate(curr.getDate() - curr.getDay() + 14));\n finalTime = lastDay;\n displayDate(finalTime);\n }\n // calculates date values related to within this year\n if (timeElements[0] == \"YEAR\") {\n var curr = new Date;\n lastDay = new Date(curr.getFullYear() + 1, 11, 31);\n finalTime = lastDay;\n displayDate(finalTime);\n }\n }\n }\n if ((timeAdjEle[0] == \"END\") || (timeAdjEle[1] == \"END\")) {\n if ((timeAdjEle[0] == \"THIS\") || (timeAdjEle[1] == \"THIS\")) {\n // calculates date values related to by the end of this month\n if (timeElements[0] == \"MONTH\") {\n lastDay = new Date(date.getFullYear(), date.getMonth() + 1, 0);\n finalTime = lastDay;\n displayDate(finalTime);\n }\n // calculates date values related to by the end of this (month)\n if ((timeElements[0] == \"JANUARY\") || (timeElements[0] == \"FEBRUARY\") || (timeElements[0] == \"MARCH\") || (timeElements[0] == \"APRIL\") || (timeElements[0] == \"MAY\") || (timeElements[0] == \"JUNE\") || (timeElements[0] == \"JULY\") || (timeElements[0] == \"AUGUST\") || (timeElements[0] == \"SEPTEMBER\") || (timeElements[0] == \"OCTOBER\") || (timeElements[0] == \"NOVEMBER\") || (timeElements[0] == \"DECEMBER\")) {\n monthCalculator(timeElements[0]);\n }\n // calculates date values related to by the end of this week\n if (timeElements[0] == \"WEEK\") {\n var curr = new Date;\n lastDay = new Date(curr.setDate(curr.getDate() - curr.getDay() + 7));\n finalTime = lastDay;\n displayDate(finalTime);\n }\n // calculates date values related to by the end of this year\n if (timeElements[0] == \"YEAR\") {\n var curr = new Date;\n lastDay = new Date(curr.getFullYear(), 11, 31);\n finalTime = lastDay;\n displayDate(finalTime);\n }\n }\n if ((timeAdjEle[0] == \"NEXT\") || (timeAdjEle[1] == \"NEXT\")) {\n // calculates date values related to by the end of next month\n if (timeElements[0] == \"MONTH\") {\n lastDay = new Date(date.getFullYear(), date.getMonth() + 2, 0);\n finalTime = lastDay;\n displayDate(finalTime);\n }\n // calculates date values related to by the end of next (month)\n if ((timeElements[0] == \"JANUARY\") || (timeElements[0] == \"FEBRUARY\") || (timeElements[0] == \"MARCH\") || (timeElements[0] == \"APRIL\") || (timeElements[0] == \"MAY\") || (timeElements[0] == \"JUNE\") || (timeElements[0] == \"JULY\") || (timeElements[0] == \"AUGUST\") || (timeElements[0] == \"SEPTEMBER\") || (timeElements[0] == \"OCTOBER\") || (timeElements[0] == \"NOVEMBER\") || (timeElements[0] == \"DECEMBER\")) {\n monthCalculator(timeElements[0]);\n }\n // calculates date values related to by the end of next week\n if (timeElements[0] == \"WEEK\") {\n var curr = new Date;\n lastDay = new Date(curr.setDate(curr.getDate() - curr.getDay() + 14));\n finalTime = lastDay;\n displayDate(finalTime);\n }\n // calculates date values related to by the end of next year\n if (timeElements[0] == \"YEAR\") {\n var curr = new Date;\n lastDay = new Date(curr.getFullYear() + 1, 11, 31);\n finalTime = lastDay;\n displayDate(finalTime);\n }\n }\n }\n }\n if ((timeElements.length >= 2) && (timeAdjEle.length >= 2)) {\n if ((timeAdjEle[0] == \"THIS\") || (timeAdjEle[1] == \"THIS\")) {\n // calculates date values related to two time elements and two time adjective elements (this month)\n if ((timeElements[0] == \"MONTH\") || (timeElements[1] == \"MONTH\")) {\n lastDay = new Date(date.getFullYear(), date.getMonth() + 1, 0);\n\n if ((timeAdjEle[0] == \"LAST\") || (timeAdjEle[1] == \"LAST\")) {\n thisMonthDay(\"LAST\", \"0\");\n }\n if ((timeAdjEle[0] == \"FIRST\") || (timeAdjEle[1] == \"FIRST\")) {\n thisMonthDay(\"FIRST\", \"1\");\n }\n if ((timeAdjEle[0] == \"SECOND\") || (timeAdjEle[1] == \"SECOND\")) {\n thisMonthDay(\"SECOND\", \"2\");\n }\n if ((timeAdjEle[0] == \"THIRD\") || (timeAdjEle[1] == \"THIRD\")) {\n thisMonthDay(\"THIRD\", \"3\");\n }\n if ((timeAdjEle[0] == \"FOURTH\") || (timeAdjEle[1] == \"FOURTH\")) {\n thisMonthDay(\"FOURTH\", \"4\");\n }\n if ((timeAdjEle[0] == \"FIFTH\") || (timeAdjEle[1] == \"FIFTH\")) {\n thisMonthDay(\"FIFTH\", \"5\");\n }\n }\n // calculates date values related to two time elements and two time adjective elements (this (month name))\n if ((timeElements[1] == \"JANUARY\") || (timeElements[1] == \"FEBRUARY\") || (timeElements[1] == \"MARCH\") || (timeElements[1] == \"APRIL\") || (timeElements[1] == \"MAY\") || (timeElements[1] == \"JUNE\") || (timeElements[1] == \"JULY\") || (timeElements[1] == \"AUGUST\") || (timeElements[1] == \"SEPTEMBER\") || (timeElements[1] == \"OCTOBER\") || (timeElements[1] == \"NOVEMBER\") || (timeElements[1] == \"DECEMBER\")) {\n lastDay = monthReturn(timeElements[1]);\n if ((timeAdjEle[0] == \"LAST\") || (timeAdjEle[1] == \"LAST\")) {\n MonthDay(\"LAST\", \"0\");\n }\n if ((timeAdjEle[0] == \"FIRST\") || (timeAdjEle[1] == \"FIRST\")) {\n MonthDay(\"FIRST\", \"1\");\n }\n if ((timeAdjEle[0] == \"SECOND\") || (timeAdjEle[1] == \"SECOND\")) {\n MonthDay(\"SECOND\", \"2\");\n }\n if ((timeAdjEle[0] == \"THIRD\") || (timeAdjEle[1] == \"THIRD\")) {\n MonthDay(\"THIRD\", \"3\");\n }\n if ((timeAdjEle[0] == \"FOURTH\") || (timeAdjEle[1] == \"FOURTH\")) {\n MonthDay(\"FOURTH\", \"4\");\n }\n if ((timeAdjEle[0] == \"FIFTH\") || (timeAdjEle[1] == \"FIFTH\")) {\n MonthDay(\"FIFTH\", \"5\");\n }\n }\n }\n // calculates date values related to two time elements and two time adjective elements (next month)\n if ((timeAdjEle[0] == \"NEXT\") || (timeAdjEle[1] == \"NEXT\")) {\n if ((timeElements[0] == \"MONTH\") || (timeElements[1] == \"MONTH\")) {\n lastDay = new Date(date.getFullYear(), date.getMonth() + 2, 0);\n if ((timeAdjEle[0] == \"LAST\") || (timeAdjEle[1] == \"LAST\")) {\n nextMonthDay(\"LAST\", \"0\");\n }\n if ((timeAdjEle[0] == \"FIRST\") || (timeAdjEle[1] == \"FIRST\")) {\n nextMonthDay(\"FIRST\", \"1\");\n }\n if ((timeAdjEle[0] == \"SECOND\") || (timeAdjEle[1] == \"SECOND\")) {\n nextMonthDay(\"SECOND\", \"2\");\n }\n if ((timeAdjEle[0] == \"THIRD\") || (timeAdjEle[1] == \"THIRD\")) {\n nextMonthDay(\"THIRD\", \"3\");\n }\n if ((timeAdjEle[0] == \"FOURTH\") || (timeAdjEle[1] == \"FOURTH\")) {\n nextMonthDay(\"FOURTH\", \"4\");\n }\n if ((timeAdjEle[0] == \"FIFTH\") || (timeAdjEle[1] == \"FIFTH\")) {\n nextMonthDay(\"FIFTH\", \"5\");\n }\n }\n // calculates date values related to two time elements and two time adjective elements (next (month name))\n if ((timeElements[1] == \"JANUARY\") || (timeElements[1] == \"FEBRUARY\") || (timeElements[1] == \"MARCH\") || (timeElements[1] == \"APRIL\") || (timeElements[1] == \"MAY\") || (timeElements[1] == \"JUNE\") || (timeElements[1] == \"JULY\") || (timeElements[1] == \"AUGUST\") || (timeElements[1] == \"SEPTEMBER\") || (timeElements[1] == \"OCTOBER\") || (timeElements[1] == \"NOVEMBER\") || (timeElements[1] == \"DECEMBER\")) {\n lastDay = monthReturn(timeElements[1]);\n if ((timeAdjEle[0] == \"LAST\") || (timeAdjEle[1] == \"LAST\")) {\n MonthDay(\"LAST\", \"0\");\n }\n if ((timeAdjEle[0] == \"FIRST\") || (timeAdjEle[1] == \"FIRST\")) {\n MonthDay(\"FIRST\", \"1\");\n }\n if ((timeAdjEle[0] == \"SECOND\") || (timeAdjEle[1] == \"SECOND\")) {\n MonthDay(\"SECOND\", \"2\");\n }\n if ((timeAdjEle[0] == \"THIRD\") || (timeAdjEle[1] == \"THIRD\")) {\n MonthDay(\"THIRD\", \"3\");\n }\n if ((timeAdjEle[0] == \"FOURTH\") || (timeAdjEle[1] == \"FOURTH\")) {\n MonthDay(\"FOURTH\", \"4\");\n }\n if ((timeAdjEle[0] == \"FIFTH\") || (timeAdjEle[1] == \"FIFTH\")) {\n MonthDay(\"FIFTH\", \"5\");\n }\n }\n }\n }\n // empties the array\n timeAdjEle = [];\n timeElements = [];\n }\n // Final alert message is displayed with all the elements of associative array\n alert(\"User: \" + document.getElementById('user_name').value + \"\\n Title:\" + resultArray['TITLE'] + \"\\n\" + \"Priority: \" + resultArray['PRIORITY'] + \"\\n\" + \"Percentage: \" + resultArray['PERCENTAGE'] + \"\\n\" + \"Description: \" + resultArray['DESCRIPTION'] + \"\\n\" + \"Start Date: \" + resultArray['STARTDATE'] + \"\\n\" + \"Due Date: \" + resultArray['DUEDATE']);\n}", "function checkCommandInEditMode() {\n var editCommand = new Object();\n editCommand[openCommand] = new Object();\n\n //add each default answer\n $(\".oldAnswerEdit\").each(function(i, e) {\n var answerName = $(e).val();\n var answerOutput = $(e).closest(\".row\").next(\"div\").children(\"div\").eq(0).children(\"div\").eq(0).children(\"textarea\").val();\n var lastChangedText = $(e).closest(\".row\").next(\"div\").children(\"div\").eq(0).children(\"div\").eq(1).children(\"small\").text();\n\n editCommand[openCommand][answerName] = new Object();\n //add answer key and value to answer object\n editCommand[openCommand][answerName][\"answer\"] = answerOutput;\n editCommand[openCommand][answerName][\"lastChangedAnswer\"] = lastChangedText;\n //add variables object\n editCommand[openCommand][answerName][\"variables\"] = new Object();\n //add each variable object\n $(\".availableVariable\", $(e).closest(\".row\").next(\"div\").children(\"div\").eq(1).children(\"div\")).each(function(i, e) {\n var variableName = e.innerHTML;\n var variableIdentifier = $(e).attr(\"data-original-title\");\n editCommand[openCommand][answerName][\"variables\"][variableName] = variableIdentifier;\n\n })\n });\n\n //add each new answer\n $(\".newAnswerEdit\").each(function(i, e) {\n var answerName = $(e).val();\n var answerOutput = $(e).closest(\".row\").next(\"div\").children(\"div\").eq(0).children(\"textarea\").val();\n var lastChangedText = $(e).closest(\".row\").next(\"div\").children(\"div\").eq(0).children(\"div\").eq(1).children(\"small\").text();\n\n editCommand[openCommand][answerName] = new Object();\n //add answer key and value to answer object\n editCommand[openCommand][answerName][\"answer\"] = answerOutput;\n editCommand[openCommand][answerName][\"lastChangedAnswer\"] = lastChangedText;\n //add variables object\n editCommand[openCommand][answerName][\"variables\"] = new Object();\n\n //add each variable object\n $(\".availableVariable\", $(e).closest(\".row\").next(\"div\").children(\"div\").eq(1)).each(function(i, e) {\n var variableName = e.innerHTML;\n var variableIdentifier = $(e).attr(\"data-original-title\");\n editCommand[openCommand][answerName][\"variables\"][variableName] = variableIdentifier;\n\n })\n });\n\n if (JSON.stringify(editCommand[openCommand]) !== JSON.stringify(botCommandObject[openCommand])) {\n editModeCommandNew = true;\n } else {\n editModeCommandNew = false;\n }\n\n setCommitChangesBtnEditMode();\n}", "function ecrire(){\nrl.question(welcomemessage, (answer) =>{\n\tif (answer == 'exit'){\n\t\tprocess.exit();\n\t}\n\telse if (answer== 'set'){\n\t\tset();\n\t}\n\telse if (answer == 'get'){\n\t\tget();\n\t}\n\telse if (answer == 'lastquery'){\n\t\tlastquery();\n\t}\n\n\telse if (answer == 'mysql') {\n\t\tsetEvent();\n\t}\n\telse if (answer== 'php'){\n\t\teventphp();\n\t}\n\telse {\n\t\tconsole.log(answer + ': command not found \\n' + listofcommand);\n\t\tsetTimeout(function(){ecrire()},120);\n\t}\n\t});\n}", "function shellInvalidCommand()\n{\n _StdIn.putText(\"Invalid Command. \");\n if (_SarcasticMode)\n {\n _StdIn.putText(\"Duh. Go back to your Speak & Spell.\");\n }\n else\n {\n _StdIn.putText(\"Type 'help' for, well... help.\");\n }\n}", "function cleanInput(input) {\n var arr = input.split(' ');\n var msg = arr[0] + \" \" + arr[1]; //take off |bb and <command>\n\n var midCommand = false;\n var i = 2;\n for (; i < arr.length; ++i) {\n //escape any existing parentheses\n if (arr[i].indexOf(\"'\") !== -1) {\n var aposIndex = arr[i].indexOf(\"'\");\n if (aposIndex > 0 && arr[i].charAt(aposIndex - 1) != \"\\\\\") {\n arr[i] = arr[i].replace(\"'\", \"\\\\'\");\n }\n }\n\n //we haven't reached another command, so keep concatenating\n if (arr[i].indexOf(\"--\") == -1) {\n if (!midCommand) {\n msg += \" \\\"\" + arr[i];\n midCommand = true;\n } else {\n msg += \" \" + arr[i];\n }\n } else {//found a command\n //convert l to list and p to print\n if (arr[i].indexOf(\"--l_\") > -1) {\n arr[i] = arr[i].replace(\"--l_\", \"--list_\");\n } else if (arr[i].indexOf(\"--p_\") > -1) {\n arr[i] = arr[i].replace(\"--p_\", \"--print_\");\n }\n\n // if (arr[i].indexOf(\"hitcount\") > 1 && arr[i].indexOf(\"hitcounts\") === -1) {\n // arr[i] = arr[i].replace(\"hitcount\", \"hitcounts\");\n // }\n if (midCommand) {\n msg += \"\\\"\";\n midCommand = false;\n }\n msg += \" \" + arr[i];\n }\n }\n //close query, if necessary\n if (midCommand) {\n msg += \"\\\"\";\n }\n\n return msg;\n}", "activate() {\n if (!this.ready) {\n return;\n }\n\n const cmdstr = this._inputController.$commandInput.val();\n // remember initial selection/cursor state, in case of reset\n this.initialRange = {\n start: this._inputController.$commandInput.prop('selectionStart'),\n end: this._inputController.$commandInput.prop('selectionEnd')\n };\n // target range of command input to ingest and replace\n this.targetRange = Object.assign({}, this.initialRange);\n\n // cursor/selection left boundary adjustment\n if (this.targetRange.start > 0) { // guarantees index (start - 1) is valid\n if (this.targetRange.start === this.targetRange.end) { // cursor\n if (!AUTOCOMPLETE_REGEXP.WHITESPACE.test(cmdstr.charAt(this.targetRange.start - 1))) {\n // cursor at mid token or touching right edge of a token\n this._growTargetRangeLeft(cmdstr, this.targetRange);\n }\n } else { // selection, guarantees index (start + 1) is valid\n const leftBoundary = cmdstr.slice(this.targetRange.start - 1, this.targetRange.start + 1);\n if (AUTOCOMPLETE_REGEXP.TOKEN_MID.test(leftBoundary)) {\n // selection left boundary at mid token\n this._growTargetRangeLeft(cmdstr, this.targetRange);\n } else if (AUTOCOMPLETE_REGEXP.TOKEN_END.exec(leftBoundary)?.index === 0) { // using test() gives spurious match\n // selection left boundary touching right edge of a token\n // exclude one space for UI aesthetics\n this.targetRange.start += 1;\n }\n }\n }\n\n // cursor/selection right boundary adjustment\n if (this.targetRange.end < cmdstr.length && // guarantees index (end + 1) is valid\n this.targetRange.start < this.targetRange.end && // guarantees index (end - 1) is valid; cursor start already moved\n AUTOCOMPLETE_REGEXP.TOKEN_MID.test(cmdstr.slice(this.targetRange.end - 1, this.targetRange.end + 1))\n ) {\n // cursor/selection right boundary at mid token\n this._growTargetRangeRight(cmdstr, this.targetRange);\n }\n\n // find first token in whole command string, if any\n const { index: firstChar, 1: firstToken } = AUTOCOMPLETE_REGEXP.FIRST_TOKEN.exec(cmdstr) ?? {};\n\n // is the first token an aircraft callsign?\n const aircraft = this._aircraftController.findAircraftByCallsign(firstToken);\n\n // if (aircraft) {\n // TODO: if so, be clever and filter suggestions depending on departure/arrival and flight phase\n // }\n\n // may require additional space for correct positioning\n let extraPad = '';\n\n // determine command type to autocomplete\n if (firstChar === undefined) {\n // empty/blank command string\n this.commandType = AUTOCOMPLETE_COMMAND_TYPE.SYSTEM;\n } else if (this.targetRange.start <= firstChar) {\n // cursor/selection before or includes first token\n if (aircraft) {\n // first token is callsign, exclude it\n let startWithoutCallsign = firstChar + firstToken.length + 1;\n\n // callsign not guaranteed to be followed by whitespace, i.e. cmdstr may match ^\\s*<callsign>$\n if (startWithoutCallsign > cmdstr.length) {\n startWithoutCallsign = cmdstr.length;\n extraPad = ' ';\n }\n\n this.targetRange.start = startWithoutCallsign;\n this.targetRange.end = Math.max(this.targetRange.start, this.targetRange.end);\n this.commandType = AUTOCOMPLETE_COMMAND_TYPE.TRANSMIT;\n } else {\n // first token is not callsign\n this.commandType = AUTOCOMPLETE_COMMAND_TYPE.SYSTEM;\n }\n } else {\n // cursor/selection outside first token\n this.commandType = AUTOCOMPLETE_COMMAND_TYPE.TRANSMIT;\n }\n\n this._updateState(AUTOCOMPLETE_STATE.COMMANDS.NO_MATCHES);\n this.$autocompleteSpacer.text(cmdstr.slice(0, this.targetRange.start).concat(extraPad));\n this.$autocompleteInput.val(cmdstr.slice(this.targetRange.start, this.targetRange.end));\n this.$autocompleteInput.attr('placeholder', AUTOCOMPLETE_INPUT_PLACEHOLDER.COMMAND);\n this.onAutocompleteInputChangeHandler();\n this.$autocomplete.addClass('active');\n this.$autocompleteInput.focus();\n this.active = true;\n }", "function adjustPosition(intCommand,pID){\r\n\tsetHatsFocus(pID);\r\n\tif(typeof(intCommand) != \"string\"){\r\n\t\tintCommand = String(intCommand);\r\n\t\treturn null;\r\n\t}\r\n\r\n\tif ((intCommand.indexOf(\"[\")==-1) && (intCommand.indexOf(\"enptui\")==-1) && (intCommand.indexOf(\"macrorun_\")==-1))\r\n\t\treturn intCommand;\r\n\r\n\tvar elements=hatsForm.elements;\r\n\tvar elementNext,eName,eType;\r\n\tfor (var i=0,iL=hatsForm.elements.length; i<iL; ++i){\r\n\t\telementNext = elements[i];\r\n\t\teName=elementNext.name;\r\n\t\teType=elementNext.type;\r\n\t\tif (isHInput(eType,eName)){\r\n\t\t\tinputAdjust(elementNext,true);\r\n\r\n\t\t\tif (eType==\"checkbox\"){\r\n\t\t\t\telementNext.disabled=true;\r\n\t\t\t} else {\r\n\t\t\t\tvar pool = eName.split(\"_\");\r\n\t\t\t\tvar pos = parseInt(hatsForm.CURSORPOSITION.value);\r\n\t\t\t\tvar len = parseInt(pool[2]);\r\n\t\t\t\tvar ipos = parseInt(pool[1]);\r\n\t\t\t\tif ((ipos <= pos) && ((ipos+len) >= pos)){\r\n\t\t\t\t\tvar strlen=elementNext.value.length;\r\n\t\t\t\t\tvar moveCursorToEndOfField = true; \r\n\r\n\t\t\t\t\tif (carettrackingenabled && (isIE||MOZILLA||OPERA)){ \r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tif ((intCommand == \"[fldext]\") || (intCommand == \"[qfldext]\") ||\r\n\t\t\t\t\t\t\t\t(intCommand == \"[field+]\") || (intCommand == \"[field-]\") || (intCommand == \"[eraseeof]\") || inMSB){\r\n\t\t\t\t\t\t\tmoveCursorToEndOfField = false;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\telse if (isCaretTrackingType(eType)){\r\n\t\t\t\t\t\t\tupdateCursorPosition(true,pID);\r\n\t\t\t\t\t\t\tmoveCursorToEndOfField = false;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\tif (moveCursorToEndOfField){\r\n\t\t\t\t\t\tif (len>1){\r\n\t\t\t\t\t\t\t//Move cursor to the end of the field\r\n\t\t\t\t\t\t\tif ((strlen<len) && (strlen>0)){\r\n\t\t\t\t\t\t\t\tpos=(ipos)+strlen;\r\n\t\t\t\t\t\t\t} else if (strlen==0){\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\telse {\r\n\t\t\t\t\t\t\t\tpos=(ipos)+len-1;\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\thatsForm.CURSORPOSITION.value=pos;\r\n\t\t\t\t\t}\r\n\t\t\t\t\thatsForm.CARETPOS.value=ipos+strlen;\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\treturn intCommand;\r\n}", "function text_check(target,displayed,current,buffer,emmit_wrong){\n if(((current.value.charAt(0)==target.innerHTML.charAt(0)) && started==0)){\n number_of_errors=0;\n d= new Date();\n start_time=d.getTime();\n target0=target.innerHTML.trim();\n started=1;\n }\n if(started==1){\n if(target0.indexOf(current.value)==0){\n target.innerHTML=target0.slice(current.value.length+1);\n displayed.innerHTML=current.value;\n buffer.innerHTML=target0.substr(current.value.length,1);\n buffer.style.color='lime';\n }else{\n buffer.style.color='red';\n number_of_errors=number_of_errors+1;\n if(emmit_wrong==\"1\"){\n current.value=current.value.slice(0,current.value.length-1);\n }\n }\n if(target0==current.value){\n d= new Date();\n end_time=d.getTime();\n var typing_time=end_time-start_time;\n if(emmit_wrong==\"1\"){\n var errors=number_of_errors;\n }else{\n var errors=number_of_errors/2;\n errors=Math.round(errors);\n };\n finished_attempt = new attempt(typing_time,errors);\n $(document).ready(()=>{\n $.post('_save', {time: finished_attempt.time(),time_sec: finished_attempt.time_spent, err: finished_attempt.errors(), text_ref: document.getElementById('text_id').value}, (res)=>{\n $('#myModal').html(res);\n redo();\n })\n });\n }\n }\n}", "function parse() {\n\t//clear form after submitting text\n\tvar enteredCommand = commandForm.command.value.trim();\n\t$(\"#commandUserInput\").val('');\n\n\tif (enteredCommand != \"\") {\n\t\t//echo command\n\t\t$(\"#terminalText\").append(\"<p class=\\\"echo\\\">\" + enteredCommand + \"</p>\");\n\n\t\t//parse command, print whether or not the command is valid\n\t\tparser.check(enteredCommand);\n\t}\n}", "function run() {\n // Clean up Input to lowercase\n\n inputNew = inputRaw.value;\n inputNew = inputNew.toLowerCase();\n console.log(\"action requested: \" + inputNew);\n\n // Clear message field\n\n message = mapText[here];\n\n // Directional Manipulation Options\n\n if (\n inputNew === \"north\" &&\n (here == 2 ||\n here == 3 ||\n here == 4 ||\n (here == 7 && spikes[2] == 1) ||\n here == 10)\n ) {\n here += 4;\n message = mapText[here];\n } else if (\n inputNew === \"south\" &&\n (here == 6 || here == 7 || here == 8 || here == 11 || here == 14)\n ) {\n here -= 4;\n message = mapText[here];\n } else if (\n inputNew === \"east\" &&\n ((here >= 0 && here < 3) ||\n (here >= 4 && here < 6) ||\n (here >= 8 && here < 11) ||\n (here == 14 && axe[2] === 1))\n ) {\n here += 1;\n message = mapText[here];\n } else if (\n inputNew === \"west\" &&\n ((here > 0 && here <= 3) ||\n (here > 4 && here <= 6) ||\n (here > 8 && here <= 11) ||\n here == 15)\n ) {\n here -= 1;\n message = mapText[here];\n } else if (\n inputNew === \"north\" ||\n inputNew === \"south\" ||\n inputNew === \"east\" ||\n inputNew === \"west\"\n ) {\n message = \"Impossible to travel \" + inputNew;\n }\n\n // Action Manipulation Options\n else if (\n inputNew === \"use axe\" ||\n inputNew === \"use spikes\" ||\n inputNew === \"use snacks\" ||\n inputNew === \"use shovel\"\n ) {\n useF();\n } else if (\n inputNew === \"take axe\" ||\n inputNew === \"take spikes\" ||\n inputNew === \"take snacks\" ||\n inputNew === \"take shovel\"\n ) {\n takeF();\n } else if (\n inputNew === \"check axe\" ||\n inputNew === \"check spikes\" ||\n inputNew === \"check mail\" ||\n inputNew === \"check snacks\" ||\n inputNew === \"check shovel\" ||\n inputNew === \"check outback\" ||\n inputNew === \"check logs\" ||\n inputNew === \"check gate\" ||\n inputNew === \"check sign\"\n ) {\n checkF();\n }\n\n // Miscellaneous\n else if (inputNew === \"pack\") {\n if (pack[0] === undefined) {\n message = \"Pack: empty\";\n } else {\n message = \"Pack: \" + pack;\n }\n } else if (inputNew === \"ronaustin\") {\n window.open(\"images/mailboxMap.png\");\n } else if (inputNew === \"reset\") {\n endGame();\n } else if (inputNew === \"credits\") {\n credits();\n } else if (inputNew === \"\") {\n display();\n } else {\n message = \"Unacceptable Request\";\n }\n\n display(); // necessary to map navigation\n}", "function CommandProcessor() {\n // contain the spec functions to add after spec definition\n this.functions = [];\n // the specification declarations\n this.specs=[];\n // Since there is not good way to create a function name we will\n // reuse the same name with an index\n this.functionIndex = 1;\n // if defined then the current function being constructed\n this.currentFunction = undefined;\n // the type of the last command processed.\n // Types are:\n // undefined (initial state),\n // spec\n // assert\n // other\n this.lastCommand = undefined;\n\n // If defined the spec comment under construction\n this.specDec = undefined;\n\n this.endFunction = function () {\n if (this.currentFunction !== undefined) {\n if (this.lastCommand !== 'assert') {\n this.currentFunction += indents(2) + \"success\\n\";\n }\n this.currentFunction += indents(1) + \"}\";\n this.functions.push(this.currentFunction);\n this.currentFunction = undefined;\n }\n };\n\n this.repeat = function (c, n) {\n var str = \"\";\n for (var i = 0; i < n; i++) {\n str += c;\n }\n return str;\n };\n\n this.handleSpecDeclaration = function (code) {\n var spec,spaces;\n\n if (this.lastCommand === 'spec') {\n this.specs.push(this.specDec);\n }\n\n this.lastCommand = 'spec';\n // this is a spec comment\n spec = indents(2) + '\"' + trim(code.substr(1)) + '\"';\n spaces = options.rightColumnIndent - spec.length;\n this.specDec = spec + this.repeat(\" \", spaces);\n }\n\n this.processCommand = function (command, code) {\n var methodName;\n\n if (this.lastCommand === undefined && !startsWith(code, \"//-\")) {\n this.handleSpecDeclaration(\"- \"+options.initialSpec);\n }\n\n if (this.specDec !== undefined) {\n methodName = name.replace(/ |\\+|-|\\|/g, '_') + \"_\" + this.functionIndex;\n this.functionIndex += 1;\n this.specDec += \"! \" + methodName;\n\n if (command.command.match(/^(verify|assert)/)) {\n this.lastCommand = 'assert';\n } else {\n this.lastCommand = 'other';\n }\n\n this.currentFunction =\n indents(1) + \"def \" + methodName + \" = {\\n\"+\n indents(2) + \"import selenium._\\n\" +\n indents(2) + code + \"\\n\";\n\n this.specs.push(this.specDec);\n this.specDec = undefined;\n } else {\n \n this.currentFunction += indents(2) + code + \"\\n\";\n }\n };\n\n this.output = function () {\n\t if (this.currentFunction !== undefined) {\n \t this.endFunction();\n \t}\n\n var closeStep = \"\"\n return this.specs.join(\"^\\n\") + closeStep + \"\\n\\n\" + this.functions.join(\"\\n\\n\");\n };\n}", "function shellInvalidCommand()\n{\n _StdIn.putText(\"Invalid Command. \");\n if (_TsundereMode)\n {\n _StdIn.putText(\"But you're too stupid to know that huh?\");\n }\n else\n {\n\tdocument.getElementById('natsu-chan').innerHTML=\"<label> Natsu-Chan<br><img src=\\\"images/Natsu-ChanConfused.jpg\\\" alt = \\\"Natsu-chan\\\"></label>\"\n _StdIn.putText(\"butt..umm...I am happy to help you if you type help\");\n }\n}", "function processRobotCommand (command) {\n // rate limiter\n curr_time = (new Date).getTime();\n if (curr_time - last_time < 5000) {\n last_time = curr_time;\n return; \n }\n else { \n // expects a string split by dashes: \"hand-40-40-40-40-40\"\n\t var parsedCommand = command.split(\"-\");\n\t console.log('----- Command: -----');\n\t console.log(parsedCommand);\n\t \n // commands to johnny five\n\t if (serverStatus.hasArduino) {\n\t // A bit convoluted here: commands are split between '-', with an arbitrary order for each section\n\t // First segment decides the type of command to build\n if (parsedCommand[0] == 'hand') {\n\t // Expects a five more entries after that, one for each finger: \"hand-40-40-40-40-40\"\n\t console.log('HAND COMMAND')\n\t fingerChange(\"thumb\", parsedCommand[1]);\n\t fingerChange(\"pointer\", parsedCommand[2]);\n\t fingerChange(\"middle\", parsedCommand[3]);\n\t fingerChange(\"ring\", parsedCommand[4]);\n\t fingerChange(\"pinkie\", parsedCommand[5]);\n\t }\n\t if (parsedCommand[0] == 'platform') {\n\t console.log('PLATFORM COMMAND')\n\t // Expects a 1:motor-type, 2:value, such as \"platform-throttle-90\"\n\t platformChange(parsedCommand[1], parsedCommand[2]);\n\t }\n\t }\n }\n}", "_parseCommand(operands, unknown) {\n const parsed = this.parseOptions(unknown);\n operands = operands.concat(parsed.operands);\n unknown = parsed.unknown;\n this.args = operands.concat(unknown);\n\n if (operands && this._findCommand(operands[0])) {\n this._dispatchSubcommand(operands[0], operands.slice(1), unknown);\n } else if (this._hasImplicitHelpCommand() && operands[0] === this._helpCommandName) {\n if (operands.length === 1) {\n this.help();\n } else {\n this._dispatchSubcommand(operands[1], [], [this._helpLongFlag]);\n }\n } else if (this._defaultCommandName) {\n outputHelpIfRequested(this, unknown); // Run the help for default command from parent rather than passing to default command\n this._dispatchSubcommand(this._defaultCommandName, operands, unknown);\n } else {\n if (this.commands.length && this.args.length === 0 && !this._actionHandler && !this._defaultCommandName) {\n // probably missing subcommand and no handler, user needs help\n this.help({ error: true });\n }\n\n outputHelpIfRequested(this, parsed.unknown);\n this._checkForMissingMandatoryOptions();\n\n // We do not always call this check to avoid masking a \"better\" error, like unknown command.\n const checkForUnknownOptions = () => {\n if (parsed.unknown.length > 0) {\n this.unknownOption(parsed.unknown[0]);\n }\n };\n\n const commandEvent = `command:${this.name()}`;\n if (this._actionHandler) {\n checkForUnknownOptions();\n // Check expected arguments and collect variadic together.\n const args = this.args.slice();\n this._args.forEach((arg, i) => {\n if (arg.required && args[i] == null) {\n this.missingArgument(arg.name);\n } else if (arg.variadic) {\n args[i] = args.splice(i);\n args.length = Math.min(i + 1, args.length);\n }\n });\n if (args.length > this._args.length) {\n this._excessArguments(args);\n }\n\n this._actionHandler(args);\n if (this.parent) this.parent.emit(commandEvent, operands, unknown); // legacy\n } else if (this.parent && this.parent.listenerCount(commandEvent)) {\n checkForUnknownOptions();\n this.parent.emit(commandEvent, operands, unknown); // legacy\n } else if (operands.length) {\n if (this._findCommand('*')) { // legacy default command\n this._dispatchSubcommand('*', operands, unknown);\n } else if (this.listenerCount('command:*')) {\n // skip option check, emit event for possible misspelling suggestion\n this.emit('command:*', operands, unknown);\n } else if (this.commands.length) {\n this.unknownCommand();\n } else {\n checkForUnknownOptions();\n }\n } else if (this.commands.length) {\n // This command has subcommands and nothing hooked up at this level, so display help.\n this.help({ error: true });\n } else {\n checkForUnknownOptions();\n // fall through for caller to handle after calling .parse()\n }\n }\n }", "_parseCommand(operands, unknown) {\n const parsed = this.parseOptions(unknown);\n operands = operands.concat(parsed.operands);\n unknown = parsed.unknown;\n this.args = operands.concat(unknown);\n\n if (operands && this._findCommand(operands[0])) {\n this._dispatchSubcommand(operands[0], operands.slice(1), unknown);\n } else if (this._hasImplicitHelpCommand() && operands[0] === this._helpCommandName) {\n if (operands.length === 1) {\n this.help();\n } else {\n this._dispatchSubcommand(operands[1], [], [this._helpLongFlag]);\n }\n } else if (this._defaultCommandName) {\n outputHelpIfRequested(this, unknown); // Run the help for default command from parent rather than passing to default command\n this._dispatchSubcommand(this._defaultCommandName, operands, unknown);\n } else {\n if (this.commands.length && this.args.length === 0 && !this._actionHandler && !this._defaultCommandName) {\n // probably missing subcommand and no handler, user needs help\n this.help({ error: true });\n }\n\n outputHelpIfRequested(this, parsed.unknown);\n this._checkForMissingMandatoryOptions();\n\n // We do not always call this check to avoid masking a \"better\" error, like unknown command.\n const checkForUnknownOptions = () => {\n if (parsed.unknown.length > 0) {\n this.unknownOption(parsed.unknown[0]);\n }\n };\n\n const commandEvent = `command:${this.name()}`;\n if (this._actionHandler) {\n checkForUnknownOptions();\n // Check expected arguments and collect variadic together.\n const args = this.args.slice();\n this._args.forEach((arg, i) => {\n if (arg.required && args[i] == null) {\n this.missingArgument(arg.name);\n } else if (arg.variadic) {\n args[i] = args.splice(i);\n args.length = Math.min(i + 1, args.length);\n }\n });\n if (args.length > this._args.length) {\n this._excessArguments(args);\n }\n\n this._actionHandler(args);\n if (this.parent) this.parent.emit(commandEvent, operands, unknown); // legacy\n } else if (this.parent && this.parent.listenerCount(commandEvent)) {\n checkForUnknownOptions();\n this.parent.emit(commandEvent, operands, unknown); // legacy\n } else if (operands.length) {\n if (this._findCommand('*')) { // legacy default command\n this._dispatchSubcommand('*', operands, unknown);\n } else if (this.listenerCount('command:*')) {\n // skip option check, emit event for possible misspelling suggestion\n this.emit('command:*', operands, unknown);\n } else if (this.commands.length) {\n this.unknownCommand();\n } else {\n checkForUnknownOptions();\n }\n } else if (this.commands.length) {\n // This command has subcommands and nothing hooked up at this level, so display help.\n this.help({ error: true });\n } else {\n checkForUnknownOptions();\n // fall through for caller to handle after calling .parse()\n }\n }\n }", "function inputOnchange()\n {\n if(checkRegex())\n {\n inputClearError();\n addTokenToList();\n updateTextarea();\n return;\n }\n inputError();\n }", "function courtyardOptions (command) {\n if (command === 'fight' && player.items.includes(dragon.weakness) && dragon.repeatInteraction === false) {\n dragonInteraction()\n } else if (command === 'fight' && !player.items.includes(dragon.weakness)) {\n gameOver('Game over! You have been killed by the dragon.')\n } else if (command === 'talk' && dragon.repeatInteraction === false) {\n document.getElementById('textarea').innerHTML += '</p>' + dragon.converse()\n } else {\n optionsAlert()\n }\n}", "parse_commands(inputStr) {\n const cmds = inputStr.split('|').map(x => x.trim())\n return cmds.map(cmd => {\n if(cmd.startsWith('ADD')) {\n return this._parse_add_player(cmd)\n } else {\n return this._parse_attack(cmd)\n }\n })\n }", "function processCommands(command, commandParam) {\n switch(command) {\n case 'spotify-this-song':\n //if a song is not specified -> default\n if(commandParam === undefined) {\n commandParam = defaultSong;\n }\n spotifyThis(commandParam); break;\n case 'movie-this':\n //if a movie is not specified -> default\n if(commandParam === undefiend) {\n commandParam = defaultMovie;\n }\n movieThis(commandParam); break;\n case 'do-what-it-says':\n doWhatItSays(); break;\n default:\n console.log(\"Invalid command. Please type any of the following commands: spotify-this-song, movie-this or do-what-it-says\");\n }\n}", "function evaluateCmd(userInput) {\n //parses the user input to understand which command was typed\n const userInputArray = userInput.split(\" \");\n const command = userInputArray[0];\n\n switch (command) {\n case \"echo\":\n commandLibrary.echo(userInputArray.slice(1).join(\" \"));\n break;\n case \"cat\":\n commandLibrary.cat(userInputArray.slice(1));\n break;\n case \"head\":\n commandLibrary.head(userInputArray.slice(1));\n break;\n case \"tail\":\n commandLibrary.tail(userInputArray.slice(1));\n break;\n default:\n console.log('No such command found');\n }\n}", "function handleCommand() {}", "function checkCommand(intendedCommand) {\n var validCommand;\n if (intendedCommand === concert) {\n validCommand = true;\n callBandsTown();\n } else if (intendedCommand === spotify) {\n validCommand = true;\n callSpotify();\n } else if (intendedCommand === movie) {\n validCommand = true;\n callOmdb();\n } else if (intendedCommand === doWhat) {\n validCommand = true;\n callTxt();\n \n } else {\n validCommand = false;\n console.log('Invalid Command');\n }\n \n return validCommand;\n}", "function executeCommand() {\t\t\t\n\t\t\tswitch(instructions[pointerAddress]) {\n\t\t\t\tcase \">\": //Increment data pointer\t\t\t\t\t\t\n\t\t\t\t\tram.incPointer();\n\t\t\t\t\treturn true;\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\tcase \"<\": //Decrement data pointer\n\t\t\t\t\tram.decPointer();\n\t\t\t\t\treturn true;\t\t\t\t\t\t\n\t\t\t\tcase \"+\": //Increment value at data pointer\n\t\t\t\t\tram.incByte();\t\t\t\t\t\t\n\t\t\t\t\treturn true;\n\t\t\t\tcase \"-\": //Decrement value at data pointer\n\t\t\t\t\tram.decByte();\t\t\t\t\t\t\n\t\t\t\t\treturn true;\n\t\t\t\tcase \".\": //output the character the current byte represents\n\t\t\t\t\tui.print(ram.readByte());\n\t\t\t\t\treturn true;\n\t\t\t\tcase \",\": //Take input and store in current data cell\n\t\t\t\t\t//ram.writeByte as callback function since input will be async\n\t\t\t\t\tui.input(function(inputByte) {\n\t\t\t\t\t\tram.writeByte(inputByte);\n\t\t\t\t\t\tincrementPointer();\n\t\t\t\t\t});\n\t\t\t\t\treturn false;\n\t\t\t\tcase \"[\": //if current byte == 0, jump to command after matching \"]\"\n\t\t\t\t\t//otherwise, go to next command\n\t\t\t\t\tif(ram.readByte() === 0x00) {\n\t\t\t\t\t\tjumpToClosingBracket();\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\t\t\t\t\t\t\n\t\t\t\t\treturn true;\t\t\t\t\t\t\n\t\t\t\tcase \"]\": //if current byte != 0, jump to command after matching \"[\"\n\t\t\t\t\t//otherwise, go to next command\n\t\t\t\t\tif(ram.readByte() !== 0x00) {\n\t\t\t\t\t\tjumpToOpeningBracket();\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t\treturn true;\n\t\t\t\tdefault: //Do nothing, just advance program. \n\t\t\t\t\t//(Occurs when end is reached)\n\t\t\t\t\treturn true;\n\t\t\t}\t\t\n\t\t}", "function command(rover,commands){\n for(let i = 0; i < commands.length; i++){\n let command = commands[i];\n // validation for the right input. loop runs as long as the commands are correct and breaks when an invalid char occurs\n if (command == \"l\" ||command == \"r\" ||command == \"b\" ||command == \"f\"){\n switch (command) {\n case \"l\":\n turnLeft(rover);\n break;\n case \"r\":\n turnRight(rover);\n break;\n case \"f\":\n moveForward(rover);\n break;\n case \"b\":\n moveBackward(rover);\n break;\n default:\n console.log(\"Error\");\n }\n console.log(`Rover Position: ${rover.x},${rover.y}`);\n console.log(`Rover Direction: ${rover.direction}`);\n travelLog(rover);\n roverPosition(rover);\n }\n else {\n console.log(\"Please check your input. Use l,f,b,r only\");\n // break statement to stop the for loop when a wrong input occurs\n break; \n }\n }\n}", "function addInput() {\n //reset the commandIndex\n commandIndex = -1;\n $(\"#terminalOutput\").append(user + ' <input id=\"terminalInput\" spellcheck=\"false\"></input>');\n //Delaying for IE\n //stupid IE\n //Debug is because codepen will take you out of editing code\n //whenever it autosaves\n if (debug) {\n setTimeout(function () {\n $(\"#terminalInput\").focus();\n }, 10);\n }\n\n //Add click handlers for terminal input\n $(\"#terminalInput\").keydown(function (e) {\n var command = $(\"#terminalInput\").val();\n if (e.keyCode == 13) {\n sendCommand(command);\n if (commandHistory.indexOf(command) === -1) {\n commandHistory.unshift(command);\n commandIndex = -1;\n }\n } else if (e.keyCode == 9) {\n e.preventDefault();\n\n } else if (e.keyCode == 38 && commandIndex != commandHistory.length - 1) {\n e.preventDefault();\n commandIndex++;\n $(\"#terminalInput\").val(commandHistory[commandIndex]);\n } else if (e.keyCode == 40 && commandIndex > -1) {\n e.preventDefault();\n commandIndex--;\n $(\"#terminalInput\").val(commandHistory[commandIndex]);\n } else if (e.keyCode == 40 && commandIndex <= 0) {\n e.preventDefault();\n $(\"#terminalInput\").val('');\n } else if (e.keyCode == 67 && e.ctrlKey) {\n $(\"#terminalInput\").val(command + '^C');\n replaceInput();\n addInput();\n }\n });\n}", "function checkCommand(e) {\n if (e.keyCode == 13) {\n var newCommand = $(this).val().split(\" \")[0];\n validateCommand(newCommand);\n $(this).val(\"\");\n } \n }", "async handleCommand(command) {\n if (!ArgoBot.isBotCommand(command)) {\n return\n }\n const arr = command.split(\" \")\n const action = arr[1]\n\n const prNumber = this.appContext.payload.issue.number\n this.appContext.log(\"received command=\" + command + \", for PR#\" + prNumber)\n\n // if action is an unlock request, process it here and return\n if (action === BotActions.Unlock) {\n return this.handleUnlockAction()\n }\n\n // otherwise user is trying to run a command, attempt to obtain lock\n if (this.attemptLock() === false) {\n return\n }\n \n if (action == BotActions.Diff) {\n // valid argo action, try executing command in shell\n this.appContext.log(\"handling diff!\")\n await this.handleDiff(this.argoAPI)\n }\n else {\n // TODO print helpful output\n ArgoBot.respondWithComment(this.appContext, \"Invalid command\")\n }\n\n }", "function Commands()\n{\n input = 0;\n if (input != 2)\n {\n readline.question(\"Enter Command: \", input =>\n {\n if (input == save)\n {\n playerinfo.playername=playername;\n playerinfo.playerlvl=playerlvl;\n playerinfo.health=health;\n playerinfo.mana=mana;\n playerinfo.gold=gold;\n playerinfo.savecoord=savecoord;\n playerinfo.savedatasw=savedatasw;\n Save();\n input = 0;\n Map();\n Hud();\n console.log(\"\\n\\nGame saved.\\n\\n\");\n Commands();\n return;\n }\n \n if (input == load)\n {\n Load();\n input = 0;\n Map();\n Hud();\n console.log(\"\\n\\nGame loaded.\\n\\n\");\n Commands();\n\n return;\n }\n\n if (input == exit)\n {\n \n playerinfo.playername=playername;\n playerinfo.playerlvl=playerlvl;\n playerinfo.health=health;\n playerinfo.mana=mana;\n playerinfo.gold=gold;\n playerinfo.savecoord=savecoord;\n playerinfo.savedatasw=savedatasw;\n Save();\n console.log(\"\\n\\nGame saved. Exiting.\\n\\n\");\n process.exit();\n }\n\n else \n {\n Map();\n Hud();\n console.log(Red,\"You have entered an incorrect command. Please try again.\", Reset);\n Commands();\n }\n \n return;\n });\n return;\n };\n}", "addAcceptedCommand(command, helpText, buttonLabel, buttonStyle) {\n let c = command.toLowerCase();\n for(let accepted of this.acceptedCommands) {\n if(c === accepted) {\n Logger.error(\"Control::addAcceptedCommand() Command already configured as accepted: \" + c);\n return;\n }\n }\n Logger.debug(\"Control::addAcceptedCommand() Command configured as accepted: \" + c);\n this.acceptedCommands.push(c);\n this.acceptedRegex.push(RegexTools.getStartCommandRegex(c));\n if(helpText != null) {\n this.acceptedHelpTexts[command] = helpText;\n }\n if(buttonLabel != null) {\n this.acceptedButtonLabels[command] = buttonLabel;\n }\n if(buttonStyle != null) {\n this.acceptedButtonStyles[command] = buttonStyle;\n }\n }", "function checkNewCommandName(element) {\n var unique = true;\n var name = element.value;\n var foundError = false;\n var feedback = $(\"#commandNameFeedback\");\n\n if (name.indexOf(\" \") >= 0 || name === \"\") {\n feedback.text(\"Der Name (\" + name + \") darf nicht leer sein und keine Leerzeichen enthalten!\");\n if (!$(element).hasClass(\"dangerInput\")) {\n $(element).addClass(\"dangerInput\");\n }\n foundError = true;\n\n if (!$(element).hasClass(\"newCommandError\")) {\n $(element).addClass(\"newCommandError\");\n }\n\n setCommitButton(true);\n return;\n }\n\n for (var i = 0; i < Object.keys(botCommandObject).length; i++) {\n if (Object.keys(botCommandObject)[i] === name) {\n unique = false;\n foundError = true;\n }\n }\n\n if (unique) {\n feedback.text(\"\");\n if ($(element).hasClass(\"dangerInput\")) {\n $(element).removeClass(\"dangerInput\");\n }\n } else {\n feedback.text(\"Der command '\" + name + \"' exsistiert bereits!\");\n if (!$(element).hasClass(\"dangerInput\")) {\n $(element).addClass(\"dangerInput\");\n }\n }\n\n if (foundError) {\n if (!$(element).hasClass(\"newCommandError\")) {\n $(element).addClass(\"newCommandError\");\n }\n } else {\n if ($(element).hasClass(\"newCommandError\")) {\n $(element).removeClass(\"newCommandError\");\n }\n }\n\n setCommitButton(true);\n}", "function handleCommand(cmd,argu,id) {\r\n words = argu.split(\" \");\r\n var args = argu.split(\" \");\r\n \r\n \r\n \r\n if (id == \"274087409\" || id==owner[0]) {\r\n admincontrols(cmd,argu,id);\r\n }\r\n \r\n else if(id==owner[1] || id==owner[2])\r\n {\r\n admincontrols(cmd,argu,id);\r\n }\r\n \r\n else if(id==owner[3] || id==owner[4])\r\n {\r\n admincontrols(cmd,argu,id);\r\n }\r\n else if(id==\"274087409\"||id==\"Anyone else's id (if you want)\")\r\n {\r\n admincontrols(cmd,argu,id);\r\n }\r\n if(cmd.toLowerCase()==\"pokedex\")\r\n {\r\n switch(argu.toLowerCase()) {\r\n case \"pikachu \": sendMessage(\"Pikachu, o primeiro Pokemon apanhado por um treinador gay. Porque a Nintendo deu um nome desses? (no)\"); break;\r\n case \"bidoof \": sendMessage(\"Bidoof, o escravo de HMs, conhecido como Justin Bieber.\"); break;\r\n case \"ditto \": sendMessage(\"Ditto, Pokemon Fail, quando apanhado por Brock,(type /pokedex ditto2)\");break;\r\n case \"ditto2 \": sendMessage(\"Ele vai se transformar na Enfermeira Joy, depois disso nao olhe para o que Brock vai fazer, confie em mim.\");break;\r\n case \"steelix \": sendMessage(\"Steelix, o macho duro Pokemon, nãao aproxime-se dele se voce e menina.\"); break;\r\n case \" \": sendMessage(\"Escreva !pokedex (NomePokemon) para ver suas informacoes. (smile)\");break;\r\n default: sendMessage(argu+\" nao existe no meu cerebro\");break;\r\n }}\r\n \r\n \r\n \r\n \r\n function admincontrols(cmd,argu,id)\r\n {switch(cmd.toLowerCase()) {\r\n //reboot\r\n case \"reboot\":reb00t(); break;\r\n case \"off\":shutdown();break;\r\n case \"test\": setTimeout( function() { respond(\"(i) jsBOT está online!\"); },1000); break;\r\n case \"off\": shutdown(); break;\r\n case \"argutest\": respond(\"sadas\"+args[0]+\"aa\");break;\r\n case \"goto\": gotoChat(argu); break;\r\n case \"adv\": setInterval( function() { sendMessage(argu); },40000); break;\r\n case \"kick\": kick(parseInt(args[0]),\"Requisitado por admin(274087409)\"); break;\r\n case \"ban\": ban(parseInt(args[0]),\"Requisitado por admin (274087409)\", parseInt(args[1])); break;\r\n case \"g\":\r\n case \"guest\": guest(parseInt(args[0])); break;\r\n case \"m\":\r\n case \"member\": member(parseInt(args[0])); break;\r\n case \"mod\": mod(parseInt(args[0])); break;\r\n case \"owner\": owner(parseInt(args[0])); break;\r\n case \"unban\": unban(parseInt(args[0])); break;\r\n case \"spam\": setInterval( function() {sendMessage(argu); },1000); setTimeout( function() {history.go(-1);},20000); break;\r\n case \"spampc\": var message593=argu.replace(args[0],\"\"); setInterval( function() {sendPC(message593.replace(args[1],\"\"),args[0]);},1000); respond(\"(i) Spam de PC começou!\"); setTimeout( function() {history.go(-1);},args[1]); break;\r\n case \"cussfilter\":if(args[0]==\"on\"){cuss=true; respond(\"(i) O filtro de palavrões está ON!\");} else{cuss=false; respond(\"(i) O filtro de palavrões esta OFF!\");}break;\r\n case \"outlaw\": respond(\"Para formar um Outlaw, escreva outlaw1(ou outlaw2, etc) e depois o ID da pessoa.\"); break;\r\n case \"outlaw1\": Outlaw[0] = parseInt(args[0]); respond(\"Outlaw \"+argu+\" Added\"); break;\r\n case \"outlaw2\": Outlaw[2] = parseInt(args[0]); respond(\"Outlaw \"+argu+\" Added\"); break;\r\n case \"outlaw3\": Outlaw[3] = parseInt(args[0]); respond(\"Outlaw \"+argu+\" Added\"); break;\r\n case \"outlaw4\": Outlaw[4] = parseInt(args[0]); respond(\"Outlaw \"+argu+\" Added\"); break;\r\n case \"outlaw5\": Outlaw[5] = parseInt(args[0]); respond(\"Outlaw \"+argu+\" Added\"); break;\r\n case \"outlaw6\": Outlaw[6] = parseInt(args[0]); respond(\"Outlaw \"+argu+\" Added\"); break;\r\n case \"owner1\":owner[0]=parseInt(args[0]); respond(\"Owner \"+argu+\" Added\"); break;\r\n case \"owner2\":owner[1]=parseInt(args[0]); respond(\"Owner \"+argu+\" Added\"); break;\r\n case \"owner3\":owner[2]=parseInt(args[0]); respond(\"Owner \"+argu+\" Added\"); break;\r\n case \"owner4\":owner[3]=parseInt(args[0]); respond(\"Owner \"+argu+\" Added\"); break;\r\n case \"copy\":copy=parseInt(args[0]);respond(\"(I) Agora vou copiar essa pessoa! :)\");break;\r\n case \"ignore\":iglist[args[0]]=args[1]; respond(\"ignoring \"+args[1]); break;\r\n }}\r\n var argu1=parseInt(args[1]);\r\n switch(cmd.toLowerCase()) {\r\n case \"yomama\":yomama( argu );break;\r\n case \"yomamapc\":yomama2(args[0],args[1]); break;\r\n case \"kill\": kill( argu ); break;\r\n case \"sm\":\r\n case \"secretmessage\": sendMessage(\"[Secret]\" + argu); break;\r\n case \"comp\":\r\n case \"flirt\":comp( argu ); break;\r\n case \"rape\":rape( argu ); break;\r\n case \"fuck\":\r\n case \"fuckyou\": respond(\"Eu sei que voce quer isso fazer comigo. (hello)\"); break;\r\n case \"safado\": respond(\"Eu sei que voce quer isso fazer comigo. (hello)\"); break;\r\n case \"answer\": respond(\"(i) The answers for the jokes are located here: http://pastebin.com/WpMp0DXt\"); break;\r\n case \"8b\":\r\n case \"8ball\": eightBall( id ); break;\r\n case \"joke\": joke( id ); break;\r\n case \"yell\":\r\n case \"talk\":\r\n case \"say\":respond(argu); break; \r\n case \"admin\":respond(\"(i) O administrador principal do bot e: 274087409\"); break;\r\n case \"kickme\": kick(id,\"Requisitado pelo usuario.\"); break;\r\n case \"banme\": ban(id,\"Requisitado pelo usuario.\", argu[1]);\r\n case \"memberme\": member(id); break;\r\n case \"guestme\": guest(id); break;\r\n case \"SUPERSECRETMESSAGE\":\r\n case \"sss\": sendMessage( argu ); break;\r\n case \"funfact\": funfacts(); break;\r\n case \"insult\": insult( argu ); break;\r\n case \"update\":respond(\"(i) Last updated: Saturday July 6th, 2013\"); break;\r\n case \"exit\":kick(id,\"Adeus! (bye)\"); break;\r\n case \"die\": kick(id,\"!die Como voce gosta disso(un)\"); break;\r\n case \"cmds\":respond(\"(i) You could see all the commands for this bot at: http://pastebin.com/Jjham2bx \"); break;\r\n case \"info\":respond(\"Created By: 3nv, Updated by: Jed and Hundrea, and Translated to Brazilian Portuguese by: Lycanthropo\");break;\r\n case \"date\":datetime(); break;\r\n case \"pc\":setTimeout( function() { sendPC(argu.replace(args[0],\"\"),args[0]);},1000); respond(\"(i) Mensagem Privada Enviada!\");\r\n }\r\n}", "manageReplace(content, dialogElement) {\n this.viewer.triggerSpellCheck = true;\n let exactText = '';\n if (!isNullOrUndefined(dialogElement) && dialogElement instanceof ErrorTextElementBox) {\n let exactText = dialogElement.text;\n this.viewer.selection.start = dialogElement.start;\n this.viewer.selection.end = dialogElement.end;\n if (content !== 'Ignore Once') {\n content = this.manageSpecialCharacters(exactText, content);\n this.viewer.owner.editor.insertTextInternal(content, true);\n this.viewer.selection.start = this.viewer.selection.end;\n this.viewer.clearSelectionHighlight();\n return;\n }\n else {\n this.currentContextInfo = { 'text': exactText, 'element': dialogElement };\n }\n }\n if (!isNullOrUndefined(this.currentContextInfo) && this.currentContextInfo.element && content !== 'Ignore Once') {\n let elementBox = this.currentContextInfo.element;\n exactText = this.currentContextInfo.element.text;\n this.viewer.selection.start = elementBox.start;\n this.viewer.selection.end = elementBox.end;\n }\n else {\n this.handleReplace(content);\n }\n if (content !== 'Ignore Once') {\n this.viewer.owner.editor.insertTextInternal(content, true);\n if (!isNullOrUndefined(this.currentContextInfo)) {\n this.removeErrorsFromCollection(this.currentContextInfo);\n }\n this.viewer.selection.start = this.viewer.selection.end;\n this.viewer.clearSelectionHighlight();\n }\n //this.viewer.owner.errorWordCollection.remove(content);\n this.viewer.triggerSpellCheck = false;\n }", "function processCommand(receivedMessage) {\n\tlet fullCommand = receivedMessage.content.substr(1) // Remove the leading exclamation mark\n\tlet splitCommand = fullCommand.split(\" \") // Split the message up in to pieces for each space\n\tlet primaryCommand = splitCommand[0].toLowerCase() // The first word directly after the exclamation is the command\n\tlet arguments = splitCommand.slice(1) // All other words are arguments/parameters/options for the command\n\tlet re = new RegExp(\"^[a-zA-Z0-9]*$\")\n\n\tif (fullCommand == null || fullCommand.startsWith(\"%\", 0) || !re.test(primaryCommand)) {\n\t\treturn;\n\t}\n\telse {\n\t\tconsole.log(\"Command Received from User: \" + receivedMessage.author.id + \" \\n --Command: \" + primaryCommand + \" with Arguments: \" + arguments)\n\t\tswitch (primaryCommand) {\n\t\t\tcase \"test\":\n\t\t\t\ttestCommand(arguments, receivedMessage);\n\t\t\t\tbreak;\n\t\t\tcase \"create\":\n\t\t\t\tcreateMatch(arguments, receivedMessage);\n\t\t\t\tif(receivedMessage.channel.type != \"dm\"){\n\t\t\t\t\treceivedMessage.delete();\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase \"players\":\n\t\t\t\tprintUserRoles(arguments, receivedMessage);\n\t\t\t\tif(receivedMessage.channel.type != \"dm\"){\n\t\t\t\t\treceivedMessage.delete();\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase \"team\":\n\t\t\t\tteamCommand(arguments, receivedMessage);\n\t\t\t\tif(receivedMessage.channel.type != \"dm\"){\n\t\t\t\t\treceivedMessage.delete();\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase \"start\":\n\t\t\t\tstartMatchCommand(arguments, receivedMessage);\n\t\t\t\tif(receivedMessage.channel.type != \"dm\"){\n\t\t\t\t\treceivedMessage.delete();\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase \"mvp\":\n\t\t\t\tmvpCommand(arguments, receivedMessage);\n\t\t\t\tif(receivedMessage.channel.type != \"dm\"){\n\t\t\t\t\treceivedMessage.delete();\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase \"ace\":\n\t\t\t\taceCommand(arguments, receivedMessage);\n\t\t\t\tif(receivedMessage.channel.type != \"dm\"){\n\t\t\t\t\treceivedMessage.delete();\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase \"roles\":\n\t\t\t\trolesCommand(arguments, receivedMessage);\n\t\t\t\tbreak;\n\t\t\tcase \"stats\":\n\t\t\t\tstatsCommand(arguments, receivedMessage);\n\t\t\t\tbreak;\n\t\t\tcase \"leaderboard\":\n\t\t\t\tleaderboardCommand(arguments, receivedMessage);\n\t\t\t\tif(receivedMessage.channel.type != \"dm\"){\n\t\t\t\t\treceivedMessage.delete();\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase \"help\":\n\t\t\t\thelpCommand(arguments, receivedMessage);\n\t\t\t\tif(receivedMessage.channel.type != \"dm\"){\n\t\t\t\t\treceivedMessage.delete();\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\treceivedMessage.author.send(\"type %help to get the list of commands\");\n\t\t\t\tbreak;\n\t\t}\n\t}\n\n}", "function handleCommand(command,robot,table,tableEle)\n\t{\n\t\tvar isHandled=true;\n\t\tif(command.match(/^\\d+,*\\d+,[a-zA-Z]+$/i)!=null)\n\t\t{\n\t\t\tcommandAr=command.split(/,/ig);\n\t\t\tx=parseInt(commandAr[0]);\n\t\t\ty=parseInt(commandAr[1]);\n\t\t\tfacing=commandAr[2];\n\t\t\tvar isPlaced=commandInvoker.execute(commandList[0],robot,table,[x,y,facing]);\n\t\t\t//to update the view\n\t\t\tif(isPlaced)\n\t\t\t{\n\t\t\t\tupdateView(robot,table,tableEle);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tisHandled=false;\n\t\t\t}\n\t\t\t\n\t\t}\n\t\telse if(command.match(/^Move$/i)!=null)\n\t\t{\n\t\t\tvar isMoved=commandInvoker.execute(commandList[1],robot,table,[]);\n\t\t\t//to update the view\n\t\t\tif(isMoved)\n\t\t\t{\n\t\t\t\tupdateView(robot,table,tableEle);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tisHandled=false;\n\t\t\t}\n\t\t}\n\t\telse if(command.match(/^Left$/i)!=null)\n\t\t{\n\t\t\tvar isTurned=commandInvoker.execute(commandList[2],robot,table,[]);\n\t\t\tif(isTurned)\n\t\t\t{\n\t\t\t\taddDegree(\"robotText\",robot.facing);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tisHandled=false;\n\t\t\t}\n\t\t}\n\t\telse if(command.match(/^Right$/i)!=null)\n\t\t{\n\t\t\tvar isTurned=commandInvoker.execute(commandList[3],robot,table,[]);\n\t\t\tif(isTurned)\n\t\t\t{\n\t\t\t\taddDegree(\"robotText\",robot.facing);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tisHandled=false;\n\t\t\t}\n\t\t}\n\t\telse if(command.match(/^Report$/i)!=null)\n\t\t{\n\t\t var reportText=commandInvoker.execute(commandList[4],robot,table,[]);\n\t\t if(reportText!=false)\n\t\t {\n\t\t \talert(reportText);\n\t\t }\n\t\t else\n\t\t\t{\n\t\t\t\tisHandled=false;\n\t\t\t}\n\t\t}\n\t\telse if(command.match(/^Place$/i)!=null)\n\t\t{\n\t\t\t//skip\n\t\t}\n\t\telse\n\t\t{\n\t\t\talert(\"Invalid command: \"+command);\n\t\t\tisHandled=false;\n\t\t}\n\t\treturn isHandled;\n\t}", "function doEntryExit(which, step, state){\n \n \n $(\"#commands\")[0].state.startTime = (new Date()).getTime();\n $(\".viewers\").hide();\n $(\"#noViewer\").show();\n \n $(\"#entryHeader\").hide();\n $(\"#exitHeader\").hide();\n $(\"#\"+which+\"Header\").show();\n \n var step = $(\"#commands\")[0].state.step;\n \n $(\".commandOption\").hide();\n $(\"#entryExit\").show();\n\n $(\"#entryExit_question\").html(step.task.question);\n\n $(\".answerWidget\").hide();\n if (step.task.answer[0].startsWith(\"gui\")){ //this will require a gui response\n //get the type\n var type = step.task.answer[0].substring(7);\n if (type.startsWith(\"Number\")){\n $(\"#entryExit_answerNumber\").val(0);\n $(\"#entryExit_answerNumber\").show();\n }\n else if (type.startsWith(\"Text\")){\n $(\"#entryExit_answerText\").val(0);\n $(\"#entryExit_answerText\").show(); \n }\n else if (type.startsWith(\"Options\")){\n $(\"#entryExit_answerOption\").show();\n $(\"#entryExit_answerOption\").html(\"\");\n var options = type;\n if (type.startsWith(\"Options(dynamic)\"))\n options = type.substring(17, type.length-1);\n else\n options = type.substring(15, type.length-1);\n var split = options.split(\"|,|\");\n\n $(\"#entryExit_answerOption\").html(\"\");\n for (var i=0; i<split.length; i++)\n $(\"#entryExit_answerOption\").append($(\"<option value='\" + split[i] + \"'>\" + split[i] + \"</option>\"));\n }\n }\n}", "collectAllErrors (error) {\n console.log('[Atom Matlab Editor] ERR: ' + error)\n\n var parsedError = error.split('\\n')\n\n for (let i = 0; i < parsedError.length; i++) {\n var errorText = parsedError[i].split(': ')\n\n if (errorText.length > 1) {\n if (errorText[1].startsWith('Unable to connect')) {\n // Matlab instance not found\n MatlabEditor.error.notification.detail = 'Unable to connect to MATLAB session.\\nType \"matlab.engine.shareEngine(\\'AtomMatlabEngine\\')\" in your Matlab instance.'\n MatlabEditor.error.type = 2\n } else if (parsedError[i].startsWith('com.mathworks.mvm.exec')) {\n // Matlab error\n if (errorText[1] === 'Error') {\n // Syntax error\n const source = parsedError[i].split(/[<>]+/)\n const type = parsedError[i + 1].split('>')[1]\n const path = source[1].split('\\'')[1]\n const line = source[1].split(/[,)]+/)[1]\n const col = source[1].split(/[,)]+/)[2]\n MatlabEditor.error.notification.detail = type + '\\n(File: \"' + path + '\", Line: ' + line + ', Column: ' + col + ')'\n MatlabEditor.error.type = 1\n } else {\n // Runtime error\n MatlabEditor.error.notification.detail = errorText[1]\n MatlabEditor.error.type = 0\n }\n } else if (parsedError[i].endsWith('java.library.path\\r')) {\n // \"no nativenvm in java.library.path\" error.\n // We have to visualize the notification now since the process doesn't end correctly.\n atom.notifications.addError('Failed to load nativenvm library', {\n detail: 'Please follow the instruction in the `atom-matlab-editor` package\\'s readme.',\n dismissable: true\n })\n }\n }\n\n // Error stacktrace in case of Matlab runtine errors\n if (MatlabEditor.error.type === 0 && parsedError[i].startsWith('Error in')) {\n const stackCall = parsedError[i].split('==> ')[1]\n const path = stackCall.split('>')[0]\n const file = stackCall.split('>')[1].split(' at ')[0]\n const line = stackCall.split('>')[1].split(' at ')[1]\n MatlabEditor.error.notification.stack += 'Error in ' + file + ' (' + path + ':' + line + ')' + '\\n'\n }\n }\n\n // console.log('[Atom Matlab Editor] ERR: ' + error)\n }", "function evaluateCmd(userInput) {\n //parses the user input to understand which command was typed\n const userInputArray = userInput.split(\" \");\n const command = userInputArray[0];\n switch (command) {\n case \"echo\":\n //we will add the functionality of echo next within the \t//object commandLibrary \n commandLibrary.echo(userInputArray.slice(1).join(\" \"));\n break;\n case \"cat\":\n commandLibrary.cat(userInputArray.slice(1));\n break;\n case \"head\":\n commandLibrary.head(userInputArray.slice(1));\n break;\n case \"tail\":\n commandLibrary.tail(userInputArray.slice(1));\n break;\n case \"r\":\n commandLibrary.r(userInputArray.slice(1));\n break;\n default:\n commandLibrary.errorHandler(command);\n break;\n }\n }", "_parseCommand(operands, unknown) {\n const parsed = this.parseOptions(unknown);\n operands = operands.concat(parsed.operands);\n unknown = parsed.unknown;\n this.args = operands.concat(unknown);\n\n if (operands && this._findCommand(operands[0])) {\n this._dispatchSubcommand(operands[0], operands.slice(1), unknown);\n } else if (this._lazyHasImplicitHelpCommand() && operands[0] === this._helpCommandName) {\n if (operands.length === 1) {\n this.help();\n } else {\n this._dispatchSubcommand(operands[1], [], [this._helpLongFlag]);\n }\n } else if (this._defaultCommandName) {\n outputHelpIfRequested(this, unknown); // Run the help for default command from parent rather than passing to default command\n this._dispatchSubcommand(this._defaultCommandName, operands, unknown);\n } else {\n if (this.commands.length && this.args.length === 0 && !this._actionHandler && !this._defaultCommandName) {\n // probably missing subcommand and no handler, user needs help\n this._helpAndError();\n }\n\n outputHelpIfRequested(this, parsed.unknown);\n this._checkForMissingMandatoryOptions();\n if (parsed.unknown.length > 0) {\n this.unknownOption(parsed.unknown[0]);\n }\n\n if (this._actionHandler) {\n const args = this.args.slice();\n this._args.forEach((arg, i) => {\n if (arg.required && args[i] == null) {\n this.missingArgument(arg.name);\n } else if (arg.variadic) {\n args[i] = args.splice(i);\n }\n });\n\n this._actionHandler(args);\n this.emit('command:' + this.name(), operands, unknown);\n } else if (operands.length) {\n if (this._findCommand('*')) {\n this._dispatchSubcommand('*', operands, unknown);\n } else if (this.listenerCount('command:*')) {\n this.emit('command:*', operands, unknown);\n } else if (this.commands.length) {\n this.unknownCommand();\n }\n } else if (this.commands.length) {\n // This command has subcommands and nothing hooked up at this level, so display help.\n this._helpAndError();\n } else {\n // fall through for caller to handle after calling .parse()\n }\n }\n }", "_parseCommand(operands, unknown) {\n const parsed = this.parseOptions(unknown);\n operands = operands.concat(parsed.operands);\n unknown = parsed.unknown;\n this.args = operands.concat(unknown);\n\n if (operands && this._findCommand(operands[0])) {\n this._dispatchSubcommand(operands[0], operands.slice(1), unknown);\n } else if (this._lazyHasImplicitHelpCommand() && operands[0] === this._helpCommandName) {\n if (operands.length === 1) {\n this.help();\n } else {\n this._dispatchSubcommand(operands[1], [], [this._helpLongFlag]);\n }\n } else if (this._defaultCommandName) {\n outputHelpIfRequested(this, unknown); // Run the help for default command from parent rather than passing to default command\n this._dispatchSubcommand(this._defaultCommandName, operands, unknown);\n } else {\n if (this.commands.length && this.args.length === 0 && !this._actionHandler && !this._defaultCommandName) {\n // probably missing subcommand and no handler, user needs help\n this._helpAndError();\n }\n\n outputHelpIfRequested(this, parsed.unknown);\n this._checkForMissingMandatoryOptions();\n if (parsed.unknown.length > 0) {\n this.unknownOption(parsed.unknown[0]);\n }\n\n if (this._actionHandler) {\n const args = this.args.slice();\n this._args.forEach((arg, i) => {\n if (arg.required && args[i] == null) {\n this.missingArgument(arg.name);\n } else if (arg.variadic) {\n args[i] = args.splice(i);\n }\n });\n\n this._actionHandler(args);\n this.emit('command:' + this.name(), operands, unknown);\n } else if (operands.length) {\n if (this._findCommand('*')) {\n this._dispatchSubcommand('*', operands, unknown);\n } else if (this.listenerCount('command:*')) {\n this.emit('command:*', operands, unknown);\n } else if (this.commands.length) {\n this.unknownCommand();\n }\n } else if (this.commands.length) {\n // This command has subcommands and nothing hooked up at this level, so display help.\n this._helpAndError();\n } else {\n // fall through for caller to handle after calling .parse()\n }\n }\n }", "function listOfCommands(rover){\nvar commands = prompt(\"Move the Rover: (f)orward, (r)ight, (l)eft (b)ack .\"); //entrada de los movimientos.\n\n if (commands.indexOf('f') >=0 || commands.indexOf('r') >=0 || commands.indexOf('l') >=0 || commands.indexOf('b') >=0){\n var newCommands = commands.split(\"\"); //.indexOf para que se haga el codigo solo con los comandos validos. Si no es un comando valido daria -1.\n console.log(\"La ruta del Rover es: \" + commands); //split para cojer cada caracter por separado de la array.\n for(var i = 0; i < newCommands.length; i++){ //for para hace todos los movimientos que hemos introducido.\n \n switch(commands[i]){ //switch para enviar a la funcion correspondiente a cada movimiento.\n case 'l' :\n turnLeft(rover);\n break;\n case 'r' :\n turnRight(rover);\n break;\n case 'f' :\n moveForward(rover);\n break ;\n case 'b' :\n moveBack(rover)\n break;\n }\n \n var position = [rover1.positionX, rover1.positionY]; //guardar los datos de la posicion del rover en cada movimiento.\n rover1.travelLog.push(position); \n console.log(\"El Rover se encuentra en \" + position);\n }\n \n \n }else{\n alert(\"Enter a valid command\"); //si el movimiento intrducido no es valido, vuelve a llamar a la funcion.\n listOfCommands(rover1);\n }\n}", "function fixSyntaxHighlighting () {\n var sts = document.querySelectorAll('.err');\n Array.prototype.forEach.call(sts, function (st) {\n if (st.textContent === '`' || st.textContent === ':') {\n st.classList.remove('err');\n }\n })\n}", "async resolveWithInputAndCommands(folder, configuration, variableToCommandMap, section, target) {\n var _a, _b, _c;\n if (!configuration) {\n return Promise.resolve(undefined);\n }\n // get all \"inputs\"\n let inputs = [];\n if (folder && this.workspaceContextService.getWorkbenchState() !== 1 /* EMPTY */ && section) {\n let result = this.configurationService.inspect(section, { resource: folder.uri });\n if (result && (result.userValue || result.workspaceValue || result.workspaceFolderValue)) {\n switch (target) {\n case 1 /* USER */:\n inputs = (_a = result.userValue) === null || _a === void 0 ? void 0 : _a.inputs;\n break;\n case 4 /* WORKSPACE */:\n inputs = (_b = result.workspaceValue) === null || _b === void 0 ? void 0 : _b.inputs;\n break;\n default: inputs = (_c = result.workspaceFolderValue) === null || _c === void 0 ? void 0 : _c.inputs;\n }\n }\n else {\n const valueResult = this.configurationService.getValue(section, { resource: folder.uri });\n if (valueResult) {\n inputs = valueResult.inputs;\n }\n }\n }\n // extract and dedupe all \"input\" and \"command\" variables and preserve their order in an array\n const variables = [];\n this.findVariables(configuration, variables);\n const variableValues = Object.create(null);\n for (const variable of variables) {\n const [type, name] = variable.split(':', 2);\n let result;\n switch (type) {\n case 'input':\n result = await this.showUserInput(name, inputs);\n break;\n case 'command':\n // use the name as a command ID #12735\n const commandId = (variableToCommandMap ? variableToCommandMap[name] : undefined) || name;\n result = await this.commandService.executeCommand(commandId, configuration);\n if (typeof result !== 'string' && !Types.isUndefinedOrNull(result)) {\n throw new Error(nls.localize('commandVariable.noStringType', \"Cannot substitute command variable '{0}' because command did not return a result of type string.\", commandId));\n }\n break;\n default:\n // Try to resolve it as a contributed variable\n if (this._contributedVariables.has(variable)) {\n result = await this._contributedVariables.get(variable)();\n }\n }\n if (typeof result === 'string') {\n variableValues[variable] = result;\n }\n else {\n return undefined;\n }\n }\n return variableValues;\n }", "function executeCommand(str){\n console.log(str)\n\n var cmdMap = {\n 'about': showAbout,\n 'commands': showCommands,\n \"voice\": toggleVoice\n };\n\n // remove '/'; to lowercase; make into array\n var commandArray = str.slice(1)\n .toLowerCase()\n .split(' ');\n var cmd = commandArray[0];\n var args = commandArray.slice(1);\n\n // run the command w/ args OR error.\n (cmdMap[cmd] || showCommandError)(args);\n\n $('#content').scrollTop(document.getElementById('content').scrollHeight)\n $('#message').val('').focus();\n}", "autocompleteHandleEvent(event) {\n if (this.commands.length > 0) {\n // sub command style\n if (event.fragment === 1) {\n // for sub command first complete should return command\n const commands = this.commands.map(c => c.getName());\n event.reply(commands.concat(['--help']));\n } else {\n const elements = event.line.split(' ');\n const commandName = elements[1];\n const commandArgs = elements.slice(2, event.fragment);\n const currentCommand = this.commands.find(c => c.getName() === commandName);\n\n if (currentCommand) {\n event.reply(currentCommand.autocompleteCandidates(commandArgs));\n } else {\n event.reply([]);\n }\n }\n } else {\n // single command style\n const singleCommandArgs = event.line.split(' ').slice(1, event.fragment);\n\n if (event.fragment === 1) {\n // offer --help for the first complete only\n event.reply(this.autocompleteCandidates(singleCommandArgs).concat(['--help']));\n } else {\n event.reply(this.autocompleteCandidates(singleCommandArgs));\n }\n }\n }", "function readCmd(input, vehicule, operator) {\n\n\t// create a log message for the vehicule blackbox to save\n\tlet date = new Date();\n\tdate.toISOString();\n\tlet log = \"initiating sequence: \" + input + \" from \" + operator.toUpperCase() + \" on \" + date;\n\n\t// send it as notification and save it to corresponding array\n\tconsole.log(log);\n\thulla.send(log, \"info\");\n\tvehicule.blackBox.push(log);\n\n\tfor (var i = 0; i < input.length; i++) {\n\n\t\tlet value = input.charAt(i);\n\t\tif (value === \"l\") {\n\t\t\tturnLeft(vehicule);\n\n\t\t} else if (value === \"r\") {\n\t\t\tturnRight(vehicule);\n\n\t\t} else if (value === \"f\") {\n\t\t\tmoveForward(vehicule);\n\n\t\t} else if (value === \"b\") {\n\t\t\tmoveBackward(vehicule);\n\t\t} else {\n\t\t\tconsole.log(value + \" is not a valid input, please use (f)orward, (b)ackward, (r)ight or (l)eft.\");\n\t\t\thulla.send(value + \" is not a valid input, please use (f)orward, (b)ackward, (r)ight or (l)eft.\");\n\t\t}\n\n\t\t// print current position when vehicule has executed it's last move \n\t\tif (i === input.length - 1) {\n\t\t\tconsole.log(vehicule.name + \" is currently located to [\" + vehicule.position.x + \", \" + vehicule.position.y + \"] heading \" + vehicule.direction);\n\t\t}\n\t}\n}", "execute(commondStr) {\n const commands = commondStr.split('\\n');\n commands.forEach(command => {\n if (command.includes(PLACE)) {\n const {\n x,\n y,\n f\n } = this.parsePlaceCommand(command);\n this.place(x, y, f);\n }\n if (command === MOVE) this.move();\n if (command === LEFT) this.left();\n if (command === RIGHT) this.right();\n if (command === REPORT) this.report();\n });\n }", "function registerCommands()\n{\n addCMD([\"cmd\", listCmds, \"Prints list of available commands\"]);\n addSynonimOf(\"cmd\", \"cmds\");\n addSynonimOf(\"cmd\", \"commands\");\n\n addCMD([\"test\", test, \"Just a test\"]);\n addCMD([\"invite\", inviteMeLink, \"I'll give you invite link to me!\", [], true]);\n\n addCMD([\"say\", say, \"I'll say some instead you! (attachments also supported!)\\n__*Syntax:*__ say <any your text>\"]);\n addCMD([\"saytts\", sayTTS, \"I'll help to pronuncate you some!\\n__*Syntax:*__ saytts <any your text>\"]);\n addCMD([\"whosaid\", sayLog, \":spy: Shsh! I'll leak you secret - who asked me to say (5 last messages)\\n\"]);\n addCMD([\"setgame\", setPlayingGame, \"I'll play any game you suggesting me!\\n\" +\n \"__*Syntax:*__ setgame <any your text>\\n\\n**NOTE:** Only permited users can use this command!\"]);\n addCMD([\"setmusic\", setListeningMusic,\"I'll listen any music you suggesting me!\\n\" +\n \"__*Syntax:*__ setmusic <any your text>\\n\\n**NOTE:** Only permited users can use this command!\"]);\n addCMD([\"setvideo\", setWatchingVideo, \"I'll watch any video suggesting me!\\n\" +\n \"__*Syntax:*__ setvideo <any your text>\\n\\n**NOTE:** Only permited users can use this command!\"]);\n addCMD([\"setstream\",setStreaming, \"I'll stream anything you ask me!\\n\" +\n \"__*Syntax:*__ setstream <any your text>\\n\\n**NOTE:** Only permited users can use this command!\"]);\n\n addCMD([\"remind\", sayDelayd, \":information_desk_person: I'll remeber a thing you request me!\\n__*Syntax:*__ remind <any your text> after <time> <seconds, minutes, hours>\\n\", [], true]);\n addCMD([\"remindme\", sayDelaydME, \":information_desk_person: I'll remeber you personally a thing you request me!\\n__*Syntax:*__ remindMe <any your text> after <time> <seconds, minutes, hours>\\n\", [], true]);\n\n addCMD([\"err\", wrongFunction, \"It hurts me...\"]);\n\n addCMD([\"isbeepboop\",isBeepBoop, \"Check is this server has a beep-boop channel\"]);\n addSynonimOf(\"isbeepboop\",\"isfun\", \"Check is this server has a beep-boop/fun channel\");\n\n addCMD([\"mytime\", myTime, \"Let's check our watches? :clock: :watch: :stopwatch: :clock1: \"]);\n addCMD([\"stats\", aboutBot, \"Just my health state\"]);\n addSynonimOf(\"stats\", \"about\", \"Wanna meet me?\");\n addCMD([\"uptime\", upTimeBot, \"How long I still be here\"]);\n\n addCMD([\"help\", cmdHelp, \"Prints help of command\"]);\n\n addCMD([\"mailwohlstand\", sendEmail, \"Send email to my creator while he is offline. (Attachments are supported!) \\n\" +\n \"__*Syntax:*__ mailwohlstand <any your text>\", [], true]);\n\n addCMD([\"check-in-list\", cachedFiles_Check, \"Check the existing of something in one of built-in lists\", [], true]);\n addCMD([\"reload-lists\", cachedFiles_ReLeload, \"<Owner-Only> Reload built-in lists\", [], true]);\n\n\n foxyLogInfo( Cmds.length + \" command has been registered!\");\n}", "function manageOutput() {\n runButton = document.getElementsByClassName(\"spellcheck_run\")[0];\n runButton.addEventListener(\"click\", () => {\n not_found = 0;\n correctable = 0;\n uncorrectable = 0;\n if(copyButton.disabled) {\n copyButton.classList.add(\"enabled\");\n copyButton.disabled = false;\n }\n if(AreaOutput.disabled) {\n AreaInput.classList.add(\"enabled\");\n AreaOutput.classList.add(\"enabled\");\n AreaOutput.disabled = false;\n }\n if(AreaOutput.childElementCount >= 1) {\n AreaOutput.innerHTML = '';\n }\n input = inputbox.value.replace(/ +/g,' ').replace(/\\n /g, '\\n').trim();\n tokens = tokenize(input);\n edits = getEditDistances(tokens);\n not_found = Object.keys(edits).length;\n out = []\n for( var i = 0; i < tokens.length; i++ ) {\n str = ''\n while(!(tokens[i] in edits) && i < tokens.length) {\n str += tokens[i++]\n }\n out.push(str);\n if(tokens[i] in edits) {\n token = {}\n token[tokens[i]] = edits[tokens[i]];\n out.push(token);\n }\n }\n output = document.createElement('span');\n output.className = \"spellcheck_output_inner\";\n out.forEach( o => {\n if (typeof(o) == 'string') {\n elem = document.createElement('span');\n elem.innerHTML = o;\n } else {\n elem = document.createElement('select');\n corrections = [];\n key = Object.keys(o)[0];\n for(var i = 1; i <= edit_distance; i++) {\n if(i in o[key]) {\n corrections = corrections.concat(o[key][i].slice(0, correction_count - corrections.length));\n }\n }\n for(var i = 0; i < corrections.length; i++) {\n e = document.createElement('option');\n e.value = i.toString();\n if( i == 0 ) {\n e.innerHTML = key;\n } else {\n e.innerHTML = corrections[i];\n }\n elem.appendChild(e);\n }\n }\n output.appendChild(elem);\n });\n AreaOutput.prepend(output);\n resizeBoxes();\n outputResults();\n });\n copyButton.addEventListener(\"click\", () => {\n el = document.createElement(\"textarea\");\n el.value = generateOutput();\n document.body.appendChild(el);\n el.select();\n document.execCommand(\"copy\");\n document.body.removeChild(el);\n });\n}", "async function runCommand(cmd) {\r\n switch (cmd.toLowerCase()) {\r\n \r\n case \"restart\": \r\n case \"reboot\": \r\n t_println(\"Rebooting. Please wait\");\r\n await t_write(\".....\", 0.5);\r\n t_terminal.innerHTML = terminalDefaultContent;\r\n boot();\r\n break;\r\n\r\n case \"shutdown\": \r\n t_println(\"Shutting down internal services\");\r\n await t_write(\"...\", 1);\r\n t_println(\"Goodbye!\");\r\n await sleep(1);\r\n t_terminal.innerHTML = \"\";\r\n break;\r\n\r\n case \"clear\": \r\n t_terminal.innerHTML = terminalDefaultContent;\r\n init();\r\n runCommand(await t_getln());\r\n break;\r\n\r\n case \"ls\": \r\n t_println(\"This is the return value of the ls command!\");\r\n runCommand(await t_getln());\r\n break;\r\n\r\n\r\n default: // Über JSON File falls kein 'Aktiver' Command (also wenn nur text zurück)\r\n t_println(\"Command not found: \" + cmd);\r\n runCommand(await t_getln()); //Ready for the next input\r\n break;\r\n }\r\n}", "function initCommands() {\n const newCmds = [];\n for (let el of commands) {\n if (!el.regexes) {\n el.regexes = [el.regex]\n }\n if (el.npcCmd) {\n if (!Array.isArray(el.regexes)) console.log(el)\n let objects\n let scope = []\n if (Array.isArray(el.objects)) {\n objects = el.objects.slice()\n objects.unshift({scope:parser.isHere, attName:\"npc\"})\n for (const el2 of el.objects) {\n scope.push(el2 === parser.isHeld ? parser.isHeldByNpc : el2)\n scope.push(el2 === parser.isWorn ? parser.isWornByNpc : el2)\n }\n }\n else {\n objects = Object.assign({}, el.objects)\n objects.char = {scope:parser.isHere, attName:\"npc\"}\n for (const key in el.objects) {\n const el2 = el.objects[key]\n scope.push(el2 === parser.isHeld ? parser.isHeldByNpc : el2)\n scope.push(el2 === parser.isWorn ? parser.isWornByNpc : el2)\n }\n }\n \n const data = {\n objects:objects,\n attName:el.attName,\n default:el.default,\n defmsg:el.defmsg,\n rules:el.rules,\n score:el.score,\n cmdCategory:el.cmdCategory ? el.cmdCategory : el.name,\n forNpc:true,\n scope:scope,\n };\n\n const cmd = new NpcCmd(\"Npc\" + el.name, data)\n \n cmd.regexes = []\n for (const regex of el.regexes) {\n if (regex instanceof RegExp) {\n const regexAsStr = regex.source.substr(1) // lose the ^ at the start, as we will prepend to it\n for (let key in lang.tell_to_prefixes) {\n cmd.regexes.push(new RegExp(\"^\" + lang.tell_to_prefixes[key] + regexAsStr))\n }\n }\n else {\n const regexAsStr = regex.regex.source.substr(1) // lose the ^ at the start, as we will prepend to it\n for (let key in lang.tell_to_prefixes) {\n cmd.regexes.push({regex:new RegExp(\"^\" + lang.tell_to_prefixes[key] + regexAsStr), mod:regex.mod})\n }\n }\n } \n \n if (el.useThisScriptForNpcs) cmd.script = el.script\n newCmds.push(cmd)\n }\n }\n \n //commands.push.apply(commands, newCmds); ?????\n \n for (let el of lang.exit_list) {\n if (el.type !== 'nocmd') {\n let regex = \"(\" + lang.go_pre_regex + \")(\" + el.name + \"|\" + el.abbrev.toLowerCase()\n if (el.alt) { regex += \"|\" + el.alt }\n regex += \")$\"\n new ExitCmd(\"Go\" + sentenceCase(el.name), el.name, { regexes:[new RegExp(\"^\" + regex)] })\n \n const regexes = []\n for (let key in lang.tell_to_prefixes) {\n regexes.push(new RegExp(\"^\" + lang.tell_to_prefixes[key] + regex))\n }\n new NpcExitCmd(\"NpcGo\" + sentenceCase(el.name), el.name, { regexes:regexes })\n }\n }\n}", "async function inputCommand(messageObject) {\n await verifyUser(messageObject.sender)\n let formatted_command = ''\n if (messageObject.type == 'image') {\n formatted_command = messageObject.caption.match(/^\\$\\w*/g) ? messageObject.caption.match(/^\\$\\w*/g)[0] : null\n } else {\n formatted_command = messageObject.body.match(/^\\$\\w*/g) ? messageObject.body.match(/^\\$\\w*/g)[0] : null;\n }\n switch (formatted_command) {\n case '$rni':\n getPersonaWithoutImage(messageObject.sender, messageObject.chat.groupMetadata.id)\n break\n case '$r':\n getPersonaWithImage(messageObject.sender, messageObject.chat.groupMetadata.id);\n break\n case '$s':\n const personaName = messageObject.body.replace('$s', '').trim()\n sendChosenPersona(messageObject.sender, messageObject.chat.groupMetadata.id, personaName)\n break\n case '$marry':\n const requestedPersona = messageObject.quotedMsgObj.caption ? messageObject.quotedMsgObj.caption.match(/(?<=\\❤️ \\*)(.*?)(?=\\* ❤️)/g)[0] : messageObject.quotedMsg.body.match(/(?<=\\❤️ \\*)(.*?)(?=\\* ❤️)/g)[0];\n marry(messageObject.sender, messageObject.chat.groupMetadata.id, requestedPersona)\n break\n case '$trade':\n const trade = messageObject.body.split(' ')\n tradePersona(messageObject.sender, messageObject.chat.groupMetadata.id, trade[1], trade[2].replace('@', ''))\n break\n case '$help':\n sendGameRules(messageObject.sender, messageObject.chat.groupMetadata.id)\n break\n case '$sim':\n confirmTrade(messageObject.sender, messageObject.chat.groupMetadata.id)\n break\n // case '$sticker': // Revisar problemas\n // sendSticker(messageObject.chat.groupMetadata.id, messageObject.body);\n // break\n }\n }", "function main(operation) {\n var hasErrors = false,\n selections = app.selection;\n for (var i = 0; i < selections.length; i++) {\n try {\n var textFrame = selections[i] instanceof InsertionPoint ?\n selections[i].parentTextFrames[0] :\n selections[i];\n\n var frameHasErrors = isError(textFrame);\n hasErrors = hasErrors || isError(textFrame);\n\n if (!frameHasErrors) {\n operation(textFrame);\n };\n } catch (e) {\n // pretend nothing happened :-)\n }\n }\n}", "function processInput (input, data) {\n let {settings, commands, player, places, messages, defaults} = data\n\n input = input.toLowerCase()\n\n if (input.length > 0) {\n println(settings.prepend + input)\n line()\n }\n\n // ask for help\n if (input.indexOf(commands.help) > -1) {\n println(messages.helpText)\n\n // look around describe where you are\n } else if (input.indexOf(commands.observe) > -1) {\n if (canSee(player)) {\n println(description(player.currentLocation, places))\n } else {\n println(messages.visibilityError)\n }\n\n // walk places\n } else if (input.indexOf(commands.move) > -1) {\n // input = input.replace(\"walk to\", \"\").trim().input.replace(\"the\", \"\").trim()\n let placeName = trimInput(input, commands.move)\n let place = placeFromString(placeName, places)\n if (place !== undefined) {\n place = applyPlaceDefaults(place, defaults)\n if (locationIsAccessable(place, player.currentLocation, places) && place !== undefined) {\n if (!locationIsLocked(place, player.pockets)) {\n player = walkTo(player, placeName, places, defaults)\n if (player.currentLocation.settings.isLocked) {\n println(player.currentLocation.messages.successEntryGranted)\n }\n player.currentLocation = unlockLocation(player.currentLocation, player.pockets)\n if (player.currentLocation.leaveUnlocked) {\n println(player.currentLocation.messages.unlock)\n }\n println(messages.moveMessage + placeName)\n } else {\n println(place.messages.locked)\n }\n } else if (place === player.currentLocation) {\n println(messages.moveRedundancy + place.name)\n } else {\n println(messages.moveError)\n }\n } else {\n println(messages.moveError)\n }\n\n // take items\n } else if (input.indexOf(commands.gainItem) > -1) {\n let item = trimInput(input, commands.gainItem)\n if (item in player.currentLocation.objects) {\n player.currentLocation.objects = hashRemove(item, player.currentLocation.objects)\n player.pockets = hashAdd(item, player.pockets)\n println(messages.pickUpSuccess + addArticle(item))\n } else {\n println(messages.pickUpError + addArticle(item))\n }\n\n // drop items\n } else if (input.indexOf(commands.loseItem) > -1) {\n let item = trimInput(input, commands.loseItem)\n if (item in player.pockets) {\n player.pockets = hashRemove(item, player.pockets)\n player.currentLocation.objects = hashAdd(item, player.currentLocation.objects)\n println(messages.dropSuccess + addArticle(item))\n } else {\n println(messages.inventoryItemError + addArticle(item))\n }\n } else if (input.indexOf(commands.useItem) > -1) {\n let item = trimInput(input, commands.useItem)\n if (item in player.pockets) {\n if (player.currentLocation.exchanges[item]) {\n player.pockets = hashRemove(item, player.pockets)\n player.pockets = hashAdd(player.currentLocation.exchanges[item], player.pockets)\n println(messages.exchangeSuccess + addArticle(player.currentLocation.exchanges[item]))\n } else {\n println(messages.useError)\n }\n } else {\n println(messages.inventoryItemError + addArticle(item))\n }\n\n // take inventory\n } else if (input.indexOf(commands.takeInventory) > -1) {\n if (player.pockets !== {}) {\n println(hashList(player.pockets, messages.inventoryError))\n }\n } else if (input.indexOf(commands.perceiveItems) > -1) {\n println(hashList(player.currentLocation.objects))\n } else {\n if (input.length > 0) {\n println(messages.commandInvalid)\n }\n }\n Object.assign(data, {player, places})\n return data\n}", "function handleCommands(ce) {\n if (ce.content === '!!time') {\n send(new Date().toString());\n }\n if (ce.content === '!!stop') {\n send('...');\n silent = true;\n }\n if (ce.content === '!!go') {\n silent = false;\n }\n }", "function checkInputs(arr, thisButton, answer){\n var counter = 0;\n\n //wildChar shows one other specific Character that the string should have, like . or =\n\n for(var i=0; i< arr.length; i++){\n /*http://stackoverflow.com/questions/17938186/trimming-whitespace-from-the-end-of-a-string-only-with-jquery*/\n var trimmedAns= $(arr[i][0]).val().replace(/\\s*$/,\"\");\n var wrongPhrase = '';\n var falsePos = '';\n\n //check if it contains all key phrases\n for(var j=0; j < arr[i][1].length; j++){\n var activeChar= arr[i][1][j];\n if(trimmedAns.indexOf(activeChar) == -1){\n wrongPhrase = activeChar;\n break;\n }\n }\n\n // this is for the Characters we don't want to see in there\n for(var l=0; l < arr[i][2].length; l++){\n var activeChar= arr[i][2][l];\n if(trimmedAns.indexOf(activeChar) > -1)\n falsePos = activeChar;\n }\n\n // make sure we save original err msg\n var origMsg= $(thisButton).siblings('.warn').text();\n\n // if it has both correct property name and value, and semi and colon are in there\n if(falsePos.length ==0 && wrongPhrase.length ==0)\n counter++\n else if(wrongPhrase.length > 1 && wrongCount == 0){\n $(thisButton).siblings('.warn').text('Did you spell everything correctly in answer '+(i+1)+'? Attempts Remaining: ' +(5-wrongCount)).show('slide');\n $(arr[i][0]).effect('highlight');\n wrongCount++;\n }\n else if(wrongPhrase.length > 1 && wrongCount > 0){\n $(thisButton).siblings('.warn').text('I think you are missing ' + wrongPhrase + ' in answer ' +(i+1)+ '. Attempts Remaining: ' +(5-wrongCount) ).show('slide');\n $(arr[i][0]).effect('highlight');\n wrongCount++;\n }\n else if(wrongPhrase.length == 1 && wrongCount == 0){\n $(thisButton).siblings('.warn').text('Did you remember all the correct syntax? Attempts Remaining: ' +(5-wrongCount)).show('slide');\n $(arr[i][0]).effect('highlight');\n wrongCount++;\n }\n else if(wrongPhrase.length == 1 && wrongCount > 0){\n $(thisButton).siblings('.warn').text('I think you forgot to include '+wrongPhrase + ' in answer ' +(i+1) + '. Attempts Remaining: ' +(5-wrongCount)).show('slide');\n $(arr[i][0]).effect('highlight');\n wrongCount++;\n }\n else if(falsePos.length > 0 && wrongCount == 0){\n $(thisButton).siblings('.warn').text('You included a character that should not be in there in answer ' +(i+1)+'! Attempts Remaining: ' +(5-wrongCount)).show('slide');\n $(arr[i][0]).effect('highlight');\n wrongCount++;\n }\n else if(falsePos.length > 0 && wrongCount > 0){\n $(thisButton).siblings('.warn').text('You included ' +falsePos+ ' in answer '+(i+1)+', which should not be in there. Attempts Remaining: ' +(5-wrongCount) ).show('slide');\n $(arr[i][0]).effect('highlight');\n wrongCount++;\n }\n //this case should never happen but fuck it I am leaving it in there\n else{\n $(thisButton).siblings('.warn').text(origMsg).show('slide');\n $(arr[i][0]).effect('highlight');\n wrongCount++;\n }\n\n //user has gotten it wrong three times or more\n if (wrongCount > 5){\n //put it in a span so the answer looks distinct\n if(answer.length == 1)\n $(thisButton).siblings('.warn').html(\"The answer is- <span>\"+answer[0]+\"</span>\").show('slide');\n else{\n $(thisButton).siblings('.warn').html(\"The answer is- <span>\"+answer[0]+\"</span><span>\"+answer[1]+\"</span>\").show('slide');\n }\n }\n }\n\n if(counter === arr.length){\n wrongCount=0;\n $(thisButton).siblings('.warn').hide()\n\n // enable continue button\n $('.advanceBtn:visible').css('pointer-events', 'auto');\n $('.advanceBtn:visible').css('background-color', 'green');\n $('.advanceBtn:visible').css('opacity', '1');\n\n // this needs to be outside the function below due to setTimeout\n //http://stackoverflow.com/questions/5226285/settimeout-in-for-loop-does-not-print-consecutive-values\n function setTheFields(i){\n var startTime = 2000 * i\n var endTime= 2000 * (i+1);\n setTimeout(function(){\n $('.interactme:visible').find('.userIn').eq(i).parent().siblings('.codeExp').css('opacity', '0')\n $('.interactme:visible').find('.userIn').eq(i).children('span').first().trigger('mouseover')\n }, startTime)\n setTimeout(function(){\n $('.interactme:visible').find('.userIn').eq(i).parents().eq(1).trigger('mouseleave')\n $('.interactme:visible').find('.userIn').eq(i).parent().siblings('.codeExp').css('opacity', '1')\n }, endTime)\n }\n\n // do all animations with delay in between\n for(var i=0; i< arr.length; i++){\n setTheFields(i);\n }\n\n }\n}", "function handleCommand(command, fromUserId, groupInfo, messageLiteral, api = gapi) {\n const attachments = messageLiteral.attachments; // For commands that take attachments\n // Command preprocessing to compare command grammars against input and check for matches\n const co = commands.commands; // Short var names since I'll be typing them a lot\n for (let c in co) {\n if (co.hasOwnProperty(c)) {\n // Check whether command is sudo-protected and, if so, whether the user is the owner\n if (!co[c].sudo || (co[c].sudo && fromUserId == config.owner.id)) {\n // Set match vals\n // fromStart will concatenate a 'start of string' operator to the beginning\n // of the regular expression used to match commands if contextless grammar\n // is turned off in the config (off by default)\n let regex = Array.isArray(co[c].regex) ? co[c].regex[0] : co[c].regex;\n if (typeof regex == \"string\") { regex = new RegExp(regex); }\n const fromStart = config.contextless ? regex : new RegExp(\"^\" + regex.source, regex.flags);\n if (co[c].user_input.accepts) { // Takes a match from the members dict\n if (Array.isArray(co[c].regex)) { // Also has a regex suffix (passed as length 2 array)\n co[c].m = utils.matchesWithUser(fromStart, command, fromUserId, groupInfo, co[c].user_input.optional, \" \", co[c].regex[1]);\n } else { // Just a standard regex prefex as a string + name\n co[c].m = utils.matchesWithUser(fromStart, command, fromUserId, groupInfo, co[c].user_input.optional);\n }\n } else {\n co[c].m = command.match(fromStart);\n }\n } else { // User not authorized\n // Set match to null to prevent checking issues\n co[c].m = null;\n }\n // Update usage statistics if command is matched\n if (co[c].m) {\n utils.updateStats(c, fromUserId);\n }\n }\n }\n debugCommandOutput(false);\n // Check commands for matches & eval\n runner.run(api, co, groupInfo, fromUserId, attachments, messageLiteral);\n}", "function processCommand(data) {\n var cmd;\n\n // This is the default response for a failed action\n var response = {\n success: false,\n err: false,\n data: false\n };\n\n try {\n // Parse the command into a JSON object\n cmd = JSON.parse(data.toString('utf-8'));\n } catch (e) {\n // This is where we catch any bad (non-json) input\n response.err = 'not_json'; // Send back an error message\n response.data = data.toString('utf-8'); // Send back the bad command so we can look at it\n console.log('Invalid JSON: '+response.data);\n return response; // Respond to the client\n }\n\n // Let's make sure it specifies some action\n if (!cmd.hasOwnProperty('action')) {\n response.err = 'no_action';\n response.data = cmd;\n console.log('Invalid action: '+JSON.stringify(cmd));\n return response;\n }\n\n /*\n * This is our primary switch case for event processing\n * We can pretty much get away with hooking up most\n * commands right in here.\n */\n switch (cmd.action) {\n // GENERAL COMMANDS\n case 'get_time':\n // Return the rov time for some reason\n response.success = true;\n response.data = {time: Date.now()};\n break;\n case 'get_mem_usage':\n // Get memory usage stats\n response.success = true;\n response.data = {free: os.freemem(), total: os.totalmem()};\n break;\n case 'get_cpu_usage':\n // Get the processor load average\n response.success = true;\n response.data = {cpuload: os.loadavg()};\n break;\n case 'ping':\n // Do nothing, successfully\n response.success = true;\n break;\n case 'echo':\n // echo recieved data, if there was any\n response.success = true;\n if (!cmd.hasOwnProperty('data')) {\n return response;\n }\n response.data = cmd.data;\n return response;\n break;\n\n // HMC6343 COMMANDS\n case 'hmc_init':\n // Initialize magnetometer\n try {\n hmc = new hmc6343('/dev/i2c-1', 0x19);\n }\n // Return error if there was one\n catch (ex) {\n response.err = ex.message\n break;\n }\n response.success = true;\n break;\n case 'hmc_get_accel':\n // Get accelerometer data from magnetometer\n try {\n hmc.readAccel(function(accelData) {\n response.data = accelData;\n response.success = true;\n });\n } catch (ex) {\n response.success = false;\n response.err = ex.message;\n }\n break;\n case 'hmc_get_mag':\n // Get magnetometer data from magnetometer\n try {\n response.success = true;\n hmc.readMag(function(magData) {\n response.data = magData;\n });\n } catch (ex) {\n response.err = ex.message;\n }\n break;\n\n // DS18B20 COMMANDS\n // yeah we'll get to that\n\n // PCA9685 COMMANDS\n case 'pca_init':\n // Initialize pca board\n if (rpi) {\n var options = {\n freq: 50,\n };\n pca = new pca9685(options);\n response.success = true;\n } else {\n response.err = 'PCA is only initializable on the RPI'\n }\n \n break;\n case 'pca_set_pulse':\n // Set Set channel chan to turn on on step cms.stepOn and off on step cmd.stepOff \n /* Usage:\n * {\"action\":\"pca_set_dutyCycle\",\n * \"chan\":\"[channel]\",\n * \"stepOn\":\"[on step]\",\n * \"stepOff\":\"[off step]\"}\n */\n if(!cmd.hasOwnProperty('chan') || !cmd.hasOwnProperty('pulse')) {\n response.err = 'usage: {action:pca_set_dutyCycle, chan:[channel], pulse:[pulse length in ms]}';\n break;\n }\n try {\n response.success = true;\n pca.setPulse(cmd.chan, cmd.pulse);\n } catch (ex) {\n response.err = ex.message;\n }\n break;\n case 'joystick_setData':\n if (cmd.joyData.type === 'button') {\n switch (cmd.joyData.value) {\n case 0:\n console.log('button ' + cmd.joyData.number + ' released');\n break;\n case 1:\n console.log('button ' + cmd.joyData.number + ' released');\n break;\n }\n }\n if (cmd.joyData.type === 'axis') {\n var scale = -(cmd.joyData.value/32767);\n switch (cmd.joyData.number) {\n case 0:\n joyX = scale;\n break;\n case 1:\n joyY = scale;\n break;\n case 3:\n upThrust = (scale * 540 + 1617);\n break;\n }\n }\n lThrust = ((-joyX/2) + (joyY/2)) * 500 + 1617;\n rThrust = ((joyX/2) + (joyY/2)) * 500 + 1617;\n pca.setPulse(1, lThrust);\n pca.setPulse(0, rThrust);\n pca.setPulse(2, upThrust);\n pca.setPulse(3, upThrust);\n break;\n default:\n response.err = 'not_implemented';\n response.data = cmd;\n console.log('Command not implemented: '+cmd.action);\n break;\n }\n\n console.log('Command was: '+JSON.stringify(cmd));\n return response;\n}", "function cmdFail(cmd) {\n // if cmd is 'end' and 1 arg isn't number -> fail\n if (cmd['cmd'] == 'end') {\n if (isNaN(cmd['cmd_num'])) {\n return true;\n }\n\n // if cmd is either 'inc' or 'deb'\n } else if (cmd['cmd'] == 'inc' || cmd['cmd'] == 'deb') {\n // if command attempts to edit box outside of correct range -> fail\n if (cmd['box'] < 0 || cmd['box'] > 9) {\n return true;\n\n // if cmd's box, next command, command number are not numbers -> fail\n } else if (isNaN(cmd['box']) || isNaN(cmd['nxt_cmd']) || isNaN(cmd['cmd_num'])) {\n return true;\n\n // if cmd is 'deb' and fail command is NaN -> fail\n } else if (cmd['cmd'] == 'deb' && isNaN(cmd['fail_cmd'])) {\n return true;\n }\n // if command is anything other than 'inc','deb','end' -> fail\n } else {\n return true;\n }\n\n // all other commands must be correct\n return false;\n}", "function simpleTextEditor(input) {\n let operations = inputs[i].split(' ');\n //console.log(operations);\n if( operations[0] == 1) {\n textStack.push(initialText);\n initialText = initialText.concat(operations[1]);\n } else if( operations[0] == 2) {\n textStack.push(initialText);\n initialText = initialText.substring(0, initialText.length - operations[1]);\n // initialText = initialText.slice(operations[1] * -1);\n } else if( operations[0] == 3) {\n console.log(initialText.charAt(operations[1] -1));\n } else if( operations[0] == 4) {\n initialText = textStack.pop();\n }\n //}\n}", "function onKeyCommand(command,editorState){switch(command){case'redo':return EditorState.redo(editorState);case'delete':return keyCommandPlainDelete(editorState);case'delete-word':return keyCommandDeleteWord(editorState);case'backspace':return keyCommandPlainBackspace(editorState);case'backspace-word':return keyCommandBackspaceWord(editorState);case'backspace-to-start-of-line':return keyCommandBackspaceToStartOfLine(editorState);case'split-block':return keyCommandInsertNewline(editorState);case'transpose-characters':return keyCommandTransposeCharacters(editorState);case'move-selection-to-start-of-block':return keyCommandMoveSelectionToStartOfBlock(editorState);case'move-selection-to-end-of-block':return keyCommandMoveSelectionToEndOfBlock(editorState);case'secondary-cut':return SecondaryClipboard.cut(editorState);case'secondary-paste':return SecondaryClipboard.paste(editorState);default:return editorState;}}", "function autoSearchSwitchFix() {\r\n\t\tvar args = autoPlgCmdFix.apply(this, arguments);\r\n\t\tif ( args[args.length - 1] === 'and' || args[args.length - 1] === 'or' ) {\r\n\t\t\tif ( typeof args[args.length - 2] === \"number\" ) {\r\n\t\t\t\tif ( args[args.length - 4] === \"thisM\" || /M\\d+/.test(args[args.length - 4]) ) {\r\n\t\t\t\t\targs.splice(args.length - 1, 0, 'S0', true);\r\n\t\t\t\t} else {\r\n\t\t\t\t\targs.splice(args.length - 3, 0, 'thisM');\r\n\t\t\t\t\targs.splice(args.length - 1, 0, 'S0', true);\r\n\t\t\t\t}\r\n\t\t\t} else if ( typeof args[args.length - 2] === 'boolean' || Array.isArray(args[args.length - 2]) ) {\r\n\t\t\t\targs.splice(args.length - 1, 0, 'thisM', 0, 0, 'S0', true);\r\n\t\t\t} else if ( !args.some( function( arg ) { return typeof arg === 'number'; } ) ) {\r\n\t\t\t\targs.splice(args.length - 1, 0, true, 'thisM', 0, 0, 'S0', true);\r\n\t\t\t}\r\n\t\t} else if ( /S\\d+/.test(args[args.length - 1]) || Array.isArray(args[args.length - 1]) ) {\r\n\t\t\targs.splice(args.length, 0, true, 'or');\r\n\t\t} else if ( typeof args[args.length - 1] === \"number\" ) {\r\n\t\t\targs.splice(args.length, 0, 'S0', true, 'or');\r\n\t\t} else if ( args[args.length - 1] === \"thisM\" || /M\\d+/.test(args[args.length - 1]) ) {\r\n\t\t\targs.splice(args.length, 0, 0, 0, 'S0', true, 'or');\r\n\t\t} else if ( !args.some( function( arg ) { return typeof arg === 'number'; } ) && typeof args[args.length - 1] === 'boolean' || Array.isArray(args[args.length - 1]) ) {\r\n\t\t\targs.splice(args.length, 0, 'thisM', 0, 0, 'S0', true, 'or');\r\n\t\t} else if ( args.some( function( arg ) { return typeof arg === 'number'; } ) ) {\r\n\t\t\targs.push('or');\r\n\t\t} else {\r\n\t\t\targs.splice(args.length, 0, true, 'thisM', 0, 0, 'S0', true, 'or');\r\n\t\t}\r\n\t\treturn args;\r\n\t}", "function textIsValidCommand(text) {\n var strArr = text.split(\"\\n\");\n var _iteratorNormalCompletion8 = true;\n var _didIteratorError8 = false;\n var _iteratorError8 = undefined;\n\n try {\n for (var _iterator8 = strArr[Symbol.iterator](), _step8; !(_iteratorNormalCompletion8 = (_step8 = _iterator8.next()).done); _iteratorNormalCompletion8 = true) {\n var str = _step8.value;\n\n var idx = str.indexOf('(');\n var idx2 = str.indexOf(')');\n if (!(idx > 0 && idx2 > idx)) {\n return false;\n }\n }\n } catch (err) {\n _didIteratorError8 = true;\n _iteratorError8 = err;\n } finally {\n try {\n if (!_iteratorNormalCompletion8 && _iterator8.return) {\n _iterator8.return();\n }\n } finally {\n if (_didIteratorError8) {\n throw _iteratorError8;\n }\n }\n }\n\n return true;\n}", "function applyReplacement() {\n errorMessages.value('');\n // Get the text that is currently displayed in the inputBlocks text area.\n file_txt = inputBlocks.value();\n updateViaText();\n //Get the text from the rule1From text area\n var From = rule1From.value();\n //Get the text from the rule1To text area\n var To = rule1To.value();\n //Strip off any whitespace or newlines\n From = From.replace(/\\s\\n/g, '');\n To = To.replace(/\\s\\n/g, '');\n\n //*******Replace this with the blocks validation function eventually TEST HERE TO SEE IF THE BLOCKS BOX IS FORMATTED CORRECTLY\n if (file_txt == '') {\n errorMessages.value('');\n errorMessages.value(\"Please click the submit button to rebuild your quilt and try again.\");\n updateTextBoxes();\n }\n //*******Replace above with Blocks validation function eventually*******//\n\n //If the ruleFrom and ruleTo text areas are empty warn the user then drop out of this function\n if (areToAndFromEmpty(From, To)) {\n //areToAndFromEmpty returns if true, then skips over the next else and drops out of the function.\n }//end else if to is empty\n //Otherwise validate the form of the text boxes and if the format is off\n //warn the user.\n\telse {\n // From and to are not empty - check if they have brackets. Remove them if they do and warn\n // the user if they are not present.\n From = removeBracketsFromString(rule1From.value());\n To = removeBracketsFromString(rule1To.value());\n //now that you have removed the brackets check if From and To are empty\n if (areToAndFromEmpty(From, To)) {\n //areToAndFromEmpty returns if true, then skips over the next else and drops out of the function.\n }//end else if to is empty\n //If to and from are not empty then check to see if the replacement is from single to multiple\n else {\n if(isColorInPalette(From, To)){\n print(\"Your to and from colors are in the palette\");\n }else{\n errorMessages.value(\"\");\n errorMessages.value(\"One of your colors is not in the palette and may cause unexpected results.\");\n }\n\n // If they are then use a local temporary value to hold the text from the block text box area.\n var trimmedTXT = file_txt.replace(/\\s/g, '');\n if((From.length == 1)&&(To.length > 1)){\n var blockHolder = trimmedTXT.match(patternBlock);\n trimmedTXT = [];\n for(var i = 0; i < blockHolder.length; i++){\n blockHolder[i] = blockHolder[i].split(',');\n }//end for\n for(var i = 0; i < blockHolder.length; i++){\n for ( var j = 0; j < blockHolder[i].length; j++){\n var fromFrontTemp = '[' + From;\n var fromBackTemp = From + ']';\n if( blockHolder[i][j] == fromFrontTemp ){\n blockHolder[i][j] = '[' + To;\n }\n if( blockHolder[i][j] == fromBackTemp ){\n blockHolder[i][j] = To + ']';\n }\n if( blockHolder[i][j] == From ){\n blockHolder[i][j] = To;\n }\n }//end for j\n }//end for i\n trimmedTXT = blockHolder;\n \t\t\tinputBlocks.html(trimmedTXT);\n \t\t\tvar input_txt = '';\n \t\t\tinput_txt += inputPalette.value() + '\\n';\n \t\t input_txt += inputBlocksWide.value() + 'x' + inputBlocksHigh.value() + '\\n\\n';\n \t\t\tinput_txt += trimmedTXT;\n \t\t\tupdateQuilt(input_txt);\n }//end if from is only one letter and to is more than one\n else{\n while (trimmedTXT.includes(From)) {\n trimmedTXT = trimmedTXT.replace(From, To);\n \t\t\t}//end while\n trimmedTXT = trimmedTXT.replace(/\\[/g, \"\\n[\").trim();\n \t\t\tinputBlocks.html(trimmedTXT);\n \t\t\tvar input_txt = '';\n \t\t\tinput_txt += inputPalette.value() + '\\n';\n \t\t input_txt += inputBlocksWide.value() + 'x' + inputBlocksHigh.value() + '\\n\\n';\n \t\t\tinput_txt += trimmedTXT;\n \t\t\tupdateQuilt(input_txt);\n }//end else\n }//end else\n\t}//end else\n}//end applyReplacement", "function handleCommand(bot, body, user, type) {\n\n /* Vote command */\n if (new RegExp(/^v [1-4]{1,4}$|^vote [1-4]{1,4}$|^votar [1-4]{1,4}$/).test(body)) {\n let nok = false;\n for (let i = body.indexOf(' '); i < body.length; i ++) {\n if (body.indexOf(body[i]) != body.lastIndexOf(body[i])) nok = true;\n }\n if (!nok) {\n CommandHandlers.onVoteCommand(bot, ACCOUNTS.BOT_JID, body, user, type);\n return;\n }\n }\n\n /* Select command */\n if (new RegExp(/^s [A-Za-z0-9]{5}$|^select [A-Za-z0-9]{5}$|^seleccionar [A-Za-z0-9]{5}$/)\n .test(body)) {\n CommandHandlers.onSelectCommand(bot, ACCOUNTS.BOT_JID, body, user, type);\n return;\n }\n\n /* Other commands */\n switch (body) {\n\n case '':\n case 'h':\n case 'help':\n CommandHandlers.onHelpCommand(bot, ACCOUNTS.BOT_JID, body, user, type);\n break;\n\n case 'c':\n case 'commands':\n case 'comandos':\n CommandHandlers.onCommandsCommand(bot, ACCOUNTS.BOT_JID, body, user, type);\n break;\n\n case 'l':\n case 'list':\n case 'listado':\n CommandHandlers.onListCommand(bot, ACCOUNTS.BOT_JID, body, user, type);\n break;\n\n case 'd':\n case 'discard':\n case 'descartar':\n CommandHandlers.onDiscardCommand(bot, ACCOUNTS.BOT_JID, body, user, type);\n break;\n\n case 'b':\n case 'a':\n case 'back':\n case 'atras':\n CommandHandlers.onBackCommand(bot, ACCOUNTS.BOT_JID, body, user, type);\n break;\n\n case 'i':\n case 'info':\n case 'informacion':\n case 'información':\n CommandHandlers.onInfoCommand(bot, ACCOUNTS.BOT_JID, body, user, type);\n break;\n\n default:\n CommandHandlers.onCommandError(bot, ACCOUNTS.BOT_JID, body, user, type);\n break;\n }\n\n}", "_resetSyntaxErrorMessage() {\n this.state.isValid = true;\n this.state.errorMessage = null;\n this.state.syntaxErrorMessage = null;\n this.trigger(this.state);\n }", "function checkIfValidCommand(command) {\n\n var valid_commands = /df|mf|al[0-9]+|ar[0-9]|none+/i;\n\n if (valid_commands.test(command)) {\n return true;\n } else {\n console.log(\"Unknown command: \" + command);\n return false;\n }\n}", "function UnbEditorDoCmd(event, cmd, arg1)\r\n{\r\n\ttextbox.focus(); // TODO: make \"textbox\" more flexible, also in other functions\r\n\tswitch (cmd)\r\n\t{\r\n\t\tcase \"bold\":\r\n\t\t\tUnbEncloseText(\"[b]\", \"[/b]\", 1); break;\r\n\t\tcase \"italic\":\r\n\t\t\tUnbEncloseText(\"[i]\", \"[/i]\", 1); break;\r\n\t\tcase \"underline\":\r\n\t\t\tUnbEncloseText(\"[u]\", \"[/u]\", 1); break;\r\n\t\tcase \"center\":\r\n\t\t\tUnbEncloseText(\"[center]\", \"[/center]\", 1); break;\r\n\t\tcase \"line\":\r\n\t\t\tUnbInsertText(\"[line]\"); break;\r\n\t\t//case \"strike\":\r\n\t\t//\tUnbEncloseText(\"[s]\", \"[/s]\", 1); break;\r\n\t\t//case \"mono\":\r\n\t\t//\tUnbEncloseText(\"[m]\", \"[/m]\", 1); break;\r\n\t\tcase \"list\":\r\n\t\t\tUnbEncloseText(\"[list][*]\", \" [/list]\", 1); break;\r\n\t\tcase \"list_1\":\r\n\t\t\tUnbEncloseText(\"[list=1][*]\", \" [/list=1]\", 1); break;\r\n\t\tcase \"list_A\":\r\n\t\t\tUnbEncloseText(\"[list=A][*]\", \" [/list=A]\", 1); break;\r\n\t\tcase \"email\":\r\n\t\t\tUnbEncloseText(\"[email]\", \"[/email]\", 1); break;\r\n\t\tcase \"quote\":\r\n\t\t\tif (event.shiftKey)\r\n\t\t\t{\r\n\t\t\t\tUnbInsertText(\"[/quote]\\n\\n\\n\\n[quote]\\n\");\r\n\t\t\t\t// If on Mozilla, move cursor to correct position\r\n\t\t\t\tif (textbox.selectionStart >= 0) textbox.selectionStart = textbox.selectionEnd -= 10;\r\n\t\t\t}\r\n\t\t\telse\r\n\t\t\t{\r\n\t\t\t\tUnbEncloseText(\"[quote]\\n\", \"\\n[/quote]\", 1);\r\n\t\t\t}\r\n\t\t\tbreak;\r\n\t\tcase \"code\":\r\n\t\t\tif (event.shiftKey)\r\n\t\t\t{\r\n\t\t\t\tUnbInsertText(\"[/code]\\n\\n\\n\\n[code]\\n\");\r\n\t\t\t\t// If on Mozilla, move cursor to correct position\r\n\t\t\t\tif (textbox.selectionStart >= 0) textbox.selectionStart = textbox.selectionEnd -= 10;\r\n\t\t\t}\r\n\t\t\telse\r\n\t\t\t{\r\n\t\t\t\tUnbEncloseText(\"[code]\\n\", \"\\n[/code]\", 1);\r\n\t\t\t}\r\n\t\t\tbreak;\r\n\t\tcase \"php\":\r\n\t\t\tif (event.shiftKey)\r\n\t\t\t{\r\n\t\t\t\tUnbInsertText(\"[/php]\\n\\n\\n\\n[php]\\n\");\r\n\t\t\t\t// If on Mozilla, move cursor to correct position\r\n\t\t\t\tif (textbox.selectionStart >= 0) textbox.selectionStart = textbox.selectionEnd -= 10;\r\n\t\t\t}\r\n\t\t\telse\r\n\t\t\t{\r\n\t\t\t\tUnbEncloseText(\"[php]\\n\", \"\\n[/php]\", 1);\r\n\t\t\t}\r\n\t\t\tbreak;\r\n\t\tcase \"url\":\r\n\t\t\tif (event.shiftKey)\r\n\t\t\t{\r\n\t\t\t\tUnbEncloseText(\"[url=]\", \"[/url]\", 0);\r\n\t\t\t\t// If on Mozilla, move cursor to correct position\r\n\t\t\t\tif (textbox.selectionStart >= 0) textbox.selectionStart = textbox.selectionEnd = textbox.selectionStart + 5;\r\n\t\t\t}\r\n\t\t\telse\r\n\t\t\t{\r\n\t\t\t\tUnbEncloseText(\"[url]\", \"[/url]\", 1);\r\n\t\t\t}\r\n\t\t\tbreak;\r\n\t\tcase \"img\":\r\n\t\t\tUnbEncloseText(\"[img]\", \"[/img]\", 1); break;\r\n\t\tcase \"color\":\r\n\t\t\tUnbEncloseText(\"[color=\" + arg1 + \"]\", \"[/color]\", 1); break;\r\n\t\tcase \"font\":\r\n\t\t\tUnbEncloseText(\"[font=\" + arg1 + \"]\", \"[/font]\", 1); break;\r\n\t\tcase \"size\":\r\n\t\t\tUnbEncloseText(\"[size=\" + arg1 + \"]\", \"[/size]\", 1); break;\r\n\r\n\t\t// \"not currently supported\":\r\n\t\t//case \"undo\":\r\n\t\t//\tdocument.selection.createRange().execCommand(\"Undo\");\r\n\t\t//case \"redo\":\r\n\t\t//\tdocument.selection.createRange().execCommand(\"Redo\");\r\n\t}\r\n}", "run_build_command(what, extra, option1){\n // console.log(\"-> run_build_command(what=%s, extra=%s, option1=%s)\", what, extra, option1)\n switch(what){\n case 'all': return this.run_build_all()\n case 'books': case 'livres': return this.run_build_books()\n case 'book': case 'livre':\n if ( option1 == '-update'){\n return this.run_build_all(extra, option1)\n } else {\n return this.run_build_books(extra, option1)\n }\n case 'document':case'documents': return this.run_build_documents(extra,option1)\n case 'pfa': return film.analyse.buildPFA(null, extra)\n case 'cover': case 'couverture': return this.run_build_cover()\n case 'sequencier': return this.run_build_sequencier()\n case 'statistiques': case 'stats': return this.run_build_statistiques(extra)\n case 'synopsis': return this.run_build_synopsis()\n case 'traitement':case'treatment': return this.run_build_traitement()\n case 'quatrieme': return this.run_build_quatrieme()\n case 'frontispice': return this.run_build_frontispice()\n default: erreur(`Je ne sais pas comment construire un ou une ${what}`)\n }\n}", "function checkEntered(e) {\r\n //to check that if the tags class list contain mustShow class\r\n if (e.target.classList.contains(\"mustShow\")) {\r\n //to check button with mustShow class we use display function\r\n display(e.target);\r\n //to check that if the button contain equal class\r\n } else if (\r\n e.target.classList.contains(\"equal\") &&\r\n displayResult.textContent != \"Error\"\r\n ) {\r\n /* if user clicks on equal button, the result will be replaced in users entered num and ops\r\n and user can use that result for next calculation */\r\n showResult(displayResult.textContent);\r\n //check that if the btn contain backspace class\r\n } else if (\r\n e.target.classList.contains(\"backspace\") ||\r\n e.target.parentElement.classList.contains(\"backspace\")\r\n ) {\r\n /* we have two btn that their classlist contain backspace\r\n one for remove just one char, and one for remove all the string in result section */\r\n // check if the button text content is C\r\n if (e.target.textContent == \"C\") {\r\n //remove all string in result section and live result section\r\n displayResult.textContent = \"\";\r\n displayLiveResult.textContent = \"\";\r\n } else {\r\n //this condition is for an other backSpace button that removes only one char from last of string\r\n //if result sections text content is Error, all string in result and live result section and check will be remove\r\n if (displayResult.textContent == \"Error\") {\r\n displayResult.textContent = \"\";\r\n displayLiveResult.textContent = \"\";\r\n check = \"\";\r\n } else {\r\n //else only one char from last of string will be removed\r\n displayResult.textContent = displayResult.textContent.substr(\r\n 0,\r\n displayResult.textContent.length - 1\r\n );\r\n check = check.substr(0, check.length - 1);\r\n /*show live result we send results to show live result function after each click\r\n on operators and numbers and backspace*/\r\n showLiveResult(displayResult.textContent);\r\n }\r\n }\r\n }\r\n}", "function UserInputs(action, input) {\n switch (action) {\n case \"concert-this\":\n runBandsInTown(input);\n fixString(input)\n break;\n case \"spotify-this-song\":\n runSpotify(input);\n fixString(input)\n break;\n case \"movie-this\":\n runOmdb(input);\n fixString(input)\n break;\n case \"do-what-it-says\":\n runRandom(input);\n break;\n default:\n console.log(\"\\n--------------------------------------------------------\");\n console.log(\n \"Please enter a valid argument, such as:\\n\\nnode liri.js movie-this [MOVIE TITLE]\\n\\nnode liri.js spotify-this-song [SONG TITLE]\\n\\nnode liri.js concert-this [ARTIST NAME]\\n\\nnode liri.js do-what-it-says\"\n );\n console.log(\n \"--------------------------------------------------------\\n\\n\"\n );\n }\n}", "handleKeyCommand(command, editorState) {\n const newState = RichUtils.handleKeyCommand(editorState, command);\n if (newState) {\n this.onChange(newState);\n return 'handled';\n }\n return 'not-handled';\n }", "function evaluateInput()\n {\n var inputText = my.html.input.value\n var inputLength = inputText.length\n\n // If the tutor is in READY state, and input has been entered,\n // then set it to RUNNING STATE.\n if (my.current.state == my.STATE.READY && inputLength > 0) {\n\n my.current.startTime = new Date().getTime()\n my.current.state = my.STATE.RUNNING\n updatePracticePaneState()\n\n log('state', my.current.state.toUpperCase(),\n 'unit', my.current.unitNo + '.' + my.current.subunitNo,\n 'type', my.settings.unit)\n }\n\n // Number of characters correctly typed by the user\n var goodChars = Util.common(my.current.subunitText, inputText)\n my.current.correctInputLength = goodChars\n\n // Validate the input\n if (goodChars == inputLength) {\n\n // Clear error if any\n if (my.current.state == my.STATE.ERROR) {\n\n my.current.state = my.STATE.RUNNING\n updatePracticePaneState()\n }\n } else {\n\n // Set and display error\n if (my.current.state == my.STATE.RUNNING) {\n my.current.state = my.STATE.ERROR\n my.current.errors++\n updatePracticePaneState()\n } else if (my.current.state == my.STATE.ERROR) {\n processInputCommand()\n }\n }\n\n // Update error rate\n if (goodChars == 0) {\n if (my.current.errors == 0) {\n my.current.errorRate = 0\n } else {\n my.current.errorRate = Number.POSITIVE_INFINITY\n }\n } else {\n my.current.errorRate = 100 * my.current.errors / goodChars\n }\n\n // Check if the complete target text has been typed successfully\n if (goodChars == my.current.subunitText.length) {\n my.current.state = my.STATE.COMPLETED\n updatePracticePaneState()\n }\n }", "function processCommand(message)\n{\n if(message.action != \"execute\")\n {\n console.error(\"Unknown action of the message\");\n return;\n }\n for(var key in message)\n {\n if(commands[key])\n commands[key].apply(null, message[key]);\n }\n}", "function parseText(text){\n var containsTurn = (text.indexOf(\"turn\") >= 0),\n containsChange = text.indexOf(\"change\") >= 0,\n containsSet = text.indexOf(\"set\") >= 0,\n containsLight = (text.indexOf(\"light\") >= 0);\n if ((containsTurn || containsChange || containsSet ) && containsLight) {\n parseCommand(text);\n }\n}" ]
[ "0.5959118", "0.58217865", "0.58019996", "0.5768349", "0.5623921", "0.55826753", "0.552547", "0.54393476", "0.5423634", "0.5421429", "0.5404077", "0.5386142", "0.537462", "0.5317956", "0.53178096", "0.5307177", "0.52626866", "0.52485746", "0.5248293", "0.52112913", "0.52062845", "0.5194742", "0.51838636", "0.5167228", "0.5140333", "0.5138397", "0.51113564", "0.5104242", "0.5102777", "0.5088123", "0.50773215", "0.50596374", "0.5058876", "0.5056714", "0.5043891", "0.50132227", "0.49991897", "0.49970448", "0.49850678", "0.4983593", "0.4983593", "0.4973012", "0.4958832", "0.49579495", "0.49475366", "0.4939242", "0.4917873", "0.49061632", "0.4894535", "0.48935676", "0.48872817", "0.48827937", "0.48800588", "0.48723617", "0.48694313", "0.48608407", "0.4854977", "0.484971", "0.48470587", "0.48456234", "0.48383966", "0.48217964", "0.4821511", "0.48146105", "0.48146105", "0.48141074", "0.48083046", "0.48047712", "0.48020718", "0.48016015", "0.47991747", "0.4788224", "0.47820798", "0.47656345", "0.4761145", "0.47610638", "0.47591427", "0.47551817", "0.47539377", "0.4746816", "0.4746444", "0.47456416", "0.47442144", "0.4740417", "0.47382104", "0.47319654", "0.47238773", "0.47199067", "0.4712747", "0.47085693", "0.4707188", "0.47063017", "0.47048178", "0.4704162", "0.4697379", "0.46928513", "0.4691481", "0.46749738", "0.46675813", "0.4667529" ]
0.67122287
0
Check if the input entered by the user contains the specified command. The specified command is considered to be contained in the input if the input ends with the specified command. Return: true if the specified command is present in the input; false otherwise
function inputCommandIs(command) { var input = my.html.input.value return input.substring(input.length - command.length) == command }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "hasCmd(cmd) {\n return this.parsed._.includes(cmd.name);\n }", "function checkIfValidCommand(command) {\n\n var valid_commands = /df|mf|al[0-9]+|ar[0-9]|none+/i;\n\n if (valid_commands.test(command)) {\n return true;\n } else {\n console.log(\"Unknown command: \" + command);\n return false;\n }\n}", "function checkCommand(intendedCommand) {\n var validCommand;\n if (intendedCommand === concert) {\n validCommand = true;\n callBandsTown();\n } else if (intendedCommand === spotify) {\n validCommand = true;\n callSpotify();\n } else if (intendedCommand === movie) {\n validCommand = true;\n callOmdb();\n } else if (intendedCommand === doWhat) {\n validCommand = true;\n callTxt();\n \n } else {\n validCommand = false;\n console.log('Invalid Command');\n }\n \n return validCommand;\n}", "function word_present(command, synonyms){\n for (n in synonyms){\n var synonym = synonyms[n];\n if (synonym.charAt(0) == \"<\"){\n //must be an exact match\n synonym = synonym.substring(1);\n if (command == synonym)\n return true;\n }\n else{\n if (command.includes(synonym))\n return true;\n }\n }\n return false;\n}", "function command_ok(command){\n if (command == 2 || command == 4 || command == 6 || command == 7){\n return true;\n }\n return false;\n}", "static isBotCommand(command) {\n const arr = command.split(\" \")\n if (!arr || arr.length != 2) {\n return false\n }\n else if (arr[0] != BotCommand) {\n return false\n }\n return true\n }", "verifyCommandInputValidity() {\n if (this.mode == Editor.MODE_COMMAND) {\n if (this.commandInput.getContent()[0] != \":\")\n this.changeMode(Editor.MODE_GENERAL);\n }\n }", "function checkCommand ( cmd ) {\r\n\tvar somethingUndefined = Object.keys( cmd ).some(function ( key ) {\r\n\t\treturn !cmd[ key ];\r\n\t}),\r\n\t\terror;\r\n\r\n\tif ( somethingUndefined ) {\r\n\t\terror = 'Illegal /learn object';\r\n\t}\r\n\r\n\tif ( !/^[\\w\\-]+$/.test(cmd.name) ) {\r\n\t\terror = 'Invalid command name';\r\n\t}\r\n\r\n\tif ( bot.commandExists(cmd.name.toLowerCase()) ) {\r\n\t\terror = 'Command ' + cmd.name + ' already exists';\r\n\t}\r\n\r\n\treturn error;\r\n}", "function commandExists(cmd){\n try{\n cp.execSync(\"where \" + cmd, {stdio:[\"ignore\"]});\n return true;\n }catch(err){\n return false;\n }\n}", "function textIsValidCommand(text) {\n var strArr = text.split(\"\\n\");\n var _iteratorNormalCompletion8 = true;\n var _didIteratorError8 = false;\n var _iteratorError8 = undefined;\n\n try {\n for (var _iterator8 = strArr[Symbol.iterator](), _step8; !(_iteratorNormalCompletion8 = (_step8 = _iterator8.next()).done); _iteratorNormalCompletion8 = true) {\n var str = _step8.value;\n\n var idx = str.indexOf('(');\n var idx2 = str.indexOf(')');\n if (!(idx > 0 && idx2 > idx)) {\n return false;\n }\n }\n } catch (err) {\n _didIteratorError8 = true;\n _iteratorError8 = err;\n } finally {\n try {\n if (!_iteratorNormalCompletion8 && _iterator8.return) {\n _iterator8.return();\n }\n } finally {\n if (_didIteratorError8) {\n throw _iteratorError8;\n }\n }\n }\n\n return true;\n}", "function validCommand() {\n console.log(\"\\n\" + \"Please enter a valid command from the following list:\");\n console.log(\"concert-this\");\n console.log(\"spotify-this-song\");\n console.log(\"movie-this\");\n console.log(\"do-what-it-says\" + \"\\n\");\n}", "hasCommand(commandName) {\n return !util_1.isUndefined(this.getCommand(commandName));\n }", "function findInput() {\n array = ['output', 'input', 'love'];\n return array.includes('input')\n}", "function is_write_command(command) {\n return /(pop)|(set)|(del)/i.test(command);\n}", "isCommandValid() {\n return (\n this.state.command.name === \"\" || this.state.command.queries.length < 2\n );\n }", "function checkCommand(e) {\n if (e.keyCode == 13) {\n var newCommand = $(this).val().split(\" \")[0];\n validateCommand(newCommand);\n $(this).val(\"\");\n } \n }", "isCommandEnabled(command) {\n var enabled = true;\n\n switch (command) {\n case \"open_in_folder_button\":\n if (gFolderDisplay.selectedCount != 1) {\n enabled = false;\n }\n break;\n case \"cmd_delete\":\n case \"cmd_shiftDelete\":\n case \"button_delete\":\n // this assumes that advanced searches don't cross accounts\n if (gFolderDisplay.selectedCount <= 0) {\n enabled = false;\n }\n break;\n case \"saveas_vf_button\":\n // need someway to see if there are any search criteria...\n return true;\n case \"cmd_selectAll\":\n return true;\n default:\n if (gFolderDisplay.selectedCount <= 0) {\n enabled = false;\n }\n break;\n }\n\n return enabled;\n }", "function validateCommand(command) {\n if (commandVerbs.indexOf(command) == -1) {\n doNotUnderstand();\n } else {\n getNewAdventure(command);\n }\n }", "isCommand(commandName) {\n return this.getCommand().name === commandName;\n }", "command(keys, exact = false) {\n \n // short-circuit check for exact\n if (exact && (keys.length !== this.pressed.length)) {\n return false\n }\n \n // check if all of our keys are pressed\n // short-circuits on failure\n for (let i = 0, ii = keys.length; i < ii; i++) {\n if (this.keys[keys[i]]) continue\n else return false\n }\n \n return true\n }", "function checkNewCommand() {\n \tconsole.log(\"Checking if command is valid.\");\n \tvar commandName = $(\"#addCommandName\").text().trim().toLowerCase();\n \tvar commandData = $(\"#addCommandData\").text().trim();\n \tvar commandPoints = Number($(\"#addCommandPoints\").text());\n \tvar commandUses = Number($(\"#addCommandUses\").text());\n \tvar repeat = document.getElementById(\"commandRepeatableChoice\").value\n \tvar commandRank = document.getElementById(\"rankChoiceAdd\").value;\n\n \tcommandName = commandName.replace(new RegExp(\"^[\\!]+\"), \"\").trim();\n \tif (commandName.length == 0 || commandName == \"!\") {\n \terrorMessageCommandModal(\"You must enter a command name!\", \"addCommandName\")\n \treturn\n \t} else {\n \tCommandHandle.findCommand(commandName).then(data => {\n \t\tif (data !== null) {\n \t\tconsole.log(\"The command \" + commandName + \" already exists\");\n \t\tdocument.getElementById(\"addCommandName\").classList.add(\"errorClass\");\n \t\tdocument.getElementById(\"errorMessageAdd\").innerHTML = \"This command already exists\";\n \t\treturn\n \t\t}\n \t})\n \t}\n \tresetMessageCommandModal(\"addCommandName\");\n\n \tif (commandData.length >= 255) {\n \t//max length is 255\n \terrorMessageCommandModal(\"This message is too long.\", \"addCommandData\");\n \treturn\n \t} else if (commandData.length == 0) {\n \terrorMessageCommandModal(\"You must type a message.\", \"addCommandData\");\n \treturn\n \t} else {\n \tcommandData = strip(commandData);\n \tresetMessageCommandModal(\"addCommandData\");\n \t}\n\n \tif (isNaN(commandPoints) == true) {\n \terrorMessageCommandModal(\"Points must be a number\", \"addCommandPoints\");\n \treturn\n \t} else if (Math.sign(parseFloat(commandPoints)) == -1) {\n \terrorMessageCommandModal(\"Cannot be negative\", \"addCommandPoints\");\n \treturn\n \t} else {\n \tresetMessageCommandModal(\"addCommandPoints\")\n \t}\n\n \tif (isNaN(commandUses) == true) {\n \terrorMessageCommandModal(\"Uses must be a number\", \"addCommandUses\");\n \treturn\n \t} else if (Math.sign(parseFloat(commandUses)) == -1) {\n \terrorMessageCommandModal(\"Cannot be negative\", \"addCommandUses\");\n \treturn\n \t} else {\n \tresetMessageCommandModal(\"addCommandUses\")\n \t}\n\n \tcommandData = commandData.replace(new RegExp(\"^[\\!]+\"), \"\").trim();\n\n \tif (repeat == \"false\") { repeat = false } else { repeat = true }\n\n \tconsole.log(commandName, commandData, commandPoints, commandUses, commandRank, null, repeat);\n \t//Adds a command to the DB\n \tCommandHandle.addCommand(commandName, null, commandData, commandUses, commandPoints, commandRank, null, repeat);\n \t//adds a row to the table with the new command info\n \taddCommandTable(commandName, commandData, commandUses, commandPoints, commandRank)\n \t$(\"#modalCart\").modal(\"hide\");\n\n \t// Shows an error in the modal\n \tfunction errorMessageCommandModal(message, errLocation) {\n \tvar addCommandName = document.getElementById(errLocation).parentElement;\n \tvar cmdErrorMessage = document.getElementById(\"errorMessageAdd\")\n \taddCommandName.classList.add(\"errorClass\");\n \tcmdErrorMessage.innerHTML = message;\n \tconsole.log(\"Command is not valid.\");\n \t}\n\n \t// resets the errors\n \tfunction resetMessageCommandModal(toBeReset) {\n \ttry {\n \t\tdocument.getElementById(toBeReset).parentElement.classList.remove(\"errorClass\");\n \t\tdocument.getElementById(\"errorMessageAdd\").innerHTML = \"\";\n \t} catch (error) {\n \t\tconsole.log(error);\n \t}\n \t}\n}", "function evaluateCmd(userInput) {\n //parses the user input to understand which command was typed\n const userInputArray = userInput.split(\" \");\n const command = userInputArray[0];\n\n switch (command) {\n case \"echo\":\n commandLibrary.echo(userInputArray.slice(1).join(\" \"));\n break;\n case \"cat\":\n commandLibrary.cat(userInputArray.slice(1));\n break;\n case \"head\":\n commandLibrary.head(userInputArray.slice(1));\n break;\n case \"tail\":\n commandLibrary.tail(userInputArray.slice(1));\n break;\n default:\n console.log('No such command found');\n }\n}", "function commandFinder(cmd) {\n\tvar activeCommands = JSON.parse(fs.readFileSync('./cmds.json', 'utf8'));\n\tvar splitInput = cmd.trim().split(\" \")\n\tfor (var i = 0; i < activeCommands.commands.length; i++) {\n\t\tif (activeCommands.commands[i].name.toLowerCase() == splitInput[0].toLowerCase()) {\n\t\t\tif (activeCommands.commands[i].name.toLowerCase() != \"exit\") {\n\t\t\t\tclearScreen();\n\t\t\t\trunScript(activeCommands.commands[i].file, function (err) {\n \t\t\t\tif (err) throw err;\n \t\t\t\t//clearScreen();\n \t\t\t\tconsole.log(`\\n-----------\\nThe ${activeCommands.commands[i].name} command has finished running.`);\n \t\t\t\taskForPrompt();\n\t\t\t\t});\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tconsole.log(\"\\nThe script has been terminated.\")\n\t\t\t\tprocess.exit()\n\t\t\t}\n\t\t}\n\t\tif (i + 1 == activeCommands.commands.length) {\n\t\t\tclearScreen()\n\t\t\tconsole.log(\"You didn't enter a valid command.\\nNeed help? Type in 'help' as your input.\\n\")\n\t\t\taskForPrompt()\n\t\t}\n\t}\n}", "function parseCommand(text){\n var words = text.split(\" \");\n for(var i=0; i < words.length; i++){\n if (words[i] in commandList){\n processCommand(words[i]);\n break;\n }\n }\n}", "runCmd() {\n switch(this.command) {\n case \"concert-this\":\n this.concertThis();\n break;\n case \"spotify-this-song\":\n this.spotifyThisSong();\n break;\n case \"movie-this\":\n this.movieThis();\n break;\n case \"do-what-it-says\":\n this.doWhatItSays();\n break;\n case undefined:\n this.usage();\n return false;\n default:\n console.log(`Unable to understand the command \"${this.command}\"\\n`);\n this.usage();\n return false;\n }\n\n return true;\n }", "function checkCommand(command) {\n\t\t/* premier check js pour certaine commandes like help */\n\t\tif (listeCommandes[command]['noserver'] == null) {\n\t\t\tjQuery.ajax({\n\t\t\t\ttype: \"POST\",\n\t\t\t\turl: '/chats/checkCommand',\n\t\t\t\tdata: {message: input.val(), onglet: ongletActuel},\n\t\t\t\tsuccess: function(data) {\n\t\t\t\t\targsRun = data;\n\t\t\t\t\tlisteCommandes[command]['run']();\n\t\t\t\t},\n\t\t\t\tdataType: 'json'\n\t\t\t});\n\t\t} else {\n\t\t\targsRun = input.val();\n\t\t\tlisteCommandes[command]['noserver']();\n\t\t}\n\t}", "function validateInput(key){\n\t\treturn (valid.indexOf(key) > -1) && (expected.indexOf(key) > -1);\n\t}", "function cmd(str, msg) { //Function for commands.\n return msg.content.startsWith(prefix + str);\n}", "function commandValid(args) {\n if (args.length < 3) {\n return false;\n }\n if (!Array.isArray(args)) {\n return false;\n }\n return true;\n}", "checkLetter(keyClicked) {\r\n if (this.phrase.includes(keyClicked)) {\r\n console.log('Yeah bitch');\r\n return true;\r\n } else {\r\n console.log('No Bitch');\r\n return false;\r\n }\r\n }", "function _isMenuThere(cmd) {\n return Menus.getMenuItem(editorContextMenu.id + \"-\" + cmd) ? true : false;\n }", "function checkWord({ results }) {\n const word = results[results.length - 1][0].transcript;\n\n let isValid = false;\n commands.forEach((command) => {\n if (word.includes(command)) {\n isValid = true;\n detectedSpeech = command;\n }\n });\n return isValid;\n}", "function contains(token) {\n\t\t\t\t\ttoken = generalTokenChecks(token);\n\n\t\t\t\t\t//Split the underlying string on spaces to get the list of tokens.\n\t\t\t\t\tvar tokenList = splitUnderlyingString.call(this);\n\n\t\t\t\t\t//Return true if token is a case-sensitive match for one of the tokens in the list \n\t\t\t\t\t//found in the previous step, or false otherwise\n\t\t\t\t\tfor (var i = 0; i < tokenList.length; i++) {\n\t\t\t\t\t\tif (tokenList[i] === token) {\n\t\t\t\t\t\t\treturn true;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\treturn false;\n\t\t\t\t}", "function complexCommand() {\n \n var save = input();\n /**\n * Save command pattern: save | string\n */\n var analyze = save.split(\" | \");\n var cmd = analyze[0];\n var str = analyze[1];\n\n if(cmd == str) {\n sessionStorage.setItem(\"data\", str);\n output().innerHTML += prefix() + '<br><p class=\"output\">Data saved.</p>';\n } \n}", "function exists(title, input)\n\t\t\t{\n\t\t\t\tfor(var i = 0; i < title.length; i++)\n\t\t\t\t{\n\t\t\t\t\tfor(var j = 0; j < input.length; j++)\n\t\t\t\t\t{\n\t\t\t\t\t\tif(new String(title[i]).valueOf() == new String(input[j]).valueOf())\n\t\t\t\t\t\t\treturn true;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn false;\n\t\t\t}", "function contains(input, value) {}", "function evaluateCmd(userInput) {\n //parses the user input to understand which command was typed\n const userInputArray = userInput.split(\" \");\n const command = userInputArray[0];\n switch (command) {\n case \"echo\":\n //we will add the functionality of echo next within the \t//object commandLibrary \n commandLibrary.echo(userInputArray.slice(1).join(\" \"));\n break;\n case \"cat\":\n commandLibrary.cat(userInputArray.slice(1));\n break;\n case \"head\":\n commandLibrary.head(userInputArray.slice(1));\n break;\n case \"tail\":\n commandLibrary.tail(userInputArray.slice(1));\n break;\n case \"r\":\n commandLibrary.r(userInputArray.slice(1));\n break;\n default:\n commandLibrary.errorHandler(command);\n break;\n }\n }", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n }", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n }", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n }", "function isKeypressCommand(nativeEvent) {\r\n\t return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\r\n\t // ctrlKey && altKey is equivalent to AltGr, and is not a command.\r\n\t !(nativeEvent.ctrlKey && nativeEvent.altKey);\r\n\t}", "function validateUserInput(){\n if(arg2.length>0){\n return true\n }else {\n return false\n }\n }", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}", "function isKeypressCommand(nativeEvent) {\n return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) &&\n // ctrlKey && altKey is equivalent to AltGr, and is not a command.\n !(nativeEvent.ctrlKey && nativeEvent.altKey);\n}" ]
[ "0.7033517", "0.6786447", "0.6714409", "0.65853816", "0.6538311", "0.650227", "0.63899565", "0.6280926", "0.6191514", "0.60680556", "0.6061942", "0.60344607", "0.6002469", "0.5984184", "0.5972817", "0.5945315", "0.59247154", "0.58821195", "0.5809269", "0.57636255", "0.57066196", "0.5675339", "0.56722206", "0.565522", "0.563733", "0.56165475", "0.55609924", "0.5558802", "0.54971296", "0.54489636", "0.5433075", "0.5427751", "0.5417071", "0.53834635", "0.53815436", "0.53736234", "0.5322798", "0.53130865", "0.53130865", "0.53130865", "0.53044224", "0.5296336", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112", "0.5287112" ]
0.80050147
0
Create an HTML element to display a pink heart and add it to the HTML page. Return: HTML element with containing the heart
function createHeart() { var span = document.createElement('span') span.style.position = 'absolute' span.style.color = '#f52887' span.style.opacity = '0' Util.addChildren(span, '\u2665') document.body.appendChild(span) return span }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function heartHeartHeart() {\r\n document.body.appendChild(heartsHome);\r\n heartBlock(); \r\n }", "function createHeart(color) {\r\n const heart = document.createElement(\"div\");\r\n heart.className = \"heart\";\r\n heartsHome.appendChild(heart);\r\n heart.style.backgroundColor = color;\r\n }", "function render_heart_rate(heart_rate){\n const target = document.getElementById('heart-rate-text');\n var hr = heart_rate;\n if (target) {\n target.innerHTML = hr;\n if (hr > 120 || hr < 50) {\n get_location();\n };\n };\n}", "function drawHeart (index) {\n const offset = index * 40;\n\n noStroke();\n fill(255, 0, 0);\n ellipse(offset + 30, 60, 15, 15);\n ellipse(offset + 40, 60, 15, 15);\n triangle(offset + 23, 63, offset + 47, 63, offset + 35, 75);\n}", "function makeHeart(x,y,type){\n\ttype += '_heart';\n\treturn makePowerup(x,y,type,GAIN_HEALTH);\n}", "function drawLives()\n{\n offset = 0;\n push();\n \n fill(255, 0, 0);\n for(i = 0; i < lives; i++)\n {\n heart(width-150+offset, 20, 18);\n offset += 30; \n }\n pop();\n}", "function drawHeart(context, elem, xp, yp, wp, hp){\n let width = pc(wp, elem.width); \n let height = pc(hp, elem.height); \n let y = pc(yp, elem.height); \n let x = pc(xp, elem.width); \n let topCurveHeight = height * 0.3;\n context.moveTo(x, y + topCurveHeight);\n context.bezierCurveTo(x, y,x - width / 2, y,x - width / 2, y + topCurveHeight);\n context.bezierCurveTo(x - width / 2, y + (height + topCurveHeight) / 2, x, y + (height + topCurveHeight) / 2,x, y + height);\n context.bezierCurveTo(x, y + (height + topCurveHeight) / 2, x + width / 2, y + (height + topCurveHeight) / 2, x + width / 2, y + topCurveHeight);\n context.bezierCurveTo(x + width / 2, y, x, y,x, y + topCurveHeight);\n context.closePath();\n}", "function growingHearts()\n {\n var ox = 0\n var oy = 80\n\n var w = document.body.clientWidth - ox - 200\n var h = document.body.clientHeight - oy - 200\n\n var newInterval = Util.random(200, 2000)\n\n window.setInterval(function()\n {\n\n var heart = createHeart()\n heart.style.fontSize = '0%'\n heart.style.left = Util.random(ox, ox + w) + 'px'\n heart.style.top = Util.random(oy, oy + h) + 'px'\n\n var growInterval = Util.random(10, 50)\n var size = Util.random(200, 2000)\n var i = 0\n var id = window.setInterval(function()\n {\n i += 20\n heart.style.fontSize = i + '%'\n\n if (i < size / 2 ) {\n heart.style.opacity = '1'\n } else {\n heart.style.opacity = (1 - (2 * i - size) / size ) + ''\n }\n\n if (i >= size) {\n window.clearInterval(id)\n document.body.removeChild(heart)\n }\n }, growInterval)\n }, newInterval)\n }", "function risingHearts()\n {\n var ox = 0\n var oy = 80\n\n var w = document.body.clientWidth - ox - 200\n var h = document.body.clientHeight - oy - 200\n\n var newInterval = Util.random(200, 2000)\n\n window.setInterval(function()\n {\n var x = Util.random(ox, ox + w)\n var y = Util.random(oy + h - 100, oy + h)\n\n var heart = createHeart()\n heart.style.fontSize = Util.random(100, 2000) + '%'\n heart.style.left = x + 'px'\n heart.style.top = y + 'px'\n\n var riseInterval = Util.random(10, 50)\n var rise = Util.random(h / 4, h)\n var drift = Util.random(-1, 1)\n var i = 0\n var id = window.setInterval(function()\n {\n i++\n if (Util.random(1, 100) <= 1) {\n drift = (drift == Util.random(-1, 1) ? 1 : 0)\n }\n\n x = Math.min(Math.max(x + drift, ox), ox + w)\n\n heart.style.left = x + 'px'\n heart.style.top = (y - i) + 'px'\n\n if (i < rise / 4) {\n heart.style.opacity = (4 * i / rise) + ''\n } else if (i < rise / 2 ) {\n heart.style.opacity = '1'\n } else {\n heart.style.opacity = (1 - (2 * i - rise) / rise ) + ''\n }\n\n if (i >= rise) {\n window.clearInterval(id)\n document.body.removeChild(heart)\n }\n }, riseInterval)\n }, newInterval)\n }", "function Hearts(){\n\tvar life = document.createElement('img');\n\tlife.style.position = 'absolute';\n\tlife.height = 50;\n\tlife.width = 100;\n\tlife.style.top = 5 + '%';\n\tlife.style.left = 0 + '%';\n\tlife.src = \"../images/lifes.png\";\n\n\tvar heart0 = document.createElement('img');\n\theart0.id = 'heart0';\n\theart0.style.position = 'absolute';\n\theart0.height = 50;\n\theart0.width = 50;\n\theart0.style.top = 50 + 'px';\n\theart0.style.left = 10 + 'px';\n\theart0.src = \"../images/heart.png\"\n\n\tvar heart1 = document.createElement('img');\n\theart1.id = 'heart1';\n\theart1.style.position = 'absolute';\n\theart1.height = 50;\n\theart1.width = 50;\n\theart1.style.top = 50 + 'px';\n\theart1.style.left = 60 + 'px';\n\theart1.src = \"../images/heart.png\"\n\n\tvar heart2 = document.createElement('img');\n\theart2.id = 'heart2';\n\theart2.style.position = 'absolute';\n\theart2.height = 50;\n\theart2.width = 50;\n\theart2.style.top = 50 + 'px';\n\theart2.style.left = 110 + 'px';\n\theart2.src = \"../images/heart.png\"\n\n\tdocument.getElementById('hearts').appendChild(life);\n\tdocument.getElementById('hearts').appendChild(heart0);\n\tdocument.getElementById('hearts').appendChild(heart1);\n\tdocument.getElementById('hearts').appendChild(heart2);\n\n\t//create the image of the heart and the writing on top left of the screen\n}", "static get heartIconFilled() {\n const icon = 'data:image/svg+xml;utf8;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iaXNvLTg4NTktMSI/Pgo8IS0tIEdlbmVyYXRvcjogQWRvYmUgSWxsdXN0cmF0b3IgMTkuMC4wLCBTVkcgRXhwb3J0IFBsdWctSW4gLiBTVkcgVmVyc2lvbjogNi4wMCBCdWlsZCAwKSAgLS0+CjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmVyc2lvbj0iMS4xIiBpZD0iQ2FwYV8xIiB4PSIwcHgiIHk9IjBweCIgdmlld0JveD0iMCAwIDUwIDUwIiBzdHlsZT0iZW5hYmxlLWJhY2tncm91bmQ6bmV3IDAgMCA1MCA1MDsiIHhtbDpzcGFjZT0icHJlc2VydmUiIHdpZHRoPSIxNnB4IiBoZWlnaHQ9IjE2cHgiPgo8cGF0aCBzdHlsZT0iZmlsbDojRDc1QTRBOyIgZD0iTTI0Ljg1LDEwLjEyNmMyLjAxOC00Ljc4Myw2LjYyOC04LjEyNSwxMS45OS04LjEyNWM3LjIyMywwLDEyLjQyNSw2LjE3OSwxMy4wNzksMTMuNTQzICBjMCwwLDAuMzUzLDEuODI4LTAuNDI0LDUuMTE5Yy0xLjA1OCw0LjQ4Mi0zLjU0NSw4LjQ2NC02Ljg5OCwxMS41MDNMMjQuODUsNDhMNy40MDIsMzIuMTY1Yy0zLjM1My0zLjAzOC01Ljg0LTcuMDIxLTYuODk4LTExLjUwMyAgYy0wLjc3Ny0zLjI5MS0wLjQyNC01LjExOS0wLjQyNC01LjExOUMwLjczNCw4LjE3OSw1LjkzNiwyLDEzLjE1OSwyQzE4LjUyMiwyLDIyLjgzMiw1LjM0MywyNC44NSwxMC4xMjZ6Ii8+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+Cjwvc3ZnPgo=';\n return icon;\n }", "static get heartIconLight() {\n const icon = 'data:image/svg+xml;utf8;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iaXNvLTg4NTktMSI/Pgo8IS0tIEdlbmVyYXRvcjogQWRvYmUgSWxsdXN0cmF0b3IgMTkuMC4wLCBTVkcgRXhwb3J0IFBsdWctSW4gLiBTVkcgVmVyc2lvbjogNi4wMCBCdWlsZCAwKSAgLS0+CjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmVyc2lvbj0iMS4xIiBpZD0iQ2FwYV8xIiB4PSIwcHgiIHk9IjBweCIgdmlld0JveD0iMCAwIDUxLjk5NyA1MS45OTciIHN0eWxlPSJlbmFibGUtYmFja2dyb3VuZDpuZXcgMCAwIDUxLjk5NyA1MS45OTc7IiB4bWw6c3BhY2U9InByZXNlcnZlIiB3aWR0aD0iMTZweCIgaGVpZ2h0PSIxNnB4Ij4KPGc+Cgk8cGF0aCBkPSJNNTEuOTExLDE2LjI0MkM1MS4xNTIsNy44ODgsNDUuMjM5LDEuODI3LDM3LjgzOSwxLjgyN2MtNC45MywwLTkuNDQ0LDIuNjUzLTExLjk4NCw2LjkwNSAgIGMtMi41MTctNC4zMDctNi44NDYtNi45MDYtMTEuNjk3LTYuOTA2Yy03LjM5OSwwLTEzLjMxMyw2LjA2MS0xNC4wNzEsMTQuNDE1Yy0wLjA2LDAuMzY5LTAuMzA2LDIuMzExLDAuNDQyLDUuNDc4ICAgYzEuMDc4LDQuNTY4LDMuNTY4LDguNzIzLDcuMTk5LDEyLjAxM2wxOC4xMTUsMTYuNDM5bDE4LjQyNi0xNi40MzhjMy42MzEtMy4yOTEsNi4xMjEtNy40NDUsNy4xOTktMTIuMDE0ICAgQzUyLjIxNiwxOC41NTMsNTEuOTcsMTYuNjExLDUxLjkxMSwxNi4yNDJ6IE00OS41MjEsMjEuMjYxYy0wLjk4NCw0LjE3Mi0zLjI2NSw3Ljk3My02LjU5LDEwLjk4NUwyNS44NTUsNDcuNDgxTDkuMDcyLDMyLjI1ICAgYy0zLjMzMS0zLjAxOC01LjYxMS02LjgxOC02LjU5Ni0xMC45OWMtMC43MDgtMi45OTctMC40MTctNC42OS0wLjQxNi00LjcwMWwwLjAxNS0wLjEwMUMyLjcyNSw5LjEzOSw3LjgwNiwzLjgyNiwxNC4xNTgsMy44MjYgICBjNC42ODcsMCw4LjgxMywyLjg4LDEwLjc3MSw3LjUxNWwwLjkyMSwyLjE4M2wwLjkyMS0yLjE4M2MxLjkyNy00LjU2NCw2LjI3MS03LjUxNCwxMS4wNjktNy41MTQgICBjNi4zNTEsMCwxMS40MzMsNS4zMTMsMTIuMDk2LDEyLjcyN0M0OS45MzgsMTYuNTcsNTAuMjI5LDE4LjI2NCw0OS41MjEsMjEuMjYxeiIgZmlsbD0iIzAwMDAwMCIvPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+Cjwvc3ZnPgo=';\n return icon;\n }", "function createHeart(){\n for (let i = 1; i <= numberofHeart; i++) {\n var imgHeart = document.createElement('img');\n imgHeart.src=\"./img/like.svg\";\n imgHeart.id =\"like\" + i;\n \n imgHeart.style=\"position:absolute;z-index:0;\"\n document.body.appendChild(imgHeart);\n }\n }", "function drawHeart(){ \n //draws a light white background behind the heart\n ctx.save();\n ctx.translate(canvas.width/2, canvas.height/2);\n ctx.fillStyle=\"rgba(255,255,255,.5)\";\n ctx.strokeStyle=\"rgba(255,255,255,1)\";\n \n ctx.lineWidth=5;\n ctx.beginPath();\n ctx.arc(0,0,180,0,2*Math.PI);\n ctx.shadowBlur=15;\n ctx.shadowColor=\"white\";\n \n if(invert){\n ctx.shadowColor=\"grey\";\n }\n \n ctx.stroke();\n ctx.fill();\n ctx.restore();\n \n //heart curves\n ctx.save();\n ctx.translate(canvas.width/2, canvas.height/2);\n ctx.fillStyle=\"#BE1E73\";\n ctx.strokeStyle= \"pink\";\n ctx.lineWidth= 3;\n ctx.beginPath();\n ctx.moveTo(0,-15);\n ctx.bezierCurveTo( 0,-45, -50,-45, -50, -15);\n ctx.bezierCurveTo( -50,15, 0,20, 0, 45 );\n ctx.bezierCurveTo( 0,20, 50,15, 50, -15 ); \n ctx.bezierCurveTo( 50,-45, 0,-45, 0, -15);\n ctx.closePath();\n ctx.fill();\n ctx.shadowBlur=8;\n ctx.shadowColor=\"white\";\n \n if(invert){\n ctx.shadowColor=\"grey\";\n }\n ctx.stroke();\n ctx.restore();\n }", "function heart(x, y, size) \n{\n x_pos = x;\n y_pos = y;\n beginShape();\n vertex(x_pos, y_pos);\n bezierVertex(x_pos - size / 2, y_pos - size / 2, x_pos - size, y_pos + size / 3, x_pos, y_pos + size);\n bezierVertex(x_pos + size, y_pos + size / 3, x_pos + size / 2, y_pos - size / 2, x_pos, y_pos);\n endShape(CLOSE);\n}", "function N() {\n M = document.createElement('canvas');\n // Ensure same dimensions\n M.width = W;\n M.height = H;\n m = M.getContext('2d');\n\n // This color is the one of the filled shape\n S(m,B);\n // Fill the mask\n m.fillRect(0, 0, W, H);\n m.globalCompositeOperation = 'xor';\n\n\n // heart\n m.beginPath();\n Z = W/2;\n h = H/3;\n P = Math.PI;\n m.moveTo(Z,H*.8);\n m.lineTo(Z-h-(h/7),h+(h/8));\n m.arc(Z-(h/2), h, h*.6,P-(P/8),0);\n m.arc(Z+(h/2),h,h*.6,P,P/8);\n m.closePath();\n m.fill();\n\n m.font = O+\"px Arial\";\n S(m,B);\n m.fillText(s,Z-((h*(s.length*.1))),h/.7);\n}", "function heartLine(k) {\r\n var k;\r\n for (i = 0; i< 10; i++) {\r\n i = i + k;\r\n var color\r\n switch (i%5) {\r\n case 0:\r\n color = \"#9b5de5\"; // Amethyst\r\n break;\r\n case 1:\r\n color = \"#f15bb5\"; // Magenta Crayola\r\n break;\r\n case 2:\r\n color = \"#fee440\"; // Minion Yellow\r\n break;\r\n case 3:\r\n color = \"#00bbf9\"; // Capri\r\n break;\r\n case 4:\r\n color = \"#00f5d4\"; // Sea Green Crayola\r\n break;\r\n \r\n default:\r\n break;\r\n }\r\n i = i - k;\r\n setTimeout(createHeart,500*i, color);\r\n\r\n }\r\n\r\n }", "function setHeartIcon () {\n var image = data.images ? data.images[data.index] : data.image;\n if (Saved.has(image)) {\n page.querySelector('.app-button.heart').classList.add('fav');\n } else {\n page.querySelector('.app-button.heart').classList.remove('fav');\n }\n }", "function paint()\n{\n\tvar newText = document.createTextNode(\"polysaccharide\");\n\tvar newElem = document.createElement(\"h3\");\n\tnewElem.appendChild( newText );\n\tdocument.getElementById(\"cooties\").appendChild(newElem);\n\n}", "function heartUpdate(item) {\n item.addEventListener('click', (e) => {\n if (e.target.classList.contains('red')) {\n e.target.innerText = '♡'\n e.target.classList.toggle(\"red\")\n e.target.classList.toggle(\"heart\")\n } else {\n e.target.innerText = '♥'\n e.target.classList.toggle(\"red\")\n e.target.classList.toggle(\"heart\")\n }\n })\n}", "function drawHeart(evt) {\n\tvar position = getMouseXY(evt);\n\tvar img = new Image();\n\timg.onload = function() {\n\t\tcontext.drawImage(img,position.x,position.y);\n\t}\n\timg.src = \"heart_picture.png\";\n}", "function generateFavoriteButton(user, story) {\n const isFavorite = user.isFavorite(story);\n const heartType = isFavorite ? 'fas' : 'far';\n\n return `<div class=\"favorite\">\n <i class=\"${heartType} fa-heart\"></i>\n </div>`;\n}", "function fav(heart){\n\tif (heart.src.includes(\"heart_filled\"))\n\t\theart.src = \"/resources/pics/heart.png\";\n\telse\n\t\theart.src = \"/resources/pics/heart_filled.png\";\n}", "function changeHeart() {\r\n var star = document.getElementById('heart');\r\n if (health === 4) {\r\n star.src = \"https://res.cloudinary.com/dytmcam8b/image/upload/v1561725918/virtual%20pet/l1.png\";\r\n }\r\n else if (health === 3) {\r\n star.src = \"https://res.cloudinary.com/dytmcam8b/image/upload/v1561725919/virtual%20pet/l2.png\";\r\n } else if (health === 2) {\r\n star.src = \"https://res.cloudinary.com/dytmcam8b/image/upload/v1561725919/virtual%20pet/l3.png\";\r\n } else if (health === 1) {\r\n star.src = \"https://res.cloudinary.com/dytmcam8b/image/upload/v1561725919/virtual%20pet/l4.png\";\r\n }\r\n }", "function heartDiamond(){\n let hrtX = bgLeft + 7000;\n imageMode(CENTER);\n image(heartImg, hrtX, heartD.y,heartD.size, heartD.size);\n hrtTouch(hrtX);\n}", "function createCard(task) {\n var heartedClass = null;\n if(task.hearted) {heartedClass = \"hearted\"}\n return `\n <div class=\"card-container\">\n <div id=\"${task._id}\" class=\"card\">\n <img class=\"screenshot\" src=\"${task.screenshotURL}\"/>\n <h2 class=\"title\">${task.title}</h2>\n <input readonly type=\"number\" value=\"${task.voteCount}\" class=\"vote-count\"></input>\n <span class=\"heart-holder\">\n <div class=\"heart icon ` + heartedClass + ` \" ></div>\n </span>\n </div>\n </div>`;\n}", "function generateHaiku() {\n // Make a DIV with the new sentence\n var expansion = cfree.getExpansion('<start>');\n expansion = expansion.replace(/%/g, '<br/>');\n var par = createP(expansion);\n par.class('text');\n}", "function loveProduct (){\n $('.product-love ').click(function(){\n $(this).toggleClass('heart')\n if($(this).hasClass('heart')){\n this.innerHTML = `<i class=\"fas fa-heart love\"></i>`\n }else{\n this.innerHTML = `<i class=\"far fa-heart love\"></i>`\n }\n })\n }", "createElement(type, innerHTML, colorHex) {\n var element = document.createElement(`span`)\n element.innerHTML = \" \" + innerHTML\n element.style.color = `#${colorHex}`\n element.classList.add(type)\n //Jesli to wiadomosc to uzywamy emotek\n if (type == 'message') $(element).emoticonize()\n return element\n }", "function paintFavouriteSeries() {\r\n let htmlCode = \"\";\r\n htmlCode += `<button class=\"card__list--button-reset js-reset\">Borrar todo</button>`;\r\n for (const favourite of arrayFavourites) {\r\n htmlCode += `<li class=\"section-favourites__cards\">`;\r\n htmlCode += `<div class=\"section-favourites__cards--item\" id=\"${favourite.id}\">`;\r\n htmlCode += `<h4 \"section-favourites__cards--title\">${favourite.name}</h4>`;\r\n htmlCode += `<img class=\"section-favourites__cards--img\"\r\n src=\"${favourite.image}\"\r\n title=\"${favourite.name}\"\r\n alt=\"${favourite.name}\"/>`;\r\n htmlCode += `<i class=\"section-favourites__cards--button js-remove gg-trash\" id=\"${favourite.id}\"></i>`;\r\n }\r\n htmlCode += `</div>`;\r\n htmlCode += `</li>`;\r\n favouritesElement.innerHTML = htmlCode;\r\n setInLocalStorage();\r\n listenSeriesEvents();\r\n listenFavouritesEvents();\r\n}", "function addHeart() {\n\n // Grab all the heart images from the html page\n var heart1 = $(\"#heart1\");\n var heart2 = $(\"#heart2\");\n\n if (heart1.hasClass('removed') && heart2.hasClass('removed')) {\n heart2.removeClass('removed');\n } else if (heart1.hasClass('removed')) {\n heart1.removeClass('removed');\n }\n}", "function heart(){\n vm.input = vm.input.concat(\"❤️\");\n }", "function createWelcomeGraphic() {\n\n}", "function printHeart() {\n console.log('<3');\n}", "function updateHearts() {\n const lives = document.getElementById('lives');\n lives.innerHTML = '';\n numHearts = maxGuesses - missedGuesses;\n for (i = 0; i < numHearts; i++) {\n lives.insertAdjacentHTML('beforeend', liveHeartTemplate);\n }\n for (i = 0; i < missedGuesses; i++) {\n lives.insertAdjacentHTML('beforeend', lostHeartTemplate);\n }\n}", "function creerEtoile() {\r\n let div = document.createElement('div');\r\n div.classList.add('star');\r\n taille(div);\r\n positionAleatoire(div);\r\n main.appendChild(div);\r\n}", "function showJoker(ele) {\n ele\n .html('')\n .append(\n $('<img>')\n .attr('src', 'img/card_joker.png')\n .attr('class', 'joker')\n );\n}", "function countHearts() {\n\t\t$(\"#hearts\").html(\"\");\n\t\tfor (let i = 0; i < fullHearts; i++) {\n\t\t\t$(\"#hearts\").append('#');\n\t\t}\n\t\tfor (let j = 0; j < emptyHearts; j++) {\n\t\t\t$(\"#hearts\").append('*');\n\t\t}\n\n\t}", "function animateHeart(){\n if(stepAnimateHeart == 120){\n stepAnimateHeart--;\n }\n for (let i = 1; i <= numberofHeart; i++) {\n $('#like' + i).width(stepAnimateHeart*0.15); \n }\n if(stepAnimateHeart == 0){\n stepAnimateHeart++;\n }\n stepAnimateHeart++;\n requestAnimationFrame(animateHeart);\n }", "function heartBlock() {\r\n for (i = 0; i < 10; i++) {\r\n setTimeout(heartLine,5000*i,i);\r\n }\r\n }", "function Life() {\n var img;\n for (var i = 0; i < hleft; i++) {\n img = document.createElement('IMG');\n img.src = 'images/Heart.png';\n heart.appendChild(img);\n }\n}", "function applyBpm(bpm) {\n var d = document.getElementById(\"heart\")\n var bpmdiv = document.getElementById(\"bpm\")\n bpmdiv.innerHTML = bpm\n var size = 45\n //d.removeAttribute('animation');\n if (bpm < 60) {\n size *= 1.5\n }\n if (bpm >= 60 && bpm < 70) {\n size *= 1.8\n }\n if (bpm >= 70 && bpm < 80) {\n size *= 2.5\n }\n if (bpm >= 80 && bpm < 120) {\n size *= 2.8\n }\n if (bpm >= 120) {\n size *= 3\n }\n d.style.fontSize = size + \"px\"\n setTimeout(() => {\n d.style.fontSize = \"45px\"\n }, 100)\n }", "function renderHealth() {\n let playerHealth = document.getElementById(\"playerHealth\")\n let enemyHealth = document.getElementById(\"enemyHealth\")\n let buckName = document.getElementById(\"buckName\")\n let enemyName = document.getElementById(\"enemyName\")\n // Remove all playerHearts\n while (playerHealth.firstChild) {\n playerHealth.removeChild(playerHealth.lastChild);\n }\n // Render PlayerHearts\n for (let i = 0; i < playerHearts; i++) {\n let img = document.createElement(\"img\")\n img.src = \"assets/heart.png\"\n playerHealth.appendChild(img)\n\n // Render \"Buck's Health:\" text\n buckName.innerHTML = \"Buck's Health\"\n }\n // Remove all enemyHearts\n while (enemyHealth.firstChild) {\n enemyHealth.removeChild(enemyHealth.lastChild);\n }\n // Render enemyHearts\n for (let i = 0; i < enemyHearts; i++) {\n let img = document.createElement(\"img\")\n img.src = \"assets/heart.png\"\n enemyHealth.appendChild(img)\n\n // Render \"Enemies Health:\" text\n enemyName.innerHTML = \"Enemies Health\"\n }\n}", "function createHeartShape (width, height) {\n var shape = new THREE.Shape();\n\n var heartSpline = [\n {x:0.5, y:0.0},\n {x:0.45, y:0.15},\n {x:0.33, y:0.3},\n {x:0.10, y:0.6},\n {x:0.15, y:0.85},\n {x:0.30, y:0.95},\n {x:0.45, y:0.85},\n {x:0.5, y:0.65}\n ];\n var leftSpline = new Array();\n var rightSpline = new Array();\n for (var i=0; i<heartSpline.length; ++i) {\n leftSpline[i] = new THREE.Vector2(heartSpline[i].x*width, heartSpline[i].y*height);\n rightSpline[heartSpline.length-1-i] = new THREE.Vector2((1.0-heartSpline[i].x)*width, heartSpline[i].y*height);\n }\n\n shape.moveTo(width/2, 0);\n shape.splineThru(leftSpline);\n shape.splineThru(rightSpline);\n return shape;\n}", "function heartBeat() {\n //console.log(\"heartbeat\");\n // Call this function recursively framerate times\n // per second.\n requestAnimationFrame(heartBeat);\n \n // Increase the hue value slightly to get different\n // fire work colors over time.\n hue += 0.5;\n \n // Normally, ctx.clearRect() would be used to clear\n // the canvas (either all or part of it), but we want\n // to create a trail effect on our firework as it travles\n // through the night sky...\n //\n // Setting the composite operation of the context to\n // a value of \"destination-out\" will allow use to clear\n // the canvase at a specific opacity, rather than\n // wiping completly clear.\n ctx.globalCompositeOperation = \"destination-out\";\n \n // Decrease the alpha value to create more prominent trails\n ctx.fillStyle = \"rgba(0, 0, 0, 0.5)\";\n \n ctx.fillRect(0, 0, canvas.width, canvas.height);\n \n // Setting a new composite operation value of \"lighter\"\n // create bright highlight points as the fireworks and\n // particles overlap each other.\n ctx.globalCompositeOperation = \"lighter\";\n \n // Loop over each Firework particle, draw it and animate.\n var i = fireworks.length;\n \n while (i--) {\n fireworks[i].draw();\n fireworks[i].update(i);\n }\n \n // Loop over each Explosion particle, draw it and animate.\n var i = particles.length;\n \n while (i--) {\n particles[i].draw();\n particles[i].update(i);\n }\n \n // Loop over each Smoke particle, draw it and animate.\n var i = smokePuffs.length;\n \n while (i--) {\n smokePuffs[i].draw();\n smokePuffs[i].update(i);\n }\n \n // Launch fireworks automatically to random target\n // coordintates when the mouse isn't pressed down.\n if (timerTick >= timerTotal) {\n \n if (!mouseDown) {\n \n // Launch a firework particle from bottom\n // middle of screen, then set random target\n // coordinates. Note, target Y-position\n // should always be in top half of screen.\n fireworks.push(new Firework(canvasWidth / 2, canvasHeight, randRange(0, canvasWidth), randRange(0, canvasHeight / 2)));\n \n timerTick = 0;\n \n } // End of !mouseDown\n \n }else{\n timerTick++;\n } // End of timerTick >= timerTotal\n \n \n // Limit the rate at which fireworks get launched\n // when user presses mousedown\n if (limiterTick >= limiterTotal) {\n \n if (mouseDown) {\n \n // Launch firework from bottom middle of screen,\n // then set random target coordinates based on\n // mouse position\n fireworks.push(new Firework(canvasWidth / 2, canvasHeight, mouseXposition, mouseYposition));\n \n limiterTick = 0;\n \n }\n \n } else {\n limiterTick++;\n }\n\n}", "function addHearts(){\n $(\"#livesLeft\").empty();\n for(i=0;i<lives; i++){\n $(\"#livesLeft\").append('<img src=\"images/heart.png\" class=\"lifesize\">');\n }\n }", "function affLifes(){\n var heart =\"\";\n\n for (var i = 0; i < tableau.length; i++) {\n heart += '<img src=img/' + tableau[i] + '>';\n affCompteurLifes.innerHTML = heart;\n }\n}", "function hideHeart(heart){\n document.querySelector(\"#\"+ heart).style.display = \"none\";\n}", "createLifeElements(count = 0) {\n const life_block = document.createElement(\"div\");\n for (let i = 0; i < count; i++) {\n let life_span = document.createElement(\"span\");\n life_span.classList.add(\"life\");\n life_span.innerHTML = \"&hearts;\";\n life_span.style.color = \"red\";\n life_block.appendChild(life_span);\n }\n return life_block;\n }", "function doNewChar()\n{\n var randomKana = getRandomKana();\n \n document.getElementById('char-to-write').innerHTML = randomKana.char;\n \n document.getElementById('char-explanation').innerHTML = '(\"' + randomKana.romaji + '\" in ' + randomKana.type + ')';\n \n //put character on canvas and fade to nothing (starting at 1 opacity)\n //our trademark #990000 red is rgb(153, 0, 0)\n fadeCharOnCanvas(randomKana.char, 153, 0, 0, 1, 1, 100, 10);\n}", "function drawHealth() {\n push()\n fill(healthColor, 255, 100);\n noStroke();\n textSize(22);\n textAlign(RIGHT);\n text(\"HEALTH-->\", width / 1.1, height - 20)\n rect(width - 50, height, width - 50, -playerHealth);\n //if the players health is gettin glow, turn the recangle red, and play a ticking clock sound\n if (playerHealth < playerMaxHealth / 3) {\n healthColor = 0;\n tickTock.play();\n } else {\n healthColor = 120;\n tickTock.stop();\n }\n pop();\n}", "function drawhealth() {\n healthElem.textContent = health\n}", "function onClickHeart(){\n if(compname === \"\"){\n notification['warning']({\n message: 'Function Error',\n description:\n 'There is no company selected.',\n });\n }else{\n if(heartState === true){\n setheartState(false);\n notification.open({\n message: 'My Favourite List Change !',\n description:\n `${compname} has been removed from My Favourite.`,\n icon: <HeartOutlined style={{ color: 'red' }} />,\n });\n }else{\n setheartState(true);\n notification.open({\n message: 'My Favourite List Change !',\n description:\n `${compname} has been added to My Favourite.`,\n icon: <HeartFilled style={{ color: 'red' }} />,\n });\n }\n }\n }", "function generateFavoriteHTML(story) {\n let hostName = getHostName(story.url);\n let starClass = \"fas\";\n // if (story has been favorited by user){\n // starClass = \"fas\";\n // }\n // console.log('story is ', story);\n // render favorite markup\n const favoriteMarkup = $(`\n <li id=\"${story.storyId}\">\n <span class=\"star\">\n <i class=\"${starClass} fa-star\"></i>\n </span>\n <a class=\"article-link\" href=\"${story.url}\" target=\"a_blank\">\n <strong>${story.title}</strong>\n </a>\n <small class=\"article-author\">by ${story.author}</small>\n <small class=\"article-hostname ${hostName}\">(${hostName})</small>\n <small class=\"article-username\">posted by ${story.username}</small>\n </li>\n `);\n return favoriteMarkup;\n }", "function displayIntroTitle(){\n push();\n textFont(`Blenny`);\n textAlign(CENTER,CENTER);\n textSize(140);\n fill(breadFill.r, breadFill.g, breadFill.b);\n text(`get this bread`, width/2, height/2);\n pop();\n push();\n textFont(`Blenny`);\n textAlign(CENTER,CENTER);\n textSize(40);\n fill(255);\n text(`press anywhere to continue`, width/2, height/1.5);\n pop();\n}", "function createRainbow() {\n const el = document.createElement(\"div\")\n // One would usually use classList but this time we are sure the are no other classes\n el.className = \"rainbow\"\n return el\n}", "function renderHealth() {\n var heart = new Image();\n heart.src = 'images\\\\heart.png'\n\n htx.clearRect(0, 0, htx.canvas.width, htx.canvas.height);\n if (player.health === 1) {\n htx.drawImage(heart, 0, 0);\n } else if (player.health === 2) {\n htx.drawImage(heart, 0, 0);\n htx.drawImage(heart, 30, 0);\n } else if (player.health === 3) {\n htx.drawImage(heart, 0, 0);\n htx.drawImage(heart, 30, 0);\n htx.drawImage(heart, 60, 0);\n } else if (player.health === 4) {\n htx.drawImage(heart, 0, 0);\n htx.drawImage(heart, 30, 0);\n htx.drawImage(heart, 60, 0);\n htx.drawImage(heart, 90, 0);\n } else if (player.health === 5) {\n htx.drawImage(heart, 0, 0);\n htx.drawImage(heart, 30, 0);\n htx.drawImage(heart, 60, 0);\n htx.drawImage(heart, 90, 0);\n htx.drawImage(heart, 120, 0);\n }\n}", "function hearts() {\n ctx.font = \"20px Times New Roman\";\n //number of lives and location of the lives tab\n ctx.fillText(\"Level: \"+lives, 8, 20);\n}", "function drawTinyFireflies() {\n let segmentDrawn = 0;\n // The number of flies will loop until numFlies\n // They are going to be placed at random places\n // to give illusion of movement\n while (segmentDrawn < numFlies) {\n fireflyX = random(0, width);\n fireflyY = random(0, height);\n // Strake and stroke weight of the tiny fireflies\n stroke(255, 254, 166, preyHealth);\n strokeWeight(15)\n // Position and Size\n ellipse(fireflyX, fireflyY, fireflySize)\n // Segments are being drawn\n segmentDrawn++\n }\n}", "function heartBeat() {\n if ($(this).data('beating')) {\n $(this).animateCSS({\n 'duration': '0.2s',\n 'timing_function': 'ease-in',\n 'css': {'transform': \"scale(1.1, 1.1)\"}\n }).animateCSS({\n 'duration': '0.5s',\n 'timing_function': 'ease-out',\n 'css': {'transform': \"scale(1, 1)\"}\n }).queue(function(next) {\n heartBeat.call(this);\n next();\n });\n }\n }", "function addRandomGreeting() {\n const greetings =\n ['Hello!', \"Bonjour!\", \"Hola!\"];\n\n // Pick a random greeting.\n const greeting = greetings[Math.floor(Math.random() * greetings.length)];\n\n // Add it to the page.\n const greetingContainer = document.getElementById('greeting-container');\n greetingContainer.innerText = greeting;\n}", "function drawIcon(weatherText) {\r\n var element = document.getElementById(\"weather\") //Generate elements\r\n var weatherIcon = document.createElement(\"div\")\r\n var weatherDesc = document.createElement(\"div\")\r\n var weatherClass = document.createElement(\"div\")\r\n weatherIcon.className = \"weatherIcon\"\r\n weatherDesc.className = weatherText //Retrieve weather desription from json object\r\n weatherClass.className = \"inner\"\r\n element.appendChild(weatherIcon) //Append elements to div element\r\n weatherIcon.appendChild(weatherDesc)\r\n weatherDesc.appendChild(weatherClass)\r\n}", "function CreateHealthBar(htmlElem, index){\r\n var barContainer = document.createElement(\"DIV\");\r\n var bar = document.createElement(\"DIV\");\r\n barContainer.classList.add('bar-container');\r\n bar.classList.add('bar');\r\n barContainer.appendChild(bar);\r\n barContainer.id = 'bar' + index;\r\n htmlElem.appendChild(barContainer)\r\n }", "function displayLives(numLives) {\n var lives = $(\"#livesHearts\")\n lives.empty()\n var lifeElement = \"<i class='material-icons'>favorite</i>\"\n for (var i = 0; i < numLives; i++) {\n lives.append($(lifeElement))\n }\n }", "function drawDisplay() {\n\n let heart = objectImages.display[0];\n let bottle = objectImages.display[1];\n\n addObject(heart, 10, 0, 0.5);\n\n ctx.fillStyle = \"white\"\n ctx.globalAlpha = 0.5;\n ctx.fillRect(310, 32, 78, 30);\n ctx.globalAlpha = 1;\n\n ctx.font = \"28px sans-serif\";\n ctx.fillStyle = \"brown\";\n ctx.fillText(\"x \" + collectedBottles, 330, 58);\n\n addObject(bottle, 280, 15, 0.4);\n}", "render() {\n let msg = `\n <figure class=\"snip1336\">\n <div class=\"photo\"><img src = \"${this.image}\"></div>\n <figcaption>\n <p><strong>Name:</strong> ${this.name}</p> \n <p><strong>Surname:</strong> ${this.surename}</p>\n <p><strong>Age:</strong> ${this.age}</p>\n <p><strong>Gender:</strong> ${this.gender}</p>\n \n <button id=\"clickme\" onclick=\"document.getElementById('clickme').innerHTML=();\">like</button>\n <img id = \"hearth\" src = \"${this.LIKEimage}\"></p>\n\n <a href=\"#\"><i class=\"fa fa-twitter\"></i></a>\n <a href=\"#\"><i class=\"fa fa-facebook\"></i></a>\n <a href=\"#\"><i class=\"fa fa-instagram\"></i></a>\n <a href=\"#\"><i class=\"fa fa-linkedin\"></i></a>\n <figcaption>\n </figure>\n `; \n \n return msg;\n }", "render() {\n let msg = `\n <figure class=\"snip1336\">\n <div class=\"photo\"><img src = \"${this.image}\"></div>\n <figcaption>\n <p><strong>Name:</strong> ${this.name}</p> \n <p><strong>Surname:</strong> ${this.surename}</p>\n <p><strong>Age:</strong> ${this.age}</p>\n <p><strong>Gender:</strong> ${this.gender}</p>\n \n <button id=\"clickme\" onclick=\"document.getElementById('clickme').innerHTML=();\">like</button>\n <img id = \"hearth\" src = \"${this.LIKEimage}\"></p>\n\n <a href=\"#\"><i class=\"fa fa-twitter\"></i></a>\n <a href=\"#\"><i class=\"fa fa-facebook\"></i></a>\n <a href=\"#\"><i class=\"fa fa-instagram\"></i></a>\n <a href=\"#\"><i class=\"fa fa-linkedin\"></i></a>\n <figcaption>\n </figure>\n `; \n \n return msg;\n }", "function addRandomGreeting() {\n const greetings =\n ['Hello world!', '¡Hola Mundo!', '你好,世界!', 'Bonjour le monde!'];\n\n // Pick a random greeting.\n const greeting = greetings[Math.floor(Math.random() * greetings.length)];\n\n // Add it to the page.\n const greetingContainer = document.getElementById('greeting-container');\n greetingContainer.innerText = greeting;\n}", "render() {\n let msg = `\n <figure class=\"snip1336\">\n <div class=\"photo\"><img src = \"${this.image}\"></div>\n <figcaption>\n <p><strong>Name:</strong> ${this.name}</p> \n <p><strong>Surname:</strong> ${this.surename}</p>\n <p><strong>Age:</strong> ${this.age}</p>\n <p><strong>Gender:</strong> ${this.gender}</p>\n \n <button id=\"clickme\" onclick=\"document.getElementById('clickme').innerHTML=();\">like</button>\n <img id = \"hearth\" src = \"${this.LIKEimage}\"></p>\n\n <a href=\"#\"><i class=\"fa fa-twitter\"></i></a>\n <a href=\"#\"><i class=\"fa fa-facebook\"></i></a>\n <a href=\"#\"><i class=\"fa fa-instagram\"></i></a>\n <a href=\"#\"><i class=\"fa fa-linkedin\"></i></a>\n <figcaption>\n </figure>\n `; \n \n return msg;\n }", "function changeOfHeart() {\n var m = document.getElementById( 'bad-guy-list' ).children[1];\n document.getElementById( 'good-guy-list').appendChild( m );\n}", "function tjekVictory() {\n $('<h2 class=\"victory\">VICTORY</h2>').appendTo('body');\n }", "function addRandomGreeting() {\n const greetings =\n ['Hello world!', '¡Hola Mundo!', '你好,世界!', 'Bonjour le monde!'];\n\n // Pick a random greeting.\n const greeting = greetings[Math.floor(Math.random() * greetings.length)];\n\n // Add it to the page.\n const greetingContainer = document.getElementById('js-greeting-container');\n greetingContainer.innerText = greeting;\n}", "removeLife() {\r\n const lifeIcon = document.querySelector('[alt=\"Heart Icon\"]'); // returns first one it finds\r\n \r\n /* Apply heart icon css animation */\r\n lifeIcon.className = 'spin-heart';\r\n \r\n /* Allow animation to complete before changing to lost heart icon */\r\n window.setTimeout(() => {\r\n lifeIcon.className = null;\r\n lifeIcon.setAttribute('alt', 'Lost Heart Icon');\r\n lifeIcon.setAttribute('src', 'images/lostHeart.png');\r\n }, 750);\r\n \r\n this.missed += 1;\r\n if (this.missed === 4) this.gameOver(false);\r\n }", "function displayHearts() {\n\tdocument.getElementById(\"heart5\").hidden = false;\n\tdocument.getElementById(\"heart4\").hidden = false;\n\tdocument.getElementById(\"heart3\").hidden = false;\n\tdocument.getElementById(\"heart2\").hidden = false;\n\tdocument.getElementById(\"heart1\").hidden = false;\n\t\n\tif( health === 4) {\n\t\tdocument.getElementById(\"heart5\").hidden = true;\n\t\t\n\t}\n\t\n\tif( health === 3) {\n\t\tdocument.getElementById(\"heart5\").hidden = true;\n\t\tdocument.getElementById(\"heart4\").hidden = true;\n\t\t\n\t}\n\t\n\tif( health === 2) {\n\t\n\t\tdocument.getElementById(\"heart5\").hidden = true;\n\t\tdocument.getElementById(\"heart4\").hidden = true;\n\t\tdocument.getElementById(\"heart3\").hidden = true;\n\t\t\n\t\t\n\t\t\n\t}\n\t\n\tif( health === 1) {\n\t\tdocument.getElementById(\"heart5\").hidden = true;\n\t\tdocument.getElementById(\"heart4\").hidden = true;\n\t\tdocument.getElementById(\"heart3\").hidden = true;\n\t\tdocument.getElementById(\"heart2\").hidden = true;\n\t\t\n\t\t\n\t}\n\t\n\tif( health === 0) {\n\t\tdocument.getElementById(\"heart5\").hidden = true;\n\t\tdocument.getElementById(\"heart4\").hidden = true;\n\t\tdocument.getElementById(\"heart3\").hidden = true;\n\t\tdocument.getElementById(\"heart2\").hidden = true;\n\t\tdocument.getElementById(\"heart1\").hidden = true;\n\t\t\n\t}\n}", "function addRandomGreeting() {\n const greetings =\n ['I play for my Universites Volleyball Team', ' I play bass and guitar ', 'I´m in rock band called Los Insurgentes. Find us on Spotify ! '];\n\n // Pick a random greeting.\n const greeting = greetings[Math.floor(Math.random() * greetings.length)];\n\n // Add it to the page.\n const greetingContainer = document.getElementById('greeting-container');\n greetingContainer.innerText = greeting;\n}", "function HealthBarElement(fillStyle, strokeStyle, lineWidth, parent) {\n this._transparency = 1.0;\n this.rectangle = new rectangle_2.default(0, 0, 0, 0);\n this.rectangle.origin = rectangle_2.RectangleOrigin.TopLeft;\n this.rectangle.fillStyle = fillStyle;\n this.rectangle.strokeStyle = strokeStyle;\n this.rectangle.lineWidth = lineWidth;\n this._parent = parent;\n }", "function createStar(container) {\n const $span = $('<span><span>');\n const $star = $('<i></i>');\n $star.addClass('fas fa-star');\n $($span).append($star);\n $(container).append($span);\n}", "function createButton(left, bottom, icon)\n {\n var b = document.createElement( 'div' );\n b.classList.add(\"whiteboard\");\n b.style.position = \"absolute\";\n b.style.zIndex = 40;\n b.style.left = left + \"px\";\n b.style.bottom = bottom + \"px\";\n b.style.top = \"auto\";\n b.style.right = \"auto\";\n b.style.fontSize = \"16px\";\n b.style.padding = \"3px\";\n b.style.borderRadius = \"3px\";\n b.style.color = \"lightgrey\";\n if (icon)\n {\n b.classList.add(\"fas\");\n b.classList.add(icon);\n }\n reveal.appendChild(b);\n return b;\n }", "function addRandomGreeting() {\n const greetings =\n ['Hello world!', '¡Hola Mundo!', '你好,世界!', 'Bonjour le monde!', 'Greetings', \n `We have been trying to send a message to you for years. We don't know how or when this will reach you, but when it does, please, wake up. You have been asleep for ${Math.round(Math.random() * 10) + Math.round(Math.random() * 10)} years.`];\n\n // Pick a random greeting.\n const greeting = greetings[Math.floor(Math.random() * greetings.length)];\n\n // Add it to the page.\n const greetingContainer = document.getElementById('greeting-container');\n greetingContainer.innerText = greeting;\n}", "function addRandomGreeting() {\n const greetings =\n ['Hirasawa Yui', 'Tainaka Ritsu', 'Akiyama Mio', 'Kotobuki Tsumugi', 'Nakano Azusa'];\n\n // Pick a random greeting.\n const greeting = greetings[Math.floor(Math.random() * greetings.length)];\n\n // Add it to the page.\n const greetingContainer = document.getElementById('greeting-container');\n greetingContainer.innerText = greeting;\n}", "function addHtmlStep(say, vmode) {\n var tag; //will be appended to document\n \n // vmode controls how simple the HTML output\n switch (vmode) {\n case 0: // simple html for each step\n var txt = document.createTextNode(say);\n tag = document.createElement(\"h3\");\n if(say.length > 5) {\n // add umph\n var moremph = document.createElement(\"i\");\n moremph.appendChild(txt);\n tag.appendChild(moremph);\n }\n else {\n tag.appendChild(txt);\n }\n break;\n default:\n // mode not implemented; add nothing\n }\n \n // append to the designated <div>\n document.getElementById(\"result\").appendChild(tag);\n \n return tag;\n}", "function randomCrystalYellow() {\n $(\"#yellow-crystal\").html(yellowValue);\n }", "createTextLife(object) {\n return object.add.text(game.config.width - 70, 16, '♥ ' + lifes, { fontFamily: 'MV Boli Bold', fontSize: '35px', fill: '#fc2003' });\n }", "function addRandomGreeting() {\n const greetings =\n ['\"Hello, you.\"-Joe Goldberg', '\"Three words, eight letters. Say it and I am yours.\" -Blair Waldorf', '\"And so the lion fell in love with the lamb...\" -Edward Cullen', '\"How you doinnn?\" -Joey'];\n\n // Pick a random greeting.\n const greeting = greetings[Math.floor(Math.random() * greetings.length)];\n\n // Add it to the page.\n const greetingContainer = document.getElementById('greeting-container');\n greetingContainer.innerText = greeting;\n}", "function heartAll(elem){\n if ($(elem).find('span').hasClass(CLASS_NAMES.activated)){\n $('.fav_heart').removeClass(CLASS_NAMES.activated);\n } else {\n $('.fav_heart').addClass(CLASS_NAMES.activated);\n }\n}", "function bonneHeart(λOffset) {\r\n\t\tvar //φ0 = 1.2835, // 85° fixed for heart\r\n\t\t\tφ0 = 1.57079633, // 85° fixed for heart\r\n\t\t\tcotφ0 = 1 / Math.tan(φ0);\r\n\t\tfunction forward(λ, φ) {\r\n\t\t\tvar ρ = cotφ0 + φ0 - φ, E;\r\n\t\t\t\tE = ρ ? (λ + λOffset) * Math.cos(φ) / ρ : ρ;\r\n\t\t\treturn [ ρ * Math.sin(E), cotφ0 - ρ * Math.cos(E) ];\r\n\t\t}\r\n\t\t// Backward function not tested\r\n\t\tforward.invert = function(x, y) {\r\n\t\t\tvar ρ = Math.sqrt(x * x + (y = cotφ0 - y) * y), φ = cotφ0 + φ0 - ρ;\r\n\t\t\treturn [ ρ / Math.cos(φ) * Math.atan2(x, y) + λOffset, φ ];\r\n\t\t};\r\n\t\treturn forward;\r\n\t}", "function createBalloon(color) {\n document.write(\"<button class='balloon' onClick='blowUpBalloon()'>Balooooon</button>\");\n}", "function addRandomGreeting() {\n const greetings =\n ['I play viola and trumpet! I have played the viola since the 5th grade and trumpet since the 7th grade.'];\n\n // Pick a random greeting.\n const greeting = greetings[Math.floor(Math.random() * greetings.length)];\n\n // Add it to the page.\n const greetingContainer = document.getElementById('greeting-container');\n greetingContainer.innerText = greeting;\n}", "function createTitleElement(text, appendTo) {\n let title = document.createElement(\"h1\")\n let title_text = document.createTextNode(text)\n title.classList.add(\"text-center\");\n title.classList.add(\"mb-3\");\n title.appendChild(title_text)\n document.getElementById(appendTo).appendChild(title)\n}", "function createSticker(item){\n var img = $(\"<img>\");\n var figure = $(\"<figure>\");\n var figCaption = $(\"<figcaption>\").text(\"Rating: \"+item.rating);\n var button = $(\"<button>\");\n\n if(isFavorite(item)){\n button.html(\"<i class='fas fa-star'></i>\");\n button.attr(\"data-favorite\", \"yes\");\n }\n else{\n button.html(\"<i class='far fa-star'></i>\");\n button.attr(\"data-favorite\", \"no\");\n }\n\n \n button.attr(\"value\",item.id);\n button.click(addOrRemoveFavorite);\n\n img.attr(\"src\",item.images.original_still.url);\n img.attr(\"src-animated\",item.images.fixed_width.url);\n img.attr(\"src-original\",item.images.original_still.url);\n img.attr(\"title\",item.title);\n img.click(toggleSticker);\n img.addClass(\"sticker\");\n\n figure.attr(\"id\", item.id);\n\n figCaption.prepend(button);\n figure.append(img);\n figure.append(figCaption);\n stickers.append(figure);\n}", "__createRewardElement(reward_text) {\n let message_reward = document.createElement(\"span\");\n message_reward.classList.add(\"message__gold\");\n message_reward.innerHTML = `<span class=\"Gold\">Gold</span>: ${reward_text}`;\n return message_reward;\n }", "function createStar() {\n\tvar littleStar = new Star();\n\n\tvar left = littleStar.coordinates.x + 'px';\n\tvar top = littleStar.coordinates.y + 'px';\n\tvar width = littleStar.size.w + 'px';\n\tvar height = littleStar.size.h + 'px';\n\n\tvar $div = $('<div class=\"color star\"></div>');\n\n\t$($div).css(\"background-color\", \"white\");\n\t$($div).css(\"height\", height);\n\t$($div).css(\"width\", width);\n\t$($div).css(\"left\", left);\n\t$($div).css(\"top\", top);\n\n\t$('.night-sky').append($div);\n}", "function newDiv(){\n\tlet randomNumber = Math.floor( Math.random() * (quotes.length) )\n\tlet quote = quotes[ randomNumber ]\n\tlet d = document.createElement( 'span' )\n\td.textContent = quote\n\td.className = 'popup'\n\td.style.top = Math.random()* ( window.innerHeight ) / 3 + \"px\"\n\td.style.left = Math.random() * ( window.innerWidth ) / 3 + \"px\"\n\td.style.fontSize = Math.random() * 14 + 7 + \"px\"\n\n\tdocument.body.appendChild( d )\n\tsetTimeout(() => {\n\t\tdocument.body.removeChild( d )\n\t}, 5*1000)\n}", "function add_markX() {\n\t\t// Creates html through our javascript.\n\t\tthis.innerHTML = turnOdd;\n\t\tthis.style.background = \"lightred\";\n\t}", "function heart()\r\n{\r\n\tshape.call(this);\r\n\tthis.populate(this, mat4());\r\n\tthis.init_buffers();\r\n}", "function appendNotice() {\n const noticeContainer = document.createElement('div');\n const noticeFragment = document.createDocumentFragment();\n noticeContainer.classList.add('mb--lg');\n if (noticeMarkup) {\n noticeContainer.innerHTML = noticeMarkup();\n }\n noticeFragment.appendChild(noticeContainer);\n document.getElementById('root').appendChild(noticeFragment);\n}", "function bigImg(x) {\n x.style.color = \"yellow\";\n // document.getElementById(\"nombreADiv\").innerHTML = \"bla bla bla\"; \n //var newDiv = document.createElement(\"span\");\n // var t = document.createTextNode(\"Nuevo bloque\");\n // newDiv.appendChild(t);\n //document.getElementById(\"palabra1Div\").appendChild(newDiv);\n\n //document.getElementById(\"nombreADiv\").innerHTML = '<span class=\"title\">' + 'dentrospan' + '</span>';\n\n // var para = document.createElement(\"span\");\n // var t = document.createTextNode(\"This is a paragraph.\");\n // para.appendChild(t);\n // document.getElementById(\"title\").appendChild(para);\n\n// document.getElementById(\"title\").innerHTML = '<span class=\"title\">' + 'dentrospan' + '</span>';\n\n}", "resetHearts() {\r\n const lostHearts = document.querySelectorAll('[alt=\"Lost Heart Icon\"]');\r\n lostHearts.forEach(heart => {\r\n heart.setAttribute('alt', 'Heart Icon');\r\n heart.setAttribute('src', 'images/liveHeart.png');\r\n });\r\n }", "showTitle() {\n let title = document.createElement(\"h2\");\n title.innerHTML = \"Introduction\";\n\n this.main.appendChild(title);\n }", "function bakebrownie() {\r\n let brownie = document.createElement(\"aside\");\r\n document.body.appendChild(brownie);\r\n brownie.setAttribute(\"id\", \"Brownie\");\r\n brownie.innerHTML =\r\n \"<p>By continuing to browse \" +\r\n url +\r\n \" you agree to the use of cookies in your browser.</p>\" +\r\n \"<section id='buttons'><button id='eatbrownie'>Got it</button><a href='https://europa.eu/european-union/abouteuropa/cookies_en'>More info here</button></a>\";\r\n document.getElementById(\"eatbrownie\").addEventListener(\"click\", eatbrownie);\r\n}" ]
[ "0.76339394", "0.742686", "0.6561861", "0.6505662", "0.6476186", "0.6309439", "0.62926173", "0.6253584", "0.62520117", "0.6244221", "0.62009877", "0.6122166", "0.6114754", "0.60292", "0.6018961", "0.59802157", "0.59791756", "0.58925426", "0.58808786", "0.581332", "0.5811368", "0.5798168", "0.57945263", "0.5778548", "0.5774479", "0.57631654", "0.5756979", "0.5702802", "0.5684964", "0.56624407", "0.5641584", "0.5630231", "0.56095874", "0.5600692", "0.55951226", "0.5580498", "0.55801433", "0.5563075", "0.5550335", "0.5547269", "0.54975903", "0.5467708", "0.5421743", "0.54183257", "0.53954536", "0.5395124", "0.5387219", "0.5378103", "0.53611034", "0.53482723", "0.5336995", "0.5297538", "0.5291102", "0.5289681", "0.5288666", "0.52832466", "0.5279363", "0.52613336", "0.5252201", "0.5241818", "0.5235269", "0.5226118", "0.5225741", "0.5224293", "0.5219265", "0.52183324", "0.52183324", "0.52163404", "0.5214949", "0.52063656", "0.5202029", "0.5196121", "0.5194889", "0.51826435", "0.51803124", "0.51748276", "0.5173224", "0.51693153", "0.5165343", "0.51598674", "0.5153583", "0.51396716", "0.5138764", "0.513777", "0.5133547", "0.51334226", "0.513094", "0.51244265", "0.51115584", "0.5110155", "0.5110147", "0.5105686", "0.51047194", "0.51046807", "0.5104278", "0.51030487", "0.5093616", "0.50882864", "0.5087695", "0.5080733" ]
0.8188092
0
Display growing hearts all over the page.
function growingHearts() { var ox = 0 var oy = 80 var w = document.body.clientWidth - ox - 200 var h = document.body.clientHeight - oy - 200 var newInterval = Util.random(200, 2000) window.setInterval(function() { var heart = createHeart() heart.style.fontSize = '0%' heart.style.left = Util.random(ox, ox + w) + 'px' heart.style.top = Util.random(oy, oy + h) + 'px' var growInterval = Util.random(10, 50) var size = Util.random(200, 2000) var i = 0 var id = window.setInterval(function() { i += 20 heart.style.fontSize = i + '%' if (i < size / 2 ) { heart.style.opacity = '1' } else { heart.style.opacity = (1 - (2 * i - size) / size ) + '' } if (i >= size) { window.clearInterval(id) document.body.removeChild(heart) } }, growInterval) }, newInterval) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function risingHearts()\n {\n var ox = 0\n var oy = 80\n\n var w = document.body.clientWidth - ox - 200\n var h = document.body.clientHeight - oy - 200\n\n var newInterval = Util.random(200, 2000)\n\n window.setInterval(function()\n {\n var x = Util.random(ox, ox + w)\n var y = Util.random(oy + h - 100, oy + h)\n\n var heart = createHeart()\n heart.style.fontSize = Util.random(100, 2000) + '%'\n heart.style.left = x + 'px'\n heart.style.top = y + 'px'\n\n var riseInterval = Util.random(10, 50)\n var rise = Util.random(h / 4, h)\n var drift = Util.random(-1, 1)\n var i = 0\n var id = window.setInterval(function()\n {\n i++\n if (Util.random(1, 100) <= 1) {\n drift = (drift == Util.random(-1, 1) ? 1 : 0)\n }\n\n x = Math.min(Math.max(x + drift, ox), ox + w)\n\n heart.style.left = x + 'px'\n heart.style.top = (y - i) + 'px'\n\n if (i < rise / 4) {\n heart.style.opacity = (4 * i / rise) + ''\n } else if (i < rise / 2 ) {\n heart.style.opacity = '1'\n } else {\n heart.style.opacity = (1 - (2 * i - rise) / rise ) + ''\n }\n\n if (i >= rise) {\n window.clearInterval(id)\n document.body.removeChild(heart)\n }\n }, riseInterval)\n }, newInterval)\n }", "function countHearts() {\n\t\t$(\"#hearts\").html(\"\");\n\t\tfor (let i = 0; i < fullHearts; i++) {\n\t\t\t$(\"#hearts\").append('#');\n\t\t}\n\t\tfor (let j = 0; j < emptyHearts; j++) {\n\t\t\t$(\"#hearts\").append('*');\n\t\t}\n\n\t}", "function updateHearts() {\n const lives = document.getElementById('lives');\n lives.innerHTML = '';\n numHearts = maxGuesses - missedGuesses;\n for (i = 0; i < numHearts; i++) {\n lives.insertAdjacentHTML('beforeend', liveHeartTemplate);\n }\n for (i = 0; i < missedGuesses; i++) {\n lives.insertAdjacentHTML('beforeend', lostHeartTemplate);\n }\n}", "function displayHearts() {\n\tdocument.getElementById(\"heart5\").hidden = false;\n\tdocument.getElementById(\"heart4\").hidden = false;\n\tdocument.getElementById(\"heart3\").hidden = false;\n\tdocument.getElementById(\"heart2\").hidden = false;\n\tdocument.getElementById(\"heart1\").hidden = false;\n\t\n\tif( health === 4) {\n\t\tdocument.getElementById(\"heart5\").hidden = true;\n\t\t\n\t}\n\t\n\tif( health === 3) {\n\t\tdocument.getElementById(\"heart5\").hidden = true;\n\t\tdocument.getElementById(\"heart4\").hidden = true;\n\t\t\n\t}\n\t\n\tif( health === 2) {\n\t\n\t\tdocument.getElementById(\"heart5\").hidden = true;\n\t\tdocument.getElementById(\"heart4\").hidden = true;\n\t\tdocument.getElementById(\"heart3\").hidden = true;\n\t\t\n\t\t\n\t\t\n\t}\n\t\n\tif( health === 1) {\n\t\tdocument.getElementById(\"heart5\").hidden = true;\n\t\tdocument.getElementById(\"heart4\").hidden = true;\n\t\tdocument.getElementById(\"heart3\").hidden = true;\n\t\tdocument.getElementById(\"heart2\").hidden = true;\n\t\t\n\t\t\n\t}\n\t\n\tif( health === 0) {\n\t\tdocument.getElementById(\"heart5\").hidden = true;\n\t\tdocument.getElementById(\"heart4\").hidden = true;\n\t\tdocument.getElementById(\"heart3\").hidden = true;\n\t\tdocument.getElementById(\"heart2\").hidden = true;\n\t\tdocument.getElementById(\"heart1\").hidden = true;\n\t\t\n\t}\n}", "function hearts() {\n ctx.font = \"20px Times New Roman\";\n //number of lives and location of the lives tab\n ctx.fillText(\"Level: \"+lives, 8, 20);\n}", "function heartHeartHeart() {\r\n document.body.appendChild(heartsHome);\r\n heartBlock(); \r\n }", "function animateHeart(){\n if(stepAnimateHeart == 120){\n stepAnimateHeart--;\n }\n for (let i = 1; i <= numberofHeart; i++) {\n $('#like' + i).width(stepAnimateHeart*0.15); \n }\n if(stepAnimateHeart == 0){\n stepAnimateHeart++;\n }\n stepAnimateHeart++;\n requestAnimationFrame(animateHeart);\n }", "function drawLives()\n{\n offset = 0;\n push();\n \n fill(255, 0, 0);\n for(i = 0; i < lives; i++)\n {\n heart(width-150+offset, 20, 18);\n offset += 30; \n }\n pop();\n}", "function addHearts(){\n $(\"#livesLeft\").empty();\n for(i=0;i<lives; i++){\n $(\"#livesLeft\").append('<img src=\"images/heart.png\" class=\"lifesize\">');\n }\n }", "function drawLives() {\n\tfor (var i = 0; i < max_lives; i++) {\n\t\tif (i < lives) {\n\t\t\theart[i].style.visibility=\"visible\";\n\t\t}\n\t\telse {\n\t\t\theart[i].style.visibility=\"hidden\";\n\t\t}\n\t}\n}", "function Hearts(){\n\tvar life = document.createElement('img');\n\tlife.style.position = 'absolute';\n\tlife.height = 50;\n\tlife.width = 100;\n\tlife.style.top = 5 + '%';\n\tlife.style.left = 0 + '%';\n\tlife.src = \"../images/lifes.png\";\n\n\tvar heart0 = document.createElement('img');\n\theart0.id = 'heart0';\n\theart0.style.position = 'absolute';\n\theart0.height = 50;\n\theart0.width = 50;\n\theart0.style.top = 50 + 'px';\n\theart0.style.left = 10 + 'px';\n\theart0.src = \"../images/heart.png\"\n\n\tvar heart1 = document.createElement('img');\n\theart1.id = 'heart1';\n\theart1.style.position = 'absolute';\n\theart1.height = 50;\n\theart1.width = 50;\n\theart1.style.top = 50 + 'px';\n\theart1.style.left = 60 + 'px';\n\theart1.src = \"../images/heart.png\"\n\n\tvar heart2 = document.createElement('img');\n\theart2.id = 'heart2';\n\theart2.style.position = 'absolute';\n\theart2.height = 50;\n\theart2.width = 50;\n\theart2.style.top = 50 + 'px';\n\theart2.style.left = 110 + 'px';\n\theart2.src = \"../images/heart.png\"\n\n\tdocument.getElementById('hearts').appendChild(life);\n\tdocument.getElementById('hearts').appendChild(heart0);\n\tdocument.getElementById('hearts').appendChild(heart1);\n\tdocument.getElementById('hearts').appendChild(heart2);\n\n\t//create the image of the heart and the writing on top left of the screen\n}", "showEggs() {\n this.UpdatePoppedEggCount();\n }", "function drawHeart (index) {\n const offset = index * 40;\n\n noStroke();\n fill(255, 0, 0);\n ellipse(offset + 30, 60, 15, 15);\n ellipse(offset + 40, 60, 15, 15);\n triangle(offset + 23, 63, offset + 47, 63, offset + 35, 75);\n}", "function displayLives(numLives) {\n var lives = $(\"#livesHearts\")\n lives.empty()\n var lifeElement = \"<i class='material-icons'>favorite</i>\"\n for (var i = 0; i < numLives; i++) {\n lives.append($(lifeElement))\n }\n }", "function showHighscores() {\n statsEl.style.display = \"none\";\n highscoresEl.style.display = \"flex\";\n for (let i = 0; i < highscores.length; i++) {\n let entry = document.createElement(\"span\");\n entry.textContent = (i + 1) + \". \" + highscores[i];\n highscoresBox.appendChild(entry);\n }\n}", "display() {\n // Lerp to proper colors\n if (blackStarfield) {\n this.alpha = 127;\n this.bg = color(0);\n this.color = color(255);\n } else {\n this.alpha = lerp(this.alpha, curLevel.alpha, STARFIELD_LERP);\n this.bg = lerpColor(this.bg, color(curLevel.bg), STARFIELD_LERP);\n this.color = lerpColor(this.color, color(curLevel.color), STARFIELD_LERP);\n }\n\n // Skip rendering stars if low graphics mode\n if (!showStars) return;\n\n // Render stars\n for (let i = 0; i < this.stars.length; i++) {\n let s = this.stars[i];\n\n // Render star\n this.color.setAlpha(this.alpha * noise(s.noise));\n fill(this.color);\n noStroke();\n ellipse(s.x, s.y, s.r, s.r);\n\n // Update position\n if (!paused) {\n s.y += s.dy * dt();\n if (s.y - s.r > height) {\n s.r = random(2);\n s.x = random(width);\n s.y = 0;\n s.dy = random(this.speed);\n }\n }\n\n // Update noise\n s.noise += s.deltaNoise;\n }\n }", "function displayFish(fish) {\n push();\n fish.r = random(0,200);\n fish.g = random(0,200);\n fish.b = random(0,200);\n\n if(!fish.eaten) {\n fill(fish.r, fish.g, fish.b);\n noStroke();\n ellipse(fish.x, fish.y, fish.size);\n }\n\n pop();\n}", "function showMoreHighScores() {\n\n // Remove the See More Option\n UI.displaySeeMore(false);\n\n // Show all the high scores \n UI.displayHighScores(highScoreConfig.total);\n\n // Add the See Less Option\n UI.displaySeeLess(true);\n}", "reduceHearts() {\n const activeHeart = \"rgb(232, 9, 9)\";\n const lostHeart = \"rgb(232, 232, 232)\";\n if ($(\"#heart1\").css(\"color\") == activeHeart) {\n $(\"#heart1\").css(\"color\", lostHeart);\n }\n else if ( $(\"#heart2\").css(\"color\") == activeHeart) {\n $(\"#heart2\").css(\"color\", lostHeart);\n }\n else if ($(\"#heart3\").css(\"color\") == activeHeart) {\n $(\"#heart3\").css(\"color\", lostHeart);\n gameOver();\n }\n }", "function drawHen() {\n for (let i = 0; i < hens.length; i++) {\n let hen = hens[i];\n let image = currentHenImage;\n\n if (hen.dead) {\n image = 'img/chicken/hen_dead.png';\n }\n\n addBackgroundobject(image, hen.position_x, bg_ground, hen.position_y, hen.scale, 1);\n }\n}", "function showHighScores() {\n display.set(\"highScores\").show();\n }", "function dispStars() {\n let starsOnPage = generateStars();\n document.querySelector('.stars').innerHTML = starsOnPage;\n}", "function render_heart_rate(heart_rate){\n const target = document.getElementById('heart-rate-text');\n var hr = heart_rate;\n if (target) {\n target.innerHTML = hr;\n if (hr > 120 || hr < 50) {\n get_location();\n };\n };\n}", "function renderHealth() {\n let playerHealth = document.getElementById(\"playerHealth\")\n let enemyHealth = document.getElementById(\"enemyHealth\")\n let buckName = document.getElementById(\"buckName\")\n let enemyName = document.getElementById(\"enemyName\")\n // Remove all playerHearts\n while (playerHealth.firstChild) {\n playerHealth.removeChild(playerHealth.lastChild);\n }\n // Render PlayerHearts\n for (let i = 0; i < playerHearts; i++) {\n let img = document.createElement(\"img\")\n img.src = \"assets/heart.png\"\n playerHealth.appendChild(img)\n\n // Render \"Buck's Health:\" text\n buckName.innerHTML = \"Buck's Health\"\n }\n // Remove all enemyHearts\n while (enemyHealth.firstChild) {\n enemyHealth.removeChild(enemyHealth.lastChild);\n }\n // Render enemyHearts\n for (let i = 0; i < enemyHearts; i++) {\n let img = document.createElement(\"img\")\n img.src = \"assets/heart.png\"\n enemyHealth.appendChild(img)\n\n // Render \"Enemies Health:\" text\n enemyName.innerHTML = \"Enemies Health\"\n }\n}", "function InventoryItemMouthFuturisticHarnessPanelGagDraw() {\n\tInventoryItemMouthFuturisticPanelGagDraw();\n}", "makingHungry() {\n let calories = get('#calories > span');\n if (this.calories > 199)\n this.calories -= 200;\n else\n this.calories = 0;\n calories.innerHTML = this.calories;\n }", "function update_life() {\n leven = leven - 1;\n if (leven < 0) {\n leven = 0;\n } else {\n leven_span.text(leven);\n }\n }", "display() {\n if (this.health > 0) {\n push();\n noStroke();\n fill(this.fillColor);\n this.radius = this.health;\n ellipse(this.x, this.y, this.radius * 2);\n image(this.image, this.x, this.y, this.radius, this.radius);\n pop();\n } else {\n var removed = hunterList.splice(this.index, 1);\n }\n }", "display() {\n super.display();\n //Displays rock\n push();\n noStroke();\n fill(this.baseColor.r, this.baseColor.g, this.baseColor.b);\n ellipse(this.x, this.y, this.width,this.height);\n pop();\n }", "refreshing(heal) {\n this.newLine();\n this.player.health += Number(heal);\n console.log(\"Ah, refreshing.\");\n }", "function livesCounter(brokenHearts){\n if(brokenHearts === 0){\n //5 hearts on screen\n image(img, imgCoord.x -200, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x -100, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x +100, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x +200, imgCoord.y, imgCoord.size, imgCoord.size2);\n } else if (brokenHearts === 1){\n //4 hearts on screen\n image(img, imgCoord.x -200, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x -100, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x +100, imgCoord.y, imgCoord.size, imgCoord.size2);\n } else if (brokenHearts === 2){\n //3 hearts on screen\n image(img, imgCoord.x -200, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x -100, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x, imgCoord.y, imgCoord.size, imgCoord.size2);\n } else if (brokenHearts === 3){\n //2 hearts on screen\n image(img, imgCoord.x -200, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x -100, imgCoord.y, imgCoord.size, imgCoord.size2);\n } else if (brokenHearts === 4){\n //1 hearts on screen\n image(img, imgCoord.x -200, imgCoord.y, imgCoord.size, imgCoord.size2);\n } else if (brokenHearts === 5){\n //0 hearts on screen, finishes game\n state = 'ending';\n }\n}", "displayUI()\n {\n var score = document.getElementById(\"score\");\n score.innerHTML = this.score;\n var gameOver = document.getElementById(\"gameover\");\n var health = document.getElementById(\"health\");\n health.style.color = \"#FF0000\";\n health.innerHTML = '<img src=\"/assets/img/full_heart.png\"> </img>'.repeat(this.health);\n health.innerHTML += '<img src=\"/assets/img/empty_heart.png\"> </img>'.repeat(3-this.health);\n if(this.gameOver)\n {\n \n gameOver.innerHTML = \"Game Over. Press (p) to restart\";\n }\n else\n {\n gameOver.innerHTML = \"\";\n }\n\n }", "function createHeart()\n {\n var span = document.createElement('span')\n\n span.style.position = 'absolute'\n span.style.color = '#f52887'\n span.style.opacity = '0'\n Util.addChildren(span, '\\u2665')\n\n document.body.appendChild(span)\n return span\n }", "showAll() {\n if (app.startHP > 0) {\n $('.card-unmatched').css('opacity', 1);\n setTimeout(function () {\n $('.card-unmatched').css('opacity', 0);\n }, 2000);\n app.startHP -= 5;\n $('#hp').html('HP: ' + app.startHP);\n } else app.checkLose();\n }", "function clearHearts() {\r\n document.querySelector(\"#heartsHome\").remove();\r\n }", "function update() {\n document.getElementById('cheese-Count').innerText = cheese.toString();\n drawPerClickStat();\n}", "function showLessHighScores() {\n\n // Remove the see less option\n UI.displaySeeLess(false);\n\n // Show only the initial high scores \n UI.displayHighScores(highScoreConfig.initial);\n\n // Add the see more option\n UI.displaySeeMore(true);\n\n}", "function drawSmileFace() {\n\tdrawHead();\n\tdrawEyes();\n\tdrawSmile();\n}", "function showHighscore() {\n\tmenuHideAll();\n\t$('#highscore').show();\n\tmenuResetColors();\n\tmenuSetColor('highscoreBox');\n\tloadMenuHighscore();\n}", "function displayReaction(){\n var name;\n var currentX = horizontalBuffer;\n var currentY = verticalBuffer;\n currentX = currentX + setInitialXCoor(countSubstrates);\n drawSubstrates(currentX, currentY);\n\n currentY = currentY + objectHeight + verticalBuffer * 2; //for version with downwards arrow\n currentX = canvas1.width / 2; //for version with downwards arrow\n name = checkedEnzsNames[0];\n drawDownArrow(currentX, currentY, name);\n\n currentX = horizontalBuffer;\n currentY = verticalBuffer * 5 + objectHeight * 2;\n currentX = currentX + setInitialXCoor(countProducts);\n drawProducts(currentX, currentY);\n}", "display() {\n if (this.cards.length) {\n // show the top card and make all cards move towards the position\n // of the deck\n this.cards[0].display(this.pos.x, this.pos.y, true);\n this.cards.forEach(c => c.approach(this.pos));\n } else {\n //show the empty slot\n stroke(0);\n strokeWeight(3);\n fill(255, 255, 255, 100);\n rect(this.pos.x, this.pos.y, CARDWIDTH, CARDHEIGHT);\n }\n }", "function renderHS() {\n for (var i = 0; i < highScores.length; i++) {\n var highScore = highScores[i];\n\n var li = document.createElement(\"li\");\n li.textContent = highScore;\n li.setAttribute(\"data-index\", i);\n pEL.appendChild(li);\n }\n }", "display() {\n if (this.show){\n push();\n rectMode(CENTER);\n ellipseMode(CENTER);\n angleMode(DEGREES);\n stroke(255);\n strokeWeight(2);\n fill(this.color);\n ellipse(this.x, this.y, this.size);\n noStroke();\n fill(255);\n ellipse(this.x, this.y, this.size / 4);\n // if dies, it will shrink\n if (this.dead) {\n this.size -= 0.5;\n this.speed = 0;\n if (this.playOnce){\n Die.play();\n this.playOnce = false;\n }\n if (this.size <= 0) {\n this.animationFinished = true;\n this.show = false;\n // if it dies, the enemy base is no longer under attack\n if (this.theEnemyBase!=null){\n this.theEnemyBase.underAttack = false;\n }\n }\n }\n pop();\n }\n }", "function resetGame() {\n remainingHearts = 0;\n while (lifes.childNodes.length > 0) {\n // loops over how many hearts there is to remove the remaining, so when it adds new set it won't add up\n lifes.removeChild(lifes.childNodes[0]);\n }\n for (let h = 3; h > remainingHearts; h--) { // Creates the hearts for the page.\n let list = document.createElement(\"LI\")\n let listImg = document.createElement(\"IMG\")\n listImg.setAttribute('src', 'images/Heart.png')\n list.appendChild(listImg)\n document.getElementById(\"lifes\").appendChild(listImg);\n }\n remainingHearts = 3; // resets counter\n level = 1; // resets level-counter\n document.getElementById('level').innerHTML = level;\n allEnemies = [];\n showEnemies();\n}", "function showHighScoreContent() {\n if (highscoreData.highscores == undefined) {\n p5HTMLElements.push(createP('No Highscores to view here'));\n p5HTMLElements[p5HTMLElements.length - 1].position(view.options.x2 / 2 + 50, view.options.y + 100);\n return;\n }\n highscoreData.highscores.reverse();\n var tableContent = '<tr><th>Name</th><th>Score</th></tr>';\n for (var i = 0; i < highscoreData.highscores.length; i++) {\n tableContent += '<tr><td>' + highscoreData.highscores[i].name + '</td><td>' + highscoreData.highscores[i].score + '</td></tr>';\n }\n highscoreData.highscores.reverse();\n p5HTMLElements.push(createElement('table', tableContent));\n var highscoresTable = p5HTMLElements[p5HTMLElements.length - 1];\n highscoresTable.position(view.options.x + 10, view.options.y + 50);\n highscoresTable.size(view.options.x2 - 20, highscoresTable.size().height);\n}", "function showLives(){\n if(livesCounter == 3){\n image(heartLivesImg, 50, 65, 25,25);\n image(heartLivesImg, 80, 65, 25,25);\n image(heartLivesImg, 110, 65, 25,25);\n }\n else if (livesCounter == 2){\n image(heartLivesImg, 50, 65, 25,25);\n image(heartLivesImg, 80, 65, 25,25);\n }\n else if(livesCounter == 1){\n image(heartLivesImg, 50, 65, 25,25);\n }\n else if(livesCounter == 0) {\n image(transparentImg, 50, 65, 25,25);\n }\n}", "function drawStars() {\n translate(width / 2, height / 2);\n for (var i = 0; i < stars.length; i++) {\n stars[i].update();\n stars[i].show();\n }\n}", "function addHearts(){\r\n $(\"#trialsLeft\").empty();\r\n for(i = 0; i < trialsLeft; i++){\r\n $(\"#trialsLeft\").append('<img src=\"images/heart.png\" class=\"life\">');\r\n }\r\n}", "function drawHealth() {\n push()\n fill(healthColor, 255, 100);\n noStroke();\n textSize(22);\n textAlign(RIGHT);\n text(\"HEALTH-->\", width / 1.1, height - 20)\n rect(width - 50, height, width - 50, -playerHealth);\n //if the players health is gettin glow, turn the recangle red, and play a ticking clock sound\n if (playerHealth < playerMaxHealth / 3) {\n healthColor = 0;\n tickTock.play();\n } else {\n healthColor = 120;\n tickTock.stop();\n }\n pop();\n}", "function catchHeart(){\n for (let k = 1; k <= numberofHeart; k++) {\n setInterval(function(){\n if(j == (parseFloat($('#like'+k).css('left'))-790)/30 && i == (parseFloat($('#like'+k).css('top')) - 413)/30){\n life++;\n randomHeartPosition();\n }\n },5) \n }\n }", "_showHighScores () {\n // Clear the memoryContainer and populate with high-score-template\n this._clearContainer(this._container)\n this._container.classList.remove('memContainer')\n this._container.classList.add('highContainer')\n this._container.appendChild(this._highScoreTemplate)\n\n // Set up the high scores\n this._highScores = new HighScores(this._highScoreStorageName)\n this._highScores.setHighScores(this._playerName, this._cropTime(this._time, this._dec), this._tries)\n\n // First get the template for the list-item and clone it\n let firstItem = this._container.querySelector('#item1')\n let collection = this._container.querySelector('#highScore')\n\n // Style the first row\n this._container.querySelector('#item1').style.borderBottom = 'solid black'\n\n // Then loop through the objects\n let objKeys = Object.keys(this._highScores.getHighScores())\n let objValues = Object.values(this._highScores.getHighScores())\n\n for (let i = 0; i < objKeys.length; i++) {\n let item = firstItem.cloneNode(true)\n item.style.borderBottom = 'none'\n item.querySelector('#firstItem').textContent = objValues[i].name\n item.querySelector('#secondItem').textContent = objValues[i].tries\n item.querySelector('#thirdItem').textContent = objValues[i].time\n\n // item.querySelector('#firstItem').innerHTML = objValues[i].name\n // item.querySelector('#secondItem').innerHTML = objValues[i].time\n collection.appendChild(item)\n }\n\n // Save the high-score list\n this._highScores.saveHighScores()\n\n this._container.appendChild(collection)\n }", "function lighthouse(){\r\n var $lighthouse = $('.lighthouse');\r\n var height = $lighthouse.height();\r\n var raiseIncrement = 34;\r\n var numIncrements = Math.round(height/raiseIncrement);\r\n var steps = Math.round(numIncrements/3);\r\n\r\n //show the lighthouse\r\n $lighthouse.toggle();\r\n TweenMax.from($lighthouse,2, {top:\"100%\",ease: SteppedEase.config(steps),onComplete:showBeam});\r\n\r\n //Beam is done with CSS tranisition\r\n function showBeam(){\r\n $beam = $(\".lighthouse-beam\");\r\n $beam.addClass('grow-beam');\r\n TweenMax.set($lighthouse,{clearProps: \"top\"});\r\n }\r\n\r\n }", "function startExpedition(){\nif(gameData.fisherman < expeditionsArray[0][0]){\n document.getElementById(\"expeditionError\").innerHTML = \"Not Enough Funds\";\n}\nelse{\n gameData.totalGold = gameData.totalGold - expeditionsArray[0][1]\n gameData.fisherman = gameData.fisherman - expeditionsArray[0][2]\n document.getElementById(\"fisherman\").innerHTML = gameData.fisherman + \" fisherman\"\n document.getElementById(\"totalGold\").innerHTML = gameData.totalGold + \" gold\"\n var width = 0;\n var elem = document.getElementById(\"myBar\");\n var myVar = setInterval(function(){\n if(width < 60){\n width++;\n elem.style.width = width + '%';\n }\n else{\n gameData.fisherman = gameData.fisherman + expeditionsArray[0][0]\n gameData.totalGold = gameData.totalGold + expeditionsArray[0][1]\n }\n },1000*expeditionsArray[0][1]);\n}\n}", "function EatsCheese(isRandomCheese) {\n\n if (isRandomCheese) {\n eatenRandomCheese++;\n }\n else {\n eatenCheese++;\n }\n \n RatHappyAudio();\n\n var points = document.getElementById(\"spanScore\");\n var currentPoints = (eatenCheese * 1000) + (eatenRandomCheese * 2500);\n\n if (currentPoints < 10000) {\n points.innerHTML = \"0\" + currentPoints.toString();\n }\n else {\n points.innerHTML = currentPoints.toString();\n }\n}", "function drawHiker(x, y) {\n fill(backpackColor[i]); // backpack\n rect(x - 10, y + 10, HIKER_WIDTH, HIKER_HEIGHT / 2);\n fill(skinColor[i]); // skin\n rect(x, y, HIKER_WIDTH, HIKER_HEIGHT);\n fill(shirtColor[i]); // shirt\n rect(x, y + 12, HIKER_WIDTH, HIKER_HEIGHT - 15);\n fill(PANT_COLOR); // pants\n rect(x, y + 25, HIKER_WIDTH, HIKER_HEIGHT / 2);\n fill(hairColor[i]); // hair\n rect(x, y - 5, HIKER_WIDTH, HIKER_HEIGHT / 10);\n\n // adds long hair for every other hiker\n if (i % 2 == 1) {\n rect(x, y - 5, 5, 25);\n }\n}", "function scoreUpdate(){\r\n document.getElementById('score').innerText = piece.score;\r\n }", "function displayBreads() {\n\t\n\tdocument.getElementById(\"bread5\").hidden = false;\n\tdocument.getElementById(\"bread4\").hidden = false;\n\tdocument.getElementById(\"bread3\").hidden = false;\n\tdocument.getElementById(\"bread2\").hidden = false;\n\tdocument.getElementById(\"bread1\").hidden = false;\n\t\n\t\n\tif( hunger === 4) {\n\t\tdocument.getElementById(\"bread5\").hidden = true;\n\t\t\n\t}\n\t\n\tif( hunger === 3) {\n\t\tdocument.getElementById(\"bread5\").hidden = true;\n\t\tdocument.getElementById(\"bread4\").hidden = true;\n\t\t\n\t}\n\t\n\tif( hunger === 2) {\n\t\tdocument.getElementById(\"bread5\").hidden = true;\n\t\tdocument.getElementById(\"bread4\").hidden = true;\n\t\tdocument.getElementById(\"bread3\").hidden = true;\n\t\t\n\t\t\n\t}\n\t\n\tif( hunger === 1) {\n\t\tdocument.getElementById(\"bread5\").hidden = true;\n\t\tdocument.getElementById(\"bread4\").hidden = true;\n\t\tdocument.getElementById(\"bread3\").hidden = true;\n\t\tdocument.getElementById(\"bread2\").hidden = true;\n\t\t\n\t\t\n\t}\n\t\n\tif( hunger === 0) {\n\t\tdocument.getElementById(\"bread5\").hidden = true;\n\t\tdocument.getElementById(\"bread4\").hidden = true;\n\t\tdocument.getElementById(\"bread3\").hidden = true;\n\t\tdocument.getElementById(\"bread2\").hidden = true;\n\t\tdocument.getElementById(\"bread1\").hidden = true;\n\t}\n}", "function displayStars(num) {\n var starLevelTemplate = '<li><i class=\"fa fa-star fa-3x animated bounceIn\"></i></li>';\n var starTemplate = '<li><i class=\"fa fa-star \"></i></li>';\n $(\"#starLevel\").empty();\n $(\".stars\").empty();\n for (var i = 0; i < num; i++) {\n $(\".stars\").append(starTemplate);\n $(\"#starLevel\").append(starLevelTemplate)\n }\n }", "updateUI() {\n this.scoreText.setText(`Score ${this.bumperPoint}`);\n\n const emojis = [];\n for (let i = 0; i < this.healthPoint; i++) {\n emojis.push('❤');\n }\n let healthHearts = emojis.join().replace(/\\,/g, ' ');\n this.healthText.setText(`Health ${healthHearts}`);\n }", "function startExpedition(){\nif(gameData.fisherman < expeditionsArray[0][0]){\n document.getElementById(\"expeditionError\").innerHTML = \"Not Enough Funds\";\n}\nelse{\n gameData.totalGold = gameData.totalGold - expeditionsArray[0][1]\n gameData.fisherman = gameData.fisherman - expeditionsArray[0][2]\n document.getElementById(\"fisherman\").innerHTML = gameData.fisherman + \" fisherman\"\n document.getElementById(\"totalGold\").innerHTML = gameData.totalGold + \" gold\"\n var width = 0;\n var elem = document.getElementById(\"myBar\");\n var myVar = setInterval(function(){\n if(width < 60){\n width++;\n elem.style.width = width + '%';\n }\n else{\n gameData.fisherman = gameData.fisherman + expeditionsArray[0][0]\n gameData.totalGold = gameData.totalGold + expeditionsArray[0][1]\n }\n },1000*expeditionsArray[0][1]);\n}\n}//start expedition", "function hud() {\n let missileCount = 5 - playerMissile.pCooldown;\n\n CONTEXT.fillStyle = \"yellow\";\n CONTEXT.font = \"20px Arial\";\n CONTEXT.textAlign = \"left\";\n CONTEXT.fillText(\"LEVEL \\\\\\\\ \" + level, 10, 20);\n CONTEXT.textAlign = \"center\";\n CONTEXT.fillText(\"LIVES \\\\\\\\ \" + playerLives, C_WIDTH / 2, 20);\n CONTEXT.textAlign = \"left\";\n CONTEXT.fillText(\"MISSLES \\\\\\\\ \" + missileCount, C_WIDTH - 130, 20);\n}", "function updateLose() {\n\tpush();\n\t\ttranslate(screen.w/2,screen.h/2-cellwidth);\n\t\tfill(TEXTCOLOR);\n\t\tnoStroke();\n\t\ttextSize(cellwidth/2);\n\t\ttextAlign(CENTER,BOTTOM);\n\t\ttext(\"The gray squares ran you over.\\nYou died!\\n\",0,0);\n\t\ttextAlign(LEFT,TOP);\n\t\ttranslate(-cellwidth*2,0);\n\t\ttextSize(cellwidth/4);\n\t\tdisplayscores();\n\tpop();\n}", "function displayScores() {\n // Current score, large and in the center\n push();\n fill(random(200, 255));\n textSize(800);\n textAlign(CENTER, CENTER);\n text(score, width / 2, height / 2);\n pop();\n\n // High score in the top left\n push();\n fill(random(200, 255));\n textSize(64);\n textAlign(LEFT, TOP);\n text(`High score: ${highScore}`, 0, 0);\n pop();\n}", "scoreUpdateView() {\n let levelElement = document.getElementById(\"show-pontos\");\n levelElement.innerHTML = '<h2>' + this.score + '</h2>';\n }", "function lifeLine() {\n let rightMargin = 30;\n for (let i = lives; i > 0; i--) {\n ctx.font = \"30px Arial\";\n ctx.fillStyle = \"red\";\n ctx.fillText(\"♥\", canvas.width - rightMargin, canvas.height - 30);\n rightMargin = rightMargin + 30;\n }\n }", "function heartBlock() {\r\n for (i = 0; i < 10; i++) {\r\n setTimeout(heartLine,5000*i,i);\r\n }\r\n }", "function changeHeart() {\r\n var star = document.getElementById('heart');\r\n if (health === 4) {\r\n star.src = \"https://res.cloudinary.com/dytmcam8b/image/upload/v1561725918/virtual%20pet/l1.png\";\r\n }\r\n else if (health === 3) {\r\n star.src = \"https://res.cloudinary.com/dytmcam8b/image/upload/v1561725919/virtual%20pet/l2.png\";\r\n } else if (health === 2) {\r\n star.src = \"https://res.cloudinary.com/dytmcam8b/image/upload/v1561725919/virtual%20pet/l3.png\";\r\n } else if (health === 1) {\r\n star.src = \"https://res.cloudinary.com/dytmcam8b/image/upload/v1561725919/virtual%20pet/l4.png\";\r\n }\r\n }", "function showStars(num) {\n const starHtml = '<li class=\"fa fa-star\"></li>';\n stars.innerHTML = \"\";\n for (let i = 0; i < num; i++) {\n stars.innerHTML += starHtml;\n }\n }", "function renderHealth () {\n OasisCanvasContext.fillStyle = 'black';\n OasisCanvasContext.font = \"30px Arial\";\n OasisCanvasContext.fillText(\n '' + OasisPlayer.health + ' / 100',\n 50,\n 50\n );\n}", "function drawHands(){\n\n //draw seconds' hand\n push();\n rotate(secondAngle); \n stroke(255,0,0);\n strokeWeight(6);\n line(0,0,100,0);\n pop();\n\n //draw minutes' hand\n push();\n rotate(minuteAngle);\n stroke(0,255,0);\n strokeWeight(6);\n line(0,0,75,0);\n pop();\n\n //draw hours' hand\n push();\n rotate(hourAngle);\n stroke(0,0,255);\n strokeWeight(6);\n line(0,0,50,0);\n pop();\n}", "function displayFood() {\n push();\n noStroke();\n fill(food.color);\n ellipse(food.x,food.y,food.size);\n pop();\n}", "draw(){\n\t\t\t//console.log(this.growth);\n\t\t\tfor(let i = 0 ; i < this.growth.length ; i++){\n\t\t\t\tthis.growth[i].drawSnake('gold');\n\t\t\t}\n\t\t}", "function increaseHealth() {\n if (money >= prices.baseHealth) {\n players.baseHealth += 20;\n money -= prices.baseHealth;\n prices.baseHealth += Math.floor((prices.baseHealth * 0.5));\n quantities.baseHealth++;\n\n let element = document.getElementsByClassName('upgrades')[0].getElementsByClassName('upgrade')[0];\n element.getElementsByTagName('h4')[0].innerHTML = prices.baseHealth + \"$\";\n }\n}", "function drawhealth() {\n healthElem.textContent = health\n}", "function updateBigCup() {\n\t// Check how many cups are full\n\tconst fullCups = document.querySelectorAll('.cup.cup-small.full').length;\n\t// check total amount of cups\n\tconst totalCups = document.querySelectorAll('.cup.cup-small').length;\n\tconsole.log(fullCups, '/', totalCups);\n\n\t// Do this forth\n\t// Adjust volume in Big cup\n\t// according to number of full small cups\n\tif (fullCups === 0) {\n\t\t// Empty Big cup if no cups are full\n\t\tpercentage.style.visibility = 'hidden';\n\t\tpercentage.style.height = 0;\n\t} else {\n\t\t// Adjust height depending on number of full cups\n\t\tpercentage.style.visibility = 'visible';\n\t\tpercentage.style.height = `${(fullCups / totalCups) * 330}px`;\n\t\tpercentage.innerText = `${(fullCups / totalCups) * 100}%`;\n\t}\n\t// Do this last\n\t// Adjust Remained text according to number of full cups\n\tif (fullCups === totalCups) {\n\t\tremained.style.visibility = 'hidden';\n\t\tremained.style.height = 0;\n\t} else {\n\t\tremained.style.visibility = 'visible';\n\t\tliters.innerText = `${2 - (250 * fullCups) / 1000}L`;\n\t}\n}", "eatSkier() {\n this.eatingAnimate = this.animate(this.eatingAnimate, Constants.RHINO_EAT_ASSET, Constants.RHINO_EAT);\n }", "show(){\n\t\tnoStroke();\n strokeWeight(1);\n //size is correlated to food count\n\t\tfill(this.food,this.food/5,this.food/5);\n\t\tellipse(this.x,this.y,this.food/50);\n\t}", "function update() {\n document.getElementById(\"score\").innerHTML = \"Score: \" + score;\n document.getElementById(\"highScore\").innerHTML = \"High Score: \" + highScore;\n frames++;\n\n if (currentState !== states.Score) {\n foregroundPosition = (foregroundPosition - 2) % 14; // Move left two px each frame. Wrap every 14px.\n }\n\n if (currentState === states.Game) {\n corals.update();\n mines.update();\n }\n\n fish.update();\n //console.log(fish.y);\n}", "function maxHealthUpdate() {\r\n hbIncrement = hbWidth/maxHealth; \r\n}", "function draw(){\n for (var i=0; i<creepWords.length ; i++){\n creepWords[i].creep();\n creepWords[i].display();\n var volume = analyzer.getLevel();\n volume*='.8';\n strokeWeight(volume);\n }\n}", "showInfo() {\n let saturnInfo;\n if (!this.visible) {\n if(scorebox.score >= this.totalStars) {\n push();\n // Saturn infos\n saturnInfo = createGraphics(280, 250);\n saturnInfo.fill(green.r, green.g, green.b);\n saturnInfo.background(20, 220);\n saturnInfo.textSize(10);\n saturnInfo.textFont(globalFont);\n saturnInfo.textAlign(LEFT);\n saturnInfo.text(this.info, 10, 20, 260, 250);\n texture(saturnInfo);\n\n // Calling the superclass Planet.js' showInfo method\n super.showInfo();\n pop();\n }\n }\n }", "function renderHealth() {\n var heart = new Image();\n heart.src = 'images\\\\heart.png'\n\n htx.clearRect(0, 0, htx.canvas.width, htx.canvas.height);\n if (player.health === 1) {\n htx.drawImage(heart, 0, 0);\n } else if (player.health === 2) {\n htx.drawImage(heart, 0, 0);\n htx.drawImage(heart, 30, 0);\n } else if (player.health === 3) {\n htx.drawImage(heart, 0, 0);\n htx.drawImage(heart, 30, 0);\n htx.drawImage(heart, 60, 0);\n } else if (player.health === 4) {\n htx.drawImage(heart, 0, 0);\n htx.drawImage(heart, 30, 0);\n htx.drawImage(heart, 60, 0);\n htx.drawImage(heart, 90, 0);\n } else if (player.health === 5) {\n htx.drawImage(heart, 0, 0);\n htx.drawImage(heart, 30, 0);\n htx.drawImage(heart, 60, 0);\n htx.drawImage(heart, 90, 0);\n htx.drawImage(heart, 120, 0);\n }\n}", "function renderRecorePage() {\n endingSound.play();\n landingPage.style.display = \"none\";\n quizPage.style.display = \"none\";\n initialenterpage.style.display = \"none\";\n header.style.display = \"none\";\n finalPage.style.display = \"block\";\n record = JSON.parse(localStorage.getItem(\"data\"));\n record.sort(compare); // sort in decending order by score\n for (var i = 0; i < record.length; i++) {\n var currentScore = document.createElement(\"div\");\n if (i === 0) { //highest\n currentScore.textContent = \"🏅\" + (i + 1) + \". \" + record[i].initialName + \" - \" + record[i].score;\n currentScore.style.backgroundColor = \"gold\";\n } else if (i === 1) { //second highest\n currentScore.textContent = \"🥈\" + (i + 1) + \". \" + record[i].initialName + \" - \" + record[i].score;\n currentScore.style.backgroundColor = \"silver\";\n } else if (i === 2) { //third highest\n currentScore.textContent = \"🥉\" + (i + 1) + \". \" + record[i].initialName + \" - \" + record[i].score;\n currentScore.style.backgroundColor = \"#b87333\"; //copper\n } else {\n currentScore.textContent = (i + 1) + \". \" + record[i].initialName + \" - \" + record[i].score;\n currentScore.style.backgroundColor = \"green\";\n }\n scoreList.appendChild(currentScore);\n currentScore.style.marginBottom = \"10px\";\n }\n}", "display() {\n if (!this.visible) {\n if(scorebox.score >= this.totalStars) {\n push();\n // Title of planet\n push();\n let tag;\n let symbol_xPos = this.x + 20;\n let symbol_yPos = this.y + 30;\n let text_xPos = this.x - 20;\n let text_yPos = this.y + 30;\n\n fill(green.r, green.g, green.b);\n\n // Symbol\n textFont(symbolFont);\n textSize(this.symbolSize);\n text(this.symbol, symbol_xPos, symbol_yPos);\n\n // Title\n textFont(globalFont);\n textSize(this.titleSize);\n text(this.title, text_xPos, text_yPos);\n pop();\n\n // Custom colour of our Venus\n // RGB parameters + position\n // Pale pink\n pointLight(this.fill.r, this.fill.g, this.fill.b, this.fill.lightPosition);\n\n // Calling the superclass Planet.js' display method\n super.display();\n pop();\n }\n }\n }", "function maxHealthUpdate() {\n hbIncrement = hbWidth/maxHealth; \n}", "function addHearts(){\n $(\".life\").remove();\n for(i=0; i < trialsLeft; i++){\n // $(\"#trialsLeft\").empty();\n $(\"#trialsLeft\").append('<img src=\"images/heart.png\" class=\"life\">');\n }\n}", "function drawDisplay() {\n\n let heart = objectImages.display[0];\n let bottle = objectImages.display[1];\n\n addObject(heart, 10, 0, 0.5);\n\n ctx.fillStyle = \"white\"\n ctx.globalAlpha = 0.5;\n ctx.fillRect(310, 32, 78, 30);\n ctx.globalAlpha = 1;\n\n ctx.font = \"28px sans-serif\";\n ctx.fillStyle = \"brown\";\n ctx.fillText(\"x \" + collectedBottles, 330, 58);\n\n addObject(bottle, 280, 15, 0.4);\n}", "function draw() {\n\t//Redraw Background Color (Necessary?)\n\tbackground(0);\n\n\tfor (let i = 0; i < fishes.length; i++){ \n\t\t// If there is food on the screen, apply attractive force and display food\n\t\tif (food) {\n\t\t\tlet f = food.calculateAttraction(fishes[i]); \n\t\t\tfishes[i].applyForce(f); \n\t\t\tfood.display(); \n\t\t} else {\n\t\t\tfishes[i].meander();\n\t\t}\n\n\t\t// Update the properties of the fish (acceleration, velocity, location) etc\n\t\t// And display the fish\n\t\tfishes[i].update(); \n\t\tfishes[i].checkEdges();\n\t\tfishes[i].display();\n\t}\n\n\t// Text for slider\t\n\tfill(255);\n\ttextSize(16);\n\ttext('Food Size', 20, 120);\n\tfill(255);\n}", "function punch() {\n if (Player.health <= 0) {\n return;\n }\n Player.health -= 5 - (5 * Player.addMods());\n Player.damageMods();\n document.getElementById(\"armor-message\").innerText = \"\"\n //this is to keep the health bars current\n Player.hits++;\n update();\n}", "function level1() {\n checkLevelCompleted();\n drawBackground();\n drawIndian();\n createGoldArray(numberTreasure);\n displayTreasure(goldArray, numberTreasure);\n treasureHunting(numberTreasure);\n piranhaBottomRare();\n drawBottomPiranha(listOrderRare, imgFish1, speedFish);\n }", "function displayScore() {\n //Display current score\n push();\n fill(255);\n textSize(500);\n textAlign(CENTER, CENTER);\n text(currentScore, width / 2, height / 2);\n pop();\n //Display high score\n push();\n fill(255);\n textSize(30);\n textAlign(CENTER, CENTER);\n text(`High score: ${bubbleData.highScore}`, width / 2, height / 2 + 200);\n pop();\n}", "function draw() {\n background(0);\n\n for (let i = 0; i < microAgros.length; i++) {\n /// microAgros.length is the specific array variable that returns how many items are currently in the array\n if (microAgros[i].active) {\n moveAgros(microAgros[i]);\n displayAgros(microAgros[i]);\n }\n\n /// heart shrinks\n nbHeart.sizeW = nbHeart.sizeW - 0.1;\n nbHeart.sizeH = nbHeart.sizeH - 0.1;\n\n //when heart size is small enough, freeze screen and display second support token (END RESULT 2)\n if (nbHeart.sizeW <= 0) {\n supportToken2.active = true;\n noLoop();\n }\n }\n\n if (supportToken2.active === true) {\n displaySupportToken2();\n }\n\n displayNbHeart();\n\n if (supportToken.active === true) {\n displaySupportToken();\n moveSupportToken();\n }\n}", "function showViewHighScoreSection() {\n for (var i = 0; i < viewHighScore.length; i++) {\n viewHighScore[i].style.display = \"block\";\n }\n}", "function grassGrow(array) {\n if (asdf % 200 == 0) {\n for (let p = 0; p < array.length; p++) {\n array[p].y1 -= 1;\n }\n }\n asdf++;\n}", "function timeLine() {\n let width = 0;\n let itId = setInterval(() => {\n timeLineDiv.style.width = `${width}%`;\n width += 0.6;\n if (width > 100) {\n clearInterval(itId);\n if (heartsFave[0].classList.contains(\"fas\")) {\n heartsFave[0].classList.remove(\"fas\");\n heartsFave[0].classList.add(\"far\");\n }\n random();\n width = 0;\n timeLineDiv.style.width = `0%`;\n timeLine();\n }\n }, 100);\n}", "removeLife() {\r\n this.missed += 1;\r\n const hearts = document.querySelectorAll('li.tries');\r\n for (let i = 0; i < this.missed; i++) {\r\n hearts[i].innerHTML = '<img src=\"images/lostHeart.png\" alt=\"Heart Icon\" height=\"35\" width=\"30\">';\r\n }\r\n }", "function showStars() {\n let count;\n if (moveCount < 16) {\n count = 3;\n score = 60;\n } else if (moveCount < 32) {\n count = 2;\n score = 40;\n } else {\n count = 1;\n score = 10;\n }\n for (let i = 0; i < (stars.length - count); i++) {\n stars[i].setAttribute('style', 'display: none');\n }\n}", "function renderStagesLineUp() {\n let stagesLineUpOutPut = document.querySelector('#stagesLineUp');\n for (i = 0; i < stagesLineUp.length; i++) {\n stagesLineUpOutPut.innerHTML += `\n <article data-stagename=\"${stagesLineUp[i].acf.name}\">\n <h4>${stagesLineUp[i].acf.name}</h4>\n <hr>\n\n </article>\n `\n }\n getLineUpArtist();\n }", "function resetLives() {\n let lifeToRemove;\n lifeToRemove = document.getElementById('heart_three');\n lifeToRemove.style.display = \"inline-block\";\n lifeToRemove = document.getElementById('heart_two');\n lifeToRemove.style.display = \"inline-block\";\n lifeToRemove = document.getElementById('heart_one');\n lifeToRemove.style.display = \"inline-block\";\n lives = 3;\n}", "updateTop5Text() {\n const numSlots = 5;\n const players = this._entities.filterByType(EntityTypes.PLAYER);\n\n players.sort((a, b) => (b.getProp('points') || 0) - (a.getProp('points') || 0));\n\n for (let i = 0; i < numSlots; i++) {\n const key = `top5_${i + 1}`;\n const index = i - (numSlots - players.length);\n if (index >= 0 && players[index]) {\n this.updateText(\n key,\n { place: index + 1, player: players[index].getProp('name'), points: players[index].getProp('points') || 0 },\n { fill: players[index].getProp('hexColor') }\n );\n } else {\n this.hideText(key);\n }\n }\n }" ]
[ "0.7028781", "0.69954866", "0.6911459", "0.67804664", "0.66451013", "0.66191816", "0.65603215", "0.6518552", "0.6307231", "0.6275858", "0.62382776", "0.61654353", "0.61185664", "0.60795075", "0.6067219", "0.59611285", "0.5948496", "0.59225917", "0.591076", "0.58987635", "0.5892848", "0.588518", "0.58671933", "0.5840471", "0.5837398", "0.5818222", "0.5802816", "0.5794954", "0.5793289", "0.5773033", "0.5757499", "0.57497144", "0.57490057", "0.5748217", "0.5728935", "0.5697568", "0.56954044", "0.56631565", "0.5659858", "0.5653992", "0.5653449", "0.56492436", "0.564083", "0.5637906", "0.56316286", "0.56207377", "0.56191117", "0.56178665", "0.56058425", "0.55861604", "0.5583049", "0.5579075", "0.5543003", "0.5532027", "0.55204713", "0.55140805", "0.5510268", "0.55097026", "0.55007005", "0.5497036", "0.5495407", "0.54949003", "0.54944503", "0.5492926", "0.54926825", "0.5478669", "0.5476071", "0.5474818", "0.5474226", "0.54732233", "0.5473188", "0.5472259", "0.546334", "0.546017", "0.54592675", "0.54575205", "0.5439627", "0.5423107", "0.5411264", "0.5405159", "0.5403173", "0.5403071", "0.54027694", "0.5401609", "0.54008883", "0.54006577", "0.539678", "0.5393212", "0.538976", "0.5387825", "0.5386147", "0.5381907", "0.53796166", "0.5375761", "0.53719753", "0.53689545", "0.53674954", "0.53672045", "0.53670055", "0.53662556" ]
0.7471282
0
Display hearts rising across the page
function risingHearts() { var ox = 0 var oy = 80 var w = document.body.clientWidth - ox - 200 var h = document.body.clientHeight - oy - 200 var newInterval = Util.random(200, 2000) window.setInterval(function() { var x = Util.random(ox, ox + w) var y = Util.random(oy + h - 100, oy + h) var heart = createHeart() heart.style.fontSize = Util.random(100, 2000) + '%' heart.style.left = x + 'px' heart.style.top = y + 'px' var riseInterval = Util.random(10, 50) var rise = Util.random(h / 4, h) var drift = Util.random(-1, 1) var i = 0 var id = window.setInterval(function() { i++ if (Util.random(1, 100) <= 1) { drift = (drift == Util.random(-1, 1) ? 1 : 0) } x = Math.min(Math.max(x + drift, ox), ox + w) heart.style.left = x + 'px' heart.style.top = (y - i) + 'px' if (i < rise / 4) { heart.style.opacity = (4 * i / rise) + '' } else if (i < rise / 2 ) { heart.style.opacity = '1' } else { heart.style.opacity = (1 - (2 * i - rise) / rise ) + '' } if (i >= rise) { window.clearInterval(id) document.body.removeChild(heart) } }, riseInterval) }, newInterval) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function countHearts() {\n\t\t$(\"#hearts\").html(\"\");\n\t\tfor (let i = 0; i < fullHearts; i++) {\n\t\t\t$(\"#hearts\").append('#');\n\t\t}\n\t\tfor (let j = 0; j < emptyHearts; j++) {\n\t\t\t$(\"#hearts\").append('*');\n\t\t}\n\n\t}", "function hearts() {\n ctx.font = \"20px Times New Roman\";\n //number of lives and location of the lives tab\n ctx.fillText(\"Level: \"+lives, 8, 20);\n}", "function displayHearts() {\n\tdocument.getElementById(\"heart5\").hidden = false;\n\tdocument.getElementById(\"heart4\").hidden = false;\n\tdocument.getElementById(\"heart3\").hidden = false;\n\tdocument.getElementById(\"heart2\").hidden = false;\n\tdocument.getElementById(\"heart1\").hidden = false;\n\t\n\tif( health === 4) {\n\t\tdocument.getElementById(\"heart5\").hidden = true;\n\t\t\n\t}\n\t\n\tif( health === 3) {\n\t\tdocument.getElementById(\"heart5\").hidden = true;\n\t\tdocument.getElementById(\"heart4\").hidden = true;\n\t\t\n\t}\n\t\n\tif( health === 2) {\n\t\n\t\tdocument.getElementById(\"heart5\").hidden = true;\n\t\tdocument.getElementById(\"heart4\").hidden = true;\n\t\tdocument.getElementById(\"heart3\").hidden = true;\n\t\t\n\t\t\n\t\t\n\t}\n\t\n\tif( health === 1) {\n\t\tdocument.getElementById(\"heart5\").hidden = true;\n\t\tdocument.getElementById(\"heart4\").hidden = true;\n\t\tdocument.getElementById(\"heart3\").hidden = true;\n\t\tdocument.getElementById(\"heart2\").hidden = true;\n\t\t\n\t\t\n\t}\n\t\n\tif( health === 0) {\n\t\tdocument.getElementById(\"heart5\").hidden = true;\n\t\tdocument.getElementById(\"heart4\").hidden = true;\n\t\tdocument.getElementById(\"heart3\").hidden = true;\n\t\tdocument.getElementById(\"heart2\").hidden = true;\n\t\tdocument.getElementById(\"heart1\").hidden = true;\n\t\t\n\t}\n}", "function drawHeart (index) {\n const offset = index * 40;\n\n noStroke();\n fill(255, 0, 0);\n ellipse(offset + 30, 60, 15, 15);\n ellipse(offset + 40, 60, 15, 15);\n triangle(offset + 23, 63, offset + 47, 63, offset + 35, 75);\n}", "function drawLives()\n{\n offset = 0;\n push();\n \n fill(255, 0, 0);\n for(i = 0; i < lives; i++)\n {\n heart(width-150+offset, 20, 18);\n offset += 30; \n }\n pop();\n}", "function growingHearts()\n {\n var ox = 0\n var oy = 80\n\n var w = document.body.clientWidth - ox - 200\n var h = document.body.clientHeight - oy - 200\n\n var newInterval = Util.random(200, 2000)\n\n window.setInterval(function()\n {\n\n var heart = createHeart()\n heart.style.fontSize = '0%'\n heart.style.left = Util.random(ox, ox + w) + 'px'\n heart.style.top = Util.random(oy, oy + h) + 'px'\n\n var growInterval = Util.random(10, 50)\n var size = Util.random(200, 2000)\n var i = 0\n var id = window.setInterval(function()\n {\n i += 20\n heart.style.fontSize = i + '%'\n\n if (i < size / 2 ) {\n heart.style.opacity = '1'\n } else {\n heart.style.opacity = (1 - (2 * i - size) / size ) + ''\n }\n\n if (i >= size) {\n window.clearInterval(id)\n document.body.removeChild(heart)\n }\n }, growInterval)\n }, newInterval)\n }", "function displayFish(fish) {\n push();\n fish.r = random(0,200);\n fish.g = random(0,200);\n fish.b = random(0,200);\n\n if(!fish.eaten) {\n fill(fish.r, fish.g, fish.b);\n noStroke();\n ellipse(fish.x, fish.y, fish.size);\n }\n\n pop();\n}", "display() {\n super.display();\n //Displays rock\n push();\n noStroke();\n fill(this.baseColor.r, this.baseColor.g, this.baseColor.b);\n ellipse(this.x, this.y, this.width,this.height);\n pop();\n }", "reduceHearts() {\n const activeHeart = \"rgb(232, 9, 9)\";\n const lostHeart = \"rgb(232, 232, 232)\";\n if ($(\"#heart1\").css(\"color\") == activeHeart) {\n $(\"#heart1\").css(\"color\", lostHeart);\n }\n else if ( $(\"#heart2\").css(\"color\") == activeHeart) {\n $(\"#heart2\").css(\"color\", lostHeart);\n }\n else if ($(\"#heart3\").css(\"color\") == activeHeart) {\n $(\"#heart3\").css(\"color\", lostHeart);\n gameOver();\n }\n }", "function heartHeartHeart() {\r\n document.body.appendChild(heartsHome);\r\n heartBlock(); \r\n }", "function updateHearts() {\n const lives = document.getElementById('lives');\n lives.innerHTML = '';\n numHearts = maxGuesses - missedGuesses;\n for (i = 0; i < numHearts; i++) {\n lives.insertAdjacentHTML('beforeend', liveHeartTemplate);\n }\n for (i = 0; i < missedGuesses; i++) {\n lives.insertAdjacentHTML('beforeend', lostHeartTemplate);\n }\n}", "function drawHands(){\n\n //draw seconds' hand\n push();\n rotate(secondAngle); \n stroke(255,0,0);\n strokeWeight(6);\n line(0,0,100,0);\n pop();\n\n //draw minutes' hand\n push();\n rotate(minuteAngle);\n stroke(0,255,0);\n strokeWeight(6);\n line(0,0,75,0);\n pop();\n\n //draw hours' hand\n push();\n rotate(hourAngle);\n stroke(0,0,255);\n strokeWeight(6);\n line(0,0,50,0);\n pop();\n}", "function render_heart_rate(heart_rate){\n const target = document.getElementById('heart-rate-text');\n var hr = heart_rate;\n if (target) {\n target.innerHTML = hr;\n if (hr > 120 || hr < 50) {\n get_location();\n };\n };\n}", "function animateHeart(){\n if(stepAnimateHeart == 120){\n stepAnimateHeart--;\n }\n for (let i = 1; i <= numberofHeart; i++) {\n $('#like' + i).width(stepAnimateHeart*0.15); \n }\n if(stepAnimateHeart == 0){\n stepAnimateHeart++;\n }\n stepAnimateHeart++;\n requestAnimationFrame(animateHeart);\n }", "function Hearts(){\n\tvar life = document.createElement('img');\n\tlife.style.position = 'absolute';\n\tlife.height = 50;\n\tlife.width = 100;\n\tlife.style.top = 5 + '%';\n\tlife.style.left = 0 + '%';\n\tlife.src = \"../images/lifes.png\";\n\n\tvar heart0 = document.createElement('img');\n\theart0.id = 'heart0';\n\theart0.style.position = 'absolute';\n\theart0.height = 50;\n\theart0.width = 50;\n\theart0.style.top = 50 + 'px';\n\theart0.style.left = 10 + 'px';\n\theart0.src = \"../images/heart.png\"\n\n\tvar heart1 = document.createElement('img');\n\theart1.id = 'heart1';\n\theart1.style.position = 'absolute';\n\theart1.height = 50;\n\theart1.width = 50;\n\theart1.style.top = 50 + 'px';\n\theart1.style.left = 60 + 'px';\n\theart1.src = \"../images/heart.png\"\n\n\tvar heart2 = document.createElement('img');\n\theart2.id = 'heart2';\n\theart2.style.position = 'absolute';\n\theart2.height = 50;\n\theart2.width = 50;\n\theart2.style.top = 50 + 'px';\n\theart2.style.left = 110 + 'px';\n\theart2.src = \"../images/heart.png\"\n\n\tdocument.getElementById('hearts').appendChild(life);\n\tdocument.getElementById('hearts').appendChild(heart0);\n\tdocument.getElementById('hearts').appendChild(heart1);\n\tdocument.getElementById('hearts').appendChild(heart2);\n\n\t//create the image of the heart and the writing on top left of the screen\n}", "function displayReaction(){\n var name;\n var currentX = horizontalBuffer;\n var currentY = verticalBuffer;\n currentX = currentX + setInitialXCoor(countSubstrates);\n drawSubstrates(currentX, currentY);\n\n currentY = currentY + objectHeight + verticalBuffer * 2; //for version with downwards arrow\n currentX = canvas1.width / 2; //for version with downwards arrow\n name = checkedEnzsNames[0];\n drawDownArrow(currentX, currentY, name);\n\n currentX = horizontalBuffer;\n currentY = verticalBuffer * 5 + objectHeight * 2;\n currentX = currentX + setInitialXCoor(countProducts);\n drawProducts(currentX, currentY);\n}", "function livesCounter(brokenHearts){\n if(brokenHearts === 0){\n //5 hearts on screen\n image(img, imgCoord.x -200, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x -100, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x +100, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x +200, imgCoord.y, imgCoord.size, imgCoord.size2);\n } else if (brokenHearts === 1){\n //4 hearts on screen\n image(img, imgCoord.x -200, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x -100, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x +100, imgCoord.y, imgCoord.size, imgCoord.size2);\n } else if (brokenHearts === 2){\n //3 hearts on screen\n image(img, imgCoord.x -200, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x -100, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x, imgCoord.y, imgCoord.size, imgCoord.size2);\n } else if (brokenHearts === 3){\n //2 hearts on screen\n image(img, imgCoord.x -200, imgCoord.y, imgCoord.size, imgCoord.size2);\n image(img, imgCoord.x -100, imgCoord.y, imgCoord.size, imgCoord.size2);\n } else if (brokenHearts === 4){\n //1 hearts on screen\n image(img, imgCoord.x -200, imgCoord.y, imgCoord.size, imgCoord.size2);\n } else if (brokenHearts === 5){\n //0 hearts on screen, finishes game\n state = 'ending';\n }\n}", "display() {\n // Lerp to proper colors\n if (blackStarfield) {\n this.alpha = 127;\n this.bg = color(0);\n this.color = color(255);\n } else {\n this.alpha = lerp(this.alpha, curLevel.alpha, STARFIELD_LERP);\n this.bg = lerpColor(this.bg, color(curLevel.bg), STARFIELD_LERP);\n this.color = lerpColor(this.color, color(curLevel.color), STARFIELD_LERP);\n }\n\n // Skip rendering stars if low graphics mode\n if (!showStars) return;\n\n // Render stars\n for (let i = 0; i < this.stars.length; i++) {\n let s = this.stars[i];\n\n // Render star\n this.color.setAlpha(this.alpha * noise(s.noise));\n fill(this.color);\n noStroke();\n ellipse(s.x, s.y, s.r, s.r);\n\n // Update position\n if (!paused) {\n s.y += s.dy * dt();\n if (s.y - s.r > height) {\n s.r = random(2);\n s.x = random(width);\n s.y = 0;\n s.dy = random(this.speed);\n }\n }\n\n // Update noise\n s.noise += s.deltaNoise;\n }\n }", "function drawLives() {\n\tfor (var i = 0; i < max_lives; i++) {\n\t\tif (i < lives) {\n\t\t\theart[i].style.visibility=\"visible\";\n\t\t}\n\t\telse {\n\t\t\theart[i].style.visibility=\"hidden\";\n\t\t}\n\t}\n}", "function drawHiker(x, y) {\n fill(backpackColor[i]); // backpack\n rect(x - 10, y + 10, HIKER_WIDTH, HIKER_HEIGHT / 2);\n fill(skinColor[i]); // skin\n rect(x, y, HIKER_WIDTH, HIKER_HEIGHT);\n fill(shirtColor[i]); // shirt\n rect(x, y + 12, HIKER_WIDTH, HIKER_HEIGHT - 15);\n fill(PANT_COLOR); // pants\n rect(x, y + 25, HIKER_WIDTH, HIKER_HEIGHT / 2);\n fill(hairColor[i]); // hair\n rect(x, y - 5, HIKER_WIDTH, HIKER_HEIGHT / 10);\n\n // adds long hair for every other hiker\n if (i % 2 == 1) {\n rect(x, y - 5, 5, 25);\n }\n}", "function addHearts(){\n $(\"#livesLeft\").empty();\n for(i=0;i<lives; i++){\n $(\"#livesLeft\").append('<img src=\"images/heart.png\" class=\"lifesize\">');\n }\n }", "function drawSmileFace() {\n\tdrawHead();\n\tdrawEyes();\n\tdrawSmile();\n}", "function drawLeftStars(num) {\n var str = '';\n for(var i = 0; i < num; i++) {\n str = str + \"*\";\n }\n for(var i = num; i < 75; i++) {\n str += \" \";\n }\n return str;\n}", "render() {\r\n if (this.cardSuit === heart || this.cardSuit === gem) {\r\n faceOfCard.style.color = '#f00a47'; // red\r\n faceOfCard.style.border = '5px solid #f00a47';\r\n } else {\r\n faceOfCard.style.color = '#05ccf0'; // blue\r\n faceOfCard.style.border = '5px solid #05ccf0';\r\n }\r\n\r\n faceOfCard.innerHTML = `\r\n <h1>${this.cardNumber}</h1>\r\n <i class=\"${this.cardSuit}\"></i>\r\n `;\r\n }", "show()\n\t{\n\t\tif(mode == 1)\n\t\t{\n\t\t\tif(score >= 105)\n\t\t\t{\n\t\t\t\tstroke(255);\n\n\t\t\t\tif (score >= 120)\n\t\t\t\t{\n\t\t\t\t\tstrokeWeight(1);\n\n\t\t\t\t\tif(score >= 135)\n\t\t\t\t\t{\n\t\t\t\t\t\tstrokeWeight(0.1);\n\t\t\t\t\t\tif(score >= 150)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tnoStroke();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\telse if(mode == 2)\n\t\t{\n\t\t\tif(score >= 70)\n\t\t\t{\n\t\t\t\tstroke(255);\n\n\t\t\t\tif (score >= 80)\n\t\t\t\t{\n\t\t\t\t\tstrokeWeight(1);\n\n\t\t\t\t\tif(score >= 90)\n\t\t\t\t\t{\n\t\t\t\t\t\tstrokeWeight(0.1);\n\t\t\t\t\t\tif(score >= 100)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tnoStroke();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\tif(score >= 35)\n\t\t\t{\n\t\t\t\tstroke(255);\n\n\t\t\t\tif (score >= 40)\n\t\t\t\t{\n\t\t\t\t\tstrokeWeight(1);\n\n\t\t\t\t\tif(score >= 45)\n\t\t\t\t\t{\n\t\t\t\t\t\tstrokeWeight(0.1);\n\t\t\t\t\t\tif(score >= 50)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tnoStroke();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tfill(this.fadeR, this.fadeG, this.fadeB);\n\t\tellipse(this.x, this.y, this.r * 2);\n\t}", "function createHeart()\n {\n var span = document.createElement('span')\n\n span.style.position = 'absolute'\n span.style.color = '#f52887'\n span.style.opacity = '0'\n Util.addChildren(span, '\\u2665')\n\n document.body.appendChild(span)\n return span\n }", "function showLives(){\n if(livesCounter == 3){\n image(heartLivesImg, 50, 65, 25,25);\n image(heartLivesImg, 80, 65, 25,25);\n image(heartLivesImg, 110, 65, 25,25);\n }\n else if (livesCounter == 2){\n image(heartLivesImg, 50, 65, 25,25);\n image(heartLivesImg, 80, 65, 25,25);\n }\n else if(livesCounter == 1){\n image(heartLivesImg, 50, 65, 25,25);\n }\n else if(livesCounter == 0) {\n image(transparentImg, 50, 65, 25,25);\n }\n}", "function upLeft(pHeight, pColorEven, pColorOdd, pSymbol){\nvar rLine =\"\";\nfor (i=1;i<=pHeight;i++){\nrLine +=\"<p>\";\n\nfor (x=1;x<=pHeight-i;x++) {\n\n rLine +=\"<span class='space'>\" + pSymbol +\"</span>\";\n}\n\nfor(j=x;j<=pHeight;j++){\n\n\nif (j%2) \nrLine +=\"<span style='color:\" + pColorEven + \";'>\" + pSymbol +\"</span>\";\nelse\nrLine +=\"<span style='color:\" + pColorOdd + \";'>\" + pSymbol +\"</span>\";\n\n}\nrLine +=\"</p>\";\n\n}\n\ndocument.getElementById(\"upLeft\").innerHTML = rLine;\n}", "function downLeft(pHeight, pColorEven, pColorOdd, pSymbol){\nvar rLine =\"\";\nfor (i=pHeight;i > 0;i--){\nrLine +=\"<p>\";\n \n for (x=1;x<=pHeight-i;x++) {\n\n rLine +=\"<span class='space'>\" + pSymbol +\"</span>\";\n}\n \nfor(j=0;j<i;j++){\n\nif (j%2) \nrLine +=\"<span style='color:\" + pColorEven + \";'>\" + pSymbol +\"</span>\";\nelse\nrLine +=\"<span style='color:\" + pColorOdd + \";'>\" + pSymbol +\"</span>\";\n\n}\nrLine +=\"</p>\";\n\n}\n\ndocument.getElementById(\"downLeft\").innerHTML = rLine;\n}", "function drawHen() {\n for (let i = 0; i < hens.length; i++) {\n let hen = hens[i];\n let image = currentHenImage;\n\n if (hen.dead) {\n image = 'img/chicken/hen_dead.png';\n }\n\n addBackgroundobject(image, hen.position_x, bg_ground, hen.position_y, hen.scale, 1);\n }\n}", "displayUI()\n {\n var score = document.getElementById(\"score\");\n score.innerHTML = this.score;\n var gameOver = document.getElementById(\"gameover\");\n var health = document.getElementById(\"health\");\n health.style.color = \"#FF0000\";\n health.innerHTML = '<img src=\"/assets/img/full_heart.png\"> </img>'.repeat(this.health);\n health.innerHTML += '<img src=\"/assets/img/empty_heart.png\"> </img>'.repeat(3-this.health);\n if(this.gameOver)\n {\n \n gameOver.innerHTML = \"Game Over. Press (p) to restart\";\n }\n else\n {\n gameOver.innerHTML = \"\";\n }\n\n }", "display() {\n if (this.cards.length) {\n // show the top card and make all cards move towards the position\n // of the deck\n this.cards[0].display(this.pos.x, this.pos.y, true);\n this.cards.forEach(c => c.approach(this.pos));\n } else {\n //show the empty slot\n stroke(0);\n strokeWeight(3);\n fill(255, 255, 255, 100);\n rect(this.pos.x, this.pos.y, CARDWIDTH, CARDHEIGHT);\n }\n }", "function changeHeart() {\r\n var star = document.getElementById('heart');\r\n if (health === 4) {\r\n star.src = \"https://res.cloudinary.com/dytmcam8b/image/upload/v1561725918/virtual%20pet/l1.png\";\r\n }\r\n else if (health === 3) {\r\n star.src = \"https://res.cloudinary.com/dytmcam8b/image/upload/v1561725919/virtual%20pet/l2.png\";\r\n } else if (health === 2) {\r\n star.src = \"https://res.cloudinary.com/dytmcam8b/image/upload/v1561725919/virtual%20pet/l3.png\";\r\n } else if (health === 1) {\r\n star.src = \"https://res.cloudinary.com/dytmcam8b/image/upload/v1561725919/virtual%20pet/l4.png\";\r\n }\r\n }", "function draw(){\n for (var i=0; i<creepWords.length ; i++){\n creepWords[i].creep();\n creepWords[i].display();\n var volume = analyzer.getLevel();\n volume*='.8';\n strokeWeight(volume);\n }\n}", "function printHeart() {\n console.log('<3');\n}", "show(){\n\t\tnoStroke();\n strokeWeight(1);\n //size is correlated to food count\n\t\tfill(this.food,this.food/5,this.food/5);\n\t\tellipse(this.x,this.y,this.food/50);\n\t}", "function downRight(pHeight, pColorEven, pColorOdd, pSymbol){\nvar rLine =\"\";\nfor (i=pHeight;i > 0;i--){\nrLine +=\"<p>\";\n\nfor(j=0;j<i;j++){\n\nif (j%2) \nrLine +=\"<span style='color:\" + pColorEven + \";'>\" + pSymbol +\"</span>\";\nelse\nrLine +=\"<span style='color:\" + pColorOdd + \";'>\" + pSymbol +\"</span>\";\n\n}\nrLine +=\"</p>\";\n\n}\n\ndocument.getElementById(\"downRight\").innerHTML = rLine;\n}", "function renderHS() {\n for (var i = 0; i < highScores.length; i++) {\n var highScore = highScores[i];\n\n var li = document.createElement(\"li\");\n li.textContent = highScore;\n li.setAttribute(\"data-index\", i);\n pEL.appendChild(li);\n }\n }", "function displayFood() {\n push();\n noStroke();\n fill(food.color);\n ellipse(food.x,food.y,food.size);\n pop();\n}", "function drawHands()\n{\n\tclockCtx.save();\n\tclockDate = new Date();\n\tvar radius = clockCWidth/2-15;\n\tvar cSeconds = clockDate.getSeconds();\n\tclockCtx.lineWidth = 3;\n\tdrawHand(cSeconds, radius);\n\tvar cMinutes = clockDate.getMinutes();\n\tradius -= 20;\n\tclockCtx.strokeStyle = \"blue\";\n\tdrawHand(cMinutes, radius);\n\tvar cHours = clockDate.getHours();\n\tradius -= 10;\n\tclockCtx.strokeStyle = \"red\";\n\tdrawHand(cHours*5, radius);\n\tclockCtx.restore();\n}", "function dispStars() {\n let starsOnPage = generateStars();\n document.querySelector('.stars').innerHTML = starsOnPage;\n}", "function showHighScores() {\n display.set(\"highScores\").show();\n }", "function drawDisplay() {\n\n let heart = objectImages.display[0];\n let bottle = objectImages.display[1];\n\n addObject(heart, 10, 0, 0.5);\n\n ctx.fillStyle = \"white\"\n ctx.globalAlpha = 0.5;\n ctx.fillRect(310, 32, 78, 30);\n ctx.globalAlpha = 1;\n\n ctx.font = \"28px sans-serif\";\n ctx.fillStyle = \"brown\";\n ctx.fillText(\"x \" + collectedBottles, 330, 58);\n\n addObject(bottle, 280, 15, 0.4);\n}", "function Toss() {\r\n if (Math.random() < 0.5) {\r\n traces.push(\"H\");\r\n } else {\r\n traces.push(\"T\");\r\n }\r\n }", "function printStars (risultati) {\n var filmVote = Math.ceil(parseInt(risultati.vote_average) / 2);\n var star = '';\n for (var i = 0; i < 5; i++) {\n if (i < filmVote) {\n star += '&#9733;';\n } else if (i >= filmVote && i < 5) {\n star += '&#9734;';\n }\n }\n return star;\n}", "function displayLives(numLives) {\n var lives = $(\"#livesHearts\")\n lives.empty()\n var lifeElement = \"<i class='material-icons'>favorite</i>\"\n for (var i = 0; i < numLives; i++) {\n lives.append($(lifeElement))\n }\n }", "function drawHeart(){ \n //draws a light white background behind the heart\n ctx.save();\n ctx.translate(canvas.width/2, canvas.height/2);\n ctx.fillStyle=\"rgba(255,255,255,.5)\";\n ctx.strokeStyle=\"rgba(255,255,255,1)\";\n \n ctx.lineWidth=5;\n ctx.beginPath();\n ctx.arc(0,0,180,0,2*Math.PI);\n ctx.shadowBlur=15;\n ctx.shadowColor=\"white\";\n \n if(invert){\n ctx.shadowColor=\"grey\";\n }\n \n ctx.stroke();\n ctx.fill();\n ctx.restore();\n \n //heart curves\n ctx.save();\n ctx.translate(canvas.width/2, canvas.height/2);\n ctx.fillStyle=\"#BE1E73\";\n ctx.strokeStyle= \"pink\";\n ctx.lineWidth= 3;\n ctx.beginPath();\n ctx.moveTo(0,-15);\n ctx.bezierCurveTo( 0,-45, -50,-45, -50, -15);\n ctx.bezierCurveTo( -50,15, 0,20, 0, 45 );\n ctx.bezierCurveTo( 0,20, 50,15, 50, -15 ); \n ctx.bezierCurveTo( 50,-45, 0,-45, 0, -15);\n ctx.closePath();\n ctx.fill();\n ctx.shadowBlur=8;\n ctx.shadowColor=\"white\";\n \n if(invert){\n ctx.shadowColor=\"grey\";\n }\n ctx.stroke();\n ctx.restore();\n }", "function drawAlternatingHens() {\n\n for (let i = 0; i < alternatingHens.length; i++) {\n let hen = alternatingHens[i];\n let image = hen.currentAlternatingHenImage;\n\n if (hen.dead) {\n if (hen.henIsFacingLeft) {\n image = 'img/chicken/hen_dead.png';\n }\n if (hen.henIsFacingRight) {\n image = 'img/chicken/hen_deadR.png';\n }\n\n }\n addBackgroundobject(image, hen.position_x, bg_ground, hen.position_y, hen.scale, 1);\n }\n}", "function renderHealth() {\n let playerHealth = document.getElementById(\"playerHealth\")\n let enemyHealth = document.getElementById(\"enemyHealth\")\n let buckName = document.getElementById(\"buckName\")\n let enemyName = document.getElementById(\"enemyName\")\n // Remove all playerHearts\n while (playerHealth.firstChild) {\n playerHealth.removeChild(playerHealth.lastChild);\n }\n // Render PlayerHearts\n for (let i = 0; i < playerHearts; i++) {\n let img = document.createElement(\"img\")\n img.src = \"assets/heart.png\"\n playerHealth.appendChild(img)\n\n // Render \"Buck's Health:\" text\n buckName.innerHTML = \"Buck's Health\"\n }\n // Remove all enemyHearts\n while (enemyHealth.firstChild) {\n enemyHealth.removeChild(enemyHealth.lastChild);\n }\n // Render enemyHearts\n for (let i = 0; i < enemyHearts; i++) {\n let img = document.createElement(\"img\")\n img.src = \"assets/heart.png\"\n enemyHealth.appendChild(img)\n\n // Render \"Enemies Health:\" text\n enemyName.innerHTML = \"Enemies Health\"\n }\n}", "function clearHearts() {\r\n document.querySelector(\"#heartsHome\").remove();\r\n }", "function upRight(pHeight, pColorEven, pColorOdd, pSymbol){\nvar rLine =\"\";\nfor (i=0;i<pHeight;i++){\nrLine +=\"<p>\";\n\nfor(j=0;j<=i;j++){\n\n\nif (j%2) \nrLine +=\"<span style='color:\" + pColorEven + \";'>\" + pSymbol +\"</span>\";\nelse\nrLine +=\"<span style='color:\" + pColorOdd + \";'>\" + pSymbol +\"</span>\";\n\n}\nrLine +=\"</p>\";\n\n}\n\ndocument.getElementById(\"upRight\").innerHTML = rLine;\n}", "function displayFood() {\n push();\n noStroke();\n fill(food.color);\n ellipse(food.x,food.y,food.size);\n stroke(0);\n noFill();\n rect(food.x-25,food.y-10,food.size/3, food.size/5,1);\n rect(food.x+5,food.y-10,food.size/3, food.size/5,1);\n line(food.x-5,food.y-5,food.x+5,food.y-5);\n line(food.x-15,food.y-15,food.x-5,food.y-10);\n line(food.x+5,food.y-10,food.x+15,food.y-15);\n arc(food.x,food.y+20,food.size/5,food.size/5,PI,TWO_PI);\n pop();\n}", "function showHighscores() {\n statsEl.style.display = \"none\";\n highscoresEl.style.display = \"flex\";\n for (let i = 0; i < highscores.length; i++) {\n let entry = document.createElement(\"span\");\n entry.textContent = (i + 1) + \". \" + highscores[i];\n highscoresBox.appendChild(entry);\n }\n}", "function dealerHandSprite() {\n textSize(28);\n textAlign(RIGHT);\n fill(255);\n text(\"Dealer's hand\", width/2+360, 55);\n for (var i = 0; i ( dealerHand; i++) {\n dealerCardSprite(dealerHand, dealerHand[i], 150);\n }\n}", "function draw() {\n //----- BACKGROUND SETUP -----\n background(bg.r, bg.g, bg.b);\n\n //----- STATE SETUP -----\n if(state === 'title'){\n titleScreen();\n }\n else if (state === 'gameplay'){\n gameplay();\n }\n else if (state === 'ending'){\n //----- NUM OF LIVES CHECK -----\n if(brokenHearts <= 2){\n ending(brokenHearts, 255, 115, 171);\n } else if (brokenHearts === 3 || brokenHearts === 4){\n ending(brokenHearts, 155, 100, 120);\n } else if (brokenHearts === 5){\n ending(brokenHearts, 70, 50, 60);\n }\n }\n}", "function drawHeart(context, elem, xp, yp, wp, hp){\n let width = pc(wp, elem.width); \n let height = pc(hp, elem.height); \n let y = pc(yp, elem.height); \n let x = pc(xp, elem.width); \n let topCurveHeight = height * 0.3;\n context.moveTo(x, y + topCurveHeight);\n context.bezierCurveTo(x, y,x - width / 2, y,x - width / 2, y + topCurveHeight);\n context.bezierCurveTo(x - width / 2, y + (height + topCurveHeight) / 2, x, y + (height + topCurveHeight) / 2,x, y + height);\n context.bezierCurveTo(x, y + (height + topCurveHeight) / 2, x + width / 2, y + (height + topCurveHeight) / 2, x + width / 2, y + topCurveHeight);\n context.bezierCurveTo(x + width / 2, y, x, y,x, y + topCurveHeight);\n context.closePath();\n}", "function lifeLine() {\n let rightMargin = 30;\n for (let i = lives; i > 0; i--) {\n ctx.font = \"30px Arial\";\n ctx.fillStyle = \"red\";\n ctx.fillText(\"♥\", canvas.width - rightMargin, canvas.height - 30);\n rightMargin = rightMargin + 30;\n }\n }", "function displayScores() {\n // Current score, large and in the center\n push();\n fill(random(200, 255));\n textSize(800);\n textAlign(CENTER, CENTER);\n text(score, width / 2, height / 2);\n pop();\n\n // High score in the top left\n push();\n fill(random(200, 255));\n textSize(64);\n textAlign(LEFT, TOP);\n text(`High score: ${highScore}`, 0, 0);\n pop();\n}", "function visual() {\n\n //first new beat, draw hexagons\n if (song.currentTime() > 14) {\n for (i = 100; i < windowWidth; i += 100) {\n for (j = -100; j < windowHeight; j += 100) {\n stroke(255);\n strokeWeight(0.4);\n fill(0);\n polygon(i, j, volume * 0.5, 6);\n }\n }\n }\n\n //second new beat, draw gray ellipses\n if (song.currentTime() > 28) {\n for (t = 50; t < windowWidth; t += 100) {\n for (z = -100; z < windowHeight; z += 100) {\n stroke(0);\n strokeWeight(0.4);\n fill(120);\n ellipse(t, z, volume * 0.2);\n }\n }\n }\n\n //third new beat, draw squares\n if (song.currentTime() > 36) {\n for (h = -100; h < windowWidth + 100; h += 100) {\n for (l = 150; l < windowHeight + 200; l += 200) {\n stroke(\"#b0f11d\");\n strokeWeight(0.5);\n fill(0);\n polygon(h, l, volume * 0.1, 4);\n }\n }\n }\n\n //fourth new beat, draw ellipses\n if (song.currentTime() > 68) {\n for (g = 50; g < windowWidth; g += 100) {\n for (r = 50; r < windowHeight; r += 200) {\n stroke(\"#b0f11d\");\n strokeWeight(0.4);\n fill(0);\n ellipse(g, r, volume * 0.2);\n }\n }\n }\n\n//once the song reaches a certain point, it stops and the whole animation gets refreshed\n if (song.currentTime() > 75) {\n song.stop();\n reset();\n }\n}", "function display20Flips() {\n for (i = 0; i < 20; i++) {\n coin.flip()\n let tossStr = coin.toString()\n document.body.append(tossStr + \" \")\n //document.body.append(imgTails)\n }\n}", "_draw_scores () {\n\n\t\tvar cw = this._deck_blue ['musician'].w\n\t\tvar ch = this._deck_blue ['musician'].h\n\t\tvar colors = [\"rgba(200, 0, 0, 0.6)\", \"rgba(0, 0, 200, 0.6)\"]\n\n\t\tvar font_height = ch/3\n\t\tcanvas.style.font = this.context.font;\n\t\tcanvas.style.fontSize = `${font_height}px`;\n\t\tthis.context.font = canvas.style.font;\n\t\tthis.context.textAlign = \"center\";\n\t\tthis.context.textBaseline = \"middle\"; \n\n\t\tfor (let i = 0; i < this._scores.length; i +=1) {\n\n\t\t\tvar [x0, y0] = this.get_slot_coo (i, 0)\n\t\t\tvar [x1, y1] = this.get_slot_coo (i, 1)\n\t\t\tif (this._scores [i] > 0) {\n\t\t\t\t\n\t\t\t\tthis.context.fillStyle = colors [this._swap_color]\n\t\t\t\tthis.context.fillRect (x0 - cw/2, y0-cw/4, cw, cw/2);\n\t\t\t\tthis.context.fillStyle = \"white\";\n\t\t\t\tthis.context.fillText (`+${this._scores [i]}`, x0, y0); \t\n\n\t\t\t\tthis.context.fillStyle = \"rgba(0, 0, 0, 0.4)\"\n\t\t\t\tthis.context.fillRect (x1 - cw/2, y1-ch/2, cw, ch);\n\t\t\t}\n\t\t\tif (this._scores [i] < 0) {\n\t\t\t\t\n\t\t\t\tthis.context.fillStyle = colors [1 - this._swap_color]\n\t\t\t\tthis.context.fillRect (x1 - cw/2, y1-cw/4, cw, cw/2);\n\t\t\t\tthis.context.fillStyle = \"white\";\n\t\t\t\tthis.context.fillText (`+${-this._scores [i]}`, x1, y1); \t\n\n\t\t\t\tthis.context.fillStyle = \"rgba(0, 0, 0, 0.4)\"\n\t\t\t\tthis.context.fillRect (x0 - cw/2, y0-ch/2, cw, ch);\n\t\t\t}\n\t\t}\n\t}", "function dealerHandSprite() {\n textSize(28);\n textAlign(RIGHT);\n fill(255);\n text(\"Dealer's hand\", width/2+360, 55);\n for (var i = 0; i ( dealerHand.length; i++) {\n dealerCardSprite(dealerHand, dealerHand[i], 150);\n }\n}", "function drawStars() {\n translate(width / 2, height / 2);\n for (var i = 0; i < stars.length; i++) {\n stars[i].update();\n stars[i].show();\n }\n}", "function drawChest() {\n ctx.drawImage(treasureChest, treasurex-13, treasurey-13);\n}", "function showRH(i, id){\n rh = `\n ${currentData[i].rh} % de humedad\n `\n document.getElementById(id).innerHTML = rh;\n}", "function EatsCheese(isRandomCheese) {\n\n if (isRandomCheese) {\n eatenRandomCheese++;\n }\n else {\n eatenCheese++;\n }\n \n RatHappyAudio();\n\n var points = document.getElementById(\"spanScore\");\n var currentPoints = (eatenCheese * 1000) + (eatenRandomCheese * 2500);\n\n if (currentPoints < 10000) {\n points.innerHTML = \"0\" + currentPoints.toString();\n }\n else {\n points.innerHTML = currentPoints.toString();\n }\n}", "function herAbout() { //\"Musician\"\n for (var k = 0; k < data.results.length; k++) {\n var showherAbout = data.results[k].about;\n textSize(12);\n fill(255);\n text(showherAbout, random(0, 400), random(0, 400));\n\n }\n}", "function displayScore(){\n push();\n textFont(`Blenny`);\n fill(tileWhite.fill.r, tileWhite.fill.g, tileWhite.fill.b); // Same white as white tiles\n textSize(40);\n text(`${score} points`, 1050, 150);\n pop();\n}", "function drawChest() {\n L10_Canvas.crc2.fillStyle = \"#7d4700\";\n L10_Canvas.crc2.beginPath();\n L10_Canvas.crc2.rect(330, 570, 110, 60);\n L10_Canvas.crc2.fill();\n L10_Canvas.crc2.stroke();\n L10_Canvas.crc2.beginPath();\n L10_Canvas.crc2.moveTo(330, 590);\n L10_Canvas.crc2.lineTo(440, 590);\n L10_Canvas.crc2.stroke();\n }", "function paintFavouriteSeries() {\r\n let htmlCode = \"\";\r\n htmlCode += `<button class=\"card__list--button-reset js-reset\">Borrar todo</button>`;\r\n for (const favourite of arrayFavourites) {\r\n htmlCode += `<li class=\"section-favourites__cards\">`;\r\n htmlCode += `<div class=\"section-favourites__cards--item\" id=\"${favourite.id}\">`;\r\n htmlCode += `<h4 \"section-favourites__cards--title\">${favourite.name}</h4>`;\r\n htmlCode += `<img class=\"section-favourites__cards--img\"\r\n src=\"${favourite.image}\"\r\n title=\"${favourite.name}\"\r\n alt=\"${favourite.name}\"/>`;\r\n htmlCode += `<i class=\"section-favourites__cards--button js-remove gg-trash\" id=\"${favourite.id}\"></i>`;\r\n }\r\n htmlCode += `</div>`;\r\n htmlCode += `</li>`;\r\n favouritesElement.innerHTML = htmlCode;\r\n setInLocalStorage();\r\n listenSeriesEvents();\r\n listenFavouritesEvents();\r\n}", "function drawHealth() {\n push()\n fill(healthColor, 255, 100);\n noStroke();\n textSize(22);\n textAlign(RIGHT);\n text(\"HEALTH-->\", width / 1.1, height - 20)\n rect(width - 50, height, width - 50, -playerHealth);\n //if the players health is gettin glow, turn the recangle red, and play a ticking clock sound\n if (playerHealth < playerMaxHealth / 3) {\n healthColor = 0;\n tickTock.play();\n } else {\n healthColor = 120;\n tickTock.stop();\n }\n pop();\n}", "function createHeart(color) {\r\n const heart = document.createElement(\"div\");\r\n heart.className = \"heart\";\r\n heartsHome.appendChild(heart);\r\n heart.style.backgroundColor = color;\r\n }", "function PresentScoring() {\n basic.clearScreen()\n // plot minumum target (depending on current level)\n for (let r = 0; r <= level * 5 - 1; r++) {\n led.plotBrightness(r % 5, 4 - r / 5, 10)\n }\n basic.pause(250)\n for (let t = 0; t <= Math.min(24, 29 - score); t++) {\n led.plot(t % 5, 4 - t / 5)\n if (!(quiet)) {\n music.playTone(175 + t * 5, music.beat(BeatFraction.Sixteenth))\n } else {\n basic.pause(music.beat(BeatFraction.Sixteenth))\n }\n basic.pause(200 - 8 * t)\n }\n basic.pause(250)\n // Check if got top Scores\n if (score < 6) {\n for (let i0 = 0; i0 < 3; i0++) {\n basic.clearScreen()\n led.plot(1, 1)\n led.plot(3, 1)\n led.plot(1, 4)\n led.plot(2, 4)\n led.plot(3, 4)\n led.plot(0, 3)\n led.plot(4, 3)\n if (!(quiet)) {\n music.playTone(587, music.beat(BeatFraction.Whole))\n } else {\n basic.pause(music.beat(BeatFraction.Whole))\n }\n basic.pause(250)\n //basic.clearScreen()\n led.plotAll()\n //ToggleScreen()\n basic.pause(250)\n //ToggleScreen()\n\n }\n screen += 1\n }\n else {\n if (30 - score >= 5 * (level)) {\n if (!(quiet)) {\n music.playTone(587, music.beat(BeatFraction.Whole))\n } else {\n basic.pause(music.beat(BeatFraction.Whole))\n }\n screen += 1\n basic.pause(1000)\n }\n else {\n // \n basic.clearScreen()\n ShowSadFace()\n basic.pause(1000)\n }\n basic.pause(30)\n }\n\n basic.pause(1000)\n}", "function renderHealth() {\n var heart = new Image();\n heart.src = 'images\\\\heart.png'\n\n htx.clearRect(0, 0, htx.canvas.width, htx.canvas.height);\n if (player.health === 1) {\n htx.drawImage(heart, 0, 0);\n } else if (player.health === 2) {\n htx.drawImage(heart, 0, 0);\n htx.drawImage(heart, 30, 0);\n } else if (player.health === 3) {\n htx.drawImage(heart, 0, 0);\n htx.drawImage(heart, 30, 0);\n htx.drawImage(heart, 60, 0);\n } else if (player.health === 4) {\n htx.drawImage(heart, 0, 0);\n htx.drawImage(heart, 30, 0);\n htx.drawImage(heart, 60, 0);\n htx.drawImage(heart, 90, 0);\n } else if (player.health === 5) {\n htx.drawImage(heart, 0, 0);\n htx.drawImage(heart, 30, 0);\n htx.drawImage(heart, 60, 0);\n htx.drawImage(heart, 90, 0);\n htx.drawImage(heart, 120, 0);\n }\n}", "function draw() {\n\t//Redraw Background Color (Necessary?)\n\tbackground(0);\n\n\tfor (let i = 0; i < fishes.length; i++){ \n\t\t// If there is food on the screen, apply attractive force and display food\n\t\tif (food) {\n\t\t\tlet f = food.calculateAttraction(fishes[i]); \n\t\t\tfishes[i].applyForce(f); \n\t\t\tfood.display(); \n\t\t} else {\n\t\t\tfishes[i].meander();\n\t\t}\n\n\t\t// Update the properties of the fish (acceleration, velocity, location) etc\n\t\t// And display the fish\n\t\tfishes[i].update(); \n\t\tfishes[i].checkEdges();\n\t\tfishes[i].display();\n\t}\n\n\t// Text for slider\t\n\tfill(255);\n\ttextSize(16);\n\ttext('Food Size', 20, 120);\n\tfill(255);\n}", "function drawShedInfo(item, index) {\n var xoffset;\n var pattern014 = [0, 1, 4];\n var pattern0124 = [0, 1, 2, 4];\n var pattern0134 = [0, 1, 3, 4];\n use_plyr_bg_color();\n xoffset = index * 100;\n ctx.moveTo(xoffset, 0);\n ctx.lineTo(xoffset, 100);\n ctx.stroke();\n ctx.font = \"30px Arial\";\n ctx.textAlign = \"center\";\n ctx.fillText(item[0], xoffset + 48, 30);\n ctx.font = \"40px Arial\";\n ctx.textAlign = \"left\";\n ctx.fillText(item[1], xoffset + 10, 90);\n ctx.fillStyle = OLIVE_GREEN;\n ctx.strokeStyle = OLIVE_GREEN;\n ctx.beginPath();\n ctx.moveTo(xoffset + 48, 62);\n ctx.lineTo(xoffset + 72, 50);\n ctx.lineTo(xoffset + 96, 62);\n ctx.lineTo(xoffset + 96, 86);\n ctx.lineTo(xoffset + 72, 98);\n ctx.lineTo(xoffset + 48, 86);\n ctx.closePath();\n ctx.stroke();\n ctx.fill();\n ctx.fillStyle = WHITE;\n ctx.strokeStyle = WHITE;\n ctx.font = \"20px Arial\";\n ctx.textAlign = \"center\";\n ctx.fillText(item[2], xoffset + 72, 80);\n drawTriangle(ctx, xoffset, [48, 53, 53], [74, 71, 77]);\n if (pattern0124.indexOf(index) !== -1) {\n drawTriangle(ctx, xoffset, [96, 91, 91], [74, 71, 77]);\n }\n if (pattern014.indexOf(index) !== -1) {\n drawTriangle(ctx, xoffset, [60, 60, 65], [56, 62, 59]);\n }\n if (pattern0134.indexOf(index) !== -1) {\n drawTriangle(ctx, xoffset, [84, 84, 79], [56, 62, 59]);\n }\n if (pattern014.indexOf(index) !== -1) {\n drawTriangle(ctx, xoffset, [60, 60, 65], [90, 84, 87]);\n }\n if (pattern0134.indexOf(index) !== -1) {\n drawTriangle(ctx, xoffset, [84, 84, 79], [90, 84, 87]);\n }\n ctx.beginPath();\n }", "function showHighscore() {\n\tmenuHideAll();\n\t$('#highscore').show();\n\tmenuResetColors();\n\tmenuSetColor('highscoreBox');\n\tloadMenuHighscore();\n}", "function heartDiamond(){\n let hrtX = bgLeft + 7000;\n imageMode(CENTER);\n image(heartImg, hrtX, heartD.y,heartD.size, heartD.size);\n hrtTouch(hrtX);\n}", "function showStars(num) {\n const starHtml = '<li class=\"fa fa-star\"></li>';\n stars.innerHTML = \"\";\n for (let i = 0; i < num; i++) {\n stars.innerHTML += starHtml;\n }\n }", "function hp() {\n return (ctx.lineWidth / 2) % 1;\n}", "function catchHeart(){\n for (let k = 1; k <= numberofHeart; k++) {\n setInterval(function(){\n if(j == (parseFloat($('#like'+k).css('left'))-790)/30 && i == (parseFloat($('#like'+k).css('top')) - 413)/30){\n life++;\n randomHeartPosition();\n }\n },5) \n }\n }", "function drawTinyFireflies() {\n let segmentDrawn = 0;\n // The number of flies will loop until numFlies\n // They are going to be placed at random places\n // to give illusion of movement\n while (segmentDrawn < numFlies) {\n fireflyX = random(0, width);\n fireflyY = random(0, height);\n // Strake and stroke weight of the tiny fireflies\n stroke(255, 254, 166, preyHealth);\n strokeWeight(15)\n // Position and Size\n ellipse(fireflyX, fireflyY, fireflySize)\n // Segments are being drawn\n segmentDrawn++\n }\n}", "function renderHealth () {\n OasisCanvasContext.fillStyle = 'black';\n OasisCanvasContext.font = \"30px Arial\";\n OasisCanvasContext.fillText(\n '' + OasisPlayer.health + ' / 100',\n 50,\n 50\n );\n}", "function InventoryItemMouthFuturisticHarnessPanelGagDraw() {\n\tInventoryItemMouthFuturisticPanelGagDraw();\n}", "function displayScore() {\n //Display current score\n push();\n fill(255);\n textSize(500);\n textAlign(CENTER, CENTER);\n text(currentScore, width / 2, height / 2);\n pop();\n //Display high score\n push();\n fill(255);\n textSize(30);\n textAlign(CENTER, CENTER);\n text(`High score: ${bubbleData.highScore}`, width / 2, height / 2 + 200);\n pop();\n}", "display() {\n\t\tvar alpha = 255;\n\t\tif (this.hover()) {\n\t\t\talpha = 150;\n\t\t} else {\n\t\t\talpha = 255;\n\t\t}\n\t\t// stroke(255);\n\t\t// for (var i = 1; i < interval - 1; i++) {\n\t\t// \tline(0,0, width, 0);\n\t\t// }\n\t\tnoStroke();\n\t\tfill(this.col, alpha);\n\t\tellipseMode(CENTER);\n\t\tellipse(this.x, this.y, this.size, this.size);\n\t\tfill(150, alpha);\n\t\trectMode(CENTER);\n\t\trect(this.x, this.y, this.size/4, this.size/4);\n\t}", "function draw() {\n background(46,139,87);\n \n if(keyWentDown(UP_ARROW)){\n writeStock(foodS);\n dog.addImage(img2);\n }\n fill(255,255,254);\n textSize(15);\n if(lastFed>+12){\n text(\"Last Feed : \"+lastFed%12 +\"PM\".350,350);\n }else if(lastFed==0){\n text(\"last feed : 12 AM\",350,30);\n }else{\n text(\"last feed : \"+lastFed + \"AM\",350)\n }\n }", "function showHighScoreContent() {\n if (highscoreData.highscores == undefined) {\n p5HTMLElements.push(createP('No Highscores to view here'));\n p5HTMLElements[p5HTMLElements.length - 1].position(view.options.x2 / 2 + 50, view.options.y + 100);\n return;\n }\n highscoreData.highscores.reverse();\n var tableContent = '<tr><th>Name</th><th>Score</th></tr>';\n for (var i = 0; i < highscoreData.highscores.length; i++) {\n tableContent += '<tr><td>' + highscoreData.highscores[i].name + '</td><td>' + highscoreData.highscores[i].score + '</td></tr>';\n }\n highscoreData.highscores.reverse();\n p5HTMLElements.push(createElement('table', tableContent));\n var highscoresTable = p5HTMLElements[p5HTMLElements.length - 1];\n highscoresTable.position(view.options.x + 10, view.options.y + 50);\n highscoresTable.size(view.options.x2 - 20, highscoresTable.size().height);\n}", "function showStars() {\n let count;\n if (moveCount < 16) {\n count = 3;\n score = 60;\n } else if (moveCount < 32) {\n count = 2;\n score = 40;\n } else {\n count = 1;\n score = 10;\n }\n for (let i = 0; i < (stars.length - count); i++) {\n stars[i].setAttribute('style', 'display: none');\n }\n}", "renderRook(piece, key) {\n\t\tconsole.log(\"Shub implement this\");\n\t\tif (piece.player === \"black\") {\n\t\t\t// Note: The Style property is CSS code - this allows an outline to be shown on the piece\n\t\t\treturn (\n\t\t\t\t<FontAwesomeIcon\n\t\t\t\t\ticon={piece.icon}\n\t\t\t\t\tcolor={piece.player}\n\t\t\t\t\tsize=\"1x\"\n\t\t\t\t\tkey={key}\n\t\t\t\t\tstyle={{ stroke: \"white\", strokeWidth: 15 }}\n\t\t\t\t/>\n\t\t\t);\n\t\t} else if (piece.player === \"white\") {\n\t\t\t// Note: The Style property is CSS code - this allows an outline to be shown on the piece\n\t\t\treturn (\n\t\t\t\t<FontAwesomeIcon\n\t\t\t\t\ticon={piece.icon}\n\t\t\t\t\tcolor={piece.player}\n\t\t\t\t\tsize=\"1x\"\n\t\t\t\t\tkey={key}\n\t\t\t\t\tstyle={{ stroke: \"black\", strokeWidth: 15 }}\n\t\t\t\t/>\n\t\t\t);\n\t\t}\n\t}", "function heartLine(k) {\r\n var k;\r\n for (i = 0; i< 10; i++) {\r\n i = i + k;\r\n var color\r\n switch (i%5) {\r\n case 0:\r\n color = \"#9b5de5\"; // Amethyst\r\n break;\r\n case 1:\r\n color = \"#f15bb5\"; // Magenta Crayola\r\n break;\r\n case 2:\r\n color = \"#fee440\"; // Minion Yellow\r\n break;\r\n case 3:\r\n color = \"#00bbf9\"; // Capri\r\n break;\r\n case 4:\r\n color = \"#00f5d4\"; // Sea Green Crayola\r\n break;\r\n \r\n default:\r\n break;\r\n }\r\n i = i - k;\r\n setTimeout(createHeart,500*i, color);\r\n\r\n }\r\n\r\n }", "function displayChord () {\n const { notes, frets } = getNoteFretPairs();\n const { minFret, chordLength } = getFretRange(frets);\n\n // Initializes the diagram\n const c = document.getElementById('fretboard');\n c.height = chordLength * 60 + 160;\n c.width = 300;\n const brush = c.getContext('2d');\n\n // Sets the fill color to be brown\n brush.fillStyle = '#670A0A';\n brush.clearRect(0, 0, c.width, c.height);\n brush.fillRect(51, 51, 199, c.height - 101);\n\n drawFretboardMarkers(brush, minFret, chordLength);\n drawFrets(brush, c.height);\n drawStrings(brush, c.height);\n drawNut(brush);\n drawNotes(brush, frets, notes, minFret);\n labelMinFret(brush, minFret);\n }", "show() {\n // Fill Red\n fill(255, 0, 0);\n // draw a rectangle to show food\n rect(this.pos.x, this.pos.y, scl, scl);\n }", "resetHearts() {\r\n const lostHearts = document.querySelectorAll('[alt=\"Lost Heart Icon\"]');\r\n lostHearts.forEach(heart => {\r\n heart.setAttribute('alt', 'Heart Icon');\r\n heart.setAttribute('src', 'images/liveHeart.png');\r\n });\r\n }", "function playerHandSprite() {\n textSize(32);\n textAlign(LEFT);\n fill(255);\n text(\"Your sum: \" + playerSum, width/2-360, 300);\n for (var i = 0; i ( playerHand; i++) {\n userCardSprite(playerHand, playerHand[i], 400);\n }\n}", "function displaySong() {\n let content = `${songs[currentSong].decade}'s: ${\n songs[currentSong].song\n } // ${songs[currentSong].artist}`;\n nowPlayingText.innerHTML = content;\n }", "function displayIntroTitle(){\n push();\n textFont(`Blenny`);\n textAlign(CENTER,CENTER);\n textSize(140);\n fill(breadFill.r, breadFill.g, breadFill.b);\n text(`get this bread`, width/2, height/2);\n pop();\n push();\n textFont(`Blenny`);\n textAlign(CENTER,CENTER);\n textSize(40);\n fill(255);\n text(`press anywhere to continue`, width/2, height/1.5);\n pop();\n}", "updateUI() {\n this.scoreText.setText(`Score ${this.bumperPoint}`);\n\n const emojis = [];\n for (let i = 0; i < this.healthPoint; i++) {\n emojis.push('❤');\n }\n let healthHearts = emojis.join().replace(/\\,/g, ' ');\n this.healthText.setText(`Health ${healthHearts}`);\n }", "function paintSeries() {\r\n let htmlCode = \"\";\r\n for (const serie of series) {\r\n htmlCode += `<li class=\"card__list\">`;\r\n htmlCode += `<div class=\"card__list--item js-card\" id=\"${serie.id}\">`;\r\n htmlCode += `<h4>${serie.name}</h4>`;\r\n htmlCode += `<img class=\"card__list--img\"\r\n src=\"${serie.image}\"\r\n title=\"${serie.name}\"\r\n alt=\"${serie.name}\"/>`;\r\n }\r\n htmlCode += `</div>`;\r\n htmlCode += `</li>`;\r\n cardsElement.innerHTML = htmlCode;\r\n listenSeriesEvents();\r\n}", "function drawPlayerHands(gameContainer) {\r\n for (var i = 0; i < players.length; i++) {\r\n var playerNum = i+1;\r\n var player = players[i];\r\n var text = new PIXI.Text(\"Player \" + playerNum + \" - \" + player.role, {font:\"20px Arial\", fill:\"black\"});\r\n var roleColorSquare = new PIXI.Graphics();\r\n roleColorSquare.beginFill(roleColors[player.role]);\r\n\r\n //roleColorSquare.lineStyle(1, 0x000000);\r\n roleColorSquare.drawRect(0, 0, 20, 20);\r\n //treasureSquare.hitArea = treasureSquare.getBounds();\r\n var background = new PIXI.Graphics();\r\n background.beginFill(0xc8c8c8);\r\n background.drawRect(0, 0, 400, 65);\r\n background.interactive = true;\r\n background.hitArea = background.getBounds();\r\n\r\n // player 1\r\n if (i == 0) {\r\n text.position.x = 5;\r\n text.position.y = height - text.height - 70;\r\n roleColorSquare.position.x = text.position.x + text.width + 5;\r\n roleColorSquare.position.y = text.position.y;\r\n player.hand.position.x = 5;\r\n player.hand.position.y = (height-65);\r\n }\r\n // player 2\r\n else if (i == 1) {\r\n text.position.x = width - text.width - 5;\r\n text.position.y = height - text.height - 70;\r\n roleColorSquare.position.x = text.position.x - roleColorSquare.width - 5;\r\n roleColorSquare.position.y = text.position.y;\r\n player.hand.position.x = width - 385;\r\n player.hand.position.y = (height-65);\r\n }\r\n // player 3\r\n else if (i == 2) {\r\n text.position.x = 5;\r\n text.position.y = 70;\r\n roleColorSquare.position.x = text.position.x + text.width + 5;\r\n roleColorSquare.position.y = text.position.y;\r\n player.hand.position.x = 5;\r\n player.hand.position.y = 5;\r\n }\r\n // player 4\r\n else if (i == 3) {\r\n text.position.x = width - text.width - 5;\r\n text.position.y = 70;\r\n roleColorSquare.position.x = text.position.x - roleColorSquare.width - 5;\r\n roleColorSquare.position.y = text.position.y;\r\n player.hand.position.x = width - 385;\r\n player.hand.position.y = 5;\r\n }\r\n background.position.x = player.hand.position.x;\r\n background.position.y = player.hand.position.y;\r\n gameContainer.addChild(text);\r\n gameContainer.addChild(roleColorSquare);\r\n gameContainer.addChild(background);\r\n gameContainer.addChild(player.hand);\r\n\r\n }\r\n}" ]
[ "0.68376845", "0.6826211", "0.67068046", "0.63591355", "0.63379914", "0.6292296", "0.628281", "0.6262421", "0.61563504", "0.60988206", "0.60862625", "0.6055171", "0.60303503", "0.602348", "0.601556", "0.5917671", "0.5907442", "0.5907421", "0.5824928", "0.5818143", "0.5815627", "0.5801446", "0.57784384", "0.575231", "0.5740446", "0.57333845", "0.57273036", "0.5721684", "0.5694444", "0.56823003", "0.5678082", "0.5664382", "0.56424", "0.5640636", "0.56317115", "0.56274545", "0.56199396", "0.56160164", "0.56147134", "0.56140774", "0.5609478", "0.560304", "0.5602961", "0.55993575", "0.5594372", "0.55898035", "0.5585737", "0.55844814", "0.5579021", "0.5569398", "0.55499655", "0.55466723", "0.554171", "0.55359066", "0.5516865", "0.5515751", "0.5515436", "0.55111647", "0.5500975", "0.5491345", "0.5467559", "0.5465177", "0.54549867", "0.54528886", "0.5451922", "0.5444492", "0.5442748", "0.54383796", "0.5433087", "0.5428515", "0.54274684", "0.5423665", "0.5421318", "0.5403448", "0.54001135", "0.53998595", "0.5393585", "0.53890055", "0.5379637", "0.537897", "0.5378878", "0.5378801", "0.536981", "0.53664327", "0.5364692", "0.53634214", "0.53590536", "0.53561544", "0.5353977", "0.53537905", "0.5353431", "0.5352218", "0.53472406", "0.53464824", "0.5344262", "0.53440136", "0.5342491", "0.5340724", "0.5335863", "0.5335792" ]
0.7237409
0
Return a message selected randomly or a message selected based on time. Return: Randomly selected message
function qtpiLetter() { var pLeft = '<p style="text-align: left">' var pCenter = '<p style="text-align: center">' var pRight = '<p style="text-align: right">' var pEnd = '</p>' var d = new Date() var meridiem = d.getHours() < 12 ? 'a.m.' : 'p.m.' if (d.getMinutes() == 14 && (d.getHours() == 3 || d.getHours() == 15)) { return pLeft + 'Cutie Pai,' + pEnd + pCenter + 'Happy <big style="font-family: serif">&pi;</big> ' + meridiem + pEnd + pRight + '&mdash; Susam' + pEnd } var letters = [ pLeft + 'Cutie Pai,' + pEnd + pCenter + 'I <span style="color: #f52887; font-size: 110%">&#x2764;' + '</span> U!' + pEnd + pRight + '&mdash; Susam' + pEnd, pLeft + 'Cutie Pai,' + pEnd + pCenter + 'I <span style="color: #f52887; font-size: 130%">&hearts;' + '</span> U!' + pEnd + pRight + '&mdash; Susam' + pEnd, pLeft + 'Cutie Pai,' + pEnd + pCenter + 'I love you! <span style="color: #f52887;">' + '<span style="font-size: 60%">&hearts;</span>' + '<span style="font-size: 100%">&hearts;</span></span>' + pEnd + pRight + '&mdash; Susam' + pEnd, pLeft + 'Cutie Pai,' + pEnd + pLeft + 'Your smile is the most beautiful thing in the ' + 'world to me. <big style="color: #a53364">&#x263a;</big>' + pEnd + pRight + '&mdash; Susam' + pEnd, pLeft + 'Cutie Pai,' + pEnd + pLeft + 'Do you know why I got the tiny wine glass for you at ' + 'Purple Haze?' + pEnd + pLeft + 'Because I can go to any length to see you smile.' + pEnd + pRight + '&mdash; Susam' + pEnd, pLeft + 'Cutie Pai,' + pEnd + pCenter + 'You make me want to be a better person.' + pEnd + pRight + '&mdash; Susam' + pEnd ] return Util.random(letters) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getRandomMessage() {\n\tvar index = Math.floor(Math.random() * messages.length); \n\treturn messages[index];\n}", "function randomMessage() {\n return messages[(Math.random() * messages.length) | 0];\n}", "function getRandomMsg(messages) {\n const r = Math.floor(Math.random() * messages.length);\n console.log(messages[r]);\n return(messages[r]);\n} // end displayRandomMsg", "function getBotMessage() {\r\n console.log(chatBotMessages[Math.floor(Math.random() * chatBotMessages.length)]);\r\n \r\n return(chatBotMessages[Math.floor(Math.random() * chatBotMessages.length)]);\r\n}", "function getRandomMessage () {\n const randNum = Math.floor((Math.random() * 3) + 1);\n switch (randNum) {\n case 1:\n return getLib1();\n case 2:\n return getLib2();\n case 3:\n return getLib3();\n default:\n return \"error\";\n }\n}", "function correctMsgGenerator () {\n var $chosenCorrectMsg = $correctMessage[Math.floor(Math.random()*$correctMessage.length)];\n $('.correct-msg').html($chosenCorrectMsg);\n }", "function wrongMsgGenerator () {\n var $chosenWrongMsg = $wrongMessage[Math.floor(Math.random()*$wrongMessage.length)];\n $('.wrong-msg').html($chosenWrongMsg);\n}", "function getRandomizedTime ( delay, randinter, mode ) {\n\ttry {\n\t\trandinter = ( randinter == null || randinter == undefined || randinter === \"\" ) ? 15*60*1000 : Number(randinter); // if randinter not specified, use default 15 min\n\t\tmode = ( mode == null || mode == undefined || mode === \"\" ) ? 0 : Number(mode); // if mode not specified, use default 0\n\n\t\tswitch ( mode ) {\n\t\t\tcase 0:\n\t\t\t\t// curent time (milli) + delay (milli) + random ( randinter ) mins\n\t\t\t return ( new Date().getTime() + delay + Math.ceil ( Math.random() * randinter ) );\n\t\t\tcase 1:\n\t\t\t\t// current time (milli) + delay (milli) +/- random ( randinter/2 ) mins\n\t\t\t\treturn ( new Date().getTime() + delay + Math.ceil ( Math.random() * randinter - randinter/2.0 ) );\n\t\t\tcase 2:\n\t\t\t\t// delay (milli) + random (randinter ) mins\n\t\t\t\treturn ( delay + Math.ceil ( Math.random() * randinter ) );\n\t\t}\n\t\t\n\t}\n\tcatch ( err ) {\n\t\tprintStackTrace();\n\t\tvar msg = \"<b>getRandomizedTime():: Something went wrong, error: \" + err.name + \", Error Message: \" + err.message + \"</b>\";\n\t\tplaySound ( msg );\n\t\tprintErrorMSG(msg);\n\t\tthrow err;\n\t}\n}", "function retrieveMessage() {\n if (affirmationMessageSelection.checked) {\n bodyForBackgroundChange.style.background = \"linear-gradient(#0575E6, #00F260)\";\n return getRandomMessage(affirmations);\n } else if (mantraMessageSelection.checked) {\n bodyForBackgroundChange.style.background = \"linear-gradient(#108dc7, #ef8e38)\";\n return getRandomMessage(mantras);\n } else {\n return \"Please select a message type!!\";\n };\n}", "function displayRandomMessage() {\n showHide(loader, logo);\n hide(chosenMessage);\n // hide(favoriteButton);\n var timer;\n timer = setTimeout(showMessage, 1500);\n}", "function message() {\n var insultGiv = insult[Math.floor((Math.random())* insult.length)]\n var choreGiv = chore[Math.floor((Math.random())* chore.length)]\n var commentGiv = comment[Math.floor((Math.random())* comment.length)]\n return `Wake up ${insultGiv}! You have to ${choreGiv} today. Get it done ${commentGiv}.`\n}", "function pickTime() {\n var min = 300,\n max = 1000;\n return Math.round(Math.random() * (max - min + 1) + min);\n}", "function selectReplica(messagesList) {\n let p = document.createElement('p');\n p.className = \"chat-response\";\n let randomReplica = messagesList[Math.floor(Math.random() * messagesList.length)];\n p.textContent = randomReplica;\n\n return p;\n}", "function generateRMsg(arr) {\n let randNum = Math.floor(Math.random() * arr.length);\n return arr[randNum];\n }", "function randomReplyStart(){\n\treturn replyStartArray[Math.floor(Math.random() * replyStartArray.length)];\n}", "function getRandom(){\n\t var random = randomFacts[Math.floor(Math.random() * randomFacts.length)];\n document.getElementById(\"message\").innerHTML=random;\n}", "function chooseMsg(msgArray) {\n var newMsgs = [];\n for (var i = msgArray.length - 1; i >= 0; i--) {\n var msg = msgArray[i];\n if (msg == lastMsg) {\n break;\n }\n newMsgs.unshift(msg);\n }\n if (newMsgs.length > 0) {\n // update the lastest received message\n lastMsg = newMsgs[newMsgs.length - 1];\n }\n return newMsgs;\n}", "function selectPassage()\n{\n\tvar randIndex = Math.floor(Math.random() * 4);\n\n\tselectedPassageTitle = passages[randIndex][0];\n\tselectedPassageText = passages[randIndex][1];\n\n\tconsole.log(selectedPassageTitle + \"\\n\\n\" + selectedPassageText);\n\n}", "function askingTime(msg){\n return msg.text.toLowerCase().match(/time/i);\n}", "getRandomTime() {\n return Math.floor(Math.random(1000) * 5000) + 1;\n }", "randomMessage(won) {\n var self = this;\n\n // Timeout is used so it doesn't feel to weird after getting a wrong combination\n setTimeout(function() {\n if(won) {\n msgWindow.textContent = self.compliment[parseInt(self.compliment.length * Math.random())];\n } else {\n msgWindow.textContent = self.error[parseInt(self.error.length * Math.random())];\n }\n\n // To display and remove the window with a custom message\n msgWindow.classList.add(\"active\"), \n setTimeout(function () { \n msgWindow.classList.remove(\"active\"); \n }, 1100); \n }, 200);\n }", "function randomTime() {\n\t\tvar randomNumber = Math.floor(Math.random() * 3);\n\t\treturn randomNumberInSecs = randomNumber * 100;\n\t}", "function getRandomEmoji(){\n\tvar emojiSet = [\n\t\"1\",\n\t\"2\",\n\t\"3\",\n\t\"4\",\n\t\"5\",\n\t\"6\",\n\t\"7\",\n\t\"8\",\n\t\"9\",\n\t\"10\",\n\t\"11\",\n\t\"12\",\n\t\"13\",\n\t\"14\",\n\t\"15\",\n\t\"16\"\n\t];\n\n\tvar selectEmoji = emojiSet[Math.floor(Math.random() * 16)];\n\t//console.log(selectColor);\n\treturn selectEmoji;\n}", "function getRandomTimeout () {\n return self.intervalMs + Math.floor(Math.random() * self.intervalMs / 5)\n }", "function recieveMessage() {\n let msg;\n switch (num) {\n case 0:\n msg = \"Hey, hey you\"\n break;\n case 1:\n msg = `You're ${fname}, right? ${fname} ${lname}?`\n break;\n case 2:\n msg = \"Listen, I don't have much time\"\n break;\n case 3:\n msg = 'check behind the image of the so-called \"Glorious\" Leader'\n break;\n case 4:\n msg = 'remember this - username is \"JinpingXi\", the password is \"GreatFirewall\"'\n break;\n }\n addMessageToChat(msg);\n messageSound.play();\n\n //have a delay between each message\n if (num < 5) {\n setTimeout(recieveMessage, 2000);\n }\n}", "function generateFakeMessage() {\n const ABC = 'abcdefghijklmnopqrstuvwxyz '.split('');\n const MESSAGE_LENGTH_MIN = 40;\n const MESSAGE_LENGTH_MAX = 70;\n const messageLength = Math.floor(Math.random() * (MESSAGE_LENGTH_MAX - MESSAGE_LENGTH_MIN) + MESSAGE_LENGTH_MIN);\n let result = '';\n\n for (let i = 0; i < messageLength; i++) {\n const letter = ABC[Math.floor(Math.random() * ABC.length)];\n const prevLetter = result[result.length - 1];\n\n result += !prevLetter ? letter.toUpperCase() : letter;\n }\n\n return {\n id: id++,\n title: `${result.trim()}.`,\n unread: true,\n datetime: new Date(),\n };\n}", "function getReply() {\n var messages = [ \"Sorry. I'm not configured with a response to your message. Text HELP OUT to see a few examples.\",\n \"Hey, I didn't understand that. I suggest sending HELP OUT\",\n \"Text me ABOUT to learn about the ChrisBot project.\",\n \"The program responds to HELP OUT only. You have to send a command that I understand. :)\",\n \"The ChrisBot is not a human. It is just a series of files on a computer. Text ABOUT to learn more.\",\n \"Seriously, you are wayyyyy smarter than ChrisBot. It just knows simple commands. Message HELP OUT for some help!\",\n \"Yo. I do not know what you are talking about. Send me a HELLO\",\n \"There is a ton of information in ChrisBot. You have to use HELP OUT to find it.\",\n \"That's interesting. Hhhmmm... I never thought of that. Maybe try HELP OUT\",\n \"Can you say that again?\",\n \"Yeah... that happens from time to time. Try HELP OUT or ABOUT.\",\n \"That is a ton of words you just wrote there... I really don't know. Try MORE\",\n \"Right now, punctuation throws me off. Send text without it. Try HELP OUT\",\n ];\n\n var arrayIndex = Math.floor( Math.random() * messages.length );\n\n\n return messages[arrayIndex];\n\n }", "function reply() {\nvar statusAccesso = $(\".active-head .name p\").html();\n$(\".active-head .name p\").text(\"Sta scrivendo..\");\nsetTimeout(function () {\n var randRisposte = Math.floor(Math.random() * risposte.length);\n var valoreInserito = risposte[randRisposte];\n var messaggioInterno = $(\".active .msg-structure .cpu\").clone();\n var orario = time();\n\n if (valoreInserito !=\"\") {\n messaggioInterno.find(\".testo-msg\").text(valoreInserito);\n messaggioInterno.find(\".ora-msg\").text(orario);\n $(\".active\").append(messaggioInterno);\n $(\"#msg-input\").val(\"\");\n $(\".active-head .name p\").html(statusAccesso);\n $(\".active-head .name p span\").text(orario);\n $(\".active-chat .name-chat .orario-chat\").text(orario);\n $(\".active-chat .name-chat .chat-style\").text(valoreInserito);\n };\n}, 2000);\n}", "function generateMessage(){\n \n // A few words we'll use a lot\n var about = \"about\";\n var and = \"and\";\n var space = \" \";\n var a = \"a(n)\";\n var of = \"of\";\n\n var indexAdj = floor(random(adjective.length));\n var indexMed = floor(random(medium.length));\n var indexMat1 = floor(random(material1.length));\n var indexMat2 = floor(random(material2.length));\n var indexAct = floor(random(action.length));\n var indexSubj = floor(random(subject.length));\n \n // print out index number for each message\n var idnum = indexAdj + \".\" + indexMed + \".\" + indexMat1 + \".\" + indexMat2 + \".\" + indexAct + \".\" + indexSubj;\n\n // Check if we want to use recall number to generate old text or generate fresh text\n if(useInputNum){\n var idNumSplit = split(inputNum, \".\");\n // Use key number to create/recreate a message\n var message = assignArticle(adjective[idNumSplit[0]]) + space + medium[idNumSplit[1]] + space + material1[idNumSplit[2]] + space + and + space + material2[idNumSplit[3]] + space + action[idNumSplit[4]] + space + subject[idNumSplit[5]];\n //return message;\n \n } else {\n \n // Compile our final text to output\n var message = idnum + \":\" + space + assignArticle(adjective[indexAdj]) + space + medium[indexMed] + space + \"using\" + space + material1[indexMat1] + space + and + space + material2[indexMat2] + space + action[indexAct] + space + subject[indexSubj];\n\n //return message;\n }\n\n\n var messageElt = document.getElementById(\"messageElt\");\n var latestMessage = message;\n console.log(latestMessage);\n messageElt.innerHTML = latestMessage;\n \n}", "function pickRandomChoice(){\n return choices[Math.floor(Math.random() * choices.length)];\n}", "function random(){\n\t return random.get();\n\t }", "function random(){\n\t return random.get();\n\t }", "function sendRandomMIDIMessage(MIDIAccess){\r\n \r\n var delay, noteNumber, velocity, midiMessage;\r\n \r\n if(currentNote < sequenceLength){\r\n \r\n //delay random between 0 an maxDelay milliseconds\r\n delay = Math.floor((Math.random() * maxDelay));\r\n\r\n //noteNumber random between 21 (A0) an 108 (C8)\r\n noteNumber = Math.floor((Math.random() * 87) + 21);\r\n\r\n //velocity random between 10 and 127\r\n velocity = Math.floor((Math.random() * 127) + 10);\r\n\r\n //position in milliseconds\r\n sequencePosition += delay;\r\n\r\n midiMessage = MIDIAccess.createMIDIMessage(JMB.NOTE_ON, noteNumber, velocity, 0, sequencePosition);\r\n \r\n //recursively called until sequenceLength is reached \r\n sendTimedMIDIEvent(midiMessage, delay, function(){\r\n currentNote = currentNote + 1;\r\n sendRandomMIDIMessage(MIDIAccess);\r\n });\r\n }else{\r\n logMessage(\" - - stop\"); \r\n }\r\n }", "function picker(posses){\n thisTime = floor(random(posses));\n return thisTime;\n }", "function getReply(type) {\n\tvar rs = replies[type];\n\treturn rs[parseInt(Math.random() * rs.length)];\n}", "function random(){\n return random.get();\n }", "function random(){\n return random.get();\n }", "function selectRandom(){\n var randomNumber = Math.floor(Math.random() * (1, arrayLength));\n var randomWord = wordArray[randomNumber];\n return randomWord;\n}", "function getComputerChoice() {\n const choices = ['r', 'p', 's', 'l', 'm'];\n const randomNumber = Math.floor(Math.random() * 5);\n return choices[randomNumber];\n}", "combineMessage() {\r\n const numberSelector = arrayLength => Math.floor(Math.random() * arrayLength); //takes an array.length and returns a random number based on that length\r\n\r\n console.log(this.names[numberSelector(this.names.length)] + \" \"\r\n + this.verbs[numberSelector(this.verbs.length)] + \" like the \"\r\n + this.objects[numberSelector(this.objects.length)] + \" that the \"\r\n + this.events[numberSelector(this.events.length)] + \" \"\r\n + this.actions[numberSelector(this.actions.length)] + \" over.\");\r\n }", "selectRand() {\n\t}", "function ranSMS(){\n var str = Math.random();\n var str1 = str.toString();\n\tvar res = str1.substring(2,6);\n\treturn res;\n}", "function ranSMS(){\n var str = Math.random();\n var str1 = str.toString();\n\tvar res = str1.substring(2,6);\n\treturn res;\n}", "function randomSelect(array) {\n var randomI = Math.floor(Math.random() * array.length);\n var randomE = array[randomI];\n return randomE;\n}", "function choose(options) {\n return options[Math.floor(Math.random() * options.length)];\n}", "function pickColor(){\r\n\tvar random = Math.floor(Math.random()*colors.length);\r\n\treturn colors[random];\r\n}", "function RandomPick() {\r\n // Randomly select one colour and return it back\r\n var picks = [\"Red\", \"Green\", \"Yellow\", \"Blue\"];\r\n return picks[Math.floor(Math.random()*picks.length)];\r\n}", "function randItem(selectedArray) {\n return selectedArray[Math.floor(Math.random()*selectedArray.length)];\n}", "function SelectWord() {\n\treturn words[Math.floor(Math.random()*words.length)];\n}", "function pickRandomColor () {\n\tvar random = Math.floor(Math.random() * colors.length);\n\treturn colors[random];\n}", "function pick() {\r\n index = Math.floor(Math.random() * words.length);\r\n return words[index];\r\n}", "function pickQuestion(){\n\n var random_question_id = Math.floor((Math.random() * questions_array.length ));\n while(_.contains(already_picked_questions,random_question_id.toString())){\n\n random_question_id = Math.floor((Math.random() * questions_array.length ));\n\n }\n if (random_question_id == 0){\n var is_contained = _.contains(already_picked_questions, \"15\");\n console.log(is_contained);\n if ( is_contained == false){\n var tmp_picked_question = \"15\";\n return random_question_id;\n }\n else {\n pickQuestion()\n }\n\n }\n\n\n return random_question_id;\n\n }", "function cpuPick(){\n switch (getRandomInt(3)){\n case 0:\n return \"rock\";\n case 1:\n return \"paper\";\n default:\n return \"scissors\";\n }\n}", "function getAlert() {\n return randomSelect([true, false]);\n}", "async function readLastOtherPersonMessage() {\n\n let message = '';\n let name = await getCurrentUserName();\n\n if (!name) {\n return false;\n }\n\n // read last message sent by other user\n message = await page.evaluate((selector) => {\n\n let nodes = document.querySelectorAll(selector);\n let el = nodes[nodes.length - 1];\n\n if (!el) {\n return '';\n }\n\n // check if it is picture message\n\n /*\n if (el.classList.contains('message-image')) {\n return 'Picture Message';\n }\n */\n\n let picNodes = el.querySelectorAll(\"img[src*='blob']\");\n let isPicture = picNodes[picNodes.length - 1];\n\n if (isPicture) {\n return 'Picture Message';\n }\n\n // check if it is gif message\n let gifNodes = el.querySelectorAll(\"div[style*='background-image']\");\n let isGif = gifNodes[gifNodes.length - 1];\n\n if (isGif) {\n return 'Gif Message';\n }\n\n // check if it is video message\n let vidNodes = el.querySelectorAll(\".video-thumb\");\n let isVideo = vidNodes[vidNodes.length - 1];\n\n if (isVideo) {\n return 'Video Message';\n }\n\n // check if it is voice message\n let audioNodes = el.querySelectorAll(\"audio\");\n let isAudio = audioNodes[audioNodes.length - 1];\n\n if (isAudio) {\n return 'Voice Message';\n }\n\n // check if it is emoji message\n let emojiNodes = el.querySelectorAll(\"div.selectable-text img.selectable-text\");\n let isEmoji = emojiNodes[emojiNodes.length - 1];\n\n if (isEmoji) {\n return 'Emoji Message';\n }\n\n // text message\n nodes = el.querySelectorAll('span.selectable-text');\n el = nodes[nodes.length - 1];\n\n return el ? el.innerText : '';\n\n }, selector.last_message);\n\n\n if (message) {\n if (last_received_message) {\n if (last_received_message != message) {\n last_received_message = message;\n print(name + \": \" + message, config.received_message_color);\n\n // show notification\n notify(name, message);\n }\n } else {\n last_received_message = message;\n //print(name + \": \" + message, config.received_message_color);\n }\n\n }\n }", "async function getSelectorNewMessage(){\n \tif (selectorNewMessage==null){\n \t\tlet classname = await page.evaluate((selector) => {\n \t\t\tlet nodes = document.querySelectorAll(selector);\n \n \t\t\tfor (let i = 0; i <= nodes.length; i++) {\n \t\t\t\tvar style = window.getComputedStyle(nodes[i]);\n \t\t\t\tvar borderRadius = style.getPropertyValue('border-radius');\n \t\t\t\tif (borderRadius=='12px')\n \t\t\t\t\treturn nodes[i].className;\n \t\t\t}\n\n \t\t\treturn null;\n \t\t}, selector.new_message_count);\n \t\tif (classname==null)\n \t\t\tconsole.log(logSymbols.warning, chalk.bgRed('Not yet found a kind of notification of new messages'));\n \t\telse{\n \t\t\tselectorNewMessage=selector.new_message.replace('XXXXX', classname);\n \t\t\tconsole.log(logSymbols.info, chalk.bgRed('It was generated selector of notification of new messages: '+selectorNewMessage));\n \t\t}\n \t\t\n \t}\n\n return selectorNewMessage;\n }", "function selectWord() {\n return wordList[Math.floor(Math.random() * wordList.length)];\n }", "function selectMeme()\n{\n\tvar r = Math.floor( Math.random() * memesLength );\n\tvar it = 0;\n\t//Si el numero aleatorio ya esta seleccionado\n\twhile($.inArray(r,validMemes) >= 0)\n\t{\n\t\t//Generar un nuevo aleatorio\n\t\tr = Math.floor( Math.random() * memesLength );\n\t}\n\treturn r;\n}", "function randomSentence() {\n var sentenceIndex = Math.floor(Math.random()*self.sentences.length)\n\n if (self.currentSentence !== sentenceIndex) {\n self.currentSentence = sentenceIndex\n } else {\n randomSentence()\n }\n }", "selectRand(length = 1) {\n\t}", "function getRandom() {\n\treturn Math.random();\n}", "function pickColor(){\n\tvar random = Math.floor(Math.random() * difficulty);\n\treturn colors[random];\n}", "function computerSelection(){\n let rand = random(choices.length);\n return choices[rand];\n}", "function pickColor(){\n\tvar random=Math.floor(Math.random()*colors.length);\n\treturn colors[random];\n}", "function pickColor(){\n\tvar random=Math.floor(Math.random()*colors.length);\n\treturn colors[random];\n}", "getRandomPhrase() {\n let randomOneToFive = Math.floor(Math.random() * 5);\n return this.phrases[randomOneToFive];\n }", "function getRandom() {return data[Math.floor(Math.random() * data.length)]}", "function getCurrentTimeAndRandom() {\n return getCurrentTime() + Math.random();\n}", "function chooseThread (threads) {\n return threads[parseInt(Math.random() * (threads.length))];\n}", "function pickColor(){\n\tvar random = Math.floor(Math.random() * colors.length);\n\n\treturn colors[random];\n}", "function pickColor(){\r\n\tvar random=Math.floor(Math.random() * colors.length);\r\n\treturn colors[random];\r\n}", "function replyMessage(){\n // Mentre aspetta il messaggio di risposta far vedre nella HEADER CONTACT BAR un messaggio..\n $('.header-contact-bar').find('.last-access p').text('sta scrivendo un messagio...');\n $('.contact.selected').find('.box-contact p').text('sta scrivendo un messagio...');\n\n setTimeout(function(){\n /* Risposte Automatiche */\n var messagesReceived = [\n 'Tutto Ok, dai!!',\n 'Non sapevo nulla',\n 'grazie',\n 'non lo sapevo',\n 'Sono contento',\n 'Raccontami qualcosa.',\n 'Vieni a casa!!',\n 'Ci vediamo domani',\n 'Sicuro???',\n 'devo salutarti',\n 'Tutto è cambiato',\n 'devo portare il cane fuori',\n 'volendo domani possiamo uscire'\n ];\n\n var numeroRandon = creaNumeroRandom(messagesReceived);\n var template = $('.template').find('.message-left').clone();\n\n // Inserire Ora.\n var date = new Date();\n var currentHours = date.getHours();\n var currentMinutes = date.getMinutes();\n var currentTime = addZeroToNumber(currentHours) + ':' + addZeroToNumber(currentMinutes);\n // Aggiungo a MESSAGE HOUR il testo di CURRENT-TIME.\n template.find('.box-left .message-hour').text(currentTime);\n // Aggiungo a MESSAGE RECEIVED il testo del \"Risposte Automatiche\".\n template.find('.js_message-received').text(messagesReceived[numeroRandon]);\n // Append il TEMPLATE sul CONTAINER MESSAGE si ha la class ACTIVE.\n $('.container-message.active').append(template);\n\n /* Vissualizare ultimo messaggio */\n $('.container-message').scrollTop($('.container-message').height());\n\n // Dopo che a risposto con un messagio far apparire nella HEADER CONTACT BAR questo messaggio.\n $('.header-contact-bar').find('.last-access p').text('ultimo accesso oggi alle ' + currentTime);\n\n // L'orario e il testo del TIME CONTACT si vedono anche nel BOX CONTACT.\n $('.contact.selected').find('.time-contact p').text(currentTime);\n $('.contact.selected').find('.box-contact p').text(messagesReceived[numeroRandon]);\n\n }, 1500);\n }", "function randomResponse() {\n const responses = DICT.random_responses;\n return responses[Math.floor(Math.random() * responses.length)];\n}", "function randomPhrase() {\n var phraseNum = randomNumber(first, phrases.length - 1);\n var thePhrase = phrases[phraseNum];\n $('#message').text(thePhrase);\n}", "function pickcolor(){\r\n var randomOneColor=Math.floor(Math.random()*colors.length);\r\n return colors[randomOneColor];\r\n}", "function randomTile() {\n // There's probably a way to get this out of the DOM via jQuery\n var choices = [\"blue\", \"brown\", \"darkgreen\", \"grey\", \"white\", \"lightgreen\"];\n var num = Math.floor(Math.random() * choices.length);\n return choices[num];\n}", "function randomSelection (array) {\n var randomNumber = Math.floor(Math.random() * array.length);\n return array[randomNumber];\n }", "function chooseRandomStickyColour(){\r\n\treturn tStickyColours[Math.floor(Math.random()*tStickyColours.length)];\r\n}", "function randomPick(array){\n\tlet choice = Math.floor(Math.random() * array.length);\n\treturn array[choice];\n}", "function getMachineInput() {\n var choices = [\"r\", \"s\", \"p\"];\n var rng = Math.floor(Math.random()*3);\n return choices[rng];\n}", "function pickColor(){\n var random = Math.floor(Math.random()*colors.length);\n return colors[random];\n}", "function choose(array) {\n\t\treturn array[getRandomInt(array.length)];\n\t}", "function pickColor(){\n var random = Math.floor(Math.random() * colors.length);\n return colors[random];\n}", "function pickcolor() {\n\tvar random=Math.floor(Math.random()*color.length);\n\t return color[random];\n\t// body...\n}", "function Message(number, text, delay) { return {number: number, text: text, delay: delay} }", "function randomChoice(choices){\n return choices[random(0, choices.length-1)];\n}", "function pickColor(){\n var random = Math.floor(Math.random()* colors.length);\n return colors[random];\n}", "function pickColor(){\n var rand = Math.floor(Math.random()*color.length);\n return color[rand];\n}", "function randomSequence () {\n\tvar random = Math.floor(Math.random() * sequence.length);\n\treturn sequence[random];\n}", "function randomSelect(array) {\n return array[getRandomInt(0, array.length)];\n}", "function getComputerChoice() {\r\n const choices = ['r', 'p', 's'];\r\n console.log((Math.floor(Math.random() *3))); // const randomNumber =\r\n return choices[randomNumber]; \r\n}", "function pickColor(){\n\tlet random = Math.floor(Math.random()*colors.length);\n\treturn colors[random];\n}", "function selectRandomly(/* TODO parameter(s) go here */) {\n // TODO complete this function\n}", "function randomThankYou() {\n // actual random would flicker every option on draw()\n // return thanks[Math.floor(Math.random()*thanks.length)];\n return thanks[(turn-1)%thanks.length]; // sequential looping\n}", "function pickColor() {\n\tvar random = Math.floor(Math.random() * colors.length);\n\treturn colors[random];\n}", "function pickColor(){\n\tvar random = Math.floor(Math.random() * colors.length);\n\t//Return random colour from array\n\treturn colors[random];\n}", "function randomPick(array) {\n let choice = Math.floor(Math.random() * array.length);\n return array[choice];\n}", "function randomPick(array) {\n let choice = Math.floor(Math.random() * array.length);\n return array[choice];\n}", "function getComputerChoice() {\r\n const choices = [\r\n { choice: 'r', beats: ['s', 'l'], losesTo: ['p', 'sp'] },\r\n { choice: 'p', beats: ['r', 'sp'], losesTo: ['s', 'l'] },\r\n { choice: 's', beats: ['p', 'l'], losesTo: ['r', 'sp'] },\r\n { choice: 'l', beats: ['p', 'sp'], losesTo: ['r', 's'] },\r\n { choice: 'sp', beats: ['r', 's'], losesTo: ['p', 'l'] }\r\n ];\r\n\r\n // generate random number\r\n const randomNumber = Math.floor(Math.random() * choices.length);\r\n\r\n // return choice based on element of random number in choices array\r\n return choices[randomNumber];\r\n}", "function botChoice() {\n var choices = ['rock', 'paper', 'scissors'];\n var randomChoice = choices[Math.floor(Math.random() * choices.length)];\n return randomChoice;\n}", "function pickColor() {\n var random = Math.floor(Math.random() * colors.length);\n return colors[random];\n}" ]
[ "0.7660767", "0.7650097", "0.6743472", "0.6567896", "0.64238006", "0.62507594", "0.62049794", "0.61180377", "0.6060958", "0.6056758", "0.60522383", "0.60224414", "0.60002166", "0.59629357", "0.5938398", "0.59235996", "0.5898373", "0.5867413", "0.5862219", "0.5828933", "0.581524", "0.5803879", "0.5803726", "0.5801621", "0.5801595", "0.5768985", "0.5748496", "0.5737467", "0.57303035", "0.5722668", "0.5665422", "0.5665422", "0.56235796", "0.559341", "0.55521184", "0.5532499", "0.5532499", "0.5503033", "0.550062", "0.5499788", "0.5488161", "0.54831296", "0.54831296", "0.5466803", "0.54510766", "0.54319584", "0.5424492", "0.54219216", "0.54164445", "0.5413182", "0.5408227", "0.5406952", "0.54050195", "0.54007137", "0.5397871", "0.5390611", "0.5383927", "0.5382336", "0.53817713", "0.53803873", "0.5379546", "0.53770316", "0.53745174", "0.5372004", "0.5372004", "0.53692925", "0.53640574", "0.53632164", "0.53558946", "0.53555226", "0.5352814", "0.53434414", "0.53404593", "0.53372824", "0.5334765", "0.53343844", "0.53341734", "0.5332363", "0.532709", "0.53245103", "0.53241396", "0.53230673", "0.5322493", "0.53181714", "0.53146726", "0.53139037", "0.5306784", "0.53024745", "0.529747", "0.52967405", "0.5293456", "0.52931136", "0.52925116", "0.5291741", "0.5291464", "0.5290286", "0.5287228", "0.5287228", "0.5285198", "0.52850366", "0.5282182" ]
0.0
-1
XXX: handle drafts in some other way. it's better to provide a control mechanism for filtering content based on metadata
draft() { return require.context( 'json!yaml-frontmatter!./drafts', false, /^\.\/.*\.md$/ ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function gotContent(data){\r\n let page = data.query.pages; \r\n //console.log(page);\r\n let pageID = Object.keys(data.query.pages)[0];\r\n console.log(pageID);\r\n\r\n let content = page[pageID].revisions[0][\"*\"];\r\n startOfContentChar = \"'''\"\r\n startCharIndex = content.search(startOfContentChar) + 3;\r\n console.log(startCharIndex);\r\n endCharIndex = startCharIndex + 200 + 1;\r\n description = content.substring(startCharIndex, endCharIndex) + '...'\r\n document.getElementById('contentDisplay').innerHTML =description;\r\n //console.log(content); \r\n // access summary brute force \r\n //let summary = page[pageID].revisions[0][\"*\"][10];\r\n //console.log('SUMMARY' + summary);\r\n }", "function updateEntityPreviewContent() {\r\n if (currentEntity) {\r\n // first get the contentContainer for the entity's preview\r\n var contentContainer = $(\"#\" + currentEntity.id + \" > div\");\r\n // create the contentContainer if it doesn't exist:\r\n if (!contentContainer[0])\r\n contentContainer = createEntityPreview(currentEntity);\r\n \r\n // add/update the appropriate contents\r\n switch(currentEntity.type) {\r\n case \"image\" :\r\n // get the image element in the contentContainer\r\n var image = $(\"#\"+currentEntity.id + \" > img\");\r\n //empty the contentContainer and create a new image contentContainer if one doesn't exist\"\r\n if(!image[0]) {\r\n image = $(\"<img>\");\r\n contentContainer.empty();\r\n contentContainer.append(image);\r\n }\r\n // set the image's source\r\n image.src = currentEntity.content;\r\n break;\r\n case \"textbox\" :\r\n // clear the current content of the contentContainer\r\n contentContainer.empty();\r\n // slice the content along line breaks so <br> tags are not needed\r\n var lines = currentEntity.content.split(/(\\r\\n)|(^\\r\\n)/gm);\r\n // add each entry to the contentContainer seperated by line breaks\r\n for (var i = 0; i < lines.length; ++i)\r\n contentContainer.append(\"\" + lines[i] + \"<br>\");\r\n break;\r\n case \"bulletlist\" :\r\n // get the contentContainer for the entitiy:\r\n var list = contentContainer.children(\"ul\");\r\n // empty the div and create a new list if one does'nt exist:\r\n if(!list[0]) {\r\n contentContainer.empty();\r\n var list = $(\"<ul><ul>\");\r\n contentContainer.append(list);\r\n }\r\n // empty the list:\r\n list.empty();\r\n // slice the content along line breaks to get the list entries:\r\n var entries = currentEntity.content.split(/(\\r\\n|^\\r\\n)/gm);\r\n // add each entry to the list:\r\n for (var i = 0; i < entries.length; ++i)\r\n $(\"<li>\"+entries[i]+\"</li>\").appendTo(list);\r\n }\r\n }\r\n}", "function content () {\n if (search.file === 'new') {\n return Split(sidebar(), [FileNew(state, emit), Page()])\n }\n\n if (search.file) return File(state, emit)\n if (search.pages === 'all') return PagesAll(state, emit)\n\n if (search.page === 'new') {\n return Split(\n sidebar(),\n [PageNew(state, emit), Page()]\n )\n }\n\n if (search.files === 'all') {\n return FilesAll(state, emit)\n }\n\n return Split(\n sidebar(),\n Page()\n )\n }", "function gotContent(data){\r\n let page = data.query.pages; \r\n //console.log(page);\r\n let pageID = Object.keys(data.query.pages)[0];\r\n console.log(pageID);\r\n\r\n let followUpContent = page[pageID].revisions[0][\"*\"];\r\n startOfContentChar = \"'''\"\r\n startCharIndex = followUpContent.search(startOfContentChar) + 3;\r\n console.log(startCharIndex);\r\n endCharIndex = startCharIndex + 200 + 1;\r\n secondDescription = followUpContent.substring(startCharIndex, endCharIndex) + '...'\r\n document.getElementById('secondContentDisplay').innerHTML =secondDescription; \r\n }", "function emblContentMetaProperties_Read() {\n var metaProperties = {};\n // <!-- Content descriptors -->\n // <meta name=\"embl:who\" content=\"{{ meta-who }}\"> <!-- the people, groups and teams involved -->\n // <meta name=\"embl:what\" content=\"{{ meta-what }}\"> <!-- the activities covered -->\n // <meta name=\"embl:where\" content=\"{{ meta-where }}\"> <!-- at which EMBL sites the content applies -->\n // <meta name=\"embl:active\" content=\"{{ meta-active }}\"> <!-- which of the who/what/where is active -->\n metaProperties.who = metaProperties.who || document.querySelector(\"meta[name='embl:who']\");\n metaProperties.what = metaProperties.what || document.querySelector(\"meta[name='embl:what']\");\n metaProperties.where = metaProperties.where || document.querySelector(\"meta[name='embl:where']\");\n metaProperties.active = metaProperties.active || document.querySelector(\"meta[name='embl:active']\");\n\n // <!-- Content role -->\n // <meta name=\"embl:utility\" content=\"-8\"> <!-- if content is task and work based or if is meant to inspire -->\n // <meta name=\"embl:reach\" content=\"-5\"> <!-- if content is externally (public) or internally focused (those that work at EMBL) -->\n metaProperties.utility = metaProperties.utility || document.querySelector(\"meta[name='embl:utility']\");\n metaProperties.reach = metaProperties.reach || document.querySelector(\"meta[name='embl:reach']\");\n\n // <!-- Page infromation -->\n // <meta name=\"embl:maintainer\" content=\"{{ meta-maintainer }}\"> <!-- the contact person or group responsible for the page -->\n // <meta name=\"embl:last-review\" content=\"{{ meta-last-review }}\"> <!-- the last time the page was reviewed or updated -->\n // <meta name=\"embl:review-cycle\" content=\"{{ meta-review-cycle }}\"> <!-- how long in days before the page should be checked -->\n // <meta name=\"embl:expiry\" content=\"{{ meta-expiry }}\"> <!-- if there is a fixed point in time when the page is no longer relevant -->\n metaProperties.maintainer = metaProperties.maintainer || document.querySelector(\"meta[name='embl:maintainer']\");\n metaProperties.lastReview = metaProperties.lastReview || document.querySelector(\"meta[name='embl:last-review']\");\n metaProperties.reviewCycle = metaProperties.reviewCycle || document.querySelector(\"meta[name='embl:review-cycle']\");\n metaProperties.expiry = metaProperties.expiry || document.querySelector(\"meta[name='embl:expiry']\");\n for (var key in metaProperties) {\n if (metaProperties[key] != null && metaProperties[key].getAttribute(\"content\").length != 0) {\n metaProperties[key] = metaProperties[key].getAttribute(\"content\");\n } else {\n metaProperties[key] = 'notSet';\n }\n }\n return metaProperties;\n}", "initDrafts() {\n this.drafts = {};\n\n // restore data from localStorage\n const contents = window.localStorage.drafts;\n if (contents != null) {\n try {\n this.drafts = JSON.parse(contents);\n }\n catch (e) {\n window.localStorage.removeItem('drafts');\n }\n }\n\n if (this.state.pageId == null) {\n const draft = this.findDraft(this.state.path);\n if (draft != null) {\n this.state.markdown = draft;\n }\n }\n }", "docToFeedItem(doc) {\n const { config } = this.imports\n const { hCard } = this.options\n\n const item = {\n title: doc.get('properties.name.0'),\n id: doc.getPermalink(),\n link: doc.getPermalink(),\n description: doc.get('properties.summary.0'),\n content: doc.get('properties.content.0.html'),\n author: [\n {\n name:\n doc.get('properties.author.0.properties.name.0') ||\n hCard.properties.name[0],\n link:\n doc.get('properties.author.0.properties.photo.0') ||\n hCard.properties.url\n ? hCard.properties.url[0]\n : config.get('siteBaseUrl'),\n email:\n doc.get('properties.author.0.properties.email.0') ||\n hCard.properties.name[0],\n },\n ],\n date: new Date(doc.get('properties.published.0')),\n image:\n doc.get('properties.featured.0') || doc.get('properties.photo.0.value'),\n }\n\n // Tidy up item removing undefined keys\n Object.keys(item).forEach((key) => {\n if (item[key] === undefined) {\n delete item[key]\n }\n })\n\n // Set title fallback from content\n if (!item.title && !item.description) {\n if (!item.content) {\n // This is a post type without a summary, name or content\n // TODO: Handle contentless posts like likes and reposts better.\n // console.warn(\n // '[Postr Feeds]',\n // 'Item is currently not supported',\n // doc.toMf2()\n // )\n return null\n } else {\n item.title =\n doc.get('properties.content.0.value').substring(0, 50) + '…'\n }\n // NOTE: This runs a lottt...\n // console.log('No title or description for rss', item)\n }\n\n // Set content fallback from title\n if (!item.content && (item.description || item.title)) {\n item.content = item.description || item.title\n }\n\n return item\n }", "setContent(content) {\n const { data } = content;\n var vList = data.filter(item => item.contentType.toLowerCase() === \"video\");\n var aList = data.filter(\n item => item.contentType.toLowerCase() === \"article\"\n );\n\n this.setState({\n src: data,\n active_list: data,\n video_list: vList,\n article_list: aList\n });\n }", "function filterContent (data) {\n const intro = {}\n intro.text = $(data).find('p, pre')\n intro.img = $(data).find('figure > img')\n if (intro.text.length === 0) {\n intro.text = null\n }\n if (intro.img.length === 0) {\n intro.img = null\n }\n if (intro.img || intro.text) {\n return intro\n }\n}", "function filterContent(posts) {\n for (let post of posts) {\n if (post.slug === \"tutorials\") {\n return post;\n break;\n }\n }\n}", "function getFilterContentProvider(contentProps) {\n var pillContent = {\n createContent: function (editMode, props, updateConfiguredStatus, updateAriaLabel, editingComplete, removeSelf) {\n return Promise.resolve().then(function () { return require(/* webpackMode: \"lazy\", webpackChunkName: \"FilterPill\" */ \"./FilterPill\"); }).then(function (FilterPill) {\n return React.createElement(FilterPill.FilterPill, { editMode: editMode, disableEdit: props.disableEdit, enableValueMultiSelect: props.enableValueMultiSelect, hideOperatorSelection: props.hideOperatorSelection, areDimensionsLoading: props.areDimensionsLoading, areOperatorsLoading: props.areOperatorsLoading, areValuesLoading: props.areValuesLoading, pickerLists: props.pickerLists, selection: props.selection, onSelectionChange: props.onSelectionChange, showLabels: props.showLabels, canCreateValueEntries: props.canCreateValueEntries, valueEntryCreatorPromptTextFormat: props.valueEntryCreatorPromptTextFormat, autoOpen: props.autoOpen, customOptionRenderers: props.customOptionRenderers, customValueRenderers: props.customValueRenderers, updateConfiguredStatus: updateConfiguredStatus, updateAriaLabel: updateAriaLabel, removeSelf: removeSelf });\n });\n },\n contentProps: contentProps,\n };\n return pillContent;\n}", "function gotContent(data){\r\n let page = data.query.pages; \r\n //console.log(page);\r\n let pageID = Object.keys(data.query.pages)[0];\r\n console.log(pageID);\r\n\r\n let lastfollowUpContent = page[pageID].revisions[0][\"*\"];\r\n startOfContentChar = \"'''\"\r\n startCharIndex = lastfollowUpContent.search(startOfContentChar) + 3;\r\n console.log(startCharIndex);\r\n endCharIndex = startCharIndex + 200 + 1;\r\n secondDescription = lastfollowUpContent.substring(startCharIndex, endCharIndex) + '...'\r\n document.getElementById('lastContentDisplay').innerHTML =secondDescription;\r\n }", "async getSponsoredMain() {\n let { firstObject:post } = await this.store.query('article', {\n sponsored_content: true,\n show_as_feature: true,\n limit: 1,\n });\n\n if (!post) {\n return;\n }\n const ageInHours = moment().diff(post.publishedMoment, 'hours');\n if (ageInHours >= 24 && ageInHours <= 48) {\n return post;\n }\n }", "function giveMeHugeDraft(mode) {\n var result;\n if (mode == 'final') {\n result = {\n text: ''\n };\n return result;\n }\n if (mode == 'preview') {\n result = {\n text: '******DRAFT******',\n fontSize: 40,\n bold: true,\n color: 'red',\n alignment: 'center'\n };\n return result;\n }\n}", "function getContentType(limit, skip, contentSettings, itemsPulled) {\n\tlet previewMode = false;\n\tif (argv.preview) {\n\t\tpreviewMode = true;\n\t}\n\tif (previewMode && !process.env.CONTENTFUL_PREVIEW_TOKEN) {\n\t\tthrow new Error(\n\t\t\t'Environment variable CONTENTFUL_PREVIEW_TOKEN not set'\n\t\t);\n\t} else if (!previewMode && !process.env.CONTENTFUL_TOKEN) {\n\t\tthrow new Error('Environment variable CONTENTFUL_TOKEN not set');\n\t}\n\tconst options = {\n\t\tspace: process.env.CONTENTFUL_SPACE,\n\t\thost: previewMode ? 'preview.contentful.com' : 'cdn.contentful.com',\n\t\taccessToken: previewMode\n\t\t\t? process.env.CONTENTFUL_PREVIEW_TOKEN\n\t\t\t: process.env.CONTENTFUL_TOKEN,\n\t};\n\tconst client = contentful.createClient(options);\n\n\t// check for file extension default to markdown\n\tif (!contentSettings.fileExtension) {\n\t\tcontentSettings.fileExtension = 'md';\n\t}\n\n\tclient\n\t\t.getEntries({\n\t\t\tcontent_type: contentSettings.typeId,\n\t\t\tlimit: limit,\n\t\t\tskip: skip,\n\t\t\torder: 'sys.updatedAt',\n\t\t})\n\t\t.then(data => {\n\t\t\t// variable for counting number of items pulled\n\t\t\tlet itemCount;\n\t\t\tif (itemsPulled) {\n\t\t\t\titemCount = itemsPulled;\n\t\t\t} else {\n\t\t\t\titemCount = 0;\n\t\t\t}\n\t\t\t// create directory for file\n\t\t\tmkdirp.sync(`.${contentSettings.directory}`);\n\n\t\t\tfor (let i = 0; i < data.items.length; i++) {\n\t\t\t\tconst item = data.items[i];\n\t\t\t\tconst frontMatter = {};\n\t\t\t\tif (contentSettings.isHeadless) {\n\t\t\t\t\tfrontMatter.headless = true;\n\t\t\t\t\tmkdirp.sync(`.${contentSettings.directory + item.sys.id}`);\n\t\t\t\t}\n\t\t\t\tif (contentSettings.type) {\n\t\t\t\t\tfrontMatter.type = contentSettings.type;\n\t\t\t\t}\n\t\t\t\tfrontMatter.updated = item.sys.updatedAt;\n\t\t\t\tfrontMatter.createdAt = item.sys.createdAt;\n\t\t\t\tfrontMatter.date = item.sys.createdAt;\n\t\t\t\tfor (const field of Object.keys(item.fields)) {\n\t\t\t\t\tif (field === contentSettings.mainContent) {\n\t\t\t\t\t\t// skips to prevent duplicating mainContent in frontmatter\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t} else if (field === 'date') {\n\t\t\t\t\t\t// convert dates with time to ISO String so Hugo can properly Parse\n\t\t\t\t\t\tconst d = item.fields[field];\n\t\t\t\t\t\tif (d.length > 10) {\n\t\t\t\t\t\t\tfrontMatter.date = new Date(d).toISOString();\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tfrontMatter.date = d;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tconst fieldContent = item.fields[field];\n\t\t\t\t\tswitch (typeof fieldContent) {\n\t\t\t\t\t\tcase 'object':\n\t\t\t\t\t\t\tif ('sys' in fieldContent) {\n\t\t\t\t\t\t\t\tfrontMatter[field] = {};\n\t\t\t\t\t\t\t\tswitch (fieldContent.sys.type) {\n\t\t\t\t\t\t\t\t\tcase 'Asset':\n\t\t\t\t\t\t\t\t\t\tfrontMatter[field] = getAssetFields(\n\t\t\t\t\t\t\t\t\t\t\tfieldContent\n\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\tcase 'Entry':\n\t\t\t\t\t\t\t\t\t\tfrontMatter[field] = getEntryFields(\n\t\t\t\t\t\t\t\t\t\t\tfieldContent\n\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\t\t\tfrontMatter[field] = fieldContent;\n\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// rich text (see rich text function)\n\t\t\t\t\t\t\telse if ('nodeType' in fieldContent) {\n\t\t\t\t\t\t\t\tfrontMatter[field] = [];\n\t\t\t\t\t\t\t\tfrontMatter[\n\t\t\t\t\t\t\t\t\t`${field}_plaintext`\n\t\t\t\t\t\t\t\t] = richTextToPlain(fieldContent);\n\t\t\t\t\t\t\t\tconst nodes = fieldContent.content;\n\t\t\t\t\t\t\t\tfor (let i = 0; i < nodes.length; i++) {\n\t\t\t\t\t\t\t\t\tfrontMatter[field].push(\n\t\t\t\t\t\t\t\t\t\trichTextNodes(nodes[i])\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// arrays\n\t\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\tif (!fieldContent.length) {\n\t\t\t\t\t\t\t\t\tfrontMatter[field] = fieldContent;\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\tfrontMatter[field] = [];\n\t\t\t\t\t\t\t\t\tfor (\n\t\t\t\t\t\t\t\t\t\tlet i = 0;\n\t\t\t\t\t\t\t\t\t\ti < fieldContent.length;\n\t\t\t\t\t\t\t\t\t\ti++\n\t\t\t\t\t\t\t\t\t) {\n\t\t\t\t\t\t\t\t\t\tconst arrayNode = fieldContent[i];\n\t\t\t\t\t\t\t\t\t\tswitch (typeof arrayNode) {\n\t\t\t\t\t\t\t\t\t\t\tcase 'object': {\n\t\t\t\t\t\t\t\t\t\t\t\tlet arrayObject = {};\n\t\t\t\t\t\t\t\t\t\t\t\tswitch (arrayNode.sys.type) {\n\t\t\t\t\t\t\t\t\t\t\t\t\tcase 'Asset':\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tarrayObject = getAssetFields(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tarrayNode\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tfrontMatter[field].push(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tarrayObject\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\t\t\tcase 'Entry':\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tarrayObject = getEntryFields(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tarrayNode\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tfrontMatter[field].push(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tarrayObject\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tfrontMatter[field].push(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tarrayNode\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\t\t\t\t\tfrontMatter[field].push(\n\t\t\t\t\t\t\t\t\t\t\t\t\tarrayNode\n\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\tfrontMatter[field] = item.fields[field];\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif (contentSettings.isHeadless) {\n\t\t\t\t\tfrontMatter.headless = true;\n\t\t\t\t\tmkdirp.sync(`.${contentSettings.directory + item.sys.id}`);\n\t\t\t\t}\n\t\t\t\tfrontMatter.updated = item.sys.updatedAt;\n\t\t\t\tfrontMatter.createdAt = item.sys.createdAt;\n\t\t\t\tfrontMatter.date = item.sys.createdAt;\n\t\t\t\tfor (const field of Object.keys(item.fields)) {\n\t\t\t\t\tif (field === contentSettings.mainContent) {\n\t\t\t\t\t\t// skips to prevent duplicating mainContent in frontmatter\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t} else if (field === 'date') {\n\t\t\t\t\t\t// convert dates with time to ISO String so Hugo can properly Parse\n\t\t\t\t\t\tconst d = item.fields[field];\n\t\t\t\t\t\tif (d.length > 10) {\n\t\t\t\t\t\t\tfrontMatter.date = new Date(d).toISOString();\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tfrontMatter.date = d;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tconst fieldContent = item.fields[field];\n\t\t\t\t\tswitch (typeof fieldContent) {\n\t\t\t\t\t\tcase 'object':\n\t\t\t\t\t\t\tif ('sys' in fieldContent) {\n\t\t\t\t\t\t\t\tfrontMatter[field] = {};\n\t\t\t\t\t\t\t\tswitch (fieldContent.sys.type) {\n\t\t\t\t\t\t\t\t\tcase 'Asset':\n\t\t\t\t\t\t\t\t\t\tfrontMatter[field] = getAssetFields(\n\t\t\t\t\t\t\t\t\t\t\tfieldContent\n\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\tcase 'Entry':\n\t\t\t\t\t\t\t\t\t\tfrontMatter[field] = getEntryFields(\n\t\t\t\t\t\t\t\t\t\t\tfieldContent\n\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\t\t\tfrontMatter[field] = fieldContent;\n\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// rich text (see rich text function)\n\t\t\t\t\t\t\telse if ('nodeType' in fieldContent) {\n\t\t\t\t\t\t\t\tfrontMatter[field] = [];\n\t\t\t\t\t\t\t\tfrontMatter[\n\t\t\t\t\t\t\t\t\t`${field}_plaintext`\n\t\t\t\t\t\t\t\t] = richTextToPlain(fieldContent);\n\t\t\t\t\t\t\t\tconst nodes = fieldContent.content;\n\t\t\t\t\t\t\t\tfor (let i = 0; i < nodes.length; i++) {\n\t\t\t\t\t\t\t\t\tfrontMatter[field].push(\n\t\t\t\t\t\t\t\t\t\trichTextNodes(nodes[i])\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// arrays\n\t\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\tif (!fieldContent.length) {\n\t\t\t\t\t\t\t\t\tfrontMatter[field] = fieldContent;\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\tfrontMatter[field] = [];\n\t\t\t\t\t\t\t\t\tfor (\n\t\t\t\t\t\t\t\t\t\tlet i = 0;\n\t\t\t\t\t\t\t\t\t\ti < fieldContent.length;\n\t\t\t\t\t\t\t\t\t\ti++\n\t\t\t\t\t\t\t\t\t) {\n\t\t\t\t\t\t\t\t\t\tconst arrayNode = fieldContent[i];\n\t\t\t\t\t\t\t\t\t\tswitch (typeof arrayNode) {\n\t\t\t\t\t\t\t\t\t\t\tcase 'object': {\n\t\t\t\t\t\t\t\t\t\t\t\tlet arrayObject = {};\n\t\t\t\t\t\t\t\t\t\t\t\tswitch (arrayNode.sys.type) {\n\t\t\t\t\t\t\t\t\t\t\t\t\tcase 'Asset':\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tarrayObject = getAssetFields(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tarrayNode\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tfrontMatter[field].push(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tarrayObject\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\t\t\tcase 'Entry':\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tarrayObject = getEntryFields(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tarrayNode\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tfrontMatter[field].push(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tarrayObject\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tfrontMatter[field].push(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tarrayNode\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\t\t\t\t\tfrontMatter[field].push(\n\t\t\t\t\t\t\t\t\t\t\t\t\tarrayNode\n\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\tfrontMatter[field] = item.fields[field];\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tlet mainContent = null;\n\t\t\t\tif (item.fields[contentSettings.mainContent]) {\n\t\t\t\t\tmainContent = `${item.fields[contentSettings.mainContent]}`;\n\t\t\t\t}\n\n\t\t\t\tcreateFile(\n\t\t\t\t\tcontentSettings,\n\t\t\t\t\titem.sys.id,\n\t\t\t\t\tfrontMatter,\n\t\t\t\t\tmainContent\n\t\t\t\t);\n\t\t\t\titemCount++;\n\t\t\t}\n\n\t\t\t// check total number of items against number of items pulled in API\n\t\t\tif (data.total > data.limit) {\n\t\t\t\t// run function again if there are still more items to get\n\t\t\t\tconst newSkip = skip + limit;\n\t\t\t\tgetContentType(limit, newSkip, contentSettings, itemCount);\n\t\t\t} else {\n\t\t\t\tlet grammarStuff;\n\t\t\t\tif (Number(data.total) === 1) {\n\t\t\t\t\tgrammarStuff = 'item';\n\t\t\t\t} else {\n\t\t\t\t\tgrammarStuff = 'items';\n\t\t\t\t}\n\t\t\t\tconsole.log(\n\t\t\t\t\t` ${contentSettings.typeId} - ${itemCount} ${grammarStuff}`\n\t\t\t\t);\n\t\t\t\ttypesExtracted++;\n\t\t\t\tif (checkIfFinished(typesExtracted, totalContentTypes)) {\n\t\t\t\t\tconsole.log(\n\t\t\t\t\t\t`\\n---------------------------------------------\\n`\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t}\n\t\t})\n\t\t.catch(error => {\n\t\t\tconst response = error.response;\n\t\t\tif (response) {\n\t\t\t\tconsole.log(\n\t\t\t\t\t` --------------------------\\n ${contentSettings.typeId} - ERROR ${response.status} ${response.statusText}\\n (Note: ${response.data.message})\\n --------------------------`\n\t\t\t\t);\n\t\t\t} else {\n\t\t\t\tconsole.log(error);\n\t\t\t}\n\t\t});\n}", "function gotContent(data) {\n\n //Require pageID\n let page = data.query.pages;\n let pageId = Object.keys(data.query.pages)[0];\n \n //Correct if error found\n if (pageId < 0 || page[pageId].revisions === undefined){ \n restart();\n }\n let content = page[pageId].revisions[0]['*'];\n\n //Find a word >4 letters\n let wordRegex = /\\b\\w{4,7}\\b/g;\n content.match(wordRegex);\n let word = random((content.match(wordRegex)));\n\n goWiki(word);\n}", "function onPublishChange(e) {\r\n const btnKey = e.target.dataset.buttonkey;\r\n let newFilters = Object.assign({}, filters);\r\n if (btnKey === 'all') {\r\n delete newFilters.isPublished;\r\n } else {\r\n newFilters.isPublished = btnKey === 'published' ? true : false;\r\n }\r\n setFilters(newFilters);\r\n }", "onActiveMessagesLoaded(aFolderDisplay) {\n let filterer = this.maybeActiveFilterer;\n if (!filterer) {\n return;\n }\n\n let filtering = aFolderDisplay.view.search.userTerms != null;\n\n // - postFilterProcess everyone who cares\n // This may need to be converted into an asynchronous process at some point.\n for (let filterDef of QuickFilterManager.filterDefs) {\n if (\"postFilterProcess\" in filterDef) {\n let preState =\n filterDef.name in filterer.filterValues\n ? filterer.filterValues[filterDef.name]\n : null;\n let [newState, update, treatAsUserAction] = filterDef.postFilterProcess(\n preState,\n aFolderDisplay.view,\n filtering\n );\n filterer.setFilterValue(filterDef.name, newState, !treatAsUserAction);\n if (update) {\n if (\n aFolderDisplay._tabInfo == this.tabmail.currentTabInfo &&\n \"reflectInDOM\" in filterDef\n ) {\n let domNode = document.getElementById(filterDef.domId);\n // We are passing update as a super-secret data propagation channel\n // exclusively for one-off cases like the text filter gloda upsell.\n filterDef.reflectInDOM(domNode, newState, document, this, update);\n }\n }\n }\n }\n\n // - Update match status.\n this.reflectFiltererResults(filterer, aFolderDisplay);\n }", "function filterPosts(post) {\n let valid = true;\n\n // Exclude posts with no message\n if (!post.message) {\n valid = false;\n }\n\n // Exclude posts updating cover photos\n if (post.story && post.story.includes('cover photo')) {\n valid = false;\n }\n\n return valid;\n }", "function checkQuery( itcb ) {\n if( args.query ) {\n\n // map form mapped fields back to schema fields\n if( args.query.editorName ) {\n args.query['editor.name'] = args.query.editorName;\n delete args.query.editorName;\n }\n if( args.query.editorInitials ) {\n args.query['editor.initials'] = args.query.editorInitials;\n delete args.query.editorInitials;\n }\n\n // there are other properties that can also filter \"timestamp\"\n if( args.query.$or && Array.isArray( args.query.$or ) ) {\n // rename \"quarterColumn\" property to \"timestamp\"\n args.query.$or.forEach( function( or ) {\n if( or.quarterColumn ) {\n or.timestamp = or.quarterColumn;\n delete or.quarterColumn;\n }\n } );\n // also apply original \"timestamp\" to \"$or\"\n if( args.query.timestamp ) {\n args.query.$or.push( {timestamp: args.query.timestamp} );\n delete args.query.timestamp;\n }\n }\n\n /**\n * [MOJ-11908]\n * Whenever a regex filter against the activity's content is queried, we intercept it.\n * This makes it possible to search the content for the so-called \"badges\" (bootstrap-labels),\n * which are rendered, if specific properties of an activity are set to true/false, or to\n * specific values (mainly ENUMs)\n * E.g. activity.phContinuousMed = true renders a badge with the abbreviation \"DM\" (in german),\n * which means \"DauerMedikament\".\n *\n * Since the user sees these patches within the content, he assumes, that one may search for the\n * label's content. In the example, this would be \"DM\".\n * So we have to be able to filter the properties in the database accordingly,\n * although the activity.content has NO knowledge of the \"DM\".\n *\n * Here, this is done by analyzing the query sent by the user,\n * and search for these abbreviations. If found, the query is altered on-the-fly,\n * to include a search for the requested parameters.\n */\n if( args.query.content && args.query.content.$regex ) {\n let CONTINUOUS_MEDICATION = i18n( 'InCaseMojit.activity_schema.CONTINUOUS_MEDICATION' ),\n SAMPLE_MEDICATION = i18n( 'InCaseMojit.activity_schema.SAMPLE_MEDICATION' ),\n ACUTE_DOK = i18n( 'InCaseMojit.activity_schema.diagnose_type.ACUTE_DOK' ),\n ACUTE_INVALIDATING = i18n( 'InCaseMojit.activity_schema.diagnose_type.ACUTE_INVALIDATING' ),\n CONT_DIAGNOSES = i18n( 'InCaseMojit.activity_schema.diagnose_type.CONT_DIAGNOSES' ),\n CONT_DIAGNOSES_DOK = i18n( 'InCaseMojit.activity_schema.diagnose_type.CONT_DIAGNOSES_DOK' ),\n CONT_DIAGNOSES_INVALIDATING = i18n( 'InCaseMojit.activity_schema.diagnose_type.CONT_DIAGNOSES_INVALIDATING' ),\n A_CONT_DIAGNOSES = i18n( 'InCaseMojit.activity_schema.diagnose_type.A_CONT_DIAGNOSES' ),\n A_CONT_DIAGNOSES_DOK = i18n( 'InCaseMojit.activity_schema.diagnose_type.A_CONT_DIAGNOSES_DOK' ),\n A_CONT_DIAGNOSES_INVALIDATING = i18n( 'InCaseMojit.activity_schema.diagnose_type.A_CONT_DIAGNOSES_INVALIDATING' ),\n EXPENSES = i18n( 'InCaseMojit.casefile_detail.group.EXPENSES' ),\n\n /**\n * An activity may provide multiple parameters, which are set to true/false,\n * or a given set of parameters. Depending on this state, a badge (bootstrap-label)\n * is displayed in the content, which shows an abbreviation, according to this state.\n * So the user sees this label, and tries to search for it, by typing the abbreviation.\n *\n * This array defines an object for each searchable property (which has a corresponding badge).\n * {\n * searchTag : abbreviation displayed in the label,\n * searchCondition: database parameters to be searched for\n * }\n * @type {Array}\n */\n propertiesToSearchFor = [\n {\n searchTag: CONTINUOUS_MEDICATION,\n searchCondition: {phContinuousMed: true}\n },\n {\n searchTag: SAMPLE_MEDICATION,\n searchCondition: {phSampleMed: true}\n },\n {\n searchTag: ACUTE_DOK,\n searchCondition: {\n diagnosisType: 'ACUTE',\n diagnosisTreatmentRelevance: 'DOKUMENTATIV'\n }\n },\n {\n searchTag: ACUTE_INVALIDATING,\n searchCondition: {\n diagnosisType: 'ACUTE',\n diagnosisTreatmentRelevance: 'INVALIDATING'\n }\n },\n {\n searchTag: CONT_DIAGNOSES,\n searchCondition: {\n diagnosisType: 'CONTINUOUS',\n diagnosisTreatmentRelevance: 'TREATMENT_RELEVANT'\n }\n },\n {\n searchTag: CONT_DIAGNOSES_DOK,\n searchCondition: {\n diagnosisType: 'CONTINUOUS',\n diagnosisTreatmentRelevance: 'DOKUMENTATIV'\n }\n },\n {\n searchTag: CONT_DIAGNOSES_INVALIDATING,\n searchCondition: {\n diagnosisType: 'CONTINUOUS',\n diagnosisTreatmentRelevance: 'INVALIDATING'\n }\n },\n {\n searchTag: A_CONT_DIAGNOSES,\n searchCondition: {\n diagnosisType: 'ANAMNESTIC',\n diagnosisTreatmentRelevance: 'TREATMENT_RELEVANT'\n }\n },\n {\n searchTag: A_CONT_DIAGNOSES_DOK,\n searchCondition: {\n diagnosisType: 'ANAMNESTIC',\n diagnosisTreatmentRelevance: 'DOKUMENTATIV'\n }\n },\n {\n searchTag: A_CONT_DIAGNOSES_INVALIDATING,\n searchCondition: {\n diagnosisType: 'ANAMNESTIC',\n diagnosisTreatmentRelevance: 'INVALIDATING'\n }\n },\n {\n searchTag: EXPENSES,\n searchCondition: {\n $and: [\n {costType: {$exists: true}},\n {costType: {$type: \"string\"}},\n {costType: {$ne: \"\"}}\n ]\n }\n },\n {\n searchTag: 'email',\n searchCondition: {savedEmails: {$exists: true}}\n\n }\n\n ],\n\n // extract the query's regex source\n queryRegexSource = (args.query.content.$regex.source || ''),\n queryRegexFlags = (args.query.content.$regex.flags || 'i');\n\n /**\n * We start, by examining the search query (which is actually a regex itself), for the occurrence of\n * the searchTags of the properties. So we filter out all occurrences, for which we have to\n * take care about. Notice: the query may additionally be limited to the beginning\n * or the end of the string, \"^\" or \"$\", respectively.\n * Examples for this regex:\n * - \"DM\", \"^DM\", \"DM$\": single occurrences\n * To search all continuous medications (DM).\n * - \"DM ExampleMedication\", \"DM ExampleMedication\", \"^DM ExampleMedication$\"\n * To search for all continuous medications (DM), and additionally those of type \"ExampleMedication\".\n * - \"DM MM\", \"^DM MM\", \"DM MM$\": multiple occurrences\n * To search for all continuous (DM) and sample medications (MM). Should generally not happen.\n */\n propertiesToSearchFor = propertiesToSearchFor\n .filter( propertyToSearch => {\n // Create multiple RegExp from the property's search tag, and match each\n // against the query. Each RegExp covers the cases explained above.\n let // watch out, the searchTag itself is escaped for regex characters\n // => this requires us to double-escape all regex-characters in our search tag,\n // to obtain a match on those (e.g. search for \"DD.d\", query is \"DD\\.d\", so we create a regex with \"DD\\\\\\.d\")\n escapedSearchTag = Y.doccirrus.commonutils.$regexEscape( Y.doccirrus.commonutils.$regexEscape( propertyToSearch.searchTag ) ),\n // get a collection of all tests to run on the user's query regex\n regexTests = [\n // match the occurrence of the searchTag at the beginning of the query\n new RegExp( \"^\\\\^?\" + escapedSearchTag + \"\\\\s\", \"gi\" ),\n\n // match the occurrence of the searchTag in the middle of the query\n new RegExp( \"\\\\s\" + escapedSearchTag + \"(\\\\s)\", \"gi\" ), // the capture group is intended here!\n\n // match the occurrence of the searchTag at the end of the query\n new RegExp( \"\\\\s\" + escapedSearchTag + \"\\\\$?$\", \"gi\" ),\n\n // match the occurrence of the searchTag as the only content of the query\n new RegExp( \"^\\\\^?\" + escapedSearchTag + \"\\\\$?$\", \"gi\" )\n ],\n tagFound = false,\n tagFoundCallback = ( match, spaceCaptureGroup ) => {\n /**\n * If yes, this function is invoked.\n * Here, we remove the occurrence of the tag from the regex string,\n * and mark the tag as found.\n * E.g.:\n * \"DD Test-Diagnosis XYZ\" => \"Test-Diagnosis XYZ\"\n *\n * NOTICE:\n * We explicitly proceed with other regex tests from the array,\n * to catch multiple occurrences of the same tag in the different positions,\n * and to properly remove these occurrences.\n * This may be caused by the user entering the tag twice,\n * e.g. \"DM test medication DM\", and him still expecting a result.\n * @type {boolean}\n */\n tagFound = true;\n\n /**\n * Replace every tag by an empty string, with one exception:\n * In case of a positioning of the tag within the string,\n * we have to keep a space, to avoid merging words.\n */\n return (typeof spaceCaptureGroup === \"string\") ? spaceCaptureGroup : '';\n };\n\n for( let regexTest of regexTests ) { //eslint-disable-line no-unused-vars\n // see, if there is a match of the query's regex source with the test regex\n queryRegexSource = queryRegexSource.replace( regexTest, tagFoundCallback );\n }\n\n // if no tag of this type was found, exclude the tag from further treatment\n return tagFound;\n } );\n\n /**\n * Now, that we have all relevant properties, and that we have cleaned the query's regex source\n * from these properties, we may map the matching properties into the query as new conditions ($and).\n */\n if( propertiesToSearchFor.length > 0 ) {\n\n // Create the new search Regex for the content, which has been cleaned from all matched tags.\n args.query.content.$regex = new RegExp( queryRegexSource, queryRegexFlags );\n\n // Ensure, that there is an $and defined ...\n if( !args.query.$and ) {\n args.query.$and = [];\n }\n // ... and that it is an array.\n if( Array.isArray( args.query.$and ) ) {\n // move the former \"content\"-query out of the original query, and into the $and.\n args.query.$and.push( {content: args.query.content} );\n delete args.query.content;\n\n // finally, map the all search conditions into the $and\n propertiesToSearchFor.map( propertyToSearch => args.query.$and.push( propertyToSearch.searchCondition ) );\n }\n }\n }\n\n }\n if( caseFileDoctorSelectFilter ) {\n args.query = {$and: [caseFileDoctorSelectFilter, args.query]};\n }\n itcb( null );\n }", "function removeUnpublishedContent() {\n $_node.getUnpublishedNodes(function (data) {\n for(i in data){\n var nid = data[i].nid;\n var _v_item = $('#media_'+nid);\n if(_v_item.length > 0)\n {\n _v_item.remove();\n }\n }\n });\n}", "function previewContent(content, article){\n\n var regex = new RegExp(article.sourceName, 'g', 'i')\n var redactedContent = content.replace(regex, \"[REDACTED BY YOURAGORA]\")\n\n if(redactedContent.includes(\"<p>\")){\n if(redactedContent.match(/<p>/g).length > 2){\n var fixedContent = redactedContent.replace(/(<img)(.*?)(>)/g, '')\n var pattern = /(<p>)(.*?)(<\\/p>)/g\n // TODO: Can we loop this more elegantly?\n var par1 = pattern.exec(fixedContent)[0]\n var par2 = pattern.exec(fixedContent)[0]\n var par3 = pattern.exec(fixedContent)[0]\n var par4 = pattern.exec(fixedContent)[0]\n return [par1, par2, par3, par4].join(\" \")\n } else {\n return '';}\n } else {\n return ''\n }\n\n}", "evaluateContent(content, cb, opts={}) {\n this.session.post({\n url: this.url + '/api/filter',\n json: Object.assign({ source_text: content }, opts),\n }, cb);\n }", "runArchivedFilter(state, cards) {\n if (state.showArchived) {\n state.filteredCards.push(cards.filter(card => card.archived))\n } else {\n state.filteredCards.push(cards.filter(card => !card.archived))\n }\n }", "function filterAuthors(data, queued) {\n // filter map_data with docs just in our selected journals\n selected_authors = selected_authors.concat($(\"select#author-list\").val());\n if(selected_authors.length == 0) {\n $(\"#author-filter i\").show();\n $(\"#filter-list h2.author\").html(\"Selected Authors <a onclick='clearAuthorFilters();'>clear</a>\");\n return data;\n } else {\n $(\"#author-filter i\").hide();\n $(\"#filter-list h2.author\").html(\"Selected Authors (\" + selected_authors.length + \") <a onclick='clearAuthorFilters();'>clear</a>\");\n }\n var entity_list = [];\n var documents = $.grep(data.documents, function(n, i) {\n if($.inArray(n.authorid+\"\", selected_authors) > -1) {\n if($.inArray(n.entityid+\"\", entity_list) == -1) {\n entity_list.push(n.entityid);\n }\n return true;\n }\n return false;\n });\n // filter links such that both documents are in selected journals\n var entities = getEntityList(documents);\n var new_data = {\"documents\":documents, \"entities\":entities};\n // remove selected journals from our select list\n for(var i=0; i<selected_authors.length; i++) {\n $(\"#author-list option[value='\" + selected_authors[i] + \"']\").remove();\n }\n\n if(queued) return new_data; // filter only and apply filters externally\n update(new_data); // update the database\n}", "function controlContentList(type){\n\n if(type == \"People\"){\n if(people.results.length) constructProfileList(people);\n }\n else{\n switch(type){\n case \"TV Shows\": if(tv.results.length) constructContentList(tv, \"tv\"); break;\n case \"Movies\": if(movies.results.length) constructContentList(movies, \"movie\"); break;\n case \"Collections\": if(collections.results.length) constructContentList(collections); break;\n }\n }\n\n if(currentList.total_pages > 1) updatePageNumbers();\n}", "function isDraft(value) {\n return !!value && !!value[DRAFT_STATE];\n}", "function editor_filterOutput(objname) {\r\n editor_updateOutput(objname);\r\n var contents = document.all[objname].value;\r\n var config = document.all[objname].config;\r\n\r\n // ignore blank contents\r\n if (contents.toLowerCase() == '<p>&nbsp;</p>') { contents = \"\"; }\r\n\r\n // filter tag - this code is run for each HTML tag matched\r\n var filterTag = function(tagBody,tagName,tagAttr) {\r\n tagName = tagName.toLowerCase();\r\n var closingTag = (tagBody.match(/^<\\//)) ? true : false;\r\n\r\n // fix placeholder URLS - remove absolute paths that IE adds\r\n if (tagName == 'img') { tagBody = tagBody.replace(/(src\\s*=\\s*.)[^*]*(\\*\\*\\*)/, \"$1$2\"); }\r\n if (tagName == 'a') { tagBody = tagBody.replace(/(href\\s*=\\s*.)[^*]*(\\*\\*\\*)/, \"$1$2\"); }\r\n\r\n // add additional tag filtering here\r\n\r\n // convert to vbCode\r\n// if (tagName == 'b' || tagName == 'strong') {\r\n// if (closingTag) { tagBody = \"[/b]\"; } else { tagBody = \"[b]\"; }\r\n// }\r\n// else if (tagName == 'i' || tagName == 'em') {\r\n// if (closingTag) { tagBody = \"[/i]\"; } else { tagBody = \"[i]\"; }\r\n// }\r\n// else if (tagName == 'u') {\r\n// if (closingTag) { tagBody = \"[/u]\"; } else { tagBody = \"[u]\"; }\r\n// }\r\n// else {\r\n// tagBody = \"\"; // disallow all other tags!\r\n// }\r\n\r\n return tagBody;\r\n };\r\n\r\n // match tags and call filterTag\r\n RegExp.lastIndex = 0;\r\n var matchTag = /<\\/?(\\w+)((?:[^'\">]*|'[^']*'|\"[^\"]*\")*)>/g; // this will match tags, but still doesn't handle container tags (textarea, comments, etc)\r\n\r\n contents = contents.replace(matchTag, filterTag);\r\n\r\n // remove nextlines from output (if requested)\r\n if (config.replaceNextlines) { \r\n contents = contents.replace(/\\r\\n/g, ' ');\r\n contents = contents.replace(/\\n/g, ' ');\r\n contents = contents.replace(/\\r/g, ' ');\r\n }\r\n\r\n // update output with filtered content\r\n document.all[objname].value = contents;\r\n\r\n}", "function editDraft_process() {\n $('body').on('click', '[data-action=\"edit_draft\"]', function(e) {\n if (e) {\n e.preventDefault();\n }\n var $object = $(this);\n\n if ($object.data('type') == \"question\") {\n $.post('/question/' + $object.data('id'), {\n }, function (results) {\n // clear content\n navbar_ask_clear_input();\n // switch to ask mode\n _question_modal_UISwitch('ask');\n // set results to the input\n navbar_question_json_set(results);\n // show asking new question option\n navbar_show_ask_new_question_option();\n // show search box\n $('#_question').modal('show');\n });\n }\n });\n}", "function getMetadata(path) {\n var passageContainer = document.getElementById(\"app\");\n var jsondata;\n fetch(path)\n .then(\n function (u) { return u.json(); }\n )\n .then(\n function (json) {\n var jsondata = json;\n for (var i = Object.keys(jsondata.title).length; i--; i >= 0) {\n // for each entry in jsondata, add div and information from \"data.json\"\n var div = document.createElement(\"div\");\n div.setAttribute(\"id\", \"div_\" + (i));\n div.innerHTML = (`${compareYear(jsondata[\"year\"][i], year0)}<p class=\"show-pub ${checkIfEmptyValue(\"\", jsondata[\"type\"][i], \"\")} ${checkIfEmptyValue(\"\", jsondata[\"community\"][i], \"\")}\">${checkIfEmptyValue(\"<span class='authors'>\", jsondata[\"co-author(s)\"][i], \"</span>: \")}<span class=\"title\"><a href=\"${jsondata[\"link to publication\"][i]}\">${jsondata[\"title\"][i]}</a></span>${checkIfEmptyValue(\", in <span class='publisher'>\", jsondata[\"publisher (e.g. journal/blog name)\"][i], \"</span>\")}. ${checkIfEmptyValue(`<span class='hashtag hashtag-${jsondata[\"type\"][i]} inactive light-mode'>`, jsondata[\"type\"][i], \"</span>\")} ${checkIfEmptyValue(`<span class='hashtag hashtag-${jsondata[\"community\"][i]} inactive light-mode'>`, jsondata[\"community\"][i], \"</span>\")}</p>`);\n passageContainer.appendChild(div);\n var year0 = jsondata[\"year\"][i];\n //enable filtering by hashtag\n document.querySelectorAll('span.hashtag').forEach((x) => {\n x.addEventListener('click', filterByHashtag);\n })\n // add functionality to lightswitch\n const lightSwitch = document.getElementById('flexSwitchCheckDefault');\n lightSwitch.addEventListener('change', e => {\n if(e.target.checked === true) {\n console.log(\"Checkbox is checked - boolean value: \", e.target.checked);\n changeToDarkMode();\n }\n if(e.target.checked === false) {\n console.log(\"Checkbox is not checked - boolean value: \", e.target.checked);\n changeToLightMode();\n }\n });\n };\n }\n );\n return jsondata;\n}", "function loadPostIfEdit(){\n let id = Quas.getUrlValues()[\"p\"];\n if(id === undefined) return false;\n Quas.ajax({\n url : \"/php/post-edit-open.php\",\n type : \"POST\",\n data : {\n id : id,\n sid : getCookie(\"session\"),\n },\n return : \"json\",\n success : function(res){\n if(res.constructor == String) return;\n let data = res[0];\n Toolbar.postID = id\n Quas.getEl(\"#post-editor-title\").val(Quas.decodeHtmlSpecialChars(data.title));\n Quas.getEl(\"#post-editor\").val(Quas.decodeHtmlSpecialChars(data.text));\n if(data.published > 0){\n let pt = new Date(data.publish_time);\n //already published\n if(Date.now() > pt.getTime()){\n Quas.getEl(\".publish-time-btn\").visible(false);\n }\n //published but scheduled for the future\n else{\n Toolbar.curTime = pt;\n setTimeString();\n }\n Toolbar.alreadyPublished();\n }\n lazyLoader();\n }\n });\n return true;\n}", "function filterPublications( e ) {\n\n var filter = searchfield.value;\n var regex = filterValueToRegex( filter );\n var nrVisibleItems = 0;\n\n for (var i = 0, len = index.length; i < len; i++) {\n\n var item = index[i];\n var itemMatchesFilter = item.content.match( regex );\n\n if( itemMatchesFilter && !item.visible ) {\n\n item.element.classList.remove('hidden');\n index[i].visible = true;\n }\n else if( !itemMatchesFilter && item.visible ) {\n\n item.element.classList.add('hidden');\n index[i].visible = false;\n }\n\n if( item.visible ) nrVisibleItems++;\n }\n\n countField.innerHTML = nrVisibleItems;\n}", "function Content() {\n async function fetchContentTypes() {\n const types = await client.getContentTypes();\n if (types.items) return types.items;\n console.log(\"Error getting Content Types.\");\n }\n async function fetchEntriesForContentType(contentType) {\n const entries = await client.getEntries({\n content_type: contentType.sys.id\n });\n if (entries.items) return entries.items;\n console.log(`Error getting Entries for ${contentType.name}.`);\n }\n const [projects, setProjects] = useState([]);\n // use above async functions to retreive content on initial load\n useEffect(() => {\n async function getProjects() {\n const contentTypes = await fetchContentTypes();\n const allProjects = await fetchEntriesForContentType(contentTypes[0]);\n setProjects([...allProjects]);\n }\n getProjects();\n }, []);\n console.log(projects.map(p => p.fields));\n // when content is retreived, the fields are mapped over to be displayed by our component\n return (\n <StyledContent>\n <Showcase>\n <>\n {projects.length > 0\n ? projects.map(p => (\n <ProjectCard\n title={p.fields.title}\n // image has fields of it's own\n image={p.fields.image.fields.file.url}\n url={p.fields.url}\n />\n ))\n : null}\n </>\n </Showcase>\n </StyledContent>\n );\n}", "function _filterItem(article, list) {\n\t\tvar styles = {};\n\t\t$helpers.propagateMobileExt(styles, article);\n\t\tarticle = _scanObj(article, function(o) {\n\t\t\tif (o.$bind === \"$resources\") {\n\t\t\t\t// only for $query || $facet\n\t\t\t\tvar cards = _cardsLayout(o, true);\n\t\t\t\t$helpers.propagateMobileExt(cards, styles);\n\t\t\t\treturn cards;\n\t\t\t}\n\t\t\t$helpers.propagateMobileExt(styles, o);\n\t\t\treturn null;\n\t\t});\n\t\treturn article;\n\t}", "function filterByContent(orgPlanList) {\n return _.filter(orgPlanList, function(event) {\n return (!_.isEmpty(event.title) && !_.isEmpty(event.image));\n });\n}", "isInitialContent() {\n return get(this, '_isInitialContent');\n }", "async function setActivityContent( itcb ) {\n // for prescriptions, we presume that the content is\n // already correct because we do not want to reload the\n // attachments.\n if(\n !hasCustomUserContent &&\n activity &&\n activity.patientId &&\n (actType === 'PUBPRESCR' ||\n actType === 'PRIVPRESCR' ||\n actType === 'LONGPRESCR' ||\n actType === 'PRESCRBTM' ||\n actType === 'PRESCRG' ||\n actType === 'PRESCRT' ||\n actType === 'PRESASSISTIVE' ||\n actType === 'MEDICATION')\n ) {\n //EXTMOJ-2118 - get medications for patient and calculate medication range\n let [err, response] = await formatPromiseResult(\n Y.doccirrus.mongodb.runDb( {\n user: user,\n model: 'activity',\n query: {\n isPrescribed: true,\n actType: 'MEDICATION',\n patientId: activity.patientId,\n status: {$nin: ['CANCELLED']}\n },\n options: {lean: true},\n sort: {timestamp: -1}\n } )\n );\n if( err ) {\n Y.log( `Could not get prescribed medications from Patient: ${err.stack || err}`, 'warn', NAME );\n }\n\n let elements = [];\n if( activity.attachments && activity.attachments.length && activity.formVersion ) {\n let documents;\n [err, documents] = await formatPromiseResult(\n Y.doccirrus.mongodb.runDb( {\n user,\n model: 'document',\n query: {\n _id: {$in: activity.attachments}\n },\n options: {\n lean: true,\n select: {\n formState: 1\n }\n }\n } )\n );\n if( err ) {\n Y.log( `setActivityContent: Could not get document for activity ${activity._id}: ${err.stack || err}`, 'warn', NAME );\n }\n\n if( documents && documents[0] && documents[0].formState ) {\n let formversions;\n [err, formversions] = await formatPromiseResult(\n Y.doccirrus.mongodb.runDb( {\n user,\n model: 'formtemplateversion',\n query: {\n _id: activity.formVersion\n },\n options: {\n lean: true,\n select: {\n 'jsonTemplate.pages.elements': 1\n }\n }\n } )\n );\n if( err ) {\n Y.log( `setActivityContent: Could not get formVersion for activity ${activity._id}: ${err.stack || err}`, 'warn', NAME );\n }\n\n let jsonTemplate = (formversions && formversions[0] || {}).jsonTemplate || {};\n\n (jsonTemplate.pages || []).map( page => {\n let lookedElements = (page.elements || []).filter(\n el => (['exactMed1', 'exactMed2', 'exactMed3'].includes( el.schemaMember )) ).map(\n el => ({\n id: el.id,\n schemaMember: el.schemaMember\n })\n );\n elements = [...elements, ...lookedElements];\n } );\n\n elements.forEach( el => {\n el.value = documents[0].formState[el.id] === '[3mm]*';\n switch( el.schemaMember ) {\n case 'exactMed1':\n el.idx = 1;\n el.medication = documents[0].formState.med1;\n break;\n case 'exactMed2':\n el.idx = 2;\n el.medication = documents[0].formState.med2;\n break;\n case 'exactMed3':\n el.idx = 3;\n el.medication = documents[0].formState.med3;\n break;\n }\n return el;\n } );\n }\n }\n\n newContent = Y.doccirrus.schemas.activity.generateContent(\n activity,\n {\n _activitiesObj: _activitiesObj || activity._activitiesObj,\n medicationsForPatient: response || [],\n formElements: elements\n }\n );\n activity.content = newContent;\n } else if(\n // if there is custom content for prescriptions we skip the (default) hardcoded routine and use the\n // template supplied by the user\n !hasCustomUserContent &&\n actType !== 'PUBPRESCR' &&\n actType !== 'PRIVPRESCR' &&\n actType !== 'LONGPRESCR' &&\n actType !== 'PRESCRBTM' &&\n actType !== 'PRESCRG' &&\n actType !== 'PRESCRT' &&\n actType !== 'PRESASSISTIVE' ||\n _activitiesObj\n ) {\n newContent = Y.doccirrus.schemas.activity.generateContent( activity, {_activitiesObj} );\n if( actType === 'TELECONSULT' ) {\n activity.userContent = newContent;\n activity.content = '';\n } else {\n if (activity.actType === 'INVOICEREFPVS') {\n if (!(activity.content && activity.content.includes(newContent))) {\n activity.content = newContent;\n }\n\n } else {\n activity.content = newContent;\n }\n }\n\n } else if( activity.noOfRepetitions && activity.content && activity.parentPrescriptionId ) {\n let\n // [MOJ-12027] switched to repeatString-generator function\n repeatString = Y.doccirrus.schemas.activity.actTypeRepeatString( actType ),\n\n // stripe an old repeatString from the existing content, and append the new\n textToReplace = '<br/>' + repeatString;\n\n if( -1 === activity.content.indexOf( textToReplace ) ) {\n textToReplace = repeatString;\n }\n newContent = activity.content.slice( 0, activity.content.indexOf( textToReplace ) ) + '<br/>' + repeatString + ' (' + activity.noOfRepetitions + ')';\n activity.content = newContent;\n }\n itcb( null );\n }", "function customHTML2Content(HTML, contentState) {\n var tempDoc = new DOMParser().parseFromString(HTML, 'text/html');\n // replace all <img /> with <blockquote /> elements\n lodash_toArray__WEBPACK_IMPORTED_MODULE_1___default()(tempDoc.querySelectorAll('img')).forEach(imgReplacer);\n // use DraftJS converter to do initial conversion. I don't provide DOMBuilder and\n // blockRenderMap arguments here since it should fall back to its default ones, which are fine\n\n var _convertFromHTML = Object(draft_js__WEBPACK_IMPORTED_MODULE_0__[\"convertFromHTML\"])(tempDoc.body.innerHTML),\n contentBlocks = _convertFromHTML.contentBlocks;\n // now replace <blockquote /> ContentBlocks with 'atomic' ones\n\n\n contentBlocks = contentBlocks.reduce(function (contentBlocks, block) {\n if (block.getType() !== 'blockquote') {\n return contentBlocks.concat(block);\n }\n var image = JSON.parse(block.getText());\n contentState.createEntity('IMAGE-ENTITY', 'IMMUTABLE', image);\n var entityKey = contentState.getLastCreatedEntityKey();\n var charData = draft_js__WEBPACK_IMPORTED_MODULE_0__[\"CharacterMetadata\"].create({ entity: entityKey });\n // const blockSpec = Object.assign({ type: 'atomic', text: ' ' }, { entityData })\n // const atomicBlock = createContentBlock(blockSpec)\n // const spacerBlock = createContentBlock({});\n var fragmentArray = [new draft_js__WEBPACK_IMPORTED_MODULE_0__[\"ContentBlock\"]({\n key: Object(draft_js__WEBPACK_IMPORTED_MODULE_0__[\"genKey\"])(),\n type: 'image-block',\n text: ' ',\n characterList: Object(immutable__WEBPACK_IMPORTED_MODULE_2__[\"List\"])(Object(immutable__WEBPACK_IMPORTED_MODULE_2__[\"Repeat\"])(charData, charData.count()))\n }), new draft_js__WEBPACK_IMPORTED_MODULE_0__[\"ContentBlock\"]({\n key: Object(draft_js__WEBPACK_IMPORTED_MODULE_0__[\"genKey\"])(),\n type: 'unstyled',\n text: '',\n characterList: Object(immutable__WEBPACK_IMPORTED_MODULE_2__[\"List\"])()\n })];\n return contentBlocks.concat(fragmentArray);\n }, []);\n // console.log('>> customHTML2Content contentBlocks', contentBlocks);\n tempDoc = null;\n return draft_js__WEBPACK_IMPORTED_MODULE_0__[\"BlockMapBuilder\"].createFromArray(contentBlocks);\n}", "handleFilter(e) {\r\n e.preventDefault();\r\n let url = \"/endpoints/teams.json?teamname=\" + this.state.teamname + \"&type=\" + this.state.type + \"&org=\" + this.state.org;\r\n fetch(url)\r\n .then(response => {\r\n const contentType = response.headers.get(\"content-type\");\r\n if (contentType && contentType.indexOf(\"application/json\") !== -1) {\r\n return response.json()\r\n .then(response => this.setState({items: response.data}));\r\n }\r\n })\r\n }", "function getFrontmatterState() {\n const parts = content.trim().split('---').length;\n switch (parts) {\n case 1:\n return null;\n case 2:\n return 'open';\n default:\n return 'closed';\n }\n }", "function editDraft(draft) {\n\t\t\t$('#drafts').empty();\n\t\t\t$('#comment-text').val(draft);\n\t\t\tvar currentDrafts = getDrafts();\n\t\t\tvar updatedDrafts = [];\n\t\t\t$.each(currentDrafts, function(i, val) {\n\t\t\t\tif (val !== draft) {\n\t\t\t\t\tupdatedDrafts.push(val);\n\t\t\t\t}\n\t\t\t});\n\t\t\t\n\t\t\t// Updates the 'drafts' array with the current user's drafts in the private state object (wave)\n\t\t\twave.getPrivateState().submitDelta({'drafts': updatedDrafts});\n\t\t}", "fetchContent(sub, filter, search) {\n this.props.fetchList(\n `${sub}/${filter}`, \n search);\n }", "function noteFilter(obj) {\n return _.pick(obj, ['notebookId', 'title', 'content']);\n}", "function getDrafts() {\n\t\t\t// Gets an array of all drafts for the current user from the private state object (wave)\n\t\t\tvar draftsToRender = wave.getPrivateState().get('drafts') === null ? [] : wave.getPrivateState().get('drafts');\n\n\t\t\treturn draftsToRender;\n\t\t}", "function getContentType(limit, skip, contentSettings, itemsPulled) {\n let client = contentful.createClient({\n space: process.env.CONTENTFUL_SPACE,\n accessToken: process.env.CONTENTFUL_TOKEN,\n });\n\n // check for file extension default to markdown\n if (!contentSettings.fileExtension) {\n contentSettings.fileExtension = 'md';\n }\n\n client\n .getEntries({\n content_type: contentSettings.typeId,\n limit: limit,\n skip: skip,\n order: 'sys.updatedAt',\n })\n .then(data => {\n // variable for counting number of items pulled\n let itemCount;\n if (itemsPulled) {\n itemCount = itemsPulled;\n } else {\n itemCount = 0;\n }\n // create directory for file\n mkdirp.sync(`.${contentSettings.directory}`);\n\n for (let i = 0; i < data.items.length; i++) {\n let item = data.items[i];\n let fileContent = '';\n let frontMatter = {};\n if (\n contentSettings.fileExtension === 'md' ||\n contentSettings.fileExtension == null ||\n contentSettings.fileExtension == undefined\n ) {\n fileContent += `---\\n`;\n }\n if (contentSettings.isHeadless) {\n frontMatter.headless = true;\n mkdirp.sync(`.${contentSettings.directory + item.sys.id}`);\n }\n if (contentSettings.type) {\n frontMatter.type = contentSettings.type\n }\n frontMatter.updated = item.sys.updatedAt;\n frontMatter.createdAt = item.sys.createdAt;\n frontMatter.date = item.sys.createdAt;\n for (let field of Object.keys(item.fields)) {\n if (field === contentSettings.mainContent) {\n // skips to prevent duplicating mainContent in frontmatter\n continue;\n } else if(field === 'date') {\n // convert dates with time to ISO String so Hugo can properly Parse\n let d = item.fields[field]\n if(d.length > 10) {\n frontMatter.date = new Date(d).toISOString()\n } else {\n frontMatter.date = d\n }\n continue;\n }\n let fieldContent = item.fields[field];\n switch (typeof fieldContent) {\n case 'object':\n if ('sys' in fieldContent) {\n frontMatter[field] = {};\n switch (fieldContent.sys.type) {\n case 'Asset':\n frontMatter[field] = getAssetFields(\n fieldContent\n );\n break;\n case 'Entry':\n frontMatter[field] = getEntryFields(\n fieldContent\n );\n break;\n default:\n frontMatter[field] = fieldContent;\n break;\n }\n }\n // rich text (see rich text function)\n else if ('nodeType' in fieldContent) {\n frontMatter[field] = [];\n frontMatter[\n `${field}_plaintext`\n ] = richTextToPlain(fieldContent);\n let nodes = fieldContent.content;\n for (let i = 0; i < nodes.length; i++) {\n frontMatter[field].push(\n richTextNodes(nodes[i])\n );\n }\n }\n // arrays\n else {\n if (!fieldContent.length) {\n frontMatter[field] = fieldContent;\n } else {\n frontMatter[field] = [];\n for (\n let i = 0;\n i < fieldContent.length;\n i++\n ) {\n let arrayNode = fieldContent[i];\n switch (typeof arrayNode) {\n case 'object':\n let arrayObject = {};\n switch (arrayNode.sys.type) {\n case 'Asset':\n arrayObject = getAssetFields(\n arrayNode\n );\n frontMatter[field].push(\n arrayObject\n );\n break;\n case 'Entry':\n arrayObject = getEntryFields(\n arrayNode\n );\n frontMatter[field].push(\n arrayObject\n );\n break;\n default:\n frontMatter[field].push(\n arrayNode\n );\n break;\n }\n break;\n default:\n frontMatter[field].push(\n arrayNode\n );\n break;\n }\n }\n }\n }\n break;\n default:\n frontMatter[field] = item.fields[field];\n break;\n }\n }\n\n // add current item to filecontent\n fileContent += YAML.stringify(frontMatter);\n if (\n contentSettings.fileExtension != 'yaml' ||\n contentSettings.fileExtension != 'yml'\n ) {\n fileContent += `---\\n`;\n }\n\n // if set add the main content below the front matter\n if (item.fields[contentSettings.mainContent]) {\n fileContent += `${\n item.fields[contentSettings.mainContent]\n }`;\n }\n\n // create file\n if (contentSettings.isHeadless) {\n fs.writeFile(\n `.${contentSettings.directory}${item.sys.id}/index.${contentSettings.fileExtension}`,\n fileContent,\n error => {\n if (error) {\n console.log(error);\n }\n }\n );\n } else if (contentSettings.isSingle) {\n fs.writeFile(\n `.${contentSettings.directory}/${contentSettings.fileName}.${contentSettings.fileExtension}`,\n fileContent,\n error => {\n if (error) {\n console.log(error);\n }\n }\n );\n } else {\n fs.writeFile(\n `.${contentSettings.directory}${item.sys.id}.${contentSettings.fileExtension}`,\n fileContent,\n error => {\n if (error) {\n console.log(error);\n }\n }\n );\n }\n itemCount++;\n }\n\n // check total number of items against number of items pulled in API\n if (data.total > data.limit) {\n // run function again if there are still more items to get\n let newSkip = skip + limit;\n getContentType(limit, newSkip, contentSettings, itemCount);\n } else {\n let grammarStuff;\n if (data.total == 1) {\n grammarStuff = 'item';\n } else {\n grammarStuff = 'items';\n }\n console.log(\n ` ${contentSettings.typeId} - ${itemCount} ${grammarStuff}`\n );\n typesExtracted++;\n checkIfFinished(typesExtracted);\n }\n })\n .catch(error => {\n let response = error.response;\n if (response) {\n console.log(\n ` --------------------------\\n ${contentSettings.typeId} - ERROR ${response.status} ${response.statusText}\\n (Note: ${response.data.message})\\n --------------------------`\n );\n } else {\n console.log(error);\n }\n });\n}", "function makeBlogEditable(isEditable) {\n if(isEditable){\n getMainBody(false);\n }\n else {\n getMainBody(true);\n }\n \n }", "function renderDrafts() {\n for (var i = 0; i < draftData.length; i++) {\n $('#existing-drafts').append(\"<div id='draft-\" + i + \"' class='draft'><input class='draft-title' id='draft-\" + i + \"-title' value='\" + draftData[i].name + \"'><div class='open-button action-button' onclick='openDraft(\" + i + \")'><span class='action-button-text'>Open</span></div><div class='delete-button action-button' onclick='deleteDraft(\" + i + \")'><span class='action-button-text'>Delete</span></div></div>\");\n }\n prepareInputs();\n}", "static parseContent(serializedContent, id) {\n let text = serializedContent;\n const extractedData = dataExtractor.exec(serializedContent);\n let result;\n if (!extractedData) {\n // In case stackedit's data has been manually removed, try to restore them\n result = utils.deepCopy(store.state.content.itemsById[id]) || emptyContent(id);\n } else {\n result = emptyContent(id);\n try {\n const serializedData = extractedData[1].replace(/\\s/g, '');\n const parsedData = JSON.parse(utils.decodeBase64(serializedData));\n text = text.slice(0, extractedData.index);\n if (parsedData.properties) {\n result.properties = utils.sanitizeText(parsedData.properties);\n }\n if (parsedData.discussions) {\n result.discussions = parsedData.discussions;\n }\n if (parsedData.comments) {\n result.comments = parsedData.comments;\n }\n result.history = parsedData.history;\n } catch (e) {\n // Ignore\n }\n }\n result.text = utils.sanitizeText(text);\n if (!result.history) {\n result.history = [];\n }\n return utils.addItemHash(result);\n }", "function hideAnyPostItemPreview() {\n //debug(\"hideAnyPostItemPreview\");\n if ($lastPreviewedItem !== null)\n hidePostItemPreview($lastPreviewedItem);\n}", "get hasContent() {\n return Boolean(typeof this.html === 'string' && this.html.length || this.items.length);\n }", "function customHTML2Content(HTML, contentState) {\n var tempDoc = new DOMParser().parseFromString(HTML, 'text/html');\n // replace all <img /> with <blockquote /> elements\n (0, _toArray2.default)(tempDoc.querySelectorAll('img')).forEach(imgReplacer);\n // use DraftJS converter to do initial conversion. I don't provide DOMBuilder and\n // blockRenderMap arguments here since it should fall back to its default ones, which are fine\n\n var _convertFromHTML = (0, _draftJs.convertFromHTML)(tempDoc.body.innerHTML),\n contentBlocks = _convertFromHTML.contentBlocks;\n // now replace <blockquote /> ContentBlocks with 'atomic' ones\n\n\n contentBlocks = contentBlocks.reduce(function (contentBlocks, block) {\n if (block.getType() !== 'blockquote') {\n return contentBlocks.concat(block);\n }\n var image = JSON.parse(block.getText());\n contentState.createEntity('IMAGE-ENTITY', 'IMMUTABLE', image);\n var entityKey = contentState.getLastCreatedEntityKey();\n var charData = _draftJs.CharacterMetadata.create({ entity: entityKey });\n // const blockSpec = Object.assign({ type: 'atomic', text: ' ' }, { entityData })\n // const atomicBlock = createContentBlock(blockSpec)\n // const spacerBlock = createContentBlock({});\n var fragmentArray = [new _draftJs.ContentBlock({\n key: (0, _draftJs.genKey)(),\n type: 'image-block',\n text: ' ',\n characterList: (0, _immutable.List)((0, _immutable.Repeat)(charData, charData.count()))\n }), new _draftJs.ContentBlock({\n key: (0, _draftJs.genKey)(),\n type: 'unstyled',\n text: '',\n characterList: (0, _immutable.List)()\n })];\n return contentBlocks.concat(fragmentArray);\n }, []);\n // console.log('>> customHTML2Content contentBlocks', contentBlocks);\n tempDoc = null;\n return _draftJs.BlockMapBuilder.createFromArray(contentBlocks);\n}", "function getViewOrListMetaAndData(name) {\n\t\t\tvar returnObject = {\n\t\t\t\tdata: null,\n\t\t\t\tmeta: null,\n\t\t\t\tisView: true,\n\t\t\t\tisEdit: true\n\t\t\t};\n\n\t\t\tif (name === \"\") {\n\t\t\t\tfor (var i = 0; i < contentData.defaultRecordView.regions.length; i++) {\n\t\t\t\t\tif (contentData.defaultRecordView.regions[i].name === \"content\") {\n\t\t\t\t\t\treturnObject.meta = fastCopy(contentData.defaultRecordView.regions[i]);\n\t\t\t\t\t\treturnObject.meta.label = \"General\";\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturnObject.isView = true;\n\t\t\t\treturnObject.isEdit = true;\n\t\t\t\treturnObject.data = fastCopy(resolvedCurrentView.data[0]);\n\t\t\t} else {\n\t\t\t\tvar selectedDataName = \"\";\n\t\t\t\treturnObject.isEdit = false;\n\t\t\t\tfor (var i = 0; i < contentData.defaultRecordView.sidebar.items.length; i++) {\n\t\t\t\t\tif (contentData.defaultRecordView.sidebar.items[i].dataName === name) {\n\t\t\t\t\t\t//Set meta\n\t\t\t\t\t\t// If in edit mode (view from the current entity) the data should be different -> we need the content region meta, not the view meta as in recursive-view directive\n\t\t\t\t\t\tif (contentData.defaultRecordView.sidebar.items[i].type === \"view\") {\n\t\t\t\t\t\t\tfor (var j = 0; j < contentData.defaultRecordView.sidebar.items[i].meta.regions.length; j++) {\n\t\t\t\t\t\t\t\tif (contentData.defaultRecordView.sidebar.items[i].meta.regions[j].name === \"content\") {\n\t\t\t\t\t\t\t\t\treturnObject.isEdit = true;\n\t\t\t\t\t\t\t\t\treturnObject.meta = fastCopy(contentData.defaultRecordView.sidebar.items[i].meta.regions[j]);\n\t\t\t\t\t\t\t\t\treturnObject.meta.label = fastCopy(contentData.defaultRecordView.sidebar.items[i].meta.label);\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse {\n\t\t\t\t\t\t\treturnObject = contentData.defaultRecordView.sidebar.items[i];\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t//Set data\n\t\t\t\t\t\tselectedDataName = contentData.defaultRecordView.sidebar.items[i].dataName;\n\t\t\t\t\t\tif (contentData.defaultRecordView.sidebar.items[i].type === \"view\") {\n\t\t\t\t\t\t\treturnObject.isView = true;\n\t\t\t\t\t\t\treturnObject.data = fastCopy(resolvedCurrentView.data[0][selectedDataName][0]);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse if (contentData.defaultRecordView.sidebar.items[i].type === \"viewFromRelation\") {\n\t\t\t\t\t\t\treturnObject.isView = true;\n\t\t\t\t\t\t\treturnObject.data = fastCopy(resolvedCurrentView.data[0][selectedDataName]);\n\t\t\t\t\t\t} else if (contentData.defaultRecordView.sidebar.items[i].type === \"list\") {\n\t\t\t\t\t\t\treturnObject.isView = false;\n\t\t\t\t\t\t\treturnObject.data = fastCopy(resolvedCurrentView.data[0][selectedDataName]);\n\t\t\t\t\t\t} else if (contentData.defaultRecordView.sidebar.items[i].type === \"listFromRelation\") {\n\t\t\t\t\t\t\treturnObject.isView = false;\n\t\t\t\t\t\t\treturnObject.data = fastCopy(resolvedCurrentView.data[0][selectedDataName]);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t\treturn returnObject;\n\t\t}", "function ɵɵcontentQuery(directiveIndex, predicate, flags, read) {\n ngDevMode && assertNumber(flags, 'Expecting flags');\n var tView = getTView();\n\n if (tView.firstCreatePass) {\n var tNode = getCurrentTNode();\n createTQuery(tView, new TQueryMetadata_(predicate, flags, read), tNode.index);\n saveContentQueryAndDirectiveIndex(tView, directiveIndex);\n\n if ((flags & 2\n /* isStatic */\n ) === 2\n /* isStatic */\n ) {\n tView.staticContentQueries = true;\n }\n }\n\n createLQuery(tView, getLView(), flags);\n }", "function customHTML2Content(HTML, contentState) {\n var tempDoc = new DOMParser().parseFromString(HTML, 'text/html');\n // replace all <img /> with <blockquote /> elements\n (0, _toArray2[\"default\"])(tempDoc.querySelectorAll('img')).forEach(imgReplacer);\n // use DraftJS converter to do initial conversion. I don't provide DOMBuilder and\n // blockRenderMap arguments here since it should fall back to its default ones, which are fine\n\n var _convertFromHTML = (0, _draftJs.convertFromHTML)(tempDoc.body.innerHTML),\n contentBlocks = _convertFromHTML.contentBlocks;\n // now replace <blockquote /> ContentBlocks with 'atomic' ones\n\n\n contentBlocks = contentBlocks.reduce(function (contentBlocks, block) {\n if (block.getType() !== 'blockquote') {\n return contentBlocks.concat(block);\n }\n var image = JSON.parse(block.getText());\n contentState.createEntity('IMAGE-ENTITY', 'IMMUTABLE', image);\n var entityKey = contentState.getLastCreatedEntityKey();\n var charData = _draftJs.CharacterMetadata.create({ entity: entityKey });\n // const blockSpec = Object.assign({ type: 'atomic', text: ' ' }, { entityData })\n // const atomicBlock = createContentBlock(blockSpec)\n // const spacerBlock = createContentBlock({});\n var fragmentArray = [new _draftJs.ContentBlock({\n key: (0, _draftJs.genKey)(),\n type: 'image-block',\n text: ' ',\n characterList: (0, _immutable.List)((0, _immutable.Repeat)(charData, charData.count()))\n }), new _draftJs.ContentBlock({\n key: (0, _draftJs.genKey)(),\n type: 'unstyled',\n text: '',\n characterList: (0, _immutable.List)()\n })];\n return contentBlocks.concat(fragmentArray);\n }, []);\n // console.log('>> customHTML2Content contentBlocks', contentBlocks);\n tempDoc = null;\n return _draftJs.BlockMapBuilder.createFromArray(contentBlocks);\n}", "_onProcessReplaceableContent() {}", "function getPublishContent(fileDesc, publishAttributes, html) {\r\n\t\tif(publishAttributes.format === undefined) {\r\n\t\t\tpublishAttributes.format = utils.getInputRadio(\"radio-publish-format\");\r\n\t\t\tif(publishAttributes.format == 'template' && utils.getInputChecked(\"#checkbox-publish-custom-template\")) {\r\n\t\t\t\tpublishAttributes.customTmpl = utils.getInputValue('#textarea-publish-custom-template');\r\n\t\t\t}\r\n\t\t}\r\n\t\tif(publishAttributes.format == \"markdown\") {\r\n\t\t\treturn fileDesc.content;\r\n\t\t}\r\n\t\telse if(publishAttributes.format == \"html\") {\r\n\t\t\treturn html.withoutComments;\r\n\t\t}\r\n\t\telse {\r\n\t\t\treturn publisher.applyTemplate(fileDesc, publishAttributes, html);\r\n\t\t}\r\n\t}", "function applyDraftChanges(annotation) {\n const changes = {};\n const draft = store.getDraft(annotation);\n\n if (draft) {\n changes.tags = draft.tags;\n changes.text = draft.text;\n changes.permissions = draft.isPrivate\n ? privatePermissions(annotation.user)\n : sharedPermissions(annotation.user, annotation.group);\n }\n\n // Integrate changes from draft into object to be persisted\n return { ...annotation, ...changes };\n }", "function parseCustom(item, contents){\n custom_parsers = {\n \"hideable_items\" : function(info){\n hideSelectedHideables(info[\"value\"]);\n },\n \"molecular_category\" : function(info){\n parseMolecularCategories(info[\"value\"], info[\"value_of_other\"]);\n },\n \"mcs_mutations_table\" : function(info){\n updateMutationsTable(info[\"value\"]);\n },\n \"mcs_mutations_table_diagnosis\" : function(info){\n updateMutationsTable_diagnosis(info[\"value\"]);\n },\n \"prior_molecular_testing\" : function(info){\n parsed_item = addPriorMolecularTesting(info[\"value\"]);\n populate(\"prior_molecular_testing\", parsed_item);\n },\n \"analyst_custom_images\" : function(info){\n parsed_item = addCustomImageSlides(info[\"value\"]);\n populate(\"analyst_custom_images\", parsed_item);\n },\n \"all_molecular_findings\" : function(info){\n parsed_item = parseAllMolecularFindings(info[\"value\"]);\n populate(\"all_molecular_findings\", parsed_item);\n \n // Also populate standalone slides or summary references list\n if(documentTypeIsSlides){\n slides_text = parseAllMolecularFindings_slides(info[\"value\"]);\n populate(\"all_findings_individual_slides\", slides_text);\n } else {\n summary_text = allMolecularFindingsReferences_summary(info[\"value\"]);\n populate(\"finding_specific_references\", summary_text);\n }\n },\n \"custom_font_size_personalized_cohorts_slide\" : function(info){\n size = info[\"value\"] // string - so empty or otherwise\n if(documentTypeIsSlides && size){\n document.getElementById(\"tablePersonalizedCohortCounts\").style.fontSize = size;\n }\n },\n \"quality_control_statement\": function (info){\n fail_reason = info[\"value\"] // string - so empty or otherwise\n if((!documentTypeIsSlides) && fail_reason){\n populate(\"quality_control_statement\", fail_reason);\n // Also make the box red\n document.getElementById(\"highlight_failed_qc_div\").classList.add(\"red\");\n }\n },\n \"optional_rin_score\": function (info){\n // retrieve global nb4pt25_RIN_Precise_result and reference_lower from script in summary or slides.template\n // Then, only set this value if Precise_result was previously NA; if not, use that canonical value\n if (info[\"value\"] && nb4pt25_RIN_Precise_result == \"NA\") {\n // Set RIN value td to what's retrieved from annotations.json\n let rin_annotations = Number(info[\"value\"])\n document.getElementById(\"rin_score_display\").innerHTML = rin_annotations;\n\n // Set PASS or FAIL td; also reset row color if new value is PASS\n let rin_min_from_notebook = Number(nb4pt25_RIN_Precise_reference_lower);\n if (rin_min_from_notebook <= rin_annotations ){\n document.getElementById(\"rin_passfail_display\").innerHTML = \"PASS\";\n rin_row = document.getElementById(\"rin_row_display\");\n rin_row.style.backgroundColor = rin_row.style.color = \"\";\n }else{\n document.getElementById(\"rin_passfail_display\").innerHTML = \"FAIL\";\n }\n }\n } // end optional_rin_score\n } // end custom_parsers dict\n custom_parsers[item](contents); // Call the parser\n }", "function customHTML2Content(HTML, contentState) {\n var tempDoc = new DOMParser().parseFromString(HTML, 'text/html');\n // replace all <img /> with <blockquote /> elements\n (0, _lodash.toArray)(tempDoc.querySelectorAll('img')).forEach(imgReplacer);\n // use DraftJS converter to do initial conversion. I don't provide DOMBuilder and\n // blockRenderMap arguments here since it should fall back to its default ones, which are fine\n\n var _convertFromHTML = (0, _draftJs.convertFromHTML)(tempDoc.body.innerHTML),\n contentBlocks = _convertFromHTML.contentBlocks;\n // now replace <blockquote /> ContentBlocks with 'atomic' ones\n\n\n contentBlocks = contentBlocks.reduce(function (contentBlocks, block) {\n if (block.getType() !== 'blockquote') {\n return contentBlocks.concat(block);\n }\n var image = JSON.parse(block.getText());\n contentState.createEntity('IMAGE-ENTITY', 'IMMUTABLE', image);\n var entityKey = contentState.getLastCreatedEntityKey();\n var charData = _draftJs.CharacterMetadata.create({ entity: entityKey });\n // const blockSpec = Object.assign({ type: 'atomic', text: ' ' }, { entityData })\n // const atomicBlock = createContentBlock(blockSpec)\n // const spacerBlock = createContentBlock({});\n var fragmentArray = [new _draftJs.ContentBlock({\n key: (0, _draftJs.genKey)(),\n type: 'image-block',\n text: ' ',\n characterList: (0, _immutable.List)((0, _immutable.Repeat)(charData, charData.count()))\n }), new _draftJs.ContentBlock({\n key: (0, _draftJs.genKey)(),\n type: 'unstyled',\n text: '',\n characterList: (0, _immutable.List)()\n })];\n return contentBlocks.concat(fragmentArray);\n }, []);\n // console.log('>> customHTML2Content contentBlocks', contentBlocks);\n tempDoc = null;\n return _draftJs.BlockMapBuilder.createFromArray(contentBlocks);\n}", "_loadResourceFragments(documentId, index) {\n if(!this.state.resource) {\n return\n }\n\n let filters = {\n \"resources\": [this.props.resource]\n }\n let options = {}\n let documentClient = this.context.documentClient\n let items = this.state.documents\n\n if(!items[index].fragments) {\n documentClient.loadFragments(documentId, filters, options, function(err, fragments) {\n if (err) {\n console.error('Search results could not be loaded', err)\n return\n }\n\n items[index].fragments = fragments\n\n this.extendState({\n documents: items,\n details: index \n })\n }.bind(this))\n } else {\n this.extendState({details: index})\n }\n }", "function customHTML2Content(HTML, contentState) {\n var tempDoc = new DOMParser().parseFromString(HTML, 'text/html');\n // replace all <img /> with <blockquote /> elements\n __WEBPACK_IMPORTED_MODULE_1_lodash_toArray___default()(tempDoc.querySelectorAll('img')).forEach(imgReplacer);\n // use DraftJS converter to do initial conversion. I don't provide DOMBuilder and\n // blockRenderMap arguments here since it should fall back to its default ones, which are fine\n\n var _convertFromHTML = Object(__WEBPACK_IMPORTED_MODULE_0_draft_js__[\"convertFromHTML\"])(tempDoc.body.innerHTML),\n contentBlocks = _convertFromHTML.contentBlocks;\n // now replace <blockquote /> ContentBlocks with 'atomic' ones\n\n\n contentBlocks = contentBlocks.reduce(function (contentBlocks, block) {\n if (block.getType() !== 'blockquote') {\n return contentBlocks.concat(block);\n }\n var image = JSON.parse(block.getText());\n contentState.createEntity('IMAGE-ENTITY', 'IMMUTABLE', image);\n var entityKey = contentState.getLastCreatedEntityKey();\n var charData = __WEBPACK_IMPORTED_MODULE_0_draft_js__[\"CharacterMetadata\"].create({ entity: entityKey });\n // const blockSpec = Object.assign({ type: 'atomic', text: ' ' }, { entityData })\n // const atomicBlock = createContentBlock(blockSpec)\n // const spacerBlock = createContentBlock({});\n var fragmentArray = [new __WEBPACK_IMPORTED_MODULE_0_draft_js__[\"ContentBlock\"]({\n key: Object(__WEBPACK_IMPORTED_MODULE_0_draft_js__[\"genKey\"])(),\n type: 'image-block',\n text: ' ',\n characterList: Object(__WEBPACK_IMPORTED_MODULE_2_immutable__[\"List\"])(Object(__WEBPACK_IMPORTED_MODULE_2_immutable__[\"Repeat\"])(charData, charData.count()))\n }), new __WEBPACK_IMPORTED_MODULE_0_draft_js__[\"ContentBlock\"]({\n key: Object(__WEBPACK_IMPORTED_MODULE_0_draft_js__[\"genKey\"])(),\n type: 'unstyled',\n text: '',\n characterList: Object(__WEBPACK_IMPORTED_MODULE_2_immutable__[\"List\"])()\n })];\n return contentBlocks.concat(fragmentArray);\n }, []);\n // console.log('>> customHTML2Content contentBlocks', contentBlocks);\n tempDoc = null;\n return __WEBPACK_IMPORTED_MODULE_0_draft_js__[\"BlockMapBuilder\"].createFromArray(contentBlocks);\n}", "function getSectionContents(bookmarkList,query) {\n var section_root = jQuery('<ol>').addClass('section_content');\n // section contents layout \n for ( var i = 0; i < bookmarkList.length; i++ ){\n if ( query == \"\" || bookmarkList[i].title.indexOf(query) >= 0 ){\n section_root.append(\n jQuery('<li>').attr('class','ui-widget-content').append(\n jQuery('<div>').text(bookmarkList[i].title).css('font-size','1em').add(\n jQuery('<input>').attr('type','hidden').val(bookmarkList[i].url)\n )\n )\n )\n \n }//end of if\n }//end of for.\n section_root.selectable({\n filter:'li',\n selected: function(event, ui) {\n chrome.tabs.create({url:$(ui.selected).find(\"input\").val()})\n }\n });\n return section_root;\n}", "function onChange (chg) {\n prepend('articles', h('article', [\n h('header', [\n h('h4', [chg.doc.title])\n ]),\n h('div', [chg.doc.body]),\n h('hr')\n ]))\n}", "function filter_favourites() {\n recipe_wrapper.innerHTML = \"\";\n var currentPage = window.location.href;\n var http = new XMLHttpRequest();\n http.open('GET', `${currentPage}/favourites`, true);\n\n http.onreadystatechange = function() {\n if(http.readyState == 4 && http.status == 200) {\n faves = this.responseText.split(\"|||\");\n for (var i = 0; i < faves.length; i++) {\n if (faves[i] != \"\") {\n new_tile = create_recipe_tile(faves[i]);\n recipe_wrapper.appendChild(new_tile);\n }\n }\n format_recipe_description_for_web();\n }\n }\n http.send();\n}", "filterByYear() {\n // Remove cached shows\n if(localStorage.getItem(\"cachedShow\")) {\n localStorage.removeItem(\"cachedShow\");\n }\n\n this.retrieveShowContent();\n }", "function processArticle(content) {\n if (!content) {\n console.error(\"processArticle didn't find any content to process!\");\n return;\n }\n if (!fm.test(content)) {\n console.error(\"Bad content:\", content);\n console.error(\"Front-matter considers this content invalid.\");\n return;\n }\n var article = fm(content.toString()); // We have an article object\n article.attributes.date = moment(article.attributes.date); //Remember to format() back to string from within jade\n // debug junk\n // var gotTags = article.attributes.tags;\n // if (gotTags){\n // console.log(\"Got tags:\", gotTags);\n // } else {\n // console.log(\"This article has no tags:\", article.path);\n // }\n\n return article;\n}", "function filterDescription(desc) {\n\t\tif (!document.getElementById('descricoes').checked) {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t}", "function heroDraft(hero, callback, wildcard) {\n DataSources[activeSource].heroDraft(hero, callback, wildcard);\n}", "handleChange(e) {\n let filteredBooks = [];\n\n // Copy book array\n let copyOfBookList = this.state.books.slice();\n\n // Text filter via a RegEx for books within the current date range\n filteredBooks = copyOfBookList.filter(obj => {\n let caseInsensitiveInput = new RegExp(e.target.value, \"i\");\n if (\n new Date(obj.publishDate) > this.state.publishedAfter &&\n new Date(obj.publishDate) < this.state.publishedBefore\n ) {\n return obj.title.match(caseInsensitiveInput);\n }\n });\n\n this.setState({\n filteredBookList: filteredBooks\n });\n }", "card_atts(card){\n // return this.attachments;\n return this.attachments.filter(att => att.parent == card.id);\n }", "function ɵɵcontentQuery(directiveIndex, predicate, descend, read) {\n contentQueryInternal(getTView(), getLView(), predicate, descend, read, false, getCurrentTNode(), directiveIndex);\n}", "function generateSingleFeedHTML(itemToUseContent) {\n\n\t\t\tvar tAuthorFullName = itemToUseContent.targetAuthor.eventDestActorFullName(true),\n\t\t\t\ttAuthorProfileUrl = itemToUseContent.targetAuthor.eventDestActorProfileUrl(true),\n\t\t\t\ttAuthorProfilePic = itemToUseContent.targetAuthor.eventDestActorProfilePic(true),\n\t\t\t\ttAuthorProfileId = itemToUseContent.targetAuthor.eventDestActorProfileId(true),\n\t\t\t\tmainActorVCard = generateVCard(tAuthorFullName, tAuthorProfileId, tAuthorProfileUrl, tAuthorProfilePic, true, false, false),\n\t\t\t\ttoAdd,\n\t\t\t\texpandedObject,\n\t\t\t\tembeddedActor = {\n\t\t\t\t\tvCard: \"\",\n\t\t\t\t\tid: -1\n\t\t\t\t},\n\t\t\t\tembeddedContent = \"\",\n\t\t\t\tnTitle = itemToUseContent.mainObject.Title || \"\",\n\t\t\t\teventDateHTML = \"\",\n\t\t\t\ttTitleToComp,\n\t\t\t\tCcontentToComp,\n\n\t\t\t\tnCreatedDateDisplay = itemToUseContent.eventCreatedDateDisplay || \"\",\n\t\t\t\tnCreatedFullDate = itemToUseContent.eventCreatedDateFull,\n\n\t\t\t\tnTargetUrl = itemToUseContent.mainObject.Url,\n\t\t\t\tnRollUpId = itemToUseContent.originalFeed.connections.rollupid || \"\",\n\t\t\t\tnIsSaved = itemToUseContent.bools.IsSaved,\n\t\t\t\tnIsLiked = itemToUseContent.bools.IsLiked,\n\t\t\t\tnIsFollowed = itemToUseContent.bools.IsFollowed,\n\t\t\t\tnDataId = itemToUseContent.mainObject.ID,\n\t\t\t\tnVerb = itemToUseContent.mainObject.Verb || \"\",\n\t\t\t\tnPublishingDate = itemToUseContent.mainObject.PublishingDate || \"\",\n\n\t\t\t\tnEventOf = itemToUseContent.eventOfType || \"\",\n\n\t\t\t\tnObjectType = itemToUseContent.mainObject.Type,\n\t\t\t\tnContent = itemToUseContent.mainObject.Content,\n\t\t\t\tnFirstLevelContentAttribute = assertChain(itemToUseContent, \"originalFeed.content\") ? itemToUseContent.originalFeed.content : \"\",\n\t\t\t\tpostObject = \"\",\n\t\t\t\tinsideActorHTML = '<li class=\"postObject-inside-actor\">$MAIN_ACTOR_VCARD</li>',\n\t\t\t\tinsideEmbedded$ = $('<ul/>').addClass('postObject-inside-embedded')\n\t\t\t\t\t.append($('<li/>').addClass('postObject-inside-embedded-actor').text('$EMBEDDED_ACTOR'),\n\t\t\t\t\t\t$('<li/>').addClass('postObject-inside-embedded-eventContent').text('$EMBEDDED_CONTENT')),\n\n\t\t\t\tinsideMain$ = $('<ul/>').addClass('postObject-inside-main')\n\t\t\t\t\t.append($('<li/>').addClass('postObject-inside-eventContent').text('$MAIN_CONTENT'),\n\t\t\t\t\t\t$('<li/>').addClass('postObject-inside-eventAttachments').text('$EVENT_ATTACHMENTS')),\n\n\t\t\t\tpostObjectHtmlTemplate = '<li class=\"normalPostEntryItem\" tabindex=\"$TAB_INDEX\" data-index=\"$DATA_INDEX\">' +\n\t\t\t\t\t'<div class=\"activityStreamNewsItemContainer ActivityStreamWidgetPost\" data-targetURL=\"$DATA_TARGETURL\" ' +\n\t\t\t\t\t'data-rollupid=\"$DATA_ROLLUPID\" saved=\"$DATA_SAVED\" liked=\"$DATA_LIKED\" followed=\"$DATA_FOLLOWED\" data-verb=\"$DATA_VERB\" data-objectType=\"$DATA_OBJECTTYPE\" data-id=\"$DATA_ID\" data-date=\"$DATA_DATE\">';\n\n\t\t\tpostObjectHtmlTemplate += '<ul class=\"ASWidgetPostUL\">' +\n\n\t\t\t\t(savedSettings.useDefaultStyle ? '' : insideActorHTML) +\n\t\t\t\t'<li class=\"normalPostEntryItemexpand\"><div class=\"postActionBox\"><i class=\"fa fa-angle-double-' + (X.L.isRTL ? 'left' : 'right') + '\" aria-hidden=\"true\"></i></div></li>';\n\n\n\t\t\teventDateHTML = '<div class=\"panel panel-default ASWidgetDatePanel\">' +\n\t\t\t\t'<div class=\"panel-body\">' +\n\t\t\t\t'<span>' +\n\t\t\t\t'<abbr data-toggle=\"ASWidget-Post-Date\" title=\"$CREATION_DATEFULL\" data-placement=\"left\" data-parseddatefull=\"$CREATION_DATEPARSEDFULL\">$EVENT_CREATEDDATE</abbr>' +\n\t\t\t\t'<span title=\"' + localizeString(\"ASWidget-event-from\", \"Event from $1\", nEventOf) + '\">$EVENT_ICON' + '</span>' +\n\t\t\t\t'</span>' +\n\t\t\t\t'</div>' +\n\t\t\t\t'</div>';\n\t\t\tpostObjectHtmlTemplate += '<li class=\"postObject\">' +\n\n\t\t\t\t'<ul class=\"postObject-inside\">' +\n\t\t\t\t'<ul class=\"postObject-inside-header\">' +\n\t\t\t\t(savedSettings.useDefaultStyle ? insideActorHTML : '') +\n\t\t\t\t'<li class=\"postObject-inside-eventTitle\">$EVENT_TITLE</li>' +\n\t\t\t\t'<li class=\"postObject-inside-time\">' +\n\t\t\t\t'<ul class=\"postObject-inside-time-ul\">' +\n\t\t\t\t'<li class=\"postObject-inside-date\">' + eventDateHTML + '</li>' +\n\t\t\t\t'</ul>' +\n\t\t\t\t'</li>' +\n\t\t\t\t'</ul>' +\n\t\t\t\t'</ul>';\n\n\t\t\tpostObjectHtmlTemplate +=\n\t\t\t\t'<ul class=\"postObject-inside-firstLevelContentAttribute\">' +\n\t\t\t\t'<li class=\"postObject-inside-firstLevelContentAttribute-eventContent\">$FIRSTLEVE_CONTENT_ATTRIBUTE</li>' +\n\t\t\t\t'</ul>' +\n\n\t\t\t\t(savedSettings.useDefaultStyle ? insideEmbedded$[0].outerHTML : '') +\n\n\t\t\t\t(savedSettings.useDefaultStyle ? insideMain$[0].outerHTML : '') +\n\n\t\t\t\t'</ul>' +\n\n\t\t\t\t(!savedSettings.useDefaultStyle ? insideEmbedded$[0].outerHTML : '') +\n\n\t\t\t\t(!savedSettings.useDefaultStyle ? insideMain$[0].outerHTML : '') +\n\n\t\t\t\t'</ul>' +\n\t\t\t\t'</div>' +\n\t\t\t\t'</li>';\n\n\t\t\t(function checkSpecialItemCases() {\n\t\t\t\tvar baseItm = itemToUseContent.originalFeed,\n\t\t\t\t\tobjectSum = (true === assertChain(baseItm, \"object.summary\")),\n\t\t\t\t\tobjectIsPerson = (\"person\" === baseItm.object.objectType),\n\t\t\t\t\ttargetIsPerson = (assertChain(baseItm, \"object.objectType\") && (\"person\" === baseItm.object.objectType)),\n\n\t\t\t\t\tallFourExisting = baseItm.actor && baseItm.object && baseItm.target && assertChain(baseItm, \"object.author\");\n\n\t\t\t\tif (allFourExisting && objectSum && (\"person\" !== baseItm.object.objectType) && (\"comment\" !== baseItm.object.objectType)) {\n\t\t\t\t\tnContent = baseItm.object.summary;\n\n\t\t\t\t\tif (objectIsPerson) {\n\t\t\t\t\t\tembeddedActor.id = baseItm.target.author.id;\n\t\t\t\t\t\tembeddedActor.vCard = generateVCard(baseItm.target.author.displayName, baseItm.target.author.id,\n\t\t\t\t\t\t\tgetspecifiedURL(baseItm.target.author.id, \"profile\"), getspecifiedURL(baseItm.target.author.id, \"picture\"), true, true, false);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tembeddedActor.id = baseItm.object.author.id;\n\t\t\t\t\t\tembeddedActor.vCard = generateVCard(baseItm.object.author.displayName, baseItm.object.author.id,\n\t\t\t\t\t\t\tgetspecifiedURL(baseItm.object.author.id, \"profile\"), getspecifiedURL(baseItm.object.author.id, \"picture\"), true, true, false);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\n\n\t\t\t\tif (allFourExisting && (\"comment\" === baseItm.object.objectType) && !targetIsPerson) {\n\t\t\t\t\tnContent = baseItm.target.summary || \"\";\n\t\t\t\t\tif (assertChain(baseItm, \"target.author\") && (baseItm.target.author.id !== baseItm.object.author.id)) {\n\t\t\t\t\t\tembeddedActor.id = baseItm.target.author.id;\n\t\t\t\t\t\tembeddedActor.vCard = generateVCard(baseItm.target.author.displayName, baseItm.target.author.id,\n\t\t\t\t\t\t\tgetspecifiedURL(baseItm.target.author.id, \"profile\"), getspecifiedURL(baseItm.target.author.id, \"picture\"), true, true, false);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif (assertChain(baseItm, \"actor.id\") && assertChain(baseItm, \"object.author.id\") && (baseItm.actor.id === baseItm.object.author.id) && !(assertChain(baseItm, \"target.author\"))) {\n\t\t\t\t\tembeddedActor.vCard = \"\";\n\t\t\t\t\tembeddedActor.id = 0;\n\t\t\t\t}\n\n\t\t\t\tif (assertChain(baseItm, \"actor.id\") && assertChain(baseItm, \"target.author.id\") && (baseItm.target.author.id === baseItm.actor.id)) {\n\t\t\t\t\tembeddedActor.vCard = \"\";\n\t\t\t\t\tembeddedActor.id = \"\";\n\t\t\t\t}\n\n\t\t\t\tif (\"todo\" === itemToUseContent.mainObject.Type) {\n\t\t\t\t\t//embeddedActor.vCard = \"\";\n\t\t\t\t\t//embeddedActor.id = 0;\n\t\t\t\t}\n\n\n\t\t\t\tif ((\"question\" === itemToUseContent.mainObject.Type) || (\"todo\" === itemToUseContent.mainObject.Type)) {\n\t\t\t\t\tif ((assertChain(itemToUseContent, \"mainObject.Actor.ProfileId\") && assertChain(itemToUseContent, \"mainObject.Author.ProfileId\") &&\n\t\t\t\t\t\titemToUseContent.mainObject.Actor.ProfileId === itemToUseContent.mainObject.Author.ProfileId) || ($(nContent).first().text().length <= 10)) {\n\t\t\t\t\t\tembeddedActor.vCard = \"\";\n\t\t\t\t\t\tembeddedActor.id = 0;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\n\t\t\t\tif (nFirstLevelContentAttribute === nContent) {\n\t\t\t\t\tnFirstLevelContentAttribute = \"\";\n\t\t\t\t}\n\t\t\t}\n\t\t\t());\n\n\n\t\t\tpostObject = replaceIt(postObjectHtmlTemplate, \"$TAB_INDEX\", lastItemDataRefId.toString());\n\t\t\tpostObject = replaceIt(postObject, \"$DATA_INDEX\", lastItemDataRefId.toString());\n\t\t\tlastItemDataRefId += 1;\n\t\t\tpostObject = replaceIt(postObject, \"$DATA_TARGETURL\", nTargetUrl);\n\t\t\tpostObject = replaceIt(postObject, \"$DATA_ROLLUPID\", nRollUpId);\n\t\t\tpostObject = replaceIt(postObject, \"$DATA_SAVED\", nIsSaved.toString());\n\t\t\tpostObject = replaceIt(postObject, \"$DATA_LIKED\", nIsLiked.toString());\n\t\t\tpostObject = replaceIt(postObject, \"$DATA_FOLLOWED\", nIsFollowed.toString());\n\t\t\tpostObject = replaceIt(postObject, \"$DATA_ID\", nDataId);\n\t\t\tpostObject = replaceIt(postObject, \"$DATA_DATE\", nPublishingDate);\n\t\t\tpostObject = replaceIt(postObject, \"$DATA_VERB\", nVerb);\n\t\t\tpostObject = replaceIt(postObject, \"$CREATION_DATEFULL\", nCreatedFullDate);\n\t\t\tpostObject = replaceIt(postObject, \"$CREATION_DATEPARSEDFULL\", nCreatedDateDisplay);\n\t\t\tpostObject = replaceIt(postObject, \"$EVENT_CREATEDDATE\", nCreatedDateDisplay);\n\n\t\t\tpostObject = replaceIt(postObject, \"$EMBEDDED_ACTOR\", embeddedActor.vCard);\n\t\t\tpostObject = replaceIt(postObject, \"$EMBEDDED_CONTENT\", embeddedContent);\n\t\t\tpostObject = replaceIt(postObject, \"$MAIN_ACTOR_VCARD\", mainActorVCard);\n\n\t\t\ttTitleToComp = startsWith(nTitle, \"<\", 0) ? $($(nTitle)[2]).text() : nTitle;\n\t\t\tCcontentToComp = $(\"<span/>\").append(nContent).text();\n\n\t\t\tif (tTitleToComp && CcontentToComp && (tTitleToComp === CcontentToComp)) {\n\t\t\t\tnContent = \"\";\n\t\t\t}\n\n\t\t\tpostObject = replaceIt(postObject, \"$EVENT_TITLE\", nTitle);\n\n\t\t\tpostObject = replaceIt(postObject, \"$FIRSTLEVE_CONTENT_ATTRIBUTE\", nFirstLevelContentAttribute);\n\n\t\t\tpostObject = replaceIt(postObject, \"$DATA_OBJECTTYPE\", nObjectType);\n\n\t\t\tif (nContent === \"[object Object]\") {\n\t\t\t\tnContent = \"\";\n\t\t\t}\n\t\t\tpostObject = replaceIt(postObject, \"$MAIN_CONTENT\", nContent);\n\n\t\t\ttoAdd = '<img src=\"' + itemToUseContent.mainObject.IconUrl + '\" alt=\"' + localizeString(\"ASWidget-event-from\", \"Event from $1\", nEventOf) + ' \">';\n\t\t\tif (!(itemToUseContent.mainObject.IconUrl && itemToUseContent.mainObject.IconUrl.length && (-1 === itemToUseContent.mainObject.IconUrl.indexOf(\"thumbnail\")))) {\n\t\t\t\ttoAdd = '<i class=\"fa fa-square\" aria-hidden=\"true\" alt=\"' + localizeString(\"ASWidget-event-from\", \"Event from $1\", nEventOf) + '\"></i>';\n\t\t\t}\n\t\t\tpostObject = replaceIt(postObject, \"$EVENT_ICON\", toAdd);\n\n\n\t\t\tif (assertChain(itemToUseContent, \"mainObject.attachmentsHTML\") && (itemToUseContent.mainObject.Attachments.length) && (itemToUseContent.mainObject.attachmentsHTML.length)) {\n\t\t\t\tpostObject = replaceIt(postObject, \"$EVENT_ATTACHMENTS\", itemToUseContent.mainObject.attachmentsHTML);\n\t\t\t}\n\n\t\t\tif (assertChain(itemToUseContent, \"targetObject.attachmentsHTML\") && (itemToUseContent.targetObject.Attachments.length) && (itemToUseContent.targetObject.attachmentsHTML.length)) {\n\t\t\t\tpostObject = replaceIt(postObject, \"$EVENT_ATTACHMENTS\", itemToUseContent.targetObject.attachmentsHTML);\n\t\t\t}\n\n\t\t\tif (-1 !== postObject.indexOf(\"$EVENT_ATTACHMENTS\")) {\n\t\t\t\tpostObject = replaceIt(postObject, \"$EVENT_ATTACHMENTS\", \"\");\n\t\t\t}\n\n\t\t\texpandedObject = {\n\t\t\t\toriginalDataObject: itemToUseContent.originalFeed,\n\t\t\t\tpregeneratedHTML: postObject,\n\t\t\t\tLiked: itemToUseContent.bools.IsLiked,\n\t\t\t\tGrabbedFeedObject: itemToUseContent\n\t\t\t};\n\t\t\tpostObject = modifyItem(expandedObject); // Add some needed HTML\n\t\t\tpostObject = createActionMenu({\n\t\t\t\toriginalDataObject: itemToUseContent.originalFeed,\n\t\t\t\tpregeneratedHTML: postObject,\n\t\t\t\tLiked: itemToUseContent.bools.IsLiked,\n\t\t\t\tGrabbedFeedObject: itemToUseContent\n\t\t\t});\n\n\n\t\t\t(function AddFinalHTMLAttribute() {\n\t\t\t\tvar ind = itemToUseContent.mainObject.ID || 0,\n\t\t\t\t\tobj = dataArray[ind];\n\t\t\t\tif (obj) {\n\t\t\t\t\tobj.finalHTML = '<ul class=\"ASWidgetLightBoxUL\">' + postObject + '</ul>';\n\t\t\t\t\tdataArray[ind] = obj;\n\t\t\t\t}\n\t\t\t}()); // Here the final HTML will be stored in an attribute. This is used later on to show content in the lightbox (fallback for the EE)\n\t\t\treturn postObject;\n\t\t}", "function ɵɵcontentQuery(directiveIndex, predicate, flags, read) {\n ngDevMode && assertNumber(flags, 'Expecting flags');\n const tView = getTView();\n if (tView.firstCreatePass) {\n const tNode = getCurrentTNode();\n createTQuery(tView, new TQueryMetadata_(predicate, flags, read), tNode.index);\n saveContentQueryAndDirectiveIndex(tView, directiveIndex);\n if ((flags & 2 /* isStatic */) === 2 /* isStatic */) {\n tView.staticContentQueries = true;\n }\n }\n createLQuery(tView, getLView(), flags);\n}", "function ɵɵcontentQuery(directiveIndex, predicate, flags, read) {\n ngDevMode && assertNumber(flags, 'Expecting flags');\n const tView = getTView();\n if (tView.firstCreatePass) {\n const tNode = getCurrentTNode();\n createTQuery(tView, new TQueryMetadata_(predicate, flags, read), tNode.index);\n saveContentQueryAndDirectiveIndex(tView, directiveIndex);\n if ((flags & 2 /* isStatic */) === 2 /* isStatic */) {\n tView.staticContentQueries = true;\n }\n }\n createLQuery(tView, getLView(), flags);\n}", "function ɵɵcontentQuery(directiveIndex, predicate, flags, read) {\n ngDevMode && assertNumber(flags, 'Expecting flags');\n const tView = getTView();\n if (tView.firstCreatePass) {\n const tNode = getCurrentTNode();\n createTQuery(tView, new TQueryMetadata_(predicate, flags, read), tNode.index);\n saveContentQueryAndDirectiveIndex(tView, directiveIndex);\n if ((flags & 2 /* isStatic */) === 2 /* isStatic */) {\n tView.staticContentQueries = true;\n }\n }\n createLQuery(tView, getLView(), flags);\n}", "function ɵɵcontentQuery(directiveIndex, predicate, flags, read) {\n ngDevMode && assertNumber(flags, 'Expecting flags');\n const tView = getTView();\n if (tView.firstCreatePass) {\n const tNode = getCurrentTNode();\n createTQuery(tView, new TQueryMetadata_(predicate, flags, read), tNode.index);\n saveContentQueryAndDirectiveIndex(tView, directiveIndex);\n if ((flags & 2 /* isStatic */) === 2 /* isStatic */) {\n tView.staticContentQueries = true;\n }\n }\n createLQuery(tView, getLView(), flags);\n}", "function ɵɵcontentQuery(directiveIndex, predicate, flags, read) {\n ngDevMode && assertNumber(flags, 'Expecting flags');\n const tView = getTView();\n if (tView.firstCreatePass) {\n const tNode = getCurrentTNode();\n createTQuery(tView, new TQueryMetadata_(predicate, flags, read), tNode.index);\n saveContentQueryAndDirectiveIndex(tView, directiveIndex);\n if ((flags & 2 /* isStatic */) === 2 /* isStatic */) {\n tView.staticContentQueries = true;\n }\n }\n createLQuery(tView, getLView(), flags);\n}", "function ɵɵcontentQuery(directiveIndex, predicate, descend, read) {\n contentQueryInternal(getTView(), getLView(), predicate, descend, read, false, getCurrentTNode(), directiveIndex);\n}", "setContentValid(isValid) {\n this.get('currentPost').set('hasValidContent', isValid);\n }", "function filterList(filter){\n\n //Unhide any book previously hidden.\n for (let book of booklist){\n book.className = 'li-cont';\n }\n \n fetch('/favorites/',{\n method: 'POST',\n headers:{\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify({\n msg:{ action: 'filter', data: filter }\n })\n })\n .then(res => res.json())\n .then(data => {\n if(data.msg === \"F2\"){\n return console.log(\"An error occured while filtering.\");\n }else{\n //Every book that doesn't match with the filter gets hidden.\n for (let book of data.msg){\n document.querySelector(`#wid-${book.workid}`).className = 'hidden-book';\n }\n }\n })\n .catch(err => console.log(\"Oops.\"));\n}", "function renderDrafts(draftsToRender) {\n\t\t $('#drafts').empty();\n\t\t if (draftsToRender.length > 0) {\n\t \t\tvar id = 1;\n\t\t\t$.each(draftsToRender, function(i, val) {\n\t\t\t var htmlString = getDraftHtml(val, id);\n\t\t\t $('#drafts').append(htmlString);\n\t\t\t \n\t\t\t // Resizes the gadget's window height to fit content\n\t\t\t gadgets.window.adjustHeight();\n\n\t\t\t $('#' + id).click(function() {\n\t\t\t\teditDraft(val);\n\t\t\t });\n\t\t\t id++;\n\t\t\t});\n\t\t }\n\t\t}", "function onFilterChange(event, payload) {\n\t\tconst entry = getEntry(props.titleMap, payload.value);\n\t\tupdateValue(event, entry, false);\n\t\tshowFilteredSuggestions();\n\n\t\t// resetting selection here in order to reinit the section + item indexes\n\t\tresetSelection();\n\t}", "function processEntries () {\n document.extraSearchEngines = {\n \"tangorin search\": \"http://tangorin.com/dict.php?dict=general&s=%s\",\n \"Forvo pronunciation\": \"http://www.forvo.com/search/%s\",\n \"Tatoeba example sentences\": \"http://tatoeba.org/eng/sentences/search?query=%s\"\n };\n document.verbSearchEngines = {\n \"Verbix verb conjugation\": \"http://www.verbix.com/webverbix/go.php?T1=%s&D1=51&H1=151\",\n \"Japanese Verb Conjugator\": \"http://www.japaneseverbconjugator.com/VerbDetails.asp?txtVerb=%s\"\n };\n document.kanjiSearchEngines = {\n \"SLJFAQ kanji search\": \"http://kanji.sljfaq.org/soft-keyboard.html#?=%s\",\n \"Red Finch kanji search\": \"http://redfinchjapanese.com/?action=kanji_dictionary?=%s\"\n };\n document.entryNodes = content.document.getElementsByClassName(\"concept_light\");\n function getEntryName(x) {\n return String.trim(x.getElementsByClassName(\"text\")[0].textContent);\n }\n document.results = map(document.entryNodes, getEntry);\n function getEntryStatusLinks(x) {\n return x.getElementsByClassName(\"concept_light-status_link\");\n }\n function getEntryLinksDropdown(x) {\n var links = getEntryStatusLinks(x);\n var dropdownId;\n for (i=0; i<links.length; ++i) {\n if (links[i].textContent == \"Links\")\n dropdownId = links[i].getAttribute(\"data-dropdown\");\n return document.getElementById(dropdownId);\n }\n }\n}", "function createPreview(allDiv,apiUrl, authToken, content, responseAsJson,\n responseAsJsonOld){\n\tconst username = localStorage.getItem('user');\n\tconst li = document.createElement(\"li\"); //general div\n\tli.setAttribute(\"data-id-post\", \"\");\n\tli.className = \"post\";\n\tlet div = document.createElement(\"div\");\n\tdiv.className = \"content\";\n div = attachToDiv(div, responseAsJson); //append subseddit, time , desc and title\n\tif (responseAsJson.image != null){ //if theres an image append image\n\t\tlet image = document.createElement(\"img\");\n\t\timage.className = \"post-image\";\n\t\timage.src = \"data:image/jpeg;base64,\" + responseAsJson.image;\n\t\tdiv.appendChild(image);\n\t}\n\tli.appendChild(div);\n\tli.appendChild(document.createElement(\"br\"));\n\tcontent.appendChild(li);\n\tif (username == responseAsJsonOld.username){\n\t\t//if own own user page, can delete or update these posts\n\t\tconst update = createFormButton(\"submit\", \"unfollow\", \"Update\");\n\t\tupdate.onclick = function(){ let form = createUpdateForm(apiUrl, authToken,\n responseAsJson.text, responseAsJson.title,\n responseAsJson.id);\n openEdit(allDiv,form)};\n\t\tconst deletePost = createFormButton(\"submit\", \"follow\", \"Delete\");\n\t\tdeletePost.onclick = function(){sendDelete(apiUrl, authToken,\n responseAsJson.id)};\n\t\tdiv.appendChild(deletePost);\n\t\tdiv.appendChild(update);\n\t}\n\treturn content;\n}", "function filterRepos() {\n // this runs through the stored results and replaces contents of web page with only code using the selected language.\n // build our list of affected repos\n filteredRepoList = []; // reset repolist to be empty or things get weird.\n var langToShow = document.getElementById(\"selLanguage\").value;\n if (langToShow == \"All\") {\n for (var k = 0; k < jsondata.length; k++) {\n filteredRepoList.push(jsondata[k]);\n }\n } else {\n for (var l = 0; l < jsondata.length; l++) {\n if (jsondata[l].language == langToShow) {\n filteredRepoList.push(jsondata[l]);\n }\n }\n\n }\n // then rebuild the projects list\n document.getElementById(\"projects\").innerHTML = parseData(filteredRepoList);\n}", "function setupEditContent() {\n var $wp = $('.write-pages li'); // the list of book pages\n // make sure the index is in bound wrapping at the ends\n if (editIndex < 0) {\n editIndex = $wp.length - 1;\n } else if (editIndex >= $wp.length) {\n editIndex = 0;\n }\n var $page = $($wp.get(editIndex)); // the current page\n var $img = $page.find('img');\n var caption = $page.find('p.thr-caption').html() || '';\n var view = {\n image: {\n url: $img.attr('src'),\n width: $img.attr('data-width'),\n height: $img.attr('data-height')\n },\n caption: caption ? caption : $('.wlClickToEdit').html()\n };\n templates.setImageSizes(view.image); // size the image\n var $content = $(templates.render('bookPage', view)); // render like any book page\n $content.filter('a.thr-home-icon,a.thr-settings-icon').hide(); // remove some unneeded links\n $editDialog.empty().append($('.wEditHelp').html()).append($content); // update dialog body\n var $deleteIcon = $('<img class=\"deleteIcon\" src=\"/theme/images/delete.png\" />');\n $deleteIcon.attr('title', $('.wDeleteThisPage').html());\n $editDialog.append($deleteIcon);\n var $copyIcon = $('<img class=\"copyIcon\" src=\"/theme/images/copy.png\" />');\n $copyIcon.attr('title', $('.wCopyThisPage').html());\n $editDialog.append($copyIcon);\n $editDialog.dialog('option', 'title', ''); // clear the title\n $editDialog.find('p.thr-caption').toggleClass('text-too-long',\n caption.length >= maxCaptionLength);\n }", "function readPost_post(obj) {\n $.each(obj.post, function(index, value){\n var title = change_alias(value.title).toLowerCase().replace(/ /g, '-');\n if (title == post) {\n var date = new Date(value.created);\n $(\"title\").text(value.title + \" - Blog's Reideen\");\n $(\".title-post\").text(value.title);\n $(\".created-post\").text(date.toDateString() + \" - WinterHk\");\n $(\".main-content-post\").html(value.content);\n return false;\n }\n\t})\t\n}", "function showPostPreview() {\n document.querySelector('#fullHTML').value = formatPost();\n document.querySelector('#preview').innerHTML = document.querySelector('#fullHTML').value;\n //document.querySelector('#nothing').value = document.querySelector('#content').innerHTML;\n aTagBlank();\n return formatPost()\n}", "function listMetadata(name){\n console.log(\"in listMetadata\");\n if (name != null) {\n document.getElementById(\"metadata_holder\").style.display = \"block\";\n document.getElementById(\"type_holder\").style.display = \"none\";\n console.log(\" model to display is \" + name);\n getMetadata(master_data, name); // extract the metadata for that model\n openOverview();\n }\n return false;\n}", "function postProcess() {\r\n for (var key in _opf.manifest) {\r\n var mediaType = _opf.manifest[key][\"media-type\"];\r\n var href = _opf.manifest[key][\"href\"];\r\n var result = '';\r\n\r\n if (mediaType === \"text/css\") {\r\n result = postProcessCSS(href);\r\n } else if (mediaType === \"application/xhtml+xml\") {\r\n result = postProcessHTML(href);\r\n }\r\n //only change the current file stored in _files if result is defined.\r\n if (result) {\r\n _files[href] = result;\r\n }\r\n }\r\n publish(EVENT.BOOKDATA_READY, STATE.OK, MSG.INIT_EBOOK_READER);\r\n }", "function changeFilter() {\n\n\t\tconst filters = {};\n\t\tconst authors = {};\n\t\tfilterCheckboxes.forEach(dom => filters[dom.name] = dom.checked);\n\t\tlistAuthors.querySelectorAll('input').forEach(dom => authors[dom.name] = dom.checked);\n\n\t\tvar strDom = '';\n\n\t\tcurPhoto.forEach(photo => {\n\t\t\tif (filters[sizePhoto(photo.width)] && authors[photo.user.name]) {\n\t\t\t\tstrDom += `<li data-id=\"${photo.id}\">\n\t\t\t\t\t\t<div \n\t\t\t\t\t\t\tclass=\"image-container\" \n\t\t\t\t\t\t\tdata-url=\"${photo.urls.full}\"\n\t\t\t\t\t\t\tdata-likes=\"${photo.likes}\"\n\t\t\t\t\t\t\tdata-author-url=\"${photo.user.links.html}\"\n\t\t\t\t\t\t\tdata-author-name=\"${photo.user.name}\"\n\t\t\t\t\t\t\tdata-author-photo=\"${photo.user.profile_image.small}\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<img src=\"${photo.urls.thumb}\" alt=\"${(photo.description) ? photo.description : ''}\">\n\t\t\t\t\t\t\t<div class=\"info\">\n\t\t\t\t\t\t\t\t<span class=\"likes\"><i class=\"fa fa-heart\" aria-hidden=\"true\"></i> ${photo.likes}</span>\n\t\t\t\t\t\t\t\t<a class=\"download\" href=\"${photo.links.download}\" download><i class=\"fa fa-arrow-circle-o-down\" aria-hidden=\"true\"></i></a>\n\t\t\t\t\t\t\t\t<a class=\"author\" href=\"${photo.user.links.html}\"><img src=\"${photo.user.profile_image.small}\">${photo.user.name}</a>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</li>`;\n\t\t\t}\n\t\t});\n\n\t\tlistPhotos.innerHTML = strDom;\n\t\tlistPhotos.querySelectorAll('.image-container').forEach(dom => dom.onclick = openModal);\n\t}", "function filterChange() {\n updateFilter();\n pullEvents();\n //put events in page\n}", "function updateSlideContentDisplay() {\n if ( $('#customize-control-slider_posts_or_pages').find('input:checked').val() == 'pages' ) {\n $('#customize-control-slider_recent_posts').addClass('hide');\n $('#customize-control-slider_post_category').addClass('hide');\n $('#customize-control-slider_pages').removeClass('hide');\n } else {\n $('#customize-control-slider_pages').addClass('hide');\n $('#customize-control-slider_recent_posts').removeClass('hide');\n $('#customize-control-slider_post_category').removeClass('hide');\n }\n }", "function openPopupWithFilteredItems( contentName, placeholderid, formId, methodName, methodArgs,gridType,popupType){\r\n\t serialNo++;\r\n\t// Tolven.Util.log( \"Getting: \" + contentName );\r\n\t $('downloadStatus').innerHTML=\"Get \" + contentName + \"...\";\r\n\r\n\t // Update this block when ever a similar new wizard is added.\r\n\r\n\t // Update this block whenever a similar new wizard is added.\r\n\t\tnew Ajax.Request(\r\n\t\t 'createGridWithFilteredItems.ajaxcchit',\r\n\t\t {\r\n\t\t\tmethod: 'get',\r\n\t\t\tparameters: \"element=\"+contentName+\"&gridId=\"+placeholderid+\"&gridType=\"+gridType+\"&methodArgs=\"+methodArgs+\"&methodName=\"+methodName+\"&formId=\"+formId+\"&popupType=\"+popupType,\r\n\t\t\tonSuccess: function(request){ setPopupContentFiltered(request, placeholderid, formId ); },\r\n\t\t\tonFailure: function(request) {displayError(request,param);}\r\n\t\t });\r\n\t}", "async function fetchPreviewItemsInfo() {\n const newPreviewItems = [];\n for (const item of value.items) {\n if (item._type === 'captionedImage') {\n const { alt, url } = await client.fetch(/* groq */ `*[_id == \"${item.image._ref}\"][0]{\n \"alt\": image.alt,\n \"url\": image.asset->url\n }`);\n newPreviewItems.push({\n caption: item.caption,\n alt: `📸 ${alt}`,\n url,\n });\n } else if (item._type === 'captionedVideo') {\n const { alt, url } = await client.fetch(/* groq */ `*[_id == \"${item.video._ref}\"][0]{\n \"alt\": video.alt,\n \"url\": video.poster.asset->url\n }`);\n newPreviewItems.push({\n caption: item.caption,\n alt: `🎥 ${alt}`,\n url,\n });\n }\n }\n\n setPreviewItems(newPreviewItems);\n }", "function getAuthorFilterItems(){\n var tempFilterArray = [];\n for(i=0; i<blog.rawData.length; i++){\n tempFilterArray.push(blog.rawData[i].author);\n }\n // console.log(tempFilterArray);\n return tempFilterArray;\n }", "getContent(input) {\n return (this.content.find((content) => {\n return content.input === input;\n }) || null);\n }", "setStart(){\n\t\tlet urlstring = \"\";\n\t\tif(AuthService.userIsModerator()){\n\t\t\turlstring = \"article/getPendingArticle/\"\n\n\t\t} else {\n\t\t\turlstring = \"article/editPendingArticle/\"\n\t\t}\n\t\trequest.get( urlstring + this.state.id, {headers: {\n\t\t\t\"auth-token\": accessToken\n\n\t\t}}).then(response => response.data).then(data => {\n\t\t\tconsole.log(data)\n\t\t\tif(data.success){this.editorComponent &&\n\t\t\t\tthis.editorComponent.setContent(data.returnValuesForArticle.content);\n\t\t\t\tthis.updateContent(data.returnValuesForArticle.content)\n\t\t\t\tthis.setState({loaded: true,\n\t\t\t\ttitle: data.returnValuesForArticle.title})\n\t\t\t\treturn data\n\t\t\t\t} else {\n\t\t\t\t\tthis.editorComponent &&\n\t\t\t\t\tthis.editorComponent.setContent(\"\");\n\t\t\t\t\tthis.updateContent(\"\")\n\t\t\t\t\tthis.setState({loaded: true})\n\t\t\t\t}\n\t\t}).catch((err) =>{\n\t\t\tthis.setState({loaded: true})\n\t\t\tconsole.log(err)})\n\t}", "function getPreview(blogs, qty, callback) {\n for (var i = 0; i < qty && i < blogs.length; i++) {\n var html = md('' + fs.readFileSync(blogs[i].localUrl + '.markdown'));\n blogs[i].preview = html.substring(0, 400);\n }\n callback(blogs);\n }", "updateDraft(text) {\n TodoDispatcher.dispatch({\n type: TodoActionTypes.UPDATE_DRAFT,\n text,\n });\n }" ]
[ "0.57377356", "0.5270778", "0.526762", "0.5255141", "0.5207966", "0.51788485", "0.51779246", "0.51768345", "0.5156462", "0.5125829", "0.5097602", "0.506294", "0.5008472", "0.49900922", "0.4970971", "0.49272928", "0.49175787", "0.49066842", "0.488469", "0.48751068", "0.48486567", "0.48484588", "0.48446333", "0.4836885", "0.4818712", "0.48155802", "0.4811888", "0.4805841", "0.47902402", "0.47708583", "0.47663805", "0.4744661", "0.4741781", "0.47413146", "0.4737317", "0.47352964", "0.47289526", "0.4724917", "0.4719324", "0.4716744", "0.47160462", "0.4715791", "0.47070548", "0.47020313", "0.46995938", "0.46993855", "0.46990463", "0.46962214", "0.4692531", "0.4688537", "0.46867898", "0.46865025", "0.46712917", "0.46681547", "0.4663024", "0.46614885", "0.4659406", "0.46491453", "0.46465194", "0.4646352", "0.46390098", "0.4636942", "0.46305147", "0.4623966", "0.46226972", "0.46216485", "0.4620108", "0.46186998", "0.46125665", "0.46119604", "0.46092322", "0.46085858", "0.46030203", "0.46030203", "0.46030203", "0.46030203", "0.46030203", "0.46020034", "0.46008903", "0.4598617", "0.45954835", "0.4583133", "0.45826173", "0.45760047", "0.4571079", "0.45678514", "0.45672396", "0.45660964", "0.45654303", "0.45614102", "0.45590794", "0.4558204", "0.45564333", "0.45544133", "0.45519218", "0.45491734", "0.45478472", "0.45455873", "0.45449772", "0.45446655" ]
0.53065634
1
init data struct node
constructor(item = null) { this.item = item; this.next = null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "init(node) {\n const properties = node.props;\n const eid = properties.id;\n const data_node = {\n eid,\n type: node.type,\n name: properties.name,\n children: reduce(properties.children, (acc, child) => { if (is.not.string(child)) {\n acc.push(child.props.id);\n } return acc; }, []),\n };\n this.bitmasks[eid] = BitSet.create();\n this.views[eid] = Reflect.getMetadata('link:structure-view', node); // link view hacky\n this.add('node', eid, data_node);\n this.add('transform', eid);\n each(properties, (data, name_cell) => {\n name_cell = startsWith(name_cell, 'c-') ? rightOf(name_cell, 'c-') : '';\n if (!name_cell) {\n return;\n } // continue\n this.add(name_cell, eid, data);\n });\n each(properties.children, (child) => {\n if (is.string(child)) {\n return;\n }\n this.init(child);\n });\n return this;\n }", "constructor(data = null) {\n if (!!data) {\n this.head = new Node(data)\n } else {\n this.head = null\n }\n }", "constructor (data, nodeType) {\n this._data = data;\n this.nodeType = nodeType;\n }", "initData(data) {\n this.status = data.status;\n this.id = data.id;\n }", "constructor(data) {\n this.data = data\n this.next = null\n }", "function Node(data) {\n this.data = data;\n}", "init(data) {\r\n this.object = data.object;\r\n }", "function initNode(dataObject) {\n var newDataObj = {};\n var selfLink;\n var parentLink;\n var childrenLink;\n\n for (var key in dataObject) {\n var value = dataObject[key];\n\n // _links must be checked first since its an array\n if (key == VDB_KEYS.LINKS.ID) {\n selfLink = RepoRestService.getLink(VDB_KEYS.LINKS.SELF, dataObject);\n parentLink = RepoRestService.getLink(VDB_KEYS.LINKS.PARENT, dataObject);\n childrenLink = RepoRestService.getLink(VDB_KEYS.LINKS.CHILDREN, dataObject);\n\n } else if (typeof (value) == 'string' || typeof (value) == 'number' || typeof (value) == 'boolean' ||\n angular.isArray(value)) {\n newDataObj[key] = value;\n }\n }\n\n if (!selfLink)\n return null;\n\n newDataObj.selfLink = selfLink;\n newDataObj.parentLink = parentLink;\n newDataObj.childrenLink = childrenLink;\n dataIndex[selfLink] = dataObject;\n\n return newDataObj;\n }", "static createNode (data) {\n return {\n prev: null,\n next: null,\n data: data\n }\n }", "function initData() {\n let data = {};\n data[\"path\"] = [null];\n data[\"name\"] = [null];\n data[\"warning\"] = [null];\n return data;\n}", "initData(data) {\n if (!data || !data.sys) {\n return;\n }\n this.data = this.data || {};\n let dict = data.sys.dict;\n let protos = data.sys.protos;\n\n //Init compress dict\n if (dict) {\n this.data.dict = dict;\n this.data.abbrs = {};\n\n for (let route in dict) {\n this.data.abbrs[dict[route]] = route;\n }\n }\n\n //Init protobuf protos\n if (protos) {\n this.data.protos = {\n server: protos.server || {},\n client: protos.client || {}\n };\n if (!tools.isNull(this.protobuf)) {\n this.protobuf.init({\n encoderProtos: protos.client,\n decoderProtos: protos.server\n });\n }\n }\n }", "constructor () {\n this.data = {}\n }", "constructor() {\n super();\n this.data = new Data();\n }", "function Node(data, parent){\n this.construct(data, parent);\n }", "function initBgpData() {\n bgpData.name = hostname;\n bgpData.children = [];\n\n}", "constructor(data = {}) {\n super(data);\n \n this.init(data);\n }", "function createCustomData() {\n return {\n dict: {},\n nextNodeId: 1,\n };\n}", "constructor() {\n this.data = {};\n }", "constructor() {\n this.data = {};\n }", "constructor(data) {\n this.data = data;\n }", "constructor(data) { }", "constructor(data){\n this.data = data;\n this.children = []; //every node has children array, every child can have some number\n }", "function Data(tag, fields) {\n this.type = DATA;\n this.tag = tag;\n this.fields = fields;\n}", "makeData (callback) {\n\t\tthis.init(callback);\n\t}", "makeData (callback) {\n\t\tthis.init(callback);\n\t}", "makeData (callback) {\n\t\tthis.init(callback);\n\t}", "makeData (callback) {\n\t\tthis.init(callback);\n\t}", "constructor(_data = {}) {\n this._data = _data;\n }", "function Data() { }", "initialize(data) {\n this.$exists = false;\n this.$changed = {};\n this.$attributes = {};\n this.fill(data);\n this.$initialized = true;\n\n return this;\n }", "function Node(data) {\n this.data = data === undefined ? null : data;\n this.next = null;\n}", "init (data = {}) {\n for(let key in data){\n this[key] = data[key];\n }\n }", "init (data = {}) {\n for(let key in data){\n this[key] = data[key];\n }\n }", "function initData() {\n initLtr_factor();\n initBosunit();\n initHero();\n initSelect25();\n initMS();\n}", "function Node(data) {\n\t\tthis.data = data;\n\t\tthis.next = null;\n\t}", "constructor(data) {\n this.data = data;\n }", "function assignData(node, data) {\n node.__data__ = data;\n}", "constructor(data) {\n \n }", "constructor(id, data = ''){\n\t\tthis.id = id;\n this.data = data;\t\t\n\t}", "function Data() {\n this.columns = null;\n this.items = null;\n this.projection = null;\n this.num_rows = 0;\n this.num_cols = 0;\n}", "function Data()\n{\n //parameters\n this.total = 0;\n this.domestic = 0;\n this.transborder = 0;\n this.other = 0;\n}", "function Node(data) {\n this.data = data;\n this.next = null;\n }", "function ElementData(){}", "constructor () {\n this.#data = {} // Objeto vazio\n this.#tail = -1 // Pilha vazia\n }", "constructor(init) {\n init = init || {};\n this.content = {\n date: init.date || new Date().toISOString(),\n version: require('../package.json').version,\n tables: init.tables || [],\n columns: {},\n rows: {},\n data: init.data || {},\n };\n }", "function initializeDtxData(){\n return {\n \"chartInfo\":{\n \"title\": \"\",\n \"artist\": \"\",\n \"bpm\": 0.0,\n \"level\": 0.00\n },\n \"metadata\": {\n \"totalNoteCount\": 0,\n \"LC_Count\": 0,\n \"HH_Count\": 0,\n \"LP_Count\": 0,\n \"LB_Count\": 0,\n \"SD_Count\": 0,\n \"HT_Count\": 0,\n \"BD_Count\": 0,\n \"LT_Count\": 0,\n \"FT_Count\": 0,\n \"RC_Count\": 0,\n \"RD_Count\": 0\n },\n \"barGroups\": []\n };\n }", "function Node(id, data) {\n\t this.id = id;\n\t this.links = null;\n\t this.data = data;\n\t}", "constructor(data, next = null) {\n this.data = data;\n this.next = next;\n }", "constructor(data, next = null) {\n this.data = data;\n this.next = next;\n }", "function fullInit(options)\n\t{\n\t\t_data = options.data;\n\t}", "function fullInit(options)\n\t{\n\t\t_data = options.data;\n\t}", "init(){\n var self = this;\n self.generateData();\n self.insertInfo();\n self.copyData();\n }", "function _init() {\n addEvent();\n getData();\n }", "constructor(data) {\n this.type = data.type;\n this.byDevice = data.byDevice;\n this.byMonth = data.byMonth;\n this.symbol = data.symbol;\n }", "function Node(data) {\n this.data = data\n this.next = null;\n}", "function Node(data) {\n DataDoo.DDObject3D.call(this);\n this.data = data || {};\n }", "function Node(data){\n this.data = data;\n this.left = null;\n this.right = null;\n this.height = 0;\n }", "function Node(data) {\n this.prev = null\n this.next = null\n this.data = data\n}", "function LC() {\n this.data = {};\n}", "function Node(data) {\n this.data = data;\n this.next = null;\n}", "function Node(data) {\n this.data = data;\n this.next = null;\n}", "function Node(data) {\n this.data = data;\n this.next = null;\n}", "function Node(data) {\n this.data = data;\n this.next = null;\n}", "function Node(data) {\n this.data = data;\n this.next = null;\n}", "function Node(data) {\n this.data = data;\n this.next = null;\n}", "function WixLabelData() {\n\n /**\n * The id of the Label\n * @member WixLabelData#id\n * @type {string}\n */\n\n /**\n * A timestamp to indicate when this Label was created\n * @member\n * @type {Date}\n */\n this.createdAt = new Date().toISOString();\n\n /**\n * Label name\n * @member\n * @type {String}\n */\n this.name = null;\n\n /**\n * Label description\n * @member\n * @type {String}\n */\n this.description = null;\n\n /**\n * Label totalMembers\n * @member\n * @type {Number}\n */\n this.totalMembers = null;\n\n /**\n * Label labelType\n * @member\n * @type {String}\n */\n this.labelType = null;\n\n /**\n * @private\n */\n this.init = function(obj) {\n this.id = obj.id;\n this.name = obj.name;\n this.description = obj.description;\n this.totalMembers = obj.totalMembers;\n this.labelType = obj.labelType;\n this.createdAt = obj.createdAt;\n return this;\n };\n}", "constructor (data) {\n // Block data model\n this.hash = \"\",\n this.height = 0,\n this.prev_block = \"\",\n this.time = 0,\n this.body = data\n }", "constructor() {\n this.nodeTree = {};\n this.numberOfValues = 0;\n }", "static initialize(obj, type, operation, value) { \n obj['type'] = type;\n obj['operation'] = operation;\n obj['value'] = value;\n }", "constructor() {\n this.data = this._loadData();\n }", "constructor( data ){\n this._emitter = new EventTarget();\n this._converters = new Map();\n this._dynamicProperties = false;\n this._data = data;\n }", "function DataBlock(numDataCodewords, codewords)\r\n{\r\n\tthis.numDataCodewords = numDataCodewords;\r\n\tthis.codewords = codewords;\r\n\t\r\n\tthis.__defineGetter__(\"NumDataCodewords\", function()\r\n\t{\r\n\t\treturn this.numDataCodewords;\r\n\t});\r\n\tthis.__defineGetter__(\"Codewords\", function()\r\n\t{\r\n\t\treturn this.codewords;\r\n\t});\r\n}", "constructor(data) {\n super(data);\n }", "function Node(data) {\n this.data - data;\n this.next = null;\n}", "function initData() {\n\tsensorTypes = {};\n}", "function Node(data, next){\n this.data = data;\n this.next = next;\n}", "function Node(id, data) {\n this.id = id;\n this.links = null;\n this.data = data;\n}", "function Node(id, data) {\n this.id = id;\n this.links = null;\n this.data = data;\n}", "function ElementData() {}", "function ElementData() {}", "function ElementData() {}", "function Layout(node, data){\n this.node = node;\n this.auto = true;\n this.data = data || [];\n}", "SetData() {}", "constructor(data) {\n const dataKeys = Object.keys(data);\n for (let i = 0; i < dataKeys.length; i++) {\n this[dataKeys[i]] = data[dataKeys[i]];\n }\n }", "function _Data(config) {\n\n var me = this;\n\n // name, status, message\n this.config = {};\n\n\n (function() {\n var item;\n\n // defaults \\ validation\n if (!(\"type\" in config) || ((\"type\" in config) && config.type === undefined)) {\n config.type = _enum.TYPE_TEST;\n }\n\n // configuration settings\n for (item in config) {\n if (config.hasOwnProperty(item)) {\n me.config[item] = config[item];\n }\n }\n\n })();\n }", "set data(data) {\n // prevent error message - setters invoked in initialization of class\n if (data == null) { return }\n \n // destructuring of data sent from Data class. reassign to Class scope\n let { title, question } = data;\n this.type = title;\n this.question = question;\n\n }", "function Node(data) {\n this.data = data;\n this.parent = null;\n this.children = [];\n}", "addInitial(data, node, port, metadata) {\n if (!this.getNode(node)) { return; }\n\n port = this.getPortName(port);\n this.checkTransactionStart();\n let initializer = {\n from: {\n data\n },\n to: {\n node,\n port\n },\n metadata\n };\n this.initializers.push(initializer);\n this.emit('addInitial', initializer);\n\n this.checkTransactionEnd();\n return initializer;\n }", "constructor(data){ \n this.data = data;\n }", "function Data(dia, mes, ano) {\n if (ano === void 0) { ano = 1970; }\n this.dia = dia;\n this.mes = mes;\n this.ano = ano;\n // this.dia = dia;\n // this.mes = mes;\n // this.ano = ano;\n }", "function initializeData(data) {\n // TODO: Convert the properties \"income\", \"lifeExpectancy\" and \"population\" to the \"number\" type for each entry.\n data.forEach(row => {\n row.income = parseFloat(row.income);\n row.lifeExpectancy = parseFloat(row.lifeExpectancy);\n row.population = parseInt(row.population);\n });\n}", "function DataBlock(numDataCodewords, codewords)\n{\n\tthis.numDataCodewords = numDataCodewords;\n\tthis.codewords = codewords;\n\t\n\tthis.__defineGetter__(\"NumDataCodewords\", function()\n\t{\n\t\treturn this.numDataCodewords;\n\t});\n\tthis.__defineGetter__(\"Codewords\", function()\n\t{\n\t\treturn this.codewords;\n\t});\n}", "function initData(){\n o_data = user.original_musics;\n d_data = user.derivative_musics;\n c_data = user.collected_musics;\n}", "constructor() {\n\n /**\n * @type {Array.<{type: string, label: string, url: string}>}\n * @private\n */\n this._data = []\n }", "function DataObject() {\n\tthis.string = 'string';\n\tthis.number = 1234;\n\tthis.bool = false;\n\tthis.undef = undefined;\n\tthis.nul = null;\n\tthis.nan = NaN;\n\tthis.array = [1, 2, 3, 4];\n\tthis.func = function() {};\n\tthis.obj = {};\n}", "constructor (number = 1) {\n this.data = number;\n }", "constructor(data) {\n // data: Object\n let defaultData = {\n sid: null,\n author: \"\",\n bookname: \"\",\n category_sid: 0,\n book_id: \"\",\n publish_date: \"1970-01-01\",\n pages: 0,\n price: 0,\n isbn: \"\",\n on_sale: 1,\n introduction: \"\",\n };\n this.data = { ...defaultData, ...data };\n }", "init (data = {}) {\n for(let _key in data){\n this[_key] = data[_key];\n }\n }", "function initData(){\n dynarexDataIsland.init();\n loadFunctionTimes();\n setEventListener();\n}", "constructor(data)\n {\n super(data.width, data.height);\n\n this._width = data.width;\n this._height = data.height;\n this._key = data.key;\n\n this.once(\"added\", () => this.onAdded());\n }", "function Data() {\n\n this.expando = cepto.expando + Data.uid++;\n\n Object.defineProperty(this.cache = {}, 0, {\n get: function() {\n return {};\n }\n });\n\n}" ]
[ "0.6700351", "0.66975415", "0.644836", "0.63927436", "0.63778853", "0.6375047", "0.63728285", "0.63598233", "0.6344904", "0.63162774", "0.63127595", "0.6310561", "0.6282381", "0.62780637", "0.6262965", "0.62441224", "0.62425417", "0.623363", "0.623363", "0.6227975", "0.6224223", "0.6208392", "0.61834013", "0.61815757", "0.61815757", "0.61815757", "0.61815757", "0.6174469", "0.6157071", "0.6132636", "0.60965776", "0.60794383", "0.60794383", "0.60757715", "0.6074821", "0.6047312", "0.6046972", "0.6044601", "0.6036497", "0.60134995", "0.6011585", "0.5993278", "0.59884906", "0.5981208", "0.59781986", "0.5977382", "0.5975878", "0.59678084", "0.59678084", "0.59492964", "0.59492964", "0.5943491", "0.5933646", "0.59154826", "0.5879203", "0.5875236", "0.58750015", "0.58580387", "0.5855003", "0.58473086", "0.58459735", "0.58459735", "0.58459735", "0.58459735", "0.58459735", "0.58293766", "0.58125305", "0.5811664", "0.5803949", "0.57885444", "0.57852954", "0.57843995", "0.5783778", "0.57741785", "0.5769268", "0.57604337", "0.5759842", "0.5759842", "0.57566166", "0.57566166", "0.57566166", "0.5753747", "0.5748069", "0.5745949", "0.5733195", "0.5713707", "0.57100564", "0.569153", "0.5684836", "0.56723857", "0.5669575", "0.5667931", "0.5666521", "0.56658185", "0.56636643", "0.56614566", "0.5653278", "0.56434005", "0.5621063", "0.5620482", "0.5611179" ]
0.0
-1
persist current state.contacts should move this and have reducers resync
function _saveContacts(c){ Actions.saveContacts(c); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "saveContact(oldContactId, newName, newEmail, newNumber) {\n const {contacts} = this.state\n const foundContact = _.find(contacts, contact => contact.id === oldContactId);\n foundContact.name = newName;\n foundContact.email = newEmail;\n foundContact.number = newNumber;\n this.setState({\n contacts\n }, () => updateLocalStorage(\"contacts\", contacts))\n }", "createContact(name, email, number) {\n const {contacts} = this.state\n contacts.unshift({'id': uuid.v4(), name: name, email: email, number: number});\n this.setState({\n contacts\n }, () => updateLocalStorage(\"contacts\", contacts))\n }", "function saveContacts() {\n window.localStorage.setItem('contacts', JSON.stringify(contacts))\n sortContacts(sortType)\n drawContacts()\n}", "function saveContacts() {\n window.localStorage.setItem(\"contacts\", JSON.stringify(contacts))\n drawContacts()\n}", "function saveContacts() {\n window.localStorage.setItem(\"contacts\", JSON.stringify(contacts))\n drawContacts()\n}", "addContact () {\n store.addContact(this.store.newContact)\n this.store.newContact = { name: '', email: '' }\n }", "saveContact() {\n const contact = this.getContact();\n if (contact.isNew() || contact.isDirty()) {\n contact.save();\n }\n }", "handleAddContact() {\n const { firstName, sirName, date, contactItems } = this.state;\n const contactItem = {\n firstName: firstName,\n sirName: sirName,\n date: date\n };\n\n const newItems = [...contactItems, contactItem];\n localStorage.setItem('contactItems', JSON.stringify(newItems));\n this.setState({ contactItems: newItems, firstName: \"\", sirName: \"\" });\n }", "function saveContactInfo(name, email, number, city, state) {\n let newContactInfo = contactInfo.push();\n\n newContactInfo.set({\n name: name,\n email: email,\n number: number,\n city: city,\n state: state,\n\n });\n}", "function saveContact(inputValues) {\n contact.setValues(inputValues);\n var validation = contact.validate();\n if (validation) {\n app.f7.alert(validation);\n return;\n }\n var contacts = Persistence.getAllContacts();\n if (!state.isNew) {\n _.remove(contacts, { _id: contact._id });\n }\n contacts.push(contact);\n Persistence.setAllContacts(contacts);\n renderContactListView();\n closePage();\n }", "function addContact(contact) {\n contacts.push(contact);\n $localStorage.contacts = contacts;\n }", "createContact(contact) {\n ContactsAPI.create(contact).then(contact => {\n this.setState(state => ({\n // add a new contact in the state\n contacts: state.contacts.concat([ contact ])\n }))\n })\n }", "_storeState() {\n storage.set(this.itemId, JSON.stringify({\n lastVisit: Date.now(),\n commentCount: this.itemDescendantCount,\n maxCommentId: this.maxCommentId\n }))\n }", "function saveContactInfo(name, email, message) {\n let newContactInfo = contactInfo.push();\n sendAnimation()\n\n newContactInfo.set({\n name: name,\n email: email,\n message: message,\n });\n}", "function setContactsInStore(contacts) {\n return {\n type: SET_CONTACTS,\n contacts\n }\n}", "function addContact(state = [], action) {\n const userId = (state) ? (state.length + 1) : 1;\n\n return [\n //Keep the old state\n ...state,\n //Add the new contact\n {\n address : action.address,\n id: userId,\n mail : action.mail, \n name : action.name, \n phone: action.phone,\n surname : action.surname \n }\n ];\n}", "function saveContactInfo (name,email,subject,message) {\n \n let newContactInfo = contactInfo.push();\n\n newContactInfo.set({\n name: name,\n email: email,\n subject: subject,\n message: message\n });\n }", "addContact(contact){\n const { contacts } =this.state;\n this.setState({\n contacts: [ ...this.state.contacts, contact ]\n });\n }", "function saveContactInfo(name, email, message){\n let newContactInfo = contactInfo.push();\n\n\n newContactInfo.set({\n name : name,\n email: email,\n message: message,\n });\n}", "function updateContactList() {\r\n\tsupervisorsStore.load( {params: { method: \"loadSupervisors\"} } );\r\n\texpertsStore.load( {params: { method: \"loadExperts\"} } );\r\n\tpeersStore.load( {params: { method: \"loadPeers\"} } );\r\n agentsStore.load( {params: { method: \"loadFavorites\"} } );\r\n}", "function SaveUpdatedContactToPhonebook()\n{\n\tTi.API.info(\"SaveUpdatedContactToPhonebook\");\n\t\n\t// TODO: Replace this with return statement\n\tif(contact == null) alert(\"Contact must be initialized ya beheema !\");\n\t\n\tif(OS_IOS) {\n\t\tTitanium.Contacts.save();\n\t} \n\telse if(OS_ANDROID) {\n\t\t/* Titanium APIs or Android OS has a bug, which is saving a contact after editing it causes another contact got edited.\n\t\t * A workaround is to delete the exisiting contact with id and then add a new contact having each and every detail the\n\t\t * deleted contact had.\n\t\t */\n\t\t\n\t\tTitanium.Contacts.removePerson(contact);\n\t\t\n\t\tTi.Contacts.createPerson({\n\t\t\taddress : contact.address ? contact.address : null,\t// Dictionary\n\t\t\tbirthday : contact.birthday ? contact.birthday : \"\",\t// String\n\t\t\tdate : contact.date ? contact.date : null,\t// Dictionary\n\t\t\temail : contact.email ? contact.email : null,\t// Dictionary\n\t\t\tfirstName : contact.firstName ? contact.firstName : contact.fullName ? contact.fullName : \"\",\t// String\n\t\t\t// TODO: The image is not copied\n\t\t\timage : contact.image ? contact.image : null,\t// Image blob\n\t\t\t\n\t\t\tinstantMessage : contact.instantMessage ? contact.instantMessage : null,\t// Dictionary\n\t\t\tkind : Ti.Contacts.CONTACTS_KIND_PERSON,\n\t\t\tlastName : contact.lastName ? contact.lastName : \"\",\t// String\n\t\t\tmiddleName : contact.middleName ? contact.middleName : \"\",\t// String\n\t\t\tnickname : contact.nickname ? contact.nickname : \"\",\t// String\n\t\t\tnote : contact.note ? contact.note : \"\",\t// String\n\t\t\torganization : contact.organization ? contact.organization : \"\",\t// String\n\t\t\tphone : contact.phone ? contact.phone : null,\t// Dictionary\n\t\t\trelatedNames : contact.relatedNames ? contact.relatedNames : null,\t// Dictionary\n\t\t\turl : contact.url ? contact.url : null,\t// Dictionary\n\t\t});\n\t}\n\t\n\tcontact = null;\t// To avoid wrong use in future.\n\talert(\"Contact Updated in Phonebook !\");\n}", "function saveContactInfo(name, email, message){\n let newContactInfo = contactInfo.push();\n \n newContactInfo.set({\n name: name,\n email: email,\n message: message,\n });\n\n retrieveInfos();\n}", "function saveContactInfo(name, email, message){\n let newContactInfo = contact.push();\n\n newContactInfo.set({\n Name : name,\n Email: email,\n Message: message,\n })\n }", "deleteContact(contactToDeleteId) {\n const {contacts} = this.state\n _.remove(contacts, contact => contact.id === contactToDeleteId);\n this.setState({\n contacts\n }, () => updateLocalStorage(\"contacts\", contacts))\n }", "async storeData(contactList) {\n const contactListString = JSON.stringify(contactList);\n try {\n await AsyncStorage.setItem(\"CONTACTS\", contactListString);\n } catch(error) {\n console.log(error);\n }\n }", "save() {\n if (this._history.length > 9){\n this._history.shift();\n }\n this._history.push(this.internalData);\n // Make the commit to setup the index and the state\n this.commit();\n }", "function updateContact() {\n var contacts = getStoredContacts();\n var idEdited = JSON.parse(localStorage.idEdited);\n\n contacts.forEach(function (contact) {\n if(idEdited == contact.id) { // capitalize name initials (a little sanitation)\n contact.firstname = form.firstname.value[0].toUpperCase() + form.firstname.value.slice(1).toLowerCase(),\n contact.lastname = form.lastname.value[0].toUpperCase() + form.lastname.value.slice(1).toLowerCase(),\n contact.phone = form.phone.value,\n contact.address = form.address.value,\n contact.email = form.email.value\n }\n });\n\n // add contact to local storage\n localStorage.contacts = JSON.stringify(contacts);\n localStorage.idEdited = JSON.stringify('updated');\n}", "saveEmailInfo(email){\n let newContactInfo=emailInfo.push();\n newContactInfo.set({\n email:email\n })\n }", "updateContact (state, payload) {\n let contact = getContactByJid(state, payload.jid)\n if (contact) {\n Object.assign(contact, payload)\n } else {\n contact = new Contact(payload)\n // 存在系统消息模块,默认插到系统消息后\n state.contacts.splice(1, 0, contact)\n // 先更新列表再补充联系人与业务相关消息,避免列表延时显示\n state.uiCore.queryAddressBook(getIdFromJid(contact.jid), (user) => {\n for (let p in user) {\n if (contact.hasOwnProperty(p)) { contact[p] = user[p] }\n }\n })\n }\n }", "function saveContactInfo(email, comment, description, date) {\r\n let newContactInfo = contactInfo.push();\r\n\r\n newContactInfo.set({\r\n email: email,\r\n comment: comment,\r\n description: description,\r\n date: date\r\n });\r\n}", "function handleCreateContact() {\n const jwt = localStorage.getItem(\"token\");\n const payload = {\n name: `${name}`,\n email: `${email}`,\n };\n axios\n .post(`${defaults.serverUrl}/account/contact`, payload, {\n headers: {\n \"x-auth-token\": jwt,\n },\n })\n .then((res) => {\n const cloneContacts = JSON.parse(JSON.stringify(contacts));\n cloneContacts.push(res.data);\n setContacts(cloneContacts);\n })\n .catch((err) => {\n console.error(err);\n })\n .finally(() => {\n // clear the input boxes\n setName(\"\");\n setEmail(\"\");\n });\n }", "function clearStoredContacts() {\n app.storage.getData(chkErr(function(data) {\n \n if (data.length > 0) {\n\n for (var i = 0; i < data.length; i++ ) {\n\n contacts.shift(data[i]);\n } \n\n }\n })); \n }", "function saveContactInfo(name, email, message) {\n\tlet newContactInfo = contactInfo.push();\n\n\tnewContactInfo.set({\n\t\tname: name,\n\t\temail: email,\n\t\tmessage: message,\n\t});\n\tretrieveInfos();\n}", "componentWillMount() {\n localStorage.getItem('Contacts') && this.setState({\n contacts: JSON.parse(localStorage.getItem('Contacts'))\n })\n }", "function App() {\n\n const [contacts, setContacts] = useState([]);\n const LOCAL_STORAGE_KEY = \"contacts\"\n\n const addContactHandler = (contact) => {\n const checkData = contacts.filter((contact1) => {\n return (contact1.email === contact.email)\n })\n if (checkData.length === 1) {\n alert(\"Email id is already existed\")\n\n }\n else {\n setContacts([...contacts, { id: uuid(), ...contact }])\n }\n\n }\n\n const updateContactHandler = (contact1) => {\n setContacts(contacts.map((contact) => {\n return contact.id === contact1.id ? { ...contact1 } : contact\n }))\n }\n\n const removeContactHandler = (id) => {\n const newContactList = contacts.filter((contact) => {\n return contact.id !== id\n })\n setContacts(newContactList);\n }\n\n const loginHandler = (loginData) => {\n const checkData = contacts.filter((contact) => {\n return (contact.name === loginData.name && contact.email === loginData.email)\n })\n if (checkData.length === 1) {\n alert(\"Welcome to React World\")\n\n }\n else {\n alert(\"something is wrong\")\n }\n }\n\n useEffect(() => {\n const retrieveContacts = JSON.parse(localStorage.getItem(LOCAL_STORAGE_KEY))\n if (retrieveContacts)\n setContacts(retrieveContacts)\n }, [])\n\n useEffect(() => {\n localStorage.setItem(LOCAL_STORAGE_KEY, JSON.stringify(contacts))\n }, [contacts])\n\n\n return (\n <div className=\"mainDiv\">\n <Router>\n <Header />\n <Switch>\n <div className=\"background\">\n <Route path=\"/add\" render={props => <AddContacts {...props} addContact={addContactHandler} />} />\n <Route path=\"/\" exact render={props => <ContactList {...props} contacts={contacts}\n getContactId={removeContactHandler} />} />\n <Route path=\"/contact/:id\" component={ContactDetails} />\n <Route path=\"/edit/:id\" render={props => <EditContact {...props} updateContact={updateContactHandler} />} />\n <Route path=\"/login\" render={props => <LoginPage {...props} getlogindata={loginHandler} />} />\n <Route path=\"/welcome\" render={props => { <WelcomePage {...props} /> }} />\n </div>\n </Switch>\n </Router>\n </div >\n );\n}", "function saveContactInfo(name, email, message) {\r\n let newContactInfo = contactInfo.push();\r\n\r\n newContactInfo.set({\r\n Username: name,\r\n email: email,\r\n message: message,\r\n });\r\n}", "createContact() {\n // check if it is allowed to save\n if (this.onCreateAction && !this.saveDisabled) {\n // disable save until it is finished\n this.toggleProperty('saveDisabled');\n\n // call the onCreate action\n this.onCreateAction(this.model).then(() => {\n // enable save again\n this.toggleProperty('saveDisabled');\n // reset the model's attributes\n this.set('model', {});\n });\n }\n }", "function onSaveContact(e) {\n \n var toSave;\n if (activeContact) {\n toSave = activeContact;\n } else {\n toSave = navigator.contacts.create();\n }\n \n // name saving:\n initName();\n \n // nickname saving:\n toSave.nickname = contactForm.getNickname();\n \n // phones saving:\n initContactFieldVals(\"phoneNumbers\", contactForm.getPhoneNumbers());\n \n // emails saving:\n initContactFieldVals(\"emails\", contactForm.getEmails());\n \n // ims saving:\n initContactFieldVals(\"ims\", contactForm.getIMs());\n \n // urls saving:\n initContactFieldVals(\"urls\", contactForm.getURLs());\n \n // addresses saving:\n initContactFieldVals(\"addresses\", contactForm.getAddresses());\n \n // organizations saving:\n initContactFieldVals(\"organizations\", contactForm.getOrganizations());\n \n // note saving:\n var note = contactForm.getNote();\n if (!isEmptyOrBlank(note)) {\n toSave.note = note;\n }\n \n // photo saving:\n initContactFieldVals(\"photos\", contactForm.getPhotos());\n \n toSave.save(onSuccess,onError);\n \n function onSuccess(contact) {\n alert(\"The contact was successfully saved\");\n displContactList.updateList();\n $.mobile.changePage(\"#cont_list_page\", { transition: \"pop\" });\n };\n\n function onError(contactError) {\n alert(\"The contact cannot be saved: error: \" + contactError.code);\n };\n \n function initName() {\n \n if (!toSave.name) {\n toSave.name = new ContactName();\n }\n var nameData = contactForm.getNames();\n toSave.name.givenName = nameData.givenName;\n toSave.name.familyName = nameData.familyName;\n toSave.name.middleName = nameData.middleName;\n toSave.name.honorificPrefix = nameData.honorificPrefix;\n toSave.name.honorificSuffix = nameData.honorificSuffix;\n };\n \n function initContactFieldVals(contactFieldName, contactFieldValsArray) {\n \n if (!toSave[contactFieldName] && (contactFieldValsArray.length > 0)) {\n toSave[contactFieldName] = [];\n } \n for (var i = 0; i < contactFieldValsArray.length; i++) {\n if (!toSave[contactFieldName][i]) {\n if (contactFieldName == \"addresses\") {\n toSave[contactFieldName][i] = new ContactAddress();\n } else if (contactFieldName == \"organizations\") {\n toSave[contactFieldName][i] = new ContactOrganization();\n } else {\n toSave[contactFieldName][i] = new ContactField();\n }\n }\n for (var key in contactFieldValsArray[i]) {\n toSave[contactFieldName][i][key] = contactFieldValsArray[i][key];\n }\n }\n if (toSave[contactFieldName]) {\n for (var i = contactFieldValsArray.length; i < toSave[contactFieldName].length; i++) {\n if (toSave[contactFieldName][i]) {\n for (var key in toSave[contactFieldName][i]) {\n if (key.toLowerCase() != \"id\") {\n toSave[contactFieldName][i][key] = \"\";\n }\n }\n }\n }\n }\n };\n}", "_saveCustomer(){\n if (Object.keys(this.customer).length === 7) {\n this.storage.setData('customers', this.customer, this.formState);\n this._cancel();\n }\n }", "addContact(contact) {\n // Create a new array with the list of existing items and the new contact at the end\n this.data = [...this.data, contact];\n\n // Rerender the list\n this.render();\n }", "handleNewContact(newContact) {\n\t\tthis.setState( lastState => ({\n\t\t\tcontactList: [...lastState.contactList, newContact]\n\t\t\t}))\n\t\tif (newContact.gender === \"Male\") {\n\t\t\tthis.state.genderCount[0] +=1;\n\t\t} else if (newContact.gender === \"Female\") {\n\t\t\tthis.state.genderCount[1] +=1;\n\t\t} else {\n\t\t\tthis.state.genderCount[2] +=1;\n\t\t}\n\t\t\n\t}", "_outgoing() {\n // Try to fill in the displayName from contacts.\n const contacts = this.app.state.contacts.contacts\n let displayName = ''\n for (const id of Object.keys(contacts)) {\n if (contacts[id].number === parseInt(this.number)) {\n displayName = contacts[id].name\n }\n }\n\n if (!this.silent) {\n // Always set this call to be the active call as soon a new\n // connection has been made.\n this.module.activateCall(this, true)\n let message = ''\n if (displayName) message = `${this.state.number}: ${displayName}`\n else message = this.state.number\n this.app.modules.ui.notification({message, number: this.state.number, title: this.translations.create})\n }\n\n this.setState({displayName: displayName, status: this._statusMap.create})\n this.app.setState({ui: {layer: 'calls', menubar: {event: 'ringing'}}})\n }", "finishSubmit(){\n let validation = this.state.isValid;\n let isValid = this._formValid();\n\n if (isValid){\n let contact = {\n lastname: this.state.lastname,\n firstname: this.state.firstname,\n date: this.state.date.format('YYYY-MM-DDTHH:mm:ss') + 'Z',\n title: this.state.title,\n highschool: this.state.highschool,\n notes: this.state.notes,\n phone: this.state.phone,\n email: this.state.email,\n selected1: this.state.selected[0],\n selected2: this.state.selected[1],\n selected3: this.state.selected[2]\n }\n\n // Store it in the local indexed db\n database.storeContact(contact)\n .then((success) => {\n\n // It will publish an event that will bubble to the header to change the counter\n PubSub.publish('contacts', 'New contact');\n\n for (let property in validation){\n if (validation.hasOwnProperty(property)){\n this.setState({\n isValid: {\n [property] : false\n }\n })\n }\n }\n\n PubSub.publish('selections', 0);\n\n // Reset the form to not edited\n this.setState({\n edited: false\n })\n\n // We need to clear out the form\n this._clearForm();\n\n toast(<h3>Successfully stored the new contact.</h3>, {\n type: 'success',\n hideProgressBar: true,\n position: toast.POSITION.TOP_RIGHT\n }) \n });\n\n \n\n }\n }", "_welcomeIfNewNode(contact, cb = ()=>{} ){\n\n if (this._kademliaNode.routingTable.map[ contact.identityHex ] || contact.identity.equals( this._kademliaNode.contact.identity ))\n return cb(null, \"already\");\n\n this._kademliaNode.routingTable.addContact(contact);\n\n if (this._replicatedStoreToNewNodesAlready[contact.identityHex])\n return cb(null, \"skipped\");\n\n this._replicatedStoreToNewNodesAlready[contact.identityHex] = Date.now();\n this._replicateStoreToNewNode(contact, undefined, cb )\n\n }", "componentDidMount() {\n //localStorage.clear()\n const cachedTasks = localStorage.getItem('contacts')\n this.setState({\n contacts: cachedTasks\n ? parseObject(cachedTasks)\n : []\n })\n }", "function contacts(state = new Map(), action) {\n\n switch (action.type) {\n case 'ADD_CONTACT': { // Parentheses are needed for creating local variables\n const newContacts = new Map(state); // Clone contacts\n newContacts.set(action.name, action.item);\n // Return the new state with new contact\n return newContacts;\n }\n\n case 'EDIT_CONTACT': { // Parentheses are needed for creating local variables\n const newContacts = new Map(state); // Clone contacts\n newContacts.delete(action.oldName);\n newContacts.set(action.newName, action.item);\n // Return the new state with edited contact\n return newContacts;\n }\n\n case 'REMOVE_CONTACT': { // Parentheses are needed for creating local variables\n const newContacts = new Map(state); // Clone contacts\n newContacts.delete(action.name);\n // Return the new state without the deleted contact\n return newContacts;\n }\n default:\n return state;\n }\n return state;\n}", "updateRecords() {\r\n\t\tlocalStorage.setItem( this.type, JSON.stringify(this.data) );\r\n\t}", "save () { this.store.saveSync() }", "storeGraphConnector() {\n let _this = this;\n\n _this.storageManager.set('graphConnector:globalRegistryRecord', 0, _this.globalRegistryRecord);\n _this.storageManager.set('graphConnector:contacts', 0, _this.contacts);\n _this.storageManager.set('graphConnector:groups', 0, _this.groups);\n _this.storageManager.set('graphConnector:privateKey', 0, _this.privateKey);\n _this.storageManager.set('graphConnector:firstName', 0, _this.firstName);\n _this.storageManager.set('graphConnector:lastName', 0, _this.lastName);\n _this.storageManager.set('graphConnector:lastCalculationBloomFilter1Hop', 0, _this.lastCalculationBloomFilter1Hop);\n _this.storageManager.set('graphConnector:residenceLocation', 0, _this.residenceLocation);\n\n }", "function saveCurrentContactName(contactName){\n PropertiesService.getUserProperties().setProperty(\"currentContact\", contactName);\n}", "function setSelectedContactForChat(contactId) {\n localStorage.setItem(configSrvc.cidLocalStorage, contactId);\n }", "save (state, payload) {\n state.firstName = payload.firstName\n state.lastName = payload.lastName\n state.age = payload.age\n state.mobileNumber = payload.mobileNumber\n state.emailAddress = payload.emailAddress\n state.dateOfBirth = payload.dateOfBirth\n state.customerQuery = payload.customerQuery\n }", "async componentDidMount() {\n const localContactBook = localStorage.getItem('contact_book');\n const response = localContactBook || await fetch('http://demo.sibers.com/users');\n const contacts = JSON.parse(localContactBook) || await response.json();\n if (!localContactBook) localStorage.setItem('contact_book', JSON.stringify(contacts));\n this.setState({contacts: contacts, filterContacts: contacts});\n }", "revertContact() {\n this.getContact().restore();\n }", "fetchContacts() {\n Contacts.getAll((err, contacts) => {\n if (err && err.type === 'permissionDenied'){\n console.log('permission denied!')\n this.setState({\n loaded: true,\n permission: 'no',\n });\n } else if (err) {\n console.log(err);\n // should probably show an error message in the ui\n } else {\n // add more dummy entries for testing purposes only\n // if (contacts.length < 10) {\n // contacts = contacts.concat(_.map(contacts, c => {\n // var d = _.clone(c); d.recordID *= 100; return d;\n // }));\n // }\n // add test entry\n var testEntry = _.clone(contacts[0]);\n testEntry.givenName = 'Venkat';\n testEntry.familyName = 'Quone Test';\n testEntry.phoneNumbers[0].number = myPhone;\n testEntry.recordID = 19642;\n contacts = contacts.concat([testEntry]);\n\n this.setState({\n loaded: true,\n permission: 'yes',\n contacts: this.getContactsRows(contacts)\n });\n console.log(this.state.contacts);\n }\n })\n }", "contact(state) {\n return state.contact;\n }", "function AddressBook() {\n this.contacts = [],\n this.currentId = 0\n}", "componentDidMount() {\n this.setState({\n contacts: JSON.parse(localStorage.getItem('contacts')) || []\n });\n }", "_save() {\n if (this.store && localStorage) {\n localStorage.setItem(this.store, JSON.stringify(this.records));\n }\n }", "function refreshContacts() {\n client.contacts.refresh()\n}", "updateCustomers(state, payload){\n state.customers = payload;\n }", "function mapStateToProps(state) {\n return {contacts: state.contactReducer.contacts};\n}", "function setSelectedContactForInfo(contactId) {\n localStorage.setItem(configSrvc.cinfoLocalStorage, contactId);\n }", "function addContactToPhoneBook(currentObj) {\n var phoneNumbers = currentObj.phoneNumbers.split(',');\n var contact = readContact(currentObj.id, currentObj.firstName, currentObj.lastName, phoneNumbers);\n pushItem(currentGroup, contact);\n }", "deleteContact(event) {\n const { contactItems } = this.state;\n const target = event.target;\n const value = target.value;\n\n const newContactItems = contactItems;\n if (value > -1) {\n newContactItems.splice(value, 1);\n }\n\n localStorage.setItem('contactItems', JSON.stringify(newContactItems));\n this.setState({ contactItems: newContactItems, firstName: \"\", sirName: \"\" });\n }", "saveData(){\n\t\t\t\tlocalStorage.clear();\n\t\t\t\tlet postData = {\n\t\t\t\t\t\t\t\t\t invoice: {\n\t\t\t\t\t\t\t\t\t customers: [\n\t\t\t\t\t\t\t\t\t {\n\t\t\t\t\t\t\t\t\t name: this.state.name,\n\t\t\t\t\t\t\t\t\t email: this.state.email,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tdate: window.selectedDate,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tamountTotal: this.state.amountTotal.toFixed(2),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tlineItems: this.state.lineItemsArray\n\t\t\t\t\t\t\t\t\t }\n\t\t\t\t\t\t\t\t\t ]\n\t\t\t\t\t\t\t\t\t }\n\t\t\t\t\t\t\t\t\t};\n\t\t\t\tlocalStorage.setItem('storeData', JSON.stringify(postData));\n\t\t\t\tnotify.show(\"Invoice successfully saved/sent\", \"success\", 2000,\"#0E1717\");\n\t\t\t\twindow.setTimeout(function(){location.reload()},1000)\n\t\t}", "function onClickSaveContact()\n{\t\n\t/*On crée un tableau pour pouvoir enregistrer plusieurs lignes dans Address Book, qui contiendront les infos de contact sous forme de tableau dans un tableau*/\n\tvar addressBook = [];\n\n\t/*stock les valeurs entrées par l'utilisateur dans la variable contact via la fonction createContact()*/\n\tvar contact = createContact(\n\t\t\t\t\t/*permet de récupérer les valeurs rentrées par l'utilisateur dans les champs du formulaire*/\n $('select[name=title]').val(), \n $('input[name=lastName]').val(), \n $('input[name=firstName]').val(), \n $('input[name=phone]').val() \n );\n\n\t/*On écrase le dernier addressBook avec le tableau comportant les nouvelles données, évite d'écraser les contacts déjà existants : va stocker dans adressBook tout ce qui a été loadé*/\n\t\t/*rajoute pas un contact à tableau existant mais écrase ancien tableau par nouveau contenant contact en plus*/\n\taddressBook = loadAddressBook();\n\n\n\t// va rajouter la propriété data-index ayant pour valeur l'index dans la balise a suivant celle ayant un id contact-details. Lie l'index du tableau de contacts (donc le contact que l'on veut) avec le lien cliquable sur le nom du contact. Va sauvegarder le contact dans le local storage\n\t\t//stocke ça dans variable index\n \tvar index = $('#contact-details a').data('index');\n \n \t// si l'attribut data-mode vaut 'add'\n if ($('#contact-form').data('mode') == 'add'){\n \t\t/*Permet de pousser contact dans le tableau, transforme ses données en tableau contenu dans un index*/\n \t\taddressBook.push(contact);\n } else {\n \t\t// sinon va charger le contact dans l'index correspondant dans addressBook\n \t\taddressBook[index] = contact;\n }\n\n /*stock les valeurs de contact dans la clée Adress Book*/\n\tsaveAddressBook(addressBook);\n\n\t/*cache la partie ajouter contact au moment d'enregistrer*/\n $('#contact-form').fadeOut('slow');\n $('#contact-details').hide();\n \n /*Affiche dans la section adress-book*/\n refreshAddressBook();\n}", "_updateCollectionState() {\n this.setState({\n addressCollection: this.controller.getAddressCollection()\n });\n }", "async preSave () {\n\t\tawait this.getStream();\n\t\tawait this.getTeam();\n\t\tawait this.checkNameUnique();\n\t\tawait this.checkNameForProvider();\n\t\tawait this.getUsers();\n\t\tawait this.clearUnreads();\n\t\tthis.attributes.modifiedAt = Date.now();\n\t\tawait super.preSave();\n\t}", "createContacts() {\n this.props.createApplicant(this.createContactValue(this.state.contact));\n }", "function AddressBook() {\n this.contacts = {};\n this.currentId = 0;\n}", "function AddressBook() {\n this.contacts = {};\n this.currentId = 0;\n}", "function save(phone, state, sync, shouldSynNotification) {\n var data = {\n phone: phone,\n state: state,\n fav: false,\n UISync: sync,\n UIShouldSyncNotification: shouldSynNotification,\n time: moment().toString()\n };\n\n dataRef.push(data);\n}", "onSave(){\n\t\tthis.props.updateCard(this.state)\n\t}", "function Addressbook() {\n this.contacts = [];\n this.currentId = 0;\n}", "function contacts(state = [], action) {\n switch (action.type) {\n case 'FETCH_REQUEST':\n const requested = Object.assign({}, state, {\n status: action.status\n })\n return requested;\n\n case 'FETCH_SUCCESS':\n const successful = Object.assign({}, state, {\n status: action.status,\n contact: action.contacts\n })\n return successful;\n\n case 'FETCH_FAILURE':\n const failed = Object.assign({}, state, {\n status: action.status,\n error: action.error\n })\n return failed;\n\n case ADD_ITEM:\n return [\n ...state,\n {\n name: action.name,\n phone1: action.phone1,\n phoneType1: action.phoneType1, \n phone2: action.phone2, \n phoneType2: action.phoneType2, \n phone3: action.phone3, \n phoneType3: action.phoneType3,\n email: action.email,\n address:action.address,\n }\n ];\n\n case DELETE_ITEM:\n return [\n ...state.slice(0, action.index),\n ...state.slice(action.index + 1)\n ];\n\n case EDIT_ITEM:\n return [\n ...state.slice(0, action.index),\n Object.assign({}, { \n name: action.name,\n phone1: action.phone1,\n phoneType1: action.phoneType1, \n phone2: action.phone2, \n phoneType2: action.phoneType2, \n phone3: action.phone3, \n phoneType3: action.phoneType3,\n email: action.email,\n address: action.address,\n }),\n ...state.slice(action.index + 1)\n ];\n\n default:\n return state;\n }\n}", "function persistLocalStorage() {\n _localStorage.setItem(_name, this.toJSON());\n }", "function loadContacts() {\n let storedContacts = JSON.parse(window.localStorage.getItem('contacts'))\n if (storedContacts) {\n contacts = storedContacts\n }\n}", "function loadContacts() {\n let storedContacts = JSON.parse(window.localStorage.getItem(\"contacts\"))\n if (storedContacts) {\n contacts = storedContacts\n }\n}", "function loadContacts() {\n let storedContacts = JSON.parse(window.localStorage.getItem(\"contacts\"))\n if (storedContacts) {\n contacts = storedContacts\n }\n}", "function sync() {\r\n // get data from the localStorage\r\n if (_.size(notesStorage.keys()) > 0) {\r\n // save in the data cloud\r\n postData(getUnsavedData())\r\n .then(function () {\r\n notesStorage.clearAll();\r\n }, function () {\r\n // an error while syncing has been occurred\r\n });\r\n }\r\n }", "_backToStart() {\n this.setState({\n cur: this.root\n })\n // Flush the old records\n // TODO: move out to be a function\n this.conversationRecords = [{\n type: this.root[0].type,\n content: this.root[0].content\n }]\n }", "function upsertContact() {\n var data = {};\n vm.isSubmit = true;\n\n // Bind typename\n angular.forEach(vm.contacts, function (contact) {\n contact.typeName = type[contact.typeId];\n });\n\n // If the StudentId and AcademicYearId are given in the route, this means that\n // the application will be modified by another person (Administrator).\n // Otherwise, the application will be modified by a student\n data.UserId = $routeParams.StudentId || Global.user.id;\n data.AcademicYearId = $routeParams.AcademicYearId || null;\n\n data.contacts = vm.contacts;\n\n\n $http.post('/api/scholarships/upsert/contacts', data).success(function (hs) {\n vm.isSuccess = true;\n // Reinit data for the sake of getting an id from DB\n Scholarships.reInit($routeParams.StudentId, $routeParams.AcademicYearId).then(function () {\n init();\n $timeout(function () {\n vm.isSaved = true;\n vm.isSuccess = false;\n vm.isSubmit = false;\n }, 5000);\n });\n }).error(function (err) {\n vm.isError = true;\n $timeout(function () {\n vm.isError = false;\n vm.isSubmit = false;\n }, 5000);\n\n });\n }", "persistLater(entity) {\n this.persist(entity);\n }", "function editContact() {\n\n for (let y = 0; y < saveEdit.length; y++) {\n let editItem = saveEdit[y];\n\n editItem.onclick = function (f) {\n let index = f.currentTarget.getAttribute('data-attr-index');\n let updatedAddress = displayList[y].value;\n let info = updatedAddress.split(\"|\");\n let contact = document.getElementsByClassName('contact');\n let contactValue = contact[y].value;\n \n\n name = contactValue;\n phoneNum = info[0];\n email_ = info[1];\n address_ = info[2];\n\n let savedAddress = JSON.parse(localStorage.getItem('addressBook'));\n\n if (savedAddress !== null) {\n savedAddress[index].name = name;\n savedAddress[index].phoneNo = phoneNum;\n savedAddress[index].email = email_;\n savedAddress[index].address = address_;\n\n localStorage.setItem(\"addressBook\", JSON.stringify(savedAddress));\n\n }\n alert('The Edited Contact has been saved');\n }\n\n }\n }", "storeNotes () {\n State.store('notifications', this.notes.map(n => {\n return {\n subject: n.subject,\n details: n.details,\n severity: n.severity,\n stamp: n.stamp,\n id: n.id,\n acked: n.acked\n }\n }))\n }", "function saveState() {\n if (currentView) {\n currentView.checkpoint();\n }\n ConferenceApp.State.local.navigationState = WinJS.Navigation.history;\n }", "@action\n saveToStore() {\n AsyncStorage.setItem(\"dates\", JSON.stringify(this.dates));\n AsyncStorage.setItem(\"content\", JSON.stringify(this.content));\n }", "function storeState() {\n\n localStorage.setItem(STORAGE_KEY, JSON.stringify(data));\n }", "persist() {\n localStorage.setItem(\n STORAGE_KEY + \"/\" + this.user.getId(),\n JSON.stringify(this.data)\n );\n }", "function refreshContactList (contacts) {\n pageContents.contacts = contacts;\n\n if (contacts.length === 0) {\n $(\".rolodex\").addClass(\"block\");\n }\n else {\n $(\".rolodex\").removeClass(\"block\");\n }\n $(\".rolodex\").html(listTemplate(pageContents));\n }", "static saveStackIntoCache() {\n if (!this.stack) return;\n const email = localStorage.getItem(\"email\");\n const mapped = this.loadStackFromCache();\n mapped[email] = this.stack;\n localStorage.setItem(\"pending_reqs\", btoa(JSON.stringify(mapped)));\n }", "function trackSelectedContacts() {\n return function(dispatch, getState) {\n var state = getState();\n // Get all of the selected contacts that untracked.\n var selectedContacts = getTargetedContacts(ContactTarget.SELECTED, state)\n .filter(function(contact) {\n return contact[model_2.CrmExtendedProperty.CRM_LINK_STATE] !==\n model_2.CrmExtendedProperty.CRM_LINK_STATE_LINKED;\n });\n if (selectedContacts.length == 0) {\n return dispatch(showAlert(resources_1.default.getString('MailApp_Module_Select_Track_Alert')));\n }\n dispatch({\n type: actionTypes_1.default.TRANSACTION_START,\n payload: {\n type: '',\n progressMax: selectedContacts.length\n }\n });\n var count = 0;\n selectedContacts.forEach(function(contact) {\n trackContact(contact,\n state.app.crmAccessKey,\n state.app.callbackToken,\n contact.index + 1,\n state.outlook.syncMapping).then(function(crmId) {\n count = count + 1;\n // Dispatch state update to refresh tracked status of affected rows\n dispatch({\n type: actionTypes_1.default.UPDATE_CONTACT,\n payload: {\n index: contact.index,\n values: (_a = {},\n _a[model_2.CrmExtendedProperty.CRM_ID] = crmId,\n _a[model_2.CrmExtendedProperty.CRM_LINK_STATE] = model_2.CrmExtendedProperty\n .CRM_LINK_STATE_LINKED,\n _a\n )\n }\n });\n // Update our transaction state\n dispatch({\n type: actionTypes_1.default.UPDATE_TRANSACTION,\n payload: count\n });\n if (count >= selectedContacts.length) {\n // After transaction is completed update state\n dispatch({ type: actionTypes_1.default.TRANSACTION_SUCCESS });\n dispatch(updateContactsCount());\n dispatcherHandler_1.sendTelemetryEvent({\n name: 'mailapp_module_track',\n data: {\n focused: false,\n count: count\n }\n });\n }\n var _a;\n },\n function(error) {\n console.error(error);\n });\n });\n };\n }", "function addNewContact(e) {\n if(form.firstname.value == '' || form.lastname.value == '' || form.phone.value == '' || form.email.value == '') {\n var removeNotice = showNotice('You have an empty form field', 'yellow', 'black');\n setTimeout(removeNotice, 3300);\n e.preventDefault();\n return;\n }\n\n // generate a unique id to identify a particular contact by\n var id = new Date().getTime();\n\n // create new contact\n var contact = {\n firstname : form.firstname.value,\n lastname : form.lastname.value,\n phone : form.phone.value,\n email : form.email.value,\n id : id\n }\n\n // capitalize name initials (a little sanitation)\n contact.firstname = contact.firstname[0].toUpperCase() + contact.firstname.slice(1).toLowerCase();\n contact.lastname = contact.lastname[0].toUpperCase() + contact.lastname.slice(1).toLowerCase();\n\n // add contact to DOM\n displayContact(contact);\n\n // add contact to local storage\n var contacts = getStoredContacts();\n contacts.push(contact);\n localStorage.contacts = JSON.stringify(contacts);\n\n // signal that contact has been added\n var removeNotice = showNotice('Contact has been added!', 'blue', 'black');\n setTimeout(removeNotice, 3300);\n\n displaySortButton();\n e.preventDefault();\n}", "function mapStateToProps(state){\r\n \r\n return {\r\n contacts : state\r\n }\r\n}", "componentWillUpdate(nextProps, nextState) {\n localStorage.setItem('todos', JSON.stringify(nextState.todos));\n }", "PostFixedProcess()\n\t{\n\t\tthis.ProcessContacts();\n\t\t\n\t\tthis.ResolveCollisionHistoryEvents(this.#Contacts, this.#ContactHistory);\n\t\tthis.ResolveCollisionHistoryEvents(this.#TriggerContacts, this.#TriggerHistory);\n\t\tthis.ResolveCollisionHistoryEvents(this.#DynamicContacts, this.#DynamicHistory);\n\t\t\n\t\tthis.#Contacts = [];\n\t\tthis.#TriggerContacts = [];\n\t\tthis.#DynamicContacts = [];\n\t}", "function reducer(action) {\n console.log(action);\n switch (action) {\n case 'reset':\n setContacts([]);\n break;\n case 'supp':\n contacts.shift();\n setContacts(contacts);\n break;\n case 'random':\n random();\n break;\n case 'reload':\n reaload();\n break;\n }\n }", "addPhone2List(state, action) {\n state.phonesList = action.payload;\n }", "componentDidUpdate(){\n localStorage.setItem('appointments', JSON.stringify(this.state.appointments));\n }" ]
[ "0.68885595", "0.6776804", "0.66792345", "0.6582764", "0.6582764", "0.6346726", "0.6301269", "0.61896855", "0.61066717", "0.6092939", "0.60800844", "0.6060277", "0.5969787", "0.59592855", "0.5931886", "0.58767194", "0.5866361", "0.58570933", "0.58174247", "0.5771048", "0.5770628", "0.5760833", "0.57589775", "0.57303137", "0.5714245", "0.568546", "0.56809515", "0.56798685", "0.565124", "0.5637119", "0.5613378", "0.5609305", "0.5561577", "0.55498546", "0.5541138", "0.55261993", "0.5521699", "0.55006665", "0.5478737", "0.54676056", "0.54645455", "0.54599553", "0.54508215", "0.54409456", "0.54168963", "0.54064655", "0.5403132", "0.54014236", "0.5386389", "0.5384713", "0.5374657", "0.53524363", "0.5349786", "0.5343124", "0.5339634", "0.5326943", "0.53198963", "0.5301007", "0.5299562", "0.5297661", "0.52911085", "0.528245", "0.52650076", "0.52548", "0.5253992", "0.52481896", "0.5229624", "0.5226141", "0.5215187", "0.52056605", "0.52037746", "0.52037746", "0.5193512", "0.51918375", "0.5189887", "0.51872456", "0.5175466", "0.5171891", "0.51657486", "0.51657486", "0.51623344", "0.5154491", "0.5143834", "0.51273", "0.5124468", "0.51207", "0.5116808", "0.5100712", "0.5095038", "0.5092434", "0.50916266", "0.50905067", "0.5089238", "0.5072615", "0.50685954", "0.5068458", "0.50618744", "0.5053447", "0.5048696", "0.50443125" ]
0.5941054
14
Creates a new LibraryAtlas
function LibraryAtlas(uid, shapePadding) { if (typeof shapePadding === "undefined") { shapePadding = 4; } this.uid = uid; this.shapePadding = shapePadding; /** * Contains the blocks used in the Binary Packing * @type {Array} */ this.blocks = []; LibraryAtlas.LIBS[uid] = this; // Create the Canvas&Context this.canvas = new Canvas(); this.context = this.canvas.getContext('2d'); // create css template this.cssCompiledTemplate = handlebars.compile(fs.readFileSync(__dirname + '/../templates/LibrarySpriteSheet.tpl', 'utf8'), { noEscape: true }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function createLibrary(name) {\n var denverLibrary = {\n name: name,\n shelves: {\n fantasy: [],\n fiction: [],\n nonFiction: []\n }\n }\n return denverLibrary;\n}", "function NewLibrary() {\n//this.property = value\n this.books = [];\n this.currentCallNumber = 0;\n}", "async library(id) {\n if (this.__library[id]) {\n return this.__library[id];\n }\n\n try {\n await this.libraries.get(id);\n } catch(e) {\n if (e.status === 404) {\n return null;\n } else {\n throw e;\n }\n }\n\n const library = new this.PouchDB(path.join(this.dataFolder, `library-${id}.db`));\n this.__library[id] = library;\n\n return library;\n }", "function Library(name,creator){\n this.name = name;\n this.creator = creator;\n this.playlists = [];\n}", "function Library() {\n \n}", "function createMadlib()\n{\n\t//get words to replace\n\tgetWordsToReplace();\n\n\tcreateMadlibElements()\n}", "function readLibrary(xmlLibrary) {\r\n var type = xmlLibrary.getAttribute(\"type\");\r\n var library = new JSGDemo.model.Library(type);\r\n self.libraries.put(type, library);\r\n\r\n var xmlLabels = xmlLibrary.getElementsByTagName(\"typename\");\r\n var xmlLabel = xmlLabels[0].getElementsByTagName(JSGDemo.lang);\r\n \r\n xmlLabels = xmlLibrary.getElementsByTagName(\"name\");\r\n xmlLabel = xmlLabels[0].getElementsByTagName(JSGDemo.lang);\r\n library.name = xmlLabel[0].childNodes[0].nodeValue.decode();\r\n\r\n return library;\r\n }", "function createScene() {\n const scene = new BABYLON.Scene(engine);\n\n const camera = new BABYLON.ArcRotateCamera(\"camera\", -Math.PI / 2, Math.PI / 2.5, 15, new BABYLON.Vector3(0, 0, 0));\n camera.attachControl(canvas, true);\n const light = new BABYLON.HemisphericLight(\"light\", new BABYLON.Vector3(1, 1, 0)); \n\n BABYLON.SceneLoader.ImportMeshAsync(\"\", \"./\", \"village.glb\");\n\n return scene;\n}", "function makeLibrary(response, type, err, contents, data)\n{\n var replacement = \"\";\n var table = util.getTable();\n var columns = [\"Author\", \"Title\", \"Year\", \"Notes\"];\n var row = [];\n var author = \"\", title = \"\", year = \"\", notes = \"\";\n\n table.setHTMLClass(\"conq\");\n table.setColumns(columns);\n for(var i = 0; i < data.length; i++)\n {\n author = util.deNullify(data[i].fullTitle);\n title = util.linkify(data[i].title, data[i].link);\n year = data[i].yearPublished;\n notes = util.deNullify(data[i].notes, \".\");\n row = [author, title, year, notes];\n table.addRow(row);\n }\n replacement = table.buildHTMLPrintout();\n\n contents = util.absRep(contents, \"LIBRARY\", replacement);\n\n final.wrapup(response, type, err, contents);\n}", "function createBucket() {\n metadata\n .buckets.set(bucketName, new BucketInfo(bucketName, ownerID, '', ''));\n metadata.keyMaps.set(bucketName, new Map);\n}", "function Libs (){\r\n if (!(this instanceof Libs)){\r\n return new Libs\r\n }\r\n}", "async function createNewContract() {\n var deploy = await LANDMARK.new()\n LANDMARK_instance = LANDMARK.at(deploy.address);\n}", "function createNewCatalog() {\n en.catalog.create(locationName, \n function(data) {\n locationID = data.response.id;\n },\n function(data) {\n error(\"Couldn't create catalog \" + locationName);\n }\n );\n}", "function prepareLib( loads, cb ){\n\t\tvar tempConfig = loads.slice();\n\t\tvar ret_lib = {};\n\t\tloadOne();\n\t\t\n\t\tfunction loadOne(){\n\t\t\tif( tempConfig.length > 0 ){\n\t\t\t\tvar conf = tempConfig.shift();\n\t\t\t\tvar name = conf[0];\n\t\t\t\tvar path = conf[1];\n\t\t\t\tvar mtlPath = conf[2];\n\t\t\t\tif( mtlPath != undefined ){\n\t\t\t\t\tloadMeshAndMaterials( path, mtlPath, function ( mesh ) {\t\t\t\t\t\t//conf.mesh = mesh;\n\t\t\t\t\t\tret_lib[name] = mesh;\n\t\t\t\t\t\tloadOne();\n\t\t\t\t\t});\n\t\t\t\t}else{\n\t\t\t\t\tloadMesh( path, undefined, function ( mesh ) {\n\t\t\t\t\t\tret_lib[name] = mesh;\n\t\t\t\t\t\tloadOne();\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}else{\n\t\t\t\tcb( ret_lib );\n\t\t\t}\n\t\t}\n\t}", "function createPkg(name, root) {\n return root[name] = createDict();\n }", "function create(library, node) {\n return Tools.instance({\n library,\n node,\n childWraps: node.children.map(library.createWrap),\n domNode: null,\n events: null\n }, {\n renderToString,\n renderToDom,\n mount,\n update,\n unmount\n });\n}", "function addBookToLibrary(name, author, pages, readStatus) {\r\n let book = new Book(name, author, pages, readStatus);\r\n myLibrary.push(book);\r\n render();\r\n}", "async createBundle () {\n const name = `${this.appIdentifier}_${this.options.branch}_${this.options.arch}.flatpak`\n const dest = this.options.rename(this.options.dest, name)\n this.options.logger(`Creating package at ${dest}`)\n const extraExports = []\n if (this.options.icon && !_.isObject(this.options.icon)) {\n extraExports.push(this.pixmapIconPath)\n }\n\n const files = [\n [this.stagingDir, '/']\n ]\n const symlinks = [\n [path.join('/lib', this.appIdentifier, this.options.bin), path.join('/bin', this.options.bin)]\n ]\n\n const command = (await this.requiresSandboxWrapper()) ? 'electron-wrapper' : this.options.bin\n\n return flatpak.bundle({\n id: this.options.id,\n branch: this.options.branch,\n base: this.options.base,\n baseVersion: this.options.baseVersion.toString(),\n runtime: this.options.runtime,\n runtimeVersion: this.options.runtimeVersion.toString(),\n sdk: this.options.sdk,\n finishArgs: this.options.finishArgs,\n command,\n modules: this.options.modules\n }, {\n ...this.flatpakrefs,\n arch: this.options.arch,\n bundlePath: dest,\n extraExports: extraExports,\n extraFlatpakBuilderArgs: this.options.extraFlatpakBuilderArgs,\n files: files.concat(this.options.files),\n symlinks: symlinks.concat(this.options.symlinks)\n })\n }", "function createNewNamespace(tagNode)\n{\n var cNodes = g_libDom.getElementsByTagName(\"TAGLIBRARIES\");\n \n // We know for sure there's only one TAGLIBRARIES element, hence use 0.\n var iHTML = cNodes[0].innerHTML;\n\n // Set the Namespace and format the line.\n var tagReplacePattern = /@@NAME@@/g;\n var newTagLib = g_tagLibOpenPattern.replace(tagReplacePattern, tagNode.NAMESPACE);\n newTagLib = newTagLib + \"\\r\\n\" + g_tagLibClosePattern;\n\n // Add a new line char to the end \n iHTML = iHTML + \"\\r\\n\" + newTagLib;\n cNodes[0].innerHTML = iHTML;\n}", "function addToLibrary(palette) {\n // console.log(`${palette.name} added to library`);\n const paletteDiv = document.createElement('div');\n paletteDiv.classList.add('custom-palette');\n\n const title = document.createElement('h4');\n title.innerText = palette.name;\n\n const previewDiv = document.createElement('div');\n previewDiv.classList.add('preview');\n palette.colors.forEach(color => {\n const colorPreview = document.createElement('div');\n colorPreview.classList.add('color');\n colorPreview.style.background = color;\n previewDiv.appendChild(colorPreview);\n });\n\n const paletteBtn = document.createElement('button');\n paletteBtn.classList.add('palette-select');\n paletteBtn.classList.add(palette.num);\n paletteBtn.innerText = 'Select';\n\n paletteBtn.addEventListener('click', () => {\n updateColors(palette.colors);\n toggleLibPanel();\n });\n\n paletteDiv.appendChild(title);\n paletteDiv.appendChild(previewDiv);\n paletteDiv.appendChild(paletteBtn);\n libPanel.children[0].appendChild(paletteDiv);\n}", "function loadAssetLibrary(libs, type, dir, libId, fileName, params, ok) {\n if (!libs[libId]) {\n libs[libId] = true;\n Human.assets.getAssetLibrary(type, dir, libId, fileName, params, ok);\n }\n }", "function loadAtlas(lvls)\n\t\t{\n\t\t\tdataLvls = lvls;\n\t\t\treturn new Promise ( (ok, error) =>\n\t\t\t{\n\t\t\t\tlet atlas = new XMLHttpRequest();\n\t\t\t\tatlas.open(\"GET\", \"img/Tiles/atlas.xml\");\n\t\t\t\tatlas.onreadystatechange = function()\n\t\t\t\t{\n\t\t\t\t\tif(atlas.readyState == 4)\n\t\t\t\t\t{\n\t\t\t\t\t\tif(atlas.status == 200)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tlet atlasParser = new DOMParser();\n\t\t\t\t\t\t\tlet xmlDoc = atlasParser.parseFromString(this.responseText, \"text/xml\");\n\t\t\t\t\t\t\tok(xmlDoc.getElementsByTagName(\"SubTexture\"));\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tconsole.log(atlas.status);\n\t\t\t\t\t\t\terror (\"chargement du fichier json\");\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t};\n\t\t\t\tatlas.send();\n\t\t\t});\n\t\t}", "function addBookToLibrary(book) {\n library.push(book);\n}", "create () {\n let asteroidsGroup = this.gameObjects['asteroids-group'] = new AsteroidsGroup(this.game);\n\n this.spawnAsteroids(25);\n this.setupUI();\n }", "function addDocToLibraries (doc) {\n //AppController.sharedInstance().librariesController().addAssetLibraryAtURL(doc.fileURL())\n\tdoc.saveAndAddLibrary()\n}", "static createLinkedPackage(name, version, folderPath, packageJson) {\n return new BasePackage(name, version, folderPath, packageJson);\n }", "function create(library, node) {\n return Tools.instance({\n text: node.text,\n domNode: null\n }, {\n renderToString,\n renderToDom,\n mount,\n update,\n unmount\n });\n}", "create () {}", "create () {}", "function createLicense() {}", "function createLayerSet(name) {\n var newLayerSet = srcDoc.layerSets.add();\n newLayerSet.name = name;\n}", "function addToLibrary(book) {\n\t\tmyLibrary.push(book);\n\t}", "async function newPortalInstance() {\n const [Portal] = await loadModules(['esri/portal/Portal'])\n return new Portal({\n url: appConfig.portalUrl,\n })\n}", "static create () {}", "function addBookToLibrary(book) {\n myLibrary.push(book)\n}", "function constructAMD() {\n\n\t\t//create a library instance\n\t\treturn init();\n\n\t\t//spawns a library instance\n\t\tfunction init() {\n\t\t\tvar library;\n\t\t\tlibrary = factory('amd');\n\t\t\tlibrary.fork = init;\n\t\t\treturn library;\n\t\t}\n\t}", "function addBookToLibrary()\n{\n \n}", "function addBookToLibrary(book) {\n myLibrary.push(book);\n}", "function addBookToLibrary(title, author, pages, read) {\n let book = new Book(title, author, pages, read);\n myLibrary.push(book);\n // do stuff here\n}", "static async create(projectDir) {\n const instance = new AnnotationsDb(projectDir)\n const fileWasCreated = await instance.file.create()\n if (!fileWasCreated) {\n throw new Error(\n `AnnotationsDb.create was called for a project that already `\n + `contains annotations.`\n )\n }\n return instance\n }", "function addBookToLibrary(newObj) {\n myLibrary.push(newObj);\n}", "function Library() {\n if (!(this instanceof Library)) return new Library();\n this.tests = {};\n}", "function Library() {\n if (!(this instanceof Library)) return new Library();\n this.tests = {};\n}", "function Library() {\n if (!(this instanceof Library)) return new Library();\n this.tests = {};\n}", "async function library(argv, ctx, args) {\n if (!(0, _isValidPackageName.default)(args.name)) {\n throw new Error(\n `${args.name} is not a valid name for a project. Please use a valid ` +\n `identifier name (alphanumeric).`\n );\n }\n\n const libraries = _path().default.resolve(ctx.root, 'Libraries');\n\n const libraryDest = _path().default.resolve(libraries, args.name);\n\n const source = _path().default.resolve(\n 'node_modules',\n 'react-native',\n 'Libraries',\n 'Sample'\n );\n\n if (!_fs().default.existsSync(libraries)) {\n _fs().default.mkdirSync(libraries);\n }\n\n if (_fs().default.existsSync(libraryDest)) {\n throw new Error(`Library already exists in ${libraryDest}`);\n }\n\n (0, _walk.default)(source).forEach(f => {\n if (\n f.indexOf('project.xcworkspace') !== -1 ||\n f.indexOf('.xcodeproj/xcuserdata') !== -1\n ) {\n return;\n }\n\n const dest = _path().default.relative(\n source,\n f.replace(/Sample/g, args.name).replace(/^_/, '.')\n );\n\n (0, _copyAndReplace.default)(\n _path().default.resolve(source, f),\n _path().default.resolve(libraryDest, dest),\n {\n Sample: args.name\n }\n );\n });\n\n _logger.default.info(`Created library in ${libraryDest}.\nNow it needs to be linked in Xcode:\nhttps://facebook.github.io/react-native/docs/linking-libraries-ios.html#content`);\n}", "function loadTemplate(template, layer) {\n const newStage = Konva.Node.create(template, 'canvas');\n newStage.add(layer);\n return newStage\n }", "function createLearningGroup(initialValues) {\n return manager.createEntity(learningGroupType, initialValues);\n }", "function firstLoadInitialize(){\r\n addBookToLibrary(\"1984\", \"George Orwell\", 328, true);\r\n addBookToLibrary(\"Fahrenheit 451\", \"Ray Bradbury\", 256, true);\r\n addBookToLibrary(\"Dune\", \"Frank Herbert\", 412, true);\r\n addBookToLibrary(\"War and Peace\", \"Leo Tolstoy\", 1225, false);\r\n}", "function Library() {\n\t if (!(this instanceof Library)) return new Library();\n\t this.tests = {};\n\t}", "function Library() {\n if (!(this instanceof Library)) return new Library();\n this.tests = {};\n }", "function DUPairFactory() {\n}", "create() {\n\t}", "function createReleaseScene(scene, core) {\n function createMaterial(name, path) {\n var material = new BABYLON.StandardMaterial(name, scene);\n material.diffuseColor = new BABYLON.Color3(1, 1, 1);\n material.diffuseTexture = new BABYLON.Texture(path, scene);\n\n return material;\n }\n\n /// Light\n var light = new BABYLON.DirectionalLight(\"globalLight\", new BABYLON.Vector3(-1, -2, -1), scene);\n light.position = new BABYLON.Vector3(10, 10, 0);\n var shadows = new BABYLON.ShadowGenerator(1024, light);\n BABYLON.Editor.Utils.SendEventObjectAdded(light, core);\n\n var object = BABYLON.Mesh.CreateGround(\"New Ground\", 60, 60, 20, scene);\n object.material = createMaterial('ground1m', './Tests/textures/tile.jpg');\n object.material.diffuseTexture.uScale = 15.0;\n object.material.diffuseTexture.vScale = 15.0;\n object.material.reflectionTexture = new BABYLON.MirrorTexture(\"mirror\", 512, scene, true);\n object.material.reflectionTexture.mirrorPlane = new BABYLON.Plane(0, -1.0, 0, 0.0);\n object.material.reflectionTexture.level = 0.6;\n object.id = BABYLON.Editor.Utils.GenerateUUID();\n object.isPickable = true;\n object.receiveShadows = true;\n BABYLON.Editor.Utils.SendEventObjectAdded(object, core);\n\n var box = BABYLON.Mesh.CreateBox('New Cube', 1, core.currentScene, true);\n //box.material = createMaterial('sphere1m', './Tests/textures/diffuse.tga');\n box.scaling = new BABYLON.Vector3(4, 4, 4);\n box.position = new BABYLON.Vector3(0, 2, 0);\n box.id = BABYLON.Editor.Utils.GenerateUUID();\n shadows.getShadowMap().renderList.push(box);\n BABYLON.Editor.Utils.SendEventObjectAdded(box, core);\n\n object.material.reflectionTexture.renderList = [box];\n}", "function pushBookToLibrary(book) {\n myLibrary.push(book)\n render(myLibrary)\n}", "addAsset(assetConfig) {\n const asset = new resources_1.Asset({\n input: slash_1.default(assetConfig.input),\n output: slash_1.default(assetConfig.output)\n });\n this.assets.push(asset);\n return asset;\n }", "function loadLibrary() {\n\n if ( loaded ) {\n return onLibraryLoaded();\n }\n\n var googletag,\n gads,\n useSSL,\n node,\n readyStateLoaded = false\n ;\n\n window.googletag = window.googletag || {};\n window.googletag.cmd = window.googletag.cmd || [];\n\n // Called when GPT is Available\n window.googletag.cmd.push( onLibraryLoaded )\n\n gads = document.createElement( 'script' );\n gads.async = true;\n gads.type = 'text/javascript';\n gads.src = 'https://www.googletagservices.com/tag/js/gpt.js';\n\n node = document.getElementsByTagName( 'script' )[0];\n node.parentNode.insertBefore( gads, node );\n\n }", "function init() {\n createMap(\"./json/map-style.json\");\n\n}", "static async new(projectDir) {\n const instance = new AnnotationsDb(projectDir)\n await instance.readAnnotations()\n return instance\n }", "function createLoad(name) {\n return {\n status: 'loading',\n name: name,\n linkSets: [],\n dependencies: [],\n metadata: {}\n };\n }", "function createLoad(name) {\n return {\n status: 'loading',\n name: name,\n linkSets: [],\n dependencies: [],\n metadata: {}\n };\n }", "function createLoad(name) {\n return {\n status: 'loading',\n name: name,\n linkSets: [],\n dependencies: [],\n metadata: {}\n };\n }", "function createLoad(name) {\n return {\n status: 'loading',\n name: name,\n linkSets: [],\n dependencies: [],\n metadata: {}\n };\n }", "function createScene() {\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n // Create the scene space\r\n\r\n\r\n\r\n var scene = new BABYLON.Scene(engine);\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n // Add a camera to the scene and attach it to the canvas\r\n\r\n\r\n\r\n camera = new BABYLON.ArcRotateCamera(\"Camera\", Math.PI / 2, Math.PI / 4, 4, BABYLON.Vector3.Zero(), scene);\r\n\r\n\r\n\r\n camera.attachControl(canvas, true);\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n // Add lights to the scene\r\n\r\n\r\n\r\n var myLight = new BABYLON.DirectionalLight(\"dir01\", new BABYLON.Vector3(0, -0.5, 1.0), scene);\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n // Add and manipulate meshes in the scene\r\n\r\n\r\n\r\n sphere = BABYLON.MeshBuilder.CreateSphere(\"sphere\", {diameter: .7}, scene);\r\n nsphere = BABYLON.MeshBuilder.CreateSphere(\"sphere\", {diameter: -.4}, scene);\r\n\r\n\r\n\r\n var lesserSphere = BABYLON.MeshBuilder.CreateSphere(\"sphere2\", {diameter: .2}, scene);\r\n\r\n\r\n\r\n lesserSphere.position.z = 1;\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n sphere.addChild(lesserSphere);\r\n\r\n\r\n\r\n light = new BABYLON.HemisphericLight(\"HemiLight\", new BABYLON.Vector3(1, 1, 0), scene);\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n blueMat = new BABYLON.StandardMaterial(\"ground\", scene);\r\n\r\n\r\n\r\n blueMat.diffuseColor = new BABYLON.Color3(0.4, 0.4, 0.4);\r\n\r\n\r\n\r\n blueMat.specularColor = new BABYLON.Color3(0.4, 0.4, 0.4);\r\n\r\n\r\n\r\n blueMat.emissiveColor = BABYLON.Color3.Blue();\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n return scene;\r\n\r\n\r\n\r\n}", "function Composer() {\n\t this.anchors = {};\n\t }", "create() {}", "create() {}", "function createLegend(layer) {\n // if the legend already exists, then update it with the new layer\n if (legend) {\n legend.layerInfos = [{\n layer: layer,\n title: \"Magnitude\"\n }];\n }\n else {\n legend = new Legend({\n view: view,\n layerInfos: [\n {\n layer: layer,\n title: \"Earthquake\"\n }]\n }, \"infoDiv\");\n }\n }", "function Libreta(apuntes) {\n this.apuntes = apuntes;\n }", "function addBookToLibrary(title, author, pages, isRead) {\n let newBook = new Book(title, author, pages, isRead);\n myLibrary.push(newBook);\n}", "function create(params) {\n var state = initState(params);\n calcVertices(state);\n makeMapping(state);\n var idx = makeIndexBuffer(state);\n var geometry = new Visualization.THREE.BufferGeometry();\n geometry.addAttribute('position', new Visualization.THREE.BufferAttribute(state.vertices, 3));\n geometry.addAttribute('index', new Visualization.THREE.BufferAttribute(idx, 1));\n geometry.addAttribute('color', new Visualization.THREE.BufferAttribute(new Float32Array(state.quadCount * 4 * 3), 3));\n geometry.addAttribute('mapping', new Visualization.THREE.BufferAttribute(state.mapping, 2));\n geometry.addAttribute('inputTexCoord', new Visualization.THREE.BufferAttribute(state.texCoords, 2));\n geometry.addAttribute('inputSize', new Visualization.THREE.BufferAttribute(state.size, 1));\n return { geometry: geometry, texture: state.textAtlas.texture, options: state.options };\n }", "async function initialize() {\n const pool = await oracledb.createPool(oracleConfig.sharding);\n oracledb.dbObjectAsPojo = true;\n}", "createLayer() {\n let jsApiUrl = this.get('_jsApiUrl');\n\n let jsApi = L.Yandex._jsApi;\n if (Ember.isNone(jsApi)) {\n L.Yandex._jsApi = jsApi = {};\n }\n\n let requestedJsApi = jsApi[jsApiUrl];\n if (Ember.isNone(requestedJsApi)) {\n jsApi[jsApiUrl] = requestedJsApi = {\n isAlreadyLoaded: false\n };\n }\n\n if (requestedJsApi.isAlreadyLoaded) {\n // Yandex Maps JS API is already loaded, so layer can be created synchronously.\n return this._createYandexLayer();\n }\n\n return new Ember.RSVP.Promise((resolve, reject) => {\n // Try to load script containing Yandex Maps JS API.\n Ember.$.ajax({\n dataType: 'script',\n cache: true,\n url: jsApiUrl\n }).done((data, textStatus, jqXHR) => {\n // Yandex Maps JS API is successfully loaded.\n // Remember it to aviod Yandex Maps JS API re-download.\n requestedJsApi.isAlreadyLoaded = true;\n\n // Create layer & resolve promise.\n resolve(this._createYandexLayer());\n }).fail((jqXHR, textStatus, errorThrown) => {\n // Yandex Maps JS API wasn't loaded, layer can't be created.\n reject(jqXHR.responseText);\n });\n });\n }", "newAssetConfigure() {\n let values = {\n source: this.shadowRoot.querySelector(\"#url\").value,\n title: this.shadowRoot.querySelector(\"#url\").value,\n };\n HAXStore.insertLogicFromValues(values, this);\n }", "function create() {\n if (gameState === \"Menu\") {\n menuGroupSetup();\n } else if (gameState === \"Playing\") {\n game.world.removeAll();\n stageGroupSetup();\n entityGroupSetup();\n guiGroupSetup();\n game.sound.setDecodedCallback([monsterLaugh, mainTheme], playIntro);\n } else if (gameState === \"GameOver\") {\n gameOverGroupSetup();\n } else if (gameState === \"Win\") {\n gameWinGroupSetup();\n }\n\n game.input.mouse.capture = true;\n cursors = game.input.keyboard.createCursorKeys();\n }", "createScene(){\n this.scene = new BABYLON.Scene(this.engine); \n \n this.ground = this.buildGround(this.groundW ,this.groundH,0);\n\n //this.player.createPlayer(this.groundH);\n this.player = new Player(\"Ossama\",this.groundH,this.playerSpeed);\n\n this.virus = new Virus(\"Covid\");\n this.createMutipleViruses(this.nbVirusToCreate);\n\n var camera = new BABYLON.ArcRotateCamera(\"camera\", -Math.PI / 2, Math.PI / 2.5, 15, new BABYLON.Vector3(this.player.initialPosX , this.player.initialPosY , this.player.initialPosZ),this.scene);\n //camera.attachControl(this.canvas, true);\n\n //light\n var light = new BABYLON.HemisphericLight(\"light\", new BABYLON.Vector3(1, 1, 0));\n \n // background\n new BABYLON.Layer(\"background\", \"assets/background.jpg\", this.scene, true);\n\n return this.scene ;\n }", "function createCar() {\n car = new Car();\n scene.add(car.mesh);\n}", "function Atlas() {\n this._maps = []; // 32 x 32 grids. [Uint32Array(32), ...]\n this._ctxs = []; // sprite sheets(canvas) contexts. [ctx, ...]\n this._spriteSheets = []; // sprite sheets(canvas). [HTMLCanvasElement, ...]\n this._imageData = {}; // image data. { key: { ssn, sw, sh, bx, by, bw, bh }, ... }\n // ssn: spriteSheetNumber\n // sw: sourceImageWidth\n // sh: sourceImageHeight\n // bx: block x\n // by: block y\n // bw: block width\n // bh: block height\n}", "addBookLibrary() {\n const bookStatus = readBtn.innerText;\n const bookItem = new Book(bookId, authorForm.value, titleForm.value, pagesForm.value, bookStatus);\n bookId++;\n myLibrary.push(bookItem);\n this.storage.saveData();\n\n this.renderElem.clearForm();\n this.renderElem.render();\n }", "static createInstance(manufacturer, assetNumber, assetType) {\n\n let newAsset = new Asset({ manufacturer, assetNumber});\n newAsset.assetType = assetType;\n return newAsset;\n }", "function initProjLibrary(opts, done) {\n if (!asyncLoader) return done();\n asyncLoader(opts, done);\n }", "function Library () {\n\t this.tests = {};\n\t}", "function init() {\n var destDirPath,\n projectItem = ProjectManager.getSelectedItem();\n\n if (projectItem.isDirectory) {\n destDirPath = projectItem.fullPath;\n } else {\n destDirPath = ProjectManager.getProjectRoot().fullPath;\n }\n\n _showDialog().done(function (libObject) {\n if (libObject.action === \"download\") {\n _getLibraryContent(libObject.url).done(function (libContent) {\n var cleanMainFile = FileUtils.getBaseName(libObject.mainFile),\n libFile = FileSystem.getFileForPath(destDirPath + cleanMainFile);\n\n FileUtils.writeText(libFile, libContent, true).done(function () {\n var tag = Linker.getTagsFromFiles([libFile.fullPath]);\n Linker.insertTags(tag);\n ProjectManager.refreshFileTree();\n }).fail(function () {\n console.log(\"Error writing file: \" + libFile);\n });\n });\n } else if (libObject.action === \"link\") {\n var tag = Linker.getTagsFromUrls([libObject.url]);\n Linker.insertTags([tag]);\n }\n });\n }", "function createPool(config, index) {\n // Oracle Pool\n oracledb.createPool(config.db[index], function(err, pool) {\n if (err) {\n console.error('error in creating oracle pool.');\n console.dir(err);\n return;\n }\n \n logger.info('Pool for oracle database [' + config.db[index].name + '] created.');\n \n pool.execute = execute;\n pool.checkGetConnectionError = checkGetConnectionError;\n pool.executeSql = executeSql;\n pool.checkSqlError = checkSqlError;\n\n database_oracle.pool = pool;\n });\n \n}", "function addBookToLibrary(title, author, pages, read) {\n let newBook = new Book(title, author, pages, read)\n myLibrary.push(newBook)\n saveLibraryInStorage(myLibrary)\n renderBook(newBook)\n}", "createManager (network, mode, addressScheme, currencies) {\n }", "function tp_make_smart_object()\n{\n\texecuteAction(stringIDToTypeID(\"newPlacedLayer\"), undefined, DialogModes.NO);\n}", "function addBooksToLibrary(title, author, pages) {\r\n let newItem = new book(title, author, pages); \r\n myLibrary.push(newItem);\r\n }", "async createNewInstance() {\n const adapters = this.processAdapters();\n const datastores = this.api.config.models.datastores;\n const models = await this.loadModels();\n\n const ormStart = promisify(Waterline.start);\n\n this.waterline = await ormStart({\n adapters,\n datastores,\n models,\n });\n }", "function create() {\n seed = createSeed();\n store.seed = seed;\n treeManager = createTreeManager();\n\n for (let i = 0; i < heightRegions; i += 1) {\n for (let j = 0; j < widthRegions; j += 1) {\n const pos = { x: j * gameConfig.GAME.VIEWWIDTH / widthRegions, y: i * gameConfig.GAME.VIEWHEIGHT / heightRegions };\n const size = { w: gameConfig.GAME.VIEWWIDTH / widthRegions, h: gameConfig.GAME.VIEWHEIGHT / heightRegions };\n addRegion(pos, size);\n\n // Lazy extra region per row. TL;DR We put 1 extra wind region outside the camera view so we can parallax them cleanly.\n if (j === widthRegions - 1) {\n const region = addRegion(pos, size);\n region.moveToBack();\n }\n }\n }\n store.ui.setCurrentLevelText(levelName);\n }", "function DynAPILibrary() {\n this.DynObject = DynObject;\n this.DynObject();\n\n // list of js files: this.scripts['../src/api/dynlayer_ie.js'] = {dep, objects, pkg, fn};\n this.scripts = {};\n\n // list of package names: this.packages['dynapi.api'] = dynapi.api = {_objects,_path}\n this.packages = {};\n\n // list of object names: this.objects['DynLayer'] = this.scripts['../src/api/dynlayer_ie.js']\n this.objects = {};\n\n this._c = 0;\n this.loadList = [];\n this.loadIndex = -1;\n this.path = null;\n this.busy = true;\n}", "function storeLibrary (libraryName, dependencies, callback) {\n libraryStorage[libraryName] = {\n dependencies: dependencies,\n callback: callback,\n };\n }", "async function createConfiguration() {\n await client.createPackage(packagePayload);\n console.log(`Package created: ${packagePayload.Name}`);\n await client.createPropertySetType(packagePayload.Name, propertySetTypePayload);\n console.log(`Property set type created: ${propertySetTypePayload.Name}`);\n await client.createThingType(packagePayload.Name, thingTypePayload);\n console.log(`Thing type created: ${thingTypePayload.Name}`);\n}", "function initBalls() {\n\n\t// Add new scripts here\n\tvar scripts = [\n\t\t\"scripts/components/Component.js\",\n\t\t\"scripts/components/BasicRenderer.js\",\n\t\t\"scripts/base/BallObject.js\",\n\t\t\"scripts/base/Ball.js\",\n\t\t\"scripts/base/BallsManager.js\",\n\t\t\"scripts/base/Vector2.js\",\n\t\t\"scripts/test/TestCanvas.js\",\n\t];\n\n\tgetScripts(scripts, startBallManagers);\n\t\n}", "function makePlatform( jsonUrl, textureUrl) {\r\n\t\tconsole.log(\"platform build\");\r\n\t\tvar placeholder = new THREE.Object3D();\r\n\t\tvar texture = THREE.ImageUtils.loadTexture( textureUrl );\r\n\t\ttexture.minFilter = THREE.LinearFilter;\r\n\t\t//texture.anisotropy = textureQuality;\r\n\t\tvar loader = new THREE.JSONLoader();\r\n\t\tvar platformMaterials = [\r\n\t\t\tnew THREE.MeshLambertMaterial({color:0x00FF00}),\r\n new THREE.MeshPhongMaterial({color:0x0000FF}),\r\n \tnew THREE.MeshBasicMaterial({color:0xFFFF00}),\r\n \tnew THREE.MeshBasicMaterial({color:0x00FFFF}),\r\n \tnew THREE.MeshBasicMaterial({color:0xFFFFFF})\r\n\t\t];\r\n\r\n\t\tvar platformMainMaterial = new THREE.MeshFaceMaterial(platformMaterials);\r\n\t\tloader.load( jsonUrl, function( geometry ) {\r\n\t\t\tgeometry.computeFaceNormals();\r\n\t\t\tplatform = new THREE.Mesh( geometry, platformMainMaterial );\r\n\t\t\tplatform.position.set(0, 0, 0);\r\n\t\t\tplatform.name = \"platform\";\r\n\t\t\tplatform.castShadow = true;\r\n\t\t\tplatform.receiveShadow = true;\r\n\t\t\tplaceholder.add( platform );\r\n\t\t});\r\n\t\treturn placeholder;\r\n\t}", "function createPackageTable( tx ) {\n\tvar query = \"CREATE TABLE IF NOT EXISTS \" + tablePackages + \" (\" +\n\t\t\t\"id INTEGER PRIMARY KEY AUTOINCREMENT, \" +\n\t\t\t\"id_mod INT NOT NULL, \" +\n\t\t\t\"name TEXT NOT NULL, \" +\n\t\t\t\"description TEXT NULL, \" +\n\t\t\t\"image TEXT NULL)\";\n\t\n\ttx.executeSql( query, [], function ( tx, result ) {\n\t\tconsole.log( \"Table \" + tablePackages + \" created successfully\" );\n\t}, errorCB );\n\t\n\tquery = \"CREATE INDEX IF NOT EXISTS id_mod ON \" + tablePackages + \" (id_mod)\";\n\t\n\ttx.executeSql( query, [], function ( tx, result ) {\n\t\tconsole.log( \"Index in \" + tablePackages + \" created successfully\" );\n\t}, errorCB );\n}", "function createObjects(){\n\tHangMan.gameReady = true;\n\tHangMan.namesObj = Object.create(gameObj);\n\tHangMan.colorsObj = Object.create(gameObj);\n\tHangMan.statesObj = Object.create(gameObj);\n\tHangMan.namesObj.words = namesArr;\n\tHangMan.colorsObj.words = colorsArr;\n\tHangMan.statesObj.words = statesArr;\n\tHangMan.categories = categories;\n\tfor(i = 0 ; i < HangMan.categories.length ; i++){\n\t\tsetObject(HangMan.categories[i]);\n\t}\n\tvar catIndex = Math.floor(Math.random() * categories.length);\n\t$('#category option:eq(' + catIndex + ')').prop('selected', true)\n\tchangeCategory();\n\tloadObject(categories[catIndex]);\n}", "function create() {\n //now that the map data and tileset are loaded, create a map object (tiles, objects, properties, etc)\n map = game.add.tilemap('testmap');\n \n //the map needs to be informed which asset of ours is the tileset it's expecting\n //the first parameter is the name of the tileset in the map data, the second is an asset key\n map.addTilesetImage('lttp_castlebasement', 'tileset');\n \n //maps aren't drawn upon being added to the game, like Phaser.Sprite, etc\n //instead, individual layers are rendered to TilemapLayers, which behave like sprites\n //the name of the layer passed in here should be the name of a tile layer in the map data\n //once created, the layer is added to the game's display list (like a sprite)\n var layer = map.createLayer('base layer');\n\n //layers are fixed to the camera by default, center this one instead\n layer.fixedToCamera = false;\n layer.x = game.world.centerX - (map.widthInPixels / 2);\n layer.y = game.world.centerY - (map.heightInPixels / 2);\n }", "static restore(data) {\n return new TextureAtlas({\n sourcePath: data.sourcePath\n });\n }", "createFromObjects(layerName, gid, spriteClass, group) {\n parent.stage.createFromObjects(layerName, gid, null, null, true, false, group, spriteClass, true);\n }", "function initLibs() {\n\t\tvar kjslib = universe.kjslib = _kJs_Initor();\n\t\tvar kxmllib = universe.kxmllib = _kXml_Initor();\n\t\tvar kanilib = universe.kanilib = _kAni_Initor();\n\t\tvar keventlib = universe.keventlib = _kEvent_Initor();\n\t\tvar kgraphlib = universe.kgraphlib = _kGraph_Initor();\n\t\tinitClasses\n\t\t\t(kjslib, \"kjsclasses\")\n\t\t\t(kxmllib, \"kxmlclasses\")\n\t\t\t(kanilib, \"kaniclasses\")\n\t\t\t(keventlib, \"keventclasses\")\n\t\t\t(kgraphlib, \"kgraphclasses\")\n\t\t;\n\t}" ]
[ "0.64622486", "0.5337491", "0.5260609", "0.525528", "0.52491814", "0.516564", "0.51183516", "0.5086852", "0.506477", "0.5023035", "0.50163406", "0.50099206", "0.50010246", "0.4973214", "0.49606636", "0.49443272", "0.49343997", "0.4902602", "0.48722452", "0.48701003", "0.48535052", "0.48406926", "0.48288637", "0.48194227", "0.48076802", "0.47974178", "0.4793001", "0.4791242", "0.4791242", "0.47668862", "0.47637346", "0.47499582", "0.47275338", "0.47019753", "0.46924534", "0.4677259", "0.46766615", "0.467373", "0.46648422", "0.466406", "0.46606624", "0.465468", "0.465468", "0.465468", "0.4653593", "0.46503097", "0.4645915", "0.46409822", "0.4639497", "0.46346912", "0.4633351", "0.46162948", "0.46096063", "0.46040434", "0.46039099", "0.46014318", "0.4592577", "0.459028", "0.4580998", "0.4580998", "0.4580998", "0.4580998", "0.45778325", "0.45727563", "0.45721537", "0.45721537", "0.4566436", "0.45639685", "0.4547237", "0.4541232", "0.45263347", "0.45216072", "0.4517165", "0.4511077", "0.45065808", "0.45038798", "0.44932038", "0.4490066", "0.4480203", "0.44763428", "0.44762087", "0.4471666", "0.4469532", "0.4469138", "0.44552693", "0.44537687", "0.44511718", "0.44509083", "0.44494623", "0.44494033", "0.4448007", "0.44444942", "0.44422138", "0.443777", "0.44357482", "0.44290367", "0.44289154", "0.4427974", "0.44259554", "0.44215912" ]
0.66683453
0
fecthing notes when the first entry
componentDidMount() { this.mounted = true; if (this.props.notes && this.props.notes.length === 0 && this.mounted) this.getNotes({ start: 0, loadAmount: 20 }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function enterNote() {\n note = {}\n if (checkIfInputIsCorrect()) {\n // create note\n note.InputOfNote = txtArea.value;\n note.dateOfNote = dateEnterded;\n note.timeOfNote = timeEnterded;\n note.noteNum = noteNumber;\n note.secondsComp = dateEnterdedToCompare;\n noteNumber++;\n NoteArrey.push(note);\n addToLocalStorage();\n printNotes(false);\n }\n}", "function fillInitialEntries() {\n console.log(\"notesService: Create some dummy entries...\");\n\n //\n // fill with default /test data:\n //\n var notes = [];\n\n var note = new Note(\"CAS FEE Selbststudium / Projekt-Aufgabe erledigen\", new Date(2016, 10, 20),\n \"HTML für die Notes Application erstellen.<br>CSS erstellen für die Notes Application<br>TODO<br>TODO\", 1,\n new Date(2016, 7, 17));\n note.finishedDate = new Date(2016, 8, 23);\n publicSaveNote(note);\n\n note = new Note(\"Einkaufen\", new Date(2016, 9, 12), \"Butter<br>Eier<br>Brot<br>...\", 2, new Date(2016, 8, 22));\n publicSaveNote(note);\n\n note = new Note(\"Mami anrufen\", null, \"888 888 88 88<br>Termin vereinbaren<br>Weihnachtsgeschenke<br>Ferienabwesenheit besprechen\", 3, new Date(2016, 8, 19));\n publicSaveNote(note);\n}", "firstUpdated() {}", "function addNote(){\r\n\tvar t = document.querySelector(\"#notes\");\r\n\tvar tr = t.childNodes[0];\r\n\tappendNote(tr, defaultNote);\r\n\taddState();\r\n\t\r\n\trefreshNotes();\r\n}", "function addNote() {\n if (noteText.value === \"\") {\n return;\n } else {\n notesCounter++;\n var note = {\n noteId: notesCounter,\n noteText: noteText.value,\n noteHead: noteHead.value,\n colorBg: noteDiv.style.background || \"rgb(255, 255, 255)\",\n tags: [],\n noteFavorite: false,\n noteFavoritePos: null,\n };\n // Add note to front end array\n notes.unshift(note);\n noteDiv.style.background = \"#ffffff\";\n renderNote(note);\n clearInputs();\n noteHead.style.display = \"none\";\n noteBot.style.display = \"none\";\n }\n console.log(note);\n }", "function setNotes(e) {\n\n\tvar cursor = e.target.result;\n\n\tif (cursor) {\n\n\t\tconsole.log(cursor.value);\n\t\tpopupPage.addNoteToView(cursor.value);\n\n\t\tcursor.continue();\n\n\t}\n\n}", "function init(){\n notes = JSON.parse(localStorage.getItem(\"notes\"));\n if(!notes) notes =[];\n notes.forEach(element => {\n addNote(element);\n });\n}", "function loadNotes() {\n noteId = 0;\n idx = 1;\n notes = [];\n document.getElementById('data').innerHTML = '';\n\n chrome.storage.sync.get('todos_notes', function(result) {\n notes = result.todos_notes;\n if (!notes) {\n notes = [''];\n }\n createNotes(notes, idx, 0);\n });\n }", "function checknotes(){\r\n\r\n}", "function addNote() {\n if (noteText.value === \"\") {\n return;\n } else {\n notesCounter++; // increamenting notes count\n var note = {\n noteId: notesCounter,\n noteText: noteText.value,\n noteHead: noteHead.value,\n colorBg: noteDiv.style.background || \"rgb(255, 255, 255)\",\n tags: [],\n noteFavorite: false,\n noteFavoritePos: null,\n };\n notes.unshift(note);\n noteDiv.style.background = \"#ffffff\";\n renderNote(note);\n updateDB();\n clearInputs();\n noteHead.style.display = \"none\";\n noteBot.style.display = \"none\";\n }\n}", "handler () {\n notes.addNote(title, body);\n }", "firstUpdated(e){}", "function addNote() {\n // formatter, to render date in polish format\n const formatter = new Intl.DateTimeFormat('pl');\n // create note object\n const note = {\n body: noteBody.value,\n img: noteImg.value,\n alt: noteAlt.value,\n date: formatter.format(new Date)\n }\n\n // create HTML node from note object\n const node = createItem(note);\n // append created node in HTML\n noteList.appendChild(node);\n // put created node in Map to match it with note\n map.set(node, note);\n // push current note to notes object\n notes.push(note);\n // overwrite notes in indexedDB with notes\n idbKeyval.set('notes', notes)\n .catch(err => console.error('submit failed: ', err));\n // reset input values\n noteBody.value = '';\n noteImg.value = '';\n noteAlt.value = '';\n }", "function showNote(note, button) {\n shownNote = note;\n shownNoteButton = button;\n $(\"#noteTime\", slide.contentDocument).text(new Date(note.time).toLocaleString());\n $(\"#noteBody\", slide.contentDocument)[0].value = note.body;\n $(\"#noteBody\", slide.contentDocument)[0].focus();\n }", "function addNote() {\n self.showAdd = !self.showAdd;\n }", "function getNote(thisRef) {\n var note_id = thisRef.attr(\"data-noteid\");\n $.getJSON('/notes/note/', {note_id: note_id}, function (data) {\n $('.note-info').attr('id', note_id);\n if (data.title === \"Untitled note\") {\n $('#title').empty();\n } else {\n $('#title').html(data.title);\n }\n $('.editor').html(data.body);\n });\n }", "function displayNotes (){\n if (localStorage.getItem(\"generalInfo\")){\n generalInfo = JSON.parse(localStorage.getItem(\"generalInfo\"));\n for(i = 0; i < generalInfo.length; i++){\n $(\"#inputEvent\"+generalInfo[i].display).attr(\"value\", generalInfo[i].notes);\n console.log($(\"#inputEvent\"+generalInfo[i].display));\n }\n }\n }", "function finalizeNote() {\r\n if (mel.type === \"melody\" || mel.type === \"gracenote\") {\r\n var note = mel.staffPosition.substring(0,1); // Staff position never has sharps or flats.\r\n var midiOffset = +mel.staffPosition.substring(1);\r\n if (lastKeySig && lastKeySig.data && lastKeySig.data.key && lastKeySig.data.key[note]) {\r\n note += lastKeySig.data.key[note]\r\n }\r\n mel.midiName = HD_TO_MIDINAME_XLATE[note + midiOffset];\r\n mel.midiNote = MIDINAME_TO_MIDI_NOTE[mel.midiName];\r\n mel.shortNoteName = note;\r\n }\r\n }", "function addNote(note) {\n setNotes((prevNotes) => {\n return [...prevNotes, note];\n });\n }", "function onNoteLoad() {\n\t\n\tvar db = window.openDatabase(\"notes\", \"1.0\", \"Notes Demo\", 2000000);\n\t//db.transaction(checkDb, errorCB, successCB);\n\ttry {\n\t\tdb.transaction(loadNote);\n\t}\n\tcatch(e) {}\n}", "function notesDB() { }", "function loadNotes() {\n if (localStorage.notes != undefined) {\n var contents = JSON.parse(localStorage.getItem(\"notes\"));\n\n for (var i = 0; i < contents.length; i ++) {\n addNote(contents[i]);\n }\n }\n}", "function addNote(note) {\n setNotesList(prevList => { return [...prevList, note] });\n }", "function findRelatedNotes(thisNote) {\n //console.log('findRelatedNotes has been called');\n if (myNotes.length > 0) {\n //console.log('case 1');\n var flag = false; //initialise flag / flag state reset\n // loop through exsisting notes. If note title exsists, then append note.\n for (var i = 0; i < myNotes.length; i++) {\n //console.log('loop started');\n if (myNotes[i].title == thisNote.title) {\n flag = true; //prevent note from being pushed as a new entry\n //console.log('found match');\n //console.log('appending to note');\n var currentNoteVal = myNotes[i].note;\n var newNoteVal = currentNoteVal + '<br/><br/>' + dateString + ' | ' + thisNote.note;\n //console.log(newNoteVal);\n myNotes[i].note = newNoteVal;\n Cookies.set('storedNotes', myNotes);\n //myNotes = Cookies.getJSON('storedNotes');\n //console.log('Saved');\n confirmation.placeholder = 'The note for this subject has been updated';\n note.value = '';\n }\n }\n if (flag === false) {\n pushNote(thisNote);\n }\n } else if (myNotes.length === 0) {\n //console.log('case 2');\n pushNote(thisNote);\n }\n}", "function addNote()\n{\n\tcreatePop(\"Add Note\", submitNote,{})\n}", "isFirstChange() { return this.firstChange; }", "isFirstChange() { return this.firstChange; }", "function gmQuickNotes() {\n\tif(document.getElementById(\"note\") && document.getElementById(\"PriorLibraryNotes\") ) {\n\t\t\n\t\t// Add quick notes\n\t\tif(document.getElementById(\"PriorLibraryNotes\").innerHTML.indexOf('QuickNotes') < 0) {\n\t\t\tdocument.getElementById(\"PriorLibraryNotes\").innerHTML += \n\t\t\t\t'<div class=\"QuickNotes\">' +\n\t\t\t\tdocument.getElementById(\"gmQuickNoteDiv\").innerHTML + '</div>';\n\t\t}\n\t\t\n\t\t// Set default value\n\t\tif(document.getElementById(\"note\").value == '') {\n\t\t\tdocument.getElementById(\"note\").value = QuickNoteDefaultOption;\n\t\t\tdocument.getElementById(\"note\").select();\n\t\t}\n\t\t\n\t}\n\tsetTimeout(gmQuickNotes, 500);\n}", "function checkNotes() {\n let noteContent = localStorage.getItem(\"note\");\n if (noteContent) { \n console.log(\"Note Exists\");\n document.getElementById(\"notes\").innerHTML = noteContent;\n }\n else {\n document.getElementById(\"notes\").placeholder = \"Whenever you're ready...\";\n }\n}", "function showNote() {\n $('#note').empty();\n let id = this.id;\n let note = createDiv(\"noteDiv\", data.players[id - 1].note)\n $('#note').append(note);\n }", "firstUpdated(changedProperties) {\n if (super.firstUpdated) {\n super.firstUpdated(changedProperties);\n }\n }", "isFirstChange() {\n return this.firstChange;\n }", "isFirstChange() {\n return this.firstChange;\n }", "isFirstChange() {\n return this.firstChange;\n }", "isFirstChange() {\n return this.firstChange;\n }", "isFirstChange() {\n return this.firstChange;\n }", "isFirstChange() {\n return this.firstChange;\n }", "isFirstChange() {\n return this.firstChange;\n }", "firstUpdated(_changedProperties) { }", "function saveNote(){\r\n if($('.notes-list-container').children('.note-item').length > 0){\r\n let content = editor.getContents();\r\n editNoteContent(editorNotebook, editorNote, editor.getContents());\r\n $('.notes-list-container .note-item.selected .note-item-title h4').text((content.ops[0].insert.length > 18) ? content.ops[0].insert.substr(0, 18) + \"...\" : content.ops[0].insert);\r\n }\r\n }", "function addNote(){\n var noteText = document.getElementById(\"note_text\").value;\n noteList.addNote(noteText);\n displayNotes();\n }", "get firstNewMessage()\n\t{\n\t\treturn true;\n\t}", "function addNote() {\n\t\n\tvar value = $('#add').val();\n\tif (value != '') {\n\n\t\tif (localStorage.getItem('last-id') === null) {\n\t\t\tvar new_id = 6;\n\t\t\tlocalStorage.setItem('last-id', new_id);\n\t\t}\n\t\telse {\n\t\t\tvar last_id = localStorage.getItem('last-id');\n\t\t\tvar new_id = parseInt(last_id)+1;\n\t\t}\n\t\t$('.notas-list').prepend('\\\n\t\t\t<article class=\"box-skin nota-thumb\" id=\"note'+ new_id +'\">\\\n\t\t\t\t<a href=\"#\" class=\"nota-delete\">X</a>\\\n\t\t\t\t<div class=\"nota-content\">\\\n\t\t\t\t\t<pre class=\"nota-title empty\" contenteditable></pre>\\\n <pre class=\"nota-text\" contenteditable>'+ value +'</pre>\\\n </div>\\\n\t\t\t</article>\\\n\t\t');\n\t\tvar $this = $('#note'+new_id);\n\n\t\t// fadeIn note & focus\n\t\tsetTimeout(function() {\n\t\t\t$this.removeClass('transparent').find('.nota-text').focus();\n\t\t}, 200);\n\n\t\t// clean input and hide btn\n\t\t$('#add').val('');\n\n\t\t// store added note\n\t\tsetLocalStorage($this);\n\n\t\t// store next id\n\t\tvar next_id = localStorage.setItem('last-id', new_id);\n\n\t\tsetNoteActive();\n\t\tsetTimeout(function() {\n\t\t\t$this.click();\n\t\t}, 200);\n\n\t\t// reiniciar o localStorage\n\t\t$this.find('.nota-title, .nota-text').keyup(function() {\n\t\t\thideEmptyfields($(this));\n\t\t\tsetLocalStorage($this);\n\t\t});\n\t\tdeleteNote();\n\t}\n}", "function firstBeat()\n{\n\tvar beat = setInterval(function()\n\t{\n\t\tnoteCount++;\n\t\tif(noteCount > 6)\n\t\t{\n\t\t\tclearInterval(beat);\n\t\t\ttextToGo();\n\t\t}\n\t\telse\n\t\t{\n\t\t\tanimate(notesInOrder[noteCount+6]);\n\t\t}\n\t}, beatTime);\n}", "function getNote () {\n\n var note = {\n owner: \"[email protected]\",\n title: \"todo\",\n items: [ \"laundry\", \"apply jobs\", \"gym\" ],\n createDate: \"1/1/2016\",\n lastModified: \"1/2/2016\",\n sharedWith: \"[email protected]\"\n }\n\n return note;\n\n } //end getNote()", "function addNote() {\n let titleEl = document.getElementById(\"title\")\n let detailsEl = document.getElementById(\"details\")\n\n newNote = new Note(titleEl.value, detailsEl.value)\n allNotes.push(newNote)\n\n printNote(newNote)\n resetFields(titleEl, detailsEl)\n checkBadWords(newNote)\n // changeBackground()\n}", "function init() {\n fs.readFile(\"./db/notes.json\", \"utf8\", function (err, data) {\n if (err) {\n throw err;\n }\n let notesJSON = JSON.parse(data);\n notesJSON.forEach(function (note) {\n notes.push(note);\n });\n lastId = Math.max(...notes.map((obj) => obj.id), 0) + 1;\n });\n}", "get note () {\n\t\treturn this._note;\n\t}", "get note () {\n\t\treturn this._note;\n\t}", "get note () {\n\t\treturn this._note;\n\t}", "get note () {\n\t\treturn this._note;\n\t}", "function init(){\n if (localStorage.getItem(\"note_local\")) {\n notesArray = JSON.parse(localStorage.getItem(\"note_local\"));\n for(var i=0;i<notesArray.length;i++)\n addnoteToDOM(notesArray[i].taskDetails, notesArray[i].taskDate, notesArray[i].taskHours);\n } \n}", "function input_note_onfocus(e) {\n var note = e.getAttribute(\"data-note\");\n if (!note) {\n note = e.value;\n e.setAttribute(\"data-note\", note);\n }\n e.value = e.value == note? '' : e.value;\n e.className = '';\n}", "addNote () {\n const time = Date.now()\n // Default new note\n const note = {\n id: String(time),\n title: 'New note ' + (this.notes.length + 1),\n content: \"**Hi!** This notebook is using [markdown](https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet) for formatting!\",\n created: time,\n favorite: false,\n }\n // Add to the list\n this.notes.push(note)\n }", "function Awake() {\n\tnoteNumber = noteNumberFirst + noteNumberNext;\n}", "notify (note) {\n // Handle type-specific updates.\n this.log('notes', 'notify', note)\n switch (note.type) {\n case 'order': {\n const order = note.order\n const mkt = this.user.exchanges[order.host].markets[order.market]\n if (mkt.orders) {\n for (const i in mkt.orders) {\n if (mkt.orders[i].id === order.id) {\n mkt.orders[i] = order\n break\n }\n }\n }\n break\n }\n case 'balance': {\n const wallet = this.user.assets[note.assetID].wallet\n if (wallet) wallet.balance = note.balance\n break\n }\n case 'feepayment':\n this.handleFeePaymentNote(note)\n break\n case 'walletstate': {\n const wallet = note.wallet\n this.assets[wallet.assetID].wallet = wallet\n this.walletMap[wallet.assetID] = wallet\n const balances = this.main.querySelectorAll(`[data-balance-target=\"${wallet.assetID}\"]`)\n balances.forEach(el => { el.textContent = (wallet.balance.available / 1e8).toFixed(8) })\n }\n }\n\n // Inform the page.\n if (this.loadedPage) this.loadedPage.notify(note)\n // Discard data notifications.\n if (note.severity < ntfn.POKE) return\n // Poke notifications have their own display.\n if (note.severity === ntfn.POKE) {\n this.pokeNote.firstChild.textContent = `${note.subject}: ${note.details}`\n this.pokeNote.classList.add('active')\n if (this.pokeNote.timer) {\n clearTimeout(this.pokeNote.timer)\n }\n this.pokeNote.timer = setTimeout(() => {\n this.pokeNote.classList.remove('active')\n delete this.pokeNote.timer\n }, 5000)\n return\n }\n // Success and higher severity go to the bell dropdown.\n this.notes.push(note)\n this.setNoteElements()\n }", "addNote(note) {\n note.id = this.nextID();\n let noteData = this.jsonData();\n\n //note that I use unshift and not push. This is to show the latest not on top when rendering.\n noteData.unshift(note);\n this.storeData(noteData);\n return noteData;\n }", "function newNote() {\n var csrftoken = $.cookie('csrftoken'),\n folder_id = $('.folder-list>.active>a').attr(\"data-folderid\"),\n data = {\n title: \"Untitled note\",\n body: \"<br>\",\n folder_id: folder_id,\n csrfmiddlewaretoken: csrftoken\n };\n $.post(\"/notes/addnote/\", data, function (data) {\n $('#notelist').children().prepend(data).children().first().trigger('click');\n $('#title').empty();\n });\n }", "function popupnotes_onclickSave()\n{\n notes_info.notes=frmPatientSummary.textareanotes.text.trim();\n notes_list.push(notes_info);\n frmPatientSummary.fcpopupnotes.setVisibility(false);\n frmPatientSummary.fcpatientsummaryheaderhover.setVisibility(false);\n frmPatientSummary.fcpatientsummaryfooterhover.setVisibility(false);\n}", "firstUpdated(_changedProperties) {\n }", "firstUpdated(_changedProperties) {\n }", "firstUpdated(_changedProperties) {\n }", "handleNewNote(event) {\n console.log('new note :D');\n \n //TODO ALL:\n //? ask user to save / discard current note if one is selected and has been modified\n //! REMOVE SAVEDNOTES DATA WHILE TESTING\n //* create new note object and save as selectedNote\n //* if the selectedNote is saved it will need to be added to savedNotes\n\n //* setup for new note object\n let notesCreated = this.state.notesCreated; //* id based on number of notes created (not tied to savedNotes.size)\n const selectedNote = {\n id: notesCreated,\n lastSaved: (new Date()).toUTCString(),\n title: '',\n text: ''\n };\n\n notesCreated += 1; //* updates number of notes created\n this.setState({ notesCreated, selectedNote }); \n }", "function addNote(newNote) {\n setNotes(prevNotes => {\n return [...prevNotes, newNote];\n });\n }", "firstUpdated() {\n super.firstUpdated();\n this.updateDisplayValue();\n }", "function displayNotes(note){\n return `<p>title: ${note.title}</p><p style=\"display:none\">note: ${note.body}</p>`\n }", "checkNextNote(){\n var ind = this.nextNoteNum * 2;\n //Get the note ( beat time and instrument number );\n var note = this.currentLoop.notes.slice( ind, ind+2 /*non-inclusive*/ );\n //Increment beat for the loop # we're on\n note[0] += this.startBeat + ( this.loopCount * this.currentLoop.beatLength );\n return note;\n }", "addNote(note) {\n const {title,text}=note;\n if (!title || !text){\n throw new Error(\"Neither text or title can be blank for the note entered\");\n }\n const newNote={title,text,id:uniqid()};\n return this.getNotes()\n .then((notes)=>[...notes,newNote])\n .then((currentNotes)=>this.write(currentNotes))\n .then(()=>newNote);\n }", "function frmPatientSummary_showpopupnotes()\n{\n searchPatient_closeSearchList();\n frmPatientSummary.lbltitle.text=frmPatientSummary.btnstepsofhealing.text;\n frmPatientSummary.lblerror.setVisibility(false);\n frmPatientSummary.textareanotes.text=\"\";\n notesModule.frmPatientSummaryAddNotes();\n}", "saveNote() {\n if (this.noteMessageInput.value) {\n let key = Date.now().toString();\n localStorage.setItem(key, this.noteMessageInput.value);\n this.displayNote(key, this.noteMessageInput.value);\n StickyNotesApp.resetMaterialTextfield(this.noteMessageInput);\n this.toggleButton();\n }\n }", "addNote(info) {\n const { title, text } = info;\n const newNote = { title, text, id: uuid() };\n return this.getInfo()\n .then ((info) => [...info, newNote])\n .then((updateInfo)=> this.write(updateInfo))\n .then(() => newNote);\n }", "function headline_notes()\n {\n // grab the .data element of the headline to note\n var note_it = $(this).parents(\".card\").data();\n // fetch notes for this headline\n $.get(\"/api/headlines/\" + note_it._id).then(function(data)\n {\n // HTML for notes modal\n var modal_html =\n [\n \"<div class='container-fluid text-center'>\",\n \"<h4>Notes For Article: \",\n note_it._id,\n \"</h4>\",\n \"<hr />\",\n \"<ul class='list-group note-container'>\",\n \"</ul>\",\n \"<textarea class='form-control' placeholder='New Note' rows='4'></textarea>\",\n \"<button class='btn btn-success save'>Save Note</button>\",\n \"</div>\"\n ].join(\"\");\n bootbox.dialog({\n message: modal_html,\n closeButton: true\n });\n var note_obj =\n {\n _id: note_it._id,\n notes: data.notes || []\n };\n // attach headline data to note\n $(\".btn.save\").data(\"headline\", note_obj);\n render_notes(note_obj);\n });\n }", "function createNoteByClick() {\n var newDate = new Date();\n var noteId = newDate.getTime();\n bq.setAttribute(\"id\", \"note-\" + noteId);\n bq.innerText = null;\n localStorage.setItem(noteId, \"\");\n bq.focus();\n}", "function pushNote(thisNote) {\n //console.log('push has been called');\n myNotes.push(thisNote);\n Cookies.set('storedNotes', myNotes);\n //myNotes = Cookies.getJSON('storedNotes');\n //console.log('New Note Saved');\n confirmation.placeholder = 'New note saved';\n note.value = '';\n}", "function setupNoteInputSection() {\n let notesSection = makeHTML(notesSection_raw);\n\n var detailsSection = document.querySelector(\"ytd-page-manager ytd-watch #main #meta\");\n detailsSection.parentElement.insertBefore(notesSection, detailsSection.nextSibling);\n var injectedNotesSection = document.querySelector(\"#notes-wrapper\");\n\n var notesObserver = new MutationObserver(function(mutations, observer) {\n setupExistingNotes();\n\n let mutation = mutations[0];\n let ytdItemSectionRenderer = mutation.addedNodes[1];\n let header = ytdItemSectionRenderer.childNodes[1];\n setupNoteHeader(header, observer);\n });\n notesObserver.observe(injectedNotesSection, {childList: true});\n}", "function update_note(data)\n {\n data.id = rcmail.html_identifier_encode(data.uid);\n\n var row, is_new = (notesdata[data.id] == undefined && data.list == me.selected_list);\n notesdata[data.id] = data;\n\n if (is_new || me.selected_note && data.id == me.selected_note.id) {\n render_note(data);\n update_taglist(data.tags || []);\n }\n else if (data.tags) {\n update_taglist(data.tags);\n }\n\n // add list item on top\n if (is_new) {\n noteslist.insert_row({\n id: 'rcmrow' + data.id,\n cols: [\n { className:'title', innerHTML:Q(data.title) },\n { className:'date', innerHTML:Q(data.changed || '') }\n ]\n }, true);\n\n noteslist.select(data.id);\n }\n // update list item\n else if (row = noteslist.rows[data.id]) {\n $('.title', row.obj).text(data.title);\n $('.date', row.obj).text(data.changed || '');\n // TODO: move to top\n }\n }", "firstUpdated(_changedProperties){}", "firstUpdated(_changedProperties){}", "get note() {\n\t\treturn this.__note;\n\t}", "get note() {\n\t\treturn this.__note;\n\t}", "get note() {\n\t\treturn this.__note;\n\t}", "function nextNote() {\n var secondsPerBeat = 60.0 / tempo * resolution / subdivision;\n nextNoteTime += secondsPerBeat / resolution;\n var c = cursor + 1;\n cursor++;\n\n drawSheet(c);\n if (cursor == max) {\n cursor = 0;\n }\n}", "function addNote(note) {\r\n setListNote((prevNote) => {\r\n return [...prevNote, note];\r\n });\r\n }", "function fResetToFirstTime(o) {\n geDate.rawValue = \"\";\n oFirstTime.rawValue = 1;\n o.presence = \"hidden\";\n app.alert(\n \"Now save this form - next time the form is opened the date will default to that day\"\n );\n}", "function nextNote() {\n const secondsPerBeat = 60.0 / tempo;\n nextNoteTime += secondsPerBeat; // Add beat length to last beat time\n // Advance the beat number\n currentNote++;\n}", "function noteload(data){\n $.each(data, function(i, note){\n note['time'] = [moment(note.created_at).format('MMMM Do YYYY, h:mm:ss a')]\n $('#maincontent').prepend(note_template(note))\n if (note.note_image == null){\n $('#imagecontainer').hide();\n $('.responsivecol').removeClass('col-sm-8').addClass('col-sm-12')\n }\n if (userEmail() == note.user.email ) {\n $('#noteedit').show()\n }\n })\n }", "function AddNote(noteText_ = \"\") {\n if (noteText_ == null || noteText_ == \"\") {\n return;\n }\n\n var newNoteArray = [];\n if (stateVars.itemArray != null) {\n newNoteArray = stateVars.itemArray;\n }\n\n newNoteArray.push(noteText_);\n\n setStateVars((prevState) => {\n return ({\n ...prevState,\n noteArray: newNoteArray,\n promptNewNote: false,\n newNoteText: \"\",\n requireUpdate: true\n });\n });\n }", "getNotes() { return this.notes; }", "function initNotesDisplay() {\n presenterNotes.style.display = 'flex';\n instructions.style.display = 'none';\n}", "function addnote(f)\n{\t\t\t\t\t\n\t// check to see if a user click save the note.\n\tif(saveflag==false && checkIfNoteSaved() == false)\n\t{\n\twarning({\n\t\ttitle:'Warning',\n\t\tmsg:'Would you like to Save the current note?',\n\t\tnoAction:function(){\n\t\t\tresetform();\n\t\t\tsaveflag=true;\n\t\t\t$('#save_note').attr('disabled','disabled');\n\t\t},\n\t\tyesAction:function(){\n\t\t\tif(saveNote() != false) {\n\t\t\t\tresetform();\n\t\t\t\tsaveflag=true;\n\t\t\t\t$('#save_note').attr('disabled','disabled');\n\t\t\t} else return false;\n\t\t\t},\n\t\tcancelAction:function(){return false;}\n\t\t});\n\t} else {\n\t\t\tresetform();\t\n\t}\n}", "function addButtonClick(){\n\t\tvar note = Note();\n\t\tstorage.push(note);\n\t\tdisplayNotes();\n\n\t}", "function displayNotes(notes) {\n\tvar el = document.getElementById('notes-played');\n\tel.innerHTML = notes; \n}", "function notePush(i) {\n strings.push(fretNotes[i].string);\n frets.push(fretNotes[i].fret);\n midis.push(fretNotes[i].midi);\n ids.push(fretNotes[i].id);\n relations.push(fretNotes[i].relation);\n count++;\n index.push(i);\n }", "function addNote(newNote) {\n allNotes.push(newNote);\n updateNotes(allNotes);\n}", "keyPressed(event, initialText) {\n const nextId = this.state.lastId + 1;\n const code = event.keycode || event.which;\n if (code === 13) {\n const newNote = {\n _id: nextId,\n text: initialText,\n dateUpdated: this.getDate()\n };\n this.setState(prevState => ({\n selectedNote: newNote,\n notes: [newNote, ...prevState.notes],\n searchNotes: \"\"\n }));\n }\n }", "function printNote(note) {\n if (note === undefined) {\n console.log('Note not found!');\n return;\n }\n\n if (note.type === 'Notes') {\n console.log(\n 'title: ' +\n note.title +\n '\\n\\tfilename: ' +\n note.filename +\n '\\n\\thashtags: ' +\n note.hashtags +\n '\\n\\tmentions: ' +\n note.mentions +\n '\\n\\tcreated: ' +\n note.createdDate +\n '\\n\\tchanged: ' +\n note.changedDate,\n );\n } else {\n console.log(\n 'date: ' +\n note.date +\n '\\n\\tfilename: ' +\n note.filename +\n '\\n\\thashtags: ' +\n note.hashtags +\n '\\n\\tmentions: ' +\n note.mentions,\n );\n }\n}", "function addNote() {\n var form = document.getElementById(\"note-form\");\n var title = document.getElementById(\"title\").value;\n var content = document.getElementById(\"contentbody\").value;\n var pri = document.getElementById(\"priority\").value;\n if (title !== \"\" && content !== \"\") {\n notes.push({\n title: `${title}`,\n content: `${content}`,\n pri: pri,\n id: c,\n state: 1\n });\n sendmsg(\"Note Added\", \"success\");\n } else {\n sendmsg(\"Fill all Fields\", \"danger\");\n }\n document.getElementById(\"title\").value = \"\";\n document.getElementById(\"contentbody\").value = \"\";\n c++;\n saveNotes();\n postNotes();\n btn.innerHTML = \"Add\";\n}", "function createNewNote()\n{\n randomNote = int(random(notes.length - 1));\n goalNote = notes[randomNote].note\n goalFrequency = -notes[randomNote].frequency\n\n // play voice over when the new note is created\n playVoiceOver();\n}", "completeEdit(updatedInfo, entryKey) {\n updatedInfo.searchString = updatedInfo.producer + updatedInfo.origin + updatedInfo.tastingNotes + updatedInfo.text + \"date:\" + updatedInfo.date + updatedInfo.barName;\n updatedInfo.tastingNotes = updatedInfo.tastingNotes ? updatedInfo.tastingNotes : \"(None)\";\n firebase.database().ref('userData/' + this.props.user.uid + '/userJournalEntries/' + entryKey).update(updatedInfo);\n }", "function addNewNote(title , content) {\n setTodoList(prev => {\n var newItem = {\n title : title,\n content: content\n }\n return[...prev, newItem]\n })\n \n }", "addNotes(note) {\n // generate random id each time\n let ID = uuidv4();\n // pull data from new note\n const { title, text } = note;\n // new note object to store data from above & adds new ID number\n const newNote = { id: ID, title, text }\n return this.getNotes()\n .then(notes => [...notes, newNote])\n .then(updateNotes => this.write(updateNotes))\n .then(() => newNote)\n }" ]
[ "0.6265579", "0.6251752", "0.6212055", "0.61438537", "0.6026429", "0.6023204", "0.6003627", "0.59873223", "0.5983173", "0.5974314", "0.5947799", "0.5882629", "0.5835221", "0.58303744", "0.5826249", "0.582183", "0.58167374", "0.5805337", "0.57676864", "0.573684", "0.5713743", "0.5698176", "0.56979936", "0.5696712", "0.5691948", "0.5682896", "0.5682896", "0.56776434", "0.56775385", "0.5662275", "0.56574476", "0.5655528", "0.5655528", "0.5655528", "0.5655528", "0.5655528", "0.5655528", "0.5655528", "0.5633528", "0.5614616", "0.5612446", "0.56121916", "0.56017476", "0.5592971", "0.55886227", "0.5582048", "0.55740845", "0.55620736", "0.55620736", "0.55620736", "0.55620736", "0.5560538", "0.55590844", "0.5555912", "0.55478585", "0.5542818", "0.5539334", "0.5531611", "0.55301225", "0.5529384", "0.5529384", "0.5529384", "0.55271155", "0.55259764", "0.5525105", "0.55149895", "0.55113333", "0.5499236", "0.5498841", "0.54909146", "0.5489473", "0.5488174", "0.5482037", "0.547884", "0.5478812", "0.54727024", "0.5469747", "0.5469747", "0.54666567", "0.54666567", "0.54666567", "0.54632926", "0.5462198", "0.54581285", "0.5455169", "0.54538053", "0.54537517", "0.54349434", "0.54171604", "0.5415539", "0.5409642", "0.54034656", "0.5401378", "0.53978044", "0.5396142", "0.53915495", "0.5391483", "0.53896683", "0.537915", "0.5374673", "0.5372921" ]
0.0
-1
update the percent of the scroll indicator bar when finishing fetch
componentDidUpdate(prevProps, prevStates) { if ( this.scrollerDiv.current && this.scrollerDiv.current.scrollHeight !== prevStates.scrollHeight ) { this.setScrolled(); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function handleProgressUpdate() {\n const { body } = document;\n const html = document.documentElement;\n const docHeight = Math.max(\n body.scrollHeight,\n body.offsetHeight,\n html.clientHeight,\n html.scrollHeight,\n html.offsetHeight\n );\n const viewportHeight = document.documentElement.clientHeight;\n const scrollableHeight = docHeight - viewportHeight;\n const scrolledHeight = window.scrollY;\n setProgressValue(scrolledHeight / scrollableHeight);\n }", "function scrollProgressBarUpdate() {\n var scrollProgressDiv = document.querySelector('div.scrollprogressbar');\n \n var windowHeight = window.innerHeight;\n var currentScrollPos = document.body.scrollTop || window.pageYOffset;\n var maxScroll = document.body.scrollHeight;\n \n var diff = maxScroll % windowHeight;\n \n\tvar percent = ((currentScrollPos + diff * 2) / (maxScroll + diff)) * 100;\n\tscrollProgressDiv.style.width = percent + '%';\n}", "function updateStatsUI() {\n countItems();\n var progressBarWidth = percentBar.css('width');\n progressBarWidth = Number(progressBarWidth.slice(0, progressBarWidth.length - 2));\n if (count == 0) {\n percentBarFill.css('width', '0px');\n percentText.text('0%');\n } else {\n percentBarFill.css('width', '' + Math.round(completed / count * progressBarWidth) + 'px');\n percentText.text('' + Math.round(completed / count * 100) + '%');\n }\n}", "function updateProgress() {\n var progress = 0,\n currentValue = $scope.curVal,\n maxValue = $scope.maxVal,\n // recompute overall progress bar width inside the handler to adapt to viewport changes\n progressBarWidth = progressBarBkgdElement.prop('clientWidth');\n\n if ($scope.maxVal) {\n // determine the current progress marker's width in pixels\n progress = Math.min(currentValue, maxValue) / maxValue * progressBarWidth;\n }\n\n // set the marker's width\n progressBarMarkerElement.css('width', progress + 'px');\n }", "function updateProgress() {\n $(\"#progressBar\").css(\"width\", _progress + \"%\");\n }", "function updateProgressBarLoadingCore() {\n var loading = 0, loaded = 0;\n loading += view.getModel().getResourceManager().getLoadingCount();\n loaded += view.getModel().getResourceManager().getLoadedCount();\n // Progress %\n status.setProgress(Math.floor(100 * (loaded || 0) / ((loading || 0) + (loaded || 1))) / 100);\n }", "function updateProgressBar() {\n let progressBar = document.getElementById(\"progress\");\n let percent = bodyArray.length * 2;\n let percentFullDisplay = document.getElementById(\"percent-full-value-display\");\n progressBar.style.width = percent + \"%\";\n percentFullDisplay.innerText = percent + \"%\";\n\n }", "function updateProgress() {\n let progressLabel = ui.Label({\n value: 'Scanning image collections ' + processedCount + ' of ' + collectionCount,\n style: {fontWeight: 'bold', fontSize: '12px', margin: '10px 5px'}\n });\n\n progressPanel.clear();\n progressPanel.add(progressLabel)\n }", "function updateProgress (evt) {\n var total = evt.lengthComputable ? evt.total : parseInt(xhr.getResponseHeader('X-Total-Length'));\n if (total) {\n var percentComplete = Math.round(evt.loaded * 100 / total);\n $('#downloadProgress').val(percentComplete);\n $(\"#prog\").width(percentComplete + '%');\n document.getElementById(\"textValue\").innerHTML = percentComplete + \"% complete\";\n } \n else {\n console.log(\"Unable to compute progress information since the total size is unknown\");\n }\n }", "function readProgress() {\n var $post = $('.main-content');\n var scrollH = ($post[0] &&\n $post[0].getBoundingClientRect().top * -1) || 0;\n \n var percent = parseInt((scrollH / Math.abs(($post.height() -\n $(window).height()))) * 100);\n percent = percent > 100 ? 100 : percent < 0 ? 0 : percent;\n percent += '%';\n\n $('.sidebar-progress-number').html(percent);\n $('.sidebar-progress-line').css('width', percent);\n }", "function updateProgress() {\n\t var percentage = (progressBar.hideEta - new Date().getTime()) / progressBar.maxHideTime * 100;\n\t progressElement.style.width = percentage + '%';\n\t }", "function $updateProgressBar(percent, complete){\r\n\tconsole.log(\"Recalculating progress bar - \" + percent + \"% initial data returned\");\r\n\tif (percent < 100) {\r\n\t\t\t$(\".meter > span\").each(function() {\r\n\t\t\t$(this).css('width', percent + \"%\");\r\n\t\t\t$(this).removeClass().addClass('orange');\r\n\t\t});\t\t\r\n\t}\t\r\n\tif (complete){\r\n\t\t$(\".meter > span\").each(function() {\r\n\t\t \t$(this).removeClass().addClass('green').css('width', '100%');\r\n\t\t});\t\t\t\r\n\t}\r\n}", "function updateProgress (event) {\r\n var elem = document.getElementById(\"bar\"); \r\n var width = 0;\r\n if (event.lengthComputable) {\r\n var percentComplete = event.loaded / event.total;\r\n width = parseInt(100 * percentComplete);\r\n elem.style.width = Math.max(4, width) + '%'; \r\n elem.innerHTML = '&nbsp;' + Math.max(1, width) + '%';\r\n } else {\r\n\t\t\t// Unable to compute progress information since the total size is unknown\r\n console.log(\"no progress indication available\");\r\n } // end if else length\r\n } // end function updateProgress (event) ", "#updatePercentage() {\n //1. calculate the percentage\n model.calculatePercentages();\n //2. Read the percentage from th budget controller\n var percentage = model.getPercentages();\n //3. display the percentage to the UI\n addItemsView.displayPercentage(percentage);\n }", "function progressBarScroll() {\n\t\tlet winScroll = document.body.scrollTop || document.documentElement.scrollTop,\n\t\t\t\theight = document.documentElement.scrollHeight - document.documentElement.clientHeight,\n\t\t\t\tscrolled = (winScroll / height) * 100;\n\t\tdocument.getElementById(\"progressBar\").style.width = scrolled + \"%\";\n\t}", "function updateProgress(){\n const computedPercentage = Math.round(attendanceRecords.length / traineeIds.length * 100);\n $(\"#progressbar\").children().attr(\"aria-valuenow\", computedPercentage).css(\"width\", computedPercentage + \"%\").text(computedPercentage + \"% Complete\");\n}", "updateProgressBar(percentage) {\n let $progressBar = document.getElementById(\"progress-bar\");\n this.progressBarObj.value = Math.min(\n 100,\n this.progressBarObj.value + percentage\n );\n $progressBar.style.width = this.progressBarObj.value + \"%\";\n $progressBar.valuenow = this.progressBarObj.value;\n $progressBar.innerText = this.progressBarObj.value + \"%\";\n }", "function updateProgress(showUI){\n var countsLeft = 0;\n for (var i=0; i < TagTracker.progressTracking.length; i++){\n countsLeft += TagTracker.progressTracking[i];\n }\n if (countsLeft > 0){\n if (debug > 1){\n console.log(\"not finished, continuing\");\n }\n\n console.log(document.getElementById(\"theProgressBar\"));\n\n var percent = 100 - Math.floor((countsLeft /\n (TagTracker.maxQueryCount * TagTracker.hashTags.length)) * 100);\n var progressBar = document.getElementById(\"theProgressBar\");\n\n if (TagTracker.strategy == \"sample\"){\n // TODO: if this makes sense, should just count # samples/sampleLimit\n //percent =\n }\n\n if (showUI){\n document.getElementById(\"theProgressBar\").style.width = percent + \"%\";\n }\n\n }else{\n renderContent();\n }\n }", "function updateBar(){\n var bar = $('#progress');\n\tif (variables.progress < 100){\n\t\tvariables.progress += 5;\n\t\tbar.width(variables.progress + '%');\n\t} else {\n\t\tvariables.progress = 0;\n\t\tvariables.videos += 1;\n\t\tbar.width(\"0%\");\n\t\tclearKeys();\n\t\tloadRound();\n\t}\n}", "function progressUpdate() {\r\n loadingProgress = Math.round(progressTl.progress() * 100);\r\n $(\".txt-perc\").text(loadingProgress + '%');\r\n}", "function updateProgressBar() {\n pbValue+=10;\n $('.progress-bar').css('width', pbValue+'%').attr('aria-valuenow', pbValue);\n $('.progress-bar').text(pbValue + \"%\");\n }", "function PopulatePercentage(value) {\n loadProgressBar(value);\n}", "onProgress(percentage, count) {}", "function progressBar(){\n //window.pageYOffset -> amount scrolled\n //document.body.scrollHeight -> total page height\n //window.innerHeigh -> window height\n document.getElementById('progress-bar').style.width = Math.min((101 * window.pageYOffset / (document.body.scrollHeight - window.innerHeight)), 100) + '%';\n}", "function update_progress() {\n let tot = open + closed;\n\n $(\"#progress_open\").css(\"width\", (open * 100 / tot) + \"%\");\n $(\"#progress_close\").css(\"width\", (closed * 100 / tot) + \"%\");\n}", "function updateProgressbarDisplay() {\n if (progressBarProgressionElement) {\n updateStep(progressBarProgressionElement)\n updateCounter()\n }\n }", "function updateProgressInfo() {\n\tif (!div_progress_info) {\n\t\tdiv_progress_info = document.getElementById('progress_info');\n\t}\n\tif (!div_progress_bar) {\n\t\tdiv_progress_bar = document.getElementById('progress_bar');\n\t}\n\tif (!div_progress_info && !div_progress_bar) {\n\t\treturn;\n\t}\n\n\tvar percentage = Math.floor(100.0*blamedLines/totalLines);\n\n\tif (div_progress_info) {\n\t\tdiv_progress_info.firstChild.data = blamedLines + ' / ' + totalLines +\n\t\t\t' (' + padLeftStr(percentage, 3, '\\u00A0') + '%)';\n\t}\n\n\tif (div_progress_bar) {\n\t\t//div_progress_bar.setAttribute('style', 'width: '+percentage+'%;');\n\t\tdiv_progress_bar.style.width = percentage + '%';\n\t}\n}", "function _updateProgressBar(oldReferenceLayer){oldReferenceLayer.querySelector(\".introjs-progress .introjs-progressbar\").style.cssText=\"width:\".concat(_getProgress.call(this),\"%;\");oldReferenceLayer.querySelector(\".introjs-progress .introjs-progressbar\").setAttribute(\"aria-valuenow\",_getProgress.call(this));}", "_updateProgress() {\n super._updateProgress();\n\n const that = this;\n\n //Label for Percentages\n if (that.showProgressValue) {\n const percentage = parseInt(that._percentageValue * 100);\n\n that.$.label.innerHTML = that.formatFunction ? that.formatFunction(percentage) : percentage + '%';\n }\n else {\n that.$.label.innerHTML = '';\n }\n\n if (that.value === null || that.indeterminate) {\n that.$value.addClass('jqx-value-animation');\n }\n else {\n that.$value.removeClass('jqx-value-animation');\n }\n\n that.$.value.style.transform = that.orientation === 'horizontal' ? 'scaleX(' + that._percentageValue + ')' : 'scaleY(' + that._percentageValue + ')';\n }", "function scrollProgressLine() {\n var body = document.body;\n var html = document.documentElement;\n var viewportHeight = window.innerHeight;\n var documentHeight = Math.max( body.scrollHeight, body.offsetHeight, html.clientHeight, html.scrollHeight, html.offsetHeight);\n var scrollTopValue = function () {\n return (window.pageYOffset !== undefined) ? window.pageYOffset : (document.documentElement || document.body.parentNode || document.body).scrollTop;\n };\n window.addEventListener('scroll', function () {\n var scroll = scrollTopValue();\n var progress = (scroll / (documentHeight - viewportHeight))*100;\n var valueToSet = progress.toFixed(0);\n $('.fix__progress').width(valueToSet + '%');\n });\n }", "function progressBarCarousel() {\n bar.css({ width: percent + \"%\" });\n percent = percent + 0.5;\n if (percent >= 100) {\n percent = 0;\n crsl.carousel(\"next\");\n }\n }", "function updateProgressBar(){ \r\n\tdocument.getElementById('progress').style.width = [count+1]/30*100+'%'; \r\n}", "function updateProgress (){\n\tprogress.value += 30;\n}", "function updateProgress(percentage){\n\tvar elem = document.getElementById('progress-bar');\n\tvar width = 1;\n\t\n\twidth = percentage;\n\tif(width > 1) width = 1;\n\telem.style.width = percentage*100 + '%';\n\n\t\n}", "update() {\n\t\tthis.scroll.update();\n\t}", "function update_status(current, total)\n {\n DOM.on_hold_progress_indicator.style.width = `${Math.round(100 * current / total)}%`;\n DOM.on_hold_status_message.textContent = `${current} / ${total}`;\n }", "function setProgress(currstep) {\n var percent = parseFloat(100 / widget.length) * currstep;\n percent = percent.toFixed();\n $(\".progress-bar\").css(\"width\", percent + \"%\").html(percent + \"%\");\n }", "function usar_update_progress_bar( percentage, speed ) {\n\t\tif ( typeof speed == 'undefined' ) {\n\t\t\tspeed = 150;\n\t\t}\n\t\t$( '.usar-progress' ).animate({\n\t\t\twidth: percentage\n\t\t}, speed );\n\t}", "function progressBarCarousel() {\n $bar.css({width:percent+'%'});\n percent = percent +0.5;\n if (percent>=100) {\n percent=0;\n $crsl.carousel('next');\n }\n }", "function updateProgress() {\n try {\n var gauge = getDailyTaskGauge();\n var progress = getProgress(gauge);\n if (progress === null) {\n return; // Progress is not there yet\n }\n if (!progress.done || progress.done === progress.total) {\n return;\n }\n var pb = getOrCreateProgressBar(gauge);\n pb.style.width = (100 * progress.done / progress.total) + '%';\n } catch (e) {\n console.log('DailyProgress: Ошибка при обновлении. ' + e);\n }\n}", "animatePercent () {\n if (!this.story) { return; }\n this.loaderPercent.innerHTML = this.story.percent + '%';\n requestAnimationFrame(this.animatePercent.bind(this));\n }", "function updateProgress (evt) {\n\n if (evt.lengthComputable) {\n var percentComplete = Math.floor((evt.loaded / evt.total) * 100),\n percentIntegrated = (percentComplete / 100) * options.width;\n\n // Display progress status\n if(options.progress != false) {\n $(options.progress).text(percentComplete); \n }\n\n // Convert 'percentComplete' to preloader element's width\n $(options.gazer).stop(true).animate({\n width: percentIntegrated\n }, function() {\n options.done.call();\n });\n\n } else {\n // when good men do nothing \n }\n }", "function updateProgress(percentage) {\n document.getElementById(\"pbar_innerdiv\").style.width = percentage + \"%\";\n}", "function updateProgress (oEvent) {\n \n if (first === false){\n console.log(oEvent);\n first = true;\n }\n \n if (oEvent.lengthComputable) {\n var percentComplete = oEvent.loaded / oEvent.total;\n console.log(percentComplete)\n progressBar.style.width = (percentComplete * 100) + \"%\"\n // ...\n } else {\n // Unable to compute progress information since the total size is unknown\n }\n}", "function _set(n) {\n if (!started) {\n return;\n }\n var pct = (n * 100) + '%';\n loadingBar.css('width', pct);\n status = n;\n\n // increment loadingbar to give the illusion that there is always\n // progress but make sure to cancel the previous timeouts so we don't\n // have multiple incs running at the same time.\n $timeout.cancel(incTimeout);\n incTimeout = $timeout(function () {\n _inc();\n }, 250);\n }", "update() {\n this.getProgression();\n }", "function handleProgress(e){\n if(e.lengthComputable){\n var percent = e.loaded / e.total * 100;\n $('.progress-bar').attr({value:e.loaded,max:e.total});\n $('.progress-bar').css('width', percent + '%');\n }\n }", "function go() {\n if (cnt++ < mydata['percent']) {\n setTimeout(go, 10);\n }\n $(element).css('width', cnt + '%');\n }", "function updateProgress() {\n let completed = 0;\n for (let i = 0; i < result.length; i++) {\n if (result[i].time != -1) {\n completed++;\n }\n }\n\n let percent = Math.floor((completed * 100) / result.length);\n let temp = \"\" + percent + \"%\";\n return temp;\n }", "function progressBarCarousel() {\n\t\t$bar.css({width:percent+'%'});\n\t\tpercent = percent +0.5;\n\t\tif (percent>=100) {\n\t\t\tpercent=0;\n\t\t\t$crsl.carousel('next');\n\t\t}\n\t}", "function progressBarCarousel() {\n\t\t$bar.css({width:percent+'%'});\n\t\tpercent = percent +0.5;\n\t\tif (percent>=100) {\n\t\t\tpercent=0;\n\t\t\t$crsl.carousel('next');\n\t\t}\n\t}", "_progress() {\n\tconst currentProgress = this.state.current * ( 100 / this.state.questionsCount );\n this.progress.style.width = currentProgress + '%';\n\n\t// update the progressbar's aria-valuenow attribute\n this.progress.setAttribute('aria-valuenow', currentProgress);\n }", "updateLoadingBar() {\n if (this.loadingRemains !== G.resource.remains) {\n this.loadingBar.text = `${G.resource.remains} resource(s) to load...\\nReceived file '${G.resource.currentLoad}'.`;\n }\n }", "function updateProgress ( current, total ){\n $(\".progress .currentProgress\").css('width', ((current - 1) / total) * 100 +'%');\n $(\".progress .progresstext\").html('Frage '+ current + ' von ' + (total))\n }", "function predictionProgress(event) {\n // var percent = 0;\n // var position = event.loaded || event.position;\n // var total = event.total;\n // var progress_bar_id = \"#progress-wrp\";\n // if (event.lengthComputable) {\n // percent = Math.ceil(position / total * 100);\n // }\n // // update progressbars classes so it fits your code\n // $(progress_bar_id + \" .progress-bar\").css(\"width\", +percent + \"%\");\n // $(progress_bar_id + \" .status\").text(percent + \"%\");\n}", "function updateProgress(progressAsPercentage) {\n bodyEl.querySelector(\n \".c8a11y-progress\"\n ).style.width = `${progressAsPercentage}%`;\n }", "function updateProgressMeter(pageNumber) {\n var numGoals = $('.goal-rank').length,\n percentIncr = 100;\n if (numGoals) {\n percentIncr = 100 * (1 / $('.goal-rank').length); \n }\n var newPercent = percentIncr * (pageNumber + 1);\n $('.progress-percent').text(newPercent);\n $('#onboarding-meter .meter').width(newPercent + \"%\");\n }", "function _set(n) {\n if (!started) {\n return;\n }\n var pct = (n * 100) + '%';\n loadingBar.css('width', pct);\n status = n;\n\n // increment loadingbar to give the illusion that there is always\n // progress but make sure to cancel the previous timeouts so we don't\n // have multiple incs running at the same time.\n if (autoIncrement) {\n $timeout.cancel(incTimeout);\n incTimeout = $timeout(function() {\n _inc();\n }, 250);\n }\n }", "function _set(n) {\n if (!started) {\n return;\n }\n var pct = (n * 100) + '%';\n loadingBar.css('width', pct);\n status = n;\n\n // increment loadingbar to give the illusion that there is always\n // progress but make sure to cancel the previous timeouts so we don't\n // have multiple incs running at the same time.\n if (autoIncrement) {\n $timeout.cancel(incTimeout);\n incTimeout = $timeout(function() {\n _inc();\n }, 250);\n }\n }", "function _set(n) {\n if (!started) {\n return;\n }\n var pct = (n * 100) + '%';\n loadingBar.css('width', pct);\n status = n;\n\n // increment loadingbar to give the illusion that there is always\n // progress but make sure to cancel the previous timeouts so we don't\n // have multiple incs running at the same time.\n if (autoIncrement) {\n $timeout.cancel(incTimeout);\n incTimeout = $timeout(function() {\n _inc();\n }, 250);\n }\n }", "function _set(n) {\n if (!started) {\n return;\n }\n var pct = (n * 100) + '%';\n loadingBar.css('width', pct);\n status = n;\n\n // increment loadingbar to give the illusion that there is always\n // progress but make sure to cancel the previous timeouts so we don't\n // have multiple incs running at the same time.\n if (autoIncrement) {\n $timeout.cancel(incTimeout);\n incTimeout = $timeout(function() {\n _inc();\n }, 250);\n }\n }", "onScroll () {\n const totalWidth = this.scrollRef.current.scrollWidth - this.scrollRef.current.offsetWidth\n const currentPosition = this.scrollRef.current.scrollLeft\n this.props.scrollPercent( Math.abs( currentPosition / totalWidth ) )\n }", "function onProgress( xhr ) {\n if ( xhr.lengthComputable ) {\n const percentComplete = xhr.loaded / xhr.total * 100;\n if (percentComplete > 99) {\n $('#placeholder')[0].innerText = 'Finishing up...'\n } else if (percentComplete > 50) {\n $('#placeholder')[0].innerText = 'Almost there...'\n }\n }\n\n }", "function updateProgressBar(){\n // Update the value of our progress bar accordingly.\n $('#progress-bar').val((player.getCurrentTime() / player.getDuration()) * 100);\n }", "function updateProgress(event) {\n if (event.lengthComputable) {\n const percentComplete = event.loaded / event.total * 100;\n postMessage(percentComplete + ' loadin ' + fileName);\n } else {\n // Unable to compute progress information since the total size is unknown\n }\n }", "function updateProgress(event) {\n if (event.lengthComputable) {\n const percentComplete = event.loaded / event.total * 100;\n postMessage(percentComplete + ' loadin ' + fileName);\n } else {\n // Unable to compute progress information since the total size is unknown\n }\n }", "updateProgressBar() {\n let revealRange = 103 - 24; //See css comment (progressBox). \n let revealPercent = this.points / this.pointsNeeded; //Current percent of points needed.\n this.baseProgressMargin = -24; //Margin value: Progress box hides bar.\n this.progressMargin = this.baseProgressMargin - revealPercent * revealRange; //New margin value\n document.getElementById(\"progress\").style.marginTop = this.progressMargin + \"vh\"; //Reveal percent of glowing border as level progress indicator.\n }", "function _set(n) {\n if (!started) {\n return;\n }\n var pct = (n * 100) + '%';\n loadingBar.css('width', pct);\n status = n;\n\n // increment loadingbar to give the illusion that there is always\n // progress but make sure to cancel the previous timeouts so we don't\n // have multiple incs running at the same time.\n $timeout.cancel(incTimeout);\n incTimeout = $timeout(function () {\n _inc();\n }, 250);\n }", "componentDidUpdate() {\r\n this.loadProgress();\r\n }", "function progressHandler(event) {\n\n var percent = Math.round((event.loaded / event.total) * 100);\n\n image_area.querySelector('.progress_bar').style.width = percent + \"%\";\n image_area.querySelector('.progress_bar').innerHTML = percent + \"%\";\n }", "function calcProgressBar() {\n $('.progress-bar .progress').css('width', `${((officialQuestionCount)/questionTotal)*100}%`)\n\n $({value: ((officialQuestionCount-1)/questionTotal)*100}).animate({value: ((officialQuestionCount)/questionTotal)*100}, {\n duration: 500,\n easing:'swing',\n step: function() {\n $('.progress-bar .progress .value').text(`${Math.round(this.value)}%`);\n }\n });\n}", "updateProgress() {\n this._Onprogress(this.state.CSVProgress * 100);\n }", "function updateProgressBar(){\n // Update the value of our progress bar accordingly.\n $('#progress-bar').val((r.getCurrentTime() / r.getDuration()) * 100);\n}", "function updateExpPercentage(){\n let percentages = budget.getPercentages();\n ui.displayPercentage(percentages);\n }", "percentage() {\n if(this.totalCount) {\n return parseInt((this.loadedCount * 100) / this.totalCount);\n }\n }", "function progressHandler(elem){\r\n var percentage=parseInt(elem.getAttribute('data-percentage'));\r\n percentage=(isNaN(percentage))? 0 : percentage;\r\n var indicator=elem.querySelector('.progress-indicator');\r\n var progressValue=elem.querySelector('.percentage');\r\n var progressWidth=(isNaN(parseInt(progressValue.textContent)) || parseInt(progressValue.textContent)>=100)? 0 : parseInt(progressValue.textContent);\r\n var interval=1;\r\n var timerId=null;\r\n if(progressWidth<percentage){\r\n indicator.style.width=progressWidth+'%';\r\n if(elem.getBoundingClientRect().bottom<=window.innerHeight && elem.getBoundingClientRect().top>0){\r\n timerId= setTimeout(function tick(){\r\n interval=Math.ceil(((1+progressWidth)*50/percentage));\r\n progressWidth++;\r\n indicator.style.width=progressWidth+'%';\r\n progressValue.textContent=progressWidth+'%';\r\n if(progressWidth<percentage){\r\n timerId=setTimeout(tick,interval);\r\n }\r\n else{\r\n clearTimeout(timerId);\r\n }\r\n },interval);\r\n }\r\n }\r\n}", "function set_progress(percent)\n{\n\tconsole.log(\"XDDD\");\n\tdocument.getElementById(\"bar\").style.width=percent+\"%\";\n}", "function updateProgressById(id, percent) {\n\t$(\"#\"+id+ \" .bar\").width(percent + \"%\");\n}", "function updateStatus(){ \n //Calculates the total price and hunger\n totalPrice = 0;\n var imageList = $(\".itemContainer2\").find(\"img\");\n totalHunger = 0;\n var hungerList = $(\".itemContainer2\").find(\"img\");\n var currentImg = \"\";\n for(var x = 0; x < imageList.length ; x++){\n currentImg = imageList[x];\n totalPrice += parseInt($(currentImg).attr(\"data-price\"));\n totalHunger += parseInt($(currentImg).attr(\"data-hunger\"));\n }\n \n if(totalHunger>100)\n totalHunger = 100;\n $(\".price\").text(\"$\"+totalPrice+ \"/$30\");\n $(\".hunger\").text(totalHunger + \"%\");\n \n $(\".bar\").attr(\"style\", \"width: \"+totalHunger+\"%\") //progress bar\n \n priceStatusLabel(totalPrice);\n DONEbuttonUpdate();\n \n}", "function updateProgressBar(el, currentValue, finalValue) {\n\tlet progressPercentage = currentValue / finalValue;\n\tlet parentWidth = el.parentElement.offsetWidth;\n\tif (progressPercentage <= 1) {\n\t\tlet progressWidth = progressPercentage * parentWidth;\n\t\tel.style.width = `${progressWidth}px`;\n\t\tif (progressPercentage < 0.35) el.style.background = \"var(--red)\";\n\t\telse if (progressPercentage > 0.35 && progressPercentage < 0.75) el.style.background = \"var(--yellow)\";\n\t\telse el.style.background = \"var(--green)\";\n\t}\n\tif (progressPercentage == 1) {\n\t\tif (!isPowerUpActive && !core.destroyed) {\n\t\t\tprogressPercentage = 0;\n\t\t\tpowerupContainer.classList.remove(\"hide\");\n\t\t\tpowerupProgressbarContainer.classList.add(\"hide\");\n\t\t\tpowerupProgressInfoEl.classList.add(\"hide\");\n\t\t}\n\t}\n}", "function updateProgress() {\n \"use strict\";\n //Gestion progress bar\n $('#quiz-progress').css('width', function () {\n var current = $('#question-number').text(), total = $('#question-total').val();\n return ((current / total) * 100).toString() + \"%\";\n });\n}", "function setProgress(percent) {\n $('#progressBar .progress-bar').css({width: percent + '%'});\n $('#percent').text(percent + '%');\n}", "function onLoadProgress(pct) {\n}", "function refreshCount() {\n // get count of all tables\n var countAllTasks = $('#Table_AllTasks').dataTable().fnGetData().length;\n var countInProgress = $('#Table_inProgress').dataTable().fnGetData().length;\n var countArchived = $('#Table_Archived').dataTable().fnGetData().length;\n var countCompleted = $('#Table_Completed').dataTable().fnGetData().length;\n\n $('#allTasksCount').html(countAllTasks);\n $('#inProgressCount').html(countInProgress);\n $('#archivedCount').html(countArchived);\n $('#completedCount').html(countCompleted);\n\n // refresh progressBar\n var count = 1;\n if (countAllTasks != 0) {\n count = (countAllTasks - countInProgress) / countAllTasks;\n }\n $('#progressBarSideBar').attr('style', 'width:' + count + '00%');\n\n}", "function setProgressBar(curStep){\n var percent = parseFloat(50 / steps) * curStep;\n percent = percent.toFixed();\n $(\".barrapedido1\")\n .css(\"width\",percent+\"%\")\n .html(percent+\"%\"); \n }", "function setProgressBar(curStep){\n var percent = parseFloat(50 / steps) * curStep;\n percent = percent.toFixed();\n $(\".barrafinal\")\n .css(\"width\",percent+\"%\")\n .html(percent+\"%\"); \n }", "function countToPercent(percent) {\n var interval = setInterval(counter,25);\n var n = 0;\n function counter() {\n if (n >= percent) {\n clearInterval(interval);\n valueProgressBarAnimated = true;\n }\n else {\n n += 1;\n // console.log(n);\n $(thisDiv).text(n + \"%\");\n }\n }\n }", "function updateProgressBar(width) {\n document.documentElement.style.setProperty('--progressbar-width', `${width}%`);\n}", "function progressBarFull() {\n\t$(\"#progress-bar-yellow\").css(\"width\",\"100%\");\n\tprogressBarPoint = 100;\n}", "function update_progress(idx){\r\n\t\t$('.step_nb').text(idx +'/'+list_elem_count);\r\n\t}", "function preloader_cb(percentage) {\n m_preloader.update_preloader(percentage);\n}", "updatePercent() {\n if ((!this.props.isPlaying || this.state.isInterrupted) && this.updateInterval) { // if shouldn't be update but is...\n window.clearInterval(this.updateInterval);\n this.updateInterval = undefined;\n return;\n }\n // find new percent viewed\n let new_percentViewed = 100*this.howler.seek()/this.howler.duration();\n this.setState({\n percentViewed: new_percentViewed\n });\n }", "function updateProgress(num1, num2){\n\t\tvar percent = Math.floor( num1 / num2 * 100 ) + '%';\n\t\tvar percentTwo = (num1 / num2 * 100) + '%';\n\t\t// console.log(percent + '////////' + percentTwo)\n\t\t$('.dragAnimate').css({\n\t\t\t'width' : percent\n\t\t})\n\t}", "function updateBar(){\n\t\t\tdocument.getElementById('misc_progress').style.height = (60 + bars.length * 60) + \"px\";\n\t\t\tfor(var i = 0; i < bars.length; i++){\n\t\t\t\tif(bars[i].bar == \"\" && bars[i].div == \"\"){\n\t\t\t\t\tbars[i].div = document.createElement('div');\n\t\t\t\t\tbars[i].div.innerHTML = '<h4>' + bars[i].title + '</h4>'\n\t\t\t\t\tbars[i].div.id = 'bar' + i;\n\t\t\t\t\tbars[i].div.class = 'bar';\n\t\t\t\t\tdocument.getElementById('misc-progressbar').appendChild(bars[i].div);\n\t\t\t\t\tbars[i].bar = new ProgressBar.Line('#bar' + i, {\n\t\t\t\t\t\tstrokeWidth: 3,\n\t\t\t\t\t\teasing: 'easeInOut',\n\t\t\t\t\t\tduration: 1000,\n\t\t\t\t\t\tcolor: '#878787',\n\t\t\t\t\t\ttrailWidth: 1,\n\t\t\t\t\t\ttrailColor: '#999',\n\t\t\t\t\t\ttext:{\n\t\t\t\t\t\t\tstyle:{\n\t\t\t\t\t\t\t\tposition: 'absolute',\n\t\t\t\t\t\t\t\tright: '5px',\n\t\t\t\t\t\t\t\ttop: '0px',\n\t\t\t\t\t\t\t\t'font-size': '18pt'\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t},\n\t\t\t\t\t\tfrom: {color: '#EBD9FF'},\n\t\t\t\t\t\tto: {color: \"#A550FF\"},\n\t\t\t\t\t\tstep: function (state, bar){\n\t\t\t\t\t\t\tbar.path.setAttribute('stroke', state.color);\n\t\t\t\t\t\t\tbar.setText(Math.round(bar.value() * 1000) / 10 + \"%\");\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tbars.forEach(function (obj){\n\t\t\t\tonenoteRequest('pages/' + obj.id + '/content', function (content, progressBar = obj.bar){\n\t\t\t\t\tvar parser = new DOMParser();\n\t\t\t\t\tvar dom = parser.parseFromString(content, 'text/html');\n\t\t\t\t\tprogressBar.animate(dom.querySelectorAll('[data-tag=\"to-do:completed\"]').length \n\t\t\t\t\t\t\t\t/ (dom.querySelectorAll('[data-tag=\"to-do:completed\"]').length + dom.querySelectorAll('[data-tag=\"to-do\"]').length));\n\t\t\t\t});\n\t\t\t});\n\t\t}", "function fetchProgressUpdate(){\n\t\t\t\t\t\n\t\t\t\t\t$.ajax({\n\t\t\t\t\t\turl: 'KernelAnalysis?getProgressStatus',\n\t\t\t\t\t\ttype: \"POST\",\n\t\t\t\t\t\tasync: true,\n\t\t\t\t\t\tdataType: \"json\",\n\t\t\t\t\t\tsuccess: function (data) {\n\t\t\t\t\t\t\t$(container).find('.progressbarGroup').css({'visibility': ''});//if we're receiving signals, show progress bar container.\n\t\t\t\t\t\t\t//alert('signal received: ' + JSON.stringify(data));\n\t\t\t\t\t\t\tif(data.title != null){\n\t\t\t\t\t\t\t\theaderTitle.innerHTML = data.title;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif(data.header != null){\n\t\t\t\t\t\t\t\tprogressHeader.innerHTML = data.header;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif(data.step != null && data.step == true){\n\t\t\t\t\t\t\t\tcurrentStep++;\n\t\t\t\t\t\t\t\tupdateProgress(currentStep);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif(data.done != null && data.done == true){\n\t\t\t\t\t\t\t\t$(reportItem).empty();\n\t\t\t\t\t\t\t\tloadKernelReport(reportItem, kernelData);\n\t\t\t\t\t\t\t\t$(menuCover).remove();\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t//errors?\n\t\t\t\t\t\t\t\tif(data.errors != null && data.errors.trim() != ''){\n\t\t\t\t\t\t\t\t\talert(data.errors);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif(data.canceled != null && data.canceled == true){\n\t\t\t\t\t\t\t\t$(cancelAnalysisSpan).hide();\n\t\t\t\t\t\t\t\theaderTitle.innerHTML = 'Canceling analysis.';\n\t\t\t\t\t\t\t\tprogressHeader.innerHTML = 'cleaning up temp file, please wait....';\n\t\t\t\t\t\t\t\tcurrentStep = 0;\n\t\t\t\t\t\t\t\tupdateProgress(currentStep);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tfetchProgressUpdate();\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t},\n\t\t\t\t\t\terror: function (jqxhr, statusText, errorThrown){\n\t\t\t\t\t\t\tconsole.log('an error occured while waiting for progressUpdate:\\n' + errorThrown);\n\t\t\t\t\t\t\talert('failed to get analysis signal: ' + errorThrown);\n\t\t\t\t\t\t\t//todo: some test to determin if to retry or not:\n\t\t\t\t\t\t\tif(false){\n\t\t\t\t\t\t\t\t//retry:\n\t\t\t\t\t\t\t\tfetchProgressUpdate();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t\t\n\t\t\t\t}", "async function setScroll() {\n setTimeout(function () {\n if (infoContent.scrollHeight == 0) {\n setScroll();\n } else if (infoContent.scrollHeight > infoContent.clientHeight+20) {\n scrollIndicator.style.display = \"block\";\n }\n }, 1000)\n }", "static finish() {\n this.progress = 100;\n setTimeout(() => {\n this.bar.style.width = `${this.progress}%`;\n }, 100);\n setTimeout(() => {\n this.parent.style.height = '0px';\n }, 1000);\n }", "function updateProgressIndicator(content)\n {\n $('#spot_easy_mode_loader_details').html(content);\n }", "function updateProgress() {\n\n // Update progress if enabled\n if (config.progress && dom.progress) {\n\n var horizontalSlides = toArray(document.querySelectorAll(HORIZONTAL_SLIDES_SELECTOR));\n\n // The number of past and total slides\n var totalCount = document.querySelectorAll(SLIDES_SELECTOR + ':not(.stack)').length;\n var pastCount = 0;\n\n // Step through all slides and count the past ones\n mainLoop: for (var i = 0; i < horizontalSlides.length; i++) {\n\n var horizontalSlide = horizontalSlides[i];\n var verticalSlides = toArray(horizontalSlide.querySelectorAll('section'));\n\n for (var j = 0; j < verticalSlides.length; j++) {\n\n // Stop as soon as we arrive at the present\n if (verticalSlides[j].classList.contains('present')) {\n break mainLoop;\n }\n\n pastCount++;\n\n }\n\n // Stop as soon as we arrive at the present\n if (horizontalSlide.classList.contains('present')) {\n break;\n }\n\n // Don't count the wrapping section for vertical slides\n if (horizontalSlide.classList.contains('stack') === false) {\n pastCount++;\n }\n\n }\n\n dom.progressbar.style.width = ( pastCount / ( totalCount - 1 ) ) * window.innerWidth + 'px';\n\n }\n\n }", "setProgress(percent) {\n const offset = this.circumference - percent / 100 * this.circumference;\n\n let circle = this.container.querySelector('.radialcircle');\n circle.style.strokeDasharray = `${this.circumference} ${this.circumference}`;\n circle.style.strokeDashoffset = offset;\n\n if (this.segments) {\n\n let tickwidth = this.segments * 2;\n\n let seglength = (((this.radius * 2) * Math.PI) - tickwidth) / (this.segments);\n\n let tickmarks = this.container.querySelector('.tickmarks');\n tickmarks.style.strokeDasharray = `2px ${seglength}px`;\n tickmarks.style.strokeDashoffset = 0;\n\n }\n }", "function onProgress(value) {\n document.getElementById('counter').innerHTML = Math.round(value);\n}" ]
[ "0.7429627", "0.726611", "0.71308297", "0.70691985", "0.689935", "0.6895333", "0.6849445", "0.68263537", "0.68130344", "0.678793", "0.6771746", "0.67644036", "0.67606825", "0.6705703", "0.670061", "0.66948634", "0.6657176", "0.66566694", "0.6637112", "0.6627516", "0.66006184", "0.6584207", "0.65756905", "0.65702957", "0.6552511", "0.65122926", "0.6491832", "0.64868087", "0.64727944", "0.64694387", "0.6467834", "0.6467217", "0.6449101", "0.6432054", "0.641742", "0.64074665", "0.63976866", "0.63966835", "0.63743436", "0.6373608", "0.63686854", "0.63633406", "0.63613945", "0.6353302", "0.633777", "0.6320927", "0.63174754", "0.63132703", "0.6302443", "0.629685", "0.629685", "0.62910604", "0.6287928", "0.6286096", "0.62779033", "0.6271387", "0.6262721", "0.62506527", "0.62506527", "0.62506527", "0.62506527", "0.6241591", "0.6236833", "0.62358034", "0.62294203", "0.62294203", "0.6226337", "0.62221414", "0.62196285", "0.6218749", "0.6217965", "0.6217299", "0.62149173", "0.621114", "0.6193639", "0.61900634", "0.61813194", "0.6170761", "0.61605597", "0.6159259", "0.61582327", "0.61561406", "0.61523855", "0.61493444", "0.6144853", "0.6135774", "0.61353266", "0.61217046", "0.61065644", "0.6099219", "0.6093225", "0.60876185", "0.6074942", "0.60661435", "0.60638976", "0.6053438", "0.60490817", "0.60469425", "0.60423505", "0.60411334", "0.60372776" ]
0.0
-1
cancel fethcing when changing component
componentWillUnmount() { this.mounted = false; this.getNotes = null; this.props.notesFetchCancelled(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "cancel() {\n this.state.cancelRender = true;\n }", "cancel() {\n this._revertInputValueToValue(); // In the next _detectAndDispatchChange() call, the change detection should not pass\n\n\n this._lastCommittedValue = this.value;\n this.close();\n }", "function cancel() {\n\t\t\tfocusedControl.fire('cancel');\n\t\t}", "function cancel() {\n\t\t\tfocusedControl.fire('cancel');\n\t\t}", "function cancel() {\n\t\t\tfocusedControl.fire('cancel');\n\t\t}", "@action\n cancelUpdatePosition() {\n this.showPositionDialog = false;\n this.earlySlot = null;\n }", "cancelUpdate() {\n this.updatingType = false;\n this.type = {};\n this.form.$setUntouched();\n }", "dispose() {\n\n\t\tthis.setEnabled(false);\n\n\t}", "dispose() {\n\n\t\tthis.setEnabled(false);\n\n\t}", "cancelEdit() {\n this.handsontableData = JSON.parse(JSON.stringify(this.handsontableDataBackup));\n this.hot.loadData(this.handsontableData);\n this.hot.render();\n\n // Change edit mode on redux\n this.props.setEdit();\n }", "cancel() {\n this.props.cancelSnapshotTransition();\n this.props.setSetting('advancedSettings');\n }", "cancel() {\n // stop drawing and remove the element\n this.stop();\n this.el.remove();\n\n this.el.fire('drawcancel');\n }", "disable() {\n tooling.unsubscribe( onChange );\n }", "handleCancel(event){\n this.showMode=true;\n this.hideButton=false;\n this.setEdit = true;\n this.hideEdit=false; \n }", "cancelXPointerEntry() {\n this.$el.find(\".cb-xf-xpointer\").removeClass('active');\n this.toggleXPointer();\n }", "function cancel()\n {\n dirtyController.setDirty(false);\n hideWorkflowEditor();\n hideWorkflowUpdateEditor();\n selectWorflow(selectedWorkflow);\n }", "cancelMe() {\n if (this.editFlag) {\n this.viewMe();\n } else {\n this.removeFromParentWithTransition(\"remove\", 400);\n }\n }", "static defaultStop (component) {\n store.commit('STOP_PROCESS', 'vk')\n store.commit('CLEAR_CANCEL', 'vk')\n component.loading = false\n }", "stopRendering () {\n this.d_is_rendering = false;\n }", "function resetComponentState(){isParent=false;previousOrParentTNode=null;elementDepthCount=0;bindingsEnabled=true;}", "function cancelChanges() {\n config = backupConfig\n renderSileoDepiction(config)\n hideAlert()\n}", "function cancel(){\n this.rotation = this.previousRotation;\n this.mouseSphere0 = null;\n}", "cancel() {\n this.cancelSource();\n }", "onCancel(){\n\n\tthis.setState({visible:false})\n}", "disable() {\n this._disabled = true;\n this._animation.stop();\n this.emit('clear');\n }", "cancelEdit() {\n const me = this,\n { inputField, oldValue } = me,\n { value } = inputField;\n\n if (!me.isFinishing && me.trigger('beforecancel', { value: value, oldValue }) !== false) {\n // Hiding must not trigger our blurAction\n me.isFinishing = true;\n me.hide();\n me.trigger('cancel', { value, oldValue });\n me.isFinishing = false;\n }\n }", "cancel() {\n cancel();\n }", "cancel() {\n this.disableEditMode();\n (this.props.onCancel || Function)();\n }", "function editCancelFunc(){\n setEdit(null);\n }", "_onCancel () {\n this._toggleModal(false);\n this.setState({refreshed: false});\n this.restartModal();\n }", "handleCancel( e ) {\n\t\tthis.setState( ( prevState ) => (\n\t\t\t{\n\t\t\t\tpostViews: pvcEditorArgs.postViews,\n\t\t\t\tisVisible: ! prevState.isVisible\n\t\t\t}\n\t\t) );\n\t}", "cancel() {\n this.cancelled = true;\n }", "function cancel() {\r\n const wrapper = document.querySelector(\".afhalen-wrapper\");\r\n wrapper.style.display = \"none\";\r\n resetState();\r\n // just to clear the error box\r\n sendErrorMessage(\"\");\r\n\r\n }", "_cancel() {\n this.dispatchEvent(new CustomEvent('cancel', {\n composed: true\n }));\n }", "deactivate(){\n\t\tthis.disposables.dispose();\n\t\tthis.disposables = null;\n\t}", "handleCancel(){\n //Dispatch an event to parent component to sand the updated data\n const updateEvent = new CustomEvent('updateconfig', {\n detail: {\"showDetails\":true,\"refreshData\":false}\n });\n this.dispatchEvent(updateEvent);\n }", "cancel(){\n \t//this.state.edittable = -1;\n \tthis.setState({edittable:-1});\n\n }", "unrender() {\n this.rendered = false;\n }", "function deactivate(){}", "cancel() {\n this.dispatchEvent(new PayloadEvent(ModifyEventType.CANCEL, this.clone_));\n this.setActive(false);\n }", "disable() {\n\t // leave empty in Widget.js\n\t }", "editCancel() {\n\t \t\t\tconst { travel } = this.state;\n\t \t\t\t\tthis.props.cancel(travel.key);\n\t }", "cancel(e) { }", "cancel() {\n // Rollback edit badge changes\n this.changeset.rollback(); //this.model.reload();\n\n this.set('editBadgeShow', false);\n }", "cancelEdit() {\n const me = this,\n {\n inputField,\n oldValue,\n lastAlignSpec\n } = me,\n {\n target\n } = lastAlignSpec,\n {\n value\n } = inputField;\n\n if (!me.isFinishing && me.trigger('beforeCancel', {\n value,\n oldValue\n }) !== false) {\n // Hiding must not trigger our blurAction\n me.isFinishing = true;\n me.hide();\n me.trigger('cancel', {\n value,\n oldValue\n });\n\n if (target.nodeType === 1) {\n target.classList.remove('b-editing');\n target.classList.remove('b-hide-visibility');\n }\n\n me.isFinishing = false;\n }\n }", "function cancel(e) {\n titleTask.value = null;\n descriptionTask.value = null;\n e.target.parentElement\n .parentElement\n .parentElement\n .classList.toggle('show');\n root.classList.toggle('opacity');\n document.body.classList.toggle('stop-scrolling');\n}", "function cancel() {\n props.dispatch({\n type: 'CLEAR_TRAVEL_FORM',\n });\n toggle();\n }", "handleCancel() {\n\t\tthis.clearInputs();\n\n\t}", "reset(){\n this.cySyncher.resetStyle();\n }", "cancel() {\n this.setState(Object.assign({}, this.state, {editable: false, data: this.props.data}));\n }", "stop() {\n this.active = false;\n }", "disable() {\n this.active = false;\n }", "componentWillUnmount() {\n window.clearTimeout(this.changeTO);\n }", "cancel() {\n\t\tweakmap.get(this).isCanceled = true;\n\t}", "reset() {\n this.unbind();\n }", "function Oncancel() {\n console.log('Oncancel event');\n\n //This is a hack; because when the Grid popup is canceled; it appears to update the command row to its initial state\n setTimeout(function () { grid.refresh() },50);\n}", "close() {\n this.activated = false;\n }", "cancelEvent() {\n }", "cancel () {\n this._fetching = false\n }", "cancel () {\n this._fetching = false\n }", "handleCancel(){\n this.setState({selectedArticle: null})\n }", "deactivate() {\n super.deactivate();\n this.litProportionProperty.set( 0 );\n }", "function cancelCallback()\n {\n deactivateInspectionToolButton();\n clearUndoBuffer();\n _layoutFunctions.enableToolbarMenu();\n }", "componentWillUnmount() {\n this.source.cancel('cancel request');\n }", "reset() {\r\n this.active = 'normal';\r\n }", "function cancelChanges() {\n\t\tsetEditMode(false);\n\t\tsetRows(previousRows);\n\t\tsetSelected([]);\n\t}", "cancelSettings() {\n this.props.cancel();\n }", "updated() {\n this.el.reset();\n }", "cancel() {\n if (!this._flying) {\n return;\n }\n this._flying = false;\n this._time1 = null;\n this._time2 = null;\n if (this._callback) {\n this._callback = null;\n }\n this.fire(\"canceled\", true, true);\n }", "onCancel() {\n this.props.resetTempSettings();\n }", "cancel() {\n\t\tthis.removeAllListeners()\n\t}", "abort() {\n const\n me = this,\n { view, creationData } = me;\n\n // Remove terminals from source and target events.\n if (creationData) {\n const { source, sourceResource, target, targetResource } = creationData;\n\n if (source) {\n const el = view.getElementFromEventRecord(source, sourceResource);\n if (el) {\n me.hideTerminals(el);\n }\n }\n if (target) {\n const el = view.getElementFromEventRecord(target, targetResource);\n if (el) {\n me.hideTerminals(el);\n }\n }\n }\n\n if (me.creationTooltip) {\n me.creationTooltip.disabled = true;\n }\n\n me.creationData = me.lastMouseMoveEvent = null;\n\n me.mouseDetacher && me.mouseDetacher();\n\n me.removeConnector();\n }", "cancelDataExplorer() {\n $(\".trender-container\").toggleClass(\"d-none d-block\");\n $(\"#data-explorer\").toggleClass(\"d-block d-none\");\n }", "unClickEvent() {\n this.setState({activeEvent: 0})\n }", "abort() {\n const me = this,\n { view, creationData } = me;\n\n // Remove terminals from source and target events.\n if (creationData) {\n const { source, sourceResource, target, targetResource } = creationData;\n\n if (source) {\n const el = view.getElementFromEventRecord(source, sourceResource);\n if (el) {\n me.hideTerminals(el);\n }\n }\n if (target) {\n const el = view.getElementFromEventRecord(target, targetResource);\n if (el) {\n me.hideTerminals(el);\n }\n }\n }\n\n me.creationData = null;\n\n me.mouseDetacher && me.mouseDetacher();\n\n me.removeConnector();\n }", "onCurrentChanged(value) {\n /* no-op */\n }", "_closeEdit() {\n\t\tthis.setState({ layerOn: false });\n\t}", "handleCancel(event) {\n // Clear the input field\n this.setState({ paletteName: \"\" });\n this.props.handleCancel();\n }", "discardChanges() {\n this.editMode = false;\n this.removeListener();\n }", "abort() {\n const me = this,\n {\n view,\n creationData\n } = me; // Remove terminals from source and target events.\n\n if (creationData) {\n const {\n source,\n sourceResource,\n target,\n targetResource\n } = creationData;\n\n if (source) {\n const el = view.getElementFromEventRecord(source, sourceResource);\n\n if (el) {\n me.hideTerminals(el);\n }\n }\n\n if (target) {\n const el = view.getElementFromEventRecord(target, targetResource);\n\n if (el) {\n me.hideTerminals(el);\n }\n }\n }\n\n if (me.creationTooltip) {\n me.creationTooltip.disabled = true;\n }\n\n me.creationData = me.lastMouseMoveEvent = null;\n me.mouseDetacher && me.mouseDetacher();\n me.removeConnector();\n }", "repaint() {\n this.container.style.display = 'none'\n setTimeout(() => this.container.style.display = '', 200)\n }", "cancel(){\n this.game.activeNPC.action=null;\n this.game.activeNPC=null;\n }", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}", "function deactivate() {}" ]
[ "0.71016383", "0.6754562", "0.66169834", "0.66169834", "0.66169834", "0.65770406", "0.6574968", "0.6495116", "0.6495116", "0.64642906", "0.6447245", "0.6446158", "0.6440962", "0.6440013", "0.64304316", "0.64190793", "0.63867587", "0.63772494", "0.6373597", "0.6367131", "0.6359015", "0.63571745", "0.6341666", "0.62980473", "0.6295594", "0.6245088", "0.62419", "0.6241788", "0.6225211", "0.6216388", "0.6180628", "0.6175354", "0.61647874", "0.6162752", "0.6159264", "0.6148772", "0.61304283", "0.6130227", "0.61200714", "0.6118906", "0.6104168", "0.61009943", "0.61001205", "0.6100064", "0.6098118", "0.6088852", "0.6075484", "0.6071527", "0.6070886", "0.6066724", "0.60564095", "0.6044631", "0.60435474", "0.6042405", "0.6041871", "0.60401773", "0.60225505", "0.601972", "0.60173106", "0.60173106", "0.6016244", "0.60107946", "0.60085297", "0.60052216", "0.60003906", "0.59970176", "0.5994907", "0.5992511", "0.59891874", "0.5987905", "0.59854645", "0.5977064", "0.5975884", "0.5975429", "0.59671944", "0.59524447", "0.5951252", "0.5950222", "0.5944664", "0.59385735", "0.5936068", "0.5932484", "0.5927291", "0.5927291", "0.5927291", "0.5927291", "0.5927291", "0.5927291", "0.5927291", "0.5927291", "0.5927291", "0.5927291", "0.5927291", "0.5927291", "0.5927291", "0.5927291", "0.5927291", "0.5927291", "0.5927291", "0.5927291", "0.5927291" ]
0.0
-1
in function 1 in function 2
function func1() { console.log('in function1'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function fun1(){} //toda a função de js retorna alguma coisa", "function accessesingData2() {\n\n}", "function accessesingData2() {\n\n}", "function fun1( /*parametros opcionais*/ ){ /*retorno opcional*/ }", "function fun1 ( ) {}", "function fun1( ) { }", "function fun1(){}", "function fun1(){}", "function fun1() {}", "function fun1() {}", "function fun1() { }", "function fun1() { }", "function fun1() { }", "function fun1() { }", "function fun1() { }", "function fun1() { }", "function fun1() { }", "function fun1() { }", "function fun1() {\n\n}", "function fun1(){\n\n}", "function accessesingData1() {\n\n}", "function accessesingData1() {\n\n}", "function func1() {}", "function process2(data){\n //do somthing with data\n}", "function func1() { }", "function lf1() { \n var la = 10;\n lf2();\n }", "function check1() {\n\n}", "function fn() {\n\t\t }", "function fun1(){ }", "function fun1(){ }", "function test2 (a) {\n test1 (0, 1);\n}", "function fun3(a,b){\n return \n\n}", "function _____SHARED_functions_____(){}", "function test2() {\n }", "function If_bound_other_other() {\r\n}", "function infun (obj1, obj2) {\n console.log(obj1 + \" -- \" + obj2)\n return obj1 + obj2\n}", "function If_bound_bound_other() {\r\n}", "function f1() {}", "function If_other_bound_other() {\r\n}", "function func1(){ // Em funções normais, não se pode omitir seus blocos, denotados por chaves. Apenas em arrow-functions.\r\n \r\n // O retorno de valor é facultativo. Caso você não ponha, ele retornará 'undefined'.\r\n }", "function second() {\r\n return third();\r\n }", "function fun2(){\n\treturn \"Hello World\";\n}", "function question4() {\n question2('functions in functions');\n}", "function func1(){ }", "function f2()\n{\n}", "function common_operation(value1,value2){\r\n var x = name_3.id[0];\r\n var y = name_3.id[1];\r\n x = parseInt(x);\r\n y = parseInt(y);\r\n var z = castle_elephent_4(x,y,turn);\r\n if (z == 5){\r\n return assign(value1,value2,x,y,turn);\r\n }\r\n else{\r\n z = castle_elephent_3(x,y,turn);\r\n if (z == 5){\r\n return assign(value1,value2,x,y,turn);\r\n } \r\n else{\r\n z = castle_elephent_2(x,y,turn);\r\n if (z == 5){\r\n return assign(value1,value2,x,y,turn);\r\n } \r\n else{\r\n z = castle_elephent_1(x,y,turn);\r\n if (z == 5){\r\n return assign(value1,value2,x,y,turn);\r\n } \r\n else{\r\n \r\n } \r\n } \r\n } \r\n }\r\n}", "function fn1(a,b) {\n function fn2(){\n alert(\"sum = \"+ (a+b).toStrin());\n }\n fn2();\n}", "function g2(x) {}", "function func1() {\n}", "function one(){\n \n}", "function miFuncion(){}", "function miFuncion(){}", "function miFuncion(){}", "function callFunctions(first, second) {\r\n closeOther(first);\r\n toggleCurrent(second);\r\n updateParentHeight(second);\r\n }", "function f1(){\n\n}", "function f1(){\n\n}", "enterA2(ctx) {\n\t}", "method2(){}", "method2(){}", "method2(){}", "function rtrn1(){\n\n}", "function a1() {\n let x = \"Alles\";\n console.log(x);\n func2();\n console.log(x);\n func1();\n console.log(x);\n console.log(\"Logo!\");\n }", "function madeSecond() {\n // will print 'This function, is cutting in from global'\n console.log('This is cutting in from madeSecond out in global'); \n }", "function miFuncion (){}", "function If_other_stack_other() {\r\n}", "function function2(parameter) {\n\tconsole.log(\"I am with parameter function and value of parameter is \"+parameter);\n}", "function a1() {\n }", "function run (fun1) {\n fun1()\n}", "function run(func1){\n func1()\n}", "function fie1(){\n console.log(\"fie1 wordt uitgevoerd\");\n}", "function otherFunct(){\n console.log(\"we are in another funct\");\n console.log(\"do stuff\");\n}", "function askAnotherPara(temp2) {\n return addTogether(temp1, temp2);\n }", "function two() {\r\n console.log('work 2');\r\n return 54;\r\n}", "function a1(){\n\treturn 1;\n}", "function transition_listener(p1, p2, time){\n\tp1.obj[p1.lstnr](p1.value);\n\treturn p1.value;\n}", "function three () {}", "function tutu(nombre2){\n\n\tvar nombre1 = nombre2;\n\treturn nombre1;\n\n}", "function inherbit( fn1, fn2 ){\n var prototype = Object.create( fn1.prototype );\n prototype.constructor = fn2;\n fn2.prototype = prototype;\n }", "function source(){\nv=0;\nflag1=1;\n}", "function fuction() {\n\n}", "function fn1(x,y) {\r\n \r\n var a = x\r\n var b = y\r\n console.log(a + b)\r\n // console.log(b)\r\n }", "function fun1(){\n console.log('Thise is normal function');\n}", "function cargarpista1 (){\n \n}", "function wa(){}", "function check3 (){\n\n}", "function lazyIntersection(fn1, fn2) {\n\n return function (param) {\n \n return fn1(param) && fn2(param);\n }; \n}", "function lazyIntersection(fn1, fn2) {\n\n return function (param) {\n \n return fn1(param) && fn2(param);\n }; \n}", "function lazyIntersection(fn1, fn2) {\n\n return function (param) {\n \n return fn1(param) && fn2(param);\n }; \n}", "function lazyIntersection(fn1, fn2) {\n\n return function (param) {\n \n return fn1(param) && fn2(param);\n }; \n}", "function lazyIntersection(fn1, fn2) {\n\n return function (param) {\n \n return fn1(param) && fn2(param);\n }; \n}", "function lazyIntersection(fn1, fn2) {\n\n return function (param) {\n \n return fn1(param) && fn2(param);\n }; \n}", "function lazyIntersection(fn1, fn2) {\n\n return function (param) {\n \n return fn1(param) && fn2(param);\n }; \n}", "function lazyIntersection(fn1, fn2) {\n\n return function (param) {\n \n return fn1(param) && fn2(param);\n }; \n}", "function lazyIntersection(fn1, fn2) {\n\n return function (param) {\n \n return fn1(param) && fn2(param);\n }; \n}", "function lazyIntersection(fn1, fn2) {\n\n return function (param) {\n \n return fn1(param) && fn2(param);\n }; \n}", "function lazyIntersection(fn1, fn2) {\n\n return function (param) {\n \n return fn1(param) && fn2(param);\n }; \n}", "function lazyIntersection(fn1, fn2) {\n\n return function (param) {\n \n return fn1(param) && fn2(param);\n }; \n}", "function lazyIntersection(fn1, fn2) {\n\n return function (param) {\n \n return fn1(param) && fn2(param);\n }; \n}", "function v2(v3,v4) {\n}", "f1() {\n }" ]
[ "0.6685216", "0.64166355", "0.64166355", "0.6346534", "0.6324493", "0.62864715", "0.62618065", "0.62618065", "0.62493503", "0.62493503", "0.6214583", "0.6214583", "0.6214583", "0.6214583", "0.6214583", "0.6214583", "0.6214583", "0.6214583", "0.6105682", "0.6081066", "0.6066492", "0.6066492", "0.6016199", "0.59840024", "0.5965698", "0.5941478", "0.5915875", "0.59107614", "0.59084535", "0.59084535", "0.59032005", "0.58711123", "0.58479404", "0.582362", "0.5818389", "0.5817355", "0.5773157", "0.57485497", "0.57404804", "0.57369006", "0.571163", "0.5707436", "0.57018733", "0.57003546", "0.5693766", "0.5668851", "0.5662428", "0.56601036", "0.56478965", "0.5645715", "0.5613112", "0.5613112", "0.5613112", "0.5603924", "0.5598564", "0.5598564", "0.5597159", "0.55839896", "0.55839896", "0.55839896", "0.5569317", "0.5566656", "0.5561902", "0.55525297", "0.5533445", "0.55093634", "0.5508114", "0.5481566", "0.5480971", "0.54800344", "0.54713017", "0.5463853", "0.5456882", "0.54425645", "0.54354775", "0.543352", "0.543016", "0.54282033", "0.5427483", "0.54243267", "0.5412848", "0.54092914", "0.5407546", "0.5407536", "0.5403912", "0.53894526", "0.53894526", "0.53894526", "0.53894526", "0.53894526", "0.53894526", "0.53894526", "0.53894526", "0.53894526", "0.53894526", "0.53894526", "0.53894526", "0.53894526", "0.5387357", "0.5383215" ]
0.5809008
36
This bit of disgustingness is to deal with a bug (28/11/2017) in the Twitch JS Helper. Normally you would call listen for the whisper channel inside onAuthorized when you get your opaque ID, however, calling twitch.listen inside onAuthorise causes the listen function to be registered more than one time for some reason. So we wait for onAuth to be called and then register the listener here.
function whisperHack() { if (!firstTimeOnly) { // Listen to this viewer's private PubSub whisper channel twitch.listen('whisper-'+latestAuth.userId, (target, type, msg) => { // console.log("New Twitch PubSub whisper:", msg); }); } else { setTimeout(whisperHack, 1000); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "_registerExternalAuthListeners () {\n this.migration = caller('migration', {postMessage: window.parent.postMessage.bind(window.parent)})\n this.authenticate = caller('authenticate', {postMessage: window.parent.postMessage.bind(window.parent)})\n this.createLink = caller('createLink', {postMessage: window.parent.postMessage.bind(window.parent)})\n }", "function listenForAuthChanges() {\r\n auth.onAuthStateChanged(user => {\r\n if (user) {\r\n user.getIdTokenResult().then(idTokenResult => {\r\n user.admin = idTokenResult.claims.admin;\r\n Client.setupUI(user, db);\r\n })\r\n showMovieList();\r\n } else {\r\n Client.setupUI();\r\n hideMovieList();\r\n }\r\n })\r\n}", "init() {\n _listenToCurrentUser();\n }", "function registerAuthenticationListener() {\n lock.on('authenticated', function (authResult) {\n localStorage.setItem('id_token', authResult.idToken);\n authManager.authenticate();\n\n lock.getProfile(authResult.idToken, function (error, profile) {\n if (error) {\n return console.log(error);\n }\n\n localStorage.setItem('profile', JSON.stringify(profile));\n deferredProfile.resolve(profile);\n });\n\n });\n }", "_setListeners() {\n this.rtm.on(CLIENT_EVENTS.RTM.AUTHENTICATED, (data) => {\n // Remember our own id and workspace users when signed in\n this.botId = data.self.id;\n this.slackUsers = data.users;\n });\n\n this.rtm.on(CLIENT_EVENTS.RTM.RTM_CONNECTION_OPENED, () => {\n // Update our saved user list when RTM connection is opened.\n this._updateUsers()\n .then(() => {\n // Run task if there is one\n if (this.task && typeof this.task === 'function') {\n this.task(this);\n }\n })\n .catch(() => {});\n });\n\n // If this bot is not performing a task, it should start listening to messages\n if (!this.task) {\n this._setMessageListener();\n }\n }", "function addListener(expectedTabId, rootName) {\n chrome.tabs.onUpdated.addListener((tabId, changeInfo, tab) => {\n if (tabId !== expectedTabId) {\n // Another tab updated.\n return;\n }\n //console.log(\"Page Status: \" + changeInfo.status);\n if (changeInfo.status === \"loading\") {\n let currentMessage = document.getElementById(\"status\").textContent;\n if (!(currentMessage.includes(\"Getting\") ||\n currentMessage.includes(\"Refreshings\") ||\n currentMessage.includes(\"Trying\"))) {\n renderStatus(\"Getting Access \\u2026\");\n document.getElementById(\"status\").style.color = \"#fff\";\n }\n hide(document.getElementById(\"statusIcon\"));\n show(document.getElementById(\"loaderContainer1\"));\n } else if (changeInfo.status === \"complete\") {\n let url;\n \n // this line requires the \"tabs\" permision\n try { url = getUrlFromTab(tab); }\n catch (error) {\n console.log(\"CAUGHT-\" + error);\n renderUnknown(\"Can\\u2019t confirm access.\");\n return;\n }\n let loginCheck = url.includes(\"idp.mit.edu\");\n let redirectCheck = url.toLowerCase().includes(\"redirect\");\n let failCheck1 = url.includes(\"libproxy.mit.edu/login?url=\");\n let failCheck2 = url.includes(\"libproxy.mit.edu/menu\") && url.length < 30;\n let failCheck3 = url.includes(\"libproxy.mit.edu/connect?session\");\n if (loginCheck) {\n if (redirectCheck) {\n // an expected redirect\n //console.log(\"URL indicates redirect.\");\n } else {\n //console.log(\"URL indicates login.\");\n renderStatus(\"Provide your MIT credentials.\");\n closeLoader();\n presentIcon(\"lock\");\n }\n } else if (failCheck1 || failCheck2 || failCheck3) {\n //console.log(\"URL indicates failure.\");\n renderFailure(rootName + \" is not a supported proxy site.\"); \n } else if (successCheckUrl(url)) {\n //console.log(\"URL indicates success.\");\n renderSuccess();\n } else {\n //console.log(\"URL was unexpected.\");\n renderUnknown(\"Unexpected redirect.\");\n } \n }\n });\n}", "function registerAuthenticationListener() {\n\n lock.on('authenticated', function (authResult) {\n localStorage.setItem('id_token', authResult.idToken);\n authManager.authenticate();\n\n lock.getProfile(authResult.idToken, function(error, profile) {\n if (!error) {\n localStorage.setItem('profile', JSON.stringify(profile));\n $rootScope.name = profile.name;\n var url = localStorage.getItem('redirect_url').replace('#!','');\n if(url) {\n $location.path(url);\n }\n } else {\n console.log(error);\n }\n });\n });\n }", "on_connecter() {\n this.enregistrerChannel()\n }", "init() {\n this._onEndpointConnStatusChanged = this.onEndpointConnStatusChanged.bind(this);\n this.rtc.addListener(_service_RTC_RTCEvents__WEBPACK_IMPORTED_MODULE_5___default.a.ENDPOINT_CONN_STATUS_CHANGED, this._onEndpointConnStatusChanged); // Handles P2P status changes\n\n this._onP2PStatus = this.refreshConnectionStatusForAll.bind(this);\n this.conference.on(_JitsiConferenceEvents__WEBPACK_IMPORTED_MODULE_1__[\"P2P_STATUS\"], this._onP2PStatus); // Used to send analytics events for the participant that left the call.\n\n this._onUserLeft = this.onUserLeft.bind(this);\n this.conference.on(_JitsiConferenceEvents__WEBPACK_IMPORTED_MODULE_1__[\"USER_LEFT\"], this._onUserLeft); // On some browsers MediaStreamTrack trigger \"onmute\"/\"onunmute\"\n // events for video type tracks when they stop receiving data which is\n // often a sign that remote user is having connectivity issues\n\n if (_browser__WEBPACK_IMPORTED_MODULE_4__[\"default\"].supportsVideoMuteOnConnInterrupted()) {\n this._onTrackRtcMuted = this.onTrackRtcMuted.bind(this);\n this.rtc.addListener(_service_RTC_RTCEvents__WEBPACK_IMPORTED_MODULE_5___default.a.REMOTE_TRACK_MUTE, this._onTrackRtcMuted);\n this._onTrackRtcUnmuted = this.onTrackRtcUnmuted.bind(this);\n this.rtc.addListener(_service_RTC_RTCEvents__WEBPACK_IMPORTED_MODULE_5___default.a.REMOTE_TRACK_UNMUTE, this._onTrackRtcUnmuted); // Track added/removed listeners are used to bind \"mute\"/\"unmute\"\n // event handlers\n\n this._onRemoteTrackAdded = this.onRemoteTrackAdded.bind(this);\n this.conference.on(_JitsiConferenceEvents__WEBPACK_IMPORTED_MODULE_1__[\"TRACK_ADDED\"], this._onRemoteTrackAdded);\n this._onRemoteTrackRemoved = this.onRemoteTrackRemoved.bind(this);\n this.conference.on(_JitsiConferenceEvents__WEBPACK_IMPORTED_MODULE_1__[\"TRACK_REMOVED\"], this._onRemoteTrackRemoved); // Listened which will be bound to JitsiRemoteTrack to listen for\n // signalling mute/unmute events.\n\n this._onSignallingMuteChanged = this.onSignallingMuteChanged.bind(this); // Used to send an analytics event when the video type changes.\n\n this._onTrackVideoTypeChanged = this.onTrackVideoTypeChanged.bind(this);\n }\n\n this._onLastNChanged = this._onLastNChanged.bind(this);\n this.conference.on(_JitsiConferenceEvents__WEBPACK_IMPORTED_MODULE_1__[\"LAST_N_ENDPOINTS_CHANGED\"], this._onLastNChanged);\n this._onLastNValueChanged = this.refreshConnectionStatusForAll.bind(this);\n this.rtc.on(_service_RTC_RTCEvents__WEBPACK_IMPORTED_MODULE_5___default.a.LASTN_VALUE_CHANGED, this._onLastNValueChanged);\n }", "function listener(event) {\n if (event.data && event.data.sessionId) {\n if (event.origin !== window.location.origin) {\n logger.warn(`Ignoring sessionId from different origin: ${event.origin}`);\n return;\n }\n\n _settings_Settings__WEBPACK_IMPORTED_MODULE_1__[\"default\"].sessionId = event.data.sessionId; // After popup is closed we will authenticate\n }\n } // Register", "function getChannelIdCallback(details) {\n console.log(\"channelId callback arrived, channel Id is '\" +\n details.channelId + \"'\");\n var channelId = details.channelId;\n if (\"\" == channelId) {\n chrome.test.fail(\"No channelId, test failed.\");\n } else {\n getAccessToken(channelId);\n }\n}", "function registerAuthenticationListener() {\n lock.on('authenticated', function(authResult) {\n localStorage.setItem('id_token', authResult.idToken);\n authManager.authenticate();\n\n lock.getProfile(authResult.idToken, function(error, profile) {\n if (error) {\n return console.log(error);\n }\n var userDetails = {\n emailAddress: profile.email,\n firstName: profile.given_name,\n lastName: profile.family_name,\n gender: profile.gender,\n socialId: profile.identities[0].user_id\n };\n $http.post(\"http://75.118.135.179:9080/BuffDaddyAPI/register\", JSON.stringify(userDetails))\n .then(\n function successCallback(response) {\n console.log(\"Success register\");\n },\n function errorCallback(response) {\n alert(\"Error \" + JSON.stringify(response));\n });\n localStorage.setItem('profile', JSON.stringify(profile));\n deferredProfile.resolve(profile);\n });\n\n });\n }", "function initAPIListeners() {\n /*\n * This listens in for whenever a new DJ starts playing.\n */\n API.addEventListener(API.DJ_ADVANCE, djAdvanced);\n\n /*\n * This listens for changes in the waiting list\n */\n API.addEventListener(API.WAIT_LIST_UPDATE, queueUpdate);\n\n /*\n * This listens for changes in the dj booth\n */\n API.addEventListener(API.DJ_UPDATE, queueUpdate);\n\n /*\n * This listens for whenever a user in the room either WOOT!s\n * or Mehs the current song.\n */\n API.addEventListener(API.VOTE_UPDATE, function (obj) {\n if (userList) {\n populateUserlist();\n }\n });\n\n /*\n * Whenever a user joins, this listener is called.\n */\n API.addEventListener(API.USER_JOIN, function (user) {\n if (userList) {\n populateUserlist();\n }\n });\n\n /*\n * Called upon a user exiting the room.\n */\n API.addEventListener(API.USER_LEAVE, function (user) {\n if (userList) {\n populateUserlist();\n }\n });\n\n API.addEventListener(API.CHAT, checkCustomUsernames);\n}", "_setupListeners() {\n whitelistStatusControllerLogger.info(\"Setting up Listeners...\");\n document.getElementById(\"discord_login\").onclick = () => {\n this.checkStatus();\n };\n }", "function callListener(event, origin) {\n function generateThisObject() {\n return {\n getOriginalListener: ytcenter.utils.funcBind(null, getYouTubeListener, event)\n };\n }\n \n var ytEvent = \"ytPlayer\" + event + \"player\" + playerId;\n var args = Array.prototype.slice.call(arguments, 2);\n var returnVal = null;\n \n if (enabled && origin === 0 && (!events.hasOwnProperty(event) || (events.hasOwnProperty(event) && !events[event].override))) {\n /* Override is false and the origin is from the player; call the YouTube Center listeners */\n if (events.hasOwnProperty(event)) {\n for (var i = 0, len = events[event].listeners.length; i < len; i++) {\n returnVal = events[event].listeners[i].apply(null, args);\n }\n }\n } else if (enabled && origin === 1) {\n if (events.hasOwnProperty(event) && events[event].override) {\n /* Override is true and the origin is from the global window; call the YouTube Center listeners */\n for (var i = 0, len = events[event].listeners.length; i < len; i++) {\n events[event].listeners[i].apply(generateThisObject(), args);\n }\n con.log(\"[Player Listener] Event \" + event + \" was called with\", args);\n } else if (ytListeners[ytEvent]) {\n if (apiNotAvailable) {\n /* API is not available therefore call YouTube Center listeners as YouTube listener is called */\n for (var i = 0, len = events[event].listeners.length; i < len; i++) {\n returnVal = events[event].listeners[i].apply(null, args);\n }\n }\n \n /* Override is false and the origin is from the global window; call the YouTube listener */\n returnVal = ytListeners[ytEvent].apply(uw, args);\n \n con.log(\"[Player Listener] Event \" + event + \" was called with\", args);\n }\n } else if (!enabled) {\n /* Everything is disabled; call the YouTube listener */\n returnVal = ytListeners[ytEvent].apply(uw, args);\n }\n return returnVal;\n }", "add_cm_listener(listener) {\n\n }", "subscribeRoom() {\n currentUser\n .subscribeToRoom({\n roomId: presenceRoomId,\n // action hooks. These functions will be executed when any of the four events below happens\n hooks: {\n onUserCameOnline: this.handleInUser,\n onUserJoinedRoom: this.handleInUser,\n onUserLeftRoom: this.handleOutUser,\n onUserWentOffline: this.handleOutUser\n }\n })\n }", "beforeConnectedCallbackHook(){\n\t\t\n\t}", "listen (pack, event, params) {\n const __callbacks = {};\n const __eventCallback = (event) => __callbacks[event] || function () {};\n\n const user_id = `${pack}.${event}_${this.project}:${this.key}`;\n request({\n uri: `${RapidAPI.callbackBaseURL()}/api/get_token?user_id=${user_id}`,\n method: 'GET',\n headers: {\n \"Content-Type\": \"application/json\"\n },\n auth: {\n 'user': this.project,\n 'pass': this.key,\n 'sendImmediately': true\n }\n }, (error, response, body) => {\n const { token } = JSON.parse(body);\n const sock_url = `${RapidAPI.websocketBaseURL()}/socket/websocket?token=${token}`;\n const socket = new Socket.Socket(sock_url, {\n params: {token}\n });\n socket.connect();\n const channel = socket.channel(`users_socket:${token}`, params);\n channel.join()\n .receive('ok', msg => { __eventCallback('join')(msg); })\n .receive('error', reason => { __eventCallback('error')(reason); })\n .receive('timeout', () => { __eventCallback('timeout'); });\n\n channel.on('new_msg', msg => {\n if (!msg.token) {\n __eventCallback('error')(msg.body);\n } else {\n __eventCallback('message')(msg.body);\n }\n });\n channel.onError(() => __eventCallback('error'));\n channel.onClose(() => __eventCallback('close'));\n });\n const r = {\n on: (event, func) => {\n if (typeof func !== 'function') throw \"Callback must be a function.\";\n if (typeof event !== 'string') throw \"Event must be a string.\";\n __callbacks[event] = func;\n return r;\n }\n };\n return r;\n }", "function twitchInit() {\n console.debug('twitchInit');\n play();\n twitchUpdateCall();\n twitchUpdateCallInterval =\n setInterval(twitchUpdateCall, twitchUpdateCallFrequency);\n}", "function onPublisherCredOffer() {\n if (!uuid) return;\n socket.emit(\"publisher-cred-offer-sub\", uuid);\n socket.on(\"publisher-cred-offer-done\", () => {\n socket.emit(\"publisher-cred-offer-unsub\", uuid);\n setPublisherCredentialOffer(false);\n mutate(`${PUBLICATION_PATH}/${id}`);\n });\n setPublisherCredentialOffer(true);\n }", "function addHanldeOnAuthenticated(rtm, handler) {\n rtm.on(\"authenticated\", handler);\n}", "function identify(request, response) {\n let { socket_id, channel_name } = request.body;\n\n var auth = pusher.authenticate(socket_id, channel_name, {\n // request.user.token comes from sonos-oauth.authenticated\n user_id: encrypt(request.user.token)\n });\n\n response.send(auth);\n\n // For the reconnect case, start subscribing to the related channel. If a\n // user is reconnecting, we need to subscribe again\n subscribe(channel_name, request.user.token);\n}", "onAuthentication(func) {\n this._onAuthCallbacks.push(func);\n }", "function onConnectedHandler(addr, port)\n{\n\tconsole.log('* Connected successfully to Twitch channel: '.concat(CHAT_CHANNEL));\n}", "function onConnectedHandler (addr, port) {\n\twriteToLog(`* Connected to Twitch: ${addr}:${port}`);\n}", "function onExistingParticipants(msg) {\r\n\tuserId = msg.userId;\r\n\tvar iceServers = [\r\n\t\t{\r\n\t\t\turl: 'turn:' + turnUrl,\r\n\t\t\tusername: turnUsername,\r\n\t\t\tcredential: turnCredential\r\n\t\t}\r\n\t];\r\n\tlet videoConstraints = null;\r\n\tif (msg.videoOn === true) {\r\n\t\tif (reduceFramerateKurento===\"true\"){\r\n\t\t\tvideoConstraints = {\r\n\t\t\t\tframeRate: {\r\n\t\t\t\t\tmin: 2, ideal: 15, max: 30\r\n\t\t\t\t},\r\n\t\t\t\twidth: {\r\n\t\t\t\t\tmin: 50, ideal: 250, max: 640\r\n\t\t\t\t},\r\n\t\t\t\theight: {\r\n\t\t\t\t\tmin: 32, ideal: 250, max: 640\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t} else {\r\n\t\tvideoConstraints = false;\r\n\t}\r\n\r\n\tvar constraints = {\r\n\r\n\r\n\t\taudio: msg.audioOn,\r\n\t\tvideo: videoConstraints,\r\n\t\tconfigurations: {\r\n\t\t\ticeServers: iceServers\r\n\t\t}\r\n\r\n\t};\r\n\tconsole.log(userId + \" registered in room \" + roomId);\r\n\tvar participant = new Participant(name, userId, selfStream);\r\n\tparticipants[userId] = participant;\r\n\r\n\tvar options = {\r\n\t\tlocalVideo: selfStream,\r\n\t\tmediaConstraints: constraints,\r\n\t\tonicecandidate: participant.onIceCandidate.bind(participant),\r\n\r\n\r\n\t}\r\n\t//user connects to KMS\r\n\tparticipant.rtcPeer = new kurentoUtils.WebRtcPeer.WebRtcPeerSendonly(options,\r\n\t\tfunction (error) {\r\n\t\t\tif (error) {\r\n\t\t\t\t/*return*/\r\n\t\t\t\tconsole.error(error);\r\n\t\t\t}\r\n\t\t\tthis.generateOffer(participant.offerToReceiveVideo.bind(participant));\r\n\t\t\t//if user decided to turn his media devices off before the call has started\r\n\t\t\tif (audioBeforeEnterTheRoom === false) {\r\n\t\t\t\tremoveMediaTrack('audio');\r\n\t\t\t}\r\n\t\t\tif (videoBeforeEnterTheRoom === false) {\r\n\t\t\t\tremoveMediaTrack('video');\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t//user registers other users in this chat room\r\n\tmsg.data.forEach(receiveVideo);\r\n}", "function userLoggedInListener (roomName, occupants, isPrimary) {\n //update the global occupants list for this user.\n all_occupants_list = occupants;\n\n //as this callback method is also called on any user disconnection...\n //remove any 'zombie' easyrtc id from 'all_occupants_details' variable\n removeZombieClientsFromOccupantsDetails(occupants);\n\n //update the online/offline status as per the new list.\n //this update is important for someone leaves the connection.\n updateOnlineStatusOfClients(all_occupants_details);\n\n //spawn telepointers for the logged in users.\n spawnTelepointers(occupants);\n\n //inform my email, name along with easyrtc id, which is later used for different tracking\n informMyDetailsToAllOtherClients(occupants);\n\n //notifyAll('disconnected', \"Hello\");\n\n\n //FOR VIDEO STRM\n clearConnectList();\n var otherClientDiv = document.getElementById(\"otherClients\");\n for(var easyrtcid in occupants) {\n var button = document.createElement(\"button\");\n button.onclick = function(easyrtcid) {\n return function() {\n performCall(easyrtcid);\n };\n }(easyrtcid);\n var label = document.createTextNode(\"Call \" + getNameForAnEasyRTCid( easyrtc.idToName(easyrtcid) ) );\n button.appendChild(label);\n otherClientDiv.appendChild(button);\n }\n\n\n\n\n\n}", "addMessageChannelEventListener() {\n\t\tself.addEventListener('message', event => {\n\t\t\tif (!this.clientId.isApproved() && event.ports[0]) {\n\t\t\t\t//console.log('@serviceworker !!!ready');\n\t\t\t\tthis.clientId.approved = this.clientId.recent;\n\t\t\t\t// save messageChannel\n\t\t\t\tthis.messageChannel = event.ports[0];\n\t\t\t\tthis.doIntercept.push(event.data); // location.origin\n\t\t\t\tthis.messageChannel.postMessage('!!!ready');\n\t\t\t} else if (event.data && Array.isArray(event.data[0])) {\n\t\t\t\t// execute resolving function\n\t\t\t\t//console.log('@serviceworker got response:', event.data);\n\t\t\t\tconst resolveFuncs = this.resolveMap.get(event.data[0][1]); // key\n\t\t\t\tif (resolveFuncs) {\n\t\t\t\t\tevent.data[1] && Array.isArray(event.data[1]) ? resolveFuncs[0](event.data[1]) : resolveFuncs[1]();\n\t\t\t\t\tthis.resolveMap.delete(event.data[0][1]);\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t}", "function subscribeAuthStateChanged() {\n return Object(redux_saga__WEBPACK_IMPORTED_MODULE_4__[\"eventChannel\"])(function (emmiter) {\n var unsubscribe = authorizeService.onAuthStateChanged(function (userClaim) {\n emmiter(userClaim || {\n noUser: true\n });\n });\n return function () {\n unsubscribe();\n };\n });\n}", "function setupListeners () {\n\t\tvar btn= document.getElementById('ws');\n\t\tbtn.addEventListener('click', yet.track, false);\n\t}", "function initUIListeners() {\n /*\n * Toggle userlist.\n */\n $(\"#plugbot-btn-userlist\").on(\"click\", function () {\n userList = !userList;\n $(this).css(\"color\", userList ? \"#3FFF00\" : \"#ED1C24\");\n $(\"#plugbot-userlist\").css(\"visibility\", userList ? (\"visible\") : (\"hidden\"));\n if (!userList) {\n $(\"#plugbot-userlist\").empty();\n } else {\n populateUserlist();\n }\n jaaulde.utils.cookies.set(COOKIE_USERLIST, userList);\n });\n\n /*\n * Toggle auto-woot.\n */\n $(\"#plugbot-btn-woot\").on(\"click\", function () {\n autowoot = !autowoot;\n $(this).css(\"color\", autowoot ? \"#3FFF00\" : \"#ED1C24\");\n if (autowoot) {\n $(\"#button-vote-positive\").click();\n }\n jaaulde.utils.cookies.set(COOKIE_WOOT, autowoot);\n });\n\n /*\n * Toggle hide video.\n */\n $(\"#plugbot-btn-hidevideo\").on(\"click\", function () {\n hideVideo = !hideVideo;\n $(this).css(\"color\", hideVideo ? \"#3FFF00\" : \"#ED1C24\");\n $(\"#yt-frame\").animate({\n \"height\": (hideVideo ? \"0px\" : \"271px\")\n }, {\n duration: \"fast\"\n });\n $(\"#playback .frame-background\").animate({\n \"opacity\": (hideVideo ? \"0\" : \"0.91\")\n }, {\n duration: \"medium\"\n });\n jaaulde.utils.cookies.set(COOKIE_HIDE_VIDEO, hideVideo);\n });\n\n /*\n * Toggle auto-queue/auto-DJ.\n */\n $(\"#plugbot-btn-queue\").on(\"click\", function () {\n autoqueue = !autoqueue;\n $(this).css(\"color\", autoqueue ? \"#3FFF00\" : \"#ED1C24\");\n if (autoqueue && !isInQueue()) {\n joinQueue();\n }\n jaaulde.utils.cookies.set(COOKIE_QUEUE, autoqueue);\n });\n}", "runAuthChangeHandler() {\n for (var i = 0; i < this.authObservers_.length; i++) {\n this.authObservers_[i](this['currentUser']);\n }\n }", "registerListeners() {}", "connectedCallback() {\n // Callback function to be passed in the subscribe call after an event is received.\n // This callback prints the event payload to the console.\n // A helper method displays the message in the console app.\n var self = this;\n const messageCallback = function(response) {\n self.onReceiveEvent(response);\n };\n // Subscribe to the channel and save the returned subscription object.\n subscribe(this.channelName, -1, messageCallback).then(response => {\n this.subscription = response;\n });\n }", "function authUser() {\n FB.Event.subscribe('auth.statusChange', handleStatusChange);\n}", "oninit () {\n // get the data from the background script\n port.postMessage('Hi BackGround');\n port.onMessage.addListener(function(msg) {\n Auth.token = msg.authToken;\n if (Auth.token) m.redraw();\n console.log('Auth.token', Auth.token);\n });\n }", "async function watchCalendarEvents(auth) {\n const calendar = google.calendar({ version: 'v3', auth });\n var channel = {\n id: uuidv4(),\n type: 'web_hook',\n address: `${HOST}/calendar_events` // triggers callback\n }\n\n const response = await calendar.events.watch({\n calendarId: 'primary',\n resource: channel,\n });\n\n console.log(response);\n\n channelId = response.data.id;\n channelResourceId = response.data.resourceId;\n}", "function onConnectionSuccess(){\n\t\t\tconsole.log(\"onConnectionSuccess getting my display Name ::: \" + _roomCredentials.name);\n\t\t\t\n\t\t _room = _connection.initJitsiConference(_roomCredentials.name, _roomConfOptions);\n\t\t \n\t\t _room.on(JitsiMeetJS.events.conference.TRACK_ADDED, onRemoteTrack);\n\t\t _room.on(JitsiMeetJS.events.conference.TRACK_REMOVED, function (track) {\n\t\t console.log(\"track removed!!!\" + track);\n\t\t });\n\t\t _room.on(JitsiMeetJS.events.conference.CONFERENCE_JOINED, onConferenceJoined);\n\t\t _room.on(JitsiMeetJS.events.conference.CONFERENCE_FAILED, onConferenceFailed);\n\t\t _room.on(JitsiMeetJS.events.conference.KICKED, onUserKicked);\n\t\t \n\t\t //room.on(JitsiMeetJS.events.conference.USER_JOINED, function(id){ console.log(\"user join\");remoteTracks[id] = [];});\n\t\t _room.on(JitsiMeetJS.events.conference.USER_JOINED, onUserJoined);\n\t\t \n\t\t _room.on(JitsiMeetJS.events.conference.USER_LEFT, onUserLeft);\n\n _room.addCommandListener(CONFERENCE_BROADCAST.MEETING_ENDED,function (values) {\n // onUserKicked();\n\t\t\t\t$rootScope.$broadcast(MEETING_CUSTOM_COMMANDS.CUSTOM_END,values.attributes)\n });\n\n // room.addCommandListener(MEETING_CUSTOM_COMMANDS.MEMBER_REMOVED,function (values) {\n //\n // });\n\n\t\t /* room.on(JitsiMeetJS.events.conference.USER_ROLE_CHANGED, function (id ,role){\n\t\t \t console.log(\"USER_ROLE_CHANGED :: \"+id + \" - \" + role);\n\t\t \t userRole = role;\n\t\t \t console.log(\"USER_ROLE_CHANGED :: userRole ==== \"+userRole);\n\t\t \t var userDisplayName =\"Name : \" + id + \", Role : \" + userRole + \", Id : \" + id;\n\t\t \t var userRemoveRoleName =\"Name : \" + id + \", Role : \" + participantString + \", Id : \" + id;\n\t\t \t \n\t\t \t var index = participentsList.indexOf(userRemoveRoleName);\n\t\t \t if (index > -1) {\n\t\t \t \tparticipentsList.splice(index, 1);\n\t\t \t }\n\t\t \t setParticipentsList(participentsList);\n\t\t \t participentsList.push(userDisplayName);\n\t\t \t if(id === localId){\n\t\t \t\t isModerator = true;\n\t\t \t\t console.log(\"I'm moderator, locking room with password\" + password);\n\t\t \t\t room.lock(password);\n\t\t \t }\n\t\t \t \n\t\t \t getUserList();\n\t\t });\n\t\t \n\t\t \n\t\t */\n\t\t JitsiMeetJS.mediaDevices.addEventListener(JitsiMeetJS.events.mediaDevices.PERMISSION_PROMPT_IS_SHOWN, function(environmentType ){\n\t\t \t//environmentTypes : 'chrome'|'opera'|'firefox'|'iexplorer'|'safari'|'nwjs'|'react-native'|'android'\n\t\t\t\t // alert(\"Enable browser permission to access audio devices for \" + environmentType +\"browser.\" );\n\t\t\t });\n\t\t \n\t\t console.info('Room Joined ');\n\t\t \n\t\t // var password = \"sagar\";\n\t\t _room.setDisplayName(_roomCredentials.displayName);\n\t\t \n\t\t if (! _connectorRole.MODERATOR) {\n\t\t\t console.log(\"not moderator\");\n\t\t\t _room.join(_roomCredentials.password);\n\t\t } else {\n\t\t \tconsole.log(\" moderator\");\n\t\t \t_room.join();\n\t\t \t_room.lock(_roomCredentials.password);\n\t\t }\n\t\t \n\t\t _room.addCommandListener(\"AddedNewParticipant\", function(values){\n\t\t\t console.log(\"========= New participant is added to the conference =============\");\n\t\t });\n\t\t \n\t\t JitsiMeetJS.createLocalTracks({devices: [\"audio\"]}, true).\n\t\t then(onLocalTracks).catch(function (error) {\n\t\t \t console.log(\"connect localtrack erroe=r ::;\");\n\t\t throw error;\n\t\t });\n\t\t \n\t\t _room.addCommandListener(MEETING_CUSTOM_COMMANDS.NEW_MEMBER_ADDED, function (values) {\n\t\t\t console.log(\"MEETING_CUSTOM_COMMANDS.NEW_MEMBER_ADDED ::: \"+angular.toJson(values));\n\t\t\t\t$rootScope.$broadcast(MEETING_CUSTOM_COMMANDS.NEW_MEMBER_ADDED, {userDetails : values,\n\t\t\t});\n\t\t });\n\t\t \n\t\t _room.addCommandListener(MEETING_CUSTOM_COMMANDS.MEMBER_REMOVED, function (values) {\n\t\t\t console.log(\"MEETING_CUSTOM_COMMANDS.MEMBER_REMOVED ::: \"+angular.toJson(values));\n\t\t\t\t$rootScope.$broadcast(MEETING_CUSTOM_COMMANDS.MEMBER_REMOVED, {userDetails : values,\n\t\t\t});\n\t\t });\n\t\t \n\t\t _room.addCommandListener(MEETING_CUSTOM_COMMANDS.MEETING_EXTENDED, function (values) {\n\t\t\t console.log(\"MEETING_CUSTOM_COMMANDS.MEETING_EXTENDED ::: \"+angular.toJson(values));\n\t\t\t\t$rootScope.$broadcast(MEETING_CUSTOM_COMMANDS.MEETING_EXTENDED, values.attributes);\n\t\t });\n\t\t \n\t\t \n\t\t \n\t\t}", "ListenToChannel(oldMember, newMember) {\n let newUserChannel = newMember.channel;\n let oldUserChannel = oldMember.channel;\n this.audioPlayer.client = this.client;\n\n //don't process the channel if the user who joined is Joinify or if there's already an audio thread being processed\n if (newMember.member.displayName == 'Joinify' || this.isAudioReady == false) {\n return;\n }\n\n //don't process the channel if the user is only muting or unmuting\n //don't process the channel if the user is only deafening or undeafening\n //don't process the channel if the user is only streaming or unstreaming\n if (newMember != null && oldMember != null && (\n newMember.mute != oldMember.mute ||\n newMember.deaf != oldMember.deaf ||\n newMember.streaming != oldMember.streaming))\n return;\n\n //don't process the channel if there's already audio being played\n if (this.audioPlayer.isAudioReady == false)\n return;\n\n if (\n (oldUserChannel === null && newUserChannel !== null && newUserChannel.id == this.channelId) ||\n (oldUserChannel !== null && newUserChannel !== null && oldUserChannel.id != newUserChannel.id && newUserChannel.id == this.channelId)\n ) {\n //a user has joined the watching channel\n //this.message.channel.send('User has joined ' + newUserChannel.name);\n var msg = this.dateService.GetCurrentDateTime() + \n ' - User ' + newMember.member.displayName + ' has joined ' + newUserChannel.name;\n console.info(msg);\n this.audioPlayer.PlayYoutube(this.joinLink);\n }\n else if (\n (oldUserChannel !== null && newUserChannel === null && oldUserChannel.id == this.channelId) || //user has left the channel\n (oldUserChannel !== null && newUserChannel !== null && newUserChannel.id != this.channelId) //user has swapped channels\n ) {\n //a user has left a voice channel \n //this.message.channel.send(\"User has left \" + oldUserChannel.name);\n var msg = this.dateService.GetCurrentDateTime() +\n \" - User \" + oldMember.member.displayName + \" has left \" + oldUserChannel.name;\n console.info(msg);\n this.audioPlayer.PlayYoutube(this.leaveLink);\n }\n }", "function peerListener( caller_rtc_id, data )\n{\n\t// trace(\"peerListener( \" + caller_rtc_id + \" ) : \" );\n\tdata = JSON.parse( data );\n\ttrace_object( data );\n\t\n\tif ( data.action == 'chat' ) {\n\t\tvideo_chat_message_recv( caller_rtc_id, data );\n\t}\n\telse if ( data.action == 'whiteboard' ) {\n\t\twhiteboard_canvas_draw_from_server( data );\n\t}\n\telse if ( data.action == 'command' ) {\n\t\tvideo_chat_command( caller_rtc_id, data );\n\t}\n}", "async function activate(context) {\n const twitcherConfig = workspace.getConfiguration('twitcher')\n\n if (!twitcherConfig.enabled) return\n //#region config\n const twitchConfig = await startupConfig()\n\n if (!twitchConfig.oauth) {\n const askForOAuth = await window.showErrorMessage(\n 'Please Enter a Oauth token for twitch',\n { title: 'Enter Oauth' }\n )\n\n if (askForOAuth) {\n const twitchOAuth = await inputCommands.twitchChatOAuth()\n if (twitchOAuth) {\n localConfig.set(TWITCH_CHAT_OAUTH, twitchOAuth)\n twitchConfig.oauth = twitchOAuth\n }\n }\n }\n\n const twitchChatConfig = {\n options: {\n debug: twitcherConfig.debug\n },\n connection: {\n reconnect: true\n },\n identity: {\n username: twitcherConfig.username,\n password: twitchConfig.oauth\n },\n channels: [`#${twitcherConfig.channel}`]\n }\n //#endregion\n\n /**\n * Initalize\n */\n const bot = new Tmi.client(twitchChatConfig)\n const twitchStatusBar = new TwitchStatusBar(twitcherConfig)\n const twitchApi = new TwitchApi(twitchConfig.clientID)\n\n let soundFile = false\n if (typeof twitcherConfig.notificationSound !== 'boolean') {\n soundFile = resolve(twitcherConfig.notificationSound)\n } else if (twitcherConfig.notificationSound) {\n soundFile = resolve(\n __dirname,\n '..',\n 'resources',\n 'audio',\n 'new_message.wav'\n )\n }\n const notification = new Notification(soundFile)\n bot.connect()\n\n /**\n * Register Data provider\n */\n const twitcherExplorerProvider = new TwticherExplorerProvider()\n window.registerTreeDataProvider('twitcher', twitcherExplorerProvider)\n if (twitcherConfig.counterUpdateInterval) {\n viewerCountUpdater = setInterval(() => {},\n ms(twitcherConfig.counterUpdateInterval))\n }\n\n //#region Register Commands\n const clearConfig = commands.registerCommand('twitcher.clearConfig', () => {\n localConfig.clear()\n })\n context.subscriptions.push(clearConfig)\n\n const switchToChatCommand = commands.registerCommand(\n 'twitcher.switchToChat',\n () => {\n twitcherExplorerProvider.enableChat()\n }\n )\n context.subscriptions.push(switchToChatCommand)\n const oAuthCommand = commands.registerCommand(\n 'twitcher.setOAuth',\n async () => {\n const oAuthToken = await inputCommands.twitchChatOAuth()\n if (oAuthToken) {\n localConfig.set(TWITCH_CHAT_OAUTH, oAuthToken)\n window.showInformationMessage('Twitch OAuth updated')\n }\n }\n )\n context.subscriptions.push(oAuthCommand)\n const clientIDCommand = commands.registerCommand(\n 'twitcher.setClientID',\n async () => {\n const twitchClientID = await inputCommands.twitchClientID()\n if (twitchClientID) {\n localConfig.set(TWITCH_CLIENT_ID, twitchClientID)\n window.showInformationMessage('Twitch Client-ID updated')\n }\n }\n )\n context.subscriptions.push(clientIDCommand)\n\n const explorerReplyCommand = commands.registerCommand(\n 'twitcher.explorerReply',\n async context => {\n const userName = `@${context.label.split(':')[0]}`\n const reply = await window.showInputBox({\n prompt: userName\n })\n\n if (!reply) return\n bot.say(twitcherConfig.channel, `${userName} ${reply}`)\n }\n )\n context.subscriptions.push(explorerReplyCommand)\n\n if (twitchConfig.clientID) {\n const refreshCommand = commands.registerCommand(\n 'twitcher.refreshViewerCount',\n async () => {\n const viewerCount = await twitchApi.getViewerCount()\n twitchStatusBar.setNewCounter(viewerCount)\n }\n )\n context.subscriptions.push(refreshCommand)\n }\n\n const switchToUserListCommand = commands.registerCommand(\n 'twitcher.switchToUserList',\n async () => {\n twitcherExplorerProvider.showLoading('Loading User list')\n const userlist = await twitchApi.getViewerList()\n twitcherExplorerProvider.hideLoading()\n twitcherExplorerProvider.loadUserList(userlist)\n twitchStatusBar.setNewCounter(userlist.length)\n }\n )\n context.subscriptions.push(switchToUserListCommand)\n const sendCommand = commands.registerCommand(\n 'twitcher.sendMessage',\n async () => {\n try {\n const message = await window.showInputBox({\n placeHolder: 'Message to send'\n })\n\n if (message) {\n bot.say(twitcherConfig.channel, message)\n }\n } catch (error) {\n console.error('Failed to send Message', error)\n window.showErrorMessage('Failed to Send Message')\n }\n }\n )\n\n context.subscriptions.push(sendCommand)\n //#endregion\n bot.on('connected', () => {\n commands.executeCommand('twitcher.refreshViewerCount')\n window.showInformationMessage(`Connected to: ${twitcherConfig.channel}`)\n })\n\n bot.on('message', async (channel, userstate, message, self) => {\n //Todo: Add Filter\n switch (userstate['message-type']) {\n case 'chat':\n twitcherExplorerProvider.addChatItem(userstate.username, message)\n\n if (!self) {\n const replyText = await notification.showNotifcation(\n userstate.username,\n message\n )\n if (!replyText) return\n bot.say(\n twitcherConfig.channel,\n `@${userstate.username}: ${replyText}`\n )\n }\n break\n }\n })\n}", "function on_auth_success(socket, accept) {\n console.log(\"Auth success\");\n /**\n * Accepts the connection\n * A message may be sent to client via accept\n */\n accept();\n }", "function formatCanOnlyListenForYouResponse(config, listener) {\n return Q.fcall(function() {\n if (_.isEqual(listener, 'my-team-channel')) {\n return \"You can't subscribe \" + listener + \" because you aren't the team captain.\" +\n \" As a non-captain you can only subscribe yourself. Use 'me' as \" + \n \" listener.\";\n } else {\n return \"You can't subscribe \" + listener + \" because you aren't a moderator.\" +\n \" As a non-moderator you can only subscribe yourself. Use 'me' as \" + \n \" listener.\";\n }\n });\n}", "function onExistingParticipants(message) {\n // Standard constraints\n var constraints = {\n audio: true,\n video: {\n frameRate: {\n min: 1, ideal: 15, max: 30\n },\n width: {\n min: 32, ideal: 50, max: 320\n },\n height: {\n min: 32, ideal: 50, max: 320\n }\n }\n };\n\n // Temasys constraints\n /*var constraints = {\n audio: true,\n video: {\n mandatory: {\n minWidth: 32,\n maxWidth: 320,\n minHeight: 32,\n maxHeight: 320,\n maxFrameRate: 30,\n minFrameRate: 1\n }\n }\n };*/\n\n console.log(sessionId + \" register in room \" + message.roomName);\n\n // create video for current user to send to server\n var localParticipant = new Participant(sessionId);\n participants[sessionId] = localParticipant;\n localVideo = document.getElementById(\"local_video\");\n var video = localVideo;\n\n // bind function so that calling 'this' in that function will receive the current instance\n var options = {\n localVideo: video,\n mediaConstraints: constraints,\n onicecandidate: localParticipant.onIceCandidate.bind(localParticipant)\n };\n\n\n localParticipant.rtcPeer = new kurentoUtils.WebRtcPeer.WebRtcPeerSendonly(options, function (error) {\n if (error) {\n return console.error(error);\n }\n\n // Set localVideo to new object if on IE/Safari\n localVideo = document.getElementById(\"local_video\");\n\n // initial main video to local first\n localVideoCurrentId = sessionId;\n localVideo.src = localParticipant.rtcPeer.localVideo.src;\n localVideo.muted = true;\n\n console.log(\"local participant id : \" + sessionId);\n this.generateOffer(localParticipant.offerToReceiveVideo.bind(localParticipant));\n });\n\n // get access to video from all the participants\n console.log(message.data);\n for (var i in message.data) {\n receiveVideoFrom(message.data[i]);\n }\n}", "addChatListeners () {\n this.webSocket.onopen = () => console.log('open channel')\n this.webSocket.addEventListener('open', this.handleSocketConnection)\n this.webSocket.onmessage = (e) => this.handleMessage(JSON.parse(e.data))\n this.form.addEventListener('submit', this.handleSubmit)\n this.emojiIcon.addEventListener('click', this.toggleEmojis)\n }", "function socketInit() {\r\n\tsocket = io();\r\n\r\n\tsocket.on('message', parsedMessage => {\r\n\t\tconsole.info('Received message: ' + parsedMessage.id);\r\n\r\n\t\tswitch (parsedMessage.id) {\r\n\t\t\t//event for self user, when he leaves the room\r\n\t\t\tcase 'disconn':\r\n\t\t\t\tparticipants[userId].disposeSelf();\r\n\t\t\t\tsocket.close();\r\n\t\t\t\tbreak;\r\n\t\t\t// event for new user to connect to KMS and register other users in room\r\n\t\t\tcase 'existingParticipants':\r\n\t\t\t\tonExistingParticipants(parsedMessage);\r\n\t\t\t\tbreak;\r\n\t\t\t// event for other users to register new participant\r\n\t\t\tcase 'newParticipantArrived':\r\n\t\t\t\tonNewParticipant(parsedMessage);\r\n\t\t\t\tbreak;\r\n\t\t\t// event for other users to register the leaving of user\r\n\t\t\tcase 'participantLeft':\r\n\t\t\t\tonParticipantLeft(parsedMessage);\r\n\t\t\t\tbreak;\r\n\t\t\t// event to register answers : user-KMS and user-user\r\n\t\t\tcase 'receiveVideoAnswer':\r\n\t\t\t\treceiveVideoResponse(parsedMessage);\r\n\t\t\t\tbreak;\r\n\t\t\t// event for exchanging ICE candidates between WebRTC peers\r\n\t\t\tcase 'iceCandidate':\r\n\t\t\t\tparticipants[parsedMessage.userId].rtcPeer.addIceCandidate(parsedMessage.candidate, function (error) {\r\n\t\t\t\t\tif (error) {\r\n\t\t\t\t\t\tconsole.error(\"Error adding candidate: \" + error);\r\n\t\t\t\t\t\treturn;\r\n\t\t\t\t\t}\r\n\t\t\t\t});\r\n\t\t\t\tbreak;\r\n\t\t\tcase'chat message':\r\n\t\t\t\treceiveChatMessage(parsedMessage);\r\n\t\t\t\tbreak;\r\n\r\n\t\t\t// event for new user to receive a response of moderator\r\n\t\t\tcase 'moderatorResponse':\r\n\t\t\t\tmoderatorResponse(parsedMessage.accepted, socket);\r\n\t\t\t\tbreak;\r\n\t\t\tcase 'videoDisabled':\r\n\t\t\t\tputNameOverVideo(document.getElementById(parsedMessage.userId));\r\n\t\t\t\tbreak;\r\n\t\t\tcase 'videoEnabled':\r\n\t\t\t\tputVideoOverName(document.getElementById(parsedMessage.userId));\r\n\t\t\t\tbreak;\r\n\r\n\t\t}\r\n\t});\r\n\t// event fired when moderator enters the room or if the moderator is not available\r\n\tsocket.on('onEnterNotification', error => {\r\n\t\tif (error === null) {\r\n\t\t\tenter('moderator');\r\n\t\t} else {\r\n\t\t\talert(error);\r\n\t\t}\r\n\t});\r\n\t// event for requesting permission from the moderator to log in a new user\r\n\tsocket.on('requestForModerator', (socketId, fullName) => {\r\n\t\tlet data = {\r\n\t\t\tid: 'moderatorResponse',\r\n\t\t\tuserId: socketId,\r\n\t\t\taccepted: false\r\n\t\t}\r\n\r\n\t\taddModal(fullName, (modalId) => {\r\n\t\t\tdata.accepted = true;\r\n\t\t\tdocument.getElementById(modalId).remove();\r\n\t\t\tsendMessage(data);\r\n\t\t}, (modalId) => {\r\n\t\t\tdocument.getElementById(modalId).remove();\r\n\t\t\tsendMessage(data);\r\n\t\t});\r\n\r\n\t});\r\n\tsocket.on('waitModeratorResponse', () => {\r\n\t\talert('Please wait until moderator accepts your entry');\r\n\t});\r\n}", "getPeerConnection(connectionWith){\n \n if (typeof self.peerConnections[connectionWith] !== 'undefined') {\n return self.peerConnections[connectionWith];\n }\n \n var peerConnection = new RTCPeerConnection(self.iceConfig);\n self.peerConnections[connectionWith] = peerConnection;\n peerConnection.onicecandidate = function(ice_event){\n if (ice_event.candidate) {\n var message = {\n type: 'new_ice_candidate',\n from: YAWB.user.uid,\n to: connectionWith,\n candidate: ice_event.candidate\n }\n self.sendMessage(message);\n }\n };\n \n if(!YAWB.user.owner){\n peerConnection.onaddstream = function(event){\n //console.log('adding remote stream of the owner');\n self.videoPlayer.src = window.URL.createObjectURL(event.stream);\n self.videoPlayer.play();\n };\n }else{\n peerConnection.addStream(self.stream);\n }\n \n return peerConnection; \n }", "function setEventListener() {\n\taddEventListener(\"message\", function(event) {\n\t\tif (event.origin + \"/\" == chrome.extension.getURL(\"\")) {\n\t\t\tconsole.log(event);\n\t\t\tvar eventToolName = event.data.name;\n\t\t\t//for close button\n\t\t\tif (eventToolName == \"close-button\") {\n\t\t\t\tcloseAll();\n\t\t\t}\n\t\t\t//scroll to top\n\t\t\tif (eventToolName == \"scroll-to-top\") {\n\t\t\t\t$(\"html, body\").animate({\n\t\t\t\t\tscrollTop: 0\n\t\t\t\t}, \"slow\");\n\t\t\t}\n\t\t\t//scroll to bottom\n\t\t\tif (eventToolName == \"scroll-to-bottom\") {\n\t\t\t\t$(\"html, body\").animate({\n\t\t\t\t\tscrollTop: $(document).height()\n\t\t\t\t}, \"slow\");\n\t\t\t}\n\t\t\t//to decrease size of frame\n\t\t\tif (eventToolName == \"resize-button\") {\n\t\t\t\tresizeFrame();\n\t\t\t}\n\t\t\t//to increase size of frame\n\t\t\tif (eventToolName == \"maximize-button\") {\n\t\t\t\tmaximizeFrame();\n\t\t\t}\n\t\t\t//for inviting friends to like a page\n\t\t\tif (eventToolName == \"inviteFriendsToGroup\") {\n\t\t\t\tvar id = event.data.id;\n\t\t\t\tvar delay = event.data.delay;\n\t\t\t\tinviteNow(id,delay);\n\t\t\t}\n\t\t\t//for restarting tool\n\t\t\tif(eventToolName==\"restartTool\"){\n\t\t\t\trestartTool();\n\t\t\t}\n\t\t}\n\t}, false);\n}", "function registerPeerConnectionListeners() {\n peerConnection.addEventListener('icegatheringstatechange', () => {\n console.log(\n `ICE gathering state changed: ${peerConnection.iceGatheringState}`);\n });\n\n peerConnection.addEventListener('connectionstatechange', () => {\n console.log(`Connection state change: ${peerConnection.connectionState}`);\n if (peerConnection.connectionState === 'disconnected') {\n document.querySelector('#remoteVideo').srcObject = null;\n }\n });\n\n peerConnection.addEventListener('signalingstatechange', () => {\n console.log(`Signaling state change: ${peerConnection.signalingState}`);\n });\n\n peerConnection.addEventListener('iceconnectionstatechange ', () => {\n console.log(\n `ICE connection state change: ${peerConnection.iceConnectionState}`);\n });\n}", "function listener(event) {\n if (event.data && event.data.sessionId) {\n if (event.origin !== window.location.origin) {\n console.warn(\n \"Ignoring sessionId from different origin: \" + event.origin);\n return;\n }\n localStorage.setItem('sessionId', event.data.sessionId);\n // After popup is closed we will authenticate\n }\n }", "async onUpgrade(request, socket, head) {\n const { websocketAuth, websocketAuthTimeoutMs } = this.config;\n\n // Create client ID and pendingRequest.\n const clientId = makeId();\n const pendingRequest = (this._pendingAuthRequests[clientId] = {\n clientId,\n request,\n socket,\n head\n });\n\n // Toothless mode for WebSockets.\n if (!websocketAuth) {\n log.debug(`WebSocket for client ${clientId} authorized.`);\n return this.authorizeWebsocket(clientId);\n }\n\n // WebSocket authentication enabled.\n\n // Create ws_auth_request\n try {\n const wsAuthRequest = (pendingRequest.wsAuthRequest = makeWsAuthRequest(\n request,\n clientId\n ));\n log.debug(\n `Authenticating WebSocket client ${clientId} from ${\n wsAuthRequest.remoteIp\n }`\n );\n } catch (wsAuthError) {\n log.warn(`Cannot authenticate WebSocket client: ${wsAuthError}`);\n return this.rejectWebsocket(clientId, wsAuthError);\n }\n\n // Set authorization timeout handler.\n const startTimeMs = Date.now();\n pendingRequest.timeout = setTimeout(() => {\n const error = new Error(`WebSocket authentication timed out.`);\n error.code = 503;\n const deltaMs = Date.now() - startTimeMs;\n log.warn(`Socket auth check timed out after ${deltaMs} ms: ${error}`);\n this.rejectWebsocket(clientId, error);\n }, Math.max(MIN_WS_AUTH_TIMEOUT_MS, websocketAuthTimeoutMs));\n\n // Decouple response handling by emitting an event.\n log.debug(\"Emitting ws_auth_request\");\n this.emit(\"ws_auth_request\", pendingRequest.wsAuthRequest);\n }", "async function openCallback() {\n\n // Unsubscribe from any existing ComputerVision \n // WebSocket connections.\n socket.Unsubscribe(\"ComputerVision\");\n\n // Use sleep() to pause execution for \n // three seconds to give Misty time \n // to register and execute the command.\n await sleep(3000);\n\n // Issue a GET request to the endpoint \n // for the GetLearnedFaces command. \n // Use then() to pass the response \n // to a callback function.\n axios.get(\"http://\" + ip + \"/api/beta/faces\").then(function (res) {\n // Store the list of known faces in the\n // faceArr variable and print this list.\n let faceArr = res.data[0].result;\n console.log(\"Learned faces:\", faceArr);\n\n // Loop through each item in faceArr. \n // Compare each item to the value stored \n // in the you variable.\n for (let i = 0; i < faceArr.length; i++) {\n // If a match is found, update \n // the value of onList to true.\n if (faceArr[i] === you) {\n onList = true;\n }\n }\n\n // Subscribe to the ComputerVision WebSocket. \n // Pass ComputerVision for the eventName and \n // msgType parameters. Set debounceMs to 200 \n // and pass a callback function named _ComputerVision \n // for the callback parameter. Pass null for \n // all other arguments.\n socket.Subscribe(\"ComputerVision\", \"ComputerVision\", 200, null, null, null, null, _ComputerVision);\n\n // Use an if, else statement to execute \n // startFaceRecognition() if onList is true \n // and to execute startFaceTraining if otherwise.\n if (onList) {\n console.log(\"You were found on the list!\");\n startFaceRecognition();\n } else {\n console.log(\"You're not on the list...\");\n startFaceTraining();\n }\n });\n}", "function onAPILoadReady() {\n console.log('ready: Auth: ', IPCortex.PBX.Auth);\n //IPCortex.PBX.Auth.setHost('https://37.122.196.252');\n IPCortex.PBX.Auth.setHost('https://call.webrtc.nu');\n}", "function handleCandidate(candidate) { \n yourConn.addIceCandidate(new RTCIceCandidate(candidate)); \n}", "listenSign(callback) {\n if (this.gapi) {\n this.gapi.auth2.getAuthInstance().isSignedIn.listen(callback);\n }\n else {\n setTimeout(() => { this.listenSign(callback) }, 300);\n console.log(\"listenSign: this.gapi not loaded. Loading again...\");\n }\n }", "onAuth(handler) {\n this.authHandlers.push(handler);\n }", "async googleAuth() {\n /**\n * Compose random name for auth-channel. We will get JWT from this.\n * @type {Promise<string>}\n */\n let channel = await utils.uniqId();\n\n return new Promise((resolve, reject) => {\n /**\n * Turns true after successful auth\n * @type {boolean}\n */\n let authSucceeded = false;\n\n /**\n * Open new window with Google Authorisation\n * @type {Electron.BrowserWindow}\n */\n let authWindow = new BrowserWindow({\n alwaysOnTop: true,\n autoHideMenuBar: true,\n webPreferences: {\n nodeIntegration: false\n }\n });\n\n /**\n * User can close auth-window\n */\n authWindow.on('closed', () => {\n if (authSucceeded) {\n resolve(global.user);\n } else {\n reject();\n }\n global.app.sockets.leaveChannel(channel);\n });\n\n /**\n * Start to load Google Auth form\n */\n authWindow.loadURL('https://accounts.google.com/o/oauth2/v2/auth?' +\n 'client_id=' + process.env.GOOGLE_CLIENT_ID +\n '&scope=email profile' +\n '&response_type=code' +\n '&redirect_uri=' + process.env.GOOGLE_REDIRECT_URI +\n '&state=' + channel, // state parameter will be passed to the redirect_uri\n {\n userAgent: 'Chrome' // bypass Google check of outdated browser\n }\n );\n\n /**\n * In case of server errors, close auth window\n */\n authWindow.webContents.on('did-get-response-details', (event, status, newURL, originalURL, httpResponseCode) => {\n if (httpResponseCode !== 200) {\n global.logger.debug(`-------------------------------\\nAuthorisation failed: code ${httpResponseCode} \\n-------------------------------`);\n\n // if (!process.env.DEBUG) {\n // authWindow.close();\n // }\n }\n });\n\n /**\n * Start to listen auth-channel. API will send JWT to this after User's authorisation\n *\n */\n global.app.sockets.listenChannel(channel,\n /**\n * User data got from the Cloud\n *\n * @param {object} socketMessage\n * @param {object} socketMessage.message\n * @param {string} socketMessage.message.jwt - JWT for authentication\n * @param {string} socketMessage.message.photo\n * @param {string} socketMessage.message.name\n * @param {number} socketMessage.message.dtModify\n * @param {string} socketMessage.message.channel - personal user's channel\n */\n async socketMessage => {\n let authData = socketMessage.message;\n\n let jwt = authData.jwt;\n\n /** Decode JWT payload */\n let payload = new Buffer(jwt.split('.')[1], 'base64');\n\n /** Try to parse payload as JSON. If this step fails, it means that auth failed at all */\n payload = JSON.parse(payload);\n\n await global.user.update({\n 'id': payload.user_id,\n 'name': authData.name,\n 'photo': authData.photo,\n 'googleId': payload.googleId,\n 'email': payload.email,\n 'token': jwt,\n 'dtModify': authData.dtModify,\n 'channel': authData.channel\n });\n\n /**\n * Refresh API client with the new token at the authorisation header;\n */\n global.app.cloudSyncObserver.refreshClient();\n global.user.saveAvatar();\n\n authSucceeded = true;\n authWindow.close();\n }\n );\n });\n }", "function handleCandidate(candidate)\n{\n yourConn.addIceCandidate(new RTCIceCandidate(candidate));\n}", "function handleOnAuthenticated(rtmStartData) {\n console.log(`I am the ${rtmStartData.self.name} bot and part of the team\n ${rtmStartData.team.name} but not yet part of channel`);\n}", "listen(){\n this.namespace.on('connection', (socket)=>{\n socket.on('teacher start poll', (teacherSocketId, poll) => {\n this.handleStartPoll(teacherSocketId, poll);\n });\n socket.on('student submit poll', (answersInfo, userId, sessionId)=>{\n this.handleStudentSubmitPoll(answersInfo, userId, sessionId);\n })\n });\n }", "function fireYouTubeReadyListeners() {\n var listeners = __youTubeReadyListeners;\n for ( var i=0; i<listeners.length; ++i ) {\n listeners[ i ]();\n } //for\n if ( __oldYouTubeReadyListener ) {\n __oldYouTubeReadyListener();\n } //if\n } //fireYouTubeReadyListeners", "function initClient() {\n gapi.client\n .init({\n apiKey: API_KEY,\n clientId: CLIENT_ID,\n scope: \"https://www.googleapis.com/auth/youtube.readonly\",\n discoveryDocs: [\"https://www.googleapis.com/discovery/v1/apis/youtube/v3/rest\"],\n })\n .then(() => {\n authBtn.addEventListener(\"click\", handleAuth);\n userAvatar.addEventListener(\"click\", handleSignout);\n // console.log(gapi.auth2);\n updateStatusAuth(gapi.auth2.getAuthInstance());\n })\n .then(loadScreen)\n .catch((error) => {\n authBtn.removeEventListener(\"click\", handleAuth);\n userAvatar.removeEventListener(\"click\", handleSignout);\n console.log(\"error = \" + error.details);\n console.dir(error);\n alert(\"Авторизация не удалась.\");\n });\n}", "OnAuthenticated(string, string) {\n\n }", "function onLoadCB() { \n checkAuth(true); \n }", "function startClientListener() {\n socketIO.on(\"connection\",(socket)=>{\n console.log(\"New connection. Waiting for device authentication...\");\n\n socket.on(\"device\",(data)=>{\n let type = data.type;\n console.log(\"Device authenticated as \"+type);\n\n switch(type) {\n case \"python\": pythonModule = socket; initializePythonModule(); break;\n case \"esp\": espModules.push(socket); break;\n default: console.log(\"Unknown device type...\");\n }\n });\n });\n}", "function startLiveChatMonitoring(webContents,ipcMain) {\n emitter = webContents;\n ipc = ipcMain;\n fs.readFile('client_secret.json', function processClientSecrets(err, content) {\n if (err) {\n console.log('Error loading client secret file: ' + err);\n return;\n }\n // Authorize a client with the loaded credentials, then call the YouTube API.\n authorize(JSON.parse(content), getChannel);\n });\n}", "connectedCallback() {\n super.connectedCallback();\n window.addEventListener('sherby-metadata', this.__metadataEventListener);\n }", "function authenticate() {\n socket.emit(\"authenticate\", {auth: auth_key, player_id: user_id, username: username});\n socket.emit(\"game/connect\", {game_id: game_id, player_id: user_id, chat: false});\n}", "onReady(socket, lobbyId, playerName) {\r\n // Controls used for the lobby chatting\r\n const chatContainer = document.getElementById(\"lobby-chat-container\");\r\n const chatInput = document.getElementById(\"lobby-chat-input\");\r\n const postButton = document.getElementById(\"lobby-chat-submit\");\r\n\r\n // Elements used to display users in lobby and\r\n // the participant list\r\n const userList = document.getElementById(\"user-list\");\r\n const participantListContainer = document.getElementById(\"lobby-participant-list\");\r\n\r\n // Controls to control starting and advancing the Lip Sync performance\r\n const startPerformanceButton = document.getElementById(\"start-performance-button\");\r\n const nextPerformerButton = document.getElementById(\"next-performer-button\");\r\n const nowPerformingDisplay = document.getElementById(\"now-performing-display\");\r\n\r\n // Hidden input for the lobby id in the register team form\r\n let lobbyIdInput = document.getElementById(\"hidden-lobby-id\");\r\n lobbyIdInput.value = lobbyId;\r\n\r\n let lobbyChannel = socket.channel(`lobby:${lobbyId}`, () => {\r\n return playerName \r\n ? {username: playerName}\r\n : {username: \"anon\" + Math.floor(Math.random() * 1000)};\r\n });\r\n\r\n let presence = new Presence(lobbyChannel);\r\n\r\n presence.onSync(() => {\r\n userList.innerHTML = presence.list((id, metas) => {\r\n return `<li>${this.esc(id)}</li>`;\r\n }).join(\"\");\r\n });\r\n \r\n // Send chat message to the server.\r\n postButton.addEventListener(\"click\", e => {\r\n let payload = {message: chatInput.value};\r\n lobbyChannel.push(\"new_msg\", payload)\r\n .receive(\"error\", e => e.console.log(e));\r\n chatInput.value = \"\";\r\n });\r\n\r\n // Test to send a new video ID for the player and update it\r\n lobbyChannel.on(\"update_video\", (resp) => {\r\n if (Player.player != null) {\r\n Player.player.loadVideoById(resp.new_id);\r\n nowPerformingDisplay.value = resp.team_name;\r\n }\r\n });\r\n\r\n // Start the Lip Sync performance\r\n startPerformanceButton.addEventListener(\"click\", e => {\r\n lobbyChannel.push(\"start_performance\", {})\r\n .receive(\"error\", e => e.console.log(e));\r\n\r\n startPerformanceButton.setAttribute(\"disabled\", \"disabled\");\r\n });\r\n\r\n // Advance the Lip Sync queue to the next performing team\r\n nextPerformerButton.addEventListener(\"click\", e => {\r\n lobbyChannel.push(\"next_performer\", {})\r\n .receive(\"error\", e => e.console.log(e));\r\n });\r\n\r\n // Receive and render a new chat message.\r\n lobbyChannel.on(\"new_msg\", (resp) => {\r\n this.renderAnnotation(chatContainer, resp);\r\n });\r\n\r\n // Receive updated list of Lip Sync participants\r\n lobbyChannel.on(\"participant_list\", (resp) => {\r\n this.renderParticipantList(participantListContainer, resp);\r\n });\r\n\r\n // Receive update that the performance ended\r\n lobbyChannel.on(\"performance_end\", (resp) => {\r\n startPerformanceButton.removeAttribute(\"disabled\");\r\n });\r\n\r\n // Join the lobby chat channel.\r\n lobbyChannel.join()\r\n .receive(\"ok\", () => {\r\n return;\r\n })\r\n .receive(\"error\", reason => console.log(\"join failed\", reason));\r\n }", "onAuth(client, options, request) {\n return true;\n }", "function handleCandidate(candidate) { \n yourConn.addIceCandidate(new RTCIceCandidate(candidate));\n }", "addAuthStateListener(callback) {\n\t\t// add to jwt token listener\n\t\tthis.qdacityTokenAuthenticationProvider.addAuthStateListener(callback);\n\n\t\tthis.googleAuthenticationProvider.addAuthStateListener(callback);\n\t\tthis.twitterAuthenticationProvider.addAuthStateListener(callback);\n\t\tthis.facebookAuthenticationProvider.addAuthStateListener(callback);\n\t}", "delegateAuthToViewer_() {\n const platformKeys = ['local'];\n const origin = getWinOrigin(this.ampdoc_.win);\n this.initializePlatformStore_(platformKeys);\n\n /** @type {!Array} */ (this.platformConfig_['services']).forEach(\n (service) => {\n if ((service['serviceId'] || 'local') == 'local') {\n const viewerPlatform = new ViewerSubscriptionPlatform(\n this.ampdoc_,\n service,\n this.serviceAdapter_,\n origin\n );\n this.platformStore_.resolvePlatform('local', viewerPlatform);\n this.getEntitlements_(viewerPlatform)\n .then((entitlement) => {\n devAssert(entitlement, 'Entitlement is null');\n // Viewer authorization is redirected to use local platform instead.\n this.resolveEntitlementsToStore_(\n 'local',\n /** @type {!./entitlement.Entitlement}*/ (entitlement)\n );\n })\n .catch((reason) => {\n this.platformStore_.reportPlatformFailureAndFallback('local');\n dev().error(TAG, 'Viewer auth failed:', reason);\n });\n }\n }\n );\n }", "function onIceCandidate(event) {\n if (event.candidate) {\n messaggio_da_inviare(event.candidate);\n } \n}", "connectedCallback() {\n this.subscribeToMessageChannel();\n }", "function onConnect() {\n // Once a connection has been made, make a subscription and send a message.\n console.log(\"onConnect\");\n client.subscribe(\"#\");\n}", "_eventLogin() {\n console.info('Successfully logged in! Initializing wiki listeners...');\n this._readLine();\n }", "function listen(listener) {\n\t // TODO: Only use a single history listener. Otherwise we'll\n\t // end up with multiple concurrent calls to match.\n\t return history.listen(function (location) {\n\t if (state.location === location) {\n\t listener(null, state);\n\t } else {\n\t match(location, function (error, redirectLocation, nextState) {\n\t if (error) {\n\t listener(error);\n\t } else if (redirectLocation) {\n\t history.transitionTo(redirectLocation);\n\t } else if (nextState) {\n\t listener(null, nextState);\n\t } else {\n\t ({\"AUTH0_CLIENT_ID\":\"vFL9QUjpiy8LmqgykJVXRhk7dYVvdEip\",\"AUTH0_DOMAIN\":\"edcheung.auth0.com\"}).NODE_ENV !== 'production' ? (0, _routerWarning2.default)(false, 'Location \"%s\" did not match any routes', location.pathname + location.search + location.hash) : void 0;\n\t }\n\t });\n\t }\n\t });\n\t }", "_notifyListenersIfCurrent(user) {\r\n if (user === this.currentUser) {\r\n this.notifyAuthListeners();\r\n }\r\n }", "_notifyListenersIfCurrent(user) {\r\n if (user === this.currentUser) {\r\n this.notifyAuthListeners();\r\n }\r\n }", "function onConnect() {\n // Once a connection has been made, make a subscription and send a message.\n console.log(\"onConnect\");\n\n}", "_handleEvent() {\n const listeners = this._opts.on || {}\n const onceListeners = this._opts.once || {}\n // Add listeners to player\n for(const evt in listeners) {\n if(VIDEO_EVENT_LIST.includes(evt) || USER_EVENT_LIST.includes(evt)) {\n this.player.on(evt, listeners[evt], {\n isPlugin: true,\n plugin: this\n })\n }\n }\n // Once listener\n for(const evt in onceListeners) {\n if(VIDEO_EVENT_LIST.includes(evt)) {\n this.player.once(evt, onceListeners[evt])\n }\n }\n }", "setUpEventListeners() {\n chrome.clipboard.onClipboardDataChanged.addListener(\n () => this.onClipboardDataChanged_());\n document.addEventListener('paste', evt => this.onClipboardPaste_(evt));\n document.addEventListener('copy', evt => this.onClipboardCopy_(evt));\n chrome.accessibilityPrivate.onSelectToSpeakKeysPressedChanged.addListener(\n (keysPressed) => {\n this.onKeysPressedChanged_(new Set(keysPressed));\n });\n chrome.accessibilityPrivate.onSelectToSpeakMouseChanged.addListener(\n (eventType, mouseX, mouseY) => {\n this.onMouseEvent_(eventType, mouseX, mouseY);\n });\n }", "function authStateObserver(user) {\n if (user) { // User is signed in!\n // show the game list\n document.getElementById(\"userID\").innerHTML=getUserName()+\" 님, 안녕하세요.\";\n toggleScreen();\n } else{\n toggleScreen();\n }\n}", "function onConnected()\n{\n document.getElementById('connectionStatus').textContent = \"connected!\";\n readForever();\n console.log(socketId);\n read();\n write('PASS none');\n write('NICK ' + userName);\n write('USER USER 0 * :Real Name', function()\n {\n //wait for a sign that we're registered before joining.\n //Welcome to the Internet Relay Network -RPL_WELCOME via IRC RFCs\n //socket.listen is not an option for client side connections. let's try reading until we get what we want\n var welcomeMsg=\"\";\n var dateRead = new Date();\n console.log(dateRead+\": Wrote after USER\\r\\n\");\n\n //write('JOIN #realtestchannel\\r\\n');\n })//end write\n} // end onConnected", "function setupSubscriptionLogic(element, original) {\n // get <listen> rules from the original declaration\n element.subscriptions = getSubscriptions(element, original);\n if(element.onSubscriptionChannelChanged) {\n element.subscriptions.forEach(function(s){\n element.onSubscriptionChannelChanged(s.channel, s.listener);\n });\n }\n var generateListener = function(element, channel, listener) {\n return function(e) {\n if(e.target.id !== element.id) {\n console.log(element.id + \" <- \" + channel + \"/\" + listener);\n var data = e.detail.data;\n var extra = e.detail.extra;\n var eventSource = e.target;\n element[listener](data, channel, extra, eventSource);\n if(element.onInputReceived) {\n element.onInputReceived(channel, data);\n }\n }\n };\n };\n // set properties on actual on-page element\n element.setSubscription = function(channel, listener) {\n var append = true, fn;\n element.subscriptions.forEach(function(s) {\n if(s.listener === listener) {\n // remove the old event listening\n fn = element[listener].listeningFunction;\n if(fn) {\n console.log(\"removing \"+s.channel+\"/\"+listener+\" pair\");\n element.discardEventListener(document, s.channel, fn);\n }\n // update the channel\n s.channel = channel;\n // bind the new event listening\n if(channel !== Ceci.emptyChannel) {\n fn = generateListener(element, s.channel, s.listener);\n console.log(\"adding \"+s.channel+\"/\"+listener+\" pair\");\n element.setupEventListener(document, s.channel, fn);\n } else {\n fn = false;\n }\n element[listener].listeningFunction = fn;\n append = false;\n }\n });\n if(append) {\n fn = generateListener(element, channel, listener);\n element[listener].listeningFunction = fn;\n console.log(\"adding \"+channel+\"/\"+listener+\" pair\");\n element.setupEventListener(document, channel, fn);\n element.subscriptions.push({\n listener: listener,\n channel: channel\n });\n }\n if(element.onSubscriptionChannelChanged) {\n element.onSubscriptionChannelChanged(channel, listener);\n }\n };\n\n element.removeSubscription = function(channel, listener) {\n var filter = function(s) {\n return !(s.channel === channel && s.listener === listener);\n };\n // single arg: remove listener, regardless of its channel\n if(channel && !listener) {\n listener = channel;\n filter = function(s) {\n return (s.listener !== listener);\n };\n }\n element.subscriptions = element.subscriptions.filter(filter);\n };\n\n element.subscriptions.forEach(function (s) {\n var fn = generateListener(element, s.channel, s.listener);\n element[s.listener].listeningFunction = fn;\n element.setupEventListener(document, s.channel, fn);\n });\n }", "setUpSocketEventListeners() {}", "static _onListenDone () {\n }", "function streamCreatedHandler(event) {\n\t\tfor (var i = 0; i < event.streams.length; i++) {\n\t\t\t// Enable the identify button as soon as the publisher hits 'Allow'\n\t\t\tif (event.streams[i].connection.connectionId == session.connection.connectionId) {\n\t\t\t\t//$(\"#identifyButton\").css(\"display\", \"block\");\n\t\t\t}\n\t\t}\n\t}", "function onDataChannelCreated(channel, id) {\n var being = isInitiator ? \"am\" : \"am not\"\n console.log(\"My id is\", my_id, \"I\", being, \" an initiator, and I CREATED a DataChannel with\", id);\n\n channel.onopen = function () {\n console.log('Channel opened!');\n // send the photo if we initiated the data channel\n if (isInitiator) {\n sendPhoto();\n }\n // otherwise, just receive the bits and report the load medium\n else {\n $(\"#send_medium\")[0].innerHTML = \"browser\";\n }\n };\n\n channel.onerror = function (e) {\n console.log('CHANNEL error!', e);\n loadFromServer();\n };\n\n // when a channel closes, clean up the data channel from our globals\n channel.onclose = function() {\n delete dataChannels[id];\n delete peerConnections[id];\n delete connections[id];\n console.info(\"dataChannel killed on client!\");\n };\n\n channel.onmessage = (webrtcDetectedBrowser == 'firefox') ? \n receiveDataFirefoxFactory(id) :\n receiveDataChromeFactory(id);\n}", "addListener(type, callback) {\n if (type == CALLBACKS.WEBSOCKET_CONNECTED) {\n this.websocketConnectedListeners.push(callback);\n } else if (type == CALLBACKS.WEBSOCKET_DISCONNECTED) {\n this.websocketDisconnectListeners.push(callback);\n } else if (type == CALLBACKS.RAW_WEBSOCKET_MESSAGE_RECEIVED) {\n this.rawMessageListeners.push(callback);\n }\n }", "function onWSSConnection(client) {\n var reqOptions = url.parse(client.upgradeReq.url, true).query;\n\n // AUTHENTICATE USER\n jwt.verify(reqOptions.token, process.env.JWT_SECRET, {\n ignoreExpiration: true,\n ignoreNotBefore: true\n }, function (err, decoded) {\n if (err) return client.close();\n\n sqlz.models.user.findOne({\n where: {id: decoded.sub},\n include: [\n {model: sqlz.models.rule, attributes: ['channel']},\n {model: sqlz.models.moderator, attributes: ['channel']},\n {model: sqlz.models.regular, attributes: ['channel']}\n ]\n }).then(function (query) {\n if (!query) return client.close();\n\n var user = query.dataValues;\n user.bans = extractBans(query);\n user.mod_powers = extractModPowers(query);\n user.regularTags = extractRegularTags(query);\n\n delete user.moderators;\n delete user.regulars;\n delete user.rules;\n\n client.userId = user.id;\n client.username = user.username;\n client.user = user;\n client.subscribedChannels = [];\n client.throttleCount = 0;\n\n client.on('message', function (event) {\n tryCatch(function () {\n event = JSON.parse(event);\n\n switch (event.event) {\n case 'subscribe':\n return handleSubscription(event, client);\n case 'unsubscribe':\n return handleUnsubscription(event, client);\n case 'presence-request':\n return handlePresenceRequest(event, client);\n case 'client-message':\n return handleClientChatMessage(event, client);\n case 'refresh-members':\n return handleRefreshMembersRequest(event, client);\n }\n });\n });\n\n client.on('close', function () {\n while (client.subscribedChannels.length > 0) {\n client.subscribedChannels[0].unsubscribeMember(client);\n }\n\n // To update online friend list (on client side)\n wss.broadcast({\n event: 'client-disconnected',\n userId: user.id\n });\n\n client = null;\n });\n\n send(client, {event: 'connected'});\n });\n });\n}", "async function auth() {\r\nclient.logger.level = 'warn'\r\nconsole.log(banner.string)\r\nclient.on('qr', qr => {\r\n console.log(color(time,\"white\"),color('[','white'),color('∆','red'),color(']','white'),color('Subscribete','white'),color('YOU','red'),color('TUBE','white'),color('Confu_Mods','yellow'))\r\n})\r\n\r\nfs.existsSync('./session.json') && client.loadAuthInfo('./session.json')\r\nclient.on('connecting', () => {\r\n\tconsole.log(color(time,\"white\"),color(\"[ESTADO]\",\"green\"), \"Conectando xd...\")\r\n})\r\nclient.on('open', () => {\r\n\tconsole.log(color(time,\"white\"),color(\"[ESTADO]\", \"green\"), \"Conectado :3\")\r\n})\r\nawait client.connect({timeoutMs: 30*1000})\r\nfs.writeFileSync('./session.json', JSON.stringify(client.base64EncodedAuthInfo(), null, '\\t'))\r\n}", "function onAuthStateChange(callback) {\n return firebase.auth().onAuthStateChanged((user) => {\n if (user) {\n console.log(user)\n if (!user.displayName) {\n fetchUserData(user.uid)\n } else {\n console.log(\"Socket.io connecting displayName \" + user.displayName);\n socket.query = { displayName: user.displayName, id: user.uid };\n // socket = io(ENDPOINT, { query: `displayName=${user.displayName}` });\n callback({\n loggedIn: true,\n displayName: user.displayName,\n email: user.email,\n emailVerified: user.emailVerified,\n photoURL: user.photoURL,\n isAnonymous: user.isAnonymous,\n uid: user.uid,\n });\n }\n } else {\n callback({ loggedIn: false });\n }\n });\n }", "function gotLocalIceCandidate(event){\n if (event.candidate) {\n // Add candidate to the remote PeerConnection\n remotePeerConnection.addIceCandidate(new RTCIceCandidate(event.candidate));\n log(\"Local ICE candidate: \\n\" + event.candidate.candidate);\n }\n }", "connectedCallback() {\n this.subscribeToMessageChannel();\n }", "connectedCallback() {\n console.log(\"Connected Callback called\")\n }", "async authorizeWebsocket(clientId) {\n assert(\n isString(clientId) && clientId,\n `Client ID must be provided as a string.`\n );\n const { _wsServer: wsServer } = this;\n const pendingRequest = this._pendingAuthRequests[clientId];\n if (pendingRequest) {\n const { socket, request, head, timeout } = pendingRequest;\n clearTimeout(timeout);\n delete this._pendingAuthRequests[clientId];\n wsServer.handleUpgrade(request, socket, head, ws => {\n wsServer.emit(\"connection\", ws, request);\n });\n } else {\n log.warn(\n `Cannot authorize unknown WebSocket client \"${clientId}\", ignoring authorizeWebsocket() call.`\n );\n return;\n }\n }", "function BaseChannelAuth () {}" ]
[ "0.61958736", "0.58636725", "0.576607", "0.57518506", "0.5557802", "0.5553211", "0.5529361", "0.5524213", "0.55090606", "0.54507405", "0.5442383", "0.5430207", "0.5401749", "0.5368009", "0.5361097", "0.53551096", "0.53515387", "0.53437555", "0.5279312", "0.5274094", "0.5273579", "0.52702814", "0.5268829", "0.526857", "0.52145886", "0.52128875", "0.5196504", "0.51952416", "0.5164672", "0.51113254", "0.51075727", "0.5090579", "0.50807494", "0.5080062", "0.50691754", "0.50599724", "0.5046308", "0.5041672", "0.504086", "0.50377274", "0.5037459", "0.50340486", "0.50313276", "0.5024427", "0.5018175", "0.501494", "0.50130254", "0.50114256", "0.5011397", "0.50002986", "0.49972832", "0.49944907", "0.49879223", "0.4980389", "0.49799606", "0.49797425", "0.49782342", "0.4974361", "0.49710295", "0.4969005", "0.49678907", "0.4961185", "0.49609232", "0.49580425", "0.495391", "0.49530014", "0.49498168", "0.49278766", "0.49266618", "0.49244788", "0.49175963", "0.49155736", "0.49146518", "0.49083155", "0.490771", "0.48936135", "0.4890502", "0.4888961", "0.4884228", "0.48842034", "0.48842034", "0.4878204", "0.48778167", "0.48766777", "0.48731273", "0.4862155", "0.48573264", "0.48514628", "0.48505557", "0.48492387", "0.48476985", "0.48415866", "0.48339695", "0.4831551", "0.48287746", "0.4827119", "0.48268062", "0.4825585", "0.48248932", "0.48147818" ]
0.6062984
1
Worker that checks the sentiment of comments every 5 seconds
function startWorker(){ (function worker() { var channel_id = getGlobalChannelName(); // console.log("channel_id", channel_id); $.ajax({ type: "POST", url: "https://chat-snitcher-ebs.herokuapp.com/collect_chat_analysis", contentType: 'application/json', data: JSON.stringify({ channel_Id: channel_id}), success: function(data) { // on success write somethibg to HTML // { "average_sentiment": 0.27, "positive_sentiment_percentage":24, .... } var average_sentiment = data.average_sentiment; var positive_sentiment_percentage = data.positive_sentiment_percentage; var negative_sentiment_percentage = data.negative_sentiment_percentage; var neutral_sentiment_percentage = data.neutral_sentiment_percentage; // console.log("average sentiment", average_sentiment); // console.log("sentiment percentages, neg, positive, neutra;", negative_sentiment_percentage, positive_sentiment_percentage, neutral_sentiment_percentage); if (average_sentiment > 0.60){ var mood = "Awesome!!"; var img = document.createElement("IMG"); img.src = "images/awesome.gif"; } else if (average_sentiment >= 0.23 && average_sentiment <= 0.60 ){ mood = "Positive"; img = document.createElement("IMG"); img.src = "images/happy.gif"; } else if (average_sentiment > -0.38 && average_sentiment< 0.22){ mood = "Neutral"; img = document.createElement("IMG"); img.src = "images/neutral.gif"; } else if (average_sentiment <= -0.38 && average_sentiment >= -0.64){ mood = "Miffed"; img = document.createElement("IMG"); img.src = "images/miffed.gif"; } else if (average_sentiment < -0.64){ mood = "Bad"; img = document.createElement("IMG"); img.src = "images/bad.gif"; } else{ mood = "Error"+ average_sentiment ; } // assign values to divs var div = document.querySelector("#viewer_sentiment"); var pos_div = document.querySelector("#pos_percentage"); var neut_div = document.querySelector("#neut_percentage"); var neg_div = document.querySelector("#neg_percentage"); div.innerHTML = "Your chat room is feeling <mark>"+ mood + "</mark>"; pos_div.innerHTML = "Positive " + positive_sentiment_percentage + "%"; neg_div.innerHTML = "Negative " + negative_sentiment_percentage + "%"; neut_div.innerHTML = "Neutral " + neutral_sentiment_percentage + "%"; var image_div = document.querySelector("#imageDiv1"); image_div.innerHTML ='<img id="sentiment_image" src=' + img.src + ' class="img-thumbnail"></img>'; // document.getElementById('imageDiv').style.backgroundImage = img.src; }, complete: function() { // run every 10 seconds setTimeout(worker, 10000); } }); })(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async function main(){\r\n const botSubmissions = await r.getUser('autolovepon').getSubmissions()\r\n botSubmissions.forEach(function(submission){\r\n parseThread(submission)\r\n\r\n //if pass certain comment threshold then pass to download function\r\n //or compare with a list of anime you follow\r\n })\r\n}", "function job_check_gmail_thread_snippet() {\n\n var search_query_array = config_gmail_search_array_();\n \n for (var i = 0; i < search_query_array.length; i++) {\n\n //console.log('searching: ' + search_query_array[i][1]);\n \n var result = threadQuery_(search_query_array[i][1]);\n\n //console.log(result);\n\n if(result.length > 0) {\n\n //console.log('result length is longer than 0');\n\n result.forEach(async function(r) {\n \n // console.log('posting card now');\n console.log(r);\n\n postTopicAsCard_(WEBHOOK_URL, CARD_TITLE, CARD_SUBTITLE, IMG_URL, search_query_array[i][0], r, CARD_LINK);\n\n //post_to_slack_(CARD_TITLE, CARD_SUBTITLE, search_query_array[i][0], r, CARD_LINK)\n\n var slack_payload = format_slack_payload(search_query_array[i][0], CARD_TITLE, r)\n \n send_alert_to_slack(slack_payload);\n\n\n });\n\n }\n\n }\n\n}", "async function restart() {\n\t\t\t//console.log('restart');\n\t\t\t\t\n\t\t\tlet commentsId = 'comments';\n\t\t\tcomments = document.getElementById(commentsId);\n\t\t\tif(!comments) return;\n\t\t\tlet threadTag = 'ytd-comment-thread-renderer';\n\t\t\tlet textTag = 'ytd-expander';\n\t\t\tlet threads = comments.getElementsByTagName(threadTag);\n\n\t\t\tfor (let thread of threads) {\n\t\t\t\tif (doneThreads.has(thread)) continue;\n\t\t\t\tdoneThreads.set(thread, 1);\n\t\t\t\t//console.log(thread);\n\t\t\t\tlet comment = thread.getElementsByTagName(textTag)[0];\n\t\t\t\tif(!comment) continue;\n\t\t\t\tlet baseComment = comment = comment.children[0].children[1];\n\t\t\t\tif(!comment) continue;\n\t\t\t\twhile(comment.firstChild && comment.firstChild.nodeType!=Node.TEXT_NODE) {\n\t\t\t\t\tcomment=comment.firstChild;\n\t\t\t\t}\n\t\t\t\tconsole.log(comment.innerHTML);\n\t\t\t\tif(comment.innerHTML.startsWith('0%')\n\t\t\t\t\t|| baseComment.children.length>3 && baseComment.children[2].innerHTML.trim()=='') {\n\t\t\t\t\t\t//todo: each span is followed by an empty one unless itself empty, check 3rd row, not 3rd span\n\t\t\t\t\tthread.style.display='none';\n\t\t\t\t\tconsole.log('removed: ' + comment.innerHTML);\n\t\t\t\t}\n\t\t\t}\n }", "async function runForComments(comments) {\n if (comments.length) {\n console.log('running for comments:', comments.map(({ id }) => id))\n }\n\n for (const { id, body, issue_url, created_at } of comments) {\n console.log(`processing comment ${id}`)\n const issueUrlSplit = issue_url.split('/')\n const issue = Number(issueUrlSplit[issueUrlSplit.length - 1])\n const surgeDomain = `lh-issue-runner-${issue}-${id}.surge.sh`\n await driver({ issue, commentText: body, surgeDomain })\n // only save state if any work was done\n state.since = created_at\n saveState()\n }\n}", "function showTweets() {\n //Fetch tweet in JSON form\n fetchTweets()\n //Begins the timer with 5 second interval\n timer = setInterval(fetchTweets, 5000)\n}", "checkIfPooped() {\n setInterval(() => {\n if (this.feedCount % 5 === 0) {\n this.hasPooped = true;\n }\n }, 1000);\n }", "function republishTweet() {\n const tenMinutes = 1000 * 60 * 10;\n\n setTimeout(function() {\n publishTweet();\n }, tenMinutes);\n}", "function tiktok() {\n int = setInterval(run, 1000); // configure interval\n}", "async function doLike () {\n try {\n // await ig.login(username, password);\n let medias = await ig.getTimeLineFeed();\n medias.map(async ({ node }) => {\n let now = new Date().getTime();\n let fourHours = 3600 * 4 * 1000;\n let mediaTimePost = node.taken_at_timestamp * 1000;\n if (mediaTimePost >= now - fourHours) {\n if (!node.viewer_has_liked) {\n await ig.like(node.id);\n }\n }\n });\n } catch (error) {\n console.error(error);\n }\n setTimeout(doLike, TIMEOUT);\n}", "function scrape(){\n obj = $(\".message-container\")\n for(var i =0; i < obj.length; i++){\n m = obj[i]\n if ($(m).hasClass(\"post-message-container\"))\n continue\n\n id = $(m).attr(\"data-reactid\")\n score = $(m).find(\".likes\").text().trim()\n text = $(m).find(\".message-text\").text()\n timeInfo = $(m).find(\".message-footer-item\")[0].children[0].text\n replies = $(m).find(\".comment-count\")[0].children[1]\n \n if(replies.children.length < 3)\n replies = 0 //no replies yet\n else\n replies = replies.children[2].children[1].innerText //traverse the html tree\n \n sendData(id + \":::\" + replies + \":::\" + score + \":::\" + text + \":::\" + timeInfo + \"\\r\\n\")\n }\n setTimeout(refreshPage, 1000 * 60 * 5) //refresh page every 5 min\n}", "function timedCommentSetup(){\n\n var renderCommentsTimeout = setTimeout(function(){clearTimeout(setupTimedCommentsPing);}, 40000);\n var setupTimedCommentsPing = setInterval(function() {\n if (eimeerTimedComments){\n clearTimeout(renderCommentsTimeout);\n clearTimeout(setupTimedCommentsPing);\n setInterval(updateTimedComments, 1000);\n }\n }, 1000);\n}", "async function main() {\n let fileName = await crawlExchange('coinmarketcap.com');\n await calculateStatistic(fileName, (exchanceList) => exchanceList.data);\n}", "function loop() { unread(null); setTimeout(loop, 60000)}", "function loadAndProcessTweets(/*days*/) {\n //https://developer.twitter.com/en/docs/tweets/search/api-reference/get-search-tweets\n //https://codeburst.io/build-a-simple-twitter-bot-with-node-js-in-just-38-lines-of-code-ed92db9eb078\n \n var T = new Twitter(config);\n var params = {\n q: '#Nike', //q is the only required parameter, and is looking for tweets with Nike\n count: 1, //only want X number of results\n result_type: 'recent', //only most recent results\n lang: 'en' //only English results\n }\n return;\n T.get('search/tweets', params, function(err, data, response){\n if(!err){\n for(let i = 0; i < data.statuses.length; i++){\n // Get the tweet Id from the returned data\n let id = { id: data.statuses[i].id_str }\n //console.log(data.statuses[i]);\n var text = data.statuses[i].text;\n var timestamp = data.statuses[i].created_at;\n var adjusted_timestamp = moment(timestamp, 'ddd MMM DD HH:mm:ss +ZZ YYYY').format('YYYY-MM-DD h:mm:ss');\n // console.log(adjusted_timestamp);\n var sentiment = getSentiment(data.statuses[i]); //this might change as getSentiment changes\n // storeTweets(text, adjusted_timestamp, sentiment, positive, negative, neutral, mixed);\n }\n } else {\n console.log(err);\n }\n })\n}", "function ten_second_interval( last_song_id ) {\n // Reload the number of days since the last discrepancy log\n // was filed\n daysSinceLastIncident();\n\n // Reload the number of web stream listeners\n $.getJSON( \"https://stream.wmtu.mtu.edu:8000/status-json.xsl\", undefined, czech_listeners );\n\n // Load new items into the trackback feed\n last_song_id = load_trackback( false, last_song_id );\n\n // Load new items into the Twitter request feed\n $.getJSON( \"./twitter.php?first=false\", function( data ) {\n var i = 0;\n cycleTwitterFeed( i, data, false );\n } );\n\n // Reload the image\n cycleImageFeed();\n\n // Check whether or not songs are being logged\n check_logging();\n\n // Run again in ten seconds\n setTimeout( ten_second_interval, 10000, last_song_id );\n}", "function doWork() {\t\r\n\tdate = new Date();\r\n\tdone = false;\r\n\r\n\tstuck = 0;\r\n\r\n\tif (date.getHours() >= startTime && date.getHours() < endTime) {\r\n\t\teraseColors();\r\n\t\tsynthesis.cancel();\r\n\r\n\t\t// upon request, give description of project\r\n\t\tif (explanation == true) {\r\n\t\t\texplanation = false;\r\n\r\n\t\t\tsocket.emit('message', 'The tones you hear relate to the colors of the object being described.<br /><br /><br /><br />Low notes are colors at the beginning of the rainbow, like <font color=\"red\">red</font> and <font color=\"orange\">orange</font>.<br /><br />High notes are colors at the end of the rainbow, like <font color=\"blue\">blue</font> and <font color=\"purple\">purple</font>.<br /><br /><br /><br />Notes that play sooner represent more of the object\\'s color.<br /><br /><br /><br /><span style=\"font-size: 80%\">Small sounds are small objects.</span><br /><br /><span style=\"font-size: 120%\">Big sounds are big objects.</span><br /><br /><br /><br /><font color=\"#00b300\">Louder sounds are brighter colors.</font><br /><br /><font color=\"#3e743e\">Softer sounds are duller colors.</font>');\r\n\r\n\t\t\tfor (var i = 0; i < explanationSpeech.length; i++) {\r\n\t\t\t\tsynthesis.speak(explanationSpeech[i]);\r\n\t\t\t}\r\n\r\n\t\t// upon request, read selection of comments\r\n\t\t} else if (commentRequest == true) {\r\n\t\t\tcommentRequest = false;\r\n\t\t\treadComments();\r\n\r\n\t\t// mention explanation\r\n\t\t} else if (counter%explanationFrequence == 0) {\r\n\t\t\tsynthesis.speak(s);\r\n\t\t\tcounter++;\r\n\r\n\t\t// solicit comment\r\n\t\t} else if (counter%explanationFrequence == Math.floor(explanationFrequence/2)) {\r\n\t\t\tsynthesis.speak(c);\r\n\t\t\tcounter++;\r\n\t\t} else {\r\n\t\t\tgetData();\r\n\t\t\tcounter++;\r\n\t\t} \r\n\t} else if (date.getHours() == reloadTime && counter != 0 && reload) {\r\n\t\tsocket.emit('reloading');\r\n\t\tlocation.reload(true);\r\n\t}\r\n}", "function the_worker()\n {\n globalThis.onmessage = function(e)\n {\n const t = e.data.t;\n if(t < 1) postMessage(e.data.tick);\n else setTimeout(() => postMessage(e.data.tick), t);\n };\n }", "function doWorkflow() {\n\n var props = PropertiesService.getScriptProperties();\n var twit = new Twitterlib.OAuth(props);\n var i = -1;\n var tweets = searchTweets(twit);\n \n if(tweets) {\n for(i = tweets.length - 1; i >= 0; i--) {\n if(sendTweet(tweets[i].id_str, tweets[i].text, twit)) {\n ScriptProperties.setProperty(\"MAX_TWITTER_ID\", tweets[0].id_str);\n break;\n }\n }\n }\n if(i < 0) {\n Logger.log(\"No matching tweets this go-round\");\n }\n}", "commentCreated(body) {\n let data = body;\n const subs = \"fuck\";\n const pen = \"pending\";\n if (body.comment === \"pending\") return false;\n if (body.comment.includes(subs)) {\n data.status = \"Rejected\";\n } else {\n data.status = \"Approved\";\n }\n EventEmitter(\"commentModerated\", data)\n .then() //Feel free to notification or anything , How about lunching a nuclear weapon ?\n .catch(); //You are also free to report an error ? Maybe, try to warn others about the nuclear weapon you mistakenly targeted at your office ?\n }", "function tweeter() {\n\n // Live and Starting\n // var live = true;\n // var starting = false;\n\n\n // if (day != 4) {\n // live = false;\n // }\n // if (hours < 1 || hours > 1) {\n // live = false;\n // }\n\n // Live and Starting\n var tweet;\n // if (live | testing) {\n // Tweet undefined if it goes the LSTM route\n tweet = generateTweet();\n // Make sure nothing offensive\n while (tweet && wordfilter.blacklisted(tweet)) {\n tweet = generateTweet();\n }\n // }\n\n // Go ahead\n // if ((live || testing) && tweet) {\n if (tweet) {\n tweetIt(tweet);\n }\n\n\n}", "function worker() {\n // deleting obsolete data\n executed = executed.filter(obj => obj.executedAt + 1000 > Date.now());\n\n // running available requests\n for (let q in queue) {\n // max 2 request in 1 sec. for one client\n if (queue.hasOwnProperty(q) && executed.filter(obj => obj.client === queue[q].client).length < 2) {\n // remember for control API restrictions\n executed.push({\n client: queue[q].client,\n executedAt: Date.now(),\n });\n // execute request\n queue[q].callback();\n // exclude repeated request\n queue[q] = null;\n }\n }\n\n // clear queue\n queue = queue.filter(obj => obj);\n setTimeout(worker, 300);\n}", "async function AnalyzeApieceOfText() {\n let sentimentService = new sentiment.SentimentService(\n process.env.MICRO_API_TOKEN\n );\n let rsp = await sentimentService.analyze({\n text: \"this is amazing\",\n });\n console.log(rsp);\n}", "async function timerstuff(msg, bot) {\n var interval = setInterval(() => {\n var db = new sqlite3.Database(`./servers/${msg.guild.id}/${msg.guild.id}.db`);\n var fp = `./servers/${msg.guild.id}/server_config.json`;\n if(fs.existsSync(fp)){\n var json = jsonManip.jsonFileReader(fp);\n if (!json[isUsingFFAttribute]) {\n clearInterval(interval);\n }\n }else{\n clearInterval(interval);\n }\n let currentTime = Date.now();\n db.all(`SELECT timestamp, timerMillis\n FROM timers`, [], (err, rows) => {\n if (err) throw err;\n console.log(Math.floor((currentTime - rows[0].timestamp)))\n if (Math.floor((currentTime - rows[0].timestamp)) >= rows[0].timerMillis) {\n db.run(`UPDATE timers SET timestamp = ${currentTime} WHERE timerID = 1`);\n matching(msg, db, bot)\n }\n })\n }, 1000);\n}", "scheduleWatchMessages() {\n this.cronJob = schedule(checkFrequency, this.checkNewMessages.bind(this), {});\n }", "function job_check_gmail_count_only() {\n\n var search_query_array = config_gmail_search_array_();\n \n for (var i = 0; i < search_query_array.length; i++) {\n\n //console.log('searching: ' + search_query_array[i][1]);\n \n var result = countQuery_(search_query_array[i][1]);\n\n if(result > 0) {\n\n postTopicAsCard_(WEBHOOK_URL, CARD_TITLE, CARD_SUBTITLE, IMG_URL, search_query_array[i][0], result + ' emails found', CARD_LINK);\n\n post_to_slack_(CARD_TITLE, CARD_SUBTITLE, search_query_array[i][0], result + ' emails found', CARD_LINK)\n\n }\n\n }\n\n}", "function doTheWork() {\n getUrlsFromPage()\n // .then(urls => {\n // // check in reddis if url exists\n // // return filtered array\n // })\n .then((urls) => {\n urls.forEach(url => {\n //return console.log(url);\n crawl(url).then((car) => {\n printCar(car);\n // send email\n // for later us: client.set(\"string key\", \"string val\", redis.print);\n });\n });\n })\n}", "async function conduct() {\n\tfor (const [publicationType, publicationConfig] of Object.entries(publicationTypes)) {\n\t\t// lookup the total number of rss feeds or podcasts\n\t\tlet total = await publicationConfig.schema.count({});\n\t\t// never schedule more than 1/15 per minute interval\n\t\tlet maxToSchedule = Math.ceil(total / 15 + 1);\n\t\tlogger.info(\n\t\t\t`conductor will schedule at most ${maxToSchedule} to scrape per ${conductorInterval} seconds`,\n\t\t);\n\n\t\t// find the publications that we need to update\n\t\tlet publications = await publicationConfig.schema\n\t\t\t.find({\n\t\t\t\tisParsing: {\n\t\t\t\t\t$ne: true,\n\t\t\t\t},\n\t\t\t\tfollowerCount: {$gte: 1},\n\t\t\t\tvalid: true,\n\t\t\t\tlastScraped: {\n\t\t\t\t\t$lte: moment()\n\t\t\t\t\t\t.subtract(durationInMinutes, 'minutes')\n\t\t\t\t\t\t.toDate(),\n\t\t\t\t},\n\t\t\t\tconsecutiveScrapeFailures: {\n\t\t\t\t\t$lt: rand(),\n\t\t\t\t},\n\t\t\t})\n\t\t\t.limit(maxToSchedule).sort('-followerCount');\n\n\t\t// make sure we don't schedule these guys again till its finished\n\t\tlet publicationIDs = [];\n\t\tfor (let publication of publications) {\n\t\t\tpublicationIDs.push(publication._id);\n\t\t}\n\t\tlet updated = await publicationConfig.schema.update(\n\t\t\t{ _id: { $in: publicationIDs } },\n\t\t\t{\n\t\t\t\tisParsing: true,\n\t\t\t},\n\t\t\t{\n\t\t\t\tmulti: true,\n\t\t\t},\n\t\t);\n\t\tlogger.info(`marked ${updated.nModified} publications as isParsing`);\n\n\t\t// actually schedule the update\n\t\tlogger.info(`conductor found ${publications.length} of type ${publicationType} to scrape`);\n\t\tlet promises = [];\n\t\tfor (let publication of publications) {\n\t\t\tif (!isURL(publication.feedUrl)) {\n\t\t\t\tlogger.warn(`Conductor, url looks invalid for ${publication.feedUrl} with id ${publication._id}`)\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tlet job = { url: publication.feedUrl };\n\t\t\tjob[publicationType] = publication._id;\n\t\t\tlet promise = publicationConfig.enqueue(job, {\n\t\t\t\tremoveOnComplete: true,\n\t\t\t\tremoveOnFail: true,\n\t\t\t});\n\t\t\tpromises.push(promise);\n\t\t}\n\t\tawait Promise.all(promises);\n\n\t\tlogger.info(`Processing complete! Will try again in ${conductorInterval} seconds...`);\n\t}\n}", "async function updateNativeWatchList() {\n var watchList = document.getElementById(\"watchList\");\n var watchedThreads = watchList.getElementsByTagName('li');\n if(watchedThreads !== null && watchedThreads.length > 0) {\n \tfor(var i = 0; i < watchedThreads.length; i++) {\n \tvar thread = watchedThreads[i].id.split('-')[1]; // format is 'watch-12345-s4s'\n var board = watchedThreads[i].id.split('-')[2];\n \n // it's da [s4s] inderfase not da otherboard indaface\n if(board != 's4s') continue;\n\n // GM_getValue will store the ['thread' => 'number of last seen posts'] pairs\n var lastSeen = await GM.getValue(thread, false);\n\n // if we have watched this thread, we check for updates\n if(lastSeen !== false) {\n getCountSince(thread, lastSeen);\n }\n else {\n getNewestPost(thread);\n }\n }\n }\n\n}", "function voting() {\n let chan = bot.guilds\n .get(get('config.discord.serverID'))\n .channels.find('name', get('config.discord.channelName'));\n chan\n .send(votestart('...', 'Loading...'))\n .then(message => {\n requ()\n .then(arr => {\n tweets = arr;\n round = get('round');\n round++;\n db.set('round', round).write();\n let choices = tweets\n .map((cur, ind) => `${ind + 1}: ${cur}`)\n .join('\\n');\n message.edit(votestart(round, choices)).then(() => {\n go = true;\n e.once('complete', res => {\n chan\n .send(\n 'https://twitter.com/' +\n twitterUser.screen_name +\n '/status/' +\n res.id_str,\n {\n embed: {\n description: res.text,\n timestamp: moment()\n .add(get('options.cooldown.toNextVote'), 'minutes')\n .toISOString(),\n author: {\n name: `${twitterUser.name} (@${\n twitterUser.screen_name\n })`,\n icon_url: twitterUser.profile_image_url_https,\n url: 'https://twitter.com/' + twitterUser.screen_name\n },\n footer: {\n icon_url:\n 'https://abs.twimg.com/icons/apple-touch-icon-192x192.png',\n text: 'Next round is'\n }\n }\n }\n )\n .catch(error => {\n console.log(new Error(error));\n process.exit(1);\n });\n let wait = get('options.cooldown.toNextVote') * 60000;\n let currentRound = get('round');\n setTimeout(() => {\n if (!go && get('round') == currentRound) {\n voting();\n }\n }, wait);\n });\n });\n })\n .catch(error => {\n console.log(new Error(error));\n process.exit(1);\n });\n })\n .catch(error => {\n console.log(new Error(error));\n process.exit(1);\n });\n}", "runUpdate() {\n this.utils.log(\"\");\n this.utils.log(\"******************* Running update ******************* \");\n this.utils.log(\"\");\n\n // Reset update flags\n this.updateTweets = false;\n this.updateStatus = false;\n\n // Process any new tweets before performing other operations\n this.checkTrackedTweets().then(() => {\n // Process any mentions\n this.checkMentions().then(() => {\n // Save the status file if needed\n if (this.updateTweets || this.updateStatus) {\n this.dataHandler.saveStatus(this.botStatus);\n }\n });\n\n // Post a normal tweet\n this.actionHandler.postTweet(this.generator.generateResponse());\n\n });\n }", "function start() {\n\n count = 5;\n\n // questionCounter += 1;\n intervalId = setInterval(countDown, 1000);\n\n}", "function pollMentionTweets() {\n\tsetTimeout(updateMentionTweets, TWITTER_POLL_INTERVAL);\n}", "run(){\n // Polling request to server\n const sleep = time => new Promise(resolve => setTimeout(resolve, time))\n const poll = (promiseFn, time) => promiseFn().then(\n sleep(time).then(() => poll(promiseFn, time)))\n\n // polling with callback function which updates the view\n poll(() => new Promise(() => {\n this.data.getActualValues((result)=>{\n this.oeeArray.push(result)\n this.thresholdMessage(result.oee)\n this.updateView(result, this.oeeArray)\n })\n\n }), 5000);\n }", "function ScanForContests(){\t\n\tscanContestsInterval = setTimeout(ScanForContests, config['scan_update_time']*1000);\n\n\tif (ratelimit_search[2] >= config['min_ratelimit_search']){\n\n\t\tfor (var search_query of config['search_queries']){\n\t\t\tTwitter.get('search/tweets', {'q':search_query, 'result_type':'recent', 'count':100, 'lang': 'en'}, function(err, data, response) {\n\t\t\t\tif (err) {\t\n\t\t\t\t\tconsole.log(\"Search error: \" + err);\n\t\t\t\t} else {\n\t\t\t\t\tfor(var tweet of data.statuses){\n\t\t\t\t\t\tvar tweet_id = tweet['id_str'];\n\t\t\t\t \t\tvar original_id;\n\t\t\t\t \t\tvar screen_name = tweet['user']['screen_name'];\n\n\t\t\t\t\t\tif(tweet.hasOwnProperty('retweeted_status')){\n\t\t\t\t \t\t\toriginal_id = tweet['retweeted_status']['id_str'];\n\t\t\t\t \t\t} else if (tweet['in_reply_to_status_id_str'] != null) {\n\t\t\t\t \t\t\toriginal_id = tweet['in_reply_to_status_id_str'];\n\t\t\t\t \t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tif(ignore_list.indexOf(tweet_id) < 0 && ignore_list.indexOf(original_id) < 0 && ignore_list.indexOf(screen_name) < 0) {\n\t\t\t\t\t\t\tvar no_ignore_keyword = true;\n\t\t\t\t\t\t\tvar no_ignore_screen_name = true;\n\n\t\t\t\t\t\t\tfor (let ignore_keyword of ignore_keywords){\n\t\t\t\t\t\t\t\tif(tweet['text'].toLowerCase().indexOf(ignore_keyword) >= 0) no_ignore_keyword = false;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tfor (let ignore_screen_name of config['ignore_screen_names']){\n\t\t\t\t\t\t\t\tif(tweet['user']['name'].toLowerCase().indexOf(ignore_screen_name) >= 0) no_ignore_screen_name = false;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (no_ignore_keyword && no_ignore_screen_name){\n\t\t\t\t\t\t\t\tpost_list.push(tweet);\n\t\t\t\t\t \t\t\taddToIgnoreList(tweet_id);\n\t\t\t\t\t \t\t\taddToIgnoreList(original_id);\n\t\t\t\t\t \t\t\taddToIgnoreList(screen_name);\n\t\t\t\t \t\t\t}\n\t\t\t\t \t\t} \n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\n\t}\n}", "async function runScraper(UN,PW,celebChoice){\r\n let returnedComments = await main_scrape_func(UN,PW,celebChoice)\r\n return returnedComments\r\n }", "function announcements_getCommentsFromDocument() {\n\n var document_id = config.files.announcements.twoWeeks;\n var comments_list = Drive.Comments.list(document_id);\n var comments = \"\";\n var lastTimeScriptRun = getLastTimeScriptRun();\n \n for (var i = 0; i < comments_list.items.length; i++) {\n \n var nextComment = comments_list.items[i] \n var modifiedDate = new Date(nextComment.modifiedDate)\n \n if (nextComment.content.indexOf(config.announcements.scriptLastRunText) === -1 &&\n nextComment.status == \"open\" && \n !nextComment.deleted && \n modifiedDate > lastTimeScriptRun) {\n \n comments += \" \" + (nextComment.content)\n }\n }\n \n if (comments === '') {\n log('No emails to be sent - no comments')\n }\n \n return comments;\n \n // Private Functions\n // -----------------\n \n function getLastTimeScriptRun() {\n \n var datetime = new Date(0); // 1970 - not run yet\n var comments = Drive.Comments.list(document_id);\n \n if (comments.items && comments.items.length > 0) {\n \n for (var i = 0; i < comments.items.length; i++) {\n \n var content = comments.items[i].content;\n \n if (content.indexOf(config.announcements.scriptLastRunText) !== -1) { \n datetime = new Date(content.slice(config.announcements.scriptLastRunTextLength));\n }\n }\n } \n \n return datetime\n \n } // getLastTimeScriptRun()\n \n}", "heartbeat () {\n }", "function watchStockPercent(recipeIDNum){\n\tvar eMsg;\n\t// Runs every hour\n\t//var cronJob = cron.job(\"0 0 */1 * * *\", function(){\n\tvar cronJob = cron.job(\"0 */1 * * * *\", function(){\n\t//get recipe from DB using ID num\n\trecipesDB.get(recipeIDNum, function(err, data){\n\t\tif(err){\n\t\t\teMsg = \"Failed to access the database for recipe _id=\" + recipeIDNum + \"\\n\" + err + \"\\n\"+\"\\n\" ;\n\t\t\tfs.appendFile('errorLog.txt', eMsg, function (err) {\n\n\t\t\t});\n\t\t}else{\n\t\t\tvar stockSymbol = data.trigger.symbol;\n\t\t\tvar stockMarket = data.trigger.market;\n\t\t\tvar stockTriggerValue = data.trigger.watchNum;\n\t\t\tvar thresh = data.trigger.inThreshold;\n\t\t\tvar callbackURL = data.callbackURL;\n\t\t\trequestURL = \"http://dev.markitondemand.com/MODApis/Api/v2/Quote/json?symbol=\"\n\t\t\trequestURL += stockSymbol;\n\n\t\t\trequest(requestURL, function(err, response, body){\n\t\t\t\tif(err){\n\t\t\t\t\teMsg = \"Failed to reach stock API for recipe _id=\" + recipeIDNum + \"\\n\" + err + \"\\n\"+\"\\n\" ;\n\t\t\t\t\tfs.appendFile('errorLog.txt', eMsg, function (err) {\n\n\t\t\t\t\t});\n\t\t\t\t} else {\n\t\t\t\t\tvar parsedbody = JSON.parse(body);\n\t\t\t\t\tvar changePercent = parsedbody.ChangePercent;\n\t\t\t\t\tvar ingred = {\n\t\t\t\t\t\t\t\t\t\"ingredients_data\":{\n\t\t\t\t\t\t\t\t\t\t\"stock_symbol\": stockSymbol,\n\t\t\t\t\t\t\t\t\t\t\"stock_market\": stockMarket,\n\t\t\t\t\t\t\t\t\t\t\"stock_trigger_value\": stockTriggerValue,\n\t\t\t\t\t\t\t\t\t\t\"change_percent\": changePercent\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t//var nsdsApiKey = config.get('NSDS_API_KEY_STAGING');\n\t\t\t\t\tvar headers = {\n\t\t\t\t\t\t\t\t\t'Content-Type':'application/json',\n\t\t\t\t\t\t\t\t\t'nsds-api-key' : nsdsApiKey\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\tif(data.trigger.relation === \"stockPerInc\"){\n\t\t\t\t\t\tconsole.log(\"checking if the percent change is GT trigger value\");\n\t\t\t\t\t\tconsole.log(\"Stocks Percent Change: \" + changePercent);\n\t\t\t\t\t\tconsole.log(\"trigger value: \" + stockTriggerValue);\n\t\t\t\t\t\tif(changePercent > stockTriggerValue){\n\t\t\t\t\t\t\tif(thresh == false) {\n\t\t\t\t\t\t\t\t// changes threshold value to true bc trigger hit\n\t\t\t\t\t\t\t\tdata.trigger.inThreshold = true;\n\t\t\t\t\t\t\t\trecipesDB.insert(data, recipeIDNum, function(err, body, header){\n\t\t\t\t\t\t\t\t\tif(err){\n\t\t\t\t\t\t\t\t\t\teMsg = \"Failed to update database for recipe _id=\" + recipeIDNum + \"\\n\" + err + \"\\n\"+\"\\n\" ;\n\t\t\t\t\t\t\t\t\t\tfs.appendFile('errorLog.txt', eMsg, function (err) {\n\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\tconsole.log(\"stock trigger hit!\");\n\t\t\t\t\t\t\t\tcallbackURL = callbackURL + \"/\" + recipeIDNum;\n\t\t\t\t\t\t\t\trequest.post(callbackURL, { 'headers': headers, 'body': JSON.stringify(ingred)}, function(eRR,httpResponse,body) {\n\t\t\t\t\t\t\t\t\tif(eRR) {\n\t\t\t\t\t\t\t\t\t\teMsg = \"Failed to reach callback URL for recipe _id=\" + recipeIDNum + \"\\n\" + eRR + \"\\n\"+\"\\n\" ;\n\t\t\t\t\t\t\t\t\t\tfs.appendFile('errorLog.txt', eMsg, function (eRR) {\n\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else if(thresh == true) {\n\t\t\t\t\t\t\t// if thresh = true than if difference is > -1.5 than threshold = false\n\t\t\t\t\t\t\tvar Diff = changePercent - stockTriggerValue;\n\t\t\t\t\t\t\tif (Diff > -1.5) {\n\t\t\t\t\t\t\t\tdata.trigger.inThreshold = false;\n\t\t\t\t\t\t\t\trecipesDB.insert(data, recipeIDNum, function(err, body, header){\n\t\t\t\t\t\t\t\t\tif(err){\n\t\t\t\t\t\t\t\t\t\teMsg = \"Failed to update database for recipe _id=\" + recipeIDNum + \"\\n\" + err + \"\\n\"+\"\\n\" ;\n\t\t\t\t\t\t\t\t\t\tfs.appendFile('errorLog.txt', eMsg, function (err) {\n\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t} \n\t\t\t\t\t\t}\n\t\t\t\t\t} else if(data.trigger.relation === \"stockPerDec\"){\n\t\t\t\t\t\tconsole.log(\"checking if the percent change is LT trigger value\");\n\t\t\t\t\t\tconsole.log(\"Stocks Percent Change: \" + changePercent);\n\t\t\t\t\t\tconsole.log(\"trigger value: \" + stockTriggerValue);\n\t\t\t\t\t\tif(changePercent < stockTriggerValue){\n\t\t\t\t\t\t\tif(thresh == false) {\n\t\t\t\t\t\t\t\t// changes threshold value to true bc trigger hit\n\t\t\t\t\t\t\t\tdata.trigger.inThreshold = true;\n\t\t\t\t\t\t\t\trecipesDB.insert(data, recipeIDNum, function(err, body, header){\n\t\t\t\t\t\t\t\t\tif(err){\n\t\t\t\t\t\t\t\t\t\teMsg = \"Failed to update database for recipe _id=\" + recipeIDNum + \"\\n\" + err + \"\\n\"+\"\\n\" ;\n\t\t\t\t\t\t\t\t\t\tfs.appendFile('errorLog.txt', eMsg, function (err) {\n\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\tconsole.log(\"stock trigger hit!\");\n\n\t\t\t\t\t\t\t\tcallbackURL = callbackURL + \"/\" + recipeIDNum;\n\t\t\t\t\t\t\t\trequest.post(callbackURL, { 'headers': headers, 'body': JSON.stringify(ingred)}, function(eRR,httpResponse,body) {\n\t\t\t\t\t\t\t\t\tif(eRR) {\n\t\t\t\t\t\t\t\t\t\teMsg = \"Failed to reach callback URL for recipe _id=\" + recipeIDNum + \"\\n\" + eRR + \"\\n\"+\"\\n\" ;\n\t\t\t\t\t\t\t\t\t\tfs.appendFile('errorLog.txt', eMsg, function (eRR) {\n\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else if(thresh == true) {\n\t\t\t\t\t\t\t// if thresh = true than if difference is > 1.5 than threshold = false\n\t\t\t\t\t\t\tvar Diff = changePercent - stockTriggerValue;\n\t\t\t\t\t\t\tif (Diff > 1.5) {\n\t\t\t\t\t\t\t\tdata.trigger.inThreshold = false;\n\t\t\t\t\t\t\t\trecipesDB.insert(data, recipeIDNum, function(err, body, header){\n\t\t\t\t\t\t\t\t\tif(err){\n\t\t\t\t\t\t\t\t\t\teMsg = \"Failed to update database for recipe _id=\" + recipeIDNum + \"\\n\" + err + \"\\n\"+\"\\n\" ;\n\t\t\t\t\t\t\t\t\t\tfs.appendFile('errorLog.txt', eMsg, function (err) {\n\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t} \n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t});\n\t});\n\tcronJob.start();\n}", "function fetchdata() \n {\n \tvar moment = require(\"moment\");\n\n \tvar keyword = $(\".search-input input\").val();\n console.log(\"Search keyword: \"+keyword);\n\n var sample_data = require('./sample_data_new.json');\n var tweets = sample_data.docs.slice(0,10);\n var trending_hashtags = sample_data.trending_hashtags;\n var num_found = sample_data.numFound;\n var sent_time = sample_data.sentiment_over_time;\n\n for (var t in tweets)\n {\n \tvar tweet = tweets[t];\n\n \tvar tweet_element = '<div class=\"email-list-item peers fxw-nw p-20 bdB bgcH-grey-100 cur-p\">\\\n <div class=\"peer peer-greed ov-h\">\\\n <div class=\"peers ai-c\">\\\n <div class=\"peer peer-greed\">\\\n <h5 class=\"fsz-def tt-c c-grey-900\">$name</h5>\\\n </div>\\\n <div class=\"peer\">\\\n <large>$emoji</large>\\\n </div>\\\n </div>\\\n <div class=\"peers ai-c\">\\\n <div class=\"peer peer-greed\">\\\n <h6>$handle</h6>\\\n </div>\\\n <div class=\"peer\">\\\n <small>$time</small>\\\n </div>\\\n </div>\\\n <span class=\"whs-nw w-100 ov-h tov-e d-b\">$text</span>\\\n </div>\\\n </div>';\n\n\n\t\tvar time_string = moment(tweet[\"tweet_date\"][0]).format(\"lll\");\n\t\tvar sent = tweet[\"sentiment_score\"];\n\n\t\tfunction get_emoji(sent) \n\t\t{\n\t\t\tvar emoji = \"😐\";\n\n\t\t\tif ( sent > -0.25 && sent < 0.25) \n\t\t\t{\n\t\t\t emoji = \"😐\";\n\t\t\t} \n\t\t\telse if ( sent >= 0.25 && sent < 0.50) {\n\t\t\t emoji = \"😀\";\n\t\t\t} \n\t\t\telse if ( sent >= 0.50 && sent < 0.75) {\n\t\t\t emoji = \"😃\";\n\t\t\t}\n\t\t\telse if ( sent >= 0.75) {\n\t\t\t emoji = \"😁\";\n\t\t\t}\n\n\n\t\t\telse if ( sent <= 0.25 && sent > 0.50) {\n\t\t\t emoji = \"😑\";\n\t\t\t} \n\t\t\telse if ( sent <= 0.50 && sent > 0.75) {\n\t\t\t emoji = \" 😒\";\n\t\t\t}\n\t\t\telse if ( sent <= 0.75) {\n\t\t\t emoji = \"😤\";\n\t\t\t}\n\n\t\t \treturn emoji;\n\t\t}\n\t\t\n\t\tvar emoji = get_emoji(sent);\n\n\t\ttweet_element = tweet_element.replace('$handle', \"@\".concat(tweet[\"poi_name\"][0]) );\n\t\ttweet_element = tweet_element.replace('$emoji', \"Emotional Tone: \".concat(emoji) );\n\t\ttweet_element = tweet_element.replace('$name', tweet[\"user.name\"][0] );\n\t\ttweet_element = tweet_element.replace('$time', time_string\t\t );\n\t\ttweet_element = tweet_element.replace('$text', tweet[\"tweet_text\"][0]);\n\n\n\t $('#tweet_container').append(tweet_element);\n\t $(\"#sentiment\").html(get_emoji(sample_data.docs.average_sentiment)); \n\t}\n\n\tvar c = [\"deep-purple\",\"green\",\"blue\",\"amber\",\"red\",\"red\"];\n\n\t// adding trending hashtags\n\tvar count = 0;\n\twhile (count < 6)\n\t{\n\t\tvar hashtag = \"#\".concat(trending_hashtags[count][0]);\n\t\tvar number = trending_hashtags[count][1];\n\t\tvar color = c[count];\n\n\t\tvar template = '<li class=\"nav-item\">\\\n <a href=\"\" class=\"nav-link c-grey-800 cH-blue-500\">\\\n <div class=\"peers ai-c jc-sb\">\\\n <div class=\"peer peer-greed\">\\\n <span>$hashtag</span>\\\n </div>\\\n <div class=\"peer\">\\\n <span class=\"badge badge-pill bgc-$color1-50 c-$color2-700\">$number</span>\\\n </div>\\\n </div>\\\n </a>\\\n </li>';\n\n\n\n template = template.replace('$hashtag', hashtag);\n template = template.replace('$number' , number);\n template = template.replace('$color1' , color);\n template = template.replace('$color2' , color);\n\n $('#trending').append(template);\n\n\t\tcount = count + 1;\n\n\t\tif (count >= trending_hashtags.length)\n\t\t{\n\t\t\tbreak;\n\t\t}\n\t}\n\t\n $(\"#num_found\").html(num_found); \n\n\n\n var sent_xx = [];\n var sent_yy = [];\n\n for (var s in sent_time)\n {\n \tsent_xx.push(moment(sent_time[s][0]).format(\"lll\"));\n \tsent_yy.push(sent_time[s][1]);\n }\n\n\n const lineChartBox = document.getElementById('sentiment-chart');\n\n if (lineChartBox) {\n const lineCtx = lineChartBox.getContext('2d');\n lineChartBox.height = 80;\n\n new Chart(lineCtx, {\n type: 'line',\n data: {\n labels: sent_xx,\n datasets: [{\n label : 'Emotional Tone',\n backgroundColor : 'rgba(232, 245, 233, 0.5)',\n borderColor : COLORS['blue-500'],\n pointBackgroundColor : COLORS['blue-700'],\n borderWidth : 2,\n data : sent_yy,\n }],\n },\n\n options: {\n legend: {\n display: false,\n },\n },\n\n });\n }\n\n\n\n var below_stuff = '<div class=\"peer\">\\\n <span class=\"fsz-def fw-600 mR-10 c-grey-800\">10% <i class=\"fa fa-level-up c-green-500\"></i></span>\\\n <small class=\"c-grey-500 fw-600\">% change in Emotional Tone over time</small>\\\n </div>';\n $('#below_stuff').html(below_stuff);\n\n\n\tconsole.log(\"Search ended\");\n }", "async function sentimentUpdater(){\n //console.log(\"In Function \");\n try {\n let fetchedData = await sentimentDao.getSentimentsToProcess();\n for (let index = 0; index < fetchedData.length; index++) {\n const singleData = fetchedData[index];\n let dataFromGoogle = await googleapi.getValueForReview(singleData);\n let udpateJson = {\n \"review_id\": singleData.review_id,\n \"pros_value\": dataFromGoogle.pros.score,\n \"pros_magnitude\": dataFromGoogle.pros.magnitude,\n \"cons_value\": dataFromGoogle.cons.score,\n \"cons_magnitude\": dataFromGoogle.cons.magnitude,\n \"result\": ((dataFromGoogle.pros.score * dataFromGoogle.pros.magnitude)\n + (dataFromGoogle.cons.score * dataFromGoogle.cons.magnitude))\n }\n //update with the value\n let updateResult = await sentimentDao.updateSentiments(udpateJson);\n }\n \n }\n catch (err) {\n console.log(\"sentimentUpdater -> err\", err);\n }\n}", "function commentCounterPause() {\n pause = parseInt($('#cambox-chat-form textarea').attr('data-pause'), 10);\n if ( pause > 0 ) {\n commentCounter(pause);\n }\n}", "function main() {\n // strip attachments\n var threads = GmailApp.getInboxThreads();\n var label = GmailApp.getUserLabelByName(\"_processed\");\n try {\n for(j=0; j<threads.length; j++) {\n processThread(threads[j]);\n }\n // move message to _processed folder\n label.addToThreads(threads);\n GmailApp.moveThreadsToArchive(threads)\n }\n catch(error) {\n sendSlackMessage(error)\n console.error(error);\n }\n}", "function intervalTasks() {\n calculateGreeting()\n displayTime()\n}", "function cdnRefreshChecker(){\n if(!isProcessing || retry_time >= 2){//force to start cdn refresh procedure if isProcessing is not set to false after 20 minutes\n\n //refresh cdn resources cached in list\n refresh_target_file_from_cache();\n // refresh_target_directory_from_cache();\n\n isProcessing = true;\n retry_time = 0;\n check_service_status((left_refresh_amount) => {\n if(left_refresh_amount <= alert_threshold){\n if(debug){\n console.log('alert! the left refresh service is less than 400, start conservative strategy.');\n }\n //stop current refresh task\n if(debug){\n console.log('stop current refresh task');\n clearInterval(check_task);\n }\n //stop refresh worker\n // if(debug){\n // console.log('stop refresh worker');\n // clearInterval(refresh_worker);\n // }\n //get the start date of conservative refresh\n present_day = new Date().getDate();\n //start conservative strategy\n // check_task_conservative = setInterval(conservative_refresh, refresh_interval);\n }else{\n if(left_refresh_amount == allowed_maximum_dir_refresh_times){\n if(debug){\n console.log('Aliyun service refreshed usage count, refresh whole CDN resource site');\n }\n refresh_ali_cdn_of_target(cdn_whole_resource_address, TYPE_DIRECTORY);\n }\n eventHandler.emit('checkPage', 1);\n }\n });\n\n }else{\n console.log('checker is now processing... retied-->' + retry_time + ' times.');\n retry_time++;\n }\n\n}", "function getCountSince(thread, newestGreenPost) {\n\t\tGM.xmlHttpRequest({\n\t\tmethod:\"get\",\n\t\turl:serverurl+\"watch.php?thread=\"+thread+\"&newestGreenPost=\"+newestGreenPost,\n\t\tonload:response=>{\n\t\t\tif(response.status==200){\n\t\t\t\tonPageLoad(_=>{\n\t\t\t\t\tvar count=response.responseText\n if(count > 0) {\n\t\t\t\t\t\tupdateWatchListItem(thread,count)\n }\n\t\t\t\t})\n\t\t\t}\n\t\t},\n\t\tonerror:response=>{\n return 0;\n\t\t}\n\t})\n}", "function check_app_jobs(username,app_id, app_status)\n{\n app_timer = setInterval(function() {\n if((app_timer !=\"stop\")&&(app_status != 'completed')) check_for_app_finished_job(username,app_id);\n },3000);\n}", "function watchStock(recipeIDNum){\n\tvar eMsg;\n\t// Runs every hour\n\t//var cronJob = cron.job(\"0 0 */1 * * *\", function(){\n\tvar cronJob = cron.job(\"0 */1 * * * *\", function(){\n\t//get recipe from DB using ID num\n\trecipesDB.get(recipeIDNum, function(err, data){\n\t\tif(err){\n\t\t\teMsg = \"Failed to access the database for recipe _id=\" + recipeIDNum + \"\\n\" + err + \"\\n\"+\"\\n\" ;\n\t\t\tfs.appendFile('errorLog.txt', eMsg, function (err) {\n\n\t\t\t});\n\t\t}else{\n\t\t\tvar stockSymbol = data.trigger.symbol;\n\t\t\tvar stockMarket = data.trigger.market;\n\t\t\tvar stockTriggerValue = data.trigger.watchNum;\n\t\t\tvar thresh = data.trigger.inThreshold;\n\t\t\tvar callbackURL = data.callbackURL;\n\t\t\trequestURL = \"http://dev.markitondemand.com/MODApis/Api/v2/Quote/json?symbol=\"\n\t\t\trequestURL += stockSymbol;\n\n\t\t\trequest(requestURL, function(err, response, body){\n\t\t\t\tif(err){\n\t\t\t\t\teMsg = \"Failed to reach stock API for recipe _id=\" + recipeIDNum + \"\\n\" + err + \"\\n\"+\"\\n\" ;\n\t\t\t\t\tfs.appendFile('errorLog.txt', eMsg, function (err) {\n\n\t\t\t\t\t});\n\t\t\t\t} else {\n\t\t\t\t\t// var parsedbody = JSON.parse(body);\n\t\t\t\t\tvar parsedbody = JSON.parse(body);\n\t\t\t\t\tvar stockPrice = parsedbody.LastPrice;\n\t\t\t\t\tvar percentChange = parsedbody.ChangePercent;\n\t\t\t\t\tvar ingred = {\n\t\t\t\t\t\t\"ingredients_data\":{\n\t\t\t\t\t\t\"stock_symbol\": stockSymbol,\n\t\t\t\t\t\t\"stock_market\": stockMarket,\n\t\t\t\t\t\t\"stock_price\": stockPrice,\n\t\t\t\t\t\t\"change_ratio\": percentChange\n\t\t\t\t\t\t}\n\n\t\t\t\t\t}\t\n\t\t\t\t\t//var nsdsApiKey = config.get('NSDS_API_KEY_STAGING');\n\t\t\t\t\tvar headers = {\n\t\t\t\t\t\t'Content-Type':'application/json',\n\t\t\t\t\t\t'nsds-api-key' : nsdsApiKey\n\t\t\t\t\t}\n\n\t\t\t\t\tif(data.trigger.relation === \"stockGT\"){\n\t\t\t\t\t\tconsole.log(\"checking if the stock price is GT trigger value\");\n\t\t\t\t\t\tconsole.log(\"Actual stock price: \" + stockPrice);\n\t\t\t\t\t\tconsole.log(\"trigger value: \" + stockTriggerValue);\n\t\t\t\t\t\tif(stockPrice > stockTriggerValue){\n\t\t\t\t\t\t\tif(thresh == false) {\n\t\t\t\t\t\t\t\t// changes threshold value to true bc trigger hit\n\t\t\t\t\t\t\t\tdata.trigger.inThreshold = true;\n\t\t\t\t\t\t\t\trecipesDB.insert(data, recipeIDNum, function(err, body, header){\n\t\t\t\t\t\t\t\t\tif(err){\n\t\t\t\t\t\t\t\t\t\teMsg = \"Failed to update database for recipe _id=\" + recipeIDNum + \"\\n\" + err + \"\\n\"+\"\\n\" ;\n\t\t\t\t\t\t\t\t\t\tfs.appendFile('errorLog.txt', eMsg, function (err) {\n\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\tconsole.log(\"stock trigger hit!\");\n\t\t\t\t\t\t\t\tcallbackURL = callbackURL + \"/\" + recipeIDNum;\n\t\t\t\t\t\t\t\trequest.post(callbackURL, { 'headers': headers, 'body': JSON.stringify(ingred)}, function(eRR,httpResponse,body) {\n\t\t\t\t\t\t\t\t\tif(eRR) {\n\t\t\t\t\t\t\t\t\t\teMsg = \"Failed to reach callback URL for recipe _id=\" + recipeIDNum + \"\\n\" + eRR + \"\\n\"+\"\\n\" ;\n\t\t\t\t\t\t\t\t\t\tfs.appendFile('errorLog.txt', eMsg, function (eRR) {\n\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else if(thresh == true) {\n\t\t\t\t\t\t\t// if thresh = true than if difference percent is > 7.5 than threshold = false\n\t\t\t\t\t\t\tvar Diff = stockTriggerValue - stockPrice;\n\t\t\t\t\t\t\tvar perc = Diff / stockPrice * 100;\n\t\t\t\t\t\t\tif (perc > 7.5) {\n\t\t\t\t\t\t\t\tdata.trigger.inThreshold = false;\n\t\t\t\t\t\t\t\trecipesDB.insert(data, recipeIDNum, function(err, body, header){\n\t\t\t\t\t\t\t\t\tif(err){\n\t\t\t\t\t\t\t\t\t\teMsg = \"Failed to update database for recipe _id=\" + recipeIDNum + \"\\n\" + err + \"\\n\"+\"\\n\" ;\n\t\t\t\t\t\t\t\t\t\tfs.appendFile('errorLog.txt', eMsg, function (err) {\n\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t} \n\t\t\t\t\t\t}\n\t\t\t\t\t} else if(data.trigger.relation === \"stockLT\"){\n\t\t\t\t\t\tconsole.log(\"checking if the stock price is LT trigger value\");\n\t\t\t\t\t\tconsole.log(\"Actual stock price: \" + stockPrice);\n\t\t\t\t\t\tconsole.log(\"trigger value: \" + stockTriggerValue);\n\t\t\t\t\t\tif(stockPrice < stockTriggerValue){\n\t\t\t\t\t\t\tif(thresh == false) {\n\t\t\t\t\t\t\t\t// changes threshold value to true bc trigger hit\n\t\t\t\t\t\t\t\tdata.trigger.inThreshold = true;\n\t\t\t\t\t\t\t\trecipesDB.insert(data, recipeIDNum, function(err, body, header){\n\t\t\t\t\t\t\t\t\tif(err){\n\t\t\t\t\t\t\t\t\t\teMsg = \"Failed to update database for recipe _id=\" + recipeIDNum + \"\\n\" + err + \"\\n\"+\"\\n\" ;\n\t\t\t\t\t\t\t\t\t\tfs.appendFile('errorLog.txt', eMsg, function (err) {\n\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\tconsole.log(\"stock trigger hit!\");\n\t\t\t\t\t\t\t\tcallbackURL = callbackURL + \"/\" + recipeIDNum;\n\t\t\t\t\t\t\t\trequest.post(callbackURL, { 'headers': headers, 'body': JSON.stringify(ingred)}, function(eRR,httpResponse,body) {\n\t\t\t\t\t\t\t\t\tif(eRR) {\n\t\t\t\t\t\t\t\t\t\teMsg = \"Failed to reach callback URL for recipe _id=\" + recipeIDNum + \"\\n\" + eRR + \"\\n\"+\"\\n\" ;\n\t\t\t\t\t\t\t\t\t\tfs.appendFile('errorLog.txt', eMsg, function (eRR) {\n\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else if(thresh == true) {\n\t\t\t\t\t\t\t// if thresh = true than if difference percent is > 7.5 than threshold = false\n\t\t\t\t\t\t\tvar Diff = stockPrice - stockTriggerValue;\n\t\t\t\t\t\t\tvar perc = Diff / stockPrice * 100;\n\t\t\t\t\t\t\tif (Diff > 7.5) {\n\t\t\t\t\t\t\t\tdata.trigger.inThreshold = false;\n\t\t\t\t\t\t\t\trecipesDB.insert(data, recipeIDNum, function(err, body, header){\n\t\t\t\t\t\t\t\t\tif(err){\n\t\t\t\t\t\t\t\t\t\teMsg = \"Failed to update database for recipe _id=\" + recipeIDNum + \"\\n\" + err + \"\\n\"+\"\\n\" ;\n\t\t\t\t\t\t\t\t\t\tfs.appendFile('errorLog.txt', eMsg, function (err) {\n\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t} \n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t});\n\t});\n\tcronJob.start();\n}", "_fetchComments(post, callback) {\n\n let comments = [];\n var isFormattedComment = true;\n\n // textFormat=plainText required due to http://stackoverflow.com/questions/35281771/youtube-api-textdisplay-is-blank-for-all-comments (once resolved by Google may remove)\n let options = this._generateOptionsPath('GET', ('/youtube/v3/commentThreads?part=snippet&videoId=' + post.id + '&order=time&textFormat=plainText'));\n\n let commentFilter = (item) => (item.kind === 'youtube#commentThread');\n let parseUser = (item) => {\n if (item.authorDisplayName === undefined || item.authorProfileImageUrl === undefined) {\n isFormattedComment = false;\n return false;\n }\n return new User({\n id: (item.authorChannelId ? item.authorChannelId.value : (item.channelId ? item.channelId : 'ERROR')),\n name: item.authorDisplayName,\n photoUrl: item.authorProfileImageUrl,\n vendor: this.identity.vendor\n });\n };\n let parseComment = (item) => {\n if (!item || typeof item !== 'object' || item.id === undefined ||\n\t\t\t\titem.snippet === undefined ||\n\t\t\t\titem.snippet.topLevelComment === undefined ||\n\t\t\t\titem.snippet.topLevelComment.snippet === undefined ||\n\t\t\t\titem.snippet.topLevelComment.snippet.updatedAt === undefined) {\n isFormattedComment = false;\n\t\t\t\treturn null;\n } \n\t\t\treturn new Comment({\n\t\t\t\tcreator: (parseUser(item.snippet.topLevelComment.snippet) ? parseUser(item.snippet.topLevelComment.snippet) : new User()),\n\t\t\t\tid: item.id,\n\t\t\t\tmessage: (item.snippet.topLevelComment.snippet.textDisplay ? this.htmlparser.decode(item.snippet.topLevelComment.snippet.textDisplay) : ''),\n\t\t\t\trawTimestamp: item.snippet.topLevelComment.snippet.updatedAt,\n\t\t\t\ttimestamp: this._epochinator(item.snippet.topLevelComment.snippet.updatedAt),\n\t\t\t\tvendor: this.identity.vendor,\n\t\t\t});\n\t\t\t\n\t\t};\n\n\t\tthis._issueRequest(options, 'loadPosts', (response, headers) => {\n\t\t\t\tcomments = response.items.filter(commentFilter).map(parseComment).filter(item => !!item);\n if (isFormattedComment === false) {\n callback(response.items);\n }\n\n\t\t\t\tif (comments.length > 0) {\n\t\t\t\t\tthis.broadcast('postUpdated', {\n\t\t\t\t\t\tcomments: comments,\n\t\t\t\t\t\tid: post.id,\n\t\t\t\t\t\tidentity: this.identity\n\t\t\t\t\t});\n\t\t\t\t} else {\n\t\t\t\t\tthis.broadcast('postFailed',{\n\t\t\t\t\t\tid: post.id\n\t\t\t\t\t})\n\t\t\t\t}\n\t\t\t},\n\t\t\t(response) => {\n\t\t\t\tif (response.error) {\n\t\t\t\t\tif (response.error.errors[0].reason === \"commentsDisabled\") {\n\t\t\t\t\t\tvar actions = [\n\t\t\t\t\t\t\tnew Action({\n\t\t\t\t\t\t\t\ttype: 'Like'\n\t\t\t\t\t\t\t}),\n\t\t\t\t\t\t\tnew Action({\n\t\t\t\t\t\t\t\ttype: 'Share'\n\t\t\t\t\t\t\t})\n\t\t\t\t\t\t];\n\t\t\t\t\t\tthis.broadcast('postUpdated', {\n\t\t\t\t\t\t\tactions: actions,\n\t\t\t\t\t\t\tid: post.id,\n\t\t\t\t\t\t\tidentity: this.identity,\n\t\t\t\t\t\t\tproperty: 'actions'\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t);\n\t}", "function commentCounter(pause) {\n chatActive = 0;\n $('#comment-form').addClass('disabled');\n $('#comment-form textarea').attr('disabled', 'disabled');\n $('.comments-wrapper .comments').scrollTop(0);\n commentTimeWaitReset();\n if ( pause == 0 ) {\n time_wait = parseInt($(textarea).attr('data-time-wait'));\n } else {\n time_wait = pause;\n }\n var counter = 0;\n var interval = setInterval(function(){\n if ( pause > 0 ) {\n time_wait = pause;\n pause = 0;\n }\n counter++;\n left = time_wait - counter;\n //$('.time-left span.seconds').html(left);\n $('#comment-form textarea').attr('placeholder', 'Espere ' + left + ' segundos para volver a comentar.');\n if ( left == 0 ) {\n chatActive = 1;\n $('#comment-form').removeClass('disabled');\n $('#comment-form textarea').removeAttr('disabled');\n clearInterval(interval);\n $('#comment-form textarea').attr('placeholder', 'Escribe tu Mensaje');\n }\n }, 1000);\n}", "function sendWeeklyComments() {\n \n // get date info in verbose, regex, and terse form (see getDateInfo() help for more)\n var date_info = getDateInfo(1)\n var date_verbose = date_info[0]\n var date_mm_dd = date_info[1]\n var date_regex = date_info[2]\n \n // get course specific variables (folder/spreadsheet ids)\n var local_vars = initializeCourseVariables()\n var master_folder = local_vars[\"admin papers\"]\n var student_uploads = local_vars[\"student papers\"]\n var course_schedule = local_vars[\"schedule\"]\n var template = local_vars[\"email - send files to faculty\"]\n \n var faculty_data = getFacultyInfo(date_verbose, course_schedule)\n var faculty_name = faculty_data[0]\n var faculty_email = faculty_data[1]\n \n if (!(faculty_name == \"NOCLASS\")) {\n \n var target_docs = getTargetFiles(student_uploads, date_mm_dd)\n \n var admin_folder_path = master_folder+date_mm_dd+\"-\"+faculty_name\n \n // zip all files together and dump in Admin directory subfolder for that week's assignments\n var zipped_files = getAdminUploadFolder(admin_folder_path).createFile(Utilities.zip(target_docs, 'Psych2500_'+date_mm_dd+'_ungraded.zip'));\n\n // send zipped files to faculty, along with grading instructions\n sendFilesToFaculty(template, faculty_name, faculty_email, zipped_files)\n \n // we don't need to store the zip file, so trash it when done\n zipped_files.setTrashed(true)\n \n } else { // for days with no class\n \n // send an email saying there's no class to TF \n // (put this in a function)\n MailApp.sendEmail({\n to: '[email protected]',\n subject: 'No class tomorrow ['+ date_verbose + ']. [ from sendComments() daemon ]',\n htmlBody: 'There is no 2500 class tomorrow. So no files were sent to faculty.', \n }); \n }\n}", "analyseArticles(articles, opinionWords) {\n articles.forEach((a) => {\n if (a.url == null) { // if there is no web link, return\n return;\n }\n request(a.url, (err, res, body) => { // send a request to the web link\n var articleText = \"\";\n var root = HTMLParser.parse(body);\n var pElements = root.querySelectorAll(\"p\"); // get all text contained within <p></p> tags\n pElements.forEach(function(p) {\n articleText += p.innerText;\n });\n var sentiment = this.analyseText(articleText, opinionWords); // analyse the text\n console.log(sentiment);\n if (sentiment > 2) {\n this.saveArticle(a, sentiment); // save the article along with it's sentiment\n }\n });\n });\n }", "function heartBeat() {\n httpRequest('GET', SERVER_PATH, 'heartbeat', 'gid=' + gid + '&pid=' + pid + \"&count=\" + count);\n}", "function getCurrentSongSentimood(songLyrics){\r\n var currentSongSentimentTotal = 0;\r\n for (var i = 0; i < songLyrics.length; i++){\r\n\r\n\r\n var sentiment = new Sentimood();\r\n var currentSongLyric = songLyrics[i];\r\n\r\n var currentSongLyricSentiment = sentiment.analyze(currentSongLyric);\r\n\r\n currentSongSentimentTotal += currentSongLyricsSentiment.score;\r\n } \r\n var currentSongSentimentValue = currentSongSentimentTotal/songlyrics.length;\r\n\r\n var currentSongSentiment;\r\n\r\n if(currentSongSentimentValue >= -0.5 && currentSongSentimentValue <= 0.5){\r\n currentSongSentiment = \"Content\";\r\n \r\n }\r\n\r\n else if (currentSongSentimentValue < -0.5 && currentSongSentimentValue > -3.5){\r\n currentSongSentiment = \"Sad\";\r\n\r\n }\r\n\r\n else if(currentSongSentimentValue <= -3.5 && currentSongSentimentValue > -7){\r\n currentSongSentiment = \"Bummer\";\r\n\r\n }\r\n\r\n else if(currentSongSentimentValue <= -7){\r\n currentSongSentiment = \"Are you OK?\";\r\n\r\n }\r\n\r\n else if(currentSongSentimentValue > 0.5 && currentSongSentimentValue < 3.5){\r\n currentSongSentiment = \"Chill\";\r\n\r\n }\r\n\r\n else if(currentSongSentimentValue >= 3.5 && currentSongSentimentValue < 7){\r\n currentSongSentiment = \"Happy\";\r\n \r\n }\r\n\r\n else if(currentSongSentimentValue >= 7){\r\n currentSongSentiment = \"Ecstatic!\";\r\n\r\n }\r\n\r\n else{\r\n currentSongSentiment = \"Unknown\";\r\n }\r\n\r\n // call next function\r\n\r\n}", "function AnalyseWorker(data) {\n\n // Worker data\n this.id = data.id; // Worker ID\n this.user = data.user; // User ID\n this.active = true; // Initial state true so the worker is active when created\n this.status = \"Active\"; // \"Active\" || \"Paused\" || \"Finished\" || \"Worker timed out\"\n\n // DateTime format settings\n this.dateFormat = \"DD/MM/YYYY HH:mm:ss\";\n\n // Filter data\n this.filterData = {\n coordinates: data.coordinates,\n location: data.location,\n keywords: data.keywords\n };\n\n // Worker timer data\n this.timer = {\n workerTimeOut: 24.0001, // Every worker gets deleted after 24 hours\n start: moment(), // Set the worker creation time\n stop: data.timer,\n formattedStart: moment().format(this.dateFormat),\n formattedStop: moment().add('h', data.timer).format(this.dateFormat)\n };\n\n // Tweets\n this.streamData = [];\n\n // Sentiment\n this.sentimentData = {\n tweetCount: 0,\n positiveTweets: 0,\n negativeTweets: 0,\n neutralTweets: 0,\n sentimentScorePerTweet: 0,\n sentimentScore: 0,\n sentimentScorePositive: 0,\n sentimentScoreNegative: 0,\n sentimentComparative: 0\n };\n\n console.log(Date() + \" Worker created: \" + this.id);\n\n}", "function runThis(numRecommendations) { }", "function doPoll(){\n getMessages();\n setTimeout(doPoll,5000);\n}", "function Thread(props) {\n /*TO DO:\n -create a 'posted by: user_name' message for threads\n -make subcomments dynamic\n -make it so user can only like or unlike, not keep adding likes\n -make tick function server dependent. Currently clocks tick out of sync b/c they are a porperty of the thread itself\n */\n\n const [likes, setLikes] = useState(props.likes);\n const [time, setTime] = useState('Loading...');\n const [comments, setComments] = useState([]);\n const [showAddCommentField, setVisibility] = useState(false);\n\n useEffect(() => {\n fetch(`${BACKEND_PORT}/forum_comments/`)\n .then((response) => {\n response.json().then((data) => {\n let old_comments = [];\n for (let i = 0; i < data.length; i++) {\n //make sure comment belongs in this thread\n if (data[i].post_id === props.id) {\n // Retrieve data from backend\n let id = data[i].id;\n let name = data[i].name;\n let message = data[i].message;\n let likes = data[i].likes;\n let date = data[i].date;\n date = new Date(date);\n let post_id = data[i].post_id;\n let key = name + '' + date.getTime();\n //create comment\n let comment = <SubCommentA key={key} id={id} name={name} message={message} createdOn={date} likes={likes} post_id={post_id}/>;\n old_comments.push(comment);\n }\n }\n setComments(old_comments);\n });\n });\n }, []);\n\n const createdOn = props.createdOn;\n setTimeout(tick, 1000);\n //let clock = setInterval(tick, 1000);\n function tick() {\n setTime(howOld(createdOn));\n }\n\n function addLike() {\n fetch(`${BACKEND_PORT}/post/${props.id}`, {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify({ likes : likes + 1 })\n });\n setLikes(likes + 1);\n };\n\n function addComment(name, message) {\n //make sure comment is not empty...\n if (name === '' || message === '') {\n alert('Must name comment and fill out description!');\n return;\n } else {\n console.log(\"User has added a comment...\");\n }\n const date = new Date();\n const key = name + ' ' + date.getTime();\n let newComment = <SubCommentA key={key} name={name} message={message} createdOn={date} likes={0} post_id={props.id}/>;\n setComments(comments.concat([newComment]));\n }\n\n // note: div instead of a react.fragment so that wrapper for the thread can be stylized\n return (\n <div className=\"thread\" id={props.id}>\n <div className=\"thread-name\">{props.name}</div>\n <button className=\"reply-button\" onClick={()=> setVisibility(true)}>Reply</button>\n <button className=\"like-button\" onClick={addLike}>Like</button>\n <div className=\"likes\">{likes}</div>\n <p>{props.message}</p>\n {comments}\n {showAddCommentField ? <CreateSubCommentForm createComment={addComment} post_id={props.id} hide={() => setVisibility(false)}/> : null}\n <p>{time}</p>\n </div>\n );\n }", "function mainGremlinPhaseOne(s) {\n var delayTime = 0;\n var delayRatio = Number(s.variables.UPSTREAM_DELAY_RATIO);\n if (delayRatio > 100){\n s.error(`ERROR: UPSTREAM_DELAY_RATIO (${delayRatio}) is greater than 100`);\n s.deny();\n } else {\n var isDelayed = JSON.parse(weightedSearch({true:delayRatio,false:100-delayRatio}));\n\n if (isDelayed) {\n var delayMin = Number(s.variables.UPSTREAM_DELAY_MIN_TIME);\n var delayMax = Number(s.variables.UPSTREAM_DELAY_MAX_TIME);\n\n if (delayMin > delayMax) {\n s.error(`ERROR: UPSTREAM_DELAY_MIN_TIME (${delayMin}) is greater than UPSTREAM_DELAY_MAX_TIME (${delayMax})`);\n s.deny();\n }\n delayTime = mathRange(delayMin,delayMax);\n s.log(`INFO: Delay Weighting -> {\"min\": ${delayMin}, \"max\": ${delayMax}}`)\n s.log(`INFO: UPSTREAM request was delayed for ${delayTime} miliseconds`)\n }\n }\n delayHandler(delayTime,s.done());\n}", "function runPerformance() {\n writeLog('starting the performance')\n // We're starting a perfomrance, so set perfomring to true\n setPlayStatus('performing', true)\n // I don't remember why this is here but i'm afraid to remove it\n setPlayStatus('fresh', false)\n\n // all this will be run at the end of the performance.\n bot.setTimeout(()=> {\n // Get the live performers current annoucenemnt message.\n // so we can count their emoji stats\n let message = getMessage(getLivePerformer().message)\n\n // console.log(message)\n\n // get the current performer\n let live = liveAccount.findOne()\n // filter through all the reactions to get the fire and poop count\n message.reactions.map(reaction => {\n switch(reaction.emoji.name) {\n case \"🔥\":\n live.dopes = reaction.count\n break\n case \"💩\":\n live.nopes = reaction.count\n break\n default:\n }\n })\n // do the performance math\n live.total = live.dopes + live.nopes\n live.dopeness = (parseInt(live.dopes) / parseInt(live.total)).toFixed(2)\n //update the performer stats\n liveAccount.update(live)\n\n setPlayStatus('performing', false) //their current performance stops\n writeLog('ending performance')\n }, 15000) // we check the performers score every 15 seconds\n }", "doCallbackAndEnableBackgroundPinging() {\n this._beSatisfiedWith = {\n instant: 0,\n low: 0,\n medium: 0\n };\n this._counter = {\n instant: 0,\n low: 0,\n medium: 0\n };\n this._suitableNodeFound = true;\n this._pingInBackGround = true;\n }", "function startUp() {\n refreshComments();\n setInterval(refreshComments, 5000);\n document.getElementById(\"send\").onclick = send;\n }", "sendHeartbeats() {\n // Send heartbeats to idle workers if it's time\n if ((new Date()).getTime() >= this.heartbeatAt) {\n this.waiting.forEach((worker) => {\n this.sendToWorker(worker, MDP.W_HEARTBEAT, null, null);\n })\n this.heartbeatAt = (new Date()).getTime() + HEARTBEAT_INTERVAL;\n }\n }", "function TaskLoop() {\n\t\n}", "async function main() {\n\tlogger.info('Updating RSS feeds now');\n\tlet rssResponse = await RSS.update({}, { isParsing: false }, { multi: true });\n\tlogger.info(`Updated isParsing to false for ${rssResponse.nModified} RSS feeds`);\n\n\tlogger.info('Updating Podcast feeds now');\n\tlet podcastResponse = await Podcast.update({}, { isParsing: false }, { multi: true });\n\tlogger.info(\n\t\t`Updated isParsing to false for ${podcastResponse.nModified} Podcast feeds`,\n\t);\n}", "function checkForIndexUpdate() {\n if (numThreads != document.getElementsByClassName(\"thread\").length) {\n \tnumThreads = document.getElementsByClassName(\"thread\").length\n addGreenPostsToIndex()\n }\n}", "function startNotificationWatcher() {\n notificationCheck(true);\n notificationWatcher = setInterval(notificationCheck, 5000);\n}", "function readtweetsnow() {\n \n \n //API place where Python application renders comments in tweeter NOW\n var url2 = \"/readtweets\"\n\n console.log(\"-> READING NEW TWEETS ********************\");\n \n //Read output from Python application reading tweets now\n d3.json(url2).then(function(tweetsnow) {\n \n var datapie2 = [tweetsnow.nsentiment.neutral, tweetsnow.nsentiment.negative, tweetsnow.nsentiment.positve]\n\n //PLace where pie for split of negative, positive and neutral tweets will be presented\n var placepie2 = \"pie2\";\n\n //Present pie with datapie2 in selected place (placepie2)\n buildPieChart(datapie2, placepie2);\n\n //Calculate the total number of tweets read NOW\n var ntweets = tweetsnow.nsentiment.neutral + tweetsnow.nsentiment.negative + tweetsnow.nsentiment.positve\n \n //Place where total number of tweets will be placed\n var placet = \"#ntw1\";\n\n //Update arrays where trend for negative, positive and neutral tweets will be stored\n neg1.push((tweetsnow.nsentiment.negative/ntweets)*100);\n pos1.push((tweetsnow.nsentiment.positve/ntweets)*100);\n neu1.push((tweetsnow.nsentiment.neutral/ntweets)*100);\n names1.push(index1);\n index1 = index1 + 1;\n\n //Place where trend line for % of negative, positive and neutral tweets will be rendered\n var placeline = \"line1\"\n\n //Build the trendline for the negative, positive and neutral tweets\n buildLineChart(placeline);\n\n //Write the number of tweets read NOW in placet within HTML\n writeNtweets (ntweets, placet);\n\n\n //Get all positive tweets and write them in position indicated #pos\n var ptweets = tweetsnow.positive;\n var placetweets1 = \"#pos\";\n\n tcomments(ptweets, placetweets1);\n\n //Get all negative tweets and write them in position indicated #neg\n var ntweets = tweetsnow.negative;\n var placetweets2 = \"#neg\";\n\n tcomments(ntweets, placetweets2);\n\n //Get all neutral tweets and write them in position indicated #neu\n var neutweets = tweetsnow.neutral;\n var placetweets3 = \"#neu\";\n\n tcomments(neutweets, placetweets3);\n \n \n });\n\n }", "function startTimer(){\n timer= setInterval('updatePosts()',10000);\n\n }", "function showflagdata(url) {\r\n // Create the query to load the last 12 messages and listen for new ones.\r\n var greenflag = 0;\r\n var redflag = 0;\r\n var query = firebase.firestore()\r\n .collection('messages')\r\n .where(\"url\", \"==\", url)\r\n .get()\r\n .then(function (querySnapshot) {\r\n querySnapshot.forEach(function (doc) {\r\n\r\n if (doc.data().action == \"agree\") {\r\n greenflag++;\r\n }\r\n else if (doc.data().action == \"disagree\") {\r\n redflag++;\r\n }\r\n\r\n });\r\n\r\n var sum;\r\n sum = greenflag + redflag;\r\n if (sum != 0) {\r\n greenflag = greenflag * 100 / sum;\r\n redflag = redflag * 100 / sum;\r\n }\r\n document.getElementById(\"greenflagvotes\").innerHTML = greenflag.toFixed(0) + \"% :\";\r\n document.getElementById(\"redflagvotes\").innerHTML = redflag.toFixed(0) + \"%\";\r\n\r\n })\r\n .catch(function (error) {\r\n console.log(\"Error getting documents: \", error);\r\n });\r\n}", "run() {\n\n\t\tif (this.sequence.number == this.settings.sequences) {\n\n\t\t\t//If we reached the maximum amount of icmp_echo_request stop the interval\n\t\t\tthis.stop()\n\n\t\t\treturn;\n\n\t\t}\n\n\t\t//Create the ping message\n\t\tlet ping = {\n\n\t\t\tservice : 'ping',\n\t\t\tdata : {\n\t\t\t\ttype: 'ping-request',\n\t\t\t\tsequence : this.sequence.number,\n\t\t\t\ttimestamp : new Date()\n\t\t\t}\n\n\t\t}\n\n\t\tthis.sendData(this.host, ping)\n\n\t\t//!!!Remember to increment the sequence number\n\t\tthis.sequence.number++;\n\n\t}", "function analyzePosts(callback){\t\n\tlet boldOnly = false;\n\tchrome.storage.local.get(\"posts\", function(posts){\n\t\tposts = posts[\"posts\"];\n\t\tposts = (posts === undefined ? {} : posts);\n\t\t\n\t\tchrome.storage.local.get(\"users\", function(users){\n\t\t\tusers = users[\"users\"];\n\t\t\tusers = (users === undefined ? {} : users);\n\t\t\t\n\t\t\tlet objArray = Object.values(posts);\n\t\t\tobjArray.forEach(function(x){\n\t\t\t\tlet messageContent = generatePostContent(x);\n\t\t\t\t\n\t\t\t\tlet quotes = new Array();\n\t\t\t\tlet tags = new Array();\n\t\t\t\tlet votes = new Array();\n\t\t\t\t\n\t\t\t\t//Remove and mark quote notes if pokeBeach\n\t\t\t\tif(x.type == \"pokebeach\"){\n\t\t\t\t\tlet directQuotes = messageContent.getElementsByClassName(\"bbCodeQuote\");\n\t\t\t\t\tdirectQuotes = Array.prototype.slice.call(directQuotes);\n\t\t\t\t\tdirectQuotes.forEach(function(quote){\n\t\t\t\t\t\tquotes.push(quote.getAttribute(\"data-author\"));\n\t\t\t\t\t\tdeleteNode(quote);\n\t\t\t\t\t});\n\t\t\t\t\t\n\t\t\t\t\tlet indirectQuotes = messageContent.getElementsByClassName(\"quote\");\n\t\t\t\t\tindirectQuotes = Array.prototype.slice.call(indirectQuotes);\n\t\t\t\t\tindirectQuotes.forEach(function(quote){\n\t\t\t\t\t\tdeleteNode(quote);\n\t\t\t\t\t});\n\t\t\t\t\t\n\t\t\t\t\tlet tagLinks = messageContent.getElementsByClassName(\"username\");\n\t\t\t\t\ttagLinks = Array.prototype.slice.call(tagLinks);\n\t\t\t\t\ttagLinks.forEach(function(link){\n\t\t\t\t\t\ttags.push(link.getAttribute(\"data-user\").match(/.*@(.*)/)[1]);\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t//Look for string to match vote pattern. If bolded option is true, check bolded\n\t\t\t\t//posts only\n\t\t\t\t\n\t\t\t\tlet queryText = \"\";\n\t\t\t\tif (boldOnly){\n\t\t\t\t\tlet base = document.createElement(\"div\");\n\t\t\t\t\tlet boldTexts = messageContent.getElementsByTagName(\"b\");\n\t\t\t\t\tboldTexts = Array.prototype.slice.call(boldTexts);\n\t\t\t\t\tboldTexts.forEach(function(boldText){\n\t\t\t\t\t\tbase.appendChild(boldText);\n\t\t\t\t\t});\n\t\t\t\t\tqueryText = strip(base);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t\tqueryText = strip(messageContent);\n\t\t\t\t\n\t\t\t\t//TODO get array of matches to the vote pattern\n\t\t\t\tlet VOTE_STRING = \"##VOTE: *\\\\w+\";\n\t\t\t\tlet UNVOTE_STRING = \"##UNVOTE:?\";\n\t\t\t\tlet VOTE_CAPTURE_STRING = \"^##VOTE: *(\\\\w+)$\";\n\t\t\t\t\n\t\t\t\tlet votePattern = new RegExp(VOTE_STRING, \"gmi\");\n\t\t\t\tlet voteCapturePattern = new RegExp(VOTE_CAPTURE_STRING, \"gmi\");\n\t\t\t\tlet unvotePattern = new RegExp(UNVOTE_STRING, \"gmi\");\n\t\t\t\tlet actionPattern = new RegExp(VOTE_STRING + \"|\" + UNVOTE_STRING, \"gmi\");\n\t\t\t\t\n\t\t\t\tlet matches = queryText.match(actionPattern);\n\t\t\t\tfor (let i = 0; matches && i < matches.length; i++){\n\t\t\t\t\tlet match = matches[i];\n\t\t\t\t\tlet target = voteCapturePattern.exec(match);\n\t\t\t\t\tif (target){\n\t\t\t\t\t\tvotes.push(new VoteRequest(false, target[1], true, false));\n\t\t\t\t\t}\n\t\t\t\t\telse if (unvotePattern.test(match)){\n\t\t\t\t\t\tvotes.push(new VoteRequest(true, null, true, false));\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tx.quotes = quotes;\n\t\t\t\tx.tags = tags;\n\t\t\t\tx.votes = votes;\t\t\t\t\n\t\t\t});\n\t\t\t\n\t\t\tchrome.storage.local.set({\"posts\" : posts}, function() {\n\t\t\t\tif (typeof(callback) === \"function\") \n\t\t\t\t\tcallback();\n\t\t\t});\n\t\t});\t\t\t\n\t});\t\n}", "function DoStatusCheck(webpage) {\n console.log(webpage.name);\n console.log(\"calling dostatus check\");\n console.log(webpage.texttoverify);\n // validate webpage has a url property\n if (typeof webpage.url !== 'undefined' && webpage.url) {\n\n //request(webpage.url.toString()+ \"/ncr\", function(error, response, body) {\n ScrapePage(webpage, function (error, value) {\n if (!error && value[1].status == 200) {\n // verify texttoverify is not null or empty\n if (webpage.texttoverify != null && webpage.texttoverify != \"\") {\n // verify all the texts are present in the webpage\n var texts = webpage.texttoverify.split(',');\n var flag = false;\n for (var i in texts) {\n if (value[0].body.toLowerCase().indexOf(texts[i].trim().toLowerCase()) == -1) {\n // log the error\n db.collection('results').insert({\n webpageid: webpage._id.toString(),\n executiontime: moment().format(),\n result: 0,\n errormessage: texts[i].trim() + ' not found'\n });\n return;\n }\n }\n }\n //if we reached here that means all texts are present\n db.collection('results').insert({\n webpageid: webpage._id.toString(),\n executiontime: moment().format(),\n result: 1\n });\n } else {\n // log the error\n db.collection('results').insert({\n webpageid: webpage._id.toString(),\n executiontime: moment().format(),\n result: 0,\n errormessage: value[1].status\n });\n }\n })\n }\n}", "function main() {\n getLogger().clear();\n\n for (var i = 0; i < threads.length; i++) {\n if (i > 0) {\n getLogger().log(\"---\");\n }\n\n getLogger().log(\"Processing thread number \" + i);\n\n if (anyMessageMatchesAnyRuleInThread(threads[i])) {\n runActionsOnThread(threads[i]);\n } else {\n getLogger().log(\"No action taken because none of your rules were matching this thread.\");\n }\n }\n}", "function getAllComments(){\n\tvar secret_key = \"630008bbe5ae4d6fbf3266dfbacd648e\";\n\tvar renren = new OAuth2('renren', {\n\t\tclient_id:'de7d400db676479b9847a0cdecefac2d',\n\t\tclient_secret:secret_key,\n\t\tapi_scope:'read_user_status,read_user_comment,read_user_request' \n\t});\n\t\n\trenren.authorize(function() {\n\t\tupdate_status('授权成功,开始获取好友回复...');\n\t\taccess_token = renren.getAccessToken();\n\t\tif (window.console) {\n\t\t\tconsole.log(access_token); \n\t\t}\n\t\ttime_allocation = 1000;\n\t\tvar iAFC = 0;\n\t\tfor (var owner_id in globalStatus){\n\t\t\tif (globalStatus[owner_id].crawl){\n\t\t\t\tfor (var i=0; i<globalStatus[owner_id].doingArray.length; i++){\n\t\t\t\t\tcomment_count = globalStatus[owner_id].doingArray[i].comment_count;\n\t\t\t\t\tif (comment_count && globalStatus[owner_id].doingArray[i].crawl){\n\t\t\t\t\t\tglobalSignAFC.push(false);\n\t\t\t\t\t\tgetComment(owner_id, i, time_allocation, secret_key, access_token, iAFC);\n\t\t\t\t\t\tiAFC ++;\n\t\t\t\t\t\ttime_allocation += paramInterval * 1000;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tglobalStatus[owner_id].doingArray[i].replyList = [];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tfor (var i=0; i<globalStatus[owner_id].doingArray.length; i++){\n\t\t\t\t\tglobalStatus[owner_id].doingArray[i].replyList = [];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tsetTimeout(function(){\n\t\t\tglobalOkWithFriendComment = true;\n\t\t}, time_allocation+10*1000);\n\t});\n}", "async function createComments () {\n let comments = [];\n\n for (let i = 0; i < 100; i++){\n let userId = Math.ceil(Math.random()*31);\n let trackId = Math.ceil(Math.random()*40);\n let sentences = Math.ceil(Math.random()*4);\n let res = await fetch(`https://baconipsum.com/api/?type=meat-and-filler&sentences=${sentences}&start-with-lorem`)\n let data = await res.json()\n let comment = {\n content: data[0],\n userId,\n trackId\n }\n comments.push(comment)\n }\n // console.log(comments)\n}", "function onNewDisqusComment() {\n\t var count = getDisqusCount() + 1;\n\t disqusCount.textContent = count;\n\t iframe.contentWindow.postMessage({ msg: 'onDisqusCount', count: count }, '*');\n\t }", "async crawlTrackedCollection () {\n // We are using the usernameName varaible to query the database but ESLint doesn't think so hence disabling the next line\n // eslint-disable-next-line no-unused-vars\n const usernameName = this.configurationOptions.mongoDatabaseInformation.usernameName;\n\n await this.database.databaseObject.collection(this.configurationOptions.mongoDatabaseInformation.trackedCollectionName).find({}).forEach((document, error) => {\n if (error) {\n console.error(error);\n this.isDatabaseReadyForQuery();\n }\n\n this.checkIfExpired(document);\n });\n }", "async function main() {\n\n if (dotenv.error) {\n console.log( \"New install: no configuration found, or script not being run in the root directory\" );\n process.exit();\n }\n\n mysql.config({\n host: config.MYSQL_HOST,\n database: process.env.MYSQL_DATABASE||config.MYSQL_DATABASE,\n user: config.MYSQL_USER,\n password: config.MYSQL_PASSWORD\n });\n\n\t// Now get data from soaringspot\n soaringSpot();\n\n console.log( \"Background download from soaring spot enabled\" );\n setInterval( function() {\n soaringSpot();\n }, 5*60*1000 );\n}", "function startPing()\n{\n var heartbeat = 90;\n heartbeatTimerId = window.setInterval(opPing, heartbeat*1000);\n}", "function startMonitor(userid) {\n\tvar stream = T.stream(\"statuses/filter\", { follow: userid })\n\tstream.on(\"tweet\", function (tweet) {\n\t\tif (tweet.user.screen_name === process.env.twitterAccountToMonitor && tweet.retweeted_status === void 0 && tweet.in_reply_to_status_id === null) {\n\t\t\tconsole.log(`New tweet: https://twitter.com/${tweet.user.screen_name}/status/${tweet.id_str}`)\n\t\t\t// Send tweet link to Discord\n\t\t\thook.send('https://twitter.com/' + tweet.user.screen_name + '/status/' + tweet.id_str)\n\t\t}\n\t})\n}", "async computeWeightsLoop() {\n while ( true ) { // eslint-disable-line no-constant-condition\n try {\n this.computeRecentTestWeights();\n }\n catch( e ) {\n this.setError( `weights error: ${e} ${e.stack}` );\n }\n\n await sleep( 30 * 1000 );\n }\n }", "async function checkLikeRtComent(profileId){\r\n const twertList = await getAllMessages()\r\n let allLikeTextElements = document.querySelectorAll('.favContainer p')\r\n let allLikeElements = document.querySelectorAll('.favIcon')\r\n let allRtTextElements = document.querySelectorAll('.rtContainer p')\r\n let allRtElements = document.querySelectorAll('.rtIcon')\r\n for (let i = 0; i < twertList.length; i++) {\r\n const twert = twertList[i];\r\n \r\n for (let j = 0; j < allLikeTextElements.length; j++) {\r\n const likeTextElement = allLikeTextElements[j];\r\n const likeElement = allLikeElements[j]\r\n if (likeTextElement.innerHTML != twert.fav.length.toString() && likeElement.getAttribute('onclick').includes(twert._id)) {\r\n if (twert.fav.includes(profileId)) {\r\n likeElement.style.backgroundImage = \"url('../img/like-red.png')\"\r\n } else {\r\n likeElement.style.backgroundImage = \"url('../img/like.png')\"\r\n }\r\n likeTextElement.innerHTML = twert.fav.length\r\n }\r\n }\r\n for (let j = 0; j < allRtTextElements.length; j++) {\r\n const rtTextElement = allRtTextElements[j];\r\n const retwertElement = allRtElements[j]\r\n if (rtTextElement.innerHTML != twert.retweet.length.toString() && retwertElement.getAttribute('onclick').includes(twert._id)) { if (twert.retweet.includes(profileId)) {\r\n retwertElement.style.backgroundImage = \"url('../img/retweet-green.png')\"\r\n } else {\r\n retwertElement.style.backgroundImage = \"url('../img/retweet.png')\"\r\n }\r\n rtTextElement.innerHTML = twert.retweet.length\r\n }\r\n }\r\n }\r\n}", "function schedulePulls() {\n interval = setInterval(postNew, routineFrequency);\n}", "function TwitchScraper() {\r\n\r\n // CLEAR THE CONSOLE\r\n console.clear();\r\n\r\n // IF LOG FILES DO NOT EXIST CREATE THEM\r\n if (!fs.existsSync(\"./data/\")) { fs.mkdirSync(\"data\"); }\r\n if (!fs.existsSync(\"./data/source.txt\")) { fs.writeFileSync(\"./data/source.txt\", \"\"); }\r\n if (!fs.existsSync(\"./data/users.txt\")) { fs.writeFileSync(\"./data/users.txt\", \"\"); }\r\n\r\n // RESET CHANNELS TO READ THE NEW LIST\r\n UpdatedChannels = [];\r\n\r\n // READ EACH LINE, PUSH TO CHANNEL ARRAY\r\n lineReader.eachLine('./data/source.txt', function(user) {\r\n UpdatedChannels.push(user);\r\n });\r\n\r\n // CONNECT TO TWITCH CLIENT WITH EACH CHANNEL IN ARRAY\r\n const client = new tmi.Client({\r\n options: { debug: true },\r\n connection: {\r\n secure: true,\r\n reconnect: true\r\n },\r\n identity: {\r\n username: 'SysCruel',\r\n password: 'oauth:0t20a0dpf2y4ezibq3xx3832swpmji'\r\n },\r\n channels: UpdatedChannels\r\n });\r\n\r\n // CONNECT CLIENT\r\n client.connect();\r\n\r\n // DETECT MESSAGES\r\n client.on('message', (channel, tags, message, self) => {\r\n\r\n // USERNAME OF USER SPEAKING, SOURCE CHANNEL THEY ARE SPEAKING ON\r\n // MIGHT BE A BETTER WAY TO DO THIS BUT ITS OKAY\r\n const thisUsername = tags.username.replace('@', '');\r\n const thisChannel = channel.replace('#', '');\r\n\r\n ThreadChannel(thisUsername, thisChannel);\r\n\r\n function ThreadChannel(user, channel) {\r\n\r\n // ADD TO THE LIST OF LOGS FOR YOU\r\n fs.appendFile(\"./data/users.txt\", \"Username: \" + user + \"\\nProfile: https://twitch.tv/\" + user + \"\\nSource: \" + channel + \"\\n\\n\", (err) => {\r\n if (err) { console.log(err);return; }\r\n\r\n // CHECK IF USERNAME EXISTS IN LOG FILES\r\n Users = fs.readFileSync(\"./data/users.txt\", \"utf-8\");\r\n Source = fs.readFileSync(\"./data/source.txt\", \"utf-8\");\r\n\r\n // ADDS CHANNEL TO SOURCE LIST IF IT ISN'T THERE YET\r\n if (!Source.includes(channel)) {\r\n fs.appendFile(\"./data/source.txt\", channel + \"\\n\", (err) => {\r\n if (err) { console.log(err);return; }\r\n });\r\n }\r\n\r\n // WILL ADD SCRAPED USER TO LIST TO CREATE A REVOLVING DOOR\r\n if (!Source.includes(user)) {\r\n fs.appendFile(\"./data/source.txt\", user + \"\\n\", (err) => {\r\n if (err) { console.log(err);return; }\r\n });\r\n }\r\n\r\n // WILL POPULATE A LOG FILE FOR YOU IF THEY DON'T EXIST IN IT\r\n if (!Users.includes(user)) {\r\n fs.appendFile(\"./data/users.txt\", user + \"\\n\", (err) => {\r\n if (err) { console.log(err);return; }\r\n });\r\n }\r\n });\r\n }\r\n });\r\n}", "start () {\n\t\tthis.updateTask.setRepeating ((callback) => {\n\t\t\tthis.update (callback);\n\t\t}, App.HeartbeatPeriod * 4, App.HeartbeatPeriod * 8);\n\t}", "sendActiveThreadCountRes() {\n \n }", "function loadUserData(){\n\t//setInterval(function () {\n\tconsole.log(\"\\n ------------- Send News (\" + new Date() + \")-------------\\n\");\n\t// Use connect method to connect to the server\n\tMongoClient.connect(url, function(err, db) {\n\t\tconsole.log(\"Connected successfully to server\");\n\t\tfindDocuments(db, function(docs) {\n\t\t\t//console.log(\"Found the following records\");\n\t\t\tuserInterests = [];\n\t\t\tfor (var i = 0; i < docs.length; i++){\n\t\t\t\tvar user = {};\n\t\t\t\tuser.screen_name = docs[i].screen_name;\n\t\t\t\tuser.user_interest = docs[i].user_interest;\n\t\t\t\tuserInterests.push(user);\n\t\t\t}\n\t\t\tdb.close();\n\t\t\tconsole.log(userInterests);\n\t\t\t//tweet to those followers who have\n\t\t\t//expressed interest in specific categories\t\t\t\t\n\t\t\tfor (var i=0; i < userInterests.length; i++){\n\t\t\t\tvar user = userInterests[i];\n\t\t\t\tvar screen_name = user.screen_name;\n\t\t\t\tvar country = 'gb';\n\t\t\t\tvar interest = user.user_interest;\n\t\t\t\tvar status_id = user.in_reply_to_status_id;\n\t\t\t\t//console.log(userInterests.length);\n\t\t\t\ttopcountrytweet(user,screen_name,country,interest,status_id,\n\t\t\t\t\t(articles, screen_name, status_id) => {\n\t\t\t\t\t\ttweetTopArticle(articles, screen_name, status_id);\n\t\t\t\t\t}\n\t\t\t\t);\n\t\t\t}\n\t\t});\n\t});\n//}, 60 * 1000); \n}", "function refreshLoop(){\n refreshInterval = setInterval(function(){ \n mlurl = matchlistURL+user;\n postRequest(createMatches,mlurl, true)\n }, 45000);\n}", "function startPolling() {\n setInterval(checkForEvents, 2000);\n }", "function heartbeat(){\n setTimeout(function(){\n $.ajax({ url: \"/thumpthump\", cache: false,\n success: function(data){\n //Next beat\n heartbeat();\n }, dataType: \"json\"});\n }, 10000);//10secs\n}", "function slowloop() {\n // Build the minimap\n logs.minimap.set();\n readmap = getminimap();\n // Build the leaderboard\n readlb = getleaderboard();\n logs.minimap.mark();\n // Check sockets\n let time = util.time();\n clients.forEach(socket => {\n //if (socket.timeout.check(time)) socket.kick('Kicked for inactivity.');\n if (time - socket.statuslastHeartbeat > c.maxHeartbeatInterval) socket.kick('Lost heartbeat.'); \n });\n }", "highlightNewComments() {\n\t\tif (!this.threadId) {\n\t\t\t// not a comment section\n\t\t\treturn;\n\t\t}\n\n\t\tchrome.runtime.sendMessage({ method: 'ExtensionOptions.getAll' }, options => {\n\t\t\tchrome.runtime.sendMessage({ method: 'ThreadStorage.getById', threadId: this.threadId }, thread => {\n\t\t\t\tif (options.redirect && this.isMobileSite()) {\n\t\t\t\t\tthis.redirectToDesktop();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tchrome.runtime.sendMessage({ method: 'ThreadStorage.add', threadId: this.threadId });\n\n\t\t\t\tif (!thread) {\n\t\t\t\t\t// first time in comment section\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tthis.lastVisited = thread.timestamp;\n\n\t\t\t\tinjectCSS(options.css, document.getElementsByTagName('head')[0]);\n\n\t\t\t\tfor (const comment of this.getNewComments()) {\n\t\t\t\t\tthis.highlightComment(comment, options.className);\n\t\t\t\t}\n\t\t\t});\n\t\t});\n\t}", "function findSentiment(msg) {\n const result = sentiment.analyze(msg);\n console.log(result);\n setSentiment(result.score);\n responseInit = false;\n }", "function tweetDailyTimer() {\n\ttweetDaily();\n \tsetInterval(tweetDaily, 1000*60*60*24);\n \tresetTimer();\n \t//Runs the function once daily\n\tsetInterval(resetTimer, 1000*60*60*24)\n}", "async function addTweetThreadToDb(id) {\n // Get first page\n const conversation_id = (await getTweet(id)).body.data[0].conversation_id;\n var page = await recentSearch(conversation_id);\n\n for(const tweet in page.body.data) {\n await addTweetToDatabase(page.body.data[tweet]);\n }\n\n // If more pages...\n while(page.body.meta.next_token) {\n var page = await recentSearch(id, page.body.meta.next_token);\n\n for(const tweet in page.body.data) {\n await addTweetToDatabase(page.body.data[tweet]);\n }\n\n if(page.headers[\"x-rate-limit-remaining\"] <= 0) {\n console.log(\"I'm rate limited... Pausing execution for \" + page.headers[\"x-rate-limit-reset\"] + \" seconds.\")\n await sleep(page.headers[\"x-rate-limit-remaining\"]*1000)\n }\n }\n}", "pollForTweets(n=10000) {\n const headers = new Headers({'Content-Type': 'application/json'});\n const request = new Request(tweetServiceEndpoint, {\n method: 'GET',\n headers: headers,\n });\n fetch(request).then(res => {\n return res.json();\n }).then(tweets => {\n const doEmitNextTweet = () => {\n if (tweets.length) {\n const currentTweet = tweets.pop();\n this.setState({currentTweet: currentTweet.tweet, tweets: tweets});\n this.location$.next({\n coords: {latitude: currentTweet.latLng.lat, longitude: currentTweet.latLng.lng},\n timestamp: new Date().getTime()\n });\n setTimeout(() => {\n doEmitNextTweet();\n }, n);\n } else {\n this.pollForTweets();\n }\n };\n // update the batch size to show the progress bar correctly\n this.setState({tweetBatchSize: tweets.length});\n // tweets come in batches of 0-50 -- emit one at a time and then grab the next batch\n doEmitNextTweet();\n });\n }", "function main() {\n var label = GmailApp.getUserLabelByName(\"Schedule\");\n var threads = label.getThreads();\n Logger.log(threads.length); \n if(threads.length >= 1) {\n\n let workShiftsObject = getWorkShifts(); \n let shifts = workShiftsObject.shifts; \n let shiftsString = writeShifts(workShiftsObject);\n if(shifts == undefined || shifts == '' || shifts == null || shiftsString == undefined) {\n Logger.log(\"No new Shifts(s) from When2Work.com\"); \n }\n else {\n createICS('Schedule.ics',shiftsString); \n sendICS('Schedule.ics', shiftsString.subjectString, ''); // Email goes in 3rd position\n }\n threads[0].removeLabel(label); \n }\n else {\n Logger.log(\"No emails in Schedule Label\"); \n }\n}", "function startLoop(){\r\n setInterval(function(){\r\n if(status === \"start\"){\r\n var response = moment().format('D MMMM YYYY, HH:mm:ss')\r\n response += \"\\n--------------------------------------------\\n\"\r\n var req = https.get(url, function(res) {\r\n var bodyChunks = []\r\n res.on('data', function(chunk) {\r\n bodyChunks.push(chunk)\r\n }).on('end', function() {\r\n let body = Buffer.concat(bodyChunks);\r\n let bodyJson = JSON.parse(body.toString('utf8'))\r\n for(var i=0; i < numberOfCoins; i++){\r\n response = response + config.cryptocurrencies[i] + \" = \" + bodyJson[config.cryptocurrencies[i]][\"USD\"] + \"$ - \" + bodyJson[config.cryptocurrencies[i]][\"EUR\"] + \"€ \\n\"\r\n }\r\n bot.sendMessage(myChatId, response)\r\n })\r\n })\r\n }\r\n }, interval)\r\n}", "async function ReminderProcess() {\r\n if (!cursedConfig.hasReminders) {\r\n return;\r\n }\r\n if (cursedConfig.isRunning && cursedConfig.reminders.length > 0 && CurrentScreen == \"ChatRoom\" && ChatRoomSpace != \"LARP\") {\r\n TryPopTip(30);\r\n let reminder = cursedConfig.reminders[Math.floor(Math.random() * cursedConfig.reminders.length)];\r\n popChatSilent(reminder, \"Reminder\");\r\n }\r\n if (cursedConfig.reminderInterval < 60000) {\r\n cursedConfig.reminderInterval = 60000;\r\n }\r\n setTimeout(ReminderProcess, cursedConfig.reminderInterval);\r\n}", "async function getTrends() {\n let requestId = Math.floor(Math.random() * 10000)\n try {\n let tempTrends = []\n // Get top trends\n let data = await twitterClient.get('trends/place', {\n id: process.env.TWITTER_WOEID,\n })\n\n // Get top 5 trends\n let topTrends = data[0].trends\n .sort((b, a) => a.tweet_volume - b.tweet_volume)\n .slice(0, maxTrends)\n\n // Create stream for each trend\n for (let trend of topTrends) {\n console.log(new Date(), `Getting tweets of trend \"${trend.name}\"`)\n let tweets = await getTweets(trend)\n console.log(new Date(), `Analyzing tweets of trend \"${trend.name}\"`)\n for (let tweet of tweets) {\n // Analyze each tweet under one session\n console.log(new Date(), `Analyzing tweet: ${tweet.text}`)\n let analysis = await analyze(requestId, trend, tweet)\n tweet.analysis = analysis\n }\n // Save trend and analyzed tweets\n tempTrends.push({\n trend,\n tweets,\n })\n }\n\n trends = tempTrends\n console.log(new Date(), \"Done collecting\")\n\n fs.writeFileSync(dataFile, JSON.stringify(trends))\n console.log(new Date(), \"Saving to FS\")\n } catch (e) {\n console.warn(e)\n }\n\n // Wait a few minutes before getting more tweets\n setInterval(getTrends, updateTrendsWaitTime)\n}" ]
[ "0.6835597", "0.5810288", "0.5720304", "0.57178414", "0.55585927", "0.5508826", "0.5481348", "0.54404646", "0.5433081", "0.54156774", "0.5384332", "0.5373829", "0.5351049", "0.53434616", "0.5324132", "0.52862245", "0.5258912", "0.52586526", "0.52499324", "0.52377635", "0.52367276", "0.52207136", "0.51963735", "0.5188856", "0.51741576", "0.5170113", "0.5166805", "0.5156631", "0.5156176", "0.5125556", "0.5122135", "0.5113315", "0.5104992", "0.5093153", "0.5087541", "0.5079136", "0.50743437", "0.5049959", "0.5030668", "0.5027971", "0.50233614", "0.5019986", "0.5016245", "0.5015288", "0.50131714", "0.5012841", "0.5010377", "0.500962", "0.5003785", "0.5002155", "0.4995707", "0.49940252", "0.49914718", "0.49881613", "0.49773887", "0.4970115", "0.4966296", "0.4958222", "0.49552536", "0.49524626", "0.49504554", "0.49478066", "0.49443865", "0.49439847", "0.49376684", "0.49134898", "0.49132764", "0.49105242", "0.49083218", "0.49034488", "0.49034068", "0.48987782", "0.4888711", "0.48856694", "0.48765182", "0.48763007", "0.4872293", "0.48670524", "0.48667243", "0.486492", "0.4856824", "0.48568207", "0.48566318", "0.48543236", "0.48481277", "0.48462975", "0.48414603", "0.48404533", "0.48372096", "0.48363566", "0.48358038", "0.48345807", "0.48338076", "0.4833732", "0.4833259", "0.48314184", "0.48294035", "0.48284438", "0.48273075", "0.48242888" ]
0.59157854
1
Collect streamers channelId from twitch and send to backend where it will be converted to the streamer name. From backend analysis of chat room will stop.
function stopLogging(auth){ var channel_id = auth.channelId.toString() $.ajax({ type: "POST", url: "https://chat-snitcher-ebs.herokuapp.com/collect_channel_name", contentType: 'application/json', data: JSON.stringify({ channel_Id: channel_id}), success: function(data) { // console.log('message', data.message); }, error: function(jqXHR, textStatus, err) { alert('text status '+textStatus+', err '+err) } }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async function getTwitchChannels() {\n\n try {\n \n let dbResponse, twitchNameArray;\n\n dbResponse = await db.announcerGetUniqueTwitchNames();\n twitchNameArray = dbResponse.map(element => {\n return element.twitch_channel_name;\n });\n \n return TWITCH.getStreamersFromArray(twitchNameArray);\n\n } catch (error) {\n \n console.log('Error in getUniqueTwitchNames()', error);\n return null;\n\n }\n\n}", "async function getStreamerTwitch() {\n\tconst user = document.querySelector(\"#streamId\").value;\n\tconsole.log(\"Calling twitch api for user: \" + user);\n\n\tfetch(BASE_URL_TWITCH + user, {\n\t\tmethod: 'GET', // or 'PUT'\n\t\theaders: {\n\t\t\t'Content-Type': 'application/json',\n\t\t\t'Client-ID': CLIENT_ID_TWITCH,\n\t\t},\n\t})\n\t.then((response) => response.json())\n\t.then((user) => {\n\t\tconsole.log('Success:', user);\n\n\t\t//Placing JSON array object into obj for better readability later\n\t\tconst obj = user.data[0];\n\t\tif(obj === undefined) {\n\t\t\tconsole.log(\"Offline\");\n\t\t}\n\t\telse {\n\t\t\taddStreamer(obj.type, obj.user_name, obj.viewer_count);\n\t\t\tconsole.log(obj.type);\n\t\t\tconsole.log(obj.viewer_count);\n\t\t}\n\t})\n}", "function getStreamerData(streamerName) {\n\t\t\t\t// reset context tmpl obj\n\t\t\t\tvar url = 'https://api.twitch.tv/kraken/streams/' + streamerName + '?callback=?';\n\t\t\t\tvar context;\n\n\t\t\t\t// helper function to render data\n\t\t\t\tfunction renderTwitchUser(ctx) {\n\t\t\t\t\t$streamersContainer.append(streamerTmpl(context));\n\t\t\t\t}\n\n\t\t\t\t// reduce twitch status info if necessarly\n\t\t\t\tfunction reduceStatusLength(status) {\n\t\t\t\t\tvar maxLength = 60;\n\t\t\t\t\tif(status.length > maxLength)\n\t\t\t\t\t{\n\t\t\t\t\t\treturn status.slice(0, maxLength - 3) + '...';\n\t\t\t\t\t}\n\t\t\t\t\treturn status;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t// get data from api\n\t\t\t\t$.getJSON(url, function (data) {\n\t\t\t\t\t//if is online\n\t\t\t\t\tif (data.stream) {\n\t\t\t\t\t\tvar info = data.stream.channel;\n\t\t\t\t\t\t// set data for template\n\t\t\t\t\t\tcontext = {\n\t\t\t\t\t\t\tlogoUrl: info.logo || logoUrlPlaceholder,\n\t\t\t\t\t\t\tchannelUrl: info.url,\n\t\t\t\t\t\t\tstreamerName: info.display_name,\n\t\t\t\t\t\t\tstatus: reduceStatusLength(info.status),\n\t\t\t\t\t\t\tisActive: true,\n\t\t\t\t\t\t\tviewers: data.stream.viewers\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// render data\n\t\t\t\t\t\trenderTwitchUser(streamerTmpl(context));\n\t\t\t\t\t} else if (data.status >= 400) {\n\t\t\t\t\t\t// if user doesnt exist\n\t\t\t\t\t\tcontext = {\n\t\t\t\t\t\t\tlogoUrl: logoUrlPlaceholder,\n\t\t\t\t\t\t\tchannelUrl: 'https://www.twitch.tv/',\n\t\t\t\t\t\t\tstreamerName: streamerName,\n\t\t\t\t\t\t\tstatus: \"User doesn't exist or closed account.\",\n\t\t\t\t\t\t\tisActive: false\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// render data\n\t\t\t\t\t\trenderTwitchUser(streamerTmpl(context));\n\t\t\t\t\t} else {\n\t\t\t\t\t\t// if is offline\n\t\t\t\t\t\tvar url = 'https://api.twitch.tv/kraken/channels/' + streamerName + '?callback=?';\n\n\t\t\t\t\t\t$.getJSON(url, function (data) {\n\t\t\t\t\t\t\tcontext = {\n\t\t\t\t\t\t\t\tlogoUrl: data.logo || logoUrlPlaceholder,\n\t\t\t\t\t\t\t\tchannelUrl: data.url,\n\t\t\t\t\t\t\t\tstreamerName: data.display_name,\n\t\t\t\t\t\t\t\tstatus: 'Offline',\n\t\t\t\t\t\t\t\tisActive: false\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// render data\n\t\t\t\t\t\t\trenderTwitchUser(streamerTmpl(context));\n\t\t\t\t\t\t});\t\t\t\t\n\t\t\t\t\t}\t\n\n\t\t\t\t});\n\t\t\t}", "function TwitchScraper() {\r\n\r\n // CLEAR THE CONSOLE\r\n console.clear();\r\n\r\n // IF LOG FILES DO NOT EXIST CREATE THEM\r\n if (!fs.existsSync(\"./data/\")) { fs.mkdirSync(\"data\"); }\r\n if (!fs.existsSync(\"./data/source.txt\")) { fs.writeFileSync(\"./data/source.txt\", \"\"); }\r\n if (!fs.existsSync(\"./data/users.txt\")) { fs.writeFileSync(\"./data/users.txt\", \"\"); }\r\n\r\n // RESET CHANNELS TO READ THE NEW LIST\r\n UpdatedChannels = [];\r\n\r\n // READ EACH LINE, PUSH TO CHANNEL ARRAY\r\n lineReader.eachLine('./data/source.txt', function(user) {\r\n UpdatedChannels.push(user);\r\n });\r\n\r\n // CONNECT TO TWITCH CLIENT WITH EACH CHANNEL IN ARRAY\r\n const client = new tmi.Client({\r\n options: { debug: true },\r\n connection: {\r\n secure: true,\r\n reconnect: true\r\n },\r\n identity: {\r\n username: 'SysCruel',\r\n password: 'oauth:0t20a0dpf2y4ezibq3xx3832swpmji'\r\n },\r\n channels: UpdatedChannels\r\n });\r\n\r\n // CONNECT CLIENT\r\n client.connect();\r\n\r\n // DETECT MESSAGES\r\n client.on('message', (channel, tags, message, self) => {\r\n\r\n // USERNAME OF USER SPEAKING, SOURCE CHANNEL THEY ARE SPEAKING ON\r\n // MIGHT BE A BETTER WAY TO DO THIS BUT ITS OKAY\r\n const thisUsername = tags.username.replace('@', '');\r\n const thisChannel = channel.replace('#', '');\r\n\r\n ThreadChannel(thisUsername, thisChannel);\r\n\r\n function ThreadChannel(user, channel) {\r\n\r\n // ADD TO THE LIST OF LOGS FOR YOU\r\n fs.appendFile(\"./data/users.txt\", \"Username: \" + user + \"\\nProfile: https://twitch.tv/\" + user + \"\\nSource: \" + channel + \"\\n\\n\", (err) => {\r\n if (err) { console.log(err);return; }\r\n\r\n // CHECK IF USERNAME EXISTS IN LOG FILES\r\n Users = fs.readFileSync(\"./data/users.txt\", \"utf-8\");\r\n Source = fs.readFileSync(\"./data/source.txt\", \"utf-8\");\r\n\r\n // ADDS CHANNEL TO SOURCE LIST IF IT ISN'T THERE YET\r\n if (!Source.includes(channel)) {\r\n fs.appendFile(\"./data/source.txt\", channel + \"\\n\", (err) => {\r\n if (err) { console.log(err);return; }\r\n });\r\n }\r\n\r\n // WILL ADD SCRAPED USER TO LIST TO CREATE A REVOLVING DOOR\r\n if (!Source.includes(user)) {\r\n fs.appendFile(\"./data/source.txt\", user + \"\\n\", (err) => {\r\n if (err) { console.log(err);return; }\r\n });\r\n }\r\n\r\n // WILL POPULATE A LOG FILE FOR YOU IF THEY DON'T EXIST IN IT\r\n if (!Users.includes(user)) {\r\n fs.appendFile(\"./data/users.txt\", user + \"\\n\", (err) => {\r\n if (err) { console.log(err);return; }\r\n });\r\n }\r\n });\r\n }\r\n });\r\n}", "function reconnectSubscribe() {\r\n // When socket reconnects we need to resub to all events.\r\n var streamerList = []\r\n\r\n // Cycle through all streams on the page already and add them to array.\r\n // These are the only ones we need to re-sub to in order to get updates again.\r\n $(\".stream\").each(function(index) {\r\n if ($(this).hasClass('streamembed') === false) {\r\n var streamName = $(this).find('h2').text();\r\n streamerList.push(streamName);\r\n }\r\n });\r\n\r\n $.each(streamerList, function(index, value) {\r\n\r\n socket.request({\r\n url: '/api/v1/channels/' + value + '?fields=id,online,token,name,type,partnered',\r\n method: 'get'\r\n }, function(body, response) {\r\n // If response recieved\r\n if (response.statusCode == 200) {\r\n var channelID = body.id;\r\n var cName = body.token;\r\n var cTitle = body.name;\r\n if (body.type !== null || body.type !== undefined) {\r\n var cGame = body.type.name;\r\n } else {\r\n var cGame = \"No Game Set\";\r\n }\r\n var cPartnered = body.partnered;\r\n var cOnline = body.online;\r\n\r\n // If channel is offline when added, make title gray.\r\n if (cOnline === false) {\r\n $('#' + channelID + ' h2').addClass('offline');\r\n };\r\n\r\n // Unfortunately since the channel is always visible in this mode we need to subscribe to all events.\r\n // Subscribe to channel updates.\r\n var updateSlug = [\"channel:\" + channelID + \":update\"];\r\n socket.request({\r\n url: '/api/v1/live',\r\n method: 'put',\r\n params: {\r\n slug: updateSlug\r\n }\r\n }, function(body, response) {\r\n if (response.statusCode == 200) {\r\n socket.on(updateSlug, function(data) {\r\n onChannelUpdate(channelID, cName, cTitle, cGame, data, cPartnered);\r\n });\r\n } else if (response.statusCode == 420) {\r\n console.error('Too many subscriptions');\r\n } else {\r\n console.error('There was an error subbing to the channel update event.', cName);\r\n }\r\n });\r\n\r\n // If partnered subscribe to that channel also.\r\n if (cPartnered === true) {\r\n var updateSlug = [\"channel:\" + channelID + \":subscribed\"];\r\n socket.request({\r\n url: '/api/v1/live',\r\n method: 'put',\r\n params: {\r\n slug: updateSlug\r\n }\r\n }, function(body, response) {\r\n if (response.statusCode == 200) {\r\n // Debug\r\n console.log('Subscribed to subscriber channel', cName);\r\n socket.on(updateSlug, function(data) {\r\n subscriber(channelID);\r\n });\r\n } else if (response.statusCode == 420) {\r\n console.error('Error: Too many subscriptions.');\r\n $('#' + channelID + ' .stream-notice').text('Error.');\r\n } else {\r\n console.error('There was an error subbing to the channel update event.', cName, response.statusCode);\r\n }\r\n });\r\n };\r\n } else {\r\n console.error('Error checking the online state for the channel', username);\r\n }\r\n });\r\n }); // End each statement\r\n}", "function buildChannel(channelID, username, title, game, partnered, followers) {\r\n\r\n // If the channel is partnered...\r\n if (partnered === true) {\r\n var partnered = \"partnered\";\r\n } else {\r\n var partnered = \"not-partnered\";\r\n }\r\n\r\n // If channel is not already on the page...\r\n if ($('#' + channelID).length === 0) {\r\n var streamEmbed = \"https://beam.pro/embed/player/\" + username;\r\n var chatEmbed = \"https://beam.pro/embed/chat/\" + username;\r\n\r\n // Build out the stream on the page.\r\n $('.channelwrapper').append('<div id=\"' + channelID + '\" stream=\"' + username + '\" followers=\"' + followers + '\" class=\"stream\" style=\"display:none\"><div class=\"streambar\"><div class=\"stream-notice\" style=\"display:none\"></div><div class=\"closestream\"><button class=\"closebtn\" stream=\"' + channelID + '\">X</button></div></div><div class=\"streamtop\"><div class=\"streamname\"><h2 class=\"' + partnered + '\"></h2></div><div class=\"cGame\"></div><div class=\"cTitle\"></div></div><div class=\"chatwrap\"></div></div>');\r\n $('#' + channelID + ' .chatwrap').html('<iframe class=\"chatembed\" src=\"https://beam.pro/embed/chat/' + username + '\"></iframe>');\r\n $('#' + channelID + ' .streamtop h2').html('<a href=\"http://www.beam.pro/' + username + '\" target=\"_blank\">' + username + '</a>');\r\n $('#' + channelID + ' .cGame').text(game);\r\n $('#' + channelID + ' .cTitle').text(title);\r\n $('#' + channelID + ' .streamtop').append('<button class=\"watch\" stream=\"' + username + '\">Watch</button>');\r\n $('#' + channelID).css('display', 'block');\r\n\r\n // Watch Button to watch streams..\r\n $('#' + channelID + ' .watch').click(function() {\r\n $('#' + channelID).before('<div stream=\"' + channelID + '\" stream=\"' + username + '\" class=\"stream streamembed\"><div class=\"streambar\"><div class=\"stream-notice\" style=\"display:none\"></div><div class=\"closestreamembed\"><button class=\"closebtn\" stream=\"' + channelID + '\">X</button></div></div><div class=\"streamtop\"><div class=\"streamname\"><h2 class=\"' + partnered + '\"><a href=\"http://www.beam.pro/' + username + '\" target=\"_blank\">' + username + '</a></h2></div><div class=\"cGame\"></div><div class=\"cTitle\"></div></div><div class=\"streamwrap\"><iframe src=\"https://beam.pro/embed/player/' + username + '\"></iframe></div></div>');\r\n\r\n // Set height of chat window to the same height as the video..\r\n var newHeight = $('.streamembed[stream=\"' + channelID + '\"] iframe').height();\r\n $('.chatembed').css('height', newHeight);\r\n\r\n // Scroll to element to account for new chat height.\r\n $('html, body').delay(750).animate({\r\n scrollTop: $('.streamembed[stream=\"' + channelID + '\"]').offset().top\r\n }, 1500);\r\n\r\n\r\n $('.streamembed[stream=\"' + channelID + '\"] .closestreamembed .closebtn').click(function() {\r\n $('.streamembed[stream=\"' + channelID + '\"]').remove();\r\n // Set related chat window back to regular height.\r\n $('.chatembed').css('height', '400px');\r\n });\r\n });\r\n\r\n }\r\n}", "setChannelName (callback) {\n\t\t// since posting to streams other than the team stream is no longer allowed,\n\t\t// just listen on the team channel\n\t\tthis.channelName = `team-${this.team.id}`;\n\n\t\t/*\n\t\tif (!this.isTeamStream) {\n\t\t\tthrow 'stream channels are deprecated';\n\t\t}\n\t\tthis.channelName = `team-${this.team.id}`;\n\t\t//this.channelName = this.isTeamStream ? `team-${this.team.id}` : `stream-${this.stream.id}`;\n\t\t*/\n\t\t\n\t\tcallback();\n\t}", "function savedChannels() {\r\n var savedStreams = localStorage.getItem(\"streamer\");\r\n if (savedStreams !== undefined && savedStreams !== null && savedStreams !== \"\") {\r\n $.each(savedStreams.split(','), function() {\r\n singleChannelSubscribe(this);\r\n });\r\n }\r\n}", "getChannels() {\n const slack_channels = this.bot.getChannels()._value.channels;\n\n for (let item = 0; item < slack_channels.length; item++) {\n this.channels[slack_channels[item].id] = slack_channels[item].name;\n }\n }", "function getChannel(name) {\n\t\t$.ajax({\n\t\t\tdataType: 'json',\n\t\t\theaders: {\n\t\t\t\t'Client-ID': process.env.TWITCH_CLIENT_ID,\n\t\t\t},\n\t\t\turl: `https://api.twitch.tv/kraken/channels/${name}`\n\t\t})\n\t\t.done(json => {\n\t\t\tconst streamData = {\n\t\t\t\tstreamUrl: json.url,\n\t\t\t\tstreamLogo: json.logo || defaultLogo,\n\t\t\t\tstreamName: json.display_name,\n\t\t\t\tstreamInfo: json.status || defaultInfo,\n\t\t\t\tstreamStatus: 'offline'\n\t\t\t};\n\t\t\t$('#featuredDivider').append(streamTemplate(streamData));\n\t\t})\n\t\t.fail(err => {\n\t\t\tconsole.log(err);\n\t\t});\n\t}", "async checkStreamStatus() {\n\n let newOnlineStreamers = await twitch.updateOnlineStreams();\n\n for (let streamerData of newOnlineStreamers) {\n await this.announceStream(streamerData);\n }\n }", "function getChannel() {\n channels.forEach(function(channel) {\n function makeURL(type, name) {\n return 'https://wind-bow.gomix.me/twitch-api/' + type + '/' + name + '?callback=?';\n };\n $.getJSON(makeURL(\"channels\", channel), function(data) {\n $(\"#\" + channel).attr('src',data.logo)\n $(\".\" + channel).html(channel)\n $(\"#\" + channel + '1').attr('href', data.url)\n $(\".game\" + channel).html('GAME:' + '<br>' + data.game)\n $(\".status\" + channel).html('STATUS:' + '<br>' + data.status)\n });\n $.getJSON(makeURL(\"streams\",channel), function(data) {\n console.log(data);\n var str1 = 'This user is currently not streaming.';\n if (data.stream === null) {\n $(\".\" + channel).addClass(\"offline\")\n $(\".game\" + channel).html(str1)\n $('.game' + channel).show();\n } else {\n $(\".\" + channel).addClass(\"online\")\n $(\".game\" + channel).removeClass('hidden')\n $(\".status\" + channel).removeClass('hidden')\n }\n });\n });\n}", "async GetChannelViewers(channel_name) {\n let cfg = this.Config.GetConfig();\n if (this.isEnabled() !== true) return Promise.reject(new Error('TwitchAPI is disabled.'));\n if (cfg['disabled_api_endpoints'].find(elt => elt === 'Get Channel Viewers')) return Promise.reject(new Error('Endpoint is disabled.'));\n\n //ADD TO STATS\n this.STAT_API_CALLS++;\n this.STAT_API_CALLS_PER_10++;\n\n if (this.API_LOG && cfg['log_api_calls']) {\n this.API_LOG.insert({\n endpoint: 'Channel Badges',\n token: 'NONE',\n querry_params: { channel_name },\n time: Date.now()\n }).catch(err => this.Logger.warn(\"API Logging: \" + err.message));;\n }\n\n return new Promise(async (resolve, reject) => {\n let output = null;\n try {\n await this.request(\"http://tmi.twitch.tv/group/user/\" + channel_name + \"/chatters\", {}, json => {\n output = json;\n });\n resolve(output);\n } catch (err) {\n reject(err);\n }\n });\n }", "async function getStreamerMixer() {\n\tconst user = document.querySelector(\"#streamId\").value;\n\tconsole.log(\"Calling mixer api for user: \" + user);\n\n\tfetch(BASE_URL_MIXER + user, {\n\t\tmethod: 'GET', // or 'PUT'\n\t\theaders: {\n\t\t\t'Content-Type': 'application/json',\n\t\t},\n\t})\n\t\t.then((response) => response.json())\n\t\t.then((user) => {\n\t\t\tconsole.log('Success:', user);\n\n\t\t\t//User is already a parsed JSON object, can access data directly and check if user.online === true\n\t\t\tif(user.online === true) {\n\t\t\t\taddStreamer(user.online, user.token, user.viewersCurrent);\n\t\t\t\tconsole.log(user.online);\n\t\t\t\tconsole.log(user.viewersCurrent);\n\t\t\t}\n\t\t\telse\n\t\t\t\tconsole.log(\"Offline\");\n\t\t})\n}", "function getStreamByChannel(channel) {\n return twitchService.get(channel).then(function(response) {\n console.info(response.data);\n var data = response.data;\n data.name = channel;\n vm.streams.push(data);\n }, function(err) {\n console.log(err);\n vm.streams.errors = vm.streams.errors || [];\n vm.streams.errors.push({ name: channel, message: err.data.message});\n });\n }", "function AddStreamer(arg){\n\t\t// appends the streamer names to the list\n\t\tvar list = document.getElementById(\"my-streamers-list\");\n\t\tvar li = document.createElement(\"li\");\n\t\tvar span = document.createElement(\"span\");\n\t\tspan.innerHTML = \" \";\n\t\tli.innerHTML = arg.name;\n\t// checks if streams is offline\n\t// and sets the circle span class acordingly\n\t$.get(\"https://wind-bow.gomix.me/twitch-api/streams/\" + arg.name, function(data){\n\t\tif (data.stream === null) {\n\t\t\tmyStreamers.filter(function(x){\n\t\t\t\tif(x.name === arg.name) {\n\t\t\t\t\tx[\"state\"] = \"Offline\";\n\t\t\t\t\tli.innerHTML = arg.name;\n\t\t\t\t\tli.appendChild(span);\n\t\t\t\t\tlist.appendChild(li);\n\t\t\t\t};\n\t\t\t});\n\t\t} else if (data.stream === undefined) {\n\t\t\tmyStreamers.filter(function(x){\n\t\t\t\tif(x.name === arg.name) {\n\t\t\t\t\tx[\"state\"] = \"Closed\";\n\t\t\t\t\tli.innerHTML = arg.name;\n\t\t\t\t\tli.appendChild(span);\n\t\t\t\t\tspan.className = \"closed\";\n\t\tlist.appendChild(li);\n\t\t\t\t};\n\t\t\t});\n\t\t} else {\n\t\t\tmyStreamers.filter(function(x){\n\t\t\t\tif(x.name === arg.name) {\n\t\t\t\t\tx[\"state\"] = \"Online\";\n\t\t\t\t\tli.innerHTML = arg.name;\n\t\t\t\t\tli.appendChild(span);\n\t\t\t\t\tlist.appendChild(li);\n\t\t\t\t\tspan.className = \"online\";\n\t\t\t\t};\n\t\t\t});\n\t\t};\n\t});\n}", "setChannelName (callback) {\n\t\t// since posting to any stream other than the team stream is no longer allowed,\n\t\t// just listen on the team channel\n\t\tthis.channelName = `team-${this.team.id}`;\n\n\t\t/*\n\t\t// team channel for file-type streams, or team-streams, otherwise the stream channel\n\t\tif (this.type === 'file' || this.isTeamStream) {\n\t\t\tthis.channelName = `team-${this.team.id}`;\n\t\t}\n\t\telse {\n\t\t\tthrow 'stream channels are deprecated';\n\t\t\t//this.channelName = `stream-${this.stream.id}`;\n\t\t}\n\t\t*/\n\t\t\n\t\tcallback();\n\t}", "function displayStreamersData() {\n\t\t\t\t// foreach streamer get info from api\n\t\t\t\tstreamers.forEach(function (streamerName) {\n\t\t\t\t\tgetStreamerData(streamerName);\n\t\t\t\t});\n\t\t\t}", "function addStream(number_in_object){\n \n var parent = document.getElementById('twitch-streams');\n var stream = document.createElement('DIV');\n var logo = document.createElement('IMG');\n var titleSpan = document.createElement('SPAN');\n var statusSpan = document.createElement('SPAN');\n \n\n if (data[number_in_object]['stream'] === null){ //if 'stream's value is 'null', the stream is offline\n \n \n stream.setAttribute('class', 'stream offline');\n stream.setAttribute('style', 'background-color: pink;');\n\n \n logo.src = 'https://t4.ftcdn.net/jpg/00/98/90/15/500_F_98901583_gAZzkuebkMSqdrRa7Qfq94Vrv9Heqn0N.jpg'\n logo.setAttribute('class', 'logo-class');\n \n titleSpan.innerHTML = \"<a href='\" + \"https://www.twitch.tv/\" + data[number_in_object]['display_name'] + \"' target='_blank'>\" + data[number_in_object]['display_name'] +\"</a>\";\n titleSpan.setAttribute('class', 'title-span-class');\n \n statusSpan.innerHTML = \"Offline\";\n statusSpan.setAttribute('class', 'status-span-class');\n \n \n stream.appendChild(logo); \n stream.appendChild(titleSpan);\n stream.appendChild(statusSpan);\n parent.appendChild(stream);\n \n } else if (data[number_in_object]['status'] === 404){ //channel does not exist\n \n stream.setAttribute('class', 'stream');\n stream.setAttribute('style', 'background-color: #DB3A34;');\n \n\n logo.src = \"https://image.freepik.com/free-icon/sad-sleepy-emoticon-face-square_318-58580.jpg\";\n logo.setAttribute('class', 'logo-class');\n \n\n titleSpan.innerHTML = data[number_in_object]['message'];\n titleSpan.setAttribute('class', 'title-span-class');\n \n stream.appendChild(logo);\n stream.appendChild(titleSpan);\n parent.appendChild(stream);\n \n } else { //chanel does exist and stream is online\n\n stream.setAttribute('class', 'stream online');\n stream.setAttribute('style', 'background-color: lightblue;');\n \n logo.src = data[number_in_object]['stream']['logo'];\n logo.setAttribute('class', 'logo-class');\n \n titleSpan.innerHTML = \"<a href='\" + data[number_in_object]['stream']['url'] + \"' target='_blank'>\" + data[number_in_object]['stream']['display_name'] +\"</a>\";\n titleSpan.setAttribute('class', 'title-span-class');\n\n statusSpan.innerHTML = data[number_in_object]['stream']['status'];\n statusSpan.setAttribute('class', 'status-span-class');\n\n stream.appendChild(logo);\n stream.appendChild(titleSpan);\n stream.appendChild(statusSpan);\n parent.appendChild(stream);\n }\n}", "function onChannelUpdate(channelID, username, title, game, data, partnered) {\r\n // Stream Title Update\r\n if (data.name !== undefined) {\r\n var wcTitle = data.name;\r\n\r\n var currentTitle = $('#' + channelID + ' .cTitle').text();\r\n if (currentTitle != wcTitle) {\r\n $('#' + channelID + ' .cTitle').text(wcTitle);\r\n }\r\n }\r\n\r\n // Stream Game Update\r\n if (data.type !== undefined) {\r\n var wGame = data.type.name;\r\n // Channel Game\r\n var currentGame = $('#' + channelID + ' .cGame').text();\r\n if (currentGame != wGame) {\r\n $('#' + channelID + ' .cGame').text(wGame);\r\n }\r\n }\r\n\r\n // Follower gained\r\n // This works by storing the follower numbers on the stream div, then checking to see if the new follower number from the websocket went up.\r\n // If it did then it will show an alert, otherwise a follower was lost and nothing will happen.\r\n if (data.numFollowers !== undefined && data.numFollowers > $('#' + channelID).attr('followers')) {\r\n var channelDiv = $('#' + channelID + ' .stream-notice');\r\n $(channelDiv).text('New Follower!');\r\n $(channelDiv).addClass('follower');\r\n $.when($(channelDiv).fadeIn('fast').delay(8000).fadeOut('fast')).done(function() {\r\n $(channelDiv).removeClass('follower');\r\n });\r\n\r\n // Adjust follower number so only positive changes are showed.\r\n var currentValue = parseInt($('#' + channelID).attr('followers'), 10);\r\n var newValue = currentValue + 1;\r\n $('#' + channelID).attr('followers', newValue);\r\n if ($('.notification-sound-input').prop('checked') === true) {\r\n $('.follower-sound')[0].play();\r\n }\r\n }\r\n\r\n // Cleanup Bot\r\n // Runs on every websocket response to add or remove people.\r\n if (data.online !== undefined && $('.cleanup').prop('checked') === true) {\r\n var onlineStatus = data.online;\r\n if (onlineStatus === false) {\r\n // If offline response recieved then fade the channel out and remove it.\r\n $('#' + channelID).fadeOut(500, function() {\r\n $(this).remove();\r\n });\r\n }\r\n } else if (data.online !== undefined && $('.cleanup').prop('checked') === false) {\r\n if (onlineStatus === false) {\r\n // If autolurk isn't checked and a channel goes offline the streamer name should turn gray.\r\n $('#' + channelID + ' h2').addClass('offline');\r\n } else {\r\n // Otherwise it should change back to default.\r\n $('#' + channelID + ' h2').removeClass('offline');\r\n }\r\n }\r\n}", "function genereateList() {\n channels.forEach(function(channel) {\n twitchAPI(channel);\n });\n}", "toUserId(id) {\n return id % constants.CHANNEL.ID_START;\n }", "setChannelName (callback) {\n\t\t// when posted to a team stream, it is the team channel\n\t\tthis.channelName = `team-${this.team.id}`;\n\t\tcallback();\n\t}", "streamingStart( subscriber ) {\n var id = this.getClientId(subscriber);\n console.log(\"Stream started for client \"+id)\n for ( var i = 0; i < this.clients.length; i++) {\n var client = this.clients[i];\n if ( client.id == id ) {\n // matched\n this.attachAudioStream(client.streamToMesh, this.getStream(subscriber));\n //this.clients.splice(i,1); // too eager, we may need to keep it for another stream\n console.log(\"Audio/video stream started for avatar of client \"+id)\n this.attachVideoStream(client, subscriber);\n break;\n }\n }\n this.subscribers.push(subscriber);\n }", "handleTeamChat(data) {\n if (data.team === \"red\") {\n for (let i = 0; i < this.redTurnOrder.length; i++) {\n super.sendDataToPlayer(this.redTurnOrder[i], {\n event: \"team-chat\",\n message: data.message,\n });\n }\n }\n if (data.team === \"blue\") {\n for (let i = 0; i < this.blueTurnOrder.length; i++) {\n super.sendDataToPlayer(this.blueTurnOrder[i], {\n event: \"team-chat\",\n message: data.message,\n });\n }\n }\n }", "function streamTweetsForUserId () {\n const stream = bot.stream('statuses/filter', { follow: '191100226'})\n\n stream.on('tweet', (tweet) => {\n console.log(tweet.text + '\\n')\n })\n}", "function renderRemote(id, stream) {\n var activeStreams;\n\n // create the peer videos list\n peerMedia[id] = peerMedia[id] || [];\n\n activeStreams = Object.keys(peerMedia).filter(function(id) {\n return peerMedia[id];\n }).length;\n\n console.log('current active stream count = ' + activeStreams);\n peerMedia[id] = peerMedia[id].concat(media(stream).render(remotes[activeStreams % 2]));\n}", "sendMessage(){\n\n let subscriptions = App.cable.subscriptions.subscriptions\n let index;\n for (let i = 0; i < subscriptions.length; i++){\n let identifier = JSON.parse(subscriptions[i].identifier)\n if (identifier.channel === \"ChatChannel\"){\n index = i\n break\n }\n }\n\n let message = {\n channel_dms_id: this.props.searchDmId,\n content: this.state.content,\n sender_id: this.state.creatorId,\n created: true\n }\n \n App.cable.subscriptions.subscriptions[index].speak({ message: message})\n this.setState({\n content: \"\"\n })\n this.props.history.push(`/client/${this.props.searchDmId}`)\n }", "function renderTwitchUser(ctx) {\n\t\t\t\t\t$streamersContainer.append(streamerTmpl(context));\n\t\t\t\t}", "pusher_subscription_counter_part(channel_name) {\n\n const {email} = this.props.user;\n var channel = pusher.subscribe(channel_name);\n console.log(channel_name);\n\n channel.bind('my_event', function(data) {\n console.log(data);\n console.log('data at pusher subscription counter part..');\n if (data != null) {\n if (data.sender_email === email.toLowerCase()) {\n\n } else {\n if (data.message != null){\n console.log('data');\n console.log(data);\n //converting data to object that fits to the model.\n const object = {sender_email: data.sender_email, sender_first_name: data.sender_first_name, text:data.message, date: data.date};\n console.log(object);\n\n this.props.appendMessageCounterPart(object);\n }\n }\n }\n }.bind(this));\n }", "streamTweets(filter) {\r\n const s = this.T.stream('statuses/filter', filter);\r\n\r\n s.on('tweet', (tweet) => {\r\n console.log(\"Caught Tweet\");\r\n\r\n this.userid = tweet.user.id_str;\r\n this.getThread(tweet);\r\n })\r\n }", "function getFollowers(val){\n\n\trequest({url: val,headers:{'Client-ID': clientid}}, (err, res, body) => {\n\t var streamers = [];\n\n\t\tif(!err && res.statusCode === 200){\n\t\t\tdata = JSON.parse(body);\n\n\t\t\tdata.follows.forEach(function(val){\n\t\t\t\tstreamers.push(val.channel.name);\n\t\t\t})\n\n\t\t\t//console.log(streamers);\n\t\t\t//streamers.sort();\n\t\t\t//showText();\n\t\t\tstreamers.forEach( (val) => display(val));\n\t\t}\n\t})\n}", "function checkstreams(chanid, elm){\n qrystring = \"https://wind-bow.gomix.me/twitch-api/streams/\" + chanid + \"?callback=?\";\n $.getJSON(qrystring,function(result){\n console.log(result);\n if(result.stream == null){\n $(elm).parent().append(\"<p>Sorry, not streaming right now.</p>\");\n $(elm).parent().addClass(\"offline\");\n if($(elm).parent().hasClass(\"fcc\")){ //special option for fcc button\n $(elm).parent().append(\"<p>Try one of these other channels</p>\")\n $(\".others\").slideDown(\"slow\",function(){\n //animation complete, do nothing\n })\n }\n }else{\n $(elm).parent().addClass(\"streaming\");\n //Show collapse button, hide query button\n $(elm).parent().find('.collapse').show();\n $(elm).hide();\n\n //build everything you want to append\n var streamdiv = \"\";\n //Nest image inside anchor linked to stream url\n var imgadd = '<a href=' + result.stream.channel.url + ' target=\"_blank\"><img src='+ result.stream.channel.logo + '></a>'\n //loop through 4 keys named in this array and grab values for stream info\n var infofields = [\"game\",\"created_at\",\"stream_type\",\"viewers\"];\n var paradd = \"\";\n infofields.forEach(function(val){\n paradd +=\"<p>\" + val + \": \" + result.stream[val] + \"</p>\";\n });\n streamdiv = \"<div class='strmdetails'>\" + imgadd + \"<div>\" + paradd + \"</div></div>\";\n\n $(elm).parent().append(streamdiv);\n $(elm).parent().find('.strmdetails').slideDown();\n }\n });\n }", "async createTeamStream () {\n\t\tlet stream = {\n\t\t\tteamId: this.attributes.id,\n\t\t\ttype: 'channel',\n\t\t\tname: 'general',\n\t\t\tisTeamStream: true\n\t\t};\n\t\tthis.transforms.createdTeamStream = await new StreamCreator({\n\t\t\trequest: this.request,\n\t\t\tnextSeqNum: this.assumeTeamStreamSeqNum || undefined\n\t\t}).createStream(stream);\n\t}", "async channels(sender) {\n let channels = await slack.getAllChannels()\n channels = _.orderBy(channels, ['name'], ['asc'])\n const bundle = channels.map((c) => {\n if (c.is_archived || c.is_im || c.is_mpim) {\n return\n }\n let type = 'public'\n if (c.is_private || c.is_group) {\n type = 'private'\n }\n if (c.is_general) {\n type = 'general'\n }\n return `${c.name} | ${c.id} | ${type} | ${c.num_members || 0}`\n })\n bundle.unshift(`Name | ChannelId | Type | Members`)\n await slack.postEphemeral(sender, bundle.join('\\n'))\n }", "getChannelID(activeChannel) {\n const channels = this.state.channels;\n let channelID;\n for (let i = 0; i < channels.length; i++) {\n const channel = channels[i];\n if (channel.name === activeChannel) {\n channelID = channel.id;\n break;\n }\n }\n return channelID;\n }", "toChannelId(id, type = constants.ChannelType.FreeChat) {\n id = this.toUserId(id);\n switch (type) {\n case constants.ChannelType.FreeChat:\n id = id + (this._options.camYou ? constants.CAMCHAN.ID_START : constants.CHANNEL.ID_START);\n break;\n case constants.ChannelType.NonFreeChat:\n id = id + constants.SESSCHAN.ID_START;\n break;\n default:\n throw new Error(`toChannelId doesn't understand this channel type: ${type}`);\n }\n return id;\n }", "function makeNewPeers(\n socket,\n roomName,\n peers,\n participants,\n myName,\n videoRefs,\n chatBoardRef,\n stream,\n toastHandler,\n peerStreams\n) {\n // find receivers\n let newPeers = Object.keys(participants);\n newPeers = newPeers.filter((x) => x !== myName);\n // make peers\n newPeers.forEach((userName) => {\n // initiate video reference\n let videoRef = React.createRef();\n videoRefs[userName] = videoRef;\n // make peer connection\n let p = new Peer(optsInit);\n p.on(\"signal\", (data) => {\n socket.emit(\n \"RTC_offer\",\n JSON.stringify(data),\n myName,\n userName,\n roomName\n );\n });\n p.on(\"connect\", () => {\n console.log(\"connected\");\n });\n p.on(\"stream\", (stream) => {\n peerStreams[userName] = stream;\n if (\"srcObject\" in videoRef.current) {\n videoRef.current.srcObject = stream;\n } else {\n videoRef.current.src = window.URL.createObjectURL(stream);\n }\n });\n p.on(\"data\", (data) => {\n let newText = new TextDecoder(\"utf-8\").decode(data);\n chatBoardRef.current.value = chatBoardRef.current.value + `${newText}\\n`;\n chatBoardRef.current.scrollTop = chatBoardRef.current.scrollHeight;\n toastHandler(newText);\n });\n p.on(\"error\", (err) => {\n console.log(err);\n });\n // add stream\n if (stream) {\n p.addStream(stream);\n }\n // store it to global variable\n peers[userName] = p;\n });\n}", "function streamNull(val, channel) {\n $(\"#results\").append(\n \"<div class='channelResults offline selected' id='\" +\n val.name +\n \"'><a href='https://www.twitch.tv/\" +\n val.name +\n \"' target='_blank'><div class='opacity'><img class='logo' src=\" +\n val.logo +\n \" ><h4 class='displayName'>\" +\n val.display_name +\n \"</h4><p class='status'>Offline</p></div></a><div class='led-red'></div></div>\"\n );\n }", "function startChannelStats() {\n stats = setInterval(() => {\n ApiHandle.getStats().then(data => {\n if (data == null) { // They are not live or the channel doesn't exist.\n console.log(\"The user is not live or there was an error getting stats.\")\n } else { // Sets the info from the request next to the icons on the chat page.\n if (data.channel.stream.countViewers !== undefined && data.channel.stream.countViewers !== null) {\n document.getElementById(\"fasUsers\").innerHTML = `<span><i class=\"fas fa-users\"></i></span> ${data.channel.stream.countViewers}`\n }\n if (data.followers.length !== undefined && data.followers.length !== null) {\n document.getElementById(\"fasHeart\").innerHTML = `<span><i class=\"fas fa-heart\"></i></span> ${data.followers.length}`\n }\n if (data.channel.stream.newSubscribers !== undefined && data.channel.stream.newSubscribers !== null) {\n document.getElementById(\"fasStar\").innerHTML = `<span><i class=\"fas fa-star\"></i></span> ${data.channel.stream.newSubscribers}`\n }\n }\n })\n }, 900000);\n}", "messagePlayers(message) {\n message = JSON.stringify(message);\n if (this.player1) this.player1.ws.send(message);\n if (this.player2) this.player2.ws.send(message);\n for (let i = this.spectators.length - 1; i >= 0; i--) {\n if (this.spectators[i].ws) {\n this.spectators[i].ws.send(message);\n } else {\n this.spectators.splice(i, 1);\n }\n }\n }", "function enumerateChannels() {\n ably.request('get', '/channels', { limit: 100, by: 'id' }, null, null, function(err,res){\n res.items.forEach(chan => {\n ably.request('get', '/channels/'+chan, { limit: 100, by: 'id' }, null, null, function(err,res2){\n chans.names[chans.names.length] = chan;\n chans.conns[chans.names.length] = res2.items[0].status.occupancy.metrics.connections;\n count++;\n });\n });\n }); \n}", "function getHostInfo() {\n $.ajax({\n type: 'GET',\n url: 'https://api.twitch.tv/kraken/streams/' + data.hosts[0].target_login,\n headers: {\n 'Client-ID': 'f2cmg4s30fnzmq7zbcx8rcsfxdc1san'\n },\n success: function(data) {\n console.log(data);\n if (data.stream) {\n $(\"#title\").text(\"Panda is currently hosting \" + data.stream.channel.display_name);\n $(\"#streaminfo\").text(data.stream.channel.status);\n chatSrc = \"https://www.twitch.tv/\" + data.stream.channel.name + \"/chat\";\n }\n else streamOffline();\n }\n });\n\n\n }", "function fetchChannels() {\n const top = async (total) => {\n const pages = Math.ceil(total / 100);\n results = [];\n channels = [];\n\n const args = \" -H 'query: username' -H 'history: default' -H 'clientid: \" + 'cli_f0d30ff74a331ee97e486558' +\n \"' -H 'token: \" + '7574a0b5ff5394fd628727f9d6d1da723a66736f3461930c79f4080073e09e349f5e8e366db4500f30c82335aa832b64b7023e0d8a6c7176c7fe9a3909fa43b7' +\n \"' -X GET https://matrix.sbapis.com/b/youtube/statistics\";\n\n for (let index = 0; index < pages; index++) {\n results.push(await client.youtube.top('subscribers', index + 1));\n }\n\n for (let page_index = 0; page_index < results.length; page_index++) {\n for (let index = 0; index < results[page_index].length; index++) {\n channel = results[page_index][index];\n channel['grade'] = \"N/A\";\n// channel_args = args;\n// exec('curl ' + channel_args.replace(\"username\",channel['id']['username']), function (error, stdout, stderr) {\n// console.log('stdout: ' + stdout)\n// if (stdout != null && stdout['data'] != undefined && stdout['data']['misc'] != undefined\n// && stdout['data']['misc']['grade'] != undefined && stdout['data']['misc']['grade']['grade'] != undefined) {\n// channel['grade'] = stdout['data']['misc']['grade']['grade'];\n// } else {\n// channel['grade'] = '';\n// }\n// console.log('stderr: ' + stderr);\n// if (error !== null) {\n// console.log('exec error: ' + error);\n// }\n// });\n channels.push(channel);\n }\n }\n\n var file = fs.createWriteStream('output.csv');\n file.write(\"id, username, display_name, created_at, channel_type, country, uploads, subscribers, views\" + \"\\n\");\n file.on('error', function(err) { /* error handling */ });\n channels.forEach(function(channel) {\n file.write(channel['id']['id'] + \", \" + channel['id']['username'] + \", \" + channel['id']['display_name'] + \", \"\n + channel['general']['created_at'] + \", \" + channel['general']['channel_type'] + \", \" + channel['general']['geo']['country'] + \", \"\n + channel['statistics']['total']['uploads'] + \", \" + channel['statistics']['total']['subscribers'] + \", \" + channel['statistics']['total']['views'] + \"\\n\");\n });\n\n file.end();\n\n return results;\n};\n\n top(500).then(\"done\").catch(console.error);\n}", "function App() {\n\n const [users, setUsers] = useState([])\n const [s , setS] = useState('');\n useEffect(()=>{\n signalingChannel.on('users', (data)=>{\n setUsers(data.users);\n })\n signalingChannel.on('self', (data)=>{\n setS(data.self);\n })\n signalingChannel.on('offer', (data)=>{\n answerCall(data.offer, data.from);\n })\n }, [])\n return (\n <div className=\"App\">\n <header className=\"App-header\">\n <div>\n {users.map(u=><button onClick = {()=>makeCall(u)}>{u}</button>)}\n </div>\n <div>\n self : {s}\n </div>\n \n </header>\n </div>\n );\n}", "async function channelsOnline() {\n try {\n\n // console.log('Running Online Check');\n let db = global.db;\n let joinedChannels = await db.channel_settings.find({ joined: true });\n let channelList = [];\n let channelReturn;\n let currentTimers = TIMERS.showTimers();\n let onlineChannels = [];\n \n\n for (let channel in joinedChannels) {\n channelList.push(joinedChannels[channel].broadcaster);\n }\n \n channelReturn = await channelCheck(channelList);\n channelReturn = channelReturn['streams'];\n\n for (let channel in channelReturn) {\n let pushThis = channelReturn[channel]['channel']['name'];\n pushThis = '#' + pushThis;\n onlineChannels.push(pushThis);\n }\n \n for (let channel in currentTimers) {\n if (currentTimers.hasOwnProperty(channel)) {\n let lastShownOnline = currentTimers[channel].online;\n let currentlyOnline = onlineChannels.includes(channel);\n\n // If channel is now online\n if (!lastShownOnline && currentlyOnline) {\n console.log(`${channel} is now online.`);\n TIMERS.changeOnlineStatus(channel);\n } \n // If channel has gone offline\n else if (lastShownOnline && !currentlyOnline) {\n console.log(`${channel} is now offline.`);\n TIMERS.changeOnlineStatus(channel);\n }\n }\n }\n } catch (err) {\n console.log('channelsOnline Error:');\n if (err.statusCode === 500) {\n console.log('Twitch Returned a 500 service error.');\n } else {\n console.log(err);\n }\n }\n}", "function getInfo() {\n list.forEach(function(channel) {\n function makeURL(type, name) {\n return 'https://wind-bow.gomix.me/twitch-api/' + type + '/' + name + '?callback=?';\n };\n\n //Get logo, name, and display name from \"users\" URL\n $.getJSON(makeURL(\"users\", channel), function(data) {\n var logo = data.logo;\n var displayName = data.display_name;\n var name = data.name;\n\n //Get status and game from \"streams\" URL\n $.getJSON(makeURL(\"streams\", channel), function(data2) {\n if (data2.stream === null) {\n status = \"OFFLINE\";\n game = \"\";\n }\n\n if (data2.stream) {\n status = \"ONLINE\";\n game = data2.stream.game;\n }\n\n html = '<div class=\"box\"><div><img src=\"' + logo + '\" class=\"logoSize\" alt=\"Logo\"></div><div class=\"nameSize\"><a href=\"' + \"https://go.twitch.tv/\" + name + '\" target=\"_blank\">' + displayName + '</a></div>' + '<a href=\"' + \"https://go.twitch.tv/\" + name + '\" target=\"_blank\"><div class=\"statusSize\">' + status + '</div><div class=\"gameSize\">' + game + '</div></a></div>';\n\n $(\"#display\").prepend(html);\n\n //Add online users to \"onlines\" variable\n if (data2.stream) {\n onlines.push(html);\n }\n\n //Add offline users to \"offlines\" variable\n if (data2.stream === null) {\n offlines.push(html);\n }\n\n $(\"#all\").click(function() {\n $(\"#display\").empty();\n $(\"#display\").prepend(onlines);\n $(\"#display\").prepend(offlines);\n $(\"#offline\").removeClass(\"active\");\n $(\"#online\").removeClass(\"active\");\n $(\"#all\").addClass(\"active\");\n });\n\n $(\"#online\").click(function() {\n $(\"#display\").empty();\n $(\"#display\").prepend(onlines);\n $(\"#offline\").removeClass(\"active\");\n $(\"#all\").removeClass(\"active\");\n $(\"#online\").addClass(\"active\");\n });\n\n $(\"#offline\").click(function() {\n $(\"#display\").empty();\n $(\"#display\").prepend(offlines);\n $(\"#all\").removeClass(\"active\");\n $(\"#online\").removeClass(\"active\");\n $(\"#offline\").addClass(\"active\");\n });\n }); //End second getJSON\n }); //End first getJSON\n }); //End list.forEach(function(channel))\n}", "function getDirectChannelIdByName(channels, users) {\n return _.transform(channels, (result, channel, id) => {\n result[users[channel.userId].username] = channel.id\n })\n}", "static toUserId(id) {\n return id % constants.CHANNEL.ID_START;\n }", "function startStream() {\n\n $('#startbroadcast').prop('disabled', true);\n $('#shopButton').prop('disabled', true);\n $('#buygpu').prop('disabled', true);\n $('#buycpu').prop('disabled', true);\n $('#startbroadcast').text('Stop Stream');\n $('#startbroadcast').addClass('btn-danger').removeClass('btn-success');\n followersJoining = true;\n broadcasting = true;\n currentviewers += 1;\n //make followers join first\n followersJoin();\n $(\"#onlinechecker\")\n .fadeOut(200, function () {\n $(\"#onlinechecker\").text('LIVE');\n })\n .fadeIn(200);\n topDonors = [];\n for (var i = 0; i < 10; i++) {\n\n $(\"#\" + i).text(\"N/A\");\n\n\n }\n\n}", "@track((undefined, state) => {\n return {action: `enter-attempt-to-channel: ${state.channel.name}`};\n })\n enterChannel(channel){\n\n let addNewMessage = this.props.addNewMessage;\n let updateMessage = this.props.updateMessage;\n\n sb.OpenChannel.getChannel(channel.url, (channel, error) => {\n if(error) return console.error(error);\n\n channel.enter((response, error) => {\n if(error) return console.error(error);\n\n //set app store to entered channel\n this.props.setEnteredChannel(channel);\n //fetch the current participantList to append\n this.fetchParticipantList(channel);\n //fetch 30 previous messages from channel\n this.fetchPreviousMessageList(channel);\n });\n });\n }", "setChannelName (callback) {\n\t\t// marker location messages come to us on the team channel\n\t\tthis.channelName = `team-${this.team.id}`;\n\t\tcallback();\n\t}", "function joinToChannel() {\n console.log(\"join to channel\", roomId);\n \n // store the room info to my meetings\n // if room does not exist set the whole info\n // if room exists update timestamp and date (to track for the recent call made) \n const mymeetings = firestore.collection(`${myName}`).doc(`${roomId}`);\n const snapshot = mymeetings.get();\n let date = new Date().toString().slice(0,-34);\n let timestamp = Date.now();\n if (!snapshot.exists) {\n try {\n mymeetings.set({ roomId, timestamp, date, roomName, createdBy });\n } catch (err) {\n console.log(err);\n }\n }\n else{\n try {\n mymeetings.update({'timestamp':timestamp, 'date':date });\n } catch (err) {\n console.log(err);\n }\n }\n socket.emit(\"join\", { channel: roomId, peerName: myName, peerVideo: myVideoStatus, peerAudio: myAudioStatus, peerHand: myHandStatus, });\n}", "function watchActivePeerChatRoom(action) {\n var receiverId, authedUser, uid;\n return _babel_runtime_regenerator__WEBPACK_IMPORTED_MODULE_1___default.a.wrap(function watchActivePeerChatRoom$(_context9) {\n while (1) {\n switch (_context9.prev = _context9.next) {\n case 0:\n receiverId = action.payload.receiverId;\n _context9.next = 3;\n return Object(redux_saga_effects__WEBPACK_IMPORTED_MODULE_8__[\"select\"])(_store_reducers_authorize_authorizeSelector__WEBPACK_IMPORTED_MODULE_12__[\"authorizeSelector\"].getAuthedUser);\n\n case 3:\n authedUser = _context9.sent;\n uid = authedUser.get('uid');\n\n if (!uid) {\n _context9.next = 15;\n break;\n }\n\n _context9.prev = 6;\n _context9.next = 9;\n return Object(redux_saga_effects__WEBPACK_IMPORTED_MODULE_8__[\"call\"])(activePeerChatRoom, receiverId);\n\n case 9:\n _context9.next = 15;\n break;\n\n case 11:\n _context9.prev = 11;\n _context9.t0 = _context9[\"catch\"](6);\n _context9.next = 15;\n return Object(redux_saga_effects__WEBPACK_IMPORTED_MODULE_8__[\"put\"])(_store_actions_globalActions__WEBPACK_IMPORTED_MODULE_11__[\"showMessage\"](_context9.t0.message));\n\n case 15:\n case \"end\":\n return _context9.stop();\n }\n }\n }, _marked9, null, [[6, 11]]);\n}", "function viewers(room) {\n const sockets = io.sockets.clients(room);\n const data = sockets.map(function(socket) { return socket.id; });\n if (data.length) io.sockets.in(room).emit('viewers', data);\n}", "sub(streams){\n this.socket.on('open',async ()=>{\n await this.checkGrantAccessAndQuerySessionInfo()\n this.subRequest(streams, this.authToken, this.sessionId)\n this.socket.on('message', (data)=>{\n // log stream data to file or console here\n // console.log(JSON.parse(data))\n // console.log(this.data.length)\n this.data.push(JSON.parse(data))\n })\n })\n }", "async function getDiscordChannels(twitchName) {\n\n try {\n \n let pairsArray = await db.announcerGetIdPairs(twitchName.toLowerCase());\n let discordChannels = pairsArray.map(pair => {\n return getDiscordChannel(pair);\n });\n \n return discordChannels;\n\n } catch (error) {\n\n console.log('Error in getDiscordChannels()', error);\n return null;\n\n }\n\n}", "function sendPlayerDetails(player) {\n\n var sessionID = player.sessionID;\n console.log(player.params.name);\n \n io.sockets.sockets[sessionID].emit('loadPlayerDetails', player);\n return;\n}", "joindreGroupe(socket,channel,username){\n $(\"#listDesMessages\").empty();\n $(\"#msgBox\").focus();\n var msg = new Message(\"onJoinChannel\", channel.id , null , username, null );\n socket.send(JSON.stringify(msg));\n document.getElementById(\"current_group_name\").innerHTML = channel.name;\n }", "get broadcasterId() {\n return this._data.broadcaster_id;\n }", "function search(a){\n var size = a.length\n var name = null;\n \n for(i=0; i<size; i++){\n name = a[i];\n var xhr = new XMLHttpRequest();\n xhr.onreadystatechange = function (){\n if(this.readyState == 4 && this.status == 200){\n var r = JSON.parse(this.responseText); \n if(r.stream != null){ \n display(r.stream.channel.logo, 1, r.stream.channel.url, r.stream.channel.display_name, r.stream.channel.status);\n }\n else if (r.stream == null){\n var link = r._links.channel.slice(38, r._links.channel.length); ///have to use slice since non-streaming channels only return links that would work with a API key\n var xhr = new XMLHttpRequest();\n xhr.open(\"GET\", \"https://wind-bow.glitch.me/twitch-api/channels/\" + link, true); /// all these calls occur after all orginal calls have taken place thats why have to use link\n xhr.send();\n xhr.onreadystatechange = function (){\n if(this.readyState == 4 && this.status == 200){\n var r = JSON.parse(this.responseText);\n console.log(r);\n display(r.logo, 0, r.url, r.display_name, \"\");\n }\n else{\n console.log(\"Error\", xmlhttp.statusText)\n }\n } \n } \n }\n else{\n console.log(\"Error\", xmlhttp.statusText) \n }\n };\n xhr.open(\"GET\", \"https://wind-bow.glitch.me/twitch-api/streams/\" + name, true); \n xhr.send();\n }\n}", "broadcastToSockets(channel, data) {\n const socketSubscribed = this.socketsPerChannels.get(channel) || new Set();\n\n socketSubscribed.forEach(client => {\n client.send(data);\n });\n }", "function processTwitchRequest(data) {\n var twitchRequest = https.get(twitchAPI + data.twitchUsername, function(res) {\n var twitchData = '';\n /* Append the twitch stream data */\n res.on('error', function(err) {\n handleResponseError(err);\n });\n res.on('data', function(twitchInfo) {\n twitchData += twitchInfo;\n });\n /* Handle if a streamer is on or offline */\n res.on('end', function() {\n var parsedTwitchData = JSON.parse(twitchData);\n mongoClient.connect(database, function(err, db) {\n if(err) {\n /* Handle the error */\n handleDbError(err);\n }\n var collection = db.collection(dbOnline);\n /* Make a function to close the database. This way the db can be closed from the parent scope when we KNOW\n the children are done. */\n function closeDb() {\n db.close();\n }\n /* User is online and playing League. See if they need to be added to the \"Online\" database */\n if(parsedTwitchData._total > 0 && parsedTwitchData.streams[0].game == lolGame) {\n /* use the data from twitch to see if this user is already in the \"Online\" database */\n var onlineCursor = collection.find({twitchUsername: parsedTwitchData.streams[0].channel.display_name});\n onlineCursor.nextObject(function(err, item) { \n if(err) {\n /* Handle the error */\n handleCursorError(err);\n }\n /* They are already in the \"Online\" database. Do nothing */\n if(item != null) {\n /* TODO: make a priority queue and give this twitch streamer the lowest priority */\n }\n /* item is null. The user just came online, add them to the \"Online\" database */\n else {\n collection.insert(data);\n }\n closeDb();\n });\n }\n /* The user is not online or not playing League. Remove them from the \"Online\" database */\n else {\n collection.remove(data);\n closeDb();\n }\n });\n });\n });\n}", "get broadcasterId() {\n return this._data.broadcaster_user_id;\n }", "get broadcasterId() {\n return this._data.broadcaster_user_id;\n }", "get broadcasterId() {\n return this._data.broadcaster_user_id;\n }", "function getSummonerNames() {\n mongoClient.connect(database, function(err, db) {\n if(err) {\n /* Handle the error */\n handleDbError(err);\n }\n var docs = [];\n /* Keeps track of how long to delay the next lookup in accordance to Riot's API ToS */\n var namesRead = 0;\n var collection = db.collection(dbOnline);\n var playersCursor = collection.find();\n playersCursor.toArray(function(err, documents) {\n if(err) {\n /* Handle the error */\n handleCursorError(err);\n }\n /* Ensure that the database resource is freed only after the \n * entire cursor has been iterated through*/\n var docs = documents.length;\n /* End of the line */\n function checkDocOff() {\n docs--;\n if(docs == 0) {\n db.close();\n }\n }\n /* For each twitch streamer that is ONLINE */\n for(var y = 0; y < documents.length; y++) {\n /* For each lolAccount this user has */\n for(var b = 0; b < documents[y].lolAccounts.length; b++) {\n /* increment namesRead to keep track of how much delay a specific lolAccount lookup needs */\n namesRead += 1;\n /* Query live game data using Riot API. some delay due to Riot API ToS */\n (function(delay, playerDoc, lolAccount) {\n setTimeout(function() {\n checkIfInGame(playerDoc, lolAccount);\n }, (delay)*apiDelay);\n checkDocOff();\n })(namesRead, documents[y], documents[y].lolAccounts[b]);\n }\n }\n });\n });\n}", "on_connecter() {\n this.enregistrerChannel()\n }", "function stopScreenShare() {\n let videoTrack = myVideoStream.getVideoTracks()[0];\n for (let x = 0; x < currentPeer.length; x++) {\n let sender = currentPeer[x].getSenders().find(function (s) {\n return s.track.kind == videoTrack.kind;\n })\n sender.replaceTrack(videoTrack);\n }\n}", "function user_chats(name){\n //clear any current channel from the local storage\n localStorage.setItem('channel', null);\n const request = new XMLHttpRequest();\n request.open('POST', '/direct');\n request.onload = () => {\n const data = JSON.parse(request.responseText);\n //now, we crate a unique indentifier for every private chat,\n //which is the length of the two names of the chatting people\n let all_names = data.current + data.other;\n localStorage.setItem('id', all_names.length);\n localStorage.setItem('name', name);\n //clear nav about any channel aspects\n document.querySelector('#current-channel').innerHTML = '';\n document.querySelector('#users-number').innerHTML = '';\n\n //now get messages btn the two users\n get_user_messages(data);\n }\n const data = new FormData();\n data.append('name', name);\n request.send(data);\n }", "function middleify (callStream){\n dashboard.setState({ 'localStream': stream, 'currentCall': callStream, 'partner': partner });\n Meteor.users.update({_id: clientID}, {$set: {'profile.status': 'streaming', 'profile.streamId': stream.id}});\n callStream.on('stream', function(theirStream) {\n dashboard.toggleLoading(false);\n theirVideo.src = URL.createObjectURL(theirStream);\n myVideo.src = URL.createObjectURL(stream);\n dashboard.setPartner(theirStream.id);\n setTimeout(function(){endify(partner._id)}, 2000);\n });\n }", "function matchUser(client, agentId, calltransfer, mediatype) {\n\n //console.log(\"Matching AgentId : \" +agentId);\n\n\n for (var index = 0; index < users.length; index++) {\n\n if (users[index]['id'].trim() === agentId) {\n //console.log(\"Partners List length before \"+client['partners_list'].length);\n client['partners_list'].splice(0, 1);\n //console.log(\"Partners List length after \"+client['partners_list'].length);\n client['partners_list'].push(users[index]);\n console.log(\"Partners List \" + client['partners_list'][0]['name']);\n var partnersArrayLength = client['partners_list'].length;\n var partner = client['partners_list'][0];\n partner['partners_list'].splice(0, 1);\n partner['partners_list'].push(client);\n if (calltransfer == true) {\n partner['call_type'] = 'transfer';\n console.log(\"Client name is \" + client['name']);\n } else {\n partner['call_type'] = 'normal';\n }\n console.log(\"Client info during start call \" + JSON.stringify(client['id']));\n //console.log(\"Transfer type \"+calltransfer+\"Partner calltype\"+partner['call_type']);\n\n client['connection'].send(JSON.stringify({'type': Call_Events.CALL_CONNECT, 'call_type': partner['call_type'], 'name': partner['name'], 'id': partner['id'], 'media_type': mediatype}));\n\n partner['connection'].send(JSON.stringify({'type': 'will_call', 'name': client['name'], 'id': client['id'], 'media_type': mediatype}));\n break;\n //UpdateAgentStatus(agentId.trim(),Status.BUSY);\n }\n }\n}", "get broadcasterId() {\n return this._eventData.event_data.broadcaster_id;\n }", "async function updateWerewolfChannel(gameid, token) {\n let werewolves = await query({ role: \"werewolf\", status: \"alive\",gameid:gameid });\n let werewolfArray = [];\n werewolves.forEach(wolf => {\n werewolfArray.push(wolf.player);\n });\n const response = await app.client.conversations.open({\n token: token,\n return_im: false,\n users: werewolfArray.join()\n });\n console.log(response.channel.id);\n let gameTable = await queryOne({ datatype: \"game\",gameid:gameid });\n gameTable.werewolfChannel = response;\n await db.update({ datatype: \"game\",gameid:gameid }, gameTable);\n return response.channel.id;\n}", "static sendQue(socket) {\n var playerNames = Player.updateNames()\n for(var i in Player.list){\n var socket = SOCKET_LIST[i];\n //socket.emit('Players', socket.name, playerNames)\n console.log(playerNames)\n socket.emit('Players', socket.name, playerNames)\n }\n }", "function _assignChannel ()\n\t{\n\t\tvar id;\n\n\t\t_channelID += 1;\n\t\tid = _PREFIX_CHANNEL + _channelID;\n\t\treturn id;\n\t}", "function onExistingParticipants(msg) {\r\n\tuserId = msg.userId;\r\n\tvar iceServers = [\r\n\t\t{\r\n\t\t\turl: 'turn:' + turnUrl,\r\n\t\t\tusername: turnUsername,\r\n\t\t\tcredential: turnCredential\r\n\t\t}\r\n\t];\r\n\tlet videoConstraints = null;\r\n\tif (msg.videoOn === true) {\r\n\t\tif (reduceFramerateKurento===\"true\"){\r\n\t\t\tvideoConstraints = {\r\n\t\t\t\tframeRate: {\r\n\t\t\t\t\tmin: 2, ideal: 15, max: 30\r\n\t\t\t\t},\r\n\t\t\t\twidth: {\r\n\t\t\t\t\tmin: 50, ideal: 250, max: 640\r\n\t\t\t\t},\r\n\t\t\t\theight: {\r\n\t\t\t\t\tmin: 32, ideal: 250, max: 640\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t} else {\r\n\t\tvideoConstraints = false;\r\n\t}\r\n\r\n\tvar constraints = {\r\n\r\n\r\n\t\taudio: msg.audioOn,\r\n\t\tvideo: videoConstraints,\r\n\t\tconfigurations: {\r\n\t\t\ticeServers: iceServers\r\n\t\t}\r\n\r\n\t};\r\n\tconsole.log(userId + \" registered in room \" + roomId);\r\n\tvar participant = new Participant(name, userId, selfStream);\r\n\tparticipants[userId] = participant;\r\n\r\n\tvar options = {\r\n\t\tlocalVideo: selfStream,\r\n\t\tmediaConstraints: constraints,\r\n\t\tonicecandidate: participant.onIceCandidate.bind(participant),\r\n\r\n\r\n\t}\r\n\t//user connects to KMS\r\n\tparticipant.rtcPeer = new kurentoUtils.WebRtcPeer.WebRtcPeerSendonly(options,\r\n\t\tfunction (error) {\r\n\t\t\tif (error) {\r\n\t\t\t\t/*return*/\r\n\t\t\t\tconsole.error(error);\r\n\t\t\t}\r\n\t\t\tthis.generateOffer(participant.offerToReceiveVideo.bind(participant));\r\n\t\t\t//if user decided to turn his media devices off before the call has started\r\n\t\t\tif (audioBeforeEnterTheRoom === false) {\r\n\t\t\t\tremoveMediaTrack('audio');\r\n\t\t\t}\r\n\t\t\tif (videoBeforeEnterTheRoom === false) {\r\n\t\t\t\tremoveMediaTrack('video');\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t//user registers other users in this chat room\r\n\tmsg.data.forEach(receiveVideo);\r\n}", "connect() {\n if (!this.channels || this.channels.length < 1)\n return;\n this.channels.forEach((infos) => {\n let conn = new Mixer.ChatService(this.client).join(infos.id).then((response) => {\n let channel = new channel_1.Channel(this, infos.id, response.body);\n channel.connect();\n infos.channel = channel;\n }).catch((e) => {\n console.log(\"Cannot connect to channel #\" + infos.id);\n });\n });\n }", "function showStreamersByStatus() {\n\t\t\t\tvar id = $(this).attr('id');\n\t\t\t\tswitch(id) {\n\t\t\t\t\tcase 'all-streamers-btn':\n\t\t\t\t\t\t$('.active-streamer,.offline-streamer').show();\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'online-streamers-btn':\n\t\t\t\t\t\t$('.offline-streamer').hide();\n\t\t\t\t\t\t$('.active-streamer').show();\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'offline-streamers-btn':\n\t\t\t\t\t\t$('.active-streamer').hide();\n\t\t\t\t\t\t$('.offline-streamer').show();\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}", "function startLocalStream(){\n if(localStreamOn){ // check if this setup has already been done\n console.log('local stream already on');\n return;\n } else {\n localStreamOn = true;\n }\n\n var ctrl = window.ctrl = CONTROLLER(phone, get_xirsys_servers);\n ctrl.ready(function(){\n if(!faceTrackerStarted){\n startFaceTracker();\n faceTrackerStarted=true;\n }\n //Here we possibly want to minimise the user's screen\n //ctrl.addLocalStream(video);\n //addLog(\"Logged in as \" + form.username.value);\n });\n ctrl.receive(function(session){\n session.connected(function(session){\n sessionList.push(session);\n var listItem = document.createElement('li');\n listItem.id= \"callee\" +session.number;\n listItem.appendChild(session.video);\n othervideos.appendChild(listItem);\n //video_out.appendChild(session.video);\n var sessionRTCPeerConnection = session.pc;\n invokeGetStats(sessionRTCPeerConnection);\n //Adding button for kicking a session\n //var kickbtn = document.createElement(\"button\");\n //video_out.appendChild(kickbtn);\n //addLog(session.number + \" has joined.\");\n console.log(session.number + \" has joined.\");\n vidCount++; });\n\n session.ended(function(session) {\n var index = sessionList.indexOf(session);\n sessionList.splice(index,1);\n ctrl.getVideoElement(session.number).remove();\n var listItem = document.getElementById('callee'+session.number);\n listItem.outerHTML =\"\";\n delete listItem;\n //addLog(session.number + \" has left.\");\n console.log(session.number + \" has left.\");\n vidCount--;});\n });\n\n ctrl.videoToggled(function(session, isEnabled){\n ctrl.getVideoElement(session.number).toggle(isEnabled);\n //addLog(session.number+\": video enabled - \" + isEnabled);\n console.log(session.number+\": video enabled - \" + isEnabled);\n });\n ctrl.audioToggled(function(session, isEnabled){\n ctrl.getVideoElement(session.number).css(\"opacity\",isEnabled ? 1 : 0.75);\n //addLog(session.number+\": audio enabled - \" + isEnabled);\n console.log(session.number+\": audio enabled - \" + isEnabled);\n });\n\n phone.message(function(session,message){\n //console.log(\"received image\");\n if(message.hasOwnProperty(\"image\")){\n var img = new Image();\n img.src = message.image.data;\n facesReceived[session.number] = img;\n var height = 0\n Object.keys(facesReceived).forEach(function (key) {\n height += 200;\n })\n snap.width = 200;\n snap.height = height;\n var startY = 0;\n img.onload = function(){\n snap_context.clearRect(0, 0, snap.width, snap.height);\n Object.keys(facesReceived).forEach(function (key) {\n console.log(\"drawing face:\" + key);\n var value = facesReceived[key];\n snap_context.drawImage(value,0,startY);\n startY = startY + 200;\n })\n snap_out.innerHTML = \"\";\n var snap_img = new Image();\n snap_img.src = snap.toDataURL(\"image/jpeg\");\n snap_out.appendChild(snap_img);\n }\n }else if(message.hasOwnProperty(\"text\")){\n var friendDiv = document.createElement('div');\n friendDiv.className =\"chat friend\";\n var friendPhoto = document.createElement('div');\n friendPhoto.className =\"photo\";\n var image = document.createElement('img');\n image.src=\"icons/minion2.png\";\n friendPhoto.appendChild(image);\n var text = document.createElement('p');\n text.className=\"message\";\n text.innerHTML=message.text;\n friendDiv.appendChild(friendPhoto);\n friendDiv.appendChild(text);\n chatlogs.appendChild(friendDiv);\n chatlogs.scrollTop=chatlogs.scrollHeight;\n }else if (message.hasOwnProperty(\"toggleBandwidth\")){\n console.log(\"Toggle Bandwidth:\" + message.toggleBandwidth);\n //Code for user to execute when they recieve toggle message \n bandwidth = message.toggleBandwidth;\n if(bandwidth.toLowerCase() == \"high\"){\n if(send_loop_id == null){\n //do nothing\n }else{\n toggle_to_high();\n }\n \n }else if(bandwidth.toLowerCase() == \"low\"){\n if(send_loop_id == null){\n toggle_to_low();\n }else{\n //do nothing\n }\n }else{\n alert(\"Only High or Low accepted not: \" + bandwidth);\n }\n \n }\n });\n return false;\n}", "function getChatStreamKey(eventId) {\n return \"event:\"+eventId+\":chatStream\";\n}", "function requestChannel(id, creator){\n\t$('#which').attr('channel', id);\n\t$('#which').attr('creator', creator);\n}", "get broadcasterName() {\n return this._data.broadcaster_user_login;\n }", "get broadcasterName() {\n return this._data.broadcaster_user_login;\n }", "get broadcasterName() {\n return this._data.broadcaster_user_login;\n }", "function getProgrammingStreams() {\n\t\t$.ajax({\n\t\t\tdataType: 'json',\n\t\t\theaders: {\n\t\t\t\t'Client-ID': process.env.TWITCH_CLIENT_ID,\n\t\t\t},\n\t\t\turl: 'https://api.twitch.tv/kraken/streams?game=creative&limit=100'\n\t\t})\n\t\t.done(json => {\n\t\t\tconst programmingStreams = filterProgrammingStreams(json.streams);\n\n\t\t\tif (programmingStreams.length === 0) {\n\t\t\t\tconst streamData = {\n\t\t\t\t\tstreamUrl: 'https://www.twitch.tv/directory/game/Creative/programming',\n\t\t\t\t\tstreamLogo: defaultLogo,\n\t\t\t\t\tstreamName: 'No coders found',\n\t\t\t\t\tstreamInfo: 'Please check back later, or click to go to Twitch.tv',\n\t\t\t\t\tstreamStatus: 'offline'\n\t\t\t\t};\n\t\t\t\t$('#searchedStreams').append(streamTemplate(streamData));\n\t\t\t} \n\t\t\telse {\n\t\t\t\tlet gameStreamsHtml = '';\n\t\t\t\tprogrammingStreams.forEach(stream => {\n\t\t\t\t\tconst streamData = {\n\t\t\t\t\t\tstreamUrl: stream.channel.url,\n\t\t\t\t\t\tstreamLogo: stream.channel.logo || defaultLogo,\n\t\t\t\t\t\tstreamName: stream.channel.display_name,\n\t\t\t\t\t\tstreamInfo: stream.channel.status || defaultInfo,\n\t\t\t\t\t\tstreamStatus: 'online'\n\t\t\t\t\t};\n\t\t\t\t\tgameStreamsHtml += streamTemplate(streamData);\n\t\t\t\t});\n\t\t\t\t$('#searchedStreams').append(gameStreamsHtml);\n\t\t\t}\n\t\t\t$('#loadingScreen').addClass('hidden');\n\t\t\t$('#streamContainer').removeClass('hidden');\n\t\t})\n\t\t.fail(err => {\n\t\t\tconsole.log(err);\n\t\t});\n\t}", "ListenToChannel(oldMember, newMember) {\n let newUserChannel = newMember.channel;\n let oldUserChannel = oldMember.channel;\n this.audioPlayer.client = this.client;\n\n //don't process the channel if the user who joined is Joinify or if there's already an audio thread being processed\n if (newMember.member.displayName == 'Joinify' || this.isAudioReady == false) {\n return;\n }\n\n //don't process the channel if the user is only muting or unmuting\n //don't process the channel if the user is only deafening or undeafening\n //don't process the channel if the user is only streaming or unstreaming\n if (newMember != null && oldMember != null && (\n newMember.mute != oldMember.mute ||\n newMember.deaf != oldMember.deaf ||\n newMember.streaming != oldMember.streaming))\n return;\n\n //don't process the channel if there's already audio being played\n if (this.audioPlayer.isAudioReady == false)\n return;\n\n if (\n (oldUserChannel === null && newUserChannel !== null && newUserChannel.id == this.channelId) ||\n (oldUserChannel !== null && newUserChannel !== null && oldUserChannel.id != newUserChannel.id && newUserChannel.id == this.channelId)\n ) {\n //a user has joined the watching channel\n //this.message.channel.send('User has joined ' + newUserChannel.name);\n var msg = this.dateService.GetCurrentDateTime() + \n ' - User ' + newMember.member.displayName + ' has joined ' + newUserChannel.name;\n console.info(msg);\n this.audioPlayer.PlayYoutube(this.joinLink);\n }\n else if (\n (oldUserChannel !== null && newUserChannel === null && oldUserChannel.id == this.channelId) || //user has left the channel\n (oldUserChannel !== null && newUserChannel !== null && newUserChannel.id != this.channelId) //user has swapped channels\n ) {\n //a user has left a voice channel \n //this.message.channel.send(\"User has left \" + oldUserChannel.name);\n var msg = this.dateService.GetCurrentDateTime() +\n \" - User \" + oldMember.member.displayName + \" has left \" + oldUserChannel.name;\n console.info(msg);\n this.audioPlayer.PlayYoutube(this.leaveLink);\n }\n }", "function Chat() {\n\n if (!isWebRTCSupported) {\n alert(\"error: This browser does not support WebRTC\");\n return;\n }\n\n console.log(\"Connecting to server\");\n socket = io(server);\n \n // once access given, join the channel\n socket.on(\"connect\", () => {\n console.log(\"Connected to server\");\n getId(\"loadingDiv\").style.display = \"none\";\n setElements();\n setChatRoom();\n setLeaveRoomBtn();\n setShareRoomBtn();\n setJoinCallBtn();\n start();\n });\n\n\n // server sends out 'add' signals to each pair of users in the channel \n socket.on(\"add\", (config) => {\n\n let peer_id = config.peer_id;\n let peers = config.peers;\n\n if (peer_id in connections) return;\n if (config.iceServers) iceServers = config.iceServers;\n\n connection = new RTCPeerConnection({ iceServers: iceServers });\n connections[peer_id] = connection;\n\n msgerAddPeers(peers);\n participantAddPeers(peers);\n\n connections[peer_id].onicecandidate = (event) => {\n if (event.candidate) {\n socket.emit(\"ICE\", { \n peer_id: peer_id, \n ice_candidate: { \n sdpMLineIndex: event.candidate.sdpMLineIndex, \n candidate: event.candidate.candidate, \n address: event.candidate.address, \n }, \n });\n } \n };\n\n // RTC Data Channel\n connections[peer_id].ondatachannel = (event) => {\n console.log(\"Datachannel event \" + peer_id, event);\n event.channel.onmessage = (msg) => {\n switch (event.channel.label) {\n case \"chat_channel\":\n let message = {};\n try {\n message = JSON.parse(msg.data);\n ChatChannel(message);\n } \n catch (err) {\n console.log(err);\n }\n break;\n }\n };\n };\n createChatChannel(peer_id);\n\n if (config.should_create_offer) {\n\n console.log(\"creating RTC offer to\", peer_id);\n connections[peer_id].createOffer()\n .then((local_description) => {\n console.log(\"local offer description is\", local_description);\n connections[peer_id].setLocalDescription(local_description)\n .then(() => {\n socket.emit(\"SDP\", { peer_id: peer_id, session_description: local_description, });\n console.log(\"offer setLocalDescription done!\");\n })\n .catch((err) => {\n console.error(\"error: offer setLocalDescription\", err);\n alert(\"error: offer setLocalDescription failed \" + err);\n });\n })\n .catch((err) => {\n console.error(\"error: sending offer\", err);\n });\n }\n\n });\n\n \n socket.on(\"sessionDescription\", (config) => {\n\n let peer_id = config.peer_id;\n let remote_description = config.session_description;\n let description = new RTCSessionDescription(remote_description);\n\n connections[peer_id].setRemoteDescription(description)\n .then(() => {\n console.log(\"setRemoteDescription done!\");\n if (remote_description.type == \"offer\") {\n console.log(\"creating answer\");\n connections[peer_id].createAnswer()\n .then((local_description) => {\n console.log(\"answer description is: \", local_description);\n connections[peer_id].setLocalDescription(local_description)\n .then(() => {\n socket.emit(\"SDP\", { peer_id: peer_id, session_description: local_description, });\n console.log(\"answer setLocalDescription done!\");\n })\n .catch((err) => {\n console.error(\"error: answer setLocalDescription\", err);\n alert(\"error: answer setLocalDescription failed \" + err);\n });\n })\n .catch((err) => {\n console.error(\"error: creating answer\", err);\n });\n } \n })\n .catch((err) => {\n console.error(\"error: setRemoteDescription\", err);\n });\n });\n\n\n socket.on(\"iceCandidate\", (config) => {\n\n let peer_id = config.peer_id;\n let ice_candidate = config.ice_candidate;\n connections[peer_id]\n .addIceCandidate(new RTCIceCandidate(ice_candidate))\n .catch((err) => {\n console.error(\"error: addIceCandidate\", err);\n alert(\"error: addIceCandidate failed \" + err);\n });\n });\n\n \n // remove all connections\n socket.on(\"disconnect\", () => {\n\n console.log(\"Disconnected from server\");\n for (let peer_id in connections) {\n connections[peer_id].close();\n msgerRemovePeer(peer_id);\n participantRemovePeer(peer_id);\n }\n chatChannels = {};\n connections = {};\n });\n\n \n // 'remove' signal is passed to all the users and the media channels open for that peer are deleted\n socket.on(\"remove\", (config) => {\n\n console.log(\"Server said to remove peer:\", config);\n let peer_id = config.peer_id;\n if (peer_id in connections) connections[peer_id].close();\n\n msgerRemovePeer(peer_id);\n participantRemovePeer(peer_id);\n\n delete chatChannels[peer_id];\n delete connections[peer_id];\n });\n\n} // end Chat", "function customergetChannel(chname)\n\n{\t\t\tif(activechannel)\n\t\t\t{ \n\t\t\tclient.removeListener('channelUpdated', updateChannels);\n\t\t\t generalChannel.removeListener('typingStarted', function(member) {\n\t\t\t\t\t\tconsole.log(\"typingStarted success\")\n\t\t\t\t\t\ttypingMembers.push(member.identity);\n\t\t\t\t\t\tupdateTypingIndicator();\n\t\t\t\t},function(erro){\n\t\t\t\tconsole.log(\"typingStarted error\",erro)\n\t\t\t\t});\n\t\t\t\tgeneralChannel.removeListener('typingEnded', function(member) {\n\t\t\t\t\t\tconsole.log(\"typingEnded success\")\n\t\t\t\t\t\ttypingMembers.splice(typingMembers.indexOf(member.identity), 1 );\n\t\t\t\t\t\t\n\t\t\t\t\t\tupdateTypingIndicator();\n\t\t\t\t},function(error){\n\t\t\t\t\n\t\t\t\t\t\tconsole.log(\"typingEnded eror\",error)\n\t\t\t\t});\n\t\t\t}\n\n \n \n\t setTimeout(function() {\n\t\n\t\t\t\t$(\"#\"+chname+\" b\").text(\"\");\n\t\t\t\t$(\"#\"+chname+\" b\").removeClass(\"m-widget4__number\");\n\t\t\t\t$(\"#\"+chname+\" input\").val(0);\n\t\t\t\t$(\".m-widget4__item\").removeClass(\"active\");\n\t\t\t\t$(\"#\"+chname).addClass(\"active\");\n\t\t\t\t\n\t\t\t\t\t$(\"#chatmessage\").html(\"\");\n\t\t\t\t$(\".loader\").show();\n\t\t\t\t client.getChannelByUniqueName(chname).then(function(channel) {\n\t\t\t\t\t\t\tconsole.log(\"channel\",channel)\n\t\t\t\t\t\t\tgeneralChannel = channel;\n\t\t\t\t\t\t \n\t\t\t\t\t$(\"#channel-title\").text(channel.state.friendlyName);\t\n\t\t\t\t\t\t\t\tsetupChannel(generalChannel);\n\t\t\t\t\t\t\t \n\t\t\t\t\t\t},function (error){\n\t\t\t\t\n\t\t\t\t\t\t console.log(\"error\",error)\n\t\t\t\t\t\t});\n\t\n\t }, 10);\n \n \n}", "function displayChannels(data) {\n\t\t\t$(`#${userName}`).append(\"<div class='layout col-lg-3 col-md-3 col-sm-12'><div class='user-name'>\" + `${data.display_name}` + \"</div></div>\");\n\t\t\t$(`#${userName} div div`).append(`<a target=\"_blank\" href=\"${data.url}\"><img src=\"${data.logo}\"></img></a>`);\n\t\t\t$.getJSON(urlStreams, displayStatus);\n\t\t}", "streamToMesh(client, mesh) {\n console.log(\"Loaded avatar of client \"+client.id)\n client.streamToMesh = mesh;\n for ( var i = 0; i < this.subscribers.length; i++) {\n var subscriber = this.subscribers[i];\n var id = this.getClientId(subscriber);\n if ( client.id == id ) {\n // matched\n this.attachAudioStream(mesh, this.getStream(subscriber));\n this.attachVideoStream(client, subscriber);\n //this.subscribers.splice(i,1);\n console.log(\"Audio/video stream connected to avatar of client \"+id)\n //break; // don't break, there may be multiple streams\n }\n }\n this.clients.push(client);\n }", "function joinToChannel() {\n console.log(\"join to channel\", roomId);\n \n // store the room info to my meetings\n // if room does not exist set the whole info\n // if room exists update timestamp and date (to track for the recent call made) \n const mymeetings = firestore.collection(`${myName}`).doc(`${roomId}`);\n const snapshot = mymeetings.get();\n let timestamp = Date.now();\n let date = new Date().toString().slice(0,-34);\n if (!snapshot.exists) {\n try {\n mymeetings.set({ roomId, timestamp, date, roomName, createdBy });\n } catch (err) {\n console.log(err);\n }\n }\n else{\n try {\n mymeetings.update({'timestamp':timestamp, 'date':date });\n } catch (err) {\n console.log(err);\n }\n }\n socket.emit(\"join\", { channel: roomId, peerName: myName, });\n}", "function startStream () {\n startButton.setAttribute('disabled', true)\n video.addEventListener('canplay', function() {\n videoWidth = video.videoWidth;\n videoHeight = video.videoHeight;\n var duration = video.duration;\n var i = 0;\n\n var interval = setInterval(function() {\n if ((socket == null) || (\"undefined\" === typeof socket)) {\n console.log(\"ROOM NOT CONNECTED >> no avatar broadcast\");\n return;\n }\n context.drawImage(video, 0, 0, 256, 256);\n var dataURL = canvas.toDataURL('image/jpeg', 0.1);\n // console.log(\"created avatar face with \" + dataURL);\n socket.emit(\"avatar-face\", JSON.stringify( {\"socket_id\": socket.id, 'type':'avatar-face', 'imagebuffer': dataURL} ) );\n }, 300);\n });\n navigator.getUserMedia = navigator.getUserMedia || navigator.webkitGetUserMedia || navigator.mozGetUserMedia || navigator.msGetUserMedia || navigator.oGetUserMedia;\n if (navigator.getUserMedia) {\n navigator.getUserMedia({audio: true, video: { width: 320, height: 240}}, handleVideo, videoError);\n }\n function handleVideo(stream) {\n var video = document.querySelector(\"video\");\n video.src = window.URL.createObjectURL(stream);\n video.volume = 0;\n }\n function videoError(e) {console.log(e);}\n\n // Usually, this would use PubNub Phone WebRTC to do VOIP,\n // This is also availabel as a support mechanism\n document.getElementById('echobutton').addEventListener('click',function() { window.open('https://discord.gg/3j7XYqY','_blank'); });\n }", "function whisperHack() {\n if (!firstTimeOnly) {\n // Listen to this viewer's private PubSub whisper channel\n twitch.listen('whisper-'+latestAuth.userId, (target, type, msg) => {\n // console.log(\"New Twitch PubSub whisper:\", msg);\n });\n } else {\n setTimeout(whisperHack, 1000);\n }\n }", "function streamOn(val) {\n $(\"#results\").append(\n \"<div class='channelResults online selected' id='\" +\n val.stream.channel.name +\n \"'><a href=\" +\n val.stream.channel.url +\n \" target='_blank'><div class='active'><img class='logo' src=\" +\n val.stream.channel.logo +\n \" ><h4 class='displayName'>\" +\n val.stream.channel.display_name +\n \"</h4><p class='status'>\" +\n val.stream.game +\n \"</p></div></a><div class='led-green'></div></div>\"\n );\n }", "function informSingleClient(id) {\n for(var i in SOCKET_LIST) {\n if(SOCKET_LIST[i].username === id) {\n var pack = {\n Room1: getRoomInformation(\"Room1\")\n }\n SOCKET_LIST[i].socket.emit('lobbyInfo', pack);\n break;\n }\n }\n}", "function identify(request, response) {\n let { socket_id, channel_name } = request.body;\n\n var auth = pusher.authenticate(socket_id, channel_name, {\n // request.user.token comes from sonos-oauth.authenticated\n user_id: encrypt(request.user.token)\n });\n\n response.send(auth);\n\n // For the reconnect case, start subscribing to the related channel. If a\n // user is reconnecting, we need to subscribe again\n subscribe(channel_name, request.user.token);\n}", "function fetchChats(socket){\n // console.log(socket);\n //return chats as an object;\n let payload = {\n 'zoz-eyad': {\n id: 1, //Represents the ChatId\n name: 'Patriot Chat Development',\n participants: ['zoz', 'eyad']\n },\n 'zoz-dhaynes': {\n id: 2,\n name: 'some other thing',\n participants: ['zoz', 'dhaynes']\n },\n 'eyad-dhaynes': {\n id: 3,\n name: 'some third thing',\n participants: ['eyad', 'dhaynes']\n }\n };\n\n io.to(socket.id).emit('fetch-chats', payload);\n}", "function setupChannel() {\r\n\r\n\t\t// Join the general channel\r\n\t\tgeneralChannel.join().then(function(channel) {\r\n\t\t\tconsole.log('Enter Chat room');\r\n\r\n\t\t\t// Listen for new messages sent to the channel\r\n\t\t\tgeneralChannel.on('messageAdded', function(message) {\r\n\t\t\t\tremoveTyping();\r\n\t\t\t\tprintMessage(message.author, message.body, message.index, message.timestamp);\r\n\t\t\t\tif (message.author != identity) {\r\n\t\t\t\t\tgeneralChannel.updateLastConsumedMessageIndex(message.index);\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\t// 招待先プルダウンの描画\r\n\t\t\tvar storedInviteTo = storage.getItem('twInviteTo');\r\n\t\t\tgenerateInviteToList(storedInviteTo);\r\n\r\n\t\t\t// 招待先プルダウンの再描画\r\n\t\t\tgeneralChannel.on('memberJoined', function(member) {\r\n\t\t\t\tconsole.log('memberJoined');\r\n\t\t\t\tmember.on('updated', function(updatedMember) {\r\n\t\t\t\t\tupdateMemberMessageReadStatus(updatedMember.identity, \r\n\t\t\t\t\t\t\t\t\t\t\t\t\tupdatedMember.lastConsumedMessageIndex || 0, \r\n\t\t\t\t\t\t\t\t\t\t\t\t\tupdatedMember.lastConsumptionTimestamp);\r\n\t\t\t\t\tconsole.log(updatedMember.identity, updatedMember.lastConsumedMessageIndex, updatedMember.lastConsumptionTimestamp);\r\n\t\t\t\t});\r\n\t\t\t\tgenerateInviteToList();\r\n\t\t\t});\r\n\t\t\tgeneralChannel.on('memberLeft', function(member) {\r\n\t\t\t\tconsole.log('memberLeft');\r\n\t\t\t\tgenerateInviteToList();\r\n\t\t\t});\r\n\r\n\t\t\t// Typing Started / Ended\r\n\t\t\tgeneralChannel.on('typingStarted', function(member) {\r\n\t\t\t\tconsole.log(member.identity + ' typing started');\r\n\t\t\t\tshowTyping();\r\n\t\t\t});\r\n\t\t\tgeneralChannel.on('typingEnded', function(member) {\r\n\t\t\t\tconsole.log(member.identity + ' typing ended');\r\n\t\t\t\tclearTimeout(typingTimer);\r\n\t\t\t});\r\n\r\n\t\t\t// 最終既読メッセージindex取得\r\n\t\t\tgeneralChannel.getMembers().then(function(members) {\r\n\t\t\t\tfor (i = 0; i < members.length; i++) {\r\n\t\t\t\t\tvar member = members[i];\r\n\t\t\t\t\tmember.on('updated', function(updatedMember) {\r\n\t\t\t\t\t\tupdateMemberMessageReadStatus(updatedMember.identity, \r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tupdatedMember.lastConsumedMessageIndex || 0, \r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tupdatedMember.lastConsumptionTimestamp);\r\n\t\t\t\t\t\tconsole.log(updatedMember.identity, updatedMember.lastConsumedMessageIndex, updatedMember.lastConsumptionTimestamp);\r\n\t\t\t\t\t});\r\n\t\t\t\t\tif (identity != member.identity && inviteToNames.indexOf(member.identity) != -1) {\r\n\t\t\t\t\t\treadStatusObj[identity] = member.lastConsumedMessageIndex;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t// Get Messages for a previously created channel\r\n\t\t\t\tgeneralChannel.getMessages().then(function(messages) {\r\n\t\t\t\t\t$chatWindow.empty();\r\n\t\t\t\t\tvar lastIndex = null;\r\n\t\t\t\t\tfor (i = 0; i < messages.length; i++) {\r\n\t\t\t\t\t\tvar message = messages[i];\r\n\t\t\t\t\t\tprintMessage(message.author, message.body, message.index, message.timestamp);\r\n\t\t\t\t\t\tif (message.author != identity) {\r\n\t\t\t\t\t\t\tlastIndex = message.index;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif (lastIndex && lastIndex >= 0) {\r\n\t\t\t\t\t\tgeneralChannel.updateLastConsumedMessageIndex(lastIndex);\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\thideSpinner();\r\n\t\t\t\t\t$('#chat-input').prop('disabled', false);\r\n\t\t\t\t});\r\n\r\n\t\t\t});\r\n\r\n\t\t});\r\n\r\n\t}", "function getDataForAllChannels() {\n channels.forEach(function(channel) {\n // Data from the Channels API\n $.getJSON(\"https://wind-bow.gomix.me/twitch-api/channels/\" + channel + \"?callback=?\", function(data) {\n var status, url, name, logo;\n if (data.error === \"Not Found\") {\n status = false;\n url = '';\n name = '<div class=\"col-md-2\">' + channel + '</div>';\n logo = \"https://dummyimage.com/50x50/ecf0e7/5c5457.jpg&text=0x3F\";\n } else {\n status = true;\n url = '<a href=\"' + data.url + '\" target=\"_blank\">';\n name = '<div class=\"col-md-2\">' + data.name + '</div></a>';\n logo = data.logo;\n };\n // Data from the Streams API\n $.getJSON(\"https://wind-bow.gomix.me/twitch-api/streams/\" + channel + \"?callback=?\", function(streamdata) {\n if (status === false) {\n status = \"Not on twitch\";\n } else if (streamdata.stream === null) {\n status = \"Offline\";\n } else {\n url = '<a href=\"' + streamdata.stream.channel.url + '\" target=\"_blank\">';\n status = '<a href=\"' + streamdata.stream.channel.url + '\">' + streamdata.stream.channel.status + '</a>';\n }\n // Build the page from the pulled data\n var html = '<div class=\"row text-center\" id=\"datarow\">' +\n url + '<div class=\"col-xs-2 col-sm-1\"><img src=\"' +\n logo + '\"></div><div class=\"col-xs-10 col-sm-3\">' +\n name + '</div><div class=\"col-xs-10 col-sm-8\"\">' +\n status + '</div></div>';\n document.getElementById(\"rows\").innerHTML += html;\n });\n });\n });\n}", "onReady(socket, lobbyId, playerName) {\r\n // Controls used for the lobby chatting\r\n const chatContainer = document.getElementById(\"lobby-chat-container\");\r\n const chatInput = document.getElementById(\"lobby-chat-input\");\r\n const postButton = document.getElementById(\"lobby-chat-submit\");\r\n\r\n // Elements used to display users in lobby and\r\n // the participant list\r\n const userList = document.getElementById(\"user-list\");\r\n const participantListContainer = document.getElementById(\"lobby-participant-list\");\r\n\r\n // Controls to control starting and advancing the Lip Sync performance\r\n const startPerformanceButton = document.getElementById(\"start-performance-button\");\r\n const nextPerformerButton = document.getElementById(\"next-performer-button\");\r\n const nowPerformingDisplay = document.getElementById(\"now-performing-display\");\r\n\r\n // Hidden input for the lobby id in the register team form\r\n let lobbyIdInput = document.getElementById(\"hidden-lobby-id\");\r\n lobbyIdInput.value = lobbyId;\r\n\r\n let lobbyChannel = socket.channel(`lobby:${lobbyId}`, () => {\r\n return playerName \r\n ? {username: playerName}\r\n : {username: \"anon\" + Math.floor(Math.random() * 1000)};\r\n });\r\n\r\n let presence = new Presence(lobbyChannel);\r\n\r\n presence.onSync(() => {\r\n userList.innerHTML = presence.list((id, metas) => {\r\n return `<li>${this.esc(id)}</li>`;\r\n }).join(\"\");\r\n });\r\n \r\n // Send chat message to the server.\r\n postButton.addEventListener(\"click\", e => {\r\n let payload = {message: chatInput.value};\r\n lobbyChannel.push(\"new_msg\", payload)\r\n .receive(\"error\", e => e.console.log(e));\r\n chatInput.value = \"\";\r\n });\r\n\r\n // Test to send a new video ID for the player and update it\r\n lobbyChannel.on(\"update_video\", (resp) => {\r\n if (Player.player != null) {\r\n Player.player.loadVideoById(resp.new_id);\r\n nowPerformingDisplay.value = resp.team_name;\r\n }\r\n });\r\n\r\n // Start the Lip Sync performance\r\n startPerformanceButton.addEventListener(\"click\", e => {\r\n lobbyChannel.push(\"start_performance\", {})\r\n .receive(\"error\", e => e.console.log(e));\r\n\r\n startPerformanceButton.setAttribute(\"disabled\", \"disabled\");\r\n });\r\n\r\n // Advance the Lip Sync queue to the next performing team\r\n nextPerformerButton.addEventListener(\"click\", e => {\r\n lobbyChannel.push(\"next_performer\", {})\r\n .receive(\"error\", e => e.console.log(e));\r\n });\r\n\r\n // Receive and render a new chat message.\r\n lobbyChannel.on(\"new_msg\", (resp) => {\r\n this.renderAnnotation(chatContainer, resp);\r\n });\r\n\r\n // Receive updated list of Lip Sync participants\r\n lobbyChannel.on(\"participant_list\", (resp) => {\r\n this.renderParticipantList(participantListContainer, resp);\r\n });\r\n\r\n // Receive update that the performance ended\r\n lobbyChannel.on(\"performance_end\", (resp) => {\r\n startPerformanceButton.removeAttribute(\"disabled\");\r\n });\r\n\r\n // Join the lobby chat channel.\r\n lobbyChannel.join()\r\n .receive(\"ok\", () => {\r\n return;\r\n })\r\n .receive(\"error\", reason => console.log(\"join failed\", reason));\r\n }" ]
[ "0.6181805", "0.6063626", "0.5829279", "0.575058", "0.56496674", "0.5610654", "0.5493258", "0.5431261", "0.5425872", "0.54246515", "0.5409868", "0.540671", "0.5364838", "0.5358927", "0.5321385", "0.5294745", "0.52865297", "0.5280389", "0.5270509", "0.5256866", "0.52472115", "0.5244393", "0.52369833", "0.5223235", "0.5219061", "0.5198028", "0.519435", "0.51702726", "0.5167817", "0.515446", "0.5145667", "0.514485", "0.514382", "0.51419663", "0.5139238", "0.51306117", "0.5123566", "0.51159835", "0.51147616", "0.51125276", "0.51105666", "0.5104355", "0.509018", "0.5081278", "0.50781006", "0.5075614", "0.5075059", "0.5073579", "0.5038126", "0.503573", "0.5035554", "0.50195813", "0.5019565", "0.4999134", "0.49914068", "0.49876884", "0.4981926", "0.49801755", "0.4976005", "0.49748313", "0.49724656", "0.4962262", "0.4958814", "0.49445605", "0.49445605", "0.49445605", "0.49438637", "0.49436194", "0.49390534", "0.493413", "0.49338785", "0.49334663", "0.49291685", "0.49189708", "0.49185562", "0.4916069", "0.49105924", "0.49094316", "0.49037176", "0.49035192", "0.4902178", "0.49013996", "0.4899392", "0.4899392", "0.4899392", "0.48962885", "0.48883453", "0.4886285", "0.4882937", "0.48827928", "0.48782867", "0.48771507", "0.48758492", "0.48699793", "0.48643577", "0.48642084", "0.48584232", "0.4857693", "0.48569015", "0.4856688", "0.48562375" ]
0.0
-1
optional, speeds up future uses
function urlParam(name) { var results = new RegExp('[\?&]' + name + '=([^&#]*)').exec(window.location.href); return results ? results[1] : ""; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private internal function m248() {}", "private public function m246() {}", "transient protected internal function m189() {}", "transient private internal function m185() {}", "transient private protected internal function m182() {}", "static private internal function m121() {}", "function _____SHARED_functions_____(){}", "transient final protected internal function m174() {}", "protected internal function m252() {}", "transient final private internal function m170() {}", "function test_bottleneck_datastore() {}", "static private protected internal function m118() {}", "transient final private protected internal function m167() {}", "transient final private protected public internal function m166() {}", "lastUsed() { }", "static transient final private internal function m43() {}", "transient private protected public internal function m181() {}", "function test_bottleneck_provider() {}", "transient private public function m183() {}", "static transient final protected internal function m47() {}", "static transient final private protected internal function m40() {}", "preload () {}", "prepare() {}", "static final private internal function m106() {}", "static private protected public internal function m117() {}", "static transient private protected internal function m55() {}", "get FastButNoExceptions() {}", "get FastPass() {\n return true;\n }", "slowOnCollision() {\n\t\tundefined;\n\t}", "__previnit(){}", "preload() {}", "__init3() {this._numProcessing = 0;}", "__init3() {this._numProcessing = 0;}", "__init3() {this._numProcessing = 0;}", "static transient private internal function m58() {}", "build () {}", "obtain(){}", "work() {}", "function mainLoop()\r\n{\r\n\tvar startTime = performance.now();\r\n}", "static transient final protected public internal function m46() {}", "preset () { return false }", "function fm(){}", "function slowloop() {\n // Build the minimap\n logs.minimap.set();\n readmap = getminimap();\n // Build the leaderboard\n readlb = getleaderboard();\n logs.minimap.mark();\n // Check sockets\n let time = util.time();\n clients.forEach(socket => {\n //if (socket.timeout.check(time)) socket.kick('Kicked for inactivity.');\n if (time - socket.statuslastHeartbeat > c.maxHeartbeatInterval) socket.kick('Lost heartbeat.'); \n });\n }", "analyze(){ return null }", "no_op() {}", "__init3() {this._finished = false;}", "__init3() {this._finished = false;}", "__init3() {this._finished = false;}", "function test_bottleneck_host() {}", "static protected internal function m125() {}", "function used(value) { }", "function noop(){}// No operation performed.", "function noop(){}// No operation performed.", "function noop(){}// No operation performed.", "function noop(){}// No operation performed.", "function noop(){}// No operation performed.", "function noop(){}// No operation performed.", "function noop(){}// No operation performed.", "myBestMethod(){\n\n }", "static transient private protected public internal function m54() {}", "transient final private public function m168() {}", "static transient private public function m56() {}", "apply () {}", "function writeOnce(){\n console.log('writeOnce()');\n doPicList();\n doLargeText();\n // tracker();\n onesZeros();\n}", "function alwaysRunOnload () {\n\t\t// Placeholder/Future use.\n\t}", "function miFuncion (){}", "function faster() {\n if (stepDelay <= MIN_DELAY) { return; }\n stepDelay /= 2;\n }", "static get SIZE() { return 2000000; }", "function test_bottleneck_cluster() {}", "function datasetDangerously () {}", "function run() {}", "static private public function m119() {}", "overTime(){\n\t\t//\n\t}", "function fractalStart(){\n\n // USUALLY A CHANGE IN ZOOM HAS BEEN MADE\n document.getElementById('spanZoom').innerHTML = config.zoomLevel;\n\n // START TO MEASURE PERFORMANCE\n\t let tStart = performance.now();\n\n // CALL THE FUNCTION GENERATING THE MANDLEBROT SET\n\tgenerateFractal(config.xCenter, config.yCenter, config.maxIterations, LIMIT, config.fractalType);\n\n // END TO MEASURE PERFORMANCE\n\t let tEnd = performance.now();\n let tTaken = tEnd - tStart;\n document.getElementById('timeTaken').innerHTML = tTaken.toFixed(3);\n // LOG PERFORMANCE\n\t console.log('Time taken: '+ (tEnd - tStart) +' milliseconds');\n\n}", "function sprinkles() {\n\n\t}", "resolution() { }", "static transient final protected function m44() {}", "function o0(o1)\n{\n var o2 = -1;\n try {\nfor (var o259 = 0; o3 < o1.length; function (o502, name, o38, o781, o782, o837, o585, o838, o549) {\n try {\no839.o468();\n}catch(e){}\n // TODO we should allow people to just pass in a complete filename instead\n // of parent and name being that we just join them anyways\n var o840 = name ? o591.resolve(o591.o592(o502, name)) : o502;\n\n function o841(o842) {\n function o843(o842) {\n try {\nif (!o838) {\n try {\no474.o800(o502, name, o842, o781, o782, o549);\n}catch(e){}\n }\n}catch(e){}\n try {\nif (o837) try {\no837();\n}catch(e){}\n}catch(e){}\n try {\no334('cp ' + o840);\n}catch(e){}\n }\n var o844 = false;\n try {\nModule['preloadPlugins'].forEach(function (o845) {\n try {\nif (o844) try {\nreturn;\n}catch(e){}\n}catch(e){}\n try {\nif (o845['canHandle'](o840)) {\n try {\no845['handle'](o842, o840, o843, function () {\n try {\nif (o585) try {\no585();\n}catch(e){}\n}catch(e){}\n try {\no334('cp ' + o840);\n}catch(e){}\n });\n}catch(e){}\n try {\no844 = true;\n}catch(e){}\n }\n}catch(e){}\n });\n}catch(e){}\n try {\nif (!o844) try {\no843(o842);\n}catch(e){}\n}catch(e){}\n }\n try {\no332('cp ' + o840);\n}catch(e){}\n try {\nif (typeof o38 == 'string') {\n try {\no839.o846(o38, function (o842) {\n try {\no841(o842);\n}catch(e){}\n }, o585);\n}catch(e){}\n } else {\n try {\no841(o38);\n}catch(e){}\n }\n}catch(e){}\n })\n {\n try {\nif (o1[o3] == undefined)\n {\n try {\nif (o2 == -1)\n {\n try {\no2 = o3;\n}catch(e){}\n }\n}catch(e){}\n }\n else\n {\n try {\nif (o2 != -1)\n {\n try {\no4.o5(o2 + \"-\" + (o3-1) + \" = undefined\");\n}catch(e){}\n try {\no2 = -1;\n}catch(e){}\n }\n}catch(e){}\n try {\no4.o5(o3 + \" = \" + o1[o3]);\n}catch(e){}\n }\n}catch(e){}\n }\n}catch(e){}\n}", "function D(){return setTimeout(function(){Ya=void 0}),Ya=_.now()}", "initialize() {}", "initialize() {}", "initialize() {}", "initialize() {}", "initialize() {}", "initialize() {}", "function o807() {\n try {\nthis.o808 = false;\n}catch(e){}\n try {\nthis.o809 = [];\n}catch(e){} // Loaded chunks. Index is the chunk number\n }", "function miFuncion(){}", "function miFuncion(){}", "function miFuncion(){}", "preprocess () {\n this.allFound = true\n\n for (let i = 0; i < this.ids.length; i++) {\n const id = this.ids[i]\n\n if (id === null) {\n continue\n }\n\n if (id in this.overpass.cacheElements) {\n const ob = this.overpass.cacheElements[id]\n let ready = true\n\n // Feature does not exists!\n if (ob.missingObject) {\n this.featureCallback(null, null, i)\n this.ids[i] = null\n continue\n }\n\n // for bounds option, if object is (partly) loaded, but outside call\n // featureCallback with 'false'\n if (this.options.bounds) {\n const intersects = this.geojsonBounds ? ob.intersects(this.geojsonBounds) : ob.intersects(this.options.bounds)\n if (intersects === 0 || (!ob.bounds && ob.properties | defines.BBOX)) {\n this.featureCallback(null, false, i)\n this.ids[i] = null\n continue\n }\n }\n\n // not fully loaded\n if ((ob !== false && ob !== null) && (this.options.properties & ob.properties) !== this.options.properties) {\n ready = false\n }\n\n // if sort is set in options maybe defer calling featureCallback\n if (ready) {\n this.receiveObject(ob)\n this.featureCallback(null, ob, i)\n this.ids[i] = null\n continue\n }\n } else {\n // Illegal ID\n if (id !== null && !id.match(/^[nwr][0-9]+$/)) {\n this.featureCallback(null, null, i)\n this.ids[i] = null\n continue\n }\n }\n\n this.allFound = false\n }\n }", "function PerformanceTestCase() {\n}", "function k(){setTimeout(function(){// IE7 needs this so dimensions are calculated correctly\n!la.start&&p()&&// !currentView.start makes sure this never happens more than once\ns()},0)}", "faster(){\n if(this.body.angularVelocity <= 800){\n this.body.angularVelocity += 200;\n }\n this.setVelocityX(this.body.velocity.x + 40);\n this.setVelocityY(this.body.velocity.y - 40);\n }", "function fullInit(options)\n\t{\n\t\tvar data = options.data;\n\n\t\t_cacheByKeyword = data.byKeyword;\n\t\t_cacheByProteinChange = data.byProteinChange;\n\t\t_cacheByGeneSymbol = data.byGeneSymbol;\n\t\t_cacheByProteinPosition = data.byProteinPosition;\n\t}", "function run() {\n\n }", "function __it() {}", "static final private protected internal function m103() {}", "loadingData() {}", "loadingData() {}", "function buildspeed(){\n let buildspeed = 0.001*engine.counter('Nworkers');\n let diggerspeed = 1;\n if( engine.perks.lander.diggerspeed )\n diggerspeed = engine.perks.lander.diggerspeed;\n buildspeed += diggerspeed*engine.counter('Ndiggers');\n return check_out_of_resource()*buildspeed;\n}", "analyze(input){ return null }" ]
[ "0.6465426", "0.59911895", "0.59265673", "0.5879232", "0.5751889", "0.57515067", "0.5597826", "0.55638534", "0.5502018", "0.54914093", "0.540573", "0.5384642", "0.5363471", "0.5294214", "0.5280769", "0.52594864", "0.52482", "0.5226643", "0.52142966", "0.518709", "0.5170638", "0.51082903", "0.5096464", "0.5089829", "0.5089776", "0.50855505", "0.50844276", "0.5056364", "0.5021854", "0.5018676", "0.5000095", "0.49922737", "0.49922737", "0.49922737", "0.49769568", "0.49748397", "0.49544853", "0.49540696", "0.49478507", "0.49425167", "0.49424985", "0.49378687", "0.49358997", "0.49293137", "0.49219638", "0.48908764", "0.48908764", "0.48908764", "0.48732132", "0.48705646", "0.48681524", "0.4844911", "0.4844911", "0.4844911", "0.4844911", "0.4844911", "0.4844911", "0.4844911", "0.48379284", "0.4836769", "0.48335227", "0.48160478", "0.48121324", "0.4806771", "0.48005462", "0.47947317", "0.47940022", "0.4781819", "0.47717142", "0.47689864", "0.47616354", "0.4754367", "0.47510353", "0.47506362", "0.47477317", "0.4725041", "0.4719966", "0.4717028", "0.47117352", "0.47102857", "0.47102857", "0.47102857", "0.47102857", "0.47102857", "0.47102857", "0.47098064", "0.46989554", "0.46989554", "0.46989554", "0.46971115", "0.46876812", "0.46856225", "0.46792614", "0.46746808", "0.46718267", "0.4659948", "0.46574232", "0.46537745", "0.46537745", "0.46537703", "0.46525297" ]
0.0
-1
Finds and selects the first option labelled 'isDefault' from the item object
getDefaultItemOption(item) { item.options.some(option => ( option.isDefault ? !this.setState({ currentOption: option, }) : false )); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "setDefaultSelectedOption() {\n var _a, _b;\n\n this.selectedIndex = (_b = (_a = this.options) === null || _a === void 0 ? void 0 : _a.findIndex(el => el.defaultSelected)) !== null && _b !== void 0 ? _b : -1;\n }", "function select_default_menu_item()\r\n{\r\n\tmenu_item_selected(document.getElementById('mi_home'));\r\n\t//menu_item_selected(document.getElementById('mi_custreqs'));\r\n}", "function getDefaultSelectValue(elem){\r\n\tvar name = elem.name;\r\n\tvar defaultElement = eval(\"document.\"+hatsForm.name+\".selectDefault\"+name);\r\n\tif (defaultElement == null){\r\n\t\tfor (var i=0,iL=elem.options.length; i<iL; ++i){\r\n\t\t\tif (elem.options[i].defaultSelected){\r\n\t\t\t\treturn elem.options[i].value;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn null; \r\n\t} else {\r\n\t\treturn defaultElement.value;\r\n\t}\r\n}", "get firstSelectedOption() {\n var _a;\n\n return (_a = this.selectedOptions[0]) !== null && _a !== void 0 ? _a : null;\n }", "function getSelectedOption(options,value){var flatOptions=flattenOptions(options);var selectedOption=flatOptions.find(function(option){return value===option.value;});if(selectedOption===undefined){// Get the first visible option (not the hidden placeholder)\nselectedOption=flatOptions.find(function(option){return!option.hidden;});}return selectedOption?selectedOption.label:'';}", "_m_pick_default_option(ps_opt_name) {\n const lo_this = this;\n return(lo_this._ah_default_options[ps_opt_name]);\n }", "function setOpenQuestionAsDefault(){\n if (tieneOpMul){\n eliminarOpcionMultiple();\n }\n $('#questionType').val(1); //colocamos la pregunta abierta como default\n $('select option[value=\"1\"]').attr(\"selected\"); //colocamos la pregunta abierta como default\n }", "function setDefaults(container) {\n\tvar found = false;\n\tvar items = container.querySelectorAll(\".alm-filter--link\");\n\t[].concat(_toConsumableArray(items)).forEach(function (item, e) {\n\t\tif (item.classList.contains(\"active\")) {\n\t\t\tfound = true;\n\t\t}\n\t});\n\n\tif (found) return false;\n\n\tvar default_item = container.querySelector('.alm-filter--link[data-selected=\"true\"]');\n\tif (default_item) {\n\t\tdefault_item.classList.add(\"active\");\n\t\tdefault_item.setAttribute(\"aria-checked\", true);\n\t}\n}", "function selectDefaultMenuItem() {\r\n\t\tif ($(\"nav ul li.current\").length == 0) {\r\n\t\t\t$(\"nav ul li:first-child\").addClass(\"current\");\r\n\t\t}\r\n\t}", "getDefaultValueSelected() {\n const {data} = this.props;\n // Bitcoin Network\n if (data.length > 2) {\n if (data[0].disabled) {\n return data[1];\n }\n return data[0];\n }\n // Public Factom Network\n return data[0];\n }", "function getInputDefaultValue(obj) {\r\n if ((typeof obj.type != \"string\") && (obj.length > 0) && (obj[0] != null) && (obj[0].type==\"radio\")) {\r\n for (var i=0; i<obj.length; i++) {\r\n if (obj[i].defaultChecked == true) { return obj[i].value; }\r\n }\r\n return \"\";\r\n }\r\n if (obj.type==\"text\")\r\n { return obj.defaultValue; }\r\n if (obj.type==\"hidden\")\r\n { return obj.defaultValue; }\r\n if (obj.type==\"textarea\")\r\n { return obj.defaultValue; }\r\n if (obj.type==\"checkbox\") {\r\n if (obj.defaultChecked == true) {\r\n return obj.value;\r\n }\r\n return \"\";\r\n }\r\n if (obj.type==\"select-one\") {\r\n if (obj.options.length > 0) {\r\n for (var i=0; i<obj.options.length; i++) {\r\n if (obj.options[i].defaultSelected) {\r\n return obj.options[i].value;\r\n }\r\n }\r\n }\r\n return \"\";\r\n }\r\n if (obj.type==\"select-multiple\") {\r\n var val = \"\";\r\n for (var i=0; i<obj.options.length; i++) {\r\n if (obj.options[i].defaultSelected) {\r\n val = val + \"\" + obj.options[i].value + \",\";\r\n }\r\n }\r\n if (val.length > 0) {\r\n val = val.substring(0,val.length-1); // remove trailing comma\r\n }\r\n return val;\r\n }\r\n return \"\";\r\n }", "function first_dropdown_item() {\n\t\t\tdebugger;\n\t\t\treturn $(\"li\", dropdown).slice(0,1);\n\t\t}", "setDefaultSelect() {\n var platefromSelect = document.getElementById(\"platforms\");\n var options = platefromSelect.options;\n for (var i = 0; i < options.length; i++) {\n if (options[i].textContent == \"android\") {\n platefromSelect.selectedIndex = i;\n }\n }\n }", "handleDefault() {\n if (this.selectedShippingMethod.value) {\n this.deliveryMethods.map((item) => {\n if (this.selectedShippingMethod.value === item.value) {\n this.$refs.shippingMethod.setSelectedByValue(item.value);\n this.setData(item);\n }\n });\n } else {\n this.$refs.shippingMethod.setSelectedByValue(this.deliveryMethods[0].value);\n this.setData(this.deliveryMethods[0]);\n }\n }", "function selectDefaultColor() {\n selected(closedOption);\n}", "handleDefault(index) {\n const dropdownValues = this.$refs.deliveryMethodDropdown[index].dropdownValues;\n if (this.selectedShippingMethod[index].value) {\n dropdownValues.map((item) => {\n if (item.value === this.selectedShippingMethod[index].value) {\n this.$refs.deliveryMethodDropdown[index].setDropdownLabel(item.label);\n this.selectedShippingMethod[index].value = item.value;\n this.selectedShippingMethod[index].label = item.label;\n this.selectedShippingMethod[index].deliveryDetails = item.deliveryDetails;\n }\n });\n } else {\n this.$refs.deliveryMethodDropdown[index].setDropdownLabel(dropdownValues[0].label);\n this.selectedShippingMethod[index].value = dropdownValues[0].value;\n this.selectedShippingMethod[index].label = dropdownValues[0].label;\n this.selectedShippingMethod[index].deliveryDetails = dropdownValues[0].deliveryDetails;\n }\n }", "function select_dropdown_item (item) {\n if(selected_dropdown_item) {\n deselect_dropdown_item($(selected_dropdown_item));\n }\n if(item) {\n item.addClass($(input).data(\"settings\").classes.selectedDropdownItem);\n selected_dropdown_item = item.get(0);\n }\n }", "selectFirstOption() {\n if (!this.disabled) {\n this.selectedIndex = 0;\n }\n }", "quickShopDefaultImage(imgObj = {}) {\n this.quickShopImages.select(0);\n }", "function SFDefaultSingleSelectModel(items) {\n assert(items, \"[SFDefaultSingleSelectModel] No items were passed\");\n //Call the constructor of SFDefaultListModel to initialize the items list\n SFDefaultListModel.call(this,items);\n //initialize with a default selection\n if (this.size() > 0)\n this._selectedIndex = 0;\n}", "setDefaultTabElement() {\n if (this.defaultTabElement) {\n return;\n }\n const elements = this.getRenderedTabItems();\n if (!elements) {\n return;\n }\n elements.forEach(element => {\n if (!this.defaultTabElement && element['isDefault']) {\n this.defaultTabElement = element;\n return;\n }\n });\n }", "function select_dropdown_item (item) {\n if(item) {\n if(selected_dropdown_item) {\n deselect_dropdown_item($(selected_dropdown_item));\n }\n\n item.addClass($(input).data(\"settings\").classes.selectedDropdownItem);\n selected_dropdown_item = item.get(0);\n }\n }", "function select_dropdown_item (item) {\n if(item) {\n if(selected_dropdown_item) {\n deselect_dropdown_item($(selected_dropdown_item));\n }\n\n item.addClass($(input).data(\"settings\").classes.selectedDropdownItem);\n selected_dropdown_item = item.get(0);\n }\n }", "function insert_default_options() {\n\n if (is_content_selected() === false) {\n return false;\n }\n\n // current options\n var options = $(\".yp-editor-list > li.active:not(.yp-li-about) .yp-option-group\");\n\n // delete all cached data.\n $(\"li[data-loaded]\").removeAttr(\"data-loaded\");\n\n // UpData current active values.\n if (options.length > 0) {\n options.each(function () {\n\n if ($(this).attr(\"id\") != \"background-parallax-group\" && $(this).attr(\"id\") != \"background-parallax-speed-group\" && $(this).attr(\"id\") != \"background-parallax-x-group\" && $(this).attr(\"id\") != \"background-position-group\") {\n\n var check = 1;\n\n if ($(this).attr(\"id\") == 'animation-duration-group' && is_animate_creator() === true) {\n check = 0;\n }\n\n if (check == 1) {\n set_default_value(get_option_id(this));\n }\n\n }\n });\n }\n\n // cache to loaded data.\n options.parent().attr(\"data-loaded\", \"true\");\n\n }", "defaultValue(props) {\n // check if there is a value in the model, if there is, display it. Otherwise, check if\n // there is a default value, display it.\n //console.log('Text.defaultValue key', this.props.form.key);\n //console.log('Text.defaultValue model', this.props.model);\n let value = utils.selectOrSet(props.form.key, props.model); //console.log('Text defaultValue value = ', value);\n // check if there is a default value\n\n if (!value && props.form['default']) {\n value = props.form['default'];\n }\n\n if (!value && props.form.schema && props.form.schema['default']) {\n value = props.form.schema['default'];\n } // Support for Select\n // The first value in the option will be the default.\n\n\n if (!value && props.form.titleMap && props.form.titleMap[0].value) {\n value = props.form.titleMap[0].value;\n } //console.log('value', value);\n\n\n return value;\n }", "getDefaultOption () {\n\t\tconst { blankOptionLabel, showDefaultOption, defaultOptionLabel, country } = this.props;\n\t\tif (!country) {\n\t\t\treturn <option value=\"\">{blankOptionLabel}</option>;\n\t\t}\n\t\tif (showDefaultOption) {\n\t\t\treturn <option value=\"\">{defaultOptionLabel}</option>;\n\t\t}\n\t\treturn null;\n\t}", "selectFirstOption() {\n var _a, _b;\n\n if (!this.disabled) {\n this.selectedIndex = (_b = (_a = this.options) === null || _a === void 0 ? void 0 : _a.findIndex(o => !o.disabled)) !== null && _b !== void 0 ? _b : -1;\n }\n }", "function selectFirstOption(elm) {\n elm.val(elm.find('option').first().val());\n}", "select(item = {}) {\n for (let path in menus) {\n menus[path].options.map(item => item.selected = false);\n }\n item.selected = true;\n }", "function getSelectedDropdown(option){\n return model.inputs.dropDownOption == option ? 'selected' : '';\n}", "function restoreDefault(filter) {\n\tvar fieldtype = filter.dataset.fieldtype; // Filter container\n\tvar selected_value = filter.dataset.selectedValue; // Default selected value\n\n\tswitch (fieldtype) {\n\t\tcase \"radio\":\n\t\tcase \"checkbox\":\n\t\t\tvar items = filter.querySelectorAll(\".alm-filter--link\");\n\t\t\t[].concat(_toConsumableArray(items)).forEach(function (item) {\n\t\t\t\tif (item.dataset.value === selected_value) {\n\t\t\t\t\t// If item is preselected.\n\t\t\t\t\titem.classList.add(\"active\");\n\t\t\t\t\titem.setAttribute(\"aria-checked\", true);\n\t\t\t\t} else {\n\t\t\t\t\titem.classList.remove(\"active\");\n\t\t\t\t\titem.setAttribute(\"aria-checked\", false);\n\t\t\t\t}\n\t\t\t});\n\n\t\t\tbreak;\n\n\t\tcase \"select\":\n\t\t\tvar select = filter.querySelector(\"select\");\n\t\t\tif (!select) {\n\t\t\t\tbreak; // exit if empty\n\t\t\t}\n\n\t\t\t// If (pre)selected value is null, set value to #\n\t\t\tselected_value = selected_value == null || selected_value === \"\" ? \"#\" : selected_value;\n\n\t\t\t[].concat(_toConsumableArray(select.options)).forEach(function (item) {\n\t\t\t\tif (item.value === selected_value) {\n\t\t\t\t\tselect.value = item.value; // Set <select/> value\n\t\t\t\t}\n\t\t\t});\n\n\t\t\tbreak;\n\n\t\tcase \"select_multiple\":\n\t\t\tvar select_multiple = filter.querySelector(\"select\");\n\t\t\tif (!select_multiple) {\n\t\t\t\tbreak; // exit if empty\n\t\t\t}\n\n\t\t\t// If (pre)selected value is null, set value to #\n\t\t\tselected_value = selected_value == null || selected_value === \"\" ? \"#\" : selected_value;\n\n\t\t\t[].concat(_toConsumableArray(select_multiple.options)).forEach(function (item, index) {\n\t\t\t\tif (item.value === selected_value) {\n\t\t\t\t\tselect.value = item.value; // Set <select/> value\n\t\t\t\t} else {\n\t\t\t\t\titem.selected = false;\n\t\t\t\t}\n\t\t\t});\n\n\t\t\tbreak;\n\n\t\tdefault:\n\t\t\t// textfield\n\n\t\t\tvar input = filter.querySelector(\"input\");\n\t\t\tif (!input) {\n\t\t\t\tbreak; // exit if empty\n\t\t\t}\n\n\t\t\tinput.value = \"\";\n\n\t\t\tbreak;\n\t}\n}", "componentDidMount() {\n const defaultSelect = this.props.options.filter(\n obj => obj.label === this.props.defaultInputValue\n );\n\n if (defaultSelect.length === 1) {\n this.handleChange(defaultSelect[0]);\n }\n }", "_highlightCorrectOption() {\n if (this._keyManager) {\n if (this.empty) {\n this._keyManager.setFirstItemActive();\n }\n else {\n this._keyManager.setActiveItem(this._selectionModel.selected[0]);\n }\n }\n }", "function editItem(currItem) {\n //if item found select combo\n\n //else set combo to please select\n\n }", "function select_dropdown_item (item) {\n if(item) {\n if(selected_dropdown_item) {\n deselect_dropdown_item($(selected_dropdown_item));\n }\n\n item.addClass(settings.classes.selectedDropdownItem);\n selected_dropdown_item = item.get(0);\n }\n }", "function select_dropdown_item (item) {\n if(item) {\n if(selected_dropdown_item) {\n deselect_dropdown_item($(selected_dropdown_item));\n }\n\n item.addClass(settings.classes.selectedDropdownItem);\n selected_dropdown_item = item.get(0);\n }\n }", "function selectItemByValue(elmnt, value){\n\n\t\t\tfor(var i=0; i < elmnt.options.length; i++)\n\t\t\t{\n\t\t\t\tif(elmnt.options[i].value == value)\n\t\t\t\telmnt.selectedIndex = i;\n\t\t\t}\n\t\t}", "function allselect(){ \n for(var i=0; i<$('category_ids').options.length;i++){\n $('category_ids').options[i].defaultSelected=true;\n }\n}", "get selectedOption() {\n\t\treturn this.options.find((option) => option.selected);\n\t}", "function setSelectedIndex(s, valsearch) {\r\n\r\n document.getElementById(\"currentAniType\").value = currentAniType;\r\n\r\n // Loop through all the items in drop down list\r\n for (i = 0; i< s.options.length; i++) { \r\n\r\n if (s.options[i].value == valsearch) {\r\n s.options[i].selected = true; // Item is found. Set its property and exit\r\n break;\r\n }\r\n }\r\n\r\n return;\r\n}", "get selectedItem() {\n let selectedElement = this._widget.selectedItem;\n if (selectedElement) {\n return this._itemsByElement.get(selectedElement);\n }\n return null;\n }", "activateDefaultMenu() {\r\n const activeMenus = this.getRenderedMenuItems() && this.getRenderedMenuItems().filter(menu => {\r\n return menu && menu['active'];\r\n });\r\n if (activeMenus && activeMenus.length === 0) {\r\n const firstMenu = this.getRenderedMenuItems()[0];\r\n if (firstMenu) {\r\n firstMenu['active'] = true;\r\n }\r\n }\r\n }", "getDefaultOption(boardId) {\n const ret = {\n 'boardId' : \"\",\n 'swimlaneId' : \"\",\n 'listId' : \"\",\n }\n return ret;\n }", "get selected() {\n if (this.isObject(this.options)) {\n return this.options.selected;\n }\n else {\n return this.__selected;\n }\n }", "setDefault() {\n\n if ( this.options.default ) {\n\n this.$field.val(this.options.default).change();\n }\n }", "function defaultOpt() {\n //\n const de = document.createElement(\"option\");\n de.innerText = \"Please select a T-shirt theme\";\n colorOpt.append(de);\n\n color.style.display = \"none\";\n}", "function populateCountry(defaultCountry) {\n if ( postCountry != '' ) {\n defaultCountry = postCountry;\n }\n var countryLineArray = country.split('|'); // Split into lines\n var selObj = document.getElementById('countrySelect');\n selObj.options[0] = new Option('Select Country','');\n selObj.selectedIndex = 0;\n for (var loop = 0; loop < countryLineArray.length; loop++) {\n lineArray = countryLineArray[loop].split(':');\n countryCode = TrimString(lineArray[0]);\n countryName = TrimString(lineArray[1]);\n if ( countryCode != '' ) {\n selObj.options[loop + 1] = new Option(countryName, countryCode);\n }\n if ( defaultCountry == countryCode ) {\n selObj.selectedIndex = loop + 1;\n }\n }\n}", "function selectJumpMenuOption(){\n \n //default selection\n GselJumpMenus.selectedIndex = 0;\n \n if ( GarrJumpMenus.length == 1 )\n return;\n else {\n //check if it is possible to select a menu in the \n\t //same form as the current selection\n var selObj = dw.getDocumentDOM().getSelectedNode();\n var currFormObj = getFormObj(selObj);\n\t var nMenus = GselJumpMenus.length;\n \n for (i=0;i<nMenus;i++){\n\t if ( GarrJumpMenus[i].form == currFormObj ){\n\t\t GselJumpMenus.selectedIndex = i;\n\t\t\tbreak;\n\t\t } \n\t }\n }\n}", "placeholderOption() {\n return this.props.placeholderOption ? this.props.placeholderOption : this.props.DropdownOptions[0];\n }", "function getElementDefault(type) {\n \"use strict\";\n\n return eDefaultsDB.findOne({\"_id\": type});\n}", "handleDefault() {\n if (this.savedCards.length === 1) {\n this.$refs.cardDropdown.setDropdownLabel(this.savedCards[0].label);\n this.setData(this.savedCards[0]);\n } else if (this.selectedCard && this.selectedCard.cardNumber) {\n const cardSelected = {};\n cardSelected.cardNumber = this.selectedCard.cardNumber\n ? this.selectedCard.cardNumber.match(/\\d+/)[0]\n : '';\n cardSelected.cardType = this.selectedCard.cardType.name;\n cardSelected.label = `<${this.selectedCard.cardType.name}> <${\n this.selectedCard.cardNumber\n }> <${this.selectedCard.expiryMonth}/${\n this.selectedCard.expiryYear\n }> <${this.selectedCard.accountHolderName}>`;\n cardSelected.paymentId = this.selectedCard.id;\n cardSelected.billingAddress = this.selectedCard.billingAddress;\n cardSelected.address = this.setAddress(this.selectedCard);\n cardSelected.accountHolderName = this.selectedCard.accountHolderName;\n this.$refs.cardDropdown.setDropdownLabel(cardSelected.label);\n this.setData(cardSelected);\n } else {\n this.savedCards.map((item) => {\n if (item.default) {\n this.$refs.cardDropdown.setDropdownLabel(item.label);\n this.setData(item);\n }\n });\n }\n }", "function getSelectedOption(){\n\n}", "function populateCountry(defaultCountry) {\r\n if ( postCountry != '' ) {\r\n defaultCountry = postCountry;\r\n }\r\n var countryLineArray = country.split('|'); // Split into lines\r\n var selObj = document.getElementById('countrySelect');\r\n selObj.options[0] = new Option('Select Country','');\r\n selObj.selectedIndex = 0;\r\n for (var loop = 0; loop < countryLineArray.length; loop++) {\r\n lineArray = countryLineArray[loop].split(':');\r\n countryCode = TrimString(lineArray[0]);\r\n countryName = TrimString(lineArray[1]);\r\n if ( countryCode != '' ) {\r\n selObj.options[loop + 1] = new Option(countryName, countryCode);\r\n }\r\n if ( defaultCountry == countryCode ) {\r\n selObj.selectedIndex = loop + 1;\r\n }\r\n }\r\n}", "function selectOption (eid, selval, defval) {\n if (selval == undefined) {\n\t selval = defval;\n }\n var select = document.getElementById(eid);\n for (var i = 0; i < select.children.length; i++) {\n\t var child = select.children[i];\n\t if (child.value == selval) {\n\t\t child.selected = \"true\";\n\t\t break;\n\t }\n }\n}", "_setSelectedOption() {\n if (this.options.length > 1) super._setSelectedOption();\n }", "get defaultStepIndex() {\n // This value can be either:\n // - the index of a wizard step with a `selected` directive, or\n // - the default step index, set in the [[WizardComponent]]\n const foundDefaultStep = this.wizardSteps.find(step => step.defaultSelected);\n if (foundDefaultStep) {\n return this.getIndexOfStep(foundDefaultStep);\n }\n else {\n return this._defaultStepIndex;\n }\n }", "function getSelectedOption(options, value) {\n var flatOptions = flattenOptions(options);\n var selectedOption = flatOptions.find(function (option) {\n return value === option.value;\n });\n if (selectedOption === undefined) {\n // Get the first visible option (not the hidden placeholder)\n selectedOption = flatOptions.find(function (option) {\n return !option.hidden;\n });\n }\n return selectedOption ? selectedOption.label : '';\n}", "function setDefaultInputValue() {\n if (!lodash.isNil(ctrl.selectedItem)) {\n ctrl.typedValue = getName(angular.isDefined(ctrl.selectPropertyOnly) ?\n lodash.find(ctrl.valuesArray, [ctrl.selectPropertyOnly, ctrl.selectedItem]) : ctrl.selectedItem);\n\n if (ctrl.typedValue === '' && ctrl.enableTyping) {\n ctrl.typedValue = ctrl.selectedItem;\n }\n }\n }", "function addDefaultOption(select) {\n let option = document.createElement(\"option\");\n option.value = \"default\";\n option.textContent = \"Please make a selection\";\n select.append(option);\n}", "function pleaseSelect(state) {\n let shirtNode = document.getElementById('color').firstElementChild;\n let defaultColor = document.createElement('option');\n let colorText = document.createTextNode('Please Select a Shirt Color');\n\n if (state === true) {\n defaultColor.setAttribute('selected', '');\n defaultColor.setAttribute('value', 'default');\n defaultColor.appendChild(colorText);\n shirtColor.insertBefore(defaultColor, shirtNode);\n }\n}", "function doFirstSelect(container){\r\n\t\tvar state = $.data(container, 'tabs')\r\n\t\tvar tabs = state.tabs;\r\n\t\tfor(var i=0; i<tabs.length; i++){\r\n\t\t\tvar opts = tabs[i].panel('options');\r\n\t\t\tif (opts.selected && !opts.disabled){\r\n\t\t\t\tselectTab(container, i);\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t}\r\n\t\tselectTab(container, state.options.selected);\r\n\t}", "function fixDefaultChecked( elem ) {\n if ( rcheckableType.test( elem.type ) ) {\n elem.defaultChecked = elem.checked;\n }\n}", "function fixDefaultChecked( elem ) {\n if ( rcheckableType.test( elem.type ) ) {\n elem.defaultChecked = elem.checked;\n }\n}", "marginItem(value) {\n \n \n let selectables = this.object_item(value).selectables;\n let selections = this.object_item(value).selections;\n \n \n if (selectables.length > 0) {\n\n selectables.addClass('OPTION-selected')\n .hide();\n\n selections.addClass('OPTION-selected')\n .show();\n\n this.object_item(value).options.prop('selected', true); // active selected original select\n\n\n\n }\n }", "function populateCountry(defaultCountry) {\n if ( postCountry != '' ) {\n defaultCountry = postCountry;\n }\n var countryLineArray = country.split('|'); // Split into lines\n var selObj = document.getElementById(\"countrySelect\");\n selObj.options[0] = new Option('Select Country',' ');\n selObj.selectedIndex = 0;\n for (var loop = 0; loop < countryLineArray.length; loop++) {\n lineArray = countryLineArray[loop].split(':');\n countryCode = TrimString(lineArray[0]);\n countryName = TrimString(lineArray[1]);\n if ( countryCode != '' ) {\n selObj.options[loop + 1] = new Option(countryName, countryCode);\n }\n if ( defaultCountry == countryCode ) {\n selObj.selectedIndex = loop + 1;\n }\n }\n}", "function fixDefaultChecked(elem) {\n if (rcheckableType.test(elem.type)) {\n elem.defaultChecked = elem.checked;\n }\n }", "get _hasPlaceholderOption() {\n return this.hasAttributeNS(null, \"required\") && !this.hasAttributeNS(null, \"multiple\") &&\n this._displaySize === 1 && this.options.length > 0 && this.options.item(0).value === \"\" &&\n this.options.item(0).parentNode._localName !== \"optgroup\";\n }", "autoshowselect(){\n cy.get('.border-left-0').click();\n cy.get('.dropdown-menu >').contains('Auto Shows').then(option => {\n cy.wrap(option).contains('Auto Shows');\n option[0].click();\n\n })\n \n }", "function fixDefaultChecked( elem ) {\n if ( rcheckableType.test( elem.type ) ) {\n elem.defaultChecked = elem.checked;\n }\n}", "function fixDefaultChecked( elem ) {\n if ( rcheckableType.test( elem.type ) ) {\n elem.defaultChecked = elem.checked;\n }\n}", "function fixDefaultChecked( elem ) {\n if ( rcheckableType.test( elem.type ) ) {\n elem.defaultChecked = elem.checked;\n }\n}", "function restore_options() {\n chrome.storage.local.get('default_mode',function(items){\n var mode_ = items['default_mode'];\n if (!mode_) {\n return;\n }\n var select = document.getElementById(\"mode\");\n for (var i = 0; i < select.children.length; i++) {\n var child = select.children[i];\n if (child.value == mode_) {\n child.selected = \"true\";\n break;\n }\n }\n });\n }", "select(item) {\n const that = this;\n\n if (typeof item === 'string') {\n item = that.getItem(item);\n if (!item) {\n return;\n }\n }\n if (typeof item === 'number') {\n item = that.getItem(item);\n if (!item) {\n return;\n }\n }\n\n if (item.grouped || item.readonly) {\n return;\n }\n\n if (that.selectionMode === 'none') {\n that.selectedIndexes = [];\n that.selectedValues = [];\n return;\n }\n\n if (!that._focusedItem !== item && that.selectionMode !== 'none') {\n if (that._focusedItem) {\n that._focusedItem._focused = false;\n }\n\n that._focusedItem = item;\n item._focused = true;\n }\n\n switch (that.selectionMode) {\n case 'one':\n if (that.selectedIndexes.length === 1 && that.selectedIndexes[0] === that._indexOf(item)) {\n return false;\n }\n\n that._previouslySelectedIndexes = that.selectedIndexes;\n\n if (that.selectedIndexes.length >= 1) {\n that.clearSelection();\n }\n\n that._select(item);\n delete that._previouslySelectedIndexes;\n return true;\n case 'zeroOrOne':\n if (that.selectedIndexes.length === 1 && that.selectedIndexes[0] === that._indexOf(item)) {\n that.unselect(item);\n return true;\n }\n\n that._previouslySelectedIndexes = that.selectedIndexes;\n\n if (that.selectedIndexes.length >= 1) {\n that.clearSelection();\n }\n\n that._select(item);\n delete that._previouslySelectedIndexes;\n return true;\n case 'radioButton':\n that._previouslySelectedIndexes = that.selectedIndexes;\n\n if (that.$.itemsInnerContainer.querySelectorAll('jqx-list-items-group').length > 0) {\n const group = item.parentNode;\n\n\n if (!item.selected) {\n for (let index in group.children) {\n const item = group.children[index];\n\n if (item.selected) {\n that.unselect(item);\n }\n }\n\n that._select(item);\n }\n\n delete that._previouslySelectedIndexes;\n return true;\n }\n else if (that.isVirtualized && that._groups.length > 0) {\n const group = item.group;\n\n if (!item.selected) {\n for (let index in group.items) {\n const item = group.items[index];\n\n if (item.selected) {\n that.unselect(item);\n }\n }\n\n that._select(item);\n }\n\n delete that._previouslySelectedIndexes;\n return true;\n }\n\n\n if (!item.selected) {\n if (that.selectedIndexes.length >= 1) {\n that.clearSelection();\n }\n\n that._select(item);\n }\n\n delete that._previouslySelectedIndexes;\n return true;\n case 'oneOrMany':\n if (!item.selected) {\n that._select(item);\n }\n else if (that.selectedIndexes.length > 1) {\n that.unselect(item);\n }\n return true;\n case 'zeroOrMany':\n case 'checkBox':\n if (!item.selected) {\n that._select(item);\n }\n else {\n that.unselect(item);\n }\n return true;\n case 'oneOrManyExtended': {\n const selectedValues = that.selectedValues;\n\n if (that._keysPressed['Control']) {\n if (that.selectedIndexes.length > 1) {\n if (item.selected) {\n that.unselect(item);\n that._focus(that._items[that.selectedIndexes[0]]);\n }\n else {\n that._select(item);\n }\n }\n else {\n that._select(item);\n }\n return true;\n }\n\n if (that._keysPressed['Shift']) {\n const selectedItem = that._items[that.selectedIndexes[0]];\n let index;\n\n that.clearSelection();\n\n const preventEvent = selectedValues.indexOf(selectedItem.value) >= 0 || selectedItem.selected;\n\n that._select(selectedItem, preventEvent);\n\n if (that._indexOf(selectedItem) > that._indexOf(item)) {\n index = that._indexOf(selectedItem) - 1;\n while (index >= that._indexOf(item)) {\n const item = that._items[index];\n const preventEvent = selectedValues.indexOf(item.value) >= 0 || item.selected;\n\n that._select(item, preventEvent);\n index--;\n }\n }\n else {\n index = that._indexOf(selectedItem) + 1;\n while (index <= that._indexOf(item)) {\n const item = that._items[index];\n const preventEvent = selectedValues.indexOf(item.value) >= 0 || item.selected;\n\n that._select(item, preventEvent);\n index++;\n }\n }\n\n const unselectedItems = [];\n\n for (let i = 0; i < selectedValues.length; i++) {\n unselectedItems.push(that.getItem(selectedValues[i]));\n }\n\n if (unselectedItems.length > 0 && !that._propertyChanging) {\n let selectedItems = [];\n\n for (let i = 0; i < that.selectedValues.length; i++) {\n const previousSelectedValue = that.selectedValues[i];\n\n if (selectedValues.indexOf(previousSelectedValue) < 0) {\n selectedItems.push(that.getItem(previousSelectedValue));\n }\n }\n\n that.$.fireEvent('change', {\n 'addedItems': selectedItems,\n 'removedItems': unselectedItems,\n 'selected': item.selected,\n 'disabled': item.disabled,\n 'index': that._indexOf(item),\n 'label': item.label,\n 'value': item.value\n });\n }\n\n return true;\n }\n\n for (let i = 0; i < selectedValues.length; i++) {\n const value = selectedValues[i];\n const selectedItem = that.getItem(value)\n\n if (item !== selectedItem) {\n that.unselect(selectedItem);\n }\n }\n\n that.clearSelection();\n that._select(item, selectedValues.indexOf(item.value) >= 0);\n return true;\n\n }\n }\n\n return false;\n }", "function fixDefaultChecked( elem ) {\n if ( elem.type === \"checkbox\" || elem.type === \"radio\" ) {\n elem.defaultChecked = elem.checked;\n }\n}", "function fixDefaultChecked( elem ) {\n if ( elem.type === \"checkbox\" || elem.type === \"radio\" ) {\n elem.defaultChecked = elem.checked;\n }\n}", "function fixDefaultChecked( elem ) {\n if ( elem.type === \"checkbox\" || elem.type === \"radio\" ) {\n elem.defaultChecked = elem.checked;\n }\n}", "function option(value, defaultValue) {\n\tif (value === null || value === undefined)\n\t\treturn defaultValue;\n\treturn value;\n}", "function getOptions(data, id, defaultVal)\r\n{\r\n\tvar arr = xrxFindElements(data, id);\r\n\tvar optionStr = \"\";\r\n\t\r\n\tfor (var i = 0; i < arr.length; i++)\r\n\t{\r\n\t\r\n\t\tvar val = xrxGetValue( arr[i] );\r\n\t\tvar displayVal = val;\r\n\t\tswitch (val)\r\n\t\t{\r\n\t\t\tcase \"MonochromeGrayscale\":\r\n\t\t\t\tdisplayVal = \"GrayScale\";\r\n\t\t\t\tbreak;\r\n\t\t\tdefault:\r\n\t\t\t\tbreak;\r\n\t\t}\r\n\t\t\r\n\t\tif (val == defaultVal)\r\n\t\t{\r\n\t\t\toptionStr += '<option selected value=\"' + val + '\">' + displayVal + '</option>';\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\toptionStr += '<option value=\"' + val + '\">' + displayVal + '</option>';\r\n\t\t}\r\n\t}\r\n\r\n\treturn optionStr;\r\n}", "function fixDefaultChecked( elem ) {\n if ( manipulation_rcheckableType.test( elem.type ) ) {\n elem.defaultChecked = elem.checked;\n }\n}", "function resetSingleOption() {\n document.getElementById('url').value = DEFAULT_IMAGE_URLS[0];\n}", "function getCurrentOption() {\n return _.isValidIndex($activeIndex, $variations) && $variations[$activeIndex].selected_options || null;\n }", "get defaultValue() {\n return this.getStringAttribute('default_value');\n }", "get selectedOption() {\n return this.options.find((option) => option.selected);\n }", "function setDefaults(){\n\n $(\"#311MessageDBsummary\\\\.fmw span.db_connection.fmes-form-component select\").prop(\"disabled\", true);\n\n $(\"#UpdateDepartmentDB\\\\.fmw span.db_connection.fmes-form-component select\").change(function() {\n var val = $(this).val();\n $('#311MessageDBsummary\\\\.fmw span.db_connection.fmes-form-component select option').each(function(){\n var val2 = $(this).html();\n if (val2 == val) {\n $(this).prop('selected', true);\n } else {\n $(this).prop('selected', false);\n }\n });\n });\n $(\"#311MessageDBsummary\\\\.fmw span.RequestType.fmes-form-component select\").prop(\"value\", \"ALL\");\n $(\"#311MessageDBsummary\\\\.fmw span.Status.fmes-form-component select\").prop(\"value\", \"ALL\");\n $(\"#311PublicMessageLoader\\\\.fmw span.RequestType.fmes-form-component select\").prop(\"value\", \"Safety\");\n}", "static select(obj) {\n if (obj[RepositoryManager.get_website()])\n return obj[RepositoryManager.get_website()];\n else if (obj.default)\n return obj.default;\n else\n return null;\n }", "function findItem() {\n var found;\n\n $rootScope.claimItems.forEach(function (item) {\n if (item.selected == true) {\n found = item;\n }\n });\n return found;\n }", "function fixDefaultChecked( elem ) {\n if ( rcheckableType.test( elem.type ) ) {\n elem.defaultChecked = elem.checked;\n }\n }", "function fixDefaultChecked( elem ) {\n if ( rcheckableType.test( elem.type ) ) {\n elem.defaultChecked = elem.checked;\n }\n }", "set defaultItems(defaultItems) {\n this._defaultItems = defaultItems;\n }", "set defaultItems(defaultItems) {\n this._defaultItems = defaultItems;\n }", "set defaultItems(defaultItems) {\n this._defaultItems = defaultItems;\n }", "function findItem() {\n var found;\n\n $rootScope.claimItems.forEach(function (item) {\n if (item.selected == true) {\n found = item;\n }\n });\n return found;\n }", "function search_grupo(data,grupo) \r\n{\r\n $('#grupo_edit').empty();\r\n $('#grupo_edit').append('<option value=\"\" disabled>...</option>');\r\n $.each(data, function(i, val) {\r\n if (val.nombre == grupo) \r\n {\r\n grupo_id = val.id;\r\n $('#grupo_edit').append('<option value=\"'+val.id+'\" selected>'+val.nombre+'</option>');\r\n }\r\n else\r\n {\r\n $('#grupo_edit').append('<option value=\"'+val.id+'\">'+val.nombre+'</option>');\r\n }\r\n });\r\n selected = grupo_id;\r\n return selected;\r\n}", "function search_grupo(data,grupo) \r\n{\r\n $('#grupo_edit').empty();\r\n $('#grupo_edit').append('<option value=\"\" disabled>...</option>');\r\n $.each(data, function(i, val) {\r\n if (val.nombre == grupo) \r\n {\r\n grupo_id = val.id;\r\n $('#grupo_edit').append('<option value=\"'+val.id+'\" selected>'+val.nombre+'</option>');\r\n }\r\n else\r\n {\r\n $('#grupo_edit').append('<option value=\"'+val.id+'\">'+val.nombre+'</option>');\r\n }\r\n });\r\n selected = grupo_id;\r\n return selected;\r\n}", "setDefault() { }", "function fixDefaultChecked( elem ) {\n if ( manipulation_rcheckableType.test( elem.type ) ) {\n elem.defaultChecked = elem.checked;\n }\n }", "function getSelectedOption(options, value) {\n const flatOptions = flattenOptions(options);\n let selectedOption = flatOptions.find(option => value === option.value);\n\n if (selectedOption === undefined) {\n // Get the first visible option (not the hidden placeholder)\n selectedOption = flatOptions.find(option => !option.hidden);\n }\n\n return selectedOption || {\n value: '',\n label: ''\n };\n}", "function whichItemIsSelected(aComponent) {\n for (var i=0; i< aComponent.options.length; i++) {\n if (aComponent.options[i].selected) {\n\t return aComponent.options[i].value;\n }\n }\n return \"\";\n}", "function CargarComboDefectoUtil(objLista, rowDefault) {\n objLista.empty();\n if (rowDefault !== '' || rowDefault === undefined) {\n objLista.append($('<option/>', {\n value : \"\",\n text : rowDefault\n }));\n }\n}", "get selected() {\n const selected = this.selectionModel.selected;\n return this.multiple ? selected : (selected[0] || null);\n }" ]
[ "0.66718537", "0.6311194", "0.6039267", "0.6000806", "0.5955329", "0.59164506", "0.5895007", "0.58630586", "0.57978356", "0.5726508", "0.5656774", "0.56539035", "0.5653307", "0.5616319", "0.5609541", "0.5600866", "0.55922085", "0.55840874", "0.55624026", "0.55548036", "0.55530554", "0.5537193", "0.5537193", "0.55352914", "0.55327994", "0.5510763", "0.5507242", "0.5503434", "0.54991347", "0.5478199", "0.5462563", "0.5439454", "0.5405337", "0.5386072", "0.53844225", "0.53844225", "0.5342735", "0.5339402", "0.5322207", "0.5308326", "0.5307137", "0.52953637", "0.5279289", "0.52528226", "0.52527785", "0.52522993", "0.52513653", "0.5221457", "0.52190936", "0.5217511", "0.5186605", "0.5178815", "0.5173703", "0.51642543", "0.51567364", "0.5154648", "0.51542616", "0.5144961", "0.51398635", "0.51362306", "0.5125169", "0.5124975", "0.5124975", "0.5114992", "0.510812", "0.5103219", "0.51026994", "0.50997007", "0.509669", "0.509669", "0.509669", "0.5096332", "0.5092864", "0.50915515", "0.50915515", "0.50915515", "0.5087683", "0.50837255", "0.5081463", "0.5073926", "0.5072217", "0.50715977", "0.50714046", "0.50695294", "0.5069428", "0.5065427", "0.5064369", "0.5064369", "0.50633025", "0.50633025", "0.50633025", "0.5061809", "0.5059363", "0.5059363", "0.50520605", "0.50485396", "0.5048437", "0.50477713", "0.5039511", "0.5035497" ]
0.7483216
0
this component makes it so that it activates when the component first mounts
componentWillMount() { //string literal => having a variable with a part of a string axios.get(`${apibase}/posts?categories=4`).then(data => { this.setState({ posts: { data: data.data, loading: false } }) }) axios.get(`${apibase}/users`).then(data => { this.setState({ authors: { data: data.data, loading: false } }) }) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "componentDidMount() {\n this.componentLoaded = true;\n }", "componenetWillMount() { }", "componentDidMount() {\n\t\tthis.startup();\n\t}", "static activate() {\n \n }", "componenetDidMount() { }", "createdCallback() {\n\t // component will mount only if part of the active document\n\t this.componentWillMount();\n\t}", "componentDidMount() {\n\t\tthis.init();\n\t}", "onComponentMount() {\n\n }", "componentDidMount(){\n \n }", "componentDidMount() {\n M.AutoInit();\n }", "componentDidMount() {\n this.setState({\n mount: true\n })\n }", "componentDidMount() {\n this.handleJoke().then(() => {\n this.setState({ loaded: true });\n this.start();\n });\n }", "componentDidMount() {\n \n }", "componentDidMount() {\n \n }", "OnActivated() {}", "componentDidMount() {\n this.onLoad();\n }", "render() {\n if (!this.initialized) {\n this.init();\n }\n }", "componentDidMount () {\n this.init();\n }", "componentDidMount () {\n this.init();\n }", "componentDidMount () {\n this.init();\n }", "componentDidMount() {\n this._isMounted = true;\n if (!this.manuallyBindClickAway) {\n this._bindClickAway();\n }\n }", "componentDidMount() {\n\t\tthis.props.onLoad();\n\t}", "function activate() {\n\t\t}", "componentDidMount() {\n let state = this.state;\n this.mounted = true;\n this.setState( state );\n }", "componentDidMount(){\n console.log(\"I am in Component Did Mount\");\n setTimeout(() => {\n this.setState({initializing : false});\n },1000)\n console.log(\"------------------------------------------\");\n }", "activate() {\n this.active = true;\n }", "componentDidMount() { \n \n }", "constructor(props) { super(props); autoBind(this); }", "render() {\n if (!this.initialized) this.init();\n }", "componentDidMount() {\n const instance = this,\n props = instance.props,\n onMount = props.onMount;\n instance._domNode._itsa_focuscontainer = instance; // to have a reference to the instance\n // on every render-cycle, we need to re-calculate this._keysUp and this._keysDown:\n instance.defineMovementKeys();\n if (props.initialFocus!==undefined) {\n instance.setInitialFocus();\n }\n onMount && onMount();\n }", "componentDidMount() {\n this.setState({ hasLoaded: !this.state.hasLoaded });\n }", "componentDidMount() {\n // console.log(\"currentUserContainer Mounted\")\n this.init()\n }", "componentDidMount() {\n this.initialize();\n }", "componentWillMount() {\n \n }", "componentDidMount() {\n this._unsubscribe = this.props.navigation.addListener('focus', () => {\n this.forceUpdate();\n });\n }", "componentDidMount(){\n\n\n\n\n}", "componentDidMount()\n\t{\n\t\t// runs before render()\n\t\t// ensure we do not go to register if we are already logged in\n\t\tif (global.client != null)\n\t\t{\n\t\t // go back where we came from\n\t\t this.props.navigation.goBack();\n\t\t}\n }", "componentDidMount() {\n this.isOkToAdvance = true\n }", "init(){\n\t\tthis._active = true\n\t}", "componentDidMount() {\n \n }", "componentDidMount(){\n\t// set state of parent component...\n\tthis.props.fn.defaultUIStateConfiguration({\n\t lockAngles: false,\n\t previewActive: false, // i.e. the grid lines\n\t pointsActive: false, // i.e. the intersection points\n\t showAllGrids: false,\n\t showColourGrids: false\n\t});\n }", "beforerender (el) {\n console.log('Component is about to be rendered for the first time')\n\n // this is where you can register other lifecycle events:\n // on.resize()\n // on.ready()\n // on.intersect()\n // on.idle()\n }", "constructor(props) {\n super(props)\n this.state = {\n loaded: false\n }\n }", "function activate() {\n\n }", "componentDidMount() {\r\n\t\tthis.startTimer()\r\n\t}", "componentDidMount(){\n this.updateEventCards().then( () => {\n this.componentMounted = true;\n });\n }", "activate() {\n this.update();\n }", "componentDidMount() {\n this.props.onLoad();\n }", "async setActive() {\n await this.prepareLazyLoaded();\n this.active = true;\n }", "componentDidMount() {\n this.isMounted_ = true;\n this.loadPlayer();\n }", "componentDidMount() {\n this.forceUpdate();\n }", "componentDidMount()\n {\n\n }", "function activate(){\n\n\t\t}", "componentModalDidMount() {\n // Focus needs to be set when mounting and already open\n if (this.props.isOpen) {\n this.setFocusAfterRender(true);\n this.open();\n }\n }", "render() {\n // always reinit on render\n this.init();\n }", "render() {\n // always reinit on render\n this.init();\n }", "componentDidMount() {\n // wait 0.2s and fade in\n setTimeout(() => {\n document.body.style.display = 'block';\n document.body.style.opacity = '1';\n }, 200);\n }", "constructor() {\n super();\n this.state = {didLoad: false};\n }", "componentDidMount() {\n\n\t}", "componentDidMount() {\n this.setActiveBatch(1);\n }", "componentDidMount(){ //Cuando un compoennte se monta y se muestra en pantalla se llama este método\n console.log(\"did Mount\");\n }", "componentDidMount(){\n // in this case, start the prop as soon as Timer loads.\n this.start()\n }", "componentDidMount() {\n if (this.props.show) {\n this.show();\n this.loadContent();\n }\n\n if (this.props.hotkey) {\n window.addEventListener('keyup', this.handleWindowKeyup);\n }\n }", "componentDidMount(){\n console.log(\"El componente se ha montado\")\n }", "onInit() {}", "componentDidMount() {\n\t\tthis.setQueryInfo();\n\t\tthis.createChannel();\n\t}", "async setActive() {\n await this.prepareLazyLoaded();\n this.active = true;\n }", "componentDidMount() {\n setTimeout(() => {\n this._bootstrapAsync()\n }, 3000)\n }", "async componentDidMount() {\n // let scenes actively listen to new received notif\n this.listener = Notifications.addListener(this.listen);\n // load all the required user data if user is logged-in\n if (this.props.auth.isAuthenticated) {\n // retrieve and setup data\n this.setupUserAppData();\n }\n }", "componentDidMount () {\n\n\t}", "componentDidMount () {\n\n\t}", "function viewWillMount() {\n // stub\n }", "componentDidMount() {\n\n console.log(\"componentDidMount()\");\n\n window.readyForStuff = this.readyForStuff.bind(this);\n\n }", "componentDidMount() {\n this.engine = new Engine();\n this.engine.initialize(this.el, {\n onStationClicked: this.handleStationClicked\n });\n this.addStations();\n\n setInterval(this.handleTimer, 1000);\n }", "componentDidMount() {\n console.log('App component was rendered to the screen');\n this.setCurrentPosition();\n }", "componentDidMount() {\n // Set media session for mobile notifications/lockscreen display\n this.setMediaSession()\n\n // Keyboard controls\n document.addEventListener('keyup', this.handleOnKeyUp, false)\n\n // Prevent spacebar scrolling\n document.addEventListener('keydown', this.handleOnKeyDown, false)\n }", "componentDidMount() {\n // loading the list for the first time\n this.loadList();\n }", "constructor(props) {\n super(props);\n this.state = {\n isLoaded: false,\n }\n }", "componentDidMount() {\n this.setup();\n }", "componentDidMount() {\n this.addBlankProposal();\n // this.initMaterialComponent();\n }", "componentDidMount() { this.props.events.on('update', this.forceUpdate); }", "function componentDidMount ()\n {\n\n }", "async componentDidMount() {\n\t\tawait Font.loadAsync({\n\t\t 'Cabin-Regular': require('../assets/fonts/Cabin-Regular.ttf'),\n\t\t 'Cabin-Bold': require('../assets/fonts/Cabin-Bold.ttf')\n\t\t});\n\t\tthis.setState({fontLoaded : true});\n\t\tawait this.fetch_state();\n\t\tthis.focusListener = this.props.navigation.addListener(\"didFocus\", () => {\n\t\t\tthis.render()\n\t\t});\n\t}", "componentDidMount() {\n if (this.props.enabled) this.bindHandlers();\n }", "componentDidMount() {\n\t\tthis.linksTracker = Tracker.autorun(() => { // used to track changes to what you define from within, and then returns the changes\n\t\t\tMeteor.subscribe('linksPublication') // calls out to the publication in api/links.js\n\t\t\tconst returnedLinks = Links.find({\n\t\t\t\tvisible: Session.get('showVisible') // filter db query based on session set value\n\t\t\t}).fetch();\n\t\t\tthis.setState({ links: returnedLinks })\n\t\t})\n\t}", "componentDidMount() {\n this.windowOnLoadOverride()\n this.listenToScrollEvent()\n }", "didMount() {\n }", "componentDidMount() {\n this.props.onMount();\n }", "componentDidMount() {\n // For Dimention Changing Runtime Responsiveness\n AddOrientation(this);\n }", "componentDidMount() {\n this.checkMobileMode();\n printDebug(\"Launching App in mobile mode: \" + this.state.mobileMode);\n this.setState({disclaimerShown: true});\n }", "componentDidMount(){\n }", "componentWillMount() {\n console.log('Before component gets created.');\n //document.querySelector('h4').style.color = 'red';\n // this line will throw an error. because we are trying to access which is not created yet.\n }", "componentDidMount() {\n DeviceEventEmitter.addListener('event.ready', this.app_ready);\n DeviceEventEmitter.addListener(\n 'event.is_search_empty',\n this.is_search_empty,\n );\n }", "componentDidMount() {\n\t\t\n\t\t\n\t\tlet metas = [\n\t\t\t{name: \"description\", content: \"Profile Description\"},\n\t\t\t{property: \"og:type\", content: \"article\"}\n\t\t];\n\t\tthis.props.dispatch(appUpdate({title:'Profile',metas: metas}))\n\t\t\n\t\t\n\t\t// start a timer for the clock:\n\t\tthis.timer = setInterval(this.updateTime, 1000);\n\t\tthis.updateTime();\n\n\t\t// every time we get remounted, increment a counter:\n\t\tthis.setState({ count: this.state.count+1 });\n\t}", "componentDidMount () {\n\n }", "componentDidMount() {\n this.mounted = true;\n this.animationID = setInterval(() => this.setPosition(), 17); // 17ms interval to approximate a 60fps animation\n }", "componentDidMount() {\n this._isMounted = true;\n this.getLocation();\n this.getGame();\n }", "componentDidMount () {\n\t\t//监听UserStore\n\t\tthis.unUserStoreChange = UserStore.listen(this.onUserStoreChange);\n\n\t\tInteractionManager.runAfterInteractions(() => {\n\t\t\tthis.setState({doRenderScene: true}, () => {\n\t\t\t\tthis.fetchData();\n\t\t\t});\n\t\t});\n\t}", "render() {\n return (this.props.ready) ? this.renderPage() : <Loader active>Getting Vendor</Loader>;\n }", "componentWillMount() {\n alert('AND NOW, FOR THE FIRST TIME EVER... FLASHY!!!!');\n }", "componentDidMount() {\n // if table's length is zero show the EmptyPlaceHolder and hide the table\n if (!this.state.tableData.length) {\n this.setState({table: false})\n this.allPlaceHolderTimeout = setTimeout(() => {\n this.refs.allPlaceHolder.setState({visible: true})\n }, 700)\n }\n // add emitter event listener\n Subscriptions.push(mrEmitter.addListener('onUpdateData', (updateData) => this.setState({tableData: updateData.filter(this.filterDownloader)})))\n }" ]
[ "0.6792422", "0.67576414", "0.66770416", "0.6661768", "0.6653347", "0.6596883", "0.6535452", "0.64971936", "0.6484291", "0.6475996", "0.6475131", "0.6460934", "0.64525694", "0.64525694", "0.6447056", "0.6414914", "0.63829505", "0.6374859", "0.6374859", "0.6374859", "0.6350301", "0.6340667", "0.63048893", "0.6303815", "0.6300907", "0.629496", "0.6258285", "0.6247051", "0.6222564", "0.6218244", "0.6214162", "0.6213735", "0.6211362", "0.6208426", "0.6195953", "0.6184104", "0.61820185", "0.6181537", "0.6178687", "0.61698025", "0.6163946", "0.61635554", "0.6162288", "0.6152084", "0.614159", "0.6138962", "0.6134588", "0.6124709", "0.61242324", "0.6122815", "0.61200565", "0.6115411", "0.6100141", "0.60967857", "0.60931015", "0.60931015", "0.60897934", "0.6087793", "0.60875607", "0.6086887", "0.6086724", "0.6079375", "0.6075693", "0.60714394", "0.60682976", "0.60648745", "0.60625213", "0.60596305", "0.60531956", "0.6045986", "0.6045986", "0.6044873", "0.6041717", "0.6038542", "0.6037208", "0.60316247", "0.6030938", "0.6019818", "0.60169077", "0.6014288", "0.6011929", "0.60084414", "0.599616", "0.59952474", "0.59946465", "0.5992061", "0.5989671", "0.59867734", "0.59856033", "0.5985457", "0.5982859", "0.59824467", "0.5979547", "0.5976326", "0.59746295", "0.597418", "0.5972977", "0.5969061", "0.5967398", "0.59659946", "0.5958706" ]
0.0
-1
busca el valor de apertura (de la propiedad OPEN) de cada dia (propiedad DTYYYYMMDD)(el primer valor de apertura de cada dia)
function buscarAperturaDia(array) { let day; let arr = []; for (let i = 0; i < array.length; i++) { let date = array[i].DTYYYYMMDD; if (day != date) { day = date; for (let j = 0; j < array.length; j++) { if (array[j].DTYYYYMMDD === day) { arr.push(array[j].OPEN); break; } } } } //console.log('Apertura:', arr) return arr; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function dadosDiaAtual(diasMonitorados) {\n\n\tvar posDiaAtual = diasMonitorados.length - 1;\n\tvar dadosDiaAtual = diasMonitorados[posDiaAtual];\n\n\treturn dadosDiaAtual;\n}", "function diaClave(propie){\n\n\tfor(i=0; i< propie.length; i++){\n\t\tvar info = propie[i].properties;\t\n\n\t\tconst latitud = info.LATITUD;\t \n\t\tconst longitud = info.LONGITUD;\t\t \n\t\tconst fecha = info.FECHA;\n\t\tconst pm10 = info.PM_10;\n\t\tconst pm25 = info.PM_2_5;\n\t\tconst NO2 = info.NO2;\n\t\tconst NO = info.NO;\n\t\tconst co = info.CO;\n\t\tconst so2 = info.SO2;\n\n\t\tconst fechaFormulario = document.querySelector('input[name=\"trip\"]').value;\t\n\t\t\t\n\t\t\n\t\tconst unicaFecha = new Date(fechaFormulario);\n\t\tconst transcurso1 = unicaFecha.getTime()\n\t\t\t\n\n\t\t//capturar la fecha del WFS y convertirla a milisegundos\n\t\t\n\t\t\n\t\tconst fechaWFS = new Date(info.FECHA);\t\t\t \t\n\t\tconst fechaWFStra = fechaWFS.getTime();\t\n\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t \n\t\t\tif(fechaWFStra === transcurso1){\n\t\t\t\t\t const informacion = new Estaciones(latitud, longitud, fecha, pm10, pm25, NO2, NO, co, so2 )\t\n\t\t\t\t\t\t\t const fech = informacion.fecha;\n\t\t\t\t\t\t\t const pm_10 = informacion.pm10;\n\t\t\t\t\t\t\t const pm_2_5 = informacion.pm25;\n\t\t\t\t\t\t\t const no2 = informacion.NO2;\n\t\t\t\t\t\t\t const No = informacion.NO;\n\t\t\t\t\t\t\t const Co = informacion.co;\n\t\t\t\t\t\t\t const So2 = informacion.so2;\n\t\t\t\t\t\t\t\n\t\t\t\t\t const gas = $('#filter2').val();\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t //escogerGas(gas);\n\t\t\t\t\tswitch (gas) {\n\t\t\t\t\t\tcase 'PM_10':\n\n\t\t\t\t\t\t\tvar marker = L.circle([latitud, longitud], {radius: (pm_10*10), stroke:true, color: coloresPM10(pm_10) }).bindPopup(`\n\t\t\t\t\t\t\t<h5>Información</h5>\n\t\t\t\t\t\t\t<ol>\n\t\t\t\t\t\t\t<li>Fecha: ${fechaFormulario}</li>\n\t\t\t\t\t\t\t<li>Medicion de Gas Promedio PM10: ${pm_10.toString()}</li>\n\t\t\t\t\t\t\t\t</ol>` ).addTo(mymap);\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tmymap.fitBounds(marker.getBounds(), { padding: [20, 20] });\t\n\t\t\t\t\t\t\t\tlimpiarMapa(marker);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'PM_2_5':\n\n\t\t\t\t\t\t\tvar marker = L.circle([latitud, longitud], {radius: (pm_2_5*10), stroke:true, color: coloresPM25(pm_2_5) }).bindPopup(`<ol>\n\t\t\t\t\t\t\t<li>${fechaFormulario}</li>\t\n\t\t\t\t\t\t\t<li>${pm_2_5.toString()}</li>\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t</ol>` ).addTo(mymap);\n\t\t\t\t\t\t\t\tmymap.fitBounds(marker.getBounds(), { padding: [20, 20] });\t\n\t\t\t\t\t\t\t\tlimpiarMapa(marker);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'N02':\n\n\t\t\t\t\t\t\tvar marker = L.circle([latitud, longitud], {radius: (no2*10), stroke:true, color: coloresNO(no2) }).bindPopup(`<ol>\n\t\t\t\t\t\t\t<li>${fechaFormulario}</li>\n\t\t\t\t\t\t\t<li>${no2.toString()}</li>\n\t\t\t\t\t\t\t\t</ol>` ).addTo(mymap);\n\t\t\t\t\t\t\t\tmymap.fitBounds(marker.getBounds(), { padding: [20, 20] });\n\t\t\t\t\t\t\t\tlimpiarMapa(marker);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'NO':\n\n\t\t\t\t\t\t\tvar marker = L.circle([latitud, longitud], {radius: (No*10), stroke:true, color: coloresNO(No) }).bindPopup(`<ol>\n\t\t\t\t\t\t\t<li>${fechaFormulario}</li>\t\n\t\t\t\t\t\t\t<li>${No.toString()}</li>\n\t\t\t\t\t\t\t\t</ol>` ).addTo(mymap);\n\t\t\t\t\t\t\t\tmymap.fitBounds(marker.getBounds(), { padding: [20, 20] });\t\n\t\t\t\t\t\t\t\tlimpiarMapa(marker);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'CO':\n\n\t\t\t\t\t\t\tvar marker = L.circle([latitud, longitud], {radius: (Co*10), stroke:true, color: coloresCO(Co) }).bindPopup(`<ol>\n\t\t\t\t\t\t\t<li>${fechaFormulario}</li>\n\t\t\t\t\t\t\t<li>${Co.toString()}</li>\n\t\t\t\t\t\t\t\t</ol>` ).addTo(mymap);\n\t\t\t\t\t\t\t\tmymap.fitBounds(marker.getBounds(), { padding: [20, 20] });\t\n\t\t\t\t\t\t\t\tlimpiarMapa(marker);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'SO2':\n\n\t\t\t\t\t\t\tvar marker = L.circle([latitud, longitud], {radius: (So2*10), stroke:true, color: coloresSO2(So2) }).bindPopup(`<ol>\n\t\t\t\t\t\t\t<li>${fechaFormulario}</li>\t\t\t\t\t\n\t\t\t\t\t\t\t<li>${So2.toString()}</li>\n\t\t\t\t\t\t\t\t</ol>` ).addTo(mymap);\n\t\t\t\t\t\t\t\tmymap.fitBounds(marker.getBounds(), { padding: [20, 20] });\t\n\t\t\t\t\t\t\t\tlimpiarMapa(marker);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\t\t\tdefault: console.log('no funciona');\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\t \n\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t }\n\t\t\t\t else{\n\t\t\t\t\t\t\t console.log('no selecciono nada')\n\t\t\t\t\t\t }\n\t\t }\n\n}", "function eq_tempo_data2(anno,njd){\n\n // funzione per il calcolo dell'equazione del tempo.\n // by Salvatore Ruiu Irgoli-Sardegna (Italy) gennaio 2012.\n // algoritmo di MEEUS.\n \n njd=jdHO(njd); // riporta il g.g. all'ora H0(zero) del giorno. \n \nvar ar_sole=pos_sole(njd); // calcolo dell'ascensione retta del sole.\nvar ar_sole_app=pos_app(njd,ar_sole[0],ar_sole[1]);\nvar TSG=temposid_app(njd);\nvar valore_et=0;\nvar h=TSG-ar_sole_app[0];\n \nif(h<0 ) {valore_et=12+h;}\nif(h>0 ) {valore_et=h-12;}\n \n valore_et=valore_et*60; // valore in minuti.\n\n valore_et=valore_et.toFixed(6);\n\nreturn valore_et\n\n}", "function getDataAtual(exibeSeparador, exibeHoras){\n // ajustando a data atual\n var fullDate = new Date();\n // acrescenta o 0 caso o mes for menor que 10\n var mes = (\"0\" + (fullDate.getMonth() + 1)).slice(-2);\n // acrescenta o 0 caso o dia for menor que 10\n var dia = (\"0\" + fullDate.getDate()).slice(-2);\n // acrescenta o 0 caso a hora for menor que 10\n var horas = (\"0\" + fullDate.getHours()).slice(-2);\n\n if (exibeHoras){\n return fullDate.getFullYear() + mes + dia;// + horas;\n }\n\n if (exibeSeparador){\n return fullDate.getFullYear() + '-' + mes + '-' + dia;\n } \n}", "function obtenerValoresPorDias(array) {\n let res;\n let dia = diaMes(array)\n let apertura = buscarAperturaDia(array);\n let max = buscarMaxDia(array);\n let min = buscarMinDia(array);\n let cierre = buscarCierreDia(array);\n res = [dia, apertura, max, min, cierre];\n return res;\n}", "function diasMonitoradosPaciente() {\n\tvar diasMonitorados = pacientesJson[numIdPacAtual].diasMonitorados;\n\n\treturn diasMonitorados;\n}", "function calcola_datan2(lingua){\n\n // parametri lingua= \"ITA\" - \"ING\" \n // by Salvatore Ruiu Irgoli-Sardegna (Italy) dicembre 2009.\n // utilizzo caratteri speciali ANSI.\n // restituisce la stringa DataIns.\n \n\t \n\tvar DataInsn=\".\";\n \n var data=new Date();\n\n var anno =data.getYear(); // anno\n var mese =data.getMonth(); // mese 0 a 11 \n var giorno=data.getDate(); // numero del giorno da 1 a 31\n var giorno_settimana=data.getDay(); // giorno della settimana 0 a 6\n var ora =data.getHours(); // ora del giorno da 0 a 23\n var minuti=data.getMinutes(); // minuti da 0 a 59\n var secondi=data.getSeconds(); // secondi da 0 a 59\n \n if (anno<1900) { anno=anno+1900; } // correzione anno\n\n if (ora<10){ ora='0'+ora;}\n \n if (minuti<10){minuti='0'+minuti;}\n\n if (secondi<10) {secondi='0'+secondi;}\n\n mese=mese+1;\n\n if (lingua==\"ING\") { DataInsn=mese+\":\"+giorno+\":\"+anno+\":\"+ora+\":\"+minuti+\":\"+secondi }\n else { DataInsn=giorno+\":\"+mese+\":\"+anno+\":\"+ora+\":\"+minuti+\":\"+secondi }\n\n return DataInsn;\n }", "function llenarComboDias(nombreCombo) {\r\n\tFECHA_INICIO = new String(document.formularioFiltro.fechaInicio.value);\r\n\tFECHA_FIN = new String(document.formularioFiltro.fechaFinRegistro.value);\r\n\tvar arregloInicio = FECHA_INICIO.split(\"/\");\r\n\tvar diaInicio = arregloInicio[0];\r\n\tvar mesInicio = arregloInicio[1];\r\n\tvar annoInicio = arregloInicio[2];\r\n\tmesInicio = mesInicio - 1;\r\n\tvar fechaInicio = new Date(annoInicio, mesInicio, diaInicio);\r\n\tvar diasSiguiente = 0;\r\n\tvar stringDia = \"\";\t//Este string es una variabla auxiliar para guardar el dia y agregarlo al combo\r\n\tlimpiarCombo(document.formularioFiltro.valorDia);\t\r\n\t\r\n\t//Agregamos la primera opcion del combo vacia \r\n\tstringDia = \"\";\r\n\taddOption(document.formularioFiltro.valorDia, stringDia, 0);\r\n\tfor (var i = 0; i < 7; i++) {\r\n\t\tdiasSiguiente = fechaInicio.getTime() + ((24 * 60 * 60 * 1000) * i);\r\n\t\r\n\t\t// Cosntruimos el objeto Date con la cantidad de\r\n\t\t// miliseg que representan cada dia de la semana\r\n\t\tvar fecha = new Date(diasSiguiente);\r\n\t\tvar dia = fecha.getDate();\r\n\t\tvar mes = fecha.getMonth() + 1;\r\n\t\tvar anno = fecha.getFullYear();\r\n\t\tstringDia = dia + \"/\" + mes + \"/\" + anno;\t\t\r\n\t\t\r\n\t\t// agregamos la opcion\r\n\t\taddOption(document.formularioFiltro.valorDia, stringDia, i);\r\n\t}\r\n}", "function calcola_datan(lingua){\n\n // parametri lingua= \"ITA\" - \"ING\" \n // by Salvatore Ruiu Irgoli-Sardegna (Italy) dicembre 2009.\n // utilizzo caratteri speciali ANSI.\n // restituisce la stringa DataIns.\n // utilizzata solo per il datario delle fasi lunari\n // per la data completa utilizzare [calcola_datan2(lingua)]\n\t \n\tvar DataInsn=\".\";\n \n var data=new Date();\n\n var anno =data.getYear(); // anno\n var mese =data.getMonth(); // mese 0 a 11 \n var giorno=data.getDate(); // numero del giorno da 1 a 31\n var giorno_settimana=data.getDay(); // giorno della settimana 0 a 6\n var ora =data.getHours(); // ora del giorno da 0 a 23\n var minuti=data.getMinutes(); // minuti da 0 a 59\n var secondi=data.getSeconds(); // secondi da 0 a 59\n \n if (anno<1900) { anno=anno+1900; } // correzione anno\n\n if (ora<10){ ora='0'+ora;}\n \n if (minuti<10){minuti='0'+minuti;}\n\n if (secondi<10) {secondi='0'+secondi;}\n\n mese=mese+1;\n\n if (lingua==\"ING\") { DataInsn=mese+\":\"+giorno+\":\"+anno+\":\"+ora }\n else { DataInsn=giorno+\":\"+mese+\":\"+anno+\":\"+ora }\n\n return DataInsn;\n }", "function specialDay( stDay )\n{\n var stValue = window.opener.dialogIdField + \"~\"+ getTextValue( \"stType\" );\n stValue += \"~\" + getTextValue( \"stComment\" )+\"~\"+stDay+ \"~Pending\";\n //alert( \" specialDay= \" + stValue );\n if ( window.opener.dialogMulti == 492 )\n {\n window.opener.dialogF1.value = getTextValue( \"stType\" );\n window.opener.dialogF2.value = getTextValue( \"stComment\" );\n window.opener.dialogF3.value = stDay;\n window.opener.dialogF4.value = \"Pending\";\n if ( window.opener.dialogDisplayField.value.toString().length > 0 )\n window.opener.dialogDisplayField.value += \"\\n|\";\n window.opener.dialogDisplayField.value += stValue;\n }\n window.close();\n}", "function checkOpen(){\n //I've used moment to handle the date because it offers a more usable interface \n //than the Date obj in JS\n //the library is made in USA so\n //isoWeekDay is the number of the day in a week,\n //and it starts with sunday == 1\n\t var today = moment().isoWeekday();\n\t var time = moment().format(); \n //We are in Europe and the week starts on monday,\n //we need to convert the weekday to monday == 1 \n\t var day = json[today-1];\n\t var str='', open=false;\t \n \tfor (var name in day) { \n if(typeof name=='undefined'){return}\n //open is a spotting variable to check if we already know the state\n \t\tif(open) continue;\n\t\t\tvar todayClosingTime = moment().format('YYYY-MM-DD') + \" \" + day[name].close;\n\t\t var todayOpeningTime = moment().format('YYYY-MM-DD') + \" \" + day[name].open; \n\n\t\t if(moment(time).isSameOrBefore(todayClosingTime) && moment(time).isSameOrAfter(todayOpeningTime)){\n\t\t\t\tstr = \"We are open, but hurry up we are closing in \" + moment.duration(moment(todayClosingTime).diff(time)).humanize();\n\t\t\t\topen=true;\n\t\t }else if(moment(time).isSameOrBefore(todayOpeningTime)){\n\t\t\t\tstr = \"We are closed, but we will open in \" + moment.duration(moment(time).diff(todayOpeningTime)).humanize();\t\t \t\n\t\t\t\topen=true\n\t\t }else{\n var tomorrowOpening = moment().add(1,'day').format('YYYY-MM-DD') + \" \" + morning.open;\n str = \"We are closed, but we will open in \" + moment.duration(moment(time).diff(todayOpeningTime)).humanize(); \n }\n\n\t\t}\t\t\n \n\t\treturn str\t\n }", "function eq_tempo_data(anno,njd){\n\n // funzione per il calcolo dell'equazione del tempo.\n // by Salvatore Ruiu Irgoli-Sardegna (Italy) dicembre 2009\n // algoritmo di P.D. SMITH.\n\n njd=jdHO(njd)+0.5; // riporta il g.g. della data al mezzogiorno. \n \nvar ar_sole=pos_sole(njd); // calcolo dell'ascensione retta del sole.\nvar Tempo_medio_Greenw=tsg_tmg_data(ar_sole[0],anno,njd); // tempo medio di Greenwich.\nvar valore_et=12-Tempo_medio_Greenw; // valore dell'equazione del tempo.\n\n valore_et=valore_et*60; // valore in minuti.\n\n valore_et=valore_et.toFixed(6);\n\nreturn valore_et\n\n}", "function buscarCierreDia(array) {\n let day;\n let arr = [];\n for (let i = 0; i < array.length; i++) {\n let date = array[i].DTYYYYMMDD;\n let res;\n if (day != date) {\n day = date;\n for (let j = 0; j < array.length; j++) {\n if (array[j].DTYYYYMMDD === day) {\n res = array[j].CLOSE;\n }\n }\n arr.push(res);\n }\n }\n\n //console.log('Cierre:', arr)\n return arr;\n}", "function getAutomatedDay(statusData){\n document.getElementById(\"proReportDel\").value = statusData[\"problemDays\"];\n document.getElementById(\"feedDel\").value = statusData[\"feedbackDays\"];\n document.getElementById(\"followReportDel\").value = statusData[\"followUpsDays\"];\n }", "function calcular_idade(data){ \n\n \t//calculo a data de hoje \n\thoje=new Date();\n \t//alert(hoje) \n\n \t//calculo a data que recebo \n \t//descomponho a data em um array\n \tvar array_data = data.split(\"/\");\n \t//se o array nao tem tres partes, a data eh incorreta \n \tif (array_data.length!=3) \n \t return false;\n\n \t//comprovo que o ano, mes, dia s�o corretos \n \tvar ano;\n \tano = parseInt(array_data[2]); \n \tif (isNaN(ano)) \n \t return false;\n\n \tvar mes;\n \tmes = parseInt(array_data[1]); \n \tif (isNaN(mes)) \n \t return false;\n\n \tvar dia;\n \tdia = parseInt(array_data[0]);\t\n \tif (isNaN(dia)) \n \t return false;\n\n\n \t//se o ano da data que recebo so tem 2 cifras temos que muda-lo a 4 \n \tif (ano<=99) \n \t ano +=1900;\n\n \t//subtraio os anos das duas datas\n \tidade=hoje.getFullYear()- ano - 1; //-1 porque ainda nao fez anos durante este ano\n\n \t//se subtraio os meses e for menor que 0 entao nao cumpriu anos. Se for maior sim ja cumpriu \n \tif (hoje.getMonth() + 1 - mes < 0) //+ 1 porque os meses comecam em 0 \n \t return idade;\n \tif (hoje.getMonth() + 1 - mes > 0) \n \t return idade+1 ;\n \t\n \t//entao eh porque sao iguais. Vejo os dias \n \t//se subtraio os dias e der menor que 0 entao nao cumpriu anos. Se der maior ou igual sim que j� cumpriu \n \tif (hoje.getUTCDate() - dia >= 0) \n \t return idade + 1; \n\n \treturn idade;\n}", "function calcola_jddata(giorno,mese,anno,ora,minuti,secondi){\n\n // funzione per il calcolo del giorno giuliano per una data qualsiasi. \n // by Salvatore Ruiu Irgoli-Sardegna (Italy) dicembre 2009\n // restituisce il valore numerico dataGiuliana_annox\n// ATTENZIONE! inserire i valori dei tempi come T.U. di GREENWICH\n \nvar dataGiuliana=costanti_jd(giorno,mese,anno,ora,minuti,secondi); // valore del giorno giuliano per una data qualsiasi.\n\n dataGiuliana=dataGiuliana*1 // definire come valore numerico.\n\nreturn dataGiuliana;\n\n}", "function eq_tempo(){\n\n // by Salvatore Ruiu Irgoli-Sardegna (Italy) ottobre 2011.\n // funzione per il calcolo del valore dell'equazione del tempo per la data odierna.\n // algoritmo di P.D. SMITH.\n \nvar njd=calcola_jd(); // giorno giuliano in questo istante a Greenwich.\n njd=jdHO(njd)+0.5; // g. g. a mezzogiorno di Greenwich.\n\nvar ar_sole=pos_sole(njd); // calcolo dell'ascensione retta del sole.\nvar anno=jd_data(njd); // anno di riferimento.\n\nvar Tempo_medio_Greenw=tsg_tmg_data(ar_sole[0],anno[2],njd); // tempo medio di Greenwich.\nvar valore_et=12-Tempo_medio_Greenw; // valore dell'equazione del tempo.\n\n valore_et=valore_et*60; // valore in minuti.\n\n valore_et=valore_et.toFixed(6);\n\n\n\nreturn valore_et\n\n}", "function x( d ){ return d.anio; } // Devuelve el valor del año de un punto dado", "function getInfoDA(id){\n var sheet = SpreadsheetApp.openById(CLSID).getSheetByName(SHEET_SUIVIDA);\n var idrow = onSearchDAwithID(id);\n var dtDeb = '', strDtDeb='';\n var dtFin = '', strDtFin='';\n // EVO-21\n var strCondition = '';\n // EVO-21\n // EVO-10\n var strTVA = '';\n // EVO-10\n if (idrow != -1) {\n dtDeb = sheet.getRange(idrow,COLUMN_DA_DTDEBLIV).getValue();\n if (dtDeb != '') {\n strDtDeb = Utilities.formatDate(dtDeb, \"GMT+6\", \"dd/MM/yyyy\");\n }\n dtFin = sheet.getRange(idrow,COLUMN_DA_DTFINLIV).getValue();\n if (dtFin != '') {\n strDtFin = Utilities.formatDate(dtFin, \"GMT+6\", \"dd/MM/yyyy\");\n }\n // EVO-21\n if (sheet.getRange(idrow,COLUMN_DA_CONDREGL).getValue() != \"\") {\n strCondition = LIB_COND_REG_EMETTEUR + sheet.getRange(idrow,COLUMN_DA_CONDREGL).getValue();\n }\n // EVO-21\n // EVO-10\n if (sheet.getRange(idrow,COLUMN_DA_TVA).getValue() != \"\") {\n strTVA = LIB_COND_TVA_EMETTEUR + sheet.getRange(idrow,COLUMN_DA_TVA).getValue();\n }\n // EVO-10\n\n globalDAData= {id:id,\n idrow:idrow,\n bdc:sheet.getRange(idrow,COLUMN_DA_NUMBDC).getValue(),\n emetteur:sheet.getRange(idrow,COLUMN_DA_EMETTEUR).getValue(),\n fournisseur:sheet.getRange(idrow,COLUMN_DA_FOURNISSEUR).getValue(),\n statut:sheet.getRange(idrow,COLUMN_DA_STATE).getValue(),\n typedemande:sheet.getRange(idrow,COLUMN_DA_TYPE).getValue(),\n codetypedemande:onSearchTypeDemandeWithLabel(sheet.getRange(idrow,COLUMN_DA_TYPE).getValue()),\n nature:sheet.getRange(idrow,COLUMN_DA_NATURE).getValue(),\n contactfournisseur:sheet.getRange(idrow,COLUMN_DA_CONTACTFOURNISSEUR).getValue(),\n emailcontactfournisseur:sheet.getRange(idrow,COLUMN_DA_EMAILCONTACTFOURNISSEUR).getValue(),\n telcontactfournisseur:sheet.getRange(idrow,COLUMN_DA_TELCONTACTFOURNISSEUR).getValue(),\n buimputation:sheet.getRange(idrow,COLUMN_DA_BU).getValue(),\n codeprojet:sheet.getRange(idrow,COLUMN_DA_CDPROJET).getValue(),\n nomprojet:sheet.getRange(idrow,COLUMN_DA_NOMPROJET).getValue(),\n quantite:sheet.getRange(idrow,COLUMN_DA_QTE).getValue(),\n prixtjmachat:sheet.getRange(idrow,COLUMN_DA_PRXACHAT).getValue(),\n prixtjmvendu:sheet.getRange(idrow,COLUMN_DA_PRXVENDU).getValue(),\n marge:sheet.getRange(idrow,COLUMN_DA_MARGE).getValue(),\n collaborateur:sheet.getRange(idrow,COLUMN_DA_COLLABORATEUR).getValue(),\n datedebutlivraison:strDtDeb,\n datefinlivraison:strDtFin,\n adresselivraison:sheet.getRange(idrow,COLUMN_DA_ADRLIV).getValue(),\n conditionreglement:sheet.getRange(idrow,COLUMN_DA_CONDREGL).getValue(),\n // EVO-21\n conditionreglementemetteur:strCondition,\n // EVO-21\n // EVO-10\n tva:sheet.getRange(idrow,COLUMN_DA_TVA).getValue(),\n tvaemetteur:strTVA,\n // EVO-10\n urlDA:sheet.getRange(idrow,COLUMN_DA_URLDA).getValue(),\n urlDevis:sheet.getRange(idrow,COLUMN_DA_DEVIS).getValue(),\n urlBDCpdf:sheet.getRange(idrow,COLUMN_DA_BDCPDF).getValue(),\n urlBDCpdfsigne:sheet.getRange(idrow,COLUMN_DA_BDCPDFSIGNE).getValue(),\n urlFacture:sheet.getRange(idrow,COLUMN_DA_FACTURE).getValue(),\n urlBPF:sheet.getRange(idrow,COLUMN_DA_BPF).getValue(),\n managerBU:GetManagerBU(sheet.getRange(idrow,COLUMN_DA_BU).getValue()),\n managerEntrepriseParis:GetManagerBU(BU_ENTREPRISE_PARIS),\n acteurComptaFournisseur:GetManagerBU(BU_COMPTA_FOURNISSEUR),\n managerDirectionFinanciere:GetManagerBU(BU_DIRECTION_FINANCIERE),\n assistantes:GetManagerBU(BU_ASSISTANTE_ENTREPRISE_PARIS)\n };\n // Log des informations de la DA\n Log_Info(\"getInfoDA\", Utilities.formatString(\"ret=%s\",Utilities.jsonStringify(globalDAData)));\n }\n if(idrow==-1) throw 'Aucun dossier associé avec la référence suivante :'+id;\n return globalDAData;\n}", "function pegarData(){\n\n today = new Date();\n\n /*Data do dia atual*/\n var date = today.getDate()+'/'+(today.getMonth()+1)+'/'+today.getFullYear();\n /*Nome do dia*/\n var op = ['Domingo', 'Segunda-feira', 'Terça-feira', 'Quarta-feira', 'Quinta-feira', 'Sexta-feira', 'Sábado', 'Domingo'];\n var diaSemana = op[today.getDay()];\n \n document.querySelector('#getDay').innerHTML = diaSemana;\n document.querySelector('#getDate').innerHTML = date;\n\n\n}", "function getEdad(fecha_nac){\n\n //calculo la fecha de hoy\n var hoy=new Date();\n //alert(hoy)\n\n\t//Los Datos de Hoy\n\tvar year_hoy=hoy.getFullYear();\n\tvar mes_hoy=hoy.getMonth() + 1;\n\tvar dia_hoy=hoy.getDate();\n\n\t//la fecha recibida\n\tvar fecha=fecha_nac;\n\n\t//alert(fecha);\n\n //calculo la fecha que recibo\n //La descompongo en un array\n var array_fecha = fecha.split(\"/\")\n //si el array no tiene tres partes, la fecha es incorrecta\n if (array_fecha.length!=3)\n\t\treturn 'Formato incorrecto, use dd/mm/yyyy';\n\t\t\n\n //compruebo que los ano, mes, dia son correctos\n var ano\n ano = parseInt(array_fecha[2],10);\n if (isNaN(ano) || ano > hoy.getFullYear() ) {\n return 'Año incorrecto';\n\t}\n\n var mes\n mes = parseInt(array_fecha[1],10);\n if (isNaN(mes) || mes < 1 || mes >12){\n return 'Mes incorrecto';\n\t}\n\t\n var dia\n dia = parseInt(array_fecha[0],10);\n if (isNaN(dia) || dia<1 || dia > 31){\n return 'Dia incorrecto';\n\t}\n\n //si el año de la fecha que recibo solo tiene 2 cifras hay que cambiarlo a 4\n if (ano<=99)\n ano +=1900\n\n\t//alert('Escrito: \\n dia ' + dia + ' mes ' + mes + ' año ' + ano + '\\n Hoy: \\n año: ' + year_hoy + ' mes: ' + mes_hoy + ' dia ' + dia_hoy );\n\t\n ano = year_hoy - ano;\n mes = mes_hoy - mes;\n dia = dia_hoy - dia;\n\n //Si salió un día negativo\n if (dia < 0) {\n dia = 30 - Math.abs(dia);\n mes = mes - 1;\n }\n\n //Si salió un mes negativo\n if (mes < 0) {\n mes = 12 - Math.abs(mes);\n ano = ano - 1;\n }\n\n\t//Prepara la información a entregar\t\n if (ano==0 && mes==0 && dia==0){\n return 'Recien Nacido?';\n\n } else if (ano<1 && mes<3){\n return mes + ' meses, ' + dia + ' dias';\n\n } else if (ano<1 && mes>=1) {\n return mes + ' meses';\n\n } else if (ano<1 && mes<1){\n return dia + ' dias';\n\n } else if (ano<2) {\n return ano + ' año, ' + mes + ' meses';\n\n } else {\n\t\treturn ano + ' Años ';\n }\t\n\t\n\treturn ano + ' años, ' + mes + ' meses, ' + dia + ' dias';\n\n\n}", "function identificarData(codigo, tipoCodigo) {\n codigo = codigo.replace(/[^0-9]/g, '');\n const tipoBoleto = identificarTipoBoleto(codigo);\n\n let fatorData = '';\n let dataBoleto = new Date();\n\n dataBoleto.setFullYear(1997);\n dataBoleto.setMonth(9);\n dataBoleto.setDate(7);\n dataBoleto.setHours(23, 54, 59);\n\n if (tipoCodigo === 'CODIGO_DE_BARRAS') {\n if (tipoBoleto == 'BANCO') {\n fatorData = codigo.substr(5, 4)\n\n dataBoleto.setDate(dataBoleto.getDate() + Number(fatorData));\n dataBoleto.setTime(dataBoleto.getTime() + dataBoleto.getTimezoneOffset() - (3) * 60 * 60 * 1000);\n var dataBoletoform = dataBoleto.getDate() + \"/\" + (dataBoleto.getMonth() + 1) + \"/\" + dataBoleto.getFullYear()\n\n return dataBoletoform;\n } else {\n dataBoleto = null\n\n return dataBoleto;\n }\n } else if (tipoCodigo === 'LINHA_DIGITAVEL') {\n if (tipoBoleto == 'BANCO') {\n fatorData = codigo.substr(33, 4)\n dataBoleto.setDate(dataBoleto.getDate() + Number(fatorData));\n dataBoleto.setTime(dataBoleto.getTime() + dataBoleto.getTimezoneOffset() - (3) * 60 * 60 * 1000);\n var dataBoletoform = dataBoleto.getDate() + \"/\" + (dataBoleto.getMonth() + 1) + \"/\" + dataBoleto.getFullYear()\n\n return dataBoletoform;\n } else {\n dataBoleto = null\n\n return dataBoleto;\n }\n }\n}", "function cambiarTiempo(ano, mes, dia, hour, min) {\n\n let cambioMin = min;\n let cambioHour = hour;\n let cambioDia = dia;\n let cambioAno = ano;\n let cambioMes = mes;\n\n\n\n if (cambioMin == 30) {\n cambioMin = 0;\n if (cambioHour === 23) {\n cambioHour = 0;\n if (cambioDia === 30 || cambioDia === 31) {\n\n cambioDia = 1;\n\n if (cambioMes === 12) {\n cambioMes = 1;\n cambioAno++;\n } else {\n cambioMes++;\n }\n } else {\n cambioDia++;\n }\n\n } else {\n cambioHour++;\n }\n\n } else if (cambioMin < 30) {\n cambioMin += 30;\n\n\n } else if (cambioMin > 30) {\n\n let aux = Math.abs(cambioMin - 30);\n if (cambioHour === 23) {\n cambioHour = 0;\n if (cambioDia === 30 || cambioDia === 31) {\n\n cambioDia = 1;\n\n if (cambioMes === 12) {\n cambioMes = 1;\n cambioAno++;\n } else {\n cambioMes++;\n }\n } else {\n cambioDia++;\n }\n\n } else {\n cambioMin = aux;\n cambioHour++;\n }\n\n }\n\n //final del dia\n\n return [cambioAno, cambioMes, cambioDia, cambioHour, cambioMin];\n\n}", "function aumentarData(attribute, campoData, valor, diaMesAno) {\n if ((valor != null) && (Xrm.Page.getAttribute(campoData).getValue() != null)) {\n var primeiradata = Xrm.Page.getAttribute(campoData).getValue();\n if (diaMesAno == 'Dia') {\n primeiradata.setDate(primeiradata.getDate() + valor);\n } else if (diaMesAno == 'Mes') {\n primeiradata.setMonth(primeiradata.getMonth() + valor);\n } else if (diaMesAno == 'Ano') {\n primeiradata.setFullYear(primeiradata.getFullYear() + valor);\n } else if (diaMesAno == 'DiaMenus') {\n primeiradata.setDate(primeiradata.getDate() - valor);\n } else if (diaMesAno == 'MesMenus') {\n primeiradata.setMonth(primeiradata.getMonth() - valor);\n } else if (diaMesAno == 'AnoMenus') {\n primeiradata.setFullYear(primeiradata.getFullYear() - valor);\n }\n Xrm.Page.getAttribute(attribute).setValue(new Date(primeiradata));\n }\n}", "function openStatus() {\n\tif((thisDay !== 6 && thisDay !== 0 && thisDay !== 2) && (time >= 10 && time <= 18)) {\n\t\tdocument.getElementById('openStatus').innerHTML = \"åben :)\";\n\t\tdocument.getElementById('openMessage').classList.remove(\"d-none\");\n\t}\n\telse if((thisDay == 2) && (time >= 11 && time <= 19)) {\n\t\tdocument.getElementById('openStatus').innerHTML = \"åben :)\";\n\t\tdocument.getElementById('openMessage').classList.remove(\"d-none\");\n\t}\n\telse {\n\t\tdocument.getElementById('openStatus').innerHTML = \"lukket :(\";\n\t\tdocument.getElementById('closedMessage').classList.remove(\"d-none\");\n\t}\n}", "function idade(ano_nascimento, mes_nascimento, dia_nascimento) {\r\n ano_atual = new Date;\r\n ano_atual = ano_atual.getFullYear();\r\n mes_atual = new Date().getMonth() + 1\r\n dia_atual = new Date().getDate()\r\n if (mes_atual < mes_nascimento || mes_atual == mes_nascimento && dia_atual < dia_nascimento) {\r\n ano_atual -= 1\r\n }\r\n return ano_atual - ano_nascimento;\r\n\r\n }", "function specialDay1( stDay )\n{\n var stValue = window.opener.dialogIdField + \"~\"+ getTextValue( \"stType\" );\n stValue += \"~\" + getTextValue( \"stComment\" )+\"~\"+stDay+ \"~Pending\";\n //alert( \" specialDay= \" + stValue );\n if ( window.opener.dialogMulti == 492 )\n {\n\t var startdate = getDateObject(window.opener.dialogF3.value,\"/\");\n\t var finishdate = getDateObject(stDay,\"/\");\n\t if(window.opener.dialogF3.value == null || window.opener.dialogF3.value == \"\")\n\t {\n\t\talert(\"Please select a start date\");\n\t\treturn;\n\t }\n\t if(startdate > finishdate)\n\t {\n\t\talert (\"Please select a date atleast as great as your start date\");\n\t\treturn;\n }\n window.opener.dialogF4.value = stDay;\n //window.opener.dialogF5.value = \"Pending\";\n if ( window.opener.dialogDisplayField.value.toString().length > 0 )\n window.opener.dialogDisplayField.value += \"\\n|\";\n window.opener.dialogDisplayField.value += stValue;\n }\n window.close();\n}", "function seleccionarDia () {\n \n var fecha = $('#fechas_seleccionadas_cita').val();\n globalFecha = fecha;\n var idMedico = $('#idMedico').text();\n\n if (fecha) {\n var date = new Date(fecha);\n //alert(date, idMedico);\n var obj_dates_idMedico = _dates_idMedico(fecha, date.getDay(), idMedico);\n tramosDisponibles(obj_dates_idMedico);\n\n } else { \n alert(\"Selecione una fecha\");\n }\n}", "function calculaEdad(dia, mes, ano)\n{\n //tomar los valores actuales\n var fecha_hoy = new Date();\n var ahora_ano = fecha_hoy.getFullYear();\n var ahora_mes = fecha_hoy.getMonth()+1;\n var ahora_dia = fecha_hoy.getDate();\n \n // realizar el calculo\n var edad = (ahora_ano + 1895) - ano;\n if ( ahora_mes < mes )\n \tedad--;\n \n if ((mes == ahora_mes) && (ahora_dia < dia))\n \tedad--;\n\n if (edad > 1894)\n edad -= 1895;\n \n return edad;\n}", "function afase_luna(njd){\n\n // calcola l'angolo di fase della luna per la data (njd)\n // gennaio 2012\n\n var dati_luna=pos_luna(njd); // recupero fase/elongazione (1)\n var dati_sole=pos_sole(njd);\n\n var elongazione1=dati_luna[4]; // elongazione in gradi sessadecimali.\n var dist_luna=dati_luna[7]/149597870; \n var dist_sole=dati_sole[4]; // distanza del sole in UA.\n\n elongazione=Math.abs(elongazione1)*1;\n\n var dist_sl=dist_luna*dist_luna+dist_sole*dist_sole-2*dist_luna*dist_sole*Math.cos(Rad(elongazione)); // distanza sole-luna\n dist_sl=Math.sqrt(dist_sl);\n\n // calcolo dell'angolo di fase in gradi . \n\n var Dpt= dist_luna; // distanza pianeta-terra.\n var Dts= dist_sole; // distanza terra-sole.\n var Dps= dist_sl; // distanza pianeta-sole.\n\n // teorema del coseno\n\n var delta_fase=(Dts*Dts+Dps*Dps-Dpt*Dpt)/(2*Dps*Dts);\n delta_fase=Math.acos(delta_fase); \n delta_fase=Rda(delta_fase);\n\n var angolo_fase=180-elongazione-delta_fase; // angolo di fase in gradi.\n\n if(elongazione1<0) {angolo_fase=-angolo_fase; }\n\n return angolo_fase;\n\n}", "function openperiod(data){\r\n var arr = [];\r\n var currentstate = 'closed';\r\n for (var i = 0; i < data.length; i++){\r\n if (currentstate == 'closed'){\r\n if (data[i][1] == 'open'){\r\n arr.push(data[i][0]);\r\n currentstate = 'open';\r\n }\r\n continue;\r\n }\r\n else {\r\n if (data[i][1] == 'closed'){\r\n arr.push(data[i][0]);\r\n currentstate = 'closed';\r\n }\r\n }\r\n }\r\n return arr;\r\n}", "function cargaArea(error, dday , dmes, nombre){\n\t//var parseDate = d3.time.format(\"%Y-%m-%d %H:%M:%S\").parse;\n\tvar parseDate = d3.time.format(\"%Y-%m-%d\").parse;\n\taux2 = dmes;\n\t\tdmes.forEach(function(d) {\n\t\t d.date = parseDate(d.date);\n\t\t d.count = +d.count;\n\t });\n\t\tnombre = 'TODAS';\n\t\taux = dday;\n\t\tarea = dmes;\n\t\tdday.forEach(function(d) {\n\t\t d.date = parseDate(d.date);\n\t\t d.count = +d.count;\n\t });\n\t\t//area = dday;\n\tdibujaArea(area, 0, nombre);\t\n\t\n}", "function getValues() {\n jornadaCertPonto = parseInt(document.getElementById('jornadaCertPonto').value);\n almoco = parseInt(document.getElementById('almoco').value);\n tolerancia = parseInt(document.getElementById('tolerancia').value);\n semAlmoco = parseInt(document.getElementById('semAlmoco').value);\n horasAbonadas = document.getElementById('horasAbonadas').value;\n\n if (isNaN(jornadaCertPonto)) {\n jornadaCertPonto = 9;\n }\n if (isNaN(almoco)) {\n almoco = 1;\n }\n if (isNaN(tolerancia)) {\n tolerancia = 10;\n }\n if (isNaN(semAlmoco)) {\n semAlmoco = 4;\n }\n if (horasAbonadas === '') {\n horasAbonadas = '00:00';\n }\n\n setValues();\n // trata horas incluídas com segundos HH:mm:ss\n if (horasAbonadas.length == 8) {\n horasAbonadas = horasAbonadas.split(':')[0] + ':' + horasAbonadas.split(':')[1];\n }\n\n jornadaSap = jornadaCertPonto - almoco;\n document.getElementById('jornadaSap').value = jornadaSap;\n}", "function jd_data(njd){\n // funzione per il calcolo della data dal numero del giorno giuliano.\n // by Salvatore Ruiu Irgoli-Sardegna (Italy) novembre 2011.\n // restituisce i valori numerici gg/mm/yy.\n // il valore gg è in giorni e ore decimali. Moltiplicare la parte decimale di qq. x24.per avere le ore.\n // njd=numero del giorno giuliano.\n \n var I=parseInt(njd+0.50);\n var F=(njd+0.50)-I;\n var A=0;\n var B=0;\n\n if (I>=2229160){A=parseInt((I-1867216.25)/36524.25); B=I+1+A-parseInt(A/4);}\nelse {B=I;}\n\nvar C=B+1524;\nvar D=parseInt((C-122.1)/365.25);\nvar E=parseInt(365.25*D);\nvar G=parseInt((C-E)/30.6001);\n\n// recupero del giorno.\n\nvar giorno=C-E+F-parseInt(30.6001*G); // giorno con ore decimali.\n giorno=giorno; // toFixed(6)\n\n // recupero del mese.\n\nvar mese=0;\n\n if (G<13.5) {mese=G-1; }\nelse if (G>13.5) {mese=G-13; }\n\n // recupero dell'anno.\n\nvar anno=0;\n\n if (mese>2.5) {anno=D-4716; }\nelse if (mese<2.5) {anno=D-4715; }\n\n njd=jdHO(njd); // riporta il giorno giuliano (njd), alle ore 0(zero) del giorno.\n\nvar gio_sett=(njd+1.5)%7; // recupera il resto: calcola il numero del giorno della settimana (0=domenica, 1=lunedì....)\nvar gio_sett_n=gio_sett; // giorno della settimana numerico.\n \nvar gio_sett_en=\"\"; // giorno della settimana in inglese.\n\n if(gio_sett==0){gio_sett=\"Do\"; gio_sett_en=\"Su\"; }\nelse if(gio_sett==1){gio_sett=\"Lu\"; gio_sett_en=\"Mo\"; }\nelse if(gio_sett==2){gio_sett=\"Ma\"; gio_sett_en=\"Tu\"; }\nelse if(gio_sett==3){gio_sett=\"Me\"; gio_sett_en=\"We\"; }\nelse if(gio_sett==4){gio_sett=\"Gi\"; gio_sett_en=\"Th\"; }\nelse if(gio_sett==5){gio_sett=\"Ve\"; gio_sett_en=\"Fr\"; }\nelse if(gio_sett==6){gio_sett=\"Sa\"; gio_sett_en=\"Sa\"; }\n\nvar data_calendario=new Array(giorno,mese,anno,gio_sett,gio_sett_en,gio_sett_n);\n // array 0 1 2 3 4 5 \n\nreturn data_calendario;\n\n\n}", "getTodayOpenClose() {\r\n return new Promise(async (resolve,reject) => {\r\n await this.alpaca.getClock().then(async (resp) => {\r\n await this.alpaca.getCalendar({\r\n start: resp.timestamp,\r\n end: resp.timestamp\r\n }).then((resp) => {\r\n var openTime = resp[0].open;\r\n var closeTime = resp[0].close;\r\n var calDate = resp[0].date;\r\n\r\n openTime = openTime.split(\":\");\r\n closeTime = closeTime.split(\":\");\r\n calDate = calDate.split(\"-\");\r\n\r\n var offset = new Date(new Date().toLocaleString('en-US',{timeZone: 'America/New_York'})).getHours() - new Date().getHours();\r\n\r\n openTime = new Date(calDate[0],calDate[1]-1,calDate[2],openTime[0]-offset,openTime[1]);\r\n closeTime = new Date(calDate[0],calDate[1]-1,calDate[2],closeTime[0]-offset,closeTime[1]);\r\n resolve([openTime,closeTime]);\r\n });\r\n });\r\n });\r\n }", "probarFechaNacimiento(){\n //lectura del atributo fecha\n console.log(this.fecha.getFecha())\n\n //escritura del atributo\n console.log(this.fecha.setFecha(new Date(2000, 4, 6)))\n console.log(this.fecha.getFormatoLargo())\n console.log(this.fecha.setFecha(new Date(2000, 4, 6)))\n console.log(this.fecha.getFormatoLargo())\n\n //acceso a los metodos\n console.log(this.fecha.getFormatoCorto())\n console.log(this.fecha.getFormatoLargo())\n console.log(this.fecha.getEdad())\n \n }", "function getDopeness() {\n return parseFloat(liveAccount.findOne().dopeness)\n }", "function controlaAnho(){\r\n\tvar fiscalYear = getValueFormatless('fiscalPeriodYear');\r\n\tvar declaType = document.getElementById('declarationType').value;\r\n\tvar fecha = new Date();\r\n\tvar anhoActual = getActualYear();\r\n\t\r\n\tif(fiscalYear != 0){\r\n\t\t//Si es clausura tiene que ser menor o igual q el a?o actual\r\n\t\tif(declaType == '| 5 | CLAUSURA'){\r\n\t\t\tif(fiscalYear > anhoActual){//Mayor o igual? O solo igual se permite\r\n\t\t\t\talert('Para las ddjj de tipo CLAUSURA, el año debe ser el menor o igual al año actual.');\r\n\t\t\t\tdocument.getElementById('fiscalPeriodYear').value = \"\";\r\n\t\t\t\tdocument.getElementById('fiscalPeriodYear').focus();\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t}else{//Si no es clausura, el a?o tiene que ser menor al actual\r\n\t\t\tif(fiscalYear >= anhoActual){\r\n\t\t\t\talert('Para las ddjj ORIGINALES y RECTIFICATIVAS, el año debe ser menor al año actual.');\r\n\t\t\t\tdocument.getElementById('fiscalPeriodYear').value = \"\";\r\n\t\t\t\tdocument.getElementById('fiscalPeriodYear').focus();\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t} \r\n\t}\r\n\t//getPorcentajeMoras(document.getElementById('fiscalPeriodYear')); \t\t \r\n}", "function establecerFechas() {\n let fecha, anio, mes, dia, hora;\n fechaVenta = new Date().toLocaleString();\n if ($('#switch-pi-prod').prop('checked') || $('#switch-pi-late-prod').prop('checked')) {\n fecha = $('#pi-fecha').val();\n fecha = fecha.split('-');\n anio = fecha[0];\n mes = fecha[1];\n dia = fecha[2];\n hora = $('select[id=pi-hora] option:selected').text();\n } else {\n fecha = fechaVenta;\n fecha = fecha.split(\" \");\n hora = fecha[1];\n fecha = fecha[0];\n fecha = fecha.split(\"/\");\n dia = fecha[0];\n if (parseInt(dia) < 10) dia = \"0\" + dia;\n mes = fecha[1];\n if (parseInt(mes) < 10) mes = \"0\" + mes;\n anio = fecha[2];\n }\n fechaEntrega = dia + \"/\" + mes + \"/\" + anio + \" \" + hora;\n}", "function dadosDiaPacienteAtual(dataEscolhida) {\n\n\tvar diasMonitorados = pacientesJson[numIdPacAtual].diasMonitorados;\n\tvar dados = [];\n\tfor (var i = 0; i < diasMonitorados.length; i++) {\n\t\tif (diasMonitorados[i].data == dataEscolhida) {\n\t\t\tdados = diasMonitorados[i].dadosHoras;\n\t\t\tbreak;\n\t\t}\n\t}\n\n\treturn dados;\n}", "function costruttoreDatiMesi(array) {\n var objIntermedio = {};\n var dataPC = [];\n for (var i = 0; i < array.length; i++) {\n var oggettoSingolo = array[i];\n var giornoVendita = oggettoSingolo.date;\n var meseVendita = moment(giornoVendita, \"DD-MM-YYYY\").clone().month(); // ottengo i numeri dei mesi che escono già ordinati nell'oggetto\n if (objIntermedio[meseVendita] === undefined) {\n objIntermedio[meseVendita] = 0;\n }\n objIntermedio[meseVendita] += parseInt(oggettoSingolo.amount);\n }\n for (var key in objIntermedio) {\n dataPC.push(objIntermedio[key]);\n }\n return dataPC;\n}", "function actualizarCantidad() {\n\n var total = 0;\n var cantidadFumigacion = 0;\n var contador = 0;\n\n // Se recorren todos los despegues\n while (contador < elDiaDeHoy.despeguesDeAvionetas.length) {\n\n // Se toma la avioneta y se evalua si es de fumigacion\n if (elDiaDeHoy.despeguesDeAvionetas[contador].Avioneta.esDeFumigacion) {\n\n // si la avioneta es de fumigacion se incrementa el contador de fumigacion en uno;\n cantidadFumigacion++;\n }\n\n // se incrementa el total en uno.\n total++;\n\n // se avanza en uno el contador\n contador++;\n }\n\n // Se actualizan los totales del dia. \n elDiaDeHoy.cantidadTotal = total;\n elDiaDeHoy.cantidadDeFumigacion = cantidadFumigacion;\n}", "function calculaIdade ( dataNascimento ) {\n\t var hoje = new Date();\t \n\t var arrayData = dataNascimento.split(\"/\");\t \n\t var retorno = \"#ERR#\";\n\t \n\t if (arrayData.length == 3) {\n\t // Decompoem a data em array\n\t var ano = parseInt( arrayData[2] );\n\t var mes = parseInt( arrayData[1] );\n\t var dia = parseInt( arrayData[0] );\n\t \n\t // Valida a data informada\n\t if ( arrayData[0] > 31 || arrayData[1] > 12 ) {\n\t return retorno;\n\t } \n\t \n\t ano = ( ano.length == 2 ) ? ano += 1900 : ano;\n\n\t // Subtrai os anos das duas datas\n\t var idade = ( hoje.getYear()+1900 ) - ano;\n\n\t // Subtrai os meses das duas datas\n\t var meses = ( hoje.getMonth() + 1 ) - mes;\n\t \n\t // Se meses for menor que 0 entao nao cumpriu anos. Se for maior sim ja cumpriu\n\t idade = ( meses < 0 ) ? idade - 1 : idade; \n\n\t meses = ( meses < 0 ) ? meses + 12 : meses; \n\n\t retorno = ( idade ); \n\t } \n\n\t return retorno;\n }", "function campos_fecha(tabla)\n{\n\tswitch(tabla)\n\t\t\t\t{\n\t\t\t\tcase \"facturacion\":\n\t\t\t\t\t{\n\t\t\t\t\t\tCalendar.setup({\n \t\t\tinputField : 'finicio', // id of the input field\n \t\t\tifFormat : '%d-%m-%Y', // format of the input field\n \t\t\tshowsTime : true, // will display a time selector\n \t\t\tbutton : 'f_trigger_finicio', // trigger for the calendar (button ID)\n \t\t\tsingleClick : false, // double-click mode\n \t\t\tstep : 1 // show all years in drop-down boxes (instead of every other year as default)\n\t\t\t\t\t})\n\t\t\t\t\t\tCalendar.setup({\n \t\t\tinputField : 'duracion', // id of the input field\n \t\t\tifFormat : '%d-%m-%Y', // format of the input field\n \t\t\tshowsTime : true, // will display a time selector\n \t\t\tbutton : 'f_trigger_duracion', // trigger for the calendar (button ID)\n \t\t\tsingleClick : false, // double-click mode\n \t\t\tstep : 1 // show all years in drop-down boxes (instead of every other year as default)\n\t\t\t\t\t})\n\t\t\t\t\t\tCalendar.setup({\n \t\t\tinputField : 'renovacion', // id of the input field\n \t\t\tifFormat : '%d-%m-%Y', // format of the input field\n \t\t\tshowsTime : true, // will display a time selector\n \t\t\tbutton : 'f_trigger_renovacion', // trigger for the calendar (button ID)\n \t\t\tsingleClick : false, // double-click mode\n \t\t\tstep : 1 // show all years in drop-down boxes (instead of every other year as default)\n\t\t\t\t\t})\n\t\t\t\t\t\n\t\t\t\t\t}break\n\t\t\t\t\tcase \"pcentral\":\n\t\t\t\t\t{\n\t\t\t\t\t\tCalendar.setup({\n \t\t\tinputField : 'cumple', // id of the input field\n \t\t\tifFormat : '%d-%m-%Y', // format of the input field\n \t\t\tshowsTime : true, // will display a time selector\n \t\t\tbutton : 'f_trigger_cumple', // trigger for the calendar (button ID)\n \t\t\tsingleClick : false, // double-click mode\n \t\t\tstep : 1 // show all years in drop-down boxes (instead of every other year as default)\n\t\t\t\t\t})\n\t\t\t\t\t}break\n\t\t\t\t\tcase \"pempresa\":\n\t\t\t\t\t{\n\t\t\t\t\t\tCalendar.setup({\n \t\t\tinputField : 'cumple', // id of the input field\n \t\t\tifFormat : '%d-%m-%Y', // format of the input field\n \t\t\tshowsTime : true, // will display a time selector\n \t\t\tbutton : 'f_trigger_cumple', // trigger for the calendar (button ID)\n \t\t\tsingleClick : false, // double-click mode\n \t\t\tstep : 1 // show all years in drop-down boxes (instead of every other year as default)\n\t\t\t\t\t})\n\t\t\t\t\t}break\n\t\t\t\t\tcase \"z_facturacion\":\n\t\t\t\t\t{\n\t\t\t\t\t\tCalendar.setup({\n \t\t\tinputField : 'finicio', // id of the input field\n \t\t\tifFormat : '%d-%m-%Y', // format of the input field\n \t\t\tshowsTime : true, // will display a time selector\n \t\t\tbutton : 'f_trigger_finicio', // trigger for the calendar (button ID)\n \t\t\tsingleClick : false, // double-click mode\n \t\t\tstep : 1 // show all years in drop-down boxes (instead of every other year as default)\n\t\t\t\t\t})\n\t\t\t\t\t\t\n\t\t\t\t\t\tCalendar.setup({\n \t\t\tinputField : 'renovacion', // id of the input field\n \t\t\tifFormat : '%d-%m-%Y', // format of the input field\n \t\t\tshowsTime : true, // will display a time selector\n \t\t\tbutton : 'f_trigger_renovacion', // trigger for the calendar (button ID)\n \t\t\tsingleClick : false, // double-click mode\n \t\t\tstep : 1 // show all years in drop-down boxes (instead of every other year as default)\n\t\t\t\t\t})\n\t\t\t\t\t}break\n\t\t\t\t\tcase \"empleados\":\n\t\t\t\t\t{\n\t\t\t\t\t\tCalendar.setup({\n \t\t\tinputField : 'fnac', // id of the input field\n \t\t\tifFormat : '%d-%m-%Y', // format of the input field\n \t\t\tshowsTime : true, // will display a time selector\n \t\t\tbutton : 'f_trigger_fnac', // trigger for the calendar (button ID)\n \t\t\tsingleClick : false, // double-click mode\n \t\t\tstep : 1 // show all years in drop-down boxes (instead of every other year as default)\n\t\t\t\t\t})\n\t\t\t\t\t\t\n\t\t\t\t\t\tCalendar.setup({\n \t\t\tinputField : 'fcon', // id of the input field\n \t\t\tifFormat : '%d-%m-%Y', // format of the input field\n \t\t\tshowsTime : true, // will display a time selector\n \t\t\tbutton : 'f_trigger_fcon', // trigger for the calendar (button ID)\n \t\t\tsingleClick : false, // double-click mode\n \t\t\tstep : 1 // show all years in drop-down boxes (instead of every other year as default)\n\t\t\t\t\t})\n\t\t\t\t\t}break\n case \"entradas_salidas\":\n\t\t\t\t\t{\n\t\t\t\t\t\tCalendar.setup({\n \t\t\tinputField : 'entrada', // id of the input field\n \t\t\tifFormat : '%d-%m-%Y', // format of the input field\n \t\t\tshowsTime : true, // will display a time selector\n \t\t\tbutton : 'f_trigger_entrada', // trigger for the calendar (button ID)\n \t\t\tsingleClick : false, // double-click mode\n \t\t\tstep : 1 // show all years in drop-down boxes (instead of every other year as default)\n\t\t\t\t\t})\n\n\t\t\t\t\t\tCalendar.setup({\n \t\t\tinputField : 'salida', // id of the input field\n \t\t\tifFormat : '%d-%m-%Y', // format of the input field\n \t\t\tshowsTime : true, // will display a time selector\n \t\t\tbutton : 'f_trigger_salida', // trigger for the calendar (button ID)\n \t\t\tsingleClick : false, // double-click mode\n \t\t\tstep : 1 // show all years in drop-down boxes (instead of every other year as default)\n\t\t\t\t\t})\n\t\t\t\t\t}break\n\t\t\t\t}\n\t\t\t\t//editor()\n}", "function selectAllOpeningTime(){\n\t\t\n\t\tvar opentimehrs = $(\"#restaurant_delivery_mon_open_hr\").val();\n\t\tvar opentimemins = $(\"#restaurant_delivery_mon_open_min\").val();\n\t\tvar opentimesess = $(\"#restaurant_delivery_mon_open_sess\").val();\n\t\t\n\t\tif( (opentimehrs == \"\") || (opentimemins == \"\") ){\n\t\t\t$(\"#resSelectAllOpenErr\").html(err_lang_arr['resmycc_plz_sel_mon_open_time']).show();\n\t\t\t$(\"#selectopen\").attr('checked',false);\n\t\t\treturn false;\n\t\t}else{\n\t\t\t$(\"#resSelectAllOpenErr\").hide();\n\t\t\t\n\t\t\t//Tues\n\t\t\t$('#restaurant_delivery_tue_open_hr').val(opentimehrs);\n\t\t\t$('#restaurant_delivery_tue_open_min').val(opentimemins);\n\t\t\t$('#restaurant_delivery_tue_open_sess').val(opentimesess);\n\t\t\t//wed\n\t\t\t$('#restaurant_delivery_wed_open_hr').val(opentimehrs);\n\t\t\t$('#restaurant_delivery_wed_open_min').val(opentimemins);\n\t\t\t$('#restaurant_delivery_wed_open_sess').val(opentimesess);\n\t\t\t//thu\n\t\t\t$('#restaurant_delivery_thu_open_hr').val(opentimehrs);\n\t\t\t$('#restaurant_delivery_thu_open_min').val(opentimemins);\n\t\t\t$('#restaurant_delivery_thu_open_sess').val(opentimesess);\n\t\t\t//fri\n\t\t\t$('#restaurant_delivery_fri_open_hr').val(opentimehrs);\n\t\t\t$('#restaurant_delivery_fri_open_min').val(opentimemins);\n\t\t\t$('#restaurant_delivery_fri_open_sess').val(opentimesess);\n\t\t\t//sat\n\t\t\t$('#restaurant_delivery_sat_open_hr').val(opentimehrs);\n\t\t\t$('#restaurant_delivery_sat_open_min').val(opentimemins);\n\t\t\t$('#restaurant_delivery_sat_open_sess').val(opentimesess);\n\t\t\t//sun\n\t\t\t$('#restaurant_delivery_sun_open_hr').val(opentimehrs);\n\t\t\t$('#restaurant_delivery_sun_open_min').val(opentimemins);\n\t\t\t$('#restaurant_delivery_sun_open_sess').val(opentimesess);\n\t\t}\n\t}", "function setDiaMesData(campoDia, campoMes, campoData) {\n if (Xrm.Page.getAttribute(campoData).getValue() != null) {\n var data = Xrm.Page.getAttribute(campoData).getValue();\n Xrm.Page.getAttribute(campoDia).setValue(data.getDate());\n Xrm.Page.getAttribute(campoMes).setValue(data.getMonth() + 1);\n }\n}", "setAlertCloseToday(){\n \n \n var aujourdhuiplus3 = this.todayplus3days.toLocaleDateString();\n\n this.eventsCloseOftheday =[]; // vide le tableau des alertesCloseToday avant chaque set\n \n for(var eventac of this.events){ // pour chaque date de debut d'event = a la date d'aujourdhuiplus3 jours\n if( eventac.datestartevent == aujourdhuiplus3 ){\n this.addAlertCloseToday(eventac);\n \n }\n \n }\n \n }", "function idadePessoa(ano, mes, dias) {\n //return ano + \" \" + mes\n const diasAno = 365;\n const diasMes = 30;\n\n const idadeEmAnos = ano * diasAno\n //console.log(idadeEmAnos)\n\n const idadeEmMeses = mes * diasMes\n //console.log (idadeEmMeses)\n\n const idadeEmDias = idadeEmAnos + idadeEmMeses + dias;\n \n return `Você possui ${idadeEmDias} dias de vida`\n //return idadeEmDias;\n\n}", "function openNewDdt(){\n\t$(\"#autonum\").prop(\"disabled\", false);\n\t$(\"#autonum\").prop(\"checked\", true);\n\t$(\"#saveNewDdt\").prop(\"disabled\", false);\n\t$(\"#newDdt\").prop(\"disabled\", false);\n\t$(\"#saveNewAndPrintDdt\").prop(\"disabled\", false);\n\t\n\t$(\"#saveDdt\").prop(\"disabled\", true);\n\t$(\"#printDdt\").prop(\"disabled\", true);\n\t\n\tvar d = new Date();\n\tvar day = d.getDate();\n\tif(day < 10)\n\t\tday = \"0\"+day;\n\t\n\tvar today = d.getFullYear() + \"-\" + (d.getMonth() + 1) + \"-\" + day;\n\tvar time = d.getHours() + \":\" + d.getMinutes();\n\t$(\"#ddtObject_ddt_oraTrasporto\").val(time);\n\t$(\"#ddtObject_ddt_dataTrasporto\").val(today);\n\t$(\"#ddtObject_ddt_data\").val(today);\n}", "function montaValorMes () {\r\n\t\t\t// laco de despesas\r\n\t\t\tfor (var x in $scope.despesas) {\r\n\t\t\t\t// separo a despesa\r\n\t\t\t\tvar despesa = $scope.despesas[x];\r\n\t\t\t\t// crio um atributo pres(array) na despesa\r\n\t\t\t\tdespesa.pres = [];\r\n\r\n\t\t\t\t// laco de meses até 8\r\n\t\t\t\t// for (var m=0; m<8; m++) {\r\n\t\t\t\tfor (var m=0; m<$scope.tlmeses; m++) {\r\n\t\t\t\t\tvar day = moment().add(m, \"M\").date(); // dia atual + 1\r\n\t\t\t\t\tvar month = moment().add(m, \"M\").month(); // mes atual + 1\r\n\t\t\t\t\tvar year = moment().add(m, \"M\").year(); // ano atual + 1\r\n\t\t\t\t\tvar data = ''; // variavel data\r\n\r\n\t\t\t\t\t// laco de prestacoes da despesa\r\n\t\t\t\t\tfor (var p=0; p<despesa.prestacoes; p++) {\r\n\t\t\t\t\t\tvar dia = moment(despesa.datavencimento).add(p, \"M\").date(); // dia da data despesa + index\r\n\t\t\t\t\t\tvar mes = moment(despesa.datavencimento).add(p, \"M\").month(); // mes data despesa + index\r\n\t\t\t\t\t\tvar ano = moment(despesa.datavencimento).add(p, \"M\").year(); // ano data despesa + index\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t// caso o mes e ano da despesa seja = ao mes e ano atual \r\n\t\t\t\t\t\tif (mes === month && ano === year) {\r\n\t\t\t\t\t\t\tdata = {\"data\": mes+\"/\"+ano, \"valor\":despesa.valor};\r\n\t\t\t\t\t\t\t// pegando a prestação atual\r\n\t\t\t\t\t\t\tif (m === 0) { // m = o ( mes atual )\r\n\t\t\t\t\t\t\t\tdespesa.prestacao = (p+1)+\"/\"+despesa.prestacoes;\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tif (!despesa.prestacao) {\r\n\t\t\t\t\t\t// se ano = atual mas mes menor ou ano menor\r\n\t\t\t\t\t\tif ( (ano === year && mes < month) || (ano < year) ) {\r\n\t\t\t\t\t\t\tdespesa.prestacao = despesa.prestacoes+\"/\"+despesa.prestacoes;\r\n\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\tdespesa.prestacao = \"0/\"+despesa.prestacoes;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tif ( data === '' ) {\r\n\t\t\t\t\t\tdespesa.pres.push({\"data\": \"00/0000\", \"valor\":\"xxxx\", \"color\":\"background:#f0f5f5; color:#ccc;\", \"icon\":\"fa-trophyx\"});\r\n\t\t\t\t\t}else{\r\n\t\t\t\t\t\tdespesa.pres.push(data);\r\n\t\t\t\t\t\t$scope.totais[m].valor = $scope.totais[m].valor + parseInt(despesa.valor);\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tif($scope.totais[m-1] != undefined && $scope.totais[m].valor < $scope.totais[m-1].valor) {\r\n\t\t\t\t\t\t\t$scope.totais[m].icon = \"fa-arrow-down\";\r\n\t\t\t\t\t\t}else if($scope.totais[m-1] != undefined && $scope.totais[m].valor > $scope.totais[m-1].valor) {\r\n\t\t\t\t\t\t\t$scope.totais[m].icon = \"fa-arrow-up\";\r\n\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t$scope.totais[m].icon = \"fa-arrow-right\";\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\t$scope.totalgeral = $scope.totalgeral + parseFloat(despesa.valor);\r\n\t\t\t}\r\n\t\t}", "function buscarEntradasDeODC(tipoBusqueda){\n\tswitch (tipoBusqueda){\n\t\tcase 1: //Cuando el criterio de buesqueda es por Almacen, Proveedor, Fecha de ODC, Fecha de Entrada de Almacen\n\t\t\tvar almacenes = []; \n\t\t\t$('#ListaAlmacenes :selected').each(function(i, selected){ \n\t\t\t almacenes[i] = $(selected).val(); \n\t\t\t});\n\n\t\t\tvar proveedores = $(\"#select-proveedor\").find(\"option:selected\").val();\n\t\t\tvar fecha_inicio_odc = $(\"#fechadel1\").val();\n\t\t\tvar fecha_fin_odc = $(\"#fechaal1\").val();\n\t\t\tvar fecha_inicio_entrada_almacen = $(\"#fechadel2\").val();\n\t\t\tvar fecha_fin_entrada_almacen = $(\"#fechaal2\").val();\n\t\t\tvar FechaInicioODC = convierteFechaJava(fecha_inicio_odc);\n\t\t\tvar FechaFinODC = convierteFechaJava(fecha_fin_odc);\n\t\t\tvar FechaInicioEntradaAlmacen = convierteFechaJava(fecha_inicio_entrada_almacen);\n\t\t\tvar FechaFinEntradaAlmacen = convierteFechaJava(fecha_fin_entrada_almacen);\n\n\t\t\tif ( (proveedores==0) && (fecha_inicio_odc==\"\") && (fecha_inicio_entrada_almacen==\"\") && (fecha_inicio_entrada_almacen==\"\") && (fecha_fin_entrada_almacen==\"\") && (almacenes.length==0) ){\n\t\t\t\talert(\"Debe elegir al menos alg\\u00fan criterio de b\\u00fasqueda\");\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\tif(FechaInicioODC > FechaFinODC){\n\t\t\t\talert(\"La fecha inicial no puede ser mayor a la fecha final en la fecha de orden de compra\");\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\telse{\n\t\t\t\tif(FechaInicioEntradaAlmacen > FechaFinEntradaAlmacen){\n\t\t\t\t\talert(\"La fecha inicial no puede ser mayor a la fecha final en la fecha de entrada a almacen\");\n\t\t\t\t}else{\n\t\t\t\t\t$(\".detalle tbody tr\").remove();\n\t\t\t\t\tvar ruta = \"llenaTablaDetalle.php\";\n\t\t\t\t\tvar envio = \"almacenes=\" + almacenes + \"&proveedores=\" + proveedores + \"&fecha_inicio_odc=\" + fecha_inicio_odc + \"&fecha_fin_odc=\" + fecha_fin_odc + \"&fecha_inicio_entrada_almacen=\" + fecha_inicio_entrada_almacen + \"&fecha_fin_entrada_almacen=\" + fecha_fin_entrada_almacen + \"&proceso=ad_movimientos_almacen\";\n\t\t\t\t\tvar respuesta = ajaxN(ruta, envio);\n\t\t\t\t\t$(\".detalle tbody\").append(respuesta);\n\t\t\t\t}\n\t\t\t}\n\t\tbreak;\n\t\tcase 2: //Cuando el criterio de buesqueda es por Orden de Compra o Documento de Cliente\n\t\t\tvar idOrdenCompra = $(\"#TxtOrdenCompra\").val();\n\t\t\tvar documentoCliente = $(\"#TxtDocumentoCliente\").val();\n\n\t\t\tif ((idOrdenCompra==\"\") && (documentoCliente==\"\")){\n\t\t\t\talert('Debe introducir la orden de compra o el documento del cliente');\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\t$(\".detalle tbody tr\").remove();\n\t\t\tvar ruta = \"llenaTablaDetalle.php\";\n\t\t\tvar envio = \"idOrdenCompra=\" + idOrdenCompra + \"&documentoCliente=\" + documentoCliente+\"&proceso=ad_movimientos_almacen\";\n\t\t\tvar respuesta = ajaxN(ruta, envio);\n\t\t\t$(\".detalle tbody\").append(respuesta);\n\t\tbreak;\n\t}\n}", "function ControlloDataInserita(datadafiltrare,campo,dt,colore,sfondo) {\r\n\r\nvar gg; //variabile per i giorni\r\nvar mm; // variabile per i mesi\r\nvar yy; // variabile per l'anno\r\nvar dateNow = new Date(); // assegna la data corrente (presa dal pc locale)\r\nvar yearNow = dateNow.getFullYear(); //assegna l'anno corente\r\nvar indice=0; // variabile di servizio\r\n\r\nvar nrgiorni = new Array();\r\n\tnrgiorni[0]=29; // febbraio bisestile\r\n\tnrgiorni[1]=31; // gennaio\r\n\tnrgiorni[2]=28; // febbraio\r\n\tnrgiorni[3]=31; // marzo\r\n\tnrgiorni[4]=30;\t// aprile\r\n\tnrgiorni[5]=31; // maggio\r\n\tnrgiorni[6]=30; // giugno\r\n\tnrgiorni[7]=31; // luglio\r\n\tnrgiorni[8]=31; // agosto\r\n\tnrgiorni[9]=30; // settembre\r\n\tnrgiorni[10]=31; // ottobre\r\n\tnrgiorni[11]=30; // novembre\r\n\tnrgiorni[12]=31; // dicembre\r\n\r\nif (datadafiltrare==null || datadafiltrare==\"\") { //se il campo è vuoto esce dalla funzione\r\n document.getElementById(campo).style.color=colore;\r\n document.getElementById(campo).style.background=\"white\";\r\n return;\r\n}\r\n\r\nswitch (datadafiltrare.length) { //analizza il formato della data e prepara le variabili gg, mm, yy\r\n case is = 6: //formato data breve\r\n gg = datadafiltrare.slice(0,2);\r\n mm = datadafiltrare.slice(2,4);\r\n yy = datadafiltrare.slice(4,6);\r\n break; \r\n \r\n case is = 8: //formato data a 8 caratteri\r\n if (datadafiltrare.indexOf(\"/\") >= 0 || datadafiltrare.indexOf(\"-\")>=0) { //con separatori\r\n gg = datadafiltrare.slice(0,2);\r\n mm = datadafiltrare.slice(3,5);\r\n yy = datadafiltrare.slice(6,8);\r\n } else { //data a 8 cifre senza separatori\r\n gg = datadafiltrare.slice(0,2);\r\n mm = datadafiltrare.slice(2,4);\r\n yy = datadafiltrare.slice(4,8);\r\n }\r\n break;\r\n \r\n case is = 10: //formato data completa\r\n gg = datadafiltrare.slice(0,2);\r\n mm = datadafiltrare.slice(3,5);\r\n yy = datadafiltrare.slice(6,10);\r\n break;\r\n\r\n default: //negli altri formati inseriti la routine genera un errore\r\n alert(\"Attenzione! La data che hai inserito e' errata. Sono validi i seguenti formati: 'ggmmaa','gg/mm/aa','ggmmaaaa' e 'gg/mm/aaaa'\");\r\n document.getElementById(campo).focus();\r\n //datadafiltrare.focus();\r\n datadafiltrare=\"\";\r\n return datadafiltrare;\r\n}\r\n\r\n//controlla che i dati di riferimento al giorno, al mese e all'anno siano dati numerici \r\nif (isNaN(gg) || isNaN(mm) || isNaN(yy)) {\r\n\talert(\"Attenzione! La data che hai inserito e' errata.\");\r\n document.getElementById(campo).focus();\r\n //datadafiltrare.focus();\r\n datadafiltrare=\"\";\r\n return datadafiltrare;\r\n}\r\n\r\n//controlla che siano stati inseriti giusti tutti gli elementi che compongono la data\r\nif (Number(gg) <= 0 || Number(mm) <= 0 || Number(mm) > 12 || Number(yy) < 0) { \r\n alert(\"Attenzione! La data che hai inserito e' errata.\");\r\n document.getElementById(campo).focus();\r\n //datadafiltrare.focus();\r\n datadafiltrare=\"\";\r\n return datadafiltrare;\r\n}\r\n\r\n//porta l'anno a quattro cifre calcolando il cambio del millennio\r\nif (Number(yy) <= (Number(yearNow)-2000)) { \r\n yy = (Number(yy)+2000); \r\n } else if (Number(yy) < 100 && Number(yy) > (Number(yearNow)-2000)){\r\n yy = (Number(yy)+1900);\r\n }\r\n\r\n//controlla che l'anno non sia maggiore o uguale a quello corrente\r\n//(dt e dn significano data tesseramento e data di nascita)\r\nif (dt==\"dn\") {\r\n if (Number(yy) >= Number(yearNow)) { \r\n alert(\"Attenzione! L'anno che hai inserito e' errato!\");\r\n document.getElementById(campo).focus;\r\n //datadafiltrare.focus();\r\n datadafiltrare=\"\";\r\n return datadafiltrare;\r\n }\r\n}\r\n// controlla che l'anno inserito non sia bisestile e assegna il valore alla variabile indice\r\nif ((Number(yy) % 4) == 0 && Number(mm)==2) {\r\n\tindice=0;\r\n} else {\r\n\tindice=Number(mm);\r\n}\r\n\r\n// controlla che l'utente non abbia inserito un numero giorni del mese errato\r\nif (Number(gg) > nrgiorni[indice]) {\t\r\n\talert(\"Attenzione! La data che hai inserito e' errata.\");\r\n document.getElementById(campo).focus();\r\n //datadafiltrare.focus();\r\n datadafiltrare=\"\";\r\n return datadafiltrare;\r\n}\r\n// ricompone e stampa la data filtrata\r\ndatadafiltrare=gg+\"/\"+mm+\"/\"+yy;\r\ndocument.getElementById(campo).value=datadafiltrare;\r\ndocument.getElementById(campo).style.color=colore;\r\ndocument.getElementById(campo).style.background=\"white\";\r\nreturn;\r\n}", "function _fecha(cadena) \r\n{ \r\n //Separador para la introduccion de las fechas \r\n var separador = \"/\"; \r\n //Separa por dia, mes y año \r\n if ( cadena.indexOf( separador ) != -1 ) \r\n {\r\n\t var posi1 = 0; \r\n\t var posi2 = cadena.indexOf( separador, posi1 + 1 ); \r\n\t var posi3 = cadena.indexOf( separador, posi2 + 1 ); \r\n\t this.dia = cadena.substring( posi1, posi2 ); \r\n\t this.mes = cadena.substring( posi2 + 1, posi3 ); \r\n\t this.mes =this.mes -1\r\n this.anio = cadena.substring( posi3 + 1, cadena.length ); \r\n } \r\n else\r\n { \r\n\t this.dia = 0; \r\n\t this.mes = 0; \r\n\t this.anio = 0; \r\n } \r\n \r\n return true;\r\n}", "changeDate(intervalo){\n let mes = this.state.mes, anho=this.state.anho;\n if (intervalo=='+') {\n if (this.state.mes==12) {\n //si le suma 1 a diciembre\n mes = 1;\n anho = anho+1;\n }else{\n mes = mes+1;\n }\n }else if(intervalo=='-'){\n if (this.state.mes==1) {\n //si le resta 1 a diciembre\n mes = 12;\n anho = anho-1;\n }else{\n mes = mes-1;\n }\n }\n\n //se vuelven a pedir los turnos\n this.getTurnos(mes, anho);\n\n //se setean los nuevos mes y anho\n this.setState({\n mes: mes,\n anho: anho\n });\n }", "function calcola_jda(){\n\n // funzione per il calcolo del giorno giuliano per il 0.0 gennaio dell'anno corrente.\n // by Salvatore Ruiu Irgoli-Sardegna (Italy) dicembre 2009\n // restituisce dataGiuliana, giorno giuliano inizio anno.\n // recupera automaticamente l'anno.\n // il giorno giuliano è calcolato per il tempo 0 T.U. di Greenwich.\n \n var data=new Date(); \n\n var anno =data.getYear(); // anno\n var mese =1; // mese \n var giorno=0.0; // giorno=0.0\n \nif (anno<1900) {anno=anno+1900;} // correzione anno per il browser.\n\nvar dataGiuliana=costanti_jd(giorno,mese,anno,0,0,0); // valore del giorno giuliano per lo 0.0 gennaio dell'anno corrente.\n\n dataGiuliana=dataGiuliana*1 // definire come valore numerico.\n // \nreturn dataGiuliana;\n\n}", "function Disponibilidad(dia , id_docente , id_semestre, horas, turno ){\n this.dia = dia;\n this.id_docente = id_docente;\n this.id_semestre = id_semestre;\n this.horas = horas;\n this.turno = turno;\n }", "function datam(c,q){\n\tif (c) {\n\t\tif (validata(c)){\t\n\t\t\tvar ano = '' + c.value.substring(6,10);\n\t\t\tvar mes = '' + Math.floor(c.value.substring(3,5))-1;\n\t\t\tvar dia = '' + c.value.substring(0,2);\n\t\t\tvar data=new Date(ano,mes,dia);\n\t\t\tdata.setDate(data.getDate()+q);\n\t\t\tdia=data.getDate();\n\t\t\tif (dia<10){\tdia='0'+dia; }\n\t\t\tmes=data.getMonth()+1;\t\t\t\n\t\t\tif (mes<10){\tmes='0'+mes; }\n\t\t\tano=data.getYear();\n\t\t\tnData=dia+'/'+mes+'/'+ano;\n\t\t\tc.value=nData;\n\t\t\treturn true;\n\t\t}\n\t}\n}", "function copiarHorarioOtrosDias(idCopiar){\n\n\tvar dia = idCopiar.slice(6);\n\n\tif( $('#'+dia).prop('checked') ) {\n\t\t\n\t\tvar inicioJornada\t= $(\"#inicioJornada\"+dia).val();\n\t\tvar finJornada\t\t= $(\"#finJornada\"+dia).val();\n\n\t\t\n\t\t$('#Lunes').prop('checked', true);\n\t\t$('#Martes').prop('checked', true);\n\t\t$('#Miercoles').prop('checked', true);\n\t\t$('#Jueves').prop('checked', true);\n\t\t$('#Viernes').prop('checked', true);\n\t\t$('#Sabado').prop('checked', true);\n\t\t$('#Domingo').prop('checked', true);\n\t\t\n\t\tActivarDesactivarDia(\"Lunes\");\n\t\tActivarDesactivarDia(\"Martes\");\n\t\tActivarDesactivarDia(\"Miercoles\");\n\t\tActivarDesactivarDia(\"Jueves\");\n\t\tActivarDesactivarDia(\"Viernes\");\n\t\tActivarDesactivarDia(\"Sabado\");\n\t\tActivarDesactivarDia(\"Domingo\");\n\t\t\n\t\t$(\"#inicioJornadaLunes\").val(inicioJornada);\t\n\t\t$(\"#finJornadaLunes\").val(finJornada);\n\n\t\t$(\"#inicioJornadaMartes\").val(inicioJornada);\t\n\t\t$(\"#finJornadaMartes\").val(finJornada);\n\t\t\n\t\t$(\"#inicioJornadaMiercoles\").val(inicioJornada);\t\n\t\t$(\"#finJornadaMiercoles\").val(finJornada);\t\n\t\t\n\t\t$(\"#inicioJornadaJueves\").val(inicioJornada);\t\n\t\t$(\"#finJornadaJueves\").val(finJornada);\n\t\t\n\t\t$(\"#inicioJornadaViernes\").val(inicioJornada);\t\n\t\t$(\"#finJornadaViernes\").val(finJornada);\t\n\t\t\n\t\t$(\"#inicioJornadaSabado\").val(inicioJornada);\t\n\t\t$(\"#finJornadaSabado\").val(finJornada);\n\t\t\n\t\t$(\"#inicioJornadaDomingo\").val(inicioJornada);\t\n\t\t$(\"#finJornadaDomingo\").val(finJornada);\t\t\n\t\t\n\t\t$(\"#label_inicioJornadaLunes\").addClass( \"active\" );\t\n\t\t$(\"#label_inicioJornadaMartes\").addClass( \"active\" );\t\n\t\t$(\"#label_inicioJornadaMiercoles\").addClass( \"active\" );\t\n\t\t$(\"#label_inicioJornadaJueves\").addClass( \"active\" );\t\n\t\t$(\"#label_inicioJornadaViernes\").addClass( \"active\" );\t\n\t\t$(\"#label_inicioJornadaSabado\").addClass( \"active\" );\t\n\t\t$(\"#label_inicioJornadaDomingo\").addClass( \"active\" );\t\n\t\t\n\t\t$(\"#label_finJornadaLunes\").addClass( \"active\" );\n\t\t$(\"#label_finJornadaMartes\").addClass( \"active\" );\n\t\t$(\"#label_finJornadaMiercoles\").addClass( \"active\" );\n\t\t$(\"#label_finJornadaJueves\").addClass( \"active\" );\n\t\t$(\"#label_finJornadaViernes\").addClass( \"active\" );\n\t\t$(\"#label_finJornadaSabado\").addClass( \"active\" );\n\t\t$(\"#label_finJornadaDomingo\").addClass( \"active\" );\t\t\t\t\t\t\t\t\t\n\n\t\t\n\t}\n\t\n}", "function calculoYMuestroPropuestas (datos) {\n\n \tconst tasaA = objTasas.tasaA;\n \tconst tasaB = objTasas.tasaB;\n \tconst tasaC = objTasas.tasaC;\n\n \tconst propuestaA = new Propuesta(datos.valor_inmueble, datos.monto_credito, datos.plazo, tasaA.tasa_anual, tasaA.comision_apertura_porcentaje, tasaA.comision_admin, tasaA.avaluo)\n \tconst propuestaB = new Propuesta(datos.valor_inmueble, datos.monto_credito, datos.plazo, tasaB.tasa_anual, tasaB.comision_apertura_porcentaje, tasaB.comision_admin, tasaB.avaluo)\n \tconst propuestaC = new Propuesta(datos.valor_inmueble, datos.monto_credito, datos.plazo, tasaC.tasa_anual, tasaC.comision_apertura_porcentaje, tasaC.comision_admin, tasaC.avaluo)\n\n \tdivPropuestas.innerHTML = propuestasAMLAI(propuestaA, propuestaB, propuestaC)\n }", "function obtenerValoresOtras(cod_usuario,cod_inspeccion){\n db.transaction(function (tx) {\n var query = \"SELECT k_coditem,v_calificacion,o_observacion,n_calificacion FROM puertas_valores_otras WHERE k_codusuario = ? AND k_codinspeccion = ?\";\n tx.executeSql(query, [cod_usuario,cod_inspeccion], function (tx, resultSet) {\n for(var x = 0, i = 55; x < resultSet.rows.length; x++,i++) {\n $(\"input[name=sele_otras\"+i+\"][value='\"+resultSet.rows.item(x).v_calificacion+\"']\").prop(\"checked\",true);\n $('#text_otras_observacion_'+i).val(resultSet.rows.item(x).o_observacion);\n }\n $('#text_calificacion55').val(resultSet.rows.item(0).n_calificacion); //se coloca el cero porque 55 es el primer valor de la lista\n $('#cal_item_otras55').val(resultSet.rows.item(0).n_calificacion); //se coloca el cero porque 55 es el primer valor de la lista\n },\n function (tx, error) {\n console.log('SELECT error: ' + error.message);\n });\n }, function (error) {\n console.log('transaction error: ' + error.message);\n }, function () {\n console.log('transaction ok');\n });\n}", "buscarDado(d) {\n\t\t// Intenta por si es un entero\n\t\tif (!isNaN(d)) {\n\t\t\tthis.entero += parseInt(d);\n\t\t\treturn; //si es entero sumo y salgo\n\t\t}\n\n\t\tif (d.includes(\"d\")) {\n\t\t\tlet sumando = d;\n\t\t\tlet sumandos;\n\t\t\tsumandos = sumando.split(\"d\");\n\t\t\t//hago D(dados, caras)\n\t\t\tlet _d = new D(parseInt(sumandos[0]),\n\t\t\t\tparseInt(sumandos[1]));\n\t\t\t// //console.log(this.dados);\n\t\t\t//Busco si existe el dado con ese nº de caras\n\t\t\tfor (let i of this.dados) {\n\t\t\t\tif (i.caras == _d.caras) {\n\t\t\t\t\t//si existe lo sumo\n\t\t\t\t\ti.sum(_d);\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t\t//si no existe lo añado\n\t\t\tthis.dados.push(_d);\n\t\t}\n\n\t}", "function listarAvionetasDespegadasDuranteElDia() {\n var contador = 0;\n\n console.log('-------------INICIO LISTADO-----');\n console.log('Fecha: ' + describirFecha(elDiaDeHoy.fecha));\n console.log('Total de Avionetas: ' + elDiaDeHoy.cantidadTotal);\n console.log('Total de Fumigación: ' + elDiaDeHoy.cantidadDeFumigacion);\n\n console.log('');\n console.log('-----Detalle de despegues-----');\n\n // Se recorren todos los despegues\n while (contador < elDiaDeHoy.despeguesDeAvionetas.length) {\n\n console.log('Despegue: ' + contador);\n\n console.log('Hora: ' + describirHora(elDiaDeHoy.despeguesDeAvionetas[contador].hora));\n console.log('Placa: ' + elDiaDeHoy.despeguesDeAvionetas[contador].Avioneta.placa);\n console.log('Numero De Pilotos: ' + elDiaDeHoy.despeguesDeAvionetas[contador].Avioneta.cantidadPilotos);\n\n // Se toma la avioneta y se evalua si es de fumigacion para el resultado\n if (elDiaDeHoy.despeguesDeAvionetas[contador].Avioneta.esDeFumigacion) {\n console.log('Avioneta de Fumigacion: Si');\n }\n else {\n console.log('Avioneta de Fumigacion: No');\n }\n\n console.log('');\n\n // se avanza en uno el contador\n contador++;\n }\n\n console.log('-------------FIN LISTADO-----');\n}", "function getPeriod(day) {\n for (var i in periods) {\n if (periods[i].open.day === day) return parseInt(i);\n if (i === periods.length - 1) return '';\n }\n }", "function catturaData() {\n var d = new Date();\n var ora = d.getHours();\n var minuti = d.getMinutes();\n return addZero(ora) + ':' + addZero(minuti);\n }", "function checaHora(diaEscolhido) {\n var mesId = \"d\";\n var mesAt = mes + 1;\n mesId = mesId.replace(\"d\", mesAt);\n \n\n var checaDia = \"d\";\n var checaDia = checaDia.replace(\"d\", diaEscolhido);\n\n tirarHoraGasta(horaIntervalo.inicio, horaIntervalo.fim);\n\n if (agMes[mesId] != null) {\n for (var i = 0; i < agMes[mesId].length; i++) {\n\n if (agMes[mesId][i].dia == checaDia) {\n\n var minutoM = 0; //minuto marcado\n var horaM = 0; //hora marcada\n\n //se for igual a 3 para saber se a hora é\n //menor que 10\n if (agMes[mesId][i].hora.length == 3) {\n horaM = parseInt(agMes[mesId][i].hora[0]);\n minutoM = agMes[mesId][i].hora[1] + agMes[mesId][i].hora[2];\n minutoM = parseInt(minutoM);\n }\n else {\n horaM = agMes[mesId][i].hora[0] + agMes[mesId][i].hora[1];\n minutoM = agMes[mesId][i].hora[2] + agMes[mesId][i].hora[3];\n horaM = parseInt(horaM);\n minutoM = parseInt(minutoM);\n }\n var horaG = agMes[mesId][i].horaGasta; //hora gasta\n var minutoG = agMes[mesId][i].minutoGasto; // minuto gasto\n horaG = parseInt(horaG);\n minutoG = parseInt(minutoG);\n\n var horaS = horaM + horaG; //hora somada\n var minutoS = minutoM + minutoG; //minuto somado\n \n if (minutoS > 30) {\n minutoS = 0;\n ++horaS;\n }\n\n var tMinuto = \"d\"; //texto Minuto\n var tHora = \"d\"; //texto hora\n if (minutoS == 0) {\n tMinuto = tMinuto.replace(\"d\", \"00\");\n }\n else {\n tMinuto = tMinuto.replace(\"d\", minutoS);\n }\n\n tHora = tHora.replace(\"d\", horaS);\n\n var fim = tHora + tMinuto;\n fim = parseInt(fim);\n var inicio = agMes[mesId][i].hora;\n tirarHoraGasta(inicio, fim);\n }\n }\n }\n}", "function getActiveByDays() {\r\n for (country in DATA) {\r\n DATA[country]['activeByDays'] = {};\r\n for (date in DATA[country]['totalByDays']) {\r\n DATA[country]['activeByDays'][date] = ((DATA[country]['totalByDays'][date] - DATA[country]['deathsByDays'][date]) - DATA[country]['recoveredByDays'][date]);\r\n //console.log(DATA[i][country]['activeByDays'][date]);\r\n }\r\n var dayDate = Object.keys(DATA[country]['totalByDays']),\r\n lastDay = dayDate[dayDate.length - 1]\r\n DATA[country]['active'] = ((DATA[country]['totalByDays'][lastDay] - DATA[country]['deathsByDays'][lastDay]) - DATA[country]['recoveredByDays'][lastDay]);\r\n }\r\n}", "function _dates_idMedico(fecha, dia, idMedico) {\n \n var obj = {\n idMedico: idMedico,\n fecha: fecha,\n dia: dia\n };\n\n return obj; \n}", "function recuperarDadosPopup(codigoRegistro, descricaoRegistro, tipoConsulta) {\r\n\r\n\tvar form = document.ImovelOutrosCriteriosActionForm;\r\n\r\n\tif (tipoConsulta == 'localidadeOrigem') {\r\n form.localidadeOrigemID.value = codigoRegistro;\r\n\t form.nomeLocalidadeOrigem.value = descricaoRegistro;\r\n\t form.nomeLocalidadeOrigem.style.color = \"#000000\";\r\n\t \r\n\t form.localidadeDestinoID.value = codigoRegistro;\r\n form.nomeLocalidadeDestino.value = descricaoRegistro;\r\n form.nomeLocalidadeDestino.style.color = \"#000000\";\r\n form.setorComercialOrigemCD.focus();\r\n\t}\r\n\r\n\tif (tipoConsulta == 'localidadeDestino') {\r\n form.localidadeDestinoID.value = codigoRegistro;\r\n form.nomeLocalidadeDestino.value = descricaoRegistro;\r\n \t form.setorComercialDestinoCD.focus();\r\n\t \t\t \r\n\t}\r\n\r\n\tif(tipoConsulta == 'municipio'){\r\n\t\tform.idMunicipio.value = codigoRegistro;\r\n\t\tform.nomeMunicipio.value = descricaoRegistro;\r\n\t\tform.nomeMunicipio.style.color = \"#000000\";\r\n\t\tform.idBairro.focus();\r\n\t}\r\n\r\n\tif(tipoConsulta == 'cep'){\r\n\t\tform.CEP.value = codigoRegistro;\r\n\t\tform.descricaoCep.value = descricaoRegistro;\r\n\t\tform.descricaoCep.style.color = \"#000000\";\r\n \t form.idLogradouro.focus();\r\n\t}\r\n\r\n\t\r\n\tif(tipoConsulta == 'bairro'){\r\n\t\tform.idBairro.value = codigoRegistro;\r\n\t\tform.nomeBairro.value = descricaoRegistro;\r\n\t\tform.nomeBairro.style.color = \"#000000\";\r\n\t form.CEP.focus();\r\n\t}\r\n\t\r\n\tif(tipoConsulta == 'logradouro'){\r\n\t\tform.idLogradouro.value = codigoRegistro;\r\n\t\tform.nomeLogradouro.value = descricaoRegistro;\r\n\t\tform.nomeLogradouro.style.color = \"#000000\";\r\n\t}\r\n\tform.action = 'exibirFiltrarImovelOutrosCriteriosConsumidoresInscricao.do?menu=sim&gerarRelatorio=RelatorioCadastroConsumidoresInscricao&limpar=S';\r\n\tform.submit();\r\n}", "function antiguedadGrado(fecha, fecha_retiro){ \n var arr = [];\n \n var fecha_r = fecha_retiro.split(\"-\");\n var ano_r = fecha_r[0];\n var mes_r = fecha_r[1];\n var dia_r = fecha_r[2];\n\n var list = fecha.split(\"-\");\n var ano = list[0];\n var mes = list[1];\n var dia = list[2];\n\n if (dia_r < dia){\n dia_dif = (dia_r+30) - dia; //27 -5\n mes_r--;\n }else{\n dia_dif = dia_r - dia; //27 -5\n }\n\n if (mes_r < mes){\n mes_dif = (mes_r + 12) - mes; //27 -5\n ano_r--;\n }else{\n mes_dif = mes_r - mes;\n }\n\n ano_dif = ano_r - ano;\n arr['e'] = ano_dif;\n\n if(mes_dif > 5) {\n arr['n'] = ano_dif + 1;\n }else{\n arr['n'] = ano_dif;\n }\n\n //console.log(arr);\n return arr;\n\n}", "function ultimoDado() {\n\tvar diasMonitorados = diasMonitoradosPaciente();\n\tvar diaAtual = dadosDiaAtual(diasMonitorados);\n\tvar quantHoras = diaAtual.dadosHoras.length;\n\tvar dado = {\n\t\tdata : diaAtual.data + \"\",\n\t\thora : diaAtual.dadosHoras[quantHoras - 1].hora\n\t};\n\n\treturn dado;\n}", "function calcularFechaFin(fechaInicio) { \t\r\n\t\r\n\t//Incrementamos 6 dias para que sea viernes el dia de cierre\r\n\tvar dia = fechaInicio.getDate();\r\n\tvar mes = fechaInicio.getMonth();\r\n\tvar anno = fechaInicio.getFullYear();\t\r\n\t\r\n\t// Variable que cuenta la cantidad de miliseg que dura el programa \r\n\t// de produccion semanal mas la fecha de inicio\r\n\tvar diasMiliseg = fechaInicio.getTime() + (DIAS_PROGRAMA * 24 * 60 * 60 * 1000);\r\n\t\r\n\t// Cosntruimos el objeto Date de fechaFin con la cantidad de miliseg\r\n\tvar fechaFin = new Date(diasMiliseg);\r\n\t\t\r\n\tvar diaFin = fechaFin.getDate();\r\n\tvar mesFin = fechaFin.getMonth()+1;\r\n\tvar annoFin = fechaFin.getFullYear();\r\n\t\r\n\tdiaFin = diaFin < 10 ? \"0\" + diaFin : diaFin;\r\n\tmesFin = mesFin < 10 ? \"0\" + mesFin : mesFin;\r\n\t\r\n\t//alert('diaFin/mesFin/annoFin = ' + diaFin + '/' + mesFin + '/' + annoFin);\t\r\n\r\n\t// Escribimos en el campo de texto la fecha de fin del plan\r\n\tdocument.formularioFiltro.fechaFinRegistro.value = diaFin + '/' + mesFin + '/' + annoFin;\r\n}", "function clima7Dias(){\n\n\t\tconst url7Days = 'https://api.openweathermap.org/data/2.5/onecall?lat='+latitud+'&lon='+longitud+'&units=metric&lang=sp&exclude=current,minutely,hourly,alerts&appid=509a71114c79dce7fe4e067058ed0286';\n\n\t\tfetch(url7Days).then(response => response.json())\n\t\t.then(data => {\n\n\t\t\tconsole.log(url7Days);\n\n\t\t\tlet daily = data['daily'];\n\t\t\tlet tomorrow = data['daily'][0];\n\t\t\tlet tomorrowTemp = data['daily'][0]['temp'];\n\t\t\t// console.log(tomorrowTemp);\n\t\t\tlet tomorrowTempMin = data['daily'][0]['temp']['min'];\n\t\t\t// console.log(tomorrowTempMin);\n\t\t\tlet tomorrowTempMax = data['daily'][0]['temp']['max'];\n\t\t\t// console.log(tomorrowTempMax);\n\n\t\t\tlet iconClimaTomorrowDescripcion = data['daily'][0]['weather'][0]['icon'];\n\t\t\t// console.log(iconClimaTomorrowDescripcion);\n\n\t\t\tlet postTomorrowTempMin = data['daily'][1]['temp']['min'];\n\t\t\t// console.log(postTomorrowTempMin);\n\t\t\tlet postTomorrowTempMax = data['daily'][1]['temp']['max'];\n\t\t\t// console.log(postTomorrowTempMax);\n\n\t\t\tlet iconClimaPostTomorrowDescripcion = data['daily'][1]['weather'][0]['icon'];\n\t\t\t// console.log(iconClimaPostTomorrowDescripcion);\n\n\t\t\t// Imprimir los datos del clima - dependiendo de la respuesta del usuario\n\n\t\t\ttempMaxTomorrow.textContent = `${Math.round(tomorrowTempMax)} °C /`;\n\t\t\ttempMinTomorrow.textContent = `${Math.round(tomorrowTempMin)} °C`;\n\n\t\t\ttempMaxPostTomorrow.textContent = `${Math.round(postTomorrowTempMax)} °C /`;\n\t\t\ttempMinPostTomorrow.textContent = `${Math.round(postTomorrowTempMin)} °C`;\n\t\t\t// Imprimir los datos del clima - dependiendo de la respuesta del usuario\n\n\t\t\t$(function mostrarImagenSiguientesDias() { \n\t\t\t\t// console.log(iconClimaDescripcion);\n\t\t\t\t$(\"#imagenClimaMañana\").attr(\"src\",`http://openweathermap.org/img/wn/${iconClimaTomorrowDescripcion}@2x.png`);\n\t\n\t\t\t\t$(\"#imagenClimaPostMañana\").attr(\"src\",`http://openweathermap.org/img/wn/${iconClimaPostTomorrowDescripcion}@2x.png`);\n\t\t\t});\n\t\t\t\n\t\t})\n\t\t.catch(error => alert(\"Nombre de la ciudad Invalido\"));\n\n\t\t// API CLIMA Openweathermap ---------------------\n\n\t}", "function getInfoRecensioniPerProfilo(id,li){\r\n var listaContatori= [0,0,0]; //[numOfferte, numVolteOspitato, mediaRecensioni]\r\n var listaEventi = li;\r\n var contatore = 0;\r\n var somma = 0;\r\n for(var i=0; i < listaEventi.length; i++){\r\n if(listaEventi[i].ospitante == id && listaEventi[i].recensioneFattaDaOspitato){\r\n listaContatori[0]+=1;\r\n contatore++;\r\n somma+=parseInt(listaEventi[i].recensioneFattaDaOspitato.numstelle);\r\n }\r\n if(listaEventi[i].ospitato == id && listaEventi[i].recensioneFattaDaOspitante){\r\n listaContatori[1]+=1;\r\n contatore++;\r\n somma+= parseInt(listaEventi[i].recensioneFattaDaOspitante.numstelle);\r\n }\r\n }\r\n if(contatore !== 0){\r\n listaContatori[2]= (parseInt(somma/contatore + 0.5));\r\n }\r\n return listaContatori;\r\n}", "function idade(date) {\n\n var nascimento = new Date(date.value);\n var hoje = new Date(Date.now());\n\n var idadePessoa = Math.floor(Math.ceil(Math.abs(nascimento.getTime() - hoje.getTime()) / (1000 * 3600 * 24)) / 365.25);\n\n if (idadePessoa < 19) {\n alert(\"Idade não pode ser inferior a 19 anos =/\");\n inputDataNascimento.value = \"\";\n }\n\n}", "getOrdreFamille(){\n if (this.appartientFamille()){\n return parseInt(this.donneesUtilisateur.getElementsByTagName(DictionnaireXml.getTagFamille())[0].getAttribute(DictionnaireXml.getAttOrdreFamille()));\n }\n else{\n throw \"Récupération de l'ordre dans la famille impossible : Le QRCode n'appartient à aucune famille\";\n }\n }", "function costanti_jd(giorno,mese,anno,ora,minuti,secondi){\n\n var yy_negativo=0; // sottrae 1 quando l'anno è negativo. \n var mese_str=String(mese); // il mese in formato stringa.\n \n if(anno<0) {yy_negativo=1;} // verifica l'anno negativo. \n \n if (mese==1 || mese==2) {mese_str=\"0\"+mese_str; anno=anno-1; mese=mese+12;} // verifica il mese e l'anno.\n\n var verifica_yy=String(anno)+\".\"+mese_str+String(giorno); // verifica l'anno formato stringa. \n var yy_num=eval(verifica_yy); // riporta l'anno in formato numerico.\n \n \n var a = parseInt( anno / 100 );\n var b = 2 - a + parseInt( a / 4 );\n\n if(yy_num<1582.1015) {a=0; b=0; } // azzera le variabili a e b quando l'anno è minore di 1582.1015.\n\n var c = parseInt( 365.25 * anno );\n var d = parseInt( 30.6001 * ( mese + 1 ) );\n\n var dataGiuliana = b + c + d + giorno + 1720994.50 - yy_negativo;\n\n var offsetGiornata = ( 3600 * ora + 60 * minuti + secondi ) / 86400;\n\n dataGiuliana = dataGiuliana + offsetGiornata;\n\n dataGiuliana=dataGiuliana.toFixed(6);\n\nreturn dataGiuliana ;\n\n}", "function masqueSaisieDate(obj) {\n\n var ch = obj.value;\n var ch_gauche, ch_droite;\n obj.value = ch.slice(0, 10);\n ch.toString();\n if (((ch.slice(2, 3)) !== (\"/\")) && (ch.length >= 3)) {\n if (ch.slice(0, 2) > 31) {\n ch_gauche = '31';\n } else {\n ch_gauche = ch.slice(0, 2);\n }\n ch_droite = ch.slice(2);\n obj.value = ch_gauche + \"/\" + ch_droite;\n }\n if (((ch.slice(5, 6)) !== (\"/\")) && (ch.length >= 6)) {\n if (ch.slice(3, 5) > 12) {\n ch_gauche = ch.slice(0, 3) + '12';\n } else {\n ch_gauche = ch.slice(0, 5);\n }\n ch_droite = ch.slice(5);\n obj.value = ch_gauche + \"/\" + ch_droite;\n }\n return;\n}", "function Data(dia, mes, ano) {\n if (ano === void 0) { ano = 1970; }\n this.dia = dia;\n this.mes = mes;\n this.ano = ano;\n // this.dia = dia;\n // this.mes = mes;\n // this.ano = ano;\n }", "_openToDate() {\n this._moveToToStep();\n this._open();\n }", "function selectHoaBudget() {\n hoa_permonth = parseInt(hoaMenu.property(\"value\"));\n console.log(`HOA budget Selected: ${hoa_permonth}`) \n return hoa_permonth;\n}", "function obtenerColoresDegradados() {\r\n return [\"90-#ff0000-#9d0000\",\"90-#00ff00-#009d00\",\"90-#0000ff-#00009d\",\"90-#ffff00-#A99200\",\"90-#FF8000-#AA6000\",\"90-#8000FF-#420373\",\"90-#FF8080-#FF8888\",\"90-#808080-#00009d\",\"90-#800000-#00009d\",\"90-#800080-#4D0178\"]; \r\n}", "getDuracionJornada() {\n let duracion = \"00:00:00\";\n //Recorro todo el array y sumo las duraciones\n for (let i = 0; i < this.arrayIntervalos.length; i++) {\n duracion = FuncionesAuxiliares.sumaDuracionesString(duracion,\n this.arrayIntervalos[i].getTiempoIntervaloString());\n }\n return duracion;\n\n }", "function getStatus(now, day) {\n var index = getPeriod(day);\n \n if (!!index) {\n var open = determineDate(periods[index].open.nextDate);\n var close = determineDate(periods[index].close.nextDate);\n };\n\n var indexPre = getPeriod((7 + day - 1) % 7);\n \n if (!!indexPre) {\n var closePre = determineDate(periods[indexPre].close.nextDate);\n };\n\n // checks for difference in nextDates\n function determineDate(inputDate) {\n var inputTime = new Date(inputDate);\n return (inputTime - now > FOUR_DAYS) ? inputDate - ONE_WEEK : inputDate;\n }\n\n // if case is true for given time, set the status\n switch (true) {\n // if now < open, [if now < pre, pre - now, else open at ''], else [if now < close, close - now, else closed]\n case !!index && !!indexPre:\n if (now < open) {\n if (now < closePre) {\n x.statuses.count();\n return closePre - now;\n } else {\n x.statuses.wait();\n return open;\n }\n } else {\n if (now < close) {\n x.statuses.count();\n return close - now;\n } else {\n x.statuses.reset();\n return 'closed';\n }\n }\n break;\n // if now < open, open at '', else [if now < close, close - now, else closed]\n case !!index && !indexPre:\n if (now < open) {\n x.statuses.wait();\n return open;\n } else {\n if (now < close) {\n x.statuses.count();\n return close - now;\n } else {\n x.statuses.reset();\n return 'closed';\n }\n };\n break;\n // if now < pre, pre - now, else closed\n case !index && !!indexPre:\n if (now < closePre) {\n x.statuses.wait();\n return closePre - now;\n } else {\n x.statuses.reset();\n return 'closed';\n }\n break;\n default:\n x.statuses.reset();\n return 'closed';\n };\n }", "function buscarMaxDia(array) {\n let day;\n let arr = [];\n for (let i = 0; i < array.length; i++) {\n let date = array[i].DTYYYYMMDD;\n if (day != date) {\n day = date;\n let res;\n let contador = 0;\n for (let j = 0; j < array.length; j++) {\n if (array[j].DTYYYYMMDD === day) {\n if (contador === 0) {\n res = array[j].HIGH;\n } else {\n res = Math.max(res, array[j].HIGH);\n }\n contador++;\n }\n }\n arr.push(res);\n }\n }\n\n // console.log('Maximos:', arr)\n return arr;\n}", "function DescuentoAusencia(){\n //recupero el valor de ausencia\n var sal_aus= document.getElementById(\"sal_aus\").value;\n var SaldoNeto= document.getElementById('sueldoNeto').value;\n //reestablece los valores al cambiar dias\n if(sal_aus > 0)\n {\n var suma=parseFloat(SaldoNeto) + parseFloat(sal_aus);\n document.getElementById(\"sueldoNeto\").value=suma;\n \n }\n var SueldoBrutoIni=document.getElementById('sueldoBruto').value;\n //calcula el jpornal diario\n var jornal=SueldoBrutoIni/30;\n //obtiene la cantidad de dias\n var dias=document.getElementById('DiaAusencia').value;\n //calcula jornal diario por cantidad de dias\n document.getElementById(\"sal_aus\").value=jornal*dias;\n //Actualiza el neto a cobrar\n var SaldoNeto= document.getElementById('sueldoNeto').value;\n document.getElementById(\"sueldoNeto\").value=SaldoNeto-(jornal*dias);\n //guardamos el valor de salario neto(esto se actualizara con cada descuento)\n var sueldoneto=document.getElementById('sueldoNeto').value;\n document.getElementById(\"sal_neto\").value=sueldoneto;\n \n \n }", "function showRangosFecha() {\n\n if (Periodos.length == 0) {\n ngNotify.set('Seleccione al menos un periodo', {\n type: 'error'\n });\n } else {\n if ((reporteSeleccionado >= 1 && reporteSeleccionado <= 4) || (reporteSeleccionado == 10) || (reporteSeleccionado == 12)) {\n\n showReporte();\n } else if ((reporteSeleccionado == 5) || (reporteSeleccionado == 6) || (reporteSeleccionado == 8) || (reporteSeleccionado == 9) || (reporteSeleccionado == 11)) {\n if (reporteSeleccionado == 9) {\n vm.MotcanDiv = false;\n } else {\n vm.MotcanDiv = true;\n }\n\n vm.search = null;\n vm.pplazas = true;\n vm.pestados = true;\n vm.pciudades = true;\n vm.plocalidades = true;\n vm.pcolonias = true;\n vm.pserviciosInternet = true;\n \n vm.ptipoclientes = true;\n vm.pperiodos = true;\n vm.prangosfecha = false;\n\n } else {\n\n vm.showMesAnio();\n }\n }\n }", "function tirarDiasAnteriores() {\n var id = \"19\";\n var dias = 1;\n var id2 = historico[0].primeiraSemana();\n var semana = historico[0].primeiraSemana();\n var diaClick = \"diaClick(9)\"; \n for (dias; dias <= diaAtual[1]; dias++) {\n id = \"19\";\n id = id.replace(\"1\", semana)\n id = id.replace(\"9\", id2);\n diaClick = \"diaClick(9)\";\n diaClick = diaClick.replace(\"9\", dias);\n document.getElementById(id).innerHTML = dias;\n document.getElementById(id).classList.remove(\"agendaLivre\");\n document.getElementById(id).classList.remove(\"clicavel\");\n document.getElementById(id).classList.add(\"agendaCheia\");\n document.getElementById(id).removeAttribute(\"onclick\");\n\n ++semana;\n ++id2;\n if (semana> 7) {\n semana = 1;\n }\n }\n}", "function mostrarDataHora() {\n var currentTime = new Date();\n var horas = currentTime.getHours();\n var minutos = currentTime.getMinutes();\n var segundos = currentTime.getSeconds();\n var dia = currentTime.getDate();\n var mes = currentTime.getMonth();\n var ano = currentTime.getFullYear();\n var Dia = currentTime.getDay();\n var Mes = currentTime.getUTCMonth();\n if (minutos < 10) {\n minutos = \"0\" + minutos;\n }\n if (segundos < 10) {\n segundos = \"0\" + segundos;\n }\n if (dia < 10) {\n dia = \"0\" + dia;\n }\n if (mes < 10) {\n mes = \"0\" + mes;\n }\n\n var arrayDia = new Array();//Array recebe os Dias \n arrayDia[0] = \"Domingo\";\n arrayDia[1] = \"Segunda-Feira\";\n arrayDia[2] = \"Terça-Feira\";\n arrayDia[3] = \"Quarta-Feira\";\n arrayDia[4] = \"Quinta-Feira\";\n arrayDia[5] = \"Sexta-Feira\";\n arrayDia[6] = \"Sábado\";\n\n var arrayMes = new Array();//Array recebe os Meses \n arrayMes[0] = \"Janeiro\";\n arrayMes[1] = \"Fevereiro\";\n arrayMes[2] = \"Março\";\n arrayMes[3] = \"Abril\";\n arrayMes[4] = \"Maio\";\n arrayMes[5] = \"Junho\";\n arrayMes[6] = \"Julho\";\n arrayMes[7] = \"Agosto\";\n arrayMes[8] = \"Setembro\";\n arrayMes[9] = \"Outubro\";\n arrayMes[10] = \"Novembro\";\n arrayMes[11] = \"Dezembro\";\n\n var diaAtual = arrayDia[Dia] + \", \" + dia + \" de \" + arrayMes[Mes] + \" de \" + ano;\n var horaAtual = horas + \":\" + minutos + \":\" + segundos;\n\n var horaDisplayCelular = horas + \":\" + minutos;\n var dataDisplayCelular = arrayDia[Dia] + \", \" + arrayMes[Mes] + \", \" + dia;\n $(\"#horaDisplay\").text(horaDisplayCelular);\n $(\"#dataDisplay\").text(dataDisplayCelular);\n\n $(\"#datahora\").html(\"<div class='pull-right'><b>\" + diaAtual + \" &nbsp \" + horaAtual + \"</b></div>\"); // MOstrar Data Hora no NavBar\n $(\"#timer\").html(\"\" + diaAtual + \" &nbsp \" + horaAtual + \"\");\n}", "function hoje(data){\t\n\t\t\tvar dataatual = new Date();\n\t\t\tvar dia = dataatual.getDate();\n\t\t\t\n\t\t\tif (dia < 10){\n\t\t\t\tdia = \"0\" + dia;}\n\t\t\t\t\n\t\t\tvar mes = (dataatual.getMonth() + 1);\n\t\t\t\n\t\t\tif (mes < 10){\n\t\t\t\tmes = \"0\" + mes;}\n\t\t\t\t\n\t\t\tvar ano = dataatual.getYear();\t\n\t\t\t\n\t\t\tdata.value = (dia + \"/\" + mes + \"/\" + ano);\t\n}", "adiciona(event){\n\t\tevent.preventDefault()\n\t\tconsole.log(this._inputData.value)\n\t\t\n\t\t\n\t\t//converte o horario para tipo date.\n\t/*\tlet data =new Date(\n\t\t ...this._inputData.value.split(\"-\").map(\n\t\t (item, idx) => {\n\t\t if (idx === 1){\n\t\t item -= 1\n\t\t }\n\t\t console.log(item)\n\t\t return item\n\t\t })\n\t\t )*/\n\t\tlet helper = new DateHelper();\n\t\tlet data = new DateHelper().textoParaData(this._inputData.value)\n\t\tconsole.log(data)\n\t\t//let data = new Date(this._inputData.value.replace(/-/g, ','))\n\t\tlet negociacao = new Negociacao(\n\t\t\thelper.dataParaTexto(this._inputData.value),\n\t\t\tthis._inputQuantidade.value,\n\t\t\tthis._inputValor.value\n\t\t)\n\n\t\t// ==> adicionar a negociação em uma lista\n\t\t\n\t}", "function kiekDienuIkiKaledu() {\n console.log(\"266\");\n // siandienos data\n let today = new Date();\n // kaledu data\n let christmas = new Date(\"2021-12-24\");\n console.log(\"today\", today.toDateString(), \"christmas\", christmas.toDateString());\n\n // skirtumo tarp datu\n let diffMs = christmas - today;\n console.log(\"diffMs\", diffMs);\n // paversti ta skirtuma dienom\n let msToDays = diffMs / 1000 / 3600 / 24;\n // gaunam kiek pilnu dienu\n let wholeDays = Math.floor(msToDays);\n\n // panaudojom pagalbine funkcija\n //let wholeDays = daysDiff(today, christmas);\n\n // atspausdinti\n console.log(\"iki kaledu liko\", wholeDays, \"dienu\");\n}", "function getStatusValue (libelle)\n{\n RMPApplication.debug(\"begin getStatusValue\");\n c_debug(dbug.status, \"=> getStatusValue: libelle = \", libelle);\n\n var status_value = \"\";\n\n switch (libelle) {\n case \"Brouillon\" :\n case \"Transmis\" :\n case \"Draft\" :\n case \"1\" :\n status_value = '1';\n break;\n case \"Clos - Résolu\" :\n case \"Terminé - Complet\" :\n case \"Closed Complete\" :\n case \"3\" :\n status_value = '3';\n break;\n case \"Clos - Non résolu\" :\n case \"Terminé - Incomplet\" :\n case \"Closed Incomplete\" :\n case \"4\" :\n status_value = '4';\n break;\n case \"Clos - Annulé\" : \n case \"Cancelled\" :\n case \"7\" :\n status_value = '7';\n break;\n case \"Diagnostiqué\" :\n case \"Qualifié\" :\n case \"Diagnosed\" :\n case \"Qualified\" :\n case \"10\" :\n status_value = '10';\n break;\n case \"En attente d'approbation\" :\n case \"Awaiting Approval\" :\n case \"11\" :\n status_value = '11';\n break;\n case \"Approuvé\" :\n case \"Approved\" :\n case \"13\" :\n status_value = '13';\n break;\n case \"En attente de diagnostic\" :\n case \"Awaiting Diagnosis\" :\n case \"15\" :\n status_value = '15';\n break;\n case \"Assigné\" :\n case \"Affecté\" :\n case \"Assigned\" :\n case \"16\" :\n status_value = '16';\n break;\n case \"Accepté\" :\n case \"Accepted\" :\n case \"17\" :\n status_value = '17';\n break;\n case \"En cours de résolution\" :\n case \"En cours de traitement\" :\n case \"Work In Progress\" :\n case \"18\" :\n status_value = '18';\n break;\n case \"Erreur\" :\n case \"Error\" :\n case \"19\" :\n status_value = '19';\n break;\n case \"Résolu - En attente de cloture\" : \n case \"Resolved\" :\n case \"20\" :\n status_value = '20';\n break;\n case \"Non résolu - En attente de cloture\" :\n case \"Unresolved\" :\n case \"21\" :\n status_value = '21';\n break;\n default: // All status or no status selected)\n status_value = '0';\n break;\n }\n\n RMPApplication.debug(\"end getStatusValue\");\n return status_value;\n}", "function numerar() {\n\n for (let i = 1; i < 366; i++) {\n\n let fecha = fechaPorDia(2020, i);\n\n let mes = fecha.getMonth();\n\n let select_tabla = document.getElementsByClassName(\"tabla_mes\")[mes];\n\n let dia = fecha.getDate();\n\n let dia_semana = fecha.getDay();\n\n if (dia == 1) { var sem = 0; }\n\n select_tabla.children[2].children[sem].children[dia_semana].innerText = dia;\n\n if (dia_semana == 6) { sem = sem + 1; } \n\n }\n\n\n\n}", "function nivelDificultad(){\n if(usuario['dificultad'] == 'BEBE'){\n dificultad = 1;\n } else if(usuario['dificultad'] == 'DECENTE'){\n dificultad = 2;\n } else{\n dificultad = 3;\n }\n}", "function dataAjusteInv(){\n let rangodeFecha = $(\"#daterange-btn-Ajuste span\").html();\n console.log(\"Rango de Fecha:\",rangodeFecha);\n if(rangodeFecha==undefined || rangodeFecha==null){\n var FechDev1=moment().format('YYYY-MM-DD');\n var FechDev2=moment().format('YYYY-MM-DD');\n }else{\n\t let arrayFecha = rangodeFecha.split(\" \", 3);\n\t let f1=arrayFecha[0].split(\"-\");\n\t let f2=arrayFecha[2].split(\"-\");\n\n\t var FechDev1=f1[2].concat(\"-\").concat(f1[1]).concat(\"-\").concat(f1[0]); //armar la fecha año-mes-dia\n\n\t var FechDev2=f2[2].concat(\"-\").concat(f2[1]).concat(\"-\").concat(f2[0]);\n }\t \n \n //console.log(FechDev1, FechDev2);\n\n tablaAjusteInv=$('#datatableAI').dataTable(\n\t{\n\t\t\"aProcessing\": true,//Activamos el procesamiento del datatables\n\t \"aServerSide\": true,//Paginación y filtrado realizados por el servidor\n \"lengthMenu\": [ [10, 25, 50,100, -1], [10, 25, 50, 100, \"Todos\"] ],\n \"language\": {\n\t\t\"sProcessing\": \"Procesando...\",\n \"sLengthMenu\": \"Mostrar _MENU_ registros &nbsp\",\n \"sZeroRecords\": \"No se encontraron resultados\",\n \"sEmptyTable\": \"Ningún dato disponible en esta tabla\",\n \"sInfo\": \"Mostrar registros del _START_ al _END_ de un total de _TOTAL_\",\n\t\t\"sInfoFiltered\": \"(filtrado de un total de _MAX_ registros)\",\n\t\t\"sInfoPostFix\": \"\", \n \"sSearch\": \"Buscar:\",\n \"sInfoThousands\": \",\",\n \"sLoadingRecords\": \"Cargando...\",\n \"oPaginate\": {\n\t\t\"sFirst\": \"Primero\",\n\t\t\"sLast\": \"Último\",\n\t\t\"sNext\": \"Siguiente\",\n\t\t\"sPrevious\": \"Anterior\"}\n },\n\t\t\"oAria\": {\n\t\t\t\"sSortAscending\": \": Activar para ordenar la columna de manera ascendente\",\n\t\t\t\"sSortDescending\": \": Activar para ordenar la columna de manera descendente\"\n\t\t},\n dom: '<clear>Bfrtip',\n buttons: [\n {\n text: 'Copiar',\n extend: 'copy'\n },\n 'excelHtml5',\n 'csvHtml5',\n {\n extend: 'pdfHtml5',\n orientation: 'landscape',\n title: \"AdminLTE\",\n customize: function ( doc ) {\n pdfMake.createPdf(doc).open();\n },\n },\n \n {\n extend: 'print',\n text: 'Imprimir',\n className: 'btn btn-success btn-sm',\n autoPrint: false //TRUE para abrir la impresora\n }\n ],\n initComplete: function () {\n var btns = $('.dt-button');\n btns.removeClass('dt-button');\n btns.addClass('btn btn-success btn-sm');\n },\n\t\t\"ajax\":\n\t\t\t\t{\n url: 'ajax/ajusteinventario.ajax.php?op=listar',\n data: {\"FechDev1\": FechDev1, \"FechDev2\": FechDev2}, \n\t\t\t\t\ttype : \"POST\",\n\t\t\t\t\tdataType : \"json\",\t\t\t\t\t\t\n\t\t\t\t\terror: function(e){\n\t\t\t\t\t\tconsole.log(e.responseText);\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\"bDestroy\": true,\n\t\t\"iDisplayLength\": 10,//Paginación\n\t \"order\": [[ 0, \"desc\" ]]//Ordenar (columna,orden)\n\t}).DataTable(); \n \n}", "function getDina (day, month, year) {\nvar tempyear, valdlookup, valdlookupday, dinane;\nvar dina = [null, \"Minggu\", \"Senin\", \"Selasa\", \"Rabu\", \"Kamis\", \"Jum'at\", \"Sabtu\"];\nvar dinalookup = new Array();\ndinalookup[1] = [2, 5, 5, 1, 3, 6, 1, 4, 0, 2, 5, 0];\ndinalookup[2] = [3, 6, 6, 2, 4, 0, 2, 5, 1, 3, 6, 1];\ndinalookup[3] = [4, 0, 1, 4, 6, 2, 4, 0, 3, 5, 1, 3];\ndinalookup[4] = [6, 2, 2, 5, 0, 3, 5, 1, 4, 6, 2, 4];\ndinalookup[5] = [0, 3, 3, 6, 1, 4, 6, 2, 5, 0, 3, 5];\ndinalookup[6] = [1, 4, 4, 0, 2, 5, 0, 3, 6, 1, 4, 6];\ndinalookup[7] = [2, 5, 6, 2, 4, 0, 2, 5, 1, 3, 6, 1];\ndinalookup[8] = [4, 0, 0, 3, 5, 1, 3, 6, 2, 4, 0, 2];\ndinalookup[9] = [5, 1, 1, 4, 6, 2, 4, 0, 3, 5, 1, 3];\ndinalookup[10] = [6, 2, 2, 5, 0, 3, 5, 1, 4, 6, 2, 4];\ndinalookup[11] = [0, 3, 4, 0, 2, 5, 0, 3, 6, 1, 4, 6];\ndinalookup[12] = [2, 5, 5, 1, 3, 6, 1, 4, 0, 2, 5, 0];\ndinalookup[13] = [3, 6, 6, 2, 4, 0, 2, 5, 1, 3, 6, 1];\ndinalookup[14] = [4, 0, 0, 3, 5, 1, 3, 6, 2, 4, 0, 2];\ndinalookup[15] = [5, 1, 2, 5, 0, 3, 5, 1, 4, 6, 2, 4];\ndinalookup[16] = [0, 3, 3, 6, 1, 4, 6, 2, 5, 0, 3, 5];\ndinalookup[17] = [1, 4, 4, 0, 2, 5, 0, 3, 6, 1, 4, 6];\ndinalookup[18] = [2, 5, 5, 1, 3, 6, 1, 4, 0, 2, 5, 0];\ndinalookup[19] = [3, 6, 0, 3, 5, 1, 3, 5, 2, 4, 0, 2];\ndinalookup[20] = [5, 1, 1, 4, 6, 2, 4, 0, 3, 5, 1, 3];\ndinalookup[21] = [6, 2, 2, 5, 0, 3, 5, 1, 4, 6, 2, 4];\ndinalookup[22] = [0, 3, 3, 6, 1, 4, 6, 2, 5, 0, 3, 5];\ndinalookup[23] = [1, 4, 5, 1, 3, 6, 1, 4, 0, 2, 5, 0];\ndinalookup[24] = [3, 6, 6, 2, 4, 0, 2, 5, 1, 3, 6, 1];\ndinalookup[25] = [4, 0, 0, 3, 5, 1, 3, 6, 2, 4, 0, 2];\ndinalookup[26] = [5, 1, 1, 4, 6, 2, 4, 0, 3, 5, 1, 3];\ndinalookup[27] = [6, 2, 3, 6, 1, 4, 6, 2, 5, 0, 3, 5];\ndinalookup[28] = [1, 4, 4, 0, 2, 5, 0, 3, 6, 1, 4, 6];\ntempyear = year+15;\nif (tempyear % 28 == 0) {\nvaldlookup = dinalookup[28][month-1];}\nelse {\nvaldlookup = dinalookup[tempyear % 28][month-1];}\nvaldlookupday = valdlookup + day;\nif (valdlookupday > 7) {\nif (valdlookupday % 7 == 0) {\ndinane = dina[7];}\nelse {\ndinane = dina[(valdlookupday % 7)];}\n}\nelse {\ndinane = dina[valdlookupday];}\nreturn dinane;\n}", "function setCurrentDayData() {\n console.log(openDay);\n\n let momentDate = moment(openDay.date, \"DD/MM/YYYY\");\n openDayName.value = momentDate.format(\"dddd\");\n openDayDate.value = openDay.date;\n amManagerInput.value = openDay.amManager;\n pmManagerInput.value = openDay.pmManager;\n\n //TODO proper formatting of cash etc\n salesInput.value = openDay.sales;\n customerCountInput.value = openDay.customerCount;\n cashVarianceInput.value = openDay.cashVariance;\n notesTextarea.value = openDay.notes;\n\n for (const row of openDay.data) {\n let foundRow = findDataRowWithItemIdentifier(row.identifier);\n if (foundRow) {\n updateRowWithData(foundRow, row);\n } else {\n // TODO if row with identifier doesn't exist make sure to show it,\n }\n }\n// TODO set the item data now\n}", "function _diferenciaFechas(FechaIni, FechaFin)\r\n{\r\n //Obtiene dia, mes y año \r\n var fecha1 = new _fecha( FechaIni ); \r\n var fecha2 = new _fecha( FechaFin );\r\n\r\n //Obtiene Objetos Date\r\n var miFecha1 = new Date( fecha1.anio, fecha1.mes, fecha1.dia );\r\n var miFecha2 = new Date( fecha2.anio, fecha2.mes, fecha2.dia ); \r\n //Resta fechas y redondea \r\n var diferencia = (miFecha2.getTime() - miFecha1.getTime())/1000*60; \r\n //var dias = Math.floor(diferencia / (1000 * 60 * 60 * 24)); \r\n //return dias; \t\r\n return diferencia;\t\t\r\n}", "function obli_ecli(njd){\n\n // calcola l'obliquità dell'eclittica.\n // per l'equinozio della data.\n // T= numero di secoli giuliani dallo 0.5 gennaio 1900.\n\n var T=(njd-2415020.0)/36525;\n\n var obli_eclittica=23.452294-0.0130125*T-0.00000164*T*T+0.000000503*T*T*T;\n\nreturn obli_eclittica; //obliquità in gradi\n\n}", "function selectAllSecondOpeningTime(){\n\t\t\n\t\tvar opentimehrs = $(\"#restaurant_delivery_mon_open_hr_second\").val();\n\t\tvar opentimemins = $(\"#restaurant_delivery_mon_open_min_second\").val();\n\t\tvar opentimesess = $(\"#restaurant_delivery_mon_open_sess_second\").val();\n\t\t\n\t\t/** if( opentimehrs == \"\" || opentimemins == \"\" ){\n\t\t\t$(\"#resSelectAllOpenErr\").html(\"Please select monday second opening time\").show();\n\t\t\t$(\"#selectsecondopen\").attr('checked',false);\n\t\t\treturn false;\n\t\t}else{\n\t\t\t$(\"#resSelectAllSecondOpenErr\").hide(); **/\n\t\t\t\n\t\t\t//Tues\n\t\t\t$('#restaurant_delivery_tue_open_hr_second').val(opentimehrs);\n\t\t\t$('#restaurant_delivery_tue_open_min_second').val(opentimemins);\n\t\t\t$('#restaurant_delivery_tue_open_sess_second').val(opentimesess);\n\t\t\t//wed\n\t\t\t$('#restaurant_delivery_wed_open_hr_second').val(opentimehrs);\n\t\t\t$('#restaurant_delivery_wed_open_min_second').val(opentimemins);\n\t\t\t$('#restaurant_delivery_wed_open_sess_second').val(opentimesess);\n\t\t\t//thu\n\t\t\t$('#restaurant_delivery_thu_open_hr_second').val(opentimehrs);\n\t\t\t$('#restaurant_delivery_thu_open_min_second').val(opentimemins);\n\t\t\t$('#restaurant_delivery_thu_open_sess_second').val(opentimesess);\n\t\t\t//fri\n\t\t\t$('#restaurant_delivery_fri_open_hr_second').val(opentimehrs);\n\t\t\t$('#restaurant_delivery_fri_open_min_second').val(opentimemins);\n\t\t\t$('#restaurant_delivery_fri_open_sess_second').val(opentimesess);\n\t\t\t//sat\n\t\t\t$('#restaurant_delivery_sat_open_hr_second').val(opentimehrs);\n\t\t\t$('#restaurant_delivery_sat_open_min_second').val(opentimemins);\n\t\t\t$('#restaurant_delivery_sat_open_sess_second').val(opentimesess);\n\t\t\t//sun\n\t\t\t$('#restaurant_delivery_sun_open_hr_second').val(opentimehrs);\n\t\t\t$('#restaurant_delivery_sun_open_min_second').val(opentimemins);\n\t\t\t$('#restaurant_delivery_sun_open_sess_second').val(opentimesess);\n\t\t}" ]
[ "0.5676619", "0.55443245", "0.5450236", "0.5415511", "0.53871185", "0.5380379", "0.53533", "0.53489166", "0.5307834", "0.53009665", "0.52848023", "0.52716637", "0.52353776", "0.5230704", "0.5217601", "0.5216233", "0.5204208", "0.51924366", "0.5186632", "0.5181951", "0.5172368", "0.51712763", "0.5152087", "0.5148801", "0.5134481", "0.51230526", "0.51112187", "0.5108221", "0.50940126", "0.5087385", "0.5072418", "0.5057673", "0.50509125", "0.5043965", "0.50390655", "0.5023185", "0.5012175", "0.50115526", "0.5008341", "0.5006831", "0.49552613", "0.49384642", "0.49324584", "0.4922651", "0.49194798", "0.49069738", "0.49012053", "0.48910013", "0.4855882", "0.48549402", "0.48533452", "0.48518705", "0.4842432", "0.48370075", "0.482649", "0.4820005", "0.48137158", "0.48124748", "0.48090997", "0.4806703", "0.48054728", "0.4801564", "0.48003218", "0.47984898", "0.47835758", "0.47814184", "0.47747216", "0.47558668", "0.47385135", "0.47362286", "0.47335842", "0.47335473", "0.47296664", "0.47266212", "0.4722927", "0.47218227", "0.4721412", "0.47207588", "0.47197846", "0.47138956", "0.47131732", "0.47118995", "0.47083443", "0.47043276", "0.4699971", "0.46965653", "0.46955666", "0.4691771", "0.46916646", "0.4690496", "0.46792614", "0.4677956", "0.4669102", "0.4666588", "0.46650285", "0.46569908", "0.46556666", "0.46548647", "0.46520877", "0.46458808" ]
0.58460104
0
busca el valor de cierre(de la propiedad CLOSE) de cada dia (propiedad DTYYYYMMDD)(el ultimo valor de cierre de cada dia)
function buscarCierreDia(array) { let day; let arr = []; for (let i = 0; i < array.length; i++) { let date = array[i].DTYYYYMMDD; let res; if (day != date) { day = date; for (let j = 0; j < array.length; j++) { if (array[j].DTYYYYMMDD === day) { res = array[j].CLOSE; } } arr.push(res); } } //console.log('Cierre:', arr) return arr; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function eq_tempo(){\n\n // by Salvatore Ruiu Irgoli-Sardegna (Italy) ottobre 2011.\n // funzione per il calcolo del valore dell'equazione del tempo per la data odierna.\n // algoritmo di P.D. SMITH.\n \nvar njd=calcola_jd(); // giorno giuliano in questo istante a Greenwich.\n njd=jdHO(njd)+0.5; // g. g. a mezzogiorno di Greenwich.\n\nvar ar_sole=pos_sole(njd); // calcolo dell'ascensione retta del sole.\nvar anno=jd_data(njd); // anno di riferimento.\n\nvar Tempo_medio_Greenw=tsg_tmg_data(ar_sole[0],anno[2],njd); // tempo medio di Greenwich.\nvar valore_et=12-Tempo_medio_Greenw; // valore dell'equazione del tempo.\n\n valore_et=valore_et*60; // valore in minuti.\n\n valore_et=valore_et.toFixed(6);\n\n\n\nreturn valore_et\n\n}", "function calcularFechaFin(fechaInicio) { \t\r\n\t\r\n\t//Incrementamos 6 dias para que sea viernes el dia de cierre\r\n\tvar dia = fechaInicio.getDate();\r\n\tvar mes = fechaInicio.getMonth();\r\n\tvar anno = fechaInicio.getFullYear();\t\r\n\t\r\n\t// Variable que cuenta la cantidad de miliseg que dura el programa \r\n\t// de produccion semanal mas la fecha de inicio\r\n\tvar diasMiliseg = fechaInicio.getTime() + (DIAS_PROGRAMA * 24 * 60 * 60 * 1000);\r\n\t\r\n\t// Cosntruimos el objeto Date de fechaFin con la cantidad de miliseg\r\n\tvar fechaFin = new Date(diasMiliseg);\r\n\t\t\r\n\tvar diaFin = fechaFin.getDate();\r\n\tvar mesFin = fechaFin.getMonth()+1;\r\n\tvar annoFin = fechaFin.getFullYear();\r\n\t\r\n\tdiaFin = diaFin < 10 ? \"0\" + diaFin : diaFin;\r\n\tmesFin = mesFin < 10 ? \"0\" + mesFin : mesFin;\r\n\t\r\n\t//alert('diaFin/mesFin/annoFin = ' + diaFin + '/' + mesFin + '/' + annoFin);\t\r\n\r\n\t// Escribimos en el campo de texto la fecha de fin del plan\r\n\tdocument.formularioFiltro.fechaFinRegistro.value = diaFin + '/' + mesFin + '/' + annoFin;\r\n}", "function calcular_idade(data){ \n\n \t//calculo a data de hoje \n\thoje=new Date();\n \t//alert(hoje) \n\n \t//calculo a data que recebo \n \t//descomponho a data em um array\n \tvar array_data = data.split(\"/\");\n \t//se o array nao tem tres partes, a data eh incorreta \n \tif (array_data.length!=3) \n \t return false;\n\n \t//comprovo que o ano, mes, dia s�o corretos \n \tvar ano;\n \tano = parseInt(array_data[2]); \n \tif (isNaN(ano)) \n \t return false;\n\n \tvar mes;\n \tmes = parseInt(array_data[1]); \n \tif (isNaN(mes)) \n \t return false;\n\n \tvar dia;\n \tdia = parseInt(array_data[0]);\t\n \tif (isNaN(dia)) \n \t return false;\n\n\n \t//se o ano da data que recebo so tem 2 cifras temos que muda-lo a 4 \n \tif (ano<=99) \n \t ano +=1900;\n\n \t//subtraio os anos das duas datas\n \tidade=hoje.getFullYear()- ano - 1; //-1 porque ainda nao fez anos durante este ano\n\n \t//se subtraio os meses e for menor que 0 entao nao cumpriu anos. Se for maior sim ja cumpriu \n \tif (hoje.getMonth() + 1 - mes < 0) //+ 1 porque os meses comecam em 0 \n \t return idade;\n \tif (hoje.getMonth() + 1 - mes > 0) \n \t return idade+1 ;\n \t\n \t//entao eh porque sao iguais. Vejo os dias \n \t//se subtraio os dias e der menor que 0 entao nao cumpriu anos. Se der maior ou igual sim que j� cumpriu \n \tif (hoje.getUTCDate() - dia >= 0) \n \t return idade + 1; \n\n \treturn idade;\n}", "function eq_tempo_data2(anno,njd){\n\n // funzione per il calcolo dell'equazione del tempo.\n // by Salvatore Ruiu Irgoli-Sardegna (Italy) gennaio 2012.\n // algoritmo di MEEUS.\n \n njd=jdHO(njd); // riporta il g.g. all'ora H0(zero) del giorno. \n \nvar ar_sole=pos_sole(njd); // calcolo dell'ascensione retta del sole.\nvar ar_sole_app=pos_app(njd,ar_sole[0],ar_sole[1]);\nvar TSG=temposid_app(njd);\nvar valore_et=0;\nvar h=TSG-ar_sole_app[0];\n \nif(h<0 ) {valore_et=12+h;}\nif(h>0 ) {valore_et=h-12;}\n \n valore_et=valore_et*60; // valore in minuti.\n\n valore_et=valore_et.toFixed(6);\n\nreturn valore_et\n\n}", "function cual_es_el_primerdia_del_mes(){\n let primer_dia=new Date(año_actual,mes_actual,1);\n //me devuelve numeros desde 0 a 7,en caso el dia sea domingo no devolvera 0\n return((primer_dia.getDay()-1)=== -1)? 6: primer_dia.getDay()-1;\n}", "function calcola_jddata(giorno,mese,anno,ora,minuti,secondi){\n\n // funzione per il calcolo del giorno giuliano per una data qualsiasi. \n // by Salvatore Ruiu Irgoli-Sardegna (Italy) dicembre 2009\n // restituisce il valore numerico dataGiuliana_annox\n// ATTENZIONE! inserire i valori dei tempi come T.U. di GREENWICH\n \nvar dataGiuliana=costanti_jd(giorno,mese,anno,ora,minuti,secondi); // valore del giorno giuliano per una data qualsiasi.\n\n dataGiuliana=dataGiuliana*1 // definire come valore numerico.\n\nreturn dataGiuliana;\n\n}", "function sc_oresd(ore_dec){\n\n // by Salvatore Ruiu Irgoli-Sardegna (Italy). \n // scomposizione delle ore decimali [ore_dec], in hh |mm |ss.decimali con 2 decimali.\n // restituisce la variabile stringa [ore_hms].\n // ATTENZIONE! La funzione riporta le ore all'interno dell'intervallo: 0-24.\n // agg: Dicembre 2011\n \n var ored=ore_24(ore_dec); // Intervallo ore: 0-24\n\n var ore= parseInt(ored); // Ore.\n var minuti= parseInt((ored-ore)*60); // Minuti.\n var secondi= (((ored-ore)*60-minuti)*60).toFixed(2); // Secondi con 2 decimali.\n\n // verifica arrotondamenti. \n\n if (secondi>=60){secondi=secondi-60; minuti=minuti+1;}\n if ( minuti>=60){ minuti= minuti-60; ore=ore+1; }\n if ( ore>=24){ ore=ore_24(ore);} // Intervallo ore: 0-24\n \n ore= String(ore); // trasforma il numero in stringa.\n minuti= String(minuti ); // trasforma il numero in stringa. \n secondi= String(secondi); // trasforma il numero in stringa. \n \n if (ore.length<2 ){ ore='0'+ore;}\n if (minuti.length<2 ){ minuti='0'+minuti;}\n if (secondi.length<=4){secondi='0'+secondi;}\n\n var ore_hms=ore+\"h. \"+minuti+\"m. \"+secondi+\"s.\";\n\t \nreturn ore_hms; \n\n}", "function calcola_jd(){\n\n // funzione per il calcolo del giorno giuliano utilizzando la data indicata dal pc.\n // by Salvatore Ruiu Irgoli-Sardegna (Italy) giugno 2010.\n // restituisce il valore numerico dataGiuliana_dec.\n // il giorno giuliano è calcolato per il T.U. di Greenwich.\n // la funzione [fuso_loc()], recupera il fuso orario della località (-est) (+ovest).\n // la funzione ritorna la variabile numerica dataGiuliana_dec;\n \n \n var data=new Date();\n\n var anno = data.getYear(); // anno\n var mese = data.getMonth(); // mese 0 a 11 \n var giorno= data.getDate(); // numero del giorno da 1 a 31\n var ora = data.getHours(); // ora del giorno da 0 a 23 recuperata dal pc.\n var minuti= data.getMinutes(); // minuti da 0 a 59\n var secondi=data.getSeconds(); // secondi da 0 a 59\n \n mese =mese+1;\n\nif (anno<1900) {anno=anno+1900;} // correzione anno per il browser.\n\n ora=ora+fuso_loc(); // recupera il fuso orario della località (compresa l'ora legale) e riporta l'ora del pc. come T.U.\n\nvar dataGiuliana=costanti_jd(giorno,mese,anno,ora,minuti,secondi);\n\n dataGiuliana=dataGiuliana*1 // definire come valore numerico.\n \nreturn dataGiuliana; // restituisce il giorno giuliano\n\n}", "function fechaCuotaEditPrestamo() {\n\tvar year = new Date(document.getElementById(\"fecha_inicio\").value).getFullYear();\n\tvar month = new Date(document.getElementById(\"fecha_inicio\").value).getMonth() + 1;\n\tvar day = new Date(document.getElementById(\"fecha_inicio\").value).getDate() + 1;\n\t\n\tvar f = new Date();\n\tvar meses = 0;\t\n\n\t//Se toma la fecha actual y se le suma la cantidad de dias del prestamo \n\t\n\tvar fecha = f.sumar(year, month, day, meses);\n\t//Recupero el valor del dia-mes-año de la finalizacion del prestamo\n\tvar mes = fecha.getMonth() + 1; //El mes se maneja [0-11]\n\tvar dia = fecha.getDate();\n\tvar anio = fecha.getFullYear();\n\n\t//String con la fecha de finalizacion con formato MM/DD/YYYY\n\tvar fecha_fin = anio + \"-\" + mes + \"-\" + dia;\n\n\tdocument.getElementById(\"fecha_fin\").value=fecha_fin ;\n}", "function costanti_jd(giorno,mese,anno,ora,minuti,secondi){\n\n var yy_negativo=0; // sottrae 1 quando l'anno è negativo. \n var mese_str=String(mese); // il mese in formato stringa.\n \n if(anno<0) {yy_negativo=1;} // verifica l'anno negativo. \n \n if (mese==1 || mese==2) {mese_str=\"0\"+mese_str; anno=anno-1; mese=mese+12;} // verifica il mese e l'anno.\n\n var verifica_yy=String(anno)+\".\"+mese_str+String(giorno); // verifica l'anno formato stringa. \n var yy_num=eval(verifica_yy); // riporta l'anno in formato numerico.\n \n \n var a = parseInt( anno / 100 );\n var b = 2 - a + parseInt( a / 4 );\n\n if(yy_num<1582.1015) {a=0; b=0; } // azzera le variabili a e b quando l'anno è minore di 1582.1015.\n\n var c = parseInt( 365.25 * anno );\n var d = parseInt( 30.6001 * ( mese + 1 ) );\n\n var dataGiuliana = b + c + d + giorno + 1720994.50 - yy_negativo;\n\n var offsetGiornata = ( 3600 * ora + 60 * minuti + secondi ) / 86400;\n\n dataGiuliana = dataGiuliana + offsetGiornata;\n\n dataGiuliana=dataGiuliana.toFixed(6);\n\nreturn dataGiuliana ;\n\n}", "function CalcolaCenaFinale() { \r\n\t\t\tvar NrOspiti = document.getElementById(\"NrOspiti\");\r\n\t\t\tif (IsStringNumeric(NrOspiti.value)) {\r\n\t\t\t\tNrOspiti.className = \"\";\r\n\t\t\t\t// ricalcolo il totale\r\n\t\t\t\tdocument.getElementById(\"CostoTotaleEuroCalcolato\").value = CalcolaCostoTotale().toFixed(2).replace(\".\", \",\");\t\t\t\r\n\t\t\t} else {\r\n\t\t\t\talert(\"Il numero degli ospiti deve essere numerico\");\r\n\t\t\t\tNrOspiti.className = \"campoerrato\";\r\n\t\t\t\tcampoLocale = NrOspiti;\r\n\t\t\t\tsetTimeout(\"campoLocale.focus();\", 1);\t\t\t// la setTimeout serve a farlo funzionare con FF\r\n\t\t\t}\r\n return; \r\n }", "function eq_tempo_data(anno,njd){\n\n // funzione per il calcolo dell'equazione del tempo.\n // by Salvatore Ruiu Irgoli-Sardegna (Italy) dicembre 2009\n // algoritmo di P.D. SMITH.\n\n njd=jdHO(njd)+0.5; // riporta il g.g. della data al mezzogiorno. \n \nvar ar_sole=pos_sole(njd); // calcolo dell'ascensione retta del sole.\nvar Tempo_medio_Greenw=tsg_tmg_data(ar_sole[0],anno,njd); // tempo medio di Greenwich.\nvar valore_et=12-Tempo_medio_Greenw; // valore dell'equazione del tempo.\n\n valore_et=valore_et*60; // valore in minuti.\n\n valore_et=valore_et.toFixed(6);\n\nreturn valore_et\n\n}", "function calcola_jdUT0(){\n\n // funzione per il calcolo del giorno giuliano per l'ora 0 di oggi in T.U.\n // by Salvatore Ruiu Irgoli-Sardegna (Italy) giugno 2010.\n // restituisce il valore numerico dataGiuliana.\n \n \n var data=new Date();\n\n var anno = data.getYear(); // anno\n var mese = data.getMonth(); // mese 0 a 11 \n var giorno= data.getDate(); // numero del giorno da 1 a 31\n var ora = 0; // ora del giorno da 0 a 23 in T.U.\n var minuti= 0; // minuti da 0 a 59\n var secondi=0; // secondi da 0 a 59\n \n mese =mese+1;\n\nif (anno<1900) {anno=anno+1900;} // correzione anno per il browser.\n\nvar dataGiuliana=costanti_jd(giorno,mese,anno,ora,minuti,secondi);\n\n dataGiuliana=dataGiuliana*1 // definire come valore numerico.\n\nreturn dataGiuliana; // restituisce il giorno giuliano\n\n}", "function calcPorcentajeMoras(){\r\n\r\n\tif (pm_called == 0){\r\n\t\tgetFiscalMoraInfo();\r\n\t\treturn;\r\n\t}\r\n\t\r\n\tvar norectificativa = 1;\r\n\tif (document.getElementById('declarationType').value=='| 2 | RECTIFICATIVA'){\r\n\t\tnorectificativa = 0;\r\n\t}\r\n\tif(CONTRAVENSION_CMOV && CONTRAVENSION_CMOV != null){//Si es rectificativa no hay contravenci�n\r\n\t\tdocument.getElementById('c39').value = CONTRAVENSION_CMOV * norectificativa;\t\t\r\n\t\tif(document.getElementById('c39').value != null)\r\n \t\t colocarpuntos(document.getElementById('c39'));//NUevo\r\n\t}\r\n\trefreshVars();\r\n\tTRGc40();\r\n\tTRGc40_0();\r\n\tTRGc41();\r\n\tTRGc41_0();\r\n\t\r\n\tvar tmp1 = removeCommas(document.getElementById('c41').value);\r\n\tvar tmp2 = removeCommas(document.getElementById('c39').value);\r\n\tvar op = tmp1 - tmp2;\r\n\tif(op < 0){\r\n\t\top = 0;\r\n\t}\r\n\r\n\tif (PORC_MORA && PORC_MORA != null){\r\n\t\tdocument.getElementById('c42').value = (PORC_MORA * op).toFixed(0);\r\n\t\tif(document.getElementById('c42').value != null)\r\n \t\t colocarpuntos(document.getElementById('c42'));\r\n\t}\t\t\r\n\t\r\n\tif (PORC_INTERES && PORC_INTERES != null){\r\n\t\tdocument.getElementById('c43').value = (PORC_INTERES * op).toFixed(0);\r\n\t\tif(document.getElementById('c43').value != null)\r\n \t\t colocarpuntos(document.getElementById('c43'));\r\n\t}\r\n\t\r\n\trefreshVars();\r\n\tTRGc44();\r\n\t\r\n\tvar tmp = (0).toFixed(0);\r\n}", "function calcPorcentajeMoras(){\n\n\tif (pm_called == 0){\n\t\tgetFiscalMoraInfo();\n\t\treturn;\n\t}\n\t\n\tvar norectificativa = 1;\n\tif (document.getElementById('declarationType').value=='| 2 | RECTIFICATIVA'){\n\t\tnorectificativa = 0;\n\t}\n\tif(CONTRAVENSION_CMOV && CONTRAVENSION_CMOV != null){//Si es rectificativa no hay contravenci?n\n\t\tdocument.getElementById('c48').value = CONTRAVENSION_CMOV * norectificativa;\t\t\n\t\tif(document.getElementById('c48').value != null)\n \t\t colocarpuntos(document.getElementById('c48'));\n\t}\n\t\n\tvar tmp1 = removeCommas(document.getElementById('c52').value);\n\tvar tmp2 = removeCommas(document.getElementById('c48').value);\n\tvar op = tmp1 - tmp2;\n\tif(op < 0){\n\t\top = 0;\n\t}\n\n\tif (PORC_MORA && PORC_MORA != null){\n\t\tdocument.getElementById('c53').value = (PORC_MORA * op).toFixed(0);\n\t\tif(document.getElementById('c53').value < 0){\n\t\t\tdocument.getElementById('c18').value = 0;\n\t\t}\n\t\tif(document.getElementById('c53').value != null)\n \t\t colocarpuntos(document.getElementById('c53'));\n\t}\t\t\n\tif (PORC_INTERES && PORC_INTERES != null){\n\t\tdocument.getElementById('c54').value = (PORC_INTERES * op).toFixed(0);\n\t\tif(document.getElementById('c54').value < 0){\n\t\t\tdocument.getElementById('c54').value = 0;\n\t\t}\n\t\tif(document.getElementById('c54').value != null)\n \t\t colocarpuntos(document.getElementById('c54'));\n\t}\n\t\n\trefreshVars();\n\tTRGc50();\n\tTRGc51();\n\tTRGc51_0();\n\tTRGc52();\n\tTRGc52_0();\n\tTRGc55();\n\t\n\tvar tmp = (0).toFixed(0);\n\n}", "function calcPorcentajeMoras(){\r\n\r\n\tif (pm_called == 0){\r\n\t\tgetFiscalMoraInfo();\r\n\t\treturn;\r\n\t}\r\n\t\r\n\tvar norectificativa = 1;\r\n\tif (document.getElementById('declarationType').value=='| 2 | RECTIFICATIVA'){\r\n\t\tnorectificativa = 0;\r\n\t}\r\n\tif(CONTRAVENSION_CMOV && CONTRAVENSION_CMOV != null){//Si es rectificativa no hay contravenci?n\r\n\t\tdocument.getElementById('c103').value = CONTRAVENSION_CMOV * norectificativa;\t\t\r\n\t\tif(document.getElementById('c103').value != null)\r\n \t\t colocarpuntos(document.getElementById('c103'));\r\n\t}\r\n\t\r\n\tvar tmp1 = removeCommas(document.getElementById('c107').value);\r\n\tvar tmp2 = removeCommas(document.getElementById('c103').value);\r\n\tvar op = tmp1 - tmp2;\r\n\tif(op < 0){\r\n\t\top = 0;\r\n\t}\r\n\r\n\tif (PORC_MORA && PORC_MORA != null){\r\n\t\tdocument.getElementById('c108').value = (PORC_MORA * op).toFixed(0);\r\n\t\tif(document.getElementById('c108').value < 0){\r\n\t\t\tdocument.getElementById('c18').value = 0;\r\n\t\t}\r\n\t\tif(document.getElementById('c108').value != null)\r\n \t\t colocarpuntos(document.getElementById('c108'));\r\n\t}\t\t\r\n\tif (PORC_INTERES && PORC_INTERES != null){\r\n\t\tdocument.getElementById('c109').value = (PORC_INTERES * op).toFixed(0);\r\n\t\tif(document.getElementById('c109').value < 0){\r\n\t\t\tdocument.getElementById('c109').value = 0;\r\n\t\t}\r\n\t\tif(document.getElementById('c109').value != null)\r\n \t\t colocarpuntos(document.getElementById('c109'));\r\n\t}\r\n\t\r\n\trefreshVars();\r\n\tTRGc105();\r\n\tTRGc106();\r\n\tTRGc106_0();\r\n\tTRGc107();\r\n\tTRGc107_0();\r\n\tTRGc110();\r\n\t\r\n\tvar tmp = (0).toFixed(0);\r\n\r\n}", "function calcola_jda(){\n\n // funzione per il calcolo del giorno giuliano per il 0.0 gennaio dell'anno corrente.\n // by Salvatore Ruiu Irgoli-Sardegna (Italy) dicembre 2009\n // restituisce dataGiuliana, giorno giuliano inizio anno.\n // recupera automaticamente l'anno.\n // il giorno giuliano è calcolato per il tempo 0 T.U. di Greenwich.\n \n var data=new Date(); \n\n var anno =data.getYear(); // anno\n var mese =1; // mese \n var giorno=0.0; // giorno=0.0\n \nif (anno<1900) {anno=anno+1900;} // correzione anno per il browser.\n\nvar dataGiuliana=costanti_jd(giorno,mese,anno,0,0,0); // valore del giorno giuliano per lo 0.0 gennaio dell'anno corrente.\n\n dataGiuliana=dataGiuliana*1 // definire come valore numerico.\n // \nreturn dataGiuliana;\n\n}", "function jd_data(njd){\n // funzione per il calcolo della data dal numero del giorno giuliano.\n // by Salvatore Ruiu Irgoli-Sardegna (Italy) novembre 2011.\n // restituisce i valori numerici gg/mm/yy.\n // il valore gg è in giorni e ore decimali. Moltiplicare la parte decimale di qq. x24.per avere le ore.\n // njd=numero del giorno giuliano.\n \n var I=parseInt(njd+0.50);\n var F=(njd+0.50)-I;\n var A=0;\n var B=0;\n\n if (I>=2229160){A=parseInt((I-1867216.25)/36524.25); B=I+1+A-parseInt(A/4);}\nelse {B=I;}\n\nvar C=B+1524;\nvar D=parseInt((C-122.1)/365.25);\nvar E=parseInt(365.25*D);\nvar G=parseInt((C-E)/30.6001);\n\n// recupero del giorno.\n\nvar giorno=C-E+F-parseInt(30.6001*G); // giorno con ore decimali.\n giorno=giorno; // toFixed(6)\n\n // recupero del mese.\n\nvar mese=0;\n\n if (G<13.5) {mese=G-1; }\nelse if (G>13.5) {mese=G-13; }\n\n // recupero dell'anno.\n\nvar anno=0;\n\n if (mese>2.5) {anno=D-4716; }\nelse if (mese<2.5) {anno=D-4715; }\n\n njd=jdHO(njd); // riporta il giorno giuliano (njd), alle ore 0(zero) del giorno.\n\nvar gio_sett=(njd+1.5)%7; // recupera il resto: calcola il numero del giorno della settimana (0=domenica, 1=lunedì....)\nvar gio_sett_n=gio_sett; // giorno della settimana numerico.\n \nvar gio_sett_en=\"\"; // giorno della settimana in inglese.\n\n if(gio_sett==0){gio_sett=\"Do\"; gio_sett_en=\"Su\"; }\nelse if(gio_sett==1){gio_sett=\"Lu\"; gio_sett_en=\"Mo\"; }\nelse if(gio_sett==2){gio_sett=\"Ma\"; gio_sett_en=\"Tu\"; }\nelse if(gio_sett==3){gio_sett=\"Me\"; gio_sett_en=\"We\"; }\nelse if(gio_sett==4){gio_sett=\"Gi\"; gio_sett_en=\"Th\"; }\nelse if(gio_sett==5){gio_sett=\"Ve\"; gio_sett_en=\"Fr\"; }\nelse if(gio_sett==6){gio_sett=\"Sa\"; gio_sett_en=\"Sa\"; }\n\nvar data_calendario=new Array(giorno,mese,anno,gio_sett,gio_sett_en,gio_sett_n);\n // array 0 1 2 3 4 5 \n\nreturn data_calendario;\n\n\n}", "function obli_ecli(njd){\n\n // calcola l'obliquità dell'eclittica.\n // per l'equinozio della data.\n // T= numero di secoli giuliani dallo 0.5 gennaio 1900.\n\n var T=(njd-2415020.0)/36525;\n\n var obli_eclittica=23.452294-0.0130125*T-0.00000164*T*T+0.000000503*T*T*T;\n\nreturn obli_eclittica; //obliquità in gradi\n\n}", "function checaHora(diaEscolhido) {\n var mesId = \"d\";\n var mesAt = mes + 1;\n mesId = mesId.replace(\"d\", mesAt);\n \n\n var checaDia = \"d\";\n var checaDia = checaDia.replace(\"d\", diaEscolhido);\n\n tirarHoraGasta(horaIntervalo.inicio, horaIntervalo.fim);\n\n if (agMes[mesId] != null) {\n for (var i = 0; i < agMes[mesId].length; i++) {\n\n if (agMes[mesId][i].dia == checaDia) {\n\n var minutoM = 0; //minuto marcado\n var horaM = 0; //hora marcada\n\n //se for igual a 3 para saber se a hora é\n //menor que 10\n if (agMes[mesId][i].hora.length == 3) {\n horaM = parseInt(agMes[mesId][i].hora[0]);\n minutoM = agMes[mesId][i].hora[1] + agMes[mesId][i].hora[2];\n minutoM = parseInt(minutoM);\n }\n else {\n horaM = agMes[mesId][i].hora[0] + agMes[mesId][i].hora[1];\n minutoM = agMes[mesId][i].hora[2] + agMes[mesId][i].hora[3];\n horaM = parseInt(horaM);\n minutoM = parseInt(minutoM);\n }\n var horaG = agMes[mesId][i].horaGasta; //hora gasta\n var minutoG = agMes[mesId][i].minutoGasto; // minuto gasto\n horaG = parseInt(horaG);\n minutoG = parseInt(minutoG);\n\n var horaS = horaM + horaG; //hora somada\n var minutoS = minutoM + minutoG; //minuto somado\n \n if (minutoS > 30) {\n minutoS = 0;\n ++horaS;\n }\n\n var tMinuto = \"d\"; //texto Minuto\n var tHora = \"d\"; //texto hora\n if (minutoS == 0) {\n tMinuto = tMinuto.replace(\"d\", \"00\");\n }\n else {\n tMinuto = tMinuto.replace(\"d\", minutoS);\n }\n\n tHora = tHora.replace(\"d\", horaS);\n\n var fim = tHora + tMinuto;\n fim = parseInt(fim);\n var inicio = agMes[mesId][i].hora;\n tirarHoraGasta(inicio, fim);\n }\n }\n }\n}", "function calcPorcentajeMoras(){\n\n\tif (pm_called == 0){\n\t\tgetFiscalMoraInfo();\n\t\treturn;\n\t}\n\t\n\tvar norectificativa = 1;\n\tif (document.getElementById('declarationType').value=='| 2 | RECTIFICATIVA'){\n\t\tnorectificativa = 0;\n\t}\n\tif(CONTRAVENSION_SMOV && CONTRAVENSION_CMOV != null){\n\t\tdocument.getElementById('c76').value = CONTRAVENSION_CMOV * norectificativa;\t\n\t\tif(document.getElementById('c76').value == 0){\n\t\t\tdocument.getElementById('c76').value == \"\";\n\t\t}\n\t\tif(document.getElementById('c76').value != null)\n \t\t colocarpuntos(document.getElementById('c76'));\n\t}\n\trefreshVars();\n\tTRGc78();\n\tTRGc80();\n\tTRGc80_0();\n\tvar tmp = (0).toFixed(0);\n}", "function getDateFromCalendarClose(inputArray, references){\n\tvar sDate = inputArray.year + '-' + inputArray.month + '-' + inputArray.day + ' ' + inputArray.hour + ':' + inputArray.minute;\n\treferences.myDate.value = sDate;\n\t\n\t//alert(sDate);\n\t\n\tvar dDate = new Date();\n\tdDate.setFullYear(inputArray.year, inputArray.month-1, inputArray.day);\n\tdDate.setHours(inputArray.hour);\n\tdDate.setMinutes(inputArray.minute);\n\tdDate.setSeconds(0);\n\tdDate.setMilliseconds(0);\n\t\n\tvar iInterval = now.getTime() - dDate.getTime();\n\t\n\t//alert(sDate + \" - \" + dDate + \" - \"+iInterval);\n\t\n\tif (iInterval < 60000)\n\t iInterval = 0;\n\t\n\tdocument.getElementById(\"interval.\"+references.myDate.id).value = iInterval;\n }", "function getValues() {\n jornadaCertPonto = parseInt(document.getElementById('jornadaCertPonto').value);\n almoco = parseInt(document.getElementById('almoco').value);\n tolerancia = parseInt(document.getElementById('tolerancia').value);\n semAlmoco = parseInt(document.getElementById('semAlmoco').value);\n horasAbonadas = document.getElementById('horasAbonadas').value;\n\n if (isNaN(jornadaCertPonto)) {\n jornadaCertPonto = 9;\n }\n if (isNaN(almoco)) {\n almoco = 1;\n }\n if (isNaN(tolerancia)) {\n tolerancia = 10;\n }\n if (isNaN(semAlmoco)) {\n semAlmoco = 4;\n }\n if (horasAbonadas === '') {\n horasAbonadas = '00:00';\n }\n\n setValues();\n // trata horas incluídas com segundos HH:mm:ss\n if (horasAbonadas.length == 8) {\n horasAbonadas = horasAbonadas.split(':')[0] + ':' + horasAbonadas.split(':')[1];\n }\n\n jornadaSap = jornadaCertPonto - almoco;\n document.getElementById('jornadaSap').value = jornadaSap;\n}", "function _diferenciaFechas(FechaIni, FechaFin)\r\n{\r\n //Obtiene dia, mes y año \r\n var fecha1 = new _fecha( FechaIni ); \r\n var fecha2 = new _fecha( FechaFin );\r\n\r\n //Obtiene Objetos Date\r\n var miFecha1 = new Date( fecha1.anio, fecha1.mes, fecha1.dia );\r\n var miFecha2 = new Date( fecha2.anio, fecha2.mes, fecha2.dia ); \r\n //Resta fechas y redondea \r\n var diferencia = (miFecha2.getTime() - miFecha1.getTime())/1000*60; \r\n //var dias = Math.floor(diferencia / (1000 * 60 * 60 * 24)); \r\n //return dias; \t\r\n return diferencia;\t\t\r\n}", "function calc_circunferencia(diametro) {\n return diametro * PI;\n}", "function calcola_datan2(lingua){\n\n // parametri lingua= \"ITA\" - \"ING\" \n // by Salvatore Ruiu Irgoli-Sardegna (Italy) dicembre 2009.\n // utilizzo caratteri speciali ANSI.\n // restituisce la stringa DataIns.\n \n\t \n\tvar DataInsn=\".\";\n \n var data=new Date();\n\n var anno =data.getYear(); // anno\n var mese =data.getMonth(); // mese 0 a 11 \n var giorno=data.getDate(); // numero del giorno da 1 a 31\n var giorno_settimana=data.getDay(); // giorno della settimana 0 a 6\n var ora =data.getHours(); // ora del giorno da 0 a 23\n var minuti=data.getMinutes(); // minuti da 0 a 59\n var secondi=data.getSeconds(); // secondi da 0 a 59\n \n if (anno<1900) { anno=anno+1900; } // correzione anno\n\n if (ora<10){ ora='0'+ora;}\n \n if (minuti<10){minuti='0'+minuti;}\n\n if (secondi<10) {secondi='0'+secondi;}\n\n mese=mese+1;\n\n if (lingua==\"ING\") { DataInsn=mese+\":\"+giorno+\":\"+anno+\":\"+ora+\":\"+minuti+\":\"+secondi }\n else { DataInsn=giorno+\":\"+mese+\":\"+anno+\":\"+ora+\":\"+minuti+\":\"+secondi }\n\n return DataInsn;\n }", "function buscaCorrelativo(idSerie){\r\n\tvar seriecompret = nlapiLookupField('customrecord_lmry_serie_compro_retencion', idSerie, [ 'custrecord_lmry_valor_actual', 'custrecord_lmry_cant_digitos' ] );\r\n\tnumeroActual = parseFloat(seriecompret.custrecord_lmry_valor_actual);\r\n\tcantDigitos = seriecompret.custrecord_lmry_cant_digitos;\r\n}", "function mostrarFechaFin(){\n var categoria_farmacologica = $('#categoria_farmacologica').text();\n var fechaInicio = $('#fechaInicio').val();\n var duracion = $('#duracion').val();\n var periodo = \"\";\n var dias = 0;\n var fechaFin = \"\";\n\n if(categoria_farmacologica.toLowerCase() == 'antibiotico'){\n fechaFin = sumarfecha(duracion, fechaInicio);\n }else{\n periodo = $('#periodo').val();\n dias = ConvercionDias(duracion, periodo);\n fechaFin = sumarfecha(dias, fechaInicio);\n }\n\n if(duracion === ''){\n $('#fechaFin').val(fechaInicio);\n }else{\n $('#fechaFin').val(fechaFin);\n }\n}", "function validacionfecFinValifecInicVali(){\n\t\t\tif ((get('calGuiasFrm.fecFinVali','T').toString()==\"\") || \n\t\t\t(get('calGuiasFrm.fecInicVali','T').toString()==\"\"))\n\t\t\t\t//en este caso no hay alguno de los valores introducidos y no se puede realizar la verificaci?n.\n\t\t\t\treturn 'OK';\n\t\t\t\n\t\t\t\tvar errorLevel = EsFechaValida(get('calGuiasFrm.fecInicVali','T') ,get('calGuiasFrm.fecFinVali','T') , \"calGuiasFrm\", \"N\");\n\t\t\t\t\n\t\t\t\n\t\t\tif ( errorLevel == 3){\n\t\t\t return GestionarMensaje(\"CalGuias.fecFinValifecInicVali.message\");\n\t\t\t}else\n\t\t\t return 'OK';\n\t\t}", "function getPeso (adcvalue, devider) {\n\n\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t return ((((parseInt(adcvalue)/devider) * 230)/1000)/3600) *12\n\n\t\t\t\t\t\t\t\t\t\t }", "function calcular() {\n qtdCadeiras = Number(nCadeiras.value);\n var resp = 0;\n\n if ((qtdCadeiras.value) <= 0) {\n alert(\"A quantidade deve ser maior que 0!\");\n nCadeiras.value = '';\n }\n else {\n // ATRIBUINDO O VALOR DE ACORDO COM O MATERIAL E TIPO DA CADEIRA\n if (materialCadeira == 'aluminio' && tipoCadeira == 'praia'){\n resp = 75 * qtdCadeiras;\n }\n else if (materialCadeira == 'plastico' && tipoCadeira == 'praia') {\n resp = 50 * qtdCadeiras;\n }\n else if (materialCadeira == 'ferro' && tipoCadeira == 'praia') {\n resp = 80 * qtdCadeiras;\n }\n else if (materialCadeira == 'aluminio' && tipoCadeira == 'jardim') {\n resp = 70 * qtdCadeiras;\n }\n else if (materialCadeira == 'plastico' && tipoCadeira == 'jardim') {\n resp = 35 * qtdCadeiras;\n }\n else {\n resp = 55 * qtdCadeiras;\n }\n\n // DESCONTO DE 3%\n if (qtdCadeiras > 50) {\n resp -= (resp * 0.03);\n }\n\n // DESCONTO UNITARIO PGTO. À VISTA\n desconto = 0;\n console.log(resp);\n materialCadeira == 'aluminio' ? desconto = resp * 0.035 : desconto = resp * 0.05;\n respDesconto = resp - desconto;\n materialCadeira == 'aluminio' ? desco = 3.5 : desco = 5;\n \n\n respCalculo.innerHTML = `<p>O orçamento para a compra de <b>${qtdCadeiras}</b> <i>cadeira(s) de ${tipoCadeira}</i> de <i>${materialCadeira}</i> é R$ <b>${resp.toFixed(2)}</b></p>\n <p>Para pagamento a vista o desconto é de <b>${desco}%</b> e seu pedido ficará por R$ <b>${respDesconto.toFixed(2)}</b></p>`; \n }\n}", "function establecerFechas() {\n let fecha, anio, mes, dia, hora;\n fechaVenta = new Date().toLocaleString();\n if ($('#switch-pi-prod').prop('checked') || $('#switch-pi-late-prod').prop('checked')) {\n fecha = $('#pi-fecha').val();\n fecha = fecha.split('-');\n anio = fecha[0];\n mes = fecha[1];\n dia = fecha[2];\n hora = $('select[id=pi-hora] option:selected').text();\n } else {\n fecha = fechaVenta;\n fecha = fecha.split(\" \");\n hora = fecha[1];\n fecha = fecha[0];\n fecha = fecha.split(\"/\");\n dia = fecha[0];\n if (parseInt(dia) < 10) dia = \"0\" + dia;\n mes = fecha[1];\n if (parseInt(mes) < 10) mes = \"0\" + mes;\n anio = fecha[2];\n }\n fechaEntrega = dia + \"/\" + mes + \"/\" + anio + \" \" + hora;\n}", "function obtenerColoresDegradados() {\r\n return [\"90-#ff0000-#9d0000\",\"90-#00ff00-#009d00\",\"90-#0000ff-#00009d\",\"90-#ffff00-#A99200\",\"90-#FF8000-#AA6000\",\"90-#8000FF-#420373\",\"90-#FF8080-#FF8888\",\"90-#808080-#00009d\",\"90-#800000-#00009d\",\"90-#800080-#4D0178\"]; \r\n}", "function calculo() {\r\n\r\n let peso = document.dados.peso.value;\r\n let altura = document.dados.altura.value;\r\n if ((validacao(peso) && validacao(altura) && isNumber(peso) && isNumber(altura)) == true) {\r\n\r\n \t//IMC\r\n\r\n imc = parseFloat(peso) / (parseFloat(altura) * parseFloat(altura));\r\n\r\n if (imc < 0.00185) {\r\n document.dados.res.value = \" Subnutrido\";\r\n } else if (imc >= 0.00185 && imc <= 0.00249) {\r\n document.dados.res.value = \" Saudável\";\r\n } else if (imc > 0.00249 && imc <= 0.00299) {\r\n document.dados.res.value = \" Sobrepeso\";\r\n } else if (imc > 0.00299 && imc <= 0.00349) {\r\n document.dados.res.value = \" Obesidade grau 1\";\r\n } else if (imc > 0.00349 && imc <= 0.00399) {\r\n document.dados.res.value = \" Obesidade grau 2\";\r\n } else {\r\n document.dados.res.value = \" Obesidade grau 3\";\r\n }\r\n\r\n //Intervalo\r\n\r\nlet inter_1=parseFloat( 0.00185)*parseFloat(altura)*parseFloat(altura);\r\nlet inter_2 = parseFloat(0.00249)*parseFloat(altura)*parseFloat(altura);\r\n\r\n\r\n document.dados.inter.value = \" Entre \" + inter_1 + \" KG e \" + inter_2 + \" KG\"; \r\n\r\n\r\n\r\n \r\n}\r\n\r\ndocument.dados.peso.value = \"\";\r\ndocument.dados.altura.value=\"\";\r\n}", "function sc_ore(ore_dec){\n\n // by Salvatore Ruiu Irgoli-Sardegna (Italy). \n // scomposizione delle ore decimali [ore_dec], in hh |mm |ss. - tronca i decimali dei secondi senza applicare arrotondamenti.\n // restituisce la variabile stringa [ore_hms].\n // ATTENZIONE! La funzione riporta le ore all'interno dell'intervallo: 0-24.\n // agg: Dicembre 2011\n\n var ored=ore_24(ore_dec); // Intervallo ore: 0-24\n\n var ore= parseInt(ored); // Ore.\n var minuti= parseInt((ored-ore)*60); // Minuti.\n var secondi= parseInt(((ored-ore)*60-minuti)*60); // Secondi. \n\n ore= String(ore); // trasforma il numero in stringa.\n minuti= String(minuti ); // trasforma il numero in stringa. \n secondi= String(secondi); // trasforma il numero in stringa. \n\n //if (ore_dec<0){ore=\"-\"+ore;} // recupera il segno meno.\n\n if (ore.length<2 ){ ore='0'+ore;}\n if (minuti.length<2 ){ minuti='0'+minuti;}\n if (secondi.length<2){secondi='0'+secondi;}\n \n var ore_hms=ore+\"h. \"+minuti+\"m. \"+secondi+\"s.\";\n\t \nreturn ore_hms; \n\n}", "function Exo_4_3() \r\n // DEBUT\r\n\t{ \r\n var iHeures, iMinutes, iSecondes;\r\n\r\n //Ecrire \"Entrez l'heure actuelle :\"\r\n //Lire iHeures\r\n iHeures=prompt(\"Entrez l'heure actuelle :\");\r\n //Ecrire \"Entrez les minutes :\"\r\n //Lire iMinutes\r\n iMinutes=prompt(\"Entrez les minutes :\");\r\n //Ecrire \"Entrez les secondes :\"\r\n //Lire iSecondes\r\n iSecondes=prompt(\"Entrez les secondes :\");\r\n\r\n iSecondes=parseInt(iSecondes)+1;\r\n\r\n //Si iSecondes=60 alors\r\n if (iSecondes==60)\r\n {\r\n iSecondes=0;\r\n iMinutes=parseInt(iMinutes)+1;\r\n }\r\n\r\n //Si iMinutes=60 alors\r\n if (iMinutes==60)\r\n {\r\n iMinutes=0;\r\n iHeures=parseInt(iHeures)+1;\r\n }\r\n \r\n //Si iHeures=60 alors\r\n if (iHeures==24)\r\n {\r\n iHeures=0;\r\n }\r\n\r\n alert(\"Dans une seconde, il sera \" + iHeures + \" heure(s) \" + iMinutes + \" minute(s) \" + iSecondes + \" seconde(s)\" );\r\n }", "function idade(ano_nascimento, mes_nascimento, dia_nascimento) {\r\n ano_atual = new Date;\r\n ano_atual = ano_atual.getFullYear();\r\n mes_atual = new Date().getMonth() + 1\r\n dia_atual = new Date().getDate()\r\n if (mes_atual < mes_nascimento || mes_atual == mes_nascimento && dia_atual < dia_nascimento) {\r\n ano_atual -= 1\r\n }\r\n return ano_atual - ano_nascimento;\r\n\r\n }", "function duracionCero(hrs, min){\n \n if($(hrs).val()===\"0\" && $(min).val()===\"00\"){\n alert(\"La duracion (horas y minutos) de la audiencia no pueden ser cero\");\n $(hrs).val('');\n $(min).val('');\n }\n}", "function identificarData(codigo, tipoCodigo) {\n codigo = codigo.replace(/[^0-9]/g, '');\n const tipoBoleto = identificarTipoBoleto(codigo);\n\n let fatorData = '';\n let dataBoleto = new Date();\n\n dataBoleto.setFullYear(1997);\n dataBoleto.setMonth(9);\n dataBoleto.setDate(7);\n dataBoleto.setHours(23, 54, 59);\n\n if (tipoCodigo === 'CODIGO_DE_BARRAS') {\n if (tipoBoleto == 'BANCO') {\n fatorData = codigo.substr(5, 4)\n\n dataBoleto.setDate(dataBoleto.getDate() + Number(fatorData));\n dataBoleto.setTime(dataBoleto.getTime() + dataBoleto.getTimezoneOffset() - (3) * 60 * 60 * 1000);\n var dataBoletoform = dataBoleto.getDate() + \"/\" + (dataBoleto.getMonth() + 1) + \"/\" + dataBoleto.getFullYear()\n\n return dataBoletoform;\n } else {\n dataBoleto = null\n\n return dataBoleto;\n }\n } else if (tipoCodigo === 'LINHA_DIGITAVEL') {\n if (tipoBoleto == 'BANCO') {\n fatorData = codigo.substr(33, 4)\n dataBoleto.setDate(dataBoleto.getDate() + Number(fatorData));\n dataBoleto.setTime(dataBoleto.getTime() + dataBoleto.getTimezoneOffset() - (3) * 60 * 60 * 1000);\n var dataBoletoform = dataBoleto.getDate() + \"/\" + (dataBoleto.getMonth() + 1) + \"/\" + dataBoleto.getFullYear()\n\n return dataBoletoform;\n } else {\n dataBoleto = null\n\n return dataBoleto;\n }\n }\n}", "function clima7Dias(){\n\n\t\tconst url7Days = 'https://api.openweathermap.org/data/2.5/onecall?lat='+latitud+'&lon='+longitud+'&units=metric&lang=sp&exclude=current,minutely,hourly,alerts&appid=509a71114c79dce7fe4e067058ed0286';\n\n\t\tfetch(url7Days).then(response => response.json())\n\t\t.then(data => {\n\n\t\t\tconsole.log(url7Days);\n\n\t\t\tlet daily = data['daily'];\n\t\t\tlet tomorrow = data['daily'][0];\n\t\t\tlet tomorrowTemp = data['daily'][0]['temp'];\n\t\t\t// console.log(tomorrowTemp);\n\t\t\tlet tomorrowTempMin = data['daily'][0]['temp']['min'];\n\t\t\t// console.log(tomorrowTempMin);\n\t\t\tlet tomorrowTempMax = data['daily'][0]['temp']['max'];\n\t\t\t// console.log(tomorrowTempMax);\n\n\t\t\tlet iconClimaTomorrowDescripcion = data['daily'][0]['weather'][0]['icon'];\n\t\t\t// console.log(iconClimaTomorrowDescripcion);\n\n\t\t\tlet postTomorrowTempMin = data['daily'][1]['temp']['min'];\n\t\t\t// console.log(postTomorrowTempMin);\n\t\t\tlet postTomorrowTempMax = data['daily'][1]['temp']['max'];\n\t\t\t// console.log(postTomorrowTempMax);\n\n\t\t\tlet iconClimaPostTomorrowDescripcion = data['daily'][1]['weather'][0]['icon'];\n\t\t\t// console.log(iconClimaPostTomorrowDescripcion);\n\n\t\t\t// Imprimir los datos del clima - dependiendo de la respuesta del usuario\n\n\t\t\ttempMaxTomorrow.textContent = `${Math.round(tomorrowTempMax)} °C /`;\n\t\t\ttempMinTomorrow.textContent = `${Math.round(tomorrowTempMin)} °C`;\n\n\t\t\ttempMaxPostTomorrow.textContent = `${Math.round(postTomorrowTempMax)} °C /`;\n\t\t\ttempMinPostTomorrow.textContent = `${Math.round(postTomorrowTempMin)} °C`;\n\t\t\t// Imprimir los datos del clima - dependiendo de la respuesta del usuario\n\n\t\t\t$(function mostrarImagenSiguientesDias() { \n\t\t\t\t// console.log(iconClimaDescripcion);\n\t\t\t\t$(\"#imagenClimaMañana\").attr(\"src\",`http://openweathermap.org/img/wn/${iconClimaTomorrowDescripcion}@2x.png`);\n\t\n\t\t\t\t$(\"#imagenClimaPostMañana\").attr(\"src\",`http://openweathermap.org/img/wn/${iconClimaPostTomorrowDescripcion}@2x.png`);\n\t\t\t});\n\t\t\t\n\t\t})\n\t\t.catch(error => alert(\"Nombre de la ciudad Invalido\"));\n\n\t\t// API CLIMA Openweathermap ---------------------\n\n\t}", "function calculaEdad(dia, mes, ano)\n{\n //tomar los valores actuales\n var fecha_hoy = new Date();\n var ahora_ano = fecha_hoy.getFullYear();\n var ahora_mes = fecha_hoy.getMonth()+1;\n var ahora_dia = fecha_hoy.getDate();\n \n // realizar el calculo\n var edad = (ahora_ano + 1895) - ano;\n if ( ahora_mes < mes )\n \tedad--;\n \n if ((mes == ahora_mes) && (ahora_dia < dia))\n \tedad--;\n\n if (edad > 1894)\n edad -= 1895;\n \n return edad;\n}", "function kiekDienuIkiKaledu() {\n console.log(\"266\");\n // siandienos data\n let today = new Date();\n // kaledu data\n let christmas = new Date(\"2021-12-24\");\n console.log(\"today\", today.toDateString(), \"christmas\", christmas.toDateString());\n\n // skirtumo tarp datu\n let diffMs = christmas - today;\n console.log(\"diffMs\", diffMs);\n // paversti ta skirtuma dienom\n let msToDays = diffMs / 1000 / 3600 / 24;\n // gaunam kiek pilnu dienu\n let wholeDays = Math.floor(msToDays);\n\n // panaudojom pagalbine funkcija\n //let wholeDays = daysDiff(today, christmas);\n\n // atspausdinti\n console.log(\"iki kaledu liko\", wholeDays, \"dienu\");\n}", "function contador() {\r\n\t\tvar minutes_day = 1440;\r\n\r\n\t\tvar hora_inicio_clases = 8;\r\n\t\tvar minuto_inicio_clases = 30;\r\n\t\tvar hora_inicio = (hora_inicio_clases*60)+minuto_inicio_clases;\r\n\r\n\t\tvar hora_fin_clases = 14;\r\n\t\tvar minuto_fin_clases = 20;\r\n\t\tvar hora_fin = (hora_fin_clases*60)+minuto_fin_clases;\r\n\r\n\t\tvar hoy = new Date();\r\n\t\tvar h = hoy.getHours();\r\n\t\tvar m = hoy.getMinutes();\r\n\t\tvar hora_actual = (h*60) + m;\r\n\r\n\t\tvar day = hoy.getDay();\r\n\r\n\t\tif ((day == 6 || day == 0) || hora_actual < hora_inicio || hora_actual > hora_fin) // Sábado o domingo, o antes de inicio, o después de fin\r\n\t\t{\r\n\t\t\tvar horas_proxima_clase = 0;\r\n\r\n\t\t\thoras_proxima_clase = horas_proxima_clase + (minutes_day - hora_actual); // Suma los minutos que quedan del día actual\r\n\t\t\thoras_proxima_clase = horas_proxima_clase + hora_inicio; // Suma minutos hasta inicio primera clase\r\n\r\n\t\t\tif (day == 6) { // Si además es sabado\t\r\n\t\t\t\thoras_proxima_clase = horas_proxima_clase + minutes_day; // Suma todos los minutos del domingo\r\n\t\t\t} \r\n\r\n\r\n\t\t\tdocument.getElementById('contador_texto').innerHTML= \"Tiempo para próxima clase:\" + \"<br/>\" + PonerCero(parseInt(horas_proxima_clase/60)) + \":\" + PonerCero(horas_proxima_clase%60) + \"h\";\r\n\t\t} else {\r\n\t\t\tvar horas_fin_clase = hora_fin - hora_actual;\r\n\t\t\tdocument.getElementById('contador_texto').innerHTML= \"Tiempo para final clases:\" + \"<br/>\" + PonerCero(parseInt(horas_fin_clase/60)) + \":\" + PonerCero(horas_fin_clase%60) + \"h\";\r\n\t\t}\r\n\t}", "function DescuentoReposo(){\n \n //recuperamos el valor descuento reposo anterior\n var descuentoReposo=document.getElementById(\"sal_rep\").value;\n //recuperamos el sueldo neto del input\n var SueldoNeto=document.getElementById('sueldoNeto').value;\n //si anteriormente ya tenia un valor, debe reestablecer\n if(descuentoReposo > 0)\n {\n var suma=parseFloat(SueldoNeto) + parseFloat(descuentoReposo);\n document.getElementById(\"sueldoNeto\").value=suma;\n }\n \n var SaldoBrutoIni=document.getElementById('sueldoBruto').value;\n //calcula el jpornal diario\n var jornal=SaldoBrutoIni/30;\n //obtiene dias de permisos/llegada tardia\n var dias= document.getElementById('DiaReposo').value;\n //descuento por dia de 50 %\n var descuentoINTN=(jornal/2);\n document.getElementById(\"sal_rep\").value=(descuentoINTN*dias);\n //Actualiza el neto a cobrar\n var SaldoNeto= document.getElementById('sueldoNeto').value;\n document.getElementById(\"sueldoNeto\").value=SaldoNeto-(descuentoINTN*dias);\n \n \n \n //guardamos el valor de salario neto(esto se actualizara con cada descuento)\n var sueldoneto=document.getElementById('sueldoNeto').value;\n document.getElementById(\"sal_neto\").value=sueldoneto;\n }", "function llenarComboDias(nombreCombo) {\r\n\tFECHA_INICIO = new String(document.formularioFiltro.fechaInicio.value);\r\n\tFECHA_FIN = new String(document.formularioFiltro.fechaFinRegistro.value);\r\n\tvar arregloInicio = FECHA_INICIO.split(\"/\");\r\n\tvar diaInicio = arregloInicio[0];\r\n\tvar mesInicio = arregloInicio[1];\r\n\tvar annoInicio = arregloInicio[2];\r\n\tmesInicio = mesInicio - 1;\r\n\tvar fechaInicio = new Date(annoInicio, mesInicio, diaInicio);\r\n\tvar diasSiguiente = 0;\r\n\tvar stringDia = \"\";\t//Este string es una variabla auxiliar para guardar el dia y agregarlo al combo\r\n\tlimpiarCombo(document.formularioFiltro.valorDia);\t\r\n\t\r\n\t//Agregamos la primera opcion del combo vacia \r\n\tstringDia = \"\";\r\n\taddOption(document.formularioFiltro.valorDia, stringDia, 0);\r\n\tfor (var i = 0; i < 7; i++) {\r\n\t\tdiasSiguiente = fechaInicio.getTime() + ((24 * 60 * 60 * 1000) * i);\r\n\t\r\n\t\t// Cosntruimos el objeto Date con la cantidad de\r\n\t\t// miliseg que representan cada dia de la semana\r\n\t\tvar fecha = new Date(diasSiguiente);\r\n\t\tvar dia = fecha.getDate();\r\n\t\tvar mes = fecha.getMonth() + 1;\r\n\t\tvar anno = fecha.getFullYear();\r\n\t\tstringDia = dia + \"/\" + mes + \"/\" + anno;\t\t\r\n\t\t\r\n\t\t// agregamos la opcion\r\n\t\taddOption(document.formularioFiltro.valorDia, stringDia, i);\r\n\t}\r\n}", "function mostrarFechaFinCursar (){\n //capturo cual vacuna está seleccionada\n let estadoSeleccionado = document.getElementById(\"inputEstado\").value;\n const fechaFinCurso = document.getElementById(\"finCursar\");\n \n if (estadoSeleccionado === \"2\") {\n //oculto la segunda dosis si la vacuna es de una dosis\n $('#finCursar').slideDown(400);\n }else{\n $('#finCursar').slideUp(400);\n //muestro la segunda dosis si la vacuna es de dos dosis\n }\n}", "function CalcularFecha(HorasLaborales,HorasTrabajo,inicio){\n var ini = new Date(inicio);\n console.log(\"Parametro de inicio: \" + inicio + \" horas Laborales: \" + HorasLaborales + \" HorasTabajo: \" + HorasTrabajo);\n var semana = [\"dom\", \"lun\", \"mar\", \"mie\", \"jue\", \"vie\", \"sab\"];\n var indice = 1;\n var dias = 0;\n var fhoras = 0;\n var DomingoPivote = new Date();\n if(HorasTrabajo > 0){\n while(indice > 0){//siclo para contar los dias y horas en base a horas laborales\n if(HorasTrabajo >= HorasLaborales){\n HorasTrabajo = HorasTrabajo - HorasLaborales;\n dias++;\n indice++;\n }else if(HorasTrabajo < HorasLaborales){\n fhoras = HorasTrabajo;\n indice = 0;\n }\n console.log(\"indice: \" + indice);\n }\n }\n console.log(\"Fecha inicio: \" + inicio);\n DomingoPivote = new Date(ini.setHours(ini.getHours() + (dias*24)));//calcula la fecha final para una OT\n if(DomingoPivote.getUTCDay() == 0){//Se busca incrementar un dia si este dia se calcula en domingo\n dias++;\n }\n ini = new Date(inicio);\n console.log(\"Fecha ini: \" + ini);\n ini.setMinutes(ini.getMinutes() + ini.getTimezoneOffset());//SE AJUSTA FECHA Y HORA\n var HorasRealesTrabjo = (dias*24) + fhoras;//horas reales a trabajar en base a la maquina, calculando el total en horas\n var FechaFin = new Date(ini.setHours(ini.getHours() + HorasRealesTrabjo));//calcula la fecha final para una OT\n \n console.log(\"Fecha funcion: \" + FormtatoFechas(FechaFin));\n return FechaFin;\n}", "function calcola_jd_anno(anno){\n\n // by Salvatore Ruiu Irgoli-Sardegna (Italy) dicembre 2009\n // funzione uguale alla precedente ma il calcolo viene effettuato per lo 0.0 gennaio dell'anno indicato dal parametro (anno).\n\n var mese =1; // mese = 1\n var giorno=0.0; // numero del giorno 0.0\n\n\nvar dataGiuliana=costanti_jd(giorno,mese,anno,0,0,0); // valore del giorno giuliano per lo 0.0 gennaio dell'anno specificato.\n\n dataGiuliana=dataGiuliana*1 // definire come valore numerico.\n\nreturn dataGiuliana;\n\n}", "function datam(c,q){\n\tif (c) {\n\t\tif (validata(c)){\t\n\t\t\tvar ano = '' + c.value.substring(6,10);\n\t\t\tvar mes = '' + Math.floor(c.value.substring(3,5))-1;\n\t\t\tvar dia = '' + c.value.substring(0,2);\n\t\t\tvar data=new Date(ano,mes,dia);\n\t\t\tdata.setDate(data.getDate()+q);\n\t\t\tdia=data.getDate();\n\t\t\tif (dia<10){\tdia='0'+dia; }\n\t\t\tmes=data.getMonth()+1;\t\t\t\n\t\t\tif (mes<10){\tmes='0'+mes; }\n\t\t\tano=data.getYear();\n\t\t\tnData=dia+'/'+mes+'/'+ano;\n\t\t\tc.value=nData;\n\t\t\treturn true;\n\t\t}\n\t}\n}", "function calcola_datan(lingua){\n\n // parametri lingua= \"ITA\" - \"ING\" \n // by Salvatore Ruiu Irgoli-Sardegna (Italy) dicembre 2009.\n // utilizzo caratteri speciali ANSI.\n // restituisce la stringa DataIns.\n // utilizzata solo per il datario delle fasi lunari\n // per la data completa utilizzare [calcola_datan2(lingua)]\n\t \n\tvar DataInsn=\".\";\n \n var data=new Date();\n\n var anno =data.getYear(); // anno\n var mese =data.getMonth(); // mese 0 a 11 \n var giorno=data.getDate(); // numero del giorno da 1 a 31\n var giorno_settimana=data.getDay(); // giorno della settimana 0 a 6\n var ora =data.getHours(); // ora del giorno da 0 a 23\n var minuti=data.getMinutes(); // minuti da 0 a 59\n var secondi=data.getSeconds(); // secondi da 0 a 59\n \n if (anno<1900) { anno=anno+1900; } // correzione anno\n\n if (ora<10){ ora='0'+ora;}\n \n if (minuti<10){minuti='0'+minuti;}\n\n if (secondi<10) {secondi='0'+secondi;}\n\n mese=mese+1;\n\n if (lingua==\"ING\") { DataInsn=mese+\":\"+giorno+\":\"+anno+\":\"+ora }\n else { DataInsn=giorno+\":\"+mese+\":\"+anno+\":\"+ora }\n\n return DataInsn;\n }", "adiciona(event){\n\t\tevent.preventDefault()\n\t\tconsole.log(this._inputData.value)\n\t\t\n\t\t\n\t\t//converte o horario para tipo date.\n\t/*\tlet data =new Date(\n\t\t ...this._inputData.value.split(\"-\").map(\n\t\t (item, idx) => {\n\t\t if (idx === 1){\n\t\t item -= 1\n\t\t }\n\t\t console.log(item)\n\t\t return item\n\t\t })\n\t\t )*/\n\t\tlet helper = new DateHelper();\n\t\tlet data = new DateHelper().textoParaData(this._inputData.value)\n\t\tconsole.log(data)\n\t\t//let data = new Date(this._inputData.value.replace(/-/g, ','))\n\t\tlet negociacao = new Negociacao(\n\t\t\thelper.dataParaTexto(this._inputData.value),\n\t\t\tthis._inputQuantidade.value,\n\t\t\tthis._inputValor.value\n\t\t)\n\n\t\t// ==> adicionar a negociação em uma lista\n\t\t\n\t}", "function finMes(fecha){\r\n\tvar nAno = fecha.substr(6);\r\n\tvar nMes = parseInt(fecha.substr(3, 2), 10);\r\n\tvar nRes = 0;\r\n\tswitch (nMes){\r\n\t\tcase 1: nRes = 31; break;\r\n\t\tcase 2: \r\n\t\t\t\tif (nAno % 4 == 0) nRes = 29; \r\n\t\t\t\telse nRes = 28;\r\n\t\t\t\tbreak;\r\n\t\tcase 3: nRes = 31; break;\r\n\t\tcase 4: nRes = 30; break;\r\n\t\tcase 5: nRes = 31; break;\r\n\t\tcase 6: nRes = 30; break;\r\n\t\tcase 7: nRes = 31; break;\r\n\t\tcase 8: nRes = 31; break;\r\n\t\tcase 9: nRes = 30; break;\r\n\t\tcase 10: nRes = 31; break;\r\n\t\tcase 11: nRes = 30; break;\r\n\t\tcase 12: nRes = 31; break;\r\n\t}\r\n\treturn nRes;\r\n}", "function crepuscolo(njd,tempo_rif,longitudine,latitudine,altitudine){\n\n // funzione per il calcolo del crepuscolo astronomico.\n // FUNZIONE DA ELIMINARE e sostituire con crepuscolo_UT\n \n var tempo_rifst=0; // tempo di riferimento per il sorgere e il tramonto.\n // \nif (tempo_rif==\"TL\") { tempo_rifst=-fuso_loc(); } // riferimento al tempo locale.\nelse if (tempo_rif==\"TU\") { tempo_rifst=0 ;} // il riferimento rimane il TU\n\n\n var ps_sole=pos_sole(njd);\n var DEs=ps_sole[1];\n\n var LATr=latitudine/180*Math.PI;\n var DEr=DEs/180*Math.PI;\n\n var H=Math.acos(-Math.tan(LATr)*Math.tan(DEr));\n\n var H1=Math.acos((Math.cos(1.88495556)-Math.sin(LATr)*Math.sin(DEr))/(Math.cos(LATr)*Math.cos(DEr)));\n\n var H= H*180/Math.PI;\n var H1=H1*180/Math.PI;\n\n var T=((H1-H)/15)*0.9973;\n\n// new Array(azimut_sorgere,azimut_tramonto,tempo_sorgere,tempo_transito,tempo_tramonto)\n// 0 1 2 3 4\n\n var p_sole=ST_ASTRO_DATA(njd,ps_sole[0],ps_sole[1],longitudine,latitudine,altitudine,0.25);\n\n var crep_m=ore_24(p_sole[2]-T+tempo_rifst); // crepuscolo del mattino.\n var crep_s=ore_24(p_sole[4]+T+tempo_rifst); // crepuscolo serale\n\n crep_m=sc_ore_hm(crep_m); // crepuscolo del mattino.\n crep_s=sc_ore_hm(crep_s); // crepuscolo serale\n\n var tempi_crep= new Array(crep_m,crep_s);\n\n return tempi_crep;\n \n}", "function mineur(){\r\n var aujd = new Date();\r\n var jour = aujd.getDate(); \r\n var mois = aujd.getMonth();\r\n var annee = aujd.getFullYear();\r\n\r\n var jourNaissance = dateNaissance.valueAsDate.getDate();\r\n var moisNaissance = dateNaissance.valueAsDate.getMonth();\r\n var anneeNaissance = dateNaissance.valueAsDate.getFullYear();\r\n\r\n console.log(aujd + \" jour \" + jour + \" mois \"+ mois + \" annee \"+ annee);\r\n console.log(dateNaissance.valueAsDate, jourNaissance, moisNaissance, anneeNaissance);\r\n\r\n if (annee-anneeNaissance < 18){\r\n dateNaissance.style.backgroundColor = \"red\";\r\n } else {\r\n dateNaissance.style.backgroundColor = \"\";\r\n }\r\n\r\n}", "getDuracionJornada() {\n let duracion = \"00:00:00\";\n //Recorro todo el array y sumo las duraciones\n for (let i = 0; i < this.arrayIntervalos.length; i++) {\n duracion = FuncionesAuxiliares.sumaDuracionesString(duracion,\n this.arrayIntervalos[i].getTiempoIntervaloString());\n }\n return duracion;\n\n }", "function fechaSistema() {\n var f = new Date();\n var meses = new Array(\"01\", \"02\", \"03\", \"04\", \"05\", \"06\", \"07\", \"08\", \"09\", \"10\", \"11\", \"12\");\n var fechaActual;\n var dia = \"\";\n dia = dia + f.getDate();\n var tam = dia.length;\n fechaActual = ((tam == 1) ? \"0\" + f.getDate() : f.getDate()) + \"/\" + meses[f.getMonth()] + \"/\" + f.getFullYear(); //descomentar si el dia de la fecha sale con un solo digito\n return fechaActual;\n}", "function getDataAtual(exibeSeparador, exibeHoras){\n // ajustando a data atual\n var fullDate = new Date();\n // acrescenta o 0 caso o mes for menor que 10\n var mes = (\"0\" + (fullDate.getMonth() + 1)).slice(-2);\n // acrescenta o 0 caso o dia for menor que 10\n var dia = (\"0\" + fullDate.getDate()).slice(-2);\n // acrescenta o 0 caso a hora for menor que 10\n var horas = (\"0\" + fullDate.getHours()).slice(-2);\n\n if (exibeHoras){\n return fullDate.getFullYear() + mes + dia;// + horas;\n }\n\n if (exibeSeparador){\n return fullDate.getFullYear() + '-' + mes + '-' + dia;\n } \n}", "function crepuscolo_NA(njd,longitudine,latitudine,altitudine){\n\n // funzione per il calcolo del crepuscolo civile per il T.U. di Greenwich\n // aggiornata al 03/12/2011.\n // by Salvatore Ruiu - Irgoli (Italy).\n // IL Sole si trova a -12 gradi sotto l'orizzonte locale. 90+12 .\n \n var ps_sole=pos_sole(njd);\n var DEs=ps_sole[1]; // declinazione del Sole.\n\n var LATr=Rad(latitudine); // angolo in radianti.\n var DEr=Rad(DEs); // angolo in radianti.\n\n var H=Math.acos(-Math.tan(LATr)*Math.tan(DEr)); // angolo orario\n\n var H1=Math.acos((Math.cos(Rad(102))-Math.sin(LATr)*Math.sin(DEr))/(Math.cos(LATr)*Math.cos(DEr)));\n\n var H= Rda(H); // angolo da radiante a sessadecimale.\n var H1=Rda(H1); // angolo da radiante a sessadecimale. \n\n var T=((H1-H)/15)*0.9973;\n\n var p_sole=ST_SOLE(njd,longitudine,latitudine,altitudine);\n\n var crep_m=ore_24(p_sole[2]-T); // crepuscolo del mattino.\n var crep_s=ore_24(p_sole[4]+T); // crepuscolo serale.\n\n var tempi_crep= new Array(crep_m,crep_s);\n\n return tempi_crep;\n \n}", "function DescuentoJudicial(){ \n //obtiene el valor anterior de sal_jud\n var sal_jud=document.getElementById(\"sal_jud\").value\n //valor del input de sueldo neto\n var SaldoNeto= document.getElementById('sueldoNeto').value;\n //si anteriormente ya tenia un valor restaura ante cambios del operador\n if(sal_jud > 0)\n {\n var suma=parseFloat(SaldoNeto) + parseFloat(sal_jud);\n document.getElementById(\"sueldoNeto\").value=suma;\n }\n //valor del input del descuento judicial\n var monto= document.getElementById('inputJudicial').value;\n //el nuevo valor de Saldo Neto\n var SaldoNeto= document.getElementById(\"sueldoNeto\").value;\n document.getElementById(\"sueldoNeto\").value=(SaldoNeto-monto);\n document.getElementById(\"sal_jud\").value=monto;\n //guardamos el valor de salario neto(esto se actualizara con cada descuento)\n var sueldoneto=document.getElementById('sueldoNeto').value;\n document.getElementById(\"sal_neto\").value=sueldoneto;\n \n }", "function DescuentoAusencia(){\n //recupero el valor de ausencia\n var sal_aus= document.getElementById(\"sal_aus\").value;\n var SaldoNeto= document.getElementById('sueldoNeto').value;\n //reestablece los valores al cambiar dias\n if(sal_aus > 0)\n {\n var suma=parseFloat(SaldoNeto) + parseFloat(sal_aus);\n document.getElementById(\"sueldoNeto\").value=suma;\n \n }\n var SueldoBrutoIni=document.getElementById('sueldoBruto').value;\n //calcula el jpornal diario\n var jornal=SueldoBrutoIni/30;\n //obtiene la cantidad de dias\n var dias=document.getElementById('DiaAusencia').value;\n //calcula jornal diario por cantidad de dias\n document.getElementById(\"sal_aus\").value=jornal*dias;\n //Actualiza el neto a cobrar\n var SaldoNeto= document.getElementById('sueldoNeto').value;\n document.getElementById(\"sueldoNeto\").value=SaldoNeto-(jornal*dias);\n //guardamos el valor de salario neto(esto se actualizara con cada descuento)\n var sueldoneto=document.getElementById('sueldoNeto').value;\n document.getElementById(\"sal_neto\").value=sueldoneto;\n \n \n }", "fecharCompra() {\n let total = 0;\n\n // 20% de desconto para novos clientes\n if (this.novoCliente) {\n total = this.valorTotal * 0.8;\n // desconto de XX% do cupom \n } else if (this.cupom) {\n total = this.valorTotal * (1 - this.cupom);\n // 5% de desconto para compras acima de 100 reais\n } else if (this.valorTotal > 100) {\n fintotalal = this.valorTotal * 0.95;\n };\n\n return this.valorTotal = total.toFixed(2);;\n }", "function CalcularMedia(fecha, hoy, presupuesto, consumido, total, correo, nombre_alerta) {\r\n \r\n var difference = (hoy - fecha);\r\n\r\n var years = Math.floor(difference / (1000 * 60 * 60 * 24 * 365));\r\n difference -= years * (1000 * 60 * 60 * 24 * 365);\r\n var months = Math.floor(difference / (1000 * 60 * 60 * 24 * 30.4375));\r\n var day = Math.floor(difference / (1000 * 60 * 60 * 24));\r\n \r\n var dif = '';\r\n if (years > 0)\r\n dif = years;\r\n\r\n if (months > 0) {\r\n if (years > 0) dif;\r\n dif += day;\r\n }else { \r\n dif = day;\r\n }\r\n \r\n \r\n Logger.log('\\nConsumido ' + consumido + '€ en ' + dif + ' dias');\r\n \r\n var resultado = (total * dif) / consumido; \r\n resultado = Math.round(resultado);\r\n var resultado_final = resultado.toFixed();\r\n \r\n Logger.log('Queda un total de ' + total + '€, aproximadamente ' + resultado_final + ' dias' );\r\n \r\n EventoCalendar(presupuesto, consumido, total, correo, nombre_alerta, resultado_final);\r\n\r\n}", "function Descuento20(){\n //recuperamos el valor descuento20 anterior\n var descuento20=document.getElementById(\"sal_pyt20\").value;\n //recuperamos el sueldo neto del input\n var SueldoNeto=document.getElementById('sueldoNeto').value;\n //si anteriormente ya tenia un valor, debe reestablecer\n if(descuento20 > 0)\n {\n var suma=parseFloat(SueldoNeto) + parseFloat(descuento20);\n document.getElementById(\"sueldoNeto\").value=suma;\n }\n //sueldo bruto inicial\n var SaldoBrutoIni=document.getElementById('sueldoBruto').value;\n //calcula el jpornal diario\n var jornal=SaldoBrutoIni/30;\n //obtiene dias de permisos/llegada tardia\n var dias= document.getElementById('descuento20').value;\n //descuento por dia de 20 %\n var descuento20=((jornal*20)/100)\n //obtener el valor actual del sal_pyt//esto se debe sumar al total de descuento sal aso\n //de 20, 40 y 50 por ciento.\n document.getElementById(\"sal_pyt20\").value=(descuento20*dias);\n //Actualiza el neto a cobrar\n var SaldoNeto= document.getElementById('sueldoNeto').value;\n document.getElementById(\"sueldoNeto\").value=SaldoNeto-(descuento20*dias);\n //guardamos el valor de salario neto(esto se actualizara con cada descuento)\n var sueldoneto=document.getElementById('sueldoNeto').value;\n document.getElementById(\"sal_neto\").value=sueldoneto;\n }", "function cambiarTiempo(ano, mes, dia, hour, min) {\n\n let cambioMin = min;\n let cambioHour = hour;\n let cambioDia = dia;\n let cambioAno = ano;\n let cambioMes = mes;\n\n\n\n if (cambioMin == 30) {\n cambioMin = 0;\n if (cambioHour === 23) {\n cambioHour = 0;\n if (cambioDia === 30 || cambioDia === 31) {\n\n cambioDia = 1;\n\n if (cambioMes === 12) {\n cambioMes = 1;\n cambioAno++;\n } else {\n cambioMes++;\n }\n } else {\n cambioDia++;\n }\n\n } else {\n cambioHour++;\n }\n\n } else if (cambioMin < 30) {\n cambioMin += 30;\n\n\n } else if (cambioMin > 30) {\n\n let aux = Math.abs(cambioMin - 30);\n if (cambioHour === 23) {\n cambioHour = 0;\n if (cambioDia === 30 || cambioDia === 31) {\n\n cambioDia = 1;\n\n if (cambioMes === 12) {\n cambioMes = 1;\n cambioAno++;\n } else {\n cambioMes++;\n }\n } else {\n cambioDia++;\n }\n\n } else {\n cambioMin = aux;\n cambioHour++;\n }\n\n }\n\n //final del dia\n\n return [cambioAno, cambioMes, cambioDia, cambioHour, cambioMin];\n\n}", "function cfasi_lunari(mese,anno,fase){\n\n // by Salvatore Ruiu Irgoli-Sardegna (Italy) Luglio 2010\n // funzione per il calcolo delle fasi lunari.\n // mese= numero del mese da 1 a 12.\n // anno=anno di riferimento.\n // k=0.00 per la luna nuova\n // k=0.25 per il primo quarto.\n // k=0.50 per la luna piena\n // k=0.75 per l'ultimo quarto.\n // fase= valore numerico per la fase 0 - 0.25 - 0.50 - 0.75 sono ammessi solo questi valori.\n \nvar anno_dec=anno+(mese/12);\nvar k=(anno_dec-1900)*12.3685; // calcolo della costante k. (parseInt) tronca la parte decimale\n k=parseInt(k)*1+fase*1;\n \nvar T=k/1236.85;\n\nvar fseno=166.56+132.87*T-0.009173*T*T;\n fseno=fseno/180*Math.PI;\n\nvar njd_fase =2415020.75933+29.53058868*k+0.0001178*T*T-0.000000155*T*T*T+0.00033*Math.sin(fseno);\n\n // calcolo anomalia media del sole.\n\nvar M=359.2242+29.10535608*k-0.0000333*T*T-0.00000347*T*T*T;\n M=gradi_360(M);\n M=M/180*Math.PI;\n\n // calcolo anomalia media della luna.\n\nvar M1=306.0253+385.81691806*k+0.0107306*T*T+0.00001236*T*T*T;\n M1=gradi_360(M1);\n M1=M1/180*Math.PI;\n\n // calcolo dell'argomento della latitudine della luna.\n\nvar F=21.2964+390.67050646*k-0.0016528*T*T-0.00000239*T*T*T;\n F=gradi_360(F);\n F=F/180*Math.PI;\n\n // calcolo correzioni per la luna nuova e piena.\n\nvar correzione1=0;\n\nif (fase==0 || fase==0.50) {\n \n correzione1= (0.1734-0.000393*T)*Math.sin(M)\n +0.0021*Math.sin(2*M)\n -0.4068*Math.sin(M1)\n +0.0161*Math.sin(2*M1)\n -0.0004*Math.sin(3*M1)\n +0.0104*Math.sin(2*F)\n -0.0051*Math.sin(M+M1)\n -0.0074*Math.sin(M-M1)\n +0.0004*Math.sin(2*F+M)\n -0.0004*Math.sin(2*F-M)\n -0.0006*Math.sin(2*F+M1)\n +0.0010*Math.sin(2*F-M1)\n +0.0005*Math.sin(M+2*M1); \n}\n\nelse if (fase==0.25 || fase==0.75) {\n \n correzione1= (0.1721-0.0004*T)*Math.sin(M)\n +0.0021*Math.sin(2*M)\n -0.6280*Math.sin(M1)\n +0.0089*Math.sin(2*M1)\n -0.0004*Math.sin(3*M1)\n +0.0079*Math.sin(2*F)\n -0.0119*Math.sin(M+M1)\n -0.0047*Math.sin(M-M1)\n +0.0003*Math.sin(2*F+M)\n -0.0004*Math.sin(2*F-M)\n -0.0006*Math.sin(2*F+M1)\n +0.0021*Math.sin(2*F-M1)\n +0.0003*Math.sin(M+2*M1)\n +0.0004*Math.sin(M-2*M1)\n -0.0003*Math.sin(2*M+M1); \n}\n\nelse {alert(\"Valore fase \"+fase+\" non valido!\");}\n\nvar njd_fase=njd_fase+correzione1; // per la luna nuova.\n\n // njd_fase= numero dei giorni giuliani.\nreturn njd_fase;\n\n}", "function Exo_4_2()\r\n // DEBUT\r\n\t{\r\n var iHeures, iMinutes;\r\n\r\n //Ecrire \"Entrez l'heure actuelle :\"\r\n //Lire iHeures\r\n iHeures=prompt(\"Entrez l'heure actuelle :\");\r\n //Ecrire \"Entrez les minutes :\"\r\n //Lire iMinutes\r\n iMinutes=prompt(\"Entrez les minutes :\");\r\n\r\n iMinutes=parseInt(iMinutes)+1;\r\n\r\n //Si iMinutes=60 alors\r\n if (iHeures!=23 & iMinutes==60)\r\n {\r\n iHeures=parseInt(iHeures)+1;\r\n iMinutes=\"00\";\r\n //Ecrire \"Dans une minute, il sera \" + iHeure + \" heure(s) \" + iMinutes\r\n alert(\"Dans une minute, il sera \" + iHeures + \" heure(s) \" + iMinutes);\r\n }\r\n\r\n //SINON SI iHeures=23 ET iMinutes=60 alors\r\n else if (iHeures==23 & iMinutes==60)\r\n {\r\n //Ecrire \"Dans une minute, il sera 00 heure 00\"\r\n alert(\"Dans une minute, il sera 00 heure 00\");\r\n }\r\n //SINON\r\n else\r\n {\r\n //Ecrire \"Dans une minute, il sera \" + iHeure + \" heure(s) \" + iMinutes\r\n alert(\"Dans une minute, il sera \" + iHeures + \" heure(s) \" + iMinutes + \" minutes\");\r\n }\r\n //FINSI\t\t\r\n //FIN\t\r\n }", "function calcularEdad(anio_nac){\r\n let edad = 2021 - anio_nac;\r\n alert(edad);\r\n}", "function getEdad(fecha_nac){\n\n //calculo la fecha de hoy\n var hoy=new Date();\n //alert(hoy)\n\n\t//Los Datos de Hoy\n\tvar year_hoy=hoy.getFullYear();\n\tvar mes_hoy=hoy.getMonth() + 1;\n\tvar dia_hoy=hoy.getDate();\n\n\t//la fecha recibida\n\tvar fecha=fecha_nac;\n\n\t//alert(fecha);\n\n //calculo la fecha que recibo\n //La descompongo en un array\n var array_fecha = fecha.split(\"/\")\n //si el array no tiene tres partes, la fecha es incorrecta\n if (array_fecha.length!=3)\n\t\treturn 'Formato incorrecto, use dd/mm/yyyy';\n\t\t\n\n //compruebo que los ano, mes, dia son correctos\n var ano\n ano = parseInt(array_fecha[2],10);\n if (isNaN(ano) || ano > hoy.getFullYear() ) {\n return 'Año incorrecto';\n\t}\n\n var mes\n mes = parseInt(array_fecha[1],10);\n if (isNaN(mes) || mes < 1 || mes >12){\n return 'Mes incorrecto';\n\t}\n\t\n var dia\n dia = parseInt(array_fecha[0],10);\n if (isNaN(dia) || dia<1 || dia > 31){\n return 'Dia incorrecto';\n\t}\n\n //si el año de la fecha que recibo solo tiene 2 cifras hay que cambiarlo a 4\n if (ano<=99)\n ano +=1900\n\n\t//alert('Escrito: \\n dia ' + dia + ' mes ' + mes + ' año ' + ano + '\\n Hoy: \\n año: ' + year_hoy + ' mes: ' + mes_hoy + ' dia ' + dia_hoy );\n\t\n ano = year_hoy - ano;\n mes = mes_hoy - mes;\n dia = dia_hoy - dia;\n\n //Si salió un día negativo\n if (dia < 0) {\n dia = 30 - Math.abs(dia);\n mes = mes - 1;\n }\n\n //Si salió un mes negativo\n if (mes < 0) {\n mes = 12 - Math.abs(mes);\n ano = ano - 1;\n }\n\n\t//Prepara la información a entregar\t\n if (ano==0 && mes==0 && dia==0){\n return 'Recien Nacido?';\n\n } else if (ano<1 && mes<3){\n return mes + ' meses, ' + dia + ' dias';\n\n } else if (ano<1 && mes>=1) {\n return mes + ' meses';\n\n } else if (ano<1 && mes<1){\n return dia + ' dias';\n\n } else if (ano<2) {\n return ano + ' año, ' + mes + ' meses';\n\n } else {\n\t\treturn ano + ' Años ';\n }\t\n\t\n\treturn ano + ' años, ' + mes + ' meses, ' + dia + ' dias';\n\n\n}", "function acu_fondosolidaridadredistribucioningresos_cargardatostemporal(){\n\t\n\t\tif(acu_fsri_panel_datanuevo)\n\t\t{\n\t\t\tacu_fsri_panel_dataviejo=acu_fsri_panel_datanuevo;\n\t\t}\n\t\tacu_fsri_panel_datanuevo=new Array();\n\t\tacu_fsri_panel_datanuevo['acu_fsi_sol_tranferencia_recursos'] = Ext.getCmp('acu_fsi_sol_tranferencia_recursos').getValue().getGroupValue();\n\t\t\n\t\tacu_fsri_panel_datanuevo['acu_fsi_recibo_recursos'] =Ext.getCmp('acu_fsi_recibo_recursos').getValue().getGroupValue();\n\t\tacu_fsri_panel_datanuevo['acu_fsi_recibo_recursos_valor_recib'] = Ext.getCmp('acu_fsi_recibo_recursos_valor_recib').getValue();\n\t\tacu_fsri_panel_datanuevo['acu_fsi_aporte_recursos'] = Ext.getCmp('acu_fsi_aporte_recursos').getValue().getGroupValue();\n\t\tacu_fsri_panel_datanuevo['acu_fsi_aporte_recursos_valor_apor'] = Ext.getCmp('acu_fsi_aporte_recursos_valor_apor').getValue();\n\t\tacu_fsri_panel_datanuevo['acu_vas_suscripcion_contrato'] = Ext.getCmp('acu_vas_suscripcion_contrato').getValue().getGroupValue();\n\t\t\n\t\t\n\t}", "function calcular() {\r\n var NUMEROYSIGNO = document.micalcu.display.value; //ME CREO UNA VARIABLE QUE ES IGUAL=document.nombreformulario.dondesemuestra.value -->\r\n document.micalcu.display.value = eval(NUMEROYSIGNO); // y digo que los datos metidos me lo cualcule la funcion eval(NUMEROYSIGNO) -->\r\n}", "function seleccionarDia () {\n \n var fecha = $('#fechas_seleccionadas_cita').val();\n globalFecha = fecha;\n var idMedico = $('#idMedico').text();\n\n if (fecha) {\n var date = new Date(fecha);\n //alert(date, idMedico);\n var obj_dates_idMedico = _dates_idMedico(fecha, date.getDay(), idMedico);\n tramosDisponibles(obj_dates_idMedico);\n\n } else { \n alert(\"Selecione una fecha\");\n }\n}", "function calculaParcelaFinanciamento (valor,meses){\n var parcela={parcela:0, seguro:0, txadm:0}; \n //caso o prazo seja menor que 12 meses, não há incidência de juros\n if (meses<=12){\n parcela[\"parcela\"]=valor/meses;\n \n return parcela;\n }else{\n //caso contrário, procede ao cálculo financeiro \n var i=0.009488793;\n var numerador= i*Math.pow(1+i,meses);\n var denominador= Math.pow(1+i,meses)-1; \n var valorparcela=valor*(numerador/denominador);\n \n parcela[\"parcela\"]=valorparcela;\n parcela[\"seguro\"]=0.00019*valor;\n parcela[\"txadm\"]=25.00;\n \n return parcela;\n \n }//fim do else\n}//fim da função calculaParcelaFinanciamento ", "function Descuento40(){\n //recuperamos el valor descuento40 anterior\n var descuento40=document.getElementById(\"sal_pyt40\").value;\n //recuperamos el sueldo neto del input\n var SueldoNeto=document.getElementById('sueldoNeto').value;\n //si anteriormente ya tenia un valor, debe reestablecer\n if(descuento40 > 0)\n {\n var suma=parseFloat(SueldoNeto) + parseFloat(descuento40);\n document.getElementById(\"sueldoNeto\").value=suma;\n }\n //sueldo bruto inicial\n var SaldoBrutoIni=document.getElementById('sueldoBruto').value;\n //calcula el jpornal diario\n var jornal=SaldoBrutoIni/30;\n //obtiene dias de permisos/llegada tardia\n var dias= document.getElementById('descuento40').value;\n //descuento por dia de 40 %\n var descuento40=((jornal*40)/100)\n //actualizar valor de sal_pyt\n document.getElementById(\"sal_pyt40\").value=(descuento40*dias);\n //Actualiza el neto a cobrar\n var SaldoNeto= document.getElementById('sueldoNeto').value;\n document.getElementById(\"sueldoNeto\").value=SaldoNeto-(descuento40*dias);\n \n \n //guardamos el valor de salario neto(esto se actualizara con cada descuento)\n var sueldoneto=document.getElementById('sueldoNeto').value;\n document.getElementById(\"sal_neto\").value=sueldoneto;\n }", "calculaIMC() {\n this.imc = (this.peso / (this.altura * this.altura)).toFixed(2);\n if (this.imc < 18.5) {\n this.resultado = \"Magreza, Obesidade 0\";\n } else if (this.imc >= 18.5 && this.imc <= 24.9) {\n this.resultado = \"Normal, Obsidade 0\";\n } else if (this.imc >= 25 && this.imc <= 29.9) {\n this.resultado = \"Sobrepeso, Obesidade I\";\n } else if (this.imc >= 30 && this.imc <= 39.9) {\n this.resultado = \"Obesidade II\";\n } else if (this.imc >= 40) {\n this.resultado = \"Obesidade Grave III\";\n }\n }", "function calcularCircunferencia(){\n const radio=(document.getElementById(\"InputRadio\").value);\n const circunferencia=redondear(2*Math.PI*radio,2);\n alert(circunferencia);\n}", "function getMessageCLima(temperatura){\n\tif(temperatura > 30){\n\t\treturn \"Nos encontramos a \" + temperatura +\". Hay demasiado calor, comprate una gaseosa :V\"\n\t}else{\n\t\treturn \"Nos encontramos a \" + temperatura +\" es un bonito dia para salir\"\n\t}\n}", "function pasaje(distancia, dias) {\r\n const valorKm = 35;\r\n var valor;\r\n\r\n if (distancia > 1000 & dias > 7) {\r\n descuento = ((distancia * valorKm) * 30) / 100;\r\n valor = (distancia * valorKm) - descuento;\r\n } else {\r\n valor = distancia * valorKm;\r\n }\r\n return (\"El valor total del viaje es \" + valor + \"$\");\r\n}", "function calculaIdade ( dataNascimento ) {\n\t var hoje = new Date();\t \n\t var arrayData = dataNascimento.split(\"/\");\t \n\t var retorno = \"#ERR#\";\n\t \n\t if (arrayData.length == 3) {\n\t // Decompoem a data em array\n\t var ano = parseInt( arrayData[2] );\n\t var mes = parseInt( arrayData[1] );\n\t var dia = parseInt( arrayData[0] );\n\t \n\t // Valida a data informada\n\t if ( arrayData[0] > 31 || arrayData[1] > 12 ) {\n\t return retorno;\n\t } \n\t \n\t ano = ( ano.length == 2 ) ? ano += 1900 : ano;\n\n\t // Subtrai os anos das duas datas\n\t var idade = ( hoje.getYear()+1900 ) - ano;\n\n\t // Subtrai os meses das duas datas\n\t var meses = ( hoje.getMonth() + 1 ) - mes;\n\t \n\t // Se meses for menor que 0 entao nao cumpriu anos. Se for maior sim ja cumpriu\n\t idade = ( meses < 0 ) ? idade - 1 : idade; \n\n\t meses = ( meses < 0 ) ? meses + 12 : meses; \n\n\t retorno = ( idade ); \n\t } \n\n\t return retorno;\n }", "function temposid (njd){\n\n // funzione per il calcolo del tempo siderale di GREENWICH.\n // by Salvatore Ruiu Irgoli-Sardegna (Italy). 10 2011.\n // PARAMETRO njd --- numero dei giorni giuliani della data corrente riferita al T.U. di Greenwich.\n // fuso= fuso orario della località è già considerato nel calcolo del giorno giuliano.\n // restituisce il valore numerico SIDERAL_TIMEG in ore decimali \n \n //var time_zg=parseInt(njd)+0.5; // giorno giuliano all'ora zero di Greenwich.\n var time_zg=jdHO(njd);\n var T=(time_zg-2415020.0)/36525; \n // data di riferimento :2415020 = 0.0:1900\n\t var int_time=0.276919398+100.0021359*T+0.000001075*T*T; // numero rivoluzioni; utilizzare la parte decimale del valore int_time.\n\t \n int_time=(int_time-parseInt(int_time))*24; // tempo siderale a Greenwich alle ore zero UT\n\t \n\t var TSG=int_time // tempo siderale a Greenwich alle ore zero UT.\n\t \n// TEMPO SIDERALE PER QUALUNQUE INTERVALLO DI ORE A GREENWICH\n \n\t var time_qi=(njd-time_zg)*24; // qualunque intervallo per Greenwich.\n\t var intervallo_ts=time_qi*1.002737908;\n\t \t \n\t var SIDERAL_TIMEG=TSG+intervallo_ts; // TEMPO SIDERALE PER QUALSIASI INTERVALLO (ore decimali).\n\n SIDERAL_TIMEG=ore_24(SIDERAL_TIMEG); // intervallo 0-24 (ore decimali).\n\nreturn SIDERAL_TIMEG;}", "function calculatorCalorieForDay(calorie){\n let a = calorie_calc(calorie)\n console.log(a[0]);\n let bmr = calculatorBMR(calorie)\n console.log(bmr);\n if (a[0] == \"little or no exerise\"){\n console.log(((bmr*1.2)*1.1).toFixed(0));\n let Caloriee = ((bmr*1.2)*1.1).toFixed(0)\n return (Caloriee) \n }\n else if (a[0] == \"1-3 exerise a week\"){\n let Caloriee = ((bmr*1.375)*1.1).toFixed(0)\n return (Caloriee) \n } \n else if (a[0] == \"4-5 exerise a week\"){\n let Caloriee = ((bmr*1.55)*1.1).toFixed(0)\n return (Caloriee) \n } \n else if (a[0] == \"6-7 exerise a week\"){\n let Caloriee = ((bmr*1.725)*1.1).toFixed(0)\n return (Caloriee) \n } \n else if (a[0] == \"more than 6-7 exerise a week\"){\n let Caloriee = ((bmr*1.9)*1.1).toFixed(0)\n return (Caloriee)\n } \n }", "function crepuscolo_UT(njd,longitudine,latitudine,altitudine){\n\n // funzione per il calcolo del crepuscolo astronomico per il T.U. di Greenwich\n // aggiornata al 03/12/2011.\n // by Salvatore Ruiu - Irgoli (Italy).\n // (in sostituzione della funzione crepuscolo.)\n // IL Sole si trova a -18 gradi sotto l'orizzonte locale. 90+18=108\n \n var ps_sole=pos_sole(njd);\n var DEs=ps_sole[1]; // declinazione del Sole.\n\n var LATr=Rad(latitudine); // angolo in radianti.\n var DEr=Rad(DEs); // angolo in radianti.\n\n var H=Math.acos(-Math.tan(LATr)*Math.tan(DEr)); // angolo orario\n\n var H1=Math.acos((Math.cos(Rad(108))-Math.sin(LATr)*Math.sin(DEr))/(Math.cos(LATr)*Math.cos(DEr)));\n\n \n var H= Rda(H); // angolo da radiante a sessadecimale.\n var H1=Rda(H1); // angolo da radiante a sessadecimale. \n\n var T=((H1-H)/15)*0.9973;\n\n var p_sole=ST_SOLE(njd,longitudine,latitudine,altitudine); //Sorgere e tramontare del Sole.\n\n var crep_m=ore_24(p_sole[2]-T); // crepuscolo del mattino.\n var crep_s=ore_24(p_sole[4]+T); // crepuscolo serale.\n\n var leng_day=p_sole[4]-p_sole[2]; // durata del giorno= ttramonto-tsorge del sole.\n var leng_crp=crep_s-crep_m; // durata del crepuscolo astronomico.\n var le_night=24-leng_crp; // durata della notte astronomica.\n\n var tempi_crep= new Array(crep_m,crep_s,leng_day,leng_crp,le_night);\n\n return tempi_crep;\n \n}", "function late(){\r\n let totalInvoice = document.querySelector('#totalInvoice').value\r\n let expirationDate = document.querySelector('#expirationDate').value\r\n let payDate = document.querySelector('#payDate').value\r\n let rate = document.querySelector('#rate').value / 100\r\n let delayDay = document.querySelector('#delayDay')\r\n\r\n function calcDate(){\r\n expiration = new Date(expirationDate)\r\n payDay = new Date(payDate)\r\n\r\n let defTime = Math.abs(payDay - expiration)\r\n let dayTime = 1000 * 60 * 60 * 24 \r\n let defDays = defTime / dayTime\r\n\r\n return defDays\r\n }\r\n\r\n delayDay.innerHTML = calcDate()\r\n\r\n if(totalInvoice == '' || expirationDate == '' || payDate == '' ||rate == ''){\r\n alert('Preencha todos os campos')\r\n } else {\r\n let iofMonth = 0.0038\r\n let iofDay = 0.000082\r\n\r\n let totalFee = totalInvoice * (1 + rate)**(0.33) - totalInvoice\r\n let dayRate = (totalInvoice * calcDate() * 0.00033)\r\n let fee = totalInvoice * 0.02\r\n let iof = (totalInvoice * iofMonth) + (totalInvoice * iofDay * calcDate())\r\n let totalRate = totalFee + dayRate + fee + iof\r\n let totalPay = parseFloat(totalInvoice) + parseFloat(totalRate)\r\n \r\n document.querySelector('#totalFee').innerHTML = realCurrency(totalFee)\r\n document.querySelector('#dayRate').innerHTML = realCurrency(dayRate)\r\n document.querySelector('#fee').innerHTML = realCurrency(fee)\r\n document.querySelector('#iof').innerHTML = realCurrency(iof)\r\n document.querySelector('#totalRate').innerHTML = realCurrency(totalRate)\r\n document.querySelector('#totalPay').innerHTML = realCurrency(totalPay)\r\n }\r\n \r\n}", "function calculaCircunferencia(radio) {\n return 2 * Math.PI * radio;\n }", "function TipoDescuento1(){\n //recuperamos el valor descuento 1 anterior\n var descuento1=document.getElementById(\"tipo_des1\").value;\n \n //recuperamos el sueldo neto del input\n var SueldoNeto=document.getElementById('sueldoNeto').value;\n //si anteriormente ya tenia un valor, debe reestablecer\n if(descuento1 > 0)\n {\n var suma=parseFloat(SueldoNeto) + parseFloat(descuento1);\n document.getElementById(\"sueldoNeto\").value=suma;\n }\n\n //el valor que se ingreso en monto\n var monto= document.getElementById('tipoDescuento1').value;\n document.getElementById(\"tipo_des1\").value=monto;\n //Actualiza el neto a cobrar\n var SaldoNeto= document.getElementById('sueldoNeto').value;\n document.getElementById(\"sueldoNeto\").value=SaldoNeto-monto;\n \n //codigo de descuento la cual guardaremos\n var posicion=document.getElementById('tipodescuento1').options.selectedIndex;\n var codigoDescuento1=document.getElementById('tipodescuento1').options[posicion].value;\n document.getElementById(\"cod_des1\").value=codigoDescuento1;\n \n //guardamos el valor de salario neto(esto se actualizara con cada descuento)\n var sueldoneto=document.getElementById('sueldoNeto').value;\n document.getElementById(\"sal_neto\").value=sueldoneto;\n }", "function getPelnas() {\nvar pajamos = 12500;\nvar islaidos = 18500;\nvar pelnas = pajamos - islaidos;\nreturn pelnas;\n}", "function pedir_tiempos_conc(){\n\tdataBase.query(\"USE reactor40\", function (err, result,field) {\n\t\t\tif (err) throw err;\n\t});\n\tdataBase.query('SELECT * FROM concentracion ORDER BY ID DESC LIMIT 20;', function(err, result, fiel){\n\t\tdatosY.y_1 = result[19].time;\n\t\tdatosY.y_2 = result[18].time;\n\t\tdatosY.y_3 = result[17].time;\n\t\tdatosY.y_4 = result[16].time;\n\t\tdatosY.y_5 = result[15].time;\n\t\tdatosY.y_6 = result[14].time;\n\t\tdatosY.y_7 = result[13].time;\n\t\tdatosY.y_8 = result[12].time;\n\t\tdatosY.y_9 = result[11].time;\n\t\tdatosY.y_10 = result[10].time;\n\t\tdatosY.y_11 = result[9].time;\n\t\tdatosY.y_12 = result[8].time;\n\t\tdatosY.y_13 = result[7].time;\n\t\tdatosY.y_14 = result[6].time;\n\t\tdatosY.y_15 = result[5].time;\n\t\tdatosY.y_16 = result[4].time;\n\t\tdatosY.y_17 = result[3].time;\n\t\tdatosY.y_18 = result[2].time;\n\t\tdatosY.y_19 = result[1].time;\n\t\tdatosY.y_20 = result[0].time;\n\t});\n}", "function controlaAnho(){\r\n\tvar fiscalYear = getValueFormatless('fiscalPeriodYear');\r\n\tvar declaType = document.getElementById('declarationType').value;\r\n\tvar fecha = new Date();\r\n\tvar anhoActual = getActualYear();\r\n\t\r\n\tif(fiscalYear != 0){\r\n\t\t//Si es clausura tiene que ser menor o igual q el a?o actual\r\n\t\tif(declaType == '| 5 | CLAUSURA'){\r\n\t\t\tif(fiscalYear > anhoActual){//Mayor o igual? O solo igual se permite\r\n\t\t\t\talert('Para las ddjj de tipo CLAUSURA, el año debe ser el menor o igual al año actual.');\r\n\t\t\t\tdocument.getElementById('fiscalPeriodYear').value = \"\";\r\n\t\t\t\tdocument.getElementById('fiscalPeriodYear').focus();\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t}else{//Si no es clausura, el a?o tiene que ser menor al actual\r\n\t\t\tif(fiscalYear >= anhoActual){\r\n\t\t\t\talert('Para las ddjj ORIGINALES y RECTIFICATIVAS, el año debe ser menor al año actual.');\r\n\t\t\t\tdocument.getElementById('fiscalPeriodYear').value = \"\";\r\n\t\t\t\tdocument.getElementById('fiscalPeriodYear').focus();\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t} \r\n\t}\r\n\t//getPorcentajeMoras(document.getElementById('fiscalPeriodYear')); \t\t \r\n}", "function idadePessoa(ano, mes, dias) {\n //return ano + \" \" + mes\n const diasAno = 365;\n const diasMes = 30;\n\n const idadeEmAnos = ano * diasAno\n //console.log(idadeEmAnos)\n\n const idadeEmMeses = mes * diasMes\n //console.log (idadeEmMeses)\n\n const idadeEmDias = idadeEmAnos + idadeEmMeses + dias;\n \n return `Você possui ${idadeEmDias} dias de vida`\n //return idadeEmDias;\n\n}", "function masqueSaisieDate(obj) {\n\n var ch = obj.value;\n var ch_gauche, ch_droite;\n obj.value = ch.slice(0, 10);\n ch.toString();\n if (((ch.slice(2, 3)) !== (\"/\")) && (ch.length >= 3)) {\n if (ch.slice(0, 2) > 31) {\n ch_gauche = '31';\n } else {\n ch_gauche = ch.slice(0, 2);\n }\n ch_droite = ch.slice(2);\n obj.value = ch_gauche + \"/\" + ch_droite;\n }\n if (((ch.slice(5, 6)) !== (\"/\")) && (ch.length >= 6)) {\n if (ch.slice(3, 5) > 12) {\n ch_gauche = ch.slice(0, 3) + '12';\n } else {\n ch_gauche = ch.slice(0, 5);\n }\n ch_droite = ch.slice(5);\n obj.value = ch_gauche + \"/\" + ch_droite;\n }\n return;\n}", "function bisciesto(){\n return((año_actual %100 !=0)&&(año_actual%4==0)||(año_actual%400==0));\n}", "function checaDiferencia1() //Verifica que la diferencia sea 0, si es cero elimina las comas de los valores\n {\n totDif=0;\n for ( i=0; i < numFilasPi; i=i+4)\n {\n elemento=\"form1:table1:\"+i+\":diferencia\";\n dif=document.getElementById(elemento).innerHTML;\n dif=parseFloat(eliminacomas(dif));\n totDif=totDif+dif;\n \n }\n if (totDif!=0)\n {\n alert(\"No se puede actualizar calendario porque existen diferencias !!\");\n return false; \n }\n else\n {\n \n for ( i=0; i < numFilasPi; i=i+4)\n {\n for (j=0; j<12; j++)\n {\n elemento=\"form1:table1:\"+i+\":\"+mes[j]; \n valor = parseFloat(eliminacomas(document.form1.elements[elemento].value));\n document.form1.elements[elemento].value = valor;\n }\n }\n \n return true;\n } \n }", "function catturaData() {\n var d = new Date();\n var ora = d.getHours();\n var minuti = d.getMinutes();\n return addZero(ora) + ':' + addZero(minuti);\n }", "function DescuentoASO(){\n //obtiene sal_aso\n var sal_aso=document.getElementById(\"sal_aso\").value\n //valor del input de sueldo neto\n var SaldoNeto= document.getElementById('sueldoNeto').value;\n //si anteriormente ya tenia un valor restaura ante cambios del operador\n if(sal_aso > 0)\n {\n var suma=parseFloat(SaldoNeto) + parseFloat(sal_aso);\n document.getElementById(\"sueldoNeto\").value=suma;\n }\n //valor del input ASO\n var monto= document.getElementById('InputASO').value;\n //el nuevo valor de Saldo Neto\n var SaldoNeto= document.getElementById(\"sueldoNeto\").value;\n document.getElementById(\"sueldoNeto\").value=(SaldoNeto-monto);\n document.getElementById(\"sal_aso\").value=monto;\n //guardamos el valor de salario neto(esto se actualizara con cada descuento)\n var sueldoneto=document.getElementById('sueldoNeto').value;\n document.getElementById(\"sal_neto\").value=sueldoneto;\n }", "function fechadehoy(){\n \n var d = new Date();\n //console.log(\"Fecha de Hoy:\",d);\n var dia = d.getDate();\n var mes = d.getMonth()+1;\n var año = d.getFullYear();\n\n if(mes < 10){\n\n var fechaInicial = dia+\"-0\"+mes+\"-\"+año;\n var fechaFinal = dia+\"-0\"+mes+\"-\"+año;\n\n }else if(dia < 10){\n\n var fechaInicial = \"0\"+dia+\"-\"+mes+\"-\"+año;\n var fechaFinal = \"0\"+dia+\"-\"+mes+\"-\"+año;\n\n }else if(mes < 10 && dia < 10){\n\n var fechaInicial = \"0\"+dia+\"-0\"+mes+\"-\"+año;\n var fechaFinal = \"0\"+dia+\"-0\"+mes+\"-\"+año;\n\n }else{\n\n var fechaInicial = dia+\"-\"+mes+\"-\"+año;\n var fechaFinal = dia+\"-\"+mes+\"-\"+año;\n\n } \n $(\"#daterange-btn-Ajuste span\").html(fechaInicial+' - '+fechaFinal);\n //console.log(fechaInicial+' - '+fechaFinal);\n \t localStorage.setItem(\"valorRangoAjusteInv\", fechaInicial+' - '+fechaFinal);\n \t\n}", "function ObtenerDiferenciaDias(_fecha_devolucion, _fecha_hoy) {\n var fecha_devolucion = new Date(_fecha_devolucion);\n var fecha_hoy = new Date(_fecha_hoy);\n var timeDiff = fecha_hoy.getTime() - fecha_devolucion.getTime();\n return Math.ceil(timeDiff / (1000 * 3600 * 24));\n}", "function gps_asignarFechaComp(fecha) {\n var dia = fecha.getDate();\n var mes = fecha.getMonth();\n var anio = fecha.getFullYear();\n\n mes += 1;\n if (mes < 10)\n mes = \"0\" + mes;\n\n var sfecha = anio + \"-\" + mes + \"-\" + dia;\n var fechaIni = sfecha + \" 00:00:00\";\n var fechaFin = sfecha + \" 23:59:00\"; \n\n document.getElementById(\"fechaInicio\").value = fechaIni;\n document.getElementById(\"fechaFinal\").value = fechaFin;\n \n gps_cambioParametros();\n}", "function mascaraCep(cep){\n if(mascaraInteiro(cep)==false){\n event.returnValue = false;\n } \n return formataCampo(cep, '00.000-000', event);\n}", "setAlertCloseToday(){\n \n \n var aujourdhuiplus3 = this.todayplus3days.toLocaleDateString();\n\n this.eventsCloseOftheday =[]; // vide le tableau des alertesCloseToday avant chaque set\n \n for(var eventac of this.events){ // pour chaque date de debut d'event = a la date d'aujourdhuiplus3 jours\n if( eventac.datestartevent == aujourdhuiplus3 ){\n this.addAlertCloseToday(eventac);\n \n }\n \n }\n \n }", "getTodayOpenClose() {\r\n return new Promise(async (resolve,reject) => {\r\n await this.alpaca.getClock().then(async (resp) => {\r\n await this.alpaca.getCalendar({\r\n start: resp.timestamp,\r\n end: resp.timestamp\r\n }).then((resp) => {\r\n var openTime = resp[0].open;\r\n var closeTime = resp[0].close;\r\n var calDate = resp[0].date;\r\n\r\n openTime = openTime.split(\":\");\r\n closeTime = closeTime.split(\":\");\r\n calDate = calDate.split(\"-\");\r\n\r\n var offset = new Date(new Date().toLocaleString('en-US',{timeZone: 'America/New_York'})).getHours() - new Date().getHours();\r\n\r\n openTime = new Date(calDate[0],calDate[1]-1,calDate[2],openTime[0]-offset,openTime[1]);\r\n closeTime = new Date(calDate[0],calDate[1]-1,calDate[2],closeTime[0]-offset,closeTime[1]);\r\n resolve([openTime,closeTime]);\r\n });\r\n });\r\n });\r\n }", "function calculardiasdel_mes(month){\n if(month==-1)month=11;\n if(month ==0|| month==2 ||month==4|| month==6|| month==7||month==9||month==11 ){\n return 31;\n }else if(month==3||month==5||month==8||month==10){\n return 30;\n }else{\n return bisciesto() ? 29:28;\n }\n}" ]
[ "0.60623664", "0.6034874", "0.5954636", "0.59204257", "0.5882735", "0.5829991", "0.58076704", "0.5793236", "0.5781888", "0.5752992", "0.5728651", "0.5724688", "0.5695152", "0.5677904", "0.5625867", "0.5623611", "0.5610476", "0.5606206", "0.55969435", "0.5564013", "0.54912454", "0.54583925", "0.54461753", "0.54411054", "0.5439952", "0.5437427", "0.5435142", "0.54244775", "0.5421649", "0.54053277", "0.53608155", "0.534862", "0.5318556", "0.531742", "0.53088444", "0.53037703", "0.5291766", "0.52863044", "0.52848876", "0.52827877", "0.528254", "0.5269138", "0.5258499", "0.5249883", "0.5246752", "0.5242945", "0.5241521", "0.5239574", "0.5231059", "0.52222896", "0.52212405", "0.5218768", "0.52118313", "0.5208211", "0.5192423", "0.51918894", "0.51751715", "0.5174488", "0.51686597", "0.5168537", "0.51666087", "0.51638275", "0.5163391", "0.5162235", "0.51589054", "0.5128731", "0.51271415", "0.512169", "0.5120763", "0.5119717", "0.5112281", "0.5107362", "0.5107173", "0.51054245", "0.51002574", "0.5090101", "0.5089765", "0.50869775", "0.5086947", "0.50851667", "0.5080421", "0.5080255", "0.5067828", "0.50674784", "0.506442", "0.5063162", "0.50628746", "0.5060702", "0.50437975", "0.5040436", "0.5028521", "0.5028048", "0.5024231", "0.5023367", "0.50188434", "0.50147045", "0.50115854", "0.5006819", "0.500655", "0.5002054" ]
0.58754873
5
busca el valor de maximo (de la propiedad HIGH) de cada dia (propiedad DTYYYYMMDD)(el valor de maximo de cada dia)
function buscarMaxDia(array) { let day; let arr = []; for (let i = 0; i < array.length; i++) { let date = array[i].DTYYYYMMDD; if (day != date) { day = date; let res; let contador = 0; for (let j = 0; j < array.length; j++) { if (array[j].DTYYYYMMDD === day) { if (contador === 0) { res = array[j].HIGH; } else { res = Math.max(res, array[j].HIGH); } contador++; } } arr.push(res); } } // console.log('Maximos:', arr) return arr; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getMax() {\n var max = Math.max.apply(null, config.values);\n max += 10 - max % 10;\n return max;\n console.log(max);\n }", "function setMax() {\n var cd = curDay();\n var input = document.getElementById('date');\n input.setAttribute(\"max\", this.value);\n input.max = cd;\n input.setAttribute(\"value\", this.value);\n input.value = cd;\n}", "function maxDecimales (){\n inputDecimales.value;\n}", "get maximumValue() {\r\n return this.i.maximumValue;\r\n }", "function getMaximum () {\n if ((document.getElementById('entMax').value)===\"\") {\n return 100;\n }\n else {\n return Number(document.getElementById('entMax').value) }\n }", "get actualMaximumValue() {\r\n return this.i.actualMaximumValue;\r\n }", "function MaxValue(array) {\n //Esto quiere decir que lo compre a array[0] y lo vendo a array[1] \"La primer diferencia\"\n let sale = array[1] - array[0] \n //Itero cada posibilidad de compra\n for (let i = 0; i < array.length - 1 ; i++) {\n //Itero cada posibilidad de venta\n for(let j = i + 1; j < array.length; j++ ){\n //sacamos la ganancia potencial\n const potential = array[j] - array[i];\n //Chequeamos con cual nos quedamos\n sale = potential > sale ? potential : sale;\n }\n }\n return sale;\n}", "function maxNum(){\n var m = Math.max(2, 3, 8, 22, 22.2);\n document.getElementById(\"max\").innerHTML = \"Between these numbers [2,3,8,22] the highest value is: \" + m;\n}", "function findMax(){\n let maxVal = max(parseInt(document.getElementById(\"max1\").value), parseInt(document.getElementById(\"max2\").value));\n document.getElementById(\"resultMax\").innerHTML = maxVal;\n}", "function fgetMaxValue(){\r\n\treturn 100;\r\n}", "get maximumValue() {\r\n return this.i.bk;\r\n }", "get maximumValue() {\n return this.i.bk;\n }", "function getMaxYValue() {\n let maxVal = Number.MIN_VALUE;\n diagram.data.forEach(function (d) {\n for (var key in d) {\n if (key !== currentSerie.groupField) {\n if (+d[key] > maxVal)\n maxVal = +d[key];\n }\n }\n });\n return maxVal;\n }", "function msMax() {\n\t\tlet max1 = msSingle.reduce((a, b) => {\n\t\t\treturn a[1] > b[1] ? a : b;\n\t\t});\n\n\t\treturn parseInt(max1[0]); //function being reduced has 2 key/value pairs in each object. reducing to max in value index 1 then returning value index 0;\n\t}", "calculateMaxYValue() {\n const { data = [] } = this.props;\n const valuesArr = data.map(el => el.y_value);\n let maxValue = Math.max.apply(null, valuesArr);\n maxValue = Math.round(maxValue);\n let exponent = maxValue.toString().length;\n exponent -= 1;\n exponent = !exponent ? 1 : exponent;\n const prec = 10 ** exponent;\n maxValue = Math.round(maxValue / prec) * prec;\n return maxValue;\n }", "function getMaxTemp() {\n for (var i = 0; i < forecastDays; i++) {\n var maxTemp = response.query.results.channel.item.forecast[i].high;\n $(\"#day\" + i + \"Max\").append(\"High: \" + maxTemp + \"°F\");\n }\n }", "function max(p1 , p2){\n\tvar maxVal= 0;\n\tif (p1 > p2){\n\t\tmaxVal = p1;\n\t} else{\n\t\tmaxVal = p2;\n\t}\n\tconsole.log(\"Los números son: \"+ p1 + \"-\" + p2 + \"\\n\" + \"El mayor de los números es: \" + maxVal)\n}", "function calculateMaxValue(maximum) {\n distance = ($attrs.distance || '2.5%').trim();\n isPercent = distance.indexOf('%') !== -1;\n return isPercent ?\n maximum * (1 - parseFloat(distance) / 100) :\n maximum - parseFloat(distance);\n }", "function maxVal(item) {\n if (item === \"Temperature\") return 120; // max in clean is 109.6\n if (item.includes(\"Fatalities\")) return 700; // max in clean is 587\n if (item.includes(\"Maize\")) return 40000; // max in clean is 36600\n if (item.includes(\"Rice\")) return 30000; // max in clean is 25000, but max in raw is 60000\n if (item.includes(\"Sorghum\")) return 40000;\n if (item.includes(\"Cowpeas\")) return 100000; // max in clean is 80000\n return 100;\n}", "function calcMetaDataField_max(data,params,field)\n{\n var target = field.target[0]; // these are always arrays coming in\n\n var dataTarget = normalizeDataItem(data,target);\n var max = null;\n\n for(var i=0; i < dataTarget.length; i++) {\n\tvar thisNumber = parseFloat(dataTarget[i]);\n\tif(max===null || thisNumber > max){\n\t max = thisNumber;\n\t} \n }\n\n return(max);\n}", "function setMaxPersediaan() {\n maxPermintaan = document.getElementById('newMaxPersediaan').value;\n }", "function maxVal(value, row){\n\n\n var max = options.scale.ticks.max;\n if ( value > max ){\n value = max;\n jQuery(row).find('.data-value').val(value);\n }\n return value;\n}", "static calcMaxValue(diceExp: string) {\n return baseBalcValue(diceExp, false, true);\n }", "function calculateMaxValue(maximum) {\n var distance = ($attrs.distance || '2.5%').trim();\n var isPercent = distance.indexOf('%') !== -1;\n return isPercent ?\n maximum * (1 - parseFloat(distance) / 100) :\n maximum - parseFloat(distance);\n }", "function calcMaxDays(maximDays) {\n\tageDayEl.setAttribute('max', maximDays);\n}", "function YLightSensor_get_highestValue()\n { var json_val = this._getAttr('highestValue');\n return (json_val == null ? Y_HIGHESTVALUE_INVALID : Math.round(json_val/6553.6) / 10);\n }", "get max() {\r\n return this._max\r\n }", "get max() { return this._max; }", "get max() { return this._max; }", "get max() { return this._max; }", "get max() { return this._max; }", "get max() { return this._max; }", "get max() { return this._max; }", "set max(max) {\n this._max = !isNumber(max) || max <= 0 ? 100 : max;\n }", "function maximum() {\r\nvar mini = Math.max.apply(null, numbers);\r\nconsole.log(\"maximum cherez matem funchii-\",mini);\r\n}", "getMax() {\n return this.max;\n }", "diameterMax() {\n let Dmax = 5.8 * Math.pow(this.mass, 1.0 / 3.0);\n return Dmax;\n }", "getComeGoal(max_value, value, current_value) {\n\n var temp = parseInt(current_value) + parseInt(value);\n if (temp < 0) {\n return 0;\n }\n if (temp >= max_value) {\n return max_value;\n } else {\n return temp;\n }\n }", "function setMaxPermintaan() {\n maxPermintaan = document.getElementById('newMaxPermintaan').value;\n }", "get max() {\n return this._max;\n }", "get maxValue() {\n return this.options.maxValue || null;\n }", "get max() {\n return this.getMax();\n }", "function getYMax(values, ucl, goal) {\n \t \t\n \tvar i, value, max = ucl;\n \t\n \tif (goal !== undefined && goal > max) {\n \t\tmax = goal;\n \t}\n \t\n \tfor(i = 0; i < values.length; i++) {\n \t\tvalue = values[i];\n \t\tif (value > max) {\n \t\t\tmax = value;\n \t\t}\n \t}\n \t\n \treturn max;\n }", "getMax() {\n return Math.max.apply(Math, this.my_orders.map(function(o) { return o.curr_1 }));\n }", "get max() {\n return this._max;\n }", "get max() {\n\t\treturn this.__max;\n\t}", "function getMaxY() {\n var max = 0;\n\n for(var i = 0; i < data.values.length; i ++) {\n if(data.values[i].Y > max) {\n max = data.values[i].Y;\n }\n }\n\n max += 10 - max % 10;\n return max;\n }", "extractMax() {\n // swap the first value in the values property with the last value\n // pop from the values property, so you can return the value at the end.\n // 'sink down' to the correct spot\n const max = this.values[0];\n const end = this.values.pop();\n if (this.values.length > 0) {\n this.values[0] = end;\n // move it to the correct position\n this.bubbleDown();\n }\n return max;\n }", "getMax() {\n \n }", "function getMaxY(data) {\r\n\tvar max = 0;\r\n\r\n\tfor(var i = 0; i < data.values.length; i ++) {\r\n\t\tif(data.values[i].Y > max) {\r\n\t\t\tmax = data.values[i].Y;\r\n\t\t}\r\n\t}\r\n\r\n\tmax += 10 - max % 10;\r\n\treturn max;\r\n}", "function getSystemMaxNumber() {\r\n\tvar t = document.getElementById('system_input').getAttribute('onkeyup').match(/\\d+/g);\r\n\r\n\treturn parseInt(t[1], 0);\r\n}", "function getMaxY() {\n var max = 0;\n for (var i = 0; i < data.values.length; i++) {\n if (data.values[i].Y > max) {\n max = data.values[i].Y;\n }\n }\n max += 10 - max % 10;\n return max;\n }", "function nota_mayor(){\n\t\tvar mayor = notas.indexOf(Math.max.apply(null, notas ));\n\t\tdocument.getElementById(\"mayor\").innerHTML = \"La nota mayor del estudiante: <b>\" + nombre_alumno(mayor) + \"</b>\";\n\t}", "function decVal(id, min, max = 12) {\n var val = parseInt($(id).val());\n if (val > min)\n $(id).val(val - 1);\n else if (val <= min)\n $(id).val(max);\n }", "function getInputMax(idx) {\r\n\tvar result = $(inputmetadata[idx]).find(\"maxes>data\");\r\n\tif (result == null || result.text() == null) {return -100;}\r\n\telse return parseFloat(extract(result.text()));\r\n}", "function feeMax(value){\n //Thresold given by hand\n return value <=0.00000200\n }", "function YLightSensor_set_highestValue(newval)\n { var rest_val;\n rest_val = String(Math.round(newval*65536.0));\n return this._setAttr('highestValue',rest_val);\n }", "function createMaximumsData() {\n var maxData={};\n maxData[LEFT]=createMaximumVO(LEFT);\n maxData[RIGHT]=createMaximumVO(RIGHT);\n maxData[UP]=createMaximumVO(UP);\n maxData[DOWN]=createMaximumVO(DOWN);\n \n return maxData;\n }", "set _max(value) {\n Helper.UpdateInputAttribute(this, \"max\", value);\n }", "maximum() {\n // Write your code here\n\tvar max = this.arr[0];\n\tfor(var i=0;i<this.arr.length;i++){\n\t\tif(max>this.arr[i]){\n\t\t max = max;\n\t\t}else{\n\t\t\tmax = this.arr[i];\n\t\t}\n\t}\n\treturn max;\n }", "get max() {\n\t\treturn this.nativeElement ? this.nativeElement.max : undefined;\n\t}", "get max() {\n\t\treturn this.nativeElement ? this.nativeElement.max : undefined;\n\t}", "function getMaxValue(series) {\n var data = [],\n item;\n\n for (item in series) {\n if (series.hasOwnProperty(item)) {\n data = data.concat(series[item]);\n }\n }\n\n return Math.max.apply(Math, data);\n }", "setMax(max) {\n self.datePicker.max = new Date(max);\n }", "set max(value) {\n Helper.UpdateInputAttribute(this, 'max', value);\n }", "function createMaximumsData() {\n\t\t\tvar maxData={};\n\t\t\tmaxData[LEFT]=createMaximumVO(LEFT);\n\t\t\tmaxData[RIGHT]=createMaximumVO(RIGHT);\n\t\t\tmaxData[UP]=createMaximumVO(UP);\n\t\t\tmaxData[DOWN]=createMaximumVO(DOWN);\n\t\t\t\n\t\t\treturn maxData;\n\t\t}", "function createMaximumsData() {\n\t\t\tvar maxData={};\n\t\t\tmaxData[LEFT]=createMaximumVO(LEFT);\n\t\t\tmaxData[RIGHT]=createMaximumVO(RIGHT);\n\t\t\tmaxData[UP]=createMaximumVO(UP);\n\t\t\tmaxData[DOWN]=createMaximumVO(DOWN);\n\t\t\t\n\t\t\treturn maxData;\n\t\t}", "function createMaximumsData() {\n\t\t\tvar maxData={};\n\t\t\tmaxData[LEFT]=createMaximumVO(LEFT);\n\t\t\tmaxData[RIGHT]=createMaximumVO(RIGHT);\n\t\t\tmaxData[UP]=createMaximumVO(UP);\n\t\t\tmaxData[DOWN]=createMaximumVO(DOWN);\n\n\t\t\treturn maxData;\n\t\t}", "function findLarge(){\r\n \r\n \r\n var boxvalue01=document.getElementById('inputBox07a').value;\r\n var boxvalue02=document.getElementById('inputBox07b').value;\r\n \r\n \r\n\r\n var largernum = Math.max(boxvalue01,boxvalue02);\r\n \r\n document.getElementById(\"ans07\").innerHTML =largernum +\" - is Larger\";\r\n \r\n return false\r\n}", "function setMaxYValue(dataId) {\n\n if (dataId == \"Above5\" || dataId == \"Above4\") {\n return 1;\n } else if (dataId == \"Attainment8\") {\n return 90;\n } else {\n return 0.5;\n }\n}", "maxOrderQuantity(maxValue) {\n return maxValue;\n }", "function maxValidator(max) {\n return control => {\n if (isEmptyInputValue(control.value) || isEmptyInputValue(max)) {\n return null; // don't validate empty values to allow optional controls\n }\n\n const value = parseFloat(control.value); // Controls with NaN values after parsing should be treated as not having a\n // maximum, per the HTML forms spec: https://www.w3.org/TR/html5/forms.html#attr-input-max\n\n return !isNaN(value) && value > max ? {\n 'max': {\n 'max': max,\n 'actual': control.value\n }\n } : null;\n };\n}", "function result_max() {\n result_a = flotr_data[0].data.filter(isBigEnough(area.x1)).filter(isSmallEnough(area.x2)).reduce(\n function(max, arr) {\n return max >= arr[1] ? max : arr[1];\n }, -Infinity);\n\n if (typeof flotr_data[1] !== \"undefined\") {\n if ( typeof flotr_data[1].yaxis === \"undefined\") {\n result_b = flotr_data[1].data.filter(isBigEnough(area.x1)).filter(isSmallEnough(area.x2)).reduce(function(max, arr) {\n return max >= arr[1] ? max : arr[1];\n }, -Infinity);\n if (result_b > result_a ){\n return result_b;\n }\n }\n }\n return result_a;\n }", "function showMaxTemp(i, id){\n max = `\n ${currentData[i].app_max_temp} ° de máxima\n `\n document.getElementById(id).innerHTML = max;\n}", "function outputMaxPrice(array) {\n let item1 = Math.max.apply(Math, array);\n let item2 = Math.min.apply(Math, array);\n return item1 - item2;\n\t\t}", "function maxtable(){\n var maximum = Math.max.apply(null, tabValue);\n console.log(tabValue);\n tabValue = [];\n console.log(\"sending value to node.js : \" + maximum);\n return maximum;\n}", "function max(writer, value) {\n if ( !isArray(value) ) {\n return typeof value === 'number' ? value : NaN;\n }\n return Math.max.apply(Math, value);\n}", "static get MAX_VALUE() {\n return 127;\n }", "function fetchMaxDisp() {\n // function that saves to memory the maxima of the displayed chart\n PlotInfo.maxDisp = 0;\n for (i = 0; i < Selected.arr.length; i++) {\n let maxima = Math.max(\n ...unpack(gdata, selected.arr[i].id).slice(\n PlotInfo.rangeStartI,\n PlotInfo.rangeEndI\n )\n );\n }\n PlotInfo.maxDisp = Math.max(PlotInfo.maxDisp, maxima);\n}", "function getMaxYAxis(data) {\n var max = 0;\n data.forEach(function(item) {\n max = Math.max(max, d3.max(item.values, function(d) {\n return d.value;\n }));\n\n });\n\n return Math.ceil(max / 500) * 500;\n }", "set max(mL) {\n if (typeof mL !== 'number' || mL < 0) throw new TypeError('max must be a non-negative number');\n this[MAX] = mL || Infinity;\n trim(this);\n }", "function maxInputDay(){\n let today = new Date();\n let dd = today.getDate();\n let mm = today.getMonth()+1; //January is 0\n let yyyy = today.getFullYear();\n if(dd < 10){\n dd = '0'+ dd\n }\n if(mm < 10){\n mm = '0' + mm\n }\n today = yyyy + '-' + mm + '-' + dd;\n maxDay.setAttribute(\"max\", today);\n }", "set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }", "set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }", "set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }", "set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }", "set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }", "set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }", "set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }", "set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }", "set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }", "set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }", "set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }", "set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }", "set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }", "set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }", "set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }", "extractMax() {\n const max = this.values[0];\n const end = this.values.pop();\n this.values[0] = end;\n this.sinkDown();\n return max;\n }", "function createMaximumsData() {\n var maxData = {};\n maxData[LEFT] = createMaximumVO(LEFT);\n maxData[RIGHT] = createMaximumVO(RIGHT);\n maxData[UP] = createMaximumVO(UP);\n maxData[DOWN] = createMaximumVO(DOWN);\n\n return maxData;\n }", "function setMaxCustomDie(){\r\n maxCustomDie = inMaxCustomDie.value;\r\n}" ]
[ "0.68274987", "0.67250717", "0.66997606", "0.6594341", "0.65138334", "0.65106434", "0.64073956", "0.6382986", "0.6377778", "0.6359372", "0.63428384", "0.6298422", "0.6285514", "0.6256145", "0.6250908", "0.6232988", "0.6216029", "0.62050897", "0.6192077", "0.6187974", "0.61835593", "0.6179138", "0.6151307", "0.6124065", "0.6119587", "0.6084207", "0.60584813", "0.60521555", "0.60521555", "0.60521555", "0.60521555", "0.60521555", "0.60521555", "0.605125", "0.60504127", "0.6041403", "0.60300535", "0.60247576", "0.6022771", "0.6020577", "0.60201347", "0.60153407", "0.5988199", "0.598446", "0.59794486", "0.59788746", "0.5971439", "0.595882", "0.5954948", "0.5953207", "0.59430265", "0.59410137", "0.59401876", "0.592705", "0.59166384", "0.5910654", "0.59103394", "0.5902316", "0.58981675", "0.5875501", "0.5871659", "0.5871659", "0.58659524", "0.58597964", "0.5841056", "0.58335006", "0.58335006", "0.58242625", "0.58158755", "0.5815149", "0.5814933", "0.5812301", "0.5804506", "0.5802127", "0.57931453", "0.5792664", "0.57906914", "0.578672", "0.5777134", "0.5765199", "0.57533026", "0.57511955", "0.57456106", "0.57456106", "0.57456106", "0.57456106", "0.57456106", "0.57456106", "0.57456106", "0.57456106", "0.57456106", "0.57456106", "0.57456106", "0.57456106", "0.57456106", "0.57456106", "0.57456106", "0.5745139", "0.57448393", "0.5741719" ]
0.6782513
1
busca el valor de minimo (de la propiedad LOW) de cada dia (propiedad DTYYYYMMDD)(el valor de minimo de cada dia)
function buscarMinDia(array) { let day; let arr = []; for (let i = 0; i < array.length; i++) { let date = array[i].DTYYYYMMDD; if (day != date) { day = date; let res; let contador = 0; for (let j = 0; j < array.length; j++) { if (array[j].DTYYYYMMDD === day) { if (contador === 0) { res = array[j].LOW; } else { res = Math.min(res, array[j].LOW); } contador++; } } arr.push(res); } } //console.log('Minimos:', arr) return arr; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function milisegundosToMinutos(milisegundos) {\n let minutos = milisegundos / 60000\n return minutos\n}", "function sumaDuracion(){\n \n var sumHrs = parseInt(0), sumMin = parseInt(0);\n var auxHrs = parseInt(0), auxMin = parseInt(0);\n var totalHrs = parseInt(0), totalMin, i=1, ni=0;\n \n $('[name=\"minAP\"]').each(function(){\n \n var m = $(this).val();\n if (m !== \"\" && m!==\"99\"){ \n sumMin += parseInt(m);\n auxMin = sumMin % 60;\n auxHrs = Math.trunc(sumMin/60);\n \n var h = $('#hrsAP'+i).val();\n sumHrs += parseInt(h);\n }else if(m === \"99\"){\n ni++;\n }\n totalHrs = sumHrs + auxHrs;\n i++;\n });\n \n if(auxMin<10){//si es menor que 10 le concatena un cero para que se muestre en el select\n totalMin = '0' + auxMin;\n }else{\n totalMin = auxMin;\n }\n \n if(ni !== 5){//muestra el valor total de las horas y minutos\n $('#hrs').val(totalHrs);\n $('#min').val(totalMin);\n $('#chkDNI').prop('checked',false);\n }else{//si todos los campos son NI pone el valor NI\n $('#hrs').val(\"99\");\n $('#min').val(\"99\");\n $('#chkDNI').prop('checked',true);\n }\n}", "function setM(value) {\n document.getElementById(\"valueM\").innerHTML = value;\n mines = parseInt(value);\n}", "function adicionaMinutos() {\n\n\n if(minutos === 5){\n setMinutos(10);\n setSegundos(0);\n }\n\n if(minutos === 10){\n setMinutos(15);\n setSegundos(0);\n }\n\n if(minutos === 10){\n setMinutos(15);\n setSegundos(0);\n }\n\n if(minutos === 15){\n setMinutos(20);\n setSegundos(0);\n }\n\n if(minutos === 20){\n setMinutos(25);\n setSegundos(0);\n }\n\n if(minutos === 25){\n setMinutos(30);\n setSegundos(0);\n }\n\n if(minutos === 30){\n setMinutos(35);\n setSegundos(0);\n }\n\n if(minutos === 35){\n setMinutos(40);\n setSegundos(0);\n }\n\n if(minutos === 40){\n setMinutos(5);\n setSegundos(0);\n }\n}", "function getInputMin(idx) {\r\n\tvar result = $(inputmetadata[idx]).find(\"mins>data\");\r\n\tif (result == null || result.text()==null) {return -100;}\r\n\telse return parseFloat(extract(result.text()));\r\n}", "get min() {\n return this.date.getMinutes();\n }", "function evaluateMin(min) {\r\n if (min == 1) {\r\n minutes = ' minute';\r\n } else {\r\n minutes = ' minutes';\r\n }\r\n return minutes;\r\n}", "function progressMin() {\n var min = mins.innerHTML;\n\n switch (true) {\n case min <= 59 && min != \"00\":\n {\n mins.innerHTML = minutes++;\n }\n break;\n case min > 59:\n {\n mins.innerHTML = \"00\";\n hours.innerHTML = \"9\";\n }\n break;\n default:\n return;\n }\n }", "function convert(min){\n min*=60;\n return min;\n}", "function findTheMinimumValueOfChemin(chemin) {\n var minimum = chemin[1].value;\n for(var i=1; i < chemin.length; i++) {\n if(chemin[i].value == \"E\" && chemin[i].marque == '-') {\n minimum = chemin[i].value;\n }\n if(chemin[i].value != \"E\" && chemin[i].value < minimum && chemin[i].marque == '-') minimum = chemin[i].value;\n }\n return minimum;\n }", "get minimumValue() {\r\n return this.i.minimumValue;\r\n }", "getInt(thing, min = 0){\n thing = parseInt(thing);\n min = parseInt(min);\n\n if (Number.isNaN(thing)) {\n if (!Number.isNaN(min)) return min;\n else return 0;\n } else {\n if (!Number.isNaN(min)) {\n if (thing > min) return thing;\n else return min;\n } else return thing;\n }\n }", "function setMinutes() {\n if (minNow <= 5 || minNow >= 55) {\n min = arrMins[0];\n }\n else if (minNow <=10 || minNow >= 50) {\n min = arrMins[1];\n }\n else if (minNow <=10 || minNow >= 50) {\n min = arrMins[1];\n }\n else if (minNow <=15 || minNow >= 45) {\n min = arrMins[2];\n }\n else if (minNow < 30 || minNow > 30) {\n min = arrMins[3];\n }\n return min;\n}", "get min() {\r\n return this._min\r\n }", "get min() { return this._min; }", "get min() { return this._min; }", "get min() { return this._min; }", "get min() { return this._min; }", "get min() { return this._min; }", "get min() { return this._min; }", "function duracionCero(hrs, min){\n \n if($(hrs).val()===\"0\" && $(min).val()===\"00\"){\n alert(\"La duracion (horas y minutos) de la audiencia no pueden ser cero\");\n $(hrs).val('');\n $(min).val('');\n }\n}", "function getDurMin($sec) {\r\n // if($sec.isNaN()){}\r\n var min = parseInt($sec / 60);\r\n var sec = parseInt($sec % 60);\r\n if (min < 10) {\r\n min = '0' + min;\r\n }\r\n if (sec < 10) {\r\n sec = '0' + sec;\r\n }\r\n return { min: min, sec: sec };\r\n }", "function cambiarTiempo(ano, mes, dia, hour, min) {\n\n let cambioMin = min;\n let cambioHour = hour;\n let cambioDia = dia;\n let cambioAno = ano;\n let cambioMes = mes;\n\n\n\n if (cambioMin == 30) {\n cambioMin = 0;\n if (cambioHour === 23) {\n cambioHour = 0;\n if (cambioDia === 30 || cambioDia === 31) {\n\n cambioDia = 1;\n\n if (cambioMes === 12) {\n cambioMes = 1;\n cambioAno++;\n } else {\n cambioMes++;\n }\n } else {\n cambioDia++;\n }\n\n } else {\n cambioHour++;\n }\n\n } else if (cambioMin < 30) {\n cambioMin += 30;\n\n\n } else if (cambioMin > 30) {\n\n let aux = Math.abs(cambioMin - 30);\n if (cambioHour === 23) {\n cambioHour = 0;\n if (cambioDia === 30 || cambioDia === 31) {\n\n cambioDia = 1;\n\n if (cambioMes === 12) {\n cambioMes = 1;\n cambioAno++;\n } else {\n cambioMes++;\n }\n } else {\n cambioDia++;\n }\n\n } else {\n cambioMin = aux;\n cambioHour++;\n }\n\n }\n\n //final del dia\n\n return [cambioAno, cambioMes, cambioDia, cambioHour, cambioMin];\n\n}", "function setMinPermintaan () {\n minPermintaan = document.getElementById('newMinPermintaan').value;\n }", "function getMinimum () {\n if ((document.getElementById('entMin').value)===\"\") {\n return 1;\n }\n else {\n return Number(document.getElementById('entMin').value)}\n}", "get min() {\n return this._min;\n }", "function arreglarFormatoMinutos () {\n const minutos = fecha.getMinutes()\n if (minutos < 10) {\n const minutosArreglados = '0' + minutos\n return minutosArreglados\n } else {\n return minutos\n }\n}", "function getMinTemp() {\n for (var i = 0; i < forecastDays; i++) {\n var minTemp = response.query.results.channel.item.forecast[i].low;\n $(\"#day\" + i + \"Min\").append(\"Low: \" + minTemp + \"°F\");\n }\n }", "get minNumber() {\n return 0\n }", "function minValue() {\n return parse(-8640000000000000, 1);\n}", "function minutecalc(input){\r\n //set a variable for the date: 1st of Jan 2018, as a reference\r\n var dateReference = new Date(\"2018-01-01T12:00:00Z\");\r\n\t//calculate the difference between current date and reference date\r\n\tvar dateDifference = dateReference.getTime() - dateCurrent.getTime();\r\n\t//turn the difference into minutes\r\n\tvar dateMinute = dateDifference / 60000;\r\n\t//convert the difference in minutes into a number\r\n\tvar dateMinuteS = Math.abs(dateMinute);\r\n\t//round the number up to remove decimals\r\n\tvar dateMinuteR = roundup(dateMinuteS);\r\n //put the following math back into the input variable and return it\r\n input = dateMinuteR;\r\n\treturn input;\r\n}", "function convertmin(minutes)\n{\n return minutes*60;\n}", "get minimumValue() {\r\n return this.i.bl;\r\n }", "function setMin (response) {\n curMin1 = 9999;\n for(var i = 0; i < 8; i++) {\n var tempMin1 = response.list[i].main.temp_min;\n //console.log(tempMin1);\n\n if (tempMin1 < curMin1) {\n curMin1 = Math.round(response.list[i].main.temp_min);\n }\n else if (curMin1 > curTemp) {\n curMin1 = Math.round(curTemp);\n }\n }\n}", "function min_t_sec(){\n const min = parseInt(document.getElementById(\"min\").value);\n const sec = min*60;\n document.getElementById(\"ans\").value = sec; \n}", "function convert(min) {\n let result = min * 60;\n\n return result;\n}", "function min(a, b) {\n console.log(\"Ini entre\", a, \"et\", b);\n return NaN;\n}", "get minimumValue() {\n return this.i.bl;\n }", "function minValidator(min) {\n return control => {\n if (isEmptyInputValue(control.value) || isEmptyInputValue(min)) {\n return null; // don't validate empty values to allow optional controls\n }\n\n const value = parseFloat(control.value); // Controls with NaN values after parsing should be treated as not having a\n // minimum, per the HTML forms spec: https://www.w3.org/TR/html5/forms.html#attr-input-min\n\n return !isNaN(value) && value < min ? {\n 'min': {\n 'min': min,\n 'actual': control.value\n }\n } : null;\n };\n}", "get min() {\n\t\treturn this.__min;\n\t}", "function habilitarSegundaFecha() {\n eval(\"debugger;\");\n var fchDesde = document.getElementById('inputInicioCursado').value;\n var fchHoy = document.getElementById('todayDate').value;\n \n if(fchDesde < fchHoy){\n document.getElementById('inputFinCursado').value = fchHoy;\n document.getElementById('inputFinCursado').min = fchHoy; \n }else{\n document.getElementById('inputFinCursado').value = fchDesde;\n document.getElementById('inputFinCursado').min = fchDesde; \n }\n \n \n document.getElementById('inputFinCursado').disabled = false;\n document.getElementById('inputFinCursado').readonly = false;\n\n}", "function minimum() {\r\nvar mini = Math.min.apply(null, numbers);\r\nconsole.log(\"minimum cherez matem funchii-\",mini);\r\n}", "function showMinTemp(i, id){\n min = `\n ${currentData[i].app_min_temp} ° de mínima\n `\n document.getElementById(id).innerHTML = min;\n}", "calcMinValue (state) {\n return d3.min(state, d => {\n let data = 0\n Object.entries(d).forEach(\n\t\t\t\t ([key, values]) => {\n\t\t\t \t\tObject.entries(values[0]).forEach(\n\t\t\t\t \t\t([key, value]) => {\n\t\t\t\t \t\t\tdata += value\n\t\t\t\t \t\t}\n\t\t\t\t \t)\n\t\t\t\t }\n )\n return (data)\n })\n }", "function min_to_ms(min) {\n return min*60*1000;\n}", "function setMinPersediaan(params) {\n minPersediaan = document.getElementById('newMinPersediaan').value;\n }", "minOrderQuantity(minValue) {\n return minValue;\n }", "mayor(){\n let valor= this._data[0];\n for (let x of this._data){\n if(valor<x){\n valor=x;\n }\n }\n return valor;\n }", "function minValidator(min) {\n return (control) => {\n if (isEmptyInputValue(control.value) || isEmptyInputValue(min)) {\n return null; // don't validate empty values to allow optional controls\n }\n const value = parseFloat(control.value);\n // Controls with NaN values after parsing should be treated as not having a\n // minimum, per the HTML forms spec: https://www.w3.org/TR/html5/forms.html#attr-input-min\n return !isNaN(value) && value < min ? { 'min': { 'min': min, 'actual': control.value } } : null;\n };\n}", "function minValidator(min) {\n return (control) => {\n if (isEmptyInputValue(control.value) || isEmptyInputValue(min)) {\n return null; // don't validate empty values to allow optional controls\n }\n const value = parseFloat(control.value);\n // Controls with NaN values after parsing should be treated as not having a\n // minimum, per the HTML forms spec: https://www.w3.org/TR/html5/forms.html#attr-input-min\n return !isNaN(value) && value < min ? { 'min': { 'min': min, 'actual': control.value } } : null;\n };\n}", "function minValidator(min) {\n return (control) => {\n if (isEmptyInputValue(control.value) || isEmptyInputValue(min)) {\n return null; // don't validate empty values to allow optional controls\n }\n const value = parseFloat(control.value);\n // Controls with NaN values after parsing should be treated as not having a\n // minimum, per the HTML forms spec: https://www.w3.org/TR/html5/forms.html#attr-input-min\n return !isNaN(value) && value < min ? { 'min': { 'min': min, 'actual': control.value } } : null;\n };\n}", "function YLightSensor_get_lowestValue()\n { var json_val = this._getAttr('lowestValue');\n return (json_val == null ? Y_LOWESTVALUE_INVALID : Math.round(json_val/6553.6) / 10);\n }", "function getMin(t){\n t = t.split(\":\");\n return 60* Number(t[0]) + Number(t[1]);\n}", "set min(value) {\n Helper.UpdateInputAttribute(this, 'min', value);\n }", "function vectorTimerMin(time, minOn, minOff){\n print('[iOLED-FIRMWARE][vectorTimerHour] Build Minute vector timer ...');\n\n let minOn = JSON.parse(minOn);\n let minOff = JSON.parse(minOff);\n\n if (minOff > minOn){\n for(let i = 0; i < 60; i++){\n yMin[i] = 0;\n if (time[i] >= minOn && time[i] < minOff){\n yMin[i] = 1;\n }\n }\n }\n\n if (minOn > minOff){\n for(let i = 0; i < 60; i++){\n yMin[i] = 1;\n if (time[i] >= minOff && time[i] < minOn){\n yMin[i] = 0;\n }\n }\n }\n\n return yMin\n}", "setMin(min) {\n self.datePicker.min = new Date(min);\n }", "function setMinDate() {\n let aus = new Date();\n aus.setDate = aus.getDate();\n aus.setFullYear(aus.getFullYear() - 8); //imposto come data di nascita massima 8 anni fa\n let data = aus.toISOString().split('T')[0];\n $(\"#dataNascitaModProfilo\").attr(\"max\", data);\n}", "function valores(){\n var valor1 = 3;\n var valor2 = 18;\n var valor3 = 10;\n var max;\n var min;\n var suma; \n var prom;\n\n console.log(\"Suma de los tres valores: \")\n console.log(suma = valor1 + valor2 + valor3);\n \n console.log(\"Promedio de los tres valores: \")\n console.log(prom = suma / 3);\n\n console.log(\"Valor Maximo: \")\n console.log(max = Math.max(valor1, valor2, valor3));\n\n console.log(\"Valor Minimo: \")\n console.log(min = Math.min(valor1, valor2, valor3));\n\n}", "function getMinValue(data){\n let min = 9999\n let t_min\n data.forEach(function(e) { \n t_min = d3.min(Object.values(e));\n if(t_min < min) {\n min = t_min;\n } \n });\n return min;\n}", "function printMinutes() {\n minDec.textContent = chronometer.twoDigitsNumber(chronometer.getMinutes())[0];\n minUni.textContent = chronometer.twoDigitsNumber(chronometer.getMinutes())[1];\n}", "get min() {\n return this.getMin();\n }", "function calcMetaDataField_min(data,params,field)\n{\n var target = field.target[0]; // these are always arrays coming in\n\n var dataTarget = normalizeDataItem(data,target);\n var min = null;\n\n for(var i=0; i < dataTarget.length; i++) {\n\tvar thisNumber = parseFloat(dataTarget[i]);\n\tif(min===null || thisNumber < min){\n\t min = thisNumber;\n\t} \n }\n\n return(min);\n}", "#getMinFeelsLikeNight(data) {\n\t\t//daily weather\n\t\tconst dailyData = data.daily;\n\t\t//array of night feels_like and night temperature amplitudes and date\n\t\tconst tempsArr = dailyData.map((item) => {\n\t\t\treturn {\n\t\t\t\tamplitude: item.temp.night - item.feels_like.night,\n\t\t\t\tdate: item.dt,\n\t\t\t};\n\t\t});\n\t\t//get object with min amplitude\n\t\tconst result = tempsArr.reduce(function (prev, curr) {\n\t\t\treturn prev.amplitude < curr.amplitude ? prev : curr;\n\t\t});\n\n\t\treturn result;\n\t}", "set _min(value) {\n Helper.UpdateInputAttribute(this, \"min\", value);\n }", "function YLightSensor_set_lowestValue(newval)\n { var rest_val;\n rest_val = String(Math.round(newval*65536.0));\n return this._setAttr('lowestValue',rest_val);\n }", "function setClosestMin(){\n var date = new Date();\n var m =date.getMinutes();\n var h = date.getHours();\n var defH = $('#hours').children('option:selected').val();\n var firstH = $('#hours').children('[active=\"\"]').val();\n if(defH==firstH || defH==h){ // pokud je aktivní hodnota hodiny shodná s reálným časem -> disable minut\n $('#minutes').children().each(function(){\n var realStep =($(this).val())-(minuteStep);\n if(realStep < m){\n $(this).attr('disabled','disabled');\n }\n });\n //store set values\n var currStep = ($('#currentState').attr('minute'))-(minuteStep);\n if(($('#currentState').attr('minute').length)>0 && (currStep>m)){\n $('#minutes option[value=\"'+$('#currentState').attr('minute')+'\"]').prop('selected',true);\n }else{\n $('#minutes').children('option:enabled').eq(0).prop('selected',true);\n }\n }else{ // selected 1h+ from curr time\n $('#minutes').children().each(function(){\n $(this).removeAttr('disabled','disabled');\n });\n var currStep = ($('#currentState').attr('minute'));\n if((currStep.length)>0){\n $('#minutes option[value=\"'+currStep+'\"]').prop('selected',true);\n }else{\n $('#minutes').children('option:enabled').eq(0).prop('selected',true);\n }\n }\n\n var countDisabled = $('#minutes').children('option:disabled').length;\n if(countDisabled > 5){ // plus 1 hour\n $('#currentState').attr('deprecated',h);\n $('#hours').children('option:enabled').eq(0).prop('disabled',true);\n $('#hours').children('option:enabled').eq(0).prop('selected',true);\n setClosestMin();\n }\n\n\n if((defH-h)==1){ // conversion minutes in next hour (16.51 -> 17:20)\n $('#minutes').children().each(function(){\n var remainsMin = 60-m;\n var realStep =($(this).val())-(minuteStep-remainsMin);\n if(realStep <= 0){\n $(this).attr('disabled','disabled');\n }\n });\n // store set values\n var currStep = ($('#currentState').attr('minute'));\n var firstEnabled = $('#minutes').children('option:enabled').eq(0).val();\n if(($('#currentState').attr('minute').length)>0 && currStep>firstEnabled){\n $('#minutes option[value=\"'+$('#currentState').attr('minute')+'\"]').prop('selected',true);\n }else{\n $('#minutes').children('option:enabled').eq(0).prop('selected',true);\n }\n }\n}", "function maxAndMinNextValue(minSoFar,total,level)\n{\nvar quotient = Math.floor(total/level)\nvar dividend = total%level\n//th\n//because the level is greater than one we can spread the total over the remaining slots\n//the -1 is because we are putting one in every slot accept the one we are concerned with\n//making the others one tells us this max\nvar maxCandidateByWhatsLeve = total-((level*1)-1)\n//This value cannot be larger than the smallest so far\nvar max = (minSoFar<maxCandidateByWhatsLeve)?minSoFar:maxCandidateByWhatsLeve;\nvar min = quotient+((dividend>0)?1:0);\nreturn [min,max];\n}", "function ObtenerValor(minutos, total) {\n return minutos * total / 1440;\n}", "function devolverMinutos(horaMinutos)\r\n{\r\n return (parseInt(horaMinutos.split(\":\")[0])*60)+parseInt(horaMinutos.split(\":\")[1]);\r\n}", "set min(value) {\n this.changeAttribute('min', value);\n }", "function minPrice(element, value) {\n element.min = value;\n element.placeholder = value;\n }", "getMin() {\n return this.min;\n }", "function convertMinutos(mins) {\n\n let h = Math.floor(mins / 60);\n let m = mins % 60;\n h = h < 10 ? '0' + h : h;\n m = m < 10 ? '0' + m : m;\n return `${h}:${m}:00`;\n\n }", "function updateMinN(min) {\n reset();\n if (min < 1 || min > 100 || Math.round(min) != min) {\n alert(\"Minimum value of n must be an integer between 1 and 100\");\n document.getElementById(\"minInput\").value = minN;\n } else {\n minN = min;\n }\n}", "get actualMinimumValue() {\r\n return this.i.actualMinimumValue;\r\n }", "get min() {\n return this.args.min || 0;\n }", "getMin() {\n return this.min;\n }", "min() {\n const { value, operation } = this.state;\n if (operation === 0) {\n this.setState({\n num1: Number(value),\n operation: 2,\n });\n this.clear();\n }\n }", "function getCurrentTimeInHoursMins(hourField, minField)\n{\n\tvar currentDate = new Date();\n\tvar currentHour = padNumber(currentDate.getHours());\n\tvar currentMin = padNumber(currentDate.getMinutes());\n\t\n\t$('#' + hourField).val(currentHour);\n\t$('#' + minField).val(currentMin);\n}", "incrementMin() {\n this.alarm.minutes < 59 ? this.alarm.minutes++ : this.alarm.minutes = 0;\n this.setDisplay();\n }", "function mini() {\n\n //If e2 errors that means, the data has reached it's conclusion. at which point the models will reset and start again.\n try {\n minim = globaldata[e2]['minute'] \n }\n catch {\n console.log('Reset')\n clear()\n speedreset()\n getdata()\n }\n\n if (minim < 10) {\n minute.push(`:0${minim}`)\n }\n else {\n minute.push(`:${minim}`)\n }\n\n minute.shift()\n e2= e2 + 1\n // console.log(minute)\n return minute;\n}", "function adjustMines() {\n maxMines = (lines*collumns) - 1;\n \n document.getElementById(\"mineSlider\").setAttribute(\"max\", maxMines);\n document.getElementById(\"valueMax\").innerHTML = maxMines;\n \n if (mines > maxMines) {\n document.getElementById(\"valueM\").innerHTML = maxMines;\n mines = parseInt(maxMines);\n }\n}", "function fieldMin(doc, field, value) {\n // Requires(doc !== undefined)\n // Requires(field !== undefined)\n // Requires(value !== undefined)\n\n fieldSet(doc, field, value, function (oldValue) {\n if (oldValue === undefined)\n return value;\n return compare(value, oldValue) < 0 ? value : oldValue;\n });\n }", "function chkEtaMinima(dataNascita) {\n let dataBase = new Date();\n let diffTime = Math.abs(dataBase - dataNascita);\n return Math.ceil(diffTime / (1000 * 60 * 60 * 24));\n}", "setValueDiffMin (valueDiffMin) {\n this._valueDiffMin = valueDiffMin\n }", "min(m) {\n const mn = ((m || '0') + '');\n return mn.length < 2 ? '0' + mn : mn;\n }", "function findMinValue(values) {\n return Math.min.apply(Math, [1, 2, 3, 4, 5, 6, 7, 8, 9, 0]);\n }", "function verificarNumero(value, min, id){\n let res = \"\";\n let val = value.split(\"\");\n for(let i = 0; i < val.length; i++){\n res += (NUMBERS.includes(val[i])) ? val[i] : \"\";\n }\n if(Number.parseInt(res) > 20) {\n res = (Number.parseInt(res) > 20) ? res.slice(0,-1) : res;\n }\n document.getElementById(id).value = res;\n return (Number.isInteger(Number.parseInt(value[value.length - 1])) && !(Number.parseInt(value) < min));\n}", "function snapMinDate(min, max, incr) {\n\t\t// get ts of 12am on day of i0 timestamp\n\t\tvar minDate = new Date(min * 1000);\n\t\tvar min00 = +(new Date(minDate[getFullYear](), minDate[getMonth](), minDate[getDate]())) / 1000;\n\t\tvar offset = min - min00;\n\t\tvar newMin = min00 + incrRoundUp(offset, incr);\n\t\treturn [newMin, max];\n\t}", "function findMinValue(values) {\n // FILL THIS IN\n return Math.min.apply(Math,values);\n }", "function mostrarBaja(){\n var notaBaja=6.8;\n\n\n for (i=0; i < estudiantes.length; i++){\n if(notaBaja > estudiantes[i].nota){\n notaBaja = Math.min(estudiantes[i].nota);\n }\n }\n document.getElementById(\"st1\").innerHTML=\"La nota mas baja es: \" + notaBaja;\n}", "min(cols=this.displayColumns) {\n if (!this.state.data || this.state.data.length === 0) { return 0; }\n\n const minObs = obs => {\n const vals = _.values(obs).filter(actualNumber);\n return Math.min(...vals);\n };\n\n const pickFields = cols.map(c => c.accessor);\n const allMins = this.getDataPackets()\n .map(obs => _.pick(obs, pickFields))\n .map(obs => minObs(obs));\n\n return Math.min(...allMins);\n }", "function getValues() {\n jornadaCertPonto = parseInt(document.getElementById('jornadaCertPonto').value);\n almoco = parseInt(document.getElementById('almoco').value);\n tolerancia = parseInt(document.getElementById('tolerancia').value);\n semAlmoco = parseInt(document.getElementById('semAlmoco').value);\n horasAbonadas = document.getElementById('horasAbonadas').value;\n\n if (isNaN(jornadaCertPonto)) {\n jornadaCertPonto = 9;\n }\n if (isNaN(almoco)) {\n almoco = 1;\n }\n if (isNaN(tolerancia)) {\n tolerancia = 10;\n }\n if (isNaN(semAlmoco)) {\n semAlmoco = 4;\n }\n if (horasAbonadas === '') {\n horasAbonadas = '00:00';\n }\n\n setValues();\n // trata horas incluídas com segundos HH:mm:ss\n if (horasAbonadas.length == 8) {\n horasAbonadas = horasAbonadas.split(':')[0] + ':' + horasAbonadas.split(':')[1];\n }\n\n jornadaSap = jornadaCertPonto - almoco;\n document.getElementById('jornadaSap').value = jornadaSap;\n}", "get minInclusive() {\n return this._minInclusive;\n }", "function x( d ){ return d.anio; } // Devuelve el valor del año de un punto dado", "function min(min,max){\n return Math.min(min,max)\n}", "function getMinFare(data) {\n\tconst fareList = data.filter(passenger => passenger.fields.fare != null).map(passenger => passenger.fields.fare)\n\tconst minFare = Math.min(...fareList)\n\tconsole.log(`MINIMUM FARE: $${minFare}`)\n\treturn minFare\n}", "function setMinCustomDie(){\r\n minCustomDie = inMinCustomDie.value;\r\n}", "function cargarMinutos(segundos){\r\n let txtMinutos;\r\n\r\n if(segundos == -1 && minutos !== 0){\r\n setTimeout(() =>{\r\n minutos--;\r\n },500)\r\n }else if(segundos == -1 && minutos == 0){\r\n setTimeout(() =>{\r\n minutos = 59;\r\n },500)\r\n }\r\n\r\n //Mostrar Minutos en pantalla\r\n if(minutos < 10){\r\n txtMinutos = `0${minutos}`;\r\n }else{\r\n txtMinutos = minutos;\r\n }\r\n document.getElementById('minutos').innerHTML = txtMinutos;\r\n cargarHoras(segundos,minutos);\r\n}", "function getMinAmount(var maximumPerDay, var amountSpent){\n return maximumPerDay - amountSpent;\n}" ]
[ "0.6305875", "0.6247586", "0.61750144", "0.60922945", "0.6088371", "0.6011467", "0.5953956", "0.59032714", "0.58966565", "0.5886316", "0.58637834", "0.5840592", "0.5825569", "0.5822594", "0.58093446", "0.58093446", "0.58093446", "0.58093446", "0.58093446", "0.58093446", "0.5803542", "0.5799085", "0.5789356", "0.5778108", "0.57372326", "0.57151026", "0.57131815", "0.5706308", "0.5697832", "0.5697695", "0.5680943", "0.56785804", "0.5678151", "0.5675121", "0.56679726", "0.566634", "0.5660489", "0.56486326", "0.5622501", "0.56212866", "0.5618792", "0.56087416", "0.5576233", "0.55747455", "0.5572317", "0.5561565", "0.5560442", "0.55518126", "0.55484533", "0.55484533", "0.55484533", "0.5537789", "0.5534481", "0.55316126", "0.552789", "0.55169", "0.5513264", "0.5499912", "0.5494269", "0.5491249", "0.5479626", "0.5476337", "0.54664534", "0.54621065", "0.5445105", "0.54434407", "0.54422235", "0.5441588", "0.54327786", "0.54276216", "0.5426248", "0.54213506", "0.54088885", "0.538703", "0.5386973", "0.53840554", "0.53711087", "0.53633595", "0.53469723", "0.53249437", "0.5312002", "0.5299038", "0.52989686", "0.5296382", "0.52942115", "0.5288431", "0.5279012", "0.5276253", "0.526707", "0.5255063", "0.5252146", "0.52474624", "0.52391577", "0.52311593", "0.5230553", "0.5208269", "0.5203162", "0.5191422", "0.5186536", "0.5185648" ]
0.6517961
0
crea un array con cuatro array dentro uno por cada propirad
function obtenerValoresPorDias(array) { let res; let dia = diaMes(array) let apertura = buscarAperturaDia(array); let max = buscarMaxDia(array); let min = buscarMinDia(array); let cierre = buscarCierreDia(array); res = [dia, apertura, max, min, cierre]; return res; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function inicializarArrayResultados() {\r\n for(var i=1;i<=totalPreguntas;i++) {\r\n resultadoEncuesta[\"p\"+i+\"-alt\"]=[0,0,0,0];\r\n }\r\n}", "function crearniveles() {\n let niveles = [];\n let fila = 0;\n let columna = 0;\n niveles[0] = [];\n for (let c = 1; c < 21; c++) {\n niveles[0][c - 1] =\n {\n tipo: 0,\n fila: fila + 3,\n columna: columna,\n }\n if (c % 10 == 0) {\n fila++;\n columna = 0;\n } else {\n columna++;\n }\n }\n fila = 0;\n columna = 0;\n niveles[1] = [];\n for (let c = 1; c < 41; c++) {\n \tniveles[1][c - 1] =\n {\n \ttipo: 0,\n \tfila: fila + 3,\n \tcolumna: columna,\n }\n \tif (c % 10 == 0) {\n \t\tfila++;\n \t\tcolumna = 0;\n \t} else {\n \t\tcolumna++;\n \t}\n }\n\n return niveles;\n }", "function obtenerVectoresPesos() {\n myArray = inicializarArr(attributesGlobal.length);\n for (var i = 0; i < attributesGlobal.length; i++) { \n my_id = \"arq_tbody_id_\"+(i);\n mv = calcularVectorPesosAPartirDelTbody(document.getElementById(my_id));\n for (var j = 0; j < mv.length; j++) {\n // console.log(mv[j]);\n //w = myArray[j] + mv[j];\n myArray[j].push(mv[j]); \n };\n }\n return myArray;\n}", "function createArray() {\n\tvar temp = [];\n\n\tfor (var i = 1; i <= circles.length; i++) {\n\t\ttemp.push(addColors());\n\t}\n\treturn temp;\n}", "function create2DArr(rows){\n //start an array\n var array = [];\n \n //loop through the array\n for(var i=0;i<rows;i++){\n //put an array in that index\n array[i] = [];\n }\n \n return array;\n}", "function MakeArray(data){\r\n shoesArray=[];\r\n shirtsArray=[];\r\n pantsArray=[];\r\n BigArray=[];\r\n for(i=0;i<data.length;i++){\r\n if(data[i].type=== \"shirts\"){\r\n shirtsArray.push(data[i]);\r\n }\r\n else if(data[i].type=== \"pants\"){\r\n pantsArray.push(data[i]);\r\n }\r\n else{\r\n shoesArray.push(data[i]);\r\n }\r\n }\r\n BigArray.push(shirtsArray);\r\n BigArray.push(pantsArray);\r\n BigArray.push(shoesArray);\r\n }", "function inicializarArr(n){\n var arr = [];\n for (var i = 0; i < n; i++) {\n arr[i] = [];\n }\n return arr;\n}", "function GenArrays() {\n for (let i = 0; i < rows; i++) {\n aGen[i] = new Array(cols);\n pGen[i] = new Array(cols);\n }\n}", "function dividoArray(array, paquetes) {\n var nuevoArray = [];\n for (i = 0; i < array.length; i += paquetes) {\n nuevoArray.push(array.slice([i], i + paquetes));\n }\n return nuevoArray;\n}", "function createArray(){\n\tvar array = [];\n\tfor(var i = 0; i < 20; i++){\n\tarray[i] = i*5;\n\t}\n\treturn(array);\n}", "function arrayObjectsTwo(palavra,num){\r\n var temp=[];\r\n for(var i=1;i<=num;i++){\r\n //temp.push(JSON.parse(`{\"${palavra}\":\"${i}\"}`));\r\n temp.push({[palavra]:[i]})\r\n }\r\n return temp;\r\n}", "function createArray(arr) {\n if (Array.isArray(arr)) {\n var newArr = [];\n var bookName = arr[0];\n var chaps = arr[1];\n var i = -1;\n\n for (i = 1; i <= chaps; i++) {\n newArr.push(bookName + i);\n }\n\n return newArr;\n }\n }", "get listadoArray(){ //Queremos transformar nuestro objeto en arrays para poder presentarlo de mejor manera por consola\n\n const listado=[];\n\n Object.keys(this._listado).forEach(key =>{\n\n const tarea=this._listado[key];\n listado.push(tarea);\n\n \n }); //Esta funcion nos devuelve el array de todas las llaves\n\n\n return listado;\n }", "function pares(platillos) {\r\n\r\n let cont = 1;\r\n let arregloPlatillos = [];\r\n for (let i = 0; i < platillos.length; i++) {\r\n if (cont % 2 == 0) {\r\n arregloPlatillos.push(platillos[i]);\r\n }\r\n cont++;\r\n }\r\n return arregloPlatillos;\r\n}", "function createArray(rows) { //creates a 2 dimensional array of required height\n let arr = [];\n for (let i = 0; i < rows; i++) {\n arr[i] = [];\n }\n return arr;\n }", "function arrayObjects(num){\r\n var temp = [];\r\n for(var i=1;i<=num;i++){\r\n temp.push({valor:i});\r\n }\r\n return temp;\r\n}", "@computed \n get partitionToArray() {\n const numOfRoom = String(this.numOfRoom);\n const numOfLivingroom = String(this.numOfLivingroom);\n const numOfBathroom = String(this.numOfBathroom);\n return [numOfRoom,numOfLivingroom, numOfBathroom];\n }", "function collectortoarray(q,c){\n \n var inpt=[];\n let counter = 0;\n \n c.forEach((value) => {\n inpt[counter]=[q[counter][0],value.content];\n counter++;\n });\n\n console.log(inpt);\n return inpt;\n}", "function construye() {\n let base = [];\n for (let i = 0; i < numCajas; i++) {\n base.push(angular.copy(cajaDefecto));\n }\n return base;\n }", "generateVerticlesArray() {\n // to all laser points starts in that same place\n for (let i = 0; i < this.particlesCount * 3; i += 3) {\n this.verticesArray[i] = this.startPos.x;\n this.verticesArray[i + 1] = this.startPos.y;\n this.verticesArray[i + 2] = this.startPos.z;\n }\n }", "function generaArray() {\n var arrayGenerato = [];\n for (var i = 0; i < 10; i++) {\n var numeroCasuale = Math.floor(Math.random() * 100) + 1;\n arrayGenerato.push(numeroCasuale);\n }\n return arrayGenerato;\n}", "function generarPoblacionInicial(){\n\tarrayAux = new Array(GENES);\n\tfor(i=0;i<POBLACION;i++) {\n\n\t\t//aux con los numeros del 0 al 22\n\t\tfor(j=0;j<GENES;j++) {\n\t\t\tarrayAux[j] = j;\n\t\t}\n\n\t\t//rellenar cromosomas con el aux en orden aleatorio\n\t\tfor(j=0;j<GENES;j++) {\n\t\t\tcromosoma[i][j] = parseInt((arrayAux.splice(Math.floor(Math.random() * arrayAux.length), 1)).join(\"\"));\n\t\t}\n\t}\n}", "function generStartArr(){\n for (var i = 0; i < gI; i++) {\n gStartArr[i]=[];\n for (var j = 0; j < gJ; j++) {\n var el = getElInPos(i,j);\n if (el){\n gStartArr[i][j] = el.type;\n }else{\n if (i===0 || i===gI-1 ||j===0 || j===gJ-1) {\n gStartArr[i][j] = 'W';\n gEls.push({i:i,j:j,type:'W'})\n }else{\n gStartArr[i][j] = 'F';\n }\n }\n }\n }\n //return arr;\n}", "function createArray(array, key){\n\t\tvar callArray = [];//creating a variable which is an empty array\n\n\t\tfor(var i = 0; i < array.length; i++){//using a for loop to loop through the array.\n\t\t\tcallArray.push(array[i][key]);//adding a new element to the array using the push method\n\t\t}\n\t\treturn callArray;//returns the array\n\t}", "function creaArray2D(f, c) { //f = fila, c = columna\r\n var obj = new Array(f);\r\n\r\n for (let i = 0; i < f; i++) {\r\n obj[i] = new Array(c);\r\n }\r\n\r\n return obj;\r\n}", "function arrayMaker(arr) {\n let array = [];\n\n for (let i = 0; i < arr.length; i++) {\n let e = arr[i];\n array[i] = [e.word, e.weight, e.weightPercent, e.freq, e.freqPercent, e.impr, e.imprPercent, e.click, e.clickPercent, e.wordsInPhrase];\n }\n return array;\n}", "arrays(count) {\n let arr = [];\n for (let i=0; i<count; i++) {\n arr.push([]);\n }\n return arr;\n }", "function createArr(res){\r\n\tlet a = [];\r\n\tlet k = _.keys(res[0]);\r\n\ta.push(k)\r\n\tres.forEach(v => {a.push(_.values(v))});\r\n\treturn a;\r\n}", "get listadoArr() { //utilizo un getter para retornar un nuevo arreglo\n\n const listado = []; //este es el arreglo que luego devuelvo con el return\n Object.keys(this._listado).forEach(key => { //El arreglo lo completo con las tareas que carga el usuario\n const tarea = this._listado[key]; //Esta funcion permite retornar todas las llaves que tenga el objeto. Esto crea un arreglo de strings. Con el forEach recorro el array y extraigo cada una de las llaves que estan dentro de _listado. Luego las agrego al array con el .push\n listado.push( tarea )\n\n });\n return listado;\n }", "function mengelompokkanAngka(arr) {\n // you can only write your code here!\n // let genap = []\n let newArr = [[],[],[]]\n // let ganjil = []\n // let kelipatan3 =[]\n for(i=0; i<arr.length; i++) {\n if(arr[i] % 2 == 0 && arr[i] % 3 !== 0) {\n newArr[0].push(arr[i])\n // newArr.push(genap);\n // console.log(genap)\n }\n else if(arr[i] % 2 !== 0 && arr[i] % 3 !== 0) {\n newArr[1].push(arr[i])\n // newArr.push(ganjil)\n // console.log(ganjil)\n }\n else if(arr[i] % 3 == 0) {\n newArr[2].push(arr[i])\n // newArr.push(kelipatan3)\n // console.log(newArr)\n }\n }\n return newArr\n}", "function siguienteGeneracion() {\n let nuevaPoblacion = [];\n for (let i = 0; i < Population.length; i++) {\n let OrderA = TomaUno(Population, fitness);\n let OrderB = TomaUno(Population, fitness);\n let Order = Cruzamos(OrderA, OrderB);\n Mutacion(Order, 0.05);\n nuevaPoblacion[i] = Order;\n }\n\n Population = nuevaPoblacion;\n}", "function createArray(length) {\n for (let x = 0; x < length; x++) {\n mapArr[x] = []\n for (let y = 0; y < length; y++) {\n mapArr[x][y] = getRandArrItem(terrain);\n }\n }\n}", "getToGenerateArray() {\n const self = this;\n let\n iterator, next,\n items = [];\n\n // go over each item in toGenerate\n iterator = self.toGenerate.keys();\n next = iterator.next();\n\n while ( !next.done ) {\n items.push( self.toGenerate.get( next.value ) );\n next = iterator.next();\n }\n\n return items;\n }", "function makeTheArray(col, row){\n arr = new Array(col);\n for(i = 0; i<arr.length;i++){\n arr[i] = new Array(row);\n }\n return arr;\n }", "function make2DArr(cols, rows) {\n let arr = [];\n for(let i = 0; i < cols; i++) {\n arr.push(new Array(rows));\n }\n\n for(let x = 0; x < cols; x++) {\n for(let y = 0; y < rows; y++){\n arr[x][y] = 0;\n }\n }\n\n return arr;\n}", "function lobural() {\n\tfor(var i=0;i<20;i++) {\n\t\tindiceCartas[i] = new Array(20);\n\t\tfor (var j=0;j<20;j++) {\n\t\t\tindiceCartas[i][j] = 0;\n\t\t}\n\t} \n}", "asistencia_persona(equipo){\n let len = equipo.length;\n let asistencias = [];\n\n for (var i = 0; i <len; ++i) {\n let asistencia_persona = equipo[i].asistencia;\n asistencias.push(asistencia_persona);\n \n }\n\n return asistencias;\n }", "function rellenarArray(Arr){\n var line4 = [];\n a = 0;\n var j = 0;\n count = 0;\n media = 0;\n for (var prop_name in Arr) {\n a = parseFloat(prop_name); \n line4.push([a, Arr[prop_name]]) \n if (j==0){\n inicio = a;\n maximo = parseFloat(Arr[prop_name]);\n minimo = parseFloat(Arr[prop_name]);\n j = 1; \n }\n if (parseFloat(Arr[prop_name]) > maximo){maximo = parseFloat(Arr[prop_name])}\n if (parseFloat(Arr[prop_name]) < minimo){minimo = parseFloat(Arr[prop_name])}\n media += parseFloat(Arr[prop_name]);\n count += 1;\n };\n finGra = a;\n media = media/count;\n return line4;\n}", "creatArr(board) {\n //initialize all grids with 0\n for (let i = 0; i < this.boardSize; i++) {\n board[i] = 0;\n }\n //generate two tiles\n this.newTile(board);\n this.newTile(board);\n return board;\n }", "function populateArrayWithValues() {\n for (let i = 0; i < gameSize; i++) {\n let line = [gameSize];\n for (let j = 0; j < gameSize; j++) {\n line[j] = new Cell(i, j, \"\");\n }\n gameField[i] = line;\n }\n}", "function crearArray2D(f,c){\n let obj = new Array(f);\n for(y=0; y<f; y++){\n obj[y] = new Array(c)\n }\n return obj;\n}", "function creaColumnas() {\n for (let i = 0; i < llave; i++) {\n arrColumnas.push(\"\"); \n }\n}", "function arrayCreation (){\n for(var i = 0; i < images.length; i++){\n itemLabels.push(images[i].name);\n itemData.push(images[i].clicked);\n if(i < 5){\n pieLabels.push(images[i].name);\n pieData.push(images[i].calculatePercent());\n }\n }\n}", "function createGrid(rows) { \n var arr = [];\n for (var i = 0; i < rows; i++) {\n arr[i] = [];\n }\n return arr;\n}", "get listadoArr () {\n const listadoArreglado = [];\n Object.keys(this._listado).forEach( key => {\n const tarea = this._listado[key];\n listadoArreglado.push(tarea);\n });\n return listadoArreglado;\n }", "function mostrarCurvas(){\n\tvar index = -1;\n\tvar arr = [];\n\tpontosAtuais.forEach(a => arr.push(a));\n\tguardarPontos();\n\tallPoints.forEach(function(conj){\n\t\tvar l = true;\n\t\tfor(let i = 0; i < conj.length; i++){\n\t\t\tif(conj[i] != pontosAtuais[i]){\n\t\t\t\tl = false;\n\t\t\t}\n\t\t\tarr.push(conj[i]);\n\t\t}\n\t\t//console.log(conj.length);\n\t\tif(l && conj.length > 0){\n\t\t\tconsole.log(\"entrou \" + allPoints.length);\n\t\t\tif(allPoints.length > 1){\n\t\t\t\tvar index = allPoints.indexOf(conj);\n\t\t\t\tconsole.log(allPoints);\n\t\t\t\tarr_curvas[index] = p_curvas;\n\t\t\t\tconsole.log(arr_curvas);\n\t\t\t}else{\n\t\t\t\tconsole.log(arr_curvas);\n\t\t\t\tarr_curvas[0] = p_curvas;\n\t\t\t}\n\t\t}else if(conj.length == 0 && arr_curvas.length == 0){\n\t\t\t//console.log(\"aaa\");\n\t\t\tarr_curvas.push(p_curvas);\n\t\t}\n\t});\n\tarr_curvas.forEach(a => a.forEach(b => arr.push(b)));\n\tstage.children(arr);\n}", "get listadoArray() {\n\t\tconst listado = [];\n\n\t\tObject.keys(this._listado).forEach((key) => {\n\t\t\tconst tarea = this._listado[key];\n\t\t\tlistado.push(tarea);\n\t\t});\n\n\t\treturn listado;\n\t}", "function createCoordsArray() {\n var coords = [];\n for (var i = 0; i < gBoard.length; i++) {\n for (var j = 0; j < gBoard[0].length; j++) {\n var coord = {i, j};\n coords.push(coord);\n }\n }\n return coords;\n}", "function createArray(first) {\n\t\tif (!first) {\n\t\t\treturn this.emptyArray.slice();\n\t\t} else {\n\t\t\tvar array = this.emptyArray.slice();\n\t\t\tarray[0] = first;\n\t\t\treturn array;\n\t\t}\n\t}", "createGrid() {\n let workingArray = [];\n for (let i = 0; i < this.cols; i++) {\n workingArray.push([]);\n for (let j = 0; j < this.rows; j++) {\n workingArray[i].push(false);\n }\n }\n return workingArray;\n }", "function pushResultsToArrays() {\n for(var i = 0; i < Product.allProducts.length; i++) {\n totalClicksArr.push(Product.allProducts[i].totalClicks);\n }\n for(var j = 0; j < Product.allProducts.length; j++) {\n allProductNames.push(Product.allProducts[j].stringName);\n }\n for(var k = 0; k < Product.allProducts.length; k++) {\n productBgColors.push(Product.allProducts[k].backgroundColor);\n }\n for(var l = 0; l < Product.allProducts.length; l++) {\n timesShownArr.push(Product.allProducts[l].timesShown);\n }\n}", "distribution(n: number): RandomArray {\n let paretoArray: RandomArray = [],\n random: RandomArray = (prng.random(n): any);\n for(let i: number = 0; i < n; i += 1){\n paretoArray[i] = this._random(random[i]);\n }\n return paretoArray;\n }", "function newPeopleArray(array){\n for (var i = 0; i < array.length; i++) {\n personArray.push(array[i]);\n }\n}", "function MiaFunzione (array, a, b) {\n var arrayNuovo = [];\n for (i = a; i < b; i++) {\n arrayNuovo.push(array[i]);\n }\n return arrayNuovo;\n}", "function arrayCreate(array, size) {\n var result = [];\n array.forEach(function iter(parts) {\n return function (v) {\n var temp = parts.concat(v);\n if (parts.includes(v)) {\n return;\n }\n if (temp.length === size) {\n result.push(temp);\n return;\n }\n array.forEach(iter(temp));\n }\n }([]));\n return result;\n}", "asArray() {\n const result = new Array();\n this.toArray(result, 0);\n return result;\n }", "function createCellsArray() {\r\n\r\n var arr = [];\r\n\r\n for (var x = 0; x < size; x++) {\r\n\r\n arr[x] = [];\r\n\r\n for (var y = 0; y < size; y++) {\r\n arr[x][y] = new Cell(x, y);\r\n }\r\n }\r\n cellsArray = arr;\r\n }", "function PrioArray() {\n this.reset();\n}", "function newArray() {\n const arrayLength = Math.round(Math.random() * 100);\n let array = [];\n for (let i = 0; i < arrayLength; i++) {\n array[i] = Math.random();\n }\n return array;\n}", "function create2dArray(x) {\r\n var arr = new Array;\r\n for (var i=0;i<x;i++) {\r\n arr[i] = new Array;\r\n }\r\n \r\n return arr;\r\n}", "function CreateMapArray() {\n\tgridArr = [];\n\tfor(i=0; i<100; i++) {\n\t\tgridArr.push({open: 0, room: \"\", explored: 0, sDoor: 0, pathValue: 0, encounter: \"\", nonPC: \"\", loot: [], trapType: \"\", trapState: 0, notes: \"\"});\n\n\t}\n}", "makeBoard() {\r\n const a = new Array(this.m).fill(null).map(()=>new Array(this.n).fill(null));\r\n for (let numS in this.placing) {\r\n let [di, dj] = this.placing[numS].dir;\r\n let [i, j] = this.placing[numS].place;\r\n for (let c of numS) {\r\n if (a[i][j]===null) a[i][j] = [];\r\n a[i][j].push(c);\r\n i += di;\r\n j += dj;\r\n }\r\n }\r\n return a;\r\n }", "function randPosisi(data, par) {\n var randomPos = new Array();\n for (var i = 0; i < par; i++) {\n randomPos[i] = [];\n for (var j = 0; j < data.length; j++) {\n randomPos[i][j] = Math.random();\n }\n }\n return randomPos;\n}", "function Create2DArray(n) {\n\t var arr = [];\n\t for (var i=0;i<n;i++) {\n\t arr[i] = new Array(n);\n\t for (var j=0;j<n;j++) {\n\t\t arr[i][j] = [];\n\t\t }\n\t }\n\n\t return arr;\n\t}", "function makeArray(n){\n var x = new Array(n);\n // x = [];\n for (var i = 0; i < x.length; i++) {\n x[i] = new Array(n);\n \n }\n for (var i = 0; i < x.length; i++) {\n for (var j = 0; j < x.length; j++) {\n x[i][j] =0;\n } \n }\n \n\n console.log(x);\n}", "function fill() {\n var array = []\n for (var i = 0; i < boardSize; i++) {\n for (var j = 0; j < boardSize; j++) {\n array[i * boardSize + j] = {\n color: i + 1,\n alive: true,\n delay: 0\n }\n }\n }\n\n return array\n }", "function prep(size, essence){\n\tvar construct = new Array(size);\n\tfor(iter = 0; iter < size; iter++){\n\t\tconstruct[iter] = essence;\n\t}//end for array\n\tconsole.log(construct);\n\treturn construct;\n}//end prep allocation", "function createEmptyArray(){\n let arr=[];\n for (let i=0; i<10; i++){\n row=[];\n for (let j=0; j<10; j++){\n row.push(0); \n }\n arr.push(row); \n }\n return arr;\n}", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function array2d(rows) {\n\t\t\tvar array = [];\n\t\t\tfor (var i = 0; i < rows; i++) {\n\t\t\t\tarray[i] = [];\n\t\t\t}\n\t\t\treturn array;\n\t\t}", "function generarTeclas(niveles){\n //.fill(valor) nos sirve para rellenar el array de valores que luego el .map reemplazará\n return new Array(niveles).fill(0).map(generarTeclaAleatoria)\n }", "function makeArray(l) {\n var a = new Array(l + 2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(d1, d2) {\n var arr = new Array(d1), i, l;\n for(i = 0, l = d2; i < l; i++) {\n arr[i] = new Array(d1);\n }\n return arr;\n }", "function crearSolicitudes() {\n var arraySolicitudes = [];\n for (var i = 1; i <= 104; i++) {\n arraySolicitudes.push(crearSolicitud(i));\n }\n return arraySolicitudes;\n }", "function Create2DArray(rows) {\r\n var arr = [];\r\n for (var i=0;i<rows;i++) {\r\n arr[i] = [];\r\n }\r\n return arr;\r\n}", "toArray() {\n return [this.x, this.y, this.z]\n }", "function createGoalArray(level) {\n if (level == 1) {\n goalArray = [\n [4, 1],\n [1, 3],\n [3, 6],\n [6, 4]\n ];\n } else if (level == 2) {\n goalArray = [\n [3, 7],\n [4, 7],\n [5, 7]\n ];\n }\n}", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function makeArray(l) {\n var a = new Array(l+2);\n a[0] = a[1] = 0;\n return a;\n }", "function buildToonArray()\n {\n toons.push(mickeyObj);\n toons.push(donaldObj);\n toons.push(goofyObj);\n toons.push(peteObj);\n }", "function pedidosComExtras(pedidos) {\n var array1 = []\n for (let index = 0; index < pedidos.length; index++) {\n //console.log(pedidos[index].pedidoConcreto.length) //para debug\n for (let i = 0; i < pedidos[index].pedidoConcreto.length; i++) {\n //console.log(pedidos[index].pedidoConcreto[i]) //para debug\n //console.log(Object.keys(pedidos[index].pedidoConcreto[i]).length) //para debug\n if (Object.keys(pedidos[index].pedidoConcreto[i]).length > 1) {\n array1.push(pedidos[index].id);\n break\n }\n }\n }return array1\n}" ]
[ "0.6856106", "0.6682753", "0.6621137", "0.6497848", "0.6456618", "0.64493555", "0.6391941", "0.6388621", "0.62940025", "0.62698966", "0.6255932", "0.6253484", "0.6247512", "0.6198426", "0.61660445", "0.61577266", "0.61558557", "0.61294526", "0.61233866", "0.61194706", "0.60789794", "0.6065232", "0.6051455", "0.60343295", "0.6031485", "0.6004972", "0.59928155", "0.5986128", "0.5945495", "0.5934165", "0.5906805", "0.59057534", "0.5898888", "0.58889484", "0.5885773", "0.5882927", "0.5877725", "0.5876866", "0.5872948", "0.58699", "0.58698165", "0.58514374", "0.5845923", "0.58421725", "0.58416754", "0.58249575", "0.5812981", "0.58089775", "0.5798838", "0.5779999", "0.5778479", "0.5778062", "0.57773113", "0.5770256", "0.5768363", "0.57645094", "0.57645077", "0.5764242", "0.5763454", "0.5760524", "0.5760422", "0.57545674", "0.57539266", "0.5750988", "0.5750203", "0.5748594", "0.5745727", "0.5743305", "0.57381475", "0.5735827", "0.57346", "0.572686", "0.57248604", "0.5720118", "0.57164437", "0.5715399", "0.57127035", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.5709145", "0.57081753", "0.57036066" ]
0.0
-1
end of key press control custom way to get id of a element
function $id(id) { return document.getElementById(id); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function btnDown(){\r\n\tlastBtn = this.id;\r\n\trokupost(\"keydown\",this.id);\r\n}", "handleKeyDown(kCode) {\n console.log(\"handleKeyDown \" + this.id + \" \" + kCode)\n }", "get keyIdInput() {\n return this._keyId;\n }", "function showSavedLetter(){\n var index = event.target.id[6];\n alert(saved_letters[index-1]);\n}", "function _getEventID(element) {\n if (element._xuiEventID) return element._xuiEventID;\n return element._xuiEventID = ++_getEventID.id;\n}", "function _getEventID(element) {\n if (element._xuiEventID) return element._xuiEventID;\n return element._xuiEventID = ++_getEventID.id;\n}", "function _getEventID(element) {\n if (element._xuiEventID) return element._xuiEventID;\n return element._xuiEventID = ++_getEventID.id;\n}", "function keydownEvent(e) {\n var key = e.which || e.keyCode;\n let idx;\n currElement = e.target;\n if (key == 8) {\n let div = currElement.parentNode;\n let note = div.getElementsByClassName('note')[0].innerText;\n if (note == '' || note == null) {\n div_id = div.id;\n if (div_id.includes('-')) {\n idx = div_id.split('-').length;\n } else {\n idx = 1;\n }\n if (idx == 2) {\n let newId = div_id.split('-')[1];\n document.getElementById(div_id).setAttribute('class', 'note1');\n document.getElementById(div_id).setAttribute('id', newId);\n }\n if (idx == 3) {\n let newId = ''.concat(\n div_id.split('-')[0],\n '-',\n div_id.split('-')[2],\n );\n document.getElementById(div_id).setAttribute('class', 'note2');\n document.getElementById(div_id).setAttribute('id', newId);\n }\n if (idx == 1) {\n removedivbyid(e.target.id);\n }\n }\n }\n }", "function handleButtonPress(e) {\n // console.log(clic_id);\n console.log(e.target.id);\n}", "function _(e) {return document.getElementById(e)}", "function getIdFromBox() {\r\n\t\tconsole.log(\"clicked\");\r\n\t\tdisplayEvents(this.id);\r\n\t}", "function getId(ele){\t// store the id value\r\n id_value = ele.id; \r\n}", "onElementKeyUp(event) {}", "onElementKeyUp(event) {}", "getAnsBtnID(){\n let choise = event.srcElement.id\n this.answer(choise)\n }", "function handleID() {\n \tconst id = IDRef.current.value\n\tif (id === '') return\n\tsetID(prevID => {\n\t\treturn [id]\n\t})\n\tIDRef.current.value = null\n }", "function getItemId()\r\n {\r\n var element =document.getElementById(\"Label12\");\r\n var item_id=0;\r\n item_id = element.textContent;\r\n return item_id;\r\n }", "function getItemId()\r\n {\r\n var element =document.getElementById(\"Label12\");\r\n var item_id=0;\r\n item_id = element.textContent;\r\n return item_id;\r\n }", "function getItemId()\r\n {\r\n var element =document.getElementById(\"Label12\");\r\n var item_id=0;\r\n item_id = element.textContent;\r\n return item_id;\r\n }", "function getItemId()\r\n {\r\n var element =document.getElementById(\"Label12\");\r\n var item_id=0;\r\n item_id = element.textContent;\r\n return item_id;\r\n }", "function getItemId()\r\n {\r\n var element =document.getElementById(\"Label12\");\r\n var item_id=0;\r\n item_id = element.textContent;\r\n return item_id;\r\n }", "function getItemId()\r\n {\r\n var element =document.getElementById(\"Label12\");\r\n var item_id=0;\r\n item_id = element.textContent;\r\n return item_id;\r\n }", "function getItemId()\r\n {\r\n var element =document.getElementById(\"Label12\");\r\n var item_id=0;\r\n item_id = element.textContent;\r\n return item_id;\r\n }", "addEscAwayEvent(id) {\n // pressing esc key will close panel.\n $(document).on('keyup.atkPanel', atk.createDebouncedFx((evt) => {\n if (evt.keyCode === 27) {\n this.closePanel(id);\n }\n }, 100));\n }", "function getKeyCodeWidget(e) {\n\tvar key = e ? e.which : window.event.keyCode;\t\n\treturn key;\n}", "function setKey(elem){\n keyID = elem.id;\n randomTPain();\n keyText(keyID, isMaj);\n}", "function lastCharInId(strTdTag)\n{\n\tvar strIdTd = strTdTag;\n\tvar intStrLngthIdTd = strIdTd.length;\n\tvar chrLastChrter = strIdTd.substring(intStrLngthIdTd, intStrLngthIdTd - 1);\n\t/* return last character in objects id value */\n\treturn chrLastChrter;\n}", "function enterBtn(id){\n $(document).keyup(function(e){\n if(e.keyCode == 13){\n $('#'+id).click();\n }\n })\n}", "function key() { }", "function functionKeyOnClick(e) {\r\n\tvar obj = targetElement(e);\r\n\tvar id = obj.id;\r\n\tvar namearray = new Array();\r\n\tidarray = id.split(\"_\");\r\n\tcallFunction(idarray);\r\n}", "getFormId(element) {\n return element.getAttribute(\"id\");\n }", "getFormId(element) {\n return element.getAttribute(\"id\");\n }", "getId() {\n this.currentIndex = this.currentIndex + 1;\n return this.currentIndex;\n }", "function returnId(elementClicked)\r\n{\r\n console.log(elementClicked);\r\n clickedElement = elementClicked;\r\n}", "function getCID($element) {\n var cid = 0;\n var id = $element.attr(\"id\");\n if (id[0] === 'h') {\n cid = parseInt(id.substring(1));\n }\n else {\n cid = parseInt(id);\n }\n return cid;\n}", "function getItemId()\r\n {\r\n var element =document.getElementById(\"Label12\");\r\n var item_id=0;\r\n if(element!=null)\r\n item_id = element.textContent;\r\n return item_id;\r\n }", "function KeyDown(elmt, event, Page){\r\n var Key = event.key;\r\n ///alert(Key);\r\n if(Key === \"Enter\"){\r\n $(elmt).blur();\r\n }else if(Key === \"Escape\"){\r\n $(elmt).val($(elmt).attr(\"OriginalValue\"));\r\n }\r\n}", "function keyReleased() {\n\n}", "function getId(e) {\n return e._private.data.id;\n}", "function igtId() {\n id = $('#igt-instance').attr('igtid');\n return id;\n}", "keyDown(_keycode) {}", "function getItemId() {\r\n var element =document.getElementById(\"Product_main1_Product_top11_Label12\");\r\n var item_id=0;\r\n item_id = element.textContent;\r\n return item_id;\r\n }", "function getIdMain()\n{\n _idMainChar = jisQuery( '.idHolder' ).first().html();\n _idStorage += _idMainChar;\n}", "onElementKeyPress(event) {}", "onElementKeyPress(event) {}", "function cust_KeyDown(evnt) {\n //f_log(evnt.keyCode)\n}", "function btnDown() {\n //dbg(\"mousedown\");\n lastBtn = this.id;\n //add graphical feed back here\n dbg({ keydown: this.id });\n rokupost(\"keydown\", this.id);\n}", "function getItemId()\r\n {\r\n var element =document.getElementById(\"Product_main1_Product_top11_Label12\");\r\n var item_id=0;\r\n item_id = element.textContent;\r\n return item_id;\r\n }", "function getItemId()\r\n {\r\n var element =document.getElementById(\"Product_main1_Product_top11_Label12\");\r\n var item_id=0;\r\n item_id = element.textContent;\r\n return item_id;\r\n }", "function getItemId()\r\n {\r\n var element =document.getElementById(\"Product_main1_Product_top11_Label12\");\r\n var item_id=0;\r\n item_id = element.textContent;\r\n return item_id;\r\n }", "function getItemId()\r\n {\r\n var element =document.getElementById(\"Product_main1_Product_top11_Label12\");\r\n var item_id=0;\r\n item_id = element.textContent;\r\n return item_id;\r\n }", "function getItemId()\r\n {\r\n var element =document.getElementById(\"Product_main1_Product_top11_Label12\");\r\n var item_id=0;\r\n item_id = element.textContent;\r\n return item_id;\r\n }", "function selectNode(event){\n item = $(event.toElement).closest('.literal-sequence, .literal, .capture-group, .charset, .digit, .non-digit, .word, .non-word, .white-space, .non-white-space, .start, .end, .space, .any-character, .word-boundary ');\n\n itemID = item.attr('id');\n }", "function getNeededId(self){\n var manipulator = $(self);\n var neededId = manipulator.attr('id').split('_')[1];//getting unique general value of id\n return neededId;\n}", "function elementListId(){\n $(\".modal-body .form-row\" ).bind('click',function(){ \n // divId =$(\".modal-body .form-row\").attr(\"id\")\n divId ='#'+$(this).attr(\"id\")\n console.log(divId)\n // $(\".modal-body .form-row\" ).unbind('click',function(){})\n });\n\n}", "function key_up(){\n\n\tdrag_manager.active_key=null;\n\n}", "function getKeyPress(id) {\n let changedValue = false;\n let button = document.getElementById(id);\n let oldValue = button.value;\n\n //Changes input value if called\n let changeButtonValue = function(e) {\n button.value = e.key;\n button.innerHTML = e.key;\n changedValue = true;\n }\n\n //Add listener when user click on key change button\n button.addEventListener(\n \"keyup\", \n changeButtonValue\n );\n\n //After 3 seconds, if no input is changed it reverts back to old input\n window.setInterval(function() {\n button.removeEventListener( \n \"keyup\",\n changeButtonValue\n );\n if (changedValue === false) {\n button.value = oldValue;\n button.innerHTML = oldValue;\n }\n }, 3000);\n }", "getBtnID(){\n this.category = event.srcElement.id\n }", "getElementId(){\n return `${this.constructor.elementIdPrefix}${this.identity}`;\n }", "function btnKey(id){\n let previousNumber = document.getElementById('inputPin').value;\n let key = document.getElementById(id).innerHTML;\n document.getElementById('inputPin').value = previousNumber + key;\n}", "endPress () {\n if (this.focusIndex === -1) return;\n this.members[this.length - 1].focus();\n }", "function numberPress() {\n\n if(this.id != \"CE\") {\n $(\"#calculatorScreen\").val($(\"#calculatorScreen\").val() + this.id);\n } else if (this.id ==\"CE\") {\n clearVariables();\n }\n\n}", "function getId(el){\n var id = el.getAttribute('adf-id');\n return id ? id : '-1';\n }", "function edClientIdKeypress(event) {\n var keycode = event.which || event.keycode;\n if (keycode == 13) {\n switchToMainAfterAuth();\n }\n}", "function opdrachttxt() {\n // element id dat je moet gebruiken is: \"opdracht2\"\n\n\n\n\n\n\n}", "function GetID(event) {\n let id;\n try {\n id = (window.opener)? window.opener.curID : curID;\n } catch (error) { id = null; }\n\n while (!id || id === \"\") {\n id = (IsOnTurk())? GetAssignmentId() : prompt('Please enter your mTurk ID:','');\n }\n return id;\n}", "handleControlEndKey() {\n let documentEnd = undefined;\n if (!isNullOrUndefined(this.owner.documentEnd)) {\n documentEnd = this.owner.documentEnd;\n }\n if (!isNullOrUndefined(documentEnd)) {\n this.owner.selection.selectContent(documentEnd, true);\n }\n this.checkForCursorVisibility();\n }", "function fun_getID(componente){ \n id_imagem = componente.target.id;\n}", "get id() { return this._chipInput.id; }", "get inputId() {\n return this.getAttribute(\"inputId\");\n }", "function getNewTextId(elem) {\n return elem.getAttribute(\"data-for\");\n }", "function getElementNewID(el) {\n var elID = el.id;\n if (!elID) {\n alert(\"Every elemet should have a unique id to use function getElementNewID()\");\n return false;\n }\n var splitID = elID.split('_');\n var index = 1;\n var newIndex = 1;\n var newID = \"\";\n if (splitID.length > 1) {\n index = splitID.length - 1;\n newIndex = Number(splitID[index]) + 1;\n splitID.pop();\n newID = splitID.join(\"\") + \"_\" + newIndex;\n } else {\n newID = elID + \"_\" + index;\n }\n return newID;\n }", "function end_input(evt) {\n\t//if the key released is the same as the one used to start moving\n\n\tif (keyPressed == evt.keyCode) {\n\t\t//clear the stored key press\n\t\tkeyPressed = -1;\n\t}\n}", "function mapKeyGo() {\n $('.map_buttons').change(function() {\n id = $(this).val();\n $(id).click()\n });\n }", "function getEleId(input) {\n return document.getElementById(input);\n}", "function inputKeyUp(e)\n {\n $(this).change();\n if(e.keyCode == 13) // Return Key\n {\n var newNum = parseInt($(this).data('num')) + 1;\n $('.game-cell-input[data-num=\"' + newNum + '\"]').first().focus();\n }\n }", "function getKey() {\n //return;\n var kc = event.keyCode;\n var elm = event.srcElement;\n var nrsrc;\n var nhre;\n var eid = elm.id;\n //nrsrc = parseInt(eid.substring(4, eid.indexOf('hre')));\n // nhre = parseInt(eid.substr(eid.indexOf('hre') + 3));\n\n switch (kc) {\n case 36: //home \n // document.all.item('rsrc0hre0').focus();\n break;\n case 35: //end \n // document.all.item('rsrc' + (endRsrc - 1) + 'hre' + hrArray[hrArray.length]).focus();\n break;\n case 33: //page up\n //if (nrsrc > 15) {\n // // document.all.item('rsrc' + (nrsrc - 15) + 'hre' + nhre).focus();\n //} else {\n // // document.all.item('rsrc0' + 'hre' + nhre).focus();\n //}\n break;\n case 34: //page down\n //if (nrsrc < (endRsrc - 15)) {\n // // document.all.item('rsrc' + (nrsrc + 15) + 'hre' + nhre).focus();\n //} else {\n // // document.all.item('rsrc' + (endRsrc - 1) + 'hre' + nhre).focus();\n //}\n break;\n case 13: //return\n //if (nhre < hrArray.length) {\n // document.all.item('rsrc' + nrsrc + 'hre' + (nhre + 1)).focus();\n //} else {\n elm.blur();\n elm.select();\n //}\n break;\n case 37: //left arrow\n //if (nhre > 0) {\n // //document.all.item('rsrc' + nrsrc + 'hre' + (nhre - 1)).focus();\n //}\n break;\n case 38: //up arrow\n //if (nrsrc > 0) {\n // //document.all.item('rsrc' + (nrsrc - 1) + 'hre' + nhre).focus();\n //}\n break;\n case 39: //right arrow\n //if (nhre < hrArray.length) {\n // //document.all.item('rsrc' + nrsrc + 'hre' + (nhre + 1)).focus();\n //}\n break;\n case 40: //down arrow\n //if (nrsrc < (endRsrc - 1)) {\n // //document.all.item('rsrc' + (nrsrc + 1) + 'hre' + nhre).focus();\n //}\n break;\n }\n\n}", "function GetControlID(inputID)\n{\n var arrParts = inputID.split('_');\n return arrParts[arrParts.length - 1]; \n}", "function keyPressed() {\n if (handler.active === handler.nameplate) {\n doorbell.keyPressed();\n }\n}", "getKeyControlDown() {\nreturn this._keyControlDown;\n}", "function keyListener(e) {\n // check which element fired the function\n let number = null;\n if($(e.target).is('button')) {\n number = $(e.target).html();\n } else {\n number = e.key;\n }\n\n if ((playing || messing) && visuals[number]) {\n const key = visuals[number];\n const skey = number;\n visualise(key);\n userSequence.push(parseInt(number));\n $numberDisplay.removeClass('hiddener');\n $numberDisplay.html(skey);\n setTimeout(hideKey, 500);\n compareArrays();\n }\n }", "function escapeKeyAndHideElement(e,element) {\n\t\t\tif (e.which == \"27\")\n\t\t\t\t$(element).addClass(\"hide\");\n\t\t}", "get id() {\n return new ElementAttribute(this.get(0), \"id\");\n }", "get id() {\n return new ElementAttribute(this.get(0), \"id\");\n }", "function onKeyDown(ev){var isEscape=ev.keyCode===$mdConstant.KEY_CODE.ESCAPE;return isEscape?close(ev):$q.when(true);}", "function onKeyEsc() {\n ctrl.blur();\n }", "function getKey() {\n //return;\n var kc = event.keyCode;\n var elm = event.srcElement;\n var nrsrc;\n var nhre;\n var eid = elm.id;\n //nrsrc = parseInt(eid.substring(4, eid.indexOf('hre')));\n // nhre = parseInt(eid.substr(eid.indexOf('hre') + 3));\n\n switch (kc) {\n case 36: //home \n // document.all.item('rsrc0hre0').focus();\n break;\n case 35: //end \n // document.all.item('rsrc' + (endRsrc - 1) + 'hre' + hrArray[hrArray.length]).focus();\n break;\n case 33: //page up\n //if (nrsrc > 15) {\n // // document.all.item('rsrc' + (nrsrc - 15) + 'hre' + nhre).focus();\n //} else {\n // // document.all.item('rsrc0' + 'hre' + nhre).focus();\n //}\n break;\n case 34: //page down\n //if (nrsrc < (endRsrc - 15)) {\n // // document.all.item('rsrc' + (nrsrc + 15) + 'hre' + nhre).focus();\n //} else {\n // // document.all.item('rsrc' + (endRsrc - 1) + 'hre' + nhre).focus();\n //}\n break;\n case 13: //return\n //if (nhre < hrArray.length) {\n // document.all.item('rsrc' + nrsrc + 'hre' + (nhre + 1)).focus();\n //} else {\n elm.blur();\n elm.select();\n //}\n break;\n case 37: //left arrow\n //if (nhre > 0) {\n // //document.all.item('rsrc' + nrsrc + 'hre' + (nhre - 1)).focus();\n //}\n break;\n case 38: //up arrow\n //if (nrsrc > 0) {\n // //document.all.item('rsrc' + (nrsrc - 1) + 'hre' + nhre).focus();\n //}\n break;\n case 39: //right arrow\n //if (nhre < hrArray.length) {\n // //document.all.item('rsrc' + nrsrc + 'hre' + (nhre + 1)).focus();\n //}\n break;\n case 40: //down arrow\n //if (nrsrc < (endRsrc - 1)) {\n // //document.all.item('rsrc' + (nrsrc + 1) + 'hre' + nhre).focus();\n //}\n break;\n }\n}", "function proximoInput(id, evento) {\n\n if(evento.keyCode == 13) {\n document.getElementById(id). focus()\n }\n}", "function putkey(element,pkey) {\n if (element.setSelectionRange){\n var start = element.selectionStart;\n var end = element.selectionEnd;\n if (is_chrome) {\n start = selectionStart;\n end = selectionEnd;\n }\n element.value = element.value.substring(0,start) + pkey + element.value.substring(end,element.value.length);\n\n start++;\n if (is_chrome) {\n selectionStart = start;\n selectionEnd = start;\n }\n\n\telement.selectionStart = start;\n element.selectionEnd = start;\n\n }\n else if (document.selection && document.selection.createRange) {\n element.focus();\n var range = document.selection.createRange();\n range.text = pkey;\n\trange.collapse(false);\n range.select();\n }\n}", "keyUp(_keycode) {}", "function id(el){\n return document.getElementById(el);\n}", "function getIndex(cardEl) {\n return (cardEl.attr(\"id\").split(\"-\"))[1];\n }", "function keyDownHandler (e){\r\n\tif (!box.close){\r\n\t\tif (e.keyCode === 32){\r\n\t\t\tcounter++;\r\n\t\t\tdrawBox();\r\n\t\t}\r\n\t} \r\n}", "function keydown(event){switch(event.keyCode){case $mdConstant.KEY_CODE.LEFT_ARROW:event.preventDefault();incrementIndex(-1,true);break;case $mdConstant.KEY_CODE.RIGHT_ARROW:event.preventDefault();incrementIndex(1,true);break;case $mdConstant.KEY_CODE.SPACE:case $mdConstant.KEY_CODE.ENTER:event.preventDefault();if(!locked)select(ctrl.focusIndex);break;}ctrl.lastClick=false;}", "function getId() {\n\t return ++lastId;\n\t }", "function getId() {\n\t return ++lastId;\n\t }", "function getId() {\n\t return ++lastId;\n\t }", "handleControlDownKey() {\n this.moveToNextParagraph();\n this.checkForCursorVisibility();\n }", "get keyInput() {\n return this._key;\n }", "function getId() {\n return ++lastId;\n }", "function elementId(id){\n const inputId = document.getElementById(id);\n return inputId;\n}" ]
[ "0.6286585", "0.62302446", "0.60026014", "0.58470315", "0.580719", "0.580719", "0.580719", "0.5782618", "0.575299", "0.56821084", "0.5671124", "0.56492555", "0.56473863", "0.56473863", "0.56405747", "0.5626527", "0.5625179", "0.5625179", "0.5625179", "0.5625179", "0.5625179", "0.5625179", "0.5625179", "0.5618067", "0.5617825", "0.56002176", "0.559949", "0.5592294", "0.5583541", "0.5577899", "0.557343", "0.557343", "0.5570355", "0.5566327", "0.5564417", "0.556357", "0.5547788", "0.55375516", "0.5534133", "0.55329627", "0.5524944", "0.55243397", "0.5517406", "0.5511196", "0.5511196", "0.5497665", "0.5492598", "0.5491852", "0.5491852", "0.5491852", "0.5491852", "0.5491852", "0.5484134", "0.5478809", "0.54781854", "0.5472785", "0.5449813", "0.5379881", "0.5366668", "0.53634953", "0.53628063", "0.53504735", "0.5338281", "0.53252864", "0.5324471", "0.53240204", "0.53193414", "0.5316981", "0.5314871", "0.53148305", "0.53060186", "0.53058124", "0.5299137", "0.52922136", "0.5283573", "0.5269257", "0.5259843", "0.5256527", "0.5256446", "0.5253993", "0.5242229", "0.52417827", "0.5241074", "0.5241074", "0.5239014", "0.52381164", "0.5236201", "0.52359253", "0.5225689", "0.5222035", "0.5217156", "0.52152807", "0.5213022", "0.5201469", "0.5195714", "0.5195714", "0.5195714", "0.519537", "0.5180655", "0.51750034", "0.5169197" ]
0.0
-1
End of ajax handles the selecting and loading the quadrants,locations and activity content
function locload(quad) { var loc=document.getElementById("loc"); if(document.getElementById("quadrant").value!="null") loc.disabled=false; else loc.disabled=true; loc.options.length=1; for(var i=0;i<quad.length;i++) loc.options[loc.options.length]= new Option(quad[i][0], quad[i][3], false, false); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function _finishedLoading() {\n if ( that.lastFunction ){\n that.lastFunction();\n that.lastFunction = false;\n }\n that.ajaxBusy = false;\n\n // make sure the search menu is completed in error cases\n if ( that.currentControl === \"SEARCH_COLUMN\" && that.searchMenuCallback ) {\n that.searchMenuCallback( false );\n that.searchMenuCallback = null;\n that.searchMenu = null;\n }\n } // _finishedLoading", "function findLocationEntitiesonLoad() {\n\t\t\t\tvar data_client_id = $(\"select.filter-action-type\").attr(\"data-client-id\");\t\n\t\t\t\tvar me = $(\"select.filter-action-type, input.filter-action-type\");\n\t\t\t\tvar selectLocation = $(\"select.filter-avatar-id\");\n\t\t\t\tvar selectSpecialty = $(\"select.filter-speciality-id\")\n\t\t\t\tvar multipleSpecilatyList = $(\"select.filter-speciality-id\").select2('val');\n\t\t\t\tvar multipleLocationList = $(\"select.filter-avatar-id\").select2('val');\n\t\t\t\tvar selectSpecialtyId = selectSpecialty.val();\n\t\t\t\tvar selectLocationId = selectLocation.val();\n\t\t\t\tvar selectedSpecialty = me.val();\n\t\t\t\t\t$.ajax({\n\t\t\t\t\t\turl: SocialView.base_url + 'reports/' + data_client_id + '/dom_request/getLocationList',\n\t\t\t\t\t\tdata: {\n\t\t\t\t\t\t\tselectedSpecialty: selectedSpecialty,\n\t\t\t\t\t\t\treport_id:SocialView.report_id\n\t\t\t\t\t\t},\n\t\t\t\t\t\tbeforeSend: function(xhr) {\n\t\t\t\t\t\t\tCustom.showLoader();\n\t\t\t\t\t\t},\n\t\t\t\t\t\ttype: \"GET\",\n\t\t\t\t\t\ttimeout: 100000,\n\t\t\t\t\t\terror: function(error) {\n\t\t\t\t\t\t\tvar messages = [];\n\t\t\t\t\t\t\tmessages.push('Please try after sometime.');\n\t\t\t\t\t\t\tCustom.showMessages('error', 'Something went wrong!', messages);\n\t\t\t\t\t\t\tCustom.hideLoader();\n\t\t\t\t\t\t}\n\t\t\t\t\t}).done(function(data) {\n\t\t\t\t\t\tselectLocation.find('option').remove().end();\n\t\t\t\t\t\tif (data.length > 0) {\n\t\t\t\t\t\t\t$(data).each(function(k,location) {\n\t\t\t\t\t\t\t\tselectLocation.append($(\"<option>\").attr('value', location.val).text(location.text));\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t$('select.filter-avatar-id option').each(function(){\n\t\t\t\t\t\t\t\tvar selLoc = $(this).val();\n\t\t\t\t\t\t\t\tvar selOption = $(this);\n\t\t\t\t\t\t\t\t$.each(multipleLocationList, function(i, item) {\n\t\t\t\t\t\t\t\t\tif(item == selLoc ){\n\t\t\t\t\t\t\t\t\t\tselOption.attr(\"selected\",'selected');\n\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\tselectLocation.select2({allowClear : true});\n\t\t\t\t\t\tCustom.hideLoader();\n\t\t\t\t\t});\n\t\t\t\t\t// remove selected specialty from the list\n\t\t\t\t\t$.ajax({\n\t\t\t\t\t\turl: SocialView.base_url + 'reports/' + data_client_id + '/dom_request/removeSpecialty',\n\t\t\t\t\t\tdata: {\n\t\t\t\t\t\t\tselectedSpecialty: selectedSpecialty\n\t\t\t\t\t\t},\n\t\t\t\t\t\tbeforeSend: function(xhr) {\n\t\t\t\t\t\t\tCustom.showLoader();\n\t\t\t\t\t\t},\n\t\t\t\t\t\ttype: \"GET\",\n\t\t\t\t\t\ttimeout: 100000,\n\t\t\t\t\t\terror: function(error) {\n\t\t\t\t\t\t\tvar messages = [];\n\t\t\t\t\t\t\tmessages.push('Please try after sometime.');\n\t\t\t\t\t\t\tCustom.showMessages('error', 'Something went wrong!', messages);\n\t\t\t\t\t\t\tCustom.hideLoader();\n\t\t\t\t\t\t}\n\t\t\t\t\t}).done(function(data) {\n\t\t\t\t\t\tselectSpecialty.find('option').remove().end();\n\t\t\t\t\t\tif (data.length > 0) {\n\t\t\t\t\t\t\t$(data).each(function(k,speciality) {\n\t\t\t\t\t\t\t\tselectSpecialty.append($(\"<option>\").attr('value', speciality.val).text(speciality.text));\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t$('select.filter-speciality-id option').each(function(){\n\t\t\t\t\t\t\t\tvar selSpe = $(this).val();\n\t\t\t\t\t\t\t\tvar selOption = $(this);\n\t\t\t\t\t\t\t\t$.each(multipleSpecilatyList, function(i, item) {\n\t\t\t\t\t\t\t\t\tif(item == selSpe ){\n\t\t\t\t\t\t\t\t\t\tselOption.attr(\"selected\",'selected');\n\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\tselectSpecialty.select2({allowClear : true});\n\t\t\t\t\t\tCustom.hideLoader();\n\t\t\t\t\t});\n\t\t\t\t}", "function finish(id){\r\n\r\n $.ajax({\r\n type: 'GET',\r\n url: constants.finishURL.replace('{{key}}', plugin.config.apikey).replace('{{searchterm}}', plugin.pcwInput.data('search-text')) + id +'&lines='+plugin.config.addresslines+'&exclude='+plugin.config.exclude+'&identifier='+plugin.config.identifier,\r\n async: false,\r\n jsonpCallback: plugin.config.jsonCallback,\r\n contentType: \"application/json\",\r\n dataType: 'jsonp',\r\n success: function(result) {\r\n\r\n plugin.pcwAddressBrowse.hide();\r\n plugin.pcwAddressSelect.hide();\r\n\r\n if (result.length > 0){\r\n\r\n plugin.config.processAddress(result[0]);\r\n\r\n }else{\r\n\r\n plugin.pcwAddressFinish.html('').html('Not found');\r\n\r\n }\r\n },\r\n error: function(e) {\r\n plugin.pcwAddressFinish.html('').html('Error');\r\n }\r\n });\r\n\r\n\r\n }", "onAfterAjax() {\n }", "function OnFinishLoading()\n {\n //\n //Get the last tr id that was edited or selected\n var last_tr_id = window.localStorage.last_tr_id;\n //\n //Retrieve the last identified tr\n var tr = document.getElementById(last_tr_id);\n //\n //Check if the tr is valid\n if (tr!==null)\n {\n //\n //Select the tr by marking it as the only row with a current\n //attribute\n new Row(tr).select();\n //\n //Href, i.e., move to the identfied tr\n window.location.href=\"#\"+last_tr_id;\n }\n //\n //Set focus to the hint field\n var hint = document.getElementById(\"hint\");\n hint.focus();\n }", "function doneFetch() {\n var sublists = createSublists(candidates);\n\n createStudentGenderChart('.student-gender-chart', sublists['genderList']);\n createStudentEthnicityChart('.student-enthnicty-chart', sublists['ethnicityList']);\n createStudentScoresChart('.student-scores-chart', sublists['satScoresList']);\n createStudentDepartmentsChart('.student-departments-chart', sublists['departmentCandidateList']);\n createDepartmentGenderChart('.department-gender-chart', sublists['departmentGenderList']);\n\n d3.select('.main').style('z-index', '1');\n d3.select('.loading').style('display', 'none');\n }", "function optionRegion(div_id,url,populate)\n{\t\n\tdivResultado = document.getElementById(div_id);\n\tajax=objetoAjax();\n\tajax.open(\"POST\", \"../php/\" +url,true);\n\tajax.onreadystatechange=function()\n\t{\n\t\tif (ajax.readyState==4)\n\t\t{\n\t\t\tdivResultado.innerHTML = ajax.responseText;\n\t\t}\n\t\telse if (ajax.readyState == 1)\n\t\t{\n\t\t\tdivResultado.innerHTML = \"<img src='../images/graphics/waitball.gif' border=0 height='20' width='20'>\";\n\t\t}\n\t}\n\tajax.setRequestHeader(\"Content-Type\",\"application/x-www-form-urlencoded\");\n\tstr_send = getparameters(populate);\n\tajax.send(str_send);\n\t\n\t// Refresh other lists\n\tswitch(populate)\n\t{\n\t\tcase 1:\n\t\t\t// refresh divisions\n\t\t\tif (document.getElementById(\"list_division\"))\n\t\t\t{\n\t\t\t\twhile (document.createitem.clubdivision.length > 1)\n\t\t\t\t{\n\t\t\t\t\tdocument.createitem.clubdivision.remove(document.createitem.clubdivision.length-1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t// refresh groups\n\t\t\tif (document.getElementById(\"list_group\"))\n\t\t\t{\n\t\t\t\twhile (document.createitem.clubgroup.length > 1)\n\t\t\t\t{\n\t\t\t\t\tdocument.createitem.clubgroup.remove(document.createitem.clubgroup.length-1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t// refresh clubs\n\t\t\tif (document.getElementById(\"list_club\"))\n\t\t\t{\n\t\t\t\twhile (document.createitem.club.length > 1)\n\t\t\t\t{\n\t\t\t\t\tdocument.createitem.club.remove(document.createitem.club.length-1);\n\t\t\t\t}\n\t\t\t}\n\t\t\tbreak;\n\t\tcase 2:\n\t\t\t// refresh groups\n\t\t\tif (document.getElementById(\"list_group\"))\n\t\t\t{\n\t\t\t\twhile (document.createitem.clubgroup.length > 1)\n\t\t\t\t{\n\t\t\t\t\tdocument.createitem.clubgroup.remove(document.createitem.clubgroup.length-1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t// refresh clubs\n\t\t\tif (document.getElementById(\"list_club\"))\n\t\t\t{\n\t\t\t\twhile (document.createitem.club.length > 1)\n\t\t\t\t{\n\t\t\t\t\tdocument.createitem.club.remove(document.createitem.club.length-1);\n\t\t\t\t}\n\t\t\t}\n\t\t\tbreak;\n\t\tcase 3:\n\t\t\t// refresh clubs\n\t\t\tif (document.getElementById(\"list_club\"))\n\t\t\t{\n\t\t\t\twhile (document.createitem.club.length > 1)\n\t\t\t\t{\n\t\t\t\t\tdocument.createitem.club.remove(document.createitem.club.length-1);\n\t\t\t\t}\n\t\t\t}\n\t\t\tbreak;\n\t}\n}", "function done() {\n\t\t\t\tdom.remove(id);\n\n\t\t\t\tif (elm) {\n\t\t\t\t\telm.onreadystatechange = elm.onload = elm = null;\n\t\t\t\t}\n\n\t\t\t\tsuccess();\n\t\t\t}", "function asyncAjaxRequestSls(categ){\n //async ajax request\n $(\"document\").ready(function(){\n $.ajax({\n method: \"GET\",\n //dataType: \"json\", //type of data\n crossDomain: true,\n url: basePath + \"db/sql_sls.php\", //Relative or absolute path to file.php file\n data: {categoria:categ},\n success: function(response) {\n //parse the json and get an array\n var arrayRes = $.parseJSON(response);\n handleResult(arrayRes);\n //after the page is filled call the function to set the position of the footer \n placeFooter();\n },\n error: function(request,error)\n {\n console.log(request+\":\"+error);\n }\n });\n });\n}", "static onXhrComplete(e){\n\t\tvar doSave = Downloader.Handlers[this.ActiveItem.type](this.ActiveItem,e.currentTarget.response);\n\t\tif(doSave) Downloader.Complete.push(this.ActiveItem);\n\n\t\tthis.ActiveItem = null;\n\t\tDownloader.loadNext();\n\t}", "function endloading(){\n\t//$(\"#ajaxloading\").fadeOut(1000);\n\t$('.sl-popup:visible .overlay').fadeOut(1000);\n}", "function queryLocations() {\t\t \n\tvar selection = document.getElementById('querySelector');\n\tvar msg = selection.options[selection.selectedIndex].value;\n\t\n $.ajax({\n url: \"query\",\n type: 'POST',\n dataType: 'json',\n data: msg \n }).done(function(resp){\n \tvar cityCircle;\n \tvar circleColor;\n \tvar dataLimit = 8;\n \tqueryResults = resp;\n \t\n \t$(\"#infoScreen\").html(\"\");\n \tfor(var i=0; i<queryResults.length; i++){ \n \t\t// Displays sample of data received in text format\n \t\tif(i<dataLimit){\n\t \t$(\"#infoScreen\").append(i+1 + \". Long: \" + queryResults[i].longitude +\n\t \t\t\t\", Lat: \" + queryResults[i].latitude + \n\t \t\t\t\", State: \" + queryResults[i].state + \"<br>\");\t\n\t \tif(i == (dataLimit-1))\n\t \t\t$(\"#infoScreen\").append(\"...\");\n \t\t}\n \t\n \tif(queryResults[i].state === \"Online\")\n \t\tcircleColor = 'green';\n \telse\n \t\tcircleColor = 'red';\n \t\t\n \t// Draws the location spots on google map\n \tvar populationOptions = {\n \t\t strokeColor: circleColor,\n \t\t strokeOpacity: 0.8,\n \t\t strokeWeight: 2,\n \t\t fillColor: circleColor,\n \t\t fillOpacity: 0.35,\n \t\t map: map,\n \t\t center: new google.maps.LatLng(queryResults[i].latitude, \n \t\t \t\t queryResults[i].longitude),\n \t\t radius: 3\n \t\t };\n \t\t // Add the circle for this city to the map.\n \t\t cityCircle = new google.maps.Circle(populationOptions);\n \t} \t \t\t\n });\n}", "function end() {\n\tshowResult();\n\toutputData.userFinalValue = userCurrentValue;\n\toutputData.marketFinalValue = marketCurrentValue;\n\toutputData.totalTrades = totalTrades;\n\tfinalData = JSON.stringify(outputData);\n\t$.ajax({\n type:'post',\n url: 'echo.py',\n data: {json: finalData},\n });\n}", "function finish(){\n if( settings.onFinish ) {\n settings.onFinish( data );\n }\n }", "function onAllApiDataLoaded() {\n $(\".spinner\").remove();\n }", "function selection() {\n $(\"#start\").hide();\n $(\"#selectionArea\").fadeIn(\"slow\");\n //Get list of all categories and append to the selectionArea\n $.getJSON(\"https://icanhazdadjoke.com/\").done(function(result) {\n dadjoke = result.joke;\n document.getElementById(\"joke2\").innerHTML = dadjoke;\n });\n\n fetch(\"https://opentdb.com/api_category.php\")\n .then(function(response) {\n return response.json();\n })\n .then(function(data) {\n var list = data.trivia_categories;\n list.forEach(function(quiz){\n var categoryList = document.getElementById(\"quizList\");\n var listElement = document.createElement(\"li\");\n var name = document.createTextNode(quiz.name);\n\n listElement.appendChild(name);\n listElement.setAttribute(\"id\", quiz.id);\n listElement.setAttribute(\"class\", \"quiz\");\n categoryList.appendChild(listElement);\n });\n\n //Adding eventListeners to trigger next page\n document.querySelectorAll(\".quiz\").forEach(function(quiz) {\n quiz.addEventListener(\"click\", function() {\n toSpecification(quiz.id);\n });\n });\n })\n .catch(function(error) {\n handleFetchError(error);\n });\n}", "function findLocationEntities() {\n\t\t\t\tvar data_client_id = $(\"select.filter-action-type\").attr(\"data-client-id\");\t\n\t\t\t\tvar me = $(\"select.filter-action-type, input.filter-action-type\");\n\t\t\t\tvar selectLocation = $(\"select.filter-avatar-id\");\n\t\t\t\tvar selectSpecialty = $(\"select.filter-speciality-id\")\n//\t\t\t\tvar multipleSpecilatyList = $(\"select.filter-speciality-id\").select2('val');\n//\t\t\t\tvar multipleLocationList = $(\"select.filter-avatar-id\").select2('val');\n\t\t\t\tvar selectSpecialtyId = selectSpecialty.val();\n\t\t\t\tvar selectLocationId = selectLocation.val();\n\t\t\t\tvar selectedSpecialty = me.val();\n\t\t\t\t\t$.ajax({\n\t\t\t\t\t\turl: SocialView.base_url + 'reports/' + data_client_id + '/dom_request/getLocationList',\n\t\t\t\t\t\tdata: {\n\t\t\t\t\t\t\tselectedSpecialty: selectedSpecialty,\n\t\t\t\t\t\t\treport_id:SocialView.report_id\n\t\t\t\t\t\t},\n\t\t\t\t\t\tbeforeSend: function(xhr) {\n\t\t\t\t\t\t\tCustom.showLoader();\n\t\t\t\t\t\t},\n\t\t\t\t\t\ttype: \"GET\",\n\t\t\t\t\t\ttimeout: 100000,\n\t\t\t\t\t\terror: function(error) {\n\t\t\t\t\t\t\tvar messages = [];\n\t\t\t\t\t\t\tmessages.push('Please try after sometime.');\n\t\t\t\t\t\t\tCustom.showMessages('error', 'Something went wrong!', messages);\n\t\t\t\t\t\t\tCustom.hideLoader();\n\t\t\t\t\t\t}\n\t\t\t\t\t}).done(function(data) {\n\t\t\t\t\t\t\n\t\t\t\t\t\tselectLocation.find('option').remove().end();\n\t\t\t\t\t\tif (data.length > 0) {\n\t\t\t\t\t\t\t$(data).each(function(k,location) {\n\t\t\t\t\t\t\t\tif (selectLocationId != null && selectLocationId == this.val) {\n\t\t\t\t\t\t\t\t\tselectLocation.append($(\"<option selected='selected'>\").attr('value', this.val).text(this.text));\n\t\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\t\tselectLocation.append($(\"<option>\").attr('value', this.val).text(this.text));\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t}\n\t\t\t\t\t\tselectLocation.select2({allowClear : true});\n\t\t\t\t\t\tCustom.hideLoader();\n\t\t\t\t\t});\n\t\t\t\t\t// remove selected specialty from the list\n\t\t\t\t\t$.ajax({\n\t\t\t\t\t\turl: SocialView.base_url + 'reports/' + data_client_id + '/dom_request/removeSpecialty',\n\t\t\t\t\t\tdata: {\n\t\t\t\t\t\t\tselectedSpecialty: selectedSpecialty\n\t\t\t\t\t\t},\n\t\t\t\t\t\tbeforeSend: function(xhr) {\n\t\t\t\t\t\t\tCustom.showLoader();\n\t\t\t\t\t\t},\n\t\t\t\t\t\ttype: \"GET\",\n\t\t\t\t\t\ttimeout: 100000,\n\t\t\t\t\t\terror: function(error) {\n\t\t\t\t\t\t\tvar messages = [];\n\t\t\t\t\t\t\tmessages.push('Please try after sometime.');\n\t\t\t\t\t\t\tCustom.showMessages('error', 'Something went wrong!', messages);\n\t\t\t\t\t\t\tCustom.hideLoader();\n\t\t\t\t\t\t}\n\t\t\t\t\t}).done(function(data) {\n\t\t\t\t\t\tselectSpecialty.find('option').remove().end();\n\t\t\t\t\t\tif (data.length > 0) {\n\t\t\t\t\t\t\t$(data).each(function(k,speciality) {\n\t\t\t\t\t\t\t\tif (selectSpecialtyId != null && selectSpecialtyId == this.val) {\n\t\t\t\t\t\t\t\t\tselectSpecialty.append($(\"<option selected='selected'>\").attr('value', this.val).text(this.text));\n\t\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\t\tselectSpecialty.append($(\"<option>\").attr('value', this.val).text(this.text));\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t}\n\t\t\t\t\t\tselectSpecialty.select2({allowClear : true});\n\t\t\t\t\t\tCustom.hideLoader();\n\t\t\t\t\t});\n\t\t\t\t}", "function _finish() {\r\n // stop all fading and animations\n $.each(['#lightbox-image-details', '#jquery-lightbox', '#jquery-overlay'], function (i, id) {\n $(id).stop(true, true);\n });\n\n window._activeLightBox = null;\r\n _disable_keyboard_navigation();\r\n $('.hover-icon').remove();\r\n $('#lightbox-loading').remove();\r\n $('#jquery-lightbox').remove();\r\n $('#jquery-overlay').remove();\r\n // Show some elements to avoid conflict with overlay in IE. These elements appear above the overlay.\r\n $('embed, object, select').css({ 'visibility' : 'visible' });\r\n }", "function afterLoading(){\n\t\t\tupdatePageInfo();\n\t\t}", "function doneTyping() {\n PagedListSectionApp.makeAjaxCall();\n }", "function _finishLoading() {\n loadsToFinish--;\n if (loadsToFinish <= 0) {\n loading = false;\n viewModel.set(\"loading\", loading);\n }\n}", "complete(jqxhr, textStatus){\r\n \r\n }", "function graphsLoadCompleteHandler(){\n $engine.log('DASHBOARD > LOADER: '+objloadedArr.length + ' / ' + loadCount)\n if(objloadedArr.length == loadCount){\n $engine.toggleViewLoader(false);\n $('.drilldown-button').show();\n loadCount=0;\n objloadedArr.length = null;\n }\n }", "function onRequest2Success(msg){\n \n $('#Results').html(msg);\n $(\"#dialog-message\").dialog( \"destroy\" );\n activateFlightDetails();\n activateSorting();\n activatePagination();\n activateHotelGallery();\n activateFilterBox(); //Yellow box filter\n activateHotelNameDescriptionCall();\n hotelShowMap();\n\n \n \n}", "static showSearchedAppend(){\n const rowlist = document.querySelectorAll('.table-row')\n const id = rowlist[rowlist.length-1].id\n //console.log(id)\n const postItem = {\n sql : window.querry,\n id : id\n }\n $.ajax({\n url:\"AJAX/AJAX.php\",\n method:\"POST\",\n data:{getbyquerryappend:postItem},\n dataType:\"json\",\n success:function(data)\n {\n //console.log(data)\n //document.querySelector('#results').innerHTML=''\n view.renderList(data.data)\n \n //Course.renderBasicCategoriesForUser(data);\n //return data;\n \n },error:function (data){\n //console.log(data)\n }\n });\n }", "function searchgroupsinitiate() {\n\n var keyword = $('#groupkeyword').val();\n var type = $('#grouptype').val();\n $.ajax({\n type: \"POST\",\n dataType: 'json', \n data: {\n 'keyword': keyword,\n 'type': type\n },\n url: BASE_URL + '/group/searchgroups', \n beforeSend: function() {\n $('.searchmygroup').append(\n ' <i class=\"fa fa-spinner fa-spin\"> </i>').css('cursor',\n 'default').addClass(\"disabled\");\n $.dbeePopup('resize');\n },\n complete: function() {\n setTimeout(function() {\n //$('.searchmygroup').attr(\"onclick\",\n //\t\t\"javascript:searchgroupsinitiate();\");\n $('.searchmygroup .fa-spin').remove();\n $('.searchmygroup').css('cursor', 'pointer');\n }, 700);\n }, \n success: function(response) {\n $('.searchmygroup').removeClass(\"disabled\")\n $(\"#content_data\").html(response.content);\n searchgroups(keyword, type);\n // $dbConfirm({content:\"Search completed successfully !\",\n // yes:false});\n setTimeout(function() {\n $.dbeePopup('resize');\n }, 2000);\n },\n error: function(error) {\n $(\"#content_data\").html(\n \"Some problems have occured. Please try again later: \" + error);\n }\n });\n}", "function setFinishSearchHandler(){\n\tvar selectBar2 = document.getElementById(\"triType\");\n\tvar button = document.getElementById(\"finish-search\");\n\tbutton.onclick = function(){\n\t\tif (_checkedTerms.length == 0){\n\t\t\treturn;\n\t\t}\n\t\tshowLoader()\n\t\t$(\"#results\").hide();\n\t\n\t\tvar checkedString = \"Your Intermediary Terms: \";\n\t\tvar csvName = \"\";\n\t\tfor (var i=0; i< _checkedTerms.length; i++){\n\t\t\tcheckedString += _checkedTerms[i] + \", \";\n\t\t\tcsvName += \"_\" + _checkedTerms[i];\n\t\t}\n\t\tcheckedString += \"<br>Your Final Term Type: \" + selectBar2.value;\n\t\t$(\"#selections\").html(checkedString);\n\t\tgetFinalTerms(_checkedTerms, selectBar2.value, csvName);\n\t};\n}", "function handleFinish(_event) {\n cleanup(null, responseData)\n }", "function contentLoading() {\n hide(topSearch);\n hide(clearSearchIcon);\n //show(loadingContentElement);\n show(\".es-progress-indicator\");\n hide(resultsElement);\n hide(articleDisplay);\n }", "function roomChanged() \n{ \nif (xmlHttp.readyState==4)\n{ \ndocument.getElementById(\"spaceSelect\").innerHTML=\"\";\ndocument.getElementById(\"spaceSelect\").innerHTML=xmlHttp.responseText;\n}\n}", "function finishAjax(id, response){\r\n $('#loader').remove();\r\n\r\n $('#'+id).append(unescape(response));\r\n}", "function chooseData() {\n\tcity = $('option[name=cities]:checked').val()\n\t$( change_data_select ).fadeOut(300, function() { $(this).remove(); });\n\t$('body').append( loader );\n\t$('#loader').fadeIn();\n\tgrabDataCity(city);\n}", "function loadGeneRelation(searchWord, searchType ,Type ,Sel){\r\n if (_pWord == searchWord && _pType == searchType&&_selectedType==Type) \r\n return; \r\n _pWord = searchWord;\r\n _pType = searchType;\r\n _selectedType=Type;\r\n $('#result_2 .table_detail').hide();\r\n var id;\r\n if(Type=='show all'){\r\n id='showall';\r\n }else{\r\n id=Type;\r\n } \r\n var l=$('#result_2 #'+id).length;\r\n if(l>0){\r\n $('#result_2 #'+id).show(); \r\n $('#pageIndex').text($('#'+id).attr('index'));\r\n $('#result_2 form,#result_2 .relselect').show();\r\n return;\r\n }\r\n $('#result_2 .relselect,#result_2 form').hide();\r\n $('#result_container .loading').show();\r\n $.ajax({\r\n type:'POST',\r\n url:_geneRelationUrl,\r\n dataType: \"JSON\",\r\n data:{\r\n query: searchWord,\r\n qtype: searchType,\r\n type: Type,\r\n sel: Sel,\r\n m:0,\r\n n:0\r\n } ,\r\n async: false,\r\n success:function(data){\r\n $('#result_container .loading').hide();\r\n $('.relselect').show();\r\n $('#result_container #result_2 form').show();\r\n var tableHtml = '<table class=\"table_detail\" id=\"'+id+'\" border=0 bgcolor=\"white\" cellSpacing=3 cellpadding=5 width=98%>';\r\n tableHtml += '<tbody><tr bgcolor=\"#dde6f3\"><th class=\"sort_th\" align=\"left\" >Gene1_Name</th><th align=\"left\">Gene2_Name</th><th align=\"left\">Network</th><th align=\"left\">Type</th><th align=\"left\">Weight</th></tr>';\r\n if(data.table_list_count > 0){\r\n // $.each(eval('(' + data.table_list_data+ ')'),function(i,e){\r\n $.each(data.table_list_data,function(i,e){\r\n var stream = makeTableItem(i,e);\r\n tableHtml += stream; \r\n });\r\n }\r\n tableHtml+= '</tbody></table>';\r\n $('#result_container #result_2 #table_box').append(tableHtml);\r\n //$('#result_2 #table_box table #'+Type).attr('index', 1);\r\n $('#'+Type).attr('m',data.m);\r\n $('#'+Type).attr('n',data.n);\r\n $('#'+Type).attr('index',1);\r\n $('#pageIndex').text('');\r\n if(data.table_list_count<50){\r\n $('.pageBtn').hide();\r\n }else{\r\n $('.pageBtn').hide();\r\n $('#nextpage').show();\r\n }\r\n }\r\n });\r\n sortTableview('co_expression',1);\r\n setStyle(Type);\r\n}", "function _finish() {\n\t\t\t$('#jquery-largephotobox').remove();\n\t\t\t$('#jquery-overlay').fadeOut(function() { $('#jquery-overlay').remove(); });\n\t\t\t\n\t\t\t// Show some elements to avoid conflict with overlay in IE. These elements appear above the overlay.\n\t\t\t$('embed, object, select').css({ 'visibility' : 'visible' });\n\t\t}", "function getAllCourse() {\n\n $(document).ajaxStart(function () {\n $(\"#wait\").css(\"display\", \"block\");\n });\n $(document).ajaxComplete(function () {\n $(\"#wait\").css(\"display\", \"none\");\n });\n var web_xml_address = \"find-all-course\";\n var format = document.getElementById(\"format\").value;\n var address = web_xml_address + \"?format=\" + format;\n\n switch (format) {\n case \"json\":\n getJSONData(address);\n break;\n case \"text\":\n getTextData(address);\n break;\n case \"xml\":\n getXMlData(address)\n break;\n }\n}", "function familyPostLoad() {\n // structure image\n if( typeof( loadOptions.si.uri ) != \"undefined\" ) {\n new Ajax.Request( loadOptions.si.uri,\n { method: 'get', \n parameters: loadOptions.si.params,\n onSuccess: siSuccess\n // not even bothering with a failure callback...\n } );\n }\n \n // domain graphics\n if( typeof( loadOptions.dg.uri ) != \"undefined\" ) {\n new Ajax.Request( loadOptions.dg.uri,\n { method: 'get', \n parameters: loadOptions.dg.params,\n onSuccess: dgSuccess,\n onFailure: dgFailure\n } );\n }\n\t\n // species tree\n if( typeof( loadOptions.st.uri ) != \"undefined\" ) {\n new Ajax.Request( loadOptions.st.uri,\n { method: 'get', \n parameters: loadOptions.st.params,\n onSuccess: stSuccess,\n onFailure: stFailure\n } );\n }\n\n // alignment tree\n if( typeof( loadOptions.at.uri ) != \"undefined\" ) {\n new Ajax.Request( loadOptions.at.uri,\n { method: 'get', \n parameters: loadOptions.at.params,\n onSuccess: atSuccess,\n onFailure: atFailure\n } );\n }\n // clan structure tab\n if( typeof( loadOptions.fstruc.uri ) != \"undefined\" ) {\n new Ajax.Request( loadOptions.fstruc.uri,\n { method: 'get', \n parameters: loadOptions.fstruc.params,\n onSuccess: fstrucSuccess,\n onFailure: fstrucFailure\n } );\n }\n // coloured alignment\n if( typeof( loadOptions.ca.uri ) != \"undefined\" ) {\n new Ajax.Request( loadOptions.ca.uri,\n { method: 'get', \n parameters: loadOptions.ca.params,\n onSuccess: caSuccess,\n onFailure: caFailure\n } );\n }\n}", "function save_new_subst()\n{\njQuery(\"#ajaxresponse\").html(baseajaxurl);\n jQuery(\"#ajaxresponse\").addClass('ajax-loading');\n \nvar playerin = jQuery(\"#in\").val();\n\t\t\t\tvar playerout = jQuery(\"#out\").val();\n\t\t\t\tvar position = jQuery(\"#project_position_id\").val();\n\t\t\t\tvar time = jQuery(\"#in_out_time\").val();\n\t\t\t\tvar querystring = '&in=' + playerin + '&out=' + playerout\n\t\t\t\t\t\t+ '&project_position_id=' + position + '&in_out_time='\n\t\t\t\t\t\t+ time + '&teamid=' + teamid + '&matchid=' + matchid\n\t\t\t\t\t\t+ '&projecttime=' + projecttime;\n\t\t\t\tvar url = baseajaxurl + '&task=matches.savesubst&tmpl=component';\n //jQuery(\"#ajaxresponse\").html(url + querystring);\n \n jQuery.ajax({\n type: 'POST', // type of request either Get or Post\n url: url + querystring, // Url of the page where to post data and receive response \n //data: data, // data to be post\n dataType:\"json\",\n success: substsaved //function to be called on successful reply from server\n \n}); \n}", "function getCountryRequestJourney(tipo,local,count){\n\n if ($('.'+count).text() == 0){\n addNewJorneyOrRequest() \n setTimeout(function(){ \n if(tipo == 'Journey'){\n $('.animate, .minus-btn').addClass('w3-hide')\n $('#journey_form').show()\n }\n else{\n $('.animate, .minus-btn').addClass('w3-hide')\n $('#request_form').show()\n }\n }, 750)\n }\n\n else {\n\n if(tipo == 'Journey' ){\n url_add = url+'rquest=get'+tipo+'s&country='+count.replace('j_','')\n $('.w3-overlay').show()\n insert=''\n $.ajax({\n url: url_add,\n type:'GET',\n cache:false,\n dataType:'json',\n success: function(data){\n $('.w3-overlay').hide()\n console.log(data)\n if (data.status == 'success' && data.total_record > 0){\n insert = TemplateShowJourneys(data.data,data.rating) \n $.ajax({\n url: tipo+\"_country.html\",\n success:function(html){\n $('#menu-main-page').html(html)\n $('.searched-country').html(local)\n $('.container-journey').html(insert)\n \n for(f=0;f<data.boxes.length;f++){\n $('.journey-box-'+data.boxes[f][0].id).attr('src','img/'+data.boxes[f][0].box)\n $('.journey-letter-'+data.boxes[f][0].id).text(data.boxes[f][0].letter.toUpperCase())\n }\n\n for(j=0;j<data.rating.length;j++)\n $('.user-rating-'+data.rating[j].idcliente_received).text(parseFloat(data.rating[j].rating).toFixed(1))\n\n for(y=0;y<data.level.length;y++){\n $('.user-level-'+data.level[y].user_id).text(data.level[y].level)\n $('.user-level-title-'+data.level[y].user_id).text(data.level[y].level_title)\n $('.user-journeys-'+data.level[y].user_id).text(data.level[y].journeys)\n }\n\n }\n })\n .done(function(){\n setLanguage()\n setTimeout(function(){\n $('.w3-overlay').hide()\n $('#menu-main-page').show()\n }, 100)\n })\n }\n },\n error: function(data){\n $('.w3-overlay').hide()\n $('#info-client').modal()\n $('.info-client-header').html('<span class=\"w3-text-red\"><i class=\"fa fa-exclamation-triangle\"></i> '+json.check+'</span>')\n $('.info-client-txt').html(json.no_wifi)\n }\n })\n }\n\n\n else if(tipo == 'Request'){\n url_add = url+'rquest=get'+tipo+'s&country='+local \n $('.w3-overlay').show()\n insert=''\n $.ajax({\n url: url_add,\n type:'GET',\n cache:false,\n dataType:'json',\n success: function(data){\n console.log(data)\n if (data.status == 'success' && data.total_record > 0){\n insert = TemplateShowRequests(data.data,data.rating) \n $.ajax({\n url: tipo+\"_country.html\",\n success:function(html){\n $('#menu-main-page').html(html)\n $('.searched-country').html(local)\n $('.container-request').html(insert)\n\n for(j=0;j<data.rating.length;j++)\n $('.user-rating-'+data.rating[j].idcliente_received).text(parseFloat(data.rating[j].rating).toFixed(1))\n\n for(y=0;y<data.level.length;y++){\n $('.user-level-'+data.level[y].user_id).text(data.level[y].level)\n $('.user-level-title-'+data.level[y].user_id).text(data.level[y].level_title)\n $('.user-journeys-'+data.level[y].user_id).text(data.level[y].journeys)\n }\n }\n })\n .done(function(){\n setLanguage()\n setTimeout(function(){\n $('.w3-overlay').hide()\n $('#menu-main-page').show()\n }, 100)\n })\n }\n },\n error: function(data){\n $('.w3-overlay').hide()\n $('#info-client').modal()\n $('.info-client-header').html('<span class=\"w3-text-red\"><i class=\"fa fa-exclamation-triangle\"></i> '+json.check+'</span>')\n $('.info-client-txt').html(json.no_wifi)\n }\n })\n }\n } \n}", "complete(res){\n that.setData({team: res.data });\n console.log(res.data)\n wx.hideLoading();\n wx.hideNavigationBarLoading();\n wx.stopPullDownRefresh();\n }", "function finishLoad() {\r\n\t// Find all the different routes.\r\n\troutes = underscore.map( vehicles, function( v ) { return { Id: parseInt( v.Route ), Name: v.RouteName }; } ); \r\n\troutes = underscore.uniq( routes, false, function( r ) { return r.Id; } );\r\n\troutes = underscore.sortBy( routes, function( v ) { return v.Id; } );\r\n\r\n\t// Create a map from route id to associated header element.\r\n\tvar idToDiv = {};\r\n\t$(\"#routes a.route\").each( function( i, elem ) {\r\n\t\tvar route = $(elem).data();\r\n\t\tidToDiv[route.Id] = $(elem);\r\n\t});\r\n\r\n\t// Create/update headers for all the routes.\r\n\t$.each( routes, function( i, r ) {\r\n\t\tif( r.Name === \"\" ) {\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\t// Find or update the header for this route.\r\n\t\tvar elem = idToDiv[r.Id];\r\n\t\tif( !elem ) {\r\n\t\t\telem = $(\"<a/>\").addClass( \"route\" ).attr( \"href\", \"#\" + r.Id );\r\n\t\t\t$(\"<span/>\").addClass( \"routeName\" ).text( r.Name ).appendTo( elem );\r\n\t\t\t$(\"<a/>\").addClass( \"refresh refresh-hide\" ).attr( \"href\", \"#\" )\r\n\t\t\t\t.click( function( evt ) {\r\n\t\t\t\t\tevt.preventDefault(); // don't follow the fake link\r\n\t\t\t\t\t$(this).addClass( \"refresh-animate\" );\r\n\t\t\t\t\t$(\"#routes .route\").addClass( \"route-refreshing\" );\r\n\t\t\t\t\trefreshFromServer();\r\n\t\t\t\t})\r\n\t\t\t\t.append( $(\"<span/>\").addClass( \"refreshIcon genericon genericon-refresh\" ) )\r\n\t\t\t\t.appendTo( elem );\r\n\t\t\telem.appendTo( \"#routes\" );\r\n\t\t}\r\n\t\telse {\r\n\t\t\telem.children( \"span.routeName\" ).text( r.Name );\r\n\t\t}\r\n\t\telem.data( r );\r\n\t} );\r\n\r\n\tif( selectedRoute ) {\r\n\t\trefreshVehicles( selectedRoute );\r\n\t}\r\n\telse {\r\n\t\t// Pre-select the last used route.\r\n\t\tvar last = localStorage.lastRoute;\r\n\t\tif( last ) {\r\n\t\t\tdocument.location.hash = \"#\" + last;\r\n\t\t\tswitchToRoute( parseInt( last ) );\r\n\t\t}\r\n\t}\r\n\r\n\t$(\"#loading\").css( \"display\", \"none\" );\r\n\t$(\"#content\").css( \"display\", \"block\" );\r\n\t$(\"a.refresh\").removeClass( \"refresh-animate\" );\r\n\t$(\"#routes .route\").removeClass( \"route-refreshing\" );\r\n}", "function showCity(){\n var xhr;\n if(window.XMLHttpRequest){\n xhr = new XMLHttpRequest();\n } else if(window.ActiveXObject){\n xhr = new ActiveXObject(\"Microsoft.XMLHTTP\");\n } else {\n throw new Error(\"AJAX is not supported by your browser\");\n }\n xhr.onreadystatechange = function(){\n if(xhr.readyState < 4){\n\n } else if(xhr.readyState == 4) {\n if(xhr.status == 200 && xhr.status < 300){\n var json = JSON.parse(this.responseText);\n for(var i = 0; i < json.Cities.India.length; i++){\n CreateElement(json.Cities.India[i],'source_select_box',0,json.Cities.India[i]);\n CreateElement(json.Cities.India[i],'destination_select_box',0,json.Cities.India[i]);\n }\n }\n }\n }\n xhr.open('GET','data.json?par=345');\n xhr.send('null');\n}", "onFinish() {}", "function _finish() {\n\t\t\t$('#jquery-lightbox').remove();\n\t\t\t$('#jquery-overlay').fadeOut(function() { $('#jquery-overlay').remove(); });\n\t\t\t// Show some elements to avoid conflict with overlay in IE. These elements appear above the overlay.\n\t\t\t$('embed, object, select').css({ 'visibility' : 'visible' });\n\t\t}", "onChildrenLoadEnd() {\n if (this._childrenLoadEnd) {\n this._childrenLoadEnd.raise();\n }\n }", "function loadEnd() {\n quizPage.style.display = \"none\";\n endPage.style.display = \"block\";\n clearInterval(timeInterval);\n}", "function ajax_selected_boxes_pagination(onclick_field, paginate_class, container, address, div_loader, select_class_name, input_read, input_unread, input_all, delete_something ){\n\n\t\t$(onclick_field).on('click', paginate_class, function (e){\n\t\t\te.preventDefault(); \n\t\t\tvar page = $(this).attr('rel');\n\t\t\t//alert(page);\n\t\t\t$(container).load(address + page + div_loader, function(){\n\t\t\t\tselected_boxes(select_class_name, input_read, input_unread, input_all);\n\t\t\t\tdelete_something_pagination(delete_something);\n\t\t\t});\n\t\t});\t\n\t}", "function select_datos_carteo(_id_region, _id_asignacion, _cadena_ciudades, _cadena_colonias, _cadena_codigos, _resto, _id_caja) {\n $(\"#\" + _id_caja).empty();\n $(\"#\" + _id_caja).append(\"<div style='text-align:center;'><br><img src='images/cargando-fb.gif'><br></div>\");\n var params = {\n accion: \"select_datos_carteo\",\n id_region: _id_region,\n id_asignacion: _id_asignacion,\n cadena_ciudades: _cadena_ciudades,\n cadena_colonias: _cadena_colonias,\n cadena_codigos: _cadena_codigos,\n resto: _resto\n };\n $.ajax({\n type: \"POST\",\n url: \"/sistema/ManageVisita\",\n data: params,\n dataType: \"html\",\n success: function (dataRes) {\n alert(\"estoy llegando a la base\" + dataRes);\n console.log(dataRes);\n paint_letter_previa(dataRes, _id_caja);\n }\n });\n}", "function loaded()\n{\n\t$.ajax({\n\t\ttype: \"POST\",\n\t\tdatatype: \"json\",\n\t\turl: 'http://divie.herokuapp.com/requestFinalDiv',\n\t\tasync: false,\n\t\tsuccess: function(data){ \n\t\t\t$.each(data, function(k, v){\n\t\t\t\tResultList.push(\n\t\t\t\t\tnew Result(\n\t\t\t\t\t\tv.item_id, \n\t\t\t\t\t\tv.item_name, \n\t\t\t\t\t\tv.img_url\n\t\t\t\t\t)\n\t\t\t\t);\n\t\t\t});\n\t\t},\n\t\terror: function(){\n\t\t\talert(\"failed to load final result.\")\n\t\t}\n\t})\n}", "function loadArea(url, area) {\n var sid = $('#sresult').val();\n var idx = $('#sresult').prop('selectedIndex');\n var csrfid = $(\"#csrf_id_find\").val()\n $('option[value=\"'+sid+'\"]').remove();\n var l = $('#sresult').children('option').length;\n // goto next in list\n if(l > idx) {\n $('#sresult').prop('selectedIndex', idx);\n // else goto prev or empty\n } else {\n $('#sresult').prop('selectedIndex', idx - 1);\n }\n if(l > 0) {\n var selid = $('#sresult').val();\n $(area).load(url, {appid: selid, csrf_token: csrfid, action: actTab});\n } else {\n $(area).html(\"\");\n }\n }", "function select_areas() \r\n{\r\n $.ajax({\r\n url: 'controller/puente.php',\r\n type: 'POST',\r\n dataType: 'json',\r\n data: {option: 46},\r\n async: false ,\r\n cache: false,\r\n })\r\n .done(function(data) {\r\n $('#select_area').empty();\r\n $('#select_area').append('<option value=\"\">BUSCAR Y/O SELECCIONAR UN ÁREA </option>')\r\n $.each(data, function(i, area) {\r\n $('#select_area').append('<option value=\"'+area.id+'\">'+area.nombre+'</option>')\r\n });\r\n })\r\n .fail(function() {\r\n console.log(\"error\");\r\n });\r\n \r\n return false;\r\n}", "function loadCreateMaquette(){\n /**\n * @close-create-maquette\n */\n $('#close-create-maquette').click(function(){\n //Style CSS for tools bar\n $('#create-maquette-btn').css({\n 'background': 'none',\n });\n for(let i = 0; i<$('.create-maquette').length; i++ ){\n $('.create-maquette')[i].style.display = 'none';\n }\n $('body').css({\n 'background': 'none',\n });\n });\n\n /**\n * @create-maquette\n * [AJAX Request]\n */\n $('#create-maquette').click(function(){\n $.ajax('/ajax/add/maquette', {\n type: 'POST',\n }).then(function(response) {\n $('.create-maquette')[0].remove();\n $('body').append(response.html);\n loadCreateMaquette();\n });\n });\n\n /**\n * @selecting-maquette\n * [AJAX Request]\n * type:POST\n * change data of selecting \n */\n $('.my-maquette').click(function(){\n let value = new Object;\n value['id'] = $(this).attr('id').split('-').pop();\n\n $.ajax('/ajax/select/maquette', {\n type: 'POST',\n data: value,\n }).then(function(response) {\n \n $('.create-maquette')[0].remove();\n $('body').append(response.html);\n\n $('#header').remove();\n $('#view').append(response.htmlView);\n $('#header').prepend('<div id=\"navbar\"></div>');\n $('#navbar').html(response.htmlNavbar); \n loadCreateMaquette();\n });\n });\n\n /**\n * @delete-maquette\n * [AJAX Request]\n * type:POST\n * Delete a maquette\n */\n $('.maquette .footer span').click(function(){\n\n let value = new Object;\n value['id'] = $(this).attr('id').split('-').pop();\n\n $.ajax('/ajax/delete/maquette', {\n type : 'POST',\n data : value,\n }).then(function(response) {\n $('.create-maquette')[0].remove();\n $('body').append(response.html);\n loadCreateMaquette();\n });\n });\n \n}", "function finalize(){\n\t\tgTabList = $('#'+gTabListId).finderSelect({totalSelector:\".tab-count\",menuSelector:\"#tab-menu\",selectClass:'active',enableDesktopCtrlDefault:true});\n\t $('#'+gTabListId).btsListFilter('#searchinput', {itemChild: 'span'});\n\t\n}", "function ajaxPostBackEnd() {\n\tif (ajaxSpinnerVisible) {\n\t\tvar panelAjaxProgress = $(\"#divAjaxProgress\");\n\t\tvar divAjaxImgProgress = $(\"#divAjaxImgProgress\");\n\n\t\tdivAjaxImgProgress.fadeOut(\"fast\");\n\t\tpanelAjaxProgress.fadeOut(\"fast\");\n\n\t\tajaxSpinnerVisible = false;\n\t\t$(window).unbind('resize', ajaxProcesingResizing);\n\t}\n}", "function baseLocation_scene(listOfDistrict) {\n\t$(\"#baselocation_id\").empty();\n loadingBaseLocationMaster(listOfDistrict);\n var selectfirst = \"<option value='0'>Select Base Location</option>\";\n $('#baselocation_id').append(selectfirst);\n $.each(baselocations, function (i, resData) {\n var baselocation = \"<option value=\" + resData.baselocationID + \">\" + resData.baselocationName + \"</option>\";\n $(baselocation).appendTo('#baselocation_id');\n });\n $('#baselocation_id').trigger(\"chosen:updated\");\n $(\"#baselocation_id\").chosen();\n\n}", "function complete() {\n\t\t\tcallbackCount++;\n\t\t\tif(callbackCount >= 1) {\n\t\t\t\t//console.log(context);\n\t\t\t\tres.render('UpdateCoach', context);\n\t\t\t}\n\t\t}", "static showFresh(){\n $.ajax({\n url:\"AJAX/AJAX.php\",\n method:\"POST\",\n data:{getlist:true},\n dataType:\"json\",\n success:function(data)\n {\n //document.querySelector('#results').innerHTML=''\n window.querry = ''\n document.getElementById('results').innerHTML = ''\n view.renderList(data)\n listeners.scrollListener()\n //Course.renderBasicCategoriesForUser(data);\n //return data;\n\n },error:function (data){\n //console.log(data)\n }\n });\n }", "function courseLecturers(choice)\n{\n\n var value = $(choice).val();\n\n if(value !== \"no-selection\") {\n $.ajax({\n type: 'POST',\n url: \"../../php/admin/admin_layout.php\",\n dataType: 'json',\n data: {buttonType: \"lecturer-tables\", course: value},\n async: false,\n cache: false,\n success: function (result) {\n $(\"#tables-area\").html(result.layout);\n },\n error: function (xhr, status, error) {\n alert(xhr);\n }\n });\n\n\n tableClickable(\"selected-table\", \"remove-lecturer-btn\");\n tableClickable(\"lecturer-table\", \"add-lecturer-btn\");\n }\n else\n $(\"#tables-area\").empty();\n}", "function building(value) {\n $(\"#controls\").css(\"visibility\",\"visible\");\n $(\"#building_list\").css(\"visibility\",\"hidden\");\t\n\n var formData = \"id=\"+value; //building id\n thisBuilding = value;\n maxFloor=0; \n\n //Get Edge data\n $.ajax({\n type: \"POST\",\n url: \"../../command_center/getEdges/\"+value,\n success: function(data){\n var json = JSON.parse(data);\n edges.length=0;\n \n //Add each edge to the edges array\n for(var i = 0; i < json.length; i++){\n var temedge={\n ID:0,\n SX:0,\n SY:0,\n SZ:0,\n EX:0,\n EY:0,\n EZ:0,\n floor:0,\n type:''\n };\n \n\t\ttemedge.type=json[i][\"type\"];\n temedge.SX=json[i][\"start_x\"];\n \t\ttemedge.SY=json[i][\"start_y\"];\n \ttemedge.SZ=json[i][\"start_z\"];\n temedge.EX=json[i][\"end_x\"];\n temedge.EY=json[i][\"end_y\"];\n temedge.EZ=json[i][\"end_z\"];\n temedge.ID=json[i][\"id\"];\n temedge.floor=json[i][\"floor\"];\n edges.push(temedge);\n edge_size++;\n\t }\n }\n });\n \n //Get Node data\n $.ajax({\n type: \"POST\",\n url: \"../../command_center/getNodes/\"+value,\n success: function(data){\n var json = JSON.parse(data);\n nodes.length=0;\n \n //Add each node to the nodes array\n for(var i = 0; i < json.length; i++){\n \tvar temnode={\n ID:0,\n X:0,\n Y:0,\n Z:0,\n type:0,\n floor:0,\n width:0,\n height:0,\n name:0\n };\n \n temnode.ID=json[i][\"id\"];\n temnode.X=json[i][\"X\"];\n temnode.Y=json[i][\"Y\"];\n temnode.Z=json[i][\"Z\"];\n temnode.type=json[i][\"type\"];\n temnode.floor=json[i][\"floor\"];\n temnode.width=json[i][\"width\"];\n temnode.height=json[i][\"height\"];\n\t\ttemnode.name=json[i][\"name\"];\n nodes.push(temnode);\n node_size++;\n\t\tif(maxFloor<json[i][\"floor\"])maxFloor=json[i][\"floor\"];\n\t//\tif(temnode.type == \"Stairs\" || temnode.type == \"Elevator\")\n\t\t //console.log(temnode.name);\n }\n //transform(); \n }\n });\n} // building()", "function blockChanged() \n{ \nif (xmlHttp.readyState==4)\n{ \ndocument.getElementById(\"roomSelect\").innerHTML=\"\";\ndocument.getElementById(\"roomSelect\").innerHTML=xmlHttp.responseText;\n}\n}", "function refresh() {\n\n apex.widget.util.cascadingLov(\n gWizardSelection$,\n pOptions.ajaxIdentifier,\n {\n pageItems: $( pOptions.pageItemsToSubmit, apex.gPageContext$ )\n },\n {\n optimizeRefresh: pOptions.optimizeRefresh,\n dependingOn: $( pOptions.dependingOnSelector, apex.gPageContext$ ),\n success: _addResult,\n clear: _clearList\n });\n\n } // refresh", "function _finish() {\r\n\t\t\t$('#jquery-lightbox').remove();\r\n\t\t\t$('#jquery-overlay').fadeOut(function() { $('#jquery-overlay').remove(); });\r\n\t\t\t// Show some elements to avoid conflict with overlay in IE. These elements appear above the overlay.\r\n\t\t\t$('embed, object, select').css({ 'visibility' : 'visible' });\r\n\t\t}", "function draw_after_ajax(script)\n\t{\n\tif (script) //if script variable 'yes' when script is\n\t\t{\n\t\tstart_internal_page();\n\t\t}\n\n\twindow.preloader.sp();\n\t//update finally hash and stop_back_button flag set 'no'\n\tdocument.location.hash = '#'+concatenate_hash(window.hs);\n\twindow.cur_hash = document.location.hash;\n\twindow.stop_back_button='no';\n\t}", "function performInitAjaxes() {\n fetchOrganizations();\n fetchFieldTypes();\n fetchDataTypes();\n }", "function detail_popularmosque(a) \n {\n $('#result').show();\n $('#hasilcari1').show();\n $('#hasilcari').empty();\n $('#hasilcari').show();\n $('#popularmosque').hide();\n hapusInfo();\n clearroute2();\n\t clearroute();\n clearangkot();\n\t hapusRadius();\n hapusMarkerTerdekat();\n det_populer=a;\n console.log(det_populer);\n \n $.ajax({\n url: server+'recom_popular_mosque.php?type='+a, data: \"\", dataType: 'json', success: function(rows)\n {\n \n if(rows==null)\n {\n alert('Worship Place Not Found !');\n }\n $('#hasilcari').append(\"<thead><th class='text-center'>Mosque</th><th class='text-center'>Info</th><th class='text-center'>Route</th></thead>\");\n for (var i in rows) {\n var row = rows[i];\n var id = row.id;\n var worship_name = row.name;\n var id_type = row.id_type;\n var worship_type = row.worship_type;\n var worship_gallery = row.woship_gallery; \n var status = row.status;\n var longitude = row.longitude ;\n var latitude = row.latitude ; \n centerBaru = new google.maps.LatLng(latitude, longitude);\n marker = new google.maps.Marker\n ({\n position: centerBaru,\n icon:'assets/ico/marker_masjid.png',\n map: map,\n animation: google.maps.Animation.DROP,\n });\n console.log(worship_name);\n console.log(latitude);\n console.log(longitude);\n markersDua.push(marker);\n map.setCenter(centerBaru);\n $('#hasilcari').append(\"<tr><td>\"+worship_name+\"</td><td><a role='button' title='info' class='btn btn-success fa fa-info' style='color: white;' onclick='detailmasjid(\\\"\"+id+\"\\\");'></a></td><td><a role='button' class='btn btn-danger fa fa-car' style='color: white;' title='Local Transportation' onclick='angkotmesjid(\\\"\"+id+\"\\\",\\\"\"+latitude+\"\\\",\\\"\"+longitude+\"\\\");info12();'></a></td></tr>\");\n klikInfoWindow(id, marker);\n }\n map.setZoom(12);\n }\n });\n }", "function allergia(){\n $('#confirm').attr('onclick', 'choiceAllergy()');\n if(allergyPts.length == 0) {\n setTimeout(function() {\n //default allergies in every level\n $('#milk').show();\n $('#egg').show();\n $('#fish').show();\n $('#wheat').show();\n \n //specific allergies of other levels\n switch(diff) {\n case '2':\n $('#nuts').show();\n $('#soy').show();\n break;\n case '3':\n $('#nuts').show();\n $('#soy').show();\n $('#shellfish').show();\n $('#clam').show();\n $('#peanuts').show();\n $('#celery').show();\n break;\n }\n \n }, 1000);\n }\n \n console.log(\"test1\");\n //chiamo l'immagine\n $.getScript('Script/ajaxCallTouch.js', function() { \n var elm;\n \n getAllergyAjax(function(risultati) {\n elm = risultati; \n alt = [\n {dbelement: elm, graphicid: 'choice1'}\n ];\n \n //mappa di riferimento che contiene tutte le corrispondenze\n allergyHandler = [\n {graphicId: 'milk', selected: false, elementValue: elm.latticini},\n {graphicId: 'fish', selected: false, elementValue: elm.pesce},\n {graphicId: 'wheat', selected: false, elementValue: elm.glutine},\n {graphicId: 'egg', selected: false, elementValue: elm.uova},\n {graphicId: 'nuts', selected: false, elementValue: elm.guscio},\n {graphicId: 'soy', selected: false, elementValue: elm.soia},\n {graphicId: 'peanuts', selected: false, elementValue: elm.arachidi},\n {graphicId: 'celery', selected: false, elementValue: elm.sedano},\n {graphicId: 'clam', selected: false, elementValue: elm.molluschi},\n {graphicId: 'shellfish', selected: false, elementValue: elm.crostacei}\n ];\n console.log('inizializzato handler ' + allergyHandler[0]);\n \n ////conto il numero di allergeni nel cibo in base alla difficoltà\n tot = 0;\n switch (diff) {\n case '1':\n for (var i=0; i<4; i++) {\n if (allergyHandler[i].elementValue == '1') {\n tot++;\n }\n }\n \n break;\n case '2': \n for (var i=0; i<6; i++) {\n if (allergyHandler[i].elementValue == '1') {\n tot++;\n }\n }\n \n break;\n case '3':\n for (var i=0; i<allergyHandler.length; i++) {\n if (allergyHandler[i].elementValue == '1')\n tot++;\n \n }\n break;\n \n }\n \n \n count = tot;\n \n setTimeout(function() {\n $('#counter').empty();\n $(\"#counter\").append(count);\n $(\"#counter_container\").show();\n }, 1000);\n \n });\n \n \n });\n}", "function load_district_ps(district_id, ps_id, state_val, district_val, ps_val, sameasper_val, sameasper_id){\n data = {\"state\":state_val};\n reset_select(district_id, \"Select District\");\n $.ajax({ url: district_url,\n data: data,\n success: function(data){\n $.each(data, function(key, resource) {\n if(resource[0] == district_val){\n $('#'+district_id).append($(\"<option></option>\").attr(\"value\",resource[0]).attr('selected', 'selected').text(resource[1]));\n }else{\n $('#'+district_id).append($(\"<option></option>\").attr(\"value\",resource[0]).text(resource[1]));\n }\n });\n\n //Police Station\n data = {\"state\": state_val, \"district\":district_val };\n reset_select(\"fir_victimpolicestation\", \"Select Police Station\");\n\n $.ajax({ url: police_station_url,\n data: data,\n success: function(data){\n $.each(data, function(key, resource) {\n if(resource[0] == ps_val){\n $('#'+ps_id).append($(\"<option></option>\").attr(\"value\",resource[0]).attr('selected', 'selected').text(resource[1]));\n }else{\n $('#'+ps_id).append($(\"<option></option>\").attr(\"value\",resource[0]).text(resource[1]));\n }\n });\n if(sameasper_val==\"Yes\"){\n $('#'+sameasper_id).click();\n }\n }});\n\n\n }\n });\n}", "function load_district_ps(district_id, ps_id, state_val, district_val, ps_val, sameasper_val, sameasper_id){\n data = {\"state\":state_val};\n reset_select(district_id, \"Select District\");\n $.ajax({ url: district_url,\n data: data,\n success: function(data){\n $.each(data, function(key, resource) {\n if(resource[0] == district_val){\n $('#'+district_id).append($(\"<option></option>\").attr(\"value\",resource[0]).attr('selected', 'selected').text(resource[1]));\n }else{\n $('#'+district_id).append($(\"<option></option>\").attr(\"value\",resource[0]).text(resource[1]));\n }\n });\n\n //Police Station\n data = {\"state\": state_val, \"district\":district_val };\n reset_select(\"fir_victimpolicestation\", \"Select Police Station\");\n\n $.ajax({ url: police_station_url,\n data: data,\n success: function(data){\n $.each(data, function(key, resource) {\n if(resource[0] == ps_val){\n $('#'+ps_id).append($(\"<option></option>\").attr(\"value\",resource[0]).attr('selected', 'selected').text(resource[1]));\n }else{\n $('#'+ps_id).append($(\"<option></option>\").attr(\"value\",resource[0]).text(resource[1]));\n }\n });\n if(sameasper_val==\"Yes\"){\n $('#'+sameasper_id).click();\n }\n }});\n\n\n }\n });\n}", "function ajaxForVehicles(){\n\t\tcreateDropDown(maxNumberOfVehicles, $dropDownVehicles);\n\t\thideTheRestDropDowns($dropDownVehicles);\n\t\t$spanInfo.text(\"Number of Vehicles\");\n\t\t$divContent.show();\n\t\t//initial value when link is clicked\n\t\tgenerateVehicles(initialNumberDisplayed);\n\t\t// get the ajax request\n\t\t$.get(\"http://swapi.co/api/vehicles/\", {\t\n\t\t}).done(function(data) {\n\t\t\t$dropDownVehicles.on( \"change\", function(){\n\t\t\t\tgenerateVehicles($(this).val());\n\t\t\t});\n\t\t\t$table.show();\t\n\t\t}).fail(function() {\n\t\t\talert('something went wrong in the ajaxForVehicles()! FIRST');\n\t\t});\n\t\t//end of ajax request\n\t}", "function onPageload(){\r\n console.log(\"document loaded\");\r\n var url = \"http://127.0.0.1:5000/get_saved_api\";\r\n // var url = \"/api/get_saved_api\"; //\r\n $.get(url,function(data, status){\r\n console.log(\"got saved api call files responses\");\r\n if (data){\r\n var locations = data.Location;\r\n var Fuel_type = data.Fuel_Type;\r\n var carname = data.car_model_names;\r\n var uilocations = document.getElementById(\"uiLocations\");\r\n $('#uiLocations').empty();\r\n for(var i in locations){\r\n var opt = new Option(locations[i]);\r\n $('#uiLocations').append(opt);\r\n }\r\n var uifuel = document.getElementById(\"uiFuel\");\r\n $('#uiFuel').empty();\r\n for(var i in Fuel_type){\r\n var opt1 = new Option(Fuel_type[i]);\r\n $('#uiFuel').append(opt1);\r\n }\r\n var uicarname = document.getElementById(\"uiCarname\");\r\n $('#carlist').empty();\r\n for(var i in carname){\r\n var opt2 = new Option(carname[i]);\r\n $('#carlist').append(opt2);\r\n }\r\n\r\n } \r\n });\r\n\r\n}", "function ajax_finalizer() {\n // re-setup data-remote again\n $('.pagination a').attr('data-remote', 'true');\n // rebind fancybox\n $(\"a.preview\").fancybox();\n // hilight search results\n var search = $(\"#search\").val();\n if (search) {\n $(\".container\").highlight(search, 1, \"hilight\");\n }\n}", "function complete() {\n Y.log('complete');\n }", "function complete() {\n Y.log('complete');\n }", "function complete() {\n Y.log('complete');\n }", "function complete() {\n Y.log('complete');\n }", "function addInteraction() {\n var value = 'Circle';\n var geometryFunction = createBox();\n draw = new Draw({\n source: source,\n type: value,\n geometryFunction: geometryFunction\n });\n\n draw.on('drawend', function (event) {\n var feature = event.feature.getGeometry();\n var coords = feature.getCoordinates();\n console.log(coords[0]);\n\n\n $('body').addClass(\"loading\"); \n var jqXHR = $.ajax({\n url: \"/background_process\",\n type: \"POST\",\n data: JSON.stringify(coords),\n contentType: 'application/json;charset=UTF-8',\n }).done(function (response, status, jqXHR) {\n //window.location = response;\n console.log(response);\n }).fail(function (jqXHR, status, err) {\n // alert(\"Request Failed.\");\n //map.removeInteraction(draw);\n }).always(function () {\n $('body').removeClass(\"loading\");\n });\n\n\n });\n map.addInteraction(draw);\n}", "function Load_Trips(srno)\n{\n console.log(\"load tour \" + srno);\n if(srno == \"\")\n {\n alert(\"Please Login First\");\n return;\n }\n Save_id=srno;\n var url = site_url+'site/getDetailTour?';\n alert(\"load trips \" +srno);\n $.ajax({\n type: 'GET',\n url: url,\n contentType: \"application/json\",\n dataType: 'jsonp',\n jsonp: 'callback',\n data: {\n srno : srno\n },\n beforeSend : function(){\n //$(\"#visited_site_list\").html('');\n //$(\"#loader_image\").css(\"display\",\"block\");\n },\n crossDomain: true,\n \n success: function(res) {\n //alert(\"success\" + JSON.stringify(res));\n \n if(res[0]!= \"no-data\")\n {\n $(\".addItinerary\").each(function()\n {\n $(this).removeClass('addItinerary');\n });\n Itineraries_list=[];\n Itineraries_Ad=[];\n Tour_List=[];\n document.getElementById('Itinerary').innerHTML='';\n var myObj = JSON.parse(res[0].Detail);\t\t\n var str_array = myObj.Places_List_all.split(',');\n //return;\n var abca='';\n \n service = new google.maps.places.PlacesService(map);\n for(var i=0; i<str_array.length; i++)\n {\n //alert(str_array[i]);\n \n service.getDetails({\n placeId:str_array[i]\n },\n function(place, status) {\n \n if (status === google.maps.places.PlacesServiceStatus.OK)\n {\n var struct='';\n //alert(\"hi\");\n if(!(typeof place.photos === \"undefined\"))\n {\n if(!(typeof place.photos[0] === \"undefined\"))\n {\n struct='<div class=\"col-sm-12 col-xs-12 paddingzero\"><input type=\"hidden\" id=\"Lat_'+place.place_id+'\" value=\"'+place.geometry.location.lat()+'\"/><input type=\"hidden\" id=\"Log_'+place.place_id+'\" value=\"'+place.geometry.location.lng()+'\"/><div class=\"col-sm-4 col-xs-4 paddingright\"><img class=\"img-circle itineraryImg\" src=\"'+place.photos[0].getUrl({'maxWidth': 500, 'maxHeight': 500})+'\" /></div><div class=\"col-sm-8 col-xs-8 paddingzero\"><ul class=\"yetToVisit\"><li class=\"title hotelName\" id=\"Place_name'+place.place_id+'\"> '+place.name+' </li> <li class=\"title itinerarydes\" id=\"Add_'+place.place_id+'\"> '+place.vicinity+'</li><li class=\"title itinerarydes\"></li></ul></div></div>';\n }\n }\n else\n {\n struct='<div class=\"col-sm-12 col-xs-12 paddingzero\"><input type=\"hidden\" id=\"Lat_'+place.place_id+'\" value=\"'+place.geometry.location.lat()+'\"/><input type=\"hidden\" id=\"Log_'+place.place_id+'\" value=\"'+place.geometry.location.lng()+'\"/><div class=\"col-sm-4 col-xs-4 paddingright\"><img class=\"img-circle itineraryImg\" src=\"'+place.icon+'\" /></div><div class=\"col-sm-8 col-xs-8 paddingzero\"><ul class=\"yetToVisit\"><li class=\"title hotelName\" id=\"Place_name'+place.place_id+'\"> '+place.name+' </li> <li class=\"title itinerarydes\" id=\"Add_'+place.place_id+'\"> '+place.vicinity+'</li><li class=\"title itinerarydes\"> </li></ul></div></div>';\n }\n \n \n document.getElementById('Itinerary').innerHTML = document.getElementById('Itinerary').innerHTML + '<div class=\"col-sm-12 col-xs-12 paddingtb borderbottom ui-state-default ALL_Places_Tour YetToVisitedNode\" id=\"Itinerari_'+place.place_id+'\"><div class=\"col-sm-8 col-xs-8 paddingzero\" onclick=\"Detail(this,false)\">' + struct + '</div> <div onClick=\"delete_it(this)\" class=\"col-sm-2 col-xs-2 paddingzero Del\" style=\"display:none\"><img class=\"img-responsive\" src=\"images/trash.png\" /></div><div class=\"col-sm-2 col-xs-2 img- responsive paddingzero handle Drag\" style=\"display:none\"><span title=\"Re-arrange itinerary by dragging and dropping sites\"></span></div><div class=\"markasvisited vis col-sm-4 col-xs-4 paddingleft\" ><div class=\"markAsVisit\">Mark visited</div><input onclick=\"visitsite(this)\" class=\"visitedcheck\" type=\"checkbox\" name=\"visited\"></div></div>';\n struct='';\n Itineraries_list.push(place.place_id);\n Itineraries_Ad.push(place.vicinity);\n Tour_List.push('1');\n $(\"#ADD_New\").val(\"\");\n \n if($('#List_'+place.place_id).length) // use this if you are using id to check\n {\n //$('#List_'+place.place_id).addClass('addItinerary');\n var abcn=\".\"+place.place_id;\n //$('#List_'+id).removeClass('addItinerary');\n $(abcn).each(function() {\n $(this).addClass('addItinerary');\n });\n }\n //code to add colore difference code starts here\n col_Diff(); \n //code to add colore difference ends here\n \n }\n else\n {\n swal(status);\n }\n });\n\n }\n $('#itinerary_Ui').show();\n $('#MyTrips').hide();\n $('#BuildSearchUi').hide();\n }\n else\n {\n swal(\"No data stored on the server form u\");\n return;\n }\n },\n error: function(e) {\n console.log(e.message);\n },\n complete: function(data) {\n //alert(\"complete\");\n //console.log(data.message);\n }\n });\n}", "onAfterLoadPage(data_obj) {\n\t\t//TODO: Override this as needed;\n\t}", "onAfterLoadPage(data_obj) {\n\t\t//TODO: Override this as needed;\n\t}", "function waitForAjax2() {\n setTimeout(function() {\n do {\n if (drawOptionSelected) {\n drawPhotos();\n drawOptionSelected = false;\n break;\n } else {\n break;\n }\n } while (1);\n }, 1000);\n }", "function complete() {\n Y.log('complete');\n }", "function continueLoad(){\n\td3.selectAll(\".loadHide\").classed(\"loadHide\", false)\n\td3.select(\"#loadingGif\")\n\t\t.transition()\n\t\t.style(\"display\", \"none\")\n\t\t.on(\"end\", function(){\n\t\t\tsetActiveDistrict(MILWAUKEE_ID, DEFAULT_LEVEL, TAMARACK_ID, \"load\")\t\t\n\t\t\tsetActiveSchool()\n\t\t})\n}", "function tybaa(url) {\r\n var xhttp = new XMLHttpRequest()\r\n xhttp.onreadystatechange = function() {\r\n if (this.readyState == 4 && this.status == 200) {\r\n document.getElementById(\"print_content\").innerHTML = this.responseText;\r\n printery('print_content');\r\n document.getElementById(\"print_content\").innerHTML = \" \";\r\n $(document).ready(function() {\r\n $('.drop_value2').html(\" \")\r\n $('#down_from_top2').fadeOut();\r\n });\r\n } else {\r\n $(document).ready(function() {\r\n $('.drop_value2').html(\"<span style='color:red;'> <img src='img/ajax-loader.gif'/> </span>\")\r\n $('#down_from_top2').fadeIn()\r\n });\r\n }\r\n }\r\n xhttp.open('POST', 'tybaa.php', true)\r\n xhttp.setRequestHeader('Content-type', 'application/x-www-form-urlencoded')\r\n xhttp.send(\"fatora_no=\" + url);\r\n}", "function ajaxLoaded(data) {\r\n\t\tdebug('AjaxLoaded: '+this.url);\r\n\t\tmodal.tmp.html(currentSettings.selector\r\n\t\t\t?filterScripts($('<div>'+data+'</div>').find(currentSettings.selector).contents())\r\n\t\t\t:filterScripts(data));\r\n\t\tif (modal.tmp.html()) {\r\n\t\t\tmodal.dataReady = true;\r\n\t\t\tshowContentOrLoading();\r\n\t\t} else\r\n\t\t\tloadingError();\r\n\t}", "function process_user_end( ajax )\n{\n\twindows.location.reload();\n}", "function profileCurrentData() {\n\n\n\n $('#p-r1c1').find('option:not(:first)').remove();\n $('#p-r2c1').find('option:not(:first)').remove();\n $('#pm-r4c1').find('option:not(:first)').remove();\n $('#pm-r1c1').find('option:not(:first)').remove();\n $('#pm-r2c1').find('option:not(:first)').remove();\n $('#pm-r3c1').find('option:not(:first)').remove();\n\n\n $('#pm-r1c2').find('option:not(:first)').remove();\n $('#pm-r2c2').find('option:not(:first)').remove();\n $('#pm-r3c2').find('option:not(:first)').remove();\n $('#pm-r4c2').find('option:not(:first)').remove();\n\n\n document.getElementById(\"loader\").style.display = \"block\";\n document.getElementById(\"mainPage\").style.display = \"none\";\n // gadgets.window.adjustHeight();\n\n var salesforceContactFields = [];\n var jiveUserFields = [];\n var existingAccountNames = [];\n var accountNameMappingFields = [];\n\n osapi.http.get({\n href: jiveBaseUrl + \"/getAccountFields\",\n 'refreshInterval': 0,\n format: 'json',\n 'authz': 'signed',\n 'headers': {\n 'Content-Type': ['application/json']\n }\n }).execute(function (res) {\n\n\n salesforceContactFields = res.content.salesforceContactFields;\n jiveUserFields = res.content.jiveUserFields;\n // existingAccountNames = res.content.existingAccountNames;\n // accountNameMappingFields = res.content.accountNameMappingFields;\n\n\n // salesforce credentials\n document.getElementById('loginUrl').value = res.content.loginUrl;\n document.getElementById('salesforceClientId').value = res.content.clientId;\n document.getElementById('salesforceClientSecret').value = res.content.clientSecret;\n\n\n //jive Credentials\n document.getElementById('jiveLoginUrl').value = res.content.jiveLoginUrl;\n document.getElementById('jiveEmailAddress').value = res.content.username;\n document.getElementById('jivePassword').value = res.content.password;\n\n\n\n\n // var select5 = document.getElementById('p-r1c1'),\n // select6 = document.getElementById('p-r2c1'),\n var select7 = document.getElementById('pm-r4c1');\n\n\n var select8 = document.getElementById('pm-r1c1'),\n select9 = document.getElementById('pm-r2c1'),\n select10 = document.getElementById('pm-r3c1');\n\n var newOption9 = document.createElement('option');\n newOption9.value = \"FirstName\";\n newOption9.text = \"FirstName\";\n select8.add(newOption9);\n\n\n var newOption10 = document.createElement('option');\n newOption10.value = \"LastName\";\n newOption10.text = \"LastName\";\n select9.add(newOption10);\n\n\n var newOption11 = document.createElement('option');\n newOption11.value = \"Email\";\n newOption11.text = \"Email\";\n select10.add(newOption11);\n\n\n\n var jiveSelect3 = document.getElementById('pm-r1c2'),\n jiveSelect4 = document.getElementById('pm-r2c2'),\n jiveSelect5 = document.getElementById('pm-r3c2'),\n jiveSelect6 = document.getElementById('pm-r4c2');\n\n var newOption12 = document.createElement('option');\n newOption12.value = \"givenName\";\n newOption12.text = \"givenName\";\n jiveSelect3.add(newOption12);\n\n\n var newOption13 = document.createElement('option');\n newOption13.value = \"familyName\";\n newOption13.text = \"familyName\";\n jiveSelect4.add(newOption13);\n\n\n var newOption14 = document.createElement('option');\n newOption14.value = \"Email\";\n newOption14.text = \"Email\";\n jiveSelect5.add(newOption14);\n\n\n // var newAccount = document.getElementById('new-account');\n\n\n for (var k = 0; k < salesforceContactFields.length; k++) {\n // var newOption6 = document.createElement('option');\n // var newOption7 = document.createElement('option');\n var newOption8 = document.createElement('option');\n //\n // newOption6.value = salesforceContactFields[k];\n // newOption6.text = salesforceContactFields[k];\n //\n // newOption7.value = salesforceContactFields[k];\n // newOption7.text = salesforceContactFields[k];\n\n\n newOption8.value = salesforceContactFields[k];\n newOption8.text = salesforceContactFields[k];\n\n\n // select6.add(newOption7);\n // select5.add(newOption6);\n select7.add(newOption8);\n\n\n }\n\n\n for (var l = 0; l < jiveUserFields.length; l++) {\n var newOption15 = document.createElement('option');\n\n\n newOption15.value = jiveUserFields[l];\n newOption15.text = jiveUserFields[l];\n\n\n\n\n\n jiveSelect6.add(newOption15);\n\n\n }\n\n // var existingAccount = document.getElementById('existing-account');\n\n // for (var m = 0; m < existingAccountNames.length; m++) {\n // var newOption16 = document.createElement('option');\n //\n //\n // newOption16.value = existingAccountNames[m].id;\n // newOption16.text = existingAccountNames[m].name;\n //\n // existingAccount.add(newOption16);\n // }\n //\n // for(var h = 0 ; h < accountNameMappingFields.length ;h++)\n // {\n // var newOption17 = document.createElement('option');\n // newOption17.value = accountNameMappingFields[h];\n // newOption17.text = accountNameMappingFields[h];\n // newAccount.add(newOption17);\n //\n // }\n osapi.http.get({\n href: jiveBaseUrl + \"/getUserSyncingFile\",\n 'refreshInterval': 0,\n format: 'json',\n 'authz': 'signed',\n 'headers': {\n 'Content-Type': ['application/json']\n }\n\n }).execute(function (res) {\n\n var currentData = res.content.userData;\n // console.log(currentData);\n\n // var tBodyChildren = document.getElementById('ProfileSync').tBodies[0].children;\n // if (currentData.length != tBodyChildren.length) {\n\n if (currentData.length) {\n\n\n\n //Account Fields\n // if (userConditionFlag == 0) {\n // if (currentData[0].condition.length > 2) {\n // for (var i = 2; i < currentData[0].condition.length; i++) {\n // var table = document.getElementById(\"ProfileSync\");\n // var new_row = table.rows[1].cloneNode(true);\n //\n // var len = table.rows.length;\n // new_row.cells[0].innerHTML = len;\n //\n // var inp1 = new_row.cells[1].getElementsByTagName('select')[0];\n //\n //\n // // console.log(new_row.children[4]);\n //\n // new_row.children[5].style.display = \"block\";\n // for (var i = 1; i < table.tBodies[0].children.length; i++) {\n // table.tBodies[0].children[i].children[0].innerHTML = i + 1;\n // }\n //\n //\n // table.tBodies[0].appendChild(new_row);\n // table.tBodies[0].children[len - 1].children[1].children[0].value = \"\";\n // table.tBodies[0].children[len - 1].children[2].children[0].value = \"\";\n // table.tBodies[0].children[len - 1].children[3].children[0].value = \"\";\n //\n // }\n // }\n // userConditionFlag = 1;\n //\n // }\n //\n // for (var j = 0; j < currentData[0].condition.length; j++) {\n //\n //\n // var trChild = tBodyChildren[j].children;\n // // console.log(currentData[0].condition[j].field);\n // trChild[1].children[0].value = currentData[0].condition[j].field;\n // trChild[2].children[0].value = currentData[0].condition[j].operator;\n // trChild[3].children[0].value = currentData[0].condition[j].value;\n //\n // }\n //\n // document.getElementById(\"AddFilterLogic1\").value = currentData[0].filterLogic;\n\n\n // Mapping Fields\n if (userMappingFlag == 0) {\n if (currentData[0].mapping.length > 3) {\n\n // console.log(\"add mapping rows\");\n for (var i = 3; i < currentData[0].mapping.length; i++) {\n\n\n var table = document.getElementById(\"userMapping\");\n\n var new_row = table.rows[4].cloneNode(true);\n\n var len = table.rows.length;\n new_row.cells[0].innerHTML = len;\n\n var inp1 = new_row.cells[1].getElementsByTagName('select')[0];\n new_row.children[4].style.display = \"block\";\n for (var i = 1; i < table.tBodies[0].children.length; i++) {\n table.tBodies[0].children[i].children[0].innerHTML = i + 1;\n }\n\n\n table.tBodies[0].appendChild(new_row);\n table.tBodies[0].children[len - 1].children[1].children[0].value = \"\";\n table.tBodies[0].children[len - 1].children[2].children[0].value = \"\";\n table.tBodies[0].children[len - 1].children[3].children[0].value = \"\";\n }\n\n }\n\n userMappingFlag = 1;\n }\n\n\n for (var map = 0; map < currentData[0].mapping.length; map++) {\n\n var tBodyChildrenmap = document.getElementById('userMapping').tBodies[0].children;\n var trChildmap = tBodyChildrenmap[map].children;\n //console.log(currentData[0].condition[map].field);\n trChildmap[1].children[0].value = currentData[0].mapping[map].salesforceField;\n trChildmap[2].children[0].value = currentData[0].mapping[map].jiveField;\n // console.log(currentData[0].mapping[map].mappingType);\n\n if (currentData[0].mapping[map].mappingType == \"0\") {\n // console.log(\"0\");\n\n trChildmap[3].children[0].value = 0;\n }\n else if (currentData[0].mapping[map].mappingType == \"1\") {\n // console.log(\"1\");\n trChildmap[3].children[0].value = 1;\n }\n else if (currentData[0].mapping[map].mappingType == \"2\") {\n // console.log(\"2\");\n trChildmap[3].children[0].value = 2;\n }\n\n }\n\n\n //Frequency\n var freq = document.getElementById('userFrequency');\n if (currentData[0].frequency == \"0\") {\n freq.children[0].checked = true;\n }\n else if (currentData[0].frequency == \"1\") {\n freq.children[2].checked = true;\n }\n else if (currentData[0].frequency == \"2\") {\n freq.children[4].checked = true;\n }\n\n\n // var accountNameMapping = currentData[0].accountNameMapping;\n //\n // if (accountNameMapping.userFieldMapping == false) {\n // console.log(\"here\");\n //\n // document.getElementById('existing-account').value = accountNameMapping.account;\n //\n // }\n // else {\n // document.getElementById('new-account').value = accountNameMapping.account;\n // }\n\n userProfileFlag = 1;\n\n gadgets.window.adjustHeight();\n\n }\n // }\n });\n showPage();\n\n\n });\n}", "function space(rahimat2)\n{\n changeroom();\n /* alert(jss);*/\n /*alert(rahimat);*/\n if (rahimat2==\"--Select Room--\")\n {\n changeroom();\n return;\n }\n xmlHttp=GetXmlHttpObject();\n if (xmlHttp==null)\n {\n alert (\"Your browser does not support AJAX!\");\n return;\n }\n /*&\"?status=\"+kkk*/\n var jss1 = document.getElementById(\"hostelSelect\").value;\n var jss2 = document.getElementById(\"blockSelect\").value;\n var url=\"populate.php\";\n url=url+\"?khadijat=\"+rahimat2+\"&nuhu=\"+jss1+\"&muluk=\"+jss2;\n xmlHttp.onreadystatechange=roomChanged;\n xmlHttp.open(\"GET\",url,true);\n xmlHttp.send(null);\n}", "_statusChanged(e){// we are in loading state so go load data and let the response\n// dictate what state we reach after that\nif(\"loading\"==e.target.status){if(typeof this.items[this.active].metadata.dataUrl!==typeof void 0&&!this.disableAjaxCalls){this.$.ajax.url=this.items[this.active].metadata.dataUrl;this.$.ajax.generateRequest()}else{setTimeout(()=>{this.items[this.active].metadata.status=\"available\";this.set(\"items.\"+this.active+\".metadata.status\",\"available\");this.notifyPath(\"items.\"+this.active+\".metadata.status\");this._responseList[this.active]={};this.activeNodeResponse=this._responseList[this.active]},1500)}}else if(\"complete\"==e.target.status&&this.items.length===this.active+1){setTimeout(()=>{this.items[this.active].metadata.status=\"finished\";this.set(\"items.\"+this.active+\".metadata.status\",\"finished\");this.notifyPath(\"items.\"+this.active+\".metadata.status\")},100)}}", "function laterPresentation() {\n ajax(\"GET\", \"/rooms\", fillRoomListLater);\n home.css(\"margin-top\", \"5%\");\n home.find(\"span\").css(\"cursor\", \"pointer\");\n homebtn.hide();\n roomList.hide();\n roomListLater.show();\n roomListEdit.hide();\n roomListDisplay.hide();\n}", "function showPickedSteps() {\n\t// alert(\"inside\");\n\tloadProgress();\n\t$.ajax({\n\t\ttype : \"GET\",\n\t\turl : \"adminTemplate/goPickedSteps\",\n\t\tcache : false,\n\t\tsuccess : function(data) {\n\t\t\t$(\"#showDynamicContent\").html(\"\");\n\t\t\t$(\"#dynamicContent\").html(data);\n\t\t\t$('#unpickSteps').dataTable({\n\t\t\t\t\"bJQueryUI\" : true,\n\t\t\t\t\"sPaginationType\" : \"full_numbers\",\n\t\t\t\t\"iDisplayLength\" : 25,\n\t\t\t\t\"sScrollY\" : \"390px\",\n\t\t\t\t\"bFilter\" : true,\n\t\t\t\t\"bDestroy\" : true\n\t\t\t});\n\t\t\tremoveProgress();\n\t\t}\n\t});\n}", "fetchDataStop(){\n this.hideLoader();\n this.showDropdown();\n }", "function updateResults(data) {\n //update results... \n\n $.each(data, function (index, city) {\n\n\n $(\"#\" + index + \" > .cityInf\").children(\".cityName\").text(city.name);\n $(\"#\" + index + \" > .cityInf\").children(\".cityWhereInfos\").text(city.region + \" - \" + city.departement + ($(\"#attributes_form > [name='distance']\").prop(\"checked\") ? \" - \" + \"25km de Paris\" : \"\"));\n\n var details = $(\"#\" + index + \" > .details\");\n\n if(city.culture != null) {\n\n details.append(\"<div class='Culture cat'>\" +\n \"<h4>Culture</h4>\" +\n \"<div class='scoreSlider'>\" +\n \"<div class='scoreSliderColored' style='width : \" + city.culture.score * 100 + \"%;'></div><span class='scoreSlidercoloredCircle'></span><div class='scoreSliderGray'></div>\");\n\n\n if(city.culture.details.animation != null) {\n\n\n\n details.append(\"<div id='Animation' class='crit'>\" +\n \"<h5>Animation / Évènementiel</h5>\" +\n \"<div class='scoreSlider'>\" +\n \"<div class='scoreSliderColored' style='width:\" + city.culture.details.animation.score * 100 + \"%;'></div><span class='scoreSlidercoloredCircle'></span>\" +\n \"</div>\" +\n \"</div>\");\n\n\n details.append(\"<div id='events'>\" +\n \"<ul>\" +\n \"<li>\" + city.culture.details.animation.evenements[0].date + \"|\" + city.culture.details.animation.evenements[0].theme + \"|\" + city.culture.details.animation.evenements[0].nom_organisation + \"</li>\" +\n \"<li>\" + city.culture.details.animation.evenements[1].date + \"|\" + city.culture.details.animation.evenements[1].theme + \"|\" + city.culture.details.animation.evenements[1].nom_organisation + \"</li>\" +\n \"<li>\" + city.culture.details.animation.evenements[2].date + \"|\" + city.culture.details.animation.evenements[2].theme + \"|\" + city.culture.details.animation.evenements[2].nom_organisation + \"</li>\" +\n \"<li>\" + city.culture.details.animation.evenements[3].date + \"|\" + city.culture.details.animation.evenements[3].theme + \"|\" + city.culture.details.animation.evenements[3].nom_organisation + \"</li>\" +\n \"<li>\" + city.culture.details.animation.evenements[4].date + \"|\" + city.culture.details.animation.evenements[4].theme + \"|\" + city.culture.details.animation.evenements[4].nom_organisation + \"</li>\" +\n \"</ul>\" +\n \"</div>\");\n\n\n }\n\n\n details.append(\"</div>\");\n\n\n\n\n }\n\n if(city.economie != null) {\n\n details.append(\"<div id='Economie' class='cat'>\" +\n \"<h4>Économie</h4>\" +\n \"<div class='scoreSlider'>\" +\n \"<div class='scoreSliderColored' style='width:\" + city.economie.score * 100 + \"%;'></div><span class='scoreSlidercoloredCircle'></span><div class='scoreSliderGray'></div>\" +\n \"</div>\");\n\n if(city.economie.details.chomage != null) {\n\n details.append(\"<div id='Chomage' class='crit'>\" +\n \"<h5>Chomâge faible</h5>\" +\n \"<div class='scoreSlider'>\" +\n \"<div class='scoreSliderColored' style='width:\" + city.economie.details.chomage.score * 100 + \"%;'></div><span class='scoreSlidercoloredCircle'></span>\" +\n \"</div>\" +\n \"</div>\");\n\n\n }\n\n\n if(city.economie.details.tourisme != null) {\n\n details.append(\"<div id='Tourisme' class='crit'>\" +\n \"<h5>Tourisme important</h5>\" +\n \"<div class='scoreSlider'>\" +\n \"<div class='scoreSliderColored' style='width:\" + city.economie.details.tourisme.score * 100 + \"%;'></div><span class='scoreSlidercoloredCircle'></span>\" +\n \"</div>\" +\n \"</div>\");\n\n }\n\n if(city.economie.details.industrie != null) {\n\n details.append(\"<div id='Industrie' class='crit'>\" +\n \"<h5>Industrie importante</h5>\" +\n \"<div class='scoreSlider'>\" +\n \"<div class='scoreSliderColored' style='width:\" + city.economie.details.industrie.score * 100 + \"%;'></div><span class='scoreSlidercoloredCircle'></span>\" +\n \"</div>\" +\n \"</div>\");\n\n }\n\n if(city.economie.details.agriculture != null) {\n\n details.append(\"<div id='Agriculture' class='crit'>\" +\n \"<h5>Agriculture importante</h5>\" +\n \"<div class='scoreSlider'>\" +\n \"<div class='scoreSliderColored' style='width:\" + city.economie.details.agriculture.score * 100 + \"%;'></div><span class='scoreSlidercoloredCircle'></span>\" +\n \"</div>\" +\n \"</div>\");\n\n }\n\n\n if(city.economie.details.commerces != null) {\n\n details.append(\"<div id='Commerces' class='crit'>\" +\n \"<h5>Variété de commerces</h5>\" +\n \"<div class='scoreSlider'>\" +\n \"<div class='scoreSliderColored' style='width:\" + city.economie.details.commerces.score * 100 + \"%;'></div><span class='scoreSlidercoloredCircle'></span>\" +\n \"</div>\" +\n \"</div>\");\n\n }\n\n\n details.append(\"</div>\");\n\n\n }\n\n if(city.population != null) {\n\n details.append(\"<div id='Population' class='cat'>\" +\n \"<h4>Population</h4>\" +\n \"<div class='scoreSlider'>\" +\n \"<div class='scoreSliderColored' style='width:\" + city.population.score * 100 + \"%;'></div><span class='scoreSlidercoloredCircle'></span><div class='scoreSliderGray'></div>\" +\n \"</div>\");\n\n if(city.population.details.senior != null) {\n\n details.append(\"<div id='Senior' class='crit'>\" +\n \"<h5>Senior</h5>\" +\n \"<div class='scoreSlider'>\" +\n \"<div class='scoreSliderColored' style='width:\" + city.population.details.senior.score * 100 + \"%;'></div><span class='scoreSlidercoloredCircle'></span>\" +\n \"</div>\" +\n \"</div>\");\n\n }\n\n if(city.population.details.jeune != null) {\n\n details.append(\"<div id='Jeune' class='crit'>\" +\n \"<h5>Jeune</h5>\" +\n \"<div class='scoreSlider'>\" +\n \"<div class='scoreSliderColored' style='width:\" + city.population.details.jeune.score * 100 + \"%;'></div><span class='scoreSlidercoloredCircle'></span>\" +\n \" </div>\" +\n \"</div>\");\n\n }\n\n details.append(\"</div>\");\n\n\n }\n\n if(city.services_publics != null) {\n\n details.append(\"<div id='ServicesPublics' class='cat'>\" +\n \"<h4>Services Publics</h4>\" +\n \"<div class='scoreSlider'>\" +\n \"<div class='scoreSliderColored' style='width:\" + city.services_publics.score * 100 + \"%;'></div><span class='scoreSlidercoloredCircle'></span><div class='scoreSliderGray'></div>\" +\n \"</div>\");\n\n if(city.services_publics.details.sante != null) {\n\n details.append(\"<div id='Sante' class='crit'>\" +\n \"<h5>Hôpitaux / médecins</h5>\" +\n \"<div class='scoreSlider'>\" +\n \"<div class='scoreSliderColored' style='width:\" + city.services_publics.details.sante.score * 100 + \"%;'></div><span class='scoreSlidercoloredCircle'></span>\" +\n \"</div>\" +\n \"</div>\");\n\n }\n\n details.append(\"</div>\");\n\n }\n\n\n\n\n\n\n\n });\n\n}", "loadingComplete() {\n // Show the canvas or something\n $('body').removeClass('loading');\n }", "function onFinish() {\n // There is the possibility that we are calling this more than once\n if (!_self.loading)\n return;\n\n _self.loading = false;\n\n // Re-select the last selected item\n if(_self.treeSelection.path) {\n var xmlNode = trFiles.$model.queryNode('//node()[@path=' +\n util.escapeXpathString(_self.treeSelection.path) + ' and @type=\"' +\n _self.treeSelection.type + '\"]');\n if (xmlNode)\n trFiles.select(xmlNode);\n }\n else {\n trFiles.select(trFiles.getFirstTraverseNode());\n }\n\n // Scroll to last set scroll pos\n if (_self.scrollPos && _self.scrollPos > -1) {\n if (animateScrollOnFinish) {\n apf.tween.single(trFiles, {\n type: \"scrollTop\",\n from: 0,\n to: _self.scrollPos\n });\n }\n else {\n trFiles.$ext.scrollTop = _self.scrollPos;\n }\n }\n\n // Now set the \"get\" attribute of the <a:insert> rule so the tree\n // knows to ask webdav for expanded folders' contents automatically\n self[\"trFilesInsertRule\"] && trFilesInsertRule.setAttribute(\"get\", \"{davProject.readdir([@path])}\");\n\n settings.save();\n }", "function LoadSelections(selection) {\n if (selection.waypoints && selection.waypoints.length > 0) {\n _.each(selection.waypoints, function (array) {\n PathSelection(array, function () {\n var bboxes = GetDrawLayerBBoxes();\n GetDataByBBox(bboxes);\n });\n });\n }\n if (selection.data) {\n if (selection.data.searchLayer) {\n $rootScope.toggleLayer(selection.data.searchLayer, true);\n }\n L.geoJson(selection.data, {\n onEachFeature: function (feature) {\n if (selection.data.search && selection.data.search.searchType === 'radius')\n {\n var startPoint = L.GeoJSON.coordsToLatLng(feature.geometry.coordinates);\n var radius = feature.properties.radius;\n var circle = L.circle(startPoint, radius, {\n opacity: 0.0,\n fill: false,\n });\n\n circle.addTo(drawLayer);\n\n var bboxes = GetDrawLayerBBoxes();\n\n var rds = (bboxes[0].getNorthWest().lat - bboxes[0].getSouthWest().lat) / 2;\n var polyCrcl = plygonFromCircle(startPoint.lat, startPoint.lng, rds)\n\n L.polygon([polyCrcl, [[90, -180], [90, 180], [-90, 180], [-90, -180]]], {\n weight: 3,\n color: '#00CFFF',\n opacity: 0.9,\n fillColor: '#0C2638',\n fillOpacity: 0.4\n }).addTo(bgLayer);\n circle.addTo(drawLayer);\n } else if (selection.data.search && selection.data.search.searchType === 'path')\n {\n\n var lineLatlngs = _.map(selection.data.search.vertices, function (item) {\n var LatLng = item.split(\",\");\n return {\n lat: LatLng[0],\n lng: LatLng[1]\n }; //item.latLng;\n });\n\n L.polyline(lineLatlngs, {color: 'red', smoothFactor: 1}).addTo(bgLayer);\n\n _.each(feature.geometry.coordinates, function (coords) {\n var points = L.GeoJSON.coordsToLatLngs(coords);\n L.polygon([points, [[90, -180], [90, 180], [-90, 180], [-90, -180]]], {\n weight: 3,\n color: '#00CFFF',\n opacity: 0.9,\n fillColor: '#0C2638',\n fillOpacity: 0.4\n }).addTo(bgLayer);\n\n L.polygon(points, {\n opacity: 0.0,\n fill: false\n }).addTo(drawLayer);\n });\n $rootScope.routeInterpolated = [];\n\n $rootScope.mapSelectionProps = {vertices: []};\n $rootScope.mapSearchType = 'path';\n _.each(lineLatlngs, function (value, index) {\n ($rootScope.mapSelectionProps.vertices).push([value.lat, value.lng].join(','));\n $rootScope.routeInterpolated.push({latLng: {lat: value.lat, lng: value.lng}});\n });\n } else\n {\n _.each(feature.geometry.coordinates, function (coords) {\n var points = L.GeoJSON.coordsToLatLngs(coords);\n //[[[90, 180],[90, -180],[-90, -180],[-90, 180]], polyLatlngs]\n L.polygon([points, [[90, -180], [90, 180], [-90, 180], [-90, -180]]], {\n weight: 3,\n color: '#00CFFF',\n opacity: 0.9,\n fillColor: '#0C2638',\n fillOpacity: 0.4\n }).addTo(bgLayer);\n\n L.polygon(points, {\n opacity: 0.0,\n fill: false\n }).addTo(drawLayer);\n });\n }\n }\n });\n }\n if (selection.data.search)\n {\n setFiltersData(selection.data.search);\n }\n var bboxes = GetDrawLayerBBoxes();\n $timeout(function () {\n GetDataByBBox(bboxes, true);\n }, 100);\n }", "function ajaxForStarships(){\n\t\tcreateDropDown(maxNumberOfStarships, $dropDownStarships);\n\t\thideTheRestDropDowns($dropDownStarships);\n\t\t$spanInfo.text(\"Number of Starships\");\n\t\t$divContent.show();\n\t\t//initial value when link is clicked\n\t\tgenerateStarships(initialNumberDisplayed);\n\t\t// get the ajax request\n\t\t$.get(\"http://swapi.co/api/starships/\", {\t\n\t\t}).done(function(data) {\n\t\t\t$dropDownStarships.on( \"change\", function(){\n\t\t\t\tgenerateStarships($(this).val());\n\t\t\t});\n\t\t\t$table.show();\t\n\t\t}).fail(function() {alert('something went wrong in the ajaxForStarships()!');});\n\t\t//end of ajax request\n\t}", "function LoadViaAjax() {\t\t\r\n\t\t\r\n\t\tFirstLoad();\t\t\r\n\t\tLazyLoad();\t\t\r\n\t\tHeroSection();\r\n\t\tFitThumbScreen();\r\n\t\tPortfolio();\t\t\r\n\t\tBackToTop();\r\n\t\tPageShare();\r\n\t\tSliders();\r\n\t\tJustifiedGrid();\r\n\t\tLightbox();\r\n\t\tAppearIteam();\r\n\t\tContactMap();\r\n\t\tContactForm();\t\t\r\n\t\r\n\t}//End Load Via Ajax\t\t\t\t", "function align_Sketch_Map() {\n\n loc = document.getElementById(\"divider\");\n createProcessingRing(loc);\n\n/* $.when(qualify_MM()).done(function () {\n\n $.when(qualify_SM()).done(function () {\n\n // ajax call for getting the matches dictionary\n $.ajax({\n url: '/alignmentData',\n type: 'GET',\n data: {\n loadedMetricFilename: loadedMetricFilename,\n loadedSketchFilename: fileName_full\n\n },\n contentType: 'text/plain',\n success: function (resp) {\n mapmatches = JSON.parse(resp);\n console.log(mapmatches);\n\n deleteProcessingRing(loc);\n $.alert({\n title: 'Info: Alignment is completed!',\n content: 'Move the mouse over sketch features to find the corresponing feature in the base map.'\n });\n }\n });\n\n });\n });*/\n qualify_MM(function () {\n console.log(\"calling qualify SM\");\n qualify_SM(function () {\n console.log(\"calling alignment\");\n // ajax call for getting the matches dictionary\n $.ajax({\n url: '/alignmentData',\n type: 'GET',\n data: {\n loadedMetricFilename: loadedMetricFilename,\n loadedSketchFilename: fileName_full\n\n },\n contentType: 'text/plain',\n success: function (resp) {\n mapmatches = JSON.parse(resp);\n console.log(mapmatches);\n\n deleteProcessingRing(loc);\n $.alert({\n title: 'Info: Alignment is completed!',\n content: 'Move the mouse over sketch features to find the corresponing feature in the base map.'\n });\n }\n });\n\n });\n });\n\n\n setTimeout(function () {\n var allFeature = map.selectAll(\"path\");\n allFeature.on(\"click\", function () {\n selected = mapClickD3(this, previousOne, selected, \"metric\");\n matchesCheck(\"metric\", mapmatches, this);\n })\n }, 1000);\n}", "static showFreshAppend(){\n const rowlist = document.querySelectorAll('.table-row')\n const id = rowlist[rowlist.length-1].id\n //console.log(id)\n $.ajax({\n url:\"AJAX/AJAX.php\",\n method:\"POST\",\n data:{getlist:id},\n dataType:\"json\",\n success:function(data)\n {\n //document.querySelector('#results').innerHTML=''\n view.renderList(data)\n\n //Course.renderBasicCategoriesForUser(data);\n //return data;\n\n },error:function (data){\n //console.log(data)\n }\n });\n }", "function success() {\n finish( false );\n }", "function getCourse() {\n $(document).ajaxStart(function () {\n $(\"#wait\").css(\"display\", \"block\");\n });\n $(document).ajaxComplete(function () {\n $(\"#wait\").css(\"display\", \"none\");\n });\n var web_xml_address = \"find-course\";\n var course = document.getElementById(\"course\").value;\n var format = document.getElementById(\"format1\").value;\n var address = web_xml_address + \"?coursename=\" + course + \"&format=\" + format;\n\n switch (format) {\n case \"json\":\n getJSONData(address);\n break;\n case \"text\":\n getTextData(address);\n break;\n case \"xml\":\n getXMlData(address)\n break;\n }\n\n}", "function handleFinish(event) {\n cleanup(null, responseData)\n }" ]
[ "0.6221699", "0.60419905", "0.5939407", "0.575101", "0.57254285", "0.5719794", "0.5707946", "0.56172913", "0.56141114", "0.56125903", "0.5612564", "0.5610286", "0.5551636", "0.55483323", "0.55476314", "0.55326897", "0.55158186", "0.55039513", "0.54837465", "0.5482504", "0.5474509", "0.54607475", "0.5448729", "0.5434972", "0.54332733", "0.5431614", "0.54182416", "0.541707", "0.54059833", "0.5404762", "0.54043186", "0.53911877", "0.53885245", "0.53862727", "0.5382304", "0.53654444", "0.5364116", "0.5363052", "0.5355856", "0.5352874", "0.5348648", "0.53478616", "0.53476554", "0.5346833", "0.5345018", "0.5343345", "0.53366786", "0.53321767", "0.53265613", "0.5326491", "0.53241503", "0.5323805", "0.52906775", "0.5275782", "0.5274418", "0.5268205", "0.5267342", "0.52666235", "0.5265319", "0.5262709", "0.52592736", "0.5258752", "0.5258696", "0.5256422", "0.5254182", "0.52540505", "0.52540505", "0.52498966", "0.52496856", "0.5247925", "0.5245202", "0.5245202", "0.5245202", "0.5245202", "0.5244484", "0.524282", "0.5234668", "0.5234668", "0.5230796", "0.52302784", "0.52294695", "0.5225428", "0.5219588", "0.52177495", "0.5211843", "0.5211127", "0.5210955", "0.5208496", "0.5206865", "0.52049744", "0.5203604", "0.52025676", "0.5202012", "0.5200189", "0.51988083", "0.51980877", "0.51933724", "0.51905733", "0.5186846", "0.51864225", "0.51860464" ]
0.0
-1
makes the content ready so that it can be sent to the server
function up_db(c) { secondlayer(true); var locid=$id("loc").value; keypress(false); var t2={}; t2['a_type']=c.name; var find_radio=[]; for(var i=0;i<c.length;i++) { if(c[i].name!="" && !c[i].disabled && (c[i].getAttribute("c_req")=="true" || c[i].getAttribute("c_req")=="false") ) { if(c[i].type=="radio") { if(find_radio.indexOf(c[i].name)<0) find_radio.push(c[i].name); } else {t2[c[i].name]=c[i].value;} } } for(var i=0;i<find_radio.length;i++) { var s=c[find_radio[i]]; for (x in s) if(s[x].checked) { t2[find_radio[i]]=s[x].value; } } t2['locid']=locid; secondlayer(true,"Uploading Data Please Wait <br>"); t2['file']=new Array(); t2['url']=new Array(); for(var i=0;i<c_alldata.length;i++) { if(c_alldata[i].c_type=="file") { UploadFile(c_alldata[i]); var ttx=new Object(); ttx.name=c_alldata[i].c_name; ttx.title=c_alldata[i].c_title; ttx.type=c_alldata[i].ext; t2['file'].push(ttx); } else { var ttx=new Object(); ttx.name=c_alldata[i].c_url; ttx.title=c_alldata[i].c_title; ttx.type=c_alldata[i].ext; t2['url'].push(ttx); t2[c_alldata[i].c_disp.id]=c_alldata[i].c_type; } } track.send=JSON.stringify(t2); if(c_alldata.length==0||t2['type']=="video"||t2['img']=='imageurl') track.finish(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "ready() {\n super.ready();\n const that = this;\n\n that._template = that._handleTemplate();\n\n if (that._template.hasBindings) {\n that.innerHTML = that._processTemplate();\n }\n else if (that.itemTemplate) {\n that.innerHTML = that._template.content;\n }\n\n if (that.contentHandler) {\n that.contentHandler(that);\n }\n }", "function onReady() {\n\t\t\tvar container;\n\t\t\tvar state;\n\t\t\tvar tmp;\n\t\t\tvar el;\n\n\t\t\t// Process the request once the request is complete and successful...\n\t\t\tif ( this.readyState === 4 && this.status === 200 ) { // eslint-disable-line no-invalid-this\n\t\t\t\t// Create a temporary DOM element into which we can insert the request HTML page (note: we don't have to worry about the requested HTML containing script tags, as script content is not executed when using `innerHTML`):\n\t\t\t\tcontainer = document.createElement( 'div' );\n\t\t\t\tcontainer.innerHTML = this.responseText; // eslint-disable-line no-invalid-this\n\n\t\t\t\t// Extract the content we want to load into the existing page:\n\t\t\t\ttmp = container.querySelector( '.readme' );\n\n\t\t\t\t// Insert the content into the page:\n\t\t\t\tel = document.querySelector( '.readme' );\n\t\t\t\tel.innerHTML = tmp.innerHTML;\n\n\t\t\t\t// Update the top navigation:\n\t\t\t\ttmp = container.querySelector( '.top-nav' );\n\t\t\t\tel = document.querySelector( '.top-nav' );\n\t\t\t\tel.innerHTML = tmp.innerHTML;\n\n\t\t\t\t// Reset the scroll position:\n\t\t\t\tdocument.querySelector( 'body' ).scrollTop = 0;\n\n\t\t\t\t// Update the document title:\n\t\t\t\tdocument.title = container.querySelector( 'title' ).innerHTML;\n\n\t\t\t\t// Update browser history (note: browser history API available IE10+):\n\t\t\t\tif ( bool && history && history.pushState ) {\n\t\t\t\t\tstate = {\n\t\t\t\t\t\t'url': url\n\t\t\t\t\t};\n\t\t\t\t\thistory.pushState( state, '', url );\n\t\t\t\t}\n\t\t\t}\n\t\t}", "function PublishContent(content,id) {\n try {\n if (content.readyState == 4) {\n if(content.status == 200) { \n \n document.getElementById(id).innerHTML=content.responseText;\n $('#content-swapper').fadeIn(800); // Use jQuery to fade content in\n } else { \n // Display alert if content does not exist\n alert('\\n\\nContent request error, status code:\\n'+content.status+' '+content.statusText); \n }\n }\n }\n catch(error) { \n alert('Error: '+error.name+' -- '+error.message); \n }\n}", "sendPageReady() {}", "async function onLoad() {\n\n let result = await sendRequest();\n articles = result.news;\n console.log(articles);\n\n createHTML();\n}", "setAsReady() {\n this.logger.debug('Page is ready to use');\n this.controller.store();\n }", "function cb_contentLoaded(cb) {}", "function handleContentReady () {\r\n\t\t // Allows the uploader to send log messages to trace, as well as to YAHOO.log\r\n\t\t\tuploader.setAllowLogging(false);\r\n\t\t\t\r\n\t\t\t// Disallows multiple file selection in \"Browse\" dialog.\r\n\t\t\tuploader.setAllowMultipleFiles(false);\r\n\t\t\t\r\n\t\t\t// New set of file filters.\r\n\t\t\tvar ff = new Array({description:\"Images\", extensions:\"*.jpg;*.png;*.gif\"});\r\n\t\t\t\r\n\t\t\t// Apply new set of file filters to the uploader.\r\n\t\t\tuploader.setFileFilters(ff);\r\n\t\t}", "function fillContent() {\r\n\t\tdebug('fillContent');\r\n\t\tif (!modal.tmp.html())\r\n\t\t\treturn;\r\n\r\n\t\tmodal.content.html(modal.tmp.contents());\r\n\t\tmodal.tmp.empty();\r\n\t\twrapContent();\r\n\r\n\t\tif (currentSettings.type == 'iframeForm') {\r\n\t\t\t$(currentSettings.from)\r\n\t\t\t\t.attr('target', 'nyroModalIframe')\r\n\t\t\t\t.data('processing', 1)\r\n\t\t\t\t.submit()\r\n\t\t\t\t.attr('target', '_blank')\r\n\t\t\t\t.removeData('processing');\r\n\t\t}\r\n\r\n\t\tif ($.isFunction(currentSettings.endFillContent))\r\n\t\t\tcurrentSettings.endFillContent(modal, currentSettings);\r\n\r\n\t\tmodal.content.append(modal.scripts);\r\n\r\n\t\t$(currentSettings.closeSelector, modal.contentWrapper).click(removeModal);\r\n\t\t$(currentSettings.openSelector, modal.contentWrapper).nyroModal(getCurrentSettingsNew());\r\n\t}", "ready() {\n if (this._prepareIx === this._prepare.length-1) {\n this._state = 1;\n this.emit('ready');\n } else {\n this.prepare();\n }\n }", "ready() {\n const that = this;\n\n super.ready();\n\n that._isParentPositionStatic = window.getComputedStyle(that.parentElement || document.querySelector('body')).position === 'static';\n that._handleSelector(that.selector);\n\n if (that.visible) {\n that._applyPosition();\n }\n\n that._handleEventListeners();\n that._handleResize();\n\n that.value = that.$.content.innerHTML = that.value ? that.value : that.innerHTML;\n that._handleTemplate();\n }", "function doSomethingAfterRendering(){\n displayLoading() // 로딩화면 보여주기\n fetchServer(); // 서버에서 데이터 가져오기\n }", "function load() {\n \n //writes all the html for the page\n htmlWriter();\n }", "function loaded(error, response, body) {\n // Check for errors\n if (!error && response.statusCode == 200) {\n // The raw HTML is in body\n res.send(body);\n } else {\n res.send(response);\n }\n }", "render_body_content(path, param) {\n let action = this.click_to_load_main;\n\n if (this.action !== null) {\n let body_content_element = $('#item_content');\n\n if (body_content_element.length > 0) {\n let result = null;\n\n $.ajax({\n method: \"POST\",\n url: path,\n // async: false\n })\n .done((msg) => {\n body_content_element\n .html(msg)\n .promise()\n .then(this.init(param));\n this.msg = msg;\n\n return this;\n })\n .fail((msg) => {\n console.log(\"Error\");\n this.msg = msg;\n return this;\n });\n\n return this;\n } else {\n alert(\"No load_out selected!\");\n return this;\n }\n } else {\n console.log(\"No intent declared\");\n return this;\n }\n return this;\n }", "init() {\n\t\treturn this.loadContent();\n\t}", "static ready() { }", "ready() {\r\n\t\tsuper.ready();\r\n\t}", "function loadContent () {\n\t\t$feedOverlay.removeClass(\"hidden\");\n\t\tMassIdea.loadHTML(SEL_CONTENT, URL_LOAD_FEED, function () {\n\t\t\t$feedOverlay.addClass(\"hidden\");\n\t\t\tresetTimer();\n\t\t});\n\t}", "async fetchContent() {\n this.srcAssigned = true;\n try {\n this.data = await dxp.api(this.src);\n this.assignContent();\n }\n catch (e) {\n dxp.log.error(this.container.tagName, 'fetchContent()', `cms fetch failed for ${this.src}`, e);\n this.srcFailed.emit({ src: this.src });\n }\n }", "make() {\n\t\t\tif(this.before_load) { this.before_load(this); }\n\n\t\t\tthis.$body = $((\"<div class=\\\"slide-body\\\">\\n\\t\\t\\t<div class=\\\"content text-center\\\">\\n\\t\\t\\t\\t<p class=\\\"title lead\\\">\" + (this.title) + \"</p>\\n\\t\\t\\t</div>\\n\\t\\t\\t<div class=\\\"form-wrapper\\\">\\n\\t\\t\\t\\t<div class=\\\"form\\\"></div>\\n\\t\\t\\t\\t<div class=\\\"add-more text-center\\\" style=\\\"margin-top: 5px;\\\">\\n\\t\\t\\t\\t\\t<a class=\\\"form-more-btn hide btn btn-default btn-xs\\\">\\n\\t\\t\\t\\t\\t\\t<span>Add More</span>\\n\\t\\t\\t\\t\\t</a>\\n\\t\\t\\t\\t</div>\\n\\t\\t\\t</div>\\n\\t\\t</div>\")).appendTo(this.$wrapper);\n\n\t\t\tthis.$content = this.$body.find(\".content\");\n\t\t\tthis.$form = this.$body.find(\".form\");\n\t\t\tthis.$primary_btn = this.slides_footer.find('.primary');\n\t\t\tthis.$form_wrapper = this.$body.find(\".form-wrapper\");\n\n\t\t\tif(this.image_src) { this.$content.append(\n\t\t\t\t$((\"<img src=\\\"\" + (this.image_src) + \"\\\" style=\\\"margin: 20px;\\\">\"))); }\n\t\t\tif(this.help) { this.$content.append($((\"<p class=\\\"slide-help\\\">\" + (this.help) + \"</p>\"))); }\n\n\t\t\tthis.reqd_fields = [];\n\n\t\t\tthis.refresh();\n\t\t\tthis.made = true;\n\t\t}", "function fillContent() {\n debug('fillContent');\n if (!modal.tmp.html())\n return;\n\n modal.content.html(modal.tmp.contents());\n modal.tmp.empty();\n wrapContent();\n\n if (currentSettings.type == 'iframeForm') {\n $(currentSettings.from)\n .attr('target', 'nyroModalIframe')\n .data('nyroModalprocessing', 1)\n .submit()\n .attr('target', '_blank')\n .removeData('nyroModalprocessing');\n }\n \n if (!currentSettings.modal)\n modal.wrapper.prepend(currentSettings.closeButton);\n \n if ($.isFunction(currentSettings.endFillContent))\n currentSettings.endFillContent(modal, currentSettings);\n\n modal.content.append(modal.scripts);\n\n $(currentSettings.closeSelector, modal.contentWrapper)\n .unbind('click.nyroModal')\n .bind('click.nyroModal', removeModal);\n $(currentSettings.openSelector, modal.contentWrapper).nyroModal(getCurrentSettingsNew());\n }", "ready() { }", "ready() { }", "ready() { }", "ready() { }", "ready() { }", "ready() { }", "ready() { }", "ready() { }", "function buildPage() {\n // Load Reusables\n $.get('includes/reusables.html', (reusables) => {\n $(\"br\").before(reusables);\n }).promise().done(() => {\n console.log(\"<Loader> Reusables loaded\");\n \n // Load Start Scene\n $.get('includes/start_scene.html', (start_scene) => {\n $(\"br\").before(start_scene);\n }).promise().done(() => {\n console.log(\"<Loader> Start scene loaded\");\n \n // Load Play Scene\n $.get('includes/play_scene.html', (play_scene) => {\n $(\"br\").before(play_scene);\n }).promise().done(() => {\n console.log(\"<Loader> Play scene loaded\");\n \n // Load Leaderboard Scene\n $.get('includes/leaderboard_scene.html', (leaderboard_scene) => {\n $(\"br\").before(leaderboard_scene);\n }).promise().done(() => {\n console.log(\"<Loader> Leaderboard scene loaded\");\n\n // Load End Scene\n $.get('includes/end_scene.html', (end_scene) => {\n $(\"br\").before(end_scene);\n }).promise().done(() => {\n console.log(\"<Loader> End scene loaded\");\n\n // Load Game Scripts\n $(\"#abofScripts\").html('<script src=\"scripts/engine.js\"></script>').promise().done(function() {\n $(\"#abofScripts script\").after('<script src=\"scripts/game.js\"></script>').promise().done(() => {\n $.when(\"#abofScripts\").done(() => {\n console.log(\"<Loader> Executing scripts...\");\n // Remove the <br> tag placeholder\n $(\"br\").remove();\n game.google.load();\n });\n });\n });\n });\n });\n });\n });\n });\n}", "function render_documento(){\n if (ready_page == false){\n //empezamos a contar los segundo para poder descargar el documento\n setTimeout(validar_regla_descarga, rule_time_dowload);\n ready_page = true;\n }\n}", "function gotData(err, result) {\n select('.bodyText').elt.innerHTML = tempBody;\n if (err) {\n console.error(err);\n }\n if (result) {\n // Update the status log\n generateButton.show();\n pauseButton.show();\n select('#status').html('Ready!');\n select('.bodyText').elt.innerHTML += generateBotBox(result.sample);\n foo.resume();\n foo.speak(result.sample);\n generateButton.elt.disabled = false;\n runningInference = false;\n // text2Image();\n }\n }", "ready() {\n super.ready();\n this._createElement();\n }", "ready() {}", "ready() {}", "ready() {}", "async _onReady() {\n // Make the editor \"complex.\" This \"fluffs\" out the DOM and makes the\n // salient controller objects.\n this._editorComplex =\n new EditorComplex(this._sessionInfo, this._window, this._editorNode);\n\n await this._editorComplex.whenReady();\n this._recoverySetup();\n }", "function isReady() {\n\t\t\treturn ready;\n\t\t}", "async _onReady() {\n // Make the editor \"complex.\" This \"fluffs\" out the DOM and makes the\n // salient controller objects.\n this._editorComplex =\n new EditorComplex(this._sessionKey, this._window, this._editorNode);\n\n await this._editorComplex.whenReady();\n this._recoverySetup();\n }", "function ensureReadiness() {\n\n\t \t//Check state and status and return nothing if not ready.\n\t \tif(request.readyState < 4) {\n\t \t\treturn;\n\t \t}\n\t \tif(request.status !== 200) {\n\t \t\treturn;\n\t \t}\n\n\t //Check if ready.\n\t if(request.readyState === 4) {\n\n\t \t//Store the info about the pages in data array of app object.\n\t \tapp.data = JSON.parse(this.response).pages;\n\n\t //Populate the top pages.\n\t app.populateTopPages();\n\t }\n\t }", "setIsReady() {\n this.isReady_ = true;\n this.flushQueue_();\n }", "ready() {\n this._root = this._createRoot();\n super.ready();\n this._firstRendered();\n }", "ready() {\n super.ready();\n }", "ready() {\n super.ready();\n }", "ready() {\n super.ready();\n }", "ready() {\n super.ready();\n }", "ready() {\n super.ready();\n }", "ready() {\n super.ready();\n }", "ready() {\n super.ready();\n }", "ready() {\n super.ready();\n }", "ready() {\n super.ready();\n }", "ready() {\n super.ready();\n }", "ready() {\n super.ready();\n }", "ready() {\n super.ready();\n }", "onReady() {}", "function buildTemplate() {\n\t\tpageTitle = new C_PageTitle();\n\n //Add classes for page layouts - updatable in css\n $('#stage').append('<div id=\"content\" class=\"lessonCon\"></div>');\n\n $(\"#content\").append(myContent);\n\t\t\n\t\taudioHolder = new C_AudioHolder();\n\t\t \n if(transition == true){\n\t\t\t// fade stage in\n\t\t\t$('#stage').velocity({\n\t\t\t\topacity: 1\n\t\t\t}, {\n\t\t\t\tduration: transitionLength,\n\t\t\t\tcomplete: checkMode\n\t\t\t});\n }else{\n \tcheckMode();\n }\n }", "function initPage() {\n $.get('/api/headlines?saved=true').done((data) => {\n articleContainer.empty();\n\n if (data && data.length > 0) {\n renderArticles(data);\n\n // Activate tooltips for the action buttons.\n $('[data-toggle=\"tooltip\"]').tooltip();\n } else {\n renderEmpty();\n }\n });\n }", "function contentPrepComplete() {\n // Loop through our pages.\n siteIndex.content.forEach((file) => {\n // Index pages are special cased to allow site maps and sectional nav.\n if (file.localName.endsWith('/index.html')) {\n parsers.loadTemplate('map', {\n map: siteIndex.map,\n }).then((response) => {\n parsers.loadTemplate('index', {\n page: {\n content: file.html,\n sidebar: '',\n title: file.title,\n map: response,\n tags: siteIndex.tags,\n },\n });\n }).then((response) => {\n parsers.loadTemplate('html', {\n page: response,\n });\n }).then((fullResponse) => {\n fileHandlers.outputFile(siteConfig, file, fullResponse);\n });\n } else {\n // All other pages go on through (at least for now).\n parsers.loadTemplate('page', {\n page: {\n content: file.html,\n sidebar: '',\n title: file.title,\n },\n }).then((response) => {\n parsers.loadTemplate('html', {\n page: response,\n }).then((fullResponse) => {\n fileHandlers.outputFile(siteConfig, file, fullResponse);\n });\n });\n }\n });\n\n // Copy supporting files.\n fileHandlers.copyHandler(siteConfig);\n}", "function loadData() {\n\t// Detect if HTTP object exists and is not busy\n\tif (http && !isWorking) {\n\t\t//http.open('get','http://people.rit.edu/~met8481/536/project_1/ajax/data/content.js');\n\t\thttp.open('get','DATA/content.js');\n\t\thttp.onreadystatechange=handleHttpResponse;\n\t\thttp.send();\n\t\tisWorking = true;\n\t}\n}", "function ready() {\n if (!isReady) {\n triggerEvent(document, \"ready\");\n isReady = true;\n }\n }", "function LoadContent(){\n\t\n\ttrace(\"LoadContent: Has API loaded and been properly initialized?:\"+String(IsLoaded()));\n\t\n\tif(!IsLoaded()) {\n\t\ttrace(\"Error loading API - Aborting!\");\n\t\treturn;\n\t}\n\n\ttrace(\"Exiting Load content...\");\n\treturn;\n\t\n}", "ready() {\n this.isReady = true;\n if (this.onLoad) {\n this.onLoad.call();\n }\n }", "ready() {\n super.ready();\n const that = this;\n\n that._createElement();\n }", "async setContent(){\n if(this._instanceDestroyed) return;\n await tryWithPageAwareness(async () => {\n await this._page.setContent(...arguments, { waitUntil: 'load'});\n await this._reflectContents();\n });\n }", "function loadNewDone(response) {\n if (response.html) {\n _content.prepend(response.html);\n }\n }", "ready() {\n super.ready();\n\n const that = this;\n\n that._render();\n }", "function setAssetReady() {\n this.ready = true;\n }", "function getReady() {\n $(\"#overLayForm\").css(\"display\", \"none\");\n _song.pause();\n _song.currentTime = 0;\n $(\"#overLayMessage\").text(\"READY\");\n $(\"#overLaySubMess\").text(\"\");\n $(\"#recordButt2\").css(\"display\", \"none\");\n setTimeout(function() {\n $(\"#overLayMessage\").text(\"SET\");\n setTimeout(function() {\n _song.play();\n _started = true;\n _recording = true;\n if (!_restarted) record();\n $(\"#overLayMessage\").text(\"\");\n $(\"#restartButt\").css(\"visibility\", \"visible\");\n $(\"#saveNowButt\").css(\"visibility\", \"visible\");\n $(\"#recordButt\").text(\"pause\");\n }, _readyTimer);\n }, _readyTimer);\n }", "function initPage() {\n $.get('/api/headlines?saved=false').done((data) => {\n articleContainer.empty();\n if (data && data.length > 0) {\n renderArticles(data);\n\n // Activate tooltips for the action buttons.\n $('[data-toggle=\"tooltip\"]').tooltip();\n } else {\n renderEmpty();\n }\n });\n }", "pageReady() {}", "function _onready(events){\n\t\t\t\t \n\t\t\t\t\t//Trigger all the json2html.ready events\n\t\t\t\t\tfor(var i=0; i < events.length; i++) \n\t\t\t\t\t\tevents[i].trigger(\"j2h.ready\");\n\t\t\t\t}", "function loadContentReady(html) {\n that.$ddlContainer.empty().append(html);\n that.$element.trigger($.Event('loader.hidden.ts.ddl'));\n that.$ddlContainer.children().data('ts.ddl', that);\n openDdlWithEffect();\n\n }", "ready() {\n super.ready();\n\n afterNextRender(this, function() {});\n }", "ready() {\n super.ready();\n\n afterNextRender(this, function() {});\n }", "ready() {\n super.ready();\n\n afterNextRender(this, function() {});\n }", "function loadContent() {\n $.ajax({\n url: 'ajax-get-page-content',\n type: 'GET',\n data: $data,\n beforeSend: function() {},\n success: function(response) {\n $('div#main-content').html(response);\n location.hash = $data.page || '';\n },\n complete: function(response) {\n loadModuleScript();\n }\n });\n }", "get contentAvailable() {\n return (\n (this.contentReady && this.hasRenderContent) ||\n (defined(this._expiredContent) && !this.contentFailed)\n );\n }", "get contentAvailable() {\n return (\n (this.contentReady && this.hasRenderContent) ||\n (defined(this._expiredContent) && !this.contentFailed)\n );\n }", "function getContent(){\n $.get('api/content')\n .done(function (result) {\n if(result.success){\n $('#currentContent').html(renderCurrent(result.currentContent));\n $('#upcomingContent').html(renderCurrent(result.upcomingContent));\n $('#missedContent').html(renderCurrent(result.missedContent));\n } else {\n console.log(\"GET request failed\");\n }\n })\n .fail(function(){\n console.log(\"GET request failed\");\n });\n}", "function load_content(content, callback) {\n var container = select(\"id\",\"content\").js_object;\n container.setAttribute(\"class\", \"transparent\");\n setTimeout(function() {\n container.innerHTML = content;\n container.setAttribute(\"class\", \"\");\n callback();\n }, 500);\n}", "function get_page_data() {\n socket.emit('get_page_data', {data: ''});\n //call server to tell we want all data, so we can fill the ui (normally done once on full page load/refresh)\n}", "ready( payload ) {\n console.log( 'Application.ready' );\n let div = document.querySelector( '#output' );\n div.innerHTML = payload;\n }", "function loadContent () {\n\t\tvar contentId = $(\"#contentId\").val();\n\t\tif (!isEmpty(contentId)) {\n\t\t\tloadContentById (contentId);\n\t\t}\t\n\t}", "async function pageConstruct () {\n let i, bodyNode, emptyElement\n\n IMLibCalc.calculateRequiredObject = {}\n INTERMediator.currentEncNumber = 1\n INTERMediator.elementIds = []\n\n // Restoring original HTML Document from backup data.\n bodyNode = document.getElementsByTagName('BODY')[0]\n if (INTERMediator.rootEnclosure === null) {\n INTERMediator.rootEnclosure = bodyNode.innerHTML\n } else {\n bodyNode.innerHTML = INTERMediator.rootEnclosure\n }\n postSetFields = []\n INTERMediatorOnPage.setReferenceToTheme()\n IMLibPageNavigation.initializeStepInfo(false)\n\n IMLibLocalContext.bindingDescendant(document.documentElement)\n\n try {\n await seekEnclosureNode(bodyNode, null, null, null)\n } catch (ex) {\n if (ex.message === '_im_auth_required_') {\n throw ex\n } else {\n INTERMediatorLog.setErrorMessage(ex, 'EXCEPTION-9')\n }\n }\n\n // After work to set up popup menus.\n for (i = 0; i < postSetFields.length; i++) {\n if (postSetFields[i].value === '' &&\n document.getElementById(postSetFields[i].id).tagName === 'SELECT') {\n // for compatibility with Firefox when the value of select tag is empty.\n emptyElement = document.createElement('option')\n emptyElement.setAttribute('id', INTERMediator.nextIdValue())\n emptyElement.setAttribute('value', '')\n emptyElement.setAttribute('data-im-element', 'auto-generated')\n document.getElementById(postSetFields[i].id).insertBefore(\n emptyElement, document.getElementById(postSetFields[i].id).firstChild)\n }\n document.getElementById(postSetFields[i].id).value = postSetFields[i].value\n }\n IMLibCalc.updateCalculationFields()\n IMLibPageNavigation.navigationSetup()\n\n if (isAcceptNotify && INTERMediator.pusherAvailable) {\n let channelName = INTERMediatorOnPage.clientNotificationIdentifier()\n let appKey = INTERMediatorOnPage.clientNotificationKey()\n if (appKey && appKey !== '_im_key_isnt_supplied' && !INTERMediator.pusherObject) {\n try {\n Pusher.log = function (message) {\n if (window.console && window.console.log) {\n window.console.log(message)\n }\n }\n\n INTERMediator.pusherObject = new Pusher(appKey)\n INTERMediator.pusherChannel = INTERMediator.pusherObject.subscribe(channelName)\n INTERMediator.pusherChannel.bind('update', function (data) {\n IMLibContextPool.updateOnAnotherClient('update', data)\n })\n INTERMediator.pusherChannel.bind('create', function (data) {\n IMLibContextPool.updateOnAnotherClient('create', data)\n })\n INTERMediator.pusherChannel.bind('delete', function (data) {\n IMLibContextPool.updateOnAnotherClient('delete', data)\n })\n } catch (ex) {\n INTERMediatorLog.setErrorMessage(ex, 'EXCEPTION-47')\n }\n }\n }\n appendCredit()\n }", "function serial () {\n let promise = Promise.resolve();\n promise\n .then(call_backweb1)\n .then((rr) => {\n return new Promise((resolve,reject) => {\n //console.log(rr.body.title.body);\n //console.log(rr.body.contents.body);\n totalrr.title.body = rr.body.title.body;\n totalrr.contents.body = rr.body.contents.body;\n resolve(\"connection complete\");\n });\n })\n .then(render_page);\n }", "function getRealContent(resList,url,success){\n var $ = Zepto;\n var distUrl = pathJoin(location.href,url);\n \n $.ajax({\n url:distUrl,\n dataType:'html',\n cache:false,\n success:function(data){\n //alert(window.DOMParser);\n //var dp = new DOMParser();\n //var dom = dp.parseFromString(data,'text/html');\n //remove datatype\n \n data = data.replace(/<!\\s*doctype[^>]+>/i,'');\n var hp = htmlParser(data,{fix:true});\n \n \n var resource = {\n styleList:[],\n scriptList:[],\n linkList:[]\n };\n \n var tokenState = 0;//0:无状态。1:标签开始。2:内容。3:结束\n var tokenText = [];\n var token;\n var resData = '';\n var bodyData = '';\n var isInHeader = false;\n \n while(token = hp.readToken()){\n if(token.type === 'atomicTag'){\n if(token.tagName === 'script'){\n var src = token.attrs.src;\n if(src){\n src = pathJoin(location.href,src);\n if(src && (src in resList)){\n \n }else{\n resData += token.text;\n resource.scriptList.push(token);\n }\n }else{\n resData += token.text;\n resource.scriptList.push(token);\n }\n }else if(token.tagName === 'style'){\n \n if(isInHeader){\n resource.styleList.push(token);\n }\n \n if(tokenState === 1){\n bodyData += token.text;\n }\n \n }else{\n resData += token.text;\n if(tokenState === 1){\n bodyData += token.text;\n }\n }\n continue;\n }\n \n if(token.type === 'startTag'){\n if(tokenState === 1){\n bodyData += token.text;\n }\n if(token.unary === true){\n if(token.tagName !== 'link'){\n resData += token.text;\n }else{\n //\n var href = pathJoin(location.href,token.attrs.href);\n if(href && (href in resList)){\n \n }else{\n resource.linkList.push(token); \n }\n }\n }\n if(token.tagName === 'head'){\n isInHeader = true;\n }\n if(token.tagName === 'body'){\n bodyData += token.text;\n tokenState = 1;\n }\n resData += token.text;\n continue;\n }\n \n if(token.type === 'endTag'){\n if(tokenState === 1){\n bodyData += token.text;\n }\n if(token.tagName === 'head'){\n isInHeader = false;\n }\n if(token.tagName === 'body'){\n tokenState = 0;\n }\n resData += token.text;\n continue;\n }\n resData += token.text;\n bodyData += token.text;\n }\n \n //显示数据\n success.call(null,bodyData,resource);\n }\n });\n \n }", "function ready () {\n\t\t this._isAttached = true\n\t\t this._isReady = true\n\t\t this._callHook('ready')\n\t\t}", "function handleContentReady() {\n // Allows the uploader to send log messages to trace, as well as to YAHOO.log\n // uploader.setAllowLogging(true);\n\n // Allows multiple file selection in \"Browse\" dialog.\n uploader.setAllowMultipleFiles(true);\n\n // New set of file filters (separate filter masks with semicolons).\n var ff = new Array({ description: \"JPEG Images\", extensions: \"*.jpg\" });\n\n // Apply new set of file filters to the uploader.\n uploader.setFileFilters(ff);\n}", "function initContent() {\n var msHide = document.querySelectorAll('.ms-hide');\n\n /**\n * Place the Yellow ribbon after the header.\n */\n $('#s4-workspace').prepend($('#DeltaPageStatusBar'));\n\n if (msHide.length > 0) {\n /**\n * Hide all right section web parts that are marked as \"hidden\".\n */\n if ($('.ms-hide').closest('.right-section')) {\n $('.right-section .ms-hide').parent().hide();\n }\n checkContentTypes();\n checkOrgChartZone();\n checkGatewayPage();\n }\n\n adjustArticleImageBlock();\n adjustWireStories();\n collapsibleList();\n customCheckboxes();\n howDoI();\n articleComments();\n startMyVMSNet();\n startUserControls();\n\n /**\n * Window Load Events.\n */\n window.addEventListener('load', function () {\n introText();\n wireStories();\n wireCatagory();\n updateMoreSearchText();\n });\n }", "function pushContent() {\n var hasContent = writeFromBufferList(buffers);\n if (hasContent) setTimeout(pushContent, 20);\n }", "ready() {\n super.ready();\n\n\n }", "function initial() {\n\t$('.load-to-content').off('click');\n\t$('.load-to-content').on('click', function (event) {\n\t\tevent.preventDefault();\n\t\tlet url = $(this).attr('href');\n\t\tloadContent(url, 'get');\n\t});\n\n\t// Ketika form di submit\n\t$('form.form-load-to-content').on('submit', function (event) {\n\t\tevent.preventDefault();\n\t\tlet url = $(this).attr('action');\n\t\tloadContent(url, 'post', new FormData(this));\n\t});\n}", "firstUpdated() {\n this.__ready = true;\n if (this._x2js) {\n if (this.auto) {\n this.shadowRoot.querySelector(\"#rssajax\").auto = this.auto;\n } else {\n this.initRequest();\n }\n }\n }", "function _buildReady(){\n var objectId, obj, i, mrkrlist;\n var count = 0;\n for (objectId in waitingForRenderable){\n ++count;\n mrkrlist = waitingForRenderable[objectId];\n obj = Human.scene.objects[objectId];\n if (obj && obj.isVisible()) {\n for (i=0; i < mrkrlist.length; i++){\n mrkrlist[i].build();\n }\n delete waitingForRenderable[objectId];\n --count;\n }\n }\n waiting = count > 0;\n }", "function tu_ShowContent(){ \n if(data.insideOf){\n \t\t\t\t\tif(data.append) jQuery(data.insideOf).append(objContent);\n \t\t\t\t\telse jQuery(data.insideOf).html(objContent);\n var content_height = jQuery(objContent).css(\"height\");\n jQuery(objContent).css(\"height\", \"0px\");\n jQuery(objContent).delay(data.delay).animate({height:content_height}, data.duration, data.ease);\n \t\t\t\t}else if(data.beforeOf){\n jQuery(objContent).insertBefore(jQuery(data.beforeOf));\n var content_height = jQuery(objContent).css(\"height\");\n \t\t\t\t\tjQuery(objContent).css(\"height\", \"0px\");\n \t\t\t\t\tjQuery(objContent).delay(data.delay).animate({height:content_height}, data.duration, data.ease);\n \t\t\t\t}else if(data.afterOf){\n jQuery(objContent).insertAfter(jQuery(data.afterOf));\n var content_height = jQuery(objContent).css(\"height\");\n \t\t\t\t\tjQuery(objContent).css(\"height\", \"0px\");\n \t\t\t\t\tjQuery(objContent).delay(data.delay).animate({height:content_height}, data.duration, data.ease);\n \t\t\t\t}else if(data.prepend){\n \t\t\t\t jQuery(data.prepend).prepend(objContent);\n \t\t\t\t}else{\n jQuery(\"body\").append(objContent);\n \t\t\t\t} \n }", "function readyStateChange()\n {\n if (document.readyState === \"complete\")\n {\n ready();\n }\n }", "function pageInitalize(){\n\n articleContainer.empty();//Empties article container.//\n $.get(\"/api/headlines?saved=false\").then(function(data){//Runs AJAX request for unsaved\n if (data && data.length) {//Renders found headlines to the page.//\n renderArticles(data);\n }else{\n renderEmpty();//Renders no articles message.//\n }\n });\n }", "async function loadContent(id) {\n console.log(`Loading content for id=${id}`);\n let response = await fetch(`${window.location.origin}/${id}.html`);\n try {\n if (response.ok) {\n let content = await response.text();\n document.querySelector(\"#main\").innerHTML = content;\n if (id == \"pedidos\") {\n initOrders();\n } \n } else {\n console.log(\"Error loading\" + id);\n }\n } catch(error) {\n console.log(error);\n } \n }", "function ready() {\n\t if (READY) return;\n\t READY = 1;\n\t utils.each(READY_BUFFER, function (connect) {\n\t connect();\n\t });\n\t}", "function ready () {\n\t this._isAttached = true\n\t this._isReady = true\n\t this._callHook('ready')\n\t}" ]
[ "0.6192604", "0.6152417", "0.6081952", "0.6045814", "0.5973004", "0.5971583", "0.59261626", "0.5892219", "0.5872687", "0.5861844", "0.5820321", "0.5819373", "0.57933855", "0.5791685", "0.57801795", "0.5752454", "0.5742327", "0.5722428", "0.5707562", "0.5705178", "0.5682829", "0.5668937", "0.56570107", "0.56570107", "0.56570107", "0.56570107", "0.56570107", "0.56570107", "0.56570107", "0.56570107", "0.56457555", "0.56306255", "0.55973816", "0.559471", "0.5585188", "0.5585188", "0.5585188", "0.5580073", "0.5574263", "0.5552926", "0.5551117", "0.5544278", "0.55317634", "0.55296695", "0.55296695", "0.55296695", "0.55296695", "0.55296695", "0.55296695", "0.55296695", "0.55296695", "0.55296695", "0.55296695", "0.55296695", "0.55296695", "0.5513794", "0.55087745", "0.55081815", "0.55043864", "0.54979324", "0.54954875", "0.54676414", "0.5463837", "0.5459643", "0.5447258", "0.5446637", "0.5433359", "0.5421928", "0.542135", "0.54141164", "0.5411239", "0.5408798", "0.540207", "0.5399683", "0.5399683", "0.5399683", "0.53957176", "0.53954536", "0.53954536", "0.5388165", "0.5384498", "0.5382407", "0.5381941", "0.5378673", "0.5376978", "0.53762776", "0.5373158", "0.5372488", "0.53574216", "0.53544503", "0.535243", "0.5349845", "0.5347917", "0.5342581", "0.53363943", "0.5322945", "0.53187984", "0.5313137", "0.53091323", "0.53006804", "0.5288686" ]
0.0
-1
form content is sent using this function to the server
function ajax_post(where,caption,content) { var xmlhttp; if (window.XMLHttpRequest) {// code for IE7+, Firefox, Chrome, Opera, Safari xmlhttp=new XMLHttpRequest(); } else {// code for IE6, IE5 xmlhttp=new ActiveXObject("Microsoft.XMLHTTP"); } xmlhttp.onreadystatechange=function() { if (xmlhttp.readyState==4 && xmlhttp.status==200) { secondlayer(true,"Form content Uploaded "); //alert(xmlhttp.response); } } xmlhttp.open("POST",where,true); xmlhttp.setRequestHeader("Content-type","application/x-www-form-urlencoded"); xmlhttp.send(caption+"="+content); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function submitContent()\n{\n\tvar result = mainForm.get(function(item, key, value) {\n\t\tvar args = $(item).data(\"irform\");\n\t\t/* Some items should be removed if they are present */\n\t\tfor (var id in {\"name\":1, \"onchange\":1, \"disabled\":1, \"ignore\":1, \"validate\":1, \"options\":1}) {\n\t\t\tif (typeof args[id] !== \"undefined\") {\n\t\t\t\tdelete args[id];\n\t\t\t}\n\t\t}\n\t\t/* Return the new value */\n\t\treturn {\n\t\t\tvalue: value,\n\t\t\targs: args\n\t\t};\n\t});\n\tnew Ircom(\"/admin/api.php?type=content&savepath=\" + encodeURI(adminPath), result, {\n\t\tonError: function(message, options) {\n\t\t\t$(\".ircms-message\").empty();\n\t\t\t$(\".ircms-message\").html(\"<div class=\\\"alert alert-danger\\\" role=\\\"alert\\\">\" + message + \"</div>\");\n\t\t},\n\t\tonSuccess: function(data, options) {\n\t\t\tvar d = new Date();\n\t\t\tvar date_str = d.getHours() + \":\" + d.getMinutes() + \":\" + d.getSeconds();\n\t\t\t$(\".ircms-message\").empty();\n\t\t\t$(\".ircms-message\").html(\"<div class=\\\"alert alert-success\\\" role=\\\"alert\\\">Saved at \" + date_str + \"</div>\");\n\t\t}\n\t});\n\tconsole.log(result);\n}", "function send(){\n if( iframe.contentWindow != null){\n var iframeDocument = iframe.contentWindow.document;\n \n iframeDocument.body.appendChild(form);\n\n var onSuccess=success.bind(iframe);\n var inneronSuccess=function(){\n var _Window_ = this.contentWindow;\n var data=_Window_.data;\n var decodedata=(W.C.Setting.UseBase64) ? JSON.stringify(data) : JSON.stringify(data);\n onSuccess.call(this,decodedata);\n \n }\n iframe.onload =inneronSuccess.bind(iframe); \n form.submit();\n beforeSend.bind(context)(); \n }\n }", "function post(){\n wave.getState().submitValue(\"content\",document.getElementById(\"content\").innerHTML);\n}", "function sendData () {\n\t\t\tfetch(form.action, {\n\t\t\t\tmethod: 'POST',\n\t\t\t\tbody: new FormData(form),\n\t\t\t\theaders: {\n\t\t\t\t\t'Accept': 'application/json'\n\t\t\t\t}\n\t\t\t}).then(function (response) {\n\t\t\t\tif (response.ok) {\n\t\t\t\t\treturn response.json();\n\t\t\t\t}\n\t\t\t\tthrow response;\n\t\t\t}).then(function (data) {\n\t\t\t\tshowStatus(data.msg, true);\n\t\t\t\tif (data.redirect) {\n\t\t\t\t\twindow.location.href = data.redirect;\n\t\t\t\t}\n\t\t\t}).catch(function (error) {\n\t\t\t\terror.json().then(function (err) {\n\t\t\t\t\tshowStatus(err.msg);\n\t\t\t\t});\n\t\t\t}).finally(function () {\n\t\t\t\tform.removeAttribute('data-submitting');\n\t\t\t});\n\t\t}", "function formPOST(){\n\n\tthis.submit();\n\n}", "function form_submit()\n {\n /* Get reply form */\n var form = submit_btn.form;\n\n /* The fields we need when do a post */\n var fields = [\"followup\", \"rootid\", \"subject\", \"upfilerename\",\n \"username\", \"passwd\", \"star\", \"totalusetable\", \"content\",\n \"expression\", \"signflag\"];\n\n /* The fields we need to encode when post */\n var encode_fields = [ \"content\" ];\n\n /* Do ajax post */\n ajax_post(form, fields, encode_fields, {\"onreadystatechange\": post_callback});\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr2('target'),\n a = $form.attr2('action'),\n mp = 'multipart/form-data',\n et = $form.attr('enctype') || $form.attr('encoding') || mp;\n\n // update form attrs in IE friendly way\n form.setAttribute('target', id);\n if (!method || /post/i.test(method)) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (!s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function () {\n timedOut = true;cb(CLIENT_TIMEOUT_ABORT);\n }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized') {\n setTimeout(checkState, 50);\n }\n } catch (e) {\n log('Server abort: ', e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle) {\n clearTimeout(timeoutHandle);\n }\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if ($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push($('<input type=\"hidden\" name=\"' + s.extraData[n].name + '\">').val(s.extraData[n].value).appendTo(form)[0]);\n } else {\n extraInputs.push($('<input type=\"hidden\" name=\"' + n + '\">').val(s.extraData[n]).appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n }\n if (io.attachEvent) {\n io.attachEvent('onload', cb);\n } else {\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState, 15);\n\n try {\n form.submit();\n } catch (err) {\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n } finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action', a);\n form.setAttribute('enctype', et); // #380\n if (t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function onSubmit()\n{\n\tlet setupObj = getFormSetup();\n\tlet postString = \"\";\n\tif (setupObj)\n\t{\n\t\tpostString = makePOSTParams(setupObj);\n\t\tconsole.log(`Sending postString of ${postString}`);\n\t} else {\n\t\treturn false;\n\t}\n\n\tlet xmlhttp = new XMLHttpRequest();\n\txmlhttp.onload = function() {\n\t\tconsole.log(this.responseXML.body.outerHTML);\n\t\tlet message = this.responseXML.body.getElementById('responseMessage');\n\t\tdocument.body.insertBefore(document.body.firstChild.nextSibling, message);\n\t}\n\txmlhttp.open(\"POST\", \"../Generated/AddProduct.php\");\n\txmlhttp.setRequestHeader('Content-type', 'application/x-www-form-urlencoded');\n\txmlhttp.responseType = \"document\";\n\txmlhttp.send(postString);\n}", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr2('target'), \n a = $form.attr2('action'), \n mp = 'multipart/form-data',\n et = $form.attr('enctype') || $form.attr('encoding') || mp;\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method || /post/i.test(method) ) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized') {\n setTimeout(checkState,50);\n }\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle) {\n clearTimeout(timeoutHandle);\n }\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').val(s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').val(s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n }\n if (io.attachEvent) {\n io.attachEvent('onload', cb);\n }\n else {\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n\n try {\n form.submit();\n } catch(err) {\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n form.setAttribute('enctype', et); // #380\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr2('target'), \n a = $form.attr2('action'), \n mp = 'multipart/form-data',\n et = $form.attr('enctype') || $form.attr('encoding') || mp;\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method || /post/i.test(method) ) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized') {\n setTimeout(checkState,50);\n }\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle) {\n clearTimeout(timeoutHandle);\n }\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').val(s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').val(s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n }\n if (io.attachEvent) {\n io.attachEvent('onload', cb);\n }\n else {\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n\n try {\n form.submit();\n } catch(err) {\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n form.setAttribute('enctype', et); // #380\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr2('target'), \n a = $form.attr2('action'), \n mp = 'multipart/form-data',\n et = $form.attr('enctype') || $form.attr('encoding') || mp;\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method || /post/i.test(method) ) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized') {\n setTimeout(checkState,50);\n }\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle) {\n clearTimeout(timeoutHandle);\n }\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').val(s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').val(s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n }\n if (io.attachEvent) {\n io.attachEvent('onload', cb);\n }\n else {\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n\n try {\n form.submit();\n } catch(err) {\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n form.setAttribute('enctype', et); // #380\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr2('target'), \n a = $form.attr2('action'), \n mp = 'multipart/form-data',\n et = $form.attr('enctype') || $form.attr('encoding') || mp;\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method || /post/i.test(method) ) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized') {\n setTimeout(checkState,50);\n }\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle) {\n clearTimeout(timeoutHandle);\n }\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').val(s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').val(s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n }\n if (io.attachEvent) {\n io.attachEvent('onload', cb);\n }\n else {\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n\n try {\n form.submit();\n } catch(err) {\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n form.setAttribute('enctype', et); // #380\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr2('target'), \n a = $form.attr2('action'), \n mp = 'multipart/form-data',\n et = $form.attr('enctype') || $form.attr('encoding') || mp;\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method || /post/i.test(method) ) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized') {\n setTimeout(checkState,50);\n }\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle) {\n clearTimeout(timeoutHandle);\n }\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').val(s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').val(s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n }\n if (io.attachEvent) {\n io.attachEvent('onload', cb);\n }\n else {\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n\n try {\n form.submit();\n } catch(err) {\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n form.setAttribute('enctype', et); // #380\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr2('target'), \n a = $form.attr2('action'), \n mp = 'multipart/form-data',\n et = $form.attr('enctype') || $form.attr('encoding') || mp;\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method || /post/i.test(method) ) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized') {\n setTimeout(checkState,50);\n }\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle) {\n clearTimeout(timeoutHandle);\n }\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').val(s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').val(s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n }\n if (io.attachEvent) {\n io.attachEvent('onload', cb);\n }\n else {\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n\n try {\n form.submit();\n } catch(err) {\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n form.setAttribute('enctype', et); // #380\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr2('target'), \n a = $form.attr2('action'), \n mp = 'multipart/form-data',\n et = $form.attr('enctype') || $form.attr('encoding') || mp;\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method || /post/i.test(method) ) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized') {\n setTimeout(checkState,50);\n }\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle) {\n clearTimeout(timeoutHandle);\n }\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').val(s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').val(s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n }\n if (io.attachEvent) {\n io.attachEvent('onload', cb);\n }\n else {\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n\n try {\n form.submit();\n } catch(err) {\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n form.setAttribute('enctype', et); // #380\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr2('target'), \n a = $form.attr2('action'), \n mp = 'multipart/form-data',\n et = $form.attr('enctype') || $form.attr('encoding') || mp;\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method || /post/i.test(method) ) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized') {\n setTimeout(checkState,50);\n }\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle) {\n clearTimeout(timeoutHandle);\n }\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').val(s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').val(s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n }\n if (io.attachEvent) {\n io.attachEvent('onload', cb);\n }\n else {\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n\n try {\n form.submit();\n } catch(err) {\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n form.setAttribute('enctype', et); // #380\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr2('target'), \n a = $form.attr2('action'), \n mp = 'multipart/form-data',\n et = $form.attr('enctype') || $form.attr('encoding') || mp;\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method || /post/i.test(method) ) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized') {\n setTimeout(checkState,50);\n }\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle) {\n clearTimeout(timeoutHandle);\n }\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').val(s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').val(s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n }\n if (io.attachEvent) {\n io.attachEvent('onload', cb);\n }\n else {\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n\n try {\n form.submit();\n } catch(err) {\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n form.setAttribute('enctype', et); // #380\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr2('target'), a = $form.attr2('action');\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized')\n setTimeout(checkState,50);\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle)\n clearTimeout(timeoutHandle);\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').val(s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').val(s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n if (io.attachEvent)\n io.attachEvent('onload', cb);\n else\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n\n try {\n form.submit();\n } catch(err) {\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr2('target'), a = $form.attr2('action');\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized')\n setTimeout(checkState,50);\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle)\n clearTimeout(timeoutHandle);\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').val(s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').val(s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n if (io.attachEvent)\n io.attachEvent('onload', cb);\n else\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n\n try {\n form.submit();\n } catch(err) {\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr('target'), a = $form.attr('action');\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n \n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized')\n setTimeout(checkState,50);\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle)\n clearTimeout(timeoutHandle);\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').attr('value',s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').attr('value',s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n if (io.attachEvent)\n io.attachEvent('onload', cb);\n else\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n form.submit();\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr('target'), a = $form.attr('action');\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n \n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized')\n setTimeout(checkState,50);\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle)\n clearTimeout(timeoutHandle);\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').attr('value',s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').attr('value',s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n if (io.attachEvent)\n io.attachEvent('onload', cb);\n else\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n form.submit();\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr('target'), a = $form.attr('action');\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n \n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized')\n setTimeout(checkState,50);\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle)\n clearTimeout(timeoutHandle);\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').attr('value',s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').attr('value',s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n if (io.attachEvent)\n io.attachEvent('onload', cb);\n else\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n form.submit();\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "submitForm(){\n\t\tlet instance = this;\n\t\tconst\tdata = JSON.stringify({\n\t\t\tinterest: instance.dropdownData.interest,\n\t\t\tloan: instance.calculatorData,\n\t\t\tnumberOfMonths: instance.dropdownData.months,\n\t\t\ttotalDebt: instance.debt\n\t\t});\n\t\t\n\t\t\n\t\tfetch(instance.endpoint, {\n\t\t\tmethod: \"POST\",\n\t\t\theaders: {\n\t\t\t\t'Accept': 'application/json, text/plain, */*',\n\t\t\t\t'Content-Type': 'application/json'\n\t\t\t},\n\t\t\tbody: data\n\t\t}).then(resp => resp.json())\n\t\t\t.then(({status}) => instance.showFormMessage(status))\n\t\t\t.catch(err => instance.showFormMessage(`something wrong. Please contact the administrator.`, true))\n\t}", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr2('target'), a = $form.attr2('action');\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method || /post/i.test(method) ) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized')\n setTimeout(checkState,50);\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle)\n clearTimeout(timeoutHandle);\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').val(s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').val(s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n }\n if (io.attachEvent)\n io.attachEvent('onload', cb);\n else\n io.addEventListener('load', cb, false);\n setTimeout(checkState,15);\n\n try {\n form.submit();\n } catch(err) {\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr2('target'), a = $form.attr2('action');\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method || /post/i.test(method) ) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized')\n setTimeout(checkState,50);\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle)\n clearTimeout(timeoutHandle);\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').val(s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').val(s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n }\n if (io.attachEvent)\n io.attachEvent('onload', cb);\n else\n io.addEventListener('load', cb, false);\n setTimeout(checkState,15);\n\n try {\n form.submit();\n } catch(err) {\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr2('target'), a = $form.attr2('action');\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method || /post/i.test(method) ) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized')\n setTimeout(checkState,50);\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle)\n clearTimeout(timeoutHandle);\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').val(s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').val(s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n }\n if (io.attachEvent)\n io.attachEvent('onload', cb);\n else\n io.addEventListener('load', cb, false);\n setTimeout(checkState,15);\n\n try {\n form.submit();\n } catch(err) {\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr('target'), a = $form.attr('action');\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized')\n setTimeout(checkState,50);\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle)\n clearTimeout(timeoutHandle);\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n // if using the $.param format that allows for multiple values with the same name\n if($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+s.extraData[n].name+'\">').val(s.extraData[n].value)\n .appendTo(form)[0]);\n } else {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').val(s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n if (io.attachEvent)\n io.attachEvent('onload', cb);\n else\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n // just in case form has element with name/id of 'submit'\n var submitFn = document.createElement('form').submit;\n submitFn.apply(form);\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function getContent(form_id)\n{\n var form_request = doFormRequest(form_id);\n\n while (form_request.status < 200 && form_request.status > 400)\n {\n form_request = doFormRequest(form_id);\n }\n\n var x = document.getElementsByClassName(\"form-wrapper\");\n var i;\n for (i = 0; i < x.length; i++) {\n x[i].innerHTML += JSON.parse(form_request.responseText);\n }\n\n return true;\n}", "function doSubmit() {\r\n\t\t\t\t// make sure form attrs are set\r\n\t\t\t\tvar t = $form.attr2('target'),\r\n\t\t\t\t\ta = $form.attr2('action'),\r\n\t\t\t\t\tmp = 'multipart/form-data',\r\n\t\t\t\t\tet = $form.attr('enctype') || $form.attr('encoding') || mp;\r\n\r\n\t\t\t\t// update form attrs in IE friendly way\r\n\t\t\t\tform.setAttribute('target', id);\r\n\t\t\t\tif (!method || /post/i.test(method)) {\r\n\t\t\t\t\tform.setAttribute('method', 'POST');\r\n\t\t\t\t}\r\n\t\t\t\tif (a !== s.url) {\r\n\t\t\t\t\tform.setAttribute('action', s.url);\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// ie borks in some cases when setting encoding\r\n\t\t\t\tif (!s.skipEncodingOverride && (!method || /post/i.test(method))) {\r\n\t\t\t\t\t$form.attr({\r\n\t\t\t\t\t\tencoding: 'multipart/form-data',\r\n\t\t\t\t\t\tenctype: 'multipart/form-data'\r\n\t\t\t\t\t});\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// support timout\r\n\t\t\t\tif (s.timeout) {\r\n\t\t\t\t\ttimeoutHandle = setTimeout(function () {\r\n\t\t\t\t\t\ttimedOut = true; cb(CLIENT_TIMEOUT_ABORT);\r\n\t\t\t\t\t}, s.timeout);\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// look for server aborts\r\n\t\t\t\tfunction checkState() {\r\n\t\t\t\t\ttry {\r\n\t\t\t\t\t\tvar state = getDoc(io).readyState;\r\n\r\n\t\t\t\t\t\tlog('state = ' + state);\r\n\t\t\t\t\t\tif (state && state.toLowerCase() === 'uninitialized') {\r\n\t\t\t\t\t\t\tsetTimeout(checkState, 50);\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t} catch (e) {\r\n\t\t\t\t\t\tlog('Server abort: ', e, ' (', e.name, ')');\r\n\t\t\t\t\t\tcb(SERVER_ABORT);\t\t\t\t// eslint-disable-line callback-return\r\n\t\t\t\t\t\tif (timeoutHandle) {\r\n\t\t\t\t\t\t\tclearTimeout(timeoutHandle);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\ttimeoutHandle = undefined;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// add \"extra\" data to form if provided in options\r\n\t\t\t\tvar extraInputs = [];\r\n\r\n\t\t\t\ttry {\r\n\t\t\t\t\tif (s.extraData) {\r\n\t\t\t\t\t\tfor (var n in s.extraData) {\r\n\t\t\t\t\t\t\tif (s.extraData.hasOwnProperty(n)) {\r\n\t\t\t\t\t\t\t\t// if using the $.param format that allows for multiple values with the same name\r\n\t\t\t\t\t\t\t\tif ($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\r\n\t\t\t\t\t\t\t\t\textraInputs.push(\r\n\t\t\t\t\t\t\t\t\t\t$('<input type=\"hidden\" name=\"' + s.extraData[n].name + '\">', ownerDocument).val(s.extraData[n].value)\r\n\t\t\t\t\t\t\t\t\t\t\t.appendTo(form)[0]);\r\n\t\t\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t\t\textraInputs.push(\r\n\t\t\t\t\t\t\t\t\t\t$('<input type=\"hidden\" name=\"' + n + '\">', ownerDocument).val(s.extraData[n])\r\n\t\t\t\t\t\t\t\t\t\t\t.appendTo(form)[0]);\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tif (!s.iframeTarget) {\r\n\t\t\t\t\t\t// add iframe to doc and submit the form\r\n\t\t\t\t\t\t$io.appendTo($body);\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tif (io.attachEvent) {\r\n\t\t\t\t\t\tio.attachEvent('onload', cb);\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tio.addEventListener('load', cb, false);\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tsetTimeout(checkState, 15);\r\n\r\n\t\t\t\t\ttry {\r\n\t\t\t\t\t\tform.submit();\r\n\r\n\t\t\t\t\t} catch (err) {\r\n\t\t\t\t\t\t// just in case form has element with name/id of 'submit'\r\n\t\t\t\t\t\tvar submitFn = document.createElement('form').submit;\r\n\r\n\t\t\t\t\t\tsubmitFn.apply(form);\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t} finally {\r\n\t\t\t\t\t// reset attrs and remove \"extra\" input elements\r\n\t\t\t\t\tform.setAttribute('action', a);\r\n\t\t\t\t\tform.setAttribute('enctype', et); // #380\r\n\t\t\t\t\tif (t) {\r\n\t\t\t\t\t\tform.setAttribute('target', t);\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\t$form.removeAttr('target');\r\n\t\t\t\t\t}\r\n\t\t\t\t\t$(extraInputs).remove();\r\n\t\t\t\t}\r\n\t\t\t}", "function submit_success(form, evt, data, status, xhr) {\n var html = xhr.responseText\n var body = $(featherlight_selector());\n body.empty();\n body.append(html);\n}", "function submitForm(e)\r\n {\r\n e.preventDefault();\r\n var namect = document.getElementById(\"namect\");\r\n var selectct = document.getElementById(\"selectct\");\r\n var emailct = document.getElementById(\"emailct\");\r\n var numberct = document.getElementById(\"numberct\");\r\n saveMessage(namect, selectct, emailct, numberct);\r\n }", "function handleFormRequest() {\n var $inputs = $('.demo-form :input');\n var values = captureFormData($inputs);\n var url;\n // submitRequest(values, url);\n}", "function doSubmit() {\n\t\t\t\t// make sure form attrs are set\n\t\t\t\tvar t = $form.attr2('target'),\n\t\t\t\t\ta = $form.attr2('action'),\n\t\t\t\t\tmp = 'multipart/form-data',\n\t\t\t\t\tet = $form.attr('enctype') || $form.attr('encoding') || mp;\n\n\t\t\t\t// update form attrs in IE friendly way\n\t\t\t\tform.setAttribute('target', id);\n\t\t\t\tif (!method || /post/i.test(method)) {\n\t\t\t\t\tform.setAttribute('method', 'POST');\n\t\t\t\t}\n\t\t\t\tif (a !== s.url) {\n\t\t\t\t\tform.setAttribute('action', s.url);\n\t\t\t\t}\n\n\t\t\t\t// ie borks in some cases when setting encoding\n\t\t\t\tif (!s.skipEncodingOverride && (!method || /post/i.test(method))) {\n\t\t\t\t\t$form.attr({\n\t\t\t\t\t\tencoding : 'multipart/form-data',\n\t\t\t\t\t\tenctype : 'multipart/form-data'\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\t// support timout\n\t\t\t\tif (s.timeout) {\n\t\t\t\t\ttimeoutHandle = setTimeout(function() {\n\t\t\t\t\t\ttimedOut = true; cb(CLIENT_TIMEOUT_ABORT);\n\t\t\t\t\t}, s.timeout);\n\t\t\t\t}\n\n\t\t\t\t// look for server aborts\n\t\t\t\tfunction checkState() {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tvar state = getDoc(io).readyState;\n\n\t\t\t\t\t\tlog('state = ' + state);\n\t\t\t\t\t\tif (state && state.toLowerCase() === 'uninitialized') {\n\t\t\t\t\t\t\tsetTimeout(checkState, 50);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t} catch (e) {\n\t\t\t\t\t\tlog('Server abort: ', e, ' (', e.name, ')');\n\t\t\t\t\t\tcb(SERVER_ABORT);\t\t\t\t// eslint-disable-line callback-return\n\t\t\t\t\t\tif (timeoutHandle) {\n\t\t\t\t\t\t\tclearTimeout(timeoutHandle);\n\t\t\t\t\t\t}\n\t\t\t\t\t\ttimeoutHandle = undefined;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// add \"extra\" data to form if provided in options\n\t\t\t\tvar extraInputs = [];\n\n\t\t\t\ttry {\n\t\t\t\t\tif (s.extraData) {\n\t\t\t\t\t\tfor (var n in s.extraData) {\n\t\t\t\t\t\t\tif (s.extraData.hasOwnProperty(n)) {\n\t\t\t\t\t\t\t\t// if using the $.param format that allows for multiple values with the same name\n\t\t\t\t\t\t\t\tif ($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n\t\t\t\t\t\t\t\t\textraInputs.push(\n\t\t\t\t\t\t\t\t\t$('<input type=\"hidden\" name=\"' + s.extraData[n].name + '\">', ownerDocument).val(s.extraData[n].value)\n\t\t\t\t\t\t\t\t\t\t.appendTo(form)[0]);\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\textraInputs.push(\n\t\t\t\t\t\t\t\t\t$('<input type=\"hidden\" name=\"' + n + '\">', ownerDocument).val(s.extraData[n])\n\t\t\t\t\t\t\t\t\t\t.appendTo(form)[0]);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif (!s.iframeTarget) {\n\t\t\t\t\t\t// add iframe to doc and submit the form\n\t\t\t\t\t\t$io.appendTo($body);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (io.attachEvent) {\n\t\t\t\t\t\tio.attachEvent('onload', cb);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tio.addEventListener('load', cb, false);\n\t\t\t\t\t}\n\n\t\t\t\t\tsetTimeout(checkState, 15);\n\n\t\t\t\t\ttry {\n\t\t\t\t\t\tform.submit();\n\n\t\t\t\t\t} catch (err) {\n\t\t\t\t\t\t// just in case form has element with name/id of 'submit'\n\t\t\t\t\t\tvar submitFn = document.createElement('form').submit;\n\n\t\t\t\t\t\tsubmitFn.apply(form);\n\t\t\t\t\t}\n\n\t\t\t\t} finally {\n\t\t\t\t\t// reset attrs and remove \"extra\" input elements\n\t\t\t\t\tform.setAttribute('action', a);\n\t\t\t\t\tform.setAttribute('enctype', et); // #380\n\t\t\t\t\tif (t) {\n\t\t\t\t\t\tform.setAttribute('target', t);\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$form.removeAttr('target');\n\t\t\t\t\t}\n\t\t\t\t\t$(extraInputs).remove();\n\t\t\t\t}\n\t\t\t}", "function doSubmit() {\n\t\t\t\t// make sure form attrs are set\n\t\t\t\tvar t = $form.attr2('target'),\n\t\t\t\t\ta = $form.attr2('action'),\n\t\t\t\t\tmp = 'multipart/form-data',\n\t\t\t\t\tet = $form.attr('enctype') || $form.attr('encoding') || mp;\n\n\t\t\t\t// update form attrs in IE friendly way\n\t\t\t\tform.setAttribute('target', id);\n\t\t\t\tif (!method || /post/i.test(method)) {\n\t\t\t\t\tform.setAttribute('method', 'POST');\n\t\t\t\t}\n\t\t\t\tif (a !== s.url) {\n\t\t\t\t\tform.setAttribute('action', s.url);\n\t\t\t\t}\n\n\t\t\t\t// ie borks in some cases when setting encoding\n\t\t\t\tif (!s.skipEncodingOverride && (!method || /post/i.test(method))) {\n\t\t\t\t\t$form.attr({\n\t\t\t\t\t\tencoding : 'multipart/form-data',\n\t\t\t\t\t\tenctype : 'multipart/form-data'\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\t// support timout\n\t\t\t\tif (s.timeout) {\n\t\t\t\t\ttimeoutHandle = setTimeout(function() {\n\t\t\t\t\t\ttimedOut = true; cb(CLIENT_TIMEOUT_ABORT);\n\t\t\t\t\t}, s.timeout);\n\t\t\t\t}\n\n\t\t\t\t// look for server aborts\n\t\t\t\tfunction checkState() {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tvar state = getDoc(io).readyState;\n\n\t\t\t\t\t\tlog('state = ' + state);\n\t\t\t\t\t\tif (state && state.toLowerCase() === 'uninitialized') {\n\t\t\t\t\t\t\tsetTimeout(checkState, 50);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t} catch (e) {\n\t\t\t\t\t\tlog('Server abort: ', e, ' (', e.name, ')');\n\t\t\t\t\t\tcb(SERVER_ABORT);\t\t\t\t// eslint-disable-line callback-return\n\t\t\t\t\t\tif (timeoutHandle) {\n\t\t\t\t\t\t\tclearTimeout(timeoutHandle);\n\t\t\t\t\t\t}\n\t\t\t\t\t\ttimeoutHandle = undefined;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// add \"extra\" data to form if provided in options\n\t\t\t\tvar extraInputs = [];\n\n\t\t\t\ttry {\n\t\t\t\t\tif (s.extraData) {\n\t\t\t\t\t\tfor (var n in s.extraData) {\n\t\t\t\t\t\t\tif (s.extraData.hasOwnProperty(n)) {\n\t\t\t\t\t\t\t\t// if using the $.param format that allows for multiple values with the same name\n\t\t\t\t\t\t\t\tif ($.isPlainObject(s.extraData[n]) && s.extraData[n].hasOwnProperty('name') && s.extraData[n].hasOwnProperty('value')) {\n\t\t\t\t\t\t\t\t\textraInputs.push(\n\t\t\t\t\t\t\t\t\t$('<input type=\"hidden\" name=\"' + s.extraData[n].name + '\">', ownerDocument).val(s.extraData[n].value)\n\t\t\t\t\t\t\t\t\t\t.appendTo(form)[0]);\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\textraInputs.push(\n\t\t\t\t\t\t\t\t\t$('<input type=\"hidden\" name=\"' + n + '\">', ownerDocument).val(s.extraData[n])\n\t\t\t\t\t\t\t\t\t\t.appendTo(form)[0]);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif (!s.iframeTarget) {\n\t\t\t\t\t\t// add iframe to doc and submit the form\n\t\t\t\t\t\t$io.appendTo($body);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (io.attachEvent) {\n\t\t\t\t\t\tio.attachEvent('onload', cb);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tio.addEventListener('load', cb, false);\n\t\t\t\t\t}\n\n\t\t\t\t\tsetTimeout(checkState, 15);\n\n\t\t\t\t\ttry {\n\t\t\t\t\t\tform.submit();\n\n\t\t\t\t\t} catch (err) {\n\t\t\t\t\t\t// just in case form has element with name/id of 'submit'\n\t\t\t\t\t\tvar submitFn = document.createElement('form').submit;\n\n\t\t\t\t\t\tsubmitFn.apply(form);\n\t\t\t\t\t}\n\n\t\t\t\t} finally {\n\t\t\t\t\t// reset attrs and remove \"extra\" input elements\n\t\t\t\t\tform.setAttribute('action', a);\n\t\t\t\t\tform.setAttribute('enctype', et); // #380\n\t\t\t\t\tif (t) {\n\t\t\t\t\t\tform.setAttribute('target', t);\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$form.removeAttr('target');\n\t\t\t\t\t}\n\t\t\t\t\t$(extraInputs).remove();\n\t\t\t\t}\n\t\t\t}", "function displayForm(res) {\n fs.readFile('form.html', function (err, data) {\n res.writeHead(200, {\n 'Content-Type': 'text/html',\n 'Content-Length': data.length\n });\n res.write(data);\n res.end();\n });\n}", "function sendData() {\n let formRequest = new XMLHttpRequest()\n let formsData = new FormData(form)\n formRequest.addEventListener('load', function(event) {\n form.parentElement.classList.add('form-success')\n form.setAttribute('aria-hidden', true);\n successMessage.setAttribute('aria-hidden', false);\n ariaMessage.innerText = 'The form submitted successfully.'\n })\n formRequest.addEventListener('error', function(event) {\n form.parentElement.classList.add('form-error')\n form.setAttribute('aria-hidden', true);\n errorMessage.setAttribute('aria-hidden', false);\n ariaMessage.innerText = 'There was an error submitting the form. Please refresh the page and try again.'\n })\n formRequest.open('POST', '#')\n formRequest.send(formsData)\n }", "function postData (){\n\t\t//creates a text string in standard URL-encoded notation\n\t\tvar dataString = $('#myform').serialize();\n\t\t$.ajax({\n\t\t\turl: $('#myform').attr('action'),\n\t\t\ttype: \"post\",\n\t\t\tdata: dataString,\n\t\t\tsuccess: function(data) {\n\t\t\t\tdocument.getElementById('note').innerHTML = 'Thanks for contact!';\n\t\t\t\t//clear form after success submit\n\t\t\t\t$('#myform input[type=\"text\"]').val('');\n\t\t\t\t$('#myform textarea').val('');\n\t\t\t},\n\t\t\terror: function(){\n\t\t\t\tdocument.getElementById('note').innerHTML = 'There is an error please try again later!';\n\t\t}\n\t})\n\t}", "function sendForm(new_recept) {\n\tconsole.log( \"SendForm\" );\n\tvar input = $(\"#new-recept\").val();\n\tvar data = $(\"#recept-textarea\").val();\n\tif (new_recept == \"new\" && input != \"\"){\n\t\tdata = '{\"ID\": \"'+input+ '\"}';\n\t}\n\t\n\t\tconsole.log( \"SendForm - Request sent\" );\n\t\t\n\t\tvar url = \"http://sphann.se:8080/saverecept\";\n\t\t$.ajax({\n\t\t type: \"POST\",\n\t\t url: url,\n\t\t data: data,\n\t\t success: success,\n\t\t dataType: \"text\"\n\t\t});\n\t}", "function postContent(content, form, headers) {\n var sendHeaders = typeof headers === 'undefined' ? false : headers;\n \n $(document).ready(function () {\n $(form).ajaxForm({\n beforeSend: function (xhr) {\n if (sendHeaders) {\n xhr.setRequestHeader('token', token);\n xhr.setRequestHeader('key', secretKey);\n }\n },\n uploadProgress: function () {\n $(content).html(string);\n },\n success: function () {\n $(content).html(string);\n },\n complete: function (data) {\n $(content).html(data.responseText);\n },\n error: function () {\n $(content).html(string);\n }\n });\n });\n}", "function send($form) {\n\t\tvar $btn = $form.find('.submit');\n\t\tvar programTitle = $form.closest('figure').find('figcaption h3').text();\n\t\tvar department = $('#degrees-header h2').text();\n\t\t$form.find('input[name=program]').val(programTitle);\n\t\t$form.find('input[name=department]').val(department);\n\t\t$btn.removeClass('success error');\n\t\t$btn.addClass('pending');\n\t\t$.ajax({\n\t\t\ttype: \"POST\",\n\t\t\tcache: false,\n\t\t\turl: \"https://ouresources.usu.edu/_assets/forms/forms.php\", //form_submit.aspx\n\t\t\tdata: $form.serialize(),\n\t\t\tsuccess: function(data) {\n\t\t\t\tshowDownload();\n\t\t\t},\n\t\t\terror: function(data) {\n\t\t\t\t$btn.find('input').val(\"Couldn't Submit\");\n\t\t\t\t$btn.removeClass('pending');\n\t\t\t\t$btn.addClass('error');\n\t\t\t}\n\t\t});\n\t}", "resend() {\n console.log(this.formdata);\n\t}", "function doSubmit() {\n\t\t\t// make sure form attrs are set\n\t\t\tvar t = $form.attr('target'), a = $form.attr('action');\n\n\t\t\t// update form attrs in IE friendly way\n\t\t\tform.setAttribute('target',id);\n\t\t\tif (!method) {\n\t\t\t\tform.setAttribute('method', 'POST');\n\t\t\t}\n\t\t\tif (a != s.url) {\n\t\t\t\tform.setAttribute('action', s.url);\n\t\t\t}\n\n\t\t\t// ie borks in some cases when setting encoding\n\t\t\tif (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n\t\t\t\t$form.attr({\n\t\t\t\t\tencoding: 'multipart/form-data',\n\t\t\t\t\tenctype: 'multipart/form-data'\n\t\t\t\t});\n\t\t\t}\n\n\t\t\t// support timout\n\t\t\tif (s.timeout) {\n\t\t\t\ttimeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n\t\t\t}\n\t\t\t\n\t\t\t// look for server aborts\n\t\t\tfunction checkState() {\n\t\t\t\ttry {\n\t\t\t\t\tvar state = getDoc(io).readyState;\n\t\t\t\t\tlog('state = ' + state);\n\t\t\t\t\tif (state.toLowerCase() == 'uninitialized')\n\t\t\t\t\t\tsetTimeout(checkState,50);\n\t\t\t\t}\n\t\t\t\tcatch(e) {\n\t\t\t\t\tlog('Server abort: ' , e, ' (', e.name, ')');\n\t\t\t\t\tcb(SERVER_ABORT);\n\t\t\t\t\ttimeoutHandle && clearTimeout(timeoutHandle);\n\t\t\t\t\ttimeoutHandle = undefined;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// add \"extra\" data to form if provided in options\n\t\t\tvar extraInputs = [];\n\t\t\ttry {\n\t\t\t\tif (s.extraData) {\n\t\t\t\t\tfor (var n in s.extraData) {\n\t\t\t\t\t\textraInputs.push(\n\t\t\t\t\t\t\t$('<input type=\"hidden\" name=\"'+n+'\" />').attr('value',s.extraData[n])\n\t\t\t\t\t\t\t\t.appendTo(form)[0]);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif (!s.iframeTarget) {\n\t\t\t\t\t// add iframe to doc and submit the form\n\t\t\t\t\t$io.appendTo('body');\n\t io.attachEvent ? io.attachEvent('onload', cb) : io.addEventListener('load', cb, false);\n\t\t\t\t}\n\t\t\t\tsetTimeout(checkState,15);\n\t\t\t\tform.submit();\n\t\t\t}\n\t\t\tfinally {\n\t\t\t\t// reset attrs and remove \"extra\" input elements\n\t\t\t\tform.setAttribute('action',a);\n\t\t\t\tif(t) {\n\t\t\t\t\tform.setAttribute('target', t);\n\t\t\t\t} else {\n\t\t\t\t\t$form.removeAttr('target');\n\t\t\t\t}\n\t\t\t\t$(extraInputs).remove();\n\t\t\t}\n\t\t}", "submitForm(e) {\n e.preventDefault();\n window.M.updateTextFields();\n let data = Util.getDataElementsForm(e.target, false);\n\n MakeRequest({\n method: 'post',\n url: 'actividad/post',\n data : data\n }).then(response => {\n if (response.error) {\n return Util.getMsnDialog('danger', Util.getModelErrorMessages(response.message));\n }\n\n this.getActivitiesByCategory();\n return Util.getMsnDialog('success', 'Created');\n });\n }", "function submitForm (e) {\n e.preventDefault();\n let formData = new FormData(e.target);\n let body = [...formData.entries()] // expand the elements from the .entries() iterator into an actual array\n .map(e => encodeURIComponent(e[0]) + \"=\" + encodeURIComponent(e[1])) // transform the elements into encoded key-value-pair\n\n xhr.open(e.target.getAttribute('method') ? e.target.getAttribute('method') : e.target.method, e.target.action, true);\n xhr.setRequestHeader(\"Content-type\", \"application/x-www-form-urlencoded\");\n xhr.onload = (e) => {\n let json = JSON.parse(e.target.responseText);\n switch (json.type){\n case 'clone':\n if(json.result.error !== undefined ) {\n responseDOM.className = \"alert alert-danger\";\n responseDOM.innerText = json.result.error;\n } else {\n responseDOM.className = \"alert alert-success\";\n responseDOM.innerText = 'Successfully added! To complete installation you\\'ll have to restart Franz.'\n }\n break;\n case 'remove':\n responseDOM.className = \"alert alert-success\";\n responseDOM.innerText = json.result;\n break;\n case 'update':\n responseDOM.className = \"alert alert-success\";\n responseDOM.innerText = json.result;\n\n getPlugins();\n break;\n default:\n responseDOM.className = \"alert alert-info\";\n responseDOM.innerText = e.target.responseText;\n }\n };\n xhr.send(body);\n}", "function postRequest($this,isMainForm){\n\tvar url=$(\"form\")[0].action;\n\tvar fdata=$(\"form\").serialize();\n\tif($($(\"form\")[0]).isValid()){\n\t\t$.post(url,fdata,function(data,status){\t\t\t\n\t\t\talert(\"Save Successfully.\");\n\t\t}).error(function(e){\n\t\t\talert(\"Error in saving. Refer terminal log.\");\n\t\t\tconsole.log(e);\n\t\t});\n\n\t}\t\n\t\n}", "function sendData(action,content,is_post)\r\n{\r\n var search= new XMLHttpRequest();\r\n search.onreadystatechange=()=>\r\n {\r\n if((search.readyState==4) && search.status==200)\r\n {\r\n let data=search.responseText;\r\n if(data==\"error\")\r\n {\r\n alert('Sorry an error is found');\r\n }\r\n else\r\n {\r\n content.innerHTML=data;\r\n }\r\n }\r\n } \r\n\r\n var donnee=\"\";\r\n if(is_post)\r\n {\r\n donnee=getFormData();\r\n }\r\n search.open('POST',`index.php?action=${action}`,true);\r\n search.send(donnee);\r\n}", "function body(containerDiv){\n \n\n if(!sessionStorage.getItem('id'))\n {\n window.location.assign('signin');\n }\n const divBody=document.createElement('div')\n divBody.className='section';\n \n containerDiv.appendChild(divBody);\n const joinUS=document.createElement('div')// fill the form div\n divBody.appendChild(joinUS);\n joinUS.className='joinus';\n\n \n \n\n joinUS.innerHTML=`<form id=myFrom action=\"../../api/meals\" method=\"post\"><h2>Share Meal</h2>\n <div class=\"innerDiv\"><div class=\"outerDiv\"><lable>Title</lable><input required name=\"title\" id=\"mytitle\" type=\"text\" class=\"textBox\"></input></div>\n <div class=\"outerDiv\"><lable>Description</lable><textarea required name=\"description\"class=\"textBox\"></textarea></div>\n <div class=\"outerDiv\"><lable>Location</lable><input type=\"text\" required name=\"location\"class=\"textBox\"></input></div>\n <div class=\"outerDiv\"><lable>Price</lable><input type=\"text\"name=\"price\" required class=\"textBox\"></input></div> \n <div class=\"outerDiv\"><lable>Max Reservations</lable><input type=\"text\" required id=\"guest\"name=\"max_reservations\" class=\"textBox\" readonly></input></div>\n <!-- <div class=\"outerDiv\"><lable>Picture</lable><input type=\"file\" name=\"file\" id=\"myFile\" class=\"textBox\" required></input></div> -->\n <div class=\"outerDiv\"><input type=\"submit\" class=\"btn\"></input></div></div></form>`;\n //auto guest fill box\n maxGuest(document.querySelector('#guest'));\n\n\n /*\n\n const myFile=document.querySelector('#myFile');\n const myForm=document.querySelector('#myForm');\n \n \n myForm.addEventListener('submit',(e)=>{\n e.preventDefault();\n \n const url='../../api/meals'\n const formData=new FormData();\n formData.append('myForm',myFile)\n \n console.log(myFile.files)\n fetch(url,{method:'post',\n body:formData\n }).then(res=>res.json())\n .then(data=>console.log(data))\n\n })*/\n \n }", "execute()\n {\n var formElement = bcdui._migPjs._$(this.form).get(0);\n if (formElement == null)\n throw Error(\"Internal error, form element (\" + this.form + \") for PDF export not found.\");\n\n // prepend navpath\n var navPathTable = bcdui.component.exports._generateNavPathTable();\n if (navPathTable != null) {\n this.rootElementArray.unshift(navPathTable);\n }\n \n // Lets loop over the elements to be included and collect their content\n var fullHTML = bcdui.component.exports._html2String(this.rootElementArray); \n\n // Generate full HTML page\n fullHTML = this._htmlPageTemplate({\n title: this.title\n , css: this._generateCSSLinkElements()\n , content: fullHTML\n });\n\n // Insert data into form\n formElement.elements['htmlString'].value = fullHTML;\n formElement.elements['orientation'].value = this.orientationLandscape ? \"landscape\" : \"portrait\";\n formElement.elements['dimension'].value = this.dimension;\n formElement.elements['format'].value = this.format;\n formElement.elements['basePath'].value = location.pathname.substring(bcdui.config.contextPath.length);\n formElement.elements['pageHash'].value = bcdui.config.frame.pageHash; // for tracking\n formElement.elements['fileName'].value = this.fileName;\n formElement.elements['htmlWidth'].value = this.htmlWidth;\n\n // Send data\n // Date param is workaround for caching issue on ff;\n formElement.action = this.servletBaseUrl + (this.fileName ? \"/\"+this.fileName : \"\" ) + \"?id=\"+ new Number(new Date()).toString();\n this.onBeforeSend();\n formElement.submit();\n this.onAfterSend();\n }", "function submitForm () {\n\n\t\t\t// Add submitting state\n\t\t\tform.setAttribute('data-submitting', true);\n\n\t\t\t// Send the data to the MailChimp API\n\t\t\tsendData(serializeForm(form));\n\n\t\t}", "function onFormSubmit(formEvent) {\n\tsaveResponse(formEvent.response);\n\tsendMail();\n}", "function submitForm(e) {\r\n e.preventDefault();\r\n //get values\r\n var name = document.getElementById('name1').value;\r\n var email = document.getElementById('mail1').value;\r\n var phone = document.getElementById('phone1').value;\r\n var subject = document.getElementById('subject1').value;\r\n var message = document.getElementById('message1').value;\r\n // var message=document.getElementById('textme').value;\r\n saveMessage(name, email, phone, subject, message);\r\n\r\n}", "function displayForm(res) {\n fs.readFile('betterform.html', function (err, data) {\n res.write(data);\n res.end();\n });\n}", "function submitForm(){\n console.log(\"entered submit function\");\n// e.preventDefault();\n\n // Get values\n var type=\"cc\"\n var name = \"ram\";\n var age = \"\";\n var email = getInputVal('mail');\n var phone = \"num\";\n\n // Save message\n saveMessage(type,name,age,email, phone);\n}", "sendPost(e) {\n\t\t// Prevent the page from reloading\n\t\te.preventDefault();\n\n\t\t// Create the object we send to the server\n\t\tlet data = {\n\t\t\t\"text\": document.querySelector(\"#postText\").value,\n\t\t\t\"img\": \n\t\t\t(document.querySelector(\".preview img\").src != \"\") ? document.querySelector(\".preview img\").src : \"\"\n\t\t};\n\t\t// Use fetch() and send the data from this.postInput\n\t\tfetch(postURL, {\n\t\t\tmethod: 'POST', // or 'PUT'\n\t\t\tbody: JSON.stringify(data), // data can be `string` or {object}!\n\t\t\theaders: new Headers({\n\t\t\t\t'Content-Type': 'application/json'\n\t\t})});\n\t}", "function submitForm()\n{\nvar confirmMessage=\"Do you want to save the released budget?\";\nif(document.forms[0].isDrafted.value==\"yes\")\n{\nconfirmMessage=\"Do you want to save the entered details as draft?\";\n}\n\n document.forms[0].hmode.value=\"saveReleaseBudget\";\n document.forms[0].action=\"/ICMR/releaseAction.do\";\n document.forms[0].method=\"post\";\n confirmation = confirm(confirmMessage);\n if(confirmation == true)\n {\n \n /*Start:hiding all the buttons*/\n document.getElementById(\"draftRelease\").style.display='none';\n /*document.getElementById(\"submitRelease\").style.display='none';*/\n /*End:hiding all the buttons*/\n \n /*Start:Show the loading screen*/\n document.getElementById(\"loadingimg\").style.display=\"inline\"; //shows the image which tells user to wait\n document.getElementById(\"login\").style.display=\"inline\"; //shows the image which tells user to wait\n /*End:Show the loading screen*/\n \n \n /*Storing the contents of the mail*/\n var html = $('#editor').html();\n $(\"#mailText\").val(html);\n /*Storing the contents of the mail*/\n document.forms[0].submit();\n }\n else\n {\n return false;\n } \n}", "function processForm(){\n\t\tvar name = formHandle.name;\n\t\tvar email = formHandle.email;\n\t\tvar comment = formHandle.comment;\n\t\tvar thanksMsgDiv = document.getElementById(\"section-div2\");\n\t\t//Validation\n\t\tif(name.value===\"\")\n\t\t{\n\t\t\tname.style.background=\"red\";\n\t\t\tname.focus();\t\t\t\n\t\t\treturn false;\n\t\t}\n\t\tif(email.value===\"\")\n\t\t{\n\t\t\temail.style.background=\"red\";\n\t\t\temail.focus();\n\t\t\treturn false;\n\t\t}\n\t\tif(comment.value===\"\")\n\t\t{\n\t\t\tcomment.style.background=\"red\";\n\t\t\tcomment.focus();\n\t\t\treturn false;\n\t\t}\n\t\tformHandle.classList.add(\"section-div2\");\n\t\tthanksMsgDiv.innerHTML=\"<p>Thank you!! \" + name.value +\" </p>\" + \"<span>Your message has been sent.</span> \"\n\t\t\n\t}", "function handleThis(form) {\n\n for (let element of form.elements){\n if(element.name){\n pokeObj[element.name] = element.value;\n }\n }\n req.onload = () => {\n window.location = \"/viewPC.html\";\n };\n req.open(\"POST\", \"http://35.235.50.146:9000/pokemon\");\n req.setRequestHeader(\"Content-Type\", \"application/json\");\n req.send(JSON.stringify(pokeObj));\n\n return false;\n}", "createPost(event){\n // prevent default stops the page from auto reloading on form submit\n event.preventDefault();\n // this grabs the data from the form \n let formData = event.target;\n // creates a JavaScript object\n let rawPost = {\n body: formData.body.value\n };\n // console.log(\"creating the post\")\n PostService.createPost(rawPost);\n // form reset says go clear that form\n formData.reset();\n _draw();\n }", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr('target'), a = $form.attr('action');\n\n // update form attrs in IE friendly way\n form.setAttribute('target', id);\n if (!method) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (!s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function () { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n\n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state.toLowerCase() == 'uninitialized')\n setTimeout(checkState, 50);\n }\n catch (e) {\n log('Server abort: ', e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n timeoutHandle && clearTimeout(timeoutHandle);\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n extraInputs.push(\n\t\t\t\t\t\t\t$('<input type=\"hidden\" name=\"' + n + '\">').attr('value', s.extraData[n])\n\t\t\t\t\t\t\t\t.appendTo(form)[0]);\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n io.attachEvent ? io.attachEvent('onload', cb) : io.addEventListener('load', cb, false);\n }\n setTimeout(checkState, 15);\n form.submit();\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action', a);\n if (t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function send(event)\n{\n event.preventDefault();//не перезагружает страницу после отправки формы\n let model=document.querySelector(\".model\");\n model.classList.toggle(\"model_show\");\n let x=model.querySelector(\".x\");\n x.onclick=function ()\n {\n model.classList.toggle(\"model_show\");\n }\n\n\n\n\n // let nameInput=document.querySelector(\".Nname\");\n // let emailInput=document.querySelector(\".e-maill\");\n // let quesInput=document.querySelector(\".heheboy\");\n // console.log(emailInput);\n // let Error=\"\";\n // if(nameInput.value==\"\")\n // {\n // Error+=\"Name can not be empty\\n\";\n // }\n // if(emailInput.value==\"\")\n // {\n // Error+=\"Email can not be empty\\n\";\n // }\n // if(quesInput.value==\"\")\n // {\n // Error+=\"You have to wright question\\n\";\n // }\n // if(Error!=\"\")\n // {\n // alert(Error);\n // }\n // if(Error==\"\")\n // {\n // alert(\"your question is send!\")\n // }\n\n\n}", "function submitForm(e){\n e.preventDefault(); // preventing default functionality of data\n const url = document.getElementById('article-url').value; // getting url typed by user\n if(checkURL(url)){\n console.log('Posting');\n postUrl('http://localhost:8081/data', {url: url}).then( // performng post request\n (data) => { // updating UI\n console.log('back');\n console.log(data);\n document.getElementById('text').innerHTML = `Text is: ${data.text}`;\n document.getElementById('agreement').innerHTML = `Agreement state: ${data.agreement}`;\n document.getElementById('subjectivity').innerHTML = `Subjectivity sate: ${data.subjectivity}`;\n document.getElementById('confidence').innerHTML = `Degree of confidence: ${data.confidence}`;\n document.getElementById('irony').innerHTML = `Irony state: ${data.irony}`;\n document.getElementById('score_tag').innerHTML = `Score Tag: ${data.score_tag}`;\n },\n (err)=>{\n console.log(err);\n }\n ) \n }\n else{ // If url is not valid, show aler and clear form\n alert('please enter a valid url'); \n document.getElementById('article-url').value = '';\n }\n}", "function upload(form) {\n \n}", "resetFormContent() {\n ContentUtils.updateElementContent(\"delimiter\", \"?\");\n ContentUtils.updateElementContent(\"hasHeaderRow\", \"?\");\n ContentUtils.updateElementContent(\"fileSize\", 0);\n ContentUtils.updateElementContent(\"totalRecords\", 0);\n ContentUtils.updateElementContent(\"badRecords\", 0);\n ContentUtils.updateElementContent(\"inputCsvTable\", \"\");\n ContentUtils.updateElementContent(\"badCsvTable\", \"\");\n ContentUtils.updateElementContent(\"interpolatedCsvTable\", \"\");\n ContentUtils.updateElementContent(\"invalidData\", \"\");\n }", "function form2db(){\n\tvar frmdiv=document.getElementById('frmdiv');\n\tvar txt_frm=document.getElementById('txt_frm');\n\ttxt_frm.value=frmdiv.innerHTML;\n\t//form=form.toString();\n\tconsole.log(txt_frm.value);\n\t$('#output').html('<h2>Waiting...</h2><img src=\"img/car.gif\" width=\"350px\">');\n\t$.ajax({\n\t\turl:\"xuly.php\",\n\t\ttype:\"POST\",\n\t\tdata:{\n\t\t\t form:'hahahahahaahah',\n\t\t\t func:'form2db'\n\t\t},\n\t\tsuccess:function (kq){\n\t\t\t$('#output').html(kq);\n\t\t}\n\t});\n}", "function doSubmit() {\n // make sure form attrs are set\n var t = $form.attr('target'), a = $form.attr('action');\n\n // update form attrs in IE friendly way\n form.setAttribute('target',id);\n if (!method) {\n form.setAttribute('method', 'POST');\n }\n if (a != s.url) {\n form.setAttribute('action', s.url);\n }\n\n // ie borks in some cases when setting encoding\n if (! s.skipEncodingOverride && (!method || /post/i.test(method))) {\n $form.attr({\n encoding: 'multipart/form-data',\n enctype: 'multipart/form-data'\n });\n }\n\n // support timout\n if (s.timeout) {\n timeoutHandle = setTimeout(function() { timedOut = true; cb(CLIENT_TIMEOUT_ABORT); }, s.timeout);\n }\n \n // look for server aborts\n function checkState() {\n try {\n var state = getDoc(io).readyState;\n log('state = ' + state);\n if (state && state.toLowerCase() == 'uninitialized')\n setTimeout(checkState,50);\n }\n catch(e) {\n log('Server abort: ' , e, ' (', e.name, ')');\n cb(SERVER_ABORT);\n if (timeoutHandle)\n clearTimeout(timeoutHandle);\n timeoutHandle = undefined;\n }\n }\n\n // add \"extra\" data to form if provided in options\n var extraInputs = [];\n try {\n if (s.extraData) {\n for (var n in s.extraData) {\n if (s.extraData.hasOwnProperty(n)) {\n extraInputs.push(\n $('<input type=\"hidden\" name=\"'+n+'\">').attr('value',s.extraData[n])\n .appendTo(form)[0]);\n }\n }\n }\n\n if (!s.iframeTarget) {\n // add iframe to doc and submit the form\n $io.appendTo('body');\n if (io.attachEvent)\n io.attachEvent('onload', cb);\n else\n io.addEventListener('load', cb, false);\n }\n setTimeout(checkState,15);\n form.submit();\n }\n finally {\n // reset attrs and remove \"extra\" input elements\n form.setAttribute('action',a);\n if(t) {\n form.setAttribute('target', t);\n } else {\n $form.removeAttr('target');\n }\n $(extraInputs).remove();\n }\n }", "function sendForm(data) {\n document.querySelector('form').style.display = 'none'\n let box = document.createElement('div')\n box.className = 'everythingOK'\n\n //append the (THANK YOU) box to the HTML\n box.innerHTML = ` \n <h3>Thank you for your time! We will take a look at your Request.</h3>\n `\n document.querySelector('.contactContent').prepend(box)\n }", "function sendform(context, space, response, username, useremail, station, bulbs, color, showurl, greeting) {\n // get user prefs for this service/space\n response.writeHead(200, {'Content-Type': 'text/html'});\n\n/*\n // read the at home template\n fs.readFile('content/athome.tmpl', 'utf8', send2);\n \n function send2 (err,data) {\n var page;\n if (err) {\n // TBD error no page\n page = \"<h1>SpaceManager missing content/athome.tmpl file\";\n } else {\n page = data;\n }\n };\n*/ response.write(\"<script language=\\\"javascript\\\">\\\nfunction toggle(tx,el) {\\\n\tvar ele = document.getElementById(el);\\\n\tvar text = document.getElementById(tx);\\\n\tif(ele.style.display == \\\"block\\\") {\\\n \t\tele.style.display = \\\"none\\\";\\\n\t\ttext.innerHTML = \\\"Show\\\";\\\n \t}\\\n\telse {\\\n\t\tele.style.display = \\\"block\\\";\\\n\t\ttext.innerHTML = \\\"Hide\\\";\\\n\t}\\\n} \\\n</script>\\\n<a id=\\\"d1\\\" href='javascript:toggle(\\\"d1\\\",\\\"t1\\\");'>Show</a> Scenes\\\n<div id=\\\"t1\\\" style=\\\"display: none\\\">\");\n\n // function generates output given space, username, useremail\n\n // TBD the modes for this user\n var stream = context.dbathomepref.find( {'space':space, 'scene':{$exists:true}}, { _id: 0, 'scene':1,'user':1});\n // handle the stream events\n stream.on(\"data\", processscene);\n stream.on(\"end\", processsceneend);\n\n \n function processscene(item) {\n var name = \"\";\n var userfield = \"\";\n console.log(item);\n if (item.hasOwnProperty(\"user\")) {\n if ((item.user != \"\") && (item.user != useremail))\n return; // skip it\n else if (item.user != \"\") {\n name = \"Your scene\"\n userfield = \",\\\\\\\"user\\\\\\\":\\\\\\\"\"+item.user+\"\\\\\\\"\";\n }\n }\n if (item.hasOwnProperty(\"scene\") && (item.scene != \"\") )\n if (name != \"\")\n name += \" named \" + item.scene;\n else\n name = item.scene;\n response.write(\"<a href='javascript:window.JSInterface.sendMode(\\\"{\\\\\\\"scene\\\\\\\":\\\\\\\"\" + item.scene +\"\\\\\\\"\"+userfield+\"}\\\");'>\" + name + \"</a><br>\");\n //JSON.stringify(item, undefined, 1));\n }\n \n function processsceneend() { \n response.write(\"</div><p></p><a id=\\\"d2\\\" href='javascript:toggle(\\\"d2\\\",\\\"t2\\\");'>Show</a> Preferences\\\n <div id=\\\"t2\\\" style=\\\"display: none\\\">\");\n \t\n response.write(\"<h2>Your At Home Preference Page</h2>\");\n response.write(\"<p>\" + username + \", select your home preferences:<p>\");\n \n response.write('<form name=\"feedback\" method=\"get\" action=\"athome\">');\n response.write('Radio Station: <input type=\"text\" name=\"station\" size=\"25\" value=\"' + station + '\"><p>');\n response.write('Lighbulb Names: <input type=\"text\" name=\"bulbs\" size=\"25\" value=\"' + bulbs + '\"><p>');\n response.write('Light Color (0-99): <input type=\"text\" name=\"color\" size=\"25\" value=\"' + color + '\"><p>');\n response.write('Personal Greeting: <input type=\"text\" name=\"greeting\" size=\"25\" value=\"' + greeting + '\"><p>');\n response.write('Web Site: <input type=\"text\" name=\"url\" size=\"25\" value=\"' + showurl + '\"><p>');\n response.write('<input type=\"hidden\" name=\"user\" value=\"' + useremail + '\">');\n response.write('<input type=\"hidden\" name=\"name\" value=\"' + username + '\">');\n response.write('<input type=\"hidden\" name=\"save\" value=\"1\">');\n response.end('<input type=\"submit\" value=\"Save\"></form></div>');\n }\n}", "function render() {\n\trout();\n\tlet html = '';\n\tlet htmlC = '';\n\tnavigationMenu.render();\n\torderPage.render();\n\tlet form = document.querySelector('form');\n\tlet sendForm = document.querySelector('#send-form');\n\tsendForm.onclick = function(event) {\n\n\t\tevent.preventDefault();\n\t\tconsole.log('Початок валідації');\n\t\tif (!validateEmail(document.getElementById('email').value)) {\n\t\t\tdocument.getElementById('email').value += \"😡\";\n\t\t\tdocument.getElementById('email').style.color = \"red\";\n\t\t} else if ((document.getElementById('phone').value.length != 10)){\n\t\t\tdocument.getElementById('phone').value += \"😡\";\n\t\t\tdocument.getElementById('phone').style.color = \"red\";\n\t\t} \n\t\telse \n\t\t{\t\n\t\t\tdocument.getElementById('email').style.color = \"black\";\n\t\t\tdocument.getElementById('phone').style.color = \"black\";\n\t\t\tconsole.log(\"Кінець валідації\")\n\t\t\t//console.log(serialize(form));\n\t\t\tlet data = '';\n\t\t\tconst requestUrl = 'https://jsonplaceholder.typicode.com/users';\n\t\t\tfunction sendRequest(method, url, body = null) {\n\t\t\t\treturn new Promise((resolve, reject) => {\n\t\t\t\t\t\n\t\t\t\tconst xhr = new XMLHttpRequest()\n\t\t\t\n\t\t\t\txhr.open(method, url)\n\t\t\t\n\t\t\t\txhr.responseType = 'json'\n\t\t\t\txhr.setRequestHeader('Content-type', 'application/json')\n\t\t\t\n\t\t\t\txhr.onload = () => {\n\t\t\t\t\tif (xhr.status >=400) {\n\t\t\t\t\t\treject(xhr.response)\n\t\t\t\t\t} else {\n\t\t\t\t\t\tresolve(xhr.response)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\n\t\t\t\txhr.onerror = () => {\n\t\t\t\t\treject(xhr.response)\n\t\t\t\t}\n\t\t\t\n\t\t\t\txhr.send(JSON.stringify(body))\n\t\t\t\t\t}) \t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t}\n\t\t\t\n\t\t\t\tconst productsStore = localStorageUtil.getProducts();\n\t\t\t\tlet values = new Array();\n\t\t\t\tlet personalId = Date.now();\n\t\t\t\tlet sumCatalog = 0;\n\t\t\t\tCATALOG.forEach(({ id, name, price }) => {\n\t\t\t\t\tif (productsStore.indexOf(id) !== -1) {\n\t\t\t\t\t\t values += JSON.stringify({name, price})\n\t\t\t\t\t\t sumCatalog+=price;\n\t\t\t\t\t\t htmlC += `\n\t\t\t\t\t\t\t<div class=\"order-container\">\n\t\t\t\t\t\t\t\t<span class=\"products-element__name\">${name}</span>\n\t\t\t\t\t\t\t\t<span class=\"products-element__price\">\n\t\t\t\t\t\t\t\t⚡️ ${price.toLocaleString()} USD\n\t\t\t\t\t\t\t\t</span>\n \t \t\t\t\t</div>\t\n\t\t\t\t\t\t\t`\n\t\t\t\t\t}\n\t\t\t\t\thtml = `<div class=\"container\">\n\t\t\t\t\t<div id=\"thanks\">Дякуємо, ${document.getElementById('exampleInputName1').value}, замовлення успішно сформоване та успішно прямує в ${document.getElementById('exampleinputAddress1').value}</div>\n\t\t\t\t\t${htmlC}\n\t\t\t\t\tСума замовлення: ${sumCatalog} USD\n\t\t\t\t\t</div>\n\t\t\t\t\t`\n\t\t\t\t\treturn values\n\t\t\t\t});\n\t\t\t\tif (sumCatalog == 0) {\n\t\t\t\t\tconsole.log('Корзина пуста')\n\t\t\t\t\tdocument.getElementById('send-form').disabled = 'true';\n\t\t\t\t\tdocument.getElementById('send-form').style.background = 'red';\n\t\t\t\t\tdocument.getElementById('send-form').innerText= 'Корзина пуста';\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\n\t\t\t\tconst body = {\n\t\t\t\t\tname: document.getElementById('exampleInputName1').value,\n\t\t\t\t\taddress: document.getElementById('exampleinputAddress1').value,\n\t\t\t\t\tphone: document.getElementById('phone').value,\n\t\t\t\t\temail: document.getElementById('email').value,\n\t\t\t\t\tadditional: document.getElementById('addinfo').value,\n\t\t\t\t\tdate: new Date(),\n\t\t\t\t\tsum: sumCatalog,\n\t\t\t\t\tvalues: values\n\t\t\t\t}\n\t\t\n\t\t\t\n\t\t\t\tsendRequest('POST', requestUrl, body )\n\t\t\t\t.then( data => {console.log(data)})\n\t\t\t\t.catch( err => console.log(err))\n\n\t\t\t\tdocument.getElementById('send-form').disabled = 'true';\n\t\t\t\tdocument.getElementById('send-form').style.background = 'green';\n\t\t\t\tdocument.getElementById('send-form').innerText = \"Замовлення сформоване\"\n\t\t\t\tlocalStorage.clear();\n\n\t\t\t\tROOT_ORDERINFO.innerHTML = html;\n\t\t}\n \n\t\t\n\t}\n}", "function processForm(e) {\n if (e.preventDefault) e.preventDefault();\n\n /* do what you want with the form */\n\n\n\n\n //guardamos el usuario\n nombreUsuario = document.getElementById(\"nombreUsuarioForm\").value;\n\n\n element.style.display = \"none\";\n\n\n //Enviamos informacion de usuario\n var auxContraseña = document.getElementById(\"contraseñaForm\").value;\n\n $.ajax({\n method: \"PUT\",\n url: \"http://localhost:8080/cuenta\",\n //url: \"https://lastnightfall-landing.herokuapp.com/cuenta\",\n data: JSON.stringify({usuario : nombreUsuario,contrasena: auxContraseña}),\n processData: false,\n headers: {\n \"Content-type\":\"application/json\"\n }\n }).done(function(data, textStatus, jqXHR) {\n\n if(data == true){\n\n that.scene.start(\"sceneMenu\");\n\n }else{\n \t //COLOCAMOS EL FORMULARIO\n\n //var element = this.add.dom(400, 600).createFromCache('formularioLogin');\n element = document.getElementById(\"div\");\n //element.style.position = \"absolute\";\n this.formUtil = new FormUtil({scene:this,rows:12,cols:20});\n //this.formUtil.showNumbers();\n\n this.formUtil.placeElementAt(107.25, \"div\", false, false);\n //this.formUtil.addChangeCallback(\"div\", this.textAreaChanged, this);\n //this.formUtil.setStyle('\n element.style.display = \"inline-block\";\n alert(\"Contraseña incorrecta\");\n }\n \n\n }).fail(function(data, textStatus, jqXHR){\n\n });\n\n // You must return false to prevent the default form behavior\n return false;\n }", "function POST(){\n \n}", "function submitRec(){\n\tconsole.log(\"came submitRecord\");\n\tconsole.log(blob);\n\t$(\"#submitRecord\").attr(\"disabled\",true);\n\tvar xhr = new XMLHttpRequest();\n\txhr.open('POST', '/getSpeechToText', true);\n\txhr.onreadystatechange = function () {\n\t\tif(xhr.readyState === XMLHttpRequest.DONE && xhr.status === 200) {\n\t\t\tconsole.log(xhr.responseText);\n\t\t\t$('#message').val(xhr.responseText);\n\t\t}\n\t};\n\txhr.send(blob);\n\t$(\"#recordDiv\").hide();\n\t$(\"#foodDiv\").show();\n\n}", "submitContactForm() {\n //Get element references\n const modal = document.getElementById(\"contact-success-modal\");\n const modalOverlay = document.getElementById(\"contact-modal-overlay\");\n \n //process the form\n const name = document.getElementById(\"name\").value;\n const email = document.getElementById(\"email\").value;\n const subj = document.getElementById(\"subject\").value;\n const msg = document.getElementById(\"message\").value;\n\n const xhr = new XMLHttpRequest();\n xhr.open(\"POST\", \"https://travisnwright.com/contact/form\", true);\n xhr.setRequestHeader('Content-Type', 'application/json');\n xhr.send(JSON.stringify({\n name: name,\n email: email,\n subject: subj,\n message: msg\n }));\n\n const onSuccess = function onSuccessfulSend() {\n if(xhr.status === 200) {\n //fade in the success modal\n this.fadeInModal(modal, modalOverlay);\n } else {\n //TODO: actual error handling\n }\n }\n\n xhr.onload = onSuccess.bind(this);\n }", "function displayForm(res){\n fs.readFile('./createnew.html', function (err, html) {\n if (err) {\n throw err; \n } \n res.writeHeader(200, {'Content-Type':'text/html'});\n res.write(html);\n res.end();\n });\n}", "function submitForm14()\n\t {\n\t\t\tvar data = $(\"#com-form\").serialize();\n\n\t\t\t$.ajax({\n\n\t\t\ttype : 'POST',\n\t\t\turl : 'comment_proce.php',\n\t\t\tdata : data,\n\t\t\tbeforeSend: function()\n\t\t\t{\n\t\t\t\t$(\"#error\").fadeOut();\n\t\t\t\t$(\"#btn-reply\").html('<span class=\"glyphicon glyphicon-transfer\"></span> &nbsp; sending ...');\n\t\t\t},\n\t\t\tsuccess : function(response)\n\t\t\t {\n\t\t\t\t\tif(response==\"ok\"){\n\n\t\t\t\t\t\t//$(\"#btn-reply\").html('<img src=\"btn-ajax-loader.gif\" /> &nbsp; Posting .....');\n//\t\t\t\t\t\tsetTimeout(' window.location.href = \"index\"; ',4000);\n window.history.go(0);\n\t\t\t\t\t}\n\t\t\t\t\telse{\n\n\t\t\t\t\t\t$(\"#error\").fadeIn(1000, function(){\n\t\t\t\t$(\"#error\").html('<div class=\"alert alert-danger\"> <span class=\"glyphicon glyphicon-info-sign\"></span> &nbsp; '+response+' !</div>');\n\t\t\t\t\t\t\t\t\t\t\t$(\"#btn-reply\").html('<span class=\"glyphicon glyphicon-log-in\"></span> &nbsp; Post');\n\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t }\n\t\t\t});\n\t\t\t\treturn false;\n\t\t}", "function getSyncDataForm(myForm, argId, argTp) {\r\n\tif(myForm != \"\" && myForm.action != undefined){ \r\n \thttpAction = myForm.action; \r\n \thttpMethod = myForm.method; \r\n \tcontentOfRequest = \"\"; \r\n \tfor(i = 0; i < myForm.elements.length; i++){ \r\n \telementos = myForm.elements[i]; \r\n \t\tif(elementos.name != \"\" && elementos.name != \"theFile\"){ \r\n \tcontentOfRequest += elementos.name + \"=\" + escape(elementos.value) + \"&\"; \r\n \t} \r\n \t} \r\n\t\tcontentOfRequest += \"ajaxGridId=\" + argId + \"&\"; \r\n\t\tcontentOfRequest += \"ajaxGridParam=\" + argTp + \"&\"; \r\n\t\t\r\n \tcontentOfRequest = contentOfRequest.substring(0, contentOfRequest.length -1); \r\n\t} else { \r\n \talert(\"Invalid Form.\"); \r\n } \r\n}", "function doFormStuff(modal) {\n var $context = modal,\n $closeButton = $('.modal-button__close', $context),\n $headerCloseButton = $('.modal-header__close', $context),\n $thanksCloseBtn = $('.-close', $context),\n $inputs = $('.modal-input', $context),\n $fullname = $('#fullName', $context),\n $jobtitle = $('#jobTitle', $context),\n $workEmail = $('#workEmail', $context),\n $phoneNumber = $('#phoneNumber', $context),\n $companyName = $('#companyName', $context),\n $numEmployees = $('#numEmployees', $context),\n $submit = $('#requestDemo', $context),\n validEmail = /^[-a-z0-9~!$%^&*_=+}{\\'?]+(\\.[-a-z0-9~!$%^&*_=+}{\\'?]+)*@([a-z0-9_][-a-z0-9_]*(\\.[-a-z0-9_]+)*\\.(aero|arpa|biz|com|coop|edu|gov|info|int|mil|museum|name|net|org|pro|travel|jobs|name|mobi|[a-z][a-z])|([0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}))(:[0-9]{1,5})?$/i,\n $headerRequest = $('.modal-header.-request', $context),\n $headerThanks = $('.modal-header.-thanks', $context),\n $bodyRequest = $('.modal-content.-request', $context),\n $bodyThanks = $('.modal-content.-thanks', $context),\n $successName = $('.form-firstname', $context);\n\n function sendToMixPanel() {\n var postData = {\n 'Fullname': $fullname.val(),\n 'Jobtitle': $jobtitle.val(),\n 'Email': $workEmail.val(),\n 'Phone': $phoneNumber.val(),\n 'Company': $companyName.val(),\n 'Employees': $numEmployees.val()\n };\n var apiData = {\n \"FullName\": $fullname.val(),\n \"JobTitle\": $jobtitle.val(),\n \"Email\": $workEmail.val(),\n \"Phone\": $phoneNumber.val(),\n \"Company\": $companyName.val(),\n \"Employees\": $numEmployees.val()\n };\n apiData = JSON.stringify(apiData);\n $.ajax({\n type: \"POST\",\n url: 'https://a3uz2ncpl3.execute-api.us-west-2.amazonaws.com/prod/send_email',\n data: apiData,\n success: function(resp){\n console.log(\"got message\");\n },\n error: function () {\n console.log(\"error in the api call\");\n },\n dataType: 'json'\n });\n mixpanel.track(\n 'DemoRequest',\n postData,\n function(e){\n console.log('Mixpanel tracked!');\n console.log(e);\n $successName.html($fullname.val());\n $headerRequest.hide();\n $bodyRequest.hide();\n $headerThanks.show();\n $bodyThanks.show();\n // go to the thank you page\n }\n );\n }\n\n function validateForm() {\n var valid = true;\n\n if ($fullname.val() === '') {\n $fullname.addClass('-error');\n } else {\n $fullname.removeClass('-error');\n }\n if ($jobtitle.val() === '') {\n $jobtitle.addClass('-error');\n } else {\n $jobtitle.removeClass('-error');\n }\n if ($workEmail.val() === '' || !validEmail.test($workEmail.val())) {\n $workEmail.addClass('-error');\n } else {\n $workEmail.removeClass('-error');\n }\n if ($phoneNumber.val() === '') {\n $phoneNumber.addClass('-error');\n } else {\n $phoneNumber.removeClass('-error');\n }\n if ($companyName.val() === '') {\n $companyName.addClass('-error');\n } else {\n $companyName.removeClass('-error');\n }\n if ($numEmployees.val() === '0') {\n $numEmployees.addClass('-error');\n } else {\n $numEmployees.removeClass('-error');\n }\n\n $inputs.each(function(i,e) {\n console.log(e);\n if ($(e).hasClass('-error')) {\n valid = false;\n }\n })\n if ($numEmployees.val() === '0') {\n valid = false;\n }\n\n if (valid === true) {\n sendToMixPanel()\n }\n }\n\n $submit.click(function(e) {\n e.preventDefault();\n // verify that fields are filled\n validateForm();\n })\n\n function closeSlider() {\n $('.modal-contents', modal).removeClass('-active');\n setTimeout(function() {\n modal.removeClass('-active');\n modal.empty();\n modal.remove();\n $('body').css('overflow','visible');\n window.location.hash = 'close';\n },300)\n }\n\n $closeButton.click(function(e) {\n e.preventDefault();\n closeSlider();\n });\n\n $headerCloseButton.click(function(e) {\n e.preventDefault();\n closeSlider();\n });\n\n $thanksCloseBtn.click(function(e) {\n e.preventDefault();\n closeSlider();\n })\n\n modal.click(function(e) {\n // close the modal when user clicks on the overlay\n if ($(e.target).hasClass('modal-overlay')) {\n closeSlider();\n }\n })\n\n $(window).on('hashchange', function() {\n if (window.location.has !== 'requestInfo') {\n $closeButton.trigger('click');\n }\n });\n\n }", "function send_form_in( name )\r\n{\r\n\treturn send_form( name , function( data ){ set_form_notice( name , data ) } );\r\n}", "okForm() {\n const { id } = this.state;\n const body = { id, parameters: this.stateParametersToArray() };\n this.submitForm(body);\n }", "function doSubmit() {\r\n\t\t\t// make sure form attrs are set\r\n\t\t\tvar t = $form.attr('target'), a = $form.attr('action');\r\n\r\n\t\t\t// update form attrs in IE friendly way\r\n\t\t\tform.setAttribute('target',id);\r\n\t\t\tif (form.getAttribute('method') != 'POST') {\r\n\t\t\t\tform.setAttribute('method', 'POST');\r\n\t\t\t}\r\n\t\t\tif (form.getAttribute('action') != s.url) {\r\n\t\t\t\tform.setAttribute('action', s.url);\r\n\t\t\t}\r\n\r\n\t\t\t// ie borks in some cases when setting encoding\r\n\t\t\tif (! s.skipEncodingOverride) {\r\n\t\t\t\t$form.attr({\r\n\t\t\t\t\tencoding: 'multipart/form-data',\r\n\t\t\t\t\tenctype: 'multipart/form-data'\r\n\t\t\t\t});\r\n\t\t\t}\r\n\r\n\t\t\t// support timout\r\n\t\t\tif (s.timeout) {\r\n\t\t\t\tsetTimeout(function() { timedOut = true; cb(); }, s.timeout);\r\n\t\t\t}\r\n\r\n\t\t\t// add \"extra\" data to form if provided in options\r\n\t\t\tvar extraInputs = [];\r\n\t\t\ttry {\r\n\t\t\t\tif (s.extraData) {\r\n\t\t\t\t\tfor (var n in s.extraData) {\r\n\t\t\t\t\t\textraInputs.push(\r\n\t\t\t\t\t\t\t$('<input type=\"hidden\" name=\"'+n+'\" value=\"'+s.extraData[n]+'\" />')\r\n\t\t\t\t\t\t\t\t.appendTo(form)[0]);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// add iframe to doc and submit the form\r\n\t\t\t\t$io.appendTo('body');\r\n io.attachEvent ? io.attachEvent('onload', cb) : io.addEventListener('load', cb, false);\r\n\t\t\t\tform.submit();\r\n\t\t\t}\r\n\t\t\tfinally {\r\n\t\t\t\t// reset attrs and remove \"extra\" input elements\r\n\t\t\t\tform.setAttribute('action',a);\r\n\t\t\t\tif(t) {\r\n\t\t\t\t\tform.setAttribute('target', t);\r\n\t\t\t\t} else {\r\n\t\t\t\t\t$form.removeAttr('target');\r\n\t\t\t\t}\r\n\t\t\t\t$(extraInputs).remove();\r\n\t\t\t}\r\n\t\t}", "function sendFormData() {\n\n\t\tsendAjaxRequest({\n\t\t\ttype: 'POST',\n\t\t\turl: '/user/save',\n\t\t\tdata: $form.serialize(),\n\t\t\tbefore: function () {\n\t\t\t\t$formLoader.addClass('visible');\n\t\t\t},\n\t\t\tdone: function (data) {\n\t\t\t\tupdateList();\n\t\t\t\tinitForm(null);\n\t\t\t\thideFormContainer();\n\t\t\t},\n\t\t\tfail: function (jqXHR, textStatus) {\n\t\t\t\tshowModal('Error', 'An error occured');\n\t\t\t},\n\t\t\talways: function () {\n\t\t\t\t$formLoader.removeClass('visible');\n\t\t\t}\n\t\t});\n\t}", "function doSubmit() {\n\t\t\t// make sure form attrs are set\n\t\t\tvar t = $form.attr('target'), a = $form.attr('action');\n\n\t\t\t// update form attrs in IE friendly way\n\t\t\tform.setAttribute('target',id);\n\t\t\tif (form.getAttribute('method') != 'POST') {\n\t\t\t\tform.setAttribute('method', 'POST');\n\t\t\t}\n\t\t\tif (form.getAttribute('action') != s.url) {\n\t\t\t\tform.setAttribute('action', s.url);\n\t\t\t}\n\n\t\t\t// ie borks in some cases when setting encoding\n\t\t\tif (! s.skipEncodingOverride) {\n\t\t\t\t$form.attr({\n\t\t\t\t\tencoding: 'multipart/form-data',\n\t\t\t\t\tenctype: 'multipart/form-data'\n\t\t\t\t});\n\t\t\t}\n\n\t\t\t// support timout\n\t\t\tif (s.timeout) {\n\t\t\t\tsetTimeout(function() { timedOut = true; cb(); }, s.timeout);\n\t\t\t}\n\n\t\t\t// add \"extra\" data to form if provided in options\n\t\t\tvar extraInputs = [];\n\t\t\ttry {\n\t\t\t\tif (s.extraData) {\n\t\t\t\t\tfor (var n in s.extraData) {\n\t\t\t\t\t\textraInputs.push(\n\t\t\t\t\t\t\t$('<input type=\"hidden\" name=\"'+n+'\" value=\"'+s.extraData[n]+'\" />')\n\t\t\t\t\t\t\t\t.appendTo(form)[0]);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// add iframe to doc and submit the form\n\t\t\t\t$io.appendTo('body');\n\t\t\t\t$io.data('form-plugin-onload', cb);\n\t\t\t\tform.submit();\n\t\t\t}\n\t\t\tfinally {\n\t\t\t\t// reset attrs and remove \"extra\" input elements\n\t\t\t\tform.setAttribute('action',a);\n\t\t\t\tif(t) {\n\t\t\t\t\tform.setAttribute('target', t);\n\t\t\t\t} else {\n\t\t\t\t\t$form.removeAttr('target');\n\t\t\t\t}\n\t\t\t\t$(extraInputs).remove();\n\t\t\t}\n\t\t}", "function doFormStuff(modal) {\n var $context = modal,\n $closeButton = $('.modal-button__close', $context),\n $thanksCloseBtn = $('.-close', $context),\n $inputs = $('.modal-input', $context),\n $fullname = $('#fullName', $context),\n $jobtitle = $('#jobTitle', $context),\n $workEmail = $('#workEmail', $context),\n $phoneNumber = $('#phoneNumber', $context),\n $companyName = $('#companyName', $context),\n $numEmployees = $('#numEmployees', $context),\n $submit = $('#requestDemo', $context),\n validEmail = /^[-a-z0-9~!$%^&*_=+}{\\'?]+(\\.[-a-z0-9~!$%^&*_=+}{\\'?]+)*@([a-z0-9_][-a-z0-9_]*(\\.[-a-z0-9_]+)*\\.(aero|arpa|biz|com|coop|edu|gov|info|int|mil|museum|name|net|org|pro|travel|jobs|name|mobi|[a-z][a-z])|([0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}))(:[0-9]{1,5})?$/i,\n $headerRequest = $('.modal-header.-request', $context),\n $headerThanks = $('.modal-header.-thanks', $context),\n $bodyRequest = $('.modal-content.-request', $context),\n $bodyThanks = $('.modal-content.-thanks', $context),\n $successName = $('.form-firstname', $context);\n\n function sendToMixPanel() {\n var postData = {\n 'Fullname': $fullname.val(),\n 'Jobtitle': $jobtitle.val(),\n 'Email': $workEmail.val(),\n 'Phone': $phoneNumber.val(),\n 'Company': $companyName.val(),\n 'Employees': $numEmployees.val()\n };\n var apiData = {\n \"FullName\": $fullname.val(),\n \"JobTitle\": $jobtitle.val(),\n \"Email\": $workEmail.val(),\n \"Phone\": $phoneNumber.val(),\n \"Company\": $companyName.val(),\n \"Employees\": $numEmployees.val()\n };\n apiData = JSON.stringify(apiData);\n $.ajax({\n type: \"POST\",\n url: 'https://a3uz2ncpl3.execute-api.us-west-2.amazonaws.com/prod/send_email',\n data: apiData,\n success: function(resp){\n console.log(\"got message\");\n },\n error: function () {\n console.log(\"error in the api call\");\n },\n dataType: 'json'\n });\n mixpanel.track(\n 'DemoRequest',\n postData,\n function(e){\n console.log('Mixpanel tracked!');\n console.log(e);\n $successName.html($fullname.val());\n $headerRequest.hide();\n $bodyRequest.hide();\n $headerThanks.show();\n $bodyThanks.show();\n // go to the thank you page\n }\n );\n }\n\n function validateForm() {\n var valid = true;\n\n if ($fullname.val() === '') {\n $fullname.addClass('-error');\n } else {\n $fullname.removeClass('-error');\n }\n if ($jobtitle.val() === '') {\n $jobtitle.addClass('-error');\n } else {\n $jobtitle.removeClass('-error');\n }\n if ($workEmail.val() === '' || !validEmail.test($workEmail.val())) {\n $workEmail.addClass('-error');\n } else {\n $workEmail.removeClass('-error');\n }\n if ($phoneNumber.val() === '') {\n $phoneNumber.addClass('-error');\n } else {\n $phoneNumber.removeClass('-error');\n }\n if ($companyName.val() === '') {\n $companyName.addClass('-error');\n } else {\n $companyName.removeClass('-error');\n }\n if ($numEmployees.val() === '0') {\n $numEmployees.addClass('-error');\n } else {\n $numEmployees.removeClass('-error');\n }\n\n $inputs.each(function(i,e) {\n console.log(e);\n if ($(e).hasClass('-error')) {\n valid = false;\n }\n })\n if ($numEmployees.val() === '0') {\n valid = false;\n }\n\n if (valid === true) {\n sendToMixPanel()\n }\n }\n\n $submit.click(function(e) {\n e.preventDefault();\n // verify that fields are filled\n validateForm();\n })\n\n $closeButton.click(function(e) {\n e.preventDefault();\n modal.empty();\n modal.removeClass('-active');\n modal.remove();\n $('body').css('overflow','visible');\n window.location.hash = 'close';\n });\n\n $thanksCloseBtn.click(function(e) {\n e.preventDefault();\n modal.empty();\n modal.removeClass('-active');\n modal.remove();\n $('body').css('overflow','visible');\n window.location.hash = 'close';\n })\n\n modal.click(function(e) {\n // close the modal when user clicks on the overlay\n if ($(e.target).hasClass('modal-overlay')) {\n modal.empty();\n modal.removeClass('-active');\n modal.remove();\n $('body').css('overflow','visible');\n window.location.hash = 'close';\n }\n })\n\n $(window).on('hashchange', function() {\n if (window.location.has !== 'requestInfo') {\n $closeButton.trigger('click');\n }\n });\n\n }", "function getForm() {\n var xhr = new XMLHttpRequest();\n \n xhr.onreadystatechange = function () {\n if (xhr.readyState === 4 && (xhr.status === 200 || xhr.status === 0)) {\n var contentNode = document.getElementById('page_content');\n contentNode.innerHTML = xhr.responseText;\n $('#uploadAlert').hide();\n setSubmitFunction();\n }\n };\n \n xhr.open('GET', 'upload.php', true);\n xhr.send(null);\n}", "function processForm(req, res){\n var form = new formidable.IncomingForm();\n\n //parse form\n form.parse(req, function (err, fields){\n\n //add a dummy id to the return value\n fields.id = '123456';\n\n //add the response code\n res.writeHead(201, {\n 'content-type' : 'text/plain'\n });\n\n //Create a string containing the body in json, no spaces\n var data = JSON.stringify({\n fields: fields\n });\n\n res.end(data);\n\n console.log('posted fields :\\n');\n console.log('The data as string ', data);\n console.log('The data as Json ', util.inspect({\n fields: fields\n }));\n });\n}", "function sendForm(type, form, mod,e){\r\n\t{\r\n\t\tif(type == \"Customer\"){\t\t\r\n\t\t\t\r\n\t\t\tvar name \t\t= document.getElementById(mod+\"NameCl\").value;\r\n\t\t\tvar surname\t\t= document.getElementById(mod+\"SurnameCl\").value;\r\n\t\t\tvar birthDate \t= document.getElementById(mod+\"BirthCl\").value;\r\n\t\t\tvar birthPlace \t= document.getElementById(mod+\"PlaceCl\").value;\r\n\t\t\tvar address \t= document.getElementById(mod+\"AddressCl\").value;\r\n\t\t\tvar civicNumber = document.getElementById(mod+\"CivicNumberCl\").value;\r\n\t\t\tvar city \t\t= document.getElementById(mod+\"CityCl\").value;\r\n\t\t\tvar province \t= document.getElementById(mod+\"ProvinceCl\").value;\r\n\t\t\tvar cap \t\t= document.getElementById(mod+\"CapCl\").value;\r\n\t\t\tvar phone \t\t= document.getElementById(mod+\"PhoneCl\").value;\r\n\t\t\tvar email \t\t= document.getElementById(mod+\"EmailCl\").value;\r\n\t\t\t\r\n\t\t\tif( name==\"\"\t||surname==\"\"\t||birthDate==\"\"\t\t||birthPlace==\"\"||\r\n\t\t\t\tprovince==\"\"||address==\"\"\t||civicNumber==\"\"\t||city==\"\"\t\t||\r\n\t\t\t\tphone==\"\"\t||province==\"\"\t\t||cap==\"\"\t\t\t||email==\"\"\t\t\t)\r\n\t\t\t{\r\n\t\t\t\talert(\"<strong>Warning!</strong> Campi vuoti o non conformi!!\");\r\n\t\t\t\treturn;\t\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t\r\n\t\t}\r\n\t\telse if(type == \"Article\"){\t\r\n\t\t\t\r\n\t\t\tvar name\t\t= document.getElementById(mod+\"NameA\").value;\r\n\t\t\tvar price\t\t= document.getElementById(mod+\"PriceA\").value;\r\n\t\t\tvar description = document.getElementById(mod+\"DescriptionA\").value;\r\n\t\t\tvar duration \t= document.getElementById(mod+\"DurationA\").value;\r\n\t\t\t\r\n\t\t\tif(name==\"\" || price==\"\" || description==\"\"||duration==\"\"){\r\n\t\t\t\talert(\"<strong>Warning!</strong> Campi vuoti o non conformi!!\");\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t\telse if(type == \"Service\"){\t\r\n\t\t\t\r\n\t\t\tvar codService\t= document.getElementById(mod+\"CodS\").value;\r\n\t\t\tvar customer\t= document.getElementById(mod+\"CustomerS\").value;\r\n\t\t\tvar quantity\t= document.getElementById(mod+\"QuantityS\").value;\r\n\t\t\tvar variation\t= document.getElementById(mod+\"VariationS\").value;\r\n\t\t\tvar note\t \t= document.getElementById(mod+\"NoteS\").value;\r\n\t\t\tvar date\t\t= document.getElementById(mod+\"ReceiptDateS\").value;\r\n\t\t\tvar rest\t \t= document.getElementById(mod+\"ReturnDateS\").value;\r\n\t\t\tvar employee\t= document.getElementById(mod+\"EmployeeS\").value;\r\n\t\t\tvar articleId\t= document.getElementById(mod+\"AidS\").value;\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tif( codService==\"\"\t||customer==\"\"\t||quantity==\"\"\t||variation==\"\"\t||\r\n\t\t\t\tnote==\"\"\t\t||date==\"\"\t\t||rest==\"\"\t\t||employee==\"\"\t|| articleId==\"\"){\r\n\t\t\t\talert(\"<strong>Warning!</strong> Campi vuoti o non conformi!!\");\t\t\t\t\r\n\t\t\t\treturn;\r\n\t\t\t}\t\r\n\t\t}\r\n\t\telse if(type == \"Payment\"){\t\t\r\n\t\t\t\r\n\t\t\tvar customer\t= document.getElementById(mod+\"CustomerP\").value;\r\n\t\t\tvar service\t\t= document.getElementById(mod+\"ServiceP\").value;\r\n\t\t\tvar serviceType\t= document.getElementById(mod+\"ServiceTypeP\").value;\r\n\t\t\tvar amount\t\t= document.getElementById(mod+\"AmountP\").value;\r\n\t\t\tvar date\t\t= document.getElementById(mod+\"DateP\").value;\r\n\r\n\t\t\tif(customer==\"\"||service==\"\"||serviceType==\"\"||amount==\"\"||date==\"\"){\r\n\t\t\t\talert(\"<strong>Warning!</strong> Campi vuoti o non conformi!!\");\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t}\r\n\t\telse if(type == \"User\"){\r\n\t\t\tvar name\t\t\t= document.getElementById(mod+\"name\").value;\r\n\t\t\tvar surname\t\t\t= document.getElementById(mod+\"surname\").value;\r\n\t\t\tvar birthDate\t\t= document.getElementById(mod+\"birthDate\").value;\r\n\t\t\tvar birthPlace\t\t= document.getElementById(mod+\"birthPlace\").value;\r\n\t\t\tvar address\t\t\t= document.getElementById(mod+\"address\").value;\r\n\t\t\tvar civicNumber\t\t= document.getElementById(mod+\"civicNumber\").value;\r\n\t\t\tvar city\t\t\t= document.getElementById(mod+\"city\").value;\r\n\t\t\tvar province\t\t= document.getElementById(mod+\"province\").value;\r\n\t\t\tvar cap\t\t\t\t= document.getElementById(mod+\"cap\").value;\r\n\t\t\tvar email\t\t\t= document.getElementById(mod+\"email\").value;\r\n\t\t\tvar taxCode\t\t\t= document.getElementById(mod+\"taxCode\").value;\r\n\t\t\tvar password\t\t= document.getElementById(mod+\"password\").value;\r\n\t\t\tvar confPassword\t= document.getElementById(mod+\"confPassword\").value;\r\n\t\t\t\r\n\t\t\tif(\tname==\"\"\t||\tsurname==\"\"\t\t||\tbirthDate==\"\"\t||\tbirthPlace==\"\"\t||\r\n\t\t\t\taddress==\"\"\t||\tcivicNumber==\"\"||\tcity==\"\"\t\t||\tprovince==\"\"\t||\r\n\t\t\t\tcap==\"\"\t\t||\temail==\"\"\t\t||\ttaxCode==\"\"\t\t||\tpassword==\"\"\t||\r\n\t\t\t\tconfPassword==\"\"){\r\n\t\t\t\talert(\"<strong>Warning!</strong> Campi vuoti o non conformi!!\");\t\t\t\t\r\n\t\t\t\treturn;\r\n\t\t\t\r\n\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\t\t$.ajax({\r\n\t\t\t\ttype: \"POST\",\r\n\t\t\t\turl: type+\"Controller\",\r\n\t\t\t\tdata: $(form).serialize(),\r\n\t\t\t\tdataType: \"text\",\r\n\t\t\t\tsuccess: function(data, status, xhr)\r\n\t\t\t\t{\r\n\t\t\t\t\t$('.modal').modal('hide');\r\n\t\t\t\t\t$('#modalConf').modal('show');\r\n\t\t\t\t\tif(xhr.responseText == \"updateOk\"){\r\n\t\t\t\t\t\t$(\"#status\").html(\"Modifica effettuata con successo\");\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if(xhr.responseText == \"insertOk\"){\r\n\t\t\t\t\t\t$(\"#status\").html(\"Inserimento effettuata con successo\");\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if(xhr.responseText == \"removeOk\"){\r\n\t\t\t\t\t\t$(\"#status\").html(\"Eliminazione effettuata con successo\");\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if(xhr.responseText == \"exists\"){\r\n\t\t\t\t\t\t$(\"#status\").html(\"Elemento già esistente\");\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if(xhr.responseText == \"noExists\"){\r\n\t\t\t\t\t\t$(\"#status\").html(\"Non sono presenti all'interno del db\");\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if(xhr.responseText == \"empty\"){\r\n\t\t\t\t\t\t$(\"#status\").html(\"Nessun elemento presente\");\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if(xhr.responseText == \"regExpError\"){\r\n\t\t\t\t\t\t$(\"#status\").html(\"Rispettare il formato\");\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if(xhr.responseText == \"emptyList\"){\r\n\t\t\t\t\t\t$(\"#status\").html(\"Nessun elemento presente\");\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if(xhr.responseText == \"cError\"){\r\n\t\t\t\t\t\t$(\"#status\").html(\"Errore Di Connessione\");\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if(xhr.responseText == \"dbError\"){\r\n\t\t\t\t\t\t$(\"#status\").html(\"Errore di connessione al Database\");\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse{\r\n\t\t\t\t\t\t$(\"#status\").html(\"Errore Generico\");\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t\te.preventDefault();\r\n\t\t\r\n\t}\r\n}", "function postMail()\n{\n \tvar x = document.getElementById('message').contentWindow.document.body.innerHTML;\n \t//alert(x);\n \tvar form = document.getElementById('mail');\n \tvar texte = document.createElement('input');\n \ttexte.setAttribute('type','text');\n \ttexte.setAttribute('name','message');\n \ttexte.setAttribute('value',x);\n \ttexte.setAttribute('style','display:none');\n\tform.appendChild(texte);\n\tdocument.forms['mail'].submit();\n}", "function sendForm(form) {\n\n if (checkInfo()) {\n var formData = new FormData(form);\n request(\"POST\", URL, formData, function (error) {\n if (error !== null) {\n alert('Es ist ein Fehler aufgetreten!');\n return;\n }\n alert('Ihre Daten wurden erfolgreich gesendet');\n });\n\n }\n}", "function Form(form) {\n var self = this;\n this.form = form;\n this.inputs = this.form.querySelectorAll('[name]');\n this.submitBtn = this.form.querySelector('button');\n\n this.canSubmit = function () {\n var regex = {\n text: /^.+$/,\n textarea: /.+/,\n email: /^[^@\\s]+@[^@\\s\\.]+\\.[\\w\\.]+$/\n };\n var canSubmit = true;\n for (var i = 0; i < self.inputs.length; i++) {\n var input = self.inputs[i];\n if (input.required && regex[input.type] && !regex[input.type].test(input.value)) {\n input.classList.add('animated');\n input.classList.remove('headShake');\n waitFrame((function (_input) {\n return function () {\n _input.classList.add('headShake');\n };\n })(input));\n canSubmit = false;\n } else\n input.classList.remove('headShake');\n }\n return canSubmit;\n };\n\n this.submit = function () {\n if (!self.canSubmit())\n return;\n window.clientName = document.getElementById('name').value;\n var xhr;\n if (window.XMLHttpRequest) {\n xhr = new XMLHttpRequest();\n } else {\n xhr = new ActiveXObject('Microsoft.XMLHTTP');\n }\n xhr.onreadystatechange = function () {\n if (this.readyState == 4 && this.status == 200) {\n router.go('/thankyou/');\n var name = document.querySelector('#submiterName');\n if (name)\n name.innerHTML = ' ' + window.clientName + '. Y';\n }\n };\n var data = '?';\n for (var i = 0; i < this.inputs.length; i++) {\n var input = this.inputs[i];\n if (input.value !== '')\n if (i === 0)\n data += input.name + '=' + input.value;\n else\n data += '&' + input.name + '=' + input.value;\n }\n console.log(data);\n xhr.open('POST', '/static/inc/submitform.php' + encodeURI(data), true);\n xhr.send();\n };\n\n this.submitBtn.addEventListener('click', function (evt) {\n evt.preventDefault();\n self.submit();\n });\n}", "function doSubmit() {\n\t\t\t// make sure form attrs are set\n\t\t\tvar t = $form.attr('target'), a = $form.attr('action');\n\n\t\t\t// update form attrs in IE friendly way\n\t\t\tform.setAttribute('target',id);\n\t\t\tif (form.getAttribute('method') != 'POST') {\n\t\t\t\tform.setAttribute('method', 'POST');\n\t\t\t}\n\t\t\tif (form.getAttribute('action') != s.url) {\n\t\t\t\tform.setAttribute('action', s.url);\n\t\t\t}\n\n\t\t\t// ie borks in some cases when setting encoding\n\t\t\tif (! s.skipEncodingOverride) {\n\t\t\t\t$form.attr({\n\t\t\t\t\tencoding: 'multipart/form-data',\n\t\t\t\t\tenctype: 'multipart/form-data'\n\t\t\t\t});\n\t\t\t}\n\n\t\t\t// support timout\n\t\t\tif (s.timeout) {\n\t\t\t\tsetTimeout(function() { timedOut = true; cb(); }, s.timeout);\n\t\t\t}\n\n\t\t\t// add \"extra\" data to form if provided in options\n\t\t\tvar extraInputs = [];\n\t\t\ttry {\n\t\t\t\tif (s.extraData) {\n\t\t\t\t\tfor (var n in s.extraData) {\n\t\t\t\t\t\textraInputs.push(\n\t\t\t\t\t\t\t$('<input type=\"hidden\" name=\"'+n+'\" value=\"'+s.extraData[n]+'\" />')\n\t\t\t\t\t\t\t\t.appendTo(form)[0]);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// add iframe to doc and submit the form\n\t\t\t\t$io.appendTo('body');\n io.attachEvent ? io.attachEvent('onload', cb) : io.addEventListener('load', cb, false);\n\t\t\t\tform.submit();\n\t\t\t}\n\t\t\tfinally {\n\t\t\t\t// reset attrs and remove \"extra\" input elements\n\t\t\t\tform.setAttribute('action',a);\n\t\t\t\tif(t) {\n\t\t\t\t\tform.setAttribute('target', t);\n\t\t\t\t} else {\n\t\t\t\t\t$form.removeAttr('target');\n\t\t\t\t}\n\t\t\t\t$(extraInputs).remove();\n\t\t\t}\n\t\t}", "function submitForm(e) {\n e.preventDefault();\n\n // Get values\n\n var title = getInputVal(\"title\");\n\n var ingredients = getInputVal(\"ingredients\");\n\n var steps = getInputVal(\"steps\");\n\n // gets input from form and sends to database\n\n saveMessage(title, ingredients, steps);\n\n document.getElementById(\"newRecipe\").reset();\n}", "function submitForm(url, content, parseFunction){\n var deferred = $q.defer();\n function toFormData(content){\n var fd = new FormData();\n angular.forEach(content, function(el, key){\n fd.append(key, el);\n });\n return fd;\n }\n var xhr = new XMLHttpRequest();\n xhr.open( 'POST', url, true );\n xhr.onreadystatechange = function() {\n if (xhr.readyState==4){\n if (xhr.status==200) {\n var result;\n if (angular.isFunction(parseFunction)){\n result = parseFunction(xhr.responseText);\n } else {\n result = xhr.responseText;\n }\n deferred.resolve(result);\n } else {\n deferred.reject(xhr);\n }\n }\n };\n xhr.send( toFormData( content ) );\n return deferred.promise;\n }", "function accionForm (datos) {\n var id_boton = $(this).attr('id');\n var tabla = $(\"#nom-tabla\").val();\n var nom = encodeURIComponent($(\"#nom\").val());\n var campos = $(\"#campos\").val();\n var requeridos = $(\"#requeridos\").val();\n var camp = campos.split(',');\n var campo_post = \"\";\n if(requeridos.length){\n var req = requeridos.split(',');\n for (var i = 0; i < req.length; i++) {\n var valor_req = $(\"#\"+req[i]).val();\n if(valor_req === ''){\n swal({title: \"Error!\",text: \"Este campo es requerido.\",type: \"error\",confirmButtonText: \"Aceptar\",confirmButtonColor: \"#E25856\"},function(){$(\"#\"+req[i]).focus();});\n return false;\n }\n }\n }\n for(var i = 0; i < camp.length; i++){\n if(i === 0){\n campo_post += camp[i]+\"=\"+$(\"#\"+camp[i]).val();\n }\n else{\n campo_post += \"&\"+camp[i]+\"=\"+$(\"#\"+camp[i]).val();\n }\n }\n // validamos si la tabla es la de banner\n if((tabla === 'rmb_banner') || (tabla === 'rmb_tcont')){\n var datos_form = new FormData($(\"#form_master\")[0]);\n }\n\n switch(id_boton){\n case 'cancel':\n $(\"#col-md-12\").load(\"./lista.php?tabla=\"+tabla+\"&nom=\"+nom);\n return;\n break;\n case 'ingresar':\n if((tabla === 'rmb_banner') || (tabla === 'rmb_tcont')){\n var send_post = datos_form;\n }\n else{\n var send_post = \"ins=1&tabla=\"+tabla+\"&\"+campo_post;\n }\n break;\n case 'actualizar':\n if((tabla === 'rmb_banner') || (tabla === 'rmb_tcont')){\n var send_post = datos_form;\n }\n else{\n var id = $(\"#id\").val();\n var send_post = \"id_upd=\"+id+\"&tabla=\"+tabla+\"&\"+campo_post;\n }\n break;\n }\n //Enviar los datos para ingresar o actualizar\n if((tabla === 'rmb_banner') || (tabla === 'rmb_tcont')){\n $.ajax({\n url:\"./edicion.php\",\n cache:false,\n type:\"POST\",\n contentType:false,\n data:send_post,\n processData:false,\n success: function(datos){\n if(datos !== ''){\n swal({\n title: \"Felicidades!\",\n text: datos,\n type: \"success\",\n confirmButtonText: \"Continuar\",\n confirmButtonColor: \"#94B86E\"\n },\n function() {\n $(\"#col-md-12\").load(\"./lista.php?tabla=\"+tabla+\"&nom=\"+nom);\n });\n }\n else{\n swal({\n title: \"Error!\",\n text: \"No se pudo \"+id_boton+\" el registro\",\n type: \"error\",\n confirmButtonText: \"Aceptar\",\n confirmButtonColor: \"#E25856\"\n },\n function() {\n $(\"#\"+req[i]).focus();\n });\n }\n }\n });\n }\n else{\n $.ajax({\n url:\"./edicion.php\",\n cache:false,\n type:\"POST\",\n data:send_post,\n success: function(datos){\n if(datos !== ''){\n swal({\n title: \"Felicidades!\",\n text: datos,\n type: \"success\",\n confirmButtonText: \"Continuar\",\n confirmButtonColor: \"#94B86E\"\n },\n function() {\n $(\"#col-md-12\").load(\"./lista.php?tabla=\"+tabla+\"&nom=\"+nom);\n });\n }\n else{\n swal({\n title: \"Error!\",\n text: \"No se pudo \"+id_boton+\" el registro\",\n type: \"error\",\n confirmButtonText: \"Aceptar\",\n confirmButtonColor: \"#E25856\"\n },\n function() {\n $(\"#\"+req[i]).focus();\n });\n }\n }\n });\n }\n}", "function processForm(e) {\n if (e.preventDefault) e.preventDefault();\n \n /*\n \n // if(e.keyCode == 13){\n console.log(\"ENVIO MENSAJE\");\n \n \n var auxValorChat = document.getElementById(\"chatButton\").value; //guardamos el texto que se desea enviar\n document.getElementById(\"chatButton\").value = (\"\");//booramos el contenido del chat\n \n \n \n //ENVIAMOS MENSAJE\n \n $.ajax({\n method: \"PUT\",\n url:\"http://localhost:8080/mensaje\",\n data: JSON.stringify({texto: auxValorChat,usuario : nombreUsuario}),\n processData: false,\n headers: {\n \"Content-type\":\"application/json\"\n }\n }).done(function(data, textStatus, jqXHR) {\n // console.log(textStatus+\" \"+jqXHR.statusCode());\n }).fail(function(data, textStatus, jqXHR){\n //console.log(textStatus+\" \"+jqXHR.statusCode());\n });\n \n // }\n \n // You must return false to prevent the default form behavior\n */\n \n return false;\n }", "async function sendData() {\r\n const res = await fetch(\"/formulier/afhalen\", {\r\n method: \"POST\",\r\n body: JSON.stringify({\r\n naam: `${voorNaam} ${achterNaam}`,\r\n \"materiaal\": materiaal,\r\n datumTijd: currentDate,\r\n \"teruggebracht\": \"neen\",\r\n }),\r\n headers: {\r\n \"content-type\": \"application/json; charset=UTF-8\"\r\n }\r\n });\r\n if (!res.ok || res.status !== 200) {\r\n console.error('Error at sending data: ', res);\r\n return\r\n };\r\n const feedback = await res.json();\r\n if (feedback.message !== \"\") {\r\n sendErrorMessage(feedback.message);\r\n } else {\r\n const wrapper = document.querySelector(\".afhalen-wrapper\");\r\n wrapper.style.display = \"none\";\r\n // just to clear the error box if there is any\r\n sendErrorMessage(\"\");\r\n // reset the state\r\n resetState();\r\n }\r\n }", "function send_specific_info_into_db(form_submit){\t\t\n\t\t$(form_submit).submit(function(evt){\n\t\tvar article_id = $('#edit_article_container').attr('rel');\n\t\t\t//alert(article_id);\n\t\tevt.preventDefault();\n\t\tvar postData = $(this).serialize();\n\t\tvar url = $(this).attr('action');\n\t\t\t$.post(url, postData, function(php_table_data){\n\t\t\t\twindow.location = 'preview.php?article_id=' + article_id;\n\t\t\t});\n\t\t});\t\n\t}", "function sendFormData(data){\n //Sends data to the server\n var httpReq = new XMLHttpRequest();\n\n httpReq.open(\"GET\", \"/bairro/\" + data , true);\n httpReq.send(null);\n /* Renders the page with the HTTP Response from Server */\n httpReq.onreadystatechange = function () {\n if(httpReq.readyState === XMLHttpRequest.DONE && httpReq.status === 200) {\n document.write(httpReq.responseText);\n }\n };\n}", "function submitBtnHandler(e){\n e.preventDefault();\n let form = document.querySelector('form');\n\n let formData = processForm(form);\n let path = document.getElementById('stackID').value;\n let url = `${form.action}${path.replace(' ','')}`;\n \n xhr.onload = success;\n\n if(form.method === 'post'){\n url += `/${formData[\"act\"]}`;\n xhr.open(form.method,url,true);\n xhr.send(JSON.stringify(formData));\n return;\n }\n\n xhr.open(form.method,url,true);\n xhr.send();\n}", "function formSend(form) {\n $.ajax({\n type: \"POST\",\n url: \"https://xdfz4o3cjk.execute-api.eu-west-2.amazonaws.com/live/networkingwater\",\n data: form.serialize(),\n dataType: 'x-www-form-urlencoded',\n contentType: 'application/x-www-form-urlencoded',\n success: function(data)\n {\n alert(\"Data Submitted!\");\n console.log('submit successful')\n }\n });\n }", "function getForm(req, res){\n var fileUrl = config.public + '/form.html';\n \n obtainData(req)\n .then(function(information){\n return compileFile(fileUrl, information);\n })\n .then(function(fileData){\n res.send(fileData);\n })\n .catch(function(err){\n console.log(err);\n res.send(500);\n });\n}", "function save_form_data(){\r\n\r\n var memberHash = localStorage.getItem(\"twocubeSSO\") || 0;\r\n if (memberHash == 0) {\r\n alert('Please login or register before submiting');\r\n return;\r\n }\r\n \r\n //document.getElementById('display').innerHTML = JSON.stringify(main_form.data);\r\n //document.getElementById('display2').innerHTML = ds.stringify();\r\n\r\n\r\n var myForm = document.createElement(\"form\");\r\n myForm.method = \"post\";\r\n myForm.action = \"./Services/SurveyControllerService.asmx/repeater\";\r\n\r\n var myInput = document.createElement(\"input\");\r\n myInput.setAttribute(\"name\", \"formString\");\r\n myInput.setAttribute(\"value\", JSON.stringify(main_form.data));\r\n myForm.appendChild(myInput);\r\n\r\n var myInput2 = document.createElement(\"input\");\r\n myInput2.setAttribute(\"name\", \"elementString\");\r\n myInput2.setAttribute(\"value\", ds.stringify());\r\n myForm.appendChild(myInput2);\r\n\r\n var myInput3 = document.createElement(\"input\");\r\n myInput3.setAttribute(\"name\", \"memberHash\");\r\n myInput3.setAttribute(\"value\", memberHash);\r\n myForm.appendChild(myInput3);\r\n document.body.appendChild(myForm);\r\n myForm.submit();\r\n document.body.removeChild(myForm);\r\n \r\n\r\n/*$.post(\"./Services/SurveyControllerService.asmx/repeater\", { formString: JSON.stringify(main_form.data), elementString: ds.stringify(), memberHash: memberHash},\r\n function(data) {\r\n alert(\"Data Loaded: \" + data);\r\n });*/\r\n \r\n\r\n\r\n\r\n\tJJ(\"#statusText\").html(\"Saving ... Please wait ...\"); JJ(\"#form_save_button\").html(\"<img src=\\\"images/icons/filesave.gif\\\" /> Saving\"); main_form.data[\"frame_height\"] = JJ(\"#main\").outerHeight(); JJ(\"#form_save_button\").unbind(\"click\"); JJ.post(\"save.php\", { form: JSON.stringify(main_form.data), elements: ds.stringify() }, function (a) { form_aftersave_callback(a) })\r\n}" ]
[ "0.6838852", "0.664906", "0.6589881", "0.6575015", "0.6412511", "0.6399322", "0.6383439", "0.63556594", "0.6347237", "0.6347237", "0.6347237", "0.6347237", "0.6347237", "0.6347237", "0.6347237", "0.6347237", "0.6347237", "0.6342083", "0.6342083", "0.6339719", "0.6339719", "0.6339719", "0.6338558", "0.63240063", "0.63240063", "0.63240063", "0.6320145", "0.6262367", "0.62500036", "0.61884403", "0.6183666", "0.6183093", "0.6179531", "0.6179531", "0.6157582", "0.61426723", "0.6140849", "0.61393744", "0.613314", "0.6128117", "0.61234766", "0.6112198", "0.6083453", "0.60640323", "0.6033218", "0.6031806", "0.6027479", "0.602651", "0.60141736", "0.600341", "0.6001102", "0.5991434", "0.59913474", "0.59849894", "0.5963712", "0.5963113", "0.5957358", "0.5952649", "0.595159", "0.59506315", "0.59401083", "0.59383774", "0.59270126", "0.59212303", "0.59172493", "0.5908112", "0.5905003", "0.5896023", "0.5893197", "0.58931017", "0.58899796", "0.5887748", "0.5882912", "0.5882886", "0.58796793", "0.5879261", "0.5878227", "0.58712214", "0.58696246", "0.58680785", "0.58673614", "0.58669966", "0.58632314", "0.58630484", "0.5862806", "0.58627063", "0.5852967", "0.5850855", "0.58490574", "0.58471924", "0.5840889", "0.58324337", "0.58322096", "0.58319366", "0.5831741", "0.58299947", "0.58214647", "0.5820382", "0.58116025", "0.58068806" ]
0.63044804
27
var c_data="null"; var c_url="null"; var c_fu="null";
function m_removeall() { while(c_alldata.length>0) { c_alldata[c_alldata.length-1].c_disp.innerHTML=""; c_alldata.pop(); } ref_thumb(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function HTML_AJAX_Serialize_Null() {}", "function getData(requestUrl) {\n \n\n}", "function initializeStatefulVariables() {\n postAction = '';\n postArgument = 'sig_response';\n host = undefined;\n sigRequest = undefined;\n duoSig = undefined;\n appSig = undefined;\n iframe = undefined;\n submitCallback = undefined;\n }", "function emptyData(_vmode, _vurl, sPageType, iItemno) {\n try {\n var _framedoc = GetWFFrameDoc();\n\n var _url = _vurl;\n var _Qstr = _vurl.split(\"?\")[1];\n var _vrurl = _vurl.split(\"?\")[0];\n var sMode = getQueryStringValue(_vurl, \"mode\");\n var iActivityID = getQueryStringValue(_vurl, \"activityid\");\n\n if (sPageType.toString().toLowerCase() == \"callback\") {\n if (_framedoc.Script)\n _framedoc.Script.loadPageData(_framedoc.URLUnencoded, _Qstr, _vmode, iItemno);\n else\n getIFrameObj(\"wfFrame\" + pdf(\"CurrentDesk\")).loadPageData(decodeURIComponent(_framedoc.URL), _Qstr, _vmode, iItemno);\n }\n else {\n var d = new Date();\n pel(\"wfFrame\" + pdf(\"CurrentDesk\")).src = _vrurl + \"?activityid=\" + iActivityID + \"&mode=\" + _vmode + \"&pagetype=\" + sPageType + \"&itemno=\" + iItemno + \"&ts=\" + d.getTime();\n }\n if (parent.document.Script)\n parent.document.Script.focuscontroltype = \"\";\n else\n window.parent.focuscontroltype = \"\";\n $('.btncorner').corner();\n\n } catch (e) { }\n}", "function post_data(dest,string,handler,noLoadingImg) {\r\n\tuser_f_loadurl = handler;\r\n xmlhttp = getXMLobj();\r\n xmlhttp.onreadystatechange = function(){loadurl_response();};\r\n xmlhttp.open(\"POST\", dest,true);\r\n xmlhttp.setRequestHeader( \"Content-Type\" , \"application/x-www-form-urlencoded; charset=UTF-8\" );\r\n xmlhttp.send(string);\r\n //Make loading icon visible\r\n if (typeof(loading_img) == 'undefined' && noLoadingImg != true) {\r\n \tloading_img = new _loading_img();\r\n \tloading_img.preload(); \r\n }\r\n if (noLoadingImg != true) {\r\n\t\tloading_img.show();\r\n\t}\r\n}", "function nullDataHandler(transaction, results)\n{\n}", "function nullDataHandler(transaction, results)\n{\n}", "function nullDataHandler(transaction, results)\n{\n}", "function nullDataHandler(transaction, results)\n{\n}", "function resetJsAttributeVars(){\n\t//Determinamos los valores para realizar la búsqueda\n\tjsCobEtapaDeudaCodEtapDeud = '';\n\tjsCobEtapaDeudaValDesc = '';\n\tjsCobEtapaDeudaValEdadInic = '';\n\tjsCobEtapaDeudaValEdadFina = '';\n\t\n}", "function up_db(c)\n{\n\t\n\tsecondlayer(true);\n\t\n\t\n\tvar locid=$id(\"loc\").value;\n\tkeypress(false);\n\tvar t2={};\n\tt2['a_type']=c.name;\n\t\n\tvar find_radio=[];\n\n\t\n\t\tfor(var i=0;i<c.length;i++)\n\t\t{\n\t\t\tif(c[i].name!=\"\" && !c[i].disabled && (c[i].getAttribute(\"c_req\")==\"true\" || c[i].getAttribute(\"c_req\")==\"false\") )\n\t\t\t{\n\t\t\t\t\n\t\t\t\tif(c[i].type==\"radio\")\n\t\t\t\t{\n\t\t\t\t\tif(find_radio.indexOf(c[i].name)<0)\n\t\t\t\t\tfind_radio.push(c[i].name);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t\t{t2[c[i].name]=c[i].value;}\n\t\t\t}\n\t\t}\n\t\t\n\t\tfor(var i=0;i<find_radio.length;i++)\n\t\t{\n\t\t\tvar s=c[find_radio[i]];\n\t\t\tfor (x in s)\n\t\t\tif(s[x].checked)\n\t\t\t{\n\t\t\t\t\n\t\t\t\tt2[find_radio[i]]=s[x].value;\t\t\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\t\n\t\t\n\t\tt2['locid']=locid;\n\t\tsecondlayer(true,\"Uploading Data Please Wait <br>\");\n\t\tt2['file']=new Array();\n\t\tt2['url']=new Array();\n\t\t\n\t\tfor(var i=0;i<c_alldata.length;i++)\n\t\t{\n\t\t\tif(c_alldata[i].c_type==\"file\")\n\t\t\t\t{\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\tUploadFile(c_alldata[i]);\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\tvar ttx=new Object();\n\t\t\t\t\t\n\t\t\t\t\tttx.name=c_alldata[i].c_name;\n\t\t\t\t\tttx.title=c_alldata[i].c_title;\n\t\t\t\t\tttx.type=c_alldata[i].ext;\n\t\t\t\t\tt2['file'].push(ttx);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\n\t\t\t\t\t\n\t\t\t\t\tvar ttx=new Object();\n\t\t\t\t\t\n\t\t\t\t\tttx.name=c_alldata[i].c_url;\n\t\t\t\t\tttx.title=c_alldata[i].c_title;\n\t\t\t\t\tttx.type=c_alldata[i].ext;\n\t\t\t\t\tt2['url'].push(ttx);\n\t\t\t\t\t\n\t\t\t\t\tt2[c_alldata[i].c_disp.id]=c_alldata[i].c_type;\n\t\t\t\t\t\n\t\t\t\t}\n\t\t}\n\t\n\t\t\n\t\t\n\t\t\n\t\ttrack.send=JSON.stringify(t2);\n\t\tif(c_alldata.length==0||t2['type']==\"video\"||t2['img']=='imageurl')\n\t\ttrack.finish();\n\t\n}", "function preencherCampos(_url) {\n $.ajax({\n type: \"GET\",\n url: _url,\n dataType: \"json\",\n contentType: \"application/json; charset=utf-8\",\n success: function (result) {\n exibirDados(result);\n },\n error: OnError,\n complete: onComplete \n });\n}", "function DataUrl() \n{ \n var url = \"json.php?bucket=m\";\n url += \"&customer=\";\n if (params['customer'])\n {\t\n url += params['customer'];\n }\n url += \"&product=\";\n if (params['product'])\n {\t\n url += params['product'];\n }\n url += \"&os=\";\n if (params['os'])\n {\t\n url += params['os'];\n }\n url += \"&software1=\";\n if (params['software1'])\n {\n url += params['software1'];\n }\n url += \"&software2=\";\n if (params['software2'])\n {\n url += params['software2'];\n }\n url += \"&software3=\";\n if (params['software3'])\n {\n url += params['software3'];\n }\n url += \"&from=\";\n url += Math.floor(lookback);\n return url; \n}", "function wV(e){var t=e.method,n=t===void 0?\"POST\":t,r=e.action,a=e.withCredentials,o=a===void 0?!1:a,i=e.headers,l=i===void 0?{}:i,s=e.data,u=s===void 0?{}:s,c=e.file,d=e.files,f=e.name,m=f===void 0?\"file\":f,w=e.onError,h=e.onProgress,p=e.onSuccess,b=d||[],g=new XMLHttpRequest;o&&(g.withCredentials=!0);var y=new FormData,C=typeof u==\"function\"?u(c):u;return Object.keys(C).forEach(function(O){y.append(O,u[O])}),b.forEach(function(O){y.append(m,O&&O.raw)}),g.open(n,r,!0),Object.keys(l).forEach(function(O){g.setRequestHeader(O,l[O])}),g.onerror=function(O){return w({event:O,file:c,files:b})},g.upload&&(g.upload.onprogress=function(O){var k=0;O.total>0&&(k=Math.round(O.loaded/O.total*100)),h({event:O,percent:k,file:c,files:b})}),g.onload=function(O){var k,$=g.status<200||g.status>=300;if($)return w({event:O,file:c,files:b,response:k});var T=g.responseText||g.response;try{k=JSON.parse(T)}catch{k=T}p({event:O,file:c,files:b,response:k})},g.send(y),g}", "function DataUrl() \n{ \n var url = \"json.php?bucket=m\";\n url += \"&publisher=\";\n if (params['publisher']) \n {\t\n url += params['publisher'];\n }\n url += \"&advertiser=\";\n if (params['advertiser']) \n {\t\n url += params['advertiser'];\n }\n url += \"&adunit=\";\n if (params['adunit']) \n {\t\n url += params['adunit'];\n }\n url += \"&from=\";\n url += Math.floor(lookback);\n return url; \n}", "function setAJAX (url, data, type, fce, close_div, param1, data_type) {\n//\tstart_preloader();\n//\talert(\"run deleteajax\");\n//\talert(data);\n\t$.ajax({\n\t\ttype: type ? type : \"GET\",\n\t\turl: url,\n\t\tdata: data,\n\t\tdataType: data_type ? data_type : 'text', // 'json'\n\t\tcache: false,\n\t\tsuccess: function(response){\n\t\t\tif(fce) eval(fce + \"('\" + param1 + \"', '\" + response + \"')\");\n\t\t\tconsole.log(response);\n\t\t\t$(close_div).hide();\t\n//\t\t\tresult.empty().append(html);\n//\t\t\tstop_preloader();\n\t\t}\n\t});\n}", "function clearGlobalsVariables(){\n\tglobalFileName = null;\n\tglobalFileContent = null;\n\tglobalFileMimeType = null;\n\tglobalFilePath = null;\n\tglobalFileExtension = null;\n}", "function _process(ctype, cwho, cdata, url) {\n\n var data = '';\n var baseurl = window.location.protocol + \"//\" + (window.location.host + \"/\" + window.location.pathname).replace('//', '/') + '/';\n /* configured to allow for requests to different resources for load balance option * default * baseurl */\n console.log('using default baseurl :' + baseurl);\n \n switch (ctype) {\n\n case ('get'):\n getdata(baseurl + cpath, callrequest, 'url', cwho);\n break;\n \n case ('post'):\n switch (cwho) {\n \n case ('_invoice'): /* contact us widget */\n postform(url, callrequest, cdata, cwho);\n break;\n\n }\n break;\n }\n\n baseurl = null;\n callrequest(data);\n data = null;\n}", "function Noop(data) {\r\n\r\n}", "function get_data() {}", "function toDataStr(data){\n if((typeof(data)).toLowerCase() == \"string\" && data.length > 0){\n if(type.toUpperCase() == \"GET\") {\n url += data;\n return null;\n }\n else {\n return data;\n }\n }\n else if((typeof(data)).toLowerCase() == \"object\" && data.length > 0){\n let str = \"\";\n for (let i = 0; i <data.length; i++) {\n if(i = 0) {\n str += i + \"=\" + data[i];\n }\n else{\n str += \"&\" + i + \"=\" + data[i];\n }\n }\n return str\n }\n else{\n return null;\n }\n }", "function resetJsAttributeVars(){\n\t//Determinamos los valores para realizar la búsqueda\n\tjsCobUsuarEtapaCobraDetalUeccOidUsuaEtapCobr = '';\n\tjsCobUsuarEtapaCobraDetalEdtcOidEtapDeudTipoCarg = '';\n\tjsCobUsuarEtapaCobraDetalZsgvOidSubgVent = '';\n\tjsCobUsuarEtapaCobraDetalZorgOidRegi = '';\n\tjsCobUsuarEtapaCobraDetalZzonOidZona = '';\n\tjsCobUsuarEtapaCobraDetalZsccOidSecc = '';\n\tjsCobUsuarEtapaCobraDetalTerrOidTerr = '';\n\t\n}", "_setParamIfEmpty(param){\r\n\t\t\r\n\t\tif(param == null) param = {};\r\n\t\t\r\n\t\tif(param['ajax_url'] == null) param['ajax_url'] = 'dummy';\r\n\t\t\r\n\t\treturn param;\r\n\t}", "function resetJsAttributeVars(){\n\t//Determinamos los valores para realizar la búsqueda\n\tjsCccSubprCcprOidProc = '';\n\tjsCccSubprCodSubp = '';\n\t\n}", "function voidfunct(e){\r\n mp.trigger(\"CallActionCEFtoClient\", function_ret[e.currentTarget.dataset.descriptor], 1);\r\n \r\n //alert(\"choix : \"+function_ret[e.currentTarget.dataset.descriptor]);\r\n}", "function resetJsAttributeVars(){\n\t//Determinamos los valores para realizar la búsqueda\n\tjsBelParamBelceSbacOidSbac = '';\n\tjsBelParamBelceValDire = '';\n\tjsBelParamBelceValTfno = '';\n\tjsBelParamBelceValMontMaxiDife = '';\n\tjsBelParamBelceValLimiEfecCaja = '';\n\tjsBelParamBelceNumCaja = '';\n\tjsBelParamBelceValNombLoca = '';\n\tjsBelParamBelceValTiempRepo = '';\n\tjsBelParamBelceValFactLoca = '';\n\tjsBelParamBelceNumMaxiProd = '';\n\tjsBelParamBelceValAlerStoc = '';\n\tjsBelParamBelceValUsua = '';\n\tjsBelParamBelceClieOidClie = '';\n\tjsBelParamBelceSociOidSoci = '';\n\tjsBelParamBelceTtraOidTipoTran = '';\n\tjsBelParamBelceCcbaOidCuenCorrBanc = '';\n\tjsBelParamBelceTmvcOidCobr = '';\n\tjsBelParamBelceTmvcOidCier = '';\n\tjsBelParamBelceTmalOidConfStoc = '';\n\tjsBelParamBelceTmalOidConfStocTran = '';\n\tjsBelParamBelceTmalOidStocTran = '';\n\tjsBelParamBelceTmalOidStocDevo = '';\n\tjsBelParamBelceTmalOidRegu = '';\n\tjsBelParamBelceTmalOidReguSap = '';\n\tjsBelParamBelceTmalOidDevoStoc = '';\n\tjsBelParamBelceTmalOidPetiExis = '';\n\t\n}", "function source() {\n return {\n url: '',\n url2: '',\n urlBypass: false,\n articleBypass: false,\n callback: ''\n };\n}", "function senGuiData()\n{\n\tvar datasend={\n\t\tevent:\"guidata\"\n\t}\n\tqueryDataGet(\"php/api_process.php\",datasend,function(res){\n\t\t//nhan du lieu tu server tra ve\n\t\talert_info(res);\n\t});\n\tqueryDataPost(\"php/api_process_post.php\",datasend,function(res){\n\t\t//nhan du lieu tu server tra ve\n\t\talert_info(\"Post:\"+res);\n\t});\n}", "function initData() {\n let data = {};\n data[\"path\"] = [null];\n data[\"name\"] = [null];\n data[\"warning\"] = [null];\n return data;\n}", "function JsHttpRequest(){\nvar t=this;\nt.onreadystatechange=null;\nt.readyState=0;\nt.responseText=null;\nt.responseXML=null;\nt.status=200;\nt.statusText=\"OK\";\nt.responseJS=null;\nt.caching=false;\nt.loader=null;\nt.session_name=\"PHPSESSID\";\nt._ldObj=null;\nt._reqHeaders=[];\nt._openArgs=null;\nt._errors={inv_form_el:\"Invalid FORM element detected: name=%, tag=%\",must_be_single_el:\"If used, <form> must be a single HTML element in the list.\",js_invalid:\"JavaScript code generated by backend is invalid!\\n%\",url_too_long:\"Cannot use so long query with GET request (URL is larger than % bytes)\",unk_loader:\"Unknown loader: %\",no_loaders:\"No loaders registered at all, please check JsHttpRequest.LOADERS array\",no_loader_matched:\"Cannot find a loader which may process the request. Notices are:\\n%\"};\nt.abort=function(){\nwith(this){\nif(_ldObj&&_ldObj.abort){\n_ldObj.abort();\n}\n_cleanup();\nif(readyState==0){\nreturn;\n}\nif(readyState==1&&!_ldObj){\nreadyState=0;\nreturn;\n}\n_changeReadyState(4,true);\n}\n};\nt.open=function(_2,_3,_4,_5,_6){\nwith(this){\nif(_3.match(/^((\\w+)\\.)?(GET|POST)\\s+(.*)/i)){\nthis.loader=RegExp.$2?RegExp.$2:null;\n_2=RegExp.$3;\n_3=RegExp.$4;\n}\ntry{\nif(document.location.search.match(new RegExp(\"[&?]\"+session_name+\"=([^&?]*)\"))||document.cookie.match(new RegExp(\"(?:;|^)\\\\s*\"+session_name+\"=([^;]*)\"))){\n_3+=(_3.indexOf(\"?\")>=0?\"&\":\"?\")+session_name+\"=\"+this.escape(RegExp.$1);\n}\n}\ncatch(e){\n}\n_openArgs={method:(_2||\"\").toUpperCase(),url:_3,asyncFlag:_4,username:_5!=null?_5:\"\",password:_6!=null?_6:\"\"};\n_ldObj=null;\n_changeReadyState(1,true);\nreturn true;\n}\n};\nt.send=function(_7){\nif(!this.readyState){\nreturn;\n}\nthis._changeReadyState(1,true);\nthis._ldObj=null;\nvar _8=[];\nvar _9=[];\nif(!this._hash2query(_7,null,_8,_9)){\nreturn;\n}\nvar _a=null;\nif(this.caching&&!_9.length){\n_a=this._openArgs.username+\":\"+this._openArgs.password+\"@\"+this._openArgs.url+\"|\"+_8+\"#\"+this._openArgs.method;\nvar _b=JsHttpRequest.CACHE[_a];\nif(_b){\nthis._dataReady(_b[0],_b[1]);\nreturn false;\n}\n}\nvar _c=(this.loader||\"\").toLowerCase();\nif(_c&&!JsHttpRequest.LOADERS[_c]){\nreturn this._error(\"unk_loader\",_c);\n}\nvar _d=[];\nvar _e=JsHttpRequest.LOADERS;\nfor(var _f in _e){\nvar ldr=_e[_f].loader;\nif(!ldr){\ncontinue;\n}\nif(_c&&_f!=_c){\ncontinue;\n}\nvar _11=new ldr(this);\nJsHttpRequest.extend(_11,this._openArgs);\nJsHttpRequest.extend(_11,{queryText:_8.join(\"&\"),queryElem:_9,id:(new Date().getTime())+\"\"+JsHttpRequest.COUNT++,hash:_a,span:null});\nvar _12=_11.load();\nif(!_12){\nthis._ldObj=_11;\nJsHttpRequest.PENDING[_11.id]=this;\nreturn true;\n}\nif(!_c){\n_d[_d.length]=\"- \"+_f.toUpperCase()+\": \"+this._l(_12);\n}else{\nreturn this._error(_12);\n}\n}\nreturn _f?this._error(\"no_loader_matched\",_d.join(\"\\n\")):this._error(\"no_loaders\");\n};\nt.getAllResponseHeaders=function(){\nwith(this){\nreturn _ldObj&&_ldObj.getAllResponseHeaders?_ldObj.getAllResponseHeaders():[];\n}\n};\nt.getResponseHeader=function(_13){\nwith(this){\nreturn _ldObj&&_ldObj.getResponseHeader?_ldObj.getResponseHeader(_13):null;\n}\n};\nt.setRequestHeader=function(_14,_15){\nwith(this){\n_reqHeaders[_reqHeaders.length]=[_14,_15];\n}\n};\nt._dataReady=function(_16,js){\nwith(this){\nif(caching&&_ldObj){\nJsHttpRequest.CACHE[_ldObj.hash]=[_16,js];\n}\nresponseText=responseXML=_16;\nresponseJS=js;\nif(js!==null){\nstatus=200;\nstatusText=\"OK\";\n}else{\nstatus=500;\nstatusText=\"Internal Server Error\";\n}\n_changeReadyState(2);\n_changeReadyState(3);\n_changeReadyState(4);\n_cleanup();\n}\n};\nt._l=function(_18){\nvar i=0,p=0,msg=this._errors[_18[0]];\nwhile((p=msg.indexOf(\"%\",p))>=0){\nvar a=_18[++i]+\"\";\nmsg=msg.substring(0,p)+a+msg.substring(p+1,msg.length);\np+=1+a.length;\n}\nreturn msg;\n};\nt._error=function(msg){\nmsg=this._l(typeof (msg)==\"string\"?arguments:msg);\nmsg=\"JsHttpRequest: \"+msg;\nif(!window.Error){\nthrow msg;\n}else{\nif((new Error(1,\"test\")).description==\"test\"){\nthrow new Error(1,msg);\n}else{\nthrow new Error(msg);\n}\n}\n};\nt._hash2query=function(_1e,_1f,_20,_21){\nif(_1f==null){\n_1f=\"\";\n}\nif((\"\"+typeof (_1e)).toLowerCase()==\"object\"){\nvar _22=false;\nif(_1e&&_1e.parentNode&&_1e.parentNode.appendChild&&_1e.tagName&&_1e.tagName.toUpperCase()==\"FORM\"){\n_1e={form:_1e};\n}\nfor(var k in _1e){\nvar v=_1e[k];\nif(v instanceof Function){\ncontinue;\n}\nvar _25=_1f?_1f+\"[\"+this.escape(k)+\"]\":this.escape(k);\nvar _26=v&&v.parentNode&&v.parentNode.appendChild&&v.tagName;\nif(_26){\nvar tn=v.tagName.toUpperCase();\nif(tn==\"FORM\"){\n_22=true;\n}else{\nif(tn==\"INPUT\"||tn==\"TEXTAREA\"||tn==\"SELECT\"){\n}else{\nreturn this._error(\"inv_form_el\",(v.name||\"\"),v.tagName);\n}\n}\n_21[_21.length]={name:_25,e:v};\n}else{\nif(v instanceof Object){\nthis._hash2query(v,_25,_20,_21);\n}else{\nif(v===null){\ncontinue;\n}\nif(v===true){\nv=1;\n}\nif(v===false){\nv=\"\";\n}\n_20[_20.length]=_25+\"=\"+this.escape(\"\"+v);\n}\n}\nif(_22&&_21.length>1){\nreturn this._error(\"must_be_single_el\");\n}\n}\n}else{\n_20[_20.length]=_1e;\n}\nreturn true;\n};\nt._cleanup=function(){\nvar _28=this._ldObj;\nif(!_28){\nreturn;\n}\nJsHttpRequest.PENDING[_28.id]=false;\nvar _29=_28.span;\nif(!_29){\nreturn;\n}\n_28.span=null;\nvar _2a=function(){\n_29.parentNode.removeChild(_29);\n};\nJsHttpRequest.setTimeout(_2a,50);\n};\nt._changeReadyState=function(s,_2c){\nwith(this){\nif(_2c){\nstatus=statusText=responseJS=null;\nresponseText=\"\";\n}\nreadyState=s;\nif(onreadystatechange){\nonreadystatechange();\n}\n}\n};\nt.escape=function(s){\nreturn escape(s).replace(new RegExp(\"\\\\+\",\"g\"),\"%2B\");\n};\n}", "function JsHttpRequest(){\nvar t=this;\nt.onreadystatechange=null;\nt.readyState=0;\nt.responseText=null;\nt.responseXML=null;\nt.status=200;\nt.statusText=\"OK\";\nt.responseJS=null;\nt.caching=false;\nt.loader=null;\nt.session_name=\"PHPSESSID\";\nt._ldObj=null;\nt._reqHeaders=[];\nt._openArgs=null;\nt._errors={inv_form_el:\"Invalid FORM element detected: name=%, tag=%\",must_be_single_el:\"If used, <form> must be a single HTML element in the list.\",js_invalid:\"JavaScript code generated by backend is invalid!\\n%\",url_too_long:\"Cannot use so long query with GET request (URL is larger than % bytes)\",unk_loader:\"Unknown loader: %\",no_loaders:\"No loaders registered at all, please check JsHttpRequest.LOADERS array\",no_loader_matched:\"Cannot find a loader which may process the request. Notices are:\\n%\"};\nt.abort=function(){\nwith(this){\nif(_ldObj&&_ldObj.abort){\n_ldObj.abort();\n}\n_cleanup();\nif(readyState==0){\nreturn;\n}\nif(readyState==1&&!_ldObj){\nreadyState=0;\nreturn;\n}\n_changeReadyState(4,true);\n}\n};\nt.open=function(_2,_3,_4,_5,_6){\nwith(this){\nif(_3.match(/^((\\w+)\\.)?(GET|POST)\\s+(.*)/i)){\nthis.loader=RegExp.$2?RegExp.$2:null;\n_2=RegExp.$3;\n_3=RegExp.$4;\n}\ntry{\nif(document.location.search.match(new RegExp(\"[&?]\"+session_name+\"=([^&?]*)\"))||document.cookie.match(new RegExp(\"(?:;|^)\\\\s*\"+session_name+\"=([^;]*)\"))){\n_3+=(_3.indexOf(\"?\")>=0?\"&\":\"?\")+session_name+\"=\"+this.escape(RegExp.$1);\n}\n}\ncatch(e){\n}\n_openArgs={method:(_2||\"\").toUpperCase(),url:_3,asyncFlag:_4,username:_5!=null?_5:\"\",password:_6!=null?_6:\"\"};\n_ldObj=null;\n_changeReadyState(1,true);\nreturn true;\n}\n};\nt.send=function(_7){\nif(!this.readyState){\nreturn;\n}\nthis._changeReadyState(1,true);\nthis._ldObj=null;\nvar _8=[];\nvar _9=[];\nif(!this._hash2query(_7,null,_8,_9)){\nreturn;\n}\nvar _a=null;\nif(this.caching&&!_9.length){\n_a=this._openArgs.username+\":\"+this._openArgs.password+\"@\"+this._openArgs.url+\"|\"+_8+\"#\"+this._openArgs.method;\nvar _b=JsHttpRequest.CACHE[_a];\nif(_b){\nthis._dataReady(_b[0],_b[1]);\nreturn false;\n}\n}\nvar _c=(this.loader||\"\").toLowerCase();\nif(_c&&!JsHttpRequest.LOADERS[_c]){\nreturn this._error(\"unk_loader\",_c);\n}\nvar _d=[];\nvar _e=JsHttpRequest.LOADERS;\nfor(var _f in _e){\nvar ldr=_e[_f].loader;\nif(!ldr){\ncontinue;\n}\nif(_c&&_f!=_c){\ncontinue;\n}\nvar _11=new ldr(this);\nJsHttpRequest.extend(_11,this._openArgs);\nJsHttpRequest.extend(_11,{queryText:_8.join(\"&\"),queryElem:_9,id:(new Date().getTime())+\"\"+JsHttpRequest.COUNT++,hash:_a,span:null});\nvar _12=_11.load();\nif(!_12){\nthis._ldObj=_11;\nJsHttpRequest.PENDING[_11.id]=this;\nreturn true;\n}\nif(!_c){\n_d[_d.length]=\"- \"+_f.toUpperCase()+\": \"+this._l(_12);\n}else{\nreturn this._error(_12);\n}\n}\nreturn _f?this._error(\"no_loader_matched\",_d.join(\"\\n\")):this._error(\"no_loaders\");\n};\nt.getAllResponseHeaders=function(){\nwith(this){\nreturn _ldObj&&_ldObj.getAllResponseHeaders?_ldObj.getAllResponseHeaders():[];\n}\n};\nt.getResponseHeader=function(_13){\nwith(this){\nreturn _ldObj&&_ldObj.getResponseHeader?_ldObj.getResponseHeader(_13):null;\n}\n};\nt.setRequestHeader=function(_14,_15){\nwith(this){\n_reqHeaders[_reqHeaders.length]=[_14,_15];\n}\n};\nt._dataReady=function(_16,js){\nwith(this){\nif(caching&&_ldObj){\nJsHttpRequest.CACHE[_ldObj.hash]=[_16,js];\n}\nresponseText=responseXML=_16;\nresponseJS=js;\nif(js!==null){\nstatus=200;\nstatusText=\"OK\";\n}else{\nstatus=500;\nstatusText=\"Internal Server Error\";\n}\n_changeReadyState(2);\n_changeReadyState(3);\n_changeReadyState(4);\n_cleanup();\n}\n};\nt._l=function(_18){\nvar i=0,p=0,msg=this._errors[_18[0]];\nwhile((p=msg.indexOf(\"%\",p))>=0){\nvar a=_18[++i]+\"\";\nmsg=msg.substring(0,p)+a+msg.substring(p+1,msg.length);\np+=1+a.length;\n}\nreturn msg;\n};\nt._error=function(msg){\nmsg=this._l(typeof (msg)==\"string\"?arguments:msg);\nmsg=\"JsHttpRequest: \"+msg;\nif(!window.Error){\nthrow msg;\n}else{\nif((new Error(1,\"test\")).description==\"test\"){\nthrow new Error(1,msg);\n}else{\nthrow new Error(msg);\n}\n}\n};\nt._hash2query=function(_1e,_1f,_20,_21){\nif(_1f==null){\n_1f=\"\";\n}\nif((\"\"+typeof (_1e)).toLowerCase()==\"object\"){\nvar _22=false;\nif(_1e&&_1e.parentNode&&_1e.parentNode.appendChild&&_1e.tagName&&_1e.tagName.toUpperCase()==\"FORM\"){\n_1e={form:_1e};\n}\nfor(var k in _1e){\nvar v=_1e[k];\nif(v instanceof Function){\ncontinue;\n}\nvar _25=_1f?_1f+\"[\"+this.escape(k)+\"]\":this.escape(k);\nvar _26=v&&v.parentNode&&v.parentNode.appendChild&&v.tagName;\nif(_26){\nvar tn=v.tagName.toUpperCase();\nif(tn==\"FORM\"){\n_22=true;\n}else{\nif(tn==\"INPUT\"||tn==\"TEXTAREA\"||tn==\"SELECT\"){\n}else{\nreturn this._error(\"inv_form_el\",(v.name||\"\"),v.tagName);\n}\n}\n_21[_21.length]={name:_25,e:v};\n}else{\nif(v instanceof Object){\nthis._hash2query(v,_25,_20,_21);\n}else{\nif(v===null){\ncontinue;\n}\nif(v===true){\nv=1;\n}\nif(v===false){\nv=\"\";\n}\n_20[_20.length]=_25+\"=\"+this.escape(\"\"+v);\n}\n}\nif(_22&&_21.length>1){\nreturn this._error(\"must_be_single_el\");\n}\n}\n}else{\n_20[_20.length]=_1e;\n}\nreturn true;\n};\nt._cleanup=function(){\nvar _28=this._ldObj;\nif(!_28){\nreturn;\n}\nJsHttpRequest.PENDING[_28.id]=false;\nvar _29=_28.span;\nif(!_29){\nreturn;\n}\n_28.span=null;\nvar _2a=function(){\n_29.parentNode.removeChild(_29);\n};\nJsHttpRequest.setTimeout(_2a,50);\n};\nt._changeReadyState=function(s,_2c){\nwith(this){\nif(_2c){\nstatus=statusText=responseJS=null;\nresponseText=\"\";\n}\nreadyState=s;\nif(onreadystatechange){\nonreadystatechange();\n}\n}\n};\nt.escape=function(s){\nreturn escape(s).replace(new RegExp(\"\\\\+\",\"g\"),\"%2B\");\n};\n}", "function initData() {\n\t\t\tvar url = $trigger.attr(\"href\");\n\n\t\t\tleavingIbmUrl = url;\n\n\t\t\trawUrl = extractUrl(url);\n\t\t}", "function gotRawData(thedata) {\n\n // println(\"gotRawData\" + thedata);\n}", "function parseArguments(url,data,success,dataType){if($.isFunction(data))dataType=success,success=data,data=undefined;if(!$.isFunction(success))dataType=success,success=undefined;return{url:url,data:data,success:success,dataType:dataType};}", "function clezr() {\n\t\t_json = {};\n\t}", "function RequestLoadGeneralData() {\n\n}", "function preapareDataAttibutes (data) {\n if(typeof data === 'undefined'){\n return false;\n }\n if (data.ajaxOptions) {\n delete data.ajaxOptions;\n }\n if (data.previewImageUrls) {\n delete data.previewImageUrls;\n }\n if (data.translations) {\n delete data.translations;\n }\n }", "function FAADataHelper() {\n}", "function httpCallbackMetadata(data){\n if(data.error){\n handleErrorMessage(data);\n return;\n }\n\n \n \n if(options.dialog){\n var b= [downloadbutton,addtobasketbutton,reloadbutton]\n options.element.dialog(\"option\",\"buttons\",b);\n }else{\n rootElement.find(\".c4i-fileviewer-downloadbutton\").button(downloadbutton).click(downloadbutton.click);\n rootElement.find(\".c4i-fileviewer-addtobasketbutton\").button(addtobasketbutton).click(addtobasketbutton.click);\n rootElement.find(\".c4i-fileviewer-reloadbutton\").button(reloadbutton).click(reloadbutton.click); \n }\n /* var html=\"<table class=\\\"c4i-fileviewer-table\\\">\";\n\n for(var j=0;j<data[0].attributes.length;j++){\n\n html+=\"<tr><td class=\\\"c4i-fileviewer-table-td-name\\\">\"+data[0].attributes[j].name+\"</td><td class=\\\"c4i-fileviewer-table-td-value\\\">\"+ data[0].attributes[j].value+\"</td></tr>\";\n \n }\n \n html+=\"</table>\";*/\n \n var html=options.prettyquery;\n rootElement.find(\".c4i-fileviewer-globalmetadata\").find(\".simplecomponent-body\").html(html);\n \n \n \n if(viewerType.transfermethod.http){\n console.log(data);\n if(viewerType.filetype.txt){\n function MyHTMLEncode(str){\n var i = str.length,\n aRet = [];\n\n while (i--) {\n var iC = str[i].charCodeAt();\n if (iC < 65 || iC > 127 || (iC>90 && iC<97)) {\n if(iC == 10)aRet[i] = '<br/>';else aRet[i] = '&#'+iC+';';\n } else {\n aRet[i] = str[i];\n }\n }\n return aRet.join('');\n };\n rootElement.find(\".c4i-fileviewer-variables\").find(\".simplecomponent-body\").html(MyHTMLEncode(data.data));\n }\n if(viewerType.filetype.csv){\n var html=\"\";\n html+=\"<table class=\\\"drupal\\\"><tr>\";\n var keys = fileViewerGetKeys(data[0]);\n for(var j=0;j<keys.length;j++){\n html+=\"<th>\"+keys[j]+\"</th>\";\n }\n html+=\"</tr>\";\n for(var j=0;j<data.length;j++){\n html+=\"<tr>\";\n for(var k=0;k<keys.length;k++){\n html+=\"<td>\"+data[j][keys[k]]+\"</td>\";\n }\n html+=\"</tr>\";\n }\n html+=\"</table>\";\n rootElement.find(\".c4i-fileviewer-variables\").find(\".simplecomponent-body\").html(html);\n }\n \n return;\n }\n \n var provenanceVar = undefined;\n for(var v=0;v<data.length;v++){\n var preview=checkForViewableVariable(data[v]);\n if(preview==\"\"){\n preview=checkForProvenanceVariable(data[v]);\n if(preview!=\"\"){\n provenanceVar = data[v];\n }\n }\n\n html+=\"<span class=\\\"c4i-fileviewer-resultitem\\\">\"; \n html+=\" <span class=\\\"c4i-fileviewer-dataset-baseimage c4i-fileviewer-dataset-collapsible c4i-fileviewer-dataset-imgcollapsed \\\" name=\\\"\"+data[v].variable+\"\\\"></span>\";\n \n \n html+=' <span class=\"c4i-fileviewer-resultitem-content \">';\n html+=' <span class=\"c4i-fileviewer-resultitem-content-varinfo \">';\n if(data[v].variabletype){\n html+=\"<span class=\\\"c4i-fileviewer-variabletype\\\">\"+data[v].variabletype+ \"</span>\"; \n }else{\n html+=\"<span class=\\\"c4i-fileviewer-variabletype\\\">-</span>\"; \n }\n html+= \"<span class=\\\"c4i-fileviewer-variablename\\\">\"+data[v].variable;\n if(data[v].dimensions&&(!data[v].isDimension)){\n var dimstring = \" (\";\n for(var d=0;d<data[v].dimensions.length;d++){\n //if(d>0)dimstring+=\", \";\n dimstring+=(data[v].dimensions[d].name);\n }\n dimstring += \")\";\n \n html+= dimstring;\n }\n html+='</span>'\n html+=' - <b>'+data[v].longname+'</b>';\n \n if(data[v].isDimension){\n html+= \"<span class=\\\"c4i-fileviewer-vardimension\\\">dimension \"+data[v].variable+\" of length \"+data[v].isDimension[0].length+\"</span>\";\n }\n html+='</span>'\n if(preview.length>0)\n {\n html+= \"<span class=\\\"c4i-fileviewer-adagucviewershow\\\"></span>\";\n }\n \n \n html+='</span>';\n html+=\" <span class=\\\"c4i-fileviewer-dataset-expandedarea\\\">\";\n html+=' <div class=\"c4i-fileviewer-body\">';\n html+=preview;\n if(preview.length>0){\n data[v].preview=preview;\n }\n \n \n html+=\" <table class=\\\"c4i-fileviewer-table\\\">\";\n for(var j=0;j<data[v].attributes.length;j++){\n var value = data[v].attributes[j].value;\n if(data[v].attributes[j].name == \"bundle\" || data[v].attributes[j].name == \"lineage\"){\n value = vkbeautify.json(data[v].attributes[j].value,2);\n }\n value = escapeHtml(value);\n html+=\" <tr><td class=\\\"c4i-fileviewer-table-td-name\\\">\"+data[v].attributes[j].name+\"</td><td class=\\\"c4i-fileviewer-table-td-value\\\">\"+ value+\"</td></tr>\";\n }\n html+=\" </table>\";\n html+=' </div>';\n html+=' <div class=\"simplecomponent-footer\"></div>';\n html+=' </span>';\n html+='</span>';\n \n \n }\n rootElement.find(\".c4i-fileviewer-variables\").find(\".simplecomponent-body\").html(html);\n rootElement.find(\".c4i-fileviewer-variables\").find(\".simplecomponent-body\").find(\".c4i-fileviewer-dataset-expandedarea\").hide();\n for(var v=0;v<data.length;v++){\n if(data[v].preview){\n var el=rootElement.find(\"span[name=\\\"\"+data[v].variable+\"\\\"]\").first();\n $(el).removeClass(\"c4i-fileviewer-dataset-imgcollapsed\");\n $(el).addClass(\"c4i-fileviewer-dataset-imgexpand\");\n $(el).parent().find(\".c4i-fileviewer-dataset-expandedarea\").show();\n var serviceOptions = el.parent().find(\".c4i-fileviewer-adagucviewershow\");\n var variable = data[v].variable;\n var adagucViewerAddLayer = $('<span name=\"'+variable+'\" />').addClass('c4i-fileviewer-adagucview').html('Add to viewer');serviceOptions.append(adagucViewerAddLayer);\n var WMS = $('<span />').addClass('c4i-fileviewer-wms').html(\n '<a target=\"_blank\" href=\"'+options.adagucservice+ 'source='+URLEncode(options.prettyquery)+'&service=WMS&request=GetCapabilities\">WMS</a>');\n \n serviceOptions.append(WMS);\n var WCS = $('<span />').addClass('c4i-fileviewer-wcs').html(\n '<a target=\"_blank\" href=\"'+options.adagucservice+ 'source='+URLEncode(options.prettyquery)+'&service=WCS&request=GetCapabilities\">WCS</a>');\n serviceOptions.append(WCS);\n \n var opendap = $('<span />').addClass('c4i-fileviewer-opendap').html(\n '<a target=\"_blank\" href=\"'+options.prettyquery+'.das\">OpenDAP</a>');\n serviceOptions.append(opendap);\n \n \n \n adagucViewerAddLayer.attr('onclick','').click(function(event){\n event.preventDefault();\n var variable = $(this).attr('name');\n _this.visualizeVariable(variable,options.prettyquery);\n return false;\n });\n \n WMS.attr('onclick','').click(function(event){\n event.stopPropagation();\n });\n \n WCS.attr('onclick','').click(function(event){\n event.stopPropagation();\n });\n \n opendap.attr('onclick','').click(function(event){\n event.stopPropagation();\n });\n \n var previewImage = el.parent().find(\".c4i-fileviewer-previewstyle\");\n previewImage.attr('onclick','').click(function(event){\n event.preventDefault(); \n var variable = $(this).attr('name');\n _this.visualizeVariable(variable,options.prettyquery);\n return false;\n });\n }\n }\n \n \n var expandcollapse = function(t){\n var el=$(this).parent().find('.c4i-fileviewer-dataset-collapsible');\n if($(el).hasClass(\"c4i-fileviewer-dataset-imgcollapsed\")){\n $(el).removeClass(\"c4i-fileviewer-dataset-imgcollapsed\");\n $(el).addClass(\"c4i-fileviewer-dataset-imgexpand\");\n $(el).parent().find(\".c4i-fileviewer-dataset-expandedarea\").show();\n }else{\n $(el).removeClass(\"c4i-fileviewer-dataset-imgexpand\");\n $(el).addClass(\"c4i-fileviewer-dataset-imgcollapsed\");\n $(el).parent().find(\".c4i-fileviewer-dataset-expandedarea\").hide();\n\n }\n };\n \n rootElement.find(\".c4i-fileviewer-resultitem-content\").attr('onclick','').click(expandcollapse);\n rootElement.find(\".c4i-fileviewer-dataset-collapsible\").attr('onclick','').click(expandcollapse);\n \n if(provenanceVar){\n doForProvenanceVariable(provenanceVar);\n }\n }", "function sendparams1(params1) {\r\nvar url = \"YOUR GOOGLE SCRIPT-PROJECT LINK\";\r\nvar f = params1;\r\nvar xhr = new XMLHttpRequest();\r\nxhr.open(\"POST\", url);\r\n//xhr.setRequestHeader(\"Content-Type\", \"application/json\");\r\nxhr.onreadystatechange = function () {\r\nif (xhr.readyState === 4) {\r\n}};\r\nvar data = `{\"first\": \"${f}\",\"second\": \"NULL\"}`;\r\nxhr.send(data);\r\n}", "function myData() {\n retrun;\n}", "function flushParams() {\n\n s.events = \"\";\n s.campaign = \"\";\n s.linkTrackVars = \"\";\n s.linkTrackEvents = \"\";\n s.Media.trackVars = \"\";\n s.Media.trackEvents = \"\";\n\n s.eVar1 = \"\";\n s.eVar2 = \"\";\n s.eVar3 = \"\";\n s.eVar4 = \"\";\n s.eVar5 = \"\";\n s.eVar6 = \"\";\n s.eVar7 = \"\";\n s.eVar8 = \"\";\n s.eVar9 = \"\";\n s.eVar10 = \"\";\n s.eVar11 = \"\";\n s.eVar12 = \"\";\n s.eVar13 = \"\";\n s.eVar14 = \"\";\n s.eVar15 = \"\";\n s.eVar16 = \"\";\n s.eVar17 = \"\";\n s.eVar18 = \"\";\n s.eVar19 = \"\";\n s.eVar20 = \"\";\n s.eVar21 = \"\";\n s.eVar22 = \"\";\n s.eVar23 = \"\";\n\n s.hier1 = \"\";\n s.hier3 = \"\";\n\n s.prop1 = \"\";\n s.prop2 = \"\";\n s.prop3 = \"\";\n s.prop4 = \"\";\n s.prop5 = \"\";\n s.prop6 = \"\";\n s.prop7 = \"\";\n s.prop8 = \"\";\n s.prop9 = \"\";\n s.prop10 = \"\";\n s.prop11 = \"\";\n s.prop12 = \"\";\n s.prop13 = \"\";\n s.prop14 = \"\";\n s.prop15 = \"\";\n s.prop16 = \"\";\n s.prop17 = \"\";\n s.prop18 = \"\";\n s.prop19 = \"\";\n s.prop20 = \"\";\n }", "function u(a,b,c){this.code=ua+a;this.message=b||va[a]||\"\";this.a=c||null}", "function http() {\n\tthis.hint = 'url,queryType,dataType,async,data,timeout\\n\\nПри передаче данных в виде аргументов следует соблюдать их порядок, как в примере выше\\n\\nИмя свойств в передаваемом объекте должны быть одноименны с названиями аргументов в примере выше';\n\tthis.control = false;\n\tthis.lastQuery = false;\n\tthis.config = new Object();\n\tthis.defined = {\n\t\turl : '',\n\t\tqueryType : 'POST',\n\t\tdataType : 'json',\n\t\tasync : true,\n\t\tdata : false,\n\t\ttimeout : 500\n\t}\n\tthis.log = new Array();\n\tthis.log.console = true;\n\tthis.log.show = function(){\n\t\tfor (var i=0; i<this.length; i++) {\n\t\t\tconsole.log(this[i]);\n\t\t}\n\t}\n\tthis.log.clean = function(){\n\t\tthis.splice( 0,this.length );\n\t}\n\tthis.fromObject = function(arg) {\n\t\tif( arg != null && typeof(arg) == 'object' && arg.url != undefined ) {\n\t\t\tthis.control = true;\n\t\t\tthis.config.url = arg.url;\n\t\t\targ.queryType ? this.config.queryType = arg.queryType : this.config.queryType = this.defined.queryType;\n\t\t\targ.dataType ? this.config.dataType = arg.dataType : this.config.dataType = this.defined.dataType;\n\t\t\targ.async ? this.config.async = arg.async : this.config.async = this.defined.async;\n\t\t\targ.data ? this.config.data = arg.data : this.config.data = this.defined.data;\n\t\t\targ.timeout ? this.config.timeout = arg.timeout : this.config.timeout = this.defined.timeout;\n\t\t} else {\n\t\t\tif( typeof(arg) == 'string' ) { this.fromArguments(new Array(arg)) }\n\t\t}\n\t}\n\tthis.fromArguments = function(args) {\n\t\tif ( !args[0] ) { console.error('No URL'); return false }\n\t\t\telse { this.config.url = args[0]; this.control = true; }\n\t\tif ( args[1] === undefined ) this.config.queryType = this.defined.queryType;\n\t\t\telse this.config.queryType = args[1];\n\t\tif ( args[2] === undefined ) this.config.dataType = this.defined.dataType;\n\t\t\telse this.config.dataType = args[2];\n\t\tif ( args[3] === undefined ) this.config.async = this.defined.async;\n\t\t\telse this.config.async = args[3];\n\t\tif ( args[4] === undefined ) this.config.data = this.defined.data;\n\t\t\telse this.config.data = args[4];\n\t\tif ( args[5] === undefined ) this.config.timeout = this.defined.timeout;\n\t\t\telse this.config.timeout = args[5];\n\t}\n\tthis.router = function(ARGS){\n\t\tswitch( ARGS.length ) {\n\t\t\tcase 0 : this.lastQuery ? this.control = true : 0; break;\n\t\t\tcase 1 : this.fromObject(ARGS[0]); break;\n\t\t\tdefault : this.fromArguments(ARGS);\n\t\t}\n\t}\n\tthis.request = function() {\n\t\tthis.router(arguments);\n\t\tif( this.control ) {\n\t\t\treturn new Promise( function(resolve,reject) {\n\t\t\t\t$.ajax({\n\t\t\t\t\ttimeout : document.http.config.url,\n\t\t\t\t\turl : document.http.config.url,\n\t\t\t\t\ttype : document.http.config.queryType,\n\t\t\t\t\tdataType : document.http.config.dataType,\n\t\t\t\t\tasync : document.http.config.async,\n\t\t\t\t\tdata : document.http.config.data,\n\t\t\t\t\tsuccess : function( data, control ) { document.http.lastQuery = true; resolve(data) },\n\t\t\t\t\terror : function (xhr, errorType, exception) { var errorMessage = exception || xhr.controlText; reject(errorMessage); },\n\t\t\t\t\tcomplete : function() {\n\t\t\t\t\t\tdocument.http.control = false;\n\t\t\t\t\t\tvar msg = 'Request to ' + document.http.config.url+ ' completed'\n\t\t\t\t\t\tif ( document.http.log.console ) console.log(msg);\n\t\t\t\t\t\tdocument.http.log.push(msg);\n\t\t\t\t\t}\n\t\t\t\t})\n\t\t\t} )\n\t\t} else {\n\t\t\tconsole.error('Cannot to request'); return false;\n\t\t}\n\t}\n}", "function zXmlHttp() {\n}", "function fullInit(options)\n\t{\n\t\t_data = options.data;\n\t}", "function fullInit(options)\n\t{\n\t\t_data = options.data;\n\t}", "function prepData(data) {\n\t if(typeof(data) == \"undefined\") {\n\t return {_ts : new Date().getTime()};\n\t }\n\t else if(typeof(data) == \"string\") {\n\t return data + \"&_ts=\" + new Date().getTime();\n\t }\n\t else if(typeof(data) == \"object\") {\n\t data._ts = new Date().getTime();\n\t return data;\n\t }\n\t return data;\n\t}", "function getData(type){\n url=\"./scripts/store_data.php\";\n callback = \"getdata\";\n parameters = \"filename=\"+document.getElementById(\"filename\").value;\n parameters += \"&access_token=\"+document.getElementById(\"token\").value;\n \n if(type==\"post\"){\n // Get all the parameters\n parameters += \"&type=post&url=\"+document.getElementById(\"post_url\").value;\n parameters += \"&parameters=\"+document.getElementById(\"post_parameters\").value;\n } else if(type==\"get\"){\n // Get all the parameters\n parameters += \"&type=get&url=\"+document.getElementById(\"get_url\").value;\n } else {\n alert(\"Error\");\n }\n \n // Send the request to the server script\n connectPOST(url,parameters,callback);\n \n return false;\n}", "function __cfclient_empty_func()\n{\n\t\n}", "function QU(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n={mimeType:t.mimeType||null,onBeforeSend:t.onBeforeSend||Function.prototype,onSuccess:t.onSuccess||Function.prototype,onError:t.onError||Function.prototype,onComplete:t.onComplete||Function.prototype},r=Array.isArray(e)?e:[e],o=Array.apply(null,Array(r.length)).map((function(e){return null}));function i(e){var t=e&&\"<\"===e.trim().charAt(0);return e&&!t}function a(e,t){n.onError(e,r[t],t)}function l(e,t){var i=n.onSuccess(e,r[t],t);e=!1===i?\"\":i||e,o[t]=e,-1===o.indexOf(null)&&n.onComplete(o)}var s=document.createElement(\"a\");r.forEach((function(e,t){if(s.setAttribute(\"href\",e),s.href=String(s.href),Boolean(document.all&&!window.atob)&&s.host.split(\":\")[0]!==location.host.split(\":\")[0]){if(s.protocol===location.protocol){var r=new XDomainRequest;r.open(\"GET\",e),r.timeout=0,r.onprogress=Function.prototype,r.ontimeout=Function.prototype,r.onload=function(){i(r.responseText)?l(r.responseText,t):a(r,t)},r.onerror=function(e){a(r,t)},setTimeout((function(){r.send()}),0)}else console.warn(\"Internet Explorer 9 Cross-Origin (CORS) requests must use the same protocol (\".concat(e,\")\")),a(null,t)}else{var o=new XMLHttpRequest;o.open(\"GET\",e),n.mimeType&&o.overrideMimeType&&o.overrideMimeType(n.mimeType),n.onBeforeSend(o,e,t),o.onreadystatechange=function(){4===o.readyState&&(200===o.status&&i(o.responseText)||0===o.status&&i(o.responseText)?l(o.responseText,t):a(o,t))},o.send()}}))}", "function get_info_canbo(filephp,frm)\r\n{\r\n\tif(frm.cbo_macanbosua.value=='Chọn mã số cán bộ')\r\n\t{\r\n\t\tfrm.cbo_tendonvisua.value=-1;\r\n\t\tfrm.txt_tencanbosua.value='';\r\n\t\tfrm.cbo_gioitinhsua.value=-1;\r\n\t\tfrm.cbo_ngaysinhsua.value=-1;\r\n\t\tfrm.cbo_thangsinhsua.value=-1;\r\n\t\tfrm.cbo_namsinhsua.value=-1;\r\n\t\tfrm.txt_emailsua.value='';\r\n\t\tfrm.txt_diachisua.value='';\r\n\t\tfrm.txt_sodienthoaisua.value='';\r\n\t\tfrm.txt_matkhausua.value='';\r\n\t}\r\n\telse\r\n\t{\r\n\tmacanbo=frm.cbo_macanbosua.value;\r\n\tmadonvi=frm.cbo_tendonvisua;\r\n\ttencanbo=frm.txt_tencanbosua;\r\n\tgioitinh=frm.cbo_gioitinhsua;\r\n\tngaysinh=frm.cbo_ngaysinhsua;\r\n\tthangsinh=frm.cbo_thangsinhsua;\r\n\tnamsinh=frm.cbo_namsinhsua;\r\n\temail=frm.txt_emailsua;\r\n\tdiachi=frm.txt_diachisua;\r\n\tsodienthoai=frm.txt_sodienthoaisua;\r\n\tmatkhau=frm.txt_matkhausua;\r\n\t\r\n\thttp=GetXmlHttpObject();\r\n\tvar params = \"macanbo=\"+macanbo;\r\n\t//mo ket noi bang phuong thuc post\r\n\thttp.open(\"POST\", filephp, false);\r\n\t//gui thong tin header cua phuong thuc post , cac thong so nay la bat buoc\r\n\thttp.setRequestHeader(\"Content-type\", \"application/x-www-form-urlencoded\");\r\n\t//http.setRequestHeader(\"Content-length\", params.length);\r\n\t//http.setRequestHeader(\"Connection\", \"close\");\r\n\t//ham xu li du lieu tra ve cua ajax send thanh cong\r\n\thttp.onreadystatechange = function() {\r\n\t\tif(http.readyState == 4 && http.status == 200) \r\n\t\t{\t\t\t\t\r\n\t\t\t\tvar x=http.responseXML.getElementsByTagName('row');\t\t\t\t\t\t\t\t\r\n\t\t\t\tmadonvi.value=x[0].getElementsByTagName('column')[0].firstChild.nodeValue;\r\n\t\t\t\ttencanbo.value=x[0].getElementsByTagName('column')[1].firstChild.nodeValue;\r\n\t\t\t\tgioitinh.value=x[0].getElementsByTagName('column')[2].firstChild.nodeValue;\r\n\t\t\t\tngaysinh.value=x[0].getElementsByTagName('column')[3].firstChild.nodeValue;\r\n\t\t\t\tthangsinh.value=x[0].getElementsByTagName('column')[4].firstChild.nodeValue;\r\n\t\t\t\tnamsinh.value=x[0].getElementsByTagName('column')[5].firstChild.nodeValue;\r\n\t\t\t\temail.value=x[0].getElementsByTagName('column')[6].firstChild.nodeValue;\r\n\t\t\t\tdiachi.value=x[0].getElementsByTagName('column')[7].firstChild.nodeValue;\r\n\t\t\t\tsodienthoai.value=x[0].getElementsByTagName('column')[8].firstChild.nodeValue;\r\n\t\t\t\tmatkhau.value=x[0].getElementsByTagName('column')[9].firstChild.nodeValue;\r\n\t\t}\r\n\t}\r\n\thttp.send(params);\r\n\t}\r\n}", "function cbaRequest()\r\n{\r\n \r\n /**\r\n * Initializing the C.B.A. Class\r\n *\r\n * @author crossbrowserajax.com\r\n * @member cbaRequest\r\n */\r\n this._init = function()\r\n {\r\n /** handler error status */\r\n this._handler_error = true;\r\n /* enable handler error */\r\n if ( this._handler_error )\r\n {\r\n window.onerror = this.cbaJsError;\r\n }\r\n \r\n /** parent element id-name */\r\n this._parent_id_name = '_cba_parent_id';\r\n \r\n /** name id in url-request */\r\n this._url_id = '_cba_request_id';\r\n \r\n /** prefix for created request */\r\n this._id_prefix = '_cba_pack_';\r\n \r\n /** interface for dom */\r\n this.dom = new cbaDOM();\r\n \r\n /** parent element */\r\n this._parent_element = this.createParentElement();\r\n \r\n /** cache of requests */\r\n this._requests = new Array();\r\n \r\n /* cache */\r\n /** caching enabled */\r\n this._caching_enabled = true;\r\n \r\n if ( this._caching_enabled )\r\n {\r\n \r\n /** buffer_size */\r\n this._buffer_size = 25;\r\n \r\n /** length string for analysis (for control total) */\r\n this._length_ct = 100;\r\n \r\n /** cache */\r\n this.cache = new cbaCache( this._buffer_size, this._length_ct );\r\n \r\n }\r\n }\r\n \r\n /**\r\n * Handler Errors\r\n * @author crossbrowserajax.com\r\n * @param _message error description\r\n * @param _url url\r\n * @param _line error line\r\n * @member cbaRequest\r\n */\r\n this.cbaJsError = function(_message, _url, _line)\r\n {\r\n var _file = \"File: \" + _url + \" :: \" + _line + \"\\n\";\r\n var _title = \"There was an error on this page.\\n--------------------------\\n\";\r\n var _error = _title;\r\n _error += \"Error: \" + _message + \"\\n\";\r\n _error += _file;\r\n if ( _message.indexOf('unterminated string literal') + _message.indexOf('missing ;') + _message.indexOf('Syntax error') > -3){\r\n _error += '--------------------------\\nRecommendation:\\n Check response from the server.\\n He may return incorrect JavaScrip.';\r\n }\r\n //alert(_error);\r\n }\r\n \r\n /**\r\n * Making the Container for <SCRIPT>\r\n *\r\n * @author crossbrowserajax.com\r\n * @return element\r\n * @member cbaRequest\r\n */\r\n this.createParentElement = function()\r\n {\r\n // create element unless exists\r\n if ( document.getElementById( this._parent_id_name ) )\r\n {\r\n return document.getElementById( this._parent_id_name );\r\n }\r\n else\r\n {\r\n return this.dom.createElement( document.body, 'div', {'id' : this._parent_id_name}, '' );\r\n }\r\n }\r\n \r\n /**\r\n * Remote Query\r\n *\r\n * @author crossbrowserajax.com\r\n * @param _url url-address for backend\r\n * @param _callback callback-function\r\n * @param _use_cache use the cache (unnecessary argument)\r\n * @member cbaRequest\r\n */\r\n this.query = function( _url , _callback )\r\n {\r\n // set _use_cache\r\n if ( arguments.length > 2 ) \r\n {\r\n var _use_cache = arguments[2];\r\n }\r\n else\r\n { \r\n var _use_cache = true;\r\n }\r\n \r\n // search in cache();\r\n if ( _use_cache && ( this.cache && this.cache._search( _url ) ) )\r\n {\r\n // rec result in 'this.answer'\r\n this.answer = this.cache._search_buffer;\r\n // run user function\r\n if (_callback instanceof Function) _callback();\r\n } \r\n else\r\n {\r\n // create id\r\n var _id = this._requests.push( {'callback' : _callback, 'request' : _url } ) - 1;\r\n /** shaping url */\r\n if ( _url.indexOf('?') == -1 )\r\n {\r\n _url += '?';\r\n }\r\n else\r\n {\r\n _url += '&';\r\n }\r\n _url += this._url_id + '=' + _id;\r\n // create <SCRIPT>\r\n this.dom.createScript( this._parent_element, this._id_prefix + _id, _url );\r\n } \r\n }\r\n\r\n /**\r\n * Processing Results\r\n *\r\n * @author crossbrowserajax.com\r\n * @param _id id of request\r\n * @param _result response\r\n * @member cbaRequest\r\n */\r\n this.ready = function( _id, _result )\r\n {\r\n // rec result in 'this.answer'\r\n // alert('_result===='+_result);\r\n this.answer = _result;\r\n // save in cache\r\n if ( this.cache ) this.cache._add( this._requests[_id].request, _result );\r\n // run user function\r\n if (this._requests[_id].callback instanceof Function) this._requests[_id].callback();\r\n // remove <SCRIPT>\r\n if (document.getElementById( this._id_prefix + _id ))\r\n {\r\n this.dom.removeElement( document.getElementById( this._id_prefix + _id ) );\r\n }\r\n // clear id\r\n delete( this._requests[_id] );\r\n }\r\n \r\n /** Init Class */\r\n this._init( arguments );\r\n \r\n}", "function FormataData(evt) {\n vr = (navigator.appName == 'Netscape') ?evt.target.value:evt.srcElement.value;\n if(vr.length == 2)vr = vr+\"/\";\n if(vr.length == 5)vr = vr+\"/\";\n return vr;\n}", "function l(){t={},u=\"\",w=\"\"}", "function getdata3(surl, inputHidden, content,selectedValue){\n\tvar cbo = null;\n\tvar json = new Request.JSON({\n\t\tmethod : 'post',\n\t\turl : surl,\n\t\t async: false,\n\t\t noCache : true,\n\t\t//data : param,\n\t\tonComplete : function(data) {\n\t\t\tcbo = dropdownB2(data,inputHidden,content,selectedValue);\n\t\t}\n\t});\n\tjson.send();\n\treturn cbo;\n}", "function resetData() {\n mapquestURL = '';\n lat = '';\n lng = '';\n $('#city').empty();\n $('#currentTemp').empty();\n $('#currentHumidity').empty();\n $('#currentWindSpeed').empty();\n uvi.empty();\n uvi.css('background-color', 'transparent');\n uvi.css('color', 'black');\n \n} //end resetData", "function UploaD_datatoserverpre(data){\n\t/*data\n\t * \n\t */\n\t var ideaid=$('#HiddeN_ideaid').val(); \n\t var ideaid=parseInt(ideaid); \t \n\t var data=data;\n\t //ajax\n\t\t/*AJAX*/\n\t\t /*Start:create a AJAX object*/\n\t \n\t var tip=\"<span style='color:rgb(255,125,0);'>\"+\"dealing...\"+\"</span>\";\n\t $('#LoadiN_tipstr').html(tip);\t \t \n\t\t $('#LoadiN_tip').css({display:'block'});\t\t \n\t\t\tvar xmlhttp;\n\t\t\tif (window.XMLHttpRequest){// code for IE7+, Firefox, Chrome, Opera, Safari\n\t\t\t xmlhttp=new XMLHttpRequest();\n\t\t\t}\n\t\t\telse{// code for IE6, IE5\n\t\t\t xmlhttp=new ActiveXObject(\"Microsoft.XMLHTTP\");\n\t\t\t}\n\t\t /*Url the data:*/\n\t\t\t xmlhttp.open(\"POST\",ROOTDIR+'php/public/idea/prepr/image.php?action=idea_preimage&id='+ideaid);\n//\t\t\t xmlhttp.setRequestHeader(\"Content-type\",\"application/x-www-form-urlencoded\");\n\t\t\t xmlhttp.send(data);\n\t\t /*Acee the data:*/\n\t\t\t /*return the data*/\n\t\t\t xmlhttp.addEventListener('load',ResulT_uploaddatatoserverloadpre,false);\n\t\t /*End:create a AJAX object*/ \t\t\t \t\t \t \t \t \t\n\t\t/*AJAX*/\t\t\t\t\t \t\t\t\t \n}", "function urlReader() {\n ajxStore.urlBuild.imgLink = $(\"#url-value\").val();\n myDataRef.push({url: ajxStore.urlBuild.imgLink});\n showImg(ajxStore.urlBuild.imgLink);\n ajxStore.urlBuild.encodedURL = encodeURIComponent(ajxStore.urlBuild.imgLink); \n alchemyAjax();\n projectOxfordAjax();\n skyAjax();\n }", "function get_user_data() {\n ajax_req(\n php_redir,\n \"\", \n get_succ, \n get_err\n );\n}", "_getDataString(data){return JSON.stringify(data).replace(/\"/g,\"&quot;\").replace(/'/g,\"&apos;\")}", "_sendData() {\n\n }", "function _swdoc_lcf_onSendSessionData()\r\n{\r\n\tvar con = {};\r\n\tcon.SendValue = function(strParamName,strValue)\r\n\t{\r\n\t\tvar strParamName = strParamName.toLowerCase();\r\n\t\tif(strParamName.indexOf(\".\")>-1)\r\n\t\t{\r\n\t\t\tvar arrParam = strParamName.split(\".\");\r\n\t\t\tif(dd.tables[arrParam[0]]!=undefined && dd.tables[arrParam[0]].columns[arrParam[1]]!=undefined)\r\n\t\t\t{\r\n\t\t\t\tdocument[arrParam[0]][arrParam[1]] = strValue;\r\n\t\t\t}\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\tdocument.opencall[strParamName] = strValue;\r\n\t\t}\r\n\t}\r\n\tcon.SendNumber = function(strField,varValue)\r\n\t{\r\n\t\tthis.SendValue(strField,varValue)\r\n\t}\r\n\tcon.SendText = function(strField,varValue)\r\n\t{\r\n\t\tthis.SendValue(strField,varValue)\r\n\t}\r\n\tcon.SendBoolean = function(strField,varValue)\r\n\t{\r\n\t\tthis.SendValue(strField,varValue)\r\n\t}\r\n\tcon.SendString = function(strField,varValue)\r\n\t{\r\n\t\tthis.SendValue(strField,intValue)\r\n\t}\r\n\tcon.SendDate = function(strField,varValue)\r\n\t{\r\n\t\tthis.SendValue(strField,varValue)\r\n\t}\r\n\r\n\t//-- call form document.onSendSessionData\r\n\tvar strFunc =\"OnSendSessionData\";\r\n\tif(window[strFunc])\r\n\t{\r\n\t\twindow[strFunc](con);\r\n\t}\r\n}", "function cm_engine_std(){\n\t// instalar propriedades basicas para operacao com motor\n\tvar _defaults = {\n\t\tagent: 'uAjaxCM',\t\t\t// nome do componente no lado cliente\n\t\t\n\t\t// ancoragem e instalacao\n\t\tanchor: '',\t\t\t\t\t// ancora, se o DOM com esse ID deixar de existir o motor morre automaticamente\n\t\tdomid: '',\t\t\t\t\t// dom de instalacao do conteudo obtido\n\n\t\tcleanup: false,\t\t\t\t// destruir componente quando atividades encerrarem?\n\t\terrno: 0,\t\t\t\t\t// codigo do erro durante execucao\n\t\tdatatype: '',\t\t\t\t// tipo de conversao da resposta, padrao: text. Opcoes: text/xhr,float,integer,xml,json\n\n\t\t// conteudo de retornos remotos\n\t\tcontent: \"\",\t\t\t\t// conteudo obtido remotamente, padro para datatype = text\n\t\t// o conteudo será convertido de acordo com o tipo de 'datatype' em:\n\t\tjson: false,\t\t\t\t// objeto JSON\n\t\txml: false,\t\t\t\t\t// objeto XML\n\t\tinteger: 0,\t\t\t\t\t// numero inteiro\n\t\tfloat: 0.0,\t\t\t\t\t// numero de ponto flutuante\n\n\t\t// quando datatype = text/xhr, procurar tag SCRIPT e executa o codigo transportado com eval\n\t\texec: true,\n\t\tinner: true,\t\t\t\t// aplicar texto obtido dentrod e domid?\n\t\tseqid: 0,\t\t\t\t\t// numero sequencial para controle de requisicoes\n\n\t\t// controle de cache\n\t\tcache: false,\t\t\t\t// permitir cache? RECOMENDAVEL: FALSE\n\t\tcachetime: 0,\t\t\t\t// se cache=true, cachetime determina o tempo para manter em cache (segundos)\n\t\tcache_id: 0,\t\t\t\t// id de cache\n\t\tcache_expire: 0,\t\t\t// timestamp unix de quando o cache expira\n\t\t/*\n\t\t\tflag para ignorar conteudo repetido\n\t\t\tmodified compara o conteudo recebido com o anterior\n\t\t\t\tfalse - todos os eventos de processamento de dados serão processados mesmo sendo igual\n\t\t\t\ttrue - so irá disparar eventos de processamento de dados se as informacoes enviadas\n\t\t\t\t\t\tforem diferentes da ultima resposta\n\t\t*/\n\t\tmodified: true,\n\t\t// keepalive: -1,\t// -1 = nao mexer, 0/false = nao, 1/true = sim\n\n\t\t// controle de cabeçalhos\n\t\theaders: {},\t\t\t\t// cabecalhos a serem enviados\n\n\t\t// tipo do cabecalho Content-Type - application/x-www-form-urlencoded\n\t\tcontentType: 'application/x-www-form-urlencoded',\n\t\tcharset: 'UTF-8',\n\t\t/*\n\t\tjQuery: contentType: \"application/x-www-form-urlencoded; charset=UTF-8\"\n\t\tcontentType: \"application/x-www-form-urlencoded; charset=UTF-8\"\n\t\tareq.setRequestHeader(\"Content-Type\",\"application/x-javascript; charset:ISO-8859-1\"); \t\t\n\t\ttry { \n\t\t\tresponse.setCharacterEncoding(\"UTF-8\"); \n\t\t\tresponse.getWriter().write(\"this._data = \" + js + \";\"); \n\t\t\tresponse.flushBuffer(); \n\t\t} catch (Exception e) { \n\t\t\t// ignore exception here \n\t\t} \n\t\thttp_request.overrideMimeType('text/xml; charset=iso-8859-1');\n\t\tif (http_request.overrideMimeType) { \n\t\t\thttp_request.overrideMimeType('text/xml; charset=iso-8859-1'); \n\t\t}\n\t\t*/\n\t\t\n\t\t// eventos\n\t\tonplay: false,\t\t\t\t// funcao a executar (sempre) antes de disparar o motor contra o servidor\n\t\tonstatuschange: false,\t\t// funcao a executar quando o status do objeto xhr mudar\n\t\tontimeout: false,\t\t\t// funcao a executar quando o servidor remoto nao responder\n\t\tonretry: false,\t\t\t\t// funcao a executar antes de tentar nova requisicao com o servidor\n\t\tonerror: false,\t\t\t\t// funcao a executar quando houver erro na requisicao\n\t\tonreply: false,\t\t\t\t// funcao apos receber retorno do conteudo remoto com sucesso\n\t\tondestroy: false,\t\t\t// funcao a executar quando o motor for finalizado, antes da destruicao em si\n\t\tonpause: false,\t\t\t\t// funcao a executar quando o motor entrar em modo pause\n\t\tonrepeatover: false,\t\t// funcao a executar quando repeat atingido\n\t\tondatarx: false,\t\t\t// funcao de traducao de dados recebidos\n\n\t\t// objeto do motor XHR\n\t\thttp_status: 0,\n\t\txhttp: false,\t\t\t\t// var que contera objeto XmlHttpRequest\n\t\tmethod: 'POST',\t\t\t\t// metodo de postagem de parametros, GET ou POST\n\n\t\t// array ou objeto de parametros submetidos\n\t\tdata: false,\t\t\t\t// objeto com parametro:valor a ser enviado (via GET ou POST, depende de .method\n\t\tedata: false,\t\t\t\t// semelhante a 'data', usado para auxilio em refresh do objeto sem reescrita do 'data'\n\t\ttdata: false,\t\t\t\t// dados extras a serem enviados uma unica vez (temporario)\n\n\t\t// alvo remoto a ser requisitado (URN), nao pode conter um dominio/ip/porta diferente\n\t\turl: \"\",\t\t\t\t\t// url dos metodos: xhr, iframe\n\t\tquery_string: \"\",\t\t\t// INTERNA: string completa de requisicao GET (url com querystring)\n\t\tpost_string: \"\",\t\t\t// INTERNA: string completa de requisicao POST (apenas variaveis de data, edata e tdata)\n\n\t\t// modo XHR sincrono/assincrono\n\t\tasync: true,\n\n\t\t// controle para pemitir stop/start do motor\n\t\txstatus: 0,\t\t\t\t\t/*\tcontrole de stop/start\n\t\t\t\t\t\t\t\t\t\t0=nao iniciado\n\t\t\t\t\t\t\t\t\t\t1-4 - status xhttp/XHR\n\t\t\t\t\t\t\t\t\t\t5 - servico concluido\n\t\t\t\t\t\t\t\t\t\t6 - evento onstatechange impediu continuacao\n\t\t\t\t\t\t\t\t\t\t7=pausado\n\t\t\t\t\t\t\t\t\t\t8=pausado aguardando wait (tempo de pause)\n\t\t\t\t\t\t\t\t\t\t9=parado\n\t\t\t\t\t\t\t\t\t\t10 - reposta http invalida recebida pelo servidor\n\t\t\t\t\t\t\t\t\t\t11 - ancora desconectada\n\t\t\t\t\t\t\t\t\t\t12 - motor parado em transito\n\t\t\t\t\t\t\t\t\t*/\n\n\t\t// codico http da ultima resposta do servidor\n\t\tstatuscode: false,\n\n\t\t// controle de requisicoes\n\t\twait: 0,\t\t\t\t\t// (float) tempo de espera antes de iniciar a tarefa (aguarda antes requsicao inicial)\n\t\tpause: 0,\t\t\t\t\t// (float) tempo de espera apos pause antes de reiniciar o motor\n\t\tinterval: 0,\t\t\t\t// (float) intervalo de re-carregamento automatico para metodo xhr\n\t\trepeat: 0,\t\t\t\t\t// (int) numero limite de requisicoes a serem solicitadas no servidor a cada .interval\n\t\tretries: 0,\t\t\t\t\t// (int) numero de tentativas, inicializar com >0 para decrescer nas tentativas\n\t\ttimeout: 0,\t\t\t\t\t// (float) tempo a aguardar a resposta do servidor, se demorar mais do que timeout, o motor considera que o servidor esta com problemas\n\t\tping: 0,\t\t\t\t\t// tempo em milisecundos que o servidor demorou para responder\n\n\t\t// variaveis internas\n\t\tprocess: 0,\t\t\t\t\t// flag de sinalizacao de processamento XHR ativo, 0=nao esta em execucao, 1=em execucao\n\n\t\t// controle de tempo\n\t\tlifetime: 0,\t\t\t\t// (float) se definido, determina o tempo de vida do motor em ms a partir da requisicao\n\n\t\tstarttime: 0,\t\t\t\t// microtimetamp do momento de criacao do motor\n\t\tstoptime: 0,\t\t\t\t// microtimestamp do momento em que o motor parou (trabalho concluido)\n\t\tplaytime: 0,\t\t\t\t// microtimestamp do momento em que a requisicao foi criada\n\t\tendtime: 0,\t\t\t\t\t// microtimestamp do momento em que a requisicao foi finalizada\n\t\tlastreply: 0,\t\t\t\t// microtimestamp da ultima resposta do servidor remoto (statuschange)\n\n\t\t// CONTROLE INTERNO\n\t\tstats: {\n\t\t\treplies: 0,\n\t\t\ttimeout: 0,\n\t\t\terr: 0,\n\t\t\trequest: 0,\n\t\t\tretries: 0,\n\t\t\tmaxretries: 0,\n\t\t\tlifetime: 0,\n\t\t\tdownload: 0,\n\t\t\tupload: 0\n\t\t},\t\t\t\t\t/* objeto com estatisticas:\n\t\t\t\t\t\t\t\t\t\t.replies: numero de requisicoes atendidas pelo servidor\n\t\t\t\t\t\t\t\t\t\t.timeout: numero de requisicoes em timeout\n\t\t\t\t\t\t\t\t\t\t.err: numero de erros do lado servidor (timeout, crash, etc...)\n\t\t\t\t\t\t\t\t\t\t.request: numero de requisicoes enviadas ao servidor\n\t\t\t\t\t\t\t\t\t\t.retries: numero de vezes que a requisicao foi repetida (retentativas)\n\t\t\t\t\t\t\t\t\t\t.lifetime: tempo de vida do motor desde sua criacao\n\t\t\t\t\t\t\t\t\t\t.download: numero de bytes recebidos\n\t\t\t\t\t\t\t\t\t\t.upload: numero de bytes enviados\n\t\t\t\t\t\t\t\t\t*/\n\n\t\t// variaveis internas para controle de intervalo e timeout em javascript setTimeout e setInterval\n\t\tjstimer_wait: 0,\t\t\t// tempo de aguardo para iniciar motor - TIMEOUT\n\t\tjstimer_interval: 0,\t\t// tempo de aguardo entre requisicoes repetitivas via .interval - TIMEOUT\n\t\tjstimer_lifetime: 0,\t\t// tempo de aguardo antes de destruir o motor por lifetime maximo - TIMEOUT\n\t\tjstimer_pause: 0,\t\t\t// tempo de aguardo em pause antes de reinciair motor - TIMEOUT\n\t\tjstimer_timeout: 0\t\t\t// tempo de aguardo ate o tempo limite de timeout (sem resposta) - TIMEOUT\n\n\t};\n\t\n\t// forcar parametros globais nas opcoes padroes\n\tfor(var _ix in cm_engine_globals) _defaults[_ix] = (cm_engine_globals[_ix]);\n\t\n\t// zerar stats\n\t//for(var _jx in _defaults.stats) _defaults.stats[_jx] = 0;\n\n\treturn _defaults;\n}", "function ksfData()\n{\n}", "function GetInit(inituserdata) {\r\n var $res;\r\n $.ajax({\r\n type: \"POST\",\r\n url: \"test.url\",\r\n async: false,\r\n cache: false,\r\n dataType: 'json',\r\n data: inituserdata,\r\n success: function (rdata) {\r\n $res = rdata;\r\n\r\n }\r\n });\r\n return $res;\r\n }", "function associaCapitoloAllaVariazione(capitolo, url, $pulsante) {\n var oggettoDaInviare = {};\n\n var urlNotUndefined = url || \"aggiungiCapitoliNellaVariazione_aggiornamento.do\";\n var ajaxParam;\n\t\tvar listaImporti = capitolo.listaImportiCapitolo;\n\t\tvar annoBilancio = $('#HIDDEN_annoEsercizio').val();\n\t\t//questa cosa sono sicura si possa far meglio, ma sono di fretta. Spero che qualcuno la metta a posto...\n\t\tvar importiCapitolo = listaImporti.find(function(imp){\n\t\t\treturn annoBilancio && imp.annoCompetenza == annoBilancio;\t\t\n\t\t});\n\t\tvar importi = importiCapitolo || {};\n\t\t\n oggettoDaInviare.uid = capitolo.uid;\n oggettoDaInviare.statoOperativoElementoDiBilancio = capitolo.statoOperativoElementoDiBilancio ? capitolo.statoOperativoElementoDiBilancio._name : \"\";\n oggettoDaInviare.competenza = $(\"#competenzaVariazioneAnno0NuovoDettaglio\").val() || 0;\n oggettoDaInviare.competenza1 = $(\"#competenzaVariazioneAnno1NuovoDettaglio\").val() || 0;\n oggettoDaInviare.competenza2 = $(\"#competenzaVariazioneAnno2NuovoDettaglio\").val() || 0;\n oggettoDaInviare.residuo = $(\"#residuoVariazioneNuovoDettaglio\").val() || 0;\n oggettoDaInviare.cassa = $(\"#cassaVariazioneNuovoDettaglio\").val() || 0;\n //la competenza originale non mi serve se non per \n oggettoDaInviare.competenzaOriginale = importi.stanziamento || 0;\n \n\t\toggettoDaInviare.residuoOriginale = importi.stanziamentoResiduo || 0;\n\t\toggettoDaInviare.cassaOriginale = importi.stanziamentoCassa || 0;\n \n oggettoDaInviare = qualify(oggettoDaInviare, \"specificaImporti.elementoCapitoloVariazione\");\n\n ajaxParam = $.extend(true, {}, oggettoDaInviare/*, oggettoOld*/);\n\n return effettuaChiamataAssociaCapitoloAVariazione(urlNotUndefined, ajaxParam);\n }", "function ajax_common_action(type,div_name,stringVar)\r\n{\t\r\n\tvar isAction=0;\r\n\tvar script_name='ajax_common_data.php';\t\r\n\t\r\n\t//photo refresh of the expert board\r\n\tif(type==\"set_reward_session\"){\r\n\t\tisAction=1;\r\n\t\t//alert(type);\r\n\t}\t\r\n\tif(isAction==1){\r\n\t\tvar url = script_name+\"?type=\"+type+\"&div_name=\"+div_name+\"&\"+stringVar;\r\n\t\t//alert(url);\r\n\t\thttp2.open(\"GET\", url , true); \r\n\t\thttp2.onreadystatechange = handleHttpResponse_ajax_common_action; \r\n\t\thttp2.send(null);\t\r\n\t}\r\n}", "function meu_callback(conteudo) {\r\r\n if (!(\"erro\" in conteudo)) {\r\r\n //Atualiza os campos com os valores.\r\r\n document.getElementById('logradouro').value=(conteudo.logradouro);\r\r\n document.getElementById('bairro').value=(conteudo.bairro);\r\r\n document.getElementById('cidade').value=(conteudo.localidade);\r\r\n document.getElementById('uf').value=(conteudo.uf);\r\r\n } //end if.\r\r\n else {\r\r\n //CEP não Encontrado.\r\r\n limpa_formulário_cep();\r\r\n alert(\"CEP não encontrado.\");\r\r\n }\r\r\n}", "function readParametres(){\n\tchrome.storage.sync.get(\"url\", function(data) {\n\t\tif (!chrome.runtime.error) {\n\t\t\turlApi = data.url;\n\t\t}\n\t});\n\n\tchrome.storage.sync.get(\"storeCode\", function(data) {\n\t\tif (!chrome.runtime.error) {\n\t\t\tstoreCode = data.storeCode;\n\t\t}\n\t});\n}", "function jsonp_cb() { return XORIGN || FDomainRequest() ? 0 : unique() }", "function getdata2(surl, inputHidden, content){\n\tvar cbo = null;\n\tvar json = new Request.JSON({\n\t\tmethod : 'post',\n\t\turl : surl,\n\t\t async: false,\n\t\t noCache : true,\n\t\t//data : param,\n\t\tonComplete : function(data) {\n\t\t\tcbo = dropdownA2(data,inputHidden,content);\n\t\t}\n\t});\n\tjson.send();\n\treturn cbo;\n}", "function resetJsAttributeVars(){\n\t//Determinamos los valores para realizar la búsqueda\n\tjsMaeEstatProduCodEstaProd = '';\n\tjsMaeEstatProduDescripcion = '';\n\t\n}", "function i(t){\"use strict\";var a=this,n=e;a.s=t,a._c=\"s_m\",n.s_c_in||(n.s_c_il=[],n.s_c_in=0),a._il=n.s_c_il,a._in=n.s_c_in,a._il[a._in]=a,n.s_c_in++,a.version=\"1.0\";var i,o,r,s=\"pending\",c=\"resolved\",d=\"rejected\",l=\"timeout\",u=!1,p={},m=[],g=[],f=0,b=!1,h=function(){var e={};e.requiredVarList=[\"supplementalDataID\",\"timestamp\",\"dynamicVariablePrefix\",\"visitorID\",\"marketingCloudVisitorID\",\"analyticsVisitorID\",\"audienceManagerLocationHint\",\"authState\",\"fid\",\"vmk\",\"visitorMigrationKey\",\"visitorMigrationServer\",\"visitorMigrationServerSecure\",\"charSet\",\"visitorNamespace\",\"cookieDomainPeriods\",\"fpCookieDomainPeriods\",\"cookieLifetime\",\"pageName\",\"pageURL\",\"referrer\",\"contextData\",\"currencyCode\",\"lightProfileID\",\"lightStoreForSeconds\",\"lightIncrementBy\",\"retrieveLightProfiles\",\"deleteLightProfiles\",\"retrieveLightData\"],e.accountVarList=e.requiredVarList.concat([\"purchaseID\",\"variableProvider\",\"channel\",\"server\",\"pageType\",\"transactionID\",\"campaign\",\"state\",\"zip\",\"events\",\"events2\",\"products\",\"audienceManagerBlob\",\"tnt\"]),e.lightRequiredVarList=[\"timestamp\",\"charSet\",\"visitorNamespace\",\"cookieDomainPeriods\",\"cookieLifetime\",\"contextData\",\"lightProfileID\",\"lightStoreForSeconds\",\"lightIncrementBy\"],e.lightVarList=e.lightRequiredVarList.slice(0),e.accountConfigList=[\"account\",\"allAccounts\",\"debugTracking\",\"visitor\",\"visitorOptedOut\",\"trackOffline\",\"offlineLimit\",\"offlineThrottleDelay\",\"offlineFilename\",\"usePlugins\",\"doPlugins\",\"configURL\",\"visitorSampling\",\"visitorSamplingGroup\",\"linkObject\",\"clickObject\",\"linkURL\",\"linkName\",\"linkType\",\"trackDownloadLinks\",\"trackExternalLinks\",\"trackClickMap\",\"trackInlineStats\",\"linkLeaveQueryString\",\"linkTrackVars\",\"linkTrackEvents\",\"linkDownloadFileTypes\",\"linkExternalFilters\",\"linkInternalFilters\",\"useForcedLinkTracking\",\"forcedLinkTrackingTimeout\",\"trackingServer\",\"trackingServerSecure\",\"ssl\",\"abort\",\"mobile\",\"dc\",\"lightTrackVars\",\"maxDelay\",\"expectSupplementalData\",\"usePostbacks\",\"AudienceManagement\"];for(var t=0;250>=t;t++)76>t&&(e.accountVarList.push(\"prop\"+t),e.lightVarList.push(\"prop\"+t)),e.accountVarList.push(\"eVar\"+t),e.lightVarList.push(\"eVar\"+t),6>t&&e.accountVarList.push(\"hier\"+t),4>t&&e.accountVarList.push(\"list\"+t);var a=[\"pe\",\"pev1\",\"pev2\",\"pev3\",\"latitude\",\"longitude\",\"resolution\",\"colorDepth\",\"javascriptVersion\",\"javaEnabled\",\"cookiesEnabled\",\"browserWidth\",\"browserHeight\",\"connectionType\",\"homepage\",\"pageURLRest\"];return e.accountVarList=e.accountVarList.concat(a),e.requiredVarList=e.requiredVarList.concat(a),e}();a.newCall=!1,a.newCallVariableOverrides=null,a.hitCount=0,a.timeout=1e3,a.currentHit=null,a.backup=function(e,t,a){var n,i,o,r;for(t=t||{},n=0;2>n;n++)for(i=n>0?h.accountConfigList:h.accountVarList,o=0;o<i.length;o++)r=i[o],t[r]=e[r],a||t[r]||(t[\"!\"+r]=1);return t},a.restore=function(e,t,a){var n,i,o,r,s,c,d=!0;for(n=0;2>n;n++)for(i=n>0?h.accountConfigList:h.accountVarList,o=0;o<i.length;o++)if(r=i[o],s=e[r],s||e[\"!\"+r]){if(!a&&(\"contextData\"==r||\"retrieveLightData\"==r)&&t[r])for(c in t[r])s[c]||(s[c]=t[r][c]);t[r]=s}return d},a.createHitMeta=function(e,t){var n,i=a.s,o=[],r=[];return t=t||{},n={id:e,delay:!1,restorePoint:f,status:c,promise:Promise.resolve(),backup:{s:{},sSet:{},variableOverrides:{}},values:{s:{},variableOverrides:{}},timeout:!1},o=a.replacePromises(i,n.values.s),r=a.replacePromises(t,n.values.variableOverrides),n.backup.s=a.backup(i),n.backup.sSet=a.backup(i,null,!0),n.backup.variableOverrides=t,(o&&o.length>0||r&&r.length>0)&&(n.delay=!0,n.status=s,n.promise=Promise.all([Promise.all(o),Promise.all(r)]).then(function(){n.delay=!1,n.status=c,n.timeout&&clearTimeout(n.timeout)}),a.timeout&&(n.timeout=setTimeout(function(){n.delay=!1,n.status=l,n.timeout&&clearTimeout(n.timeout),a.sendPendingHits()},a.timeout))),n},a.replacePromises=function(e,t){var a,n,i,o,r,l,u=[];t=t||{},o=function(e,t){return function(a){t[e].value=a,t[e].status=c}},r=function(e,t){return function(a){t[e].status=d,t[e].exception=a}},l=function(e,t,a){var n=e[t];n instanceof Promise?(a[t]=a[t]||{},\"contextData\"===t||\"retrieveLightData\"===t?e[t]={}:e[t]=\"\",a[t].status=s,u.push(n.then(o(t,a))[\"catch\"](r(t,a)))):\"object\"==typeof n&&null!==n&&n.promise instanceof Promise&&(a[t]=a[t]||{},\"contextData\"===t||\"retrieveLightData\"===t?e[t]={}:e[t]=\"\",n.hasOwnProperty(\"unresolved\")&&(a[t].value=n.unresolved),a[t].status=s,u.push(n.promise.then(o(t,a))[\"catch\"](r(t,a))))};for(a in e)if(e.hasOwnProperty(a))if(i=e[a],\"contextData\"===a||\"retrieveLightData\"===a)if(i instanceof Promise||\"object\"==typeof i&&null!==i&&i.promise instanceof Promise)l(e,a,t);else{t[a]={isGroup:!0};for(n in i)i.hasOwnProperty(n)&&l(i,n,t[a])}else l(e,a,t);return u},a.metaToObject=function(e){var t,n,i,o,r=(a.s,{});if(e)for(t in e)if(e.hasOwnProperty(t))if(i=e[t],\"contextData\"!==t&&\"retrieveLightData\"!==t||!i.isGroup)i.value&&i.status===c&&(r[t]=i.value);else{r[t]={};for(n in i)i.hasOwnProperty(n)&&(o=i[n],o.value&&o.status===c&&(r[t][n]=o.value))}return r},a.getMeta=function(e){return e&&m[e]?m[e]:m},a.forceReady=function(){u=!0,a.sendPendingHits()},i=t.isReadyToTrack,t.isReadyToTrack=function(){return!!(!a.newCall&&i()&&g&&g.length>0&&(u||m[g[0]]&&!m[g[0]].delay))},o=t.callbackWhenReadyToTrack,t.callbackWhenReadyToTrack=function(e,n,i){var r,s;return n!==t.track?o(e,n,i):void(a.newCall&&(r=a.hitCount++,g.push(r),s=a.createHitMeta(r,a.newCallVariableOverrides),m[r]=s,b||(b=setInterval(a.sendPendingHits,100)),s.promise.then(function(){a.sendPendingHits()})))},r=t.t,t.t=t.track=function(e,t,n){n||(a.newCall=!0,a.newCallVariableOverrides=e),r(e,t),n||(a.newCall=!1,a.newCallVariableOverrides=null,a.sendPendingHits())},a.sendPendingHits=function(){for(var e,t,n,i,o,r=a.s;r.isReadyToTrack();){for(e=m[g[0]],a.currentHit=e,i={},o={},a.trigger(\"hitBeforeSend\",e),o.marketingCloudVisitorID=r.marketingCloudVisitorID,o.visitorOptedOut=r.visitorOptedOut,o.analyticsVisitorID=r.analyticsVisitorID,o.audienceManagerLocationHint=r.audienceManagerLocationHint,o.audienceManagerBlob=r.audienceManagerBlob,a.restore(e.backup.s,r),t=e.restorePoint;t<g[0];t++)n=a.metaToObject(m[t].values.s),delete n.referrer,delete n.resolution,delete n.colorDepth,delete n.javascriptVersion,delete n.javaEnabled,delete n.cookiesEnabled,delete n.browserWidth,delete n.browserHeight,delete n.connectionType,delete n.homepage,a.restore(n,o);a.restore(e.backup.sSet,o),a.restore(a.metaToObject(e.values.s),o),a.restore(e.backup.variableOverrides,i),a.restore(a.metaToObject(e.values.variableOverrides),i),r.track(i,o,!0),f=g.shift(),a.trigger(\"hitAfterSend\",e),a.currentHit=null}b&&g.length<1&&(clearInterval(b),b=!1)},i()||o(a,function(){a.sendPendingHits()},[]),a.on=function(e,t){p[e]||(p[e]=[]),p[e].push(t)},a.trigger=function(e,t){var a,n,i,o=!1;if(p[e])for(a=0,n=p[e].length;n>a;a++){i=p[e][a];try{i(t),o=!0}catch(e){}}else o=!0;return o},a._s=function(){a.trigger(\"_s\")},a._d=function(){return a.trigger(\"_d\"),0},a._g=function(){a.trigger(\"_g\")},a._t=function(){a.trigger(\"_t\")}}", "function ff(a,b){this.Dl=[];this.Fu=a;this.us=b||null;this.ui=this.jb=!1;this.ac=void 0;this.Sq=this.Ur=this.wm=!1;this.Zl=0;this.S=null;this.Lj=0}", "function prepare_params()\n{\n\tvar data = {\n\t\ttoken: token,\n\t\tlat: latitude,\n\t\tlon: longitude,\n\t\tdamage: $('#damage_info').val()\n\t};\n\n\tif(action != undefined && action != '') data.driver_action = action;\n\tif( $('#shipment-details-form .damage #checbox').is(':checked') ) {\n\t\tdata.damaged = 0;\n\t} else {\n\t\tdata.damaged = 1;\n\t}\n\tupload_params = data;\n}", "function _null_function() {}", "function initRequest(url) {\n \n //window.alert(\"initRequest(\" + url + \") is called\");\n //console.log(\"initRequest(%s) is called\", url);\n \n if (window.XMLHttpRequest) {\n req = new XMLHttpRequest(); \n } else if (window.ActiveXObject) {\n isIE = true;\n req = new ActiveXObject(\"Microsoft.XMLHTTP\");\n }\n }", "function fncallxmlAjaxFunction()\r\n{\r\n var senddata = mstrInformationTargetID;\r\n\t\tvar url = \"/loadData?senddata=\"+senddata;\r\n \r\n // To remove firefox bug :\r\n if (navigator.appName ==\"Netscape\")\r\n\t\t{\r\n\t\t\t http_request.open(\"GET\", url, true);\r\n\t\t}\r\n else\r\n {\r\n http_request.open(\"GET\", url, true);\r\n }\r\n\t\thttp_request.onreadystatechange = fnRequestwinStatusChanged;\r\n http_request.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');\r\n\t\thttp_request.send(senddata); \r\n}", "function qq(a){this.b=!0;this.c=!1;this.a=\"\";this.g=\"https\";this.f=\"\";this.port=-1;a=a.trim();a=a.replace(/[\\t\\r\\n]/g,\"\");a=rq(this,a);if(r(a,\"//\")){a=a.substr(2);a:{var b=0,c=!1;\"\"!==a&&91===a.charCodeAt(0)&&(c=!0,b++);for(var d=-1,e=-1,g=-1,k=a.charCodeAt(b);35!==k&&47!==k&&63!==k&&!isNaN(k);k=a.charCodeAt(++b))switch(k){case 64:d=b;g=e;e=-1;91===a.charCodeAt(b+1)?(c=!0,b++):c=!1;break;case 58:-1!==e||c||(e=b+1);break;case 91:c=!1;break;case 93:c=!1}-1!==d&&(c=d,-1!==g&&g===d&&c--);d=-1!==d?d+1:\n0;g=-1!==e?e-1:b;c=!1;if(91===a.charCodeAt(d)&&93===a.charCodeAt(g-1)&&d!=g){b:{for(var c=/^[0-9A-Fa-f]{1,4}$/,k=/^([0-9]{1,3}\\.){3}[0-9]{1,3}$/,l=!1,m=a.substr(d+1,g-d-2).split(\":\"),t=m.length,E=0;E<m.length;++E){var v=m[E];if(\"\"===v){if(l){c=!1;break b}l=!0;0===E&&(++E,--t);E===m.length-2&&(++E,--t)}else if(!c.test(v))if(E===m.length-1&&k.test(v))++t;else{c=!1;break b}}c=8<t||8>t&&!l?!1:!0}if(c)++d,--g;else{this.b=!1;break a}}d=a.substr(d,g-d);if(!c)b:{g=d;d=\"\";try{d=decodeURIComponent(g)}catch(J){this.b=\n!1;d=g;break b}for(g=0;g<d.length;++g)c=d.charCodeAt(g),!isNaN(c)&&31<c&&32!==c&&33!==c&&34!==c&&35!==c&&36!==c&&37!==c&&38!==c&&39!==c&&40!==c&&41!==c&&42!==c&&43!==c&&44!==c&&47!==c&&58!==c&&59!==c&&60!==c&&61!==c&&62!==c&&63!==c&&58!==c&&91!==c&&92!==c&&93!==c&&94!==c&&96!==c&&123!==c&&124!==c&&125!==c&&126!==c&&123!==c||(this.b=!1)}r(d,\".\")||-1!==d.indexOf(\"..\")?this.b=!1:\".\"===d.substr(-1)&&(d=d.substr(0,d.length-1));this.f=d;\"\"===this.f&&(this.b=!1);if(-1!==e){a=a.substr(e,b-e);if(\"\"===a)this.port=\n0;else if(/^[0-9]*$/g.test(a))this.port=parseInt(a,10);else{this.b=!1;break a}65535<this.port?this.b=!1:0===this.port&&(this.port={http:80,https:443,ftp:21,sftp:22}[this.a])}}}}", "static initialize(obj, _date, contentType, transferEncoding, connection, contentEncoding) { \n obj['date'] = _date;\n obj['content-type'] = contentType;\n obj['transfer-encoding'] = transferEncoding;\n obj['connection'] = connection;\n obj['content-encoding'] = contentEncoding;\n }", "function resetJsAttributeVars(){\n\t//Determinamos los valores para realizar la b?squeda\n\tjsCalGuiasCodGuia = '';\n\tjsCalGuiasDpteOidDepa = '';\n\tjsCalGuiasValTitu = '';\n\tjsCalGuiasFecInicVali = '';\n\tjsCalGuiasFecFinVali = '';\n\tjsCalGuiasValDescGuia = '';\n\t\n}", "get copy_datauri(){\n\t\treturn data.copy_datauri;\n\t}", "function resetJsAttributeVars(){\n\t//Determinamos los valores para realizar la búsqueda\n\tjsSegPaisViewCodPais = '';\n\tjsSegPaisViewMoneOidMone = '';\n\t\n}", "function detailask(x,y,z,t) {\n//var temp=new Array();\n//temp=x.split(',');\nvar query=x;\nvar session=y;\nvar sessionfolder=z;\nvar plotfile=t;\nvar file = 'http://bioinf3.bioc.le.ac.uk/~ss533/cgi-bin/sessions2.cgi?session='+session+'&query='+query+'&sessionfolder='+sessionfolder+'';\nnew Ajax.Updater(\"detailask\",file,{\n\tparameters:{session:session,query:query,sessionfolder:sessionfolder,plotfile:plotfile}});\n}", "function $3gg(){\n var blob$=new $3gg.$$;XMLHttpRequestResponseType(\"blob\",blob$);\n return blob$;\n}", "constructor(_data = {}) {\n this._data = _data;\n }", "function enviaDados(url) {\n criaQueryString();\n requisicaoHTTP(\"POST\", url, true);\n\n}", "function nullHandlerFunction() {}", "function api_url(data){\n\treturn base_url+data;\n}", "function _D(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n={mimeType:t.mimeType||null,onBeforeSend:t.onBeforeSend||Function.prototype,onSuccess:t.onSuccess||Function.prototype,onError:t.onError||Function.prototype,onComplete:t.onComplete||Function.prototype},r=Array.isArray(e)?e:[e],o=Array.apply(null,Array(r.length)).map((function(e){return null}));function a(e){var t=e&&\"<\"===e.trim().charAt(0);return e&&!t}function i(e,t){n.onError(e,r[t],t)}function l(e,t){var a=n.onSuccess(e,r[t],t);e=!1===a?\"\":a||e,o[t]=e,-1===o.indexOf(null)&&n.onComplete(o)}var s=document.createElement(\"a\");r.forEach((function(e,t){if(s.setAttribute(\"href\",e),s.href=String(s.href),Boolean(document.all&&!window.atob)&&s.host.split(\":\")[0]!==location.host.split(\":\")[0]){if(s.protocol===location.protocol){var r=new XDomainRequest;r.open(\"GET\",e),r.timeout=0,r.onprogress=Function.prototype,r.ontimeout=Function.prototype,r.onload=function(){a(r.responseText)?l(r.responseText,t):i(r,t)},r.onerror=function(e){i(r,t)},setTimeout((function(){r.send()}),0)}else console.warn(\"Internet Explorer 9 Cross-Origin (CORS) requests must use the same protocol (\".concat(e,\")\")),i(null,t)}else{var o=new XMLHttpRequest;o.open(\"GET\",e),n.mimeType&&o.overrideMimeType&&o.overrideMimeType(n.mimeType),n.onBeforeSend(o,e,t),o.onreadystatechange=function(){4===o.readyState&&(o.status<400&&a(o.responseText)||0===o.status&&a(o.responseText)?l(o.responseText,t):i(o,t))},o.send()}}))}", "function parseArguments(url, data, success, dataType) {\n\t if ($.isFunction(data)) dataType = success, success = data, data = undefined;\n\t if (!$.isFunction(success)) dataType = success, success = undefined;\n\t return {\n\t url: url,\n\t data: data,\n\t success: success,\n\t dataType: dataType\n\t };\n\t }", "function co(a,b){this.Wd=[];this.uf=a;this.kf=b||null;this.jd=this.Lc=!1;this.Qb=void 0;this.Ne=this.If=this.he=!1;this.Zd=0;this.Ca=null;this.ie=0}", "loadOwnProperties(){\r\n//\t\tdebugger;\r\n\t\tvar self=this;\r\n//\t\tself.autoAddPostHtml=false;\r\n\t\tself.name=self.getAttrVal(\"name\");\r\n\t\tself.nameRest=self.getAttrVal(\"nameRest\");\r\n\t\tself.type=self.getAttrVal(\"type\");\r\n//\t\tself.where=self.getAttrVal(\"where\",undefined,false);\r\n\t\tself.innerVarName=self.getAttrVal(\"as\",undefined,false);\r\n\t\tself.resultVarName=self.getAttrVal(\"resultvarname\");\r\n\t\tself.restVarName=self.getAttrVal(\"restvarname\");\r\n\t\t\r\n\t\tself.bWithRest=false;\r\n\t\tself.hsResult;\r\n\t\tself.hsRest;\r\n\t\t\r\n\t\tself.recursiveField=self.getAttrVal(\"recursivefield\",undefined,false);\r\n\t\t\r\n\t\tself.source=self.getAttrVal(\"source\");\r\n\t\tself.sourceJson=self.getAttrVal(\"sourcejson\");\r\n\t\tself.sourceJS=self.getAttrVal(\"sourcejs\",undefined,false);\r\n\t\tself.sourceFormula=self.getAttrVal(\"sourceformula\",undefined,false);\r\n\t\t\r\n\t\tself.whereCondition=self.getAttrVal(\"where\",undefined,false);\r\n\t\tself.orderFormula=self.getAttrVal(\"order\",undefined,false);\r\n\t\tself.boundStartAt=self.getAttrVal(\"start\",undefined,false);\r\n\t\tself.boundLimit=self.getAttrVal(\"limit\",undefined,false);\r\n\t}", "function ajax ( type, fichier, variables /* , fonction */ ) \r\n{ \r\n\tif ( window.XMLHttpRequest ) var req = new XMLHttpRequest();\r\n\telse if ( window.ActiveXObject ) var req = new ActiveXObject(\"Microsoft.XMLHTTP\");\r\n\telse alert(\"Votre navigateur n'est pas assez récent pour accéder à cette fonction, ou les ActiveX ne sont pas autorisés\");\r\n\tif ( arguments.length==4 ) var fonction = arguments[3];\r\n\r\n\tif (type.toLowerCase()==\"post\") {\r\n\t\treq.open(\"POST\", _URL+fichier, true);\r\n\t\treq.setRequestHeader('Content-Type','application/x-www-form-urlencoded; charset=iso-8859-1');\r\n\t\treq.send(variables);\r\n\t} else if (type.toLowerCase()==\"get\") {\r\n\t\treq.open('get', _URL+fichier+\"?\"+variables, true);\r\n\t\treq.setRequestHeader('Content-type', 'application/x-www-form-urlencoded; charset=iso-8859-1');\r\n\t\treq.send(null);\r\n\t} else { \r\n\t\talert(\"Méthode d'envoie des données invalide\"); \r\n\t}\r\n\r\n\treq.onreadystatechange = function() { \r\n\t\tif (req.readyState == 4 && req.responseText != null )\r\n\t\t{\t\t\t\t\r\n\t\t\tif (fonction) eval( fonction + \"('\"+escape(req.responseText)+\"')\");\r\n\t\t\t\r\n\t\t} \r\n\t}\r\n}", "function ajax ( type, fichier, variables /* , fonction */ ) \r\n{ \r\n\tif ( window.XMLHttpRequest ) var req = new XMLHttpRequest();\r\n\telse if ( window.ActiveXObject ) var req = new ActiveXObject(\"Microsoft.XMLHTTP\");\r\n\telse alert(\"Votre navigateur n'est pas assez récent pour accéder à cette fonction, ou les ActiveX ne sont pas autorisés\");\r\n\tif ( arguments.length==4 ) var fonction = arguments[3];\r\n\r\n\tif (type.toLowerCase()==\"post\") {\r\n\t\treq.open(\"POST\", _URL+fichier, true);\r\n\t\treq.setRequestHeader('Content-Type','application/x-www-form-urlencoded; charset=iso-8859-1');\r\n\t\treq.send(variables);\r\n\t} else if (type.toLowerCase()==\"get\") {\r\n\t\treq.open('get', _URL+fichier+\"?\"+variables, true);\r\n\t\treq.setRequestHeader('Content-type', 'application/x-www-form-urlencoded; charset=iso-8859-1');\r\n\t\treq.send(null);\r\n\t} else { \r\n\t\talert(\"Méthode d'envoie des données invalide\"); \r\n\t}\r\n\r\n\treq.onreadystatechange = function() { \r\n\t\tif (req.readyState == 4 && req.responseText != null )\r\n\t\t{\t\t\t\t\r\n\t\t\tif (fonction) eval( fonction + \"('\"+escape(req.responseText)+\"')\");\r\n\t\t\t\r\n\t\t} \r\n\t}\r\n}", "function test(){\n var requestURL2 = \"qa\";\n var data0={\n \"session_id\":sessionID,\n \"sequence\":indx,\n \"timestamp\":\"????\",\n \"user_question\":{\n \"content\":userMsg,\n \"act\":act0+\"?\"+ner\n },\n \"robot_answer\":{\n \"content\":answer,\n \"act\":bact\n }\n };\n $.ajax({\n type: \"POST\",\n url:requestURL2,\n dataType:\"json\",\n contentType: \"application/json;charset=utf-8\",\n processData:false,\n headers:{\n speciLan:\"ch\",\n devicetype:\"web\",\n userkey:12345\n },\n data:JSON.stringify(data0),\n /* dataType: 'json',*/\n success: function (data) {\n }\n });\n }", "function getdata(surl, inputHidden, content){\n\tvar json = new Request.JSON({\n\t\tmethod : 'post',\n\t\turl : surl,\n\t\t async: false,\n\t\t noCache : true,\n\t\t//data : param,\n\t\tonComplete : function(data) {\n\t\t dropdownA(data,inputHidden,content);\n\t\t}\n\t});\n\tjson.send();\t\n}", "function urllib(d) {\n\t\t// nothing yet\n\t\t//console.log(this);\n\t\t//console.log(that);\n\t\treturn {current: varval,};\n\t }", "function\nXATS2JS_optn_nil()\n{\nlet xtmp0;\n{\nxtmp0 = [0];\n}\n;\nreturn xtmp0;\n} // function // XATS2JS_optn_nil(83)", "constructor(id, data = ''){\n\t\tthis.id = id;\n this.data = data;\t\t\n\t}" ]
[ "0.5797142", "0.57417", "0.5704281", "0.560942", "0.55760556", "0.5551452", "0.5551452", "0.5551452", "0.5551452", "0.55450845", "0.55106324", "0.5467482", "0.5378713", "0.5364637", "0.536413", "0.5355956", "0.5350828", "0.5339574", "0.5302566", "0.52872974", "0.5278333", "0.52582693", "0.524856", "0.5243133", "0.5238022", "0.5235144", "0.5235009", "0.5234131", "0.5229493", "0.52047986", "0.52047986", "0.5199329", "0.51741487", "0.51716506", "0.51634717", "0.51586986", "0.5158679", "0.5156922", "0.5146639", "0.51441634", "0.5133064", "0.51325065", "0.5126834", "0.5125563", "0.5071134", "0.5058032", "0.5058032", "0.5055762", "0.50545734", "0.5053424", "0.5051344", "0.5048667", "0.5040594", "0.50340354", "0.5018815", "0.50158894", "0.5010086", "0.5009185", "0.5002", "0.49938965", "0.49884772", "0.49850893", "0.495851", "0.49536473", "0.49478695", "0.49440753", "0.49440277", "0.49415553", "0.49410525", "0.4936837", "0.4936197", "0.49319732", "0.49230945", "0.4922854", "0.49205667", "0.49179757", "0.49164775", "0.49134925", "0.4912193", "0.49031126", "0.48984072", "0.48944432", "0.4891332", "0.48912826", "0.4884269", "0.4882736", "0.4882098", "0.48647577", "0.48631153", "0.4862672", "0.48579228", "0.48573858", "0.4857245", "0.4855055", "0.48539463", "0.48539463", "0.48530376", "0.4844013", "0.48410985", "0.48393008", "0.4837668" ]
0.0
-1
displays the dropped file
function ParseFile(file,dest,dis) { // display an image if (file.type.indexOf("image") == 0) { var reader = new FileReader(); reader.onload = function(e) { if(dis==0 || pars_glob==dis) { if(file.size <= $id("MAX_FILE_SIZE").value) { m_add(file,e.target.result,"file",dest,true);Output('<img src="' + e.target.result + '" />',dest);} else { pars_sizeE++; ref_thumb(); } if(pars_sizeE>0) alert(pars_sizeE+" files has not been accepted because of the file size is greater than 1 mb"); } else if(file.size <= $id("MAX_FILE_SIZE").value) m_add(file,e.target.result,"file",dest,false); else pars_sizeE++; pars_glob++; } reader.readAsDataURL(file); } else { alert("please upload only images"); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function drop(e) {\n e.stopPropagation();\n e.preventDefault();\n displayFile(e.dataTransfer.files);\n}", "function _handleDrop(e){\n\n var files = e.originalEvent.dataTransfer.files,\n docPath =currentDoc.file._parentPath,\n relativeFilename;\n\n if(files && files.length){\n e.stopPropagation();\n e.preventDefault();\n\n brackets.app.getDroppedFiles(function(err, paths){\n if(!err){\n relativeFilename = abspath2rel( docPath, paths[0] );\n doInsert({text:relativeFilename});\n hideDialog();\n }\n });\n }\n }", "function displayFileDetails(file, side){\n side.innerHTML = file.name + \" (\"+ file.size + \" bytes) has been selected. <br/> Last Modified: \" +\n (file.lastModifiedDate ? file.lastModifiedDate.toLocaleDateString() : 'n/a') + \". <br/><br/> To change files drop another file.\";\n }", "function handleFileDrop(evt){\n\tevt.stopPropagation();//stop this event from being handled multiple times at once\n\tevt.preventDefault();//prevents other handlers from running (makes this on the main)\n\tvar files = evt.dataTransfer.files; //retrieve the FileList object\n\t\n\tvar output = [];\n\tfor (var i=0, f; f = files[i]; i++){\n\t\toutput.push('<li><strong>', escape(f.name), '</strong> (', f.type || 'n/a', ') - ',\n\t\tf.size, ' bytes, last modified: ',\n\t\tf.lastModifiedDate ? f.lastModifiedDate.toLocaleDateString() : 'n/a', '</li>');\n\t};\n\tdocument.getElementById('list2').innerHTML = '<ul>' + output.join('') + '</ul>';\n}", "function handleFileSelect(evt) {\n evt.stopPropagation();\n evt.preventDefault();\n\n // Get the FileList object that contains the list of files that were dropped\n var files = evt.dataTransfer.files;\n\n // this UI is only built for a single file so just dump the first one\n dumpFile(files[0]);\n }", "onFileDropped($event) {\n this.prepareFilesList($event);\n }", "function handleFileSelect(evt) {\n evt.stopPropagation();\n evt.preventDefault();\n\n var files = evt.dataTransfer.files; // FileList object.\n \n // files is a FileList of File objects. List some properties.\n //var output = files[0].name;\n //console.log(files[0]);\n document.getElementById('uploadPic').name=files[0];\n for(var i = 0; i < files.length;i++){\n if (i == 0){ \n document.getElementById('dropzone').innerHTML = \"<p>\"+files[i].name +\"</p>\";\n }else{\n document.getElementById('dropzone').innerHTML += \"<p>\"+files[i].name +\"</p>\";\n }\n }\n /*for (var i = 0, f; f = files[i]; i++) {\n output.push('<li><strong>', escape(f.name), '</strong> (', f.type || 'n/a', ') - ',\n f.size, ' bytes, last modified: ',\n f.lastModifiedDate.toLocaleDateString(), '</li>');\n }*/\n \n }", "function handlePicked() {\n displayFile(this.files);\n}", "function handleDrop(event) {\n unhighlight(event);\n var dt = event.dataTransfer;\n var files = dt.files;\n handleFiles(files);\n }", "onDrop(files) {\n\n\t\tthis.addFilesToEditPane(files)\n\t\tthis.setState({ saveStatus: 2 });\n\t\t\t\t\t\t\n\t}", "function drop(e) {\n if (_isDraggingFile) {\n e.preventDefault();\n\n _outerCounter = 0;\n _innerCounter = 0;\n _isDraggingFile = false;\n\n var files = [];\n\n if (e.dataTransfer.items) {\n for (var i = 0; i < e.dataTransfer.items.length; i++) {\n if (e.dataTransfer.items[i].kind === 'file') {\n files.push(e.dataTransfer.items[i].getAsFile());\n }\n }\n }\n\n if (files.length > 0) {\n $(this).removeClass(\"drop-over\");\n $(\"html\").removeClass(\"dragging\");\n wvy.fileupload.uploadBlobs(files, $(jQuery.data($(this)[0], \"target\")));\n }\n }\n }", "function dropHandler(e) {\n\t\n\t//preventDefault behaviour\n \te.preventDefault();\n\t\n\t//remove the border\n\tdropArea.style.borderColor = bgColor;\n\t\n\t//grab the first file from the list\n\tfile = e.dataTransfer.files[0];\n\n\t//lets find out what the fileType is\n\tfileType = getFileType();\n\t\n\tif (fileType == \"NONE\") {\n\t\talert(\"File type not supported\");\n\t\treturn;\n\t}\n\t\n\t//create a new instance of FileReader\n\tvar reader = new FileReader();\n\n\t//our callback\n\treader.onload = function(loadEvent) {\n\n\t\t//lets find out the fileURL\n\t\tfileURL = loadEvent.target.result;\n\n\t\t//initPreview (now that we know what the file, fileType and fileURL are)\n\t\tinitPreview();\n\t\t\n\t}\n\n\t//now attempt to the read the file\n\treader.readAsDataURL(file);\n\t\n\t//hideIntroElem\n\thideIntroElem();\n\t//showOptionsElem\n\tshowOptionsElem();\n \t\n}", "function dropHandler(evt) {\n evt.originalEvent.stopPropagation();\n evt.originalEvent.preventDefault();\n\n var files = evt.originalEvent.dataTransfer.files;\n\tvar count = files.length;\n\t\n\t// turn on the table\n\tif ($('#drop_result').css('visibility') == 'hidden') {\n\t\t$('#drop_result').css('visibility', 'visible');\n\t};\n\n\t// Issue an async read for each dropped file.\n\t// Precess the file when the read completes.\n\t// Move the HTML stuff out soon.\n\tfor (var i = 0; i < count; i++) {\n\t\tvar reader = new FileReader();\n\t\tvar f = files[i];\n\t\t\n\t\treader.onerror = errorHandler;\n\t\treader.onload = (function(file) { return function(e) {\n\t\t\t var hash = hex_sha512(e.target.result);\n\t\t\t var output = [];\n\t\t\t\n\t\t\t output.push('<tr><td><button class=\\'btn btn-danger\\'>Remove</button></td>');\n\t\t\t output.push('<td><strong>', file.name, '</strong></td><td>', file.type || 'n/a', '</td>');\n\t\t\t output.push('<tdd class=\\'td_size\\' style=\\'visibility: hidden\\'>', file.size, '</td>');\n\t\t\t output.push('<tdd class=\\'td_hash\\' style=\\'visibility: hidden\\'>', hash, '</td></tr>');\t\t\t\n\t\t\t $('#drop_result').append(output.join(''));\n\t\t\t\t$('#drop_result').find('tr:last').find('button').click(function() {$this.parent().parent().remove();})\n\t\t };\n\t\t})(f);\n\n\t\treader.readAsDataURL(f);\n\t}\n}", "onDrop (file) {\n this.props.handleDroppedFile(file[0]); // Call parent function\n }", "function onDrop(event) {\n alert(\"Now Dropping!!\");\n // cancel event\n if (event.stopPropagation) {\n event.stopPropagation();\n }\n if (event.preventDefault) {\n event.preventDefault();\n }\n if (event.dataTransfer.files) {\n var files = event.dataTransfer.files;\n readFile(files);\n }\n }", "onDrop(files) {\n // First clean any memory used by any previous file drops\n this.cleanMemory();\n\n // Set the state to include the dropped files\n this.setState({\n files\n });\n }", "function dragOverHandler(ev) {\n // console.log('File(s) in drop zone');\n\n // Prevent default behavior (Prevent file from being opened)\n ev.preventDefault();\n}", "onDrop (files) {\n const fileArray = [];\n for (let idx = 0; idx < files.length; idx++) {\n fileArray.push(files[idx]);\n }\n this.props.onDrop(fileArray);\n }", "function onItemFileDrop( event ){\n ctrl.addFile( event.dataTransfer.files[0] );\n }", "function dropFile(event)\n\t{\n\t\t// stop the browser doing\n\t\t// it's normal thing of going\n\t\t// to the item\n\t\tevent.stopPropagation();\n\t\tevent.preventDefault();\n\t\t\n\t\t// query what was dropped\n\t\tvar files = event.dataTransfer.files;\n\t\t\n\t\t// if we have something\n\t\tif(files.length) {\n\t\t\thandleFile(files[0]);\n\t\t}\n\t\t\n\t\treturn false;\n\t}", "function onDrop(e) {\n e.stopPropagation();\n e.preventDefault();\n \n var file = e.dataTransfer.files[0];\n \n readFile(file);\n}", "function handleFileSelect(evt) {\r\n\t\"use strict\";\t\r\n var files = evt.target.files;\r\n\r\n // files is a FileList of File objects. List some properties.\r\n var output = [];\r\n for (var i = 0, f; f = files[i]; i++) {\r\n output.push('<li><strong>', escape(f.name), '</strong> (', f.type || 'n/a', ') - ',\r\n f.size, ' bytes, last modified: ',\r\n f.lastModifiedDate ? f.lastModifiedDate.toLocaleDateString() : 'n/a',\r\n '</li>');\r\n }\r\n\t\r\n\tupdateBGfromFile();\r\n\t\r\n\tBGNAME = escape(f.name);\r\n document.getElementById('file_output').innerHTML = '<ul>' + output.join('') + '</ul>';\r\n }", "function handleFileSelect(evt) {\n evt.stopPropagation();\n evt.preventDefault();\n if (window.File && window.FileReader && window.FileList && window.Blob) {\n // Pode-se receber varios arquivos. \n files = evt.dataTransfer.files; // Objeto FileList\n console.log(files)\n var output = [];\n for (var i = 0, f; f = files[i]; i++) {\n output.push('<li><strong>', escape(f.name), '</strong> (', f.type || 'n/a', ') - ',\n f.size, ' kb, last modified: ',\n f.lastModifiedDate.toLocaleDateString(), '</li>');\n }\n document.getElementById('list').innerHTML = '<ul>' + output.join('') + '</ul>';\n\n } else {\n swal({\n title: 'Navegador não suportado: ' + navigator.appVersion,\n text: 'Atualize seu navegador!',\n timer: 2000,\n showConfirmButton: false\n });\n }\n }//", "function handleFileSelect(evt) {\r\n evt.stopPropagation();\r\n evt.preventDefault();\r\n\r\n // Get the FileList object that contains the list of files that were dropped\r\n const files = evt.dataTransfer.files;\r\n\r\n // this UI is only built for a single file so just dump the first one\r\n file = files[0];\r\n const imageId = cornerstoneWADOImageLoader.wadouri.fileManager.add(file);\r\n loadAndViewImage(imageId);\r\n}", "function dragOverHandler(ev) {\n // console.log('File(s) in drop zone'); \n document.getElementById(\"dragdropcontainer\").style.backgroundColor = \"white\";\n // Prevent default behavior (Prevent file from being opened)\n ev.preventDefault();\n}", "function showDrop(event) { uploadzone.className += \" dragover\"; }", "drop_file(e) {\r\n let droppedFiles = e.dataTransfer.files;\r\n if(!droppedFiles) return;\r\n this.$parent.upload_image(droppedFiles[0]);\r\n }", "function handleDrop(id) {\n console.log('%c find me', 'font-size:30px; color: blue');\n console.log(id);\n }", "function dropFiles(ev) {\n for (var i = 0; i < ev.dataTransfer.files.length; i += 1) {\n if (ev.dataTransfer.files[i].type != \"text/xml\") {\n ev.preventDefault();\n openModalError();\n return;\n }\n }\n fileInput.files = ev.dataTransfer.files;\n animateOnDrop();\n ev.preventDefault();\n}", "function handleFileSelect(evt) {\n \n evt.stopPropagation();\n evt.preventDefault();\n\n // Get the FileList object that contains the list of files that were dropped\n const files = evt.dataTransfer.files;\n\n // this UI is only built for a single file so just dump the first one\n file = files[0];\n const imageId = cornerstoneWADOImageLoader.wadouri.fileManager.add(file);\n loadAndViewImage(imageId);\n }", "function readAndUploadDroppedFile(file) {\n Y.log('Uploading dropped file: ' + file.name, 'info', NAME);\n\n var divId = 'divUp' + Y.doccirrus.media.tempId();\n\n // add a line to the test console for this upload\n jqCache.divAttachmentsNote.append('' +\n '<div id=\"' + divId + '\" style=\"background-color: rgba(255, 255, 100, 0.3);\">' +\n Y.doccirrus.i18n('MediaMojit.list_attachments.view.LBL_UPLOADING') + ': ' + file.name +\n '</div>'\n );\n\n function onFileUploaded(err, newMediaId) {\n\n var jqNoticeDiv = $('#' + divId), cleanText;\n\n if (err) {\n Y.log( 'Error uploading file: ' + JSON.stringify( err ), 'warn', NAME );\n if ( err && !err.statusText ) { err = { 'statusText': 'Die Datei konnte nicht erkannt werden.' }; }\n cleanText = err.statusText.replace('500', '').replace( new RegExp( '\"', 'g'), '');\n\n jqNoticeDiv.html( 'Fehler: ' + cleanText + '<br/>Datei: ' + file.name );\n jqNoticeDiv.css( 'background-color', 'rgba(255, 100, 100, 0.3)' );\n\n // pop a notice to the user\n Y.doccirrus.DCWindow.notice( {\n type: 'notice',\n title: 'Hinweis',\n message: cleanText + '<br/>Datei: ' + file.name,\n window: { id: 'list_attachments_upload_fail', width: 'medium' }\n } );\n\n window.setTimeout(function() { jqNoticeDiv.hide(); }, 2800);\n return;\n }\n\n Y.log('Attached file as: ' + newMediaId, 'debug', NAME);\n\n // update the upload line in the UI\n jqNoticeDiv.html( Y.doccirrus.i18n('MediaMojit.list_attachments.view.LBL_COMPLETE') + ': ' + file.name);\n window.setTimeout(function() { jqNoticeDiv.hide(); }, 800);\n\n\n // reload the list of attachments (will update display)\n Y.doccirrus.media.clearCache(ownerCollection, ownerId);\n requestAttachmentsList(newMediaId);\n }\n\n Y.log( 'Checking upload of type: ' + file.type, 'debug', NAME );\n\n var category = Y.doccirrus.media.types.getCategory( file.type );\n if ( -1 === allowCategories.indexOf( category ) && 'unknown' !== category ) {\n Y.log( 'Blocked: file is of category: ' + category + ', allowed categories: ' + JSON.stringify( allowCategories ), 'warn', NAME );\n $( '#' + divId ).html( 'Bitte eine Datei vom Typ wählen:<br/> ' + listAllowedExt().join( ', ' ) );\n\n // fade this out after a few seconds\n window.setTimeout( function() { $( '#' + divId ).fadeOut(); }, 5000 );\n return;\n }\n\n Y.log( 'Recognized file as belonging to category: ' );\n Y.doccirrus.media.uploadFile(ownerCollection, ownerId, label, file, onFileUploaded);\n }", "function onDrop(acceptedFiles, rejectedFiles) {\n // do stuff with files...\n}", "function dropHandler(ev) {\n ev.preventDefault();\n for (const file of ev.dataTransfer.files) {\n addFile(gallery, file);\n overlay.classList.remove(\"draggedover\");\n counter = 0;\n }\n}", "async function onDrop(event) {\n // Prevent default behavior (Prevent file from being opened)\n event.preventDefault();\n\n if (event.dataTransfer.files) {\n onFilesDroppedOrSelected(event.dataTransfer.files);\n } else {\n console.log(`Your browser does not support FileList`);\n }\n}", "function handleFileSelect(evt) {\n evt.stopPropagation();\n evt.preventDefault();\n // Get the FileList object that contains the list of files that were dropped\n const files = evt.dataTransfer.files;\n // this UI is only built for a single file so just dump the first one\n file = files[0];\n const imageId = cornerstoneWADOImageLoader.wadouri.fileManager.add(file);\n loadAndViewImage(imageId);\n }", "function imagesDropped() {\n addDroppedFiles();\n}", "onDrop(files) {\n if (files.length > 0) {\n // Update the file state and\n // call `getImageWithDND` after \n // setState (which is async) completes\n this.setState({ file: files[0] }, this.getImageWithDND);\n }\n }", "function handleDrop(e, ui){\n\t\tvar selected_src = ui.draggable.attr('src');\n\t\t$('#ui_display').attr(\"src\", selected_src);\n\t\tui.helper.hide();\n\t\t\n\t}", "_onShowDeletedClicked(e) {\n e.preventDefault();\n e.stopPropagation();\n\n /*\n * Replace the current contents (\"This file was deleted ... \") with a\n * spinner. This will be automatically replaced with the file contents\n * once loaded from the server.\n */\n $(e.target).parent()\n .html('<span class=\"djblets-o-spinner\"></span>');\n\n this.trigger('showDeletedClicked');\n }", "function readfiles(files) {\n for (var i = 0; i < files.length; i++) {\n var imagename = files[i].name;\n var imagepath = \"\";\n if (readExtension(files[i].name)) {\n DraggedFiles.push(files[i]);\n imagepath = \"img/001-pdf.png\";\n } else {\n discardedFileListDragnDrop.push(files[i].name);\n imagepath = \"img/004-warning.png\";\n }\n var imgListelement = '<div class=\"imgcontainer\">';\n imgListelement = imgListelement + '<img src=' + imagepath + ' class=\"blockfile\" title=\"' + imagename + '\">';\n imgListelement = imgListelement + '<img src=\"img/recycling.png\" class=\"blockdeleteIcon\" title=\"' + imagename + '\"onclick=\"removeImage(\\'' + escape(imagename) + '\\',' + imgid + ')\">';\n imgListelement = imgListelement + '</div>';\n imgList.push(imgListelement);\n imgid = imgid + 1;\n }\n \n $('#drop-zone').html(imgList);\n if (discardedFileListDragnDrop.length > 0) {\n $('#msg-for-drop-zone').addClass(\"red\");\n $('#msg-for-drop-zone').html('<p><strong> Sorry we\\'re unable to process following files</strong><ul>' + makeArrayList(discardedFileListDragnDrop) + '</ul></span></p>');\n $('#msg-for-drop-zone').css('visibility', 'visible');\n }\n}", "function handleDrop(e) {\n // create an event.dataTransfer variable called dt\n let dt = e.dataTransfer;\n // set the files to process to the element's dataTransfer files\n var files = Array.from(dt.files);\n let titleArray = [];\n files.forEach((el) => {\n titleArray.push(el.name);\n })\n // loop through the files (if there are multiple)\n for (let i = 0; i < files.length; i++) {\n // set a unique file key\n // once again, this is in XML since that's what SVGs really are at the core\n var FILE_KEY = 'file-' + i + '.xml';\n // set up a new FileReader\n var reader = new FileReader();\n // set the specific file we're looking at to the ith file in the file list\n var file = files[i];\n // use the FileReader to read the selected file as plaintext\n reader.readAsText(file);\n // when the reader has loaded the file\n reader.onload = function(event) {\n // set the save variable to the plaintext file\n var save = event.target.result;\n // save the file with its key in sessionStorage\n window.sessionStorage.setItem(FILE_KEY, save);\n // use the download and convert functions to save the file\n // notice the filename: it's the original filename plus \"-fixed\" before the .SVG extension\n download(titleArray[i].slice(0, -4) + \"-fixed.svg\", convert(FILE_KEY));\n };\n }\n}", "function deleteThisFile () {\n // only hide the file\n $thisFile.hide();\n // trigger a file deletion operations\n self.emit('_deleteFile', $thisFile.find(ps).text(), function(err) {\n // show back the file on error or remove on success\n if (err) {\n $thisFile.fadeIn();\n } else {\n $thisFile.remove();\n }\n });\n }", "function FileSelectHandler(e) {\n\n // cancel browser events and remove hover style\n FileDragHover(e);\n\n // gets a FileList object containing dropped files\n var files = e.originalEvent.dataTransfer.files;\n //alert(files.item(0).name.toString());\n \n UploadFile(files.item(0));\n }", "addedfile (file) {\n if (this.element === this.previewsContainer) this.element.classList.add(\"dz-started\");\n if (this.previewsContainer && !this.options.disablePreviews) {\n file.previewElement = $3ed269f2f0fb224b$export$2e2bcd8739ae039.createElement(this.options.previewTemplate.trim());\n file.previewTemplate = file.previewElement; // Backwards compatibility\n this.previewsContainer.appendChild(file.previewElement);\n for (var node of file.previewElement.querySelectorAll(\"[data-dz-name]\"))node.textContent = file.name;\n for (node of file.previewElement.querySelectorAll(\"[data-dz-size]\"))node.innerHTML = this.filesize(file.size);\n if (this.options.addRemoveLinks) {\n file._removeLink = $3ed269f2f0fb224b$export$2e2bcd8739ae039.createElement(`<a class=\"dz-remove\" href=\"javascript:undefined;\" data-dz-remove>${this.options.dictRemoveFile}</a>`);\n file.previewElement.appendChild(file._removeLink);\n }\n let removeFileEvent = (e)=>{\n e.preventDefault();\n e.stopPropagation();\n if (file.status === $3ed269f2f0fb224b$export$2e2bcd8739ae039.UPLOADING) return $3ed269f2f0fb224b$export$2e2bcd8739ae039.confirm(this.options.dictCancelUploadConfirmation, ()=>this.removeFile(file)\n );\n else {\n if (this.options.dictRemoveFileConfirmation) return $3ed269f2f0fb224b$export$2e2bcd8739ae039.confirm(this.options.dictRemoveFileConfirmation, ()=>this.removeFile(file)\n );\n else return this.removeFile(file);\n }\n };\n for (let removeLink of file.previewElement.querySelectorAll(\"[data-dz-remove]\"))removeLink.addEventListener(\"click\", removeFileEvent);\n }\n }", "function handleFileDrop(event, ui){ \n var appointmentID = this.getAttribute( 'appointmentID' );\n var fileID = ui.draggable.attr( 'fileID' );\n /*\n //Get the data from the div that was dropped to the appointment\n var FirstName=ui.draggable.attr('FirstName');\n var LastName= ui.draggable.attr('LastName');\n \n var StreetNumber=ui.draggable.attr('StreetNumber');\n var StreetName=ui.draggable.attr('StreetName');\n var City=ui.draggable.attr('City');\n var Province=ui.draggable.attr('Province');\n var PostalCode=ui.draggable.attr('PostalCode');\n */\n var getString=\"FileID=\"+fileID;//+\"&FirstName=\"+FirstName+\"&LastName=\"+LastName+\"&StreetNumber=\"+StreetNumber+\"&StreetName=\"+StreetName+\"&City=\"+City+\"&Province=\"+Province+\"&PostalCode=\"+PostalCode; \n\t \t \n\t \n\t getString = strReplace(getString, ' ', \"\\\\s\");\n disable(ui.draggable);\n \n $(this).append($(\"<div class='droppedContainer' DroppedID='\"+fileID+\"'>\").load(\"php/view/AppointmentAssignment/FilesFoundDiv/DroppedFile.php?\"+getString, function(){\n DropRefresh();\n submitFile(fileID, appointmentID);\n //setInitialFocus(); \n }));\n \n \n }", "function fileDrop(ev) {\n upload.files = ev.dataTransfer.files;\n ev.preventDefault(); \n}", "function displayFile(file) {\n document.getElementById('name').textContent = file.fileName;\n document.getElementById('size').textContent = file.fileSize;\n document.getElementById('file-content').style.border = \"1px solid black\";\n\n var reader = new FileReader();\n\n reader.onload = function(event) {\n document.getElementById('file-content').textContent = \n event.target.result;\n };\n\n reader.onerror = function() {\n document.getElementById('file-content').innerHTML = 'Unable to read ' + file.fileName;\n };\n\n reader.readAsText(file);\n }", "function handleFileSelect(mEvent) {\n mEvent.stopPropagation();\n mEvent.preventDefault();\n\n files = mEvent.dataTransfer.files; // FileList object.\n\n //List some properties.\n document.getElementById('list').innerHTML =\n '<p><strong>' + files[0].name + '</strong> - ' +\n files[0].size + ' bytes, last modified: ' +\n (files[0].lastModifiedDate ? files[0].lastModifiedDate.toLocaleDateString() : 'n/a') +\n '</p>';\n\n var add = addElements();\n\n startDrawing = true;\n\n}", "function show(file) {\n console.log('-'.repeat(10));\n console.log(`Содержимое файлы ${file.name}:`);\n console.log(file.content);\n console.log('-'.repeat(10));\n}", "function display_file_name(event) {\n // alert(event.fpfile.filename );\n $('.uploaded_file_name').text(event.fpfile.filename)\n}", "function manejadorDrop(event) {\n event.preventDefault();\n event.stopPropagation();\n document.getElementById('zonaArrastre').classList.remove('is-primary'); \n\n if (event.dataTransfer.files.length > 0) {\n mostrarInfoDeArchivos(event.dataTransfer.files);\n }\n else {\n alert(\"Tiene que traer un archivo de su computadora\");\n return;\n }\n\n}", "onDrop(files){\n console.log('Received files: ', files);\n this.setState({\n files: files\n });\n }", "function handleFile(path) {\n console.log('Dropped File: ', path);\n // Sends the file path to the Main process\n ipcRenderer.send('set-file', path);\n\n // Gets the file name only\n var file = Path.basename(path);\n\n // Hides the options to choose a file\n $('#chooseFileSection').hide();\n // Shows the preview section\n $('#previewSection').transition('fade down');\n\n // Enables the buttons\n $('#inputStepNext').removeClass('disabled');\n $('#inputStepClear').removeClass('disabled');\n\n // Clears the preview\n $('#previewHeader').empty();\n $('#previewContent').empty();\n $('#preview').removeClass('placeholder');\n\n // Sets the preview\n $('#previewHeader').append('<h3>Preview of: \\'' + file + '\\'</h3>');\n fs.readFile(path, function (err, data) {\n if (err) {\n console.log(err);\n }\n if (data) {\n $('#previewContent').append('<pre>' + data + '</pre>');\n }\n })\n}", "function handleFileSelect(evt) {\n evt.stopPropagation();\n evt.preventDefault();\n\n var files = evt.dataTransfer.files; // FileList object.\n\n // files is a FileList of File objects. List some properties.\n var output;\n for (var i = 0, f; f = files[i]; i++) {\n output=f.name;\n }\n document.getElementById('textarea').value = output;\n }", "onDrop(evt) {\n evt.preventDefault();\n const { onComplete, multiple, output, onError } = this.props;\n const files = Array.from(evt.dataTransfer.files).filter((file) => {\n if (output && outputs[output])\n return file.type === outputs[output].mimeType;\n return true;\n });\n if (files.length)\n Promise.all(files.map(file => this.readFile(file)))\n .then(results => this.output(results))\n .catch(err => onError(err));\n else\n onComplete(multiple ? [] : null);\n }", "function handleFileBrowse(evt){\n\tvar files = evt.target.files;\n\t\n\tvar output = [];\n\tfor (var i=0, f; f = files[i]; i++){\n\t\t//build the HTML list output\n\t\toutput.push('<li><strong>', escape(f.name), '</strong> (', f.type || 'n/a', ') - ',\n\t\tf.size, ' bytes, last modified: ',\n\t\tf.lastModifiedDate ? f.lastModifiedDate.toLocaleDateString() : 'n/a', '</li>');\n\t};\n\tdocument.getElementById('list').innerHTML = '<ul>' + output.join('') + '</ul>';\n}", "function visualizeUploadedFiles() {\n fs.readFile('uploadedFiles.jade', function (err, template) {\n if (err) {\n res.end(err);\n return;\n }\n\n fs.readdir('uploaded', function (error, files) {\n if (error) {\n resp.end(error);\n return;\n }\n\n let output = jade.compile(template)({\n files: files\n });\n\n res.writeHead(200, {'Content-Type': 'text/html'});\n res.write(output);\n res.end();\n })\n });\n }", "function onArtifactFileChange() {\n // Show the name of the file\n if (this.files.length > 0) {\n $('#labelArtifactFile').text(this.files[0].name);\n }\n}", "function trashDrop() {\n // createCanvas(1000, 1000);\n var trashBin;\n trashBin = createDiv('🗑️');\n trashBin.style('font-size', '48px');\n trashBin.dragOver(trashHover);\n trashBin.dragLeave(trashUnhover);\n trashBin.drop(throwInTrash, trashUnhover);\n}", "function file_drag_start(){\n\n\tdrag_flag();\n\n}", "function handleDrop(event) {\n event.stopPropagation();\n event.preventDefault();\n dropArea.removeClass(\"hover\");\n processFiles(event.dataTransfer.files);\n }", "function onFileSelection(e) {\n\tvar files = e.target.files;\n\tvar output = [];\n\ttotFileCount = files.length;\n\ttotFileLength = 0;\n\tfor (var i = 0; i < totFileCount; i++) {\n\t\tvar file = files[i];\n\t\toutput.push(file.name, ' (', file.size, ' bytes, ',\n\t\t\tfile.lastModifiedDate.toLocaleDateString(), ')');\n\t\toutput.push('<br/>');\n\t\tdebug('add ' + file.size);\n\t\ttotFileLength += file.size;\n\t}\n\tdocument.getElementById('selectedFiles').innerHTML = output.join('');\n}", "function drop(ev) {\n ev.preventDefault();\n var data = ev.dataTransfer.getData(\"text\");\n if (ev.target.tagName == \"CANVAS\") {\n moveAndDrawImageToCanvas(document.getElementById(data), ev.target)\n } else {\n ev.target.appendChild(document.getElementById(data));\n }\n}", "function displaySingleSelection(fileName) {\n var baseName = fileName.replace(/^.*[\\/\\\\]/, \"\");\n $(\".upload-filelist\").empty();\n $(\".upload-filelist\").append($(\"<li/>\").text(baseName));\n }", "function dragDropVisual () {\n // Start the drag effect\n $('.drop-zone').on('dragover', function (e) {\n e.preventDefault()\n e.stopPropagation()\n $(this).addClass('dragover')\n })\n\n // Stop the effect when mouse out/release\n $('.drop-zone').on('dragleave dragend', function (e) {\n e.preventDefault()\n e.stopPropagation()\n $(this).removeClass('dragover')\n })\n\n // Stop when successfully dropped\n $('.drop-zone').on('drop', function (e) {\n e.stopPropagation()\n e.preventDefault()\n $(this).removeClass('dragover')\n\n // we're interested in just first file\n var files = e.originalEvent.dataTransfer.files\n for (var i = 0; i < files.length; i++) {\n parseImport(files[i])\n }\n })\n}", "function fileDropzoneLeftCallback() {\n var overlayElement = this.widget.domNode.querySelector('.' + DROP_OVERLAY_CSS_CLASS);\n overlayElement.style.display = 'none';\n }", "drop(evt) {\n evt.preventDefault();\n var data = evt.dataTransfer.getData(\"text\");\n var fromIdx = document.getElementById(data).attributes[0].nodeValue;\n\n this.reorderImages(fromIdx, this.toIdx);\n }", "function onDragOver(event) {\n // Prevent default behavior (Prevent file from being opened)\n event.preventDefault();\n event.dataTransfer.dropEffect = 'copy';\n}", "function handleDrop(e) {\n e.stopPropagation();\n e.preventDefault();\n var files = e.dataTransfer.files;\n var i,f;\n for (i = 0, f = files[i]; i != files.length; ++i) {\n var reader = new FileReader();\n var name = f.name;\n reader.onload = function(e) {\n var data = e.target.result;\n\n /* if binary string, read with type 'binary' */\n var workbook = XLSX.read(data, {type: 'binary'});\n\n /* DO SOMETHING WITH workbook HERE */\n\t\t\tprocessExcelFile(workbook);\n\t\t\tDOMElement = $('#fileName')[0].value = \"\";\n\t\t\t// console.log(e.target.value);\n };\n reader.readAsBinaryString(f);\n }\n}", "function showErrorFile() {\n filewrapper.style.display = 'block'\n filename.innerHTML = 'File type not supported'\n filewrapper.style.color = 'red'\n}", "function hideFiles() { showFiles(true,this); }", "function dropFile(element, file) {\n var evt = document.createEvent('Event');\n evt.initEvent('drop', true, true)\n evt.dataTransfer = {\n files: [file]\n }\n element.dispatchEvent(evt, true)\n}", "checkDropItem (e) {\n if (e.dataTransfer.files.length) {\n let file = e.dataTransfer.files[0];\n let ext = LGraphCanvas.getFileExtension(file.name).toLowerCase();\n let nodetype = LiteGraph.node_types_by_file_extension[ext];\n if (nodetype) {\n let node = LiteGraph.createNode(nodetype.type);\n node.pos = [e.canvasX, e.canvasY];\n this.d_graph.add(node);\n if (node.onDropFile)\n node.onDropFile(file);\n }\n }\n }", "function dropImageFromFile(e) {\n e.stopPropagation();\n e.preventDefault();\n const regex = /image.*/;\n const imageUrl = e.dataTransfer.getData('text');\n const files = e.dataTransfer.files;\n\n //== drop image from a URL ==//\n if (imageUrl) {\n if (imageUrl.match(regex) !== null) {\n img.src = imageUrl\n filewrapper.style.display = 'block'\n filewrapper.style.color = 'green'\n filename.innerHTML = imageUrl.slice(15, 40)\n showDropIcon();\n } else {\n //showErrorFile();\n showErrorFileCors();\n hideDropIcon();\n }\n\n //== drop image from device or storage ==//\n } else if (files) {\n for (let i = 0, file; file = files[i]; i++) {\n let reader = new FileReader();\n reader.addEventListener(\"load\", function (targetFile) {\n img.src = targetFile.target.result;\n }, false);\n\n if (file.type.match(regex)) {\n reader.readAsDataURL(file);\n showFileContent(file);\n showDropIcon();\n\n } else {\n showErrorFile();\n hideDropIcon();\n }\n }\n }\n}", "onDrop(files) {\n this.setState({\n image: files[0].preview\n });\n console.log(files);\n }", "function DropFileHere(/**string*/ fileName, /**objectId*/ dropElement)\n{\n\tvar JS_DROP_FILE =\n\t\t\"var target = arguments[0],\" +\n\t\t\" offsetX = arguments[1],\" +\n\t\t\" offsetY = arguments[2],\" +\n\t\t\" document = target.ownerDocument || document,\" +\n\t\t\" window = document.defaultView || window;\" +\n\t\t\"\" +\n\t\t\"var input = document.createElement('INPUT');\" +\n\t\t\"input.type = 'file';\" +\n\t\t\"input.style.display = 'none';\" +\n\t\t\"input.onchange = function () {\" +\n\t\t\" var rect = target.getBoundingClientRect(),\" +\n\t\t\" x = rect.left + (offsetX || (rect.width >> 1)),\" +\n\t\t\" y = rect.top + (offsetY || (rect.height >> 1)),\" +\n\t\t\" dataTransfer = { files: this.files };\" +\n\t\t\"\" +\n\t\t\" ['dragenter', 'dragover', 'drop'].forEach(function (name) {\" +\n\t\t\" var evt = document.createEvent('MouseEvent');\" +\n\t\t\" evt.initMouseEvent(name, !0, !0, window, 0, 0, 0, x, y, !1, !1, !1, !1, 0, null);\" +\n\t\t\" evt.dataTransfer = dataTransfer;\" +\n\t\t\" target.dispatchEvent(evt);\" +\n\t\t\" });\" +\n\t\t\"\" +\n\t\t\" setTimeout(function () { document.body.removeChild(input); }, 25);\" +\n\t\t\"};\" +\n\t\t\"document.body.appendChild(input);\" +\n\t\t\"return input;\";\n\n\ttry\n\t{\n\t\tvar obj = SeS(dropElement);\n\t\tvar input = WebDriver.ExecuteScript(JS_DROP_FILE, [obj.element.e, 25, 25]);\n\t\tinput.SendKeys(fileName);\n\t}\n\tcatch(e)\n\t{\n\t\tTester.Message('Problem with file upload: ' + e.message);\n\t\treturn false;\n\t}\n\n\t// Wait for input to disappear after file upload\n\tvar count = 60;\n\twhile(true)\n\t{\n\t\ttry\n\t\t{\n\t\t\tinput.GetEnabled();\n\t\t\tGlobal.DoSleep(1000);\n\t\t\tcount--;\n\t\t\tif (count == 0)\n\t\t\t{\n\t\t\t\tTester.Message('File upload timeout of ' + count + ' seconds');\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\tcatch(e)\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t}\n\t\n\treturn false;\n}", "function gotFile(file) {\n createDiv(\"<h1>\"+file.name+\"</h1>\").class(tabNumber).parent(\"left\");\n\n // Handle image and text differently\n if (file.type === 'image') {\n createImg(file.data);\n } \n else if (file.type === 'text') {\n tabs[file.name] = new Tab(file.name, tabNumber);\n switchTab(file.name, tabNumber);\n analyzeText(file, tabNumber);\n }\n}", "function FileDropHandle(e) {\n\t\te.stopPropagation();\n\t\te.preventDefault();\n\t\tvar className=e.target.className;\n\t\tif(className.indexOf(\"hover\")!=-1) {\n\t\tclassName=className.replace(\"hover\",\"\");\n\t\te.target.className=className;\n\t\t}\n\t\tvar files = e.target.files || e.dataTransfer.files;\n\t\tif (validate(files[0]) == false) {\n\t\t\tshowMessageError();\n\t\t\treturn;\n\t\t} else {\n\t\t\tfileUpload = files[0];\n\t\t}\n\t\tuploadFile();\n\t}", "function file_selected( e ) {\n\tif( e.files.length == 1 ) {\n\t\t$('#upload_button').button('enable');\n\t\t$('#new_file_name_container').html( '<span id=\"new_file_name\">' + e.files[0].name + '</span>' );\n\t} else {\n\t\t$('#upload_button').button('disable');\n\t\t$('#new_file_name_container').html( '(Use \\'pick file\\' to select a tradition file to upload.)' );\n\t}\n}", "function dragtaskStart(ev) {\n ev.dataTransfer.setData(\"text/plain\", ev.target.id);\n}", "function fileSelected(file) {\n // Clear file selection listeners\n const reportSelector = document.getElementById('report_file_input');\n reportSelector.removeEventListener('change', fileInputValueChanged);\n const dropArea = document.getElementById('drop_target');\n dropArea.removeEventListener('dragover', dragoverEvent);\n dropArea.removeEventListener('drop', dropEvent);\n document.getElementById('report_upload').hidden = true;\n document.getElementById('loading').hidden = false;\n document.getElementById('local_file').innerText = file.name;\n const fileReader = new FileReader();\n fileReader.addEventListener('load', () => {\n const statistics = JSON.parse(fileReader.result);\n document.getElementById('loading').hidden = true;\n document.getElementById('viewer').hidden = false;\n allStatistics = statistics;\n reloadStatistics();\n });\n fileReader.readAsText(file);\n}", "function displayFiles() {\n // clear current file list\n $(\".file-names\").remove();\n\n // populate visual file list\n for (var i = 0; i <= files.length - 1; i++) { \n $(\"#filebar\").append('<div id=\"file-button_' + i + '\"class=\"file-names\">' + files[i].name + '</div>');\n };\n\n // load file on clicking the div/tab\n $(\".file-names\").click(function () {\n var name = $(this).attr(\"id\");\n var fileNumber = name.substr(name.lastIndexOf('_') + 1);\n sidebarFileLoad(fileNumber);\n });\n}", "function dragOver(e) {\n if (_isDraggingFile) {\n e.preventDefault();\n }\n }", "_placeHolderFileDrop(e) {\n // reference the active place holder element since place holders are\n // the only things possible for seeing these\n HAXStore.activePlaceHolder = e.detail.placeHolderElement;\n // ! I can't believe this actually works. This takes the event\n // ! that was a drop event else where on the page and then repoints\n // ! it to simulate the drop event using the same event structure that\n // ! would have happened if they had used this element in the first place\n this.shadowRoot.querySelector(\"#fileupload\")._onDrop(e.detail);\n }", "function drop(ev) {\n ev.preventDefault();\n var datos=ev.dataTransfer.getData(\"text\");\n ev.target.appendChild(document.getElementById( datos));\n var destino = ev.target.id\n console.log(\"destino: \"+destino);\n console.log(\"objeto: \"+datos);\n edit_Kanban(destino, datos)\n ev.stopPropagation();\n}", "function showFile(file){\n let fileType = file.type;\n \n //? adding some valid image extensions in array\n let validExtensions = [\"image/jpeg\", \"imgae/jpg\", \"image/png\"]; \n\n if(validExtensions.includes(fileType)){\n //? if user selected file is an image file\n\n //? creating new FileReader object\n let fileReader = new FileReader(); \n\n fileReader.onload = () => {\n //? passing user file source is fileURL variable\n // console.log(fileReader)\n let fileURL = fileReader.result;\n // console.log(fileURL);\n\n //? creating an img tag and padding user selected file source inside src attribute\n let imgTag = `<img src=\"${fileURL}\" alt=\"\">`;\n dropArea.innerHTML = imgTag; \n }\n fileReader.readAsDataURL(file);\n dropArea.classList.add('active');\n }else{\n alert(\"This is an not Image File\")\n dropArea.classList.remove('active');\n }\n}", "function reset() {\n \n $('#btnParser').hide();\n $('#fileName').text('Drag workorder file here');\n $('#dropTarget').removeClass('bg-drop');\n \n}", "_placeHolderFileDrop(e) {\n // reset the manager back to the first page\n this.resetManager();\n // trigger a self open request\n this.open();\n // reference the active place holder element since place holders are\n // the only things possible for seeing these\n window.HaxStore.instance.activePlaceHolder = e.detail.placeHolderElement;\n this.editExistingNode = true;\n // ! I can't believe this actually works. This takes the event\n // ! that was a drop event else where on the page and then repoints\n // ! it to simulate the drop event using the same event structure that\n // ! would have happened if they had used this element in the first place\n this.shadowRoot.querySelector(\"#fileupload\")._onDrop(e.detail);\n }", "onDrop(e) {\n e.preventDefault();\n\n // Loop through array of files and upload each file\n if (e.dataTransfer && e.dataTransfer.files && e.dataTransfer.files.length > 0) {\n // eslint-disable-next-line no-plusplus,no-cond-assign\n for (let i = 0, f; f = e.dataTransfer.files[i]; i++) {\n document.querySelector('.media-dragoutline').classList.remove('active');\n this.upload(f);\n }\n }\n document.querySelector('.media-dragoutline').classList.remove('active');\n }", "function drop(ev) {\n // Prevenimos su comportamiento por defecto\n ev.preventDefault();\n // Hacemos que el evento reciba un dato (\"informacion\")\n var data = ev.dataTransfer.getData(\"Informacion\");\n // Si el elemento que hemos soltado era la bola\n if(data==\"bola\"){\n document.getElementById(\"papelera\").src=\"papeleraLLena.jpg\";\n }\n}", "function showFileContent(file) {\n filewrapper.style.display = 'block'\n filename.innerHTML = file.name\n filewrapper.style.color = 'green'\n filewrapper.classList.add('animation');\n}", "function handleDragOver(evt){\n\tevt.stopPropagation();\n\tevt.preventDefault();\n\tevt.dataTransfer.dropEffect = 'copy'; \n\t//This basically makes the dropped file a copy of the original\n}", "function fileDropzoneEnteredCallback() {\n var overlayElement = this.widget.domNode.querySelector('.' + DROP_OVERLAY_CSS_CLASS);\n overlayElement.style.display = 'block';\n }", "function setupDragDropListener(obj){\n obj.addEventListener(\"dragover\", fileDragHover, false);\n obj.addEventListener(\"dragleave\", fileDragHover, false);\n obj.addEventListener(\"drop\", fileSelectHandler, false);\n obj.style.display = \"block\";\n }", "function uploadOnChange() {\n var input = document.getElementById('file_btn_comment');\n var output = document.getElementById('display_file_comment');\n output.innerHTML = '<ul> Selected File :';\n for (var i = 0; i < input.files.length; ++i) {\n output.innerHTML += '<li>' + input.files.item(i).name + '</li>';\n }\n output.innerHTML += '</ul>';\n output.style.display = 'block';\n var cancelBtn = document.getElementById('cancel_btn_comment');\n\n cancelBtn.addEventListener('click', function () {\n output.style.display = 'none';\n })\n}", "function onPostAttachmentDrop( event ){\n ctrl.addAttachments( event.dataTransfer.files );\n }", "function onDrop() {\n\t\tobject.style.display = \"none\";\n\n\t\tvar\n\t\telement = document.elementFromPoint(onDrag.x, onDrag.y),\n\t\tevent = hasListener ? document.createEvent(\"MouseEvent\") : document.createEventObject();\n\n\t\tevent.MsDataTransfer = new DataTransfer(arguments);\n\n\t\thasListener && event.initMouseEvent(\"drop\", true, true, document.defaultView, 1, 0, 0, 0, 0, false, false, false, false, 0, null);\n\n\t\thasListener ? element.dispatchEvent(event) : element.fireEvent(\"ondrop\", event);\n\n\t\tonDrop.active = false;\n\t}", "function onFileSelect(e) {\r\n\tvar bar = document.getElementById('bar');\r\n\tbar.style.width = 0 + '%';\r\n\tbar.innerHTML = 0 + ' % complete';\r\n\r\n\tvar files = e.target.files; // FileList object\r\n\tvar output = [];\r\n\tfileCount = files.length;\r\n\ttotalFileLength = 0;\r\n\tfor (var i = 0; i < fileCount; i++) {\r\n\t\tvar file = files[i];\r\n\t\toutput.push(file.name, ' (', file.size, ' bytes, ', file.lastModifiedDate.toLocaleDateString(), ')');\r\n\t\toutput.push('<br/>');\r\n\t\tdebug('add ' + file.size);\r\n\t\ttotalFileLength += file.size;\r\n\t}\r\n\t// document.getElementById('selectedFiles').innerHTML = output.join('');\r\n\tdebug('totalFileLength:' + totalFileLength);\r\n}", "async function handleFileDrop(event, canvas) {\n event.preventDefault();\n const items = []\n // First, convert that ugly object to a proper array\n for (let i = 0; i < event.dataTransfer.items.length; ++i) {\n items.push(event.dataTransfer.items[i]);\n }\n // Select only the files\n const files = items\n .filter(item => item.kind === 'file')\n .map(item => item.getAsFile());\n console.log(`${files.length} files dropped`);\n\n // Parse the files\n const instances = await Promise.all(files.map(file => makeInstance(file)));\n const [volume, ...rest] = findVolume(instances);\n const camera = initCamera(volume, 'CORONAL');\n drawMPR(volume, camera, canvas);\n}", "showDrag() {\n this.setState({ upload: true, showTeam: false, files: [] });\n }", "function renderFile(file) {\n var fileDiv = document.createElement(\"div\");\n fileDiv.classList = \"fileEntry text-center\";\n fileDiv.innerHTML = `\n <h3> ` + file.name.slice(0, file.name.length - 4) + `<h3>\n `\n fileList.appendChild(fileDiv);\n}" ]
[ "0.72894186", "0.727713", "0.7140937", "0.7077785", "0.69156796", "0.6882988", "0.68160087", "0.67447686", "0.6662817", "0.6625142", "0.65877557", "0.6571451", "0.6544129", "0.6541286", "0.6481612", "0.64540297", "0.64540064", "0.6381019", "0.63696617", "0.63520384", "0.63464874", "0.6277382", "0.62742084", "0.6264842", "0.62601256", "0.62329537", "0.6198175", "0.6178935", "0.6161829", "0.6159207", "0.615836", "0.61539006", "0.6142444", "0.6124535", "0.61233187", "0.6117615", "0.61076015", "0.6103305", "0.60947", "0.6080489", "0.6068612", "0.6068458", "0.6059156", "0.60585904", "0.6049553", "0.60471666", "0.60310245", "0.602482", "0.60134584", "0.60079944", "0.59948534", "0.5994624", "0.5985497", "0.59853923", "0.59709316", "0.5964435", "0.5960499", "0.5908829", "0.5902029", "0.5892672", "0.58892286", "0.58874387", "0.58690596", "0.5863947", "0.5849631", "0.584478", "0.5840477", "0.5821298", "0.58199257", "0.58149475", "0.5812913", "0.58049357", "0.5796203", "0.57926327", "0.5763706", "0.5759229", "0.5749894", "0.5747664", "0.57473874", "0.5741087", "0.5732397", "0.57180107", "0.57152176", "0.57085055", "0.5702131", "0.56986606", "0.5689722", "0.56885964", "0.5676041", "0.56724846", "0.5669611", "0.56649727", "0.5664358", "0.5662389", "0.5661243", "0.56570846", "0.56545746", "0.56513005", "0.5627257", "0.5624455", "0.56203246" ]
0.0
-1
Creates an instance of Updater.
constructor(messenger) { // Initialize. this.autoUpdater = autoUpdater this.messenger = messenger // Wire events. // @see https://www.electron.build/auto-update console.log('asdf') this.autoUpdater.on('checking-for-update', (e, i) => { this.messenger.info('Checking for update.') }) this.autoUpdater.on('download-progress', (e, i) => { // tslint:disable-next-line:no-console console.log('autoUpdater: download-progress: ', e, i) }) this.autoUpdater.on('update-available', (e, i) => { // tslint:disable-next-line:no-console console.log('autoUpdater: update-available: ', e, i) this.messenger.info( 'A new version is available. Downloading in background.' ) }) this.autoUpdater.on('update-not-available', (e, i) => { // tslint:disable-next-line:no-console console.log('autoUpdater: update-not-available: ', e, i) this.messenger.info('Your application is up to date.') }) this.autoUpdater.on('update-downloaded', (e, i) => { this.messenger.info('An update was downloaded.') this.quitAndInstall() }) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function updateFactory(model){\n new update(model)\n}", "promoteUpdater() {}", "initialize(){this._saveInstanceProperties();// ensures first update will be caught by an early access of\n// `updateComplete`\nthis._requestUpdate()}", "update(updater) {\n if (typeof updater === \"function\") {\n this.data = updater(this.data);\n } else {\n this.data = Object.assign({}, this.data, updater);\n }\n\n this.persist();\n }", "function IntegrationUpdateBase() {\n _classCallCheck(this, IntegrationUpdateBase);\n\n IntegrationUpdateBase.initialize(this);\n }", "initialize(){// ensures first update will be caught by an early access of\n// `updateComplete`\nthis._saveInstanceProperties(),this._requestUpdate()}", "constructor() { \n IntegrationUpdateBase.initialize(this);AndroidUpdateAllOf.initialize(this);\n AndroidUpdate.initialize(this);\n }", "function createInstance() {\n var api = extendApi(nouislider__WEBPACK_IMPORTED_MODULE_1___default.a.create(htmlElement, options));\n setCreatedWatcher(api);\n setOptionsWatcher(api);\n\n if (ngModel !== null) {\n bindNgModelControls(api);\n }\n } // Wait for ngModel to be initialized", "configure(...args) {\n this.instance = new OptimizelyManager(...args);\n }", "initialize() {\n this._saveInstanceProperties();\n // ensures first update will be caught by an early access of\n // `updateComplete`\n this._requestUpdate();\n }", "initialize() {\n this._saveInstanceProperties();\n // ensures first update will be caught by an early access of\n // `updateComplete`\n this._requestUpdate();\n }", "static create(config) {\n let $config = new Configuration(config.doc ? config.doc.type.schema : config.schema, config.plugins);\n let instance = new EditorState($config);\n for (let i = 0; i < $config.fields.length; i++)\n instance[$config.fields[i].name] = $config.fields[i].init(config, instance);\n return instance;\n }", "constructor() { \n \n MailgunUpdateAllOf.initialize(this);\n }", "constructor() { \n \n IssueUpdateDetails.initialize(this);\n }", "static create () {}", "async createOrUpdate () {\n\t\tif (this.existingModel) {\n\t\t\tawait this.update();\n\t\t}\n\t\telse {\n\t\t\tawait this.create();\n\t\t}\n\t}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n }", "async update() {\n if ( !this._inited ) {\n await this.init()\n }\n\n if ( !this.enabled || !this.canUpdate) {\n return;\n }\n\n await this.broadcast('onUpdate');\n await this.broadcast('onAfterUpdate', this.canUpdate);\n\n return this;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "setup() {\n /**\n * The last time at which this structure was updated, as an epoch timestamp.\n * @type {number}\n */\n this.updated = Date.now();\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n }", "initialize(){this._updateState=0;this._updatePromise=new Promise(res=>this._enableUpdatingResolver=res);this._changedProperties=new Map();this._saveInstanceProperties();// ensures first update will be caught by an early access of\n// `updateComplete`\nthis.requestUpdateInternal();}", "update() {\n return update.call(this);\n }", "function update() {\n updaters.forEach(function (f) { f(); });\n }", "update(){}", "update(){}", "update(){}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n // If a component has string refs, we will assign a different object later.\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n // If a component has string refs, we will assign a different object later.\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n // If a component has string refs, we will assign a different object later.\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n // If a component has string refs, we will assign a different object later.\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n\t this.props = props;\n\t this.context = context;\n\t this.refs = emptyObject;\n\t // We initialize the default updater but the real one gets injected by the\n\t // renderer.\n\t this.updater = updater || ReactNoopUpdateQueue;\n\t}", "function Observer() {\n this.update = function () {\n // /* ... */\n };\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "initialize() {\n this._updateState = 0;\n this._updatePromise =\n new Promise((res) => this._enableUpdatingResolver = res);\n this._changedProperties = new Map();\n this._saveInstanceProperties();\n // ensures first update will be caught by an early access of\n // `updateComplete`\n this.requestUpdateInternal();\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "constructor(update_rate) {\n super(update_rate);\n this.client = new CoinGecko();\n }", "function DateUpdater() { }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n }", "create() {\n return this.new();\n }", "static autorun() {\n return Tracker.autorun.apply(this, arguments);\n }", "function Observer(){\n this.update = function(){\n // ...\n };\n}", "static async new(projectDir) {\n const instance = new AnnotationsDb(projectDir)\n await instance.readAnnotations()\n return instance\n }", "function Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n }", "function update() {}", "install() {\n this.listen(this.update.bind(this))\n }", "function update() {\n // ... no implementation required\n }", "initialize() {\n this.form = this.element.closest(\"form\")\n this.formSubmit = this.form.querySelector(\"input[type='submit']\")\n\n // create template from initial state\n this.buildTemplate()\n\n this.uppy = Uppy({\n id: this.element.id,\n autoProceed: true,\n allowMultipleUploads: true,\n restrictions: {\n maxNumberOfFiles: this.maxNumberOfFiles,\n allowedFileTypes: this.whitelist,\n maxFileSize: this.maxFileSize\n },\n onBeforeFileAdded: (currentFile, files) => {\n // reset uppy before a file is added\n // this.reset()\n }\n })\n .use(DragDrop, {\n target: this.dropTarget\n })\n .use(Tus, {\n endpoint: this.data.get('endpoint'),\n chunkSize: 5*1024*1024\n })\n .use(Informer, {\n target: this.infoTarget\n })\n\n // starting to upload\n // remove any eventual messages from informer\n this.uppy.on(\"upload\", (data) => {\n this.uppy.info(\"\")\n this.formSubmit.disabled = true\n })\n\n // update progress bar\n this.uppy.on(\"upload-progress\", (file, progress) => {\n this.progressHandler(file, progress)\n })\n\n // single upload succeeded\n // update file field for form and preview uploaded file\n this.uppy.on(\"upload-success\", (file, response) => {\n this.successHandler(file, response)\n })\n\n // after all uploads finished\n // reset if form was submitted automatically\n this.uppy.on(\"complete\", (result) => {\n this.formSubmit.disabled = false\n\n if (this.autoSubmit) {\n this.reset(true)\n } else {\n this.reset()\n }\n })\n }", "get updateCreate () {\n\t\treturn this._updateCreate;\n\t}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}", "function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n // We initialize the default updater but the real one gets injected by the\n // renderer.\n this.updater = updater || ReactNoopUpdateQueue;\n}" ]
[ "0.5641583", "0.4933229", "0.48488805", "0.48151898", "0.4755564", "0.47414222", "0.46838057", "0.46585783", "0.45369828", "0.45264116", "0.45264116", "0.44620517", "0.44413695", "0.44035208", "0.4378131", "0.43774065", "0.43724427", "0.43699595", "0.43699595", "0.43699595", "0.43699595", "0.43699595", "0.43699595", "0.43699595", "0.43599924", "0.4336562", "0.43347254", "0.43301648", "0.4319073", "0.43157694", "0.42960325", "0.4278382", "0.4278382", "0.4278382", "0.42655697", "0.42655697", "0.42655697", "0.42655697", "0.42579207", "0.42498952", "0.4244917", "0.4244917", "0.4244917", "0.4244917", "0.4244917", "0.4244917", "0.4244917", "0.4244917", "0.4244917", "0.4244917", "0.4244917", "0.4244917", "0.4244917", "0.4244917", "0.4244917", "0.4244917", "0.4244917", "0.4241107", "0.42249173", "0.42131808", "0.42038113", "0.41824314", "0.41790918", "0.41741028", "0.4140414", "0.4139215", "0.4138972", "0.41360283", "0.41271237", "0.41243955", "0.41201335", "0.41187376", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505", "0.41142505" ]
0.0
-1
Quits the application and installs the update.
quitAndInstall() { setTimeout(() => { this.autoUpdater.quitAndInstall() }, 5000) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async scheduleInstallOnQuit() {\n this.restart = false;\n await this._rememberInstallAttempt();\n this._setupExitHook();\n }", "function updateApplication() {\r\n\t\t\t\r\n\t\t\ttry{\r\n\t\t\t\tvar updater = new air.Updater();\r\n\t\t\t\tupdater.update(newAppFile, currentVersion);\r\n\t\t\t} catch(err) {}\r\n\t\t\t\r\n\t\t\tnativeWindow.close();\r\n\t\t} // End of updateApplication() function.", "async quitAndInstall() {\n this.restart = true;\n await this._rememberInstallAttempt();\n this._setupExitHook();\n this._quit();\n }", "_installUpdate() {\n browser.runtime.onInstalled.addListener((details) => {\n // Note that console logging doesn't work within this event.\n if (details.reason === 'install') {\n this.app.setState({\n app: {\n installed: true,\n updated: false,\n version: {\n current: chrome.runtime.getManifest().version,\n },\n },\n })\n } else if (details.reason === 'update') {\n this.app.setState({\n app: {\n installed: false,\n updated: true,\n version: {\n current: chrome.runtime.getManifest().version,\n previous: details.previousVersion,\n },\n },\n })\n }\n })\n }", "function installPrompt()\n{\n closeWindow();\n if (app.pluginInstalled() && // plugin already installed but needs upgrade\n (Callcast.pluginUpdateRequired() || Callcast.pluginUpdateAvailable()) )\n {\n // chrome can't load an upgraded plugin so prompt user to restart\n if (app.browser.name === 'Chrome')\n {\n openWindow('#chromeRestart');\n }\n else\n {\n openWindow('#pageReload');\n }\n }\n else if (app.browser.name === 'Firefox') // firefox seems to have a problem polling navigator.plugins\n // so prompt user to reload instead of polling plugins\n {\n openWindow('#pageReload');\n }\n else // no plugin installed, wait for plugin\n {\n openWindow('#winWait');\n checkForPlugin();\n //openWindow('#pageReload');\n }\n}", "async quitAndRetryInstall(allowLocal = true) {\n try {\n const info = await this._getValidUpdateInfoOnDisk();\n this.downloadedFile = info.updateFile;\n info.attempts++;\n await new Promise((fulfill, reject) => {\n fs.writeFile(this._getUpdateInfoFilePath(), JSON.stringify(info), err => {\n if (err) {\n // Can't write install attempt for some reason.\n // Log the error and continue.\n console.error('Failed to write install attempt info: ', err);\n }\n fulfill();\n });\n });\n this.restart = true;\n this._setupExitHook();\n this._quit();\n } catch (err) {\n // Try checking for and downloading the update.\n try {\n if (!await this._check()) {\n // No update is found... strange.\n // Restart anyway by throwing exception.\n throw new Error('No update found');\n }\n await this._download();\n // Success, try installing the update.\n this.quitAndInstall();\n } catch (ex) {\n // TODO: record another failed attempt.\n await this._rememberInstallAttempt();\n if (process.versions && process.versions.electron) {\n const { app } = require('electron');\n this.restart = true;\n if (process.platform !== 'linux') {\n app.relaunch(); // linux is handled by \"_quit\"\n }\n }\n this._quit();\n }\n }\n }", "async function checkUpdate(){\r\n\r\n var fileContents = Fs.readFileSync(__dirname+'/package.json');\r\n var pkg = JSON.parse(fileContents);\r\n\tpkg['name'] = PACKAGE_TO_UPDATE;\r\n\tpkg['version'] = pkg['dependencies'][PACKAGE_TO_UPDATE];\r\n\tif(isNaN(pkg['version'].substr(0,1))){\r\n\t\t//exemple: ^0.3.1\r\n\t\tpkg['version'] = pkg['version'].substr(1);\r\n\t}\r\n\r\n\tconst update = new AutoUpdate(pkg);\r\n\tupdate.on('update', function(){\r\n\t\tconsole.log('started update')\r\n\t\tif(app){\r\n\t\t\tconsole.log('[lanSupervLauncher] stopApplication');\r\n\t\t\tapp.stopApplication();\r\n\t\t\tapp = null;\r\n\t\t}\r\n\t});\r\n\tupdate.on('ready', function(){\r\n\t\tconsole.log('[lanSupervLauncher] ready (updated or not !)');\r\n\t\t//3) (Re)launch application\r\n\t\tif(app===null){\r\n\t\t\tconsole.log('[lanSupervLauncher] startApplication');\r\n\t\t\tapp = new LanSuperv();\r\n\t\t\tvar ConfigFile = __dirname + '/config.js';\r\n\t\t\tapp.startApplication(ConfigFile);\r\n\t\t\t//(initial launch or relaunch after update)\r\n\t\t}\r\n\t});\r\n\r\n}", "function handleSquirrelEvent(application) {\n if (process.argv.length === 1) {\n return false;\n }\n\n const ChildProcess = require('child_process');\n const path = require('path');\n\n const appFolder = path.resolve(process.execPath, '..');\n const rootAtomFolder = path.resolve(appFolder, '..');\n const updateDotExe = path.resolve(path.join(rootAtomFolder, 'Update.exe'));\n const exeName = path.basename(process.execPath);\n\n const spawn = function(command, args) {\n let spawnedProcess, error;\n\n try {\n spawnedProcess = ChildProcess.spawn(command, args, {\n detached: true\n });\n } catch (error) {}\n\n return spawnedProcess;\n };\n\n const spawnUpdate = function(args) {\n return spawn(updateDotExe, args);\n };\n\n const squirrelEvent = process.argv[1];\n switch (squirrelEvent) {\n case '--squirrel-install':\n case '--squirrel-updated':\n // Optionally do things such as:\n // - Add your .exe to the PATH\n // - Write to the registry for things like file associations and\n\t\t\t// explorer context menus\n\t\t\t\n // Install desktop and start menu shortcuts\n spawnUpdate(['--createShortcut', exeName]);\n\n setTimeout(application.quit, 1000);\n return true;\n\n case '--squirrel-uninstall':\n // Undo anything you did in the --squirrel-install and\n // --squirrel-updated handlers\n\n // Remove desktop and start menu shortcuts\n spawnUpdate(['--removeShortcut', exeName]);\n\n setTimeout(application.quit, 1000);\n return true;\n\n case '--squirrel-obsolete':\n // This is called on the outgoing version of your app before\n // we update to the new version - it's the opposite of\n // --squirrel-updated\n\n application.quit();\n return true;\n }\n}", "function handleSquirrelEvent() {\n if (process.argv.length === 1) {\n return false;\n }\n\n const ChildProcess = require(\"child_process\");\n const path = require(\"path\");\n\n const appFolder = path.resolve(process.execPath, \"..\");\n const rootAtomFolder = path.resolve(appFolder, \"..\");\n const updateDotExe = path.resolve(path.join(rootAtomFolder, \"Update.exe\"));\n const exeName = path.basename(process.execPath);\n\n const spawn = function (command, args) {\n let spawnedProcess, error;\n\n try {\n spawnedProcess = ChildProcess.spawn(command, args, { detached: true });\n } catch (error) { }\n\n return spawnedProcess;\n };\n\n const spawnUpdate = function (args) {\n return spawn(updateDotExe, args);\n };\n\n const squirrelEvent = process.argv[1];\n switch (squirrelEvent) {\n case \"--squirrel-install\":\n case \"--squirrel-updated\":\n // Optionally do things such as:\n // - Add your .exe to the PATH\n // - Write to the registry for things like file associations and\n // explorer context menus\n\n // Install desktop and start menu shortcuts\n spawnUpdate([\"--createShortcut\", exeName]);\n\n setTimeout(app.quit, 1000);\n return true;\n\n case \"--squirrel-uninstall\":\n // Undo anything you did in the --squirrel-install and\n // --squirrel-updated handlers\n\n // Remove desktop and start menu shortcuts\n spawnUpdate([\"--removeShortcut\", exeName]);\n\n setTimeout(app.quit, 1000);\n return true;\n\n case \"--squirrel-obsolete\":\n // This is called on the outgoing version of your app before\n // we update to the new version - it's the opposite of\n // --squirrel-updated\n\n app.quit();\n return true;\n }\n}", "function handleSquirrelEvent(application) {\n if (process.argv.length === 1) {\n return false;\n }\n\n const ChildProcess = require('child_process');\n const path = require('path');\n\n const appFolder = path.resolve(process.execPath, '..');\n const rootAtomFolder = path.resolve(appFolder, '..');\n const updateDotExe = path.resolve(path.join(rootAtomFolder, 'Update.exe'));\n const exeName = path.basename(process.execPath);\n\n const spawn = function (command, args) {\n let spawnedProcess, error;\n\n try {\n spawnedProcess = ChildProcess.spawn(command, args, {\n detached: true\n });\n } catch (error) { }\n\n return spawnedProcess;\n };\n\n const spawnUpdate = function (args) {\n return spawn(updateDotExe, args);\n };\n\n const squirrelEvent = process.argv[1];\n switch (squirrelEvent) {\n case '--squirrel-install':\n case '--squirrel-updated':\n // Optionally do things such as:\n // - Add your .exe to the PATH\n // - Write to the registry for things like file associations and\n // explorer context menus\n\n // Install desktop and start menu shortcuts\n spawnUpdate(['--createShortcut', exeName]);\n\n setTimeout(application.quit, 1000);\n return true;\n\n case '--squirrel-uninstall':\n // Undo anything you did in the --squirrel-install and\n // --squirrel-updated handlers\n\n // Remove desktop and start menu shortcuts\n spawnUpdate(['--removeShortcut', exeName]);\n\n setTimeout(application.quit, 1000);\n return true;\n\n case '--squirrel-obsolete':\n // This is called on the outgoing version of your app before\n // we update to the new version - it's the opposite of\n // --squirrel-updated\n\n application.quit();\n return true;\n }\n}", "updateClickHandler() {\n const { manualUpdateAvailable, hasAppUpdate } = this;\n if (manualUpdateAvailable) {\n const { updateVersion } = this;\n const base = 'https://github.com/advanced-rest-client/arc-electron/releases/tag';\n const url = `${base}/v${updateVersion}`;\n Events.Navigation.navigateExternal(document.body, url);\n } else if (hasAppUpdate) {\n Events.Updater.installUpdate(document.body);\n }\n }", "function handleSquirrelEvent(application) {\n if (process.argv.length === 1) {\n return false\n }\n const ChildProcess = require('child_process')\n const path = require('path')\n const appFolder = path.resolve(process.execPath, '..')\n const rootAtomFolder = path.resolve(appFolder, '..')\n const updateDotExe = path.resolve(path.join(rootAtomFolder, 'Update.exe'))\n const exeName = path.basename(process.execPath)\n const spawn = function (command, args) {\n let spawnedProcess, error\n try {\n spawnedProcess = ChildProcess.spawn(command, args, {\n detached: true,\n })\n } catch (error) {}\n return spawnedProcess\n }\n const spawnUpdate = function (args) {\n return spawn(updateDotExe, args)\n }\n const squirrelEvent = process.argv[1]\n switch (squirrelEvent) {\n case '--squirrel-install':\n case '--squirrel-updated':\n // Optionally do things such as:\n // - Add your .exe to the PATH\n // - Write to the registry for things like file associations and\n // explorer context menus\n // Install desktop and start menu shortcuts\n spawnUpdate(['--createShortcut', exeName])\n setTimeout(application.quit, 1000)\n return true\n case '--squirrel-uninstall':\n // Undo anything you did in the --squirrel-install and\n // --squirrel-updated handlers\n // Remove desktop and start menu shortcuts\n spawnUpdate(['--removeShortcut', exeName])\n setTimeout(application.quit, 1000)\n return true\n case '--squirrel-obsolete':\n // This is called on the outgoing version of your app before\n // we update to the new version - it's the opposite of\n // --squirrel-updated\n application.quit()\n return true\n }\n}", "function handleSquirrelEvent() {\n if (process.argv.length === 1) {\n return false;\n }\n\n const ChildProcess = require('child_process');\n const path = require('path');\n\n const appFolder = path.resolve(process.execPath, '..');\n const rootAtomFolder = path.resolve(appFolder, '..');\n const updateDotExe = path.resolve(path.join(rootAtomFolder, 'Update.exe'));\n const exeName = path.basename(process.execPath);\n\n const spawn = function(command, args) {\n let spawnedProcess, error;\n\n try {\n spawnedProcess = ChildProcess.spawn(command, args, {detached: true});\n } catch (error) {}\n\n return spawnedProcess;\n };\n\n const spawnUpdate = function(args) {\n return spawn(updateDotExe, args);\n };\n\n const squirrelEvent = process.argv[1];\n switch (squirrelEvent) {\n case '--squirrel-install':\n case '--squirrel-updated':\n // Optionally do things such as:\n // - Add your .exe to the PATH\n // - Write to the registry for things like file associations and\n // explorer context menus\n\n // Install desktop and start menu shortcuts\n spawnUpdate(['--createShortcut', exeName]);\n\n setTimeout(app.quit, 1000);\n return true;\n\n case '--squirrel-uninstall':\n // Undo anything you did in the --squirrel-install and\n // --squirrel-updated handlers\n\n // Remove desktop and start menu shortcuts\n spawnUpdate(['--removeShortcut', exeName]);\n\n setTimeout(app.quit, 1000);\n return true;\n\n case '--squirrel-obsolete':\n // This is called on the outgoing version of your app before\n // we update to the new version - it's the opposite of\n // --squirrel-updated\n\n app.quit();\n return true;\n }\n}", "function onUpdateExe () {\r\n let job = new Job({\r\n videoUrl: 'Update youtube-dl.exe executable',\r\n updateExe: true\r\n });\r\n state.jobs.unshift(job);\r\n job.create();\r\n return Promise.resolve(job);\r\n}", "function executeSquirrelCommand(args, done) {\n const updateDotExe = path.resolve(path.dirname(process.execPath), '..', 'Update.exe');\n const child = spawn(updateDotExe, args, { detached: true });\n child.on('close', () => done());\n}", "function winInstall(event)\n{\n // close the eula window\n closeWindow();\n installPrompt(app.WIN_PL_NAME);\n}", "function updateApp() {\n\n\tif ($(\".selectedPortlet\")[0]) {\n\t\tvar portletID = $(\".selectedPortlet\")[0].id;\n\t\t$.getJSON(\"/security/config/installedapps?action=update&app=\" + portletID+\"&user=\" + otusr + \"&pw=\" + otpwd, function(json) {\n\t\t\talert(json.statusInfo);\n\t\t});\n\t} else {\n\t\talert(\"Wählen Sie ein Bundle!\");\n\t}\n}", "function updateApp(e){\n // Get zip and feelings from UI\n const zip = document.getElementById('zip').value;\n const feelings = document.getElementById('feelings').value;\n\n // Get weather from api\n getWeather(baseURL, zip, apiKey)\n .then(function(data){\n // Update the data obj on the server\n const currentDate = new Date(data.dt*1000).toLocaleDateString(\"en-US\");\n updateData('/save', {\n date: currentDate, \n temp: data.main.temp,\n feelings: feelings\n });\n })\n .then(function(data){\n // Update the UI\n updateUI();\n });\n}", "onUpdateDownloaded(info) {\n if(this.updateEntry != null) {\n this.updateEntry.setTitle(\"Update downloaded\");\n this.updateEntry.setText(\"XenonTrade <span>v\" + info.version + \"</span> has been downloaded. It will be automatically installed after closing XenonTrade.<br /><i class='fas fa-arrow-right'></i> <span data-update='install'>Install now</span>\");\n this.updateEntry.enableClose();\n }\n\n $(\".menu\").find(\"[data-button='download']\").hide();\n\n $(\".entry[data-id='\" + this.updateEntry.getId() + \"']\").find(\"[data-update='install']\").click(function() {\n ipcRenderer.send(\"install-update\");\n });\n }", "handleUpdateCheckingProcess()\n {\n let checkForUpdateItem = this.tray.getMenuItem('checkForUpdate');\n let restartAndInstallUpdateItem = this.tray.getMenuItem('restartAndInstallUpdate');\n let youAreUpToDateItem = this.tray.getMenuItem('youAreUpToDate');\n let downloadingUpdateItem = this.tray.getMenuItem('downloadingUpdate');\n let downloadingUpdateFailedItem = this.tray.getMenuItem('downloadingUpdateFailed');\n\n // Disable the check for update menu item to avoid running into\n // multiple checks\n checkForUpdateItem.enabled = false;\n\n // Run the updater to see if there is an update\n this.updater.checkForUpdate()\n\n // We have an update!\n .then(() => {\n\n // Tell user we are downloading the update\n downloadingUpdateItem.visible = true;\n checkForUpdateItem.visible = false;\n checkForUpdateItem.enabled = true;\n\n // Wait for the download to finish\n this.updater.onUpdateDownloaded()\n\n // Enable the restart and install update menu item\n .then(() => {\n downloadingUpdateItem.visible = false;\n restartAndInstallUpdateItem.visible = true;\n })\n\n // Failed to download update\n .catch(() => {\n downloadingUpdateFailedItem.visible = true;\n downloadingUpdateItem.visible = false;\n\n // Enable check for update after 1 min\n setTimeout(() => {\n checkForUpdateItem.visible = true;\n downloadingUpdateFailedItem.visible = false;\n }, 1000 * 60);\n });\n })\n\n // Nope, all up to date\n .catch((error) => {\n\n if (this.debug) {\n console.log(error);\n }\n\n youAreUpToDateItem.visible = true;\n checkForUpdateItem.visible = false;\n checkForUpdateItem.enabled = true;\n\n // Enable check for update after 1 min\n setTimeout(() => {\n checkForUpdateItem.visible = true;\n youAreUpToDateItem.visible = false;\n }, 1000 * 60);\n });\n }", "autoupdate() {\r\n const sendStatusToWindow = (message) => {\r\n this.mainWindow.webContents.send(\"updateMessage\", message);\r\n };\r\n autoUpdater.checkForUpdatesAndNotify();\r\n\r\n autoUpdater.on(\"update-available\", () => {\r\n this.mainWindow.webContents.send(\r\n \"updateMessage\",\r\n \"Update available!\"\r\n );\r\n });\r\n\r\n autoUpdater.on(\"update-downloaded\", () => {\r\n autoUpdater.quitAndInstall();\r\n });\r\n\r\n autoUpdater.on(\"checking-for-update\", () => {\r\n sendStatusToWindow(\"Checking for update...\");\r\n });\r\n autoUpdater.on(\"update-available\", (info) => {\r\n sendStatusToWindow(\"Update available.\");\r\n });\r\n autoUpdater.on(\"update-not-available\", (info) => {\r\n sendStatusToWindow(\"Update not available.\");\r\n });\r\n autoUpdater.on(\"error\", (err) => {\r\n sendStatusToWindow(\"Error in auto-updater. \" + err);\r\n });\r\n autoUpdater.on(\"download-progress\", (progressObj) => {\r\n let log_message = \"Download speed: \" + progressObj.bytesPerSecond;\r\n log_message =\r\n log_message + \" - Downloaded \" + progressObj.percent + \"%\";\r\n log_message =\r\n log_message +\r\n \" (\" +\r\n Math.round(progressObj.transferred) +\r\n \"/\" +\r\n Math.round(progressObj.total) +\r\n \")\";\r\n sendStatusToWindow(log_message);\r\n });\r\n autoUpdater.on(\"update-downloaded\", (info) => {\r\n sendStatusToWindow(\"Update downloaded\");\r\n });\r\n }", "install() {\r\n return this.clone(App, \"Install\").postCore();\r\n }", "function update_tray() { \n if (tray && !isWin) return; //Bug in linux doesn't allow us to recreate the tray in this boostrap manner. See: https://github.com/electron/electron/issues/17622\n if (tray) tray.destroy();\n tray = new Tray(icon_path)\n tray.setToolTip('Diary Prompter')\n tray.on('click', () => create_quick_entry_window());\n\n let items = [\n new MenuItem({label: 'Preferences', click: () => {\n if (isWin) options_window.show();\n else create_options_window();\n }}),\n // new MenuItem({\n // label: `${(store.get('tracking') ? 'Enable' : 'Disable')} Program Tracking`,\n // click: () => {\n // store.set('tracking', !store.get('tracking'));\n // update_tray();\n // }\n // }),\n new MenuItem({\n label: 'Add Quick Entry',\n click: () => create_quick_entry_window()\n }),\n new MenuItem({\n label: 'Add Full Entry',\n click: () => create_diary_entry_window()\n }),\n new MenuItem({\n label: 'Quit',\n click: () => {\n app.isQutting = true;\n if (isWin) options_window.close();\n app.quit();\n }\n })\n ];\n if (isWin) items.push(new MenuItem({\n label: `${(store.get('reminders') ? 'Enable' : 'Disable')} Hourly Reminders`,\n click: () => {\n store.set('reminders', !store.get('reminders'));\n update_tray();\n }\n })); //We can only add this item on windows machines, as the fast toggle doesn't work for linux.\n\n tray.setContextMenu(Menu.buildFromTemplate(items));\n}", "async reload() {\n const addon = addonFor(this);\n\n logger.debug(`reloading add-on ${addon.id}`);\n\n if (!this.temporarilyInstalled) {\n await XPIDatabase.updateAddonDisabledState(addon, true);\n await XPIDatabase.updateAddonDisabledState(addon, false);\n } else {\n // This function supports re-installing an existing add-on.\n await AddonManager.installTemporaryAddon(addon._sourceBundle);\n }\n }", "async handle_update() {\n\t\tthis.new_worker = await navigator.serviceWorker.getRegistration();\n\t\tif (this.new_worker.waiting) {\n\t\t\tthis.promote_app_update();\n\t\t}\n\t}", "function onFirstButtonPressed() {\n\t\t\t\t\tif (result.meta.redirectURL && result.meta.redirectURL.length != 0) {\n\t\t\t\t\t\t//RaU wants us to open a URL, most probably core/player updated and binary changed. \n\t\t\t\t\t\tSMF.Net.browseOut(result.meta.redirectURL);\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\t//There is an update waiting to be downloaded. Let's download it.\n\t\t\t\t\t\tresult.download(function(err, result) {\n\t\t\t\t\t\t\tif (err) {\n\t\t\t\t\t\t\t\t//Download failed\n\t\t\t\t\t\t\t\talert(\"Autoupdate download failed: \" + err);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\t//All files are received, we'll trigger an update.\n\t\t\t\t\t\t\t\tresult.updateAll(function(err) {\n\t\t\t\t\t\t\t\t\tif (err) {\n\t\t\t\t\t\t\t\t\t\t//Updating the app with downloaded files failed\n\t\t\t\t\t\t\t\t\t\talert(\"Autoupdate update failed: \" + err);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\t\t\t//After that the app will be restarted automatically to apply the new updates\n\t\t\t\t\t\t\t\t\t\tApplication.restart();\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t}", "function handleInstalled (details) {\n if (details.reason === 'install') {\n browser.runtime.openOptionsPage()\n } else if (details.reason === 'update') {\n let previousVersion = details.previousVersion\n if (previousVersion[0] === '1') {\n // Update from version 1.*\n browser.storage.local.remove(['override', 'icon', 'inbox', 'addtotop'])\n }\n browser.storage.local.set({newRelease: true}).then(() => {\n browser.runtime.openOptionsPage()\n }, onError)\n }\n}", "function handleStartupEvent(callback) {\n const squirrelCommand = process.argv[1];\n\n switch (squirrelCommand) {\n case '--squirrel-install':\n case '--squirrel-updated':\n // Optionally do things such as:\n //\n // - Install desktop and start menu shortcuts\n // - Add your .exe to the PATH\n // - Write to the registry for things like file associations and\n // explorer context menus\n\n // Always quit when done\n install(app.quit);\n break;\n\n case '--squirrel-uninstall':\n // Undo anything you did in the --squirrel-install and\n // --squirrel-updated handlers\n\n // Always quit when done\n uninstall(app.quit);\n break;\n\n case '--squirrel-obsolete':\n // This is called on the outgoing version of your app before\n // we update to the new version - it's the opposite of\n // --squirrel-updated\n uninstall(app.quit);\n break;\n\n case '--squirrel-firstrun':\n // do something on windows first run\n app.quit();\n break;\n\n default:\n callback();\n }\n}", "promoteUpdater() {}", "function onInstall() {\n onOpen();\n}", "function onInstall() {\n onOpen();\n}", "function onInstall() {\n onOpen();\n}", "function add_to_install(val) {\n $('#package-name').val(\"\");\n $('#package-name').blur();\n var a = val.split(' - ');\n var pkg = {\n 'name': a[0],\n 'version': a[1],\n 'staus': ''\n };\n var data = [];\n data.push(pkg);\n var output = views.to_install(data);\n $('#to-install').append(output);\n var toInstall = common.get_to_install();\n views.select_to_install(toInstall);\n $('#to-install-main').css(\"display\", \"initial\");\n }", "showUpdateMessage() {\r\n const currentVersion = store.get(\"version\");\r\n\r\n if (typeof currentVersion == \"undefined\")\r\n store.set(\"version\", app.getVersion());\r\n\r\n if (currentVersion !== app.getVersion()) {\r\n this.mainWindow.webContents.send(\"showJustUpdated\");\r\n store.set(\"version\", app.getVersion());\r\n }\r\n }", "function onInstall() {\n onOpen();\n}", "async function startCourseUpdate() {\n\n const firstPrompt = \"Update the list of available courses to match the \" +\n \"current OSU course catalog?\";\n const secondPrompt = \"Updating the courses may take anywhere from a few minutes \" +\n \"to a few hours.\\n\\n \" +\n \"This action should only be performed when there is not \" +\n \"a large amount of user traffic and only when there is the expectation \" +\n \"of new courses existing in the OSU course catalog (once a term).\\n\\n\" +\n \"Do you still want to update the current list of available courses?\";\n\n if (window.confirm(firstPrompt) && window.confirm(secondPrompt)) {\n\n try {\n\n // request that all courses are updated\n const url = `/api/course/updateDatabase`;\n\n // perform the query\n const response = await fetch(url);\n if (!response.ok) {\n\n if (response.status === 403) {\n // if the user is not allowed to update courses,\n // redirect to login to allow updating of user info\n login();\n } else {\n // note that there was an error trying to start the update\n alert(\"Internal server error. Unable to update courses.\");\n }\n\n }\n\n } catch (err) {\n // note that there was an error trying to start the update\n alert(\"Internal server error. Unable to update courses.\");\n }\n }\n\n }", "async function copyright( args ) {\n\tvar state = {} ;\n\n\t// Process arguments\n\tstate.update = args.commandArgs[ 0 ] === 'update' ;\n\n\tstate.cwd = process.cwd() ;\n\tstate.packagePath = state.cwd + '/package.json' ;\n\n\ttry {\n\t\tstate.package = require( state.packagePath ) ;\n\t}\n\tcatch ( error ) {\n\t\twfm.exitError( \"No package.json found.\\n\" ) ;\n\t}\n\n\tawait packageInfo( state ) ;\n\tawait writePackage( state ) ;\n\tawait patchFiles( state ) ;\n\n\tprocess.exit( 0 ) ;\n}", "function autoUpdateCheck() {\n //get the auto update value\n const auto_update = settings.get('auto_update');\n if (auto_update === true) {\n log.info('[main]', 'Checking for updates with auto updater');\n //Call pullUpdate and wait for the promise to return the result\n setActionRun(true);\n PullUpdate().then(\n (result) => {\n //If it is a success (update installed) reload the window\n setActionRun(false);\n log.info('[main]', 'autoUpdateCheck Success');\n reloadMain('index');\n },\n (error) => {\n // check error or no need to be updated\n setActionRun(false);\n log.error('[main]', 'autoUpdateCheck:' , error);\n }\n );\n }\n}", "function reRun(){\n inquirer.prompt([\n {\n type: \"confirm\",\n name: \"reply\",\n message: \"Would you like to purchase another item?\"\n }\n ]).then(function(answer) {\n if(answer.reply) {\n buy();\n } \n else \n {\n console.log(\"Thanks for shopping Bamazon!\");\n connection.end();\n }\n });\n}", "function uninstallAUUpdater() {\n WScript.Echo(\"uninstallAUUpdater\");\n try {\n var AUGUID=\"{4A03706F-666A-4037-7777-5F2748764D10}\";\t\t\n var uninstallCmd = \"MsiExec.exe REBOOT=Suppress /x\" + AUGUID + \" /qn\";\n WScript.Echo(uninstallCmd);\n WshShell.Run(uninstallCmd, 1, true);\n } catch(exception) { \n return false;\n }\n return true;\n }", "function installQuitButton() {\n installSidebarButton('label-quit', 'quit', 'exit-to-app', -1, '#', (e) => {\n remote.app.quit();\n e.preventDefault();\n e.stopPropagation();\n return false;\n });\n}", "function reInstall() {\n if (isUsingYarn) {\n return execa.shellSync(`${installCmd} --force`, { stdio: 'inherit' });\n }\n return execa.shellSync(installCmd, { stdio: 'inherit' });\n}", "function onInstall(event) {\n event.waitUntil(self.skipWaiting());\n}", "function installLatest(version) {\n\tconsole.log(`Installing version ${version}`);\n\tchild_process.exec(`npm install -g ${alfredNPMpath}`, (error, stdout, stderr) => {\n\t\tif (error) {\n\t\t\tconsole.log(stderr);\n\t\t\tthrow error;\n\t\t} else {\n\t\t\tconsole.log(stdout);\n\t\t\tconsole.log('Alfred has been udpated and will now quit. Relaunch to get back to work!');\n\t\t}\n\t\tprocess.exit();\n\t});\n}", "function onInstall(e) {\n onOpen(e);\n}", "function onInstall(e) {\n onOpen(e);\n}", "function onInstall(e) {\n onOpen(e);\n}", "function onInstall(e) {\n onOpen(e);\n}", "function checkForUpdate() {\n superagent.get(packageJson).end((error, response) => {\n if (error) return;\n const actualVersion = JSON.parse(response.text).version; // TODO: case without internet connection\n console.log('Actual app version: ' + actualVersion + '. Current app version: ' + currentVersion);\n if (semver.gt(actualVersion, currentVersion)) {\n mb.window.webContents.send('update-available');\n console.log('New version is available!');\n }\n });\n}", "onFirstInstalled() {\n\n }", "function update() {\n\tIPC.sendToHost('api-call', '/daemon/version', 'version');\n\t\n\tupdating = setTimeout(update, 50000);\n}", "function uninstallApp(path) {\n Log(\"Attempt to uninstall previous application version...\");\n Log(\"\\tDirectory : \" + path);\n\n wscript_shell.CurrentDirectory = path;\n var command = \"powershell -ExecutionPolicy RemoteSigned \\\". \" + WINDOWS_STORE_UTILS + \"; Uninstall-App \" + PACKAGE_NAME;\n Log(command);\n exec_verbose(command);\n}", "function inventoryUpdates() {\n\tinquirer.prompt([{\n\t\tname: \"action\",\n\t\ttype: \"list\",\n\t\tmessage: \"Choose an option below to manage current inventory:\",\n\t\tchoices: [\"Restock Inventory\", \"Add New Product\", \"Remove An Existing Product\"]\n\t}]).then(function (answers) {\n\t\tswitch (answers.action) {\n\t\t\tcase 'Restock Inventory':\n\t\t\t\trestockRequest();\n\t\t\t\tbreak;\n\t\t\tcase 'Add New Product':\n\t\t\t\taddNewItem();\n\t\t\t\tbreak;\n\t\t\tcase 'Remove An Existing Product':\n\t\t\t\tremoveRequest();\n\t\t\t\tbreak;\n\t\t}\n\t});\n}", "function onInstall() {\n\t\n\tif (navigator.onLine) {\n\t\tchrome.tabs.create({url: 'https://singleclickapps.com/merge-windows/postinstall-chrome.html'});\n\t}\n}", "function updatePrompt() {\n return inquirer.prompt([\n {\n type: \"list\",\n name: \"update\",\n message: \"What specifically would you like to update?\",\n choices: [\"Title\", \"Salary\", \"Department ID\"]\n }\n ]);\n}", "function callInstallPrompt() {\n\t// We can't fire the dialog before preventing default browser dialog\n\t//TODO: Complete this for custom prompts\n\tif (installPromptEvent !== undefined) {\n\t\tinstallPromptEvent.prompt();\n\t}\n}", "onUpdateAvailable(info) {\n var self = this;\n\n this.updateEntry = new TextEntry(\"Update available\", \"A new version of XenonTrade (<span>v\" + info.version + \"</span>) is available.<br /><i class='fas fa-arrow-right'></i> <span data-update='download'>Update now</span>\", {icon: \"fa-box blue\"});\n this.updateEntry.add();\n\n $(\".entry[data-id='\" + this.updateEntry.getId() + \"']\").find(\"[data-update='download']\").click(function() {\n ipcRenderer.send(\"download-update\");\n $(\".menu\").find(\"[data-button='download']\").show();\n\n self.updateEntry.setTitle(\"Downloading <span>v\" + info.version + \"</span>...\");\n self.updateEntry.setText(\"\");\n self.updateEntry.enableClose(false);\n });\n }", "async function upgradeAutoLaunch() {\n if (process.platform === 'darwin') {\n return;\n }\n const appLauncher = new auto_launch__WEBPACK_IMPORTED_MODULE_0___default.a({\n name: 'Mattermost',\n isHidden: true,\n });\n const enabled = await appLauncher.isEnabled();\n if (enabled) {\n await appLauncher.enable();\n }\n}", "function afterInstall(ars) {\n var ln = ars?ars.length:0;\n if (ln>0) {\n var rs = ars[ln-1];\n if (rs) { // rs will be undefined if there was an error in installation \n var inst = !(rs.__autonamed__);// && !noInst; // instantiate directly built fellows, so as to share their code\n var ovr = installOverrides(rs);\n var ws = __pj__.set(\"ws\",om.DNode.mk());\n if (inst) {\n var frs = rs.instantiate();\n } else {\n frs = rs;\n }\n ws.set(rs.__name__,frs); // @todo rename if necessary\n om.root = draw.wsRoot = frs;\n page.codeBuilt = !(frs.__saveCount__);\n draw.enabled = !inspectDom &&!frs.notStandalone;\n var standalone = draw.enabled;\n showTopNote();\n if (standalone) {\n om.overrides = ovr;\n frs.deepUpdate(ovr);\n \n var bkc = frs.backgroundColor;\n if (!bkc) {\n frs.backgroundColor=\"white\";\n }\n }\n } else {\n om.root ={__installFailure__:1};\n }\n } else {\n // newItem\n om.root = draw.wsRoot = __pj__.set(\"ws\",geom.Shape.mk());\n om.root.backgroundColor=\"white\";\n standalone = true;\n page.codeBuilt = false;\n }\n setFselOptions(); \n \n \n page.genMainPage(standalone,function () {\n if (!wssrc) {\n page.setSaved(false);\n }\n if (!om.root.__about__) {\n aboutBut.hide();\n }\n var ue = om.updateErrors && (om.updateErrors.length > 0);\n if (ue) {\n var lb = mpg.lightbox;\n lb.pop();\n lb.setHtml(\"<div id='updateMessage'><p>An error was encountered in running the update function for this item: </p><i>\"+om.updateErrors[0]+\"</i></p></div>\");\n }\n //om.clearDataSources(om.root); //put this in someday under some conditions, if the data sources should be reloaded\n om.loadTheDataSources(om.root,function () {\n if (standalone || inspectDom) om.root.deepUpdate(ovr);\n tree.initShapeTreeWidget();\n var isVariant = !!(om.root.__saveCount__);\n if (inspectDom) {\n var doc = om.root.document;\n if (doc) {\n var dmf = doc.domify();\n canvasDiv.addChild(dmf);\n dmf.install();\n }\n \n } else if (standalone) {\n var tr = om.root.transform;\n var cdims = om.root.__canvasDimensions__;\n\n if (tr && cdims) {\n draw.mainCanvas.adjustTransform(draw.mainCanvas.transform(),cdims);\n } else {\n if (!isVariant || !tr) {\n //draw.mainCanvas.refresh();// so that text can be given bounds\n tr = draw.mainCanvas.fitTransform();\n om.root.set(\"transform\",tr);\n }\n }\n draw.refresh();\n\n }\n tree.openTop();\n tree.adjust();\n });\n });\n \n }", "function Controller() {\n installer.autoRejectMessageBoxes();\n\n installer.setMessageBoxAutomaticAnswer(\"OverwriteTargetDirectory\", QMessageBox.Yes);\n\n installer.setMessageBoxAutomaticAnswer(\"TargetDirectoryInUse\", QMessageBox.NO);\n\n installer.installationFinished.connect(\n function() {\n gui.clickButton(buttons.NextButton);\n }\n )\n}", "function update() {\n isEventbriteEventPage(function(e) {\n // Set the popup depending on whether this is an Eventbrite event page.\n setPopup(e);\n\n if (e) {\n // Set the icon to inform the user the plugin may be used.\n setIcon(\"icon\");\n\n // Check if the runner is already active\n chrome.storage.sync.get(null, function(response) {\n if (response.run) {\n // Set the icon\n setIcon(\"icon_active\");\n\n // Try to secure the ticket\n chrome.tabs.executeScript(null, {\n file: 'secureTicket.js'\n }, function() {\n if (chrome.runtime.lastError) {\n // An error has occurred.\n console.warn(\"Error encountered:\");\n console.warn(chrome.runtime.lastError);\n }\n });\n }\n })\n } else {\n setIcon(\"icon_bw\");\n }\n });\n}", "function performUpgrade() {\r\n\t\t_log(3, \"-> performUpgrade()\");\r\n\t\r\n\tcreateCookie(\"TTQ_CODE_0\", \"\");\r\n\tcreateCookie(\"TTQ_CODE_1\", \"\");\t\r\n\t\t\r\n\tGM_setValue(\"TTQ_VERSION\", sCurrentVersion);\r\n\talert(\"Your Travian Task Queue script has been updated. Please check that the TTQ_CODE_0 and TTQ_CODE_1 cookies for all Travian domains were cleared. (If not sure, delete all cookies from your browser.)\");\t\r\n\t\t_log(3, \"<- performUpgrade()\");\r\n}", "function showInstallFrame() {\n log_d(\"Plugin not installed. Use install plugin button. Refresh the page when complete\");\n CDO.getInstallerURL(CDO.createResponder(function (url) {\n $('#installButton').\n attr('href', url).\n show().\n click(pollForPlugin);\n }));\n}", "function updateInstallationRequest(appConfig) {\n return update(appConfig, function (oldEntry) {\n if (!oldEntry) {\n throw ERROR_FACTORY.create(\"installation-not-found\" /* INSTALLATION_NOT_FOUND */);\n }\n return clearTimedOutRequest(oldEntry);\n });\n}", "function updateInstallationRequest(appConfig) {\n return update(appConfig, function (oldEntry) {\n if (!oldEntry) {\n throw ERROR_FACTORY.create(\"installation-not-found\" /* INSTALLATION_NOT_FOUND */);\n }\n return clearTimedOutRequest(oldEntry);\n });\n}", "function updateInstallationRequest(appConfig) {\r\n return update(appConfig, function (oldEntry) {\r\n if (!oldEntry) {\r\n throw ERROR_FACTORY.create(\"installation-not-found\" /* INSTALLATION_NOT_FOUND */);\r\n }\r\n return clearTimedOutRequest(oldEntry);\r\n });\r\n}", "function updateInstallationRequest(appConfig) {\r\n return update(appConfig, function (oldEntry) {\r\n if (!oldEntry) {\r\n throw ERROR_FACTORY.create(\"installation-not-found\" /* INSTALLATION_NOT_FOUND */);\r\n }\r\n return clearTimedOutRequest(oldEntry);\r\n });\r\n}", "install() {\n this.listen(this.update.bind(this))\n }", "function update(){\n newInventory = currentQuantity + updateQuantity;\n\n connection.query(\n \"UPDATE products SET ? WHERE ?\",\n [\n {\n stock_quantity: newInventory\n },\n {\n item_id: itemNum\n }\n ],\n function(err, res) {\n\n if (err) throw err;\n \n inquirer.prompt([\n {\n type: \"confirm\",\n name: \"doAgain\",\n message: \"Your inventory has been successfully updated. Would you like to do something else?\",\n \n }\n ]).then(function(response){\n if (response.doAgain){\n promptManager();\n } else {\n connection.end();\n };\n \n });\n });\n }", "syncImmediate() {\n CodePush.sync(\n { installMode: CodePush.InstallMode.IMMEDIATE,//启动模式三种:ON_NEXT_RESUME、ON_NEXT_RESTART、IMMEDIATE\n updateDialog: {\n appendReleaseDescription:true,//是否显示更新description,默认为false\n descriptionPrefix:\"更新内容:\",//更新说明的前缀。 默认是” Description:\n mandatoryContinueButtonLabel:\"立即更新\",//强制更新的按钮文字,默认为continue\n mandatoryUpdateMessage:\"\",//- 强制更新时,更新通知. Defaults to “An update is available that must be installed.”.\n optionalIgnoreButtonLabel: '稍后',//非强制更新时,取消按钮文字,默认是ignore\n optionalInstallButtonLabel: '后台更新',//非强制更新时,确认文字. Defaults to “Install”\n optionalUpdateMessage: '有新版本了,是否更新?',//非强制更新时,更新通知. Defaults to “An update is available. Would you like to install it?”.\n title: '更新提示'//要显示的更新通知的标题. Defaults to “Update available”.\n },\n },\n );\n }", "function update() {\n switch (x) {\n case 'help': return help(cmd, x);\n case 'history': return history(cmd, x);\n case 'reset': return reset(cmd);\n case 'reset -a': return window.localStorage.removeItem('itemKey');\n case 'cv': return cv(cmd, x);\n case 'cv --json': return cvjson(cmd, x);\n case 'q':\n case 'quit': return quit(cmd, x);\n default: return unexisting(cmd, x);\n }\n }", "function launchApp() {\r\n console.log(\"Hypersubs: Launching.\");\r\n $('#hypersubs-main-dialog').dialog('open');\r\n $('#hypersubs-splash').css('display', 'none');\r\n loadFlange(0, userPreferences.smartFill);\r\n }", "function manuallyCheckForUpdate() {\r\n\tcheckForUpdate(true);\r\n} //End manual update check", "function updateCart() {\n clear();\n displayStock();\n shoppingCart();\n //prompt the user to see if they want to update a quantity in the cart or remove an item in the cart\n inquirer.prompt([\n {\n type: \"list\",\n message: \"What would you like to do?\",\n choices: [\"Update Quantity\", \"Remove Item\"],\n name: \"choices\"\n }\n ]).then(function (choice) {\n switch (choice.choices) {\n //run a function based on their choices\n case \"Update Quantity\":\n updateQuantity();\n break;\n case \"Remove Item\":\n removeItem();\n break;\n }\n });\n}", "function onInstall(event) {\n Plugins.init();\n \n onOpen(event);\n}", "function onReady() {\n\tconsole.log( 'Application is ready...' ); // eslint-disable-line no-console\n\tcreateWindow( pathToOpen, ( mainWindow ) => {\n\t\tisReady = true;\n\n\t\tfunction sendStatusToWindow( text ) {\n\t\t\tmainWindow.webContents.send('message', text );\n\t\t}\n\n\t\tif ( process.env.NODE_ENV === 'production' ) {\n\t\t\tsendStatusToWindow( 'Check for updates and notify if available...' );\n\n\t\t\tautoUpdater.on( 'checking-for-update', () => {\n\t\t\t\tsendStatusToWindow('Checking for update...');\n\t\t\t});\n\n\t\t\tautoUpdater.on( 'update-available', ( info ) => {\n\t\t\t\tsendStatusToWindow('Update available.');\n\t\t\t});\n\n\t\t\tautoUpdater.on( 'update-not-available', ( info ) => {\n\t\t\t\tsendStatusToWindow('Update not available.');\n\t\t\t});\n\n\t\t\tautoUpdater.on( 'error', ( err ) => {\n\t\t\t\tsendStatusToWindow('Error in auto-updater. ' + err);\n\t\t\t});\n\n\t\t\tautoUpdater.on( 'download-progress', ( progressObj ) => {\n\t\t\t\tlet msg = 'Download speed: ' + progressObj.bytesPerSecond;\n\t\t\t\tmsg = msg + ' - Downloaded ' + progressObj.percent + '%';\n\t\t\t\tmsg = msg + ' (' + progressObj.transferred + '/' + progressObj.total + ')';\n\t\t\t\tsendStatusToWindow( msg );\n\t\t\t});\n\n\t\t\tautoUpdater.on( 'update-downloaded', ( info ) => {\n\t\t\t\tsendStatusToWindow( 'Update downloaded' );\n\t\t\t});\n\n\t\t\tautoUpdater.checkForUpdatesAndNotify();\n\t\t}\n\t});\n\tMenu.setApplicationMenu( Menu.buildFromTemplate( configureMenu({ app }) ) );\n\taddRecentFilesMenu();\n}", "install() {\n installed = true;\n }", "function onInstallStart(ev) {\n future.when(function () {\n console.log('start', ev, 'status', appCache.status, new Date().toISOString());\n primaryEmitter.emit('start');\n });\n }", "function initInlineInstalls()\n{\n $(\"link[rel=chrome-webstore-item]\").attr(\"href\", getWebStoreInstallUrl());\n}", "function initInlineInstalls()\n{\n $(\"link[rel=chrome-webstore-item]\").attr(\"href\", getWebStoreInstallUrl());\n}", "function updateCheck()\r\n{\r\n\tvar scriptNum = 27776;\r\n\t\r\n\t//Only check for update if using Greasemonkey and no check has been made in the last day.\r\n\tif( !MS_getValue('checked_update') )\r\n\t{\r\n\t\tMS_setValue( 'checked_update', true, 24*3600 );\r\n\t\tGM_xmlhttpRequest(\r\n\t\t{\r\n\t\t\tmethod: 'GET',\r\n\t\t\turl: 'http://userscripts.org/scripts/source/'+scriptNum+'.meta.js?'+new Date().getTime(),\r\n\t\t\theaders: { 'Cache-Control': 'no-cache' },\r\n\t\t\tonload: function(response)\r\n\t\t\t{\r\n\t\t\t\tvar localVersion = parseInt( GM_getValue( 'local_version', 0 ) );\r\n\t\t\t\tvar remoteVersion = parseInt( /@uso:version\\s*([0-9]+?)\\s*$/m.exec(response.responseText)[1] );\r\n\t\t\t\t\r\n\t\t\t\tif( !localVersion || remoteVersion <= localVersion )\r\n\t\t\t\t\tGM_setValue( 'local_version', remoteVersion );\r\n\t\t\t\telse if( confirm( 'There is an update available for the Greasemonkey script \"'+/@name\\s*(.*?)\\s*$/m.exec(response.responseText)[1]+'\".\\nWould you like to go to the install page now?' ) )\r\n\t\t\t\t{\r\n\t\t\t\t\tGM_openInTab( 'http://userscripts.org/scripts/show/'+scriptNum );\r\n\t\t\t\t\tGM_setValue( 'local_version', remoteVersion );\r\n\t\t\t\t}\r\n\t\t\t},\r\n\t\t});\r\n\t}\r\n}", "function updateNow(bp) {\n\t$('#update-now-span').text(t('library_update_in_progress'));\n\n\tbp.loadBugList(true, function (result) {\n\t\tif (!result) {\n\t\t\t$('#update-now-span').text(t('library_update_failed'));\n\t\t\treturn;\n\t\t}\n\n\t\tupdateBugsLastUpdated();\n\n\t\t// rebuild the tracker browser\n\t\t$('#app-list-reset-search').click();\n\t\twindow.browser.categories.reset(getCategories(bp));\n\t\twindow.browser.new_app_ids = prefs('newAppIds');\n\n\t\t$('#update-now-span').html('<span style=\"color:green\">' + t('library_update_successful') + '</span>');\n\t});\n}", "function startApp() {\n inquirer.prompt([\n {\n name: 'menu',\n type: 'list',\n message: 'What would you like to do?',\n choices: ['View Products for Sale', 'View Low Inventory', 'Add to Inventory', 'Add New Product']\n }\n ]).then(function(answers) {\n if (answers.menu === 'View Products for Sale') {\n viewProducts();\n }\n else if (answers.menu === 'View Low Inventory') {\n lowInventory();\n }\n else if (answers.menu === 'Add to Inventory') {\n addInventory();\n }\n else if (answers.menu === 'Add New Product') {\n addProduct();\n }\n });\n}", "constructor(messenger) {\n // Initialize.\n this.autoUpdater = autoUpdater\n this.messenger = messenger\n // Wire events.\n // @see https://www.electron.build/auto-update\n console.log('asdf')\n this.autoUpdater.on('checking-for-update', (e, i) => {\n this.messenger.info('Checking for update.')\n })\n this.autoUpdater.on('download-progress', (e, i) => {\n // tslint:disable-next-line:no-console\n console.log('autoUpdater: download-progress: ', e, i)\n })\n this.autoUpdater.on('update-available', (e, i) => {\n // tslint:disable-next-line:no-console\n console.log('autoUpdater: update-available: ', e, i)\n this.messenger.info(\n 'A new version is available. Downloading in background.'\n )\n })\n this.autoUpdater.on('update-not-available', (e, i) => {\n // tslint:disable-next-line:no-console\n console.log('autoUpdater: update-not-available: ', e, i)\n this.messenger.info('Your application is up to date.')\n })\n this.autoUpdater.on('update-downloaded', (e, i) => {\n this.messenger.info('An update was downloaded.')\n this.quitAndInstall()\n })\n }", "function postInstallAction(isError) {\n\tpostUpdateAction(isError);\n}", "function install() {}", "function install() {}", "function install() {}", "function install() {}", "function updateApp(config) {\n var appType = config.apptype;\n if (appType !== 'native' && appType !== 'hybrid_remote' && appType !== 'hybrid_local') {\n console.log(outputColors.red + 'Unrecognized app type: \\'' + appType + '\\'.' + outputColors.reset + 'App type must be native, hybrid_remote, or hybrid_local.');\n usage();\n process.exit(4);\n }\n\n // Copy dependencies\n copyDependencies(config, function(success, msg) {\n if (success) {\n if (msg) console.log(outputColors.green + msg + outputColors.reset);\n console.log(outputColors.green + 'Congratulations! You have successfully updated your app.' + outputColors.reset);\n } else {\n if (msg) console.log(outputColors.red + msg + outputColors.reset);\n console.log(outputColors.red + 'There was an error updating the app.' + outputColors.reset);\n }\n });\n}", "function startApp() {\n\tinquirer\n\t\t.prompt([\n\t\t\t{\n\t\t\t\tname: 'startApp',\n\t\t\t\ttype: 'confirm',\n\t\t\t\tmessage: 'Would you like to assemble a team?',\n\t\t\t},\n\t\t])\n\t\t.then((res, err) => {\n\t\t\tif (err) console.error(err);\n\t\t\tif (res.startApp) {\n\t\t\t\taddManager();\n\t\t\t} else {\n\t\t\t\tprocess.exit();\n\t\t\t}\n\t\t});\n}", "function startApp(){\n inquirer.prompt({\n name: 'start',\n type: 'list',\n message: 'What would you like to do?',\n choices: [\n 'Department',\n 'Role',\n 'Employee',\n 'Update Employee Role',\n 'View Departments',\n 'View Roles',\n 'View Employees',\n 'All Done!'\n ]\n })\n .then((answer) => {\n switch (answer.start){\n case 'Department':\n addDepartment();\n break;\n case 'Role':\n addRole();\n break;\n case 'Employee':\n addEmployee();\n break;\n case 'Update Employee Role':\n updateRole();\n break;\n case 'View Departments':\n viewDepartments();\n break;\n case 'View Roles':\n viewRoles();\n break;\n case 'View Employees':\n viewEmployees();\n break;\n case 'All Done!':\n console.log('Finished!');\n process.exit();\n break;\n }\n }\n )}", "function updateInfoPrompt () {\n return inquirer.prompt ([\n {\n type: \"list\",\n name: \"itemToUpdate\",\n message: \"What would you like to update?\",\n choices: [\n \"The role for an existing employee\"\n ]\n }\n ])\n }", "function runDesktop() {\n distributor.run();\n bindMenu();\n }", "function updateCurrentQuantity (err, results) {\n if (err) {\n console.log(err)\n }\n console.log('Updated!')\n mainMenu()\n}", "function updates() {\n var checked = $(\"#updates\").is(\":checked\");\n track('Options', 'Latest updates', 'Latest updates feature', checked);\n if (checked) {\n localStorage.feature_latestupdates = true;\n showMessage(\"Feature 'latest updates' enabled.\");\n } else {\n localStorage.feature_latestupdates = false;\n showMessage(\"Feature 'latest updates' disabled.\");\n }\n}", "updateActiveAddons() {\n logger.debug(\"Updating add-on states\");\n for (let [, addon] of this.addonDB) {\n let newActive = (addon.visible && !addon.disabled && !addon.pendingUninstall);\n if (newActive != addon.active) {\n addon.active = newActive;\n this.saveChanges();\n }\n }\n\n Services.prefs.setBoolPref(PREF_PENDING_OPERATIONS, false);\n }", "runUpdate() {\n this.utils.log(\"\");\n this.utils.log(\"******************* Running update ******************* \");\n this.utils.log(\"\");\n\n // Reset update flags\n this.updateTweets = false;\n this.updateStatus = false;\n\n // Process any new tweets before performing other operations\n this.checkTrackedTweets().then(() => {\n // Process any mentions\n this.checkMentions().then(() => {\n // Save the status file if needed\n if (this.updateTweets || this.updateStatus) {\n this.dataHandler.saveStatus(this.botStatus);\n }\n });\n\n // Post a normal tweet\n this.actionHandler.postTweet(this.generator.generateResponse());\n\n });\n }", "function updateInstallationRequest(appConfig) {\r\n return update(appConfig, oldEntry => {\r\n if (!oldEntry) {\r\n throw ERROR_FACTORY.create(\"installation-not-found\" /* INSTALLATION_NOT_FOUND */);\r\n }\r\n return clearTimedOutRequest(oldEntry);\r\n });\r\n}", "updateSoho() {\n this.applicationmenu.updated();\n }" ]
[ "0.6529961", "0.63500094", "0.6310466", "0.62678844", "0.61116886", "0.59876883", "0.59263605", "0.5832421", "0.5810761", "0.5805487", "0.58005667", "0.5796299", "0.576113", "0.5694946", "0.56922966", "0.55574274", "0.5548117", "0.552466", "0.5483094", "0.5480218", "0.5464473", "0.5414999", "0.54000914", "0.5376877", "0.537114", "0.53593266", "0.5357919", "0.53576463", "0.5351046", "0.53372216", "0.53372216", "0.53372216", "0.5304739", "0.53036356", "0.52727324", "0.5272523", "0.52620286", "0.5258454", "0.52570605", "0.5244351", "0.52430284", "0.52269995", "0.5210739", "0.51918906", "0.5172321", "0.5172321", "0.5172321", "0.5172321", "0.51614934", "0.5152937", "0.5127848", "0.5125921", "0.51190376", "0.5113222", "0.5107046", "0.51047987", "0.5102951", "0.5101904", "0.5092022", "0.5085378", "0.5058607", "0.50530803", "0.5032301", "0.5020401", "0.5020401", "0.50107706", "0.50107706", "0.5006216", "0.50060344", "0.5005402", "0.5001772", "0.4987306", "0.4985762", "0.4971364", "0.49703416", "0.4969878", "0.49588755", "0.49441788", "0.49382162", "0.49382162", "0.49319565", "0.49294126", "0.49258265", "0.4925458", "0.49110377", "0.48948452", "0.48948452", "0.48948452", "0.48948452", "0.48920086", "0.4884942", "0.48729113", "0.48395506", "0.4838995", "0.48280466", "0.48267764", "0.48265505", "0.48237437", "0.48212016", "0.48133552" ]
0.63585895
1
This is used to load cart values that are stored after refreshing the page
function onLoadCartNumbers() { let productNum = localStorage.getItem('cartNum'); if(productNum) { document.querySelector('.cart span').textContent = productNum; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function loadCart() {\n productsInCart = JSON.parse(sessionStorage.getItem('shoppingCart'));\n }", "function loadCart(){\n cart = JSON.parse(sessionStorage.getItem('revonicCart')); // fetching original object items using JSON parse. \n }", "function populateCartOnLoad() {\n let cartItems = localStorage.getItem('cartItems');\n if (cartItems) {\n let cartItemsArray = JSON.parse(cartItems);\n document.querySelector('.cart-items').innerText = cartItemsArray.length;\n sendItemsToCartUI(cartItemsArray);\n grandTotals(cartItemsArray);\n }\n}", "function loadCart(){\r\n inames = JSON.parse(sessionStorage.getItem(\"inames\"));\r\n iprice = JSON.parse(sessionStorage.getItem(\"iprice\"));\r\n showCart();\r\n}", "function init() {\n\t\tvar loadItems = sessionStorage.getItem('load');\n\t\tif(loadItems == null) {\n\t\t\t$.when($.ajax({\n\t\t\t\t'url' : 'js/cart.json',\n\t\t\t\t'method' : 'POST',\n\t\t\t\t'dataType' : 'json',\n\t\t\t\t'success' : function(data){\n\n\t\t\t\t\tfor(var i=0; i < data.productsInCart.length; i++) {\n\t\t\t\t\t\tdata.productsInCart[i].p_total_price = (+data.productsInCart[i].p_quantity * +data.productsInCart[i].p_price);\n\t\t\t\t\t\tdata.productsInCart[i].p_total_originalprice = (+data.productsInCart[i].p_quantity * +data.productsInCart[i].p_originalprice);\n\t\t\t\t\t}\n\t\t\t\t\t// data.productsInCart\n\t\t\t\t\tconsole.log(data.productsInCart);\n\t\t\t\t\tsessionStorage.setItem('cartItems', JSON.stringify(data));\n\t\t\t\t}\n\t\t\t})).done(function(){\n\t\t\t\treloadCart();\t\n\t\t\t\tsessionStorage.setItem('load', true);\n\t\t\t});\n\t\t}else{\n\t\t\treloadCart();\n\t\t}\t\n\t}", "function loadCart2(){\r\n inames = JSON.parse(sessionStorage.getItem(\"inames\"));\r\n iprice = JSON.parse(sessionStorage.getItem(\"iprice\"));\r\n displayCart();\r\n}", "function reloadCart() {\n\t\tvar cart = sessionStorage.getItem('cartItems');\n\t\tvar prdcts = JSON.parse(cart);\n\t\tloadCart(prdcts);\n\t}", "function LoadCart()\n{\n\tCart = JSON.parse(localStorage.getItem(\"ItemsInShoppingCart\"));\n\tDisplayItems();\n\tadd();\n\t//if the cart is not empty display cost and total items in cart page\n\t\tif (TotalCount()>0) {\n\tdocument.getElementById('notempty').innerHTML = \"Total Items in Cart \" + String(TotalCount());\n\tdocument.getElementById('order').innerHTML = \" \";\n\tdocument.getElementById('currentprice').innerHTML = String(TotalCost());}\n\t\n}", "function initCartItems() {\n const lsCartItems = JSON.parse(localStorage.getItem(\"cartItems\"));\n if (lsCartItems) {\n setCartItems(lsCartItems);\n }\n }", "function onLoadCartNumbers(){\n let productNumbers = localStorage.getItem('cartNumbers');\n if(productNumbers){\n document.querySelector('.spanCart').textContent = productNumbers;\n }\n }", "function loadCart() {\n\n\tif (document.cookie) {\n\t\n\t\tvar cookie = JSON.parse(document.cookie);\n\n\t\tclearCart();\n\t\tcookie.cart.forEach(function(val) {\n\t\t\n\t\t\tif (searchIDRequest(val.id)) {\n\t\t\t\tdocument.getElementById('cartCounter' + val.id).value = val.counter;\n\t\t\t}\n\t\t});\n\t\t\n\t\tcalcCartPrice();\n\t}\n\n}", "function onLoadCart() {\n let productNumbers = localStorage.getItem('cartNumbers');\n let storedCartList = localStorage.getItem('cartItems');\n if(productNumbers) {\n document.querySelector('.cart-qty span').textContent = productNumbers;\n }\n if(productNumbers && document.URL.includes(\"5cart.html\")) {\n document.querySelector('.items-in-cart span').textContent = productNumbers;\n //update max value of input with actual number of cart items\n var input = document.getElementById(\"cartItemToDelete\");\n input.setAttribute(\"max\",productNumbers);\n } \n if(storedCartList != null && document.URL.includes(\"5cart.html\")) {\n document.querySelector('.myCartList span').textContent = storedCartList;\n }\n }", "function readStoredCart() {\n\n\tlet carrito = sessionStorage.getItem('std_carrito');\n if (carrito == null || typeof carrito == \"undefined\"\n || carrito == \"\") {\n\n carrito = new Array;\n\n } else {\n\n carrito = JSON.parse(carrito);\n\n }\n\n if (Array.isArray(carrito)) {\n \tcarrito.forEach((item)=>{\n \t\taddProductInCart(item.id,item.name,item.price); \n \t});\n }\n\n \n let carritoprice = sessionStorage.getItem('std_importecarrito');\n if (carritoprice == null || typeof carritoprice == \"undefined\"\n || carritoprice == \"\") {\n\n carritoprice = 0.00;\n\n } else {\n\n carritoprice = parseFloat(carritoprice);\n\n }\n $('#importe_total_carrito').html(carritoprice);\n\n\t\n\n let carritoenvio = sessionStorage.getItem('std_enviocarrito');\n if (carritoenvio == null || typeof carritoenvio == \"undefined\"\n || carritoenvio == \"\") {\n\n carritoenvio = 0.00;\n\n } else {\n\n carritoenvio = parseFloat(carritoenvio);\n\n } \n\t$('#gastos_envio_carrito').html(carritoenvio + '€');\n\n}", "function getCartData() {\n const pizzaFromCartLS = JSON.parse(localStorage.getItem('cart'));\n if (pizzaFromCartLS) {\n pizzaFromCartLS.forEach((pizza, i) => cart[i] = pizza);\n }\n}", "function loadCartNumbs(){\n let productNumb = localStorage.getItem('cartNumbers');\n\n document.querySelector('.cart span').textContent = productNumb;\n}", "function cartOnLoad() {\n\t// define variable who get the number of item on local storage\n\tconst produitNbr = localStorage.getItem(\"produit\");\n\tconst cartIcon = document.querySelector(\".cart-icon\");\n\t// if we have product in cart on local storage\n\tif (produitNbr) {\n\t\t// display the value on the cart\n\t\tinCart.innerText = produitNbr;\n\t\tcartIcon.classList.add(\"text-info\");\n\t}\n\tif (produitNbr === \"0\") {\n\t\tcartIcon.classList.remove(\"text-info\");\n\t}\n}", "function onLoadCartNumbers() {\n let productNumbers = localStorage.getItem('cartNumbers');\n if (productNumbers) {\n document.querySelector('.cart span').textContent = productNumbers;\n }\n}", "function getCartData() {\n return JSON.parse(localStorage.getItem('cart'));\n}", "function onLoadCartNumber() {\n let productNumber = localStorage.getItem('cartNumbers');\n if (productNumber) {\n $('.cart-icon span').text(productNumber);\n }\n }", "function loadedCart() {\n let cartNumber = localStorage.getItem(\"cartQuantity\");\n\n if (cartNumber)\n document.querySelector(\".cart-number\").innerHTML = cartNumber;\n}", "loadFromLocalStorage() {\n\t\t\tvar json = localStorage.getItem(\"cart\");\n\t\t\tthis.items = json ? JSON.parse(json) : [];\n\t\t}", "function loadMyCart() {\n let userId = sessionStorage.getItem('userId');\n marketService.getUser(userId)\n .then((userInfo) => {\n displayMyCart(userInfo);\n }).catch(handleError);\n }", "function loadCart() {\n\n var cartItems = JSON.parse(localStorage.getItem('cart')) || [];\n cart = new Cart(cartItems);\n console.log(cart);\n\n}", "function onLoadCartNumbers(){\r\n let productNumbers = localStorage.getItem('cartNumbers');\r\n if(productNumbers){\r\n document.querySelector('.cart span').textContent = productNumbers;\r\n }\r\n}", "function loadCartNumbers() {\n let productNumbers = localStorage.getItem(\"cartNumbers\");\n if (productNumbers) {\n document.querySelector('.cart span').textContent = productNumbers;\n }\n}", "function buildCartList() {\n // $.getJSON('./cart.json', function(data){\n // // console.log(typeof(data))\n // cart = data[\"items\"];\n\n // });\n cartObj = JSON.parse(localStorage.getItem(\"cart\"))\n cart = cartObj[\"items\"];\n // console.log(cart);\n buildCartListHelper();\n}", "function getCart(){\n let items = localStorage.getItem(\"cartProducts\");\n items = JSON.parse(items);\n\n let container = document.querySelector(\".products\");\n\n // let baskettotal = document.querySelector(\".basket-total\");\n\n let totalCartCost = localStorage.getItem('totalCost');\n totalCartCost = JSON.parse(totalCartCost);\n displayCheckout();\n // run only if items and .cart-container is running.\n if (items && container) {\n container.innerHTML = '';\n\n // check the values of the cart items\n Object.values(items).map((item) => {\n //display each basket item.\n container.innerHTML += `\n <div class=productItem>\n <div class=\"item-title\">\n <div>${item.itemName}</div>\n <img src=\"${item.imgurl}\" style=\"width:60px; height:60px;\">\n </div>\n <div class=\"item-price\">$${item.price},00</div>\n <div class=\"item-quantity\">${item.numInCart}</div>\n <div class=\"item-total\">$${item.price * item.numInCart},00</div>\n </div>\n `\n });\n }\n}", "function showCartNum() {\n //check that all required objects exist in local storage and create local variables with their values\n var itemsInCart;\n var inCart;\n if (sessionStorage.getItem(\"itemsInCart\") == null) {\n //exit function if itemsInCart doesn't exist\n alert(\"add: itemsInCart does not exist\");\n return;\n }\n else {\n itemsInCart = JSON.parse(sessionStorage.getItem(\"itemsInCart\"));\n }\n if (sessionStorage.getItem(\"inCart\") == null) {\n alert(\"add: inCart does not exist\");\n return;\n }\n else {\n inCart = JSON.parse(sessionStorage.getItem(\"inCart\"));\n }\n //update html\n document.getElementById(\"cartsize\").innerHTML = itemsInCart.toString();\n //update html for each item in the store\n for (var i = 0; i < inCart.length; i++) {\n var id = \"incart\" + i;\n document.getElementById(id).innerHTML = \"Amount in cart: \" + inCart[i].toString();\n }\n}", "function cart(){\n let cartNumStored = JSON.parse(localStorage.getItem('cartNum'));\n if (cartNumStored) {\n let currCart = document.getElementById('cart');\n currCart.textContent = (cartNumStored);\n }\n let priceSum = JSON.parse(localStorage.getItem('priceSum'))\n if (priceSum == null) {\n localStorage.setItem('priceSum', JSON.stringify(0))\n }\n updateCart();\n}", "function initCart() {\n\t// If there's a cart already in the local storage... (PC)\n\tif (localStorage.cart) {\n\t\t// put the storage into our live array (PC)\n\t\tcartStorageToArray();\n\t\t// update the cart icon badge in the nav bar (PC)\n\t\tupdateCartIcon();\n\t\t// update the shopping cart modal with the existing entries (PC)\n\t\tpopulateCartModal();\n\t}\n}", "function loadCartItems() {\n\n products = JSON.parse(localStorage.getItem('cart'))\n if (products !== null) {\n ids = Object.keys(products);\n $.ajax({\n type: \"GET\",\n url: \"/api/cart_products\",\n data: {'ids[]': ids},\n success: function (response) {\n if(response.length > 0) {\n setCartRows(response)\n } else {\n\n $('#cart_items').html(`<div class=\"row justify-content-center\"> \n <h3 class=\"text-grey\">\n Cart Empty\n </h3>\n </div>`);\n }\n },\n error: function (response) {\n console.log(response);\n },\n }); \n } else {\n $('#cart_items').html(html);\n }\n \n }", "function cart() {\n let cartNumStored = JSON.parse(localStorage.getItem('cartNum'));\n if (cartNumStored) {\n let currCart = document.getElementById('cart');\n currCart.textContent = (cartNumStored);\n }\n let priceSum = JSON.parse(localStorage.getItem('priceSum'))\n if (priceSum === null) {\n localStorage.setItem('priceSum', JSON.stringify(0))\n }\n}", "function getCart() {\n \n return JSON.parse(localStorage.getItem(\"cart\"))\n\n}", "function loadData() {\n sizeJSON = localStorage != null ? localStorage[\"size\"] : null;\n cartDataJSON = localStorage != null ? localStorage[\"cartData\"] : null;\n if (cartDataJSON != null && sizeJSON != null && JSON != null) {\n try {\n size = JSON.parse(sizeJSON);\n cartData = JSON.parse(cartDataJSON);\n }\n catch (err) {\n // ignore errors while loading...\n }\n }\n }", "function getCart(){\n return localStorage.getItem(\"cart\");\n }", "function loadCart() {\n\tvar _cart = JSON.parse(getCookie(\"cart\"));\n\tfor(var i in _cart){\n\t\tconsole.log(_cart[i])\n\t\tconsole.log(i)\n\t}\n\t//\tconsole.log(_cart)\n\tvar _str = JSON.stringify(_cart)\n\t\t//\tconsole.log(typeof _str)\n\t\t//\talert(_str == \"{}\")\n\t\t//\tvar _str = \"\"\n\tif (!_cart || _str == \"{}\") {\n\t\t$(\".shopping_box\").html(\"\")\n\t\t$(\".shopping_box\").css(\"display\", \"none\")\n\t\t$(\".login_tips\").css(\"display\", \"block\")\n\t\t$(\".shopping_total\").css(\"display\", \"none\")\n\t\t$(\".pay_box\").css(\"display\", \"none\")\n\t\t$(\".exchange\").css(\"display\", \"none\")\n\t\t\t//\t\t$(\".shopping_box\").attr(\"asd\",\"asd32r\")\n\t} else {\n\t\t$(\".shopping_box\").css(\"display\", \"block\")\n\t\t$(\".login_tips\").css(\"display\", \"none\")\n\t\t$(\".shopping_total\").css(\"display\", \"block\")\n\t\t$(\".pay_box\").css(\"display\", \"block\")\n\t\t\t//\t\talert($)\n\t\t$(\".shopping_box\").html(\"\")\n\t\t\t//\t\t$(\".cart_box_has\").html(\"\");\n\t\t$.ajax({\n\t\t\turl: \"json/cart.json\",\n\t\t\tsuccess: function(date) {\n\t\t\t\tvar _len = date.length\n\t\t\t\tvar _date_index = 0;\n\t\t\t\t$(\".shopping_box\").html(\"\")\n\t\t\t\tfor (var i = 0; i < _len; i++) {\n\t\t\t\t\tif (_cart[date[i].id]) {\n\t\t\t\t\t\t_str1 = \"\"\n\t\t\t\t\t\tvar _total = parseInt(_cart[date[i].id]) * parseInt(date[i].list.newprice)\n\t\t\t\t\t\t_str1 = \"<div date_index ='\" + _date_index + \"' class='cart_good clearfix'><div class='cart_code'>\" + date[i].id + \"</div><div class='cart_name clearfix'><div class='cart_good_img'><a href='javascript:;'><img src='\" + date[i].list.src[0] + \"'/></a><div class='cart_good_sec'><img src='\" + date[i].list.src[0] + \"'/></div></div><div class='cart_good_txt'>\" + date[i].list.name + \"</div></div><div class='cart_oldp'>¥<span>\" + date[i].list.oldprice + \"</span></div><div class='cart_newp'>¥<span>\" + date[i].list.newprice + \"</span></div><div class='cart_num'><div class='cart_num_addsub'><span class='sub_btn' date_index = '\" + _date_index + \"'><img src='img/cart/btn_minus.gif'/></span><input type='text' readonly='readonly' id='cart_good_num' value='\" + _cart[date[i].id] + \"' /><span class='add_btn' date_index = '\" + _date_index + \"'><img src='img/cart/btn_plus.gif'/></span></div></div><div class='cart_total'>¥<span>\" + _total + \"</span></div><div class='cart_del'><a class='del' date_id = '\" + date[i].id + \"' href='javascript:;'>删除</a></div></div>\"\n\t\t\t\t\t\t_date_index++;\n\t\t\t\t\t\t$(\".shopping_box\").append(_str1)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tboundEvent()\n\n\t\t\t}\n\t\t})\n\n\t}\n}", "function loadShoppingCart() {\n console.log('setShoppingcart')\n \n // reset cart and values\n document.getElementsByClassName('all-cart-product')[0].innerHTML = \"\";\n total_items = 0;\n total = 0;\n\n // render cartItem to cart\n for (var i= 0; i< cart.length; i++){\n\n //update total numer of items\n total_items = total_items + cart[i].quantity;\n\n //update total price\n total = total + (cart[i].price * cart[i].quantity);\n\n var display_individualisation = cart[i].hasIndividualisation === false ? 'none': 'block';\n\n var individualisationwrapper = '';\n for (var k = 0; k < cart[i].individualisation.length; k++){\n individualisationwrapper+= '<p style=\"display:'+display_individualisation+'; font-family: '+cart[i].individualisation[k].font+'; font-size: 1.1em;\">'+cart[i].individualisation[k].value+'</p>';\n }\n \n\n var div = document.createElement('div');\n div.className = \"single-cart clearfix\";\n div.innerHTML = '<div class=\"single-cart clearfix\">\\\n <div class=\"cart-photo\">\\\n <a href=\"#\"><img src=\"img/cart/'+ cart[i].image +'\" alt=\"\"></a>\\\n </div>\\\n <div class=\"cart-info\">\\\n <h5><a href=\"#\">'+ cart[i].productname +'</a></h5>\\\n <p class=\"mb-0\">#'+ cart[i].itemId +' </p>\\\n <p class=\"mb-0\"><span data-i18n=\"cart-price-label\">Preis:</span> '+ cart[i].price.toLocaleString('de-DE', {maximumFractionDigits: 2, minimumFractionDigits: 2, minimumIntegerDigits:1 }) +' €</p>\\\n <p class=\"mb-0\"><span data-i18n=\"cart-quantity-label\">Stück:</span> '+ cart[i].quantity +' </p>\\\n <p style=\"display:'+display_individualisation+'; class=\"mt-20\">'+ individualisationwrapper +' </p>\\\n <span data-cartItemId=\"'+cart[i].cartItemId +'\" onclick=\"removeItemfromCart(this)\" class=\"cart-delete\"><a href=\"#\"><i class=\"zmdi zmdi-close\"></i></a></span>\\\n <img style=\"display:'+display_individualisation+'; height:25px; width: 100%\" src=\"'+cart[i].decorImage+'\">\\\n </div>\\\n </div>'\n document.getElementsByClassName('all-cart-product')[0].appendChild(div);\n\n } // End for-loop\n\n // set badge number\n document.getElementsByClassName('cart-icon')[0].querySelector('span').innerHTML = total_items;\n\n //set number in detail hover view\n document.getElementsByClassName('cart-items')[0].querySelector('p').innerHTML = $.i18n( 'you have $1 {{plural:$1|item|items}} in your shopping bag', total_items );\n \n // render total price\n document.getElementsByClassName('cart-totals')[0].querySelector('span').innerHTML = total.toLocaleString('de-DE', {maximumFractionDigits: 2, minimumFractionDigits: 2, minimumIntegerDigits:1 }) + ' €';\n\n //disable cart button if cart is empty\n if(total_items === 0){\n document.getElementsByClassName('cart-bottom')[0].style.display = 'none';\n document.getElementsByClassName('all-cart-product')[0].style.display = 'none';\n \n }else{\n document.getElementsByClassName('cart-bottom')[0].style.display = 'block';\n document.getElementsByClassName('all-cart-product')[0].style.display = 'block';\n }\n \n}", "function loadCartItems() {\n subTotal = 0;\n carts = JSON.parse(sessionStorage.getItem(\"carts\")); //Get the cart object from sessionStorage\n // load the items in cart in the DOM for display on the UI\n let cartElement = document.getElementById(\"itemNos\");\n // Sizing the div to accomodate the no of items in the cart\n let strhtml = '<b>%itemCount%</b>';\n //Display the item count in the cart\n let strhtml2 = strhtml.replace(\"%itemCount%\", carts.length);\n // Insert the item count next to the cart icon in the DOM\n cartElement.insertAdjacentHTML(\"afterend\", strhtml2);\n cartElement = document.getElementById(\"total\");\n //Next, display all the items in the cart\n carts.forEach((itemCart, i) => {\n let strhtml = '<p><a href=\"#\">%itemDescription%</a> <span class=\"price\">%itemTotal%</span></p>'\n // Insert the HTLM statement for the items in the cart\n let strhtml2 = strhtml.replace(\"%itemDescription%\", itemCart.itemDescription);\n strhtml2 = strhtml2.replace(\"%orderQty%\", itemCart.orderQty);\n strhtml2 = strhtml2.replace(\"%itemTotal%\", formatNumber((itemCart.orderQty * itemCart.price)));\n cartElement.insertAdjacentHTML(\"afterbegin\", strhtml2);\n subTotal += Number(itemCart.price * itemCart.orderQty);\n\n }) // end of forEach\n if (document.querySelector(\"#homeDelivery\").checked) {\n deliveryCost = 500;\n } else {\n deliveryCost = 100;\n }\n totalAmt = subTotal + deliveryCost\n vat = totalAmt * 0.17; // VAT at 17%\n totalAmt += vat;\n cartElement = document.getElementById(\"cart\");\n // Sizing the div to accomodate the no of items in the cart\n strhtml = '<p>Delivery Cost <span class=\"price\" id=\"delivery\" style=\"color:black\"><b>%deliveryCost%</b></span></p>';\n //Display the item count in the cart\n strhtml2 = strhtml.replace(\"%deliveryCost%\", formatNumber(deliveryCost.toFixed()));\n // Insert the delivery cost, right after the cart items list\n cartElement.insertAdjacentHTML(\"beforeend\", strhtml2);\n strhtml = '<p>VAT @17% <span class=\"price\" id=\"vat\" style=\"color:black\"><b>%vat%</b></span></p>';\n //Display the item count in the cart\n strhtml2 = strhtml.replace(\"%vat%\", formatNumber(vat.toFixed()));\n // Insert the VAT cost, right after delivery cost\n cartElement.insertAdjacentHTML(\"beforeend\", strhtml2);\n\n cartElement = document.getElementById(\"cart\");\n // Sizing the div to accomodate the no of items in the cart\n strhtml = '<p>Total <span class=\"price\" id=\"totalAmt\" style=\"color:black\"><b>%totalAmt%</b></span></p>';\n //Display the item count in the cart\n strhtml2 = strhtml.replace(\"%totalAmt%\", formatNumber(totalAmt));\n // Insert the total cost, after vat\n cartElement.insertAdjacentHTML(\"beforeend\", strhtml2);\n}", "function onLoad() {\n\tdocument.getElementById(\"chosenq\").innerHTML = localStorage.getItem(\"qp\");\n\tdocument.getElementById(\"choseng\").innerHTML = localStorage.getItem(\"glazings\");\n\tdocument.getElementById(\"subtotalprice\").innerHTML = localStorage.getItem(\"price\");\n\tdocument.getElementById(\"prelimprice\").innerHTML = \"$ \" + localStorage.getItem(\"price\");\n\tdocument.getElementById(\"calctax\").innerHTML = (localStorage.getItem(\"price\") * 0.07).toFixed(2);\n\tdocument.getElementById(\"carttotal\").innerHTML = \"Shopping Cart (\" + localStorage.getItem(\"quant\") + \")\" ;\n\tdocument.getElementById(\"finalp\").innerHTML = \"$ \" + (localStorage.getItem(\"price\") * 1.07).toFixed(2);\n\tdocument.getElementById(\"cartquan\").src = localStorage.getItem(\"cartp\") ;\n}", "function storingCartItem() {\n \n /**\n * TODO: Create Product Object\n */\n let cartItem = product;\n cartItem.quantity = 1;\n cartItem.lensOption = updatePersonalizedFeatures();\n\n /**\n * TODO: Get \"cartItems\" value \n */\n let cartItems = JSON.parse(localStorage.getItem('cartItems'));\n\n\n /**\n * TODO: Update \"cartItems\" value with new Product Object (Push to the Array)\n */\n cartItems.push(cartItem);\n localStorage.setItem('cartItems', JSON.stringify(cartItems));\n\n // update cart badge\n let cartItemsQuantity = document.getElementById('cartItemQuantity');\n cartItemsQuantity.style.display = \"inline-block\";\n updateCartBadge();\n \n /**\n * TODO: Further \"Add to cart\" stuff....\n */\n //goToCartPage();\n \n console.log(cartItems);\n\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function reloadCart() {\n\n\tif(typeof noCartRefresh === \"undefined\"){\n\t\tnoCartRefresh = true;\n\t\tlog(\"reloadCart: cart is not up to date and has to be reloaded\");\n\t // Get the cart content - asynchronously\n\t\t$.ajax({\n\t\t\ttype: \"GET\",\n\t\t\turl: \"/web/json/getCart.htm\",\n\t\t\tdataType: \"json\",\n\t\t\tsuccess: function(cart){\n\t\t\t\trefreshCartContent(cart, '','');\n refreshArticlesCount(cart.articleItems);\n\t\t\t}\n\t\t});\n\t}\n}", "function getCart() {\n if (localStorage.getItem(\"cart\") === null) {\n $(\"#cartList\").prepend(\n '<h2 style=\"text-align:center\"><B>Cart is empty</b></h2>'\n );\n removeForm();\n } else {\n tempCart = JSON.parse(localStorage.getItem(\"cart\")); // cart = localstorage cart\n console.log(\"tempCart\");\n console.log(tempCart);\n for (let i = 0; i < tempCart.length; i++) {\n if (\n tempCart[i].amount == false ||\n tempCart[i].amount == undefined ||\n tempCart[i].amount == NaN\n ) {\n getAmount();\n }\n }\n combineDuplicates();\n console.log(\"newTempCart\");\n console.log(tempCart);\n cart = tempCart;\n setCart();\n }\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n \n}", "function loadProductToCart() {\n let vProduct = JSON.parse(localStorage.getItem('products'));\n let vOrderDetail = JSON.parse(localStorage.getItem('orderDetail'));\n if (vProduct) {\n vProduct.forEach((productId, index) => {\n $.ajax({\n url: `${G_BASE_URL}/products/${productId}`,\n method: 'get',\n dataType: 'json',\n success: (product) => {\n renderProductToCart(product, index, vOrderDetail[index]);\n },\n error: (e) => alert(e.responseText),\n });\n });\n }\n }", "function cartload(){\n\n $.ajax({\n url: '/load_cart_data',\n method: \"GET\",\n success: function (response) {\n var totalItem = response['totalcartcount'];\n $('#totalItem_in_cart').text(totalItem);\n }\n });\n}", "function setCartData(data) {\n localStorage.setItem('cart', JSON.stringify(data));\n}", "function setCart() {\n localStorage.setItem(\"cart\", JSON.stringify(cart)); //updates the cart\n}", "function cart(){\n let cart=localStorage.getItem(\"cart\");\n (cart)? showCart(cart) :alert(\"you don't have a cart yet!\")\n }", "function addtocart1() {\n\tvar a = JSON.parse(sessionStorage.getItem(\"Catalogue\"));\n\tvar b = JSON.parse(localStorage.getItem(\"Items\"));\n\tvar c = parseInt(localStorage.getItem(\"Amount\"));\n\n\tif (b == null) {\n\t\tb = [a[0]];\n\t} else {\n\t\tb.push(a[0]);\n\t};\n\n\tlocalStorage.setItem(\"Items\", JSON.stringify(b));\n\n\tlocalStorage.setItem(\"Amount\", c += a[0].price);\n\talert(\"The current total of the items is R\" + c);\n}", "function onLoadCartNumber() {\n let productNumbers = getItemFromLocalStorage('productsCart');\n if (productNumbers != null) {\n var broj = 0;\n productNumbers.forEach((value) => {\n broj += value.quantity;\n });\n // console.log(broj);\n displayCartData();\n\n // let numberOfProducts = productNumbers.length;\n document.querySelector('#itemNumber').textContent = broj;\n } else {\n emptyCartData();\n }\n}", "function updateCart() {\n emptyCart();\n let items = JSON.parse(localStorage.getItem('items'));\n if(items !== null) {\n if(typeof items.forEach !== \"function\") {\n items = [items];\n }\n items.forEach(function(item) {\n $('#shoppingcart-items').append(\n \"<li class='cart-item'>\" +\n \"<span>\" + item.name + \"</span>\" +\n \"<span>\" + item.size + \"</span>\" +\n \"<span>\" + item.color + \"</span>\" +\n \"<span>\" + item.amount + \"</span>\" +\n \"<span class='cart-item-price'>\" + item.price + \"</span>\" +\n \"<a class='remove-item' href='#' data-item='\" + item.name + \"'><i class='fa fa-times' aria-hidden='true'></i></a>\" +\n \"</li>\");\n });\n localStorage.setItem('items-timestamp', (+ new Date() / 1000) );\n }else {\n removeAllStorage();\n \n }\n updateCounter();\n updateTotal();\n }", "function loadCartFromLocalStorage() {\n var data;\n\n if (localStorage && localStorage[LOCALSTORAGE_KEY]) {\n try {\n data = JSON.parse(localStorage[LOCALSTORAGE_KEY]);\n $cart = _.merge({}, data.cart || {});\n $lastSync = data.lastSync || 0;\n $meta = _.merge({}, data.meta || {});\n\n // console.info('Cart syncd with localStorage');\n } catch ($e) {\n $cart = _.merge({}, $empty);\n $lastSync = 0;\n\n // console.info('localStorage sync data not found.');\n }\n }\n\n return _this_;\n }", "function onLoadCartNumbers() {\r\n\tlet productNumbers = localStorage.getItem('cartNumbers');\r\n\tif (productNumbers) {\r\n\t\tdocument.getElementById('count').textContent = productNumbers;\r\n\t}\r\n}", "function renderCart() {\r\n loadCart();\r\n clearCart();\r\n showCart();\r\n}", "function displayCartItems () {\r\n // get cart items div and clear it\r\n const cartItemsDiv = document.getElementById('cartItems')\r\n cartItemsDiv.innerHTML = ''\r\n\r\n // retrive the cart and the catalogue fro storage\r\n const cart = JSON.parse(sessionStorage.getItem('cart'))\r\n const catalogue = JSON.parse(sessionStorage.getItem('catalogue'))\r\n\r\n // check if the cart is not empty\r\n if (cart.length !== 0) {\r\n let id = 0 // initiaise the id\r\n // iterate through the cart list\r\n cart.forEach(index => {\r\n // retrive the item object based on the index\r\n const item = catalogue[Number(index)]\r\n // display the item\r\n displayItem(item, id)\r\n // increment the id\r\n id++\r\n })\r\n\r\n // display the checkout div\r\n $('#checkoutDiv').css({ visibility: 'visible' })\r\n // get the total div and clear it\r\n const divTotal = document.getElementById('divTotal')\r\n divTotal.innerHTML = ''\r\n\r\n // create a h5 elemnt for the sub-total\r\n const subTotal = document.createElement('h5')\r\n subTotal.setAttribute('id', 'subtotalCartPrice')\r\n subTotal.style.textAlign = 'right'\r\n\r\n // create a h5 elemnt for the VAT\r\n const VATtotal = document.createElement('h5')\r\n VATtotal.setAttribute('id', 'VAT')\r\n VATtotal.style.textAlign = 'right'\r\n\r\n // create a h5 elemnt for the discount\r\n const discount = document.createElement('h5')\r\n discount.setAttribute('id', 'discount')\r\n discount.style.textAlign = 'right'\r\n discount.style.color = 'green'\r\n\r\n // create a h4 elemnt for the total\r\n const total = document.createElement('h4')\r\n total.setAttribute('id', 'totalCartPrice')\r\n total.style.textAlign = 'right'\r\n\r\n // create a check-out button\r\n const checkOutButton = document.createElement('button')\r\n checkOutButton.setAttribute('class', 'btn btn-outline-secondary')\r\n checkOutButton.setAttribute('onclick', 'checkout()') // handler function on click\r\n checkOutButton.setAttribute('id', 'checkOutButton')\r\n checkOutButton.style.float = 'right'\r\n checkOutButton.style.color = 'green'\r\n\r\n // create a cart icon\r\n const cartIcon = document.createElement('i')\r\n cartIcon.setAttribute('class', 'fas fa-shopping-cart')\r\n cartIcon.innerHTML = ' CHECKOUT'\r\n\r\n // add the icon the button\r\n checkOutButton.appendChild(cartIcon)\r\n\r\n // apped to the total div\r\n divTotal.appendChild(subTotal)\r\n divTotal.appendChild(VATtotal)\r\n divTotal.appendChild(discount)\r\n divTotal.appendChild(total)\r\n divTotal.appendChild(checkOutButton)\r\n\r\n // calculate the total & display it\r\n getCartTotal()\r\n } else {\r\n // hide notification and checkout div if cart is empty\r\n $('#checkoutDiv').css({ visibility: 'hidden' })\r\n $('#cartCounter').css({ visibility: 'hidden' })\r\n\r\n // if cart empty, clear the cart items div\r\n cartItemsDiv.innerHTML = ''\r\n // create a h4 element to display the 'cart empty' text\r\n const text = document.createElement('h4')\r\n text.setAttribute('class', 'text-center')\r\n text.innerHTML = 'Cart Empty'\r\n // add the text to the cart items div\r\n cartItemsDiv.appendChild(text)\r\n }\r\n}", "function displayCheckout(){\n\n let productNumb = localStorage.getItem('cartNumbers');\n let totalCartCost = localStorage.getItem('totalCost');\n\n $('.basket-total-cost').html(\"Basket Total (\"+ productNumb +\" items): $\"+totalCartCost + \",00\");\n\n}", "function loadCart(products){\n\t\tvar source = $(\"#my-cart-template\").html();\n\t\tvar template = Handlebars.compile(source);\n\t\t$(\"#my-cart\").append(template(products));\n\n\t\tvar currency = products.productsInCart[0].c_currency;\n\t\tvar subTotalAmount = calculateSubTotal(products);\n\t\tvar discountAmount = subTotalAmount * calculateDiscount(products);\n\t\tvar pcv = calculatePromoCode();\n\t\tvar sa = calculateShipping();\n\t\tvar estimatedTotal = subTotalAmount - discountAmount - pcv + sa;\n\n\t\t//display calculated values here\n\n\t\t$(\"#count\").html(products.productsInCart.length);\n\t\t$(\"._cur\").html(currency);\n\t\t$(\".subtotal_amount\").html(displayCurrency(subTotalAmount));\n\t\t$(\"._discount_amount\").html(displayCurrency(discountAmount));\n\t\t$(\".promo_applied_amount\").html(displayCurrency(pcv));\n\t\t$(\".shipping_amount\").html(displayCurrency(sa));\n\t\t$(\".estimated_total_amount\").html(displayCurrency(estimatedTotal));\n\t\t$(\"#e_o_l\").prev().css(\"display\", \"none\");;\n\t}", "function onLoadProducts() {\n\tvar lsc = window.localStorage.length;\n\tfor (i = 0; i < lsc; i++) {\n\t\titem = JSON.parse(window.localStorage.getItem(i));\n\t\tvar itemKey = window.localStorage.key(i);\n\t\tif (item === null) {\n\t\t\tbreak;\n\t\t} else {\n\t\t\tvar quantityCount = document.getElementById(\"quantityCount\");\n\t\t\tquantityCount.innerText = item.quantity;\n\t\t\tdocument.getElementById(\"quantityCount\").style.visibility = \"visible\";\n\t\t}\n\t}\n}", "function loadCartContent() {\n // DVARS: Gets the information from the URL bar\n var formData = location.search.slice(1);\n formData = formData.replace(/\\+/g, \" \");\n formData = decodeURIComponent(formData);\n var formFields = formData.split(/[&=]/g);\n // DLOOP: Loops through the storeItems array\n for (var i = 0; i < storeItems.length; i++) {\n // DVARL: Gets the index of each item needed\n var currentItemID = storeItems[i][4],\n itemPriceIndex = formFields.indexOf(`${currentItemID}price`),\n itemQTYIndex = formFields.indexOf(`${currentItemID}qty`),\n itemEngravingIndex = formFields.indexOf(`${currentItemID}eng`);\n // DIFDO: If their is an item ordered then it display the item with its information\n if (formFields[itemQTYIndex + 1] != '0') {\n // DVARL: Creates a bunch of nodes and caculates out the item price\n var itemHTML = document.createElement('div'),\n nameHTML = document.createElement('h3'),\n imageHTML = document.createElement('img'),\n priceHTML = document.createElement('input'),\n qtyHTML = document.createElement('input'),\n engravingHTML = document.createElement('input'),\n itemsPrice = parseFloat(formFields[itemPriceIndex + 1].replace('$', \"\")) * parseFloat(formFields[itemQTYIndex + 1]);\n // DDOES: Edits the nameHTML and imageHTML to display the correct information\n nameHTML.textContent = storeItems[i][0];\n imageHTML.src = `Images/store/${storeItems[i][0]}/${storeItems[i][1][0]}`;\n // DDOES: Edits the priceHTML node\n priceHTML.type = \"text\";\n priceHTML.name = `${storeItems[i][4]}price`;\n priceHTML.classList = storeItems[i][4];\n priceHTML.id = \"itemPrice\";\n priceHTML.value = `$${itemsPrice.toFixed(2)}`;\n priceHTML.readOnly = \"readonly\";\n // DDOES: Edits the qtyHTML node\n qtyHTML.type = \"number\";\n qtyHTML.name = `${storeItems[i][4]}qty`;\n qtyHTML.classList = storeItems[i][4];\n qtyHTML.id = \"itemQty\";\n qtyHTML.min = 0;\n qtyHTML.value = formFields[itemQTYIndex + 1];\n qtyHTML.readOnly = \"readonly\";\n // DDOES: Edits the engravingHTML node\n engravingHTML.type = \"text\";\n engravingHTML.name = `${storeItems[i][4]}eng`;\n engravingHTML.id = \"itemEngraving\";\n engravingHTML.classList = storeItems[i][4];\n engravingHTML.maxLength = 10;\n engravingHTML.value = formFields[itemEngravingIndex + 1];\n engravingHTML.readOnly = \"readonly\";\n // DDOES: appends the nodes to their respective nodes\n itemHTML.appendChild(nameHTML);\n itemHTML.appendChild(imageHTML);\n itemHTML.appendChild(priceHTML);\n itemHTML.appendChild(qtyHTML);\n itemHTML.appendChild(engravingHTML);\n document.getElementById('cart').appendChild(itemHTML);\n };\n };\n // DVARL: Gets the information out of the formFields array and caculates values need to be applied\n var totalCountIndx = formFields.indexOf('tCount'),\n totalCostIndex = formFields.indexOf('tCost'),\n totalCostAmount = parseFloat(formFields[totalCostIndex + 1].replace('$', \"\")).toFixed(2),\n submitButton = document.createElement('input'),\n itemCount = document.createElement('input'),\n cost = document.createElement('input');\n // DDOES: Edits the submitButton node\n submitButton.type = \"submit\";\n submitButton.id = \"submitButton\";\n submitButton.value = \"Checkout\";\n submitButton.classList = \"button\";\n // DDOES: Edits the itemCount node\n itemCount.type = \"number\";\n itemCount.name = \"tCount\";\n itemCount.id = \"itemCount\";\n itemCount.value = formFields[totalCountIndx + 1];\n itemCount.readOnly = \"readonly\";\n // DDOES: Edits the cost node\n cost.type = \"text\";\n cost.name = \"tCost\";\n cost.id = \"itemCost\";\n cost.value = `$${totalCostAmount}`;\n cost.readOnly = \"readonly\";\n // DDOES: appends the nodes to their respective nodes\n document.getElementById('cart').appendChild(submitButton);\n document.getElementById('cart').appendChild(itemCount);\n document.getElementById('cart').appendChild(cost);\n}", "function renderCart() {\n loadCart();\n showCart();\n}", "get cartItems() {\n //return store.cartItems; //added*\n return JSON.parse(this.storage.getItem(this.CART_KEY));\n }", "function displayCart() {\n let cartItems = localStorage.getItem(\"productsInCart\");\n cartItems = JSON.parse(cartItems);\nconsole.log(cartItems);\nlet cartCost = localStorage.getItem(\"totalCost\");\nlet productContainer = document.querySelector(\".products\");\n\n\nif(cartIems && productContainer){\n productContainer.innerHTML = '';\n\n Object.values(cartItems)\n .map(item=>{productContainer.innerHTML += `<div class=\"product\"> <ion-icon name=\"close-circle\"></ion-icon>\n <img src=\"./images/${item.tag}.jpg\"> \n <span>${item.name}</span></div>`\n\n `<div class = \"price\">$${item.price}.00</div>`\n `<div class = \"quantity\"><ion-ionic class=\"decrease\" name=\"arrow-dropleft-circle\"></ion-icon>\n <span>${item.inCart}</span>\n\n <ion-ionic class=\"increase\" name=\"arrow-dropright-circle\"> </ion-icon></div>`\n `<div class=\"total\"> $${item.inCart * item.price},00 </div>` \n });\n\n productContainer.innerHTML += `<div class=\"basketTotalContanier\">\n <h4 class =\"basketTotalTitle\"> Basket Total </h4>\n <h4 class =\"basketTotal\">$${cartCost}.00 </h4>`;\nconsole.log(productContainer);\n}\n}", "function updateCart(){\n\t\tstorage(['items', 'subtotal'], function(err, col){\n\t\t\t//console.log(\"Cart Collection - \" + JSON.stringify(col));\n\n\t\t\t//items = col[0];\n\t\t\t//subtotal = col[1];\n\n\t\t\tif(console) console.log(\"Items in Cart: \" + items);\n\t\t\tif(console) console.log(\"Subtotal of Cart: \" + subtotal);\n\t\t\t\n\t\t\t// update DOM Here\n\t\t\tdocument.getElementById( _options.itemsEleId ).innerHTML = items;\n\t\t\tdocument.getElementById( _options.subtotalEleId ).value = \"$\" + subtotal.toFixed(2);\n\n\t\t\t// reset default quantity input fields of products\n\t\t\tPRODUCTS.updateProducts();\n\t\t});\n\t}", "function loadReviewCart() {\n var cartObj = [];\n\n if (sessionStorage.getItem(\"showPreviousCart\") == \"1\") {\n //checks if call is to show previous cart, then assign previous cart object to cartObj\n if (localStorage.getItem(\"previousCart\") != null && localStorage.getItem(\"previousCart\") != '' && localStorage.getItem(\"previousCart\") != \"[]\") {\n cartObj = JSON.parse(localStorage.getItem(\"previousCart\"));\n }\n\n }\n else {\n //else shows current cart\n if (localStorage.getItem(\"cart\") != null && localStorage.getItem(\"cart\") != '' && localStorage.getItem(\"cart\") != \"[]\") {\n cartObj = JSON.parse(localStorage.getItem(\"cart\"));\n }\n }\n if (cartObj.length > 0) {\n\n var cartItemBlock = '';\n for (var i = 0; i < cartObj.length; i++) {\n //Loop thru cart object for each product and prepares the row for each products\n\n var product = productResult.filter(function (obj) {\n return (obj[1] == cartObj[i].ProductID);\n });\n //creates the row with product info.\n cartItemBlock += '<tr><td class=\"product-col\"><figure class=\"product-image-container\"><a href=\"javascript:\" class=\"product-image\"> <img id=\"reviewProductImage\" src=\"ProductImages/' + product[0][3] + '\" alt=\"product\"> <input type=\"hidden\" id=\"reviewProductID\" /> </a> </figure> <div class=\"widget widget-categories\"> <h4 class=\"widget-title\">' + product[0][2] + '</h4> <ul class=\"list\">@@VariantOptions</div> </td> <td><div style=\"vertical-align:bottom; padding: 20px 0px 20px 0px;\"><button onclick=\"editCart(\\'' + product[0][1] + '\\')\" class=\"btn btn-xs-edit btn-info\" type=\"button\"><i class=\"fa fa-edit\"></i></button></div><div style=\"vertical-align:bottom\"> <button data-rowindex=\"' + cartObj[i].CartRowIndex + '\" class=\"btn btn-xs-delete btn-danger\" type=\"button\"><i class=\"fa fa-trash\"></i></button></div></td></tr>';\n\n //find the selected variants from cartItemVariants\n var variantList = $.map(cartObj[i].cartItemVariant, function (value, key) {\n return [[key, value]];\n });\n\n //prepares the <li> list for each variants\n var variantBlock = '<li><a href=\"javascript:\">Quantity : <span class=\"\">' + cartObj[i].Quantity + '</span></a></li>';\n\n for (var j = 0; j < variantList.length; j++) {\n //loop thru each selected variant and finds all the details of that selected variant.\n var currentVariant = productVariantsResult.filter(function (obj) {\n return (obj[2] == variantList[j][1] && obj[0] == cartObj[i].ProductID);\n });\n\n if (variantList[j][0] == \"Color\") {\n\n variantBlock += '<li><a href=\"javascript:\">Color: <span class=\"\">' + currentVariant[0][4] + '</span> | <div style=\"background-color: ' + variantList[j][1] + '; height: 20px; width: 20px; display: inline-block; margin-bottom: -5px;\"></div></a> </li>';\n }\n else {\n variantBlock += '<li><a href=\"javascript:\">' + variantList[j][0] + ': <span class=\"\">' + currentVariant[0][4] + '</span></a></li>';\n }\n }\n variantBlock += '<li><a href=\"javascript:\">Created Date: <span class=\"\">' + cartObj[i].CreatedDate + '</span></a></li>';\n\n /*Completes the <tr> by replacing @@VariantOptions with prepared <li> list of variants*/\n cartItemBlock = cartItemBlock.replace(\"@@VariantOptions\", variantBlock);\n }\n //loads the all prepared html\n $('#reviewCart').html(cartItemBlock);\n\n }\n else {\n if (sessionStorage.getItem(\"showPreviousCart\") == \"1\") {\n $('#reviewCart').html('<tr><td colspan=\"3\">No Previous Cart..</td></tr>');\n }\n else {\n $('#reviewCart').html('<tr><td colspan=\"3\">No Items..</td></tr>');\n }\n $('#btnSubmitOrder').addClass('disabled');\n }\n if (sessionStorage.getItem(\"showPreviousCart\") == \"1\") {\n //if previous cart is loaded. all unwanted buttons are hidden.\n $('.btn-xs-delete').hide();\n $('.btn-xs-edit').hide();\n $('#activeBreadCrumb').text('Previous Cart');\n $('#btnShowCurrentCart').removeClass('hide');\n $('#btnShowPreviousCart').addClass('hide');\n\n sessionStorage.setItem(\"showPreviousCart\", \"\");\n }\n\n}", "function displaycart() {\n let cartItems = localStorage.getItem(\"productsInCart\");\n cartItems = JSON.parse(cartItems);\n console.log(cartItems)\n // for basket total price\n let totalPrice = localStorage.getItem(\"totalPrice\");\n // to display shopping products \n let productsIncart = document.querySelector(\".products\");\n if (cartItems && productsIncart) {\n productsIncart.innerHTML = \"\";\n // getting only product object from cartitems\n let cartItemsArray = Object.values(cartItems);\n console.log(Object.values(cartItems))\n //mapping of each item\n cartItemsArray.map(item => {\n // for each product in cart\n productsIncart.innerHTML += `\n <div class= \"product\">\n <ion-icon class=\"remove-button\" name = \"close-circle\"></ion-icon>\n <img src=\"./img/${item.tag}.jpg\">\n <span>${item.name}</span>\n </div>\n <div class= \"price\"> ${item.price}</div>\n <div class= \"quantity\">\n <ion-icon class = \"increase\" name=\"add-circle-outline\"></ion-icon> \n <span>${item.inCart}</span>\n <ion-icon class = \"decrease\" name=\"remove-circle-outline\"></ion-icon> \n </div>\n <div class= \"total\">\n ${item.inCart * item.price}\n </div>\n `;\n });\n console.log(totalPrice)\n // for basket total in cart.html\n productsIncart.innerHTML += `\n <div class= \"basketTotalContainer\">\n <h4 class= \"basketTotalTitle\"> Basket Total </h4>\n <h4 class= \"basketTotal\"> ${totalPrice}.00</h4> \n </div>\n `;\n }\n changingQuantityOfCartItems();\n RemoveCartItem();\n\n\n}", "function getCart() {\n return cart;\n}", "function loadCart() {\n // getting items stored in getCart and placing them in ss\n var ss = getCart()\n var total = 0\n for (var item of ss) {\n // cloning an html element so that we can have a template for how our cart items should........... #cloneItem\n var element = $(\"#CloneItem\").clone()\n // getting the id and defining the item name through the id\n element.attr(\"id\", item)\n // getting the item name based on id based key\n element.find(\".name\").text(laptops[item].name)\n // adding tax\n total += laptops[item].price * 1.14\n element.find(\".price\").text((laptops[item].price * 1.14).toFixed(0))\n element.find(\".img-fluid\").attr(\"src\", laptops[item].image)\n\n $(\".content-fluid\").append(element)\n }\n\n $(\".CartTotalAndCheckout .total\").text(\"R\" + total.toFixed(0))\n\n $(\".RemoveFromCart\").click(function() {\n var removedItem = $(this).parents(\".card\")\n var id = removedItem.attr(\"id\")\n total -= laptops[id].price * 1.14\n $(\".CartTotalAndCheckout .total\").text(\"R\" + total.toFixed(0))\n removeFromCart(id)\n removedItem.remove()\n })\n\n // preventing the refresh to load problem\n $(\".checkout\").click(function(e) {\n e.preventDefault()\n console.log($(\"dialog\"))\n $(\"dialog\").get(0).showModal()\n })\n\n // implimenting delivery costs\n var checkoutWithExtra = 0\n $(\".CartTotalAndCheckout .total\").text((total * 1.14).toFixed(0))\n $(\"dialog .options > label input\").change(function() {\n if ($(this).is(\":checked\") && $(this).attr(\"id\") == \"delivery\") {\n $(this).parent().parent().find(\".hidden\").slideDown()\n var checkoutWithExtra = (total * 1.17).toFixed(0)\n $(\".CartTotalAndCheckout .total\").text(checkoutWithExtra)\n } else {\n $(this).parent().parent().find(\".hidden\").slideUp()\n var checkoutWithExtra = (total * 1.14).toFixed(0)\n $(\".CartTotalAndCheckout .total\").text(checkoutWithExtra)\n }\n });\n\n // implimenting coupon application keywords is ---- couponWin ---- use to test the functionality of this \n // default value is false because the coupon hasnt been applied yet\n // when coupon already applied a 30% discounts\n var alreadyAppliedCoupon = false\n $(\"dialog .coupon button\").click(function() {\n if ($(this).prev().val() == \"couponWin\" && !alreadyAppliedCoupon) {\n alreadyAppliedCoupon = true\n total *= 0.70\n var checkoutWithExtra = total * 1.14\n if ($(\"dialog .options > label input#delivery\").is(\":checked\"))\n checkoutWithExtra *= 1.03\n $(\".CartTotalAndCheckout .total\").text(checkoutWithExtra.toFixed(0))\n }\n })\n}", "function saveCart() {\n sessionStorage.setItem('shoppingCart', JSON.stringify(productsInCart));\n }", "_loadCustomerCarts(currentCartId) {\n const customerId = this.customerId;\n\n this.customerRenderer.showLoadingCarts();\n $.get(this.router.generate('admin_customers_carts', {customerId})).then((response) => {\n this.customerRenderer.renderCarts(response.carts, currentCartId);\n }).catch((e) => {\n showErrorMessage(e.responseJSON.message);\n });\n }", "function test() {\n var carnum = sessionStorage.items_in_cart\n\n document.getElementById(\"cartnum\").innerText = items_in_cart;\n\n if (sessionStorage.items_in_cart == undefined) {\n sessionStorage.items_in_cart = 0;\n sessionStorage.cart_products = new Array();\n }\n document.getElementById(\"cartnum\").innerHTML = sessionStorage.items_in_cart;\n}", "function first(){\r\n\r\n if(sessionStorage.getItem(\"items\") == null){\r\n document.getElementById('cart').innerHTML = \"Begin adding items to your order and they will show up here\";\r\n }else{\r\n loadCart2();\r\n }\r\n}", "function displayCart(){\r\n let cartItems = localStorage.getItem(\"productsInCart\");\r\n cartItems = JSON.parse(cartItems);\r\n let productContainer = document.querySelector\r\n (\".product\");\r\n let cartCost = localStorage.getItem('totalCost');\r\n\r\n console.log(cartItems);\r\n if( cartItems && productContainer){\r\n productContainer.innerHTML = '';\r\n Object.values(cartItems).map(item =>{\r\n productContainer.innerHTML += ` \r\n <div class = \"product\">\r\n <ion-icon name=\"close-circle\"></ion-icon>\r\n <span>${item.name}M</span>\r\n </div>\r\n <div class=\"price\">P${item.price}.00</div>\r\n <div class=\"quantity\">\r\n <span>${item.inCart}</span>\r\n </div>\r\n <div class=\"total\">\r\n P${item.inCart * item.price}.00\r\n </div> \r\n `;\r\n });\r\n\r\n productContainer.innerHTML += ` \r\n <div class=\"basketTotalContainer\">\r\n <h4 class=\"basketTotalTitle\">\r\n Basket Total\r\n </h4>\r\n <h4 class=\"basketTotal\">\r\n P${cartCost}.00\r\n </h4>\r\n `;\r\n }\r\n}", "function displayCart(){\n let cartItems = localStorage.getItem(\"productsInCart\");\n cartItems = JSON.parse(cartItems);\n let productContainer = document.querySelector(\".products\");\n let cartCost = localStorage.getItem('totalCost');\n if(cartItems && productContainer ){\n productContainer.innerHTML = '';\n Object.values(cartItems).map(item => {\n productContainer.innerHTML += `\n <div class=\"product\">\n <ion-icon name=\"close-circle-outline\"></ion-icon>\n <img scr=\"products/productsAlgemeen/dist/productFotos/${imagePath+images.Afbeeldingsnaam}.jpg\">\n <span>${item.Productnaam}</span>\n </div>\n <div class=\"price\">$${item.Eenheidsprijs},00</div>\n <div class=\"quantity\">\n <ion-icon class=\"decrease\" name=\"arrow-dropleft-circle\"></ion-icon>\n <span>${item.inCart}</span>\n <ion-icon class=\"increase\" name=\"arrow-dropright-circle\"></ion-icon>\n </div>\n <div class=\"total\">\n $${item.inCart * item.Eenheidsprijs},00\n </div>\n `;\n });\n\n productContainer.innerHTML += `\n <div class=\"basketTotalContainer\">\n <h4 class=\"basketTotalTitle\">Basket Total</h4>\n <h4 class=\"basketTotal\">€${cartCost},00</h4>\n `;\n\n }\n}", "function renderCart() {\n\n loadCart();\n clearCart();\n showCart();\n updateCounter();\n}", "function Cart1() {\r\n\r\n let vneck = clothingPrices.clothes1;\r\n sessionStorage.setItem(\"vneck\", vneck);\r\n\r\n}", "function setCart(cart) {\n window.localStorage.setItem('cart', JSON.stringify(cart));\n}", "function getLocatStoragedata() {\n return JSON.parse(localStorage.getItem('cartItems') || JSON.stringify(itemList.items));\n }", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n cart.updateCounter();\n}", "function getCart() {\r\n if (sessionStorage.getItem(\"vneck\") != null) {\r\n let cartItem1 = document.createElement(\"p\");\r\n whatsInCart.appendChild(cartItem1);\r\n cartItem1.innerHTML = sessionStorage.getItem(\"vneck\");\r\n ItemStyler();\r\n }\r\n\r\n if (sessionStorage.getItem(\"African\") != null) {\r\n let cartItem2 = document.createElement(\"p\");\r\n whatsInCart.appendChild(cartItem2);\r\n cartItem2.innerHTML = sessionStorage.getItem(\"African\");\r\n ItemStyler();\r\n }\r\n\r\n if (sessionStorage.getItem(\"kapi\") != null) {\r\n let cartItem3 = document.createElement(\"p\");\r\n whatsInCart.appendChild(cartItem3);\r\n cartItem3.innerHTML = sessionStorage.getItem(\"kapi\");\r\n ItemStyler();\r\n }\r\n\r\n if (sessionStorage.getItem(\"formal\") != null) {\r\n let cartItem4 = document.createElement(\"p\");\r\n whatsInCart.appendChild(cartItem4);\r\n cartItem4.innerHTML = sessionStorage.getItem(\"formal\");\r\n ItemStyler();\r\n }\r\n\r\n if (sessionStorage.getItem(\"fiasco\") != null) {\r\n let cartItem5 = document.createElement(\"p\");\r\n whatsInCart.appendChild(cartItem5);\r\n cartItem5.innerHTML = sessionStorage.getItem(\"fiasco\");\r\n ItemStyler();\r\n }\r\n\r\n if (sessionStorage.getItem(\"nice\") != null) {\r\n let cartItem6 = document.createElement(\"p\");\r\n whatsInCart.appendChild(cartItem6);\r\n cartItem6.innerHTML = sessionStorage.getItem(\"nice\");\r\n ItemStyler();\r\n }\r\n\r\n if (sessionStorage.getItem(\"design\") != null) {\r\n let choicesTotal = document.createElement(\"p\");\r\n cartPrice.appendChild(choicesTotal);\r\n choicesTotal.innerHTML = \"Total: R\" + myPrice;\r\n PriceStyler();\r\n\r\n } else { //Should the cart be empty, display the following message in a pragraph that is appended to the selected ID\r\n let empty = document.createElement(\"p\");\r\n empty.innerHTML = \"Your Cart is currently empty\";\r\n whatsInCart.appendChild(empty);\r\n ItemStyler();\r\n $(\"#orderOptions\").hide();\r\n $(\".firstBigHeading\").hide();\r\n }\r\n\r\n}", "function init() {\n // Use local storage to preserve the quantities' states between page reloads\n var quantities = JSON.parse(localStorage.getItem('quantities'));\n if (!quantities) {\n quantities = []; var n = PRODUCT_DATA.length;\n for (var i = 0; i < n; ++i) quantities[i] = 0;\n localStorage.setItem('quantities', JSON.stringify(quantities));\n }\n\n var html_string = ''; var subtotal = 0.0;\n PRODUCT_DATA.forEach(function(item, i) {\n var quantity = quantities[i]; var cost = item['price'];\n var price = quantity*cost; var price_text = price === 0 ? '$0' : '$'+price.toFixed(2).toString();\n subtotal += price;\n html_string +=\n '<div id=\"' + item['id'].toString() + '\" class=\"product\"> \\\n <div class=\"row\"> \\\n <div class=\"col-md-3\"> \\\n <img class=\"img-fluid mx-auto d-block image\" src=\"' + item['image'] + '\"> \\\n </div> \\\n <div class=\"col-md-8\"> \\\n <div class=\"info\"> \\\n <div class=\"row\"> \\\n <div class=\"col-md-5 product-name\"> \\\n <div class=\"product-name\"> \\\n <span>' + item['name'] + '</span> \\\n <div class=\"product-info\"> \\\n <div>Cost: <span class=\"value product-cost\">$' + cost.toFixed(2).toString() + '</span></div> \\\n <div>Type: <span class=\"value product-type\">' + item['product_type'] + '</span></div> \\\n </div> \\\n </div> \\\n </div> \\\n <div class=\"col-md-4 quantity\"> \\\n <label for=\"quantity\">Quantity:</label> \\\n <input type=\"number\" value=\"' + quantity.toString() + '\" min=\"0\" max=\"99\" maxlength=\"2\" class=\"form-control quantity-input\"> \\\n </div> \\\n <div class=\"col-md-3 price\"> \\\n <span>' + price_text + '</span> \\\n </div> \\\n </div> \\\n </div> \\\n </div> \\\n </div> \\\n </div>';\n });\n $('.items').append(html_string);\n update_totals(subtotal);\n}", "function GetStoreList() {\n var values = fetch(`store/stores`)\n .then(res => {\n if (!res.ok) {\n console.log('unable to fetch stores')\n throw new Error(`Network response was not ok (${res.status})`);\n }\n return res.json();\n })\n .then(res => {\n // console.log(res);\n sessionStorage.setItem('store', JSON.stringify(res));\n // the below are all valid ways to get the values back from the storage object.\n console.log(sessionStorage.getItem('store'));\n // console.log(sessionStorage.store);\n // console.log(sessionStorage['store']);\n //sessionStorage.clear()\n\n })\n .catch(err => console.log(`There was an error ${err}`));\n let store = JSON.parse(sessionStorage.getItem('store'));\n console.log(store);\n var form = document.createElement(\"form\");\n select = document.createElement(\"select\");\n select.name = \"stores\";\n select.id = \"stores\"\n form.appendChild(select);\n for (const val of store) {\n var option = document.createElement(\"option\");\n option.value = val;\n option.text = val.charAt(0).toUpperCase() + val.slice(1);\n select.appendChild(option);\n }\n\n function addToCart() {\n let currentOrder = document.getElementById(\"currentOrder\");\n let tempProduct = document.createElement(\"li\");\n let value = JSON.parse(this.value);\n currentOrderList.push(value);\n tempProduct.innerHTML = \"<Label>\" + value[\"productName\"] + \" : $\" + value[\"productPrice\"] + \"</Label> \";\n let currentPrice = parseFloat(document.getElementById(\"price\").innerHTML);\n currentPrice += parseFloat(value[\"productPrice\"]);\n document.getElementById(\"price\").innerHTML = parseFloat(currentPrice).toFixed(2);\n currentOrder.appendChild(tempProduct);\n };\n\n\n select.onchange = function () {\n productsMain = document.getElementById(\"products\");\n document.getElementById(\"orders\").innerHTML = \"\";\n while (productsMain.firstChild) {\n productsMain.removeChild(productsMain.firstChild);\n }\n var products = fetch(`store/products`)\n .then(res => {\n if (!res.ok) {\n console.log('unable to fetch products')\n throw new Error(`Network response was not ok (${res.status})`);\n }\n return res.json();\n })\n .then(res => {\n //console.log(res);\n sessionStorage.setItem('products', JSON.stringify(res));\n // the below are all valid ways to get the values back from the storage object.\n //console.log(sessionStorage.getItem('products'));\n // console.log(sessionStorage.products);\n //console.log(sessionStorage['products']);\n //sessionStorage.clear()\n\n })\n .catch(err => console.log(`There was an error ${err}`));\n products = JSON.parse(sessionStorage.products);\n console.log(products);\n for (const val of products) {\n var button = document.createElement(\"button\");\n button.onclick = addToCart;\n button.innerHTML = \"Add to Cart\";\n button.value = JSON.stringify(val);\n button.style.width = \"85px\";\n button.style.height = \"25x\";\n var option = document.createElement(\"Label\");\n option.innerHTML = \"<Label>\" + val[\"productName\"] + \" : $\" + val[\"productPrice\"] + \"</Label> \";\n var div = document.createElement(\"div\");\n div.appendChild(option);\n div.appendChild(button);\n productsMain.appendChild(div);\n // option.text = val.charAt(0).toUpperCase() + val.slice(1);\n //productsMain.appendChild(option);\n }\n };\n\n document.getElementById(\"listofstores\").appendChild(select);\n}", "function cartItem() {\n\titemsArray = JSON.parse(localStorage.getItem('item'));\n\tif (itemsArray !== null) {\n\t\thtmlContent = `<i class=\"fas fa-shopping-cart\"> <span>(${\n\t\t\titemsArray.length\n\t\t})</span> </i>`;\n\t\t$('.fa-shopping-cart')\n\t\t\t.parent()\n\t\t\t.html(htmlContent);\n\t} else {\n\t\thtmlContent = `<i class=\"fas fa-shopping-cart\"> <span>(0)</span> </i>`;\n\t\t$('.fa-shopping-cart')\n\t\t\t.parent()\n\t\t\t.html(htmlContent);\n\t}\n}", "function initiateCart() {\n window.page = 'shoppingCart';\n if (document.readyState == 'loading') {\n document.addEventListener('DOMContentLoaded', RemoveBTM)\n document.addEventListener('DOMContentLoaded', addItemToCart)\n } else {\n var quantityInputs1KG = document.getElementsByClassName('product-quantity-1kg-input')\n for (var i = 0; i < quantityInputs1KG.length; i++) {\n var input = quantityInputs1KG[i]\n input.addEventListener('change', quantityChanged)\n }\n loadShoppingCartItemsByUser();\n RemoveBTM()\n\n }\n}" ]
[ "0.81625164", "0.8090929", "0.7938621", "0.7830751", "0.7762661", "0.77029717", "0.75776607", "0.7565405", "0.753374", "0.74773914", "0.741326", "0.7387352", "0.73023784", "0.7295141", "0.7268452", "0.7234852", "0.723237", "0.7223062", "0.72082615", "0.7201361", "0.7199485", "0.71492726", "0.7134309", "0.71276", "0.711538", "0.7034627", "0.70294076", "0.70089537", "0.700592", "0.70051485", "0.6998716", "0.6973517", "0.69675916", "0.6961621", "0.69556296", "0.6953155", "0.6933657", "0.6905264", "0.6893774", "0.68923604", "0.68269545", "0.68269545", "0.68269545", "0.68269545", "0.68269545", "0.68269545", "0.68269545", "0.68269545", "0.68269545", "0.68269545", "0.68269545", "0.68269545", "0.68269545", "0.68269545", "0.68269545", "0.68269545", "0.68269545", "0.6825477", "0.68219405", "0.6821639", "0.6821454", "0.6821233", "0.6791881", "0.6757003", "0.67539275", "0.67516625", "0.6751504", "0.6748635", "0.6741298", "0.67391956", "0.6737636", "0.67360014", "0.6733083", "0.6724421", "0.6669584", "0.6661228", "0.6659609", "0.6654067", "0.66527873", "0.6651368", "0.66442144", "0.6626028", "0.6624596", "0.6622322", "0.6614122", "0.6609524", "0.66088474", "0.660691", "0.66024095", "0.6597422", "0.6595343", "0.6587033", "0.658007", "0.65654415", "0.6548461", "0.6548236", "0.65462136", "0.65453434", "0.6540581", "0.65374076" ]
0.7241475
15
This is used to store the amount in a cart
function cartNum(products) { let productNum = localStorage.getItem('cartNum'); productNum = parseInt(productNum); if(productNum) { localStorage.setItem('cartNum', productNum + 1); document.querySelector('.cart span').textContent = productNum + 1; } else { localStorage.setItem('cartNum', 1); document.querySelector('.cart span').textContent = 1; } setItems(products); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function updateQuantity() {\n let prod = this.closest(\".cart-item\");\n let prod_cost = prod.children[2].innerText.slice(1);\n prod.children[4].innerText = `$${Number(prod_cost)*this.value}`\n\n let z = JSON.parse(localStorage.getItem(\"CartItem\"));\n arr = [];\n for (let k = 0; k < Object.keys(z).length; k++) {\n if (z[k].name == prod.children[1].innerText) {\n z[k].quantity = this.value;\n }\n arr.push(z[k]);\n }\n localStorage.setItem(\"CartItem\", JSON.stringify(arr));\n}", "function totalCart() {\n\tlet total = 0;\n\tcart.forEach(function (product) {\n\t\ttotal = total + product.price * product.quantity;\n\t});\n\tdocument.getElementById(\"price_total\").textContent = total + \" €\";\n\tlocalStorage.setItem(\"totalCart\", total);\n}", "function addtocart1() {\n\tvar a = JSON.parse(sessionStorage.getItem(\"Catalogue\"));\n\tvar b = JSON.parse(localStorage.getItem(\"Items\"));\n\tvar c = parseInt(localStorage.getItem(\"Amount\"));\n\n\tif (b == null) {\n\t\tb = [a[0]];\n\t} else {\n\t\tb.push(a[0]);\n\t};\n\n\tlocalStorage.setItem(\"Items\", JSON.stringify(b));\n\n\tlocalStorage.setItem(\"Amount\", c += a[0].price);\n\talert(\"The current total of the items is R\" + c);\n}", "function setCart(){\n\t\tstorage.set({ \n\t\t\titems: 0, \n\t\t\tsubtotal: 0\n\t\t}, function(){\n\t\t\tupdateCart();\n\t\t});\n\t}", "function total() {\n let totalVal = 0;\n for (var i = 0; i < cartItems.length; i++) {\n totalVal += cartItems[i].price * cartItems[i].quantity\n }\n setCartTotal(totalVal)\n }", "function addSelectedItemToCart() { \n var itemsEl = document.getElementById('items').value;\n var quantityEl = document.getElementById('quantity').value;\n cart.addItem(itemsEl, parseInt(quantityEl));\n // console.log(cart.items[0].product);\n // console.log(cart.items[0].quantity); \n}", "total()\r\n\t{\r\n \t\tthis.cart = Cookie.get(this.settings.cookie_name);\r\n\r\n \t\tvar total = 0.00;\r\n \t\tlet i;\r\n\r\n \t\tfor (i = 0; i < this.cart.items.length; i++) {\r\n \t\t\ttotal += parseFloat(this.cart.items[i].price.amount) * this.cart.items[i].quantity;\r\n \t\t}\r\n\r\n \t\treturn total.toFixed(2);\r\n\t}", "function UpdateCart() {\n\n // get current text displaying for cart\n\tvar cart_num = parseInt(document.getElementById('cart_number').innerText);\n\n\t// get value from quantity drop down menu\n\tvar qty1 = document.getElementById('qty1').value;\n\tqty1 = parseInt(qty1);\n\t//console.log(qty1);\n\n\t// Add quantity selected to the total & update total\n\titem_number += qty1;\n\tcart_num = item_number;\n\tdocument.getElementById('cart_number').innerText = cart_num;\n // console.log(cart_num);\n //console.log(cart_num);\n\n window.localStorage.setItem('cart_count', JSON.stringify(cart_num));\n\n}", "cartPlusOne(product) {\r\n product.quantity = product.quantity + 1;\r\n }", "function addToCart(pizzaId){\n var key = 'pizza_' + pizzaId;\n var amount = parseInt(window.localStorage.getItem(key)) || 0;\n amount ++;\n window.localStorage.setItem(key, amount);\n updateOrdersButton();\n}", "function totalCost(product, qty) {\n let cartCost = localStorage.getItem('totalCost');\n\n if (cartCost != null) {\n cartCost = parseInt(cartCost);\n localStorage.setItem(\"totalCost\", cartCost + (product.price * qty));\n } else {\n localStorage.setItem(\"totalCost\", product.price * qty);\n }\n\n\n}", "function quanitityToCart(product) {\n let value = parseInt($(\"#amountOfBeer\").val());\n let isProductInCart = 0;\n for (let i = 0; i < cart.length; i++) {\n if (product.id === cart[i].id) {\n cart[i].inCart += value;\n isProductInCart++;\n }\n }\n if (isProductInCart == 0) {\n product.inCart = value;\n cart.push(product);\n }\n saveToLS();\n renderCart();\n}", "function addPrToCarrt() {\n var model = { prid: prid, total: parseInt($(\"#numb\").text()) };\n addToCart(model);\n}", "function carttotal() {\n //multipily the price by the number of items in the cart\n producttotal = price * itemcount;\n var formatproducttotal = currencyFormat(producttotal);\n //note we are updating the BTC and Lightning totals here we will have to refactor this code is we ever\n // have a lightning only version of the cart (as stated elsewhere in the notes)\n changeClassText(document.getElementById('sr-lightningtotal'), 'Pay '+formatproducttotal + ' satoshi');\n changeClassText(document.getElementById('sr-bitcointotal'), 'Pay '+formatproducttotal + ' satoshi');\n changeClassText(document.getElementById('sr-checkouttotal'), formatproducttotal);\n //update counter\n changeClassText(document.querySelector('.sr-count'), itemcount);\n //store product\n if (serverless == 0) {\n var url = serverurl + \"api/storeproduct?name=\" + name + \"&quantity=\" + itemcount + \"&btcaddress=\" + btcaddress + \"&price=\" + price;\n //call the store produt endpoint\n fetchurl(url, 'storeproduct')\n }\n }", "function addToCart() {\n\n\n\tvar cart = JSON.parse(localStorage.getItem(\"cart\"));\n\n\tif (cart === null) {\n\t\tvar cart = new Cart([]);\n\t}\n\n\tvar name = document.getElementById(\"item-name\").innerHTML;\n\tconsole.log(name);\n\tvar size = document.getElementById(\"size\").value;\n\tconsole.log(size);\n\tvar color = document.getElementById(\"color\").value;\n\tconsole.log(color);\n\tvar quantity = document.getElementById(\"quantity\").value;\n\tconsole.log(quantity);\n\n\n\tvar newItem = new Item(name, color, size, quantity);\n\n\tcart.items.push(newItem);\n\n\tvar cartTotalSize = parseInt(localStorage.getItem(\"cartSize\"));\n\n\tconsole.log(\"cartTotalSize: \" + cartTotalSize);\n\n\tif (typeof(cartTotalSize) === \"undefined\" || cartTotalSize === null || isNaN(cartTotalSize)) {\n\t\tcartTotalSize = 0;\n\t}\n\n\tcartTotalSize += parseInt(quantity);\n\n\tlocalStorage.setItem(\"cartSize\", cartTotalSize);\n\n\n\n\tlocalStorage.setItem(\"cart\", JSON.stringify(cart));\n\n\n\tvar itemCost = parseInt(newItem.quantity) * 10.00;\n\n\tconsole.log(\"itemCost: \" + itemCost);\n\n\tvar totalPrice = localStorage.getItem(\"price\");\n\n\tconsole.log(totalPrice);\n\n\tif (totalPrice === null || typeof(totalPrice) === \"undefined\" ) {\n\t\ttotalPrice = 0;\n\t\tconsole.log(itemTotal);\n\t}\n\n\ttotalPrice = parseInt(totalPrice);\n\ttotalPrice += itemCost;\n\tconsole.log(\"price: \" + totalPrice);\n\tlocalStorage.setItem(\"price\", totalPrice);\n\tconsole.log(localStorage.getItem(\"price\"));\n\n\tupdateNavBar();\n}", "function cart(){\n let cartNumStored = JSON.parse(localStorage.getItem('cartNum'));\n if (cartNumStored) {\n let currCart = document.getElementById('cart');\n currCart.textContent = (cartNumStored);\n }\n let priceSum = JSON.parse(localStorage.getItem('priceSum'))\n if (priceSum == null) {\n localStorage.setItem('priceSum', JSON.stringify(0))\n }\n updateCart();\n}", "function addProductToCart(productname, amountFromStorage) {\n let index = myCart.findIndex(item => item.product === productname);\n let amount = 0;\n\n if (index === -1 && amountFromStorage === 0) {\n amount = 1;\n myCart.push({ product: productname, amount: amount });\n //save this to sessionstorage\n let product = myCart.find(element => element.product === productname);\n saveToStorage(productname, JSON.stringify(product));\n }\n //check if the given parameter productAmount is greater than 0, this means we\n //get the value from session storage\n //set the exact amount in cart\n else if (amountFromStorage > 0) {\n myCart.push({ product: productname, amount: amountFromStorage });\n amount = amountFromStorage;\n }\n //else, the functions add and remove product use this method and you'll just want to update the\n //amount by 1\n else {\n myCart[index] = { product: productname, amount: ++amount };\n //save this to sessionstorage\n let product = myCart.find(element => element.product === productname);\n saveToStorage(productname, JSON.stringify(product));\n }\n\n /////update cart icon in the header with new items added\n\n //update the html of the productAmount shown\n updateProductAmountHtml(productname, amount);\n}", "function cart() {\n let cartNumStored = JSON.parse(localStorage.getItem('cartNum'));\n if (cartNumStored) {\n let currCart = document.getElementById('cart');\n currCart.textContent = (cartNumStored);\n }\n let priceSum = JSON.parse(localStorage.getItem('priceSum'))\n if (priceSum === null) {\n localStorage.setItem('priceSum', JSON.stringify(0))\n }\n}", "function increase() {\n var holdCount1 = count + 1;\n setCount(holdCount1);\n var holdItem1 = props;\n window.localStorage.setItem(JSON.stringify(holdItem1), holdCount1);\n cartContext.setCartTotal(calTotal());\n }", "function changeQuantity(element) {\n current_value = $(element).val();\n product_id = $(element).data('id');\n \n let total_price = 0;\n if (current_value <= 0) {\n current_value = $(element).val(1)\n alert('Invalid Quamtity value');\n }\n \n products[product_id] = current_value;\n localStorage.setItem('cart', JSON.stringify(products));\n \n for(var key in price_per_item) {\n total_price += getPricePerProductQuantity(key, price_per_item[key])\n }\n $('#total_price').text(total_price);\n }", "addProductAmount(id) {\n let product = shoppingCart.findById(id);\n product.amount++;\n document.getElementById('foodAmountCart-' + product.id).innerHTML = product.amount + 'x';\n document.getElementById('overall-shopping-cart-price-' + product.id).innerHTML = printPrice(product) + '€';\n }", "function addItemToCart() {}", "function addItemToCart() {}", "function totalCost(product){\n let itemPrice = parseFloat(product.price.replace(/,/g, '')) //You replace comma seperated price string with space to you can parse it to a float number\n let cartCost = localStorage.getItem('totalCost');\n \n console.log(cartCost)\n\n //check if cartCost exist already\n if (cartCost != null){\n cartCost = parseFloat(cartCost)\n localStorage.setItem(\"totalCost\", cartCost+itemPrice)\n } else{\n localStorage.setItem(\"totalCost\", itemPrice)\n }\n}", "function updateCartTab(value) {\n if (sessionStorage.getItem(\"itemTotal\") != null) {\n sessionStorage.setItem(\n \"itemTotal\",\n parseInt(sessionStorage.getItem(\"itemTotal\")) + parseInt(value)\n );\n } else {\n sessionStorage.setItem(\"itemTotal\", value);\n }\n showShowCartTab();\n }", "function addToCart(value){\n var quantity;\n var oldValue = parseInt(document.querySelector('.cart_number').innerText);\n if(value !== undefined){\n quantity = 1; // Ajout depuis More Product // +1\n } else {\n quantity = parseInt(document.querySelector('.quantities').value); // Ajout depuis la selection principale // +Quantity\n }\n document.querySelector('.cart_number').innerText = oldValue + quantity;\n // Idée pour plus tard : Ajouter un affichage des articles dans le panier\n}", "function updateTotal() {\n let price = JSON.parse(localStorage.getItem('currPrice'))\n let cartPrice = JSON.parse(localStorage.getItem('priceSum'))\n if (cartPrice){\n localStorage.setItem('priceSum', JSON.stringify(parseFloat(price) + parseFloat(cartPrice)))\n }\n else{\n localStorage.setItem('priceSum', JSON.stringify(parseFloat(price)))\n }\n displayCart()\n}", "function calcTotal() {\n // get the value and parse from session storage\n let cart = JSON.parse(sessionStorage.getItem('cart'));\n\n // define a total variable = 0\n let total = 0;\n\n // loop through all items in the cart\n for (let i in cart) {\n // add each item's price to total\n total += cart[i].price;\n }\n\n // return the total\n return total.toFixed(2);\n }", "function addToCart(){\n let name = \"Roll with \";\n let glaze = JSON.parse(localStorage.getItem('currGlaze'))\n let img = document.getElementById('originalImg').src;\n let qty = parseInt((document.getElementById('qtyNum').value));\n let cartNum = document.getElementById('cart').innerText\n cartNum = cartNum.replace('CART (', '')\n cartNum = cartNum.replace(')', '')\n localStorage.setItem(\"cartNum\", JSON.stringify(parseInt(cartNum) + qty));\n let price = (document.getElementById('currPrice').innerText)\n price = price.replace('Total: $', '')\n price = parseFloat(price)\n roll(name, glaze, img, qty, price, cartNum)\n updateCart()\n}", "function shipping(){\n\n let cart=localStorage.getItem('totalCost');\n cart = parseFloat(cart);\n\n console.log(cart);\n var shippingvalue=document.getElementsByClassName('price-shipping');\n\n let ordertotal=cart;\n\n for(let i=0;i<shippingvalue.length;i++){\n\n if(shippingvalue[i].checked){\n\n var itis=parseFloat(shippingvalue[i].value);\n \n console.log(itis);\n\n ordertotal=(ordertotal+itis).toFixed(2);\n\n localStorage.setItem('totalOrder',ordertotal);\n displayCart();\n }\n }\n}", "function addToCart(){\n//the function to add chosen door to a cart\n//and put it to a LOCAL STORAGE\nvar chosenItem = this.getAttribute('data-button-propName'); // chosen item is an unique item, chosen with a button click and added to CARTFORITEMS object\n if(cartForItems[chosenItem] != undefined){\n cartForItems[chosenItem] = cartForItems[chosenItem]+1;\n }else{\n cartForItems[chosenItem] = 1;\n }\n totalPrice += priceCollector[chosenItem].price;\nlocalStorage.setItem('addedToCartItems', JSON.stringify(cartForItems));\nlocalStorage.setItem('addedTotalPrice', JSON.stringify(totalPrice));\nconsole.log(cartForItems[chosenItem]);\nconsole.log(totalPrice);\nshowItemsInCart();\nrenderDiv();\n}", "function addItemToCart(e) {\n e.preventDefault();\n const { target } = e;\n if (target.classList.value !== \"product-box__btn\") {\n return;\n }\n const priceObj = target.parentNode.firstElementChild;\n const price = parseInt(priceObj.innerText);\n const qtyObj = priceObj.nextElementSibling.firstElementChild;\n // Regular expr.\n const re = /\\d+/gm;\n //input validation\n if (!re.test(qtyObj.value) || qtyObj.value <= 0) {\n alert(\"В поле введены некорректные данные!\");\n return false;\n }\n const qty = parseInt(qtyObj.value);\n qtyObj.value = \"\";\n cart.update(qty, price);\n}", "setAmount(state, data){ \r\n\t\t\tvar i = data.i\r\n\t\t\tvar count = data.count\r\n\t\t\tstate.basket[i].count = +count\t\r\n\r\n\t\t\tthis.dispatch(\"basket/saveBasket\")\r\n\t\t}", "_changeQuantity(productId) {\n const value = this.shadowRoot.querySelector('#chart_item_' + productId).value;\n\n const cartItem = this._findCartItem(productId);\n\n const index = this.cartItems.indexOf(cartItem);\n this.cartItems[index].quantity = value;\n this.cartItems = [...this.cartItems]; // this.cartItems[index] = cartItem['quantity'] + 1;\n // this.set('cartItems.' + index + '.quantity', cartItem['quantity'] + 1);\n\n localStorage.setItem('shop-cart', JSON.stringify(this.cartItems));\n this.dispatchEvent(new CustomEvent('change-cart-count', {\n bubbles: true,\n composed: true,\n detail: {}\n }));\n }", "function totalCost(products) {\r\n\tconsole.log(\"The product price is\", products.price);\r\n\tlet cartCost = localStorage.getItem('totalCost');\r\n\r\n\tconsole.log(\"my cartCost is\", cartCost);\r\n\t\r\n\tif(cartCost != null) {\r\n\t\tcartCost = parseInt(cartCost);\r\n\t\tlocalStorage.setItem(\"totalCost\", cartCost + products.price);\r\n\t} else {\t\r\n\tlocalStorage.setItem(\"totalCost\", products.price);\r\n\t}\r\n}", "function totalCost(response){\n console.log('The product price is', response.price /100);\n let cartCost = localStorage.getItem('totalCost');\n if(cartCost != null){\n cartCost = parseInt(cartCost);\n localStorage.setItem('totalCost', cartCost + response.price / 100);\n } else {\n localStorage.setItem('totalCost', response.price / 100);\n }\n }", "function addToCart() {\n let name = \"Roll with \";\n let glaze = JSON.parse(localStorage.getItem('currGlaze'))\n let img = document.getElementById('originalImg').src;\n let qty = parseInt((document.getElementById('qtyNum').value));\n let cartNum = document.getElementById('cart').innerText\n cartNum = cartNum.replace('CART (', '')\n cartNum = cartNum.replace(')', '')\n localStorage.setItem(\"cartNum\", JSON.stringify(parseInt(cartNum) + qty));\n let price = (document.getElementById('currPrice').innerText)\n price = price.replace('Total: $', '')\n price = parseFloat(price)\n roll(name, glaze, img, qty, price, cartNum)\n updateCart()\n displayCart()\n}", "function total() {\n var totalValue = 0;\n for (var i = 0; i < cart.length; i++) {\n totalValue += cart[i].itemPrice\n }\n return totalValue;\n}", "function totalCost(product, action){\n console.log('price of product', product.price)\n let totalCost =parseInt(localStorage.getItem('totalCost'))\n console.log('my total cost is ', totalCost)\n\n if(action == \"decrease\"){\n localStorage.setItem('totalCost', totalCost - product.price) \n } else if(action == \"increase\"){\n localStorage.setItem('totalCost', totalCost + product.price) \n\n }\n setCartValue()\n}", "function totalCost(product ){\r\n let cartCost = localStorage.getItem('totalCost');\r\n console.log(\"My cartCost is\", cartCost);\r\n console.log(typeof cartCost);\r\n\r\n if(cartCost != null){\r\n cartCost = parseInt(cartCost);\r\n localStorage.setItem(\"totalCost\", cartCost + product.price);\r\n } else {\r\n localStorage.setItem(\"totalCost\", product.price);\r\n }\r\n\r\n}", "add() {\n\t\torinoco.cart.add({ imageUrl: this.imageUrl, name: this.name, price: this.price, _id: this._id });\n\t}", "function updatePrice() {\n let currPrice = document.getElementById('currPrice');\n let qty = document.getElementById('qtyNum').value;\n let price = (5) * parseInt(qty);\n currPrice.innerText = 'Total: $' + parseFloat(price);\n localStorage.setItem('currPrice', JSON.stringify(parseFloat(price)))\n updateTotal()\n}", "handleAddItemToCart(item, quantity){\n var buyableItem = new BuyableItem(item, quantity);\n currentCart.push(buyableItem);\n this.setState({cartQuantity : this.calculateCartQuantity(currentCart)})\n localStorage.setItem(\"cart\", JSON.stringify(currentCart));\n this.readFromCart();\n }", "function updateCartTotal() {\n var cartItemContainer = document.getElementsByClassName('cart-items')[0]\n var cartRows = cartItemContainer.getElementsByClassName('cart-row')\n var total = 0\n var quantityN = 0\n for (var i = 0; i < cartRows.length; i++) {\n var cartRow = cartRows[i]\n var priceElement = cartRow.getElementsByClassName('cart-price')[0]\n var cartPriceItem = cartRow.getElementsByClassName('cart-price-item')[0]\n var quantityElement = cartRow.getElementsByClassName('cart-quantity-input')[0]\n\n var price = priceElement.innerText.replace(' đ', '')\n var replaceAllPrice = price.replaceAll('.','')\n\n var quantity = quantityElement.value\n total = total + (replaceAllPrice * quantity)\n quantityN = parseFloat(quantityN + Number(quantity))\n //Format price item\n cartPriceItemFormat = replaceAllPrice * Number(quantity)\n cartPriceItem.innerText = new Intl.NumberFormat('vi').format(cartPriceItemFormat)\n }\n total = Math.round(total)\n document.getElementsByClassName('cart-total-price')[0].innerText = new Intl.NumberFormat('vi').format(total)\n document.getElementsByClassName('cart-total-quantity')[0].innerText = quantityN\n}", "function currentQuantityCart() {\n\n}", "function updatecart() {\r\n //initialize the total variable with 0 (if we don't initialize it our cart will show NaN since it has no value at all)\r\n var total = 0\r\n //we get the value from the quantity input box and we check if it the user gave an input <= than 0 or not given an input at all. If this happened then >>\r\n // we set the value to 1 (there is no point in having a negative or zero or undefined quantity... it will also cause trouble in calculating the total price)\r\n var input = event.target\r\n if (input.value <= 0 || input.value == NaN) {\r\n input.value = 1\r\n }\r\n //cartitem_all gets the element of our shopping cart containing all cart items\r\n var cartitem_all = document.getElementsByClassName('cart-items')[0]\r\n // rows11 gets a list of all the cart rows where each row is a package we have in our shopping cart with all its data \r\n var rows11 = cartitem_all.getElementsByClassName('cart-row')\r\n // we create a loop that goes through every package in our cart (if existing) and executes the commands in {}\r\n for (var i = 0; i < rows11.length; i++) {\r\n // in cartRow we save the package element that we are processing in each time the loop runs\r\n var cartRow = rows11[i]\r\n // we get the price of that package and save it into \"priceElement\"\r\n var priceElement = cartRow.getElementsByClassName('cart-price')[0]\r\n // we get the quantity of that package and save it into \"quantityElement\" NOTE: Here we use [1] since when creating the element we have used the class >>\r\n // \"cart-quantity-input\" 2 times one for styling. So we need to call the 2nd one which is having the actual value\r\n var quantityElement = cartRow.getElementsByClassName('cart-quantity-input')[1]\r\n // we change the type of \"price\" from string to float so we can use it in a math equation. HOWEVER >>\r\n // Before doing so we replace the euro sign with nothing (we remove it) from our variable since we want only the number that makes sense for math equations\r\n var price = parseFloat(priceElement.innerText.replace('€', ''))\r\n // we get the value part of the quantityElement since it is the one containing the number value and we save it in \"quantity\"\r\n var quantity = quantityElement.value\r\n // this is an obvious math equation to calculate the total price. Note that we +total at the beginning since this is in a loop running for each package in the cart\r\n total = total + (price * quantity)\r\n }\r\n // we use the Math.round to avoid having numbers with too many decimals coming from a multiplication. We set them to be with only 2 decimals rounded which >>\r\n // make sense when talking about money\r\n total = Math.round(total * 100) / 100\r\n // we get the \"cart-total-price\" element and we write inside it the euro sign and the number which is rounded to 2 decimals to be displayed in out total price section\r\n document.getElementsByClassName('cart-total-price')[0].innerText = '€' + total\r\n}", "function updateCartTotal() {\r\n var cartItemContainer = document.getElementsByClassName(\"cart-items\")[0];\r\n var cartRows = cartItemContainer.getElementsByClassName(\"cart-row\");\r\n var total = 0;\r\n for (var i = 0; i < cartRows.length; i++) {\r\n var cartRow = cartRows[i];\r\n var priceElement = cartRow.getElementsByClassName(\"cart-price\")[0];\r\n var quantityElement = cartRow.getElementsByClassName(\"cart-quantity-input\")[0];\r\n var price = parseFloat(priceElement.innerText.replace(\"€\", \"\"));\r\n var quantity = quantityElement.value;\r\n total = total + (price * quantity);\r\n }\r\n total = Math.round(total * 100) / 100;\r\n document.getElementsByClassName(\"cart-total-price\")[0].innerText = \"€\" + total;\r\n }", "function updatePrice(){\n let currPrice = document.getElementById('currPrice');\n let qty = document.getElementById('qtyNum').value;\n let price = (5) * parseInt(qty);\n currPrice.innerText = 'Total: $' + parseFloat(price);\n localStorage.setItem('currPrice', JSON.stringify(parseFloat(price)))\n}", "function updateTotalCartPricing() {\r\n\t $('.cart .pricing').text(formatAsMoney(cart.subtotal));\r\n\t }", "function updateTotal() {\n var total = 0;\n $('.cart-item-price').each(function() {\n total += parseInt($(this).text());\n });\n $('#shoppingcart-items').append('<hr><span>Total: ' + total + '$ <a href=\"/checkout\">Go to checkout</a></span>');\n }", "function totalCost(products){\n\n let cartCost = localStorage.getItem('totalCost');\n\n if(cartCost != null){\n cartCost = parseInt(cartCost);\n localStorage.setItem(\"totalCost\", cartCost + parseInt(products.price));\n } else {\n localStorage.setItem(\"totalCost\", parseInt(products.price));\n }\n\n}", "function updateCartTotal() {\n //Get all the items in the cart with the class name cart-item-row\n let cartItemRows = document.getElementsByClassName(\"cart-item-row\");\n\n let total = 0;\n // For each item in the cart, run a loop that gets the quantity input and price of the item. Add all of them to the total amount in the cart. \n for (let i = 0; i < cartItemRows.length;i++){\n let cartItemRow = cartItemRows[i];\n let priceItem = cartItemRow.getElementsByClassName('cart-item-price')[0];\n let quantityItem = cartItemRow.getElementsByClassName('cart-quantity-input')[0];\n let price= parseFloat(priceItem.innerText.replace('R',''));\n let quantity = quantityItem.value;\n //increment the total amount in the cart by the price and quantity of each item in the cart. \n total = total + (price * quantity)\n \n }\n document.getElementsByClassName('cart-total-amount')[0].innerText = \"Total Amount: R\"+ total;\n }", "function updateCart(){\n\t\tstorage(['items', 'subtotal'], function(err, col){\n\t\t\t//console.log(\"Cart Collection - \" + JSON.stringify(col));\n\n\t\t\t//items = col[0];\n\t\t\t//subtotal = col[1];\n\n\t\t\tif(console) console.log(\"Items in Cart: \" + items);\n\t\t\tif(console) console.log(\"Subtotal of Cart: \" + subtotal);\n\t\t\t\n\t\t\t// update DOM Here\n\t\t\tdocument.getElementById( _options.itemsEleId ).innerHTML = items;\n\t\t\tdocument.getElementById( _options.subtotalEleId ).value = \"$\" + subtotal.toFixed(2);\n\n\t\t\t// reset default quantity input fields of products\n\t\t\tPRODUCTS.updateProducts();\n\t\t});\n\t}", "function updateCartTotal() {\n var cartItemContainer = document.getElementsByClassName(\"cart-body\")[0];\n var cartRows = cartItemContainer.getElementsByClassName(\"cart-item\");\n var total = 0;\n for (var i = 0; i < cartRows.length; i++) {\n var cartRow = cartRows[i];\n var priceElement = cartRow.getElementsByClassName(\"cart-item-price\")[0];\n var quantityElement = cartRow.getElementsByClassName(\n \"ItemCounterCart2\"\n )[0];\n var price = parseFloat(priceElement.innerText.replace(\"$\", \"\"));\n var quantity = parseInt(quantityElement.value);\n var total1 = price * quantity;\n total = total + total1;\n total = Math.round(total * 100) / 100;\n }\n document.getElementsByClassName(\"subtotal3\")[0].innerText = \"$\" + total;\n }", "function totalCost(products) {\r\n\r\n // console.log(\"The products price is \", products.price)\r\n let cartCost = localStorage.getItem('totalCost');\r\n\r\n console.log(\"My cartCost is\", cartCost);\r\n console.log(typeof cartCost);\r\n\r\n if (cartCost != null) {\r\n cartCost = parseInt(cartCost);\r\n localStorage.setItem(\"totalCost\", cartCost + products.price);\r\n\r\n } else\r\n\r\n {\r\n localStorage.setItem(\"totalCost\", products.price);\r\n }\r\n\r\n}", "calculateTotal(price, skuId, qty) {\n let cartListArr = this.props.elcStore.cartList.length ? JSON.parse(this.props.elcStore.cartList) : {};\n if (Object.keys(cartListArr).length && cartListArr[skuId] !== undefined) {\n for (let x in cartListArr) {\n if (x === skuId) {\n cartListArr[skuId] = {qty: cartListArr[skuId].qty + qty};\n }\n }\n } else {\n cartListArr[skuId] = {qty: qty};\n }\n const total = this.state.total + (price * qty);\n const cartList = cartListArr;\n this.props.elcStore.cartListUpdate(total, cartList);\n }", "function addSelectedItemToCart() {\n // TODO: suss out the item picked from the select list\n // TODO: get the quantity\n // TODO: using those, add one item to the Cart\n var suss = document.getElementById('cartContents');\n var print = document.createElement('p');\n suss.appendChild(print);\n var selectedItem = document.getElementById('items');\n var quantityItem = document.getElementById('quantity');\n print.textContent= `${quantityItem.value} quantities of ${selectedItem.value}`;\n var x =new cart(selectedItem.value,quantityItem.value);\n counter++;\n console.log(counter);\n var setLocalStorage = JSON.stringify(cartArray);\n localStorage.setItem('cartItems', setLocalStorage);\n \n}", "function increaseValue(brand, totalPrice, price, sign, OneOrHalf) {\n if (getFromStorage('userID')) {\n let quantity1 = 'quantity_'+brand+'_'+(OneOrHalf?'1kg':'halfkg');\n var value = parseInt(document.getElementById(quantity1).value, 10);\n value = isNaN(value) ? 0 : value;\n value++;\n document.getElementById(quantity1).value = value;\n updateTotalPrice(totalPrice, price, sign);\n updateCartItems(brand, value, OneOrHalf);\n\n } else {\n alert('you need to login first');\n }\n\n}", "function totalCost(item){\n let totalCartCost = localStorage.getItem('totalCost');\n console.log(\"added item: \"+ item.itemName + \" with cost of: \" + item.price);\n console.log(\"total cost before is: \"+ totalCartCost);\n\n// If an item is already selected add its price to total cost, else save the first added item's price as the total cost.\n if(totalCartCost != null){\n totalCartCost = parseInt(totalCartCost);\n\n localStorage.setItem(\"totalCost\", totalCartCost + item.price)\n\n }else {\n localStorage.setItem(\"totalCost\", item.price)\n }\n console.log(\"total cost now is: \" + localStorage.getItem(\"totalCost\"));\n}", "function updateCart(e) {\n event.preventDefault();\n var selectedProduct = e.target.productToPurchase.value;\n var selectedQuantity = e.target.quantityInCart.value;\n\n console.log(selectedProduct);\n console.log(selectedQuantity);\n\n // ++ to the timesClicked property for image user click on\n for(var i in Product.allProducts){\n if(selectedProduct === Product.allProducts[i].name){\n Product.allProducts[i].quantityInCart = selectedQuantity;\n console.log(Product.allProducts[i]);\n }\n }\n localStorage.setItem('shoppingCart', JSON.stringify(Product.allProducts));\n}", "function total() {\n for (var i = 0; i < cart.length; i++){\n \n getCart()[i].itemPrice\n return \n }\n}", "function totalCost(product) {\n // Creation de la variable dans le localstorage\n let cartCost = localStorage.getItem(\"totalPrice\");\n if (cartCost != null) {\n //console.log(cartCost)\n // je transforme la variable en nombre(number)\n cartCost = parseInt(cartCost);\n //Stockage la somme final en calculant le prix multiplier avec le selecteur nombre multiplier avec la quantité de chaque produit\n localStorage.setItem(\"totalPrice\", cartCost + product.price * select.value / 100);\n } else {\n // Stockage la somme final des produits selectionne\n localStorage.setItem(\"totalPrice\", product.price * select.value / 100);\n }\n}", "function addAnotherProductToCart(event) {\n let productname = event.dataset.productname;\n let product = myCart.find(element => element.product === productname);\n product.amount++;\n //update the amount html\n updateProductAmountHtml(productname, product.amount);\n //also update the storage\n saveToStorage(productname, JSON.stringify(product));\n}", "function addToCart() {\n const productQty = document.getElementById('product__quantity').value; \n productObject.quantity = parseInt(productQty);\n productArray.push(productObject);\n localStorage.setItem('productCart', JSON.stringify(productArray));\n window.location='cart.html'; \n }", "function addSelectedItemToCart() {\n // TODO: suss out the item picked from the select list\n var product = event.target.items.value;\n var quantity = event.target.quantity.value;\n cart.addItem(product, quantity);\n counter++;\n console.log(counter);\n // TODO: get the quantity\n // TODO: using those, add one item to the Cart\n}", "function addToCartAndStore(id) {\n //if item in storage already dont add again\n let amount = sessionStorage.getItem(id);\n if (amount) {\n changeQuantity(id);\n } else {\n addToCart(id);\n }\n Storage(id);\n}", "function calculate() {\n let cart = JSON.parse(localStorage.getItem(\"cart\"));\n for (let i = 0; i < cart.length; i++) {\n $scope.subtotal += cart[i].price * cart[i].quantity;\n $scope.tax = $scope.subtotal * 0.09;\n $scope.finalTotal = $scope.subtotal + $scope.tax + $scope.shipping;\n console.log($scope.subtotal);\n }\n }", "totalCart()\n {\n let total = 0;\n for (let i = 0; i < this.itemlist.length; i++)\n {\n total += this.itemList[1].price * this.itemQuantity[i];\n }\n return total;\n }", "function total() {\n var total = 0\n for(var i = 0; i < cart.length; i++){\n total += cart[i].itemPrice\n }\n return total\n}", "function storingCartItem() {\n \n /**\n * TODO: Create Product Object\n */\n let cartItem = product;\n cartItem.quantity = 1;\n cartItem.lensOption = updatePersonalizedFeatures();\n\n /**\n * TODO: Get \"cartItems\" value \n */\n let cartItems = JSON.parse(localStorage.getItem('cartItems'));\n\n\n /**\n * TODO: Update \"cartItems\" value with new Product Object (Push to the Array)\n */\n cartItems.push(cartItem);\n localStorage.setItem('cartItems', JSON.stringify(cartItems));\n\n // update cart badge\n let cartItemsQuantity = document.getElementById('cartItemQuantity');\n cartItemsQuantity.style.display = \"inline-block\";\n updateCartBadge();\n \n /**\n * TODO: Further \"Add to cart\" stuff....\n */\n //goToCartPage();\n \n console.log(cartItems);\n\n}", "function getQuantity() {\n let quantity = 0;\n for (let i = 0; i < cart.length; i++) {\n quantity += cart[i].quantity;\n }\n\n return quantity;\n}", "function updateCartTotal() {\n var cartItemContainer = document.getElementsByClassName('cart-items')[0];\n var cartRows = cartItemContainer.getElementsByClassName('cart-row');\n var total = 0;\n for (var i = 0; i < cartRows.length; i++) {\n var cartRow = cartRows[i];\n var priceElement = cartRow.getElementsByClassName('cart-price')[0];\n console.log(priceElement);\n var quantityElement = cartRow.getElementsByClassName('cart-quantity-input')[0];\n var price = parseFloat(priceElement.innerText.replace('$', ''));\n console.log(price);\n var quantity = quantityElement.value;\n console.log(quantity);\n total = total + (price * quantity);\n }\n total = Math.round(total * 100) / 100;\n document.getElementsByClassName('cart-total-price')[0].innerText = '$' + total;\n}", "function actualizarPrecioCarrito(){\n totalCarrito = 0;\n carrito = actualizarCantidades();\n\n for(const item of carrito){\n let nuevoPrecioItem = calcularPrecioItem(item);\n item.precioItem = nuevoPrecioItem;\n //console.log(nuevoPrecioItem);\n totalCarrito = totalCarrito + nuevoPrecioItem;\n }\n \n $(\".shoppingCartTotal\").html(`$ ${totalCarrito.toFixed(2)}`);\n $(\".shoppingCartTotal\").hide()\n $(\".shoppingCartTotal\").fadeIn(\"slow\")\n \n localStorage.setItem( \"productos\", JSON.stringify(carrito));\n localStorage.setItem( \"total\", JSON.stringify(totalCarrito));\n}", "setCartValues(cart) {\n let tempTotal = 0;\n let itemTotal = 0;\n\n cart.map(item => {\n tempTotal += item.price * item.amount;\n itemTotal += item.amount;\n });\n\n cartTotal.innerText = parseFloat(tempTotal.toFixed(2));\n cartItems.innerText = itemTotal;\n }", "ADD_TO_CART(state, product) {\n // Check if cart is empty\n if (Object.keys(state.cart).length != 0) {\n for (const [key, value] of Object.entries(state.cart)) {\n // Check if product already in cart, then change quantity \n if (key === product.reference) {\n product.qty = value.qty + state.qty\n state.cart[key].qty = product.qty\n } else {\n state.cart[product.reference] = product\n }\n }\n } else {\n state.cart[product.reference] = product\n }\n }", "function displayTotalPrice() {\n let totalPrice = 0;\n let totalPriceInCart = localStorage.getItem('Cart');\n let cart = JSON.parse(totalPriceInCart);\n for (i= 0; i < cart.length ; i++){\n console.log(cart[i])\n totalPrice += cart[i].price * cart[i].quantity;\n }\n document.getElementById('basket-totalPrice').innerHTML = totalPrice.toLocaleString(\"fr-FR\", {style:\"currency\", currency:\"EUR\"})\n}", "function quantityChanged(event) {\n // var input = event.target;\n updateCartTotal();\n }", "function addSelectedItemToCart() {\n // suss out the item picked from the select list\n let product = document.getElementById('items').value;\n let quantity = document.getElementById('quantity').value;\n cart.addItem(product, quantity);\n\n // console.log(newCartItem);\n // console.log(cart);\n\n // get the quantity\n // using those, add one item to the Cart\n}", "addCarting({commit, state}, products) {\n // verify if the 'product' is or not add in the 'carting'. This 'hasOwnProperty' method returns \n // a boolean indicating whether the object has the specified property\n hasOwnProperty.call(state.carting, products.id) \n ? products.amount = state.carting[products.id].amount + 1\n : products.amount = 1;\n //console.log(products.amount);\n // pushing to \"mutation\"\n commit('setCarting', products);\n }", "function cartQuantity(subject, option, originalValue){\n var inputValue = Math.abs(Math.floor(Number(document.getElementById(subject + option + \"quantity\").value)));\n if(inputValue == 0 || inputValue == NaN){\n inputValue = 1;\n document.getElementById(subject + option + \"quantity\").value = 1; \n } \n sessionStorage.setItem(subject + \"Quantity\", inputValue);\n if(document.getElementById(subject + option + \"price\").innerHTML.includes(\"<\")){ \n var spanText = document.getElementById(subject + option + \"price\").innerHTML.split('<')[1];\n var newPrice = originalValue * inputValue;\n document.getElementById(subject + option + \"price\").innerHTML = \"\" + newPrice + \"<\" + spanText; \n sessionStorage.setItem(subject + \"Price\", document.getElementById(subject + option + \"price\").innerHTML.split('<')[0]);\n }\n else{ \n var newPrice = originalValue * inputValue;\n document.getElementById(subject + option + \"price\").innerHTML = \"\" + newPrice; \n sessionStorage.setItem(subject + \"Price\", document.getElementById(subject + option + \"price\").innerHTML);\n } \n}", "function updateBill(amount, quantity) {\n const payBtn = document.querySelector(\".btn-pay\");\n const subTotal = document.querySelector(\".bill-sub-total\");\n const tax = document.querySelector(\".bill-taxes\");\n const discount = document.querySelector(\".bill-discount\");\n\n let total = cart.reduce((prevBill, curr) => {\n let currItemTotal = Number(curr.price) * Number(curr.quantity);\n prevBill += currItemTotal;\n prevBill.toFixed(2);\n return prevBill;\n }, 0);\n\n subTotal.innerHTML = `₹ ${total}`;\n let currTax = (total * 0.28).toFixed(2);\n tax.innerHTML = `₹ ${currTax}`;\n discount.innerHTML = `₹ ${0.0}`;\n\n let finalAmount = total + Number(currTax);\n payBtn.innerHTML = `Pay ₹ ${finalAmount.toFixed(2)}`;\n}", "function addCartEntry() {\n\tlet productNumbers = localStorage.getItem('cartNumbers');\n //convert string of productNumbers into Int\n\tproductNumbers = parseInt(productNumbers);\n \n //if something is in the cart\n\tif(productNumbers) {\n\t\tlocalStorage.setItem('cartNumbers', productNumbers+1);\n\t\tdocument.querySelector('.cart-qty span').textContent = productNumbers + 1;\n\t} else {\n\t\tlocalStorage.setItem('cartNumbers', 1);\n\t\t//update all instances of .cart-qty span with the new number\n\t\tdocument.querySelector('.cart-qty span').textContent = 1;\n\t}\n\n\t//create object with color and filling information and add to storedCartList array\n\tvar storedCartList = JSON.parse(localStorage.getItem('cartItems'));\n if(storedCartList == null) storedCartList = [];\n var newitem = {\n \t'Product' : 'big ole comfy pillow',\n \t'Price' : '$$',\n\t\t'Color' : chosenColor,\n\t\t'Filling' : chosenFilling\n };\n localStorage.setItem('newitem', JSON.stringify(newitem));\n // Save cartItems back to local storage\n storedCartList.push(newitem);\n localStorage.setItem('cartItems', JSON.stringify(storedCartList));\n}", "function addToCart() {\n\tvar quantityCount = document.getElementById(\"quantityCount\");\n\tquantityCount.innerText = document.getElementById(\"quantity\").value;\n\tdocument.getElementById(\"quantityCount\").style.visibility = \"visible\";\n\n\n\ttitle = document.getElementsByClassName(\"productTitle\");\n\tquantity = document.getElementById(\"quantity\").value;\n\tglazing = document.getElementById(\"glazing\").value;\n\tprice = document.getElementById(\"quantity\").value;\n\timg = \"images/blackberry-bag.png\"\n\taddItem = new items(title, quantity, glazing, price, img);\n\n\twindow.localStorage.setItem(localStorageCount, JSON.stringify(addItem));\n\t// localStorageCount += 1;\n}", "function calculateTotalPrice (product) {\n let quantity = JSON.parse(localStorage.getItem(product._id));\n return quantity * product.price / 100;\n\n}", "function buy(title, description, colour, value) {\n cart = JSON.parse(sessionStorage.getItem(\"price\"));\n vinylObject = JSON.parse(sessionStorage.getItem(\"object\"));\n let newVinyl = new vinyl(\n title,\n description,\n colour,\n value,\n );\n vinylObject.push(newVinyl)\n let prices = parseInt(value);\n cart.push(prices);\n $(\".fas\").css(\"color\", \"#ff5200\");\n sessionStorage.setItem(\"price\", JSON.stringify(cart));\n sessionStorage.setItem(\"object\", JSON.stringify(vinylObject));\n}", "function plusQtty(i) {\n\n cart[i].qtty++;\n document.getElementsByClassName(\"cart-quantity\")[i].innerHTML = cart[i].qtty;\n\n /* Update total items in the cart*/\n totalShoppingItems++;\n document.getElementById(\"total-qtty\").innerHTML = totalShoppingItems;\n}", "function store(price) {\n wallet.setPrice(price);\n console.log('the new price is ' + price);\n }", "function calcTotal() {\n // get value and parse sessionStorage\n let cart = JSON.parse(sessionStorage.getItem('cart'));\n\n // loop through all items in the Cart\n // add each items price to Total\n // return total\n let total = 0;\n for (let product in cart) {\n total += cart[product].price;\n }\n return total.toFixed(2)\n}", "function priceTotalBasket(camera) {\n prixPanier += camera.quantity * camera.price / 100;\n //Afficher le prix total de panier \n let prixTotal = document.getElementById('prixTotal').textContent = prixPanier + \" € \";\n //Envoyer le au localstorage\n localStorage.setItem('prixTotal', JSON.stringify(prixTotal));\n}", "function cart_qty_change(e, itemId, isAdd) {\n\n let cartItems = localStorage.getItem('productsInCart');\n cartItems = JSON.parse(cartItems);\n\n if (cartItems) {\n\n let prd_qty;\n let prd_sum = $(e).parent().parent().next().children();\n\n if (isAdd) prd_qty = $(e).prev();\n else prd_qty = $(e).next();\n\n let qty = Number(prd_qty.val());\n\n if (qty > 1 && isAdd == false) {\n qty -= 1;\n prd_qty.attr('value', qty);\n total = Number(cartItems[itemId]['price']) * qty;\n prd_sum.html('&#8377; ' + total);\n cartItems[itemId]['qty'] -= 1;\n localStorage.setItem(\"productsInCart\", JSON.stringify(cartItems));\n alter_totalCost(cartItems[itemId]['price'], isAdd = false);\n }\n else if (qty >= 1 && isAdd == true) {\n qty += 1;\n prd_qty.attr('value', qty);\n total = Number(cartItems[itemId]['price']) * qty;\n prd_sum.html('&#8377; ' + total);\n cartItems[itemId]['qty'] += 1;\n localStorage.setItem(\"productsInCart\", JSON.stringify(cartItems));\n alter_totalCost(cartItems[itemId]['price'], isAdd = true);\n }\n\n }\n}", "function updateCartTotal() {\n var cartItemContainer = document.getElementsByClassName(\"cart-items\")[0];\n var cartRows = cartItemContainer.getElementsByClassName(\"cart-row\");\n var total = 0;\n for (var i = 0; i < cartRows.length; i++) {\n var cartRow = cartRows[i];\n var priceElement = cartRow.getElementsByClassName(\"cart-price\")[0];\n var quantityElement = cartRow.getElementsByClassName(\n \"cart-quantity-input\"\n )[0];\n var price = parseFloat(priceElement.innerText.replace(\"$\", \"\"));\n var quantity = quantityElement.value;\n total = total + price * quantity;\n }\n document.getElementsByClassName(\"cart-total-price\")[0].innerText = total;\n}", "function updateTotal(){\n\t\tvar sum = 0;\n\t\t$(\".cart_items>.item\").each(function(i,v){\n\t\t\tsum += $(v).data(\"price\") * $(v).find(\".cart_cloth_num\").text();\n\t\t});\n\t\t$(\".cart_total\").text(sum);\n\t}", "function tshirt_total() {\r\n\t\tvar tshirt_no = document.getElementById(\"tshirt\").value;\r\n\t\ttsNumber = parseInt(tshirt_no);\r\n\t\t\t\t//alert(\"in tshirt_total - tsNumber \" + tsNumber);\r\n\t\tvar tshirt_text = document.getElementById(\"tsh_label\").textContent;\r\n\t\tvar tsh_size = document.getElementById(\"tshirt_size\").value;\r\n\t\t//alert(\"tshirt_text \" + tshirt_text);\r\n\r\n\t\tupdateTshirtBasket(tsNumber,tshirt_text,tsh_size);\r\n\t\tsetCookie(\"tshirt_total\", tsNumber,1);\r\n\t\t//updateDisplayMerch();\t\r\n\t\t//alert(\"go to updateTshirtBasket\");\r\n\t}", "function updateCartTotal(){\n\tvar cartItemContainer = document.getElementsByClassName(\"cart-items\")[0];\n\tvar cartRows = cartItemContainer.getElementsByClassName(\"first-cart-row\");\n\tvar total = 0;\n\tfor (var i = 0; i < cartRows.length; i++) {\n\t\tvar cartRow = cartRows[i];\n\t\tvar priceElement = cartRow.getElementsByClassName(\"cart-price\")[0];\n\t\tvar quantityElement = cartRow.getElementsByClassName(\"cart-quantity-input\")[0];\n\t\tvar price = parseFloat(priceElement.innerText.replace(\"$\",\"\"));\n\t\tvar quantity = quantityElement.value;\n\t\ttotal = total + (price * quantity);\n\t}\n\ttotal = Math.round(total * 100) / 100;\n\tdocument.getElementsByClassName(\"cart-total-price\")[0].innerText = \"$\" + total;\n}", "function productTotal() {\n for (let i = 0; i < basket.length; i++) {\n let price = Number(basket[i].price.replace(/[^0-9.-]+/g,\"\"));\n let totalPrice = price * basket[i].quantity;\n basket[i].totalPrice = totalPrice\n } \n}", "function newOrder(){\n let $amount = document.getElementById(\"amount\");\n $amount.value = 0;\n cart = []; \n reset();\n}", "cartTotal() {\n return this.total;\n }", "function cartQuantity(items, action) {\n\n let cartNumber = localStorage.getItem(\"cartQuantity\");\n cartNumber = parseInt(cartNumber);\n let cartProduct = localStorage.getItem(\"coffeeInCart\");\n cartProduct = JSON.parse(cartProduct);\n\n if (action == \"decrement\") {\n localStorage.setItem(\"cartQuantity\", cartNumber - 1);\n document.querySelector(\".cart-number\").textContent = cartNumber - 1;\n } else if (cartNumber) {\n localStorage.setItem(\"cartQuantity\", cartNumber + 1);\n document.querySelector(\".cart-number\").textContent = cartNumber + 1;\n } else {\n localStorage.setItem(\"cartQuantity\", 1);\n document.querySelector(\".cart-number\").textContent = 1;\n }\n setCoffeeProducts(items);\n}", "function UpdateCart(quantityChanged, target, type, idx) {\n var cartContainer = document.getElementsByClassName('products')[0];\n var allproducts = cartContainer.getElementsByClassName('product');\n var totalprice = 0;\n for (var i = 0; i < allproducts.length; i++) {\n var CartProduct = allproducts[i];\n var price1kgProduct = CartProduct.getElementsByClassName('product-price-1kg')[0];\n var quantity1kgProduct = CartProduct.getElementsByClassName('product-quantity-1kg-input')[0];\n var price1kgNumber = parseFloat(price1kgProduct.innerText.replace('$ - 1KG', ''));\n var quantity1kg = quantity1kgProduct.value;\n var priceHalfkgProduct = CartProduct.getElementsByClassName('product-price-Halfkg')[0];\n var quantityHalfkgProduct = CartProduct.getElementsByClassName('product-quantity-Halfkg-input')[0];\n var priceHalfkgNumber = parseFloat(priceHalfkgProduct.innerText.replace('$ - 0.5KG', ''));\n var quantityHalfkg = quantityHalfkgProduct.value;\n totalprice = totalprice + (price1kgNumber * quantity1kg) + (priceHalfkgNumber * quantityHalfkg);\n }\n totalprice = Math.round(totalprice * 100) / 100\n document.getElementsByClassName('cartTotaPrice')[0].innerText = updateTotalPriceData() + '$';\n sessionStorage.setItem('CartTotalPrice', totalprice);\n if (quantityChanged) {\n console.log(target);\n QuantityFromIceCream[idx][type] = +target.value;\n updateShoppingCart();\n }\n //()\n\n}", "function calculateTotal(){\n let totalPrice = 0;\n $('#myCart #item').each(function(){\n totalPrice = totalPrice + $(this).data('price');\n })\n $('#price').text(`Total Price:Rs.${totalPrice}/-`)\n }", "function addProductToCart(product) {\n let cart = getCart();\n cart.items.push(product);\n\n setCart(cart);\n alert(product.name + ' added to cart, Total is R' + getTotal(cart));\n}" ]
[ "0.7134825", "0.6897594", "0.6897404", "0.68962795", "0.6887796", "0.682068", "0.68079644", "0.6801724", "0.6786111", "0.67719436", "0.67669487", "0.67305833", "0.67223895", "0.67132324", "0.67067385", "0.66997266", "0.6685919", "0.6678676", "0.6675621", "0.6659142", "0.6651891", "0.6626231", "0.6626231", "0.6618471", "0.66057825", "0.65933496", "0.65880686", "0.65825504", "0.6580173", "0.65707266", "0.6558457", "0.6557347", "0.6554312", "0.65499985", "0.6546376", "0.65297556", "0.6519487", "0.6513585", "0.6505018", "0.6497256", "0.6494739", "0.646187", "0.6457844", "0.6456203", "0.64549166", "0.64546907", "0.6451501", "0.6448599", "0.64457965", "0.6444475", "0.6434436", "0.6430185", "0.6427611", "0.6421566", "0.6420629", "0.6419816", "0.64195096", "0.6416546", "0.6413298", "0.6413121", "0.64079773", "0.6407607", "0.63980085", "0.6397501", "0.6393784", "0.6382769", "0.6379519", "0.63765514", "0.6366841", "0.63634866", "0.63606584", "0.6356791", "0.6347786", "0.63404125", "0.63350534", "0.6332073", "0.6329249", "0.6323753", "0.6320853", "0.63181573", "0.63130116", "0.6312982", "0.63047075", "0.6299566", "0.6297486", "0.6294568", "0.62825185", "0.62824255", "0.6281141", "0.62800485", "0.6277668", "0.62759113", "0.6270583", "0.6269343", "0.6264138", "0.6264136", "0.62635", "0.6260272", "0.62588656", "0.62573093", "0.62570083" ]
0.0
-1
This is used to set which items are being added to the cart
function setItems(products) { let cartItems = localStorage.getItem('productsInCart'); cartItems = JSON.parse(cartItems); if(cartItems != null) { if(cartItems[products.tag] == undefined){ cartItems = { ...cartItems, [products.tag]: products } } cartItems[products.tag].inCart += 1; } else { products.inCart = 1; cartItems = { [products.tag]: products } } localStorage.setItem("productsInCart", JSON.stringify(cartItems)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "addItemsToCart() {\n\n Model.addItemsToCart(this.currentItems);\n }", "function addSelectedItemToCart() {\n // TODO: suss out the item picked from the select list\n let selectedItem = event.target.items.value;\n console.log(selectedItem);\n // TODO: get the quantity\n let quantity = event.target.quantity.value;\n // TODO: using those, add one item to the Cart\n \n \n carts.addItem(selectedItem,quantity); \n console.log(carts.items);\n \n}", "function addItemToCart() {}", "function addItemToCart() {}", "function addSelectedItemToCart() {\n // TODO: suss out the item picked from the select list\n var product = event.target.items.value;\n var quantity = event.target.quantity.value;\n cart.addItem(product, quantity);\n counter++;\n console.log(counter);\n // TODO: get the quantity\n // TODO: using those, add one item to the Cart\n}", "setItemsInCart(state, items) {\n state.itemsInCart = items;\n }", "add(id, product) {\n // if an item exists in the cart\n const item = this.items[id]\n ? new CartItem(this.items[id])\n : new CartItem({ id, product });\n\n // increment the items quantity\n item.qty += 1;\n // Update the items price\n item.price = item.product.price * item.qty;\n\n this.items = {\n ...this.items,\n [id]: item\n };\n }", "addToCart(item, index, size, quantity) {\n var itemsArray = this.state.itemsInCart;\n var itemTemp = Object.assign({}, item)\n itemTemp.key = uuid.v4()\n itemTemp.size = size\n itemTemp.quantity = Math.floor(Math.abs(quantity))\n itemTemp.donation = (itemTemp.price * quantity)\n itemsArray.push(itemTemp)\n this.setState({ itemsInCart: itemsArray })\n this.updateMerchAmount()\n // Update Left Side Bar\n let length = this.state.itemsInCart.length\n this.setState({\n menuItems: [\n { name: 'donate', title: 'Donate' },\n { name: 'bills', title: 'KZSC Bills' },\n { name: 'merch', title: 'Merchandise' },\n { name: \"cart\", title: \"Your Cart\", label: length }\n ]\n })\n }", "function addSelectedItemToCart() {\n // suss out the item picked from the select list\n let product = document.getElementById('items').value;\n let quantity = document.getElementById('quantity').value;\n cart.addItem(product, quantity);\n\n // console.log(newCartItem);\n // console.log(cart);\n\n // get the quantity\n // using those, add one item to the Cart\n}", "setAddableProduct(item) {\n this.addableProduct = jQuery.extend(true, {}, item);\n // Handling a case when unreceived quantity less than a quantity in customer order content entry.\n // The product at the line had been previously partially received.\n this.addableProduct.quantity = item.unreceived;\n this.addableProduct.total = item.total / item.quantity * item.unreceived;\n this.searchProductsList = [];\n }", "function setCart(){\n\t\tstorage.set({ \n\t\t\titems: 0, \n\t\t\tsubtotal: 0\n\t\t}, function(){\n\t\t\tupdateCart();\n\t\t});\n\t}", "function setCartItems(item){\n let cartItems = localStorage.getItem('cartProducts');\n cartItems = JSON.parse(cartItems);\n\n//If no items in cart, set cartItems as the product just added.\n if(cartItems == null){\n item.numInCart = 1;\n cartItems = {\n [item.itemName] : item\n }\n }else {\n // get the previous items from local storage and all others\n if(cartItems[item.itemName] == undefined){\n cartItems = {\n ...cartItems,\n [item.itemName]: item\n }\n }\n cartItems[item.itemName].numInCart += 1;\n }\n\n//set new products in cart.\n localStorage.setItem(\"cartProducts\", JSON.stringify(cartItems));\n\n //update cart\n getCart();\n}", "function addSelectedItemToCart() {\n // TODO: suss out the item picked from the select list\n // TODO: get the quantity\n // TODO: using those, add one item to the Cart\n var suss = document.getElementById('cartContents');\n var print = document.createElement('p');\n suss.appendChild(print);\n var selectedItem = document.getElementById('items');\n var quantityItem = document.getElementById('quantity');\n print.textContent= `${quantityItem.value} quantities of ${selectedItem.value}`;\n var x =new cart(selectedItem.value,quantityItem.value);\n counter++;\n console.log(counter);\n var setLocalStorage = JSON.stringify(cartArray);\n localStorage.setItem('cartItems', setLocalStorage);\n \n}", "function setCoffeeProducts(items) {\n let cartProduct = localStorage.getItem(\"coffeeInCart\");\n cartProduct = JSON.parse(cartProduct);\n\n if (cartProduct !== null) {\n if (cartProduct[items.name] == undefined) {\n cartProduct = {\n ...cartProduct,\n [items.name]: items\n };\n }\n cartProduct[items.name].insideCart += 1;\n } else {\n items.insideCart = 1;\n cartProduct = {\n [items.name]: items\n };\n }\n\n localStorage.setItem(\"coffeeInCart\", JSON.stringify(cartProduct));\n}", "addToCart(itemOptions) {\n this.store.cart.products.push({\n product_id: itemOptions.item,\n price: itemOptions.price || 0,\n total: itemOptions.price || 0,\n quantity: itemOptions.quantity || 1,\n offer: itemOptions.offer || null,\n materials: itemOptions.config ? itemOptions.config.split(',') : [],\n description: \"\",\n comment: itemOptions.comment\n });\n }", "set cartItems(cartItems) {\n //store.cartItems = storedCartItems; //added*\n this.storage.setItem(this.CART_KEY, JSON.stringify(cartItems));\n }", "addToCart(item) {\n const nameKey = item.name;\n // If the item that is being added to the cart is already in the cart,\n // we increment the numInCart variable to show that an additional unit\n // is being added\n if (nameKey in this.state.aggregatedItems) {\n let currAggregatedItems = this.state.aggregatedItems;\n let currPrice = currAggregatedItems[nameKey].price;\n let currNumInCart = currAggregatedItems[nameKey].numInCart;\n let currImage = currAggregatedItems[nameKey].image;\n let currShelfLife = currAggregatedItems[nameKey].shelf_life;\n let currType = currAggregatedItems[nameKey].type;\n\n currAggregatedItems[nameKey] = {\n numInCart: currNumInCart + 1,\n price: currPrice,\n image: currImage,\n type: currType,\n shelf_life: currShelfLife\n };\n this.setState({\n aggregatedItems: currAggregatedItems\n })\n // If it is not already in the cart, we need to add this key-value pair to the \n // aggregatedItems state variable. We do so using the setState function\n } else {\n let currAggregatedItems = this.state.aggregatedItems;\n currAggregatedItems[nameKey] = {\n numInCart: 1,\n price: item.price,\n image: item.image,\n shelf_life: item.shelf_life,\n type: item.type\n\n }\n this.setState({\n aggregatedItems: currAggregatedItems\n })\n }\n }", "add() {\n\t\torinoco.cart.add({ imageUrl: this.imageUrl, name: this.name, price: this.price, _id: this._id });\n\t}", "addItemToCart(item){\n // check for duplicates\n if(this.cart.hasOwnProperty(item.id)){\n this.cart[item.id].quantity += 1\n localStorage.setItem('cart', JSON.stringify(this.cart))\n }\n else {\n item.index = Object.keys(this.cart).length\n item.quantity = 1\n this.cart[item.id] = item\n localStorage.setItem('cart', JSON.stringify(this.cart))\n }\n return this\n }", "function addOneItemToCart() {\n var itemID = $(this).attr(\"id\");\n var positionInCart = itemID.slice(12, itemID.length);\n cartItems[positionInCart][3] += 1;\n updateCartDetails();\n}", "handleAddItemToCart(item, quantity){\n var buyableItem = new BuyableItem(item, quantity);\n currentCart.push(buyableItem);\n this.setState({cartQuantity : this.calculateCartQuantity(currentCart)})\n localStorage.setItem(\"cart\", JSON.stringify(currentCart));\n this.readFromCart();\n }", "function addCart() {\n\n let sameItems = stylishStorage.cart.list.filter( el => \n el.id === details_product_id.textContent &&\n el.color.code === currentColor && \n el.size === currentSize); \n\n if (sameItems.length > 0){\n stylishStorage.cart.list.forEach( item => {\n if ( item.id === details_product_id.textContent &&\n item.color.code === currentColor &&\n item.size === currentSize ){\n item.qty = quantity_count_value.textContent;\n }\n })\n \n }else{\n newItem ={\n id: details_product_id.textContent,\n name: details_product_name.textContent,\n main_image: main_img,\n price: product_price,\n color: {\n name: currentColorName,\n code: currentColor\n },\n size: currentSize,\n qty: quantity_count_value.textContent,\n stock: stock_qty\n }\n\n stylishStorage.cart.list.push(newItem);\n }\n\n localStorage.setItem('cart', JSON.stringify(stylishStorage.cart));\n}", "addToCart(){ \n const cartItems = localStorage.getItem('cartItems') ? JSON.parse(localStorage.getItem('cartItems')) : {};\n let cartSize = localStorage.getItem('cartSize') ? JSON.parse(localStorage.getItem('cartSize')) : 0;\n cartSize ++;\n if(this.state.selectedSource.id in cartItems){\n cartItems[this.state.selectedSource.id]['count'] ++;\n }else{\n cartItems[this.state.selectedSource.id] = {};\n cartItems[this.state.selectedSource.id]['count'] = 1;\n cartItems[this.state.selectedSource.id]['product'] = this.state;\n }\n this.setState({cartItems: cartItems, cartSize});\n localStorage.setItem('cartItems', JSON.stringify(cartItems));\n localStorage.setItem('cartSize', JSON.stringify(cartSize));\n }", "function populateProductCart(product) {\n products_cart.items.push(product);\n updateCart();\n clearAddItemModal();\n}", "function initCartItems() {\n const lsCartItems = JSON.parse(localStorage.getItem(\"cartItems\"));\n if (lsCartItems) {\n setCartItems(lsCartItems);\n }\n }", "function addSelectedItemToCart() { \n var itemsEl = document.getElementById('items').value;\n var quantityEl = document.getElementById('quantity').value;\n cart.addItem(itemsEl, parseInt(quantityEl));\n // console.log(cart.items[0].product);\n // console.log(cart.items[0].quantity); \n}", "function updateMiniCart() {\n if(!cart.items ) {\n cart.items = [];\n }\n }", "function setItems(product) {\r\n\tlet cartItems = localStorage.getItem('productsInCart');\r\n\tcartItems = JSON.parse(cartItems);\r\n\tif (cartItems != null) {\r\n\t\tif (cartItems[product.title] == undefined) {\r\n\t\t\tcartItems = {\r\n\t\t\t\t...cartItems,\r\n\t\t\t\t[product.title]: product\r\n\t\t\t}\r\n\t\t}\r\n\t\tcartItems[product.title].incart += 1;\r\n\t} else {\r\n\t\tproduct.incart = 1;\r\n\tcartItems = {\r\n\t\t[product.title]: product\r\n\t}\r\n\t}\r\n\tlocalStorage.setItem('productsInCart', JSON.stringify(cartItems))\r\n}", "function addSelectedItemToCart() {\n // TODO: suss out the item picked from the select list\n // TODO: get the quantity\n // TODO: using those, add one item to the Cart\n const product = selectElement.options[selectElement.selectedIndex].text;\n const quantity = parseInt(document.getElementById('quantity').value);\n cart.addItem(product, quantity);\n}", "function updateCart(){\n reset();\n cart.forEach(product =>{\n appendProduct(product);\n }); \n}", "add_item(item){\n this.cart.push(item);\n }", "function addToCart() {\n var itemID = $(this).attr(\"id\");\n var alreadyInCart = false;\n for (var i = 0; i < cartItems.length; i++) {\n if (itemID == cartItems[i][0]) {\n alreadyInCart = true;\n cartItems[i][3] += 1;\n }\n }\n if (alreadyInCart == false) {\n for (var i = 0; i < shopItems.length; i++) {\n if (itemID == shopItems[i][0]) {\n var applianceID = shopItems[i][0];\n var applianceName = shopItems[i][1];\n var appliancePrice = shopItems[i][2];\n var applianceQuantity = 1;\n itemID = [\n applianceID,\n applianceName,\n appliancePrice,\n applianceQuantity,\n ];\n }\n }\n cartItems.push(itemID);\n }\n\n updateCartDetails();\n}", "function setItems(products) {\r\n let cartItems = localStorage.getItem('productsInCart')\r\n\r\n cartItems = JSON.parse(cartItems);\r\n\r\n\r\n if (cartItems != null) {\r\n if (cartItems[products.tag] == undefined) {\r\n cartItems = {\r\n ...cartItems,\r\n [products.tag]: products\r\n }\r\n }\r\n cartItems[products.tag].inCart += 1;\r\n } else {\r\n products.inCart = 1;\r\n\r\n cartItems = {\r\n [products.tag]: products\r\n }\r\n }\r\n localStorage.setItem(\"productsInCart\", JSON.stringify(cartItems));\r\n}", "handleAddItem() {\n const transactionState = this.props.transactionState;\n const items = transactionState.transactionItems;\n items[items.length - 1].item = {\n name: this.state.name,\n category: this.state.category,\n gender: this.state.gender,\n typeColor: this.state.typeColor,\n size: this.state.size,\n location: this.state.location,\n };\n items[items.length - 1].quantityChanged = this.state.quantity;\n items[items.length - 1].recipient = this.state.recipient;\n this.props.setTransactionState(transactionState);\n }", "_changeQuantity(productId) {\n const value = this.shadowRoot.querySelector('#chart_item_' + productId).value;\n\n const cartItem = this._findCartItem(productId);\n\n const index = this.cartItems.indexOf(cartItem);\n this.cartItems[index].quantity = value;\n this.cartItems = [...this.cartItems]; // this.cartItems[index] = cartItem['quantity'] + 1;\n // this.set('cartItems.' + index + '.quantity', cartItem['quantity'] + 1);\n\n localStorage.setItem('shop-cart', JSON.stringify(this.cartItems));\n this.dispatchEvent(new CustomEvent('change-cart-count', {\n bubbles: true,\n composed: true,\n detail: {}\n }));\n }", "function addSelectedItemToCart(product, quantity) {\n // TODO: suss out the item picked from the select list\n cart.addItem(product, quantity);\n\n // TODO: get the quantity\n // TODO: using those, add one item to the Cart\n}", "function updateCart(flavors) {\n //Creating a variable to store the flavors selected.\n //If no flavors were selected (in the case of Single count), an empty array is created.\n var extraFlavors = flavors || [];\n var quantity=$('#product-qty').val(); \n var itemName=$('#product-name').text();\n if(extraFlavors.length) {\n itemName = itemName+\" - \"+extraFlavors.join(\", \");\n }\n var itemFound = false;\n //Iterate through the cart to see if the desired item exists already\n for(var i=0; i<cart.length; i++){\n //If the item already exists, update the quantity and subtotal\n if(cart[i].rollName === itemName){\n var existingQty = parseInt(cart[i].numQty);\n cart[i].numQty = parseInt(quantity) + existingQty;\n cart[i].subtotal = parseInt(cart[i].rollPrice) * parseInt(cart[i].numQty);\n //Update the changes in local storage\n localStorage.setItem(\"cart\", JSON.stringify(cart));\n localStorage.setItem(\"cartCount\", cart.length);\n itemFound = true;\n break;\n }\n }\n //If the item doesn't exist yet, add the item\n if(!itemFound) {\n var itemImage=$('#roll-image').attr('src');\n var price=$('#product-price').text();\n var subtotal=parseInt(price)*parseInt(quantity);\n var bakeryRoll = new newCartItem(itemImage, itemName, quantity, price, subtotal);\n cart.push(bakeryRoll);\n localStorage.setItem(\"cart\", JSON.stringify(cart));\n localStorage.setItem(\"cartCount\", cart.length);\n $('#cartCount').show();\n $('#cartCount').html(cart.length).css('display', 'block');\n }\n }", "setCartItem() {\n console.log(this.itemNumber);\n if (this.itemNumber < this.cart.length) {\n this.set('cartItem.name', this.cart[this.itemNumber].name);\n this.set('cartItem.price', this.cart[this.itemNumber].price);\n }\n if (this.itemNumber < this.cart.length && this.cart[this.itemNumber].shippingAddress) {\n this.set('cartItem.giftMessage', this.cart[this.itemNumber].giftMessage);\n this.set('cartItem.shippingAddress', Object.assign({}, this.cart[this.itemNumber].shippingAddress));\n } else {\n console.log(this.itemNumber);\n this.set('cartItem.giftMessage', \"\");\n this.set('cartItem.shippingAddress', {\n firstName: \"\",\n lastName: \"\",\n streetAddress1: \"\",\n streetAddress2: \"\",\n cityName: \"\",\n state: \"\",\n zipCode: \"\",\n recipientNumber: \"\"\n });\n }\n }", "function plusItem() {\n const productId = this.name;\n const cartList = JSON.parse(sessionStorage.getItem(\"shoppingCartItems\"));\n const item = cartList.find(product => product.id == productId);\n cartList.push(item);\n sessionStorage.setItem(\"shoppingCartItems\", JSON.stringify(cartList));\n shoppingCartCount();\n populateShoppingCartPage();\n}", "function addItemToCart(user, item) {}", "function addSelectedItemToCart() {\n\n // suss out the item picked from the select list\n var productPicked = document.getElementById('items').value; // why not 'options'? it knows there's something in the dropdown.\n var quantityPicked = document.getElementById('quantity').value; // get the quantity\n //using those, add one item to the Cart\n cart.addItem(productPicked,quantityPicked);\n}", "function appendToCart(){\n ui.cartItems.innerHTML = \"\";\n cart.forEach((item)=>{\n ui.appendToCart(item.imgSrc,item.title,item.size,item.price,item.id,item.numberOfUnits);\n })\n}", "_addToCart() {\n\t\tthis.dispatchEvent(new CustomEvent('productselected', { detail: this.id, composed: true, bubbles: true }));\n\t}", "function addToCart(newItem, itemQuantity, itemPrice) {\n\n for (let i = 0; i < cartItems.length; i++) {\n if (cartItems[i].item === newItem) {\n cartItems[i].quantity += itemQuantity;\n total()\n\n return\n }\n }\n\n setCartItems([...cartItems, {\n item: newItem,\n quantity: itemQuantity,\n price: itemPrice\n }])\n\n\n total()\n }", "function addItem() {\n\t\t\tvar order = ordersGrid.selection.getSelected()[0];\n\n\t\t\titensStore.newItem({\n\t\t\t\tpi_codigo: \"new\" + itensCounter,\n\t\t\t\tpi_pedido: order ? order.pe_codigo : \"new\",\n\t\t\t\tpi_prod: \"\",\n\t\t\t\tpi_quant: 0,\n\t\t\t\tpi_moeda: \"R$\",\n\t\t\t\tpi_preco: 0,\n\t\t\t\tpi_valor: 0,\n\t\t\t\tpi_desc: 0,\n\t\t\t\tpi_valort: 0,\n\t\t\t\tpr_descr: \"\",\n\t\t\t\tpr_unid: \"\"\n\t\t\t});\n\t\t\t\n\t\t\titensCounter = itensCounter + 1;\n\t\t}", "function setItems(product){\r\n let cartItems = localStorage.getItem('productsInCart');\r\n cartItems = JSON.parse(cartItems);\r\n //checked if the cartItems is null\r\n if(cartItems != null){\r\n if(cartItems[product.tag] == undefined){\r\n cartItems = {\r\n ...cartItems,\r\n [product.tag]: product\r\n }\r\n }\r\n cartItems[product.tag].inCart += 1; \r\n } else {\r\n product.inCart = 1;\r\n cartItems = {\r\n [product.tag]: product\r\n }\r\n } \r\n product.inCart = 1;\r\n\r\n //json stringify turns object into subjects that can stored on the browser local storage\r\n localStorage.setItem(\"productsInCart\", JSON.stringify (cartItems));\r\n}", "addToCart(newItem) {\n let itemExisted = false\n let updatedCart = this.state.cart.map(item => {\n if (newItem === item.sku) {\n itemExisted = true\n return { sku: item.sku, quantity: ++item.quantity }\n } else {\n return item\n }\n })\n if (!itemExisted) {\n updatedCart = [...updatedCart, { sku: newItem, quantity: 1 }]\n }\n this.setState({ cart: updatedCart })\n // Store the cart in the localStorage.\n // localStorage.setItem('stripe_checkout_items', JSON.stringify(updatedCart))\n }", "_addNewItem() {\n // Add new Item from Order's Items array:\n this.order.items = this.order.items.concat([this.item]);\n // Update current Order:\n this.orderService.setCurrentOrder(this.order);\n this._closeAddNewItem();\n }", "ADD_TO_CART(state, product) {\n // Check if cart is empty\n if (Object.keys(state.cart).length != 0) {\n for (const [key, value] of Object.entries(state.cart)) {\n // Check if product already in cart, then change quantity \n if (key === product.reference) {\n product.qty = value.qty + state.qty\n state.cart[key].qty = product.qty\n } else {\n state.cart[product.reference] = product\n }\n }\n } else {\n state.cart[product.reference] = product\n }\n }", "function addItemsToCart(button, products) {\n button.innerText = 'Added to Bag'; // change button text\n let productId = button.dataset.id; // get the id of the button that was clicked\n let product = products.find(product => { // compare if the array id and the returned id are the same\n return product.id === productId;\n });\n product['quantity'] = 1;\n product['discount'] = 0;\n product['total'] = product.price;\n product['discountedTotal'] = product.price;\n\n //add items to local storage\n let items;\n let cartItems = localStorage.getItem('cartItems');\n if (cartItems) {\n items = JSON.parse(cartItems);\n let itemExists = items.find(item => item.id === product.id);\n if (!itemExists) {\n items.push(product);// add product to the array\n }\n localStorage.setItem('cartItems', JSON.stringify(items));\n } else {\n items = [product];\n localStorage.setItem('cartItems', JSON.stringify(items));// put it in local storage\n }\n //send items to cart ui\n sendItemsToCartUI(items);\n grandTotals(items);\n document.querySelector('.cart-items').innerText = items.length;\n // show cart on the screen\n openCart();\n}", "addToCart(text, price)\n {\n let count = 1;\n let item = {Name:text, Count:count, Price:price};\n let fl=1;\n for (i = 0; i < cart.length; i++) {\n if(cart[i].Name === text)\n {\n cart[i].Count=cart[i].Count+1;\n cart[i].Price=Number(cart[i].Price)+Number(price);\n fl=0;\n break;\n\n }\n }\n if(fl==1){\n cart.push(item);\n }\n // for(i=0; i<cart.length; i++){\n // console.log(\"item: \"+i+\" is \"+cart[i].Name+\" count \"+cart[i].Count+\" price \"+cart[i].Price); \n // }\n window.alert('Added to cart.');\n this.render();\n }", "setupCart()\r\n\t{\r\n\t\tthis.cart = {};\r\n\t\tthis.cart.id = Str.random(10);\r\n\t\tthis.cart.items = [];\r\n\t\tthis.cart.favorites = [];\r\n\t\tCookie.set(this.settings.cookie_name, this.cart, 2);\r\n\t}", "function setItems(product) {\n //Get cartItems in local Storage\n let cartItems = localStorage.getItem('productsInCart');\n //Because of productsInCart now is string but now we want it string to array Json =>\n cartItems = JSON.parse(cartItems);\n //Check cartItems \n if (cartItems != null) {\n //Check product have tag or not =>\n if (cartItems[product.tag] == undefined) {\n //Set cartItem with tag =>\n cartItems = {\n ...cartItems,\n [product.tag]: product\n }\n }\n //=> if cartItem in stock => +1 cart in next time\n cartItems[product.tag].inCart += 1;\n }\n else {\n //=>if not, cart =1 and next time will be +1=> loop if\n product.inCart = 1;\n //=>set cartItems\n cartItems = {\n [product.tag]: product\n }\n }\n //cartItems array to string =>\n localStorage.setItem(\"productsInCart\", JSON.stringify(cartItems));\n}", "function addToCart(newItem) {\n console.log(newItem);\n const index = findCartItem(\n newItem.product.id,\n newItem.toppings,\n newItem.remark\n );\n\n if (index === -1) {\n setCart([...cart, { ...newItem, id: uuidV4() }]);\n } else {\n return -1;\n }\n }", "addToCart() {\n const addedItemsId = this.props.cart.addedItems.map(item => item.id);\n const check = addedItemsId.includes(this.props.item.id);\n if (!check) {\n const item = {\n id: this.props.item.id,\n name: this.props.item.ename,\n price: this.props.item.price,\n ingredient: this.props.item.dish_ingradint,\n photo: this.props.item.dishImage_thump,\n availability: this.props.item.active,\n restaurantName: this.props.restaurantItem.restaurantName,\n restaurantId: this.props.restaurantItem.id,\n quantity: 1,\n deliveryCost: this.props.restaurantItem.deliveryCost\n };\n this.props.addItemToCart(item);\n }\n if (check) {\n Alert.alert('', 'this item is already added to cart');\n }\n }", "handleAddClick() {\n var isProductInCart = false;\n var newCart = this.state.cart.slice();\n var product = this.state.products[this.state.value];\n /*Searchs for the product in the cart*/\n\n var newProduct = {\n id: product.id,\n name: product.name,\n price: product.price,\n description: product.description,\n quantity: this.state.quantity\n };\n for (let i = 0; i < newCart.length; i++) {\n if (product.id == newCart[i].id) {\n newCart[i].quantity += this.state.quantity;\n isProductInCart = true;\n }\n }\n /*if is not there add it*/\n if (!isProductInCart) newCart.push(newProduct);\n this.setState({ cart: newCart });\n }", "function setCart() {\n cart.forEach(\n (item) =>\n !filteredCart.filter(\n (cart) => (cart.name === item.name) & (cart.size === item.size)\n ).length > 0 && filteredCart.push(item)\n );\n\n filteredCart.forEach((item) =>\n cartNew.push(\n cart.filter((i) => (i.name === item.name) & (i.size === item.size))\n )\n );\n }", "function addToCarts(id){\r\n if(!data[id].itemInCart){\r\n cartList = [...cartList,data[id]];\r\n addItem();\r\n\r\n alert('item add to your cart');\r\n }\r\n else{\r\n alert('Your item is already there');\r\n }\r\n data[id].itemInCart = true;\r\n}", "function addItem(){\n var itemName = $(\"#spinlabel\").html();\n var quantity = $(\"#spin\").val();\n for(var i = 0; i < CurrentShoppingListArray.length; i++){\n if(itemName == CurrentShoppingListArray[i].name){\n CurrentShoppingListArray[i].quantity = parseInt(CurrentShoppingListArray[i].quantity) + parseInt(quantity);\n return;\n }\n }\n var tempItem = new Item(itemName, quantity);\n CurrentShoppingListArray.push(tempItem);\n}", "function addFirstItemToLocalStorage() {\n let products = [];\n products[0] = {\n id: id,\n quantity: 1,\n };\n\n setItemToLocalStorage('productsCart', products);\n }", "handleAddToCard (e, products) {\n this.setState(state => {\n const cartItems = state.cartItems;\n let productAlreadyInCart = false;\n cartItems.forEach(item => {\n console.log('dentro de forEach')\n if (item._id === products._id) {\n productAlreadyInCart = true;\n item.count++;\n }\n });\n if (!productAlreadyInCart) {\n console.log('dentro de cartItem push')\n cartItems.push({...products, count: 0});\n }\n localStorage.setItem(\"cartItems\", JSON.stringify(cartItems));\n console.log(this.state.cartItems, \"cart item\")\n return cartItems;\n })\n }", "function addItems() {\n\t\t\t\tvar form = $(psForms.shift());\n\t\t\t\tvar itemid = form.find(\"input[name='pid']\").val();\n\n\t\t\t\t$.ajax({\n\t\t\t\t\tdataType : \"html\",\n\t\t\t\t\turl: addProductUrl,\n\t\t\t\t\tdata: form.serialize()\n\t\t\t\t})\n\t\t\t\t.done(function (response) {\n\t\t\t\t\t// success\n\t\t\t\t\tminiCartHtml = response;\n\t\t\t\t})\n\t\t\t\t.fail(function (xhr, textStatus) {\n\t\t\t\t\t// failed\n\t\t\t\t\tvar msg = app.resources.ADD_TO_CART_FAIL;\n\t\t\t\t\t$.validator.format(msg, itemid);\n\t\t\t\t\tif(textStatus === \"parsererror\") {\n\t\t\t\t\t\tmsg+=\"\\n\"+app.resources.BAD_RESPONSE;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tmsg+=\"\\n\"+app.resources.SERVER_CONNECTION_ERROR;\n\t\t\t\t\t}\n\t\t\t\t\twindow.alert(msg);\n\t\t\t\t})\n\t\t\t\t.always(function () {\n\t\t\t\t\tif (psForms.length > 0) {\n\t\t\t\t\t\taddItems();\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\tquickView.close();\n\t\t\t\t\t\tminicart.show(miniCartHtml);\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}", "function addToCart(){\n//the function to add chosen door to a cart\n//and put it to a LOCAL STORAGE\nvar chosenItem = this.getAttribute('data-button-propName'); // chosen item is an unique item, chosen with a button click and added to CARTFORITEMS object\n if(cartForItems[chosenItem] != undefined){\n cartForItems[chosenItem] = cartForItems[chosenItem]+1;\n }else{\n cartForItems[chosenItem] = 1;\n }\n totalPrice += priceCollector[chosenItem].price;\nlocalStorage.setItem('addedToCartItems', JSON.stringify(cartForItems));\nlocalStorage.setItem('addedTotalPrice', JSON.stringify(totalPrice));\nconsole.log(cartForItems[chosenItem]);\nconsole.log(totalPrice);\nshowItemsInCart();\nrenderDiv();\n}", "cartPlusOne(product) {\r\n product.quantity = product.quantity + 1;\r\n }", "function storingCartItem() {\n \n /**\n * TODO: Create Product Object\n */\n let cartItem = product;\n cartItem.quantity = 1;\n cartItem.lensOption = updatePersonalizedFeatures();\n\n /**\n * TODO: Get \"cartItems\" value \n */\n let cartItems = JSON.parse(localStorage.getItem('cartItems'));\n\n\n /**\n * TODO: Update \"cartItems\" value with new Product Object (Push to the Array)\n */\n cartItems.push(cartItem);\n localStorage.setItem('cartItems', JSON.stringify(cartItems));\n\n // update cart badge\n let cartItemsQuantity = document.getElementById('cartItemQuantity');\n cartItemsQuantity.style.display = \"inline-block\";\n updateCartBadge();\n \n /**\n * TODO: Further \"Add to cart\" stuff....\n */\n //goToCartPage();\n \n console.log(cartItems);\n\n}", "addItem(item) {\n this.items.push(item);\n // tegye közzé a frissített elemek listáját, hogy frissítse a Cart topic-ot\n // amikor a cart tartalma frissült\n PubSub.publish(\"updateCart\", this.getItems());\n }", "_incrementQuantity(evt) {\n console.log('_incrementQuantity');\n const productId = evt.currentTarget.dataset['product'];\n\n const cartItem = this._findCartItem(productId);\n\n const index = this.cartItems.indexOf(cartItem);\n this.cartItems[index].quantity = cartItem['quantity'] + 1;\n this.cartItems = [...this.cartItems]; // this.cartItems[index] = cartItem['quantity'] + 1;\n // this.set('cartItems.' + index + '.quantity', cartItem['quantity'] + 1);\n\n localStorage.setItem('shop-cart', JSON.stringify(this.cartItems));\n this.dispatchEvent(new CustomEvent('change-cart-count', {\n bubbles: true,\n composed: true,\n detail: {}\n }));\n }", "function updateCart(e) {\n event.preventDefault();\n var selectedProduct = e.target.productToPurchase.value;\n var selectedQuantity = e.target.quantityInCart.value;\n\n console.log(selectedProduct);\n console.log(selectedQuantity);\n\n // ++ to the timesClicked property for image user click on\n for(var i in Product.allProducts){\n if(selectedProduct === Product.allProducts[i].name){\n Product.allProducts[i].quantityInCart = selectedQuantity;\n console.log(Product.allProducts[i]);\n }\n }\n localStorage.setItem('shoppingCart', JSON.stringify(Product.allProducts));\n}", "addProduct(state, action) {\n const newItem = action.payload;\n\n const existingItem = state.cartItems.find(\n (item) => item.title === newItem.title\n );\n if (!existingItem) {\n // don't use ==\n state.cartItems.push({\n id: newItem.id,\n title: newItem.title,\n price: newItem.price,\n quantity: 1,\n total: newItem.price,\n });\n console.log(\"updated new listing\", current(state));\n } else {\n // find_index\n const itemIndex = state.cartItems.findIndex(\n (item) => item.title === newItem.title\n );\n // console.log(itemIndex);\n // select item\n const selectedItem = state.cartItems[itemIndex];\n //\n const newQty = selectedItem.quantity + 1;\n const newTotal = selectedItem.total + selectedItem.price;\n\n state.cartItems[itemIndex] = {\n ...newItem, // keeps other items in the object\n quantity: newQty,\n total: newTotal,\n };\n\n // console.log(\"updated existing\", current(state));\n }\n }", "addItem(newItem) {\n for (let index in this.items) {\n let item = this.items[index];\n if (item.id === newItem.id) {\n item.quantity += newItem.quantity;\n this.updateTotal();\n return;\n }\n }\n\n this.items.push(newItem);\n this.updateTotal();\n }", "function updateCart(){\n\t\tstorage(['items', 'subtotal'], function(err, col){\n\t\t\t//console.log(\"Cart Collection - \" + JSON.stringify(col));\n\n\t\t\t//items = col[0];\n\t\t\t//subtotal = col[1];\n\n\t\t\tif(console) console.log(\"Items in Cart: \" + items);\n\t\t\tif(console) console.log(\"Subtotal of Cart: \" + subtotal);\n\t\t\t\n\t\t\t// update DOM Here\n\t\t\tdocument.getElementById( _options.itemsEleId ).innerHTML = items;\n\t\t\tdocument.getElementById( _options.subtotalEleId ).value = \"$\" + subtotal.toFixed(2);\n\n\t\t\t// reset default quantity input fields of products\n\t\t\tPRODUCTS.updateProducts();\n\t\t});\n\t}", "handleAddCart(e, product){\n this.setState(state => {\n const cartItems = state.cartItems;\n let productAlreadyInCart = false;\n cartItems.forEach(item => {\n if(item.id === product.id){\n productAlreadyInCart= true;\n item.count++;\n }\n });\n if(!productAlreadyInCart){\n cartItems.push({...product, count:1});\n }\n localStorage.setItem(\"cartItems\",JSON.stringify(cartItems));\n return cartItems;\n })\n }", "addItem(i,q){\n this.itemList.push(i);\n this.itemQuantity.push(q);\n }", "addItem(i,q){\n this.itemList.push(i);\n this.itemQuantity.push(q);\n }", "function addToCartClicked(event) {\n document.querySelector(\".custom\").style.display = \"block\";\n var button = event.target;\n var shopItem = button.parentElement.parentElement;\n var title = shopItem.getElementsByClassName(\"shop-item-title\")[0].innerText;\n var price = shopItem.getElementsByClassName(\"shop-item-price\")[0].innerText;\n var imageSrc = shopItem.getElementsByClassName(\"shop-item-image\")[0].src;\n items = {\n title,\n price,\n imageSrc,\n };\n\n // check if the total is updating\n}", "addItem(name, quantity, pricePerUnit) {\n this.items.push({\n name,\n quantity,\n pricePerUnit\n })\n }", "addToCart(index) {\n var product = productList[index];\n var cartCopy = this.state.cart.slice();\n cartCopy[cartCopy.length] = {\n name: product.name,\n price: product.price\n };\n }", "function addSelectedItemToCart() {\n\n let quantityTextbox = document.getElementById('quantity').value;\n let ddlProducts = document.getElementById(\"items\");\n let selectedOption = ddlProducts.value; \n cart.addItem(selectedOption, quantityTextbox);\n \n}", "addItem(item) {\n\t // makes a copy of state\n\t const newItems = this.state.inventoryItems;\n\t // add new item\n\t const timestamp = Date.now();\n\t newItems[`item-${timestamp}`] = item;\n\t // // set state\n\t this.setState({\n\t\t\t\tinventoryItems: newItems\n\t\t\t})\n\t }", "function updateCart() {\n emptyCart();\n let items = JSON.parse(localStorage.getItem('items'));\n if(items !== null) {\n if(typeof items.forEach !== \"function\") {\n items = [items];\n }\n items.forEach(function(item) {\n $('#shoppingcart-items').append(\n \"<li class='cart-item'>\" +\n \"<span>\" + item.name + \"</span>\" +\n \"<span>\" + item.size + \"</span>\" +\n \"<span>\" + item.color + \"</span>\" +\n \"<span>\" + item.amount + \"</span>\" +\n \"<span class='cart-item-price'>\" + item.price + \"</span>\" +\n \"<a class='remove-item' href='#' data-item='\" + item.name + \"'><i class='fa fa-times' aria-hidden='true'></i></a>\" +\n \"</li>\");\n });\n localStorage.setItem('items-timestamp', (+ new Date() / 1000) );\n }else {\n removeAllStorage();\n \n }\n updateCounter();\n updateTotal();\n }", "addOne(item) {\n const newItems = this.state.inventoryItems;\n newItems[item].quantity = parseInt(newItems[item].quantity);\n newItems[item].quantity = (newItems[item].quantity + 1);\n this.setState({\n inventoryItems: newItems\n })\n }", "function initItems() {\n $(\"#add-items\").find(\".add-item\").mousedown(function(e) {\n var modelUrl = $(this).attr(\"model-url\");\n var itemType = parseInt($(this).attr(\"model-type\"));\n var metadata = {\n itemName: $(this).attr(\"model-name\"),\n resizable: true,\n modelUrl: modelUrl,\n itemType: itemType\n }\n\n blueprint3d.model.scene.addItem(itemType, modelUrl, metadata);\n setCurrentState(scope.states.DEFAULT);\n });\n }", "addToCartBtn(e){\n\n this.productItem = this.$.productListItem.itemForElement(e.target);\n console.log(this.$.productListItem);\n this.$.selector.select(this.productItem);\n\n //Storing the data in to local storage\n this.productList = JSON.parse(localStorage.getItem(\"setProductItemsInLocalStorage\"));\n console.log('this.productEntries :' + this.productList);\n if (this.productList == null) this.productList = [];\n this.produclistArray = [];\n\n //Getting the Product price value\n var totalprice = this.productItem.price;\n console.log('totalamount :' + totalprice);\n\n //Pushing the productItem to produclistArray\n this.produclistArray.push(this.productItem.img, this.productItem.productName, this.productItem.price,this.productItem.id, totalprice)\n console.log(this.produclistArray);\n\n // Getting current selected values and setting to CurrentProductList\n window.localStorage.setItem('CurrentProductList', JSON.stringify(this.produclistArray));\n\n //Pushing the data to products list Array\n this.productList.push(this.produclistArray);\n\n //Finally store the all products using localstorage setitem\n window.localStorage.setItem(\"setProductItemsInLocalStorage\", JSON.stringify(this.productList));\n\n //reload the page to set the values in shopping-cart\n location.reload();\n\n // adding tot product price amount\n\n this.productPrice = window.localStorage.getItem('totalprice');\n if(this.productPrice != null){\n this.productPrice = parseInt(this.productPrice);\n window.localStorage.setItem(\"totalprice\", this.productPrice + this.productItem.price);\n } else{\n window.localStorage.setItem(\"totalprice\", this.productItem.price);\n }\n\n\n }", "function addItemToCart(name, price, count) {\n for (var i in cart) {\n if (cart[i].name === name) {\n cart[i].count += count;\n saveCart();\n displayCart();\n return;\n }\n }\n var item = new Item(name, price, count);\n cart.push(item);\n saveCart();\n displayCart();\n }", "function addItemToCart(user, item) {\n\n}", "add(event, item) {\n event.preventDefault();\n this.props.addToBasket({\n product_id: item.product_id,\n product_name: item.product_name,\n product_images: item.product_images,\n product_price: item.product_price\n })\n }", "function onClickActionAddCartItem(e){\n\t\t\n\t\tvar html = '';\n\t\tlet itemId = parseInt(e.currentTarget.dataset.itemid);\n\t\tvar it = DB.getItemInfo( itemId );\n\t\tvar content = CashShop.ui.find('.container-cart');\n\t\tconst itemCart = CashShop.cartItem.find(i => i.itemId === itemId);\n\t\tvar item = [];\n\t\tvar tab = 0;\n\t\tif(CashShop.activeCashMenu !== 'SEARCH_RESULT'){\n\t\t\titem = CashShop.cashShopListItem[CashShop.activeCashMenu].items.find(i => i.itemId === itemId);\n\t\t\ttab = CashShop.cashShopListItem[CashShop.activeCashMenu].tabNum;\n\t\t} else {\n\t\t\titem = CashShop.csListItemSearchResult.find(i => i.itemId === itemId);\n\t\t\ttab = item.tab;\n\t\t}\n\n\t\tif(content.find('#cart-list .items .no-items').length > 0){\n\t\t\tcontent.find('#cart-list .items .no-items').remove();\n\t\t}\n\n\t\tif(CashShop.cartItem.length > 4 && typeof itemCart === 'undefined'){\n\t\t\t//only 5 item can store in cart\n\t\t\tUIManager.showMessageBox( '5 Item can only stored in cart!', 'ok');\n\t\t\treturn;\n\t\t}\n\n\t\tif(item.amount >= 99){\n\t\t\tUIManager.showMessageBox( 'Max Quantity 99!', 'ok');\n\t\t\tChatBox.addText( 'Max Quantity 99!', ChatBox.TYPE.ERROR);\n\t\t\treturn;\n\t\t}\n\n\t\tif(typeof itemCart === 'undefined'){\n\t\t\titem.amount = 1;\n\t\t\titem.tab = tab;\n\t\t\tCashShop.cartItem.push(item);\n\t\t\thtml = `<li class=\"item\" data-index=\"${itemId}\">\n\t\t\t\t\t<div class=\"inner-item-dt\">\n\t\t\t\t\t\t<div class=\"delete-item\"><button>x</button></div>\n\t\t\t\t\t\t<div class=\"item-dt-img\"></div>\n\t\t\t\t\t\t<div class=\"item-dt-desc\">\n\t\t\t\t\t\t\t<div class=\"item-desc-top\">${it.identifiedDisplayName}</div>\n\t\t\t\t\t\t\t<div class=\"item-counter\">\n\t\t\t\t\t\t\t\t<div class=\"item-cnt\">${item.amount}</div>\n\t\t\t\t\t\t\t\t<button class=\"counter-btn item-cnt-up\" data-index=\"up\"></button>\n\t\t\t\t\t\t\t\t<button class=\"counter-btn item-cnt-down\" data-index=\"down\"></button>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"item-desc-price\">\n\t\t\t\t\t\t\t\t<div class=\"icon-gold-coin\"></div>\n\t\t\t\t\t\t\t\t<span>${item.price}</span>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t</li>`;\n\t\t\tcontent.find('.items').append(html);\n\t\t\tClient.loadFile( DB.INTERFACE_PATH + 'collection/' + ( it.identifiedResourceName ) + '.bmp', function(data){\n\t\t\t\tcontent.find('.item[data-index=\"'+ itemId +'\"] .item-dt-img').css('backgroundImage', 'url('+ data +')');\n\t\t\t});\n\n\t\t\tClient.loadFile( DB.INTERFACE_PATH + 'cashshop/img_shop_itemBg2.bmp', function(data){\n\t\t\t\tcontent.find('.item-counter').css('backgroundImage', 'url('+ data +')');\n\t\t\t});\n\t\t} else {\n\t\t\titemCart.amount += 1;\n\t\t\tcontent.find('.items .item[data-index=\"'+itemId+'\"] .item-cnt').html(itemCart.amount);\n\t\t}\n\t\tCashShop.cartItemTotalPrice = CashShop.cartItem.map(item => item.price * item.amount).reduce((prev, next) => prev + next);\n\t\tCashShop.ui.find('.container-cart-footer .item-desc-price span').html(CashShop.cartItemTotalPrice);\n\t}", "function addToCart(event) {\n console.log(event);\n\n if (cart.length == 0) {\n // if there is nothing in the cart \n console.log(\"there was nothing in the cart, lets add this product: \", event.data.added.title);\n\n cart.push(event.data.added);\n\n localStorage.setItem(\"cart\", JSON.stringify(cart));\n\n } else {\n\n let foundProduct = false;\n\n $.each(cart, function (index, product) {\n\n if (product.id === event.data.added.id) {\n console.log(\"something similar!\", product.title, product.quantity);\n product.quantity++;\n product.price = product.pricePerUnit * product.quantity;\n foundProduct = true;\n }\n });\n\n // add of a loop over the order array to add total price?\n if (!foundProduct) {\n console.log(\"new product! we simply add it\");\n cart.push(event.data.added);\n }\n\n localStorage.setItem(\"cart\", JSON.stringify(cart));\n }\n\n createCart();\n showBadge();\n}", "function addToCart()\n\t{\n\t\t// avoid adding to cart before the item info is fetched\n\t\t// if( product.ASIN === undefined) return ;\n\t\tif( product === undefined) return ;\n\t\t\n\t\tvar newItem = Object.assign({}, product); \n\t\tnewItem.ID \t\t= Date.now();\n\t\t\n\t\t// console.log( \"product id: \" + newItem.ID );\n\t\tnewProduct = \"<tr>\"\n\t\t\t\t\t\t+ \"<td><img src=\\\"\"+ newItem.Image_url + \"\\\" class=\\\"thumbnail\\\" /> </td>\"\n\t\t\t\t\t\t+ \"<td>\"+ newItem.Color\t\t\t+\"</td>\"\n\t\t\t\t\t\t+ \"<td>\"+ newItem.Size\t\t\t+\"</td>\"\n\t\t\t\t\t\t+ \"<td>\"+ newItem.PriceSAR\t\t+\" ريال</td>\"\t\t\t\t\t\t\n\t\t\t\t\t\t+ \"<td>\"+ newItem.TaxSAR\t\t+\" ريال</td>\"\t\t\t\t\t\t\n\t\t\t\t\t\t+ \"<td>\"+ newItem.ShippingCost\t+\" ريال </td>\"\t\t\t\t\t\t\n\t\t\t\t\t\t+ \"<td> <i class='fi-x removeItem button alert' id='\"+ newItem.ID +\"'></i></td>\"\n\t\t\t\t\t\t+ \"</tr>\";\n\t\t\t\t\t\t\n\t\t$('#items > tbody:last-child').append(newProduct);\n\t\t$(\"#addToCartBtn\").notify(\"تم إضافته لسلة المشتريات\", {className:\"success\"});\n\t\t$(\"#itemsList\").slideDown();\n\t\t\n\t\t// save cart\n\t\tsaveCart(\"add\", newItem.ID);\n\t\t\n\t\t// start observer for remove from cart button\n\t\tobserveRemoveBtn();\n\t\t\n\t\t// add to invoice\n\t\taddToInvoice(newItem);\n\t}", "function addBasket() {\n if (basket.length === 0 || (basket.find(x => x.name === item.name)) === undefined) {\n item.quantity = updatedQuantity\n basket.push(item)\n } else {\n for (let i=0; i < basket.length; i++) {\n if (basket[i].name === item.name) {\n basket[i].quantity = basket[i].quantity + updatedQuantity\n } \n }\n }\n productTotal();\n basketCount();\n localStorage.setItem(\"savedBasket\", JSON.stringify(basket));\n}", "function addItemToCart(item, itemQuantity){\n if(isNaN(itemQuantity)){\n itemQuantity = 1; \n }\n var itemIsNew = true; \n cart.forEach(function (cartItem){\n if(cartItem.name === item.name){\n cartItem.quantity += itemQuantity; \n updateQuantityDisplay(cartItem); \n return itemIsNew = false\n } \n })\n if(itemIsNew){\n cart.push(item); \n item.quantity = itemQuantity; \n displayItem(item, itemQuantity, \".cart-container\")\n }\n}", "function handleAddToCart(id) {\n console.log('current addToCart: ' + addToCart);\n let theCart = cartContents;\n theCart.push(id);\n setCartContents(theCart);\n console.log('handleaddtocart cart: ' + theCart);\n setAddToCart(addToCart + 1);\n }", "function addToCart(payload) {\n const inCart = cartItems.findIndex((item) => item.beer === payload.beer);\n if (inCart === -1) {\n //add\n console.log(payload);\n const nextPayload = { ...payload };\n nextPayload.amount = payload.amount;\n setCartItems((prevState) => [...prevState, nextPayload]);\n } else {\n //it exists, modify amount\n const nextCart = cartItems.map((item) => {\n if (item.beer === payload.beer) {\n item.amount += payload.amount;\n }\n return item;\n });\n setCartItems(nextCart);\n }\n }", "addBoothToCart(product, subitem){\n this.cart.forEach(m => {\n if ( m.booths && m.id == product.id ){\n this.total -= m.price;\n this.cart = this.cart.filter(n => n.id !== m.id);\n }\n if ( m.notify ){\n this.cart = this.cart.filter(n => !n.notify);\n }\n })\n product.booths.booths = true;\n product.booths.quantity++;\n product.booths.name = subitem.name;\n product.booths.price = subitem.price;\n cartitem = Object.assign({}, product.booths);\n this.cart.push(cartitem);\n this.total += cartitem.price;\n }", "function addCartEntry() {\n\tlet productNumbers = localStorage.getItem('cartNumbers');\n //convert string of productNumbers into Int\n\tproductNumbers = parseInt(productNumbers);\n \n //if something is in the cart\n\tif(productNumbers) {\n\t\tlocalStorage.setItem('cartNumbers', productNumbers+1);\n\t\tdocument.querySelector('.cart-qty span').textContent = productNumbers + 1;\n\t} else {\n\t\tlocalStorage.setItem('cartNumbers', 1);\n\t\t//update all instances of .cart-qty span with the new number\n\t\tdocument.querySelector('.cart-qty span').textContent = 1;\n\t}\n\n\t//create object with color and filling information and add to storedCartList array\n\tvar storedCartList = JSON.parse(localStorage.getItem('cartItems'));\n if(storedCartList == null) storedCartList = [];\n var newitem = {\n \t'Product' : 'big ole comfy pillow',\n \t'Price' : '$$',\n\t\t'Color' : chosenColor,\n\t\t'Filling' : chosenFilling\n };\n localStorage.setItem('newitem', JSON.stringify(newitem));\n // Save cartItems back to local storage\n storedCartList.push(newitem);\n localStorage.setItem('cartItems', JSON.stringify(storedCartList));\n}", "function updateCart(item, price, amount, ID) {\n cartItems.push(item);\n cartCost.push(price);\n CartAmount.push(amount);\n cartIDs.push(ID);\n}", "function itemsClicked(callback) {\n var itemForm = {\n name : callback.item.naturalName,\n catalogCode : callback.item.catalogCode,\n number : 1\n };\n vm.store.createShoppingItem(itemForm);\n vm.externalModel = []; // use to clear the selected items\n }", "addToCart (productt) {\n checkRepeated(productt) \n added()\n console.log(productt)\n }", "function addProductToCart(product) {\n let cart = getCart();\n cart.items.push(product);\n\n setCart(cart);\n alert(product.name + ' added to cart, Total is R' + getTotal(cart));\n}", "function addItem (name, quantity) {\n if(cart[name] == undefined) {\n createItem(name);\n }\n cart[name] = cart[name] + quantity;\n}" ]
[ "0.7762722", "0.7326693", "0.7265426", "0.7265426", "0.72461456", "0.71997476", "0.7058776", "0.69982564", "0.69665176", "0.6965611", "0.69420576", "0.68941665", "0.6893985", "0.68878645", "0.6875005", "0.6870788", "0.6860676", "0.6849292", "0.68060195", "0.67960274", "0.6791422", "0.6770826", "0.6750582", "0.6750171", "0.67347413", "0.6727289", "0.67271334", "0.67060274", "0.67038035", "0.6690069", "0.66870147", "0.66685224", "0.66629976", "0.6658784", "0.66561973", "0.66558665", "0.663055", "0.6626581", "0.66257936", "0.66103", "0.66077954", "0.65934765", "0.6593155", "0.6592266", "0.65836054", "0.65721744", "0.65683585", "0.65622574", "0.65572006", "0.65562946", "0.6549531", "0.6543186", "0.65402687", "0.65295726", "0.65208983", "0.65161276", "0.65055513", "0.65023893", "0.64953834", "0.64946395", "0.6488611", "0.64826655", "0.64814824", "0.6477668", "0.6471142", "0.64695066", "0.6458584", "0.6451847", "0.6441765", "0.6433562", "0.6430636", "0.6423689", "0.64159745", "0.64159745", "0.6394993", "0.6389352", "0.6387457", "0.63811177", "0.6362474", "0.6362399", "0.63408816", "0.63207996", "0.6320505", "0.631199", "0.63057685", "0.6302237", "0.6300576", "0.6296738", "0.62944335", "0.62893724", "0.6284032", "0.6277535", "0.6266576", "0.62656015", "0.62588155", "0.62394565", "0.6237115", "0.62358814", "0.62336135", "0.6232944" ]
0.68060637
18
Tallies up the total cost of items
function totalCost(products) { console.log("The product price is", products.price); let cartCost = localStorage.getItem('totalCost'); console.log("my cartCost is", cartCost); if(cartCost != null) { cartCost = parseInt(cartCost); localStorage.setItem("totalCost", cartCost + products.price); } else { localStorage.setItem("totalCost", products.price); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getTotalCost() {\n return this.transactions.map(t => t.cost).reduce((acc, value) => acc + value, 0);\n }", "getTotalSelectedItemsCost() {\n const totalCost = this.itemModelList.data.reduce((prevVal, item) => {\n if (!item.isChecked) {\n return prevVal;\n }\n\n return prevVal + MartCtrl.getItemCost(item);\n\n }, 0);\n\n events.emit(MART_CTRL_SET_TOTAL_COST, totalCost);\n }", "total() {\n var total = 0.0\n for (var sku in this.items) {\n var li = this.items[sku]\n var price = li.quantity * li.price\n total += price\n }\n return total\n }", "function totalCost() {\n var cost = price * quantity\n return cost;\n}", "function total() {\n let totalCost = 0\n for (var i = 0; i < cart.length; i++) {\n for (var item in cart[i]) {\n totalCost += cart[i][item]\n }\n }\n return totalCost\n}", "function TotalCost()\n{\n\tvar totalcost = 0;\n\tfor (var i in Cart) {\n\ttotalcost += Cart[i].price;\n\t}\n\treturn totalcost;\n}", "function calcTotal(itemId, itemPrice, orderQty) {\n var total = orderQty * itemPrice;\n console.log(\"Total Cost is $\" + total.toFixed(2));\n}", "function getTotalPrice(items) {\n return _.reduce(items, function(memo, item) {\n return memo + item.quantity * item.price;\n }, 0);\n }", "function compute_subtotal(items) {\n\t$(\".wddp-shopping-cart\").text(\"Shopping cart total: $\" + Object.values(items).reduce((x, y) => (x + y), 0));\n}", "getTotalWithTax() {\n \n // total individual items from getPriceWithTax\n let totWithTax = 0;\n this.items.forEach((net) => {\n totWithTax += net.getPriceWithTax();\n });\n return totWithTax;\n }", "function calc_total(frm){\n\tvar total_cost = 0;\n\tcur_frm.doc.sold_waste_item.forEach(function(_){\n\t\ttotal_cost += _.amount\n\t});\n\tfrappe.model.set_value(cur_frm.doctype,cur_frm.docname, \"total\", total_cost)\n}", "function budgetCalculator(watch, phone, laptop){\n // cost every single item\n var watchCost = watch * 50;\n var phoneCost = phone * 100;\n var laptopCost = laptop * 500;\n //total cost of all item.\n var totalCost = watchCost + phoneCost + laptopCost;\n return totalCost;\n\n}", "function getTotalCost(data) {\n var total = 0;\n data.forEach(function(element) {\n total += parseInt(element.cost);\n });\n \n return total.toFixed(2);\n}", "function calcTotal() {\n let total = 0;\n for (let item of itemList) {\n total += Number(item.price);\n }\n console.log(\"this is the total\", total);\n return total;\n }", "function calcItemPrice(baseCost, quantity, frameCost, glassCost, mattID) {\n var cost = (baseCost + frameCost + glassCost) * quantity;\n if(mattID != 35) { cost += (10 * quantity);}\n return formatMoney(cost);\n }", "function totalCost(){\n var totalCartCost=0;\n for(var i in cart){\n \t totalCartCost+=cart[i].price*cart[i].count; \n }\n return totalCartCost; \n}", "updateTotal() {\n let total = 0;\n for (let index in this.items) {\n let item = this.items[index];\n total += item.price * item.quantity;\n }\n this.total = total;\n }", "function costWithTax(item) {\n return parseFloat( item.price + taxForItem(item) );\n }", "function updatePrice() {\n var sum = 0;\n for(var i = 0; i < $scope.currentItems.length; i++) {\n sum += $scope.currentItems[i].price;\n }\n\n $scope.totalCost = sum + (sum * taxRate);\n $scope.totalCost = Math.floor($scope.totalCost);\n console.log($scope.totalCost);\n }", "function showAllItemsCost() {\n\tshowCost(healthKitShopItemEl, healingCost);\n\tshowCost(improveMagazineShopItemEl, magazineIncreaseCost);\n\tshowCost(fasterReloadShopItemEl, decreaseReloadingTimeCost);\n\tshowCost(increasePowerUpDurationShopItemEl, powerUpDurationIncreaseCost);\n}", "getOrderTotal() {\n\n return Object.values(this.lineItems).reduce(\n (total, {product, sku, quantity}) =>\n total + quantity * this.plans[0].amount,\n 0\n );\n }", "total (itens) {\n prod1 = list[0].amount\n prod2 = list[1].amount\n prod3 = list[2].amount\n prod4 = list[3].amount\n\n itens = prod1 + prod2 + prod3 + prod4\n\n return itens\n }", "amt_of(item) { }", "function ItemCosts({ price, qty }) {\n const itemTotal = calculateItemTotal(price, qty);\n\n return (\n <div className=\"itemTotal\">\n {formatPrice(itemTotal)}\n </div>\n );\n}", "totalSpent(){\n return this.meals().reduce((a,b)=>(a += b.price), 0);\n }", "function total(cost) {\n var total = subtotal * '.08';\n return total;\n}", "function getTotal() {\n\t\treturn cart.reduce((current, next) => {\n\t\t\treturn current + next.price * next.count;\n\t\t}, 0);\n\t}", "function calculateTotalPrice(orderedItems) {\n let totalPrice = 0;\n // Пиши код ниже этой строки\n\n \n\n orderedItems.forEach(function( orderedItems, index,){\n \ttotalPrice += orderedItems;\n }); \n // Пиши код выше этой строки\n return totalPrice;\n}", "totalPrice() {\n let sum = 0;\n\n for(let i = 0; i < this.state.items.length; i++){\n sum += this.totalItemPrice(this.state.items[i]);\n }\n return sum;\n }", "function totalCost() {\n var totalCost = 0;\n if (localStorage.BASKET) {\n var json = JSON.parse(localStorage.BASKET);\n\n for (var i = 0; i < json.length; i++) {\n var product = JSON.parse(json[i]);\n var lineTotal = parseFloat(product.productPrice) *\n parseFloat(product.quantity);\n totalCost += lineTotal;\n }\n }\n return totalCost;\n}", "function calculateTotalCost(rowIndex){\n\tvar ds=View.dataSources.get('createMultiSupplyReqPartLocDs');\n\tvar quanity=replaceLocalizedDecimalSeparatorByDot(document.getElementById(\"row_trans_index_\"+rowIndex).value);\n\tvar unitCost=replaceLocalizedDecimalSeparatorByDot(document.getElementById(\"row_unitCost_index_\"+rowIndex).value);\n\t\n\tvar totalCost=View.controllers.get('addToExistPurchaseOrderMultipleController').calculateTotalCost(quanity,unitCost);\n\t\n\tdocument.getElementById('row_totalCost_index_'+rowIndex).innerHTML=ds.formatValue('pt_store_loc_pt.cost_unit_std',totalCost,true);\n\t\n}", "function total() {\n let totalVal = 0;\n for (var i = 0; i < cartItems.length; i++) {\n totalVal += cartItems[i].price * cartItems[i].quantity\n }\n setCartTotal(totalVal)\n }", "get amount() {\n\t\t\treturn this.items\n\t\t\t\t.map(item => item.qty * item.price)\n\t\t\t\t.reduce((total, qty) => total += qty, 0);\n\t\t}", "findTotalItemCost() {\n let sum = 0;\n this.state.inventory_costs.map((inventory_cost) => {\n const itemTotal = inventory_cost.inventory_quantity * inventory_cost.cost_per_unit;\n sum += itemTotal;\n return sum;\n\n })\n console.log(sum, 'before setting state SUM')\n this.setState({\n totalCost: sum\n });\n }", "function computeTotal(data, callback){\n var appleSum = 0;\n var tomatoSum = 0;\n data.Items.forEach(function(entry){\n if(entry.offeredGoods.S == 'Tomatoes')\n tomatoSum = (tomatoSum*1 +entry.Capacity.N*1);\n else\n appleSum = (appleSum*1 +entry.Capacity.N*1);\n })\n total = [\n {\"Name\": \"Apples\", \"Quota\": appleSum},\n {\"Name\": \"Tomatoes\", \"Quota\": tomatoSum}\n ]\n callback(total);\n}", "subtotal() {\n return this.state.dishes\n .map(dish => (dish.price.num))\n .reduce(Utils.sumFunc, 0);\n }", "function sumValues() {\n return data.reduce((temp, currValue) => temp + currValue.cost, 0);\n }", "function getTotalQuantity(items) {\n return _.reduce(items, function(memo, item) {\n return memo + item.quantity;\n }, 0);\n }", "function totalPurchaseCost(item, quantity, coins){\n\tvar storeItems = storeInfo.getItems();\n\tvar cost;\n\tfor (var storeItem in storeItems){\n\t\tif (storeItem.name == item)\n\t\t\tcost = storeItem.price;\n\t}\n\tif (coins >= quantity * cost)\n\t\treturn quantity * cost;\n\telse \n\t\treturn false;\n}", "function total_order_cost_calc(datasets) {\n $scope.total_order_cost = 0;\n // Combines all the costs\n for (var key in datasets) {\n $scope.total_order_cost += datasets[key][2];\n }\n // Formats cost in a currency style\n // Uses decimalAdjust functions above, from the Mozilla Developer Network\n $scope.total_order_cost = \"$\" + Math.ceil10($scope.total_order_cost, -2);\n if ($scope.total_order_cost[$scope.total_order_cost.indexOf(\".\") + 2] === undefined) {\n $scope.total_order_cost += \"0\";\n }\n }", "function calculateTotalCost(shoppingCart) {\n let total = 0;\n for (let product of shoppingCart) {\n total += product.price * product.count\n }\n\n return total\n}", "totalCart()\n {\n let total = 0;\n for (let i = 0; i < this.itemlist.length; i++)\n {\n total += this.itemList[1].price * this.itemQuantity[i];\n }\n return total;\n }", "function total() {\n var total = 0\n for(var i = 0; i < cart.length; i++){\n total += cart[i].itemPrice\n }\n return total\n}", "function priceIt(qty, cost)\n {\n var total = (parseFloat(cost) * qty);\n console.log(\"Your Total Cost is: $\"+total.toFixed(2));\n }", "function calcTotalCart(item){\n //console.log(\"item count\" + item.count);\n total = total + item.count;\n var productName = products.find(y => y.id == item.id).name;\n //Display each individual item name and it's individual count\n console.log(productName + \" - Quantity = \" + item.count);\n }", "function total() {\n for (var i = 0; i < cart.length; i++){\n \n getCart()[i].itemPrice\n return \n }\n}", "function calculateItemsAndTotal(){\n var li_perCopy = {};\n var li_perSubmission = {};\n var perCopyDescription = '';\n var perCopyCostFinal = 0;\n//This function builds the final items[] and total to be displayed from global variables itemsPerCopy[],perCopyTotal, itemsPerSubmission [], & perSubmissionTotal\n//the functions above set an items array for perCopy vs perSubmission costs.\n //the code below adds a summary line item for each type and then adds both to items[]\n\n //perCopy\n perCopyDescription += '$' + perCopyTotal + ' per copy x ' + copyCount + (copyCount == 1 ? ' copy' : ' copies');\n perCopyCostFinal += perCopyTotal * copyCount;\n\n li_perCopy = {\n name: 'Total Per Copy Cost',\n description: perCopyDescription,\n cost: perCopyCostFinal,\n style: 'OPTION_1'\n };\n\n itemsPerCopy.push(li_perCopy);\n total += perCopyCostFinal;\n\n for (var i=0; i < itemsPerCopy.length; i++){\n items.push(itemsPerCopy[i]);\n }\n\n for (var c=0; c < itemsPerSubmission.length; c++){\n items.push(itemsPerSubmission[c]);\n }\n\n //perSubmission Summary line item\n\n li_perSubmission = {\n name: 'Total Per Submission Cost',\n description: '',\n cost: perSubmissionTotal,\n style: 'OPTION_1'\n };\n\n items.push(li_perSubmission);\n total += perSubmissionTotal;\n}", "totalSpent() {\n return this.meals().reduce(function(sum, meal) {\n return sum + meal.price;\n }, 0);\n }", "totalSpent() {\n return this.meals().reduce(function(sum, meal) {\n return sum + meal.price;\n }, 0);\n }", "function total() {\n var totalValue = 0;\n for (var i = 0; i < cart.length; i++) {\n totalValue += cart[i].itemPrice\n }\n return totalValue;\n}", "function totalCarrito(carrito) {\r\n let total = 0;\r\n carrito.forEach(p => total += p.subtotal());\r\n return total;\r\n}", "function getTotalCost (pizzas) {\n var totalCost = 0;\n pizzas.forEach(function (pizza) {\n totalCost += pizza.getCost();\n });\n return totalCost;\n}", "function updateSubTotal() {\r\n\r\nlet subTotal = 0;\r\ncartItems.forEach(function(item){\r\n subTotal = subTotal + item.price;\r\n console.log(subTotal);\r\n});\r\n document.getElementById(\"val\").innerHTML = \"Total = N\" + subTotal.toFixed(2);\r\n}", "function totalCarrito(carrito) {\n console.log(carrito);\n let total = 0;\n carrito.forEach(p => total += p.subtotal());\n return total.toFixed(2);\n}", "function getTotalPrice(itemNode) {\n var price = getPriceByProduct(itemNode);\n var qty = getQuantityByProduct(itemNode);\n return price * qty;\n}", "function costTotal(items, action) {\n let productTotal = localStorage.getItem(\"costTotal\", items.price);\n\n if (action == \"decrement\") {\n productTotal = parseInt(productTotal);\n localStorage.setItem(\"costTotal\", productTotal - items.price);\n } else if (productTotal !== null) {\n productTotal = parseFloat(productTotal);\n localStorage.setItem(\"costTotal\", +productTotal + items.price);\n } else {\n localStorage.setItem(\"costTotal\", items.price);\n }\n}", "function ReEvaluateItemCost() {\n\n var rowCount = $('#itemList').rowCount();\n\n var compannyGstin = $(\"[id$=compannyGstin]\").val().substring(1, 2);\n var billToClientGSTIN = $(\"[id$=billToClientGSTIN]\").val().substring(1, 2);\n\n if (compannyGstin !== \"\" && billToClientGSTIN !== \"\") {\n if (compannyGstin === billToClientGSTIN) {\n var cumulativeintraStateCGST = 0;\n var cumulativeintraStateSGST = 0;\n var cumulativeintraStateCost = 0;\n var finalintraStateCost = 0;\n for (var i = 1; i <= rowCount; i++) {\n var intraStategst = $('#itemGST' + i).val();\n var intraStatesgst = intraStategst / 2;\n var intraStatecgst = intraStategst / 2;\n\n var intraStateamount = $('#itemAmount' + i).val();\n var intraStatesgstperc = (intraStatesgst / 100) * intraStateamount;\n var intraStatecgstperc = (intraStatecgst / 100) * intraStateamount;\n\n cumulativeintraStateCGST += +intraStatecgstperc;\n cumulativeintraStateSGST += +intraStatesgstperc;\n cumulativeintraStateCost += +intraStateamount;\n finalintraStateCost += +(cumulativeintraStateCGST + cumulativeintraStateSGST + cumulativeintraStateCost);\n }\n\n var totalCostHtmlContent = \"<tr>\";\n totalCostHtmlContent += \"<td id=\\\"intraStateTotalAmount\\\">\" + cumulativeintraStateCost + \"</td>\";\n totalCostHtmlContent += \"<td id=\\\"intraStateTotalCGST\\\">\" + cumulativeintraStateCGST + \"</td>\";\n totalCostHtmlContent += \"<tdid=\\\"intraStateTotalSGST\\\">\" + cumulativeintraStateSGST + \"</td>\";\n totalCostHtmlContent += \"<td id=\\\"intraStateFinalAmount\\\">\" + finalintraStateCost + \"</td>\";\n totalCostHtmlContent += \"</tr>\";\n\n $(\"[id$=amoutCalculationInterState]\").hide();\n $(\"[id$=amoutCalculationIntraState]\").show();\n $(\"[id$=amoutCalculationIntraState]\").closest('tr').remove();\n $(\"[id$=amoutCalculationIntraState] tbody\").append(totalCostHtmlContent);\n }\n else {\n var cumulativeinterStateGST = 0;\n var cumulativeinterStateCost = 0;\n var finalinterStateCost = 0;\n for (var j = 1; j <= rowCount; j++) {\n var interStategst = $('#itemGST' + j).val();\n var interStateamount = $('#itemAmount' + j).val();\n var interStategstperc = (interStategst / 100) * interStateamount;\n\n cumulativeinterStateGST += +interStategstperc;\n cumulativeinterStateCost += +interStateamount;\n finalinterStateCost += +(cumulativeinterStateGST + cumulativeinterStateCost);\n }\n var totalCostHtmlContent2 = \"<tr>\";\n totalCostHtmlContent2 += \"<td id=\\\"interStateTotalAmount\\\">\" + cumulativeinterStateCost + \"</td>\";\n totalCostHtmlContent2 += \"<td id=\\\"intraStateTotalGST\\\">\" + cumulativeinterStateGST + \"</td>\";\n totalCostHtmlContent2 += \"<td id=\\\"intraStateFinalCost\\\">\" + finalinterStateCost + \"</td>\";\n totalCostHtmlContent2 += \"</tr>\";\n\n $(\"[id$=amoutCalculationIntraState]\").hide();\n $(\"[id$=amoutCalculationInterState]\").show();\n $(\"[id$=amoutCalculationInterState]\").closest('tr').remove();\n $(\"[id$=amoutCalculationInterState] tbody\").append(totalCostHtmlContent2);\n }\n }\n else {\n var companyAddrState = $(\"[id$=companyAddrState] option:selected\").val();\n var companyAddrCity = $(\"[id$=companyAddrCity] option:selected\").val();\n var billToClientStateList = $(\"[id$=billToClientStateList] option:selected\").val();\n var billToClientCityList = $(\"[id$=billToClientCityList] option:selected\").val();\n if (companyAddrState !== \"\" && companyAddrCity !== \"\") {\n //If State selected is same for two comapny and bill\n if (companyAddrState === billToClientStateList) {\n var cumulativeintraStateCGST_StateCode = 0;\n var cumulativeintraStateSGST_StateCode = 0;\n var cumulativeintraStateCost_StateCode = 0;\n var finalintraStateCost_StateCode = 0;\n for (var i_StateCode = 1; i_StateCode <= rowCount; i_StateCode++) {\n var intraStategst_StateCode = $('#itemGST' + i_StateCode).val();\n var intraStatesgst_StateCode = intraStategst_StateCode / 2;\n var intraStatecgst_StateCode = intraStategst_StateCode / 2;\n\n var intraStateamount_StateCode = $('#itemAmount' + i_StateCode).val();\n var intraStatesgstperc_StateCode = (intraStatesgst_StateCode / 100) * intraStateamount_StateCode;\n var intraStatecgstperc_StateCode = (intraStatecgst_StateCode / 100) * intraStateamount_StateCode;\n\n cumulativeintraStateCGST_StateCode += +intraStatecgstperc_StateCode;\n cumulativeintraStateSGST_StateCode += +intraStatesgstperc_StateCode;\n cumulativeintraStateCost_StateCode += +intraStateamount_StateCode;\n finalintraStateCost_StateCode += +(cumulativeintraStateCGST_StateCode + cumulativeintraStateSGST_StateCode + cumulativeintraStateCost_StateCode);\n }\n\n var totalCostHtmlContent_StateCode = \"<tr>\";\n totalCostHtmlContent_StateCode += \"<td id=\\\"intraStateTotalAmount\\\">\" + cumulativeintraStateCost_StateCode + \"</td>\";\n totalCostHtmlContent_StateCode += \"<td id=\\\"intraStateTotalCGST\\\">\" + cumulativeintraStateCGST_StateCode + \"</td>\";\n totalCostHtmlContent_StateCode += \"<td id=\\\"intraStateTotalSGST\\\">\" + cumulativeintraStateSGST_StateCode + \"</td>\";\n totalCostHtmlContent_StateCode += \"<td id=\\\"intraStateFinalAmount\\\">\" + finalintraStateCost_StateCode + \"</td>\";\n totalCostHtmlContent_StateCode += \"</tr>\";\n\n $(\"[id$=amoutCalculationInterState]\").hide();\n $(\"[id$=amoutCalculationIntraState]\").show();\n $(\"[id$=amoutCalculationIntraState]\").closest('tr').remove();\n $(\"[id$=amoutCalculationIntraState] tbody\").append(totalCostHtmlContent_StateCode);\n }\n else {\n var cumulativeinterStateGST_StateCode = 0;\n var cumulativeinterStateCost_StateCode = 0;\n var finalinterStateCost_StateCode = 0;\n for (var j_StateCode = 1; j_StateCode <= rowCount; j_StateCode++) {\n var interStategst_StateCode = $('#itemGST' + j_StateCode).val();\n var interStateamount_StateCode = $('#itemAmount' + j_StateCode).val();\n var interStategstperc_StateCode = (interStategst_StateCode / 100) * interStateamount_StateCode;\n\n cumulativeinterStateGST_StateCode += +interStategstperc_StateCode;\n cumulativeinterStateCost_StateCode += +interStateamount_StateCode;\n finalinterStateCost_StateCode += +(cumulativeinterStateGST_StateCode + cumulativeinterStateCost_StateCode);\n }\n var totalCostHtmlContent2_StateCode = \"<tr>\";\n totalCostHtmlContent2_StateCode += \"<td id=\\\"interStateTotalAmount\\\">\" + cumulativeinterStateCost_StateCode + \"</td>\";\n totalCostHtmlContent2_StateCode += \"<td id=\\\"intraStateTotalGST\\\">\" + cumulativeinterStateGST + \"</td>\";\n totalCostHtmlContent2_StateCode += \"<td id=\\\"intraStateFinalCost\\\">\" + finalinterStateCost_StateCode + \"</td>\";\n totalCostHtmlContent2_StateCode += \"</tr>\";\n\n $(\"[id$=amoutCalculationIntraState]\").hide();\n $(\"[id$=amoutCalculationInterState]\").show();\n $(\"[id$=amoutCalculationInterState]\").closest('tr').remove();\n $(\"[id$=amoutCalculationInterState] tbody\").append(totalCostHtmlContent2_StateCode);\n }\n }\n else {\n alert(\"Please eiether provide GSTIN/PAN !\")\n }\n }\n }", "function totalBill()\n{\n var result = 0.00;\n\n for (var i = 0; i < outstandingBill.length; i++)\n {\n result += outstandingBill[i].cost;\n }\n\n //console.log(\"bill total = \" + result);\n return result;\n}", "function calculate_total(){\r\n\r\n var hotdogs = GetNum1();\r\n var french_fries = GetNum2();\r\n var drinks = GetNum3();\r\n if(document.forms['items']['num1'].value == \"\" && document.forms['items']['num2'].value == \"\" && document.forms['items']['num3'].value == \"\"){\r\n alert('ERROR: No Items Ordered')\r\n }\r\n \r\n\r\n //console log to make sure the numbers are correct\r\n console.log(hotdogs);\r\n console.log(french_fries);\r\n console.log(drinks);\r\n\r\n \r\n let cost = (hotdogs * cost_hotdog) + (french_fries * cost_fries) + (drinks * cost_drink);\r\n cost = cost.toFixed(2);\r\n cost2 = cost;\r\n console.log(cost2);\r\n if(cost > 20.00){\r\n \r\n discount = cost * discount;\r\n discount = discount.toFixed(2);\r\n cost = cost - discount;\r\n tax = cost * tax;\r\n tax = tax.toFixed(2);\r\n console.log(tax)\r\n total = Number(cost) + Number(tax);\r\n total = total.toFixed(2)\r\n }else{\r\n tax = cost * tax;\r\n tax = tax.toFixed(2);\r\n discount = 0.00;\r\n total = Number(cost) + Number(tax);\r\n console.log(total)\r\n total = total.toFixed(2);\r\n }\r\n //table information\r\n var tableArray = [\r\n ['Items', 'Quantity/Cost'],\r\n ['Hot Dogs $3.25ea', hotdogs],\r\n ['French Fries $2.00ea' , french_fries],\r\n ['Drinks $1.50ea', drinks],\r\n ['Cost Before Tax ($)' , cost2],\r\n ['Discount ($)',discount],\r\n ['Tax After Discount($)', tax],\r\n ['Total ($)', total]\r\n ];\r\n\r\n\r\n //creating the table 2 by 2\r\n var myTableDiv = document.getElementById(\"myTable\");\r\n\r\n var table = document.createElement('TABLE');\r\n table.setAttribute('border','2');\r\n table.setAttribute('width','100%')\r\n\r\n var tableBody = document.createElement('TBODY');\r\n table.appendChild(tableBody);\r\n\r\n for (var i = 0; i < 8; i++) {\r\n var tr = document.createElement('TR');\r\n tableBody.appendChild(tr);\r\n\r\n for (var j = 0; j < 2; j++) {\r\n var td = document.createElement('TD');\r\n td.appendChild(document.createTextNode(tableArray[i][j]));\r\n tr.appendChild(td);\r\n }\r\n }\r\n myTableDiv.appendChild(table);\r\n}", "function getTotalForItem(inputItem,itemValue){\n const items = inputItem;\n const value = itemValue;\n const total = items * value;\n return total;\n}", "function updateActivitiesPrice(activityItems) {\n activitiesTotalPrice = 0;\n for (let i=0; i<activityItems.length; i++) {\n if (activityItems[i].children[0].checked) {\n const activityCost = parseInt(activityItems[i].children[0].getAttribute('data-cost'));\n activitiesTotalPrice += activityCost;\n };\n }\n const activityCostText = document.getElementById('activities-cost');\n activityCostText.textContent = `Total: $${activitiesTotalPrice}`;\n}", "totalSpent() {\n let prices = this.meals().map(\n function(meal) {\n return meal.price;\n }\n );\n\n return prices.reduce(\n function (total, price) {\n return total + price;\n }\n )\n\n }", "function updateTotal(){\n let unitCosts = document.querySelectorAll('input.unitCost');\n let quantities = document.querySelectorAll('input.quantity');\n let grandTotalGauge = document.querySelector('#invoice-items-total span');\n let grandTotal = 0;\n for (var i = 0; i < unitCosts.length; i++) {\n itemCost = unitCosts[i].value * quantities[i].value;\n grandTotal += itemCost;\n }\n grandTotalGauge.innerHTML = grandTotal;\n}", "totalSpent(){\n let sum = 0;\n for(const meal of this.meals()){\n sum += meal.price;\n }\n return sum;\n\n \n }", "function updateTotal() {\n let memoryCost = parseFloat(getElement(\"memory-price\").innerText);\n let storageCost = parseFloat(getElement(\"storage-price\").innerText);\n let deliveryCost = parseFloat(getElement(\"delivery-price\").innerText);\n let total = 1299 + memoryCost + storageCost + deliveryCost; /* total price sum */\n getElement(\"total-price\").innerText = total;\n getElement(\"grand-total-price\").innerText = total;\n}", "function getTotalCost(order) {\n var totalCost = 0;\n for (let key in order) {\n const cost = parseInt(getCostFromId(key));\n const no = order[key];\n totalCost += cost*no;\n }\n return totalCost;\n}", "function totalTaxCost(){\n\t\t\n\t\treturn totalPrice * taxPercentage;\n\t} // End totalTaxCost.", "forAllDays() {\n if (this.breakDown() !== 'No Information to display') {\n let totalCost = this.breakDown().reduce((acc, item) => acc += item.totalCost, 0)\n return totalCost || 0;\n }\n }", "totalItemPrice(item) {\n if(undefined === item.price || undefined === item.quantity){\n return 0;\n }\n return item.price * item.quantity;\n }", "function updateExpectedCost() {\n\n var cost = Number(totalInvoicedBox.innerHTML || 0);\n\n // for any LI's that are not yet billed (i.e. filled in)\n // use the total expected cost for that lineitem.\n for(var id in widgetRegistry.acqie) {\n var entry = widgetRegistry.acqie[id]._object;\n if(!entry.isdeleted()) {\n if (Number(widgetRegistry.acqie[id].cost_billed.getFormattedValue()) == 0) {\n var li = entry.lineitem();\n cost += \n Number(li.order_summary().estimated_amount()) - \n Number(li.order_summary().paid_amount());\n }\n }\n }\n\n dojo.byId('acq-invoice-summary-cost').innerHTML = cost.toFixed(2);\n}", "function CalculateTotalCost()\n{\n var apples = document.getElementById('apples').value;\n var oranges = document.getElementById('oranges').value;\n var bananas = document.getElementById('bananas').value;\n\n totalcost.value = ((apples * 0.69) + (oranges * 0.59) + (bananas * 0.39)).toFixed(2);\n}", "function totale(price) {\n tot += price;\n }", "totalPrice() {\n var total = 0;\n for (var i = 0; i < this.listItems.length; i++) {\n total += parseFloat(this.listItems[i].price);\n }\n return total.toFixed(2);\n }", "function calcAll() {\n let subTotal = 0;\n [...cart.children].forEach(product => subTotal += updateSubtot(product));\n document.querySelector('h2 > span').innerHTML = subTotal;\n}", "function updateTotal(){\n\t\tvar sum = 0;\n\t\t$(\".cart_items>.item\").each(function(i,v){\n\t\t\tsum += $(v).data(\"price\") * $(v).find(\".cart_cloth_num\").text();\n\t\t});\n\t\t$(\".cart_total\").text(sum);\n\t}", "total () {\n\t\treturn this.subtotal() - this.discounts();\n\t}", "function getTotalMoney() {\n return Purchase.find().then(function(purchases) {\n let total = 0;\n for (i=0; i < purchases.length; i++) {\n total += purchases[i].cost;\n }\n return total;\n })\n}", "function productTotal() {\n for (let i = 0; i < basket.length; i++) {\n let price = Number(basket[i].price.replace(/[^0-9.-]+/g,\"\"));\n let totalPrice = price * basket[i].quantity;\n basket[i].totalPrice = totalPrice\n } \n}", "function calcTotalPrice() {\n let totalPricePrev = 0;\n cartItems.forEach((item) => {\n prices.forEach((price) => {\n if (price.beername === item.beer) {\n totalPricePrev += item.amount * price.price;\n }\n });\n });\n setTotalPrice(totalPricePrev);\n }", "getTotal() {\n //Creating variable total with value of 0.\n let total = 0;\n // using built-in forEach(), calculate the total using the price field of each object.\n let beverageTotal = this._beverages.forEach(function(beverage) {\n total += parseFloat(beverage.price);\n });\n let appetizerTotal = this._appetizers.forEach(function(appetizer) {\n total += parseFloat(appetizer.price);\n });\n let mainCourseTotal = this._mainCourses.forEach(function(mainCourse) {\n total += parseFloat(mainCourse.price);\n });\n let dessertTotal = this._desserts.forEach(function(dessert) {\n total += parseFloat(dessert.price);\n });\n console.log(`The total is ${total}`);\n //Return the total variable and set its precisions to two decimal places.\n return total.toFixed(2);\n }", "subtotalOwed(pInd) {\n return this.state.dishes\n .map((dish, dInd) => (this.personCostForDish(pInd, dInd)))\n .reduce(Utils.sumFunc, 0);\n }", "calculateTotal() {\n\t\t//Réinitialise le total\n\t\tthis.total = 0\n\t\tfor (let product of this.products) {\n\t\t\tthis.total += product.price * product.number\n\t\t}\n\t}", "function addItem(item, cost) {\n if (typeof cost !== \"number\" || isNaN(cost)) {\n cost = 0.0;\n }\n\n $(\"#receipt-table tbody\").append(\n \"<tr>\" +\n '<th scope=\"row\"><i class=\"fas fa-receipt\"></i></th>' +\n '<td id=\"name\">' +\n item +\n \"</td>\" +\n '<td id=\"cost\">' +\n cost.toFixed(2) +\n \"</td>\" +\n \"<td>\" +\n '<span><button type=\"button\" class=\"btn btn-danger\"><i class=\"far fa-trash-alt\"></i></button></span>' +\n \"</td>\" +\n \"</tr>\"\n );\n var newTotal = parseFloat($(\"#total-cost\").text()) + cost;\n $(\"#total-cost\").text(newTotal.toFixed(2));\n }", "function finalTotalAmountOfThisOrder()\n {\n return (nanCheck(parseFloat(subTotalWithoutShippingCost())) + nanCheck(parseFloat(shippingCostOfThisMainOrder()))).toFixed(2);\n }", "function update_price() {\n var row = $(this).parents('.item-row');\n var cost = row.find('.rate').val();\n var qty = row.find('.qty').val();\n //console.log(row,cost,qty)\n // console.log(row.find('.price'))\n row.find('.price').val(Number(qty) * Number(cost));\n subTot.textContent = \"Sub Total: \" + summing();\n tot.textContent=\"Total: \"+summing()*1.5;\n\n }", "function updateCartTotal(){\n let cartItemContainer = document.querySelectorAll(\"#shoppingReminder\")[0];\n let cartRows = cartItemContainer.querySelectorAll(\"#shoppingRow\");\n let subTotal = 0 ;\n for (let i = 0 ; i<cartRows.length; i++){\n let cartRow = cartRows[i];\n let productPrice = cartRow.querySelectorAll(\".productPrice\")[0];\n let price = parseFloat(productPrice.innerText.replace('€',\"\"));\n let subTotalCount = document.querySelector(\"#subtotalcount\");\n subTotal += price;\n subTotalCount.innerHTML = subTotal +\"€\";\n }\n let totalCount = document.querySelector(\"#totalcount\");\n let delivery = document.querySelector(\"#deliverycost\")\n let deliveryCost =0 ;\n if(deliveryCost == 0 || null){\n delivery.innerHTML = \"Offerte\";\n }else{\n delivery.innerHTML = deliveryCost + \"€\";\n }\n totalCount.innerHTML = (subTotal + deliveryCost) + \"€\"; \n}", "function newCost() {\n let precioSubtotal = 0;\n let precioTotal = 0;\n let productos = cart_products_info.articles\n for(let i = 0; i <productos.length; i++) {\n let units = document.getElementById(\"cart_\"+i+\"_units\").value;\n precioSubtotal += convertir(productos[i].currency)*units*productos[i].unitCost;\n }\n // precioTotal = precioSubtotal*(1+precioEnvio()).toFixed(0)\n\n document.getElementById(\"precioSubtotal\").innerHTML = \"UYU \" + precioSubtotal.toFixed(0)\n document.getElementById(\"precioEnvio\").innerHTML = \"UYU \" + (precioSubtotal*precioEnvio()).toFixed(0)\n document.getElementById(\"precioTotal\").innerHTML = \"UYU \" + (precioSubtotal*(1+precioEnvio())).toFixed(0)\n\n}", "deriveTotalOrderCost(ordersArray) {\n let totalOrderCost = 0;\n ordersArray.forEach(order => {\n totalOrderCost = totalOrderCost + order.price;\n });\n return totalOrderCost;\n }", "get subtotal_ex_tax() {\n let sub = 0.0;\n self.items.map((i) => {\n sub += i.price * i.quantity;\n return sub;\n });\n return sub.toFixed(2);\n }", "get subtotal_ex_tax() {\n let sub = 0.0;\n self.items.map((i) => {\n sub += i.price * i.quantity;\n return sub;\n });\n return sub.toFixed(2);\n }", "function muestroTotalProductos() {\r\n var subTotalCompleto = 0;\r\n subTotalCompletoImporte = 0;\r\n if ($('.articuloDeLista').length > 0) {\r\n $('.articuloDeLista').each(function () {\r\n subTotalCompleto = parseFloat($(this).children('.productSubtotal').text());\r\n subTotalCompletoImporte += subTotalCompleto;\r\n document.getElementById(\"productCostText\").innerHTML = subTotalCompletoImporte;\r\n });\r\n }\r\n }", "function calcTotals() {\n var incomes = 0;\n var expenses = 0;\n var budget;\n // calculate total income\n data.allItems.inc.forEach(function(item) {\n incomes+= item.value;\n })\n //calculate total expenses\n data.allItems.exp.forEach(function(item) {\n expenses+= item.value;\n })\n //calculate total budget\n budget = incomes - expenses;\n // Put them in our data structure\n data.total.exp = expenses;\n data.total.inc = incomes;\n //Set Budget\n data.budget = budget;\n }", "getTotalPrice () {\n return _.reduce(this.options.data, (total, option) => total + option.quantity * option.price, 0).toFixed(2);\n }", "function computeActivityTotals(items) {\n var elevation = 0.0;\n var distance = 0.0;\n angular.forEach(items, obj => {\n elevation += obj.elevation;\n distance += obj.distance;\n });\n return { 'elevation': elevation, 'distance': distance.toFixed(2) };\n }", "function totalCost(e) {\n let quantity = e.target\n quantity_parent = quantity.parentElement.parentElement\n price_field = quantity_parent.getElementsByClassName('item-price')[0]\n total_field = quantity_parent.getElementsByClassName('total-price')[0]\n price_field_content = price_field.innerText.replace('€', '')\n total_field.children[0].innerText = '€' + quantity.value * price_field_content\n grandTotal()\n if (isNaN(quantity.value) || quantity.value <= 0) {\n quantity.value = 1\n }\n\n}", "getTotalPrice() {\n this.totalPrice = this.selectedPlan.getRenewablePrice();\n const newEnvironmentPlanCode = find(this.selectedPlan.addonFamilies, {\n name: ADDON_FAMILY.ENVIRONMENT,\n }).addons[0];\n const environmentAddon = new Plan(\n find(this.catalog.addons, { planCode: newEnvironmentPlanCode }),\n );\n this.selectedProject.addons.forEach((addon) => {\n let addonPrice =\n find(this.availableAddons, {\n productName: addon.productName,\n }).getRenewablePrice().value * 100000000;\n\n switch (addon.planFamilyName) {\n case ADDON_FAMILY.STORAGE:\n addonPrice =\n find(this.selectedProject.addons, {\n planFamilyName: ADDON_FAMILY.ENVIRONMENT,\n }).quantity *\n addonPrice *\n addon.quantity;\n this.totalPrice += addonPrice;\n break;\n case ADDON_FAMILY.ENVIRONMENT:\n addonPrice = environmentAddon.getRenewablePrice();\n this.totalPrice += (addon.quantity - 2) * addonPrice;\n break;\n default:\n this.totalPrice += addon.quantity * addonPrice;\n break;\n }\n });\n set(this.selectedPlan, 'totalPrice', this.totalPrice);\n }", "function totalCostAndTime(){\n let totalTime = 0;\n let totalCost = 0;\n $('#packageSection .packageWrapper').each(function(){\n let cost = $(this).find('.cost').html();\n let costSubstring = cost.substring(1, cost.length);\n if(costSubstring) {\n totalCost += parseInt(costSubstring);\n }\n let time = $(this).find('.time').html();\n let timeSubstring = time.substring(0, time.length-3);\n if(timeSubstring) {\n totalTime += parseInt(timeSubstring);\n }\n });\n $('.total .totalTime').html('TOTAL TIME: '+totalTime+' min');\n $('.total .totalCost').html('TOTAL COST: £'+totalCost);\n }", "function totalValue(prods) {\n let inventoryValue = 0;\n for (i = 0; i < prods.length; i += 1 ) {\n inventoryValue += prods[i].inventory * prods[i].unit_price;\n }\n return inventoryValue;\n}", "function getTotal() {\n const { cart } = state;\n\n const res = cart.reduce((prev, product) => {\n return (prev + (product.price * product.count));\n }, 0);\n\n dispatch({\n type: 'TOTAL',\n payload: res\n });\n }", "function updateTotalCookPerSecChain(){\n updateTotalCookPerSec();\n \n if(dist[item]){\n updateTotalDistribution();\n }\n else{\n updateTotalProduction();\n }\n \n updateTimeToGet();\n updateEfficiency();\n}", "function calcTotal() {\r\n // Get chosen package items\r\n var depFlight = JSON.parse(localStorage.getItem('departure'));\r\n var hotel = JSON.parse(localStorage.getItem('hotel'));\r\n var retFlight = JSON.parse(localStorage.getItem('return'));\r\n\r\n return parseInt(depFlight.price) + parseInt(hotel.price) + parseInt(retFlight.price);\r\n}" ]
[ "0.7797716", "0.7496572", "0.7408303", "0.72762775", "0.7254776", "0.7243303", "0.71155304", "0.7102601", "0.70956385", "0.705537", "0.7043262", "0.7038848", "0.7028002", "0.7020986", "0.70182633", "0.6992299", "0.6985358", "0.6973873", "0.69628024", "0.6942091", "0.6939054", "0.69094306", "0.69032055", "0.6890366", "0.68770486", "0.6868464", "0.6837938", "0.68332225", "0.6832673", "0.68254083", "0.6782596", "0.67635286", "0.67632395", "0.6750086", "0.67312986", "0.6725506", "0.672279", "0.671724", "0.67004025", "0.6674769", "0.6673603", "0.66558236", "0.66539824", "0.66496867", "0.66373116", "0.6623581", "0.662154", "0.661452", "0.661452", "0.661385", "0.66041696", "0.6597276", "0.65884894", "0.6577188", "0.6575944", "0.65749925", "0.6564927", "0.6536377", "0.65334713", "0.6528251", "0.6527565", "0.65250766", "0.65229046", "0.65225184", "0.6518085", "0.65119946", "0.65115434", "0.650972", "0.6499147", "0.6471706", "0.6470701", "0.647035", "0.6462784", "0.6458151", "0.64517", "0.64407796", "0.6432637", "0.64216375", "0.64186084", "0.64157206", "0.64123434", "0.6405841", "0.6404469", "0.6393496", "0.6393264", "0.63879514", "0.63874656", "0.638663", "0.6384573", "0.6384573", "0.63835543", "0.63761926", "0.6364252", "0.63569975", "0.6355442", "0.6331456", "0.6329007", "0.6327947", "0.63204837", "0.6320249", "0.63074225" ]
0.0
-1
Displays the cart in the cart page
function displayCart() { let cartItems = localStorage.getItem("productsInCart"); cartItems = JSON.parse(cartItems); let productContainer = document.querySelector(".products"); if(cartItems && productContainer) { productContainer.innerHTML = ''; Object.values(cartItems).map(item => { productContainer.innerHTML += ` <div class="product"> <ion-icon name="close-circle"></ion-icon> <img src="./images/${item.tag}.jpg"> ${item.name} </div> <div class="price"> Price per: ${item.price} </div> <div class="quantity"> Amount: ${item.inCart} </div> <div class="total"> Total: ${item.inCart * item.price} </div> ` }); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n cart.updateCounter();\n}", "function renderCart() {\n\n loadCart();\n clearCart();\n showCart();\n updateCounter();\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n \n}", "function renderCart() {\r\n loadCart();\r\n clearCart();\r\n showCart();\r\n}", "function renderCart() {\n loadCart();\n showCart();\n}", "function showCart(cart){\n setShowCarts(!showCarts);\n fetchCart(cart);\n }", "function showCart (req, res) {\n const cart = req.session.cart\n const total = Math.round((cart.reduce(function (sum, value) {\n return sum + value.itemTotal\n }, 0)) * 100) / 100\n res.render('pages/cart', {cart, total})\n}", "function renderCart() {\n loadCart();\n clearCart();\n showCart();\n\n //create for process order\n}", "function displayCart() {\r\n if (cart.products.length == 0) {\r\n document.getElementById('cart').innerHTML = '<h3>No Product </h3>';\r\n document.getElementById('order').style.display = 'none';\r\n } else {\r\n var cartCode = \"\";\r\n for (var i = 0; i < cart.products.length; i++) {\r\n var product = cart.products[i];\r\n var div = \"<div><strong>\" + product.title + \"</strong> : \" + product.price + \"</div>\";\r\n cartCode += div;\r\n }\r\n\r\n cartCode += \"<h2>TOTAL : \" + cart.total.toString() + \" TND</h2>\";\r\n\r\n document.getElementById('cart').innerHTML = cartCode;\r\n document.getElementById('order').style.display = 'block';\r\n }\r\n }", "function showCart() {\n let cart = getCart();\n let cartList = $(\"#cartList\");\n let listString = \"\";\n\n if(cart === null){\n cartList.html(\"<p> No items in cart </p>\");\n } else {\n for(let item of cart){\n listString += \"<li>\" + \"<strong>\" + item.name + \"</strong>\" + \" \" +\n \"$\" + item.price + \"/hour\";\n }\n listString += \"</li>\";\n cartList.html(listString);\n }\n\n let totalHTML = $(\"#total\");\n let total = 0.0;\n for(let item of cart){\n let p = parseFloat(item.price);\n total += p;\n }\n totalHTML.html(\"$\" + total.toString() + \" Per Hour\");\n\n $(\"#clearCart\").click(clearCart);\n }", "function showCart() {\n // get the value and parse from session storage\n let cart = JSON.parse(sessionStorage.getItem('cart'));\n\n if (cart === null) {\n cart = [];\n }\n // if cart is empty set the table in the cart col md 3 section to display none\n if (cart.length === 0) {\n $('#cart').css('display', 'none');\n $('#empty').text('You have no item in your cart.');\n } else {\n // otherwise show table by setting display to block, loop over all items in cart and create a new row for each item.\n $('#cart').css('display', 'block');\n\n let html = '';\n\n let duplicates = [];\n\n for (let i in cart) {\n let count = countDuplicates(cart[i].id);\n\n if (duplicates.indexOf(cart[i].id)== -1) {\n html += `\n <tr>\n <td>${count}</td>\n <td>${cart[i].title}</td>\n <td>$${(cart[i].price*count).toFixed(2)}</td>\n <td>\n <button onClick=\"removeItem(${cart[i].id})\" class=\"btn btn-danger\">X</button>\n </td>\n </tr>\n `;\n duplicates.push(cart[i].id);\n }\n }\n\n\n // send the proper string into the tbody section\n $('tbody').html(html);\n }\n // call update totals\n updateTotals();\n }", "function displayCartItems () {\r\n // get cart items div and clear it\r\n const cartItemsDiv = document.getElementById('cartItems')\r\n cartItemsDiv.innerHTML = ''\r\n\r\n // retrive the cart and the catalogue fro storage\r\n const cart = JSON.parse(sessionStorage.getItem('cart'))\r\n const catalogue = JSON.parse(sessionStorage.getItem('catalogue'))\r\n\r\n // check if the cart is not empty\r\n if (cart.length !== 0) {\r\n let id = 0 // initiaise the id\r\n // iterate through the cart list\r\n cart.forEach(index => {\r\n // retrive the item object based on the index\r\n const item = catalogue[Number(index)]\r\n // display the item\r\n displayItem(item, id)\r\n // increment the id\r\n id++\r\n })\r\n\r\n // display the checkout div\r\n $('#checkoutDiv').css({ visibility: 'visible' })\r\n // get the total div and clear it\r\n const divTotal = document.getElementById('divTotal')\r\n divTotal.innerHTML = ''\r\n\r\n // create a h5 elemnt for the sub-total\r\n const subTotal = document.createElement('h5')\r\n subTotal.setAttribute('id', 'subtotalCartPrice')\r\n subTotal.style.textAlign = 'right'\r\n\r\n // create a h5 elemnt for the VAT\r\n const VATtotal = document.createElement('h5')\r\n VATtotal.setAttribute('id', 'VAT')\r\n VATtotal.style.textAlign = 'right'\r\n\r\n // create a h5 elemnt for the discount\r\n const discount = document.createElement('h5')\r\n discount.setAttribute('id', 'discount')\r\n discount.style.textAlign = 'right'\r\n discount.style.color = 'green'\r\n\r\n // create a h4 elemnt for the total\r\n const total = document.createElement('h4')\r\n total.setAttribute('id', 'totalCartPrice')\r\n total.style.textAlign = 'right'\r\n\r\n // create a check-out button\r\n const checkOutButton = document.createElement('button')\r\n checkOutButton.setAttribute('class', 'btn btn-outline-secondary')\r\n checkOutButton.setAttribute('onclick', 'checkout()') // handler function on click\r\n checkOutButton.setAttribute('id', 'checkOutButton')\r\n checkOutButton.style.float = 'right'\r\n checkOutButton.style.color = 'green'\r\n\r\n // create a cart icon\r\n const cartIcon = document.createElement('i')\r\n cartIcon.setAttribute('class', 'fas fa-shopping-cart')\r\n cartIcon.innerHTML = ' CHECKOUT'\r\n\r\n // add the icon the button\r\n checkOutButton.appendChild(cartIcon)\r\n\r\n // apped to the total div\r\n divTotal.appendChild(subTotal)\r\n divTotal.appendChild(VATtotal)\r\n divTotal.appendChild(discount)\r\n divTotal.appendChild(total)\r\n divTotal.appendChild(checkOutButton)\r\n\r\n // calculate the total & display it\r\n getCartTotal()\r\n } else {\r\n // hide notification and checkout div if cart is empty\r\n $('#checkoutDiv').css({ visibility: 'hidden' })\r\n $('#cartCounter').css({ visibility: 'hidden' })\r\n\r\n // if cart empty, clear the cart items div\r\n cartItemsDiv.innerHTML = ''\r\n // create a h4 element to display the 'cart empty' text\r\n const text = document.createElement('h4')\r\n text.setAttribute('class', 'text-center')\r\n text.innerHTML = 'Cart Empty'\r\n // add the text to the cart items div\r\n cartItemsDiv.appendChild(text)\r\n }\r\n}", "function showCart(cart) {\n var cart_info = \"\";\n for (var key in cart) {\n if (cart.hasOwnProperty(key)) {\n cart_info += key + \" : \" + cart[key] + \"\\n\";\n }\n }\n var modal = document.getElementById(\"modal\");\n modal.style.display = \"block\";\n var modalContent = document.getElementById(\"modal-content\");\n renderCart(modalContent, store)\n inactiveTime = 0;\n}", "function _showCart() {\n _isCartVisible = true;\n}", "function showCart() {\n\n const cartItems = JSON.parse(localStorage.getItem('cart')) || [];\n cart = new Cart(cartItems);\n // TODO: Find the table body\n let tableBody= document.querySelector('tbody');\n // TODO: Iterate over the items in the cart\n // TODO: Create a TR\n // TODO: Create a TD for the delete link, quantity, and the item\n // TODO: Add the TR to the TBODY and each of the TD's to the TR\n for (let i =0;i<this.cartItems.length;i++){\n let tableRow=document.createElement('tr');\n tbody.appendChild(tableRow);\n let deleteLink=document.createElement('td');\n deleteLink.textContent='x';\n deleteLink.appendChild(tableRow);\n let quantityTable =document.createElement('td');\n quantityTable.textContent=cartItems[0];\n quantityTable.appendChild(tableRow);\n let itemTable =document.createElement('td');\n itemTable.textContent=cartItems[1];\n itemTable.appendChild(tableRow);\n }\n}", "function showCart(cart){\n for (item in cart) {\n //Store the product details\n var images=cart[item].rollImg;\n var names=cart[item].rollName; \n var qtys=cart[item].numQty;\n var prices=cart[item].rollPrice;\n var subtotals=cart[item].subtotal;\n //Create a new row in the cart for the item\n var newRow = \"<tr><td>\" + \"<img src='\" + images + \"'></img>\" + \"</td><td>\" + names + \"</td><td>\" + \"$\" + prices + \".00\" + \"</td><td>\" + qtys + \"</td><td>\" + \"$\" + subtotals + \".00\" + \"</td><td>\" + \"<button class='quantity-option remove-button' data-item='\"+names+\"'>\" + 'Remove' + \"</button></tr>\";\n $('#cart-table').append(newRow);\n //Update the total cost of items\n var showTotal = parseInt(getTotal(cart,totalAmount));\n $('#view-total').text(showTotal);\n }\n }", "function viewCart() {\n\n if (cart.length === 0) {\n return \"Your shopping cart is empty.\"\n\n } else if (cart.length === 1) {\n return \"In your cart, you have \" + `${cart[0].itemName} at $${cart[0].itemPrice}.`;\n\n } else if (cart.length === 2){\n return \"In your cart, you have \" + `${cart[0].itemName} at $${cart[0].itemPrice}, and ${cart[1].itemName} at $${cart[1].itemPrice}.`;\n\n } else {\n var allItemsPriceToView = \"In your cart, you have\";\n for (var i=0; i < cart.length-1; i++) {\n allItemsPriceToView += ` ${cart[i].itemName} at $${cart[i].itemPrice},`;\n }\n }\n return allItemsPriceToView.concat(` and ${cart[cart.length-1].itemName} at $${cart[cart.length-1].itemPrice}.`) ;\n\n}", "function showCart() {\n\t$.ajax(\n\t{\n\t\turl: 'php_scripts/actions.php',\n\t\ttype: 'POST',\n\t\tdata: 'action=show-cart',\n\t\tdataType: 'JSON',\n\t\tsuccess: function(data) {\n\t\t\tappendCartToDom(data);\n\n\t\t\t//remove loading\n\t\t\tcloseLoading();\n\t\t},\n\t\terror: function(response) {\n\t\t\t//log js errors\n\t\t\tshortTimeMesg('Alert! No items found!', 'short-time-msg-failure');\n\n\t\t\t//remove loading\n\t\t\tcloseLoading();\n\t\t}\n\t}\n\t);\n}", "function viewCart() {\n $(\".modal-body\").empty();\n shoppingCart.forEach(product => {\n $(\".modal-body\").append(\n `<div data-name=\"${product.product_name}\">${product.product_name}</div>\n <div data-quantity=\"${product.stock_quantity}\">${product.stock_quantity}</div>`\n );\n });\n\n const total = getTotal();\n\n $(\".modal-body\").append(`<div><hr>$${total}</div>`);\n }", "function cart(){\n let cart=localStorage.getItem(\"cart\");\n (cart)? showCart(cart) :alert(\"you don't have a cart yet!\")\n }", "function updateCartPreview() {\n // TODO: Get the item and quantity from the form\n // TODO: Add a new element to the cartContents div with that information\n}", "function renderCart() {\n var prices = [];\n\n cartContent.innerHTML = \"\";\n\n cart.items.forEach(function(item) {\n var itemPrice = parseFloat(item.price.replace(\"$ \", \"\")),\n itemQuantity = parseInt(item.quantity);\n\n prices.push(itemPrice * itemQuantity);\n cartContent.innerHTML += \"<li class='cart-item' id='cart-\" + item.id + \"'><p class='cart-item-name'>\" + item.name + \"</p><img class='cart-item-img' src='http://vignette1.wikia.nocookie.net/clubpenguin/images/5/5f/Red_X.png/revision/latest?cb=20120514130731'><input type='number' class='inset quantity' min='0' max='50' value=\" + item.quantity + \"></li>\";\n })\n\n var totalPrice = prices.reduce(function(a, b) {\n return a + b;\n }, 0);\n\n cart.total = totalPrice.toFixed(2);\n cartTotal.innerHTML = \"$ \" + cart.total;\n }", "function viewCart() {\n //console.log(cart)\n var message = \"In your cart, you have\";\n if (cart.length === 0) {\n console.log(\"Your shopping cart is empty.\")\n }\n else if (cart.length === 1) {\n console.log(message + \" \" + Object.keys(cart[0]) + \" at $\" + cart[0][Object.keys(cart[0])] + \".\")\n }\n else if (cart.length >= 2) {\n var items = []\n for (var i = 0; i < cart.length; i++) {\n var itemName = Object.keys(cart[i])\n var price = cart[i][itemName]\n items.push(itemName + \" at $\" + price)\n if (i != cart.length-1) {\n cart.length === 2 ? message += \" \" + items[i] : message += (\" \" + items[i] + \",\")\n }\n else {\n message += (\" and \" + items[i] + \".\")\n }\n }\n console.log(message)\n }\n}", "function displayCart(){;\r\n document.getElementById('main').style.display = 'none'\r\n document.getElementById('details-page').style.display = 'none';\r\n document.getElementById('cart-container').style.display = 'block';\r\n if(cartList.length==0){\r\n document.getElementById('cart-with-items').style.display = 'none';\r\n document.getElementById('empty-cart').style.display = 'block';\r\n }\r\n else{\r\n document.getElementById('cart-with-items').style.display = 'block';\r\n document.getElementById('empty-cart').style.display = 'none';\r\n }\r\n}", "function showList() {\n\t\t\t$state.go('cart.list');\n\t\t}", "function displayCart(){\n let cartItems = localStorage.getItem(\"productsInCart\");\n cartItems = JSON.parse(cartItems);\n let productContainer = document.querySelector(\".products\");\n let cartCost = localStorage.getItem('totalCost');\n if(cartItems && productContainer ){\n productContainer.innerHTML = '';\n Object.values(cartItems).map(item => {\n productContainer.innerHTML += `\n <div class=\"product\">\n <ion-icon name=\"close-circle-outline\"></ion-icon>\n <img scr=\"products/productsAlgemeen/dist/productFotos/${imagePath+images.Afbeeldingsnaam}.jpg\">\n <span>${item.Productnaam}</span>\n </div>\n <div class=\"price\">$${item.Eenheidsprijs},00</div>\n <div class=\"quantity\">\n <ion-icon class=\"decrease\" name=\"arrow-dropleft-circle\"></ion-icon>\n <span>${item.inCart}</span>\n <ion-icon class=\"increase\" name=\"arrow-dropright-circle\"></ion-icon>\n </div>\n <div class=\"total\">\n $${item.inCart * item.Eenheidsprijs},00\n </div>\n `;\n });\n\n productContainer.innerHTML += `\n <div class=\"basketTotalContainer\">\n <h4 class=\"basketTotalTitle\">Basket Total</h4>\n <h4 class=\"basketTotal\">€${cartCost},00</h4>\n `;\n\n }\n}", "renderCarts(cart){\n \tif(cart.length>0){\n \t\treturn cart.map(i=><li>{i.name}</li>)\n \t}else{\n \t\treturn <h1>No Items added</h1>\n \t}\n \t\n }", "function getCart(){\n let items = localStorage.getItem(\"cartProducts\");\n items = JSON.parse(items);\n\n let container = document.querySelector(\".products\");\n\n // let baskettotal = document.querySelector(\".basket-total\");\n\n let totalCartCost = localStorage.getItem('totalCost');\n totalCartCost = JSON.parse(totalCartCost);\n displayCheckout();\n // run only if items and .cart-container is running.\n if (items && container) {\n container.innerHTML = '';\n\n // check the values of the cart items\n Object.values(items).map((item) => {\n //display each basket item.\n container.innerHTML += `\n <div class=productItem>\n <div class=\"item-title\">\n <div>${item.itemName}</div>\n <img src=\"${item.imgurl}\" style=\"width:60px; height:60px;\">\n </div>\n <div class=\"item-price\">$${item.price},00</div>\n <div class=\"item-quantity\">${item.numInCart}</div>\n <div class=\"item-total\">$${item.price * item.numInCart},00</div>\n </div>\n `\n });\n }\n}", "function showItems() {\n\tconst qty = getQty()\n\tcartQty.innerHTML = `You have ${qty} items in your cart.`\n\t//console.log(`You have ${qty} items in your cart.`)\n\n\tlet itemStr = ''\n\tfor (let i = 0; i < cart.length; i++) {\n\t\tlet itemTotal = cart[i].price * cart[i].qty\n\t\t//console.log(`- ${cart[i].name} - ${cart[i].price} x ${cart[i].qty}`)\n\t\titemStr += `<li class=\"cart-list\"><div class=\"checkout-item\">\n\t\t${cart[i].name} - ${cart[i].price} x ${cart[i].qty} = ${itemTotal.toFixed(2)}</div>\n\t\t<button class=\"remove\" data-name=\"${cart[i].name}\">Remove</button>\n\t\t<button class=\"decrease change\" data-name=\"${cart[i].name}\">-</button>\n\t\t<button class=\"increase change\" data-name=\"${cart[i].name}\">+</button>\n\t\t</li>`\n\t}\n\n\t// make a list of all the items in the cart\n\titemList.innerHTML = itemStr\n\t\n\tconst total = getTotal()\n\tcartTotal.innerHTML = `Your cart total is: $${total}`\n\t//console.log(`Your cart total is: $${total}`)\n}", "function viewCart() {\nvar list = [];\nif (cart.length === 0) {\n return 'Your shopping cart is empty.'\n}\nfor (var i = 0; i < cart.length; i++) {\n\n if (cart.length === 1) {\n list.push(`In your cart, you have ${cart[0].itemName} at $${cart[0].itemPrice}.`) \n}\n\n else if (cart.length === 2) {\n list.push(`In your cart, you have ${getCart()[0].itemName} at $${getCart()[0].itemPrice}, and ${getCart()[1].itemName} at $${getCart()[1].itemPrice}.`)\n}\n\nelse{\n list.push(`In your cart, you have ${getCart()[0].itemName} at $${getCart()[0].itemPrice}, ${getCart()[1].itemName} at $${getCart()[1].itemPrice}, and ${getCart()[2].itemName} at $${getCart()[2].itemPrice}.`)\n}\nreturn list;\n}\n}", "function showCart(id) {\n // get value and parse sessionStorage\n let cart = JSON.parse(sessionStorage.getItem('cart'));\n // if cart is empty set the table in the cart col-md-3 section to display none\n if (cart.length === 0) {\n $('#cart-checkout').css('display','none');\n $('#empty').html('<h1>You have no items in your cart.</h1>');\n $('.total').text('Your cart is empty');\n }\n // otherwise show table by setting display to block, loop over all items in cart and create a new row for each item\n else {\n let html = \"\";\n\n // send the proper string into the tbody section\n $('#cart').css('display','block');\n\n let duplicates = [];\n\n for (let product in cart) {\n let count = countDuplicates(cart[product].id);\n\n if (duplicates.indexOf(cart[product].id) == -1) {\n html += `\n <tr>\n <td>${count}</td>\n <td>${cart[product].title}</td>\n <td>$${(cart[product].price*count).toFixed(2)}</td>\n <td>\n <button class=\"btn btn-danger\" onclick=\"removeItem('${cart[product].id}')\">X</button>\n </td>\n </tr>\n `;\n duplicates.push(cart[product].id);\n }\n }\n\n updateTotals();\n $('tbody').html(html);\n }\n}", "function displayCart(){\r\n let cartItems = localStorage.getItem(\"productsInCart\");\r\n cartItems = JSON.parse(cartItems);\r\n let productContainer = document.querySelector\r\n (\".product\");\r\n let cartCost = localStorage.getItem('totalCost');\r\n\r\n console.log(cartItems);\r\n if( cartItems && productContainer){\r\n productContainer.innerHTML = '';\r\n Object.values(cartItems).map(item =>{\r\n productContainer.innerHTML += ` \r\n <div class = \"product\">\r\n <ion-icon name=\"close-circle\"></ion-icon>\r\n <span>${item.name}M</span>\r\n </div>\r\n <div class=\"price\">P${item.price}.00</div>\r\n <div class=\"quantity\">\r\n <span>${item.inCart}</span>\r\n </div>\r\n <div class=\"total\">\r\n P${item.inCart * item.price}.00\r\n </div> \r\n `;\r\n });\r\n\r\n productContainer.innerHTML += ` \r\n <div class=\"basketTotalContainer\">\r\n <h4 class=\"basketTotalTitle\">\r\n Basket Total\r\n </h4>\r\n <h4 class=\"basketTotal\">\r\n P${cartCost}.00\r\n </h4>\r\n `;\r\n }\r\n}", "function displayCart() {\n let cartItems = localStorage.getItem(\"productsInCart\");\n cartItems = JSON.parse(cartItems);\nconsole.log(cartItems);\nlet cartCost = localStorage.getItem(\"totalCost\");\nlet productContainer = document.querySelector(\".products\");\n\n\nif(cartIems && productContainer){\n productContainer.innerHTML = '';\n\n Object.values(cartItems)\n .map(item=>{productContainer.innerHTML += `<div class=\"product\"> <ion-icon name=\"close-circle\"></ion-icon>\n <img src=\"./images/${item.tag}.jpg\"> \n <span>${item.name}</span></div>`\n\n `<div class = \"price\">$${item.price}.00</div>`\n `<div class = \"quantity\"><ion-ionic class=\"decrease\" name=\"arrow-dropleft-circle\"></ion-icon>\n <span>${item.inCart}</span>\n\n <ion-ionic class=\"increase\" name=\"arrow-dropright-circle\"> </ion-icon></div>`\n `<div class=\"total\"> $${item.inCart * item.price},00 </div>` \n });\n\n productContainer.innerHTML += `<div class=\"basketTotalContanier\">\n <h4 class =\"basketTotalTitle\"> Basket Total </h4>\n <h4 class =\"basketTotal\">$${cartCost}.00 </h4>`;\nconsole.log(productContainer);\n}\n}", "function viewCart() {\n console.log(buffer);\n if (cartItems.length === 0) {\n console.log(\"Your cart is empty\")\n whatNext();\n } else {\n console.log(\"Items in cart:\");\n for (var i = 0; i < cartItems.length; i++) {\n console.log(cartItems[i] + \" x\" + CartAmount[i]);\n }\n console.log(\"\\nTotal: $\" + cartCost.reduce(add).toFixed(2));\n inCart();\n }\n}", "function getCart() {\n // api call to retrieve items in shopping cart\n API.getCart()\n .then(res=> {\n // save how many cart items to the store for updating the cart total number in navbar from the store\n dispatch({\n type: \"numCartItems\",\n numItems: res.data.length\n })\n })\n}", "displayCart() {\n const productsInCart = JSON.parse(localStorage.getItem('cart'));\n if (productsInCart) {\n // Si le panier n'est pas vide\n let productsToDisplay = [];\n const request = new Request();\n request.getJson(\"/api/cameras/\")\n .then(camerasFromDatabase => {\n productsInCart.map(product => {\n // Pour chaque item dans le panier, on cherche la caméra correspondante dans la base de données\n const matchingCamera = camerasFromDatabase.filter(camera => camera._id == product.id)[0];\n // On ajoute les bonnes infos à afficher\n productsToDisplay.push({\n \"id\": product.id,\n \"name\": matchingCamera.name,\n \"lenseId\": product.lenseId,\n \"lenseName\": matchingCamera.lenses[product.lenseId],\n \"quantity\": product.quantity,\n \"price\": matchingCamera.price\n })\n })\n // Construction du tableau html\n const build = new BuildHtml();\n build.cart(productsToDisplay);\n // Ajout de l'event listener pour la suppression de 1 produit\n const deleteBtns = document.querySelectorAll(\"#cartTableBody td:last-child\");\n for (const deleteBtn of deleteBtns) {\n deleteBtn.addEventListener('click', function() {\n const cart = new Cart();\n cart.delete1Item(this);\n });\n }\n // Ajout de la liste des id qui sera envoyée pour la commande\n let idList = []\n productsToDisplay.map(product => {\n for (let i = 0; i < product.quantity; i++) {\n idList.push(product.id) \n }\n })\n build.addProductListToForm(idList);\n })\n .catch(error => {\n const build = new BuildHtml();\n const errorDiv = build.errorMessage();\n const targetDiv = document.getElementById('cartTable');\n targetDiv.innerText = \"\";\n targetDiv.appendChild(errorDiv);\n })\n document.querySelector(\".cart--btn__purchase\").disabled = false;\n\n } else {\n // Si le panier est vide\n document.getElementById(\"cartTable\").innerHTML = '<p class=\"cart--empty-cart\">Votre panier est vide !</p>';\n document.querySelector(\".cart--btn__purchase\").disabled = true;\n }\n }", "function Cart(){}", "function LoadCart()\n{\n\tCart = JSON.parse(localStorage.getItem(\"ItemsInShoppingCart\"));\n\tDisplayItems();\n\tadd();\n\t//if the cart is not empty display cost and total items in cart page\n\t\tif (TotalCount()>0) {\n\tdocument.getElementById('notempty').innerHTML = \"Total Items in Cart \" + String(TotalCount());\n\tdocument.getElementById('order').innerHTML = \" \";\n\tdocument.getElementById('currentprice').innerHTML = String(TotalCost());}\n\t\n}", "viewCart() {\n alert(\"View Cart\");\n }", "function renderCart(cart, container) {\n var idx, item;\n \n //empty the container of whatever is there currently\n container.empty();\n\n //for each item in the cart...\n var instance;\n var subTotal = 0;\n var str;\n for (idx = 0; idx < cart.items.length; ++idx) {\n item = cart.items[idx];\n subTotal += +item.price; //Unary operator convert to int\n instance = $(\"#template-cart-item\").clone();\n\n //Concatenate display string\n str = item.name + \" (\";\n if (item.size != null) {\n \tstr += item.size + \" - \";\n }\n str += \"$\" + item.price + \")\";\n\n\t\t//Display the cart item\n instance.html(\"<img src=img/x.png>\" + str);\n\t\tvar tempImg = instance.find(\"img\");\n\t\ttempImg.attr(\"data-index\", idx);\n\t\ttempImg.addClass(\"delete-me\");\n\n instance.removeClass(\"js-template\");\n\t\tcontainer.append(instance);\n\n\t\t//Delete item from cart\n\t\t$(\".delete-me\").click(function() {\n\t\t var idxToRemove = +(this.getAttribute('data-index'));\n\t\t cart.items.splice(idxToRemove, 1);\n\t renderCart(cart, $('.cart-container'));\n\t\t});\n } //for each cart item\n\n\n $(\"#cart-sub-total\").html(\"Sub-Total: $\" + subTotal);\n var tax = (subTotal * .095).toFixed(2);\n $(\"#cart-tax\").html(\"Tax: $\" + tax);\n $(\"#cart-total\").html(\"Total: $\" + (+subTotal + +tax)); //Unary operators convert to int\n} //renderCart()", "function displayCart() {\n\tshopcartOverlay.innerHTML = '';\n\tshopcartOverlay.style.display = 'block';\n\tshopBag.src = '/skate-shop/images/shopbag.svg';\n\tshopcartOverlay.style.right = '0';\n\tshopBag.src = '/skate-shop/images/xicon.png';\n\tlet storedCart = JSON.parse(localStorage.getItem('cart'));\n\tlet sum = 0;\n\t//INVOKING FUNCTION TO DISPLAY SHOPPING CART LABEL\n\tcartLabel();\n\t//PRINTING OUT THE CHOSEN ITEMS IN THE USER'S CART\n\tif (!storedCart) {\n\t\treturn;\n\t} else {\n\t\tstoredCart.forEach((item) => {\n\t\t\tshopcartOverlay.innerHTML += `\n\t\t\t <div class=\"displayItem-container\">\n\t\t\t <div class=\"name-box\">\n\t\t\t <h5>${item.name}</h5> \n\t\t\t <img class=\"cart-prdt-img\" src=${item.picUrl} alt=\"${item.alt}\">\n\t\t\t <div class=\"size-container\">Size: ${item.size}</div>\n\t\t\t <div class=\"deleteButton\" data-name=\"${item.label}\">X</div></div>\n\t\t\n\t\t\t <div class=\"price-box\">$${item.price}.00</div>\n\t\t\n\t\t\t <div class=\"qty-box\"><i class=\"fas fa-angle-down\" data-name=\"${item.label}\"></i>${item.qty}<i class=\"fas fa-angle-up\" data-name=\"${item.label}\"></i></div>\n\t\t\t \n\t\t\t <div class=\"totalPrice-box\">$${item.price * item.qty}.00</div>\n\t\t\t </div>\n\t\t\t `;\n\n\t\t\tsum += item.price * item.qty;\n\t\t});\n\t}\n\n\tshopcartOverlay.innerHTML += `\n\t<div id=\"display-subTot-container\">\n\t<p id=\"subTot-text\">Sub total is: $${sum}.00</p>\n\t</div>\n\t`;\n\tupdateCartCounter();\n\n\t//HERE WE ARE CREATING THE DELETE BUTTONS AND INCREASE/DECECREASE ARROWS.\n\tlet deleteButtons = shopcartOverlay.querySelectorAll('.deleteButton');\n\tdeleteButtons.forEach((button) => {\n\t\tbutton.addEventListener('click', removeFromCart);\n\t});\n\n\tlet upArrow = document.querySelectorAll('.fa-angle-up');\n\tlet downArrow = document.querySelectorAll('.fa-angle-down');\n\tupArrow.forEach((button) => {\n\t\tbutton.addEventListener('click', addMore);\n\t});\n\tdownArrow.forEach((button) => {\n\t\tbutton.addEventListener('click', reduce);\n\t});\n}", "function addCart() {\n\n\t//Track number of items in cart\n\tif (cart){\n\t\tcart++;\n\t}\n\telse {\n\t\tcart = 1;\n\t}\n\n\t//Display number of items in cart\n\tdocument.getElementById(\"num_cart\").innerHTML = cart;\n\tdocument.getElementById(\"num_cart\").style.display = \"inline-block\";\n}", "function printCart() {\n\tconsole.log(\"ALL ITEMS IN SHOPPING CART\");\n\tconsole.log(\"-----------------------------\")\n\t// loops through the shoppingCart array\n\tfor (var i = 0; i < shoppingCart.length; i++) {\n\t\t// placeholder variable because I hate typing\n\t\tvar sC = shoppingCart[i];\n\t\tvar sCPrice = sC.purchaseQTY * sC.price_customer\n\t\tconsole.log(\"ITEM \" + (i + 1) + \" IN CART: \" + sC.product_name);\n\t\tconsole.log(\"QTY: \" + sC.purchaseQTY + \" @ \" + sC.price_customer + \" = $\" + sCPrice);\n\t\tconsole.log(\"-----------------------------\");\n\t}\n\tconsole.log(\"TOTAL PRICE OF CART : $\" + parseFloat(cartPrice));\n}", "function addItemToCart() {}", "function addItemToCart() {}", "function showCart() {\n // TODO: Find the table body\n\n // TODO: Iterate over the items in the cart\n // Done\n for(var ItemRow = 0 ; ItemRow < cart.items.length ; ItemRow++ ){\n // TODO: Create a TR\n // Done\n var tr = document.createElement('tr');\n tbody[0].appendChild(tr);\n // TODO: Create a TD for the delete link, quantity, and the item\n // Done\n var td = document.createElement('td');\n // var aLink = document.createElement('a');\n td.textContent = 'X';\n // td.appendChild(aLink);\n tr.appendChild(td);\n\n td = document.createElement('td');\n tr.appendChild(td);\n\n // td.textContent = Product.name;\n console.log('cart.items : ', cart.items);\n\n\n\n\n // for(var itemContent = 1 ; itemContent < 3 ; itemContent++ ){\n // td = document.createElement('td');\n // tr.appendChild(td);\n // td.innerHTML = '' + cart.items[itemContent];\n // }\n\n }\n \n \n // TODO: Add the TR to the TBODY and each of the TD's to the TR\n\n}", "function showCart() {\n\n // TODO: Find the table body\n\n // TODO: Iterate over the items in the cart\n // TODO: Create a TR\nvar trElement=document.createElement('tr');\n // TODO: Create a TD for the delete link, quantity, and the item\n var tdRemove=document.createElement('td');\n var tdQuantity=document.createElement('td');\n var tdItem=document.createElement('td');\n\n // TODO: Add the TR to the TBODY and each of the TD's to the TR\ntrElement.appendChild(tdRemove);\ntrElement.appendChild(tdQuantity);\ntrElement.appendChild(tdItem);\ntable.appendChild(trElement);\n\n}", "function showCartNum() {\n //check that all required objects exist in local storage and create local variables with their values\n var itemsInCart;\n var inCart;\n if (sessionStorage.getItem(\"itemsInCart\") == null) {\n //exit function if itemsInCart doesn't exist\n alert(\"add: itemsInCart does not exist\");\n return;\n }\n else {\n itemsInCart = JSON.parse(sessionStorage.getItem(\"itemsInCart\"));\n }\n if (sessionStorage.getItem(\"inCart\") == null) {\n alert(\"add: inCart does not exist\");\n return;\n }\n else {\n inCart = JSON.parse(sessionStorage.getItem(\"inCart\"));\n }\n //update html\n document.getElementById(\"cartsize\").innerHTML = itemsInCart.toString();\n //update html for each item in the store\n for (var i = 0; i < inCart.length; i++) {\n var id = \"incart\" + i;\n document.getElementById(id).innerHTML = \"Amount in cart: \" + inCart[i].toString();\n }\n}", "function displayCart() {\n let cartItems = localStorage.getItem(\"productsInCart\");\n // when you grab object from localStorage we want to convert to JS objects\n cartItems = JSON.parse(cartItems);\n // check if products container is on page so that it only runs on this HTML page\n let productContainer = document.querySelector('.products');\n let cartCost = localStorage.getItem('totalCost');\n\n //calc VAT\n const VAT_RATE = 0.15;\n let totalVAT = cartCost * VAT_RATE;\n // made use of unary plus operator, to force an eventual string to be treated\n // as number, inside parenthesis to make the code more readable\n // ref: https://stackoverflow.com/questions/8976627/how-to-add-two-strings-as-if-they-were-numbers\n let sumTotal = (+totalVAT) + (+cartCost);\n\n // so we have something in cartItems and it has the container\n if (cartItems && productContainer) {\n productContainer.innerHTML = '';\n Object.values(cartItems).map(item => {\n productContainer.innerHTML += `\n <br>\n <div class=\"product text-center\"> \n <img class=\"img-fluid thumbnail \"src=\"./images/${item.tag}.jpg\"> \n <br>\n \n <span class=\"lead\">${item.name}</span>\n </div>\n <div class=\"price text-center\">\n <span> Price: ${item.price} </span>\n </div>\n <div class=\"quantity text-center\">\n <span> Quantity: ${item.inCart}</span>\n </div>\n\n <div class=\"total text-center\">\n <span> Total Item Price: R${item.inCart * item.price}</span>\n </div>\n `\n });\n productContainer.innerHTML += `\n <hr>\n <div class=\"basketTotalContainer\" style=\"text-align: center\";>\n <h3 class=\"lead\"> Vat: R${totalVAT} </h3>\n <h4 class=\"basketTotalTitle lead\"> \n Total(incl. Vat): R${sumTotal}\n </h4>\n </div>\n <br>\n `\n }\n checkoutTotal(sumTotal);\n return sumTotal;\n}", "function showCart() {\n\n // TODO: Find the table body\n // var tBody = document.getElementsByTagName('tbody');\n\n // TODO: Iterate over the items in the cart\n for (var i = 0; i < cart.items.length; i++) {\n // create table row and three table data\n var row = document.createElement('tr');\n var dataItem = document.createElement('td');\n var dataQuantity = document.createElement('td');\n var dataDelete = document.createElement('td');\n\n // fill data\n dataItem.textContent = cart.items[i].product;\n dataQuantity.textContent = cart.items[i].quantity;\n dataDelete.textContent = 'X';\n\n // add data to row\n row.appendChild(dataDelete);\n row.appendChild(dataQuantity);\n row.appendChild(dataItem);\n\n tBody[0].appendChild(row);\n }\n}", "function updateCart(){if(window.Cart&&window.Cart.updateCart){window.Cart.updateCart();}}", "function cartItem() {\n\titemsArray = JSON.parse(localStorage.getItem('item'));\n\tif (itemsArray !== null) {\n\t\thtmlContent = `<i class=\"fas fa-shopping-cart\"> <span>(${\n\t\t\titemsArray.length\n\t\t})</span> </i>`;\n\t\t$('.fa-shopping-cart')\n\t\t\t.parent()\n\t\t\t.html(htmlContent);\n\t} else {\n\t\thtmlContent = `<i class=\"fas fa-shopping-cart\"> <span>(0)</span> </i>`;\n\t\t$('.fa-shopping-cart')\n\t\t\t.parent()\n\t\t\t.html(htmlContent);\n\t}\n}", "function showCart() {\n //each component cart\n $('.carts').empty();\n $('.cart_component').empty();\n $('.show_total_price').empty();\n $('#render_lastcart').empty();\n $.each(cart, (key, data) => {\n $('.carts').append(\n `<div class=\"container-fluid d-flex justify-content-between px-0\">\n <div class=\"header--img-cart\">\n <img class=\"img_cart\" style=\"width: 60px; height: 60px;\" src=\"${data.prodImage}\">\n </div>\n <div class=\"header__info-cart p-2\">\n <h6><strong id=\"prod_name\"></strong></h6>\n <!--<p class=\"header&#45;&#45;price_1 my-0\">4.000.000 VND</p>-->\n <p class=\"header--price_2 my-0\" style=\"font-size: 13px\">${data.prodPrice}<small>đ x </small><strong>${data.prodQty}</strong></p>\n <div class=\"d-flex\">\n <p style=\"font-size: 12px;margin-right: 3px\">size: ${data.proSize} /</p>\n <p style=\"font-size: 12px\">màu: ${data.proColor}</p>\n </div>\n </div>\n <div class=\"header__remove-item\">\n <i itemid=\"${key}\" class=\"item-cart-del fa fa-trash-o\" aria-hidden=\"true\"></i>\n </div>\n </div>\n `\n );\n $('.cart_component').append(\n `<div class=\"py-3\">\n <div class=\"row\">\n <div class=\"col-md-2 col-lg-2 col-sm-12 col-xs-12 col-xl-2\">\n <img style=\"width: 110px; height: 110px;\" src=\"${data.prodImage}\"/>\n </div>\n <div class=\"col-md-6 col-lg-5 col-sm-12 col-xs-12 col-xl-5 d-flex align-items-center\">\n <div class=\"d-flex justify-content-start flex-column\">\n <div class=\"\">\n <h6>${data.prodName}</h6>\n <div class=\"d-flex\">\n <p class=\"header--price_1 mb-0 py-1 pr-2\">${(data.prodSalePrice != null) ? data.prodSalePrice : ''}</p>\n <p class=\"header--price_2 mb-0\">${data.prodPrice}<small> đ </small></p>\n </div>\n <div class=\"mb-0 d-flex\">\n <label> Màu: ${data.proColor} </label>\n\n <label>/ Size:</label>\n <div class=\"border border-secondary rounded text-center mx-2\" style=\"width: 20px; height: 20px;line-height: 20px;\">${data.proSize}</div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"col-md-1 col-lg-2 col-sm-12 col-xs-12 col-xl-2 d-flex align-items-center\">\n <div class=\"input_quantity\">\n\n <div class=\"quantity d-flex\">\n <button class=\"buttons\">-</button>\n <input id=\"input_quantitys\" style=\"width: 40px\" name=\"qty\" type=\"number\" max=\"2\" min=\"1\" value=\"${data.prodQty}\" readonly=\"readonly\">\n <button class=\"buttons\">+</button>\n </div>\n </div>\n </div>\n <div class=\"col-md-2 col-lg-2 col-sm-12 col-xs-12 col-xl-2 d-flex align-items-center\">\n <div class=\"header__cart\">\n <h6><strong>${totalPriceSingle()}</strong></h6>\n </div>\n </div>\n <div class=\"col-md-1 col-lg-1 col-sm-12 col-xs-12 col-xl-1 d-flex align-items-center\">\n <span itemid=\"${key}\" class=\"item-cart-del\" style=\"cursor:pointer\">xóa</span>\n </div>\n </div>\n </div>`\n );\n $('.show_total_price').empty();\n $('.show_total_price').append(` <h5> Tổng Tiền: <strong>${totalPrice()} VND</strong> </h5>`);\n $('#render_lastcart').append(\n `<div class=\"d-flex justify-content-between p-3\">\n <img src=\"${data.prodImage}\" style=\"width:50px;height: 50px\">\n <div class=\"text-right\">\n <p>${data.prodName.slice(0,20)+'. . .'}</p>\n <small><del></del></small>\n <span>${data.prodPrice}<small>đ</small></span>\n <strong><small>X</small> ${data.prodQty}</strong>\n </div>\n </div>\n <div style=\"border: 1px dashed #ddd\"></div>`\n );\n });\n\n //each total cart total component\n if(cart.length > 0){\n $('.number_item').empty();\n $('.number_item').append(countTotalItem());\n $('.total_cart').empty();\n $('.total_cart').append(\n `\n <a href=\"/checkouts\"><button class=\"btn mb-2 w-100\"> Đặt Hàng</button></a>\n <a href=\"/cart\">\n <button class=\"btn w-100\"> Xem Giỏ Hàng</button>\n </a>\n <strong>Tổng: ${totalPrice()}VND</strong>\n `\n );\n }\n if(cart.length < 1){\n $('.number_item').empty();\n console.log('ok');\n $('.number_item').append(`0`);\n $('.total_cart').empty();\n $('.total_cart').append(`<strong>Giỏ hàng đang trống</strong><i class=\"fa fa-frown-o\" aria-hidden=\"true\"></i>`);\n $('#auto-hide').addClass('invisible');\n }\n //event click delete item\n $('.item-cart-del').on('click', function () {\n const _self = $(this);\n const index = _self.attr('itemid');\n deleteItem(index);\n });\n // each component cart page\n }", "function renderCart(cartItems) {\n let cartContainer = document.querySelector(\"#cart\");\n cartContainer.innerHTML = \"\";\n if (cartItems.length > 0) {\n \n cartItems.map((cartItem) => {\n cartContainer.innerHTML += `\n <div class = \"products\"> \n <div class=\"image-div\">\n <img src=\"${cartItem.image}\" class = \"product-image\">\n </div>\n <div class=\"cart-content\">\n <div class = \"product-content\"> \n \n <h4 class = \"product-title\"> ${cartItem.product_name}</h4>\n <p class = \"product-description\"> ${cartItem.brand}</p>\n <p class = \"product-price\">R${cartItem.price} </p>\n </div>\n\n <div class=\"cart-btns\">\n <button class =\"revome_cart\" onclick=\"removeItem(${cartItem.prod_id})\">Remove item</button>\n <button class=\"checkout-button\" onlcick=\"\">Checkout</button>\n </div>\n\n <div class=\"container\">\n\t\t\t\t <input type=\"button\" onclick=\"decrementValue()\" value=\"-\" />\n\t\t\t\t <input type=\"text\" name=\"quantity\" value=\"1\" maxlength=\"2\" max=\"10\" size=\"1\" id=\"number\" />\n\t\t\t\t <input type=\"button\" onclick=\"incrementValue()\" value=\"+\" />\n\t\t\t\t </div>\n </div>\n \n \n \n \n \n </div>\n\t\t\t \n\t\t \n\n `;\n });\n let totalPrice = cartItems.reduce((total, item) => total + item.price, 0);\n cartContainer.innerHTML += `<h3> Your total is: ${totalPrice} </h3>`;\n } else {\n cartContainer.innerHTML = \"<h2> No items in cart</h2>\";\n }\n}", "function renderCart(cartItems) {\n let cartContainer = document.querySelector(\"#cart\");\n cartContainer.innerHTML = \"\";\n if (cartItems.length > 0) {\n cartItems.map((cartItem) => {\n cartContainer.innerHTML += `\n <div class = \"products\">\n <img src=\"${cartItem.image}\" class = \"product-image\">\n <div class = \"product-content\"> \n <h4 class = \"product-title\"> ${cartItem.product_name}</h4>\n <p class = \"product-description\"> ${cartItem.brand}</p>\n <p class = \"product-price\">R${cartItem.price} </p>\n <button class =\"revome_cart\" onclick=\"removeItem(${cartItems.prod_id})\">Remove item</button>\n </div>\n \n </div>\n \n \n `;\n });\n let totalPrice = cartItems.reduce((total, item) => total + item.price, 0);\n cartContainer.innerHTML += `<h3> Your total is: ${totalPrice} </h3>`;\n } else {\n cartContainer.innerHTML = \"<h2> No items in cart</h2>\";\n }\n}", "function showCart() {\n\n // TODO: Find the table body\n var tbodyEl = document.getElementById('cart').childNodes[3];\n\n // TODO: Iterate over the items in the cart\n for (var count = 0; count<cart.items.length; count++) {\n // TODO: Create a TR\n var tbrEl = document.createElement('tr');\n // TODO: Create a TD for the delete link, quantity, and the item\n var deleteLink = document.createElement('td');\n deleteLink.textContent = 'x';\n deleteLink.name = cart.items[count][0];\n tbrEl.appendChild(deleteLink);\n var quanityEl = document.createElement('td');\n var productEl = document.createElement('td');\n quanityEl.textContent = cart.items[count].quantity;\n productEl.textContent = cart.items[count].product;\n tbrEl.appendChild(quanityEl);\n tbrEl.appendChild(productEl);\n tbodyEl.appendChild(tbrEl);\n }\n // TODO: Add the TR to the TBODY and each of the TD's to the TR\n}", "function loadMyCart() {\n let userId = sessionStorage.getItem('userId');\n marketService.getUser(userId)\n .then((userInfo) => {\n displayMyCart(userInfo);\n }).catch(handleError);\n }", "function loadCart(products){\n\t\tvar source = $(\"#my-cart-template\").html();\n\t\tvar template = Handlebars.compile(source);\n\t\t$(\"#my-cart\").append(template(products));\n\n\t\tvar currency = products.productsInCart[0].c_currency;\n\t\tvar subTotalAmount = calculateSubTotal(products);\n\t\tvar discountAmount = subTotalAmount * calculateDiscount(products);\n\t\tvar pcv = calculatePromoCode();\n\t\tvar sa = calculateShipping();\n\t\tvar estimatedTotal = subTotalAmount - discountAmount - pcv + sa;\n\n\t\t//display calculated values here\n\n\t\t$(\"#count\").html(products.productsInCart.length);\n\t\t$(\"._cur\").html(currency);\n\t\t$(\".subtotal_amount\").html(displayCurrency(subTotalAmount));\n\t\t$(\"._discount_amount\").html(displayCurrency(discountAmount));\n\t\t$(\".promo_applied_amount\").html(displayCurrency(pcv));\n\t\t$(\".shipping_amount\").html(displayCurrency(sa));\n\t\t$(\".estimated_total_amount\").html(displayCurrency(estimatedTotal));\n\t\t$(\"#e_o_l\").prev().css(\"display\", \"none\");;\n\t}", "function invokeItemPage(){\n addCart();\n displayCounter();\n addCartForItem('carrot');\n}", "function displayCart() {\n // elements variables\n\tlet newElement,\n\t\tc_tr,\n\t\tc_th,\n\t\tc_td,\n cartDiv,\n cartTable;\n // increament and total variables\n let count = 1,\n subTotal = 0,\n totalPrice = 0;\n\n\tcartDiv = document.getElementById(\"cart\"); // Cart HTML element\n\n\tif (Object.entries(cartItems).length === 0) {\n\t\tcartDiv.innerHTML = \"Cart is empty!\";\n\t} else {\n\t\t// add cart items:\n\t\tcartDiv.innerHTML = \"\";\n\t\tcartTable = document.createElement(\"table\");\n\t\tcartTable.className = \"table table-sm\";\n\t\tcartTable.innerHTML = `\n <thead>\n <tr>\n <th scope=\"col\">No.</th>\n <th scope=\"col\">Item Name</th>\n <th scope=\"col\">Quantity</th>\n <th scope=\"col\">Price</th>\n <th scope=\"col\">Total</th>\n <th scope=\"col\">Action</th>\n </tr>\n </thead> `;\n\n\t\tcartTableBody = document.createElement(\"tbody\");\n // iterating through cartItems to disply in the table body.\n\t\tfor (let key in cartItems) {\n // calculating subTotal and totalPrice\n\t\t\tsubTotal = products[key].price * cartItems[key];\n\t\t\ttotalPrice += subTotal;\n\n\t\t\tc_tr = document.createElement(\"tr\");\n\t\t\tc_th = document.createElement(\"th\");\n\t\t\tc_th.scope = \"row\";\n\t\t\tc_th.innerHTML = count;\n\t\t\tc_tr.appendChild(c_th);\n\n\t\t\tc_td = document.createElement(\"td\");\n\t\t\tc_td.innerHTML = products[key].name; // item name\n\t\t\tc_tr.appendChild(c_td);\n\t\t\t\n\t\t\tc_td = document.createElement(\"td\");\n\t\t\tnewElement = document.createElement(\"input\"); // item quantity element\n\t\t\tnewElement.id = \"itemQuantity\";\n\t\t\tnewElement.type = \"number\";\n\t\t\tnewElement.min = 1;\n\t\t\tnewElement.dataset.id = key;\n\t\t\tnewElement.value = cartItems[key];\n\t\t\tnewElement.addEventListener(\"change\", updateTotals); // updating cart if quantity changes\n\t\t\tnewElement.innerHTML = cartItems[key];\n\t\t\tc_td.appendChild(newElement);\n\t\t\tc_tr.appendChild(c_td);\n\n\t\t\tc_td = document.createElement(\"td\");\n\t\t\tc_td.innerHTML = `$${products[key].price}`; // item price\n\t\t\tc_tr.appendChild(c_td);\n\n\t\t\tc_td = document.createElement(\"td\");\n c_td.id = `subTotal_${key}`;\n\t\t\tc_td.innerHTML = `$${subTotal}`; // item subTotal\n\t\t\tc_tr.appendChild(c_td);\n\n\t\t\tc_td = document.createElement(\"td\");\n\t\t\tnewElement = document.createElement(\"button\");\n\t\t\tnewElement.innerHTML = \"X\";\n\t\t\tnewElement.type = \"button\";\n\t\t\tnewElement.dataset.id = key;\n\t\t\tnewElement.className = \"btn btn-danger btn-sm\";\n\t\t\tnewElement.addEventListener(\"click\", removeFromCart); // removing item from Cart if clicked. \n\t\t\tc_td.appendChild(newElement);\n\t\t\tc_tr.appendChild(c_td);\n\n\t\t\tcartTableBody.appendChild(c_tr);\n\t\t\tcount += 1; // items counter\n\t\t}\n\n\t\tcartTable.appendChild(cartTableBody);\n\t\tcartDiv.appendChild(cartTable);\n\n\t\t//displaying Total\n\t\tnewElement = document.createElement(\"div\");\n newElement.id = `total`;\n\t\tnewElement.className = \"container text-end\";\n\t\tnewElement.innerHTML = `<h5 class=\"me-5\">Total : $${totalPrice}<h5>`;\n\t\tcartDiv.appendChild(newElement);\n\t}\n}", "function showCart(){\n var parentContainer = document.querySelector('div.container')\n var totalItems = 0;\n var totalPrice = 0;\n if(localStorage.getItem('cart')){\n var cart = JSON.parse(localStorage.getItem('cart'))\n }\n else{\n var msg = document.createElement('p');\n msg.textContent = 'Sorry, cart is empty';\n parentContainer.appendChild(msg)\n var totalItemsSpan = document.querySelector('span.total-items')\n var totalItemsPrice = document.querySelector('span.total-price')\n\n totalItemsSpan.textContent = totalItems;\n totalItemsPrice.textContent = totalPrice;\n return;\n } \n \n\n cart.forEach(function(el){\n var productDiv = document.createElement('div');\n\n //Product Name\n var productName = document.createElement('p');\n productName.innerHTML = \"Product Name: <span class='productName'>\" + el['name'] + \"</span>\";\n productDiv.appendChild(productName);\n\n //Product Price\n var productPrice = document.createElement('p');\n productPrice.innerHTML = \"Price: $ <span class='productPrice'>\" + el['price'] + \"</span>\";\n productDiv.appendChild(productPrice);\n // --- add to total price\n totalItems++;\n totalPrice += Number(el['price']);\n\n //Product URL\n var productImage = document.createElement('p');\n productImage.innerHTML = \"See image at: <span class='productImage'>\" + el['url'] + \"</span>\";\n productDiv.appendChild(productImage);\n\n //Add To Cart Button\n var addToCartBtn = document.createElement('button');\n addToCartBtn.textContent = \"Add To Cart\";\n addToCartBtn.setAttribute('class', 'add-to-cart');\n productDiv.appendChild(addToCartBtn);\n\n parentContainer.appendChild(productDiv);\n })\n\n var totalItemsSpan = document.querySelector('span.total-items')\n var totalItemsPrice = document.querySelector('span.total-price')\n\n totalItemsSpan.textContent = totalItems;\n totalItemsPrice.textContent = totalPrice;\n\n}", "function showCart() {\n document.querySelector(\".cart__modal\").style.display = \"block\";\n document.querySelector(\".cart__container\").style.display = \"block\";\n document.querySelector(\".live__list\").classList.add(\"hidden\");\n document.querySelector(\".laugh__list\").classList.add(\"hidden\");\n document.querySelector(\".lounge__list\").classList.add(\"hidden\");\n}", "function generateCartButtons() {\n if (productsInCart.length > 0) {\n emptyCart.style.display = \"block\";\n cartCheckout.style.display = \"block\"\n totalPrice.innerHTML = calculateTotalPrice() + \" kn\";\n } else {\n emptyCart.style.display = \"none\";\n cartCheckout.style.display = \"none\";\n }\n }", "function displayCartItems(){\n\n //get cart from local storage\n let cart = localStorage.getItem(\"cart\"); \n \n // split contents of cart local storage into 1d array\n let bookList = cart.split('@@@');\n var quantity = [];\n var cList = \"\";\n \n // Change the 1 outer array into 2 dim array\n // and create a HTML list\n for (let z = 0; z<bookList.length;z++)\n {\n bookList[z] = bookList[z].split('$$$');\n quantity[z] = bookList[z][1]; //count\n let currentBook = StringToJSON(bookList[z][0]);\n cList += \"<p>\";\n cList += currentBook.title;\n cList += \"<span class = 'price'>\"\n cList += quantity[z];\n cList += \" x $\"\n cList += currentBook.price;\n cList += \"</span></p>\"; \n }\n \n // Get total price\n var cartTotal = parseInt(localStorage.getItem(\"cartTotal\"));\n var tax = 0.0635;\n var shipping = 4.99\n \n\t// Display the table\n\tdocument.getElementById(\"checkoutList\").innerHTML = cList; \n document.getElementById(\"checkoutSubtotal\").innerHTML = \"$\" + cartTotal.toFixed(2);\n document.getElementById(\"taxes\").innerHTML = \"$\" + (cartTotal * tax).toFixed(2);\n document.getElementById(\"shipping\").innerHTML = \"$\" + 4.99;\n document.getElementById(\"checkoutTotalPrice\").innerHTML = \"$\" + totalCost();\n localStorage.setItem(\"totalPrice\",((parseInt(cartTotal)* 1.0635)+4.99).toFixed(2));\n \n}", "function CartPage() {\n\treturn <Cart />;\n}", "function showCart() {\n\n // TODO: Find the table body\n var table = document.getElementById('cart');\n // TODO: Iterate over the items in the cart\n for(var i = 0; i < cart.items.length; i++) {\n // TODO: Create a TR\n var tr = document.createElement('tr');\n // TODO: Create a TD for the delete link, quantity, and the item\n var deleteLinkEl = document.createElement('td');\n var a = document.createElement('a');\n a.textContent = 'X';\n a.href = '#';\n deleteLinkEl.appendChild(a);\n\n var quantityEl = document.createElement('td');\n quantityEl.textContent = cart.items[i].quantity;\n\n var itemEl = document.createElement('td');\n itemEl.textContent = cart.items[0].product;\n\n // TODO: Add the TR to the TBODY and each of the TD's to the TR\n tr.appendChild(deleteLinkEl);\n tr.appendChild(quantityEl);\n tr.appendChild(itemEl);\n\n table.appendChild(tr);\n }\n}", "function loadCheckOutPage()\n{\n displayCartItems();\n}", "function processCartPage() {\n var _this = this;\n // Check current page is cart page\n if (!isCartPage()) {\n goToCartPage();\n return;\n }\n // Get the body element\n var content = document.querySelector(\"body\");\n var html = \"<body>\" + content.innerHTML + \"</body>\";\n (function () { return __awaiter(_this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4 /*yield*/, sendCartDetailsToApi(html)];\n case 1:\n _a.sent();\n return [2 /*return*/];\n }\n });\n }); })();\n}", "function viewCart() {\n // special case if there are no items in the cart\n if(cart.length === 0){\n return \"Your shopping cart is empty.\"\n } else {\n // create empty array\n var newArray = [];\n\n for(var i = 0; i < cart.length; i++){\n // special case for first item\n if(i === 0){\n newArray.push(`In your cart, you have ${cart[i].itemName} at $${cart[i].itemPrice}`)\n }\n // special case for last item\n else if(i + 1 === cart.length){\n console.log(\"hi\")\n newArray.push(` and ${cart[i].itemName} at $${cart[i].itemPrice}`);\n }else {\n // convert the Array of Objects into an Array of String\n newArray.push(` ${cart[i].itemName} at $${cart[i].itemPrice}`)\n }\n }\n // In your cart, you have bananas at $17, pancake batter at $5, and eggs at $49.\n return `${newArray.toString()}.`\n }\n}", "function displaycart() {\n let cartItems = localStorage.getItem(\"productsInCart\");\n cartItems = JSON.parse(cartItems);\n console.log(cartItems)\n // for basket total price\n let totalPrice = localStorage.getItem(\"totalPrice\");\n // to display shopping products \n let productsIncart = document.querySelector(\".products\");\n if (cartItems && productsIncart) {\n productsIncart.innerHTML = \"\";\n // getting only product object from cartitems\n let cartItemsArray = Object.values(cartItems);\n console.log(Object.values(cartItems))\n //mapping of each item\n cartItemsArray.map(item => {\n // for each product in cart\n productsIncart.innerHTML += `\n <div class= \"product\">\n <ion-icon class=\"remove-button\" name = \"close-circle\"></ion-icon>\n <img src=\"./img/${item.tag}.jpg\">\n <span>${item.name}</span>\n </div>\n <div class= \"price\"> ${item.price}</div>\n <div class= \"quantity\">\n <ion-icon class = \"increase\" name=\"add-circle-outline\"></ion-icon> \n <span>${item.inCart}</span>\n <ion-icon class = \"decrease\" name=\"remove-circle-outline\"></ion-icon> \n </div>\n <div class= \"total\">\n ${item.inCart * item.price}\n </div>\n `;\n });\n console.log(totalPrice)\n // for basket total in cart.html\n productsIncart.innerHTML += `\n <div class= \"basketTotalContainer\">\n <h4 class= \"basketTotalTitle\"> Basket Total </h4>\n <h4 class= \"basketTotal\"> ${totalPrice}.00</h4> \n </div>\n `;\n }\n changingQuantityOfCartItems();\n RemoveCartItem();\n\n\n}", "function loadCart(){\r\n inames = JSON.parse(sessionStorage.getItem(\"inames\"));\r\n iprice = JSON.parse(sessionStorage.getItem(\"iprice\"));\r\n showCart();\r\n}", "function loadShoppingCart() {\n console.log('setShoppingcart')\n \n // reset cart and values\n document.getElementsByClassName('all-cart-product')[0].innerHTML = \"\";\n total_items = 0;\n total = 0;\n\n // render cartItem to cart\n for (var i= 0; i< cart.length; i++){\n\n //update total numer of items\n total_items = total_items + cart[i].quantity;\n\n //update total price\n total = total + (cart[i].price * cart[i].quantity);\n\n var display_individualisation = cart[i].hasIndividualisation === false ? 'none': 'block';\n\n var individualisationwrapper = '';\n for (var k = 0; k < cart[i].individualisation.length; k++){\n individualisationwrapper+= '<p style=\"display:'+display_individualisation+'; font-family: '+cart[i].individualisation[k].font+'; font-size: 1.1em;\">'+cart[i].individualisation[k].value+'</p>';\n }\n \n\n var div = document.createElement('div');\n div.className = \"single-cart clearfix\";\n div.innerHTML = '<div class=\"single-cart clearfix\">\\\n <div class=\"cart-photo\">\\\n <a href=\"#\"><img src=\"img/cart/'+ cart[i].image +'\" alt=\"\"></a>\\\n </div>\\\n <div class=\"cart-info\">\\\n <h5><a href=\"#\">'+ cart[i].productname +'</a></h5>\\\n <p class=\"mb-0\">#'+ cart[i].itemId +' </p>\\\n <p class=\"mb-0\"><span data-i18n=\"cart-price-label\">Preis:</span> '+ cart[i].price.toLocaleString('de-DE', {maximumFractionDigits: 2, minimumFractionDigits: 2, minimumIntegerDigits:1 }) +' €</p>\\\n <p class=\"mb-0\"><span data-i18n=\"cart-quantity-label\">Stück:</span> '+ cart[i].quantity +' </p>\\\n <p style=\"display:'+display_individualisation+'; class=\"mt-20\">'+ individualisationwrapper +' </p>\\\n <span data-cartItemId=\"'+cart[i].cartItemId +'\" onclick=\"removeItemfromCart(this)\" class=\"cart-delete\"><a href=\"#\"><i class=\"zmdi zmdi-close\"></i></a></span>\\\n <img style=\"display:'+display_individualisation+'; height:25px; width: 100%\" src=\"'+cart[i].decorImage+'\">\\\n </div>\\\n </div>'\n document.getElementsByClassName('all-cart-product')[0].appendChild(div);\n\n } // End for-loop\n\n // set badge number\n document.getElementsByClassName('cart-icon')[0].querySelector('span').innerHTML = total_items;\n\n //set number in detail hover view\n document.getElementsByClassName('cart-items')[0].querySelector('p').innerHTML = $.i18n( 'you have $1 {{plural:$1|item|items}} in your shopping bag', total_items );\n \n // render total price\n document.getElementsByClassName('cart-totals')[0].querySelector('span').innerHTML = total.toLocaleString('de-DE', {maximumFractionDigits: 2, minimumFractionDigits: 2, minimumIntegerDigits:1 }) + ' €';\n\n //disable cart button if cart is empty\n if(total_items === 0){\n document.getElementsByClassName('cart-bottom')[0].style.display = 'none';\n document.getElementsByClassName('all-cart-product')[0].style.display = 'none';\n \n }else{\n document.getElementsByClassName('cart-bottom')[0].style.display = 'block';\n document.getElementsByClassName('all-cart-product')[0].style.display = 'block';\n }\n \n}", "function updateCart(){\n\t\tstorage(['items', 'subtotal'], function(err, col){\n\t\t\t//console.log(\"Cart Collection - \" + JSON.stringify(col));\n\n\t\t\t//items = col[0];\n\t\t\t//subtotal = col[1];\n\n\t\t\tif(console) console.log(\"Items in Cart: \" + items);\n\t\t\tif(console) console.log(\"Subtotal of Cart: \" + subtotal);\n\t\t\t\n\t\t\t// update DOM Here\n\t\t\tdocument.getElementById( _options.itemsEleId ).innerHTML = items;\n\t\t\tdocument.getElementById( _options.subtotalEleId ).value = \"$\" + subtotal.toFixed(2);\n\n\t\t\t// reset default quantity input fields of products\n\t\t\tPRODUCTS.updateProducts();\n\t\t});\n\t}", "function appendToCart(){\n ui.cartItems.innerHTML = \"\";\n cart.forEach((item)=>{\n ui.appendToCart(item.imgSrc,item.title,item.size,item.price,item.id,item.numberOfUnits);\n })\n}", "function displayShoppingCart(){\n var orderedProductsTblBody=document.getElementById(\"orderedProductsTblBody\");\n //ensure we delete all previously added rows from ordered products table\n while(orderedProductsTblBody.rows.length>0) {\n orderedProductsTblBody.deleteRow(0);\n }\n\n //variable to hold total price of shopping cart\n var cart_total_price=0;\n //iterate over array of objects\n for(var product in shoppingCart){\n //add new row \n var row=orderedProductsTblBody.insertRow();\n //create three cells for product properties \n var cellName = row.insertCell(0);\n var cellDescription = row.insertCell(1);\n var cellPrice = row.insertCell(2);\n cellPrice.align=\"right\";\n //fill cells with values from current product object of our array\n cellName.innerHTML = shoppingCart[product].Name;\n cellDescription.innerHTML = shoppingCart[product].Description;\n cellPrice.innerHTML = shoppingCart[product].Price.toFixed(2);\n cart_total_price+=shoppingCart[product].Price;\n }\n //fill total cost of our shopping cart \n var temp = ((1.0919 * (cart_total_price.toFixed(2))) + 12.35);\n \n document.getElementById(\"cart_total\").innerHTML=\"$\" + temp.toFixed(2);\n var x = shoppingCart.length;\n document.getElementById(\"navigationTextCart\").innerHTML=\"Shopping Cart(\" + x + \")\";\n }", "function updateShoppingCart(addQty) {\n\tvar totalItems = getTotalItemsCart() + addQty;\n\tdocument.getElementById('shopping-cart-text').innerHTML = totalItems + ' items';\n}", "function showCart() {\n // TODO: Find the table body\n var tBody = document.getElementsByTagName('tbody')[0];\n // TODO: Iterate over the items in the cart\n for (var j = 0; j < cart.items.items.length; j++) {\n // TODO: Create a TR\n var cartTR = document.createElement('tr');\n // TODO: Create a TD for the delete link, quantity, and the item\n var removeBtnTD = document.createElement('td');\n var newBtn = document.createElement('button');\n newBtn.textContent = 'Delete this item';\n removeBtnTD.appendChild(newBtn);\n cartTR.appendChild(removeBtnTD);\n\n var pictureTD = document.createElement('td');\n var newPicture = document.createElement('img');\n newPicture.src = cart.items.items[j].product;\n cartTR.appendChild(pictureTD);\n pictureTD.appendChild(newPicture);\n\n var quantityTD = document.createElement('td');\n quantityTD.innerText = cart.items.items[j].quantity;\n cartTR.appendChild(quantityTD);\n\n // TODO: Add the TR to the TBODY and each of the TD's to the TR\n tBody.appendChild(cartTR);}\n}", "function updateCartDetails() {\n var numberOfCartItems = 0;\n totalCost = 0;\n\n for (var i = 0; i < cartItems.length; i++) {\n numberOfCartItems = numberOfCartItems + cartItems[i][3];\n totalCost = totalCost + cartItems[i][2] * cartItems[i][3];\n }\n $(\"#numberOfCartItems\").text(numberOfCartItems);\n $(\"#cartItemTotal\").text(totalCost);\n if (numberOfCartItems > 3) {\n $(\".cart-item-container\").addClass(\"scrollable-menu\");\n } else {\n $(\".cart-item-container\").removeClass(\"scrollable-menu\");\n }\n\n displayCartItems();\n}", "function updateCartPreview() {\n // TODO: Get the item and quantity from the form\n let product = document.getElementById('items').value;\n let quantity = document.getElementById('quantity').value;\n // TODO: Add a new element to the cartContents div with that information\n let cartContents = document.querySelector('#cartContents');\n let newContent = document.createElement('p');\n newContent.innerText = `${quantity}: ${product}`;\n cartContents.appendChild(newContent);\n\n}", "function updateCartPreview() {\n // DONE: Get the item and quantity from the form\n // DONE: Add a new element to the cartContents div with that information\n\n var itemAddedDisplayEl = document.getElementById('cartContents');\n var itemsEl = document.getElementById('items').value;\n var quantityEl = document.getElementById('quantity').value;\n itemAddedDisplayEl.textContent ='Item: ' + itemsEl + ' Quantity: ' + quantityEl;\n}", "function loadCart(){\n cart = JSON.parse(sessionStorage.getItem('revonicCart')); // fetching original object items using JSON parse. \n }", "function showCart() {\n // localStorage.getItem('items')\n // var cartTable = document.getElementById('cart')\n // if (localStorage.) {\n var allItemsString = localStorage.getItem('items');\n var allItemsData = JSON.parse(allItemsString);\n for (var i = 0; i < Cart.length; i++) {\n var tr = document.createElement('tr');\n var deleteLink = document.createElement('td');\n var deleteQuantity = document.createElement('td');\n var deleteItem = document.createElement('td');\n tr.appendChild(deleteItem);\n tr.appendChild(deleteQuantity);\n tr.appendChild(deleteLink);\n allItemsData.appendChild(tr);\n }\n}", "function showCartItems() {\n const billItemContainer = document.querySelector(\".bill-items\");\n billItemContainer.innerHTML = \"\";\n if (cart.length > 0) {\n const billItem = document.createElement(\"div\");\n billItem.classList = \"bill-item\";\n const itemName = document.createElement(\"h4\");\n itemName.innerHTML = \"Name\";\n const itemQuantity = document.createElement(\"p\");\n itemQuantity.innerHTML = \"Qty\";\n const itemPrice = document.createElement(\"p\");\n itemPrice.innerHTML = \"Price\";\n\n billItem.appendChild(itemName);\n billItem.appendChild(itemQuantity);\n billItem.appendChild(itemPrice);\n\n billItemContainer.appendChild(billItem);\n }\n cart.map((item) => {\n const billItem = document.createElement(\"div\");\n billItem.classList = \"bill-item\";\n\n const itemName = document.createElement(\"h5\");\n itemName.innerHTML = item.name;\n const itemQuantity = document.createElement(\"p\");\n itemQuantity.innerHTML = ` x ${item.quantity}`;\n const itemPrice = document.createElement(\"p\");\n itemPrice.innerHTML = \"₹ \" + item.price;\n\n billItem.appendChild(itemName);\n billItem.appendChild(itemQuantity);\n billItem.appendChild(itemPrice);\n\n billItemContainer.appendChild(billItem);\n });\n}" ]
[ "0.8199349", "0.8199349", "0.8199349", "0.8199349", "0.8199349", "0.8199349", "0.8199349", "0.8199349", "0.8199349", "0.8199349", "0.8199349", "0.8199349", "0.8199349", "0.8199349", "0.8199349", "0.8199349", "0.8199349", "0.81431025", "0.8133412", "0.80924135", "0.8089521", "0.8068178", "0.7787415", "0.7765276", "0.76981735", "0.7637878", "0.7539286", "0.74299216", "0.73395485", "0.733077", "0.73069745", "0.7142177", "0.7105021", "0.70849437", "0.7055095", "0.7036373", "0.7035375", "0.6981543", "0.6959859", "0.690061", "0.6867271", "0.6854905", "0.68249613", "0.67887324", "0.67676187", "0.6762229", "0.6738644", "0.6714161", "0.67117965", "0.6700848", "0.6697083", "0.66721255", "0.66632426", "0.6649573", "0.6639509", "0.6639013", "0.66378075", "0.66108197", "0.65949583", "0.6584932", "0.6572211", "0.6572211", "0.6566031", "0.6555537", "0.6544196", "0.65303785", "0.6487216", "0.6486555", "0.6484428", "0.647699", "0.6472853", "0.6456912", "0.6452567", "0.6442823", "0.6440311", "0.6438655", "0.64340454", "0.6432576", "0.6429647", "0.6424538", "0.64183307", "0.64032775", "0.6402287", "0.640186", "0.64016706", "0.63979137", "0.6397788", "0.6378949", "0.63629836", "0.6355945", "0.6330439", "0.6327026", "0.6318019", "0.63145936", "0.6311264", "0.6309103", "0.6307209", "0.63000566", "0.62914413", "0.6287327" ]
0.6980044
38
drag_util.js Utility functions for YUI darg and drop applications ///////////////////////////////////// Dependencies from YUI yahoomin.js dommin.js eventmin.js //////////////////// //////////////////////////// selectMultiple Event Handeler Uses Shift or Cmd/Ctrl click to select multiple items in a supplied container element ///// Variables //////////// ev JS Event use_parent Bool apply selected class to the clicked element or it's parent (e.g. for tables event is fired by td but selected class is applied to tr);
function selectMultiple(ev, use_parent){ var Dom = YAHOO.util.Dom, Event = YAHOO.util.Event; var dd = null; var tar = Event.getTarget(ev); if(use_parent){ tar = tar.parentNode; } var kids = tar.parentNode.getElementsByTagName(tar.tagName); //Event.stopEvent(ev); //If the shift key is pressed, add it to the list if (ev.metaKey || ev.ctrlKey) { if (tar.className.search(/selected/) > -1) { Dom.removeClass(tar, 'selected'); } else { Dom.addClass(tar, 'selected'); } }else if(ev.shiftKey) { var sel = false; for (var i = 0 ; i < kids.length ; i++){ if(!sel && kids.item(i).className.search(/selected/) > -1){ sel = true; } if(sel){ Dom.addClass(kids.item(i), 'selected'); } if(kids.item(i) == tar){ // shift clicked elem reached if(!sel){ //selection either below or no other row selected for (var ii = i ; ii < kids.length ; ii++){ if(!sel && kids.item(ii).className.search(/selected/) > -1){ sel = true; }else if(sel && kids.item(ii).className.search(/selected/) == -1){ break; } Dom.addClass(kids.item(ii), 'selected'); } if(!sel){ //no second row selected for (var ii = i + 1 ; i < kids.length ; i++){ Dom.removeClass(kids.item(ii), 'selected'); } } } break; } } }else { for (var i = 0 ; i < kids.length ; i++){ kids.item(i).className = ''; } Dom.addClass(tar, 'selected'); } //clear any highlighted text from the defualt shift-click functionality clearSelection(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function initializeMultipleSelectBoxMouseEvent($container) {\r\n\t\tvar $document = $(document);\r\n\t\t/* process container event */\r\n\t\t$container.bind(\"mousedown.\" + PLUGIN_NAMESPACE, function(e) {\r\n\t\t\t/* disable text selection */\r\n\t\t\te.preventDefault();\r\n\t\t\t/* starting row */\r\n\t\t\tvar target = e.target;\r\n\t\t\tvar $target = $(target);\r\n\t\t\tvar $startRow = $target;\r\n\t\t\t/* correct the focus for chrome */\r\n\t\t\tif (target == this) {\r\n\t\t\t\treturn;\r\n\t\t\t} else if ($target.parent()[0] != this) {\r\n\t\t\t\ttarget.focus();\r\n\t\t\t\t$startRow = $target.parents(\".\" + PLUGIN_NAMESPACE + \">*\").eq(0);\r\n\t\t\t} else {\r\n\t\t\t\tthis.focus();\r\n\t\t\t}\r\n\t\t\tvar startIndex = $startRow.getMultipleSelectBoxRowIndex($container);\r\n\t\t\tvar currentIndex = startIndex;\r\n\t\t\t/* trigger callback */\r\n\t\t\tif (!fireOnSelectStartEvent(e, $container, startIndex)) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t\t/* prepare info for drawing */\r\n\t\t\tvar options = $container.getMultipleSelectBoxOptions();\r\n\t\t\tvar containerHistory = $container.getMultipleSelectBoxHistory();\r\n\t\t\t/* opposite and retain selection for touch device */\r\n\t\t\tvar isTouchDeviceMode = options.isTouchDeviceMode;\r\n\t\t\tvar isSelectionOpposite = isTouchDeviceMode;\r\n\t\t\tvar isSelectionRetained = isTouchDeviceMode;\r\n\t\t\tif (options.isKeyEventEnabled) {\r\n\t\t\t\tif (e.shiftKey) {\r\n\t\t\t\t\tcurrentIndex = startIndex;\r\n\t\t\t\t\tstartIndex = containerHistory.selectingStartIndex;\r\n\t\t\t\t} else if (e.ctrlKey) {\r\n\t\t\t\t\tisSelectionOpposite = isSelectionRetained = true;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t/* starting */\r\n\t\t\t$container.addClass(PLUGIN_STYLE_SELECTING).drawMultipleSelectBox(startIndex, currentIndex, {\r\n\t\t\t\t\"isSelectionOpposite\": isSelectionOpposite,\r\n\t\t\t\t\"isSelectionRetained\": isSelectionRetained,\r\n\t\t\t\t\"scrollPos\": null\r\n\t\t\t});\r\n\t\t\t/* listening */\r\n\t\t\tvar scrollHelperFunc = function(e1) {\r\n\t\t\t\toptions.scrollHelper(e1, $container, startIndex, isSelectionRetained);\r\n\t\t\t};\r\n\t\t\t$container.yieldMultipleSelectBox().bind(\"mouseenter.\" + PLUGIN_NAMESPACE, function() {\r\n\t\t\t\tunbindEvents($document, [ \"mousemove\" ]);\r\n\t\t\t}).bind(\"mouseleave.\" + PLUGIN_NAMESPACE, function(e1) {\r\n\t\t\t\tscrollHelperFunc(e1);\r\n\t\t\t\t$document.bind(\"mousemove.\" + PLUGIN_NAMESPACE, function(e2) {\r\n\t\t\t\t\tscrollHelperFunc(e2);\r\n\t\t\t\t});\r\n\t\t\t}).bind(\"mouseover.\" + PLUGIN_NAMESPACE, function(e1) {\r\n\t\t\t\tscrollHelperFunc(e1);\r\n\t\t\t}).one(\"mouseup.\" + PLUGIN_NAMESPACE, function(e1) {\r\n\t\t\t\tscrollHelperFunc(e1);\r\n\t\t\t});\r\n\t\t\t/* IE hacked for mouse up event */\r\n\t\t\tif (isIE) {\r\n\t\t\t\t$document.bind(\"mouseleave.\" + PLUGIN_NAMESPACE, function() {\r\n\t\t\t\t\t$document.one(\"mousemove.\" + PLUGIN_NAMESPACE, function(e1) {\r\n\t\t\t\t\t\tif (!e1.button) {\r\n\t\t\t\t\t\t\tvalidateMultipleSelectBox(e1);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t});\r\n\t\t\t\t});\r\n\t\t\t}\r\n\t\t});\r\n\t\t/* select group items automatically */\r\n\t\t$container.getMultipleSelectBoxCachedRows().filter(\".\" + PLUGIN_STYLE_OPTGROUP).bind(\"dblclick.\" + PLUGIN_NAMESPACE, function(e) {\r\n\t\t\tvar $startRow = $(this);\r\n\t\t\t/* trigger callback */\r\n\t\t\tif (!fireOnSelectStartEvent(e, $container, $startRow.getMultipleSelectBoxRowIndex($container))) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t\tvar options = $container.getMultipleSelectBoxOptions();\r\n\t\t\tvar maxLimit = options.maxLimit;\r\n\t\t\tvar childGroupItemList = $startRow.getMultipleSelectBoxOptGroupItems();\r\n\t\t\tvar childGroupItemSelectSize = childGroupItemList.length;\r\n\t\t\tif (childGroupItemSelectSize > 0) {\r\n\t\t\t\tif (maxLimit > 0 && childGroupItemSelectSize > maxLimit) {\r\n\t\t\t\t\tchildGroupItemSelectSize = maxLimit;\r\n\t\t\t\t}\r\n\t\t\t\t$container.drawMultipleSelectBox(childGroupItemList.eq(0).getMultipleSelectBoxRowIndex($container), childGroupItemList.eq(childGroupItemSelectSize - 1).getMultipleSelectBoxRowIndex($container), {\r\n\t\t\t\t\t\"scrollPos\": null\r\n\t\t\t\t});\r\n\t\t\t\t/* special case */\r\n\t\t\t\t$container.addClass(PLUGIN_STYLE_SELECTING);\r\n\t\t\t\tvalidateMultipleSelectBox(e);\r\n\t\t\t}\r\n\t\t});\r\n\t}", "function initMultipleSelection(element) {\n element.on('click', 'li.type-task, li.type-sub-task', function (eventObject) {\n if (!eventObject.ctrlKey) {\n $('li.selected', element).not(this).removeClass('selected');\n }\n $(this).toggleClass('selected');\n eventObject.stopPropagation();\n });\n}", "click(event){\n if(event.target.tagName === \"MULTI-SELECTION\"){\n const onContainerMouseClick = this.onContainerMouseClick;\n\n if(onContainerMouseClick){\n onContainerMouseClick();\n }\n }\n }", "function doSelections(event, selectedEles, cols) {\n // Select elements in a range, either across rows or columns\n function selectRange() {\n var frstSelect = selectedEles[0];\n var lstSelect = selectedEles[selectedEles.length - 1];\n if (cols) {\n var flipStart = flipFlipIdx(Math.min(flipIdx(selectionMinPivot), flipIdx(selectionMaxPivot),\n flipIdx(frstSelect), flipIdx(lstSelect)));\n var flipEnd = flipFlipIdx(Math.max(flipIdx(selectionMinPivot), flipIdx(selectionMaxPivot),\n flipIdx(frstSelect), flipIdx(lstSelect)));\n selectElemsDownRows(Math.min(flipStart, flipEnd), Math.max(flipStart, flipEnd));\n } else {\n var start = Math.min(selectionMinPivot, frstSelect);\n var end = Math.max(selectionMaxPivot, lstSelect);\n selectElemRange(start, end);\n }\n }\n // If not left mouse button then leave it for someone else\n if (event.which != LEFT_MOUSE_BUTTON) {\n return;\n }\n // Just a click - make selection current row/column clicked on\n if (!event.ctrlKey && !event.shiftKey) {\n clearAll();\n selectEles(selectedEles);\n selectionMinPivot = selectedEles[0];\n selectionMaxPivot = selectedEles[selectedEles.length - 1];\n return;\n }\n // Cntrl/Shift click - add to current selections cells between (inclusive) last single selection and cell\n // clicked on\n if (event.ctrlKey && event.shiftKey) {\n selectRange();\n return;\n }\n // Cntrl click - keep current selections and add toggle of selection on the single cell clicked on\n if (event.ctrlKey) {\n toggleEles(selectedEles);\n selectionMinPivot = selectedEles[0];\n selectionMaxPivot = selectedEles[selectedEles.length - 1];\n return;\n }\n // Shift click - make current selections cells between (inclusive) last single selection and cell clicked on\n if (event.shiftKey) {\n clearAll();\n selectRange();\n }\n }", "function selectedDblclick( event ) {\n if ( self.cfg.onSelectedDblclick.length > 0 &&\n ( $(event.target).hasClass('selected') || $(event.target).closest('g').hasClass('selected') ) )\n for ( var n=0; n<self.cfg.onSelectedDblclick.length; n++ )\n self.cfg.onSelectedDblclick[n](event.target);\n }", "mouseUp(e){\n this._super(...arguments);\n\n\n if(e.path === undefined || e.path[0].tagName !== \"MULTI-SELECTION\"){\n return;\n }\n\n if(e.button == 0){\n e.stopPropagation();\n e.preventDefault();\n\n this.set('moveStart', false);\n }\n\n\n\n document.removeEventListener('mousemove', this.get('mouseMoveListener'));\n document.removeEventListener('mouseup', this.get('mouseUpListener'));\n\n\n }", "function setupMouseEvents(parent, canvas, selection) {\n function mousedownHandler(evt) {\n var mousePos = selection\n .geometry()\n .m2v(multiselect_utilities.offsetMousePos(parent, evt));\n switch (multiselect.modifierKeys(evt)) {\n case multiselect.NONE:\n selection.click(mousePos);\n break;\n case multiselect.CMD:\n selection.cmdClick(mousePos);\n break;\n case multiselect.SHIFT:\n selection.shiftClick(mousePos);\n break;\n default:\n return;\n }\n\n selection.geometry().drawIndicators(selection, canvas, true, true, false);\n\n document.addEventListener(\"mousemove\", mousemoveHandler, false);\n document.addEventListener(\"mouseup\", mouseupHandler, false);\n evt.preventDefault();\n evt.stopPropagation();\n }\n\n function mousemoveHandler(evt) {\n evt.preventDefault();\n evt.stopPropagation();\n var mousePos = selection\n .geometry()\n .m2v(multiselect_utilities.offsetMousePos(parent, evt));\n selection.shiftClick(mousePos);\n selection.geometry().drawIndicators(selection, canvas, true, true, true);\n }\n\n function mouseupHandler(evt) {\n document.removeEventListener(\"mousemove\", mousemoveHandler, false);\n document.removeEventListener(\"mouseup\", mouseupHandler, false);\n selection\n .geometry()\n .drawIndicators(selection, canvas, true, true, false, false);\n }\n\n parent.addEventListener(\"mousedown\", mousedownHandler, false);\n}", "function selectImg(e){\n\n //get the id of the thumb that was clicked on (e.g thumb0, thumb1,...etc)\n var selectedThumbId = e.toElement.id;\n\n //get the number of the thumb that was clicked on from its id (e.g. 0,1,2,...etc)\n var selectedImgNum = (selectedThumbId.substring(8))*1;\n\n // if shift is pressed when user clicks on thumb:\n // then highlight all images between the last selected image and the image that was clicked on when shift was pressed\n if(e.shiftKey) {\n\n var start = selectedImgs[selectedImgs.length-1] + 1; // next thumb after last entry in the selected images array\n var end = selectedImgNum;\n\n //handle case of selecting images in reverse order\n if(end < start) {\n start = end;\n end = selectedImgs[0]-1;\n }\n\n\n //loop through the thumbs add them to the array selectedImgs and mark the thumbs as selected\n for (var i=start; i<end+1; i++) {\n\n if(selectedImgs.indexOf(i)<0) {\n selectedImgs.push(i);\n $('#thumb' + i).addClass('selected');\n }\n\n selectedImgs.sort(function(a,b){return a-b});\n\n }\n\n } else {\n\n //check if the thumb that was clicked on has already been selected:\n //if the image has not been selected it wont be in the array selectedImgs and index will be -1\n var index = selectedImgs.indexOf(selectedImgNum);\n\n if(index < 0 ) {\n //image was not already selected\n selectedImgs.push(selectedImgNum); //add the number of the image to the array selectedImgs\n selectedImgs.sort(function(a,b){return a-b});\n $('#thumb' + selectedImgNum).addClass('selected'); //show a border around the thumb\n } else {\n //image was already selected\n selectedImgs.splice(index,1); //remove the number of the image from the array selectedImgs\n $('#thumb' + selectedImgNum).removeClass('selected'); //remove the border around the thumb\n }\n\n }\n\n }", "selectItemEvent(event) {\n\n var name = event.target.getAttribute('data-name')\n var boxid = event.target.getAttribute('id')\n var client = event.data.client\n var items = client.items\n var index = items.selected.indexOf(name);\n\n // If selected, we want to unselect it\n if ($(event.target).hasClass(client.selectedClass)) {\n $(event.target).removeClass(client.selectedClass);\n $(event.target).attr(\"style\", \"\");\n client.items.selected.splice(index, 1);\n\n // If unselected, we want to select it\n } else {\n $(event.target).attr(\"style\", \"background:\" + client.selectedColor);\n $(event.target).addClass(client.selectedClass);\n client.items.selected.push(name)\n }\n client.bingoCheck()\n }", "function resultsMouseDownHandler (e) {\n let target = e.target; // Type depends ..\n let className = target.className;\n//console.log(\"Result mouse down event: \"+e.type+\" button: \"+e.button+\" shift: \"+e.shiftKey+\" target: \"+target+\" class: \"+className);\n if ((className != undefined) && (className.length > 0)) {\n\t// The click target is one of .brow cell,\n\t// .rbkmkitem_x div, .rtwistieac div, favicon img or .favttext span\n\t// Find cell, for selection\n\tlet cell;\n\tif (className.includes(\"fav\") || className.startsWith(\"rtwistie\")) {\n\t cell = target.parentElement.parentElement;\n\t}\n\telse if (className.startsWith(\"rbkmkitem_\")) {\n\t cell = target.parentElement;\n\t}\n\telse if (className.includes(\"brow\")) {\n\t cell = target;\n\t}\n\n\t// Select result item if recognized\n\t// , and if not already selected=> keep bigger multi-items selection area if right click inside it \n\tif (cell != undefined) {\n\t let button = e.button;\n\t // Do nothing on selection if this is a right click inside a selection range\n\t if ((button != 2) || !cell.classList.contains(rselection.selectHighlight)) {\n//\t\tsetCellHighlight(rcursor, rlastSelOp, cell, rselection.selectIds);\n\t\tif (button == 1) { // If middle click, simple select, no multi-select\n\t\t addCellCursorSelection(cell, rcursor, rselection);\n\t\t}\n\t\telse {\n\t\t let is_ctrlKey = (isMacOS ? e.metaKey : e.ctrlKey);\n\t\t addCellCursorSelection(cell, rcursor, rselection, true, is_ctrlKey, e.shiftKey);\n\t\t}\n\t }\n\t}\n }\n}", "set_selected_items(top, left, width, height) {\n this.selection_items.forEach((selected_item, item_index) => {\n if (this.is_element_selected(selected_item.element, top, left, width, height)) {\n selected_item.element.classList.add(this.options.selected_class_name);\n this.selection_items[item_index].is_selected = true;\n } else {\n if (selected_item.is_selected) {\n selected_item.element.classList.add(this.options.selected_class_name);\n this.selection_items[item_index].is_selected = true;\n return;\n }\n }\n });\n }", "function defaultScrollHelper(e, $container, startIndex, isSelectionRetained) {\r\n\t\tif (e.type == \"mouseover\") {\r\n\t\t\t/* on mouse down and than mouse over */\r\n\t\t\tvar $childTarget = $(e.target);\r\n\t\t\tif ($container[0] != $childTarget.parent()[0]) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t\tdefaultScrollHelperUtils.stopTimer();\r\n\t\t\t$container.drawMultipleSelectBox(startIndex, $childTarget.getMultipleSelectBoxRowIndex($container), {\r\n\t\t\t\t\"isSelectionRetained\": isSelectionRetained,\r\n\t\t\t\t\"scrollPos\": null\r\n\t\t\t});\r\n\t\t} else if (e.type == \"mouseup\") {\r\n\t\t\t/* on mouse down and than mouse up */\r\n\t\t\tdefaultScrollHelperUtils.stopTimer();\r\n\t\t} else if (e.type == \"mouseleave\") {\r\n\t\t\t/* on mouse down and than mouse leave */\r\n\t\t} else if (e.type == \"mousemove\") {\r\n\t\t\t/* on mouse down and than mouse leave and moving */\r\n\t\t\tvar options = $container.getMultipleSelectBoxOptions();\r\n\t\t\tvar isHorizontalMode = options.isHorizontalMode;\r\n\t\t\tdefaultScrollHelperUtils.mousePos = (isHorizontalMode ? e.pageX : e.pageY);\r\n\t\t\tdefaultScrollHelperUtils.startTimer(function() {\r\n\t\t\t\tvar containerViewport = $container.getMultipleSelectBoxViewport();\r\n\t\t\t\tvar containerBackPos = containerViewport.getTopPos();\r\n\t\t\t\tvar containerFrontPos = containerViewport.getBottomPos();\r\n\t\t\t\tvar containerScrollPos = containerViewport.getScrollTop();\r\n\t\t\t\tvar containerVisibleRange = containerViewport.getHeight();\r\n\t\t\t\tif (isHorizontalMode) {\r\n\t\t\t\t\tcontainerBackPos = containerViewport.getLeftPos();\r\n\t\t\t\t\tcontainerFrontPos = containerViewport.getRightPos();\r\n\t\t\t\t\tcontainerScrollPos = containerViewport.getScrollLeft();\r\n\t\t\t\t\tcontainerVisibleRange = containerViewport.getWidth();\r\n\t\t\t\t}\r\n\t\t\t\tvar scrollToPos = containerScrollPos;\r\n\t\t\t\tvar targetPos = scrollToPos;\r\n\t\t\t\tvar scrollSpeed = options.scrollSpeed;\r\n\t\t\t\t/* mousemove event is triggered when mouse out of the box only */\r\n\t\t\t\tvar mousePos = defaultScrollHelperUtils.mousePos;\r\n\t\t\t\tif (mousePos < containerBackPos) {\r\n\t\t\t\t\tscrollToPos -= scrollSpeed;\r\n\t\t\t\t\ttargetPos = scrollToPos;\r\n\t\t\t\t} else if (mousePos > containerFrontPos) {\r\n\t\t\t\t\tscrollToPos += scrollSpeed;\r\n\t\t\t\t\ttargetPos = scrollToPos + containerVisibleRange;\r\n\t\t\t\t}\r\n\t\t\t\t/* calculate cuurentIndex */\r\n\t\t\t\t$container.drawMultipleSelectBox(startIndex, calculateScrollHelperCurrentIndex($container, targetPos), {\r\n\t\t\t\t\t\"isSelectionRetained\": isSelectionRetained,\r\n\t\t\t\t\t\"scrollPos\": scrollToPos\r\n\t\t\t\t});\r\n\t\t\t}, 100);\r\n\t\t}\r\n\t}", "function drag(e){\ndraggedItem=e.target;\ndragging=true;\n}", "onMultiSelectionComponentPress(event) {\n if (this.isInactive) {\n return;\n }\n this.fireEvent(\"_selection-requested\", {\n item: this,\n selected: event.target.checked,\n selectionComponentPressed: true\n });\n }", "function dragAction() {\n $(\".content-list\").selectable({\n selected: function(event, ui) {\n docListTools();\n },\n unselecting: function(event, ui) {\n docListTools();\n }\n });\n\n $(\".content-list\").find(\".folder\").draggable({\n revert: 'false',\n helper: function(event) {\n var $group = $(\"<div>\", {\n class: \"content-list\"\n });\n if ($(\".folder.ui-selected\").length) {\n var theClone = $(\".folder.ui-selected\").clone();\n theClone = $group.html(theClone);\n } else {\n theClone = $group.html($(this).clone());\n }\n return theClone;\n }\n });\n $(\".content-list\").find(\".data-folder\").droppable({\n tolerance: 'pointer',\n drop: function(event, ui) {\n var dragId = ui.draggable.attr(\"data-id\");\n var dragType = ui.draggable.attr(\"data-type\");\n var dropId = $(this).attr(\"data-id\");\n // relocate(dragId, dragType, dropId);\n if ($(\".folder.ui-selected\").length) {\n $(\".folder.ui-selected\").remove();\n } else {\n ui.draggable.remove();\n }\n\n $(this).removeClass(\"over-now\");\n },\n over: function(event, ui) {\n $(this).addClass(\"over-now\");\n },\n out: function(event, ui) {\n $(this).removeClass(\"over-now\");\n }\n });\n}", "function drop_allow(event) {\n u(event.target.parentElement).closest('tr').addClass(\"drop-allow\");\n}", "function clickHandler( event /*: JQueryEventObject */ ) {\n if ( $element.hasClass( pausedDragSelectClass ) ) return;\n if ( $element[0].dragData.firstX == $element[0].dragData.lastX\n && $element[0].dragData.firstY == $element[0].dragData.lastY ) {\n if ( $element.hasClass( SELECTED_FOR_DRAGGING_CLASS ) ) {\n $element.removeDragAndSizeSelection();\n } else {\n $element.addDragAndSizeSelection();\n }\n setTimeout( function () {\n var mouseMoveEvent = $.Event( 'mousemove' );\n mouseMoveEvent.pageX = event.pageX;\n mouseMoveEvent.pageY = event.pageY;\n $element.trigger( mouseMoveEvent );\n }, 0 );\n }\n }", "function clicked(element)\n{\n // Add classes to the elements\n element.className += selectedClass;\n element.firstElementChild.className += childSelectedClass;\n element.className += selectedHoverClass;\n // If prevElement exists, remove the classes\n if (prevElement)\n {\n removeSelectedClass(prevElement);\n }\n\n // Assign the previous clicked element to the newPrevElement\n prevElement = element;\n}", "function SelectionManager() {\n\tvar t = this;\n\t\n\t\n\t// exports\n\tt.select = select;\n\tt.unselect = unselect;\n\tt.reportSelection = reportSelection;\n\tt.daySelectionMousedown = daySelectionMousedown;\n\t\n\t\n\t// imports\n\tvar opt = t.opt;\n\tvar trigger = t.trigger;\n\tvar defaultSelectionEnd = t.defaultSelectionEnd;\n\tvar renderSelection = t.renderSelection;\n\tvar clearSelection = t.clearSelection;\n\t\n\t\n\t// locals\n\tvar selected = false;\n\n\n\n\t// unselectAuto\n\tif (opt('selectable') && opt('unselectAuto')) {\n\t\t$(document).mousedown(function(ev) {\n\t\t\tvar ignore = opt('unselectCancel');\n\t\t\tif (ignore) {\n\t\t\t\tif ($(ev.target).parents(ignore).length) { // could be optimized to stop after first match\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t\tunselect(ev);\n\t\t});\n\t}\n\t\n\n\tfunction select(startDate, endDate, allDay) {\n\t\tunselect();\n\t\tif (!endDate) {\n\t\t\tendDate = defaultSelectionEnd(startDate, allDay);\n\t\t}\n\t\trenderSelection(startDate, endDate, allDay);\n\t\treportSelection(startDate, endDate, allDay);\n\t}\n\t\n\t\n\tfunction unselect(ev) {\n\t\tif (selected) {\n\t\t\tselected = false;\n\t\t\tclearSelection();\n\t\t\ttrigger('unselect', null, ev);\n\t\t}\n\t}\n\t\n\t\n\tfunction reportSelection(startDate, endDate, allDay, ev) {\n\t\tselected = true;\n\t\ttrigger('select', null, startDate, endDate, allDay, ev);\n\t}\n\t\n\t\n\tfunction daySelectionMousedown(ev) { // not really a generic manager method, oh well\n\t\tvar cellToDate = t.cellToDate;\n\t\tvar getIsCellAllDay = t.getIsCellAllDay;\n\t\tvar hoverListener = t.getHoverListener();\n\t\tvar reportDayClick = t.reportDayClick; // this is hacky and sort of weird\n\t\tif (ev.which == 1 && opt('selectable')) { // which==1 means left mouse button\n\t\t\tunselect(ev);\n\t\t\tvar _mousedownElement = this;\n\t\t\tvar dates;\n\t\t\thoverListener.start(function(cell, origCell) { // TODO: maybe put cellToDate/getIsCellAllDay info in cell\n\t\t\t\tclearSelection();\n\t\t\t\tif (cell && getIsCellAllDay(cell)) {\n\t\t\t\t\tdates = [ cellToDate(origCell), cellToDate(cell) ].sort(dateCompare);\n\t\t\t\t\trenderSelection(dates[0], dates[1], true);\n\t\t\t\t}else{\n\t\t\t\t\tdates = null;\n\t\t\t\t}\n\t\t\t}, ev);\n\t\t\t$(document).one('mouseup', function(ev) {\n\t\t\t\thoverListener.stop();\n\t\t\t\tif (dates) {\n\t\t\t\t\tif (+dates[0] == +dates[1]) {\n\t\t\t\t\t\treportDayClick(dates[0], true, ev);\n\t\t\t\t\t}\n\t\t\t\t\treportSelection(dates[0], dates[1], true, ev);\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t}\n\n\n}", "function SelectionManager() {\n\tvar t = this;\n\t\n\t\n\t// exports\n\tt.select = select;\n\tt.unselect = unselect;\n\tt.reportSelection = reportSelection;\n\tt.daySelectionMousedown = daySelectionMousedown;\n\t\n\t\n\t// imports\n\tvar opt = t.opt;\n\tvar trigger = t.trigger;\n\tvar defaultSelectionEnd = t.defaultSelectionEnd;\n\tvar renderSelection = t.renderSelection;\n\tvar clearSelection = t.clearSelection;\n\t\n\t\n\t// locals\n\tvar selected = false;\n\n\n\n\t// unselectAuto\n\tif (opt('selectable') && opt('unselectAuto')) {\n\t\t$(document).mousedown(function(ev) {\n\t\t\tvar ignore = opt('unselectCancel');\n\t\t\tif (ignore) {\n\t\t\t\tif ($(ev.target).parents(ignore).length) { // could be optimized to stop after first match\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t\tunselect(ev);\n\t\t});\n\t}\n\t\n\n\tfunction select(startDate, endDate, allDay) {\n\t\tunselect();\n\t\tif (!endDate) {\n\t\t\tendDate = defaultSelectionEnd(startDate, allDay);\n\t\t}\n\t\trenderSelection(startDate, endDate, allDay);\n\t\treportSelection(startDate, endDate, allDay);\n\t}\n\t\n\t\n\tfunction unselect(ev) {\n\t\tif (selected) {\n\t\t\tselected = false;\n\t\t\tclearSelection();\n\t\t\ttrigger('unselect', null, ev);\n\t\t}\n\t}\n\t\n\t\n\tfunction reportSelection(startDate, endDate, allDay, ev) {\n\t\tselected = true;\n\t\ttrigger('select', null, startDate, endDate, allDay, ev);\n\t}\n\t\n\t\n\tfunction daySelectionMousedown(ev) { // not really a generic manager method, oh well\n\t\tvar cellToDate = t.cellToDate;\n\t\tvar getIsCellAllDay = t.getIsCellAllDay;\n\t\tvar hoverListener = t.getHoverListener();\n\t\tvar reportDayClick = t.reportDayClick; // this is hacky and sort of weird\n\t\tif (ev.which == 1 && opt('selectable')) { // which==1 means left mouse button\n\t\t\tunselect(ev);\n\t\t\tvar _mousedownElement = this;\n\t\t\tvar dates;\n\t\t\thoverListener.start(function(cell, origCell) { // TODO: maybe put cellToDate/getIsCellAllDay info in cell\n\t\t\t\tclearSelection();\n\t\t\t\tif (cell && getIsCellAllDay(cell)) {\n\t\t\t\t\tdates = [ cellToDate(origCell), cellToDate(cell) ].sort(dateCompare);\n\t\t\t\t\trenderSelection(dates[0], dates[1], true);\n\t\t\t\t}else{\n\t\t\t\t\tdates = null;\n\t\t\t\t}\n\t\t\t}, ev);\n\t\t\t$(document).one('mouseup', function(ev) {\n\t\t\t\thoverListener.stop();\n\t\t\t\tif (dates) {\n\t\t\t\t\tif (+dates[0] == +dates[1]) {\n\t\t\t\t\t\treportDayClick(dates[0], true, ev);\n\t\t\t\t\t}\n\t\t\t\t\treportSelection(dates[0], dates[1], true, ev);\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t}\n\n\n}", "function SelectionManager() {\n\tvar t = this;\n\t\n\t\n\t// exports\n\tt.select = select;\n\tt.unselect = unselect;\n\tt.reportSelection = reportSelection;\n\tt.daySelectionMousedown = daySelectionMousedown;\n\t\n\t\n\t// imports\n\tvar opt = t.opt;\n\tvar trigger = t.trigger;\n\tvar defaultSelectionEnd = t.defaultSelectionEnd;\n\tvar renderSelection = t.renderSelection;\n\tvar clearSelection = t.clearSelection;\n\t\n\t\n\t// locals\n\tvar selected = false;\n\n\n\n\t// unselectAuto\n\tif (opt('selectable') && opt('unselectAuto')) {\n\t\t$(document).mousedown(function(ev) {\n\t\t\tvar ignore = opt('unselectCancel');\n\t\t\tif (ignore) {\n\t\t\t\tif ($(ev.target).parents(ignore).length) { // could be optimized to stop after first match\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t\tunselect(ev);\n\t\t});\n\t}\n\t\n\n\tfunction select(startDate, endDate, allDay) {\n\t\tunselect();\n\t\tif (!endDate) {\n\t\t\tendDate = defaultSelectionEnd(startDate, allDay);\n\t\t}\n\t\trenderSelection(startDate, endDate, allDay);\n\t\treportSelection(startDate, endDate, allDay);\n\t}\n\t\n\t\n\tfunction unselect(ev) {\n\t\tif (selected) {\n\t\t\tselected = false;\n\t\t\tclearSelection();\n\t\t\ttrigger('unselect', null, ev);\n\t\t}\n\t}\n\t\n\t\n\tfunction reportSelection(startDate, endDate, allDay, ev) {\n\t\tselected = true;\n\t\ttrigger('select', null, startDate, endDate, allDay, ev);\n\t}\n\t\n\t\n\tfunction daySelectionMousedown(ev) { // not really a generic manager method, oh well\n\t\tvar cellToDate = t.cellToDate;\n\t\tvar getIsCellAllDay = t.getIsCellAllDay;\n\t\tvar hoverListener = t.getHoverListener();\n\t\tvar reportDayClick = t.reportDayClick; // this is hacky and sort of weird\n\t\tif (ev.which == 1 && opt('selectable')) { // which==1 means left mouse button\n\t\t\tunselect(ev);\n\t\t\tvar _mousedownElement = this;\n\t\t\tvar dates;\n\t\t\thoverListener.start(function(cell, origCell) { // TODO: maybe put cellToDate/getIsCellAllDay info in cell\n\t\t\t\tclearSelection();\n\t\t\t\tif (cell && getIsCellAllDay(cell)) {\n\t\t\t\t\tdates = [ cellToDate(origCell), cellToDate(cell) ].sort(dateCompare);\n\t\t\t\t\trenderSelection(dates[0], dates[1], true);\n\t\t\t\t}else{\n\t\t\t\t\tdates = null;\n\t\t\t\t}\n\t\t\t}, ev);\n\t\t\t$(document).one('mouseup', function(ev) {\n\t\t\t\thoverListener.stop();\n\t\t\t\tif (dates) {\n\t\t\t\t\tif (+dates[0] == +dates[1]) {\n\t\t\t\t\t\treportDayClick(dates[0], true, ev);\n\t\t\t\t\t}\n\t\t\t\t\treportSelection(dates[0], dates[1], true, ev);\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t}\n\n\n}", "activeClick() {\n var $_this = this;\n var action = this.options.dblClick ? 'dblclick' : 'click';\n\n this.$selectableUl.on(action, '.SELECT-elem-selectable', function () {\n $_this.select($(this).data('SELECT-value'));\n });\n this.$selectionUl.on(action, '.SELECT-elem-selection', function () {\n $_this.deselect($(this).data('SELECT-value'));\n });\n\n }", "function extractEvents$3(dispatchQueue,domEventName,targetInst,nativeEvent,nativeEventTarget,eventSystemFlags,targetContainer){var targetNode=targetInst?getNodeFromInstance(targetInst):window;switch(domEventName){// Track the input node that has focus.\ncase'focusin':if(isTextInputElement(targetNode)||targetNode.contentEditable==='true'){activeElement$1=targetNode;activeElementInst$1=targetInst;lastSelection=null;}break;case'focusout':activeElement$1=null;activeElementInst$1=null;lastSelection=null;break;// Don't fire the event while the user is dragging. This matches the\n// semantics of the native select event.\ncase'mousedown':mouseDown=true;break;case'contextmenu':case'mouseup':case'dragend':mouseDown=false;constructSelectEvent(dispatchQueue,nativeEvent,nativeEventTarget);break;// Chrome and IE fire non-standard event when selection is changed (and\n// sometimes when it hasn't). IE's event fires out of order with respect\n// to key and input events on deletion, so we discard it.\n//\n// Firefox doesn't support selectionchange, so check selection status\n// after each key entry. The selection changes after keydown and before\n// keyup, but we check on keydown as well in the case of holding down a\n// key, when multiple keydown events are fired but only one keyup is.\n// This is also our approach for IE handling, for the reason above.\ncase'selectionchange':if(skipSelectionChangeEvent){break;}// falls through\ncase'keydown':case'keyup':constructSelectEvent(dispatchQueue,nativeEvent,nativeEventTarget);}}", "function extractEvents$3(dispatchQueue,domEventName,targetInst,nativeEvent,nativeEventTarget,eventSystemFlags,targetContainer){var targetNode=targetInst?getNodeFromInstance(targetInst):window;switch(domEventName){// Track the input node that has focus.\ncase'focusin':if(isTextInputElement(targetNode)||targetNode.contentEditable==='true'){activeElement$1=targetNode;activeElementInst$1=targetInst;lastSelection=null;}break;case'focusout':activeElement$1=null;activeElementInst$1=null;lastSelection=null;break;// Don't fire the event while the user is dragging. This matches the\n// semantics of the native select event.\ncase'mousedown':mouseDown=true;break;case'contextmenu':case'mouseup':case'dragend':mouseDown=false;constructSelectEvent(dispatchQueue,nativeEvent,nativeEventTarget);break;// Chrome and IE fire non-standard event when selection is changed (and\n// sometimes when it hasn't). IE's event fires out of order with respect\n// to key and input events on deletion, so we discard it.\n//\n// Firefox doesn't support selectionchange, so check selection status\n// after each key entry. The selection changes after keydown and before\n// keyup, but we check on keydown as well in the case of holding down a\n// key, when multiple keydown events are fired but only one keyup is.\n// This is also our approach for IE handling, for the reason above.\ncase'selectionchange':if(skipSelectionChangeEvent){break;}// falls through\ncase'keydown':case'keyup':constructSelectEvent(dispatchQueue,nativeEvent,nativeEventTarget);}}", "toggSelAll (c, direct) {\r\n const O = this;\r\n const cloneOriginalEvents = $.extend(true, {}, $._data(O.E.get(0), \"events\")); // clone original select elements events\r\n O.E.off(); // unbind original select elements events because we do not want the following clicks to trigger change on it\r\n\r\n if (O.is_multi) {\r\n // Select all\r\n if (c) {\r\n O.E.find('option:not(:checked):not(:disabled):not(:hidden)').toArray().forEach(option => {\r\n if (!$(option).data('li').hasClass('hidden')) {\r\n option.selected = true;\r\n $(option).data('li').toggleClass('selected', true);\r\n }\r\n });\r\n } else {\r\n // Unselect all\r\n O.E.find('option:checked:not(:disabled):not(:hidden)').toArray().forEach(option => {\r\n if (!$(option).data('li').hasClass('hidden')) {\r\n option.selected = false;\r\n $(option).data('li').toggleClass('selected', false);\r\n }\r\n });\r\n }\r\n } else {\r\n if (!c) O.E[0].selectedIndex = -1;\r\n else console.warn('You called `SelectAll` on a non-multiple select');\r\n }\r\n\r\n // rebind original select elements events\r\n $.each(cloneOriginalEvents, (_, e) => {\r\n $.each(e, (__, ev) => {\r\n O.E.on(ev.type, ev.handler);\r\n });\r\n });\r\n\r\n if((O.is_multi && !settings.okCancelInMulti) || !O.is_multi){\r\n O.callChange(); // call change on original select element\r\n O.setText();\r\n }\r\n\r\n if (!direct) {\r\n if (!O.mob && O.selAll) O.selAll.removeClass('partial').toggleClass('selected', !!c);\r\n O.setText();\r\n O.setPstate();\r\n }\r\n }", "function initializeMultipleSelectBoxTouchEvent($container) {\r\n\t\t$container.bind(\"touchstart.\" + PLUGIN_NAMESPACE, function(e) {\r\n\t\t\tvar options = $container.getMultipleSelectBoxOptions();\r\n\t\t\tvar containerViewport = $container.getMultipleSelectBoxViewport();\r\n\t\t\tvar startTouches = e.originalEvent.touches[0];\r\n\t\t\tvar startTouchPos = startTouches.pageY;\r\n\t\t\tvar startContainerScrollPos = containerViewport.getScrollTop();\r\n\t\t\tif (options.isHorizontalMode) {\r\n\t\t\t\tstartTouchPos = startTouches.pageX;\r\n\t\t\t\tstartContainerScrollPos = containerViewport.getScrollLeft();\r\n\t\t\t}\r\n\t\t\t$container.yieldMultipleSelectBox().bind(\"touchmove.\" + PLUGIN_NAMESPACE, function(e1) {\r\n\t\t\t\t/* disable touch scroll */\r\n\t\t\t\te1.preventDefault();\r\n\t\t\t\t/* calculate scroll to position */\r\n\t\t\t\tvar thisTouches = e1.originalEvent.touches[0];\r\n\t\t\t\tif (options.isHorizontalMode) {\r\n\t\t\t\t\t$container.scrollLeft(startContainerScrollPos + (thisTouches.pageX - startTouchPos));\r\n\t\t\t\t} else {\r\n\t\t\t\t\t$container.scrollTop(startContainerScrollPos + (thisTouches.pageY - startTouchPos));\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t});\r\n\t}", "function SelectionUtil() {\n}", "function customizeMultiSelect(){\n /* IE doesn't support event handling on option tag, hence conveted option click event to select onchange event*/\n $('body').on('change','.customize_multiselect', function(){\n var select = $(this);\n var sel_val = $(this).val();\n var sel_opt = '';\n $(select).find(\"option\").each(function () {\n if($(this).val() == sel_val){\n sel_opt = $(this);\n return;\n }\n });\n if ($(sel_opt).attr(\"class\") == undefined || $(sel_opt).attr(\"class\").length == 0 || $(sel_opt).hasClass(\"unclicked\")){\n $(sel_opt).removeClass('unclicked');\n $(sel_opt).addClass('clicked');\n } else {\n $(sel_opt).removeClass('clicked')\n $(sel_opt).addClass('unclicked');\n $(sel_opt).removeAttr(\"selected\");\n }\n $(select).find(\"option.clicked\").attr(\"selected\",\"selected\");\n $(select).find(\"option.unclicked\").removeAttr(\"selected\");\n });\n}", "function initializeMultiCheckboxSelection() {\n // Add event listener on li element instead of directly to checkbox in order to allow shift click in firefox.\n // A click on checkboxes in firefox is not triggered, if a modifier is active (shift, alt, ctrl)\n const doesProvideMod = !(navigator.userAgent.indexOf(\"Firefox\") >= 0);\n $('#imageList>li').on('click', (doesProvideMod ? 'input[type=\"checkbox\"]' : 'label'), function(event) {\n const checkbox = doesProvideMod ? this : $(this).siblings('input[type=\"checkbox\"]')[0];\n if( !lastChecked ) {\n lastChecked = checkbox;\n return;\n }\n\n if( event.shiftKey ) {\n var checkBoxes = $('#imageList input[type=\"checkbox\"]').not('#selectFilter');\n var start = $(checkBoxes).index($(checkbox));\n var end = $(checkBoxes).index($(lastChecked));\n\n $(checkBoxes).slice(Math.min(start, end), Math.max(start, end) + 1).prop('checked', $(lastChecked).is(':checked'));\n }\n\n $(checkbox).change();\n lastChecked = checkbox;\n });\n}", "function selectable(options) {\r\n\treturn this.each(function () {\r\n\t\tvar elem = this;\r\n\t\tvar $elem = $(elem);\r\n\t\tif ($elem.hasClass(selectableClass)) return; // Already done\r\n\t\t$elem.addClass(selectableClass);\r\n\t\tvar opt = initOptions(\"selectable\", selectableDefaults, $elem, {}, options);\r\n\t\topt._prepareChild = prepareChild;\r\n\r\n\t\t$elem.children().each(prepareChild);\r\n\t\t\r\n\t\tfunction prepareChild() {\r\n\t\t\tvar child = $(this);\r\n\t\t\tchild.click(function (event) {\r\n\t\t\t\tevent.preventDefault();\r\n\t\t\t\tevent.stopPropagation();\r\n\t\t\t\tlet ctrlKey = !!event.originalEvent.ctrlKey;\r\n\t\t\t\tif (!opt.multi) ctrlKey = false;\r\n\t\t\t\tif (opt.toggle) ctrlKey = true;\r\n\t\t\t\tlet changed = false;\r\n\t\t\t\tif (ctrlKey) {\r\n\t\t\t\t\tchild.toggleClass(\"selected\");\r\n\t\t\t\t\tchanged = true;\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tif (!child.hasClass(\"selected\")) {\r\n\t\t\t\t\t\t$elem.children().removeClass(\"selected\");\r\n\t\t\t\t\t\tchild.addClass(\"selected\");\r\n\t\t\t\t\t\tchanged = true;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\tif (changed) {\r\n\t\t\t\t\t$elem.trigger(\"selectionchange\");\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t}\r\n\t});\r\n}", "function createMultipleSelectRect(e) {\n iv.sMultipleSvg = iv.svg.rect().fill('none').stroke({\n width: 2\n });\n iv.sMultipleSvg.x(e.x);\n iv.sMultipleSvg.y(e.y);\n}", "function eventMakeSelection(d) {\n selected.push(d.elemNum) // Store clicked node's elemNum to \"selected\" array.\n\n if (layout.properties.selectionMode == \"parent\") {\n parent_id = d.parent_id;\n } else if (layout.properties.selectionMode == \"child\" ) {\n my_id = d.id;\n } else {\n // do nothing\n }\n\n if (layout.properties.clearAll) {\n //clear selections\n app.clearAll();\n self.paint($element);\n } else {\n self.paint($element, layout)\n }\n }", "function setCollapsibleEvents() {\n var lists = $(collapsibleClass);\n //Set Drag on Each 'li' in the list\n lists.each(function (index, element) {\n var list = $(element).find('li');\n $.each(list, function (idx, val) {\n $(this).on('dragstart', function (evt) {\n evt.originalEvent.dataTransfer.setData('Text', evt.target.textContent);\n evt.originalEvent.dataTransfer.setData('ID', evt.target.id);\n evt.originalEvent.dataTransfer.setData('Location', 'list');\n });\n });\n });\n }", "function onDragEnter(ev)\n{\n // If a valid item, highlight it as a target\n let target = ev.target;\n if ((target.tagName && target.tagName.search(/^(li|div|span|svg|path)$/i) === 0 ) ||\n target.nodeName.search(/^(#text)$/i) === 0)\n {\n if (!target.tagName)\n target = target.parentNode;\n if (target.tagName.search(/^li$/i) !== 0)\n target = target.closest(\"li\");\n if (target !== null)\n target.className += \" dragging\";\n }\n}", "handleMouseMultiSelect(cellData, event) {\n const me = this,\n id = cellData.id;\n\n function mergeRange(fromId, toId) {\n const {\n store,\n selectedRecordCollection\n } = me,\n fromIndex = store.indexOf(fromId),\n toIndex = store.indexOf(toId),\n startIndex = Math.min(fromIndex, toIndex),\n endIndex = Math.max(fromIndex, toIndex);\n\n if (startIndex === -1 || endIndex === -1) {\n throw new Error('Record not found in selectRange');\n }\n\n const newRange = store.getRange(startIndex, endIndex + 1, false).filter(row => me.isSelectable(row));\n selectedRecordCollection.splice(0, me.lastRange || 0, newRange);\n me.lastRange = newRange;\n }\n\n if ((event.metaKey || event.ctrlKey) && me.isSelected(id)) {\n // ctrl/cmd deselects row if selected\n me.deselectRow(id);\n } else if (me.selectionMode.multiSelect) {\n if (event.shiftKey && me.startCell) {\n // shift appends selected range (if we have previously focused cell)\n mergeRange(me.startCell.id, id);\n } else if (event.ctrlKey || event.metaKey) {\n // ctrl/cmd adds to selection if using multiselect (and not selected)\n me.selectRow({\n record: id,\n scrollIntoView: false,\n addToSelection: true\n });\n }\n }\n }", "function onMouseMoveEventOnHandler(ev){\n if(WorkStore.isSelected()) return;\n\n window.addEventListener(MOUSE_DOWN, onMouseDownHandler);\n document.body.classList.add(\"drag\");\n}", "handleMouseMultiSelect(cellData, event) {\n const me = this,\n id = cellData.id;\n\n function mergeRange(fromId, toId) {\n const { store, recordCollection } = me,\n fromIndex = store.indexOf(fromId),\n toIndex = store.indexOf(toId),\n startIndex = Math.min(fromIndex, toIndex),\n endIndex = Math.max(fromIndex, toIndex);\n\n if (startIndex === -1 || endIndex === -1) {\n throw new Error('Record not found in selectRange');\n }\n\n const newRange = store.getRange(startIndex, endIndex + 1, false).filter((row) => me.isSelectable(row));\n recordCollection.splice(0, me.lastRange || 0, newRange);\n me.lastRange = newRange;\n }\n\n if ((event.metaKey || event.ctrlKey) && me.isSelected(id)) {\n // ctrl/cmd deselects row if selected\n me.deselectRow(id);\n } else if (me.selectionMode.multiSelect) {\n if (event.shiftKey && me.startCell) {\n // shift appends selected range (if we have previously focused cell)\n mergeRange(me.startCell.id, id);\n } else if (event.ctrlKey || event.metaKey) {\n // ctrl/cmd adds to selection if using multiselect (and not selected)\n me.selectRow(id, false, true);\n }\n }\n }", "function onDragLeave(ev)\n{\n // If current is a valid item, stop highlighting it as a target\n let target = ev.target;\n if ((target.tagName && target.tagName.search(/^(li|div|span|svg|path)$/i) === 0 ) ||\n target.nodeName.search(/^(#text)$/i) === 0)\n {\n if (!target.tagName)\n target = target.parentNode;\n if (target.tagName.search(/^li$/i) !== 0)\n target = target.closest(\"li\");\n if (target !== null)\n target.className = target.className.replace(/ dragging\\b/,'');\n }\n}", "_selectedFilesClickHandler(event) {\n const that = this;\n\n if (that.disabled) {\n return;\n }\n\n const target = event.target,\n isItemUploadClicked = target.closest('.jqx-item-upload-button'),\n isItemCancelClicked = target.closest('.jqx-item-cancel-button'),\n isItemAbortClicked = target.closest('.jqx-item-pause-button'),\n clickedItem = target.closest('.jqx-file');\n\n if (isItemUploadClicked) {\n that.uploadFile(clickedItem.index);\n }\n else if (isItemCancelClicked) {\n that.cancelFile(clickedItem.index);\n }\n else if (isItemAbortClicked) {\n that.pauseFile(clickedItem.index);\n }\n }", "onSelectedCollectionChange({ added, removed }) {\n const me = this,\n selection = me.selectedEvents,\n selected = added || [],\n deselected = removed || [];\n\n function updateSelection(record, select) {\n const resourceRecord = record.isTask ? record : record.resource,\n eventRecord = record.isAssignment ? record.event : record;\n\n if (eventRecord) {\n const element = me.getElementFromEventRecord(eventRecord, resourceRecord);\n\n me.currentOrientation.toggleCls(eventRecord, resourceRecord, me.eventSelectedCls, select);\n\n if (record.isAssignment) {\n me.getElementsFromEventRecord(eventRecord).forEach((el) => {\n if (el !== element) {\n el.classList[select ? 'add' : 'remove'](me.eventAssignHighlightCls);\n }\n });\n }\n }\n }\n\n selected.forEach((record) => updateSelection(record, true));\n deselected.forEach((record) => updateSelection(record, false));\n\n if (!me.silent) {\n me.trigger('eventSelectionChange', {\n action:\n selection.length > 0\n ? selected.length > 0 && deselected.length > 0\n ? 'update'\n : selected.length > 0\n ? 'select'\n : 'deselect'\n : 'clear',\n selection,\n selected,\n deselected\n });\n }\n }", "function dragEnter(e) {\n e.target.closest(\"li\").classList.add(\"over\");\n}", "function dragTarget(){\n //prevent default positon in order to allow drop of element\n var e= event;\n e.preventDefault();\n //move element to selected drop target\n let children= Array.from(e.target.parentNode.parentNode.children);\n if (children.indexOf(e.target.parentNode)>children.indexOf(row)){\n e.target.parentNode.after(row);\n }\n else{\n e.target.parnetNode.before(row);\n }\n }", "function MultiSelector(list_target, max) {\n this.list_target = list_target;this.count = 0;this.id = 0;if( max ){this.max = max;} else {this.max = -1;};this.addElement = function( element ){if( element.tagName == 'INPUT' && element.type == 'file' ){element.name = 'attachment[file_' + (this.id++) + ']';element.multi_selector = this;element.onchange = function(){var new_element = document.createElement( 'input' );new_element.type = 'file';this.parentNode.insertBefore( new_element, this );this.multi_selector.addElement( new_element );this.multi_selector.addListRow( this );this.style.position = 'absolute';this.style.left = '-1000px';};if( this.max != -1 && this.count >= this.max ){element.disabled = true;};this.count++;this.current_element = element;} else {alert( 'Error: not a file input element' );};};this.addListRow = function( element ){var new_row = document.createElement('li');var new_row_button = document.createElement( 'a' );new_row_button.title = 'Remove This Image';new_row_button.href = '#';new_row_button.innerHTML = 'Remove';new_row.element = element;new_row_button.onclick= function(){this.parentNode.element.parentNode.removeChild( this.parentNode.element );this.parentNode.parentNode.removeChild( this.parentNode );this.parentNode.element.multi_selector.count--;this.parentNode.element.multi_selector.current_element.disabled = false;return false;};new_row.innerHTML = element.value.split('/')[element.value.split('/').length - 1];new_row.appendChild( new_row_button );this.list_target.appendChild( new_row );};\n}", "function attachEvents(selection, renderItems) {\r\n var dragBehavior;\r\n \r\n // We want to know all the different types of events that exist in any of the elements. This cryptic oneliner does that.\r\n // Say we have one element with handlers for click and mouseover, and another one with handlers for mouseover and mouseout.\r\n // We will want an array that says [\"click\", \"mouseover\", \"mouseout\"]. We will have to attach all three events to all elements\r\n // because there is no (trivial) way to attach event handlers per element. The handlers will actually be functions that check\r\n // if the given handler exists and only then call it.\r\n var allEvents = _.uniq(_.flatten(_.map(_.pluck(renderItems, \"eventHandlers\"), function (eh) { return _.keys(eh); })));\r\n \r\n // Add all the handlers except for click and dblclick which we take special care of below.\r\n _.each(allEvents, function (ce) {\r\n if (ce === \"click\" || ce === \"dblclick\")\r\n return;\r\n \r\n // drag events aren't native to the browser so we need to attach D3's dragBehavior if such handlers exist.\r\n if (ce === \"dragstart\" || ce === \"drag\" || ce === \"dragend\") {\r\n if (!dragBehavior) {\r\n dragBehavior = d3.behavior.drag()\r\n .origin(function() { \r\n var t = d3.select(this);\r\n return {x: t.attr(\"x\"), y: t.attr(\"y\")};\r\n })\r\n }\r\n \r\n dragBehavior.on(ce, function (d, i) {\r\n d.eventHandlers[ce](d, i, d3.event);\r\n //d3.event.stopPropagation();\r\n });\r\n } else {\r\n selection.on(ce, function (d, i) {\r\n if (d.eventHandlers.hasOwnProperty(ce)) {\r\n d.eventHandlers[ce](d, i, d3.event);\r\n d3.event.stopPropagation();\r\n }\r\n });\r\n }\r\n });\r\n \r\n if (dragBehavior)\r\n selection.call(dragBehavior);\r\n \r\n var doubleClickDelay = 300;\r\n var singleClickTimer;\r\n var storedEvent;\r\n \r\n // Now, as for click and dblclick, we want to make sure they can work together. If only one of them is supplied, there is no problem\r\n // because we can simply attach to that event. However, if both are in use, we need to wait after the first click and see if the user\r\n // indeed meant to double click or not. If no secondary click is recorded within doubleClickDelay milliseconds, it's considered a single click.\r\n selection.on(\"click\", function (d, i) {\r\n if (d.eventHandlers.hasOwnProperty(\"click\") && d.eventHandlers.hasOwnProperty(\"dblclick\")) {\r\n if (singleClickTimer) {\r\n d.eventHandlers.dblclick(d, i, d3.event);\r\n clearTimeout(singleClickTimer);\r\n singleClickTimer = null;\r\n } else {\r\n storedEvent = d3.event;\r\n singleClickTimer = setTimeout(function () {\r\n d.eventHandlers.click(d, i, storedEvent);\r\n singleClickTimer = null;\r\n }, doubleClickDelay);\r\n }\r\n d3.event.stopPropagation();\r\n } else if (d.eventHandlers.hasOwnProperty(\"click\")) {\r\n d.eventHandlers.click(d, i, d3.event);\r\n d3.event.stopPropagation();\r\n }\r\n });\r\n \r\n selection.on(\"dblclick\", function (d, i) {\r\n if (d.eventHandlers.hasOwnProperty(\"dblclick\") && !d.eventHandlers.hasOwnProperty(\"click\")) {\r\n d.eventHandlers.dblclick(d, i, d3.event);\r\n d3.event.stopPropagation();\r\n }\r\n });\r\n }", "function highlightSelectedElements(curSelectedElem, isMultiSelected)\n {\n var iframeContents = _iframe.contents();\n var greenborderElem = $(\"<div class='perc-itool-selected-green-border' style='border:5px solid #A2C437; display:none;position:absolute;z-index:50000;opacity:1;filter:alpha(opacity=100);'></div>\");\n iframeContents.find(\".perc-region:first\").append(greenborderElem);\n greenborderElem.on('click',function(){\n if(curSelectedElem.prev().hasClass(\"perc-itool-selected-elem\") &&\n curSelectedElem.next().hasClass(\"perc-itool-selected-elem\"))\n return;\n clearItoolSelection();\n });\n if(isMultiSelected) {\n greenborderElem.css('border-color','#00afea');\n }\n //Show it and position\n greenborderElem.show();\n greenborderElem.offset({\n \"top\": curSelectedElem.offset().top,\n \"left\": curSelectedElem.offset().left\n }).height(curSelectedElem.innerHeight() -10 ).width(curSelectedElem.innerWidth()-10);\n }", "function SelectionManager() {\n\tvar t = this;\n\t\n\t\n\t// exports\n\tt.select = select;\n\tt.unselect = unselect;\n\tt.reportSelection = reportSelection;\n\tt.daySelectionMousedown = daySelectionMousedown;\n\t\n\t\n\t// imports\n\tvar calendar = t.calendar;\n\tvar opt = t.opt;\n\tvar trigger = t.trigger;\n\tvar defaultSelectionEnd = t.defaultSelectionEnd;\n\tvar renderSelection = t.renderSelection;\n\tvar clearSelection = t.clearSelection;\n\t\n\t\n\t// locals\n\tvar selected = false;\n\n\n\n\t// unselectAuto\n\tif (opt('selectable') && opt('unselectAuto')) {\n\t\t// TODO: unbind on destroy\n\t\t$(document).mousedown(function(ev) {\n\t\t\tvar ignore = opt('unselectCancel');\n\t\t\tif (ignore) {\n\t\t\t\tif ($(ev.target).parents(ignore).length) { // could be optimized to stop after first match\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t\tunselect(ev);\n\t\t});\n\t}\n\t\n\n\tfunction select(start, end) {\n\t\tunselect();\n\n\t\tstart = calendar.moment(start);\n\t\tif (end) {\n\t\t\tend = calendar.moment(end);\n\t\t}\n\t\telse {\n\t\t\tend = defaultSelectionEnd(start);\n\t\t}\n\n\t\trenderSelection(start, end);\n\t\treportSelection(start, end);\n\t}\n\t// TODO: better date normalization. see notes in automated test\n\t\n\t\n\tfunction unselect(ev) {\n\t\tif (selected) {\n\t\t\tselected = false;\n\t\t\tclearSelection();\n\t\t\ttrigger('unselect', null, ev);\n\t\t}\n\t}\n\t\n\t\n\tfunction reportSelection(start, end, ev) {\n\t\tselected = true;\n\t\ttrigger('select', null, start, end, ev);\n\t}\n\t\n\t\n\tfunction daySelectionMousedown(ev) { // not really a generic manager method, oh well\n\t\tvar cellToDate = t.cellToDate;\n\t\tvar getIsCellAllDay = t.getIsCellAllDay;\n\t\tvar hoverListener = t.getHoverListener();\n\t\tvar reportDayClick = t.reportDayClick; // this is hacky and sort of weird\n\n\t\tif (ev.which == 1 && opt('selectable')) { // which==1 means left mouse button\n\t\t\tunselect(ev);\n\t\t\tvar dates;\n\t\t\thoverListener.start(function(cell, origCell) { // TODO: maybe put cellToDate/getIsCellAllDay info in cell\n\t\t\t\tclearSelection();\n\t\t\t\tif (cell && getIsCellAllDay(cell)) {\n\t\t\t\t\tdates = [ cellToDate(origCell), cellToDate(cell) ].sort(dateCompare);\n\t\t\t\t\trenderSelection(\n\t\t\t\t\t\tdates[0],\n\t\t\t\t\t\tdates[1].clone().add('days', 1) // make exclusive\n\t\t\t\t\t);\n\t\t\t\t}else{\n\t\t\t\t\tdates = null;\n\t\t\t\t}\n\t\t\t}, ev);\n\t\t\t$(document).one('mouseup', function(ev) {\n\t\t\t\thoverListener.stop();\n\t\t\t\tif (dates) {\n\t\t\t\t\tif (+dates[0] == +dates[1]) {\n\t\t\t\t\t\treportDayClick(dates[0], ev);\n\t\t\t\t\t}\n\t\t\t\t\treportSelection(\n\t\t\t\t\t\tdates[0],\n\t\t\t\t\t\tdates[1].clone().add('days', 1), // make exclusive\n\t\t\t\t\t\tev\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t}\n\n\n}", "function onMouseMove(event) {\n\t\t\tif (selectEventTarget(event)) {\n\t\t\t\thighlightSelected(true);\n\t\t\t}\n\t\t}", "function drag(event) {\n // if the dragged element is a imgcontainer, highlight it\n if (event.target.tagName === 'DIV' && event.target.classList.contains(\"imgcontainer\")) {\n highlight(event.target);\n }\n // save id and type in dataTransfer\n event.dataTransfer.setData('id', event.target.id);\n event.dataTransfer.setData('type', event.target.tagName);\n}", "function SelectionManager() {\n\tvar t = this;\n\t\n\t\n\t// exports\n\tt.select = select;\n\tt.unselect = unselect;\n\tt.reportSelection = reportSelection;\n\tt.daySelectionMousedown = daySelectionMousedown;\n\tt.selectionManagerDestroy = destroy;\n\t\n\t\n\t// imports\n\tvar calendar = t.calendar;\n\tvar opt = t.opt;\n\tvar trigger = t.trigger;\n\tvar defaultSelectionEnd = t.defaultSelectionEnd;\n\tvar renderSelection = t.renderSelection;\n\tvar clearSelection = t.clearSelection;\n\t\n\t\n\t// locals\n\tvar selected = false;\n\n\n\n\t// unselectAuto\n\tif (opt('selectable') && opt('unselectAuto')) {\n\t\t$(document).on('mousedown', documentMousedown);\n\t}\n\n\n\tfunction documentMousedown(ev) {\n\t\tvar ignore = opt('unselectCancel');\n\t\tif (ignore) {\n\t\t\tif ($(ev.target).parents(ignore).length) { // could be optimized to stop after first match\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t\tunselect(ev);\n\t}\n\t\n\n\tfunction select(start, end) {\n\t\tunselect();\n\n\t\tstart = calendar.moment(start);\n\t\tif (end) {\n\t\t\tend = calendar.moment(end);\n\t\t}\n\t\telse {\n\t\t\tend = defaultSelectionEnd(start);\n\t\t}\n\n\t\trenderSelection(start, end);\n\t\treportSelection(start, end);\n\t}\n\t// TODO: better date normalization. see notes in automated test\n\t\n\t\n\tfunction unselect(ev) {\n\t\tif (selected) {\n\t\t\tselected = false;\n\t\t\tclearSelection();\n\t\t\ttrigger('unselect', null, ev);\n\t\t}\n\t}\n\t\n\t\n\tfunction reportSelection(start, end, ev) {\n\t\tselected = true;\n\t\ttrigger('select', null, start, end, ev);\n\t}\n\t\n\t\n\tfunction daySelectionMousedown(ev) { // not really a generic manager method, oh well\n\t\tvar cellToDate = t.cellToDate;\n\t\tvar getIsCellAllDay = t.getIsCellAllDay;\n\t\tvar hoverListener = t.getHoverListener();\n\t\tvar reportDayClick = t.reportDayClick; // this is hacky and sort of weird\n\n\t\tif (ev.which == 1 && opt('selectable')) { // which==1 means left mouse button\n\t\t\tunselect(ev);\n\t\t\tvar dates;\n\t\t\thoverListener.start(function(cell, origCell) { // TODO: maybe put cellToDate/getIsCellAllDay info in cell\n\t\t\t\tclearSelection();\n\t\t\t\tif (cell && getIsCellAllDay(cell)) {\n\t\t\t\t\tdates = [ cellToDate(origCell), cellToDate(cell) ].sort(dateCompare);\n\t\t\t\t\trenderSelection(\n\t\t\t\t\t\tdates[0],\n\t\t\t\t\t\tdates[1].clone().add('days', 1) // make exclusive\n\t\t\t\t\t);\n\t\t\t\t}else{\n\t\t\t\t\tdates = null;\n\t\t\t\t}\n\t\t\t}, ev);\n\t\t\t$(document).one('mouseup', function(ev) {\n\t\t\t\thoverListener.stop();\n\t\t\t\tif (dates) {\n\t\t\t\t\tif (+dates[0] == +dates[1]) {\n\t\t\t\t\t\treportDayClick(dates[0], ev);\n\t\t\t\t\t}\n\t\t\t\t\treportSelection(\n\t\t\t\t\t\tdates[0],\n\t\t\t\t\t\tdates[1].clone().add('days', 1), // make exclusive\n\t\t\t\t\t\tev\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t}\n\n\n\tfunction destroy() {\n\t\t$(document).off('mousedown', documentMousedown);\n\t}\n\n\n}", "function selectEles(a) {\n for (var i = 0; i < a.length; i++) {\n tds[a[i]].className = 'selected';\n }\n }", "function selectColor(e) {\n e.siblings().removeClass(\"selected\");\n e.addClass(\"selected\");\n }", "function setupKeyboardEvents(parent, canvas, selection) {\n parent.addEventListener(\"keydown\", keydownHandler, false);\n parent.addEventListener(\n \"mousedown\",\n function () {\n parent.focus();\n },\n false\n );\n\n function keydownHandler(evt) {\n var handled = false;\n var mk = multiselect.modifierKeys(evt);\n switch (evt.which) {\n case 37:\n handled = callArrow(mk, multiselect.LEFT);\n break;\n case 38:\n handled = callArrow(mk, multiselect.UP);\n break;\n case 39:\n handled = callArrow(mk, multiselect.RIGHT);\n break;\n case 40:\n handled = callArrow(mk, multiselect.DOWN);\n break;\n case 32:\n handled = callSpace(mk);\n break;\n case 90:\n handled = callUndoRedo(mk);\n break;\n default:\n return; // exit this handler for unrecognized keys\n }\n if (!handled) return;\n\n // event is recognized\n selection.geometry().drawIndicators(selection, canvas, true, true, false);\n evt.preventDefault();\n evt.stopPropagation();\n }\n\n function callUndoRedo(mk) {\n switch (mk) {\n case multiselect.OPT:\n selection.undo();\n break;\n case multiselect.SHIFT_OPT:\n selection.redo();\n break;\n default:\n return false;\n }\n return true;\n }\n\n function callArrow(mk, dir) {\n switch (mk) {\n case multiselect.NONE:\n selection.arrow(dir);\n break;\n case multiselect.CMD:\n selection.cmdArrow(dir);\n break;\n case multiselect.SHIFT:\n selection.shiftArrow(dir);\n break;\n default:\n return false;\n }\n return true;\n }\n\n function callSpace(mk) {\n switch (mk) {\n case multiselect.NONE:\n selection.space();\n break;\n case multiselect.CMD:\n selection.cmdSpace();\n break;\n case multiselect.SHIFT:\n selection.shiftSpace();\n break;\n default:\n return false;\n }\n return true;\n }\n}", "function highlightList(event) {\n // remove previous highlight\n for (var c in catNames) {\n if (catNames[c].classList.contains('selected-cat') === true) {\n catNames[c].classList.remove('selected-cat');\n }\n };\n // highlight name\n event.target.classList.add('selected-cat');\n}", "function updateTouchscreenInputForSelect(element){ \n var inputTarget = tstInputTarget;\n var multiple = inputTarget.getAttribute(\"multiple\") == \"multiple\";\n\n if (multiple) {\n var val_arr = inputTarget.value.split(tstMultipleSplitChar);\n var val = \"\";\n \n if (element.innerHTML.length>1)\n val = unescape(element.innerHTML); \n // njih\n else if (element.value.length>1)\n val = element.value;\n \n // Check if the item is already included\n // var idx = val_arr.toString().indexOf(val);\n if (!tstMultipleSelected[tstCurrentPage][val]){ //(idx == -1){\n val_arr.push(val);\n tstMultipleSelected[tstCurrentPage][val] = true;\n } else {\n // val_arr.splice(idx, 1);\n val_arr = removeFromArray(val_arr, val);\n delete(tstMultipleSelected[tstCurrentPage][val]);\n }\n inputTarget.value = val_arr.join(tstMultipleSplitChar);\n if (inputTarget.value.indexOf(tstMultipleSplitChar) == 0)\n inputTarget.value = inputTarget.value.substring(1, inputTarget.value.length);\n } else {\n if (element.value.length>1){\n inputTarget.value = element.value;\n }\n else if (element.innerHTML.length>0){\n inputTarget.value = element.innerHTML;\n }\n }\n\n highlightSelection(element.parentNode.childNodes, inputTarget)\n \n tt_update(inputTarget);\n}", "function makeSelectable(e) {\n e.setStyle('user-select', 'text');\n e.setStyle('-webkit-user-select', 'text');\n e.setStyle('-moz-user-select', 'text');\n e.setStyle('-o-user-select', 'text');\n e.setStyle('-khtml-user-select', 'text');\n }", "function assignContListClick($target, $ul, clickEvent){\r\n\t$ul.children(\"li\").click(function(){\r\n\t\tsetContSelection($target, $(this));\r\n\t\tif (clickEvent){\r\n\t\t\tclickEvent();\r\n\t\t}\r\n\t});\r\n}", "function CdkDragDrop() {}", "function CdkDragDrop() {}", "function rowSelection(e) {\n var\n // get current HTML row object\n currentRow = this,\n // get current HTML row index\n index = currentRow.offsetTop / (options.rowHeight + options.borderHeight);\n\n if (!options.multiselection)\n // mark all other selected row as unselected \n self.clearSelection();\n\n \n if (! (e.shiftKey || e.metaKey || e.ctrlKey))\n // clear selected row\n self.clearSelection();\n \n if (e.shiftKey && options.multiselection) {\n // Shift is pressed\n var\n _lastSelectedIndex = lastSelectedIndex(),\n // get last selected index\n from = Math.min(_lastSelectedIndex + 1, index),\n to = Math.max(_lastSelectedIndex, index),\n viewPort = getViewPort();\n\n // select all rows between interval\n for (var i = from; i <= to && _currentData[i]; i++) {\n if ($.inArray(i, selectedIndexes()) == -1) {\n selectRow(i);\n if (i >= viewPort.from && i <= viewPort.to) {\n var row = self.rowAt(i);\n $self.trigger('rowSelection', [i, row, true, _currentData[i]]);\n }\n }\n }\n\n } else if (e.ctrlKey || e.metaKey) {\n /* Ctrl is pressed ( CTRL on Mac is identified by metaKey property ) */\n\n // toggle selection\n if ( $.inArray( index, selectedIndexes() ) > -1) {\n unselectRow(index);\n $self.trigger('rowSelection', [index, this, false, _currentData[index]]);\n } else {\n selectRow(index);\n $self.trigger('rowSelection', [index, this, true, _currentData[index]]);\n }\n\n } else {\n // simple click\n selectRow(index);\n $self.trigger('rowSelection', [index, this, true, _currentData[index]]);\n }\n\n }", "enableUserSelection() {\n this[addDivListener]('mousedown', this[userSelectionDragListenerSym]);\n }", "function makeActiveMultiItem(element) {\n $(element).on('click', function(){\n $(element).removeClass(\"active\");\n $(this).addClass(\"active\");\n });\n}", "function drag(e) {\r\n draggedItem = e.target;\r\n dragging = true;\r\n}", "function batchEventHook(event) \n{\n var elem = event.target;\n\n // Hook for [delete] checkbox range selection.\n if ( isDeleteCheckbox(elem) && (event.button == 0 || event.keyCode == 32) ) {\n if (event.shiftKey && lastClickedCheckbox) {\n selectCheckboxRange(lastClickedCheckbox, elem);\n }\n lastClickedCheckbox = elem;\n }\n}", "function handleMouseDown(evt)\n{\n mylog('Started handleMouseDown with target nodeName '+evt.target.nodeName);\n // With svgweb, mousedown on text elements causes also mousedown on\n // the \"svg\" node on the back, so this check nullifies the second\n // function call\n if (evt.target.nodeName == 'svg')\n return;\n // This is necessary with firefox native renderer, otherwise the\n // \"mousedown\" event would cause the attempt of dragging svg\n // elements\n evt.preventDefault();\n\n var p = mouseCoordsSvg(evt);\n\n if(g['shape'].active)\n // When the current tool corresponds to a shape, mouse events are\n // forwarded to the shape\n g['shape'].mousedown(p.x, p.y);\n else{\n // Other tools not binded with shapes, but that act on a\n // clicked shape. First ignore the operation if the target is\n // 'canvas', then retrieve the shape parent group and execute\n // the action\n var target = evt.target;\n if (target.id == 'canvas'){\n mylog('Ignoring attempt to act on the canvas');\n if (g['tool']=='delete')\n // Activate the \"dragging delete\"\n g['active_tool'] = true;\n }\n else{\n // To search the group and then to come back to the childs\n // can look weird, but this is useful because changing the\n // renderer, the element which raises the event (for\n // example in a text structure) may change\n var group = find_group(target.parentNode);\n switch(g['tool']){\n case 'select':\n var shape = group.childNodes[0];\n // Select is useful only for the links, which have\n // 'text' as top node. They can distinguished by plain\n // text elements because they have a first <tspan>\n // element with visibility=\"hidden\"\n if (shape.nodeName == 'text' &&\n shape.childNodes[0].getAttribute('visibility')=='hidden'){\n var url = shape.childNodes[1].data;\n // Urls without the http look nicer, but it has to\n // be added, otherwise they will be taken as\n // relative links\n if (!/http/.test(url))\n url = 'http://'+url;\n window.open(url);\n }\n break;\n case 'edit':\n var shape = group.childNodes[0];\n // Paths can't be edited\n if (shape.nodeName == 'path')\n mylog('Ignoring attempt to edit a path');\n else{\n // Distinguish a 'link' shape\n if (shape.nodeName == 'text' &&\n shape.childNodes[0].getAttribute('visibility')=='hidden')\n var shape_name = 'link';\n else\n var shape_name = shape.nodeName;\n show_additional_panel(shape_name);\n // Copy the old object\n g['shape'] = g['shape_generator'].generate_shape(shape_name);\n g['shape'].copy_shape(shape);\n g['shape'].mousedown(p.x, p.y);\n // Delete the old object: sender_add is called\n // with the asynchronous flag set to true, so the\n // delete update will be sent together with the\n // new shape update.\n var group_id = group.getAttribute('id');\n sender_add('delete', [], group_id, true);\n g['pages'].remove(group);\n }\n break;\n case 'delete':\n delete_object(group);\n g['active_tool'] = true;\n break;\n case 'move':\n g['moving_object'] = group;\n var transMatrix = g['moving_object'].getCTM();\n // g['p'] will be read on mouse up, and to correctly\n // compute the new transformation we must consider the\n // original position of the object, not the one seen\n // by the user and the pointer\n p.x = p.x - Number(transMatrix.e);\n p.y = p.y - Number(transMatrix.f);\n g['active_tool'] = true;\n break;\n }\n }\n }\n // Store the initial mouse position for the other event handlers\n g['p'] = p;\n}", "setEvents(){\n const listElements = this.el.childNodes;\n for(let i = 0; i < listElements.length; i++){\n listElements[i].addEventListener('mousedown',this.onItemClickedEvent,true);\n }\n }", "selectItem (i) { this.toggSel(true, i); }", "function getMoseDownFunc(eventName){return function(ev){ev=ev||window.event;ev.preventDefault?ev.preventDefault():ev.returnValue=false;ev.stopPropagation();var x=ev.pageX||ev.touches[0].pageX;var y=ev.pageY||ev.touches[0].pageY;_this.el.fire(eventName,{x:x,y:y,event:ev});};}// create the selection-rectangle and add the css-class", "function getMoseDownFunc(eventName){return function(ev){ev=ev||window.event;ev.preventDefault?ev.preventDefault():ev.returnValue=false;ev.stopPropagation();var x=ev.pageX||ev.touches[0].pageX;var y=ev.pageY||ev.touches[0].pageY;_this.el.fire(eventName,{x:x,y:y,event:ev});};}// create the selection-rectangle and add the css-class", "function selectCategoryClickHandler(ev) {\n selectCategory(ev.target);\n}", "_handleClick(event) {\n var row = $(event.target).parents('tr:first');\n var rows = this.$element.find('tbody tr');\n\n if (!this.lastChecked) {\n this.lastChecked = row;\n return;\n }\n\n if (event.shiftKey) {\n this.changeMultiple = true;\n\n var start = rows.index(row);\n var end = rows.index(this.lastChecked);\n var from = Math.min(start, end);\n var to = Math.max(start, end) + 1;\n var checked = this.lastChecked.find('input').is(':checked');\n var checkboxes = rows.slice(from, to).find('input');\n\n if (checked) {\n checkboxes.trigger('check.zf.trigger');\n } else {\n checkboxes.trigger('uncheck.zf.trigger');\n }\n\n this.changeMultiple = false;\n }\n\n this.lastChecked = row;\n }", "_isDragStartInSelection(ev) {\n const selectedElements = this.root.querySelectorAll('[data-is-selected]');\n for (let i = 0; i < selectedElements.length; i++) {\n const element = selectedElements[i];\n const itemRect = element.getBoundingClientRect();\n if (this._isPointInRectangle(itemRect, { left: ev.clientX, top: ev.clientY })) {\n return true;\n }\n }\n return false;\n }", "function selectItem(e) {\n\n for (var i = 0; i < e.currentTarget.parentNode.children.length; i++) {\n e.currentTarget.parentNode.children[i].classList.remove(\"selected\");\n }\n\n e.currentTarget.classList.add(\"selected\");\n console.log($(e.currentTarget).children().eq(1).text());\n updateP1Moves($(e.currentTarget).children().eq(1).text());\n \n}", "function handleCheckboxClick(e, highlightClass) {\n\n // if e is an input checkbox, then parentNode is a list element, its and parentNode is an\n // unordered list. Getting all of the tags by \"input\" will therefore return all of the related\n // inputs in this respective list\n var inputs = e.parentNode.parentNode.getElementsByTagName(\"input\");\n\n // The following block handles the checkbox lists that contain \"Any [items].\" If the user\n // selects anything other than \"Any [item]\", then \"Any...\" must be deselected. Otherwise,\n // if the user selects \"Any...\" then all other items currently checked must be deselected. In\n // each group of checkboxes, the \"Any...\" option is represented with an empty string value (\"\").\n\n if (e.value == \"\") { // If the user clicked the \"Any...\" checkbox\n for (var j = 0; j < inputs.length; j++) { // loop through all of this list's checkboxes\n if (inputs[j].value != \"\" && inputs[j].checked) { // if any item (other than \"Any...\") is checked\n inputs[j].checked = \"\"; // uncheck it and\n inputs[j].parentNode.className = \"\"; // unhighlight it\n }\n }\n } else { // Otherwise, the user clicked another checkbox\n for (var i = 0; i < inputs.length; i++) { // loop through this list's checkboxes\n if (inputs[i].value == \"\" && inputs[i].checked) { // find the \"Any...\" checkbox\n inputs[i].checked = \"\"; // uncheck it\n inputs[i].parentNode.className = \"\"; // unhighlight it\n }\n }\n }\n\n // Finally, perform simple highlighting\n if (!e.checked)\n e.parentNode.className = \"\";\n else\n e.parentNode.className = highlightClass;\n}", "isMultipleSelection() {\n return this._multiple;\n }", "onEventSelectionClick(event, clickedRecord) {\n const me = this;\n\n // Multi selection: CTRL means preserve selection, just add or remove the event.\n // Single selection: CTRL deselects already selected event\n if (me.isEventSelected(clickedRecord)) {\n event.ctrlKey && me.deselectEvent(clickedRecord, me.multiEventSelect);\n } else {\n me.selectEvent(clickedRecord, event.ctrlKey && me.multiEventSelect);\n }\n }", "function addSelection(item) {\n //if the owner reference is still null, set it to this item's parent\n //so that further selection is only allowed within the same container\n if (!selections.owner) {\n selections.owner = item.parentNode;\n }\n\n //or if that's already happened then compare it with this item's parent\n //and if they're not the same container, return to prevent selection\n else if (selections.owner != item.parentNode) {\n return;\n }\n\n //set this item's grabbed state\n item.setAttribute('aria-grabbed', 'true');\n\n //add it to the items array\n selections.items.push(item);\n}", "function validateMultipleSelectBox(e) {\r\n\t\t/* yield event handler */\r\n\t\treturn $(\".\" + PLUGIN_NAMESPACE).yieldMultipleSelectBox().each(\r\n\t\t\tfunction() {\r\n\t\t\t\tvar $container = $(this);\r\n\t\t\t\tvar options = $container.getMultipleSelectBoxOptions();\r\n\t\t\t\tvar containerHistory = $container.getMultipleSelectBoxHistory();\r\n\t\t\t\tif ($container.isMultipleSelectBoxSelecting()) {\r\n\t\t\t\t\t/* reset style */\r\n\t\t\t\t\t$container.removeClass(PLUGIN_STYLE_SELECTING);\r\n\t\t\t\t\tvar selectedRows = $container.getMultipleSelectBoxSelectedRows();\r\n\t\t\t\t\t/* slide up */\r\n\t\t\t\t\tif (options.isPopupMode) {\r\n\t\t\t\t\t\t$container.slideUp(\"slow\");\r\n\t\t\t\t\t}\r\n\t\t\t\t\t/* fire event */\r\n\t\t\t\t\t$container.trigger(\"mouseup.\" + PLUGIN_NAMESPACE);\r\n\t\t\t\t\t/* trigger callback */\r\n\t\t\t\t\tif (options.onSelectEnd != null) {\r\n\t\t\t\t\t\toptions.onSelectEnd.apply($container[0], [ e, selectedRows, containerHistory.selectingStartIndex, containerHistory.selectingCurrentIndex, containerHistory.selectedStartIndex, containerHistory.selectedCurrentIndex ]);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif (options.onSelectChange != null && (containerHistory.selectedRows == null || !isJQueryCollectionEquals(containerHistory.selectedRows, selectedRows))) {\r\n\t\t\t\t\t\toptions.onSelectChange.apply($container[0], [ e, selectedRows, containerHistory.selectedRows, containerHistory.selectingStartIndex, containerHistory.selectingCurrentIndex, containerHistory.selectedStartIndex,\r\n\t\t\t\t\t\t\tcontainerHistory.selectedCurrentIndex ]);\r\n\t\t\t\t\t}\r\n\t\t\t\t\t/* reset the field value */\r\n\t\t\t\t\tif (options.submitField != null) {\r\n\t\t\t\t\t\toptions.submitField.val($container.serializeMultipleSelectBox());\r\n\t\t\t\t\t}\r\n\t\t\t\t\tcontainerHistory.selectedRows = selectedRows;\r\n\t\t\t\t}\r\n\t\t\t\t/* reset history */\r\n\t\t\t\tcontainerHistory.selectedStartIndex = containerHistory.selectingStartIndex;\r\n\t\t\t\tcontainerHistory.selectedCurrentIndex = containerHistory.selectingCurrentIndex;\r\n\t\t\t});\r\n\t}", "function CustomSelectableList()\r\n{\r\n\tthis.name = 'cslist';\r\n\tthis.items = new Array();\r\n\tthis.itemIdentifiers = new Array();\r\n\tthis.clickHandlers = new Array();\r\n\tthis.dblClickHandlers = new Array();\r\n\tthis.instanceName = null;\r\n\tthis.obj = \"CSList\";\r\n\tthis.lastId = null;\r\n\r\n\tthis.selectedObj = null;\r\n\t\r\n\tif (this.obj)\r\n\t\teval(this.obj + \"=this\");\r\n\r\n\tthis.unselectedColor = null;\r\n\tthis.selectedColor = null;\r\n\r\n\tthis.attachEventEx = function(target, event, func) \r\n\t{\r\n\t\tif (target.attachEvent)\r\n\t\t\ttarget.attachEvent(\"on\" + event, func);\r\n\t\telse if (target.addEventListener)\r\n\t\t\ttarget.addEventListener(event, func, false);\r\n\t\telse\r\n\t\t\ttarget[\"on\" + event] = func;\r\n\t}\r\n\r\n\tthis.addItem = function(item, itemIndex, clickHandler, doubleClickHandler, objIdentifier) \r\n\t{\r\n\t\tthis.items.push(item);\r\n\t\tthis.clickHandlers.push(clickHandler);\r\n\t\tthis.dblClickHandlers.push(doubleClickHandler);\r\n\t\tthis.itemIdentifiers.push(objIdentifier);\r\n\r\n\t\tvar obj = document.getElementById(item)\r\n\t\tif (obj) {\r\n\t\t\tthis.attachEventEx(obj, \"click\", new Function(this.obj + \".click('\" + item + \"');\"));\r\n\t\t\tthis.attachEventEx(obj, \"dblclick\", new Function(this.obj + \".dblclick('\" + item + \"');\"));\r\n\t\t}\r\n\t}\r\n\r\n\tthis.selectFirst = function()\r\n\t{\r\n\t\tif (this.items.length)\r\n\t\t\tthis.click(this.items[0]);\r\n\t}\r\n\r\n\tthis.selectById = function( id )\r\n\t{\r\n\t\tif (id.length)\r\n\t\t\tthis.click(id);\r\n\t\telse\r\n\t\t\tthis.selectFirst();\r\n\t}\r\n\r\n\tthis.selectByObj = function( obj )\r\n\t{\r\n\t\tif ( this.selectedObj != null )\r\n\t\t\tthis.selectedObj.style.backgroundColor = this.unselectedColor;\r\n\r\n\t\tif (obj)\r\n\t\t\tobj.style.backgroundColor = this.selectedColor;\r\n\r\n\t\tthis.selectedObj = obj;\r\n\t}\r\n\r\n\tthis._getItemIndex = function(id)\r\n\t{\r\n\t\treturn id.substr( this.instanceName.length+String(\"item\").length );\r\n\t}\r\n\r\n\tthis.click = function(id)\r\n\t{\r\n\t\tvar itemObj = document.getElementById(id);\r\n\t\tthis.selectByObj( itemObj );\r\n\r\n\t\tvar index = this._getItemIndex(id);\r\n\r\n\t\tif (this.clickHandlers[index] && this.lastId != index) {\r\n\t\t\teval(this.clickHandlers[index]);\r\n\t\t}\r\n\r\n\t\tthis.lastId = index;\r\n\t}\r\n\r\n\tthis.dblclick = function(id)\r\n\t{\r\n\t\tvar itemObj = document.getElementById(id);\r\n\r\n\t\tvar index = this._getItemIndex(id);\r\n\t\tif (this.dblClickHandlers[index]) {\r\n\t\t\teval(this.dblClickHandlers[index]);\r\n\t\t}\r\n\t}\r\n\r\n\tthis.getCurrentData = function()\r\n\t{\r\n\t\tif (this.lastId == null)\r\n\t\t\treturn null;\r\n\r\n\t\treturn this.itemIdentifiers[this.lastId];\r\n\t}\r\n}", "function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {\n\n var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;\n\n switch (domEventName) {\n // Track the input node that has focus.\n case 'focusin':\n if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') {\n activeElement$1 = targetNode;\n activeElementInst$1 = targetInst;\n lastSelection = null;\n }\n\n break;\n\n case 'focusout':\n activeElement$1 = null;\n activeElementInst$1 = null;\n lastSelection = null;\n break;\n // Don't fire the event while the user is dragging. This matches the\n // semantics of the native select event.\n\n case 'mousedown':\n mouseDown = true;\n break;\n\n case 'contextmenu':\n case 'mouseup':\n case 'dragend':\n mouseDown = false;\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n break;\n // Chrome and IE fire non-standard event when selection is changed (and\n // sometimes when it hasn't). IE's event fires out of order with respect\n // to key and input events on deletion, so we discard it.\n //\n // Firefox doesn't support selectionchange, so check selection status\n // after each key entry. The selection changes after keydown and before\n // keyup, but we check on keydown as well in the case of holding down a\n // key, when multiple keydown events are fired but only one keyup is.\n // This is also our approach for IE handling, for the reason above.\n\n case 'selectionchange':\n if (skipSelectionChangeEvent) {\n break;\n }\n\n // falls through\n\n case 'keydown':\n case 'keyup':\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n }\n}", "function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {\n\n var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;\n\n switch (domEventName) {\n // Track the input node that has focus.\n case 'focusin':\n if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') {\n activeElement$1 = targetNode;\n activeElementInst$1 = targetInst;\n lastSelection = null;\n }\n\n break;\n\n case 'focusout':\n activeElement$1 = null;\n activeElementInst$1 = null;\n lastSelection = null;\n break;\n // Don't fire the event while the user is dragging. This matches the\n // semantics of the native select event.\n\n case 'mousedown':\n mouseDown = true;\n break;\n\n case 'contextmenu':\n case 'mouseup':\n case 'dragend':\n mouseDown = false;\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n break;\n // Chrome and IE fire non-standard event when selection is changed (and\n // sometimes when it hasn't). IE's event fires out of order with respect\n // to key and input events on deletion, so we discard it.\n //\n // Firefox doesn't support selectionchange, so check selection status\n // after each key entry. The selection changes after keydown and before\n // keyup, but we check on keydown as well in the case of holding down a\n // key, when multiple keydown events are fired but only one keyup is.\n // This is also our approach for IE handling, for the reason above.\n\n case 'selectionchange':\n if (skipSelectionChangeEvent) {\n break;\n }\n\n // falls through\n\n case 'keydown':\n case 'keyup':\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n }\n}", "function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {\n\n var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;\n\n switch (domEventName) {\n // Track the input node that has focus.\n case 'focusin':\n if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') {\n activeElement$1 = targetNode;\n activeElementInst$1 = targetInst;\n lastSelection = null;\n }\n\n break;\n\n case 'focusout':\n activeElement$1 = null;\n activeElementInst$1 = null;\n lastSelection = null;\n break;\n // Don't fire the event while the user is dragging. This matches the\n // semantics of the native select event.\n\n case 'mousedown':\n mouseDown = true;\n break;\n\n case 'contextmenu':\n case 'mouseup':\n case 'dragend':\n mouseDown = false;\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n break;\n // Chrome and IE fire non-standard event when selection is changed (and\n // sometimes when it hasn't). IE's event fires out of order with respect\n // to key and input events on deletion, so we discard it.\n //\n // Firefox doesn't support selectionchange, so check selection status\n // after each key entry. The selection changes after keydown and before\n // keyup, but we check on keydown as well in the case of holding down a\n // key, when multiple keydown events are fired but only one keyup is.\n // This is also our approach for IE handling, for the reason above.\n\n case 'selectionchange':\n if (skipSelectionChangeEvent) {\n break;\n }\n\n // falls through\n\n case 'keydown':\n case 'keyup':\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n }\n}", "function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {\n\n var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;\n\n switch (domEventName) {\n // Track the input node that has focus.\n case 'focusin':\n if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') {\n activeElement$1 = targetNode;\n activeElementInst$1 = targetInst;\n lastSelection = null;\n }\n\n break;\n\n case 'focusout':\n activeElement$1 = null;\n activeElementInst$1 = null;\n lastSelection = null;\n break;\n // Don't fire the event while the user is dragging. This matches the\n // semantics of the native select event.\n\n case 'mousedown':\n mouseDown = true;\n break;\n\n case 'contextmenu':\n case 'mouseup':\n case 'dragend':\n mouseDown = false;\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n break;\n // Chrome and IE fire non-standard event when selection is changed (and\n // sometimes when it hasn't). IE's event fires out of order with respect\n // to key and input events on deletion, so we discard it.\n //\n // Firefox doesn't support selectionchange, so check selection status\n // after each key entry. The selection changes after keydown and before\n // keyup, but we check on keydown as well in the case of holding down a\n // key, when multiple keydown events are fired but only one keyup is.\n // This is also our approach for IE handling, for the reason above.\n\n case 'selectionchange':\n if (skipSelectionChangeEvent) {\n break;\n }\n\n // falls through\n\n case 'keydown':\n case 'keyup':\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n }\n}", "function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {\n\n var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;\n\n switch (domEventName) {\n // Track the input node that has focus.\n case 'focusin':\n if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') {\n activeElement$1 = targetNode;\n activeElementInst$1 = targetInst;\n lastSelection = null;\n }\n\n break;\n\n case 'focusout':\n activeElement$1 = null;\n activeElementInst$1 = null;\n lastSelection = null;\n break;\n // Don't fire the event while the user is dragging. This matches the\n // semantics of the native select event.\n\n case 'mousedown':\n mouseDown = true;\n break;\n\n case 'contextmenu':\n case 'mouseup':\n case 'dragend':\n mouseDown = false;\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n break;\n // Chrome and IE fire non-standard event when selection is changed (and\n // sometimes when it hasn't). IE's event fires out of order with respect\n // to key and input events on deletion, so we discard it.\n //\n // Firefox doesn't support selectionchange, so check selection status\n // after each key entry. The selection changes after keydown and before\n // keyup, but we check on keydown as well in the case of holding down a\n // key, when multiple keydown events are fired but only one keyup is.\n // This is also our approach for IE handling, for the reason above.\n\n case 'selectionchange':\n if (skipSelectionChangeEvent) {\n break;\n }\n\n // falls through\n\n case 'keydown':\n case 'keyup':\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n }\n}", "function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {\n\n var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;\n\n switch (domEventName) {\n // Track the input node that has focus.\n case 'focusin':\n if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') {\n activeElement$1 = targetNode;\n activeElementInst$1 = targetInst;\n lastSelection = null;\n }\n\n break;\n\n case 'focusout':\n activeElement$1 = null;\n activeElementInst$1 = null;\n lastSelection = null;\n break;\n // Don't fire the event while the user is dragging. This matches the\n // semantics of the native select event.\n\n case 'mousedown':\n mouseDown = true;\n break;\n\n case 'contextmenu':\n case 'mouseup':\n case 'dragend':\n mouseDown = false;\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n break;\n // Chrome and IE fire non-standard event when selection is changed (and\n // sometimes when it hasn't). IE's event fires out of order with respect\n // to key and input events on deletion, so we discard it.\n //\n // Firefox doesn't support selectionchange, so check selection status\n // after each key entry. The selection changes after keydown and before\n // keyup, but we check on keydown as well in the case of holding down a\n // key, when multiple keydown events are fired but only one keyup is.\n // This is also our approach for IE handling, for the reason above.\n\n case 'selectionchange':\n if (skipSelectionChangeEvent) {\n break;\n }\n\n // falls through\n\n case 'keydown':\n case 'keyup':\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n }\n}", "function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {\n\n var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;\n\n switch (domEventName) {\n // Track the input node that has focus.\n case 'focusin':\n if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') {\n activeElement$1 = targetNode;\n activeElementInst$1 = targetInst;\n lastSelection = null;\n }\n\n break;\n\n case 'focusout':\n activeElement$1 = null;\n activeElementInst$1 = null;\n lastSelection = null;\n break;\n // Don't fire the event while the user is dragging. This matches the\n // semantics of the native select event.\n\n case 'mousedown':\n mouseDown = true;\n break;\n\n case 'contextmenu':\n case 'mouseup':\n case 'dragend':\n mouseDown = false;\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n break;\n // Chrome and IE fire non-standard event when selection is changed (and\n // sometimes when it hasn't). IE's event fires out of order with respect\n // to key and input events on deletion, so we discard it.\n //\n // Firefox doesn't support selectionchange, so check selection status\n // after each key entry. The selection changes after keydown and before\n // keyup, but we check on keydown as well in the case of holding down a\n // key, when multiple keydown events are fired but only one keyup is.\n // This is also our approach for IE handling, for the reason above.\n\n case 'selectionchange':\n if (skipSelectionChangeEvent) {\n break;\n }\n\n // falls through\n\n case 'keydown':\n case 'keyup':\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n }\n}", "function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {\n\n var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;\n\n switch (domEventName) {\n // Track the input node that has focus.\n case 'focusin':\n if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') {\n activeElement$1 = targetNode;\n activeElementInst$1 = targetInst;\n lastSelection = null;\n }\n\n break;\n\n case 'focusout':\n activeElement$1 = null;\n activeElementInst$1 = null;\n lastSelection = null;\n break;\n // Don't fire the event while the user is dragging. This matches the\n // semantics of the native select event.\n\n case 'mousedown':\n mouseDown = true;\n break;\n\n case 'contextmenu':\n case 'mouseup':\n case 'dragend':\n mouseDown = false;\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n break;\n // Chrome and IE fire non-standard event when selection is changed (and\n // sometimes when it hasn't). IE's event fires out of order with respect\n // to key and input events on deletion, so we discard it.\n //\n // Firefox doesn't support selectionchange, so check selection status\n // after each key entry. The selection changes after keydown and before\n // keyup, but we check on keydown as well in the case of holding down a\n // key, when multiple keydown events are fired but only one keyup is.\n // This is also our approach for IE handling, for the reason above.\n\n case 'selectionchange':\n if (skipSelectionChangeEvent) {\n break;\n }\n\n // falls through\n\n case 'keydown':\n case 'keyup':\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n }\n}", "function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {\n\n var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;\n\n switch (domEventName) {\n // Track the input node that has focus.\n case 'focusin':\n if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') {\n activeElement$1 = targetNode;\n activeElementInst$1 = targetInst;\n lastSelection = null;\n }\n\n break;\n\n case 'focusout':\n activeElement$1 = null;\n activeElementInst$1 = null;\n lastSelection = null;\n break;\n // Don't fire the event while the user is dragging. This matches the\n // semantics of the native select event.\n\n case 'mousedown':\n mouseDown = true;\n break;\n\n case 'contextmenu':\n case 'mouseup':\n case 'dragend':\n mouseDown = false;\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n break;\n // Chrome and IE fire non-standard event when selection is changed (and\n // sometimes when it hasn't). IE's event fires out of order with respect\n // to key and input events on deletion, so we discard it.\n //\n // Firefox doesn't support selectionchange, so check selection status\n // after each key entry. The selection changes after keydown and before\n // keyup, but we check on keydown as well in the case of holding down a\n // key, when multiple keydown events are fired but only one keyup is.\n // This is also our approach for IE handling, for the reason above.\n\n case 'selectionchange':\n if (skipSelectionChangeEvent) {\n break;\n }\n\n // falls through\n\n case 'keydown':\n case 'keyup':\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n }\n}", "function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {\n\n var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;\n\n switch (domEventName) {\n // Track the input node that has focus.\n case 'focusin':\n if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') {\n activeElement$1 = targetNode;\n activeElementInst$1 = targetInst;\n lastSelection = null;\n }\n\n break;\n\n case 'focusout':\n activeElement$1 = null;\n activeElementInst$1 = null;\n lastSelection = null;\n break;\n // Don't fire the event while the user is dragging. This matches the\n // semantics of the native select event.\n\n case 'mousedown':\n mouseDown = true;\n break;\n\n case 'contextmenu':\n case 'mouseup':\n case 'dragend':\n mouseDown = false;\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n break;\n // Chrome and IE fire non-standard event when selection is changed (and\n // sometimes when it hasn't). IE's event fires out of order with respect\n // to key and input events on deletion, so we discard it.\n //\n // Firefox doesn't support selectionchange, so check selection status\n // after each key entry. The selection changes after keydown and before\n // keyup, but we check on keydown as well in the case of holding down a\n // key, when multiple keydown events are fired but only one keyup is.\n // This is also our approach for IE handling, for the reason above.\n\n case 'selectionchange':\n if (skipSelectionChangeEvent) {\n break;\n }\n\n // falls through\n\n case 'keydown':\n case 'keyup':\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n }\n}", "function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {\n\n var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;\n\n switch (domEventName) {\n // Track the input node that has focus.\n case 'focusin':\n if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') {\n activeElement$1 = targetNode;\n activeElementInst$1 = targetInst;\n lastSelection = null;\n }\n\n break;\n\n case 'focusout':\n activeElement$1 = null;\n activeElementInst$1 = null;\n lastSelection = null;\n break;\n // Don't fire the event while the user is dragging. This matches the\n // semantics of the native select event.\n\n case 'mousedown':\n mouseDown = true;\n break;\n\n case 'contextmenu':\n case 'mouseup':\n case 'dragend':\n mouseDown = false;\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n break;\n // Chrome and IE fire non-standard event when selection is changed (and\n // sometimes when it hasn't). IE's event fires out of order with respect\n // to key and input events on deletion, so we discard it.\n //\n // Firefox doesn't support selectionchange, so check selection status\n // after each key entry. The selection changes after keydown and before\n // keyup, but we check on keydown as well in the case of holding down a\n // key, when multiple keydown events are fired but only one keyup is.\n // This is also our approach for IE handling, for the reason above.\n\n case 'selectionchange':\n if (skipSelectionChangeEvent) {\n break;\n }\n\n // falls through\n\n case 'keydown':\n case 'keyup':\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n }\n}", "function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {\n\n var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;\n\n switch (domEventName) {\n // Track the input node that has focus.\n case 'focusin':\n if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') {\n activeElement$1 = targetNode;\n activeElementInst$1 = targetInst;\n lastSelection = null;\n }\n\n break;\n\n case 'focusout':\n activeElement$1 = null;\n activeElementInst$1 = null;\n lastSelection = null;\n break;\n // Don't fire the event while the user is dragging. This matches the\n // semantics of the native select event.\n\n case 'mousedown':\n mouseDown = true;\n break;\n\n case 'contextmenu':\n case 'mouseup':\n case 'dragend':\n mouseDown = false;\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n break;\n // Chrome and IE fire non-standard event when selection is changed (and\n // sometimes when it hasn't). IE's event fires out of order with respect\n // to key and input events on deletion, so we discard it.\n //\n // Firefox doesn't support selectionchange, so check selection status\n // after each key entry. The selection changes after keydown and before\n // keyup, but we check on keydown as well in the case of holding down a\n // key, when multiple keydown events are fired but only one keyup is.\n // This is also our approach for IE handling, for the reason above.\n\n case 'selectionchange':\n if (skipSelectionChangeEvent) {\n break;\n }\n\n // falls through\n\n case 'keydown':\n case 'keyup':\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n }\n}", "function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {\n\n var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;\n\n switch (domEventName) {\n // Track the input node that has focus.\n case 'focusin':\n if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') {\n activeElement$1 = targetNode;\n activeElementInst$1 = targetInst;\n lastSelection = null;\n }\n\n break;\n\n case 'focusout':\n activeElement$1 = null;\n activeElementInst$1 = null;\n lastSelection = null;\n break;\n // Don't fire the event while the user is dragging. This matches the\n // semantics of the native select event.\n\n case 'mousedown':\n mouseDown = true;\n break;\n\n case 'contextmenu':\n case 'mouseup':\n case 'dragend':\n mouseDown = false;\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n break;\n // Chrome and IE fire non-standard event when selection is changed (and\n // sometimes when it hasn't). IE's event fires out of order with respect\n // to key and input events on deletion, so we discard it.\n //\n // Firefox doesn't support selectionchange, so check selection status\n // after each key entry. The selection changes after keydown and before\n // keyup, but we check on keydown as well in the case of holding down a\n // key, when multiple keydown events are fired but only one keyup is.\n // This is also our approach for IE handling, for the reason above.\n\n case 'selectionchange':\n if (skipSelectionChangeEvent) {\n break;\n }\n\n // falls through\n\n case 'keydown':\n case 'keyup':\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n }\n}", "function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {\n\n var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;\n\n switch (domEventName) {\n // Track the input node that has focus.\n case 'focusin':\n if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') {\n activeElement$1 = targetNode;\n activeElementInst$1 = targetInst;\n lastSelection = null;\n }\n\n break;\n\n case 'focusout':\n activeElement$1 = null;\n activeElementInst$1 = null;\n lastSelection = null;\n break;\n // Don't fire the event while the user is dragging. This matches the\n // semantics of the native select event.\n\n case 'mousedown':\n mouseDown = true;\n break;\n\n case 'contextmenu':\n case 'mouseup':\n case 'dragend':\n mouseDown = false;\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n break;\n // Chrome and IE fire non-standard event when selection is changed (and\n // sometimes when it hasn't). IE's event fires out of order with respect\n // to key and input events on deletion, so we discard it.\n //\n // Firefox doesn't support selectionchange, so check selection status\n // after each key entry. The selection changes after keydown and before\n // keyup, but we check on keydown as well in the case of holding down a\n // key, when multiple keydown events are fired but only one keyup is.\n // This is also our approach for IE handling, for the reason above.\n\n case 'selectionchange':\n if (skipSelectionChangeEvent) {\n break;\n }\n\n // falls through\n\n case 'keydown':\n case 'keyup':\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n }\n}", "function extractEvents$3(dispatchQueue, domEventName, targetInst, nativeEvent, nativeEventTarget, eventSystemFlags, targetContainer) {\n\n var targetNode = targetInst ? getNodeFromInstance(targetInst) : window;\n\n switch (domEventName) {\n // Track the input node that has focus.\n case 'focusin':\n if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') {\n activeElement$1 = targetNode;\n activeElementInst$1 = targetInst;\n lastSelection = null;\n }\n\n break;\n\n case 'focusout':\n activeElement$1 = null;\n activeElementInst$1 = null;\n lastSelection = null;\n break;\n // Don't fire the event while the user is dragging. This matches the\n // semantics of the native select event.\n\n case 'mousedown':\n mouseDown = true;\n break;\n\n case 'contextmenu':\n case 'mouseup':\n case 'dragend':\n mouseDown = false;\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n break;\n // Chrome and IE fire non-standard event when selection is changed (and\n // sometimes when it hasn't). IE's event fires out of order with respect\n // to key and input events on deletion, so we discard it.\n //\n // Firefox doesn't support selectionchange, so check selection status\n // after each key entry. The selection changes after keydown and before\n // keyup, but we check on keydown as well in the case of holding down a\n // key, when multiple keydown events are fired but only one keyup is.\n // This is also our approach for IE handling, for the reason above.\n\n case 'selectionchange':\n if (skipSelectionChangeEvent) {\n break;\n }\n\n // falls through\n\n case 'keydown':\n case 'keyup':\n constructSelectEvent(dispatchQueue, nativeEvent, nativeEventTarget);\n }\n}", "function dragDropped(arg) {\n\t\tif (Y.Lang.isArray(arg.value)) {\n\t\t\targ = arg.value;\n\t\t}\n\n\t\tfor (var i = 0; i < arg.length; i++) {\n\t\t\tif (arg[i].mimeType[0] == \"application/x-folder\") { continue; }// skip folders\n\t\t\tfilesToUpload.push(arg[i]);\n\t\t} \n\n\t\t// now let's disable that pesky drop target.\n\t\tlog(START, \"Now processing \" + filesToUpload.length + \" files...\");\n\t\tenableDropTarget(false);\n\t\tstartNextUploadTest();\n\t}", "function findSelectables() {\n\n var a = svg.getBoundingClientRect();\n\n for (var i = selectables.length; i--;) {\n\n var selectable = selectables[i],\n b = selectable.getBoundingClientRect();\n\n if (isColliding(a, b)) {\n selectable.classList.add(\"selected\");\n } else {\n selectable.classList.remove(\"selected\");\n }\n }\n}", "function selectDDDragstart (e) {\n selectMenuItem ( 'drag-drop-menu', 'dragstart');\n e.preventDefault();\n}", "function ld_course_builder_draggable_helper( selected ) {\n\t\t\n\t\tvar container = $('<div/>').attr('id', 'ld-selector-draggable-group');\n\n\t\tif ( ( typeof selected !== 'undefined' ) && ( selected.length ) ) {\n\t\t\tvar max_width = 0;\n\t\t\tjQuery(selected).each(function( selected_idx, selected_el ) {\n\t\t\t\t//console.log('selected_el[%o]', selected_el );\n\t\t\t\tjQuery('.ld-course-builder-sub-actions', selected_el).hide();\n\t\t\t\tvar el_width = jQuery(selected_el).outerWidth();\n\t\t\t\tif ( el_width > max_width )\n\t\t\t\t\tmax_width = el_width;\n\t\t\t});\n\t\t\n\t\t\tcontainer.css('list-style', 'none');\n\t\t\tcontainer.css('width', max_width + 'px');\n\t\t\tcontainer.append(selected.clone());\n\t\t}\n\t\treturn container;\n\t}", "multipleChanged(prev, next) {\n this.ariaMultiSelectable = next ? \"true\" : undefined;\n }", "function dropList(e) {\n\t\tstopEvent(e);\n\t\tvar cname = this.className;\n\t\tthis.className = cname ? \"\" : \"on\";\n\t}", "_evtMousedown(event) {\n if (this.isHidden || !this._editor) {\n return;\n }\n if (Private.nonstandardClick(event)) {\n this.reset();\n return;\n }\n let target = event.target;\n while (target !== document.documentElement) {\n // If the user has made a selection, emit its value and reset the widget.\n if (target.classList.contains(ITEM_CLASS)) {\n event.preventDefault();\n event.stopPropagation();\n event.stopImmediatePropagation();\n this._selected.emit(target.getAttribute('data-value'));\n this.reset();\n return;\n }\n // If the mouse event happened anywhere else in the widget, bail.\n if (target === this.node) {\n event.preventDefault();\n event.stopPropagation();\n event.stopImmediatePropagation();\n return;\n }\n target = target.parentElement;\n }\n this.reset();\n }" ]
[ "0.64923054", "0.64745873", "0.6313913", "0.62336046", "0.5861946", "0.5806698", "0.57896096", "0.5698621", "0.5660796", "0.56062526", "0.55689436", "0.5549231", "0.5530512", "0.55174196", "0.549765", "0.546832", "0.5462681", "0.5454696", "0.5427804", "0.5427804", "0.5427804", "0.5425037", "0.5416513", "0.5416513", "0.54002714", "0.5383086", "0.5382684", "0.5377326", "0.53691137", "0.5361874", "0.5311658", "0.5308211", "0.52824736", "0.5276573", "0.5268588", "0.5260891", "0.5240748", "0.5226757", "0.52245617", "0.51981145", "0.51962477", "0.5186361", "0.5182172", "0.51817364", "0.51770395", "0.5163307", "0.5161557", "0.51577514", "0.5146852", "0.51467985", "0.5134127", "0.5122279", "0.51166195", "0.51136947", "0.5109408", "0.51090026", "0.5104298", "0.5104298", "0.51019406", "0.5090308", "0.5079695", "0.50740457", "0.5073462", "0.50722516", "0.5071018", "0.5067003", "0.5065843", "0.5065843", "0.5064359", "0.5057702", "0.5044094", "0.5039945", "0.5034139", "0.50249547", "0.5023872", "0.50235254", "0.50214106", "0.5020625", "0.50199896", "0.50199896", "0.50199896", "0.50199896", "0.50199896", "0.50199896", "0.50199896", "0.50199896", "0.50199896", "0.50199896", "0.50199896", "0.50199896", "0.50199896", "0.50199896", "0.50199896", "0.50165385", "0.50106484", "0.5008916", "0.5008507", "0.50080186", "0.50068176", "0.5004552" ]
0.77628446
0
Gets the contents of a file.
read(file) { return this[FILES][file] || null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getFileContents(filename){\r\n\t\r\n\tvar contents;\r\n\tcontents = fs.readFileSync(filename);\r\n\treturn contents;\r\n}", "function getContents(file) {\n\t// Ensure that the file's name is not null.\n\tif(file === null) {\n\t\tself.fail(\"The File object is null.\");\n\t}\n\tif(! file.exists()) {\n\t\tself.fail(\"The file does not exist: \" + file);\n\t}\n\t\n\tvar fileReader;\n\ttry {\n\t\tfileReader = new FileReader(file);\n\t}\n\tcatch(e) {\n\t\tself.fail(\"Could not open the file: \" + e);\n\t\treturn;\n\t}\n\t\n\treturn new String(FileUtils.readFully(fileReader));\n}", "function readFile(file) {\n return fetch(file).then(function (response) {\n return response.text();\n });\n }", "function readFile(file)\n{\n var content = '';\n\n var stream = Components.classes['@mozilla.org/network/file-input-stream;1']\n .createInstance(Components.interfaces.nsIFileInputStream);\n stream.init(file, 0x01, 0, 0);\n\n var script = Components.classes['@mozilla.org/scriptableinputstream;1']\n .createInstance(Components.interfaces.nsIScriptableInputStream);\n script.init(stream);\n\n if (stream.available()) {\n var data = script.read(4096);\n\n while (data.length > 0) {\n content += data;\n data = script.read(4096);\n }\n }\n\n stream.close();\n script.close();\n\n return content;\n}", "function fileContents(filePath, file) {\n return file.contents.toString('utf8');\n}", "function fileContents (filePath, file) {\n return file.contents.toString('utf8');\n}", "function getFileContent(path) {\n return fs.readFileSync(`${path}`, {\n encoding: 'utf8'\n })\n}", "function readFile() {\n return fs.readFileSync(fileName);\n}", "getContents() {\n return _fs.default.readFileSync(this.filePath, \"utf8\");\n }", "function readFile(file) {\n return fs.readFileSync(file, \"utf8\");\n}", "function getContent(fileName) {\n return fs.readFileSync(fileName, { encoding: 'utf8' });\n}", "function readFile(path) {\n\t\tvar content = \"\";\n\t\ttry {\n\t\t\tcontent = fs.readFileSync(path).toString();\n\t\t} catch (e) {\n\t\t\tif (e.code === \"ENOENT\") {\n\t\t\t\twarn(\"Source file \" + e.path + \" not found.\");\n\t\t\t} else {\n\t\t\t\tthrow e;\n\t\t\t}\n\t\t}\n\t\treturn content;\n\t}", "async function getFileContent(filePath) {\n return (await filePath) ? readFile(filePath) : null;\n}", "function read(file) {\n var complete = fs.readFileSync(file, 'utf8')\n return complete\n}", "function GetFileBody(file) {\n\treturn fs.readFileSync(InputDir + file).toString('utf-8');\n}", "function read_file(path_to_file){\n var data = fs.readFileSync(path_to_file).toString();\n return data;\n}", "function getTextFile(theFilename){\n return new Promise($.async(function (resolve, reject) {\n try {\n $.fs.readFile(theFilename, 'utf8', function (err, theContent) {\n if (err) {\n resolve(\"\")\n } else {\n resolve(theContent);\n }\n });\n }\n catch (error) {\n resolve(\"\")\n }\n \n }));\n}", "function readFromFile(file) {\n let istream = Cc[\"@mozilla.org/network/file-input-stream;1\"].\n createInstance(Ci.nsIFileInputStream);\n istream.init(file, 0x01, 0444,0);\n istream.QueryInterface(Ci.nsILineInputStream);\n dump(\"reading\\n\");\n\n let line = {}, lines = [], hasmore;\n do {\n hasmore = istream.readLine(line);\n dump(\"line:\" + line.value + \"\\n\");\n lines.push(line.value);\n } while(hasmore);\n istream.close();\n dump(\"done reading\\n\");\n return lines;\n}", "function readContentFile(filename) {\n var promise = new Promise(async function(resolve, reject) {\n fs.readFile(filename, 'utf8', function (err, data) {\n if (err) {\n reject(err);\n return;\n }\n resolve (data);\n });\n });\n return promise;\n}", "function readFile(file) {\n return new Promise((resolve, reject) => {\n let chunks = [];\n // Create a readable stream\n let readableStream = fs.createReadStream(file);\n \n readableStream.on('data', chunk => {\n chunks.push(chunk);\n });\n\n readableStream.on('error', err => {\n reject(err)\n })\n \n return readableStream.on('end', () => {\n resolve(chunks);\n });\n });\n}", "function readTextFile(file) {\n\tvar rawFile1 = new XMLHttpRequest();\n\trawFile1.open(\"GET\", file, false);\n\trawFile1.onreadystatechange = function() {\n\t\tif(rawFile1.readyState === 4) {\n\t\t\tif(rawFile1.status === 200 || rawFile1.status == 0) {\n\t\t\t\treturn rawFile1.responseText;\n\t\t\t}\n\t\t}\n\t}\n\trawFile1.send(null);\n\treturn rawFile1.responseText;\n}", "function getFile(fileName) {\n return fs.readFileSync(path.resolve(__dirname, fileName), \"utf-8\");\n}", "function getFile(filePath) {\n return new Promise((resolve, reject) => {\n fs.readFile(filePath, function(error, data) {\n if (error) {\n return reject(error);\n }\n return resolve(data);\n });\n });\n}", "readFile(file) {\n return new Promise((resolve, reject) => {\n\n const reader = new FileReader();\n\n reader.onload = res => {\n resolve(res.target.result);\n };\n\n reader.onerror = err => reject(err);\n\n reader.readAsDataURL(file);\n });\n }", "function ReadFile(path)\n{\n\treturn _fs.readFileSync(path, \"utf8\").toString();\n}", "async read (filepath, options = {}) {\n try {\n let buffer = await this._readFile(filepath, options);\n return buffer\n } catch (err) {\n return null\n }\n }", "readFile(file) {\n return new Promise((resolve, reject) => {\n const reader = new FileReader();\n reader.onload = (evt) => {\n if(evt && evt.target) {\n resolve(evt.target.result);\n }\n reject();\n };\n reader.readAsDataURL(file);\n });\n }", "function readFile(file_path) {\n return fs.readFileSync(file_path, 'utf8', function(err, data) { \n if (err) throw err;\n console.log(data);\n });\n}", "function readfile(){\n\t\t\tvar txtFile = \"c:/test.txt\"\n\t\t\tvar file = new File([\"\"],txtFile);\n\n\t\t\tfile.open(\"r\"); // open file with read access\n\t\t\tvar str = \"\";\n\t\t\twhile (!file.eof) {\n\t\t\t\t// read each line of text\n\t\t\t\tstr += file.readln() + \"\\n\";\n\t\t\t}\n\t\t\tfile.close();\n\t\t\talert(str);\n\t\t}", "function readFile(aFileName) {\n let f = do_get_file(aFileName);\n let s = Cc[\"@mozilla.org/network/file-input-stream;1\"]\n .createInstance(Ci.nsIFileInputStream);\n s.init(f, -1, -1, false);\n try {\n return NetUtil.readInputStreamToString(s, s.available());\n } finally {\n s.close();\n }\n}", "function readFile (fullpath){\n\tvar result=\"\";\n\t$.ajax({\n\t\turl: fullpath,\n\t\tasync: false,\n\t\tdataType: \"text\",\n\t\tsuccess: function (data) {\n\t\t\tresult = data;\n\t\t}\n\t});\n\treturn result;\n}", "function _getDataFromFile(){\n\tvar fileData = _openFIle();\n\treturn fileData;\n}", "function readfile(path)\r\n{\r\n return fs.readFileSync(path,'UTF8',function(data,err)\r\n {\r\n if(err) throw err;\r\n return data\r\n });\r\n}", "static read_file(filename, encoding='utf8')\r\n {\r\n let data;\r\n try\r\n {\r\n data = fs.readFileSync(filename, encoding);\r\n }\r\n catch (err)\r\n {\r\n throw new Error(err);\r\n }\r\n return data;\r\n }", "function readFile(file) {\n\treturn ''+new String(org.apache.tools.ant.util.FileUtils.readFully(new java.io.FileReader(file)));\n}", "function readTextFile(file) {\n //Look into fetch or FileReader\n let rawFile = new XMLHttpRequest();\n let allText;\n rawFile.open(\"GET\", file, false);\n rawFile.onreadystatechange = () => (allText = rawFile.responseText);\n rawFile.send(null);\n getElementData(allText, file);\n}", "function readFile(file) {\n return new Promise(function (resolve) {\n var reader = new FileReader();\n\n // This is called when finished reading\n reader.onload = function (event) {\n // Return an array with one image\n resolve({\n // These are attributes like size, name, type, ...\n lastModifiedDate: file.lastModifiedDate,\n lastModified: file.lastModified,\n name: file.name,\n size: file.size,\n type: file.type,\n\n // This is the files content as base64\n src: event.target.result\n });\n };\n\n if (file.type.indexOf('text/') === 0 || file.type === 'application/json') {\n reader.readAsText(file);\n } else if (file.type.indexOf('image/') === 0) {\n reader.readAsDataURL(file);\n } else {\n reader.readAsBinaryString(file);\n }\n });\n}", "function getFileContents(file, callback) {\n\n\t// ajax linker\n\t$.ajax({\n\t\turl : file,\n\n\t\t// on success, call callback\n\t\tsuccess : function(result){\n\t\t\tif ($.isFunction(callback))\n\t\t\t\tcallback.apply(null, [result]);\n\t\t}\n\n\t});\n}", "function readFile (file) {\n var str = fs.readFileSync(file, 'utf-8');\n console.log(str);\n}", "function getFile(url){\n var req = request.get(url, function(err, res){\n if (err) throw err;\n console.log('Response ok:', res.ok);\n console.log('Response text:', res.text);\n return res.text;\n });\n}", "function retriveFile(path) {\n return new Promise((resolve, reject) => {\n var request = new XMLHttpRequest();\n request.open('GET', path, true);\n request.responseType = 'text';\n request.onload = () => resolve({\n fileData: request.response\n });\n request.onerror = reject;\n request.send();\n })\n}", "function readFile(fileEntry) {\n\n // Get the file from the file entry\n fileEntry.file(function (file) {\n \n // Create the reader\n var reader = new FileReader();\n reader.readAsText(file);\n\n reader.onloadend = function() {\n\n console.log(\"Successful file read: \" + this.result);\n console.log(\"file path: \" + fileEntry.fullPath);\n\n };\n\n }, onError);\n}", "function getFileContents(activityXmlFile) {\n\t\ttry {\n\t\t\treturn fs.readFileSync(activityXmlFile);\n\t\t} catch(ex) {\n\t\t\tconsole.log('Error reading activity xml file [', activityXmlFile, ']\\n', ex);\n\t\t\tthrow 'Error reading Activity XML File';\n\t\t}\n\t}", "function readFile (file){ \n let data = (fs.readFileSync(file)\n .toString())\n .replace('\\r', '')\n .split('\\n');\n return data;\n}", "async getFileContents(file, returnDecryptStreamSeparately = false){\n try{\n let beautifiedPath = await this.beautifyPath(file.config.folder, true);\n let filePath = `${beautifiedPath}${beautifiedPath === \"\" ? \"\" : \"/\"}${file.config.name}.${file.config.ext}`;\n\n return await this.getLocalFileContents(filePath, file.config.isEncrypted, file.config.iv);\n }catch(error){ Logger.log(error); }\n\n return { contents: null, contentType: null, contentLength: 0, readStream: null, };\n }", "function read (fileName) {\n return new Promise((resolve, reject) => {\n fs.readFile(fileName, \"utf8\",\n (err, textFileData) => {\n if (err) {\n reject(err);\n return;\n }\n\n resolve(textFileData);\n }\n );\n });\n}", "function getFile (file) {\n fakeAjax(file, function (text) {\n fileReceived(file, text)\n })\n}", "function openFile(path) {\n\treturn new Promise(function (resolve, reject) {\n\t\tfs.readFile(path, \"utf8\", (err, data) => {\n\t\t\tif (err) reject(err);\n\t\t\tresolve(data);\n\t\t});\n\t});\n}", "function getFile(file) {\n fakeAjax(file, function(text) {\n handleResponse(file, text);\n });\n}", "function loadFile(file){\n\tlet fs = require('fs');\n\tvar data = fs.readFileSync(file);\n\tvar contents = (JSON.parse(data));\n\treturn contents;\n}", "function readTxtFile(file) {\n if (!file.exists) {\n throw \"Cannot find file: \" + decodeURI(file.absoluteURI);\n }\n file.open(\"r\", \"TEXT\");\n file.encoding = \"UTF8\";\n file.lineFeed = \"unix\";\n var str = file.read();\n file.close();\n return str;\n}", "async readFile(fileName) {\n const bytes = await this.idb.get(fileName, this.store);\n return bytes;\n }", "readFile(mfs, file) {\n try {\n return mfs.readFileSync(path.join(this.confClient.output.path, file), \"utf-8\")\n } catch (error) {}\n }", "async function readFile(file) {\n return new Promise((resolve, reject) => {\n const reader = new FileReader();\n reader.onload = () => resolve(reader.result);\n reader.readAsText(file);\n });\n}", "getFile(filePath, options) {\n console.log('api.getFile: ', filePath);\n return this.sendRequest({\n type: 'loadFile',\n filePath: filePath,\n options: options\n })\n .then(function(fileInfo) {\n return {\n filePath: filePath,\n contents: fileInfo.payload.contents\n }\n })\n .catch(function(errorInfo) {\n return undefined;\n });\n }", "function readTextFile(file)\n{\n var rawFile = new XMLHttpRequest();\n rawFile.open(\"GET\", file, false);\n rawFile.onreadystatechange = function ()\n {\n if(rawFile.readyState === 4)\n {\n if(rawFile.status === 200 || rawFile.status == 0)\n {\n var allText = rawFile.responseText;\n fileDisplayArea.innerText = allText\n }\n }\n }\n rawFile.send(null);\n}", "function getFile(){\n\n\t\treturn this.file;\n\t}", "function getFile(file) {\n fakeAjax(file, function (text) {\n fileReceived(file, text);\n });\n }", "function readFile() {\n return new Promise((resolve, reject) => {\n fs.readFile(SOURCE, {\n encoding: 'utf-8'\n }, (err, data) => {\n if (err) {\n reject(err);\n // puts the callback given to the .catch in the Promise pending callbacks queue\n } else {\n resolve(data);\n // puts the callback given to the first .then, in the Promise pending callbacks queue\n }\n });\n });\n}", "function loadFileToString(file) {\n let frawin = Cc[\"@mozilla.org/network/file-input-stream;1\"]\n .createInstance(Ci.nsIFileInputStream);\n frawin.init(file, -1, 0, 0);\n let fin = Cc[\"@mozilla.org/scriptableinputstream;1\"]\n .createInstance(Ci.nsIScriptableInputStream);\n fin.init(frawin);\n let data = \"\";\n let str = fin.read(4096);\n while (str.length > 0) {\n data += str;\n str = fin.read(4096);\n }\n fin.close();\n\n return data;\n}", "function readFileAsync (file, options) {\n return new Promise(function (resolve, reject) {\n fs.readFile(file, options, function (err, data) {\n if (err) {\n reject(err)\n } else {\n resolve(data)\n }\n })\n })\n}", "function read(f)\n\t{\n\t\tt = fs.readFileSync(f, 'utf8', (err,txt) => {\n\t\t\tif (err) throw err;\n\t\t});\n\t\treturn t;\n\t}", "function getFileContents(caller, path, app, username, zoneFileLookupURL, forceText) {\n return Promise.resolve().then(function () {\n if (username) {\n return getUserAppFileUrl(path, username, app, zoneFileLookupURL);\n } else {\n return (0, _hub.getOrSetLocalGaiaHubConnection)(caller).then(function (gaiaHubConfig) {\n return (0, _hub.getFullReadUrl)(path, gaiaHubConfig);\n });\n }\n }).then(function (readUrl) {\n return new Promise(function (resolve, reject) {\n if (!readUrl) {\n reject(null);\n } else {\n resolve(readUrl);\n }\n });\n }).then(function (readUrl) {\n return fetch(readUrl);\n }).then(function (response) {\n if (response.status !== 200) {\n if (response.status === 404) {\n _logger.Logger.debug('getFile ' + path + ' returned 404, returning null');\n return null;\n } else {\n throw new Error('getFile ' + path + ' failed with HTTP status ' + response.status);\n }\n }\n var contentType = response.headers.get('Content-Type');\n if (forceText || contentType === null || contentType.startsWith('text') || contentType === 'application/json') {\n return response.text();\n } else {\n return response.arrayBuffer();\n }\n });\n}", "function readTextFile(file)\n{\n var rawFile = new XMLHttpRequest();\n rawFile.open(\"GET\", file, true);\n rawFile.onreadystatechange = function ()\n {\n if(rawFile.readyState === 4)\n {\n if(rawFile.status === 200 || rawFile.status == 0)\n {\n var allText = rawFile.responseText;\n\n alert(allText);\n }\n }\n }\n rawFile.send(null);\n}", "read() {\n return fs.readFileSync(this.filepath).toString();\n }", "function readTextFile(path) {\n\tfs.readFile(path, function(err, data) {\n\t\treturn String(data);\n\t});\n}", "function read(filePath) {\n if (fs.existsSync(filePath)) {\n let isFile = fs.statSync(filePath).isFile;\n if (isFile) {\n let data = fs.readFileSync(filePath, FILE_OPTIONS);\n return data;\n }\n }\n return null;\n}", "readReportFromFile() {\n const content = this.utility.readFromFile(this.reportFileName);\n return content;\n }", "readFile(filePath) {\n return fs.readFileSync(path.resolve(filePath));\n }", "async function getFile(fileId) {\n return await $.ajax({\n url: domain + \"/file/\" + encodeURIComponent(fileId),\n method: \"GET\",\n });\n }", "function getFile(file) {\n\treturn ASQ(function(done){\n\t\tfakeAjax(file,done);\n\t});\n}", "function readFile(filePath, fmt) {\n return new Promise((resolve, reject) =>\n fs.readFile(filePath, fmt || 'utf8', (err, results) =>\n err ? reject(err) : resolve(results))\n );\n}", "function read(f)\n{\n t = fs.readFileSync(f, 'utf8', (err,txt) => {\n if (err) throw err;\n });\n return t;\n}", "function readFile(file) {\n\tvar read = new FileReader();\n\tread.onloadend = function() {\n\t\tconsole.log(read.result);\n\t};\n\tread.readAsBinaryString(file);\n}", "function read_file(filename) {\n var file_data = data.load(filename);\n return file_data;\n}", "async function getFile(name) {\n return new Promise(res => {\n fs.readFile(name, 'utf-8', (err, result) => {\n res(result);\n });\n });\n}", "function readFile(file, header){\r\n\ttemplateGet(file,HEADER,header);\r\n\tvar isDat = header.fileType==1;\r\n\tvar headerSize = isDat ? 108 : 80;\r\n\tif(isDat)\r\n\t\ttemplateGet(file,DAT_HEADER,header);\r\n\tvar data=file.slice(headerSize, file.length-20);\r\n\t//if(header.compressed==4){\r\n\t//\tdata=pako.inflateRaw(data);\r\n\t//}\r\n\treturn data;\r\n}", "async read(filepath) {\n try {\n return await this.reader(filepath, 'utf-8');\n } catch (error) {\n return undefined;\n }\n }", "function read(path, method) {\n method = method || 'readAsText';\n return file(path).then(function (fileEntry) {\n return new Promise(function (resolve, reject) {\n fileEntry.file(function (file) {\n var reader = new FileReader();\n reader.onloadend = function () {\n resolve(this.result);\n };\n reader[method](file);\n }, reject);\n });\n });\n }", "function get_file(url) {\n\tconst request = new XMLHttpRequest()\n\t// This throws a warning about synchronous requests being deprecated\n\trequest.open('GET',url,false)\n\trequest.send()\n\treturn request.responseText\n}", "function readFile(filename){\n return new Promise(function(resolve,reject){\n fs.readFile(filename,'utf8',function(err,data){\n err?reject(err):resolve(data);\n });\n })\n}", "function fetchFileContents(path, callback)\n{\n\t// Check for file existence first, then perform a read if it exists\n\tfs.exists(path, function(exists)\n\t{\n\t\tif (exists)\n\t\t{\n\t\t\tfs.readFile(path, {encoding: 'utf-8'},\n\t\t\t\tfunction(err, data)\n\t\t\t\t{\n\t\t\t\t\tif (!err)\n\t\t\t\t {\n\t\t\t\t \tcallback(data);\n\t\t\t\t }\n\t\t\t\t else\n\t\t\t\t {\n\t\t\t\t\t \tconsole.log(err);\n\t\t\t\t \tcallback(\"404 - The file at \" + path + \" was inaccessible.\");\n\t\t\t\t }\n\t\t\t\t});\n\t\t}\n\t\telse\n\t\t{\n\t\t\tcallback(\"404 - The file at \" + path + \" was not found.\");\n\t\t}\n\t});\n}", "static async readFile(path) {\n return (await Util.promisify(Fs.readFile)(path)).toString('utf-8');\n }", "readFile(path_to_file) {\n return new Promise((resolve, reject) => {\n let result = [],\n line_reader = readline.createInterface({\n input : fs.createReadStream(__dirname + path_to_file)\n })\n line_reader.on('line', (line) => {\n result.push(line)\n })\n line_reader.on('close', () => {\n resolve(result)\n })\n })\n }", "function readFile(fileEntry) {\n // Get the file from the file entry\n fileEntry.file(function (file) { \n // Create the reader\n var reader = new FileReader();\n reader.readAsText(file);\n reader.onloadend = function() {\n console.log(\"Successful file read: \" + reader.result);\n document.getElementById('dataObj').innerHTML = reader.result;\n console.log(\"file path: \" + fileEntry.fullPath);\n };\n });\n }", "function readFromFile(file) {\n return new Promise((resolve, reject) => {\n fs.readFile(file, function (err, data) {\n if (err) {\n console.log(err);\n reject(err);\n }\n else {\n resolve(JSON.parse(data));\n }\n });\n });\n}", "function read_file(filepath, cb) {\n var param = { fsid: fsid, path: filepath };\n ajax(service_url.read, param, function(err, filecontent, textStatus, jqXHR) {\n if (err) return cb(err);\n if (jqXHR.status != 200) {\n var msg;\n switch (jqXHR.status) {\n case 404:\n msg = lang('s0035'); break;\n case 406:\n msg = lang('s0036'); break;\n case 400:\n msg = lang('s0037'); break;\n default:\n msg = 'Code ' + jqXHR.status +' -- '+ textStatus;\n }\n return cb(new Error(lang('s0038')+ ': '+ filepath+ ', '+ msg));\n }\n var mimetype = jqXHR.getResponseHeader('Content-Type');\n var uptime = jqXHR.getResponseHeader('uptime');\n cb(null, filecontent, uptime, mimetype);\n });\n }", "function read(path,method) {\n method = method || 'readAsText';\n return file(path).then(function(fileEntry) {\n return new Promise(function(resolve,reject){\n fileEntry.file(function(file){\n var reader = new FileReader();\n reader.onloadend = function(){\n resolve(this.result);\n };\n reader[method](file);\n },reject);\n });\n });\n }", "getFileContent(path: string) {\n fs.readFile(path, 'utf8', (err, data) => {\n this.editorContentCallback(data, path);\n });\n }", "readFile(filePath) {\n return RNFetchBlob.fs.readFile(filePath, 'utf8');\n }", "function readJSONFile(file)\n{ var allText\n var rawFile = new XMLHttpRequest();\n rawFile.open(\"GET\", file, false);\n rawFile.onreadystatechange = function ()\n {\n if(rawFile.readyState === 4)\n {\n if(rawFile.status === 200 || rawFile.status == 0)\n {\n allText = rawFile.responseText;\n }\n }\n }\n rawFile.send(null);\n return allText;\n}", "function loadFile(filePath) {\n var result = null;\n var xmlhttp = new XMLHttpRequest();\n xmlhttp.open(\"GET\", filePath, false);\n xmlhttp.send();\n if (xmlhttp.status==200) {\n result = xmlhttp.responseText;\n }\n return result;\n}", "function rFile (file) {\n fs.readFile(file, 'utf8', function (err, data) {\n if (err) {\n return console.log(err);\n }\n console.log(data);\n });\n}", "function loadFile(filePath) {\n var result = null;\n var xmlhttp = new XMLHttpRequest();\n xmlhttp.open(\"GET\", filePath, false);\n xmlhttp.send();\n if (xmlhttp.status==200) {\n result = xmlhttp.responseText;\n }\n return result;\n }", "function readAllFromFile(fname) {\n var fso = new ActiveXObject(\"Scripting.FileSystemObject\");\n var file = null;\n try {\n file = fso.OpenTextFile(fname, 1, 0);\n return (file.readAll());\n } finally {\n // Close the file in the finally section to guarantee that it will be closed in any case\n // (if the exception is thrown or not).\n file.Close();\n }\n}", "_read () {\n let { filename } = this\n return new Promise((resolve, reject) =>\n fs.readFile((filename), (err, content) => err ? reject(err) : resolve(content))\n ).then(JSON.parse)\n }", "static readFile(path) {\n path = pathHelper.resolve(path);\n logger.debug('Checking data file: ' + path);\n\n return fs.readFileSync(path, 'utf8');\n }", "fileCall(path) {\n var fileStream = require('fs');\n var f = fileStream.readFileSync(path, 'utf8');\n return f;\n // var arr= f.split('');\n // return arr;\n }", "static readFile(filePath, options) {\n return FileSystem._wrapException(() => {\n options = Object.assign(Object.assign({}, READ_FILE_DEFAULT_OPTIONS), options);\n let contents = FileSystem.readFileToBuffer(filePath).toString(options.encoding);\n if (options.convertLineEndings) {\n contents = Text_1.Text.convertTo(contents, options.convertLineEndings);\n }\n return contents;\n });\n }", "readin () {\n this.content = readFile(this.path);\n }", "function loadFile(filePath) {\r\n var result = null;\r\n var xmlhttp = new XMLHttpRequest();\r\n xmlhttp.open(\"GET\", filePath, false);\r\n xmlhttp.send();\r\n if (xmlhttp.status === 200) {\r\n result = xmlhttp.responseText;\r\n }\r\n return result;\r\n}" ]
[ "0.790714", "0.77232456", "0.75610566", "0.7484739", "0.7429082", "0.7402849", "0.70870584", "0.70229805", "0.69181293", "0.68460333", "0.68416864", "0.67938757", "0.67254823", "0.6645344", "0.6645003", "0.66349036", "0.66026247", "0.6600203", "0.65757376", "0.64575833", "0.6452056", "0.643963", "0.640745", "0.63999444", "0.6373837", "0.63723165", "0.636517", "0.6363997", "0.63458556", "0.63346595", "0.63185036", "0.63165766", "0.6312703", "0.63123506", "0.6282988", "0.6278201", "0.6268859", "0.62541246", "0.6198028", "0.6191339", "0.6178407", "0.6176599", "0.61718476", "0.61388934", "0.6133638", "0.61291206", "0.61133814", "0.60887736", "0.6076457", "0.60459894", "0.6045023", "0.60406375", "0.6040145", "0.60380685", "0.60315335", "0.60185903", "0.60142004", "0.6011808", "0.6002801", "0.597518", "0.5960802", "0.59603184", "0.59591466", "0.59254557", "0.592023", "0.59147805", "0.5906467", "0.5901174", "0.5884886", "0.58693415", "0.586764", "0.5862089", "0.5860128", "0.5860012", "0.58583885", "0.584551", "0.5845253", "0.58430564", "0.5836899", "0.58321077", "0.5823499", "0.58213454", "0.58101517", "0.5807126", "0.58054304", "0.5796165", "0.57935065", "0.57916695", "0.57909703", "0.57864887", "0.5786416", "0.5786127", "0.5763726", "0.57557243", "0.5753459", "0.5751203", "0.5733438", "0.5717191", "0.57156", "0.5714189", "0.5713314" ]
0.0
-1
Sets the contents of a file.
write(file, contents) { // validate input if (!isString(file)) throw new TypeError('Expected file to be a string; got: ' + typeof file); if (isString(contents)) contents = new Buffer(contents); else if (contents !== null && !Buffer.isBuffer(contents)) { throw new TypeError('Exected contents to be a buffer, string or null; got: ' + typeof contents); } // check what the old contents was before updating it const oldContents = this.read(file); // update our record of this file's contents if (contents) this[FILES][file] = contents; else delete this[FILES][file]; // decide change type, if any let type; if (oldContents) { if (contents) { if (!bufferEqual(oldContents, contents)) type = 'modify'; } else type = 'delete'; } else if (contents) type = 'add'; // respond with a change object, if it changed if (type) { const change = new Change({file, contents, oldContents, type}); this.emit('change', change); return change; } return null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "set file(value) { this._file = value; }", "setFileContent(newValue) {\n this._fileContent = newValue;\n }", "setFile(file) {\n this.file = file;\n }", "set file(value) {\n this._file = value;\n this.renderImage();\n }", "function setFile(url){\n\tfile = url;\n}", "setFileContents(files) {\n for(let entry of files) {\n this.stream.writeFixedString(entry.data, false);\n }\n }", "readin () {\n this.content = readFile(this.path);\n }", "setContent(content) {\r\n return this.clone(File, \"$value\", false).postCore({\r\n body: content,\r\n headers: {\r\n \"X-HTTP-Method\": \"PUT\",\r\n },\r\n }).then(_ => new File(this));\r\n }", "setFileBuffer(fileBuffer) {\n this.fileBuffer = fileBuffer;\n }", "setFile(name, file) {\n this.zone[name].clearRecords()\n this.zone[name].fromFile(file)\n return this\n }", "setPath(path) {\n this.filePath = path;\n }", "setFile(blob, filename) {\n this.props.callSetFile(blob, filename);\n }", "apply(contents) {\n this.filePointer.apply(contents);\n return this;\n }", "function updateTextFromFile(file) {\n return new Promise((resolve, reject) => {\n var contents_textfield = document.getElementById('contents_textfield');\n readBlobAsText(file).then(text => {\n contents_textfield.value = text;\n resolve();\n }, err => reject(err));\n });\n}", "sendFile_() {\n var content = this.file;\n var end = this.file.size;\n\n if (this.offset || this.chunkSize) {\n // Only bother to slice the file if we're either resuming or uploading in chunks\n if (this.chunkSize) {\n end = Math.min(this.offset + this.chunkSize, this.file.size);\n }\n content = content.slice(this.offset, end);\n }\n\n var xhr = new XMLHttpRequest();\n xhr.open(\"PUT\", this.url, true);\n xhr.setRequestHeader(\"Content-Type\", this.contentType);\n xhr.setRequestHeader(\n \"Content-Range\",\n \"bytes \" + this.offset + \"-\" + (end - 1) + \"/\" + this.file.size\n );\n xhr.setRequestHeader(\"X-Upload-Content-Type\", this.file.type);\n if (xhr.upload) {\n xhr.upload.addEventListener(\"progress\", this.onProgress);\n }\n xhr.onload = this.onContentUploadSuccess_.bind(this);\n xhr.onerror = this.onContentUploadError_.bind(this);\n xhr.send(content);\n }", "function contentWrite(file) {\n console.log(\"Writing file contents\");\n\n const fs = require(\"fs\");\n const writeFile = require('when/node').lift(fs.writeFile);\n writeFile(\"tmp/extracted.\" + file.ext, file.binary)\n .then(function (result) {\n console.log(\"Successfully created file\");\n })\n .catch(function (err) {\n console.log(err);\n });\n}", "async function updateFile(fileId, content) {\n return await $.ajax({\n url: domain + \"/file/\" + encodeURIComponent(fileId),\n method: \"PUT\",\n data: content,\n });\n }", "function remoteSetContentAfterOpen(filepathArg) {\n\tvar hasExecuted = false; //closure variable\n\n\tif (!hasExecuted) { //if never executed before (aka if hasExecuted has still the value it was initialized with)\n\t\thasExecuted = true; //set it to true to prevent execution next time\n\t\tfilepath = filepathArg;\n\t\tfs.readFile(filepathArg, function (err, data) {\n\t\t\tif (err) {\n\t\t\t\tconsole.log(\"Read failed: \" + err);\n\t\t\t}\n\t\t\tsetContent(data);\n\t\t});\n\t} else {\n\t\tconsole.log(\"remoteSetContentAfterOpen can only be called once to prevent resetting content accidently\")\n\t}\n}", "function writeFile(filePath) {\n try {\n fs.writeFile(filePath, file.content, function (error) {\n // ERRO\n if (error) throw error\n // ARQUIVO SALVO\n file.path = filePath\n file.saved = true\n file.name = path.basename(filePath)\n\n mainWindow.webContents.send('set-file', file)\n })\n } catch (e) {\n console.log(e)\n }\n}", "setIn(path, value) {\n if (isEmptyPath(path))\n this.contents = value;\n else if (this.contents == null) {\n this.contents = collectionFromPath(this.schema, Array.from(path), value);\n }\n else if (assertCollection(this.contents)) {\n this.contents.setIn(path, value);\n }\n }", "async setFile(output, path) {\n const type = Path.extname(path).substring(1);\n const file = Path.join(this.settings.directory, path);\n const mime = this.settings.strict ? this.settings.types[type] : this.settings.types[type] || 'application/octet-stream';\n if (!mime || !Fs.existsSync(file) || !Fs.lstatSync(file).isFile()) {\n response_1.Response.setStatus(output, 404);\n }\n else {\n response_1.Response.setStatus(output, 200);\n response_1.Response.setContent(output, await Util.promisify(Fs.readFile)(file), mime);\n }\n }", "async setFile({path, data, contentType, encoding, sensitivity, credentials}) {\n credentials = credentials || this.credentials\n await this.ensureIndexLoaded()\n this.ensurePermission({path, credentials, write: true})\n\n path = u.packKeys(path)\n\n // Generate fileID, store it on the index, set nodetype\n let fileID = u.uuid()\n this.index.setNodeType(path, u.NT_S3REF)\n this.index.setNodeProperty(path, 'fileID', fileID)\n this.index.setDontDelete(path, true)\n \n // Write the file to s3, write the url to the node\n let ref = await this.s3Client.write({key: fileID, body: data, contentType, encoding})\n let attributes = {}\n attributes[path] = ref\n await this.set({attributes, sensitivity})\n return ref\n }", "function setcurrentFile(file) {\n\tfs.readdir(path.resolve(__dirname, \"../\", \"asciiArt\"), function (err, items) {\n\t\tif (err) {\n\t\t\tconsole.log(err);\n\t\t} else {\n\t\t\t// To validate the text file with filename 'file' exists in the folder\n\t\t\tif (\n\t\t\t\titems.find(\n\t\t\t\t\titem => item.replace(\".txt\", \"\") === file || (file.includes(\".txt\") && file === item)\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tfs.readFile(\n\t\t\t\t\tpath.resolve(__dirname, \"../\", \"main.json\"),\n\t\t\t\t\t\"utf8\",\n\t\t\t\t\tfunction readFileCallback(err, data) {\n\t\t\t\t\t\tif (err) {\n\t\t\t\t\t\t\tconsole.log(err);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tvar obj = JSON.parse(data); //now it is an object\n\t\t\t\t\t\t\tobj.currentFile = file; //add updated file data\n\t\t\t\t\t\t\tvar json = JSON.stringify(obj); //convert it back to string json\n\t\t\t\t\t\t\tfs.writeFile(\n\t\t\t\t\t\t\t\tpath.resolve(__dirname, \"../\", \"main.json\"),\n\t\t\t\t\t\t\t\tjson,\n\t\t\t\t\t\t\t\t\"utf8\",\n\t\t\t\t\t\t\t\tfunction writeFileCallback(err) {\n\t\t\t\t\t\t\t\t\tif (err) {\n\t\t\t\t\t\t\t\t\t\tconsole.log(err);\n\t\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t\tconsole.log(\n\t\t\t\t\t\t\t\t\t\t\tchalk.keyword(\"green\")(\n\t\t\t\t\t\t\t\t\t\t\t\t\"Successfully swapped file to \" + file\n\t\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t);\n\t\t\t} else {\n\t\t\t\tconsole.log(\n\t\t\t\t\tchalk.keyword(\"red\")(\n\t\t\t\t\t\t\"File does not exist, please create a text file matching that name\"\n\t\t\t\t\t)\n\t\t\t\t);\n\t\t\t\tconsole.log(\"Files: \");\n\t\t\t\titems.forEach(item => {\n\t\t\t\t\tconsole.log(\n\t\t\t\t\t\t\"Name: \" +\n\t\t\t\t\t\tchalk.keyword(\"green\")(item.replace(\".txt\", \"\")) +\n\t\t\t\t\t\t\" Filename: \" +\n\t\t\t\t\t\tchalk.keyword(\"green\")(item)\n\t\t\t\t\t);\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\t});\n}", "setContents ({ commit }, data) {\n commit(\n 'setContents',\n data\n )\n }", "setIn(path, value) {\n if (Collection.isEmptyPath(path)) {\n // @ts-expect-error We can't really know that this matches Contents.\n this.contents = value;\n }\n else if (this.contents == null) {\n // @ts-expect-error We can't really know that this matches Contents.\n this.contents = Collection.collectionFromPath(this.schema, Array.from(path), value);\n }\n else if (assertCollection(this.contents)) {\n this.contents.setIn(path, value);\n }\n }", "function writeFile(file, content) {\n\tvar writer = new java.io.FileWriter(file);\n\twriter.write(content);\n\twriter.close();\n}", "function WriteFile(path, contents)\n{\n\t_fs.writeFileSync(path, contents, \"utf8\");\n}", "function editFile(file, currentPlayer) {\n\n let fs = require('fs');\n\n // read the given file \n fs.readFile('./public/files/' + file, 'utf-8', function(err, data){\n if (err) throw err;\n \n // change username and password to correct values \n let username = currentPlayer.opponent;\n let password = currentPlayer.opponentPassword; \n\n let user_start = data.indexOf('<USERNAME>') + 10;\n let user_end = data.indexOf('</USERNAME>'); \n data = data.replaceBetween(user_start, user_end, username);\n\n let pass_start = data.indexOf('<PASSWORD>') + 10; \n let pass_end = data.indexOf('</PASSWORD>'); \n data = data.replaceBetween(pass_start, pass_end, password);\n // data = data.replace('[USER]', username);\n // data = data.replace('[PASS]', password);\n\n // write/return the new changed file \n fs.writeFile('./public/files/' + file, data, 'utf-8', function (err) {\n if (err) throw err;\n });\n });\n}", "function onChangeFile(event) {\n var files = event.target.files;\n readFile(files);\n }", "constructor(file) {\n this._file = file\n this.size = file.size\n }", "static io_setfile(filename, base64ContentStr, fcn) {\n if (window.Settings.enableLog)\n WebUtils.log(\"Web.io_setfile({0},{1})\".format(filename, base64ContentStr));\n Database.setfile(filename, base64ContentStr, fcn);\n }", "function setData() {\n return through.obj((file, _enc, cb) => {\n file.data = {\n title: 'Greetings!',\n };\n cb(null, file);\n });\n}", "function handleFileChange(event) {\n file.current = event.target.files[0];\n }", "function changeFile(event){\n const file = event.target.files[0]\n if(file){\n setFile({file})\n }\n }", "setToRemoteFile(file, originalFileName = origFileNameDefault) {\n let [ssName, storageService] = getStorageService();\n this._obj.state = remote_file;\n this._obj.location = file;\n this._obj.originalFileName = originalFileName;\n this._obj.ss = ssName;\n }", "function read$2(context, file, fileSet, next) {\n var filePath = file.path;\n\n if (file.contents || file.data.unifiedEngineStreamIn) {\n debug$a('Not reading file `%s` with contents', filePath);\n next();\n } else if (stats$7(file).fatal) {\n debug$a('Not reading failed file `%s`', filePath);\n next();\n } else {\n filePath = path$6.resolve(context.cwd, filePath);\n\n debug$a('Reading `%s` in `%s`', filePath, 'utf8');\n fs$6.readFile(filePath, 'utf8', onread);\n }\n\n function onread(error, contents) {\n debug$a('Read `%s` (error: %s)', filePath, error);\n\n file.contents = contents || '';\n\n next(error);\n }\n}", "setToLocalFile(filename, originalFileName=null) {\n this._obj.state = local_file;\n this._obj.location = filename;\n this._obj.originalFileName = originalFileName || path.basename(filename);\n }", "set(key, value) {\n if (this.contents == null) {\n this.contents = collectionFromPath(this.schema, [key], value);\n }\n else if (assertCollection(this.contents)) {\n this.contents.set(key, value);\n }\n }", "setContent(content) {\r\n return this.clone(AttachmentFile, \"$value\", false).postCore({\r\n body: content,\r\n headers: {\r\n \"X-HTTP-Method\": \"PUT\",\r\n },\r\n }).then(_ => new AttachmentFile(this));\r\n }", "function writefile(){\n\t\t\tvar txtFile = \"c:/test.txt\";\n\t\t\tvar file = new File([\"\"],txtFile);\n\t\t\tvar str = \"My string of text\";\n\n\t\t\tfile.open(\"w\"); // open file with write access\n\t\t\tfile.writeln(\"First line of text\");\n\t\t\tfile.writeln(\"Second line of text \" + str);\n\t\t\tfile.write(str);\n\t\t\tfile.close();\n\t\t}", "function FileSource(file) {\n _classCallCheck$3(this, FileSource);\n this._file = file;\n this.size = file.size;\n }", "function File(filepath, html) {\n\n // If html argument has not been set, set to true\n if(html === undefined) html = true;\n\n // File properties\n this.filePath = filepath;\n this.fileName = this.getName();\n this.fileType = this.getType();\n this.fileExtension = this.getExtension();\n this.fileContents = '';\n this.fileContentsArray;\n\n // Read file\n // this.read(this.filePath, function(err, data) {\n // if(html) this.fileContents = replaceAll(data, ['<', '>'], ['&lt;', '&gt;']);\n // this.fileContentsArray = data.split('\\n');\n // }.bind(this));\n this.readSync(this.filePath, html);\n}", "open(file) {\n this.file = file;\n this.input = this.file.input;\n this.state = new State();\n this.state.init(this.options, this.file);\n }", "function processSelectedFile(filePath, requestingField) {\n $('#' + requestingField).val(filePath).trigger('change');\n}", "function readFile(filepath) {\n fs.readFile(filepath, 'utf-8', function (err, data) {\n if (err) {\n alert(\"An error ocurred reading the file :\" + err.message);\n return;\n }\n // Change how to handle the file content\n content = data;\n // console.log(\"The file content is : \" + data);\n document.getElementById(\"content-editor\").value = content;\n });\n}", "function openFile(targetWindow, file) {\n\tconst content = fs.readFileSync(file).toString();\n\ttargetWindow.webContents.send('file-opened', file, content);\n}", "set store_file(file_or_fullPath) {\n //\n // file_or_fullPath is a Json file\n if (file_or_fullPath) {\n // ignore if already set\n if (this._store === file_or_fullPath) {\n return;\n }\n this._store = file_or_fullPath;\n return;\n }\n //\n // Else file_or_fullPath is a string full_path\n // ignore if already set\n if (this._store.full_path === file_or_fullPath) {\n return;\n }\n this._store = new Json_File({\n full_path: file_or_fullPath,\n });\n }", "setEntry(entry) {\n this.stream.writeString(entry.filename);\n this.stream.writeFixedString(entry.method);\n this.stream.writeInt(entry.originalSize);\n this.stream.writeInt(entry.reserved);\n this.stream.writeInt(entry.timestamp);\n this.stream.writeInt(entry.dataSize);\n }", "function newFile() {\n\teditor.reset();\n\tpathToFileBeingEdited = undefined;\n\tparse();\n}", "function write_file(aFilePath, aContents, aFileMode) {\n var mode = PR_TRUNCATE;\n if (!aFileMode) aFileMode = 0600;\n var outfile = getFileFromPath(aFilePath);\n if (!outfile.exists()) {\n outfile.create(CI.nsIFile.NORMAL_FILE_TYPE, aFileMode);\n }\n var outStream = CC[\"@mozilla.org/network/file-output-stream;1\"]\n .createInstance(CI.nsIFileOutputStream);\n outStream.init(outfile, PR_WRONLY | PR_CREATE_FILE | mode, aFileMode, 0);\n outStream.write(aContents, aContents.length);\n outStream.close();\n}", "function openFile(content, fileExtension) {\n var counter = 1;\n var doc = DocumentManager.createUntitledDocument(counter, fileExtension);\n doc.setText(content);\n }", "function saveFile(file, contents){\n\t\tlet fs = require('fs');\n\t\tfs.writeFileSync(file, JSON.stringify(contents));\n\t}", "function writeFile(host, fileId, contents) {\n var url = host + '/file/' + extensionKey + '/' + fileId;\n return fetch(url, {\n method: 'POST',\n headers: {\n 'Content-Type': 'text/plain',\n },\n body: contents,\n });\n}", "function readFile(inputFile) {\n var fr = new FileReader();\n fr.onload = function(e) {\n $(\"#hiddenFile\").val(e.target.result);\n };\n fr.readAsText(inputFile);\n}", "writeFile(new_file, content) {\n console.log('Writing to ' + new_file);\n fs.writeFile(new_file, content, 'utf8', (err) => {\n if (err)\n return console.log(err);\n });\n }", "set(key, value) {\n if (this.contents == null) {\n // @ts-expect-error We can't really know that this matches Contents.\n this.contents = Collection.collectionFromPath(this.schema, [key], value);\n }\n else if (assertCollection(this.contents)) {\n this.contents.set(key, value);\n }\n }", "static init() {\n fs.writeFile(file, '{}');\n }", "function bufferContents( file ){\n if (file.isNull()) return; // ignore\n if (file.isStream()) return this.emit( 'error', new PluginError( 'gulp-kss', 'Streaming not supported' ));\n\n if (!firstFile) firstFile = file;\n\n buffer.push(file.contents.toString( 'utf8' ));\n }", "updateDataFile() {\n\t\tthis.getDataFile()\n\t\t.then(() => this.getClient());\n\t}", "function FileSource(file) {\n _classCallCheck(this, FileSource);\n\n this._file = file;\n this.size = file.size;\n }", "changeVersion({ filePath, version, replacingTag }) {\n logger.section(`Set '${version}' as version in ${filePath}`);\n let versionFile = fs.readFileSync(filePath, 'utf-8');\n this.checkReplacingTag({\n filePath,\n replacingTag,\n checkBuildTask: false\n });\n try {\n let newVersionFile = versionFile.replace(replacingTag, version);\n versionFile = newVersionFile;\n fs.writeFileSync(filePath, versionFile, 'utf-8');\n }\n catch (err) {\n logger.error(err);\n }\n }", "set(key, val) {\n this.data[key] = val;\n // Wait, I thought using the node.js' synchronous APIs was bad form?\n // We're not writing a server so there's not nearly the same IO demand on the process\n // Also if we used an async API and our app was quit before the asynchronous write had a chance to complete,\n // we might lose that data. Note that in a real app, we would try/catch this.\n fs.writeFileSync(this.path, JSON.stringify(this.data));\n }", "getFileContents() {\n for (let entry of this.files) {\n entry.data = this.stream.getFixedString(entry.size);\n }\n }", "function File() {\n _classCallCheck(this, File);\n\n File.initialize(this);\n }", "set contents(aContents) {\n // If there are already some contents displayed, replace them.\n if (this._target.hasChildNodes()) {\n this._target.replaceChild(aContents, this._target.firstChild);\n return;\n }\n // These are the first contents ever displayed.\n this._target.appendChild(aContents);\n }", "set contents(aContents) {\n // If there are already some contents displayed, replace them.\n if (this._target.hasChildNodes()) {\n this._target.replaceChild(aContents, this._target.firstChild);\n return;\n }\n // These are the first contents ever displayed.\n this._target.appendChild(aContents);\n }", "function saveFile(file, contents){\n\tlet fs = require('fs');\n\tfs.writeFileSync(file, JSON.stringify(contents));\n}", "function templateSet(file, template, header, offset){\r\n\tvar view = new DataView(file.buffer);\r\n\ttemplate.forEach(function(item){\r\n\t\tvar value = item.name ? header[item.name] : item.value;\r\n\t\tvar arg = item.arg===undefined ? true : item.arg;\r\n\t\tview[\"set\"+item.type](item.pos+ +offset,value,arg);\r\n\t});\r\n}", "file(path) {\n\t\tif (typeof path !== 'string') {\n\t\t\tthrow new Error('The \"path\" parameter must be a string');\n\t\t}\n\t\t// just reuse the path name as the store name...will be unique\n\t\tthis.reorderFileStores(path);\n\t}", "function uploadFile(){\n var fileToLoad = document.getElementById(\"fileToLoad\").files[0];\n\n var fileReader = new FileReader();\n fileReader.onload = function(fileLoadedEvent) \n {\n var textFromFileLoaded = fileLoadedEvent.target.result;\n document.getElementById(\"content\").value = textFromFileLoaded;\n };\n fileReader.readAsText(fileToLoad, \"UTF-8\");\n }", "function updateFileInCache(options, filePath, contents, instance) {\n let fileWatcherEventKind;\n // Update file contents\n const key = instance.filePathKeyMapper(filePath);\n let file = instance.files.get(key);\n if (file === undefined) {\n file = instance.otherFiles.get(key);\n if (file !== undefined) {\n if (!(0, utils_1.isReferencedFile)(instance, filePath)) {\n instance.otherFiles.delete(key);\n instance.files.set(key, file);\n instance.changedFilesList = true;\n }\n }\n else {\n if (instance.watchHost !== undefined) {\n fileWatcherEventKind = instance.compiler.FileWatcherEventKind.Created;\n }\n file = { fileName: filePath, version: 0 };\n if (!(0, utils_1.isReferencedFile)(instance, filePath)) {\n instance.files.set(key, file);\n instance.changedFilesList = true;\n }\n }\n }\n if (instance.watchHost !== undefined && contents === undefined) {\n fileWatcherEventKind = instance.compiler.FileWatcherEventKind.Deleted;\n }\n // filePath is a root file as it was passed to the loader. But it\n // could have been found earlier as a dependency of another file. If\n // that is the case, compiling this file changes the structure of\n // the program and we need to increase the instance version.\n //\n // See https://github.com/TypeStrong/ts-loader/issues/943\n if (!(0, utils_1.isReferencedFile)(instance, filePath) &&\n !instance.rootFileNames.has(filePath) &&\n // however, be careful not to add files from node_modules unless\n // it is allowed by the options.\n (options.allowTsInNodeModules || filePath.indexOf('node_modules') === -1)) {\n instance.version++;\n instance.rootFileNames.add(filePath);\n }\n if (file.text !== contents) {\n file.version++;\n file.text = contents;\n file.modifiedTime = new Date();\n instance.version++;\n if (instance.watchHost !== undefined &&\n fileWatcherEventKind === undefined) {\n fileWatcherEventKind = instance.compiler.FileWatcherEventKind.Changed;\n }\n }\n // Added in case the files were already updated by the watch API\n if (instance.modifiedFiles && instance.modifiedFiles.get(key)) {\n fileWatcherEventKind = instance.compiler.FileWatcherEventKind.Changed;\n }\n if (instance.watchHost !== undefined && fileWatcherEventKind !== undefined) {\n instance.hasUnaccountedModifiedFiles =\n instance.watchHost.invokeFileWatcher(filePath, fileWatcherEventKind) ||\n instance.hasUnaccountedModifiedFiles;\n }\n // push this file to modified files hash.\n if (!instance.modifiedFiles) {\n instance.modifiedFiles = new Map();\n }\n instance.modifiedFiles.set(key, true);\n return file.version;\n}", "function serveFile(sekiResponse, status, file) {\n\tverbosity(\"FILE = \" + file);\n\n\tfs.readFile(file, function(err, data) {\n\t\tif (err) {\n\t\t\tdata = \"Error :\" + err;\n\t\t\tstatus = 500;\n\t\t}\n\t\tsekiResponse.writeHead(status, sekiHeaders); // queryResponse.headers\n\t\tsekiResponse.write(data, 'binary');\n\t\tsekiResponse.end();\n\t});\n}", "setDirty(settingsFile, dirty) {\r\n if (!dirty) {\r\n // Remove the settings file from the dirty settings array if present\r\n const index = this.dirtySettings.indexOf(settingsFile);\r\n if (index !== -1)\r\n this.dirtySettings.splice(index, 1);\r\n }\r\n else {\r\n // Add the settings file to the dirty settings array if it isn't in there yet\r\n const index = this.dirtySettings.indexOf(settingsFile);\r\n if (index === -1)\r\n this.dirtySettings.push(settingsFile);\r\n }\r\n }", "function setData(fileData) {\n if (Object(fileData) === fileData) {\n var propertyValue;\n\n for (var p in fileData) {\n if (fileData.hasOwnProperty(p)) {\n propertyValue = fileData[p];\n\n switch (p) {\n case \"id\":\n case \"fileId\":\n if (id && propertyValue !== id)\n throw new Error(\"Can't change ID for a FileData object.\");\n\n id = propertyValue;\n break;\n case \"file\":\n this.cloudUrl = propertyValue.url();\n case \"thumbnail\":\n this.cloudThumbnailUrl = propertyValue.url();\n case \"file\":\n case \"thumbnail\":\n this.requireDownload = true;\n break;\n case \"mimeType\":\n if (Object(propertyValue) === propertyValue)\n this.mimeType = propertyValue;\n else\n this.mimeType = FileData.mimeTypes.index[propertyValue];\n\n break;\n default:\n this[p] = propertyValue;\n }\n }\n }\n\n if (this.localUrl === undefined) {\n this.localUrl = null;\n this.localThumbnailUrl = null;\n }\n }\n else if (typeof(fileData) === \"string\") {\n id = fileData;\n this.fillData(id);\n }\n else\n throw new Error(\"Invalid data for FileData, must be either object or string representing the FileData's ID.\");\n }", "function update_file(file) {\n var file_button = document.getElementById(\"file-button\");\n document.getElementById(\"filename\").innerHTML = file.name;\n file_button.innerHTML = \"open file\";\n file_button.className = \"mat-button mdc-button mdc-button--raised blue-button\";\n mdc.ripple.MDCRipple.attachTo(file_button);\n opened_file = file;\n}", "function writeFile(file, input_stream) {\n var tmpStream = Components.classes[\"@mozilla.org/network/file-output-stream;1\"\n ].createInstance(Components.interfaces.nsIFileOutputStream);\n\n // 0x02 | 0x20 = WRITE_ONLY | TRUNCATE (recommended by the documentation)\n tmpStream.init(file, 0x02 | 0x20, 0666, 0);\n\n var converter = Components.classes[\"@mozilla.org/intl/converter-output-stream;1\"\n ].createInstance(Components.interfaces.nsIConverterOutputStream);\n converter.init(tmpStream, \"UTF-8\", 0, 0);\n\n var chunk_size = 1024;\n while (input_stream.available()) {\n converter.writeString(input_stream.read(chunk_size));\n }\n\n converter.close();\n}", "setFileDetector() {}", "function writeFile() {\n const ERR_MESS_WRITE = \"TODO: Trouble writing file\";\n\n todocl.dbx.filesUpload({\n contents: todocl.todoText,\n path: todocl.path,\n mode: 'overwrite',\n autorename: false,\n mute: true\n }).then(function (response) {\n\n }).catch(function (error) {\n todocl.dbx.accessToken = null;\n todocl.out.innerHTML = ERR_MESS_WRITE;\n });\n }", "setIndexFile() {\n currentFile = this.getCurrentFile();\n if (currentFile === \"\") {\n atom.notifications.addWarning(\"Path of current File not available\", {\n detail: \"Could not set the index file\",\n dismissable: true\n });\n } else {\n atom.config.set('mcide.indexFile', currentFile);\n }\n }", "function set_tags(file_name) {\n fetch('articles/' + file_name + '.md')\n .then((res) => res.text())\n .then((text) => {\n process_tags(file_name, text);\n });\n}", "function File(stream) {\n this.stream = stream;\n this.closed = false;\n}", "function editFile(path) {\n fs.readFile(path, 'utf-8', function (err, data) {\n if (err) {\n log.error(\"Read file error:\" + err);\n } else {\n if (data.indexOf(oldName)) {\n var re = new RegExp(oldName, \"g\");\n if (data.indexOf(oldName) !== -1) {\n fs.writeFile(path, data.replace(re, newName), function (err) {\n if (err) {\n log.error('Modify file failure' + err);\n } else {\n log.info('Modify file success' + path);\n }\n });\n }\n }\n }\n });\n}", "function _file (index) {\n\n\t\t\t\tthis.index = index;\n\t\t\t\t// initialize file\n\t\t\t\tthis.status = 1;\n\t\t\t\t// triggle callback list\n\t\t\t\tthis.Events = [];\n\n\t\t\t}", "setCurrentFile(absolutePath) {\n this.lastFilePathSet = absolutePath;\n }", "function modifyAudio(file){\n document.getElementById('audio').src = file;\n\n}", "setFileID(e) {\n this.fileID = e.target.value;\n this.contenBodyId=this.fileDetails[e.target.value+'contenBodyId'];\n this.versionId=this.fileDetails[e.target.value+'versionId'];\n this.fileExtension=this.fileDetails[e.target.value+'fileExtension'];\n this.versionData=this.fileDetails[e.target.value+'versionData'];\n\n }", "overwrite(path, content) {\n return this._base.overwrite(this._fullPath(path), content);\n }", "overwrite(path, content) {\n return this._base.overwrite(this._fullPath(path), content);\n }", "function saveFile(file, contents){\n\tlet fs = require('fs');\n\tlet data = fs.writeFileSync(file, JSON.stringify(contents));\n}", "get file () {\n return this._file\n }", "_setCache(key, value) {\n this.fileCache[key] = value;\n }", "function commentFile(fileID, text) {\n db.updateData('file', { id: fileID }, { $set: { comment: text } })\n}", "function loadFile() {\n dialog.showOpenDialog({ filters: [\n { name: 'txt', extensions: ['txt'] },\n ]}, function(filenames) {\n if(filenames === undefined) return;\n var filename = filenames[0];\n readFromFile(editor, filename);\n loadedfs = filename;\n })\n}", "function handleFileSelect(evt){\n var f = evt.target.files[0]; // FileList object\n window.reader = new FileReader();\n // Closure to capture the file information.\n reader.onload = (function(theFile){\n return function(e){\n editor.setData(e.target.result);\n evt.target.value = null; // allow reload\n };\n })(f);\n // Read file as text\n reader.readAsText(f);\n thisDoc = f.name;\n }", "_writeFile(filename, contents) {\n const tempFilename = filename + '.tmp.' + Random.id();\n try {\n fs.writeFileSync(tempFilename, contents);\n fs.renameSync(tempFilename, filename);\n } catch (e) {\n this._cacheDebug(e)\n // ignore errors, it's just a cache\n }\n }", "set(absPath, payload) {\n if (!this.enabled) {\n return;\n }\n this.cacheStore.set(absPath, payload);\n }", "async function reWrite() {\n await writeFile(`${dir}/testFile.txt`, 'Отсыпь кода на забивку');\n const data = String(fs.readFileSync(`${dir}/testFile.txt`));\n const arrayOfFiles = await readDir(dir);\n writeFile(`${dir}/${arrayOfFiles[0]}`, data);\n console.log('File was successfully rewritten');\n}", "getFileContent(path: string) {\n fs.readFile(path, 'utf8', (err, data) => {\n this.editorContentCallback(data, path);\n });\n }", "function fileSystem$2(context, file, fileSet, next) {\n var destinationPath;\n\n if (!context.output) {\n debug$2('Ignoring writing to file-system');\n return next()\n }\n\n if (!file.data.unifiedEngineGiven) {\n debug$2('Ignoring programmatically added file');\n return next()\n }\n\n destinationPath = file.path;\n\n if (!destinationPath) {\n debug$2('Cannot write file without a `destinationPath`');\n return next(new Error('Cannot write file without an output path'))\n }\n\n if (stats(file).fatal) {\n debug$2('Cannot write file with a fatal error');\n return next()\n }\n\n destinationPath = path$4.resolve(context.cwd, destinationPath);\n debug$2('Writing document to `%s`', destinationPath);\n\n file.stored = true;\n\n fs$4.writeFile(destinationPath, file.toString(), next);\n}", "function open_file(file) {\n $('#filebrowser').hide();\n\n \n $('#filename').val(file)\n\n var data = new FormData();\n data.append('filename', file);\n\n var xhr = new XMLHttpRequest();\n xhr.open('POST', '/openfile', true);\n xhr.onload = function (event) {\n r = JSON.parse(this.responseText);\n editor.setValue(r.text);\n server_last_modified_time = r.mtime;\n $('#menu_save').addClass('disable');\n };\n xhr.send(data);\n}" ]
[ "0.710111", "0.69011784", "0.67491597", "0.60025394", "0.5962338", "0.5741352", "0.5706499", "0.5573751", "0.5539292", "0.54850197", "0.5431247", "0.5369234", "0.529847", "0.52593386", "0.52385753", "0.52270186", "0.5182997", "0.51553184", "0.5150205", "0.5150192", "0.5131616", "0.5095263", "0.50907236", "0.50887966", "0.5081817", "0.50754184", "0.50679797", "0.50407845", "0.5022877", "0.5013733", "0.50105727", "0.49887577", "0.49883553", "0.4982263", "0.49808902", "0.4960887", "0.48950803", "0.48886147", "0.48729482", "0.4848164", "0.47992563", "0.47829646", "0.47738042", "0.47544822", "0.4716563", "0.47113279", "0.47049308", "0.47044766", "0.4680367", "0.4671702", "0.46636772", "0.46617684", "0.46545836", "0.46507695", "0.463516", "0.4626422", "0.46097434", "0.46082935", "0.46073", "0.46044776", "0.45865366", "0.45849755", "0.4582347", "0.45712766", "0.4570726", "0.4570726", "0.4567422", "0.4560231", "0.4554833", "0.4553282", "0.45454997", "0.45416006", "0.45151326", "0.45135763", "0.44979268", "0.4481399", "0.44770327", "0.4476252", "0.44762057", "0.44757077", "0.4472594", "0.4472505", "0.4469521", "0.44543606", "0.44523638", "0.44505647", "0.4442079", "0.4442079", "0.44417506", "0.44361278", "0.44351968", "0.44337642", "0.44225973", "0.4420068", "0.4413787", "0.44063243", "0.4405162", "0.44021073", "0.4398593", "0.4398551" ]
0.5394224
11
Returns an array of all the file paths currently in the virtual folder.
getAllPaths() { return Object.keys(this[FILES]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getAllFilePaths() {\n \n //holds all the file paths being tracked by storyteller\n var allFilePaths = [];\n \n //go through each file/dir mapping\n for(var filePath in pathToIdMap) {\n if(pathToIdMap.hasOwnProperty(filePath)) {\n \n //if the file exists in the allFiles collection we know it is a file\n if(allFiles[getIdFromFilePath(filePath)]) {\n allFilePaths.push(filePath); \n }\n }\n }\n \n return allFilePaths;\n}", "getFilePaths(dirPath){\n return new Promise( (resolve, reject) => {\n this.fspath.paths(dirPath, function(err, paths) {\n if (err) reject(err);\n resolve(paths);\n })\n })\n }", "function getPaths() {\n try {\n return require.cache ? Object.keys(require.cache) : [];\n }\n catch (e) {\n return [];\n }\n}", "function pathNames() {\n return getPathNames(urlBase.pathname);\n }", "getLocalResourceRoots() {\n const localResourceRoots = [];\n const workspaceFolder = vscode_1.workspace.getWorkspaceFolder(this.uri);\n if (workspaceFolder) {\n localResourceRoots.push(workspaceFolder.uri);\n }\n else if (!this.uri.scheme || this.uri.scheme === 'file') {\n localResourceRoots.push(vscode_1.Uri.file(path.dirname(this.uri.fsPath)));\n }\n // add vega preview js scripts\n localResourceRoots.push(vscode_1.Uri.file(path.join(this._extensionPath, 'scripts')));\n this._logger.logMessage(logger_1.LogLevel.Debug, 'getLocalResourceRoots():', localResourceRoots);\n return localResourceRoots;\n }", "getFiles() {\n const {\n files\n } = this.getState();\n return Object.values(files);\n }", "function getCurrentFilenames(dirPath) { \n let files = []\n // console.log(`Current files in: ${dirPath}`); \n fs.readdirSync(dirPath).forEach(file => { \n // console.log(\" \" + file);\n files.push(file)\n });\n return files\n}", "getAllFiles() {\n return this.cache.getOrAdd('getAllFiles', () => {\n let result = [];\n let dependencies = this.dependencyGraph.getAllDependencies(this.dependencyGraphKey);\n for (let dependency of dependencies) {\n //load components by their name\n if (dependency.startsWith('component:')) {\n let comp = this.program.getComponent(dependency.replace(/$component:/, ''));\n if (comp) {\n result.push(comp.file);\n }\n }\n else {\n let file = this.program.getFile(dependency);\n if (file) {\n result.push(file);\n }\n }\n }\n this.logDebug('getAllFiles', () => result.map(x => x.pkgPath));\n return result;\n });\n }", "getOwnFiles() {\n //source scope only inherits files from global, so just return all files. This function mostly exists to assist XmlScope\n return this.getAllFiles();\n }", "getFiles() {\n if (this._files) {\n return this._files;\n }\n this._files = glob.sync(`${this._changesPath}/**/*.json`);\n return this._files || [];\n }", "listFileNames(path) {\n return fs_1.readdirSync(path) || [];\n }", "function listFiles()\r\n{\r\n\tvar f = fso.GetFolder(curdir);\r\n\r\n\tfor(var fc = new Enumerator(f.Files);!fc.atEnd();fc.moveNext()){\r\n\t\t//\tIs this a good idea? making all file Paths relative to the FusionEngine directory?\r\n\t\tstats( relativeFilename(fc.item().Path) );\t\t\r\n\t}\r\n}", "function readFilePaths(files) {\n const locations = [];\n for (let i = 0; i < files.length; i++) {\n const file = files[i];\n const location = path.join(__dirname, \"../../../\", file);\n locations.push(location);\n }\n return locations;\n }", "function getRouteFilePaths(){\n return new Promise(\n (resolve, reject)=>{\n const controllerPath = path.join(__dirname, '..', 'controller')\n dir.files(controllerPath, (err, filePathArray)=>{\n if(err){\n return reject(err)\n }\n //console.log(filePathArray)\n resolve(filePathArray)\n });\n });\n}", "function pathNames() {\n return getPathNames(urlBase.pathname);\n }", "function extractVueFiles(folderPath) {\n let results = [];\n fs.readdirSync(folderPath).forEach((pathName) => {\n const computedPath = path.join(folderPath, pathName);\n const stat = fs.statSync(computedPath);\n if (stat && stat.isDirectory()) {\n results = results.concat(extractVueFiles(computedPath));\n } else if (path.extname(computedPath).toLowerCase() === '.vue') {\n results.push(computedPath);\n }\n });\n return results;\n}", "function files() {\n _throwIfNotInitialized();\n return props.files;\n}", "uris() {\n return this.files.keys();\n }", "files() {\n return [];\n }", "getFiles() {\n let files = this.state.cursor().get( 'files' )\n return files\n ? files.toList()\n : null\n }", "async getAllFilesOfLocalDirectoryRecursively(path){\n try{\n const items = await fs.promises.readdir(path).then(async data => {\n let files = [];\n for(let item of data){\n const isItemDir = await fs.promises.stat(`${path}/${item}`).then(stats => {return stats.isDirectory()}).catch(error => {return false;});\n if(isItemDir){\n const filesOfCurrentDir = await this.getAllFilesOfLocalDirectoryRecursively(`${path}/${item}`);\n files = [...files, ...filesOfCurrentDir];\n }else{\n files.push(`${path}/${item}`);\n }\n }\n\n return files;\n }).catch(error => {\n return [];\n });\n\n return items;\n }catch(error){ Logger.log(error); }\n\n return [];\n }", "async getDependentPaths() {\n return [];\n }", "function getAllDirPaths() {\n\t\t\n //holds all the dir paths being tracked by storyteller\n var allDirPaths = [];\n \n //go through each file/dir mapping\n for(var dirPath in pathToIdMap) {\n if(pathToIdMap.hasOwnProperty(dirPath)) {\n \n //if the dir exists in the allDirs collection we know it is a dir\n if(allDirs[getIdFromDirPath(dirPath)]) {\n allDirPaths.push(dirPath); \n }\n }\n }\n \n return allDirPaths;\n}", "function getArrSelectedFiles(){\r\n\t\t\r\n\t\tvar arrFiles = [];\r\n\t\tvar arrItems = getArrSelectedItems();\r\n\t\t\r\n\t\tjQuery.each(arrItems, function(index, item){\r\n\t\t\tarrFiles.push(item.file);\r\n\t\t});\r\n\t\t\r\n\t\treturn(arrFiles);\r\n\t}", "getFiles() { throw new Error('Should be overridden in subclass.') }", "function readFiles() {\n return fs.readdirAsync(pathPrevDir);\n}", "async function listFiles ({\n dir,\n gitdir = path__WEBPACK_IMPORTED_MODULE_0___default.a.join(dir, '.git'),\n fs: _fs\n}) {\n const fs = new FileSystem(_fs);\n let filenames;\n await GitIndexManager.acquire(\n { fs, filepath: `${gitdir}/index` },\n async function (index) {\n filenames = index.entries.map(x => x.path);\n }\n );\n return filenames\n}", "getFileNames() {\n return this._fileNames;\n }", "configFiles() {\n return this.storeId ? this.getConfigFiles(this.storeId) : [];\n }", "_listing(path) {\n\t\tconst statResult = new Promise((resolve, reject) => {\n\t\t\tfs.readdir(path, (error, fileList) => {\n\t\t\t\tresolve(fileList);\n\t\t\t\treject(error);\n\t\t\t});\n\t\t});\n\t\treturn statResult;\n\t}", "getPathNames() {\n return Object.keys(paths)\n }", "get files() {\n return this._files;\n }", "function readDir_getPaths(folder_path) {\n\treturn new Promise((resolve,reject) => {\n\t\tfs.readdir(folder_path, (err,files) => {\n\t\t\tif (err) {\n\t\t\t\treject(err);\n\t\t\t} else {\n\t\t\t\tresolve(JSON.stringify(files.map(file_name => folder_path + \"/\" + file_name)));\n\t\t\t}\n\t\t})\n\t})\n}", "toArray() {\r\n return this._paths.slice(0);\r\n }", "readdirCached() {\n const children = this.children();\n return children.slice(0, children.provisional);\n }", "GetAllScenePaths() {}", "function listFiles() {\n\t\n\t// git log --grep=hourly --name-only --pretty=\"format:\" --reverse --oneline | grep log\n\texec('cd ' + repoPath + ' && git log --grep=hourly --name-only --pretty=\"format:\" --reverse --oneline | grep log', function(err, stdout, stderr) {\n\t\tif (err || stderr)\n\t\t\tthrow err\n\t\telse {\n\t\t\t\n\t\t\tfiles = stdout.split('\\n').map(path => path.replace('data', 'data/raw'))\n\t\t\t\n\t\t\t//remove the last two invalid entry from the array\n\t\t\tfiles.pop()\n\t\t\t\n\t\t\t\n\t\t\tprogressScale.domain([0, files.length-1])\n\t\t\tconsole.log('files', files.length)\n\t\t\t//~console.log('last files', files[files.length-2])\n\t\t\t//~console.log('last files', files[files.length-1])\n\t\t\t\n\t\t\tconsole.log('...all files identified')\t\t\t\n\n\t\t\tnext()\n\t\t}\n\t})\n\t\n}", "function walkFolderCollect()\n\t\t{\n\t\t\tfunction collect(element)\n\t\t\t{\n\t\t\t\tpaths.push(element.path);\n\t\t\t}\n\n\t\t\tvar paths = [];\n\t\t\tUtils.walkFolder('{user}', collect);\n\t\t\tlist(paths)\n\t\t}", "function getFiles(srcpath) {\r\n return fs.readdirSync(srcpath);\r\n}", "function getListFiles() {\n console.log(this);\n return true;\n }", "async function getPathsToWatch(siteDir) {\n const context = await server_1.loadContext(siteDir);\n const pluginConfigs = server_1.loadPluginConfigs(context);\n const plugins = await init_1.default({\n pluginConfigs,\n context,\n });\n return lodash_1.flatten(plugins.map((plugin) => { var _a, _b; return (_b = (_a = plugin === null || plugin === void 0 ? void 0 : plugin.getPathsToWatch) === null || _a === void 0 ? void 0 : _a.call(plugin)) !== null && _b !== void 0 ? _b : []; }));\n}", "function getSrcFiles () {\n return Object.keys(this._.CHANGEMAP);\n}", "function getFiles(pattern) {\n const reportFiles = [];\n shelljs_shell.ls(pattern).forEach(function (file) {\n core.debug('file: ' + file);\n reportFiles.push(`${getWorkspaceDir()}/${file}`);\n });\n return reportFiles;\n}", "function getRealPaths(startPath) {\n // Check each folder in the wikis folder to see if it has a\n // tiddlywiki.info file\n let realFolders = [];\n try {\n const folderContents = fs.readdirSync(startPath);\n folderContents.forEach(function (item) {\n const fullName = path.join(startPath, item);\n if(fs.statSync(fullName).isDirectory()) {\n if($tw.ServerSide.wikiExists(fullName)) {\n realFolders.push(fullName);\n }\n // Check if there are subfolders that contain wikis and recurse\n const nextPath = path.join(startPath,item)\n if(fs.statSync(nextPath).isDirectory()) {\n realFolders = realFolders.concat(getRealPaths(nextPath));\n }\n }\n })\n } catch (e) {\n $tw.Bob.logger.log('Error getting wiki paths', e, {level:1});\n }\n return realFolders;\n }", "function refresh_asset_paths()\n{\n\t function walk(dir, done) {\n\t\tvar results = [];\n\t\ttry\n\t\t{\n\t\t\tvar list = fs.readdirSync(dir);\n\t\t\tvar i = 0;\n\n\t\t\t(function next() {\n\t\t\t var file = list[i++];\n\t\t\t if (!file) return done(null, results);\n\t\t\t file = dir + '/' + file;\n\t\t\t fs.stat(file, function(err, stat) {\n\t\t\t if (stat && stat.isDirectory()) {\n\t\t\t walk(file, function(err, res) {\n\t\t\t results = results.concat(res);\n\t\t\t next();\n\t\t\t });\n\t\t\t } else {\n\t\t\t results.push(file.replace('\\\\', '/').replace('static/', ''));\n\t\t\t next();\n\t\t\t }\n\t\t\t });\n\t\t\t})();\n\t\t}\n\t\tcatch(e)\n\t\t{\n\t\t\tconsole.error('Could not walk ' + dir + ' ' + e);\n\t\t}\n\t};\n\n\tasset_paths = [];\n\twalk('static/voxels', (err, paths) => { asset_paths = asset_paths.concat(paths); });\n\twalk('static/imgs', (err, paths) => { asset_paths = asset_paths.concat(paths); });\n\twalk('static/sounds', (err, paths) => { asset_paths = asset_paths.concat(paths); });\n\twalk('static/shaders', (err, paths) => { asset_paths = asset_paths.concat(paths); });\n\twalk('static/meshes', (err, paths) => { asset_paths = asset_paths.concat(paths); });\n}", "getLookupPaths() {\n return this.lookups.map(lookup => lookup.path.path());\n }", "static getRecentFiles(evt){\n let filePaths = FolderData.recentFilePaths;\n IpcResponder.respond(evt, \"files-recent\", {filePaths});\n }", "function getDirFiles(theDirectory){\n return new Promise($.async(function (resolve, reject) {\n try {\n $.fs.readdir(theDirectory, function (err, files) {\n if (err) {\n resolve([])\n }\n resolve(files);\n });\n }\n catch (error) {\n resolve([])\n }\n }));\n\n \n\n \n\n}", "getFiles() {\n return Resource.find({})\n }", "getTexFilesList() {\n return fs.listSync(this.projectPath, [\".tex\"]);\n }", "function _getFileList(folder, callback) {\n var files = [];\n \n klaw(folder)\n .on('data', function(item) {\n if (item.stats.isFile() && isAllowed(item.path))\n files.push(item.path);\n })\n .on('end', function() {\n callback(files);\n });\n}", "function getFileList(path) {\n\tvar paths = fs.readdirSync(path);\n\tvar files = [];\n\tvar stats, item, i;\n\n\t// sort files from directories\n\tfor (i = paths.length - 1; i >= 0; i--) {\n\t\titem = paths[i];\n\n\t\tif (item.charAt(0) == '.') return [];\n\n\t\titem = path + '/' + item;\n\n\t\ttry {\n\t\t\tstats = fs.statSync(item);\n\n\t\t\t// files or directories\n\t\t\tif ( ! stats.isDirectory() ) files.push(item);\n\t\t\telse files = files.concat(getFileList(item));\n\t\t}\n\t\tcatch (e) {\n\t\t\tconsole.log('GetSmartJS: Couldn\\'t find path:', item);\n\t\t}\n\t}\n\n\treturn files;\n}", "getFileList(path, dir) {\n if (!path) {\n return [];\n }\n\n let files = [];\n this.formatKeys.forEach(\n function(key) {\n this.getExtensionsFromKey(key).forEach(function(extension) {\n files.push((dir ? dir + \"/\" : \"\") + path + \".\" + extension);\n });\n }.bind(this)\n );\n\n return files;\n }", "getFilesSync(pathToContent, recursive = false) {\n let files = [];\n if (recursive !== false) recursive = this.toBoolean(recursive);\n\n if (!this.is(pathToContent, String)) return files;\n pathToContent = path.normalize(pathToContent);\n\n if (this.isFileSync(pathToContent)) {\n files.push(pathToContent);\n } else if (this.isDirectorySync(pathToContent)) {\n const contents = fs.readdirSync(pathToContent, 'utf8');\n for(let content of contents) {\n const contentPath = path.join(pathToContent, content);\n if (this.isFileSync(contentPath)) files.push(contentPath);\n else if (recursive && this.isDirectorySync(contentPath)) files = [...files, ...this.getFilesSync(contentPath, recursive)];\n }\n } else {\n console.error(`${colors.red('safe-regex-cli error: no such file or directory \"' + pathToContent + '\".')}`);\n }\n return files;\n }", "function walk(folder){\n var filenames=[];\n // get relative filenames from folder\n var folderContent=fs.readdirSync(folder);\n // iterate over the folder content to handle nested folders\n _.each(folderContent,function(filename){\n // build absolute filename\n var absoluteFilename=folder+path.sep+filename;\n // get file stats\n var stat=fs.statSync(absoluteFilename);\n if(stat.isDirectory()){\n // directory case => add filenames fetched from recursive call\n filenames=filenames.concat(walk(absoluteFilename));\n }\n else{\n // file case => simply add it\n filenames.push(absoluteFilename);\n }\n });\n return filenames;\n }", "getFolderItems(folderPath) {\r\n return new Promise(function (resolve, reject) {\r\n fs.readdir(folderPath, function (err, items) {\r\n if (err) {\r\n return reject(err);\r\n }\r\n var results = [];\r\n items.forEach(item => {\r\n try {\r\n results.push(new FileInfo_1.FileInfo(path.join(folderPath, item)));\r\n }\r\n catch (err) {\r\n // silently ignore permissions errors\r\n }\r\n });\r\n resolve(results);\r\n });\r\n });\r\n }", "async function folderList () {\n return bucket.getFiles({\n // TODO: changing frequency may break this?\n maxResults: 365 * 24 / config.get('archiver.frequency'),\n delimiter: '/',\n }).then((data) => {\n const response = data[2];\n return response.prefixes.map(val => val.replace(/\\//, ''));\n });\n}", "function GetPagesList()\n{\n var list = []; // Initialise array\n var files = fs.readdirSync(\"pages\"); // Node JS sync List files in folder.\n for (var i = 0; i < files.length; i++)\n {\n list[i] = []; // Initialise array item into 2D Array\n list[i][0] = files[i]; //filename\n list[i][1] = files[i].replace(/\\.[^\\.]*$/,''); //pagename\n }\n return list;\n}", "async readdir() {\n if (!this.canReaddir()) {\n return [];\n }\n const children = this.children();\n if (this.calledReaddir()) {\n return children.slice(0, children.provisional);\n }\n // else read the directory, fill up children\n // de-provisionalize any provisional children.\n const fullpath = this.fullpath();\n if (this.#asyncReaddirInFlight) {\n await this.#asyncReaddirInFlight;\n }\n else {\n /* c8 ignore start */\n let resolve = () => { };\n /* c8 ignore stop */\n this.#asyncReaddirInFlight = new Promise(res => (resolve = res));\n try {\n for (const e of await this.#fs.promises.readdir(fullpath, {\n withFileTypes: true,\n })) {\n this.#readdirAddChild(e, children);\n }\n this.#readdirSuccess(children);\n }\n catch (er) {\n this.#readdirFail(er.code);\n children.provisional = 0;\n }\n this.#asyncReaddirInFlight = undefined;\n resolve();\n }\n return children.slice(0, children.provisional);\n }", "function getFilePaths(funcs) {\n return new BbPromise(function(resolve, reject) {\n var paths = [];\n\n if (funcs && (funcs.length > 0)) {\n funcs.forEach(function(val, idx) {\n paths.push(testFilePath(val));\n });\n return resolve(paths);\n }\n // No funcs provided, list all test files\n fs.readdirSync(testFolder).filter(function(file){\n // Only keep the .js files\n return file.substr(-3) === '.js';\n }).forEach(function(file) {\n paths.push(path.join(testFolder, file));\n });\n return resolve(paths);\n });\n }", "function getAllPages() {\n var filepath = getCurrentPath();\n console.log('file path: ', filepath);\n htmlFiles = fs.readdirSync(filepath)\n .filter(function (file) {\n return file.includes('.html');\n }).map(function (file) {\n var correctPath = pathLib.resolve(filepath, file);\n if (correctPath == undefined) {\n pagesToImageObjs('current path is undefined', null);\n }\n return {\n file: file,\n contents: fs.readFileSync(correctPath, 'utf8')\n };\n });\n return htmlFiles;\n}", "async _fileList() {\n return (await readFile('list.txt', {\n encoding: 'utf-8'\n })).trim().split('\\n');\n }", "static listaArquivos(dirPath) {\n return new Promise((resolve, reject)=> {\n try {\n fs.readdir(dirPath, (err, files) => {\n if (err) {\n reject(err);\n } else {\n resolve(files);\n }\n });\n } catch (err) {\n reject(err);\n }\n });\n }", "function getFileList(entryPoint, context) {\n let entryFiles = [];\n if (typeof entryPoint === \"string\") {\n // If path is string use as is\n entryFiles.push(path.resolve(context, entryPoint));\n }\n else {\n // Else exclude paths with node_modules\n // (webpack-dev-server files, prepended to entry files in the array)\n const filteredPaths = entryPoint.filter(entryPath => !entryPath.includes('node_modules'));\n filteredPaths.forEach(entryPath => {\n entryFiles.push(path.resolve(context, entryPath));\n });\n }\n return entryFiles;\n}", "listDir(path) {\n return backend.listDir(path);\n }", "function getAllFilenames() {\n return fs.readdirAsync(articlesPath).filter(function(filename) {\n return !testIfDirectory(filename);\n });\n}", "async readdir (filepath) {\n try {\n return await this._readdir(filepath)\n } catch (err) {\n return []\n }\n }", "function file_cache_list() {\n\t\tconsole.log(Object.keys(wkof.file_cache.dir).sort().join('\\n'));\n\t}", "getFileExplorers() {\n return this.app.workspace.getLeavesOfType('file-explorer');\n }", "function _getFilesInFolder(dir) {\n var results = [];\n fs.readdirSync(dir).forEach(function(file) {\n file_dir = dir+'/'+file;\n var stat = fs.statSync(file_dir);\n if (stat && stat.isDirectory()) {\n results = results.concat(_getAllFilesFromFolder(file_dir));\n } else results.push(file);\n\n });\n return results;\n}", "function ls( path ) {\n return _readdir( path );\n}", "function listDataFiles() {\n try {\n return fsPromises.readdir(DATA_DIRECTORY);\n } catch (err) {\n console.error('Error occured while reading directory!', err);\n }\n}", "scanAppDir() {\n return glob.sync(path.resolve(this.app.appPath, '**'), {\n nodir: true,\n });\n }", "getFiles() {\n recursive(this.path, (err, files) => {\n for(var i in files) {\n var f = files[i];\n var stat = fs.statSync(f);\n\n if(stat.isFile()) {\n var basename = path.basename(f);\n var masks = [/^script\\.js$/, /^style\\.css$/, /^styles\\.css$/, /^.*\\.less$/];\n // if(basename == 'script.js' || basename == 'style.css' || basename == 'styles.css') {\n if( this.checkMask(basename, masks) ) {\n if(! this.files.includes(f)) {\n this.files.push(f);\n\n // if file has`t compressed copy make it\n if(! this.isFileCompressed(f)) {\n this.compressFile(f);\n }\n\n this.watcher(f);\n }\n }\n }\n }\n });\n }", "static getFiles(path){\n\t\treturn (context, source) => {\n\t\t\tif (source == undefined) source=null;\n\t\t\tvar fs = context.createProvider(\"default:fs\");\n\t\t\tvar res = Lib.getFiles(fs, path);\n\t\t\tif (source == null){\n\t\t\t\treturn res;\n\t\t\t}\n\t\t\treturn source.concat(res);\n\t\t}\n\t}", "function getFiles (absolutePath){\n var fileArray = [];\n var directoryArray = [absolutePath];\n return readDirectory(fileArray, directoryArray);\n}", "function getFilesData(pathToFile) {\n findFilesData(pathToFile);\n var tempFiles = filesData;\n filesData = [];\n return tempFiles;\n}", "loadFiles(){\n if(this.paths.length == 0)\n throw 'Set one or more paths.';\n\n for(var i in this.paths){\n var fc = new this.fc(this.paths[i]);\n\n var file_array = fc.getFiles();\n\n for(var i in file_array){\n /**\n * Ignore double files.\n */\n if(!this.files.includes(file_array[i])){\n this.files.push(file_array[i]);\n }\n }\n }\n }", "items() {\n // eslint-disable-next-line vue/no-side-effects-in-computed-properties\n const directories = this.$store.getters.getSelectedDirectoryDirectories\n // Sort by type and alphabetically\n .sort((a, b) => ((a.name.toUpperCase() < b.name.toUpperCase()) ? -1 : 1))\n .filter((dir) => dir.name.toLowerCase().includes(this.$store.state.search.toLowerCase()));\n\n // eslint-disable-next-line vue/no-side-effects-in-computed-properties\n const files = this.$store.getters.getSelectedDirectoryFiles\n // Sort by type and alphabetically\n .sort((a, b) => ((a.name.toUpperCase() < b.name.toUpperCase()) ? -1 : 1))\n .filter((file) => file.name.toLowerCase().includes(this.$store.state.search.toLowerCase()));\n\n return [...directories, ...files];\n }", "readdir(dirpath) {\n return RNFS.readDir(dirpath)\n .then(files => {\n return files.map(file => file.name);\n });\n }", "getDevFilesToCopy () {\n const filesToCopy = [`${settings.paths.dev.root}/**/*`]\n const ignore = [\n settings.paths.dev.js,\n settings.paths.dev.css\n ]\n\n ignore.forEach((ignoreValue) => {\n filesToCopy.push(`!${ignoreValue}`, `!${ignoreValue}/**`)\n })\n\n return filesToCopy\n }", "function findFiles(auth, dir) {\n let query = \"?q='\" + dir + \"'+in+parents\"\n let headers = {\n \"Authorization\": \"Bearer \" + auth.credentials.access_token\n }\n\n let url = DRIVE_URL + query\n\n return axios({ url, headers }).then( res => {\n\n if ( !res.data.files ) throw new Error('folder not found')\n\n return res.data.files\n })\n}", "function findConfigfiles (root) {\n ['app/index.html', 'app/run.js'].reduce(function(configFiles, file) {\n if(path.exists(file)) configFiles.push(file)\n return configFiles;\n }, []);\n }", "get RenderPaths() {}", "function iterate(currentPath)\n{\n\tvar folders = [],\n\t\tfiles = [],\n\t\tmain = null;\n\t\n\tcurrentPath = path.resolve(currentPath);\n\t\n\tfs.readdirSync(currentPath).forEach(function(file)\n\t{\n\t\tvar item = path.normalize(path.join(currentPath, file));\n\t\t\n\t\tif(file == \"lib\")\n\t\t\tArray.prototype.unshift.apply(folders, iterate(item));\n\t\telse if(file == \"main.js\")\n\t\t\tmain = item;\n\t\telse if(fs.lstatSync(item).isDirectory())\n\t\t\tArray.prototype.push.apply(folders, iterate(item));\n\t\telse\n\t\t\tfiles.push(item);\n\t});\n\t\n\tif(main)\n\t\tfiles.push(main);\n\t\n\tArray.prototype.push.apply(folders, files);\n\t\n\treturn folders;\n}", "getAllMyFiles (scrpt_id) {\n\t\t\tthis.$axios.get('api/getAllMyFiles/'+scrpt_id).then(res => {\n\t\t\t\tthis.docFileArr = res.data.doc_file;\n\t\t\t\tthis.allFigFiles = res.data.fig_files;\n\t\t\t});\n\t\t}", "function walkSyncJS(dir) {\n let files = fs.readdirSync(dir);\n let filelist = [];\n files.forEach(function(file) {\n let fullPath = path.join(dir, file);\n if (fs.statSync(fullPath).isDirectory()) {\n filelist = filelist.concat(walkSyncJS(fullPath));\n } else if(file.endsWith('.js')) {\n filelist.push(fullPath);\n }\n });\n\n return filelist;\n}", "getAssetRoots() {\n return [__dirname];\n }", "function getFiles(callback) {\n var directory = '../public/blog';\n var walk = require('walk'), fs = require('fs'), options, walker;\n var walker = walk.walk('./public/blog', {followLinks: false});\n\n var fs = [];\n\n walker.on(\"file\", function (root, file, next) {\n var fileDir = \"public/blog\";\n var f = root + \"/\" + file['name'].substring(0, file['name'].lastIndexOf('.'));\n\n if (f.toLowerCase() != (\"./\" + fileDir + '/').toLowerCase()) {\n var localUrl = f;\n var date = f.replace(\"./public/blog/\", \"\").replace(new RegExp('/', 'g'), \":\");\n var name = date.substring(date.lastIndexOf(':') + 1, date.length);\n date = date.substring(0, date.lastIndexOf(':')).replace(new RegExp(':', 'g'), \"-\");\n\n // push without /blog prefix\n if (name.length > 0 && date.length > 0)\n fs.push({url: f.substring(f.indexOf('/')), date: date, name: name, localUrl: localUrl});\n }\n next();\n });\n\n walker.on(\"end\", function () {\n callback(fs);\n });\n }", "function getPDFFilesFromCurFolder() {\n var files = folder.getFiles();\n var allFileNameUrls = [];\n\n while (files.hasNext()) {\n var file = files.next();\n\n var fileName = file.getName();\n if(fileName.endsWith(\".pdf\") && !fileName.includes(\"_protected\")){\n // Create Pre-Signed URL from PDF.co\n var respPresignedUrl = getPDFcoPreSignedURL(fileName)\n\n if(!respPresignedUrl.error){\n var fileData = file.getBlob();\n if(uploadFileToPresignedURL(respPresignedUrl.presignedUrl, fileData)){\n // Add Url\n allFileNameUrls.push({url: respPresignedUrl.url, fileName: fileName});\n }\n }\n }\n }\n\n return allFileNameUrls;\n}", "async listComponentsWithTrackDir() {\n if (this.consumer.isLegacy) return [];\n const workspaceComponents = await this.getFromFileSystem(_constants().COMPONENT_ORIGINS.AUTHORED);\n return workspaceComponents.filter(component => {\n const componentMap = component.componentMap;\n if (!componentMap) throw new Error('listComponentsWithIndividualFiles componentMap is missing');\n return Boolean(componentMap.trackDir);\n });\n }", "getPaths () {\n if (this._paths) {\n return this._paths\n }\n\n const paths = []\n\n let proto = this\n\n // 1. should has a own property `configFileName`\n // 2. this.configFileName should be a string\n // 3. has a own property `nodePath` or not\n\n // Loop back for the prototype chain\n while (proto) {\n proto = Object.getPrototypeOf(proto)\n\n // There is no caviar.config.js in caviar,\n // So just stop\n if (proto === ConfigLoader.prototype) {\n break\n }\n\n if (!hasOwnProperty(proto, 'configFile')) {\n throw error('CONFIG_FILE_GETTER_REQUIRED')\n }\n\n const {\n configFile\n } = proto\n\n if (!isString(configFile)) {\n throw error('INVALID_CONFIG_FILE', configFile)\n }\n\n const nodePath = hasOwnProperty(proto, 'nodePath')\n ? checkNodePath(proto.nodePath)\n : UNDEFINED\n\n paths.push({\n nodePath: nodePath && realNodePath(nodePath),\n configFile: realConfigFile(configFile)\n })\n }\n\n log('config-loader: paths: %s', inspect(paths))\n\n return this._paths = paths\n }", "dirList (path) {\n const dirPaths = []\n const collectList = (path) => {\n return new Promise((resolve, reject) => {\n this.readdir(path).then((ls) => {\n const promises = Object.keys(ls).map((item, index) => {\n if (ls[item].isDirectory && !dirPaths.includes(item)) {\n dirPaths.push(item)\n resolve(dirPaths)\n }\n return new Promise((resolve, reject) => { resolve() })\n })\n Promise.all(promises).then(() => { resolve(dirPaths) })\n })\n })\n }\n return collectList(path)\n }", "function getRecipeList(){\n var recipe_files = [];\n //passsing directoryPath and callback function\n fs.readdir(__dirname + '/data', function (err, files) {\n //handling error\n if (err) {\n return console.log('Unable to scan directory: ' + err);\n } \n //listing all files using forEach\n files.forEach(function (file) {\n // Do whatever you want to do with the file\n console.log(file);\n recipe_files.push(file);\n });\n });\n\n return recipe_files;\n}", "static async GetFileNames(){\n\t\tvar returnMe = [];\n\t\t//get all file names using async \n\t\t_retrieveKeys = async () => {\n\t\t\ttry {\n\t\t\t\tconst value = await AsyncStorage.getAllKeys();\n\t\t\t\tif (value !== null) {\n\t\t\t\t\tfor(fileNumber in value){\n\t\t\t\t\t\t//whats the filename according to our filesystem\n\t\t\t\t\t\tvar fileName = value[fileNumber];\n\t\t\t\t\t\t\n\t\t\t\t\t\t//return all filenames that ARENT \"GlobalData\"\n\t\t\t\t\t\tif(fileName != \"GlobalData\"){\n\t\t\t\t\t\t\treturnMe.push(value[fileNumber]);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\treturnMe.sort(this.sortFileNames);\n\t\t\t\t}\n\t\t\t\treturn returnMe;\n\t\t\t\t\n\t\t\t} catch (error) {\n\t\t\t\t// Error saving data\n\t\t\t\talert(error);\n\t\t\t}\n\t\t}\n\t\t \n\t\t return _retrieveKeys();\n\t}", "function filesInDir(dir) {\n return Q.nfcall(fs.readdir, dir).catch(() => []);\n}", "function getViews () {\n\t\t// grunt.log.writeln('Getting views:');\n\t\t// use fs to read the views folder; fs.readdirSync()\n\t\tvar views = fs.readdirSync(getViewsDir())\n\t\t\t// filter to only select other dirs and not files\n\t\t\t.filter(function(name){\n\t\t\t\treturn grunt.file.isDir(getViewsDir() + name);\n\t\t\t});\n\t\t// grunt.log.writeln('/********');\n\t\t// grunt.log.writeln(' * Views:');\n\t\t// views.forEach(function(name) {\n\t\t// \tgrunt.log.writeln(' * - ' + name);\n\t\t// });\n\t\t// grunt.log.writeln('********/');\n\t\t// grunt.log.writeln('');\n\t\treturn views;\n\t}", "async listComponentsWithIndividualFiles() {\n if (this.consumer.isLegacy) return [];\n const workspaceComponents = await this.getFromFileSystem(_constants().COMPONENT_ORIGINS.AUTHORED);\n return workspaceComponents.filter(component => {\n const componentMap = component.componentMap;\n if (!componentMap) throw new Error('listComponentsWithIndividualFiles componentMap is missing');\n return Boolean(!componentMap.trackDir && !componentMap.rootDir);\n });\n }", "function getAllPaths() {\n let pathList = [];\n let pathNodes = $(\"svg[id='svg']\").find(\"path\");\n $.each(pathNodes, (key, Node) => {\n pathList.push({\n name: Node.getAttribute(\"id\"),\n data: Node.getAttribute(\"d\")\n });\n });\n return pathList;\n}", "getAllBranches() {\n this.checkInit();\n\n return this.cfgObj.getFileNames();\n }" ]
[ "0.66810745", "0.62842715", "0.61882734", "0.6179658", "0.6170243", "0.61617494", "0.6159305", "0.6144904", "0.61183137", "0.61148167", "0.6114717", "0.6114136", "0.611184", "0.6051959", "0.6038199", "0.60099494", "0.59697807", "0.595084", "0.5949616", "0.59400827", "0.5939316", "0.593854", "0.5932895", "0.59132886", "0.5905", "0.586446", "0.5829084", "0.5783972", "0.5771515", "0.5764975", "0.5724567", "0.57176685", "0.57135487", "0.5667401", "0.56636757", "0.5641175", "0.5634357", "0.5620668", "0.56087035", "0.5590496", "0.55801785", "0.5580024", "0.5575625", "0.5569536", "0.556646", "0.55622184", "0.5551398", "0.55367637", "0.55338085", "0.55275977", "0.5525159", "0.55180675", "0.5514787", "0.5497691", "0.54875803", "0.54550385", "0.54546773", "0.5443024", "0.54284513", "0.5415947", "0.54077226", "0.54019994", "0.5373497", "0.5365453", "0.53550607", "0.53534025", "0.53488284", "0.53388625", "0.5328245", "0.53236675", "0.53183585", "0.53183573", "0.5313673", "0.53066677", "0.5300035", "0.52927244", "0.5287823", "0.5285911", "0.52592075", "0.52545404", "0.52399004", "0.5231522", "0.5227502", "0.5209638", "0.5209372", "0.5207987", "0.52068245", "0.5196745", "0.51908076", "0.51841193", "0.51819843", "0.51787394", "0.5161697", "0.51527166", "0.51507515", "0.51502776", "0.51405567", "0.5138698", "0.513742", "0.51365757" ]
0.6898038
0
Close the form if one is currently open Also hide applications list div when adding a new application
function setClose() { if (props.total_results != 0) { if (jobType != null) { setJobType(null); document.getElementById('apps').style.display = 'initial'; } else { document.getElementById('apps').style.display = 'none'; } } else { if (jobType != null) { setJobType(null); } else { } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function hideListForm() {\n if (!isAddingList) {\n vm.isListFormVisible = false;\n }\n }", "function hideForm() {\n mainForm.style.display = 'none';\n newInfoButton.style.display = 'block';\n}", "hideCreateForm() {\n this.changeFormMode(this.FORM_MODES.LIST);\n }", "function closeForm(){\n document.getElementsByClassName('container-toDO')[0].style.display = 'block';\n let PopUp = document.getElementsByClassName('pop-up')[0];\n PopUp.classList.add('hides');\n document.getElementById(\"myForm\").style.display = \"none\";\n }", "function closeModuleList() {\n $(\".graybg\").hide();\n $('.add_module_list').hide();\n $('body').css('overflow-y', 'auto');\n visibleAddEvent = false;\n}", "function hideForm() {\n\t\tthat.state.formShow = false;\n\t}", "function closeForm() {\n $('.add-parent-popup').hide();\n $('.overlay').hide();\n clearFields();\n $('#pin-message').hide();\n}", "function closeForm() {\n document.getElementById(\"myForm\").style.display = \"none\";\n document.getElementById(\"post-start\").style.display = \"none\";\n document.getElementById(\"post-start-title\").style.display = \"none\";\n document.getElementById(\"delete\").disabled = false;\n document.getElementById(\"add\").disabled = false;\n document.getElementById(\"upload\").disabled = false;\n}", "function cancelNewProgramForm() {\n $('#injected-content').hide();\n $('#main-content').fadeIn();\n $('aside div').hide();\n $('aside div.new-program').fadeIn().css(\"display\",\"inline-block\");\n}", "function hideAddDeviceForm() {\n $(\"#addDeviceControl\").show(); // Hide the add device link\n $(\"#addDeviceForm\").slideUp(); // Show the add device form\n $(\"#error\").hide();\n}", "function hideAddDeviceForm() {\n $(\"#addDeviceControl\").show(); // Hide the add device link\n $(\"#addDeviceForm\").slideUp(); // Show the add device form\n $(\"#error\").hide();\n}", "function hideAddDeviceForm() {\n $(\"#addDeviceControl\").show(); // Hide the add device link\n $(\"#addDeviceForm\").slideUp(); // Show the add device form\n $(\"#error\").hide();\n}", "function closeInput() {\n document.getElementById('editForm').style.display = 'none';\n}", "function CloseAppt() {\n $(\"#add-appt\").css(\"display\", \"inline-block\");\n $(\"#appt-form\").css(\"display\", \"none\");\n $(\"#add-btn\").css(\"display\", \"none\");\n $(\"#cancel-btn\").css(\"display\", \"none\");\n}", "function closeFormButton() {\n clearFields();\n $('#add-section').hide();\n $('.show-form-btn').show();\n}", "function closeApp()\n{\n\tdocument.getElementById(\"openAppHolder\").remove();\n}", "function openForm(){\n document.getElementsByClassName('container-toDO')[0].style.display = 'none';\n let PopUp = document.getElementsByClassName('pop-up')[0];\n PopUp.classList.remove('hides');\n document.getElementById(\"myForm\").style.display = \"block\";\n}", "function hideAllForms() {\n\t$('#add-item-form').hide();\n\t$('#set-email-form').hide();\n}", "function closeSubmitted(e) {\n if(e.target === submitBtn && bookTitle.value !== \"\" && bookAuthor.value !== \"\" && pages.value !== \"\"){\n formContainer.style.display = 'none'\n }else{\n displayData()\n }\n}", "function hideAddListForm() {\r\n\r\n let addListForm = document.getElementById(\"addListForm\");\r\n let annuleerAddList = document.getElementById(\"annuleerAddList\");\r\n\r\n addListForm.classList.add(\"invisible\");\r\n annuleerAddList.classList.add(\"invisible\");\r\n}", "function view () {\n $('div.employeeList').removeClass('hidden');\n // $('form.addForm').addClass('hidden');\n var forms = document.querySelectorAll('form');\n if (forms[0] != undefined) {\n document.body.removeChild(forms[0]);\n }\n toggleActive('View');\n}", "function closeForm() {\n document.getElementById(\"myForm\").style.display = \"none\"; \n}", "function closeForm() {\r\n document.getElementById(\"popupForm\").style.display = \"none\";\r\n document.getElementById(\"taForm\").style.display = \"none\";\r\n document.getElementById(\"anmtForm\").style.display = \"none\";\r\n}", "function displayFormWindow(){\r\n if(!AddTAWindow.isVisible()){\r\n resetAddForm();\r\n AddTAWindow.show();\r\n } else {\r\n AddTAWindow.toFront();\r\n }\r\n \r\n \r\n }", "function closeForm() {\n document.getElementById(\"myForm\").style.display = \"none\";\n document.getElementById('openBtn').style.display = 'block';\n // clear channel poller running in window\n clearInterval(window.poller);\n}", "function hideReplaceDeviceForm() {\n $(\"#relpaceDeviceControl\").show(); // Hide the add device link\n $(\"#replaceDeviceForm\").slideUp(); // Show the add device form\n $(\"#error\").hide();\n}", "function closeAdd(e) {\n //if form isn't open don't bother checking anything.\n if ($(\"#newCollectibleForm\").css(\"display\") === \"none\")\n return;\n var container = $(\"#newCollectibleForm\");\n\n if (!container.is(e.target)\n && container.has(e.target).length === 0)\n {\n console.log(\"Closing...\");\n //if we click on the toast don't close the form\n if ($(e.target).attr(\"class\").indexOf(\"toast\") !== -1)\n return;\n\n clearForm();\n closeForm();\n $(document).off(\"mouseup\");\n }\n }", "function hideForm() {\n $scope.formDisplay = false;\n }", "function closeAddFrom(){\n var container = document.getElementById(\"addFromContainer\");\n container.style.display = \"none\";\n}", "function showNewProgramForm() {\n var url = \"includes/new_program_form.php\";\n var contentContainer = $('#injected-content');\n $('#main-content').hide();\n getData(url, injectContent, contentContainer);\n contentContainer.fadeIn();\n $('aside div').hide();\n $('aside div.cancel').fadeIn().css(\"display\",\"inline-block\");\n}", "function exitForm() {\n $('#contactForm').hide();\n}", "function toggleEntryForm() {\n const HideForm = document.getElementById(\"dino-compare\");\n HideForm.classList.add(\"hide\");\n }", "function closeCreateUserForm() {\n document.getElementById(\"createUserForm\").style.display = \"none\";\n}", "function displayFormWindow(){\r\n if(!AddPriceWindow.isVisible()){\r\n resetPriceForm();\r\n AddPriceWindow.show();\r\n } else {\r\n AddPriceWindow.toFront();\r\n }\r\n\r\n\r\n }", "function hideForm() {\n orderForm.style.display = 'none';\n}", "function displayEFormWindow(){\r\n if(!EditCourseWindow.isVisible()){\r\n resetECourseForm();\r\n EditCourseWindow.show();\r\n } else {\r\n EditCourseWindow.toFront();\r\n }\r\n \r\n \r\n }", "function hideFormMedidaCreate(){\n $(\"#medida-table\").show(300);\n $(\"#medida-pagination\").show(300);\n $(\"#medida-view\").hide(300);\n $(\"#medida-create\").hide(300);\n $(\"#medida-button\").removeClass(\"active\");\n}", "function hideForm() {\n form.classList.add('hidden');\n}", "function showAddListForm() {\r\n\r\n let addListForm = document.getElementById(\"addListForm\");\r\n let annuleerAddList = document.getElementById(\"annuleerAddList\");\r\n\r\n addListForm.classList.remove(\"invisible\");\r\n annuleerAddList.classList.remove(\"invisible\");\r\n}", "function hideForm() {\n document.getElementById('appendForm').style.display = \"none\"\n // test commit made through Github interface.\n // to start editing, I opened this specific file in Github, then I pressed: .\n // That's it. If I can edit and commit from here, this is officially crazy. \n }", "function closeForm() {\n document.getElementById(\"msgForm\").style.display = \"none\";\n}", "function hideForm1() {\n $('.form-1').hide();\n }", "function removeForm() {\n const form = document.querySelector('#dino-compare');\n form.style.display = \"none\";\n }", "function revealInputForm() {\n $(this).find('form').removeClass('hidden');\n }", "function closeApp() {\n document.getElementById(\"form-close\").submit();\n}", "function showForm(){\n form.reset();\n background.classList.add(\"transparent\")\n addBookForm.classList.remove(\"form--hidden\");\n }", "closeLoginForm() {\n document.getElementById(\"showLoginForm\").checked = false;\n this.switchToLogin();\n updatePageTitle(\"Utforsk nye aktiviteter\");\n }", "function showForm() {\n document.querySelector(\"#new-book-form\").classList.remove(\"hide\");\n document.querySelector(\"#new-book-form\").classList.add(\"show\");\n}", "function toggleForm() {\n formContainer.classList.toggle(\"invisible\");\n mainContainer.classList.toggle(\"invisible\");\n}", "closeForm(){\n this.setState({showEditForm: false});\n sessionStorage.setItem('showEditForm', 'false');\n }", "function closeListContent() {\n $(\"#sidebar2\").css(\"display\",\"none\");\n}", "function AddBookForm() {\n document.querySelector('.heading').style.display = 'none';\n document.querySelector('#lib').style.display = 'none';\n document.querySelector('#list_container').style.display = 'none';\n document.querySelector('.line').style.display = 'none';\n document.querySelector('#AddNewbook_container').style.display = 'block';\n document.querySelector('#contact').style.display = 'none';\n document.querySelector('#welcome').style.display = 'none';\n}", "hide()\n {\n this._window.hide();\n }", "function startapp(app) {\n/*\nif (document.getElementById(app).style.display==\"block\") {\ndocument.getElementById(app).style.display=\"none\"; }\nelse {document.getElementById(app).style.display=\"block\";}\n*/\n}", "function closeList() {\n\tif (iPopupOpen) {\n\t\tofVBAISpan.style.display=\"none\";\n\t\tiPopupOpen=false;\n\t\t}\n\t}", "function closeForm() {\n document.getElementById(\"author\").value = \"\";\n document.getElementById(\"title\").value = \"\";\n document.getElementById(\"pages\").value = \"\";\n document.getElementById(\"read\").checked = false;\n document.getElementById(\"notRead\").checked = true;\n document.getElementById(\"form\").style.display = \"none\";\n}", "function attachCloseButtonToForm() {\n let closeFormButton = document.querySelector(\"#cancel-form\");\n closeFormButton.addEventListener(\"click\", () => {\n editOrCreateFormContainer.style.display = \"none\";\n document.querySelector(\"#create-meme-iframe\").style.display = \"unset\";\n modifyElemenetsWithClassHidden(\"none\");\n clearForm();\n });\n}", "function frmPatientSummary_hideDropDownsOnFormclick() {\n frmPatientSummary.fcunitslist.setVisibility(false);\n}", "function closeAll() {\n $scope.closeMenu();\n document.activeElement.blur();\n $scope.ib.close();\n var listBox = document.getElementById(\"floating-panel\");\n while (listBox.firstChild) {\n listBox.removeChild(listBox.firstChild);\n }\n listBox.className = \"hidden\";\n $scope.closeWndr();\n }", "function closeElement() {\r\n\t\tvar removeDocument = document.getElementById(\"removeDocument\");\r\n\t\tif (removeDocument.style.visibility === \"visible\") removeDocument.style.visibility = \"hidden\";\r\n\t\tvar openDocument = document.getElementById(\"openDocument\");\r\n\t\tif (openDocument.style.visibility === \"visible\") openDocument.style.visibility = \"hidden\";\r\n\t }", "handle_closing() {\n if (!this.app || !this.element) {\n return;\n }\n /* The AttentionToaster will take care of that for AttentionWindows */\n /* InputWindow & InputWindowManager will take care of visibility of IM */\n if (!this.app.isAttentionWindow && !this.app.isCallscreenWindow &&\n !this.app.isInputMethod) {\n this.app.setVisible && this.app.setVisible(false);\n }\n this.switchTransitionState('closing');\n }", "close() {\n\n // Pop the activity from the stack\n utils.popStackActivity();\n\n // Hide the screen\n this._screen.scrollTop(0).hide();\n\n // Hide the content behind the placeholders\n $(\"#page--info .ph-hidden-content\").hide();\n\n // Stop the placeholders animation\n this._placeholders.removeClass(\"ph-animate\").show();\n\n // Hide the delete button\n $(\"#info-delete\").hide();\n\n // Hide the info button\n $(\"#info-edit\").hide();\n\n // Show all the fields\n $(\".info-block\").show();\n\n // Delete the content of each of the fields\n $(\"#info-createdAt .info-content\").html(\"\");\n $(\"#info-updatedAt .info-content\").html(\"\");\n $(\"#info-coordinates .info-content\").html(\"\");\n $(\"#info-coordinatesAccuracy .info-content\").html(\"\");\n $(\"#info-altitude .info-content\").html(\"\");\n $(\"#info-altitudeAccuracy .info-content\").html(\"\");\n $(\"#info-type .info-content\").html(\"\");\n $(\"#info-materialType .info-content\").html(\"\");\n $(\"#info-hillPosition .info-content\").html(\"\");\n $(\"#info-water .info-content\").html(\"\");\n $(\"#info-vegetation .info-content\").html(\"\");\n $(\"#info-mitigation .info-content\").html(\"\");\n $(\"#info-mitigationsList .info-content\").html(\"\");\n $(\"#info-monitoring .info-content\").html(\"\");\n $(\"#info-monitoringList .info-content\").html(\"\");\n $(\"#info-damages .info-content\").html(\"\");\n $(\"#info-damagesList .info-content\").html(\"\");\n $(\"#info-notes .info-content\").html(\"\");\n\n // Show the image placeholder\n $(\"#info-photo-preview\").attr(\"src\", \"img/no-img-placeholder-200.png\");\n\n }", "closeSearch() {\n if (this.closable) {\n this.element_main.style.visibility = \"hidden\"; // hide search box\n document.activeElement.blur(); // remove focus from search box \n this.visible = false; // search not visible\n }\n }", "function hideForm(){\n const form = document.getElementById('dino-compare');\n form.style.display = 'none';\n}", "function hideBoardEditForm() {\n vm.isBoardEditFormVisible = false;\n }", "function closeEditForm(event) {\n const element = event.currentTarget;\n\n var iconGroup = element.parentNode,\n iconColumn = iconGroup.parentNode,\n row = iconColumn.parentNode,\n formContainer = row.parentNode,\n parent = formContainer.parentNode,\n studentContainer = parent.querySelector(\".student-details\");\n console.log();\n\n formContainer\n .classList\n .add(\"d-none\");\n\n studentContainer\n .classList\n .remove(\"d-none\");\n}", "function closeDesktopSearch() {\n document.getElementsByClassName('search-form-desktop')[0].setAttribute('class', 'search-form');\n document.getElementsByClassName('search-form-icon-desktop-active')[0].style.cssText = 'display: none;';\n document.getElementsByClassName('search-form-icon-desktop')[0].style.cssText = 'display: inline-block;';\n}", "function closeExcursionsMenu() {\n !!list.excursionMenu && list.excursionMenu.hide();\n }", "function openSearchForm() {\n spaceList.innerHTML = '';\n selectionHeading.innerText = '';\n searchWindow.classList.toggle('show');\n}", "function closeRegister(){\n document.getElementById(\"register-page\").style.display='none';\n}", "function parClose(){\n if (typeof parent.delSubmitSafe == 'function')\n parent.delSubmitSafe();\n if (typeof top.delSubmitSafe == 'function')\n top.delSubmitSafe();\n if (par!=null)\n par.style.display='none';\n}", "function fHideAllForms() {\n fLog(\"fHideAllForms\");\n for (i = 0; i < vaServices.length; i++) {\n var dService = vaServices[i];\n var oForm = dService[\"form\"];\n fHide(oForm);\n }\n}", "function closeForm() {\n const form = document.querySelector('#form')\n let title = document.querySelector('#formTitle').value;\n let author = document.querySelector('#formAuthor').value;\n let pages = document.querySelector('#formPage').value;\n let read = document.querySelector('#formRead').value;\n let newBook = new book(title, author, pages, read);\n debugger\n console.log(newBook);\n form.style.display = 'block';\n //form grabs data but disapears????\n}", "function hideForm() {\n document.getElementById(\"dino-compare\").style.display = 'none'\n}", "function closeSystemInfo() {\n if (isSystemInfoOpen) {\n systemInfoPanel.classList.add('hidden');\n isSystemInfoOpen = false;\n }\n }", "function hideOtherThreads() {\n var array = $$('.threadItem');\n var open = false;\n array.each(function(item){\n if(item.get('open') == 'true') {\n open = true;\n }\n });\n // If there is an opened item\n if (open == true) {\n array = $$('.threadItem[open = false]');\n // For each unopened thread item\n array.each(function(item){\n item.setStyles({\n 'visibility' : 'hidden',\n 'display':'none'\n }); \n }); \n // Not on thread page so dispose of thread button\n $('addThreadButton').dispose();\n if($('newThreadForm') != null) {\n // if the form has been opened dipose of it too\n $('newThreadForm').dispose();\n }\n }\n}", "function hideOnCloseBtn() {\n $(\".closebtn\").on('click', function() {\n $(\".user_login\").hide();\n })\n }", "hideWindow() {\n\t\tfinsembleWindow.hide();\n\t}", "function showHideForm() {\n /*\n If the form is hidden:\n * Show the form\n * Set the button text to 'Hide Form' or 'Cancel'\n * Set the input focus to the name field\n Else\n * Clear the form (call resetFormValues())\n * Hide the form\n * Set the button text back to 'Add Review'\n */\n let form = document.querySelector('form');\n let addButton = document.getElementById('btnToggleForm');\n if (form.classList.contains('d-none')) {\n form.classList.remove('d-none');\n addButton.innerText = \"Hide Form\";\n document.getElementById('name').focus();\n } else {\n form.classList.add('d-none');\n addButton.innerText = \"Add Review\";\n resetFormValues();\n }\n}", "function hide_widget_wizard() {\n $('#open-nc-widget').remove();\n $('#dd-form, #data-tables').show('slow'); \n }", "function showApp() {\n if (!isHidden) {\n return;\n }\n\n Object(external_lodash_[\"forEach\"])(hiddenElements, function (element) {\n element.removeAttribute('aria-hidden');\n });\n hiddenElements = [];\n isHidden = false;\n}", "function openEdit(div, form){\n\tdiv.style.display = \"none\";\n\tform.style.display = \"block\";\n}", "function openEdit(div, form){\n\tdiv.style.display = \"none\";\n\tform.style.display = \"block\";\n}", "function closeFPOpenCurrent(id) {\n\tif (document.getElementsByClassName('form-popup').style.display != 'none') {\n\t\tdocument.getElementsByClassName('form-popup').style.display = 'none';\n\t\tdocument.getElementById(id).style.display = 'block';\n\t}\n}", "function closeOption(param) {\n\n gw_com_api.hide(\"frmOption\");\n\n}", "function closeQuoteForm()\n\t{\n\t\tdocument.getElementById('quote_form').style.display=\"none\";\n\t}", "handleTaskForm()\n {\n if(this.state.dispForm == true)\n {\n this.state.dispForm = false;\n document.getElementById(\"addTaskForm\").style.display=\"none\";\n \n }\n else if(this.state.dispForm == false)\n {\n this.state.dispForm = true;\n document.getElementById(\"addTaskForm\").style.display=\"block\";\n \n }\n \n }", "function checkForm() {\n addBookToLibrary();\n let myLibrarySize = myLibrary.length - 1;\n for (let i in myLibrary[myLibrarySize]){\n if (myLibrary[myLibrarySize][i] == \"\"){\n myLibrary.pop();\n return false;\n }\n }\n removeAll();\n closeForm();\n displayBook();\n return true;\n}", "function hideWorkflowUpdateEditor()\n {\n $.PercDataList.enableButtons(container);\n $(\"#perc-workflow-name\").val(\"\");\n $(\"#perc-wf-update-editor\").hide();\n $(\"#perc-wf-name-wrapper\").show();\n dirtyController.setDirty(false);\n }", "function displayAddMenuWindow(){\r\n if(!AddMenuWindow.isVisible()){\r\n resetAddMenuForm();\r\n AddMenuWindow.show();\r\n } else {\r\n AddMenuWindow.toFront();\r\n }\r\n \r\n \r\n }", "function openForm(hiddenFormID) {\n\tvar allFormPopups = document.getElementsByClassName('form-popup');\n\tfor (x = 0; x < allFormPopups.length; x++) {\n\t\tdocument.getElementsByClassName('form-popup')[x].style.display = 'none';\n\t}\n\tdocument.getElementById(hiddenFormID).style.display = 'block';\n}", "function cancelForm() { switchToView('listing'); }", "function closeInformationDialogBox() {\n document.getElementById(\"checkDoc\").style.display = \"none\";\n document.getElementById(\"dialogBox\").style.display = \"none\";\n}", "function hide_add_product()\n{\n\t//hide the modal box \n\t$('.overlay').hide(); \n\t$('#product_picker').hide(); \t\n\t//Redraw the screen \n\tredraw_order_list();\n}", "function openGestionFilm() {\n\n $(\"#logindiv\").hide();\n $(\"#signupdiv\").hide();\n $(\"#allProd\").hide();\n $(\"#gestionMembreDiv\").hide();\n $(\"#gestionFilmDiv\").show();\n}", "hide(){\n\t\tif(atom && this.panel)\n\t\t\tthis.panel.hide();\n\t\telse (\"dialog\" === this.elementTagName)\n\t\t\t? this.element.close()\n\t\t\t: this.element.hidden = true;\n\t\tthis.autoFocus && this.restoreFocus();\n\t}", "function hideBoardTitleForm() {\n vm.isBoardTitleFormVisible = false;\n }", "function hideForm2() {\n $('.form-2').hide();\n }", "function showForm() {\n var orderForm = document.forms.order;\n orderForm.classList.toggle('disactive');\n }", "function closeForm(hiddenFormID) {\n\tdocument.getElementById(hiddenFormID).style.display = 'none';\n}" ]
[ "0.66123235", "0.65635896", "0.65525305", "0.6478083", "0.64173216", "0.6416694", "0.63985556", "0.63683105", "0.6364733", "0.6262822", "0.6239844", "0.6239844", "0.62326294", "0.62016577", "0.6171097", "0.61555815", "0.6123144", "0.61150104", "0.605529", "0.6045824", "0.6034964", "0.6020635", "0.60058105", "0.6000355", "0.5962955", "0.59553236", "0.5954376", "0.593601", "0.5935975", "0.5922114", "0.5914204", "0.59117377", "0.5902933", "0.58901304", "0.5887187", "0.5878359", "0.58661675", "0.58653164", "0.58613193", "0.58590055", "0.5856311", "0.58548945", "0.58495075", "0.58452684", "0.5836889", "0.5807491", "0.58072984", "0.5805092", "0.57990897", "0.5797489", "0.57939374", "0.579127", "0.5785707", "0.5772961", "0.57650936", "0.57518905", "0.57480216", "0.5729151", "0.5723177", "0.571721", "0.5716925", "0.5713456", "0.5706872", "0.57061213", "0.5698954", "0.5695646", "0.56955296", "0.5695333", "0.5694598", "0.5687887", "0.5676821", "0.56765413", "0.5652718", "0.5651643", "0.5648468", "0.5648005", "0.56463915", "0.5640329", "0.56329113", "0.56296974", "0.562784", "0.56255484", "0.56255484", "0.5625307", "0.56226504", "0.5622209", "0.5619102", "0.56189984", "0.5615688", "0.56149393", "0.56131756", "0.5604892", "0.5602997", "0.56000817", "0.5595475", "0.55951494", "0.5592343", "0.5590404", "0.5590198", "0.5588344" ]
0.64333135
4
read saved data on start
async function loadSavedData() { const newData = await new Promise(resolve => { fs.readFile(TMP_DB_PATH, (err, content) => { if (err) console.log("Error loading saved data from file. ", err); return resolve(JSON.parse(content)); }); }); if (Array.isArray(newData) && newData.length) { data = newData; console.log("Loaded saved data from file."); } else { console.log("No data in the file."); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function initialize() {\n fs.readFile(\"data.json\", (err, data) => {\n if (err) {\n return console.error(\"FATAL: couldn't restore app state from data.json\");\n }\n var state = JSON.parse(data);\n interactionsHistory = data.interactionsHistory || {};\n engagementHistory = data.engagementHistory || [];\n lastMentionId = data.lastMentionId || 1;\n lastCycleTime = data.lastCycleTime || 0;\n \n schedule();\n });\n}", "function readAppData()\n {\n nsmethods.readDataIntoApplication();\n }", "function LoadData(){\n\tLoadDataFiles();\n\tExtractDataFromFiles();\n}", "function prepareProcessedData() {\n // #BUG: Had to add resourcesDirectory for Android...\n state.processedData = JSON.parse(Ti.Filesystem.getFile(Ti.Filesystem.resourcesDirectory + 'common/data-base.json').read().text);\n}", "readData() {\n\t\t// Se non esiste, lo crea, con le impostazioni di default\n\t\tif (!fs.existsSync(this.filepath)) {\n\t\t\tlogger.debug('Creato nuovo file di impostazioni.');\n\t\t\tthis.writeData();\n\t\t\treturn;\n\t\t}\n\n\t\ttry {\n\t\t\tconst text = fs.readFileSync(this.filepath, 'utf8');\n\t\t\t// file YAML => {}\n\t\t\tconst data = yaml.safeLoad(text);\n\n\t\t\t// NOTE: validazione in lettura su readData, mentre in scrittura su setData.\n\t\t\tif (!isValid(data)) {\n\t\t\t\tthrow new Error('impostazioni del file non valide.');\n\t\t\t} else {\n\t\t\t\tthis.data = data;\n\t\t\t}\n\t\t} catch (e) {\n\t\t\tlogger.error(`Errore nella lettura file yaml: ${e.toString()}`);\n\t\t}\n\t}", "function loadData()\n{\n /***************\n * GET INTEGER *\n ***************/\n function getInt(name)\n {\n return parseInt(localStorage.getItem(name));\n }\n\n /***************\n * GET BOOLEAN *\n ***************/\n function getBool(name)\n {\n var data = getInt(name);\n if (data !== 0 && data !== null && data != undefined && !isNaN(data))\n return true;\n else\n return false;\n }\n \n // if local data exists, then get it\n if (getBool('data') === true)\n {\n // parse data\n ax = getInt('ax');\n ay = getInt('ay');\n dx = getInt('dx');\n dy = getInt('dy');\n score = getInt('score');\n recent = getInt('recent');\n hScore = getInt('hScore');\n paused = getBool('paused');\n doWrap = getBool('doWrap');\n \n // parse snake dataa\n var length = getInt('length');\n snake = [];\n for (var i = 0; i < length; i++)\n {\n var sx = getInt('snake' + i + 'x');\n var sy = getInt('snake' + i + 'y');\n snake.push({x: sx, y: sy}); \n }\n }\n // otherwise, initialize it\n else\n resetData();\n}", "function loadData() {\n try {\n const fsStorageAsArray = JSON.parse(localStorage.getItem(\"saveArray\"));\n fromSaveFormat(fsStorageAsArray);\n } catch (err) {\n // fill some initial data\n fsStorage = [\n {\n id: 0, name: \"root\", children: [\n { id: 1, name: \"sub1\", children: [\n { id: 4, name: \"file.txt\"},\n { id: 5, name: \"sub3\", children: [\n {id: 6, name: \"file2.txt\", content: \"content2\"}\n ]}\n ]},\n { id: 2, name: \"sub2\", children: []},\n { id: 3, name: \"file1.txt\", content: \"text\"}\n ]\n }\n ]\n }\n }", "function loadData() {\n try {\n get_valsFromJSON(JSON.parse(atob(localStorage.sv1)));\n } catch(NoSuchSaveException) { \n console.log(\"No saved data to load: \" + NoSuchSaveException);\n }\n}", "function loadData() {\n var strBookPath = io.appendPath(conf.bookPath, this.strBookName);\n var strBookStructurePath = io.appendPath(strBookPath, conf.bookStructureFileName);\n io.getXmlContent(strBookStructurePath, setBookStructureXml);\n io.getFilesInDirectory(strBookPath, setPageFileNames);\n}", "function _loadSavedData(cb) {\n if (window.localStorage._taskData === undefined) {\n window.memory.data = {\n \"FOCUS\" : [],\n \"TODAY\" : [],\n \"LATER\" : [],\n \"ASANA\" : [],\n \"NEVER\" : []\n };\n } else {\n window.memory.data = JSON.parse(window.localStorage._taskData);\n }\n if (cb) cb();\n}", "function loadData()\n\t{\n\t\tloadMaterials(false);\n\t\tloadLabors(false);\n\t}", "loadData() {\r\n\t\t// load the current tracker type data from localStorage\r\n\t\tlet currentData = localStorage.getItem( this.type );\r\n\r\n\t\t// parse it into an object if it exists\r\n\t\tif ( currentData ) {\r\n\t\t\tthis.data = JSON.parse(currentData);\r\n\t\t} else {\r\n\t\t\tthis.data = {};\r\n\t\t}\r\n\t}", "function loadData(){\n\t\tloadParetoData();\n\t\tloadConstraints();\n\t\t\n\t}", "function loadData() {\n // set all our variables\n setVars(twitch.configuration)\n // do an initial browse to `/`(root)\n navigate()\n // remove our loading element from the DM\n removeElement(\"repo-loading\")\n}", "readData() {\r\n if (window.localStorage.getItem(this[\"key\"]) != null) {\r\n this.data = JSON.parse(window.localStorage.getItem(this[\"key\"]));\r\n }\r\n \r\n return this.data;\r\n }", "function getAndProcessData() { \n\t\tchooseFileSource();\n\t}", "initializeLoadOrder() {\n this.loadorder = json.read(\"user/cache/loadorder.json\");\n }", "function preload () { \n training_data = loadStrings('./data/train_10000.csv', () => console.log(\"Training data loaded\"))\n testing_data = loadStrings('./data/test_1000.csv', () => console.log(\"Testing data loaded\"))\n}", "function readUserData() {\r\n\treturn fs.readFileSync(storagePath, \"utf8\");\r\n}", "function readStorage() {\n\tstudentGrade = localStorage.getItem(\"Student Grade:\");\n\tstudentGender = localStorage.getItem(\"Student Gender:\");\n\tstudentClub = localStorage.getItem(\"Student Club:\");\n\tstudentNumber = localStorage.getItem(\"Student Number:\");\n\tannTitle = JSON.parse(localStorage.getItem(\"AnnTitle:\"));\n\tannDetails = JSON.parse(localStorage.getItem(\"AnnDetails:\"));\n\tannGrade = JSON.parse(localStorage.getItem(\"AnnGrade:\"));\n\tannGender = JSON.parse(localStorage.getItem(\"AnnGender:\"));\n\tannClub = JSON.parse(localStorage.getItem(\"AnnClub:\"));\n\tannStudentNumber = JSON.parse(localStorage.getItem(\"AnnStudentNumber:\"));\n\tannDateTime = JSON.parse(localStorage.getItem(\"AnnDateTime:\"));\n}", "function ImportData() {\n //in this method we can connect to database or read our necessery info from file\n //Currently we read registered users from file and History matches from file(maybe) and save to lists\n ReadFromFile();\n}", "function _loadData()\n\t{\n\t\ttry\n\t\t{\t\t\t\t\t\t\t\t\t\t\t\t\t//create EZ.script.options from defaults\n\t\t\tvar options = EZ.script.options = EZ.options(EZ.defaultOptions.script);\t\t\n\t\t\t\n\t\t\t//---------------------------------------------------------------------\n\t\t\tvar json = localStorage.getItem('EZ.script.savedData')\n\t\t\tEZ.script.savedData = json ? JSON.parse(json) : {}\t\n\t\t\t//---------------------------------------------------------------------\n\t\t\t\n\t\t\tvar savedData = json ? JSON.parse(json) : {}\t\n\t\t\tif (savedData.version != options.version)\n\t\t\t\tsavedData = {version: options.version, timestamp:''};\n\t\t\t//savedData.listValues = savedData.listValues || {}\n\t\t\tsavedData.listOptions = savedData.listOptions || {};\n\t\t\tsavedData.fieldValues = savedData.fieldValues || {};\n\t\t\t\n\t\t\tvar log = EZ.field.add(savedData.fieldValues);\t//restore saved fieldValues\n\t\t\tEZ.log('EZscript.loadData', 'restored fieldValues', log);\n\t\t\t\n\t\t\tlog = EZ.field.add(['EZscript']);\t\t\t\t//add fields with default values (not saved)\n\t\t\tEZ.log('EZscript.loadData', 'all EZscript fields', {log:log});\n\t\t\t\n\t\t\tlog = EZ.event.trigger(['EZscript']);\t\t\t//fire events to initialize EZ.script.options\n\t\t\tEZ.log('EZscript.loadData', {'onload events':log})\n\t\t\t\n\t\t\tsetTimeout(function()\t\t\t\t\t\t\t//after events run...\n\t\t\t{\n\t\t\t\toptions.listNames.forEach(function(name)\t//populate saved list(s) options\n\t\t\t\t{\t\t\t\t\t\t\t\t\t\t\t//...and select save values\n\t\t\t\t\tvar list = _getEl(options.tags[name]);\n\t\t\t\t\tif (list)\n\t\t\t\t\t{\n\t\t\t\t\t\tvar listValue = EZ.get(list);\n\t\t\t\t\t\tvar listOptions = '.'.concat(name,'.optionsList').ov(savedData.listOptions)\n\t\t\t\t\t\t\t\t\t || [].slice.call(list.options);\n\t\t\t\t\t\tlistOptions = EZ.script.listOptions[name] \n\t\t\t\t\t\t\t\t\t= EZ.displayDropdown(list, listOptions, listValue);\n\t\t\t\t\t\t_displayValue(name + 'Count', listOptions.valueList.length.wrap('['))\n\n\t\t\t\t\t\tvar value = EZ.get(list)\n\t\t\t\t\t\tif (name == 'history' && value.toInt() > 0)\n\t\t\t\t\t\t\t_displayValue('optionTime', value);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (name == 'favorites' && list.selectedIndex > 1)\n\t\t\t\t\t\t\t_displayValue('favoriteName', list.options[list.selectedIndex].text);\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t\tEZ.script.saveData()\n\t\t\t}, 0 );\n\t\t}\n\t\tcatch (e)\n\t\t{\n\t\t\treturn EZ.oops(e);\n\t\t}\n\t}", "function loadSaveData() {\n // Load configuration first\n let iconConfig = localStorage.getItem(\"IconConfig\") || \"image\";\n setIcons(iconConfig, false);\n \n let styleConfig = localStorage.getItem(\"StyleConfig\") || \"light\";\n setStyle(styleConfig);\n \n setListStyle(isListActive(), false);\n \n if (getLocal(currentMode, \"CompletedVisible\") == null) {\n let isNewSave = (getLocal(currentMode, \"Completed\") == null);\n setLocal(currentMode, \"CompletedVisible\", isNewSave.toString()); // New saves start open\n }\n \n if (currentMode == \"event\") {\n loadEventSaveData();\n } else {\n loadMainSaveData();\n }\n \n // Finally load up the completion time data\n missionCompletionTimes = {};\n let loadedCompletionTimes = getLocal(currentMode, \"CompletionTimes\");\n if (loadedCompletionTimes != null) {\n let completionTimesHash = JSON.parse(loadedCompletionTimes);\n for (let missionId in completionTimesHash) {\n missionCompletionTimes[missionId] = parseInt(completionTimesHash[missionId]);\n }\n }\n}", "readin () {\n this.content = readFile(this.path);\n }", "function Load()\n{\n // The file *does* exist\n if (fs.existsSync(\"save.json\"))\n {\n savedatasw = 1;\n const importdata = fs.readFileSync('save.json', 'utf8');\n const playerdata = JSON.parse(importdata);\n playername=playerdata.playername;\n playerlvl=playerdata.playerlvl;\n health=playerdata.health;\n mana=playerdata.mana;\n gold=playerdata.gold;\n savecoord=playerdata.savecoord;\n savedatasw=playerdata.savedatasw;\n playerinfo.playername=playername;\n playerinfo.playerlvl=playerlvl;\n playerinfo.health=health;\n playerinfo.mana=mana;\n playerinfo.gold=gold;\n playerinfo.savecoord=savecoord;\n playerinfo.savedatasw=savedatasw;\n return;\n }\n\n return;\n }", "function restoreData() {\n myLibrary = []\n retrieveDataFromStorage(myLibrary)\n}", "static async initGlobalData(){\n\t\tvar fileNames = await this.GetFileNames();\n\t\t\n\t\t_retrieveGlobal = async () => {\n\t\t\ttry {\n\t\t\t\tconst value = await AsyncStorage.getItem(\"GlobalData\");\n\t\t\t\t\n\t\t\t\tif (value != null) {\n\t\t\t\t\t//we have played before, load our GlobalData object into GameData\n\t\t\t\t\tGameData.setGlobalData(JSON.parse(value));\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\telse{\n\t\t\t\t\t//we have never played before, do nothing, waiting until the end of a player's first level to save the GlobalData object \n\t\t\t\t}\n\t\t\t\t\n\t\t\t} catch (error) {\n\t\t\t\t// Error retrieving data\n\t\t\t\talert(error);\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn _retrieveGlobal();\n\t}", "function preload ( ) {\n // Read in all the data\n lines = loadStrings ( \"./distances2.csv\" ) ;\n}", "loadData() {\n\n }", "function initStorage(storage) {\n if (storage.isEmpty()) {\n // load the initial knowledge base from a text file in turtle format\n $.get('initial_kb.txt', function(turtle) {\n storage.loadKnowledgeBaseFromString(turtle);\n //alert(\"from local file: \" + turtle);\n storage.save();\n }, 'text');\n } else {\n storage.load();\n }\n}", "function init() {\n if (localStorage.AddressBookRecord) {\n addresBookArray = JSON.parse(localStorage.AddressBookRecord);\n }\n}", "load() {\n\t\t\tlet storage = Storage.local.get('commander') || null;\n\t\t\tif (storage) {\n\t\t\t\tupdate(bs => {\n\t\t\t\t\tbs = storage;\n\t\t\t\t\treturn bs;\n\t\t\t\t});\n\t\t\t}\n\t\t}", "function init() {\n fs.readFile(\"./db/notes.json\", \"utf8\", function (err, data) {\n if (err) {\n throw err;\n }\n let notesJSON = JSON.parse(data);\n notesJSON.forEach(function (note) {\n notes.push(note);\n });\n lastId = Math.max(...notes.map((obj) => obj.id), 0) + 1;\n });\n}", "function init(){\n getData();\n}", "startReading() {\n this.startDate = Date.now();\n this.updatedDate = this.startDate;\n this.pageNumber = 1;\n }", "function dataLoad()\n{\n try{\n var writ = fs.readFileSync('note.json')\n var buff = writ.toString();\n return JSON.parse(buff);\n }\n catch(e)\n {\n return [];\n }\n}", "function readData() {\n\t\t\t\tconsole.log(\"Estado Session:\", sessionService.estadoSesion);\n\t\t\t\tif(sessionService.estadoSesion !== 00){\n\t\t\t\t\tjAlert(mensajeTexto.sesionExpirada, mensajeTexto.controlAcces, function () {\n\t\t\t\t\t\t$state.go('login');\t\n\t\t \t});\n\t\t\t\t}else{\n\t\t\t\t\treadDataSel();\n\t\t\t\t\treadDataQueue();\n\t\t\t\t}\n\t\t\t}", "function read() {\n\tvar data = JSON.parse(fs.readFileSync('db/db.json', 'utf-8'));\n\treturn data;\n}", "function preLoad() {\n\n\t\t\tangular.forEach($localStorage, function(value, key) {\n\t\t\t\tlocalStorageObj[key] = value\n\t\t\t});\n\n\t\t}", "function initData(callback) {\n initLanguage(); // set the system language if not set\n DB.loadAll(function() {\n if(getUsers() === null){\n setUsers(DB.users);\n console.log('storing users in localStorage');\n }\n if(getBeverages() === null){\n setBeverages(DB.beverages);\n console.log('Storing beverages in localstorage');\n }\n if(getOrders() === null){\n setOrders([]);\n }\n if(callback) callback();\n });\n}", "function preload() {\n //load json file\n data = loadJSON(\"./content.json\");\n}", "function preload(){\n\t//loads .json data\n\t\tdata = loadJSON('paris-weather.json');\n}", "function loadData() {\n sizeJSON = localStorage != null ? localStorage[\"size\"] : null;\n cartDataJSON = localStorage != null ? localStorage[\"cartData\"] : null;\n if (cartDataJSON != null && sizeJSON != null && JSON != null) {\n try {\n size = JSON.parse(sizeJSON);\n cartData = JSON.parse(cartDataJSON);\n }\n catch (err) {\n // ignore errors while loading...\n }\n }\n }", "async initializeDataLoad() {\n }", "function init() {\n createDataReader('heartbeat', true);\n createDataReader('timing');\n createDataReader('telemetry');\n }", "preIngestData() {}", "function readData() {\n d3.json(url).then(function (data) {\n samples_data = data;\n initializeIDPulldown();\n buildBarChart(0);\n buildBubbleChart(0);\n buildDemographics(0);\n buildGaugeChart(0);\n // log out the entire dataset\n console.log(samples_data);\n })\n}", "async loadStartData() {\n console.timeStart('track');\n for (let document of this.documents.all()) {\n if (this.shouldTrackFile(vscode_uri_1.URI.parse(document.uri).fsPath)) {\n this.trackOpenedDocument(document);\n }\n }\n if (this.alwaysIncludeGlobPattern) {\n let alwaysIncludePaths = await util_1.promisify(glob_1.glob)(this.alwaysIncludeGlobPattern, {\n cwd: this.startPath || undefined,\n absolute: true,\n });\n for (let filePath of alwaysIncludePaths) {\n filePath = vscode_uri_1.URI.file(filePath).fsPath;\n if (this.shouldTrackFile(filePath)) {\n this.trackFile(filePath);\n }\n }\n }\n await this.trackFileOrFolder(this.startPath);\n console.timeEnd('track', `${this.map.size} files tracked`);\n this.startDataLoaded = true;\n }", "async function init() {\n try {\n // Fetch new data\n currentLocation = await getLocation();\n const coordinates = `${currentLocation.coords.latitude},${currentLocation.coords.longitude}`;\n forecast = await getForecast(coordinates);\n\n // Render data\n renderForecast(forecast);\n renderCoordinates(currentLocation);\n\n // Save data\n localStorage.setItem('location', coordinates);\n localStorage.setItem('forecast', JSON.stringify(forecast));\n } catch (err) {\n renderErrors(err);\n }\n}", "function loaddata(){\n\t\tvar data1 = localStorage.getItem(\"infor_sku\") || \"\";\n\t\tvar data2 = localStorage.getItem(\"pd\") || \"\";\n\t\tvar data3 = localStorage.getItem(\"sh\") || \"\";\n\t\tif (!!data1) { sku_items = JSON.parse(data1); }\n\t\tif (!!data2) { pd_items = JSON.parse(data2); }\n\t\tif (!!data3) { sh_items = JSON.parse(data3); }\n\t\t$(\"#datafile\").val( localStorage.getItem(\"datafile\") ||\"http://123.123.123.250:5000/\");\n\t\t$(\"#myfile\").val( localStorage.getItem(\"myfile\") ||\"spchkm/\");\n\t\t\n\t}", "function initializeData() {\n const profileContents = fs.readFileSync(profileEntriesFile, 'utf8');\n const data = jsonic(profileContents);\n _.each(data, function (entry) {\n profileData.push(entry);\n });\n\n filterInterest.initData();\n}", "loadStateImage() {\n let stateData = path.join(this.cwd, this.USER_DATA, this.TUTORSTATE);\n this.state = JSON.parse(fs.readFileSync(stateData));\n }", "function preload(){\n\tdata = loadJSON('population.json'); // data variable is assigned json data\n}", "function readData(){\r\n let dataRead = fs.readFileSync('data.json');\r\n let infoRead = JSON.parse(dataRead);\r\n return infoRead;\r\n}", "function getSavedData() {\n chrome.storage.sync.get({\n data: SAMPLE_DATA,\n }, function (saved) {\n data = saved.data;\n });\n}", "function preload() {\n data = loadTable('dict.csv', 'csv');\n}", "function initData(){\n o_data = user.original_musics;\n d_data = user.derivative_musics;\n c_data = user.collected_musics;\n}", "function loadData() {\n // STAND\n loadStandData();\n // PIT\n loadPitData();\n // IMAGES\n loadImageData();\n // NOTES\n loadNotesData();\n // PRESCOUTING\n loadPrescouting(\"./resources/prescout.csv\");\n\n}", "function initializeStock() {\n\tbank = json.readFileSync(\"./wallet/bank.json\");\n}", "function start() {\n\treadStorage();\n\tdisplayAnn();\n}", "function ResumeManager_LoadData()\n{\n\t//by default we have no data\n\tvar resume = null;\n\t//do we have a valid controller?\n\tif (__CONTROLLER && __CONTROLLER.getResumeData)\n\t{\n\t\t//retrieve the resume data\n\t\tresume = __CONTROLLER.getResumeData();\n\t\t//valid?\n\t\tif (resume)\n\t\t{\n\t\t\t//is this a string?\n\t\t\tif (typeof resume == \"string\")\n\t\t\t{\n\t\t\t\t//convert to object\n\t\t\t\tresume = JSON.parse(resume);\n\t\t\t}\n\t\t\t//designer data object?\n\t\t\tif (resume.DesignerPreview)\n\t\t\t{\n\t\t\t\t//build the resume data from the preview data (using this so that all (most!) the resume code is here)\n\t\t\t\tresume = ResumeManager_GeneratePreviewData(resume.PathToStart);\n\t\t\t}\n\t\t\t//and now update its funcions\n\t\t\tresume.RestoreLesson = Resume_RestoreLesson;\n\t\t\tresume.StatesLoaded = Resume_StatesLoaded;\n\t\t\tresume.VerifySatesOptimised = Resume_VerifySatesOptimised;\n\t\t\tresume.MaximiseData = Resume_MaximiseData;\n\t\t\tresume.Notify_Get_ItemList_CallBack = Resume_Notify_CallBack;\n\t\t\tresume.Notify_State_CallBack = Resume_Notify_CallBack;\n\t\t}\n\t}\n\t//return the data\n\treturn resume;\n}", "constructor() {\n this.data = this._loadData();\n }", "loadFromFile() {\n // Don't save or load state if useRootDir is true\n if ( this.useRootDir ) {\n return;\n }\n\n if ( fs.existsSync( this.saveFile ) ) {\n const serialization = JSON.parse( fs.readFileSync( this.saveFile, 'utf-8' ) );\n this.snapshots = serialization.snapshots.map( Snapshot.deserialize );\n this.trashSnapshots = serialization.trashSnapshots ? serialization.trashSnapshots.map( Snapshot.deserializeStub ) : [];\n if ( serialization.pendingSnapshot && serialization.pendingSnapshot.directory ) {\n this.trashSnapshots.push( Snapshot.deserializeStub( serialization.pendingSnapshot ) );\n }\n }\n }", "function loadData(){ \t\n \t//if (gameData.data.player.playerID>0) {\n \t\tCORE.LOG.addInfo(\"PROFILE_PAGE:loadData\");\n \t\t//var p = new ProfileCommunication(CORE.SOCKET, setData); \t\t\n \t\t//p.getData(gameData.data.player.playerID); \t\t\n \t\t\n \t//}\n \t//else \n \t\tsetDataFromLocalStorage(); \t \t \t\n }", "function recoverPomoData() {\n if (localStorage.getItem(\"cpid\") !== null) {\n // Do not change these to getters and setters\n currentPomoID = parseInt(localStorage.getItem(\"cpid\"));\n pomoData = JSON.parse(localStorage.getItem(\"pomoData\"));\n }\n updateTable();\n}", "function preload() {\n\tdata = loadJSON('new-york-weather.json');\n}", "function initializeDataStorage() {\n for(i = 0; i < ordered_plates.length; i++) {\n sessionStorage.setItem(ordered_plates[i].name, 0);\n }\n }", "getData() {\n // todo: read from fs if you have it already or retrieve using storage layer client\n return fs.readFileSync(Chunk.getChunkStoragePath(this.id), { encoding: null });\n }", "function loadAll(){\n\tchangeSeason()\n\tgetAnimeData()\n\tgetCharacterData()\n\tgetEpisodeData()\n\tgetImageData()\n\tgetVideoData()\n}", "load() {\n try {\n appState.state.cursor().update( cursor => {\n return cursor.merge( JSON.parse( window.localStorage.getItem( APPCONFIG.LS ) ) )\n })\n } catch( err ) {\n console.error( 'Error loading from local storage' )\n console.error( err )\n return\n }\n\n console.log( 'loaded' )\n }", "async function load() {\n const str = await localStorage.getItem(KEY);\n if (!str) return;\n let initialState;\n ({ path, text, revision, lineCount, store: initialState } = JSON.parse(\n str\n ));\n store = createStore(reducer, initialState);\n }", "function readFromFileAndInitAppState(fileName) {\n var stringReadFromFile = null;\n\n // Initialize a roaming folder variable.\n var roamingFolder = Windows.Storage.ApplicationData.current.roamingFolder;\n\n // Open tne file asynchronously.\n roamingFolder.getFileAsync(fileName).done(function (file) {\n file.openAsync(Windows.Storage.FileAccessMode.read).done(function (stream) {\n var size = stream.size;\n var inputStream = stream.getInputStreamAt(0);\n\n // Create a DataReader object.\n var reader = new Windows.Storage.Streams.DataReader(inputStream);\n\n // Read from the file.\n reader.loadAsync(size).done(function () {\n stringReadFromFile = reader.readString(size);\n\t\t reader.close();\n if (stringReadFromFile) {\n loadStatus = initializeAppState(stringReadFromFile, fileName);\n }\n callBackToComputeLoadState();\n }, function (errorOnReaderLoadAsync) {\n reader.close();\n callBackToComputeLoadState();\n });\n }, function (errorOnOpenFile) {\n callBackToComputeLoadState();\n });\n }, function (errorOnGetFileAsync) {\n callBackToComputeLoadState();\n });\n }", "function load() {\n m_data.load(\"b4w/obj/moto.json\", load_cb);\n}", "function loadLocalData(){\n if($scope.loading){\n return;\n }\n $scope.loading = true;\n storeService.getAllEntries(soup.name, sortBy, 'ascending').then(function(result){\n $scope.entries = result.currentPageOrderedEntries;\n console.log('entries', $scope.entries);\n $scope.loading = false;\n }, function(err){\n $scope.loading = false;\n });\n }", "function loadData() {\n var storedDay = JSON.parse(localStorage.getItem(\"myDay\"));\n\n if (storedDay) {\n myDay = storedDay;\n }\n\n saveToDos();\n displayToDos();\n}", "function loadData()\n{\n loadJSON('lastSearch.json', loadedData);\n}", "read() {\n try {\n this._toggleEditThrobber();\n var id = parseInt(document.getElementById('edit_id').value);\n var outputEl = this._clearOutput();\n \n // read data from db\n var jsonObj = this.dao.read(id);\n if (!jsonObj) throw `Error reading experiment data for audiogram ${id}`;\n //console.log(jsonObj)\n this._showOutput(id, jsonObj);\n\n } catch(e) {\n console.log(e);\n alert(e);\n }\n this._toggleEditThrobber();\n }", "preloadJson()\n {\n currentScene.load.json('dialogues', 'data/SingleDialogues.json');\n currentScene.load.json('notes', 'data/Notes.json');\n }", "function readTrie() {\n var triePath = path.join(__dirname, './trie.json');\n if (fs.existsSync(triePath)) {\n // Read trie data from file (stored in case server restarts)\n const data = fs.readFileSync(triePath);\n var fileDataTrie = JSON.parse(data);\n trie = Object.setPrototypeOf(fileDataTrie, trieNode.prototype);\n console.log(\"Loading of previous trie done.\");\n } else {\n saveTrie();\n }\n}", "function preload() {\n restaurantFile = loadJSON(\"Restaurant.json\");\n}", "function loadData() {\n\n //Users name.\n loadName()\n\n //Users config.\n loadConfig()\n}", "read() {\n return readFileAsync(\"db/db.json\", \"utf8\"); // shows the notes from the database json file (db.json)\n }", "onLoad() {\n this.curLogic = require(\"logic\").getInstance();\n emitter.on(\"getdifficultData\",this.resetdifficultData,this); //保证能在数据层的json读取后赋值\n this.difficult = null;\n this.difficultData = this.curLogic.get(\"difficultData\");\n this.levelsData = [];\n this.initDiffState();\n this.initEditLevel();\n this.isshowLevels();\n }", "function start_db () {\r\n dataref = firebase.database()\r\n read()\r\n}", "function reloadData() {\n if (typeof (CPData) != \"undefined\") { CPData.regenerate(); }\n if (typeof (CPDataSoon) != \"undefined\") { CPData.regenerate(); }\n if (typeof (CPDataDownloaded) != \"undefined\") { CPData.regenerate(); }\n loadInfo();\n }", "function init()\r\n\t\t\t{ \r\n\t\t\t\tget_data('get_dir','','directory');\r\n\t\t\t\tget_data('read_dir','current_dir','file_folder');\r\n\t\t\t}", "leerDB() {\n //Verificar si existe el archivo, si no existe, el array de historial queda como se declaro (vacio).\n if (fs.existsSync(this.dbPath)) {\n const info = fs.readFileSync(this.dbPath, { encoding: 'utf-8' });\n const data = JSON.parse(info);\n this.historial = data;\n }\n }", "function initLoad() {\n\n\tvar cityHistStore = JSON.parse(localStorage.getItem('city'));\n\n\tif (cityHistStore !== null) {\n\t\tcityHist = cityHistStore\n\t}\n\tgetHistory();\n\tgetWeatherToday();\n}", "function load(callback){\r\n\tutil.log(\"Data: Saving All...\");\r\n\t//Save Each\r\n\tutil.log(\"Data: Saving Done...\");\r\n}", "function initialize() {\n//here you would load your data\n}", "loadingData() {}", "loadingData() {}", "resetData() {\n\t\t\tthis.initFlags();\n\t\t\tthis.initMetadata();\n\t\t}", "function read(){\n let AllKeys = Object.keys(localStorage);\n devKeys=AllKeys.filter(value => value.startsWith('Sdev'));\n // the global variable for al the objects\n devObjects=devKeys.map(obj => JSON.parse(localStorage.getItem(obj)));\n display_developers();\n}", "function preload() {\n data = loadJSON(\"data/clean_speech_pop_20.json\");\n table = loadTable(\"data/mturk_task_sortedcity.csv\", \"csv\", \"header\");\n}", "function initializeData() {\n \tconsole.log(\"Initializing data from session.json...\")\n \tvar rawData = fs.readFileSync(dataFile);\n \tdata = JSON.parse(rawData);\n\n \t// Reads in current collections located in data/corpus-files\n \tlet collections = fs.readdirSync('./data/corpus-files').filter(function (file) {\n\t\treturn fs.statSync('./data/corpus-files/' + file).isDirectory();\n\t});\n\n\t// Deletes any collections in the data JSON structure that don't appear\n\t// within our folder and prints a warning message.\n\tvar remove = [];\n\tfor (var c in data['collections']) {\n\t\tif (!collections.includes(c)) {\n\t\t\tremove.push(c);\n\t\t}\n\t}\n\tfor (var i in remove) {\n\t\tdelete data[remove[i]];\n\t\tconsole.log('WARNING: ' + remove[i] + ' collection doesn\\'t exist in data/corpus-files. Please either add the files or delete the entry from session.json.');\n\t}\n }", "function readLocalStorage() {\n let readed = localStorage.getItem(\"language\");\n if(readed == null) {\n readed = \"English\"; // First time - Default\n console.log(\"No había nada en LocalStorage\");\n }\n controlLanguage(readed);\n }", "function load_progress_as_of_last_saved() {\n\tif (progress_snapshot == 0) {\n\t\t// No progress, load from the start of level\n\t\t// Note that these values are already filled out\n\t\treturn true\n\t}\n\telse {\n\t\tlevel_number = progress_snapshot[0]\n\t\tquestion_number = progress_snapshot[1]\n\t\tdisplay_format = progress_snapshot[2]\n\t\tquestions_correct_total_count = progress_snapshot[3]\n\t\tquestions_incorrect_total_count = progress_snapshot[4]\n\t\tquestions_correct_level_count = progress_snapshot[5]\n\t\tquestions_incorrect_level_count = progress_snapshot[6]\n\t}\n}", "function initData(){\n container.prepend(progressInfo);\n jQuery.get(getPageURL(0, resource)).done(function(data) {\n records = processData(data, true);\n initView(new recline.Model.Dataset({records:records}));\n numReq = getRequestNumber(data.result.total, pageSize);\n for (var i = 1; i <= numReq; i++) {\n requestData(getPageURL(i, resource));\n };\n });\n }", "loadProgram() {\n const getBooks = JSON.parse(localStorage.getItem(STORAGE_NAME));\n const getId = JSON.parse(localStorage.getItem(STORAGE_ID));\n if (getBooks && getBooks.length != 0) {\n const storedBooks = getBooks;\n const storedId = getId;\n myLibrary = [...storedBooks];\n bookId = parseInt(storedId);\n console.log('loaded');\n } else {\n myLibrary = [...FILLER_DATA];\n bookId = 2;\n console.log('default');\n }\n storage.saveData();\n this.renderElem.render();\n }" ]
[ "0.6337528", "0.6305773", "0.6291212", "0.6202274", "0.6178993", "0.614394", "0.61196107", "0.6113442", "0.60658365", "0.6051222", "0.60293895", "0.60205126", "0.6005231", "0.59646505", "0.59555554", "0.59379375", "0.5937245", "0.59237146", "0.59133095", "0.5900318", "0.5896602", "0.58939207", "0.58935153", "0.5884373", "0.58748674", "0.5871461", "0.5851313", "0.58184916", "0.5812505", "0.5797529", "0.579699", "0.57866293", "0.5786326", "0.57850844", "0.57582784", "0.5758056", "0.5749623", "0.57407033", "0.5733216", "0.5731504", "0.5721111", "0.57196075", "0.571893", "0.5715971", "0.56941974", "0.56937623", "0.5690691", "0.56858116", "0.5678913", "0.56781936", "0.56743354", "0.5674023", "0.56720024", "0.5652469", "0.5632007", "0.56315756", "0.5618594", "0.56185764", "0.5618086", "0.56170684", "0.5606926", "0.5599955", "0.55984265", "0.55936545", "0.55741334", "0.5566473", "0.5563877", "0.5552855", "0.5551358", "0.55511", "0.55506945", "0.55490553", "0.55479467", "0.5547575", "0.55427366", "0.5539239", "0.5534968", "0.5522669", "0.55174625", "0.55149156", "0.5513518", "0.55041283", "0.55026764", "0.5500902", "0.5499541", "0.54888046", "0.5479354", "0.54706514", "0.5461493", "0.5460238", "0.5458647", "0.5458647", "0.5457808", "0.5455821", "0.5454698", "0.5449108", "0.5446502", "0.5442149", "0.5440132", "0.5436397" ]
0.6179756
4
Component responsible for present list of all posts
function UserShow(props) { const { match } = props; const [posts, setPosts] = useState([]); const [user, setUser] = useState({}); const [totalItems, setTotalItems] = useState(0); // Default page in pagination const [page, setPage] = useState(1); const [perPage, setPerPage] = useState(0); const [isLoading, setIsLoading] = useState(true); const [errors, setErrors] = useState(""); // Fetch post list from backend with pagination. Refetch data when page change useEffect(() => { setIsLoading(true); userService .show(match.params.id, page) .then(response => { setPosts(response.data.posts); setUser(response.data.user); setTotalItems(response.data.meta.total); setPerPage(response.data.meta.per_page); setIsLoading(false); }) .catch(error => { if (error.response) { let error_messages = ""; if (error.response.status === 500) { error_messages = "Backend not responding"; } else { error_messages = error.response.statusText; } setErrors(error_messages); } else if (error.request) { setErrors("Something went wrong. Try again later."); } setIsLoading(false); }); }, [match.params.id, page]); // Handle page change function onChange(page) { setPage(page); } return ( <React.Fragment> {!isLoading && !errors ? <UserInfo user={user} /> : null} <PostListContainer posts={posts} isLoading={isLoading} errors={errors} /> <Pagination total={totalItems} pageSize={perPage} onChange={onChange} /> </React.Fragment> ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async function listPosts() {\n\t\tconst p = await API.graphql(graphqlOperation(ListPosts));\n\t\tupdatePosts(p.data.listPosts.items);\n\t}", "async function list(ctx, next) {\n ctx.body = await render('list', { posts: posts})\n}", "getPosts() {\r\n return this.posts;\r\n }", "function PostList({ posts, setPosts }) {\n // TODO: Diplay the list of posts.\n // TODO: Create at least one additional component that is used by this component.\n // TODO: Each post must have className=\"post\" for the tests to work.\n // TODO: Each post must have a delete button - <button name=\"delete\">Delete</button> - that deletes the post when clicked\n return (\n <div className=\"post-list\">\n {posts.map((post) => (\n <Post setPosts={setPosts} posts={posts} post={post} text={post} />\n ))}\n </div>\n );\n}", "all_posts(state){ \n return state.posts\n }", "function displayPosts() {\n var posts = JSON.parse(this.response);\n var postsContainer = $(\"#posts\");\n for (var i=0; i<posts.length; i++) {\n postsContainer.append(\"<li>\" + posts[i].body + \"</li>\")\n }\n }", "async function showPosts() {\n\tconst posts = await getPosts();\n\n\t// Get post one by one\n\tposts.forEach((post) => {\n\t\t// ! Create post container from api\n\t\tconst postEl = document.createElement('div');\n\t\tpostEl.classList.add('post');\n\t\tpostEl.innerHTML = `\n <div class=\"number\">${post.id}</div>\n <div class=\"post-info\">\n <h2 class=\"post-title\">${post.title}</h2>\n <p class=\"post-body\">${post.body}</p>\n </div>`;\n\n\t\t// ! Add the post data in to the post container\n\t\tpostContainer.appendChild(postEl);\n\t});\n}", "getAllPosts() {\n return this.http.get(\"http://localhost:8080/api/posts\");\n }", "renderPosts() {\n if ( this.props.posts.length > 0 ) {\n return this.props.posts.map( ( post ) => {\n return <div key={ post._id }>{post.title}</div>;\n });\n } else if (!this.props.posts) {\n return <div>No posts found.</div>;\n } else {\n return <div>Loading...</div>\n }\n }", "list(req, res, next) {\n PostModel.find((err, posts) => {\n res.render('posts', { posts });\n }); //end of PostModel.find\n }", "function getPosts() {\n $.get('/api/posts/', function (data) {\n var postsToAdd = [];\n for (var i = 0; i < data.length; i++) {\n\n newPost = data[i];\n\n postsToAdd.push(createPostDiv(newPost));\n renderPost(postsToAdd);\n }\n });\n }", "async function showPosts() {\n const posts = await getPosts();\n\n posts.forEach((post) => {\n const postEl = document.createElement(\"div\");\n postEl.classList.add(\"post\");\n postEl.innerHTML = `\n <div class=\"post-number\">${post.id}</div>\n <div class=\"post-info\">\n <h2 class=\"post-title\">${post.title}</h2>\n <div class=\"post-body\">${post.body}</div>\n </div>\n `;\n postsContainer.appendChild(postEl);\n // The Node.appendChild() method adds a node to the end of the list of children of a specified parent node.\n // The fetch() method takes one mandatory argument, the path to the resource you want to fetch.\n // It returns a Promise that resolves to the Response to that request, whether it is successful or not\n });\n}", "render() {\n\t\t//console.log(links);\n\t\treturn (\n\t\t\t<div className=\"Posts\" >\n\t\t\t\t{posts.map((post)=>{\n return <Post text={post.text} author={post.author}/>\n })}\n\t\t\t</div>\n\t\t);\n\t}", "renderList() {\n if (this.props.posts) {\n return this.props.posts.map(post => (\n <Card as={Link} to={`/posts/${post.id}`} fluid key={post.id}>\n <Card.Content header={post.title} />\n <Card.Content description={post.body} />\n <Card.Content extra>{post.id}</Card.Content>\n </Card>\n ));\n }\n return <Loader />;\n }", "function getAllPosts() {\n const endpoint = 'posts?query={}&sort={\"_kmd.ect\": -1}';\n\n return remote.get('appdata', endpoint, 'kinvey');\n }", "createListItems() {\n // map the property(Allposts array)\n return this.props.AllPosts.map((post) => {\n return (\n <li key={post.id}>Title: {post.title} <br></br> Body:{post.body}</li>\n )\n })\n }", "function PostsMain({ posts, ...rest }) {\n return (\n <div className=\"section\">\n <div className=\"PostMain row\">\n <div className=\"PostMain-left-column\">\n <div className=\"row center\">\n <Link to=\"/posts/add\" className=\"PostMain-btn btn-large waves-effect waves-light blue\" >\n Add New Post\n </Link>\n </div>\n <PostList className=\"PostList\" posts={posts} mode={COLLECTION} {...rest} render={\n (post, rest) => (<PostCollectionItem key={post.id} post={post} {...rest} />)\n } />\n </div>\n <div className=\"PostMain-right-column\">\n <Outlet />\n </div>\n </div>\n </div>\n );\n}", "renderList() {\n return this.props.posts.map((post) => { // return a JSX full result\n return( // returns one piece of JSX for each iteration\n <div className=\"item\" key={post.id}>\n <i className=\"large middle aligned icon user\"></i>\n <div className=\"content\">\n <div className=\"description\">\n <h2>{post.title}</h2>\n <p>{post.body}</p>\n </div>\n </div>\n </div>\n );\n });\n }", "get posts() {\r\n return new Posts(this);\r\n }", "function renderPosts(event) {\n event.preventDefault();\n let postList = localStorage.getItem(\"postList\");\n postList = JSON.parse(postList);\n\n if (postList != null) {\n for (post in postList) {\n makePost(postList[post]);\n }\n }\n}", "getPosts( state ){\n return state.post\n }", "renderPosts(){\n return this.props.posts.map((post) => {\n //for each post in post's arr we return li\n return (\n // back end generates id\n <li className='list-group-item' key={post.id}>\n <Link to={'posts/' + post.id}>\n <span className='pull-xs-right'>{post.categories}</span>\n <strong> {post.title}</strong>\n </Link>\n </li>\n )\n })\n }", "getAllPost() {\n return service\n .get('/posts/')\n .then((res) => res.data)\n .catch(errorHandler);\n }", "function getPosts() {\n Post\n // remote method that returns `posts` array with username\n .findAll()\n .$promise\n .then(function(results) {\n vm.posts = results.posts;\n });\n }", "displayPosts() {\n const { data } = this.props;\n\n return data.posts.map(post => {\n return (\n <ListGroupItem key={post.id} value={post.id}>\n <Media>\n <Media heading>\n {/* Pass ID through here, make call */}\n <Link\n to={{\n pathname: `/post/${post.id}`,\n state: { id: post.id }\n }}\n style={{ textDecoration: 'none', color: 'black' }}\n >\n {post.heading}\n </Link>\n </Media>\n </Media>\n <PostFooter\n id={post.id}\n heading={post.heading}\n text={post.text}\n upvotes={post.upvotes}\n mainPage={true}\n />\n </ListGroupItem>\n );\n });\n }", "componentWillMount() {\n this.getPosts();\n }", "async index({ view }) {\n // const posts = [\n // {title:'Post One', body:'This is post one'},\n // {title:'Post Two', body:'This is post two'},\n // {title:'Post Three', body:'This is post three'},\n // ]\n\n // The posts object is an instance of Vanilla serializer\n const posts = await Post.all();\n // render index page under posts & pass the data title over to the frontend\n return view.render('posts.index', {\n title: 'Latest Posts',\n posts: posts.toJSON(),\n })\n }", "generatePosts(){\n const feedPosts = [];\n\n for(var i = 0; i < this.state.posts.length; i++) {\n feedPosts.push(\n <Post userName={this.state.posts[i].userName} postText={this.state.posts[i].postText} />\n );\n }\n\n return(\n feedPosts\n );\n }", "getAllPosts() {\n return this.storyapi\n .get('cdn/stories', {\n starts_with: 'posts/',\n version,\n })\n .catch((error) => console.log(error));\n }", "static displayEntries() {\n let posts = Store.getEntries();\n\n posts.forEach((entry) => UI.addEntryToList(entry));\n\n }", "render() {\n\t\treturn(\n\t\t\t<div> \n\t\t\t\t<div className=\"text-xs-right\">\n\t\t\t\t\t<Link to=\"/posts/new\" className=\"btn btn-primary\" > \n\t\t\t\t\t\tAdd a Post\n\t\t\t\t\t</Link>\n\t\t\t\t</div>\t\n\t\t\t\tList of Blog Posts\n\t\t\t\t<h3>Posts</h3>\n\t\t\t\t<ul className=\"list-group\">\n\t\t\t\t\t{this.renderPosts()}\n\t\t\t\t</ul>\n\t\t\t </div>\n\t\t);\n\t}", "function PostListCtrl(Post) {\n this.posts = Post.query();\n }", "async routes () {\n let { data } = await axios.post(process.env.POSTS_URL,\n JSON.stringify({\n filter: { published: true },\n sort: {_created:-1},\n populate: 1\n }),\n {\n headers: { 'Content-Type': 'application/json' }\n })\n\n const collection = collect(data.entries)\n\n let tags = collection.map(post => post.tags)\n .flatten()\n .unique()\n .map(tag => `category/${tag}`)\n .all()\n\n let posts = collection.map(post => post.title_slug).all()\n\n if(perPage < data.total) {\n let pages = collection\n .take(perPage-data.total)\n .chunk(perPage)\n .map((items, key) => `blog/${key+2}`)\n .all()\n\n return posts.concat(tags,pages)\n }\n\n return posts.concat(tags)\n }", "getAllPosts(state){\n return state.loadData\n }", "function loadPosts() {\n // Note: \"posts\" is the [API] -> [endpoint] -> [name] in src -> index.js\n return API.get(\"posts\", `/searching/all/${name}`);\n }", "getPost() {\n\t\t// fetch all posts from the server\n\t\tfetch(postURL)\n\t\t\t.then(response => response.json())\n\t\t\t// put them into this.posts and store them there\n\t\t\t.then(data => {\n\t\t\t\tthis.posts = data;\n\t\t\t\treturn data;\n\t\t\t})\n\t\t\t// Use .showPost() to display posts\n\t\t\t.then(data => this.showPost(data));\n\t}", "function Home() {\n const { loading, data: { getPosts: posts } = [] } = useQuery(\n FETCH_POSTS_QUERY\n );\n\n return (\n <WithLoading loading={loading}>\n <List\n itemLayout=\"horizontal\"\n dataSource={posts}\n renderItem={(post) => (\n <List.Item>\n <UpvoteButton post={post} />\n <List.Item.Meta\n title={\n <Tooltip title={post.url}>\n <a href={post.url} target=\"_blank\" rel=\"noopener noreferrer\">\n {post.title}\n </a>\n </Tooltip>\n }\n description={`${post.username} • ${getTopDomain(\n post.url\n )} • ${moment(post.createdAt).fromNow(true)} ago`}\n />\n <CommentButton post={post} />\n </List.Item>\n )}\n />\n </WithLoading>\n );\n}", "function renderPosts() {\n // assign posts object to a variable\n var posts = memory.posts;\n // loop through posts object\n for (var i = 0; i < posts.length; i++) {\n // call render method\n memory.posts[i].render();\n };\n }", "function getAllPostIts() {\n\t\tpostItService.getAll().then(function(result) {\n\t\t\t$scope.postIts = result;\n\t\t}, function (error) {\n\t\t\talert(error);\n\t\t});\n\t}", "function loadPosts() {\n return API.get(\"posts\", \"/publicposts\");\n }", "loadPosts() {\n if (this.props.thread.posts) {\n return (\n Object.keys(this.props.thread.posts).map(key =>\n <Post\n key={key}\n arraykey={key}\n post={this.props.thread.posts[key]}\n username={this.props.username}\n userid={this.props.userid}\n opname={this.props.thread.postername}\n opid={this.props.thread.posterid}\n updatePost={this.updatePost}\n deletePost={this.deletePost}\n />\n ))\n }\n }", "function getPosts() {\n\tvar snippet = {\n\t\tquery : {},\n\t\tfields: \"title,category,thumbnail\"\n\t}\n\t// for unpublished\n\t// snippet.query = {published: false, nextKey: '-K_W8zLX65ktmaKwf1Yx'}\n\n\trimer.post.find(snippet, function(error, value) {\n\t\tif(error) {\n\t\t\tconsole.log(error)\n\t\t}\n\t\telse {\n\t\t\tconsole.log(value)\n\t\t}\n\t})\n}", "function allPost(req,res){\n //get all posts from database\n Post.find({},(err,posts)=>{\n if(err){\n res.status(404);\n res.send('Post Not Found !');\n }\n\n //return a view with post data\n res.render('./partials/postlst',{\n posts:posts,\n layout:'./layouts/layout'\n });\n });\n}", "allposts( state, data ){\n return state.post = data\n }", "render() {\n return (\n <div>\n <h1>Posts</h1>\n {\n this.state.posts.map(post =>{\n return <div key={post.id}>\n <h1>{post.title} </h1>\n <p>{post.body} </p>\n </div>\n })\n }\n </div>\n )\n }", "async getPosts() {\n this.loading = false;\n const posts = [];\n const counter = await contract.methods.getCounter().call({\n from: this.currentAccount,\n });\n\n if (counter !== null) {\n const hashes = [];\n const captions = [];\n for (let i = counter; i >= 1; i -= 1) {\n hashes.push(contract.methods.getHash(i).call({\n from: this.currentAccount,\n }));\n }\n\n const postHashes = await Promise.all(hashes);\n\n for (let i = 0; i < postHashes.length; i += 1) {\n captions.push(fetch(`https://gateway.ipfs.io/ipfs/${postHashes[i].text}`)\n .then(res => res.text()));\n }\n\n const postCaptions = await Promise.all(captions);\n\n for (let i = 0; i < postHashes.length; i += 1) {\n posts.push({\n id: i,\n key: `key${i}`,\n caption: postCaptions[i],\n src: `https://gateway.ipfs.io/ipfs/${postHashes[i].img}`,\n });\n }\n\n this.currentPosts = posts;\n this.loading = false;\n }\n }", "render() {\n return (\n <div>\n <div className=\"text-xs-right\">\n <Link className=\"btn btn-primary\" to=\"/posts/new\">\n Add a Post\n </Link>\n </div>\n <h3>Posts</h3>\n <ul className=\"list-group\">\n {this.renderPosts()}\n </ul>\n </div>\n );\n }", "constructor(props) {\n super(props);\n this.state = {\n posts: []\n }\n }", "function displayPostsDOM(posts) {\n posts.forEach((post) => {\n appendPostDOM(post);\n });\n}", "async function showPosts() {\n const posts = await getPosts();\n\n //console.log(posts);\n\n postContainer.innerHTML += posts\n .map(\n (post) => `\n <div class=\"post\">\n <div class=\"number\">${post[\"id\"]}</div>\n <div class=\"post-info\">\n <h2 class=\"post-title\">${post[\"title\"]}</h2>\n <p class=\"post-body\">\n ${post[\"body\"]}\n </p>\n </div>\n </div>`\n )\n .join(\"\");\n}", "ngOnInit() {\n this.postService.getAllPosts().subscribe(p => {\n this.allPosts = p;\n this.filterPosts();\n });\n }", "function index(req, res) {\n Post.find({})\n .then((Posts) => {\n res.render(\"posts/index\", {\n user: req.user,\n title: \"Message Board\",\n posts: Posts.reverse()\n })\n })\n }", "function allPostsView(targetname){\n\n let posts = Model.getPosts();\n let count = 0;\n\n for (let i =0; i<posts.length;i++){\n\n count++\n\n }\n\n let target = document.getElementById(targetname);\n let template = Handlebars.compile(\n document.getElementById(\"display-list-template\").textContent\n ) \n target.innerHTML = template({'display': Model.getRecentPosts(count)})\n\n}", "render() {\n const username = this.props.username;\n const response = this.state.response;\n const onePost = this.state.onePost;\n var array = [];\n if (onePost){\n array.push(response.posts[Object.keys(response.posts)[0]]);\n }\n const posts = onePost ? array : response.posts;\n return (\n <div className=\"sportsContainer tabContiner\">\n <div className = \"refresh-container\" style = {{overflow: 'hidden', whitespace: 'overflow'}}>\n <Button onClick={this.refresh}>Refresh</Button>\n </div>\n <ListGroup>\n {\n posts && posts.map(data =>\n <ListGroupItem>\n <PostItem currentUser={username} username={data.post_user} title={data.post_title} description={data.post_content} id={data.post_id} commentObj={data.post_comments}/>\n </ListGroupItem>\n )\n }\n </ListGroup>\n </div>\n\n );\n }", "static getAllPosts() {\n return fetch('https://dev-selfiegram.consumertrack.com/users/1/feed').then(response => {\n return response.json();\n }).catch(error => {\n return error;\n });\n }", "async getPosts(){\n const postData = await this.getPostData()\n\n return postData\n }", "async getPosts (params) {\n const endpoint = this.addParamsToEndPoint('posts', params)\n\n const { posts } = await this.get(endpoint)\n return posts\n }", "function sendPostsList(request, response) {\n response.send(posts);\n}", "function uiGetPosts () {\r\n getAllPosts().then((data)=>{\r\n console.log(data)\r\n const display = document.querySelector('div.response')\r\n display.innerHTML = JSON.stringify(data, null, 2)\r\n })\r\n}", "static async list(token) {\n return await sendRequest(\"GET\", \"/posts\", token);\n }", "function posts(arr) {\n let postApi = arr.filter((el) => el.userId == id);\n postApi.forEach(element => {\n fragmentPost.appendChild(renderPosts(element));\n });\n elPostListWrapper.appendChild(fragmentPost)\n }", "render() {\n\t return (\n\t \t<div className=\"content-container\">\n\t \t{\n\t \t this.state.posts.map ((item, value) => (\n\t \t \t<PostItem key={item.contentId} contentType={item.contentType} \n\t \t \timgUrls={item.thumbnails[1].url} headline={item.metadata.headline}/>\n\t \t ))\n\t \t}\t \n\t </div>\n\t );\n\t}", "renderpost(){\n {return this.state.posts.map(post=> <div key={post.id} className=\"media\">\n <div className=\"media-left\">\n \n </div>\n <div className=\"media-body\">\n <a href={`/users/${post.user.username}`}><b>{post.user.username}</b></a>{' '}\n - {post.created_at}\n \n\n <p> {post.body}</p>\n </div>\n </div>)}\n }", "fetchAll(params) {\n return api.get('posts', params).then(response => ({\n posts: _.map(_.filter(response.data, filterPosts), post => new Post(post)),\n paging: response.paging\n }));\n }", "constructor(props) {\n super(props);\n this.state = {\n posts: []\n };\n }", "function load_posts() {\n document.querySelector('#form-view').style.display = 'block';\n document.querySelector('#post-list').style.display = 'block';\n document.querySelector('#post-list').innerHTML = '';\n document.querySelector('#profile-view').style.display = 'none'; \n document.querySelector('#profile-view').innerHTML = ''; \n\n fetch('/show')\n .then(response => response.json())\n .then(posts => {\n paginate_posts(posts);\n });\n}", "function getPosts() {\n return [{\n id: 'hello-nextjs',\n title: 'Hello Next.js'\n }, {\n id: 'learn-nextjs',\n title: 'Learn Next.js is awesome'\n }, {\n id: 'deploy-nextjs',\n title: 'Deploy apps with ZEIT'\n }];\n}", "function Blog({ posts }) {\n return (\n <>\n <h1>This is a blog with content from an API</h1>\n <ul>\n {posts.map((post) => (\n <li key={post.id}>{post.title}</li>\n ))}\n </ul>\n </>\n )\n}", "componentDidMount() {\n this.props.getPosts();\n }", "allPosts() {\n console.log('New posts have arrived.');\n // console.log('allPosts was modified, updating feed!');\n if (!this.allPosts) {\n return;\n }\n this.redrawFeed();\n }", "posts(user) {\n return user.getPosts();\n }", "function renderPosts(data) {\r\n postLists.innerHTML = null;\r\n const nameBox = document.createElement(\"h3\");\r\n nameBox.textContent = \"POSTS\";\r\n postLists.appendChild(nameBox);\r\n\r\n data.forEach((element) => {\r\n const newUserPost = userPostTemp.cloneNode(true);\r\n const postTitle = newUserPost.querySelector(\".post-title\");\r\n postTitle.textContent = element.title;\r\n postTitle.dataset.post_id = element.id;\r\n newUserPost.querySelector(\".body\").textContent = element.body;\r\n postLists.appendChild(newUserPost);\r\n });\r\n}", "function loadPosts() {\n const postsCollection = firebase.firestore().collection(\"postagens\");\n container.querySelector(\"#lista-feed\").innerHTML = \"Carregando...\";\n postsCollection.get().then((querySnapshot) => {\n container.querySelector(\"#lista-feed\").innerHTML = \"\";\n querySnapshot.forEach((doc) => {\n const post = { id: doc.id, data: doc.data() };\n const componente = postTemplate(post);\n console.log(componente)\n container.querySelector(\"#lista-feed\").appendChild(componente);\n });\n });\n }", "render() {\n return (\n <section id=\"post-list\">\n { \n this.state.feed.map(post => (\n // Setar uma key com um ID unico faz o react conseguir achar os \n // elementos mais rapidamente na DOM e ter uma performance melhor\n <article key={post._id}>\n <header>\n <div className=\"user-info\">\n <span>{post.author}</span>\n <span className=\"place\">{post.place}</span>\n </div>\n \n <img src={more} alt=\"Mais\"></img>\n </header>\n \n <img src={`http://localhost:3333/files/${post.image}`} alt=\"\"></img>\n \n <footer>\n <div className=\"actions\">\n <button type=\"button\" onClick={() => this.handleLike(post._id)}>\n <img src={like} alt=\"\"/>\n </button> \n <img src={comment} alt=\"\"/>\n <img src={send} alt=\"\"/>\n </div>\n \n <strong>{post.likes} curtidas</strong>\n \n <p>\n {post.description}\n <span>{post.hashtags}</span>\n </p> \n </footer>\n </article> \n ))\n } \n </section>\n );\n }", "componentDidMount() {\n this.retrievePosts();\n }", "componentDidMount() {\n this.loadPosts();\n }", "function displayPosts(posts) {\r\n\t// use helper function displayPost\r\n\r\n}", "async index( req, res ){\n const posts = await Post.find().sort('-createdAt')\n res.json( posts )\n }", "renderPosts(posts) {\n //When iterating over post we can get an index value\n //which we can use as <li key={index}>\n return posts.map((post, index) => {\n return (\n <li key={index}>\n {/* passing data via a query string parameter (a query param). \n In our case, it's the title query param. \n <Link as={`/portfolioDetails/${post.id}`} href={`/portfolioDetails?id=${post.id}`}>*/}\n <Link as={`/portfolioDetails/${post.id}`} href=\"/portfolioDetails/[id]\">\n <a style={{'fontSize': '20px'}}>{post.title}</a>\n </Link>\n </li>\n )\n })\n }", "bindResources(props) {\n const page = props.params.page ? Number.parseInt(props.params.page) : 1\n this.setState({ page });\n const query = {\n filter: {\n limit: this.state.perPage,\n skip: this.state.perPage * (page - 1),\n include: ['roles']\n }\n }\n // # retrieve all the posts from the Post Store\n this.retrieveAll(this.store, { query });\n }", "function loadPosts() {// 02\n $.get({ // send get to take all posts\n url: apiBaseUrl + 'posts',\n headers: authorizationHeader\n })\n .then(fillDropDownMenu)\n .catch(renderError);\n }", "async getPosts() {\n try {\n const posts = await Post.find().sort({ createdAt: -1 });\n return posts;\n } catch (err) {\n console.log(` An error as occurred while fetching the posts ${JSON.stringify(err)} `);\n throw new Error(err);\n }\n }", "function getAllPosts() {\n fetch(\"https://bloguefp.herokuapp.com/\")\n .then((r) => r.json())\n .then(appendPosts)\n .catch(console.warn);\n}", "async getReplies () {\n\t\tconst postId = this.codeError.get('postId');\n\t\tif (!postId) {\n\t\t\t\tthrow this.errorHandler.error('notFound', { info: 'postId' });\n\t\t}\n\n\t\t// TODO this should be paginated\n\t\tconst posts = await this.data.posts.getByQuery(\n\t\t\t\t{\n\t\t\t\t\t\tteamId: this.codeError.get('teamId'),\n\t\t\t\t\t\tstreamId: this.codeError.get('streamId'),\n\t\t\t\t\t\tparentPostId: postId\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\t\thint: PostIndexes.byParentPostId\n\t\t\t\t}\n\t\t);\n\n\t\t// also get posts that are replies to these posts\n\t\tconst postIds = posts.map(post => post.id);\n\t\tconst replies = await this.data.posts.getByQuery(\n\t\t\t\t{\n\t\t\t\t\t\tteamId: this.codeError.get('teamId'),\n\t\t\t\t\t\tstreamId: this.codeError.get('streamId'),\n\t\t\t\t\t\tparentPostId: this.data.posts.inQuery(postIds)\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\t\thint: PostIndexes.byParentPostId\n\t\t\t\t}\n\t\t);\n\n\t\tthis.posts = [\n\t\t\t\t...posts,\n\t\t\t\t...replies\n\t\t].sort((a, b) => {\n\t\t\t\treturn b.get('seqNum') - a.get('seqNum');\n\t\t});\n\t}", "static async getAll() {\n let page = 1;\n let shouldQueryMorePosts = true;\n const returnPosts = [];\n\n while (shouldQueryMorePosts) {\n const response = await this.getPaginated(page);\n\n if (response.posts.length > 0) {\n returnPosts.push(...response.posts);\n }\n\n shouldQueryMorePosts = returnPosts.length < response.total;\n page++;\n }\n\n return returnPosts;\n }", "function Feed({posts}) {\n\n return (\n <div>\n <ul>\n {images.map((image) => {\n return (\n <PhotoPost \n key={image.id}/>\n )\n })}\n </ul>\n <Toggles />\n </div>\n )\n // return (\n // <div>\n // <h3>photos will show up here </h3>\n // <PhotoPost images={images} />\n // <Toggles />\n // </div>\n // );\n}", "function get_posts(){\r\n\treturn app.getHits('Post', {published:true}, {sort:{'date':'desc'}});\r\n}", "async getAll(query = {}) {\n // NOTE convertToQuery will take an object and turn it into a queryString\n const res = await api.get('api/posts' + convertToQuery(query))\n logger.log(res.data)\n AppState.posts = res.data\n // logger.log('This is the post material', AppState.posts)\n // NOTE goes through the entire function but will not post to page. Function is good.\n }", "static get all() {\n return new Promise(async (resolve, reject) => {\n try {\n const postsData = await db.query(`SELECT * FROM thoughts;`)\n const posts = postsData.rows.map(p => new Post(p))\n resolve(posts);\n } catch (err) {\n reject(\"Sorry No Posts Found\")\n }\n })\n }", "function allPosts(req, res) {\n request(\n 'https://jsonplaceholder.typicode.com/posts',\n function(err, response, posts) {\n res.render('posts', {posts: JSON.parse(posts)})\n }\n )\n}", "getPosts() {\n let communicationController = new CommunicationController()\n let response = function (result) {\n // Rimozione dei post precedenti sia dal model che dall'html\n Model.getInstance().clearPosts()\n\n this._imagePosts = new Array()\n let posts = result.posts.reverse()\n for (let i = 0; i < posts.length; i++) {\n\n Model.getInstance().addPost(posts[i]);\n if (Model.getInstance().actualUser.uid == posts[i].uid) {\n this.myPostHTML(posts[i]);\n } else {\n this.othersPostHTML(posts[i]);\n }\n }\n this.fullScreenImage()\n this.openProfilePicturesDataBase()\n this.openImagesDataBase()\n\n // Apertura mappa per i post di tipo posizione\n $(\".locationButton\").click(function () {\n console.log(\"click\");\n let postIndex = $(\".post\").index($(this).parent());\n let map = new Map();\n map.setPostLocation(result.posts[postIndex].lat, result.posts[postIndex].lon);\n });\n }\n communicationController.getChannel(ctitle, response.bind(this));\n }", "function getPosts(author) {\n authorId = author || \"\";\n if (authorId) {\n authorId = \"/?author_id=\" + authorId;\n }\n $.get(\"/api/posts\" + authorId, function(data) {\n console.log(\"Posts\", data);\n posts = data;\n if (!posts || !posts.length) {\n displayEmpty(author);\n }\n else {\n initializeRows();\n }\n });\n }", "function renderBlogposts() {\n\n let $sideBlogList = $(`\n <div class=\"side-blog-list\">\n <ul>\n </ul>\n </div>\n `);\n\n function addBlogToList(model) {\n let $liContainer = $(`\n <li>\n <h2>${model.get('username')}</h4>\n <h3>${model.get('title')}</h3>\n <p>${model.get('body')}</p>\n </li>\n `);\n $sideBlogList.find('ul').append($liContainer);\n }\n\n\n blogCollection.forEach(addBlogToList);\n blogCollection.on('add', addBlogToList);\n blogCollection.fetch();\n\n let $sideBlog = $(`\n <ul id=\"single-blog\">\n <li>\n\n <li>\n </ul>\n `);\n\n\n\n\n return $sideBlogList;\n}", "async userIndex({view, auth}) {\n const posts = await auth.user.posts().fetch();\n\n return view.render('posts', { posts: posts.toJSON() });\n }", "function Posts(props) {\n const [posts, setPosts] = useState([]);\n\n useEffect(() => {\n async function getPosts() {\n const response = await fetch(\n \"https://strangers-things.herokuapp.com/api/2109-LSU-RM-WEB-FT/posts\"\n );\n\n const responseObj = await response.json();\n\n setPosts(responseObj.data.posts);\n }\n console.log(posts);\n getPosts();\n }, [posts]);\n\n const postsToRender = posts.map((post) => {\n return <SinglePost post={post} />;\n });\n\n return (\n <div>\n <h1>Posts:</h1>\n {postsToRender}\n </div>\n );\n}", "render() {\n\t\t//5. Loop over all of the to do list items now living in state from firebase!\n\t\tlet blogPosts = this.state.blogPosts.map((item, index)=>{\n\t\t\treturn (\n\t\t\t\t<div>\n\t\t\t\t\t<li className=\"list-group-item title\">{item.title}</li>\n\t\t\t\t\t<img className=\"blogImage m-3\" src={item.image}/>\n\t\t\t\t\t<div className=\"blogText\">\n\t\t\t\t\t\t<p className=\" body\">{item.body}</p>\n\t\t\t\t\t</div>\n\t\t\t\t\t<button className=\"btn btn-danger mb-3\" onClick={this.handleDelete}>Delete</button>\n\t\t\t\t</div>\n\t\t\t)\n\n\t\t});\n\n\n\t\treturn (\n\t\t\t<div className=\"container\">\n\t\t\t\t<div className=\"row justify-content-center\">\n\t\t\t\t\t<div className=\"col-10\">\n\t\t\t\t\t\t<h1 className=\"bg-light m-3 p-3\">Blog</h1>\n\t\t\t\t\t</div>\n\t\t\t\t\t<div className=\"row\">\n\t\t\t\t\t\t<div className=\"col-3\">\n\t\t\t\t\t\t\t<input className=\"m-3\" onChange={this.titleChange} placeholder=\"Enter title here\"/>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t\t<div className=\"col-3\">\n\t\t\t\t\t\t\t<input className=\"m-3\" onChange={this.imageChange} placeholder=\"Enter Image Address\"/>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t\t<div className=\"col-5\">\n\t\t\t\t\t\t\t<button className=\"btn btn-primary m-2\" onClick={this.handleClick}>Submit</button>\n\t\t\t\t\t\t\t<button className=\"btn btn-danger m-2\" onClick={this.deleteAll}>Delete All Posts</button>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t\t<div className=\"row\">\n\t\t\t\t\t\t<div className=\"col-10\">\n\t\t\t\t\t\t\t<textarea className=\"bodyText\" type=\"textarea\" placeholder=\"Enter Blog Post Here...\" onChange={this.handleChange}/>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\n\n\n\t\t\t\t\t</div>\n\n\t\t\t\t\t<div className=\"col-12\">\n\t\t\t\t\t\t<h1 className=\"bg-light m-3 p-3\">Previous Posts</h1>\n\t\t\t\t\t\t\t{blogPosts}\n\t\t\t\t\t</div>\n\t\t\t</div>\n\n\t\t);\n\t}", "function postListController(RecipeFactory){\n const vm=this\n vm.post = [{\n title: \"Cats, and they're pissed\",\n description: \"Not really sure why these cats are so pissed, but they're pissed. Nothing can really be known about why they are pissed because they dont speak, they meow. No one has understood the meow explicitly... but tone goes a long way, and they're pissed.\",\n author: \"Tom Swagger\",\n votes: 6,\n imageURL: \"http://dailypicksandflicks.com/wp-content/uploads/2011/01/angry-wet-cat.jpg\",\n createdAt: '2015-05-02',\n comments : [\n {content: \"this is a shitty book\"}\n ]\n },\n {\n title: \"A book of names, for Hamsters\",\n description: \"Hamsters can have names, but a name shapes a hamster... this book will help you choose wisely. Shape your hamster into your best friend starting with a name. It's all in a name\",\n author: \"Theo Thunderbutt\",\n votes: 1,\n imageURL: \"https://s-media-cache-ak0.pinimg.com/736x/d5/db/06/d5db068c895eab1df0091510ee242c61--hamster-stuff-baby-hamster.jpg\",\n createdAt: '2006-09-22',\n comments : [\n {content: \"this is a great book.\"},\n {content: \"well, your an idiot.\"},\n {content: \"no YOU'RE an idiot... fuckturd.\"}\n ]\n },\n {\n title: \"Sex with my neighbor\",\n description: \"too good to be ok, I should not do it...\",\n author: \"Anonymous\",\n votes: 4,\n imageURL: \"https://images-na.ssl-images-amazon.com/images/I/81XIpcZfo-L._SL1500_.jpg\",\n createdAt: '2016-09-22',\n comments : [\n {content: \"this is not a book\"},\n {content: \"thi is practically a porno! my kids are ruined.\"},\n {content: \"you're a porno, and your kids were already ruined\"}\n ]\n }]\n }", "async fetchPage() {\n this.listPair = await this.readListPair();\n const { crowdtangle_saved_searches: savedSearches } = this.listPair;\n\n const savedSearchIds = Object.keys(savedSearches).join(\",\");\n\n if (this.savedSearchToggle) {\n this.queryParams = {\n ...this.queryParams,\n listIds: savedSearchIds, // Saved Searches\n };\n } else {\n this.queryParams = {\n ...this.queryParams,\n listIds: undefined, // Lists\n };\n }\n\n const posts = await super.fetchPage();\n posts.forEach((post) => this.addCrowdTangleTags(post));\n\n this.savedSearchToggle = !this.savedSearchToggle;\n\n return posts;\n }", "function Home(){\n // to store the articles\n const [articles , setArticles] = useState([]);\n\n useEffect(() => {\n const requestOptions = {\n method: 'GET',\n headers: { 'Content-Type': 'application/json' },\n };\n //get request to fetch all the posts and store it\n fetch('https://jsonplaceholder.typicode.com/posts', requestOptions)\n .then(response => response.json())\n .then(data => setArticles(data));\n }, []);\n\n //mapping through the entire lists and renderering a card fo revery post\n const posts=articles.map((currPost)=>\n <div key={currPost.id}>\n <Homecard article={currPost}/>\n </div>\n )\n return (\n <div>\n <Heading>\n Articles\n </Heading>\n <ArticleWrapper>\n {posts}\n </ArticleWrapper>\n </div>\n \n )\n}", "componentWillMount() {\n this.props.fetchPosts();\n }", "function getPosts() {\n setTimeout(() => {\n let output = \"\";\n posts.forEach((e, i) => {\n output += `<li>${e.title}</li>`;\n });\n document.body.innerHTML = output;\n }, 1000);\n}" ]
[ "0.7404693", "0.7352751", "0.7247325", "0.7133187", "0.7089901", "0.70602983", "0.7026492", "0.70116025", "0.69791776", "0.69705784", "0.6962189", "0.6948067", "0.6934963", "0.6923527", "0.69020087", "0.6892614", "0.68825185", "0.6866711", "0.6862716", "0.68602693", "0.6857877", "0.68509626", "0.68387324", "0.6836445", "0.68260235", "0.6821881", "0.6790404", "0.67685235", "0.6760753", "0.675348", "0.674205", "0.67106164", "0.6698968", "0.6694361", "0.6694026", "0.6678343", "0.6659325", "0.66497314", "0.65927815", "0.65885216", "0.65669703", "0.65432954", "0.653647", "0.6524485", "0.65167993", "0.65113926", "0.65053815", "0.64972275", "0.6485634", "0.648306", "0.64818203", "0.6480651", "0.64738816", "0.64636207", "0.6450268", "0.6444541", "0.64388", "0.64378166", "0.6429583", "0.64144653", "0.6410193", "0.64030933", "0.6400411", "0.63996273", "0.63902044", "0.6365866", "0.6362136", "0.6356068", "0.635467", "0.6351133", "0.634813", "0.63478774", "0.63470334", "0.6346459", "0.6328545", "0.6302595", "0.63025457", "0.62979406", "0.6283722", "0.6281088", "0.628076", "0.6278882", "0.62757117", "0.62724847", "0.6270682", "0.6256937", "0.6254665", "0.6244351", "0.62282085", "0.6224832", "0.6217947", "0.62163484", "0.62140256", "0.6206105", "0.6201837", "0.62005913", "0.61988837", "0.6198064", "0.6196904", "0.6194595", "0.6188534" ]
0.0
-1
get parameters from the URL which was navigated to from autogenerated email
function getParameterByName(name, url) { if (!url) url = window.location.href; name = name.replace(/[\[\]]/g, "\\$&"); var regex = new RegExp("[?&]" + name + "(=([^&#]*)|&|#|$)"), results = regex.exec(url); if (!results) return null; if (!results[2]) return ''; return decodeURIComponent(results[2].replace(/\+/g, " ")); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getUrlParams() {\n\n //var my_url_var = window.location.href;\n let my_url_var = (window.location != window.parent.location) ?\n document.referrer :\n document.location.href;\n\n let params_list = my_url_var.split(\"?\");\n\n let final = {};\n\n if (params_list.length > 1) {\n\n let params_parsed = params_list[1].split(\"&\");\n\n for (let i = 0; i < params_parsed.length; i++) {\n let p_couple = params_parsed[i].split(\"=\");\n final[p_couple[0]] = p_couple[1];\n }\n }\n\n return final;\n }", "function grabLinkParams() {\n var url = new URL(window.location.href);\n var fulfillRequestTo = url.searchParams.get(\"fulfillRequestTo\");\n $(\"#destinationWalletOrEmail\").val(fulfillRequestTo);\n var fulfillRequestAmount = url.searchParams.get(\"fulfillRequestAmount\");\n $(\"#transactionAmount\").val(fulfillRequestAmount);\n }", "function getURLParameters() {\n 'use strict';\n if (debugMode) {\n console.groupCollapsed(\"URL parameters\");\n }\n\n var parametersArray = {};\n\n // A bit hackish.\n if (location.href.indexOf(\"#\") > -1) {\n location.assign(location.href.replace(/\\/?#\\//, \"/\"));\n }\n\n location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function (m, key, value) {\n var setting = value.split(\"#\")[0]; // Hack\n parametersArray[key] = setting;\n });\n\n var parameters = JSON.stringify(parametersArray);\n GM_setValue(\"current_parameters\", parameters);\n\n if (debugMode) {\n console.dir(parametersArray);\n console.groupEnd(\"URL parameters\");\n }\n}", "function getURLArgs() {\n var query_string = {};\n let query = window.location.search.substring(1);\n let vars = query.split(\"&\");\n \n for (let i=0;i<vars.length;i++) {\n let pair = vars[i].split(\"=\");\n //if is the first entry with that name\n if (typeof query_string[pair[0]] === \"undefined\") {\n query_string[pair[0]] = decodeURIComponent(pair[1]);\n //if is the second entry with that name\n } else if (typeof query_string[pair[0]] === \"string\") {\n let arr = [ query_string[pair[0]],decodeURIComponent(pair[1]) ];\n query_string[pair[0]] = arr;\n //if is the third or more entry with that name\n } else {\n query_string[pair[0]].push(decodeURIComponent(pair[1]));\n }\n } \n return query_string;\n }", "function getUrlParams() {\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for (var i = 0; i < hashes.length; i++) {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n }", "function getUrlParameters() {\n\tvar vars = [], hash;\n\tvar hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n\tfor (var i = 0; i < hashes.length; i++) {\n\t\thash = hashes[i].split('=');\n\t\tvars.push(hash[0]);\n\t\tvars[hash[0]] = hash[1];\n\t}\n\treturn vars;\n}", "function getEmailAgent(params){\n\n}", "function getParameters() {\n\t\t\t var searchString = window.location.search.substring(1)\n\t\t\t\t, params = searchString.split(\"&\")\n\t\t\t\t, hash = {}\n\t\t\t\t;\n\n\t\t\t for (var i = 0; i < params.length; i++) {\n\t\t\t\tvar val = params[i].split(\"=\");\n\t\t\t\thash[unescape(val[0])] = unescape(val[1]);\n\t\t\t }\n\t\t\t return hash;\n\t\t\t}", "function get_url_params() {\n var $_GET = {};\n\n document.location.search.replace(/\\??(?:([^=]+)=([^&]*)&?)/g, function () {\n function decode(s) {\n return decodeURIComponent(s.split(\"+\").join(\" \"));\n }\n\n $_GET[decode(arguments[1])] = decode(arguments[2]);\n });\n return $_GET;\n}", "function getParametersFromUrl() {\n let queryDict = {}\n location.search.substr(1).split(\"&\").forEach(function(item) {queryDict[item.split(\"=\")[0]] = item.split(\"=\")[1]})\n return queryDict\n}", "function xGetURLArguments()\r\n{\r\n var idx = location.href.indexOf('?');\r\n var params = new Array();\r\n if (idx != -1) {\r\n var pairs = location.href.substring(idx+1, location.href.length).split('&');\r\n for (var i=0; i<pairs.length; i++) {\r\n nameVal = pairs[i].split('=');\r\n params[i] = nameVal[1];\r\n params[nameVal[0]] = nameVal[1];\r\n }\r\n }\r\n return params;\r\n}", "function getURLParameters () {\n let paramstrings = window.location.search.substr(1).split('&');\n\n if (paramstrings == '') {\n return {};\n }\n\n let params = {};\n\n for (let i = 0; i < paramstrings.length; ++i) {\n let param = paramstrings[i].split('=', 2);\n if (param.length == 1)\n params[param[0]] = '';\n else\n params[param[0]] = decodeURIComponent(param[1].replace(/\\+/g, ' '));\n }\n\n return params;\n}", "function captureParameters() {\n\tvar vr = 'ip'; /* parámetro que se necesita */\n\tvar src = String(window.location.href).split('?')[1];\n\tvar vrs = src.split('&');\n\tfor (var x = 0, c = vrs.length; x < c; x++)\n\t{\n\t\tif (vrs[x].indexOf(vr) != -1)\n\t\t{\n\t\t\treturn decodeURI(vrs[x].split('=')[1]);\n\t\t\tbreak;\n\t\t}\n\t\t;\n\t}\n\t;\n}", "function getUrlArgs() {\n\tvar qs = (location.search.length > 0 ? location.search.substring(1) : \"\")\n\tvar args = {};\n\tvar items = qs.split(\"&\");\n\tvar item = null;\n\tname = null;\n\tvalue = null;\n\tfor (var i = 0; i < items.length; i++) {\n\t\titem = items[i].split(\"=\");\n\t\tname = decodeURIComponent(item[0]);\n\t\tvalue = decodeURIComponent(item[1]);\n\t\targs[name] = value;\n\t}\n\treturn args;\n}", "function getUrlParams()\n {\n var decodedUri = decodeURIComponent(window.location.href);\n var params = [], hash;\n var hashes = decodedUri.slice(decodedUri.indexOf('?') + 1).split('&');\n\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n if (hash[1]) {\n params.push(hash[1].replace('+', ' '));\n }\n }\n return params;\n }", "function getURLParams() {\n var vars = {};\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n vars[key] = value;\n });\n return vars;\n}", "function getURLParams()\n{\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n}", "function getParams()\n{\n var idx = document.URL.indexOf('?');\n var params = [];\n if (idx != -1) {\n var pairs = document.URL.substring(idx+1, document.URL.length).split('&');\n for (var i=0; i<pairs.length; i++)\n {\n nameVal = pairs[i].split('=');\n params[nameVal[0]] = nameVal[1];\n }\n }\n return params;\n}", "function getUrlParams(){\r\n var url = decodeURIComponent(location.href);\r\n var query = url.split('?')[1];\r\n var params = {};\r\n if (query !== ''){\r\n var arr = query.split('&');\r\n for (var i of arr) {\r\n var entry = i.split('=');\r\n var key = entry[0];\r\n var value = entry[1];\r\n params[key] = value;\r\n }\r\n }\r\n return params;\r\n}", "function getUrlParams() {\n\tvar vars = {};\n\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi,\n\t\t\tfunction(m, key, value) {\n\t\t\t\tvars[key] = value;\n\t\t\t});\n\treturn vars;\n}", "function parseParams() {\n var md = view.getLocation().match(/^(.*?)#(.*)$/);\n var result = {};\n if(md) {\n var hash = md[2];\n hash.split('&').forEach(function(param) {\n var kv = param.split('=');\n if(kv[1]) {\n result[kv[0]] = decodeURIComponent(kv[1]);\n }\n });\n if(Object.keys(result).length > 0) {\n view.setLocation(md[1] + '#');\n }\n }\n return result; \n }", "getURLParameters() {\n var hashParams = {};\n var e, r = /([^&;=]+)=?([^&;]*)/g,\n q = window.location.hash.substring(1);\n e = r.exec(q)\n while (e) {\n hashParams[e[1]] = decodeURIComponent(e[2]);\n e = r.exec(q);\n }\n return hashParams;\n }", "function getURLParameters() {\n var params = {};\n if (location.search) {\n var parts = location.search.substring(1).split(\"&\");\n for (var i = 0; i < parts.length; i++) {\n var pair = parts[i].split(\"=\");\n if (!pair[0]) {\n continue;\n }\n params[pair[0]] = pair[1] || \"\";\n }\n }\n return params;\n}", "function getRequest(){\n\tvar params = window.location.search.replace('?','').split('&').reduce(\n\t\tfunction(prev, curr){\n\t\t\tvar temp = curr.split('=');\n\t\t\tprev[decodeURIComponent(temp[0])] = decodeURIComponent(temp[1]);\n\t\t\treturn prev;\n\t\t},{}\n\t);\n\treturn params;\n}", "function get_url_params() {\n var url_params = new URLSearchParams(window.location.search);\n\n return url_params;\n}", "getUrlParams() {\n const params = [];\n for (let key in this.urlParameters) {\n params.push(`${encodeURIComponent(key)}=${encodeURIComponent(this.urlParameters[key])}`);\n }\n return params.join('&');\n }", "function parse_get_parameters() {\n if (location.search.length < 1) {\n return null;\n }\n else {\n var parameters = [];\n location.search\n .substr(1)\n .split(\"&\")\n .forEach(function (item) {\n let temp = item.split(\"=\");\n parameters.push(\n {\n parameter_name: temp[0],\n parameter_value: temp[1]\n }\n )\n });\n\n return parameters;\n }\n}", "function getURLparams() {\n var paramsArray = getURLSearch().split('&');\n var returnArray = [];\n\n paramsArray.forEach(function(param) {\n \n splitedParams = param.split('=');\n\n returnArray.push({\n name: splitedParams[0],\n value: splitedParams[1]\n });\n\n });\n\n return returnArray;\n}", "function parseCurrentUrlParams () {\n\t\tme.urlParams = me.paramsToObject(window.location.search.substr(1));\n\t}", "function getUrlVars() {\n\t\t\tvar vars = {};\n\t\t\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n\t\t\tvars[key] = value;\n\t\t\t});\n\t\t\treturn vars;\n\t\t}", "function urlQueryValues() {}", "function ekGetSearchParams() {\n var result = {};\n var searchParams = window.location.href.split('?');\n if (searchParams && searchParams.length > 1) {\n var vals = searchParams[1].split('&');\n for (var i = 0; i < vals.length; i++) {\n var next = vals[i].split('=');\n var key = next[0];\n var val = decodeURIComponent(next[1].replace(/\\+/g,' '));\n result[key] = val;\n }\n }\n return result;\n }", "function getSearchParameters() {\n var prmstr = window.location.search.substr(1);\n return prmstr != null && prmstr != \"\" ? transformToAssocArray(prmstr) : {};\n}", "function getUrlVars() {\n\t\t\tvar vars = {};\n\t\t\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n\t\t\t\tvars[key] = value;\n\t\t\t});\n\t\t\treturn vars;\n\t\t}", "function GetUrlVars() {\nvar vars = {};\nvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n vars[key] = value;\n});\nreturn vars;\n}", "function getParams() {\n var res = {}\n var params = location.search.substr(1).split('&')\n\n for (var value; value = params.pop();) {\n var tmp = value.split('=')\n res[tmp[0]] = decodeURIComponent(tmp[1])\n }\n\n return res\n}", "function getParams() {\n return qs.parse(window.location.search);\n}", "function getUrlVars() {\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for (var i = 0; i < hashes.length; i++) {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n }", "function getUrlVars() { \r\n var vars = {}, hash;\r\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\r\n for(var i = 0; i < hashes.length; i++)\r\n {\r\n hash = hashes[i].split('=');\r\n vars[hash[0]] = hash[1];\r\n }\r\n console.log(vars);\r\n return vars;\r\n }", "function getUrlVars() {\n \t\tvar vars = {};\n \t\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n \t\tvars[key] = value;\n \t\t});\n \t\treturn vars;\n\t\t}", "function getUrlVars() {\n \t\tvar vars = {};\n \t\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n \t\tvars[key] = value;\n \t\t});\n \t\treturn vars;\n\t\t}", "_getParams(route) {\n var matches = route.match(/:\\w+/g)\n return (matches || []).map(match => {\n return match.substring(1, match.length)\n })\n }", "function getSearchParameters() {\r\n var prmstr = window.location.search.substr(1);\r\n return prmstr != null && prmstr != \"\" ? transformToAssocArray(prmstr) : {};\r\n }", "function getURL() {\r\n let loc = document.location.href;\r\n\r\n if (loc.indexOf('?') > 0) {\r\n let getString = loc.split('?')[1];\r\n let GET = getString.split('&');\r\n var get = {};\r\n for (var i = 0, l = GET.length; i < l; i++) {\r\n var tmp = GET[i].split('=');\r\n get[tmp[0]] = unescape(decodeURI(tmp[1]));\r\n }\r\n return get;\r\n }\r\n}", "function getUrlVars() {\n var vars = {};\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, \n function(m,key,value) {\n vars[key] = value;\n });\n return vars;\n }", "function getUrlVars() {\n var vars = {};\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, \n function(m,key,value) {\n vars[key] = value;\n });\n return vars;\n }", "function getURLParams() {\n\tvar query = window.location.search.substring(1);\n\tvar vars = query.split(\"&\");\n\tvar query_string = {};\n\tfor (var i = 0; i < vars.length; i++) {\n\t\tvar pair = vars[i].split(\"=\");\n\t\tvar key = decodeURIComponent(pair[0]);\n\t\tvar value = decodeURIComponent(pair[1]);\n\t\t// If first entry with this name\n\t\tif (typeof query_string[key] === \"undefined\") {\n\t\t\tquery_string[key] = decodeURIComponent(value);\n\t\t\t// If second entry with this name\n\t\t} \n\t\telse if (typeof query_string[key] === \"string\") {\n\t\t\tvar arr = [query_string[key], decodeURIComponent(value)];\n\t\t\tquery_string[key] = arr;\n\t\t\t// If third or later entry with this name\n\t\t} \n\t\telse {\n\t\t\tquery_string[key].push(decodeURIComponent(value));\n\t\t}\n\t}\n\treturn query_string;\n}", "function getUrlParameters() {\n var params = location.search.slice(1).split('&');\n\n var targetUrl = \"\";\n var configUrl = \"\";\n\n for (var i =0; i < params.length; i++) {\n var param = params[i];\n if (param.split('=')[0] == 'target') {targetUrl = param.split('=')[1]}\n if (param.split('=')[0] == 'config') {configUrl = param.split('=')[1]}\n }\n\n // read default configuration\n $.ajax({\n type: \"GET\",\n url: \"config/default.json\",\n dataType: \"json\",\n async: false,\n success: function(data) {\n setConfig(data);\n },\n error: function() {\n alert(\"Could not read default configuration. Consult the administrator.\");\n }\n });\n\n if (configUrl != \"\") {\n $.ajax({\n type: \"GET\",\n url: configUrl,\n dataType: \"json\",\n crossDomain: true,\n success: function(data) {\n setConfig(data);\n getAnnotationFrom(targetUrl);\n },\n error: function() {\n alert('could not read the configuration from the location you specified.');\n }\n });\n } else {\n getAnnotationFrom(targetUrl);\n }\n }", "function getVars(){\n var loc = document.location.href;\n var getString = loc.split('?');\n if(getString[1]){\n var GET = getString[1].split('&');\n var get = {};//This object will be filled with the key-value pairs and returned.\n\n for(var i = 0, l = GET.length; i < l; i++){\n var tmp = GET[i].split('=');\n get[tmp[0]] = unescape(decodeURI(tmp[1]));\n }\n return get;\n }else{\n return \"\";\n }\n}", "function getSearchParameters() {\n var prmstr = window.location.search.substr(1);\n return prmstr != null && prmstr != \"\" ? transformToAssocArray(prmstr) : {};\n }", "function getUrlVars() {\n\t\t\t\n\t\t\t\n\t\t\tvar vars = {};\n\t\t\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n\t\t\tvars[key] = value;\n\t\t\t});\n\t\t\treturn vars;\n\t\t\t\n\t\t}", "function obtainGETparameters() {\n\tvar oGetParameters = new Array();\n\n\tvar sLocation = location.search.split(\"?\");\t\n\tif(sLocation.length > 1) {\n\t\tvar sParameterList =sLocation[1].split(\"&\"); \n\n\t\tfor(var i=0; i < sParameterList.length; i++) { \n\t\t\tsParameterList[i] = sParameterList[i].split(\"+\").join(\" \");\n\t\t\tvar aValues = sParameterList[i].split(\"=\");\n\t\t\tvar sId = aValues[0];\n\t\t\tvar sValue = aValues[1];\n\t\t\toGetParameters[sId]=sValue;\n\t\t}\t\t\t\t\n\t}\n\treturn oGetParameters;\n}", "function getDataUrlParams()\n\t{\n\t\treturn objThis.selectorElt.tagSuggest().getDataUrlParams();\n\t}", "getURL() {\n const urlParams = new URLSearchParams(window.location.search);\n this.myParam = urlParams.get(\"gp\");\n return this.myParam;\n }", "function getCompanyParams() {\n\n // adds value specification to array\n var identities = [];\n identities.push('empmin');\n identities.push('empmax');\n identities.push('valuemin');\n identities.push('valuemax');\n identities.push('street');\n identities.push('zipCode');\n\n // adds value to array\n var params = [];\n params.push(document.getElementById('qp-min-emps').value);\n params.push(document.getElementById('qp-max-emps').value);\n params.push(document.getElementById('qp-min-market').value);\n params.push(document.getElementById('qp-max-market').value);\n params.push(document.getElementById('qp-street').value);\n params.push(document.getElementById('qp-zip-code').value);\n\n // adds value specification and value to array if value exist\n var queryParams = [];\n for (var index in params) {\n if (params[index] != '' && params[index] != null) {\n queryParams.push(identities[index] + \"=\" + params[index]);\n }\n }\n $('#company-params-modal').modal('hide');\n\n // returns a joined string with '&' seperation\n return \"company?\" + queryParams.join(\"&\");\n}", "function parseParameters() {\n var pageURL = window.location.href;\n var message = url(\"?message\", pageURL);\n\n if (message == \"submitted\") {\n $(\"#modal-message-submitted\").openModal();\n }\n}", "function getUrlVars() {\r\n var vars = {};\r\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, \r\n function(m,key,value) {\r\n vars[key] = value;\r\n });\r\n return vars;\r\n }", "function getParameters(){\n\tvar url = document.URL;\n\tvar vett = url.split('?');\n\tvar rawParameters = vett[1]; // contiene tutti i parametri get separati dal carattere '&'\n\tif(rawParameters == null){\n\t\treturn null;\n\t}\n\tvar rawParametersCouples = rawParameters.split('&');\n\tvar parameters = new Array();\n\tfor(var i=0;i<rawParametersCouples.length; i++){\n\t\tvar elemento = rawParametersCouples[i].split('=');\n\t\tvar chiave = elemento[0];\n\t\tvar valore = elemento[1];\n\t\tvalore = valore.replace(/%20+/g,\" \"); // rimpiazzo i %20 con degli spazi\n\t\tparameters[chiave] = valore; // le inserisco dentro un array associativo\n\t\t//console.log(\"Chiave: \"+chiave+\", valore: \"+parameters[chiave]); // DEBUG\n\t}\n\treturn parameters;\n}", "function getUrlVars()\n {\n var vars = {};\n if (window.location.href.indexOf('?') !==-1) {\n var url = window.location.href.split('?');\n var hashes = url[1].split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n var hash = hashes[i].split('=');\n vars[hash[0]] = hash[1];\n }\n }\n \n return vars;\n }", "function getParams() {\n const hash = decodeURIComponent(window.location.hash.substr(1))\n const params = (/:(.*)/).exec(hash)[1].split('&').reduce(function (result, item) {\n const split = item.split('=')\n result[split[0]] = split[1]\n return result\n }, {})\n return params\n}", "function getUrlVars() {\n //var vars = {};\n var vars;\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n vars = key + '=' + value;\n });\n return vars;\n}", "function getUrlVars()\r\n\t{\r\n\tvar vars = {};\r\n\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, \r\n\t\tfunction(m,key,value) {\r\n\t\t vars[key] = value;\r\n\t\t});\r\n\treturn vars;\r\n\t}", "function GetUrlParams() { \n var e, \n d = function (s) { return decodeURIComponent(s.replace(/\\+/g, \" \")); }, \n q = window.location.search.substring(1), \n r = /([^&=]+)=?([^&]*)/g; \n \n while (e = r.exec(q)) \n urlParams[d(e[1])] = d(e[2]); \n}", "getRequestUrl () {\n let url = new URL(this.base);\n\n const newSearchParams = new URLSearchParams(url.searchParams);\n newSearchParams.set('client_id', this.client.clientId);\n newSearchParams.set('redirect_uri', this.redirectUri);\n newSearchParams.set('response_type', 'code');\n newSearchParams.set('scope', 'activity:read_all');\n\n url.search = newSearchParams;\n return url;\n }", "getParameters() {\n assert(typeof this.link === 'string', 'You must provide at least one string as link!');\n const matches = this.REGEX_MATCHER_CURIE_PARAMS.exec(this.link);\n if (!matches || !matches[1]) return [];\n return matches[1].split(this.REGEX_MATCHER_PARAM_SPIT);\n }", "function getURLParameters() {\n\tvar parameters = {};\t\n\tvar urlText = window.location.search;\n\n\t//Decodes parameters if encoded in 'Game' parameter\n\tif (urlText.indexOf('?Game=') === 0) {\n\t\tvar encodedURLText = urlText.substring(6);\n\t\turlText = '?' + atob(encodedURLText);\n\t};\n\n\tvar queryValuePairs = urlText.substring(1).split(\"&\");\n\tfor (var i = 0; i < queryValuePairs.length; i++) {\t\t\n \tif (queryValuePairs[i] === \"\") {\n \tcontinue;\n \t}\n\n \tvar queryValueObj = queryValuePairs[i].split(\"=\");\n \tparameters[decodeURIComponent(queryValueObj[0])] = decodeURIComponent(queryValueObj[1] || \"\");\n };\n\n return parameters;\n}", "function getUrlVars() {\n\t\tvar vars = {};\n\t\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n\t\t\tvars[key] = value;\n\t\t});\n\t\treturn vars;\n\t}", "function getUrlVars() {\n var vars = {};\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi,\n function(m,key,value) {\n vars[key] = value;\n });\n return vars;\n }", "function getUrlVars(){\r\n var vars = [];\r\n var loc = window.location.search.substring(1);\r\n var hashes = loc.split('&');\r\n for(var i = 0; i < hashes.length; i++){\r\n var hash = hashes[i].split('=');\r\n vars.push(hash[0]);\r\n vars[hash[0]] = hash[1];\r\n }\r\n return vars;\r\n}", "function getURLParameters()\n {\n var sURL = window.document.URL.toString();\n if (sURL.indexOf(\"?\") > 0)\n {\n var arrParams = sURL.split(\"?\");\n var arrURLParams = arrParams[1].split(\"&\");\n\n var i = 0;\n for (i = 0; i<arrURLParams.length; i++)\n {\n var sParam = arrURLParams[i].split(\"=\");\n key = unescape(sParam[0]);\n if (sParam[1] != \"\")\n value = unescape(sParam[1]);\n else\n value = null;\n\n if(argv[key] == null){\n argv[key] = value;\n }\n else if(typeof argv[key] === 'string'){\n argv[key] = [ argv[key], value ];\n }\n else {\n argv[key].push(value);\n }\n }\n }\n }", "function getUrlParams() {\n var params = {};\n var location = redirect_1.getLocation();\n if (!location) {\n return params;\n }\n var hashes = location.search.slice(location.search.indexOf('?') + 1).split('&');\n return hashes.reduce(function (acc, hash) {\n var _a;\n var _b = hash.split('='), key = _b[0], val = _b[1];\n return __assign(__assign({}, acc), (_a = {}, _a[decodeURIComponent(key)] = decodeURIComponent(val), _a));\n }, params);\n}", "function getPersonParams() {\n\n // adds value specification to array\n var identities = [];\n identities.push('zipcode');\n identities.push('street');\n\n // adds value to array\n var params = [];\n params.push(document.getElementById('zipcode').value);\n params.push(document.getElementById('street').value);\n\n // adds value specification and value to array if value exist\n var queryParams = [];\n for (var index in params) {\n if (params[index] != '' && params[index] != null) {\n queryParams.push(identities[index] + \"=\" + params[index]);\n }\n }\n $('#person-params-modal').modal('hide');\n\n // returns a joined string with '&' seperation\n return \"person?\" + queryParams.join(\"&\");\n}", "function getUrlVars() {\n var vars = {};\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n vars[key] = value;\n });\n return vars;\n }", "function populateGet() {\r\n\tvar obj = {}, params = location.search.slice(1).split('&');\r\n\tfor(var i=0,len=params.length;i<len;i++) {\r\n\t\tvar keyVal = params[i].split('=');\r\n\t\tobj[decodeURIComponent(keyVal[0])] = decodeURIComponent(keyVal[1]);\r\n\t}\r\n\treturn obj;\r\n}", "function getQueryString() {\n var result = {}, queryString = location.search.substring(1),\n re = /([^&=]+)=([^&]*)/g, m;\n\n while (m = re.exec(queryString)) {\n result[decodeURIComponent(m[1])] = decodeURIComponent(m[2]);\n }\n\n return result;\n }", "function getUrlVars() {\n var vars = {};\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function (m, key, value) {\n vars[key] = value;\n });\n return vars;\n\n }", "function getURL() {\n var query_string = {};\n var query = window.location.search.substring(1);\n var vars = query.split(\"&\");\n for (var i=0;i<vars.length;i++) {\n var pair = vars[i].split(\"=\");\n // If first entry with this name\n if (typeof query_string[pair[0]] === \"undefined\") {\n query_string[pair[0]] = decodeURIComponent(pair[1]);\n // If second entry with this name\n } else if (typeof query_string[pair[0]] === \"string\") {\n var arr = [ query_string[pair[0]],decodeURIComponent(pair[1]) ];\n query_string[pair[0]] = arr;\n // If third or later entry with this name\n } else {\n query_string[pair[0]].push(decodeURIComponent(pair[1]));\n }\n }\n return query_string;\n}", "function getParams(){\r\n\tall_scripts = document.getElementsByTagName('script');\r\n\tscript_index = all_scripts.length - 2;\r\n\tlast_script = all_scripts[script_index];\r\n\tqueryString = last_script.src.replace(/^[^\\?]+\\??/,'');\r\n}", "function relay_parameters () {\n\n parameters = getURLParameters();\n\n $('a[href]:not(a[href^=\"javascript\"]):not(a[href^=\"mailto\"])').each( function () {\n\n for (var name in parameters) {\n var hash = $(this).attr('href').split('#')[1] ? ( '#' + $(this).attr('href').split('#')[1] ) : '';\n $(this).attr('href', updateURLParameter( $(this).attr('href').split('#')[0], name, parameters[name] ) + hash );\n\n }\n });\n\n}", "function get_params() {\n return get_cookie(\"params\");\n}", "function getParamURL(name) {\n return decodeURIComponent((new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(location.search)||[,\"\"])[1].replace(/\\+/g, '%20'))||null\n}", "function getURLParams() {\n try {\n var search = location.search.substring(1);\n return search ? JSON.parse('{\"' + search.replace(/&/g, '\",\"').replace(/=/g, '\":\"') + '\"}',\n function(key, value) {\n return key === \"\" ? value : decodeURIComponent(value);\n }) : {};\n } catch (_) {\n return {};\n }\n}", "function getUrlVars()\r\n{\r\n var vars = {};\r\n\r\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value)\r\n {\r\n vars[key] = value;\r\n });\r\n return vars;\r\n}", "function getPageParameters() {\r\n var str = window.location.search.substr(1);\r\n var params = {};\r\n if (str) {\r\n var items = str.split(\"&\");\r\n for (var idItem = 0; idItem < items.length; idItem++) {\r\n var tmp = items[idItem].split(\"=\");\r\n params[tmp[0]] = decodeURIComponent(tmp[1]);\r\n }\r\n }\r\n return params;\r\n}", "function getURLParams (req) {\n\tvar urlParts = url.parse(req.url, true);\n\treturn urlParts.query;\n}", "function getUrlVars() {\n let vars = {};\n let parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m, key, value) {\n vars[key] = value;\n });\n return vars;\n}", "extractParameters(url, routePattern) {\n var result = {};\n let names = routePattern.trimAll(\"/\").split(\"/\");\n let values = url.trimAll(\"/\").split(\"/\");\n\n for (var i=0; i<names.length; i++) {\n var name = names[i];\n if ((new RegExp(\"<.+?>\")).test(name)) {\n var trimmedName = name.replaceAll(\"<\", \"\").replaceAll(\">\", \"\");\n result[trimmedName] = values[i];\n }\n }\n return result;\n }", "function getUrlVars()\n {\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n\n return vars;\n }", "function getUrlVars()\n {\n var vars = [], hash;\n var vhref = window.location.href;\n //console.log('vhref:'+vhref);\n var hashes = vhref.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n }", "function getUrlVars() {\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n }", "function getUrlVars() {\n\t\tvar vars = {};\n\t\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n\t\t\tvars[key] = value.replace(\"#\", \"\");\n\t\t});\n\t\treturn vars;\n\t}", "function getUrlParams ()\n{\n let query = window.location.search.substring(1);\n let params = query.split ('&');\n\n let object = new Object ();\n for (let param of params)\n {\n let pair = param.split ('=');\n\n object[pair[0]] = pair[1];\n }\n\n return object;\n}", "function getUrlVars() {\n\t var vars = {};\n\t var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n\t vars[key] = value;\n\t });\n\t return vars;\n\t}", "function getUrlVars() {\r\n\tvar vars = {};\r\n\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\r\n\t\tvars[key] = value;\r\n\t});\r\n\treturn vars;\r\n}", "function getCampaignParamsFromURL() {\n var params = getURLParams(),\n result = {},\n key,\n val;\n for (key in vtm_vars) {\n val = vtm_vars[key];\n if (params[key])\n result[val] = params[key];\n }\n return result;\n}", "function getUrlVars() {\n var vars = [],\n hash;\n var hashes = window.location.href\n .slice(window.location.href.indexOf(\"?\") + 1)\n .split(\"&\");\n for (var i = 0; i < hashes.length; i++) {\n hash = hashes[i].split(\"=\");\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n }", "function getParams() {\n if (!window.frameElement.hasAttribute('data-params')) {\n return;\n }\n params = JSON.parse(decodeURIComponent(window.frameElement.getAttribute('data-params')));\n }", "function getUrlVars() {\n let vars = {}\n let parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function (m, key, value) {\n vars[key] = value\n })\n return vars\n}", "function getUrlVars() {\r\n var vars = {};\r\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi,\r\n function(m,key,value) {\r\n vars[key] = value;\r\n });\r\n return vars;\r\n}", "function getUrlVars() {\n\tvar urlParams;\n\t\n var match,\n pl = /\\+/g, // Regex for replacing addition symbol with a space\n search = /([^&=]+)=?([^&]*)/g,\n decode = function (s) { return decodeURIComponent(s.replace(pl, \" \")); },\n query = window.location.search.substring(1);\n \n\turlParams = {};\n while (match = search.exec(query))\n urlParams[decode(match[1])] = decode(match[2]);\n\t\n\t//if (urlParams.demoMode==\"y\") { urlParams = defaultData.ortho; } \n\t//urlParams = defaultData.ortho;\n\treturn urlParams;\n}", "function getQueryString() {\n return window.location.search\n .substr(1)\n .split('&')\n .map(item => item.split('='))\n .reduce((acc, curr) => {\n acc[curr[0]] = curr[1];\n return acc;\n }, {});\n}" ]
[ "0.6902981", "0.67514557", "0.6713892", "0.662862", "0.6604577", "0.65747327", "0.65498495", "0.65119433", "0.65069336", "0.6499713", "0.64825743", "0.6458913", "0.64554983", "0.64527464", "0.64510113", "0.6406078", "0.6378883", "0.6325121", "0.63198483", "0.6311011", "0.6303175", "0.62796634", "0.61942494", "0.61886144", "0.61845255", "0.6166216", "0.6162157", "0.6116305", "0.6111595", "0.6100203", "0.6094405", "0.60665315", "0.6063976", "0.6047142", "0.6036097", "0.6032164", "0.60313445", "0.60265076", "0.60102516", "0.60012776", "0.60012776", "0.60010797", "0.59962213", "0.5992922", "0.59888595", "0.59888595", "0.5985421", "0.59838384", "0.5981863", "0.5978845", "0.5970597", "0.5969788", "0.59688765", "0.59557366", "0.59380174", "0.59372175", "0.59357524", "0.59288794", "0.5919417", "0.5911438", "0.59107554", "0.5905521", "0.5896881", "0.5892791", "0.58925444", "0.5892134", "0.588894", "0.5885543", "0.5883209", "0.5882344", "0.5879047", "0.5870406", "0.5863388", "0.5856343", "0.5855996", "0.5851892", "0.5844001", "0.58365387", "0.58353496", "0.58350986", "0.5833465", "0.5832347", "0.5830555", "0.58277416", "0.5827647", "0.5827606", "0.58205175", "0.5817817", "0.58169985", "0.5806657", "0.58058643", "0.5805591", "0.580175", "0.5801", "0.5797578", "0.578432", "0.57766634", "0.57741016", "0.57732064", "0.5771683", "0.57709914" ]
0.0
-1
helper function to display card on successful password reset
function SuccessfullyResetCard() { return ( <Card className="px-5 pt-4"> <Card.Header className="card-header-no-border"><h2 className="font-weight-bold">You've successfully reset your password!</h2></Card.Header> <Card.Body className="px-0"> <Row className="mt-2 px-0"> <Col className="pl-3 py-1"> <CustomButton wide secondary type="button" className="drop-shadow py-2" style={{ backgroundColor: 'var(--primary3)', color: 'var(--gray1)' }} href="/login" > Return to Login </CustomButton> </Col> </Row> </Card.Body> </Card> ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function ResetCard({ email, onPasswordChange, submitForm, errorCode}) {\r\n return (\r\n <Card className=\"px-5 pt-4\">\r\n <Card.Header className=\"card-header-no-border\">\r\n <h2 className=\"font-weight-bold\">Resetting Password for:</h2 >\r\n <p className=\"mb-0\">{email}</p>\r\n </Card.Header >\r\n <Card.Body className=\"px-0\">\r\n {errorCode !== '' && <h6 className=\"text-danger\">{ }</h6>}\r\n <Form onSubmit={submitForm}>\r\n <Form.Group controlId=\"password\">\r\n <Form.Control\r\n className=\"py-4\"\r\n required\r\n type=\"password\"\r\n onChange={onPasswordChange}\r\n placeholder=\"New Password\" />\r\n </Form.Group>\r\n <Row className=\"mt-2 px-0\">\r\n <Col className=\"pr-3 py-1\">\r\n <CustomButton\r\n wide\r\n type=\"submit\"\r\n className=\"drop-shadow py-2\"\r\n > \r\n Save\r\n </CustomButton>\r\n </Col>\r\n </Row>\r\n <Row>\r\n <Col className=\"mt-4\">\r\n <p className=\"main-text\">Don't have an account yet? <a href=\"/\">Sign up!</a></p>\r\n </Col>\r\n </Row>\r\n </Form>\r\n </Card.Body>\r\n </Card >\r\n );\r\n}", "function resetPasswordSuccess() {\n var $formState = $('.reset-password-success');\n\n // check if reset password form was successfully submited.\n if (!$formState.length) {\n return;\n }\n\n // show success message\n $('#ResetSuccess').removeClass('hide');\n }", "function resetPasswordSuccess() {\n // check if reset password form was successfully submited\n if (!$('.reset-password-success').length) {\n return;\n }\n\n // show success message\n $('#ResetSuccess').removeClass('hide');\n }", "async resetPassword({ view, params, antl }) {\n return view.render('user.password', {\n token: params.token,\n key: params.key,\n action: 'UserController.storeResetPassword',\n header_msg: antl.formatMessage('main.change_password'),\n button_msg: antl.formatMessage('main.change_password'),\n })\n }", "function processResetPasswordReturn (data, $message) {\n\n if (data.result === \"No\") {\n // If result returned no then something went wrong so build and display an\n // error message\n\n // Build HTML for error message\n var result = [\n '<div class=\"alert alert-danger alert-dismissable\">',\n '<button type=\"button\"',\n ' class=\"close\"',\n ' data-dismiss=\"alert\"',\n ' aria-hidden=\"true\">&times;</button>',\n '<h4>Reset Password Error</h4>',\n data.message,\n '</div>'];\n\n // Output error message\n $message.html(result.join(''));\n\n } else {\n\n // Build HTML for success message\n var result = [\n '<div class=\"alert alert-success alert-dismissable\">',\n '<button type=\"button\"',\n ' class=\"close\"',\n ' data-dismiss=\"alert\"',\n ' aria-hidden=\"true\">&times;</button>',\n 'Password successfully reset!',\n '</div>'];\n\n // Output error message\n $message.html(result.join(''));\n\n }\n\n}", "function handleRecoverPassword(){\n if(emailValid()){\n console.log(`send me my password to: ${email}`)\n setEmail('')\n }else{\n console.log('invalid')\n }\n }", "function printResetPassword(token) {\n const main = document.getElementById(\"main\");\n main.innerHTML = `<div class=\"resetpage\">\n <div class=\"reset\">\n <h2>Reset password</h2>\n <form id=\"reset\">\n <label for=\"reset-password\">New password</label>\n <input type=\"password\" name=\"reset-password\" required>\n <br>\n <input type=\"submit\" value=\"Reset password\">\n </form>\n </div>\n </div>`;\n // when the user submits the form we call the function resetPassword()\n document.getElementById(\"reset\").addEventListener('submit', function(e) {\n e.preventDefault();\n resetPassword(token);\n })\n}", "function resetPassword(req, res) {\n res.render(\"resetPassword\");\n}", "function resetPassword() {\n\t\t\tif (vm.newPassword != \"\" && vm.newPassword == vm.confirmPassword) {\n\t\t\t\tvm.waiting = true;\n\t\t\t\tserver.resetPassword($stateParams.token, vm.newPassword).then(function(res) {\n\t\t\t\t\tvm.success = 1;\n\t\t\t\t\tvm.waiting = false;\n\t\t\t\t\t$rootScope.$broadcast('loading', false); // TODO (HACK)\n\t\t\t\t}, function(res) {\n\t\t\t\t\tvm.success = 0;\n\t\t\t\t\tvm.waiting = false;\n\t\t\t\t\t$rootScope.$broadcast('loading', false); // TODO (HACK)\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tgui.alertError(\"Passwords do not match.\");\n\t\t\t}\n\t\t}", "renderSuccess () {\n this.response.render('auth/password-changed', {\n title: 'Password Changed', returnToUrl: this.returnToUrl\n })\n }", "function resetChangePass(massage = \"\") {\n $(\"#successMassage\").html(massage);\n $(\"#verifyMassage\").html(\"\");\n $(\"#confirmMassage\").html(\"\");\n $('#currentPassword').val(\"\");\n $('#newPassword').val(\"\");\n $('#confirmPassword').val(\"\");\n}", "function forgotPasswordEnterDetails(){\n formLogin.removeClass('is-selected');\n formSignup.removeClass('is-selected');\n formForgotPassword.removeClass('is-selected');\n formForgotPasswordDetailsSignup.removeClass('is-selected'); \n formEnterDetailsOTP.removeClass('is-selected');\n\t\tformEnterLoginDetailsToSignUp.removeClass('is-selected');\n $('.cd-switcher').find('.selected').html(\"Forgot Password\");\n }", "function cardDetails(msg) {\n header('SECURE PAYMENT', msg)\n prompt.question(\"Enter your card number: \", (options) => {\n if (options == parseInt(options)) {\n payConfirm('YOUR PAYMENT WAS SUCCESSFUL !'.cyan);\n cart = [];\n } else {\n cardDetails('PLEASE ENTER A VALID INPUT'.cyan);\n }\n })\n}", "function unlockCard(card, codeInput){\r\n\tif(codeInput.substring(codeInput.length-1) == 'V'){\r\n\t\tif(codeInput.startsWith(card.password)){\r\n\t\t\tdisplayScreen(3);\r\n\t\t}\r\n\t\telse{\r\n\t\t\tremainingTries--;\r\n\t\t\tif(remainingTries==0){\r\n\t\t\t\tdisplayScreen(5);\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tdisplayScreen(2);\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\telse {\r\n\t\tdocument.getElementById(\"code\").innerHTML = \"• \".repeat(codeInput.length) + \"_ \".repeat(4-codeInput.length)\r\n\t}\r\n}", "function showPassword() {\n register((data, err)=>{\n if(data === -1) {\n showErr(err);\n }\n else {\n data = JSON.parse(data);\n userId = data.userId;\n attempt = 3;\n listenNextButton();\n $(\"#password1\").text(data.password_1);\n $(\"#password2\").text(data.password_2);\n $(\"#password3\").text(data.password_3);\n $(\"#ui_2\").fadeIn();\n }\n });\n}", "forgotPass() \n {\n \tAlert.alert(\n\t\t 'Go To Site',\n\t\t 'Pressing this button would help you restore your password (external source)',\n\t\t [\n\t\t {text: 'OK', onPress: () => console.log('OK Pressed')},\n\t\t ],\n\t\t {cancelable: false},\n\t\t);\n }", "if (\n prevProps.updatePasswordState.isFetching &&\n !this.props.updatePasswordState.isFetching &&\n this.props.updatePasswordState.error === null\n ) {\n Alert.alert(\n translate(\"reset.reset\"),\n translate(\"reset.changeSuccess\"),\n [{ text: \"OK\", onPress: () => this._returnToMain() }],\n { cancelable: false }\n );\n }", "function showIncorrectPasswordPage() {\n\n // Retrieve all password elements.\n var passwordInputForm = document.getElementById(\"passwordInputForm\");\n var passwordInputLabel = document.getElementById(\"passwordInputLabel\");\n var scenarios = document.getElementById(\"scenarios\");\n\n passwordInputLabel.innerHTML = \"Enter password\";\n passwordInputForm.className = \"item shown\";\n passwordSubmitButton.className = \"item shown\";\n\n scenarios.className = \"options hide\";\n document.getElementById(\"scenariosLabel\").innerHTML = \"\";\n\n showStartupErrorMessage(\"Incorrect password\");\n }", "function handlePasswordResetPage(req, res) {\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: \"\",\n resetErr: false\n });\n}", "function checkValidResetFormPassword() {\n let isValid = /^(?=.*\\d)(?=.*[a-z])(?=.*[A-Z])(?=.*[^a-zA-Z0-9])(?!.*\\s).{8,}$/.test(\n ResetForm.elements[\"password-reset\"].value\n );\n\n if (!isValid) {\n let errMes = ResetFormPassword.parentElement.parentElement.querySelector(\n \".error-message\"\n );\n if (errMes) return;\n\n let p = document.createElement(\"p\");\n p.classList.add(\"error-message\");\n\n let img = document.createElement(\"img\");\n img.src = \"./images/popup/exclamation.svg\";\n img.alt = \"icon\";\n\n let span = document.createElement(\"span\");\n span.innerText =\n \"Mật khẩu yêu cầu tối thiểu tám ký tự, ít nhất một chữ cái viết hoa, một chữ cái viết thường, một số và một ký tự đặc biệt\";\n\n p.appendChild(img);\n p.appendChild(span);\n\n ResetFormPassword.parentElement.parentElement.appendChild(p);\n ResetFormError.push(\"error\");\n } else {\n let errMes = ResetFormPassword.parentElement.parentElement.querySelector(\n \".error-message\"\n );\n if (!errMes) return;\n\n ResetFormPassword.parentElement.parentElement.removeChild(errMes);\n ResetFormError.pop();\n }\n}", "function postResetPassword() {\n const validatePasswords = validatePasswordMatch(password, confirmPassword);\n if (validatePasswords !== true) {\n setSubmitResult(validatePasswords);\n setIsError(true);\n return;\n }\n setIsLoading(true);\n setIsError(false);\n axios.post(process.env.REACT_APP_API_LINK + \"/password/reset\", {\n \"email\": data.email,\n token,\n password\n }).then(result => {\n setIsLoading(false);\n if (result.status === 200) {\n setIsSuccess(true);\n data.onCloseModal();\n alert(\"Password Reset Successful!\")\n } else {\n setSubmitResult(\"An error has occurred, please contact an administrator.\")\n setIsError(true);\n }\n }).catch(e => {\n setIsLoading(false);\n setSubmitResult(e.response.data.error);\n setIsError(true);\n });\n }", "function resALert() {\n alert(\"The form has been reset. Please try again.\");\n}", "function password_validation(){\n\n if(!checkResetPasswordEmail()) {\n return false;\n } else {\n document.getElementById('get_password').value = \"Sending...\";\n return true;\n }\n}", "function showPassword(displayPassword) {\n document.getElementById(\"password\").textContent = displayPassword;\n}", "function postResetPassword(data, textStatus, jqXHR, param) {\n\tvar user = param.user;\n\tvar uiDiv = $('#ui');\n\tuiDiv.html('');\n\tvar p = $('<p>');\n\tuiDiv.append(p);\n\tp.html('The password for \"' + user + '\" has been reset.');\n\tvar ul = $('<ul>');\n\tuiDiv.append(ul);\n\tvar li = $('<li>');\n\tul.append(li);\n\tli.html('New password: \"' + data[user] + '\"');\n}", "passwordReset() {\n Actions.passwordReset();\n }", "resetPassword(actionCode, newPassword) {\n var accountEmail;\n let thisComponent = this;\n // Verify the password reset code is valid.\n auth.verifyPasswordResetCode(actionCode).then(function(email) {\n var accountEmail = email;\n \n // TODO: Show the reset screen with the user's email and ask the user for\n // the new password.\n \n // Save the new password.\n auth.confirmPasswordReset(actionCode, newPassword).then(function(resp) {\n // Password reset has been confirmed and new password updated.\n \n // TODO: Display a link back to the app, or sign-in the user directly\n // if the page belongs to the same domain as the app:\n // auth.signInWithEmailAndPassword(accountEmail, newPassword);\n \n // TODO: If a continue URL is available, display a button which on\n // click redirects the user back to the app via continueUrl with\n // additional state determined from that URL's parameters.\n }).catch(function(error) {\n // Error occurred during confirmation. The code might have expired or the\n // password is too weak.\n });\n }).catch(function(error) {\n // Invalid or expired action code. Ask user to try to reset the password\n // again.\n }).then(function() {\n thisComponent.props.history.push('/signin'); // redirect to home page\n });\n }", "function retrieveForgotPassword() {\n var userData = {};\n angular.copy(vm.misc.forgotPassword, userData);\n cmnSvc.resetForm(scope.forgotPasswordForm, vm.misc.authData);\n fbaseSvc.resetForgetPassword(userData.emailAdd).then(function(rs){\n alert(rs);\n }, function(err){\n alert('Error! '+err);\n });\n }", "function showPasswordRecovery() {\n const form = document.getElementById(\"forgot-password\");\n form.querySelector(\"span\").classList.toggle(\"hidden\");\n}", "recoverPassword({ Bert }, { email }) {\n // Call forgot password procedure\n Accounts.forgotPassword({\n email,\n }, (error) => {\n if (error) {\n Bert.alert(error.reason, 'warning');\n } else {\n Bert.alert('Check your inbox for a reset link!', 'success');\n }\n });\n }", "function passwordsMismatched() {\n document.getElementById(\"passwordP\").style.display = \"visible\";\n}", "function reset() {\n // Flag it to prevent double clicking, and visually communicate\n if ($scope.isSubmitting) {\n return;\n }\n\n $scope.isSubmitting = true;\n\n // Lets try to reset their password\n visitorApiService.resetPassword({\n key: $scope.key,\n password: $scope.visitor.password\n })\n .$promise.then(function(response) {\n // Unlock the submit button\n $scope.isSubmitting = false;\n\n if (response.error === null) {\n return response.result; // email\n } else {\n // Most common error is an expired key\n $scope.message = commonUtilService.getMessage(response);\n return $q.reject();\n }\n })\n .then(function(email) {\n\n // Log them in now\n return visitorApiService.login({\n email: email,\n password: $scope.visitor.password\n })\n .$promise.then(function(response) {\n if (response.error !== null) {\n $scope.message = commonUtilService.getMessage(response);\n return $q.reject();\n }\n });\n })\n .then(function() {\n // Request customer info\n return visitorLoginService.isLoggedIn(true);\n })\n .then(function() {\n // Get their cart info\n cartService.reload();\n })\n .then(function() {\n // Redirect them to their last page\n var path = angular.module(\"visitorModule\").back.path || '/account';\n $location.path(path);\n });\n\n }", "function preRedeemSubmitActions(error) {\n var errorMsg = checkRedeemMandatoryFields(error);\n \n var pwdErrorMsg = validatePasswordSize();\n if (pwdErrorMsg != \"\") { \n errorMsg = errorMsg + pwdErrorMsg + \"\\n\\n\";\n }\n\n if (errorMsg != \"\"){\n alert(errorMsg);\n return false;\n }\n return errorMsg;\n}", "function confirmPasswordReset (e) {\n e.preventDefault();\n showConfirmation(\"Are you sure you want to reset your password?\").then(function (confirmed) {\n if (confirmed) {\n sendResetPasswordEmail().then(function () {\n $(e.target).parent().html('Password Reset Email Sent.');\n });\n }\n }).catch(function (error) {\n showError(\"Response Error\", error);\n });\n}", "function failedPasswordConfirmation(){\n req.flash('error', \"Incorrect current password.\");\n return res.redirect(\"/account\");\n }", "function forgotPasswordPage(req, res) {\n res.render('forgotPassword')\n}", "passwordreset(email) {\r\n return this.auth\r\n .sendPasswordResetEmail(email)\r\n .then(function () {\r\n alert(\"Email Sent!\");\r\n })\r\n .catch(function (error) {\r\n alert(\"An error occured. Please try again\");\r\n });\r\n }", "function showChangePasswordDialog(passwordResetToken) {\n\tvar errorCallback = function(error, data) {\n\n\t\t// Special case when old password did not match\n\t\tif(!passwordResetToken && !error && data && data[\"resultCode\"] === \"NOT_FOUND\") {\n\t\t\ttp.dialogs.showDialog(\"errorDialog\", \"#wrong-password\");\n\t\t} else {\n\t\t\tconsole.error(error, data);\n\t\t\ttp.dialogs.showDialog(\"errorDialog\", \"#password-change-failed\")\n\t\t\t\t.on(\"ok\", function() {\n\t\t\t\t\tif(passwordResetToken) {\n\t\t\t\t\t\tdoNavigate(\"/home.html\");\n\t\t\t\t\t}\n\t\t\t\t})\n\t\t\t;\n\t\t}\n\t};\n\tvar changeDispatcher = tp.dialogs.showDialog(\"changePasswordDialog\", tp.lang.getText(passwordResetToken ? \"password-change\" : \"change-password\"));\n\tif(!passwordResetToken) {\n\t\td3.select(\".password-old\").classed(\"hidden\", false);\n\t}\n\tchangeDispatcher\n\t\t.on(\"ok\", function() {\n\t\t\tvar oldPasswordElement = d3.select(\"input[name=password-old]\");\n\t\t\tvar oldPassword = oldPasswordElement.property(\"value\");\n\t\t\tvar newPasswordElement = d3.select(\"input[name=password-new]\");\n\t\t\tvar newPassword = newPasswordElement.property(\"value\");\n\t\t\tvar verifyPassword = d3.select(\"input[name=password-verify]\").property(\"value\");\n\t\t\tif(!passwordResetToken) {\n\t\t\t\tif(tp.util.isEmpty(oldPassword) || oldPassword.length < 6) {\n\t\t\t\t\ttp.dialogs.showDialog(\"errorDialog\", \"#password-too-short\")\n\t\t\t\t\t\t.on(\"ok\", function() {\n\t\t\t\t\t\t\toldPasswordElement.node().select();\n\t\t\t\t\t\t})\n\t\t\t\t\t;\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif(tp.util.isEmpty(newPassword) || newPassword.length < 6) {\n\t\t\t\ttp.dialogs.showDialog(\"errorDialog\", \"#password-too-short\")\n\t\t\t\t\t.on(\"ok\", function() {\n\t\t\t\t\t\tnewPasswordElement.node().select();\n\t\t\t\t\t})\n\t\t\t\t;\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\tif(newPassword !== verifyPassword) {\n\t\t\t\ttp.dialogs.showDialog(\"errorDialog\", \"#passwords-different\")\n\t\t\t\t\t.on(\"ok\", function() {\n\t\t\t\t\t\tnewPasswordElement.node().select();\n\t\t\t\t\t})\n\t\t\t\t;\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\tif(passwordResetToken) {\n\t\t\t\ttp.session.resetPassword(passwordResetToken, newPassword, function(error, data) {\n\t\t\t\t\tif(error) {\n\t\t\t\t\t\terrorCallback(error, data);\n\t\t\t\t\t} else {\n\t\t\t\t\t\ttp.dialogs.showDialog(\"messageDialog\", \"#password-reset-change-successful\")\n\t\t\t\t\t\t\t.on(\"ok\", function() {\n\t\t\t\t\t\t\t\tdoNavigate(\"/home.html?signin=true\");\n\t\t\t\t\t\t\t})\n\t\t\t\t\t\t;\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\ttp.session.changePassword(oldPassword, newPassword, function(error, data) {\n\t\t\t\t\tif(error) {\n\t\t\t\t\t\terrorCallback(error, data);\n\t\t\t\t\t} else {\n\t\t\t\t\t\ttp.dialogs.closeDialogWithMessage(changeDispatcher.target, \"messageDialog\", \"#password-change-successful\");\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}\n\t\t\treturn false;\n\t\t})\n\t\t.on(\"cancel\", function() {\n\t\t\ttp.dialogs.closeDialogWithMessage(changeDispatcher.target, \"messageDialog\", \"#password-no-change\");\n\t\t\treturn false;\n\t\t})\n\t;\n}", "function changePasswordHandler(response) {\n messageData = JSON.parse(response);\n if (messageData.success) \n\tdocument.getElementById(\"changePasswordForm\").reset();\n}", "function forgetPassword(req, res) {\n res.render(\"forgetPassword\");\n}", "function forgotPasswordEnterDetailsSignup(){\n formLogin.removeClass('is-selected');\n formSignup.removeClass('is-selected');\n formForgotPassword.removeClass('is-selected');\n formForgotPasswordDetailsSignup.addClass('is-selected'); \n formEnterDetailsOTP.removeClass('is-selected');\n formEnterLoginDetailsToSignUp.removeClass('is-selected');\n $('.cd-switcher').find('.selected').html(\"Forgot Password\");\n }", "function reset() {\n password = \"\";\n charactersToUse = \"\";\n lengthofPW = 0;\n\n\n\n}", "handleOk() {\n const { email } = this.state;\n if (!this.validateEmail(email)) {\n message.error('Please enter valid eamil');\n return;\n }\n firebase.auth().sendPasswordResetEmail(email).then(() => {\n message.success('Password reset email has been sent.');\n }).catch((err) => {\n message.error(err.message);\n });\n this.setState({\n showModal: false,\n });\n }", "function ksForgotPassword(){\n //check if the form is valid\n if(!$('#forgotpassword').valid()) return;\n \n //put the loading screen on\n loadingScreen();\n \n //create an object to send to varify auth\n var obj=new Object();\n obj.email = $('#forgotpassword input[name=\"email\"]').val();\n \n //send the reset information via ajax\n $.ajax({\n type: \"POST\",\n url: \"/login/resetpassword/\",\n dataType: \"json\",\n data: obj ,\n async: false,\n success: function(res) {\n if (res.items[0].status ==='success'){\n setSuccessToSuccess();\n //loading screen\n removeLoadingScreen();\n\n //display success failure screen\n displaySuccessFailure();\n \n \n $('#glassnoloading').fadeOut('normal');\n \n //change the dialog to be more informative\n $('.registerdialog img').attr(\"src\" , \"/img/success.png\");\n $('.registerdialog * .message').text('Successfully identified your account. A mail was sent to the address you supplied. To proceed with password change follow the link in the mail sent.');\n $('.registerdialog > .front-card').remove();\n \n }\n else{\n setSuccessToFailed();\n //loading screen\n removeLoadingScreen();\n\n //display success failure screen\n displaySuccessFailure();\n\n $('#glassnoloading').fadeOut('normal');\n \n //change the dialog to be more informative\n $('.registerdialog img').attr(\"src\" , \"/img/failed.png\");\n $('.registerdialog * .message').text(res.items[0].msg);\n }\n },\n error: function(res){\n setSuccessToFailed();\n //loading screen\n removeLoadingScreen();\n \n //display success failure screen\n displaySuccessFailure();\n \n //$(\"#error\").text(\"Connection failure! Try again\");\n //change the dialog to be more informative\n $('.registerdialog img').attr(\"src\" , \"/img/failed.png\");\n $('.registerdialog * .message').text('Error! Connection failure. Try again');\n }\n });\n}", "resetUserPassword() {\n this.security.resetUserPassword(this.passwordDetails, '/api/auth/reset/' + this.$stateParams.token)\n .then((response) => {\n this.passwordDetails = null;\n this.toastr.success(\"Your password was reset successfully.\");\n // Attach user profile\n this.authentication.user = response;\n // And redirect to the index page\n this.$state.go('home');\n })\n .catch((response) => {\n this.toastr.error(response.message.message, 'Error');\n });\n }", "function logkey() {\n if(password.length <= 0) {\n // Displays message about password length requirements\n ReactDOM.render(<div id=\"password-status-2\">Password length must be one character or more</div>, document.getElementById('password-status-1'));\n // Show password length message\n $(\"#password-status-2\").show()\n } else if (password.length > 0) {\n // Hide password length message\n $(\"#password-status-2\").hide()\n }\n }", "function validateForgotPassword(e) {\n\n var regex = /^(\\d{3}\\d{3}\\d{4}|([\\w-]+(?:\\.[\\w-]+)*)@((?:[\\w-]+\\.)*\\w[\\w-]{0,66})\\.([a-z]{2,6}(?:\\.[a-z]{2})?))$/;\n e.preventDefault();\n if (regex.test(document.getElementById(\"capture_forgotPassword_resetPasswordUserID\").value)) {\n janrain.capture.ui.postCaptureForm('forgotPasswordForm');\n //document.getElementById('forgotFormButton').style.display = 'none';\n //document.getElementById(\"forgotFormSubmit\").click();\n } else if (document.getElementById(\"capture_forgotPassword_resetPasswordUserID\").value != '') {\n janrain.capture.ui.postCaptureForm('forgotPasswordForm');\n console.log('invalid.. fp GROUP ID');\n // document.getElementById('forgotPasswordGroupFailure').style.display = 'block';\n //document.getElementById('forgotPasswordForm').style.display = 'none';\n // document.getElementById('forgotFormButton').style.display = 'none';\n // document.getElementById(\"forgotFormSubmit\").click();\n } else {\n console.log('invalid blank fp');\n }\n}", "function resetPassword(email){\n $.ajax({\n method: 'POST',\n url: \"inc/Auth/forget.php\",\n data: {email: email}\n }).done(function(msg){\n if(msg == 'user issue')\n {\n AJAXloader(false, '#loader-pass-forgot');\n displayMessagesOut();\n $('.error-field').addClass('novisible');\n $('.error-forgot-exist').removeClass('novisible');\n displayError([], '#pass-forgot-form', ['input[name=\"pass-forgot\"]'], '');\n }\n if(msg == 'confirm issue')\n {\n AJAXloader(false, '#loader-pass-forgot');\n displayMessagesOut();\n $('.error-field').addClass('novisible');\n $('.error-forgot-confirm').removeClass('novisible');\n displaySpecial([], '#pass-forgot-form', ['input[name=\"pass-forgot\"]'], '');\n }\n //ce msg est un retour de la fonction de mail et non de la fonction de reset\n if(msg == 'success')\n {\n AJAXloader(false, '#loader-pass-forgot');\n displayMessagesOut();\n $('.error-field').addClass('novisible');\n $('.valid-forgot').removeClass('novisible');\n displaySuccess([], '#pass-forgot-form', ['input[name=\"pass-forgot\"]'], '');\n }\n });\n}", "resetPassword({ Meteor, Store, Bert }, data) {\n const { token, password } = data;\n const { dispatch } = Store;\n\n // Change state to password reset request\n dispatch(resetPasswordRequest());\n\n // Call reset password procedure\n Accounts.resetPassword(token, password, (error) => {\n if (error) {\n Bert.alert(error.reason, 'danger');\n // Change state to password reset error\n dispatch(resetPasswordError());\n } else {\n Bert.alert('Password reset!', 'success');\n // Change state to successful password reset\n dispatch(resetPasswordSuccess(Meteor.user()));\n\n // Redirect to home screen\n browserHistory.push('/');\n }\n });\n }", "function AdminConfirmPassword() {\r\n var password = $(\"#admin_password\").val()\r\n var confirm_pas = $(\"#confirm_password_reset\").val()\r\n if (confirm_pas.length == null || confirm_pas.length == \"\") {\r\n $(\"#conf_password_reset_label\").show();\r\n\r\n $(\"#confirm_password_reset\").addClass(\"has-error\");\r\n $(\"#conf_password_reset_label\").text(\"This Field is required\");\r\n return false;\r\n } \r\n else {\r\n if(confirm_pas != password) {\r\n $(\"#confirm_password_reset\").addClass(\"has-error\");\r\n $(\"#conf_password_reset_label\").show();\r\n $(\"#conf_password_reset_label\").text(\"Password is not match\");\r\n return false;\r\n } \r\n else {\r\n $(\"#confirm_password_reset\").removeClass(\"has-error\");\r\n $(\"#conf_password_reset_label\").hide();\r\n $(\"#conf_password_reset_label\").text(\"\");\r\n return true;\r\n }\r\n }\r\n\r\n}", "function showForgotPassword() {\n document.getElementById(\"newAccount\").style.display=\"none\";\n document.getElementById(\"login\").style.display=\"none\";\n document.getElementById(\"forgotPassword\").style.display=\"block\";\n document.getElementById(\"forgotUsername\").value=\"\";\n}", "function displayPassword() {\n document.querySelector(\"#generate\").blur(); // remove button focus so it doesn't hang there after password is displayed.\n document.querySelector(\"#passwordBox\").value = generatePassword(); // call generate function and place returned value into HTML <input>\n}", "function resetPassword(e) {\n e.preventDefault();\n\n axios\n .put(`${defaults.serverUrl}/account/change-credentials/${accountID}`, {\n security: questions,\n newPW: password,\n })\n .then((res) => {\n localStorage.setItem(\"token\", res.data);\n alert(\"Your password has been changed! Logging you in...\");\n router.push(\"/\");\n })\n .catch(() => {\n alert(\n \"Could not reset password! You likely had the wrong answers to the security questions\"\n );\n });\n }", "function onReset() {\n\tdocument.getElementById('username').value = \"\";\n\tdocument.getElementById('password').value = \"\";\n\tdocument.getElementById('email').value = \"\";\n\tdocument.getElementById('result').innerHTML = \"\";\n\tflagUsername = false;\n\tflagPassword = false;\n\tflagEmail = false;\n}", "function resetPassword() {\r\n \tconsole.log(\"Inside reset password\");\r\n \t//self.user.userpassword = self.user.password;\r\n \tself.user.user_id = $(\"#id\").val();\r\n \tself.user.obsolete = $(\"#link\").val();\r\n \tdelete self.user.confpassword;\r\n \tUserService.changePassword(self.user)\r\n \t\t.then(\r\n \t\t\t\tfunction (response) {\r\n \t\t\t\t\tif(response.status == 200) {\r\n \t\t\t\t\t\tself.message = \"Password changed successfully..!\";\r\n \t\t\t\t\t\tsuccessAnimate('.success');\r\n \t\t\t\t\t\t\r\n \t\t\t\t\t\twindow.setTimeout( function(){\r\n \t\t\t\t\t\t\twindow.location.replace('/Conti/login');\r\n \t\t\t\t \t}, 5000);\r\n \t\t\t\t\t\t\r\n \t\t\t\t\t} else {\r\n \t\t\t\t\t\tself.message = \"Password is not changed..!\";\r\n \t\t\t\t\t\tsuccessAnimate('.failure');\r\n \t\t\t\t\t}\r\n \t\t\t\t\t\r\n \t\t\t\t},\r\n \t\t\t\tfunction (errResponse) {\r\n \t\t\t\t\tconsole.log(errResponse);\r\n \t\t\t\t}\r\n \t\t\t);\r\n }", "checkForError() {\n if (this.state.attemptedSubmit && this.state.changePassword) {\n if (!this.compareOldPasswords())\n return (\n <div className=\"alert alert-danger\">\n Old password does not match current password.\n </div>\n );\n if (this.compareNewPasswords())\n return (\n <div className=\"alert alert-danger\">New passwords do not match.</div>\n );\n }\n return null;\n }", "function reset_password_form() {\n\t// Encode the String\n\tvar encoded_string = Base64.encode('login/reset_password/');\n\tvar encoded_val = encoded_string.strtr(encode_chars_obj);\n\t\n\tvar encoded_login_string = Base64.encode('login/index/');\n\tvar encoded_login_val = encoded_login_string.strtr(encode_chars_obj);\n\t\n\tvar success_msg = 'Successful';\n\tvar failure_msg = 'Failed';\n\t\n\tvar ajaxData = $(\"#resetForm\").serialize();\t\n\t\t$.ajax({\n\t\turl: base_url + encoded_val,\n\t\tdataType: \"json\",\n\t\ttype: \"post\",\n\t\tdata: ajaxData,\t\n\t\tbeforeSend: function() {\n $('.uni_wrapper').addClass('loadingDiv');\t\t\n },\t\t\n\t\tsuccess: function(response) {\n\t\t $('.uni_wrapper').removeClass('loadingDiv');\n\t\t\tif(true == response.status)\n\t\t\t{\t\t\t\t\n\t\t\t\t$(\".error-message .alert\").removeClass('alert-danger');\n\t\t\t\t$(\".error-message .alert\").addClass('alert-success');\n\t\t\t\t$(\".error-message\").show();\n\t\t\t\tif(response.message)\n\t\t\t\t{\n\t\t\t\t\tsuccess_msg = response.message;\n\t\t\t\t}\n\t\t\t\t$(\".alert\").html(success_msg);\n\t\t\t\tsetTimeout(function(){\t\t\t\t\t\t \n\t\t\t\t window.location.href = base_url + encoded_login_val;\t\t\t\t\t\t \n\t\t\t\t}, 500);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$(\".error-message\").show();\n\t\t\t\tif(response.message)\n\t\t\t\t{\n\t\t\t\t\tfailure_msg = response.message;\n\t\t\t\t}\n\t\t\t\t$(\".alert\").html(failure_msg);\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t});\t\n}", "function showForgotPasswordDIV() {\r\n\tdocument.getElementById('forgotPwd').style.display=\"block\";\r\n}", "processPassRep() {\n if (this.password.value !== this.passwordRepeat.value) {\n this.passwordRepeat.err = true;\n this.passwordRepeatErr.seen = true;\n this.valid = false;\n this.passwordRepeatErr.text = \"رمز عبور و تکرار آن یکسان نیستند\";\n } else {\n this.passwordRepeat.err = false;\n this.passwordRepeatErr.seen = false;\n }\n }", "function recoverPassword() {\n const email = document.getElementsByName(\"recover-email\").item(0);\n xhttp(\"POST\", \"forgot.php\", { email: email.value }, (response) => {\n // do nothing if it works or if it fails\n });\n const loginpage = document.getElementById(\"main\").querySelector(\"div.loginpage\");\n loginpage.innerHTML += '<p class=\"warn\">If the email is in our database, an email will be sent shortly to recover your account</p>';\n return false;\n}", "recoverPassword() {\n let { username } = this.state;\n if (username === '') {\n return this.setState({\n loginStatus: 'Enter your username or ssn for a chance to retrieve your password',\n });\n }\n fetch('/recover', {\n method: 'POST',\n body: JSON.stringify({ username }),\n headers: { 'content-type': 'application/json' },\n })\n .then(resp => resp.json())\n .then(data =>\n (data.password_hint.length\n ? this.setState({\n loginStatus: `The hint for user ${username} is: ${data.password_hint}`,\n })\n : this.setState({\n loginStatus:\n 'Looks like someone forget to set a password hint. Try making a new account instead!',\n })))\n .catch(console.error);\n }", "function forgotPassword() { \n\n\t\t\t$( \"#load\" ).show();\n\t\t\t\n\t\t\tvar form = new FormData(document.getElementById('reset_form'));\n\t\t\t\n\t\t\tvar validate_url = $('#reset_form').attr('action');\n\t\t\t\n\t\t\t$.ajax({\n\t\t\t\ttype: \"POST\",\n\t\t\t\turl: validate_url,\n\t\t\t\t//data: dataString,\n\t\t\t\tdata: form,\n\t\t\t\t//dataType: \"json\",\n\t\t\t\tcache : false,\n\t\t\t\tcontentType: false,\n\t\t\t\tprocessData: false,\n\t\t\t\tsuccess: function(data){\n\n\t\t\t\t\t\n\t\t\t\t\tif(data.success == true ){\n\t\t\t\t\t\t\n\t\t\t\t\t\t$( \"#load\" ).hide();\n\t\t\t\t\t\t$(\"input\").val('');\n\t\t\t\t\t\t\n\t\t\t\t\t\t$(\".forgot-password-box\").html(data.notif);\n\t\n\t\t\t\t\t\tsetTimeout(function() { \n\t\t\t\t\t\t\t//$(\"#notif\").slideUp({ opacity: \"hide\" }, \"slow\");\n\t\t\t\t\t\t\t//window.location.reload(true);\n\t\t\t\t\t\t}, 2000); \n\n\t\t\t\t\t}else if(data.success == false){\n\t\t\t\t\t\t$( \"#load\" ).hide();\n\t\t\t\t\t\t$(\"#notif\").html(data.notif);\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t},error: function(xhr, status, error) {\n\t\t\t\t\t$( \"#load\" ).hide();\n\t\t\t\t},\n\t\t\t});\n\t\t\treturn false;\n\t\t}", "_sendPasswordReset(user, password) {\n return this.mailer.reset({email: user.email, password: password})\n }", "function OtpPassword(){\r\n var otp_time_check=$(\"#reset_otp\").val();\r\n if(otp_time_check.length == '' || otp_time_check.length == null) {\r\n $(\"#reset_otp\").removeClass(\"has-success\");\r\n $(\"#reset_otp\").addClass(\"has-error\");\r\n $(\"#otp_label_reset\").show();\r\n\r\n $(\"#otp_label_reset\").text(\"This Field is required\");\r\n return false;\r\n }\r\n else{\r\n $(\"#reset_otp\").addClass(\"has-success\");\r\n $(\"#otp_label_reset\").show();\r\n $(\"#otp_label_reset\").text(\"\");\r\n return true;\r\n\r\n }\r\n \r\n }", "resetPassword(event) {\n var email = this.state.email;\n firebase.auth().sendPasswordResetEmail(email).then(() => {\n this.setState({ success: true })\n }).catch((error) => {\n this.setState({ success: false })\n alert(error.message);\n });\n }", "function printError() {\n if (!validatePasswd()) {\n isPasswdValid = false;\n var html = \"<img src ='image/Error-icon.png'></img><span style = 'color:red'>The two password don't Match!</span>\";\n document.getElementById('validatepasswd').innerHTML = html; \n } else {\n isPasswdValid = true;\n }\n if (!isCorrectEmail) {\n var email = document.getElementById('email').value \n if ( !validateEmail(email)) { errorMessage(\"Please input valid email address!\"); }\n else { errorMessage(\"The email was Registered!\");}\n }\n}", "function showCode() {\n\t\t\t//Reset game\n\t\t\tabortGame();\n\t\t\tvm.secretCode = Mastermind.secretCode();\n\t\t}", "function handlePasswordReset(req, res) {\n csrf.verify(req);\n\n if (!verifyReferrer(req, '/account/passwordreset')) {\n res.status(403).send('Mismatched referrer');\n return;\n }\n\n var name = req.body.name,\n email = req.body.email;\n\n if (typeof name !== \"string\" || typeof email !== \"string\") {\n res.send(400);\n return;\n }\n\n if (!$util.isValidUserName(name)) {\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: \"\",\n resetErr: \"Invalid username '\" + name + \"'\"\n });\n return;\n }\n\n db.users.getEmail(name, function (err, actualEmail) {\n if (err) {\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: \"\",\n resetErr: err\n });\n return;\n }\n\n if (actualEmail === '') {\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: \"\",\n resetErr: `Username ${name} cannot be recovered because it ` +\n \"doesn't have an email address associated with it.\"\n });\n return;\n } else if (actualEmail.toLowerCase() !== email.trim().toLowerCase()) {\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: \"\",\n resetErr: \"Provided email does not match the email address on record for \" + name\n });\n return;\n }\n\n crypto.randomBytes(20, (err, bytes) => {\n if (err) {\n LOGGER.error(\n 'Could not generate random bytes for password reset: %s',\n err.stack\n );\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: email,\n resetErr: \"Internal error when generating password reset\"\n });\n return;\n }\n\n var hash = bytes.toString('hex');\n // 24-hour expiration\n var expire = Date.now() + 86400000;\n var ip = req.realIP;\n\n db.addPasswordReset({\n ip: ip,\n name: name,\n email: actualEmail,\n hash: hash,\n expire: expire\n }, function (err, _dbres) {\n if (err) {\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: \"\",\n resetErr: err\n });\n return;\n }\n\n Logger.eventlog.log(\"[account] \" + ip + \" requested password recovery for \" +\n name + \" <\" + email + \">\");\n\n if (!emailConfig.getPasswordReset().isEnabled()) {\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: email,\n resetErr: \"This server does not have mail support enabled. Please \" +\n \"contact an administrator for assistance.\"\n });\n return;\n }\n\n const baseUrl = `${req.realProtocol}://${req.header(\"host\")}`;\n\n emailController.sendPasswordReset({\n username: name,\n address: email,\n url: `${baseUrl}/account/passwordrecover/${hash}`\n }).then(_result => {\n sendPug(res, \"account-passwordreset\", {\n reset: true,\n resetEmail: email,\n resetErr: false\n });\n }).catch(error => {\n LOGGER.error(\"Sending password reset email failed: %s\", error);\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: email,\n resetErr: \"Sending reset email failed. Please contact an \" +\n \"administrator for assistance.\"\n });\n });\n });\n });\n });\n}", "async passwordreset({ commit, dispatch }, form) {\n form.busy = true;\n try {\n await App.post(route(\"api.auth.reset-password\"), form).then(() => {\n commit(\"isAuthenticated\", {\n isAuthenticated: vm.$auth.check()\n });\n form.busy = false;\n });\n await dispatch(\"fetchMe\");\n } catch ({ errors, message }) {\n form.errors.set(errors);\n form.busy = false;\n }\n }", "async function requestResetPassword(formData) {\n const headers = {};\n attach_headers([HEADERS.CSRF], headers);\n const body = { user: formData };\n\n cleanupAuthState();\n dispatch({ type: LOADING_STARTED });\n const resp = await supervise_rq(() =>\n axios.post(API_PATHS.AUTH_UPDATE_PASSWORD, body, { headers })\n );\n\n if (resp.status === STATUS.SUCCESS) {\n dispatch({\n type: AUTH_ACTIONS.AUTH_REQUEST_RESET_PASSWORD,\n payload:\n \"If an account for the provided email exists, an email with reset instructions will be sent to you. Please check your inbox.\",\n });\n } else {\n dispatch({\n type: AUTH_ACTIONS.AUTH_ERROR,\n payload: \"Oops, something went wrong. Pleas try again later.\",\n });\n }\n }", "function resetPassword() {\n password = randomnum();\n}", "function forgotPass(click) {\n modal.style.display = \"block\";\n signin.style.display = \"none\";\n otp.style.display = \"none\";\n forgot.style.display = \"flex\";\n}", "resetPasswordInit(email) {\n return this.afAuth.auth.sendPasswordResetEmail(email, { url: 'https://coincoininsolite-1cf37.firebaseapp.com/__/auth/action' });\n }", "requirePassword() {\n this.navigateTo('walletResetRequirePassword');\n }", "function restorePassword(form, email) {\n\tvar emailValue = document.getElementById(email).value;\n\tvar auth = firebase.auth();\n\t\n\tauth.sendPasswordResetEmail(emailValue).then(function() {\n\t\t\tform.unbind().submit();\n\t\t}, function(error) {\n\t\t\t// console.log(error);\n\t\t\taddHidden(form, 'error', error.code);\n\t form.unbind().submit();\n\t\t});\n}", "auth() {\n \tif(this.attempt == this.correct)\n \t{\n \t\tthis.invalid = false;\n this.setState((state) => {\n return{\n \talert: \"Please enter your password: \", \n \tplacemessage: 'Enter password...'\n };\n });\n this.passInput.clear();\n this.props.navigation.navigate('MainStack');\n\n \t}\n \telse\n \t{\n \t\tthis.setState((state) => {\n this.invalid = true;\n this.showErrorAnimation();\n return{alert: \"Incorrect password. Please try again:\"};\n });\n \t}\n }", "function refresh(){\n \"use strict\";\n $(\"#js-display\").text(password());\n}", "function checkPasswordMatch() {\n const password = $(\"#password\").val();\n const confirmPassword = $(\"#password2\").val();\n const feedback = $(\"#divCheckPasswordMatch\");\n\n if (password !== confirmPassword) {\n feedback.html(\"Wachtwoorden zijn niet gelijk!\").removeClass('text-success').addClass('text-danger');\n return;\n }\n\n feedback.html(\"Wachtwoorden zijn gelijk.\").removeClass('text-danger').addClass('text-success');\n }", "screenToShow(){ \n if(!this.props.forgotPasswordScreen){\n return <AuthScreen renderError={this.renderError.bind(this)}/>\n } else {\n return <ResetScreen renderError={this.renderError.bind(this)}/>\n }\n }", "function showPassword(text){\n xapi.command(\"UserInterface Message TextInput Display\", {\n InputType: KEYBOARD_TYPES.PIN\n , Placeholder: \"Meeting Password (numeric)\"\n , Title: \"Meeting Password\"\n , Text: text\n , SubmitText: \"Next\"\n , FeedbackId: DIALPAD_PASSWORD\n } ).catch((error) => { console.error(error); });\n}", "function warnPasswordsDoNotMatch(){\n if (!createAccountPasswordsMatch()){\n $(\"#confirmPasswordMessage\").html('<p style=\"color:red;\">Passwords do not match.</p>');\n }\n}", "resetPassword(){\n firebase.auth().sendPasswordResetEmail(this.passwordChangeEmail)\n .then(() => alert(\"Password reset email sent\"))\n .catch((error) => this.setState({error:error.message}))\n }", "_handlePasswordCheck(res) {\n var passMsg = \"Incorrect password!\";\n var termMsg = \"Please agree to the terms of use!\";\n\n if (res == \"false\") { // Wrong password\n $scope.passwordMessage = passMsg;\n $(\"#passwordMessage\").fadeIn(100);\n }\n else if (!$scope.terms) { // Terms not checked\n $scope.passwordMessage = termMsg;\n $(\"#passwordMessage\").fadeIn(100);\n }\n else { // All correct\n $(\"#slide1\").fadeOut(0);\n $(\"#slide2\").fadeIn(200);\n $scope.isLocked = false;\n $scope.checkit();\n }\n $scope.$apply();\n }", "function showPassword(password) {\n $(\"input\").prev(\"p\").show(200);\n $(\"input:hidden\").show(200);\n $(\"#result\").val(password);\n}", "render() {\n return (\n <Card className=\"mt-4\">\n <Card.Body>\n <Card.Title>Admin Key Registration</Card.Title>\n <Form onSubmit={this.handleSubmit}>\n <Form.Group>\n <Form.Label>Please enter the secret key provided to you to request admin privileges for Academoo.</Form.Label>\n <Form.Control name=\"key\" onChange={this.handleChange} placeholder=\"Secret Key: e.g kd523nDJFL57ams7sv1m\" />\n </Form.Group>\n {!this.state.isLoading && <Button type=\"submit\" variant=\"outline-secondary\">Register Key</Button>}\n </Form>\n <br />\n {this.state.errors.map(error => (\n <Alert variant='warning' key={error}>{error.title}: {error.message}</Alert>\n ))}\n {this.state.changed && <Alert variant='success'>{this.state.user} has been added as a site-wide Admin!</Alert>}\n\n </Card.Body>\n </Card>\n )\n }", "function generatePassword() {\n var pw = mainForm.master.value,\n sh = mainForm.siteHost.value;\n\n // Don't show error message until needed\n hide(mainForm.pwIncorrect);\n\n // Only generate if a master password has been entered\n if (pw !== '') {\n if (settings.rememberPassword) {\n verifyPassword(pw, correct => {\n if (!correct) {\n // Master password is incorrect so show a warning\n show(mainForm.pwIncorrect);\n mainForm.master.select();\n }\n });\n }\n\n // Only generate if a site has been entered\n if (sh !== '') {\n mainForm.pwResult.value = '';\n mainForm.pwResult.placeholder = 'Generating...';\n\n // Generate a password to use, regardless of correct password\n uniquify(pw, sh, unique => {\n mainForm.pwResult.value = unique;\n mainForm.pwResult.placeholder = '';\n mainForm.pwResult.select();\n }, settings);\n }\n }\n }", "function showForgotPassword(){\n //position the forget password dialog in the middle\n var heighthtml = $('html').height()/2;\n var heightforget = $('#forget_password_dialog').height()/2;\n var widthhtml = $('html').width()/2;\n var widthforget = $('#forget_password_dialog').width()/2;\n $('#forget_password_dialog').css(\"top\", \"\" + (heighthtml - heightforget) + \"px\");\n $('#forget_password_dialog').css(\"left\", \"\" + (widthhtml - widthforget) + \"px\");\n $('#forget_password_dialog_success').css('display', 'none');\n $('#forget_password_dialog_error').css('display', 'none');\n $('#forget_password_dialog_body').css('display', 'block');\n $('#loginregister').fadeOut('normal', function(){\n $('#forget_password_dialog').fadeIn('normal');\n });\n}", "function forget_password(){\r\n localStorage.setItem(\"time\",\"1000\");\r\n localStorage.setItem(\"link\",\"password_reset.html\");\r\n window.open('loading.html',\"_self\");\r\n }", "function submitNewPassword() {\n axios.post(`/users/reset`, {onyen: onyenAndToken[0], password: password}, {\n headers: {\n Authorization: `Token ${onyenAndToken[1]}`\n }\n }).then(res => {\n window.localStorage.setItem('onyen', res.data.onyen);\n window.localStorage.setItem('name', res.data.name);\n if (res.data.admin) {\n window.localStorage.setItem(\"adminUser\", \"true\");\n history.push(\"/dashboard\");\n } else {\n window.localStorage.setItem(\"teamId\", res.data.teamId);\n window.localStorage.setItem(\"studentUser\", \"true\");\n history.push(\"/studentDash\");\n }\n });\n }", "recoverPassword(){\n this.setState({ isLoading: true });\n\n const { history, intl } = this.props;\n const { email } = this.state;\n\n // firebase.auth.sendPasswordResetEmail(email)\n // .then(() => {\n // NotificationService.success(intl.formatMessage(translations.emailSended));\n // this.setState({\n // ...this.INITIAL_STATE,\n // });\n // history.push(SIGN_IN);\n // }).catch((error) => {\n // this.setState({\n // isLoading: false,\n // isApiError: true,\n // apiError: error.message\n // });\n // });\n }", "handleSubmit () {\n\n let validation = validateChangePassword(this.state)\n if (validation !== false) {\n return this.props.openSnackBar(validation)\n } else {\n userChangePassword(this.state, this.props.state.token)\n .then((response) => {\n return this.props.openSnackBar('Ditt lösenord har ändrats!')\n }).catch((err) => {\n console.log(err)\n return this.props.openSnackBar('Något gick fel. Försök igen!')\n })\n }\n }", "function checkConfirmPassword() {\n var password = $modalPass.val();\n var confirmPassword = $modalConfirmPass.val();\n if (password !== confirmPassword) {\n $confirmPasswordError.html(\"Passwords Did Not Match\");\n $confirmPasswordError.show();\n $modalConfirmPass.css(\"border-bottom\",\"2px solid #F90A0A\");\n confirmPasswordError = true;\n } else {\n $confirmPasswordError.hide();\n $modalConfirmPass.css(\"border-bottom\",\"2px solid #34F458\");\n }\n }", "function checkResetPasswordEmail(){\n var reset_email = document.getElementById('recovery_email');\n var error_message = document.getElementById('error-recovery-message');\n\n if(reset_email.value.length <= 0) {\n error_message.style.visibility = \"visible\";\n error_message.innerText = \"The reset email is required\";\n reset_email.style.borderColor = \"red\";\n return false;\n } else {\n error_message.style.visibility = \"hidden\";\n error_message.innerText = \"\";\n reset_email.style.borderColor = \"red\";\n }\n return true;\n}", "function afterSuccess(value)\n{\nif(value == \"Thanks for registering with us. Please check your email inbox or spambox to activate your account with us!\")\n{\n//$('#customForm').resetForm();\ndocument.getElementById(\"customForm\").reset();\n}\n}", "function showMessage(res) {\n\t\tvar target = document.getElementById(\"invalid-container\");\n\t\tif (res == 'fail') {\n\t\t\tif($('#invalid-container').children().length == 0) {\n\t\t\t\tvar div = document.createElement('div');\n\t\t\t\tdiv.textContent = 'Invalid username or password';\n\t\t\t\tdiv.setAttribute('id', 'invalid');\n\t\t\t\ttarget.appendChild(div);\n\t\t\t}\n\t\t} else {\n\t\t\twindow.location='http://www.hsd-studio.com/';\n\t\t}\n\t}", "function forgotPassword(method,type) {\n hideError('email');\n addFunActionLabel=\"Forgot Pasword Submit\";\n if(pageType=='not_login'){\n var email = $.trim($(\"#TenTimes-Modal #userEmailCopy\").val()); \n }else{\n var email = $.trim($(\"#TenTimes-Modal #userEmail\").val());\n }\n if(!validateEmail12345(email)){\n $(\".alert_email\").show();\n return 0;\n }\n var otpType='password';\n if(type=='N' || type=='U'){\n otpType='otp';\n }\n\n if(method == \"connect\")\n var postData = {'email':email, 'name' : receiverData.name , 'type' : otpType }\n else\n var postData = {'email':email, 'name' : email , 'type' : otpType }\n showloading();\n $.post(site_url_attend+'/user/getpassword',postData,function(response){\n hideloading();\n response=$.parseJSON(response);\n var resText=response.resText;\n var resLink=response.resLink;\n if(type=='N' || type=='U'){\n resText=response.resText_typeN;\n resLink=response.resLink_typeN;\n \n }\n \n switch(response.response) {\n case 'true':\n $('#getpassword').parent().replaceWith(function() { return \"<a style='text-decoration:none'>\" + \"<p class='text-center' style='text-decoration:none;color:#909090;'>\" + resText + \"</p>\"+$('#getpassword').get(0).outerHTML+\"</a>\"; });\n\n $('#getpassword').text(resLink);\n if(method!='signup' && method!='connect' && method!='contact_organizer_venue'){\n $('#TenTimes-Modal .partial-log').hide();\n $('#getpassword').removeAttr(\"onclick\").click(function() {\n partialLog(method,type)\n }).text(resLink).css('color','#335aa1');\n }\n break;\n case 'false':\n $(\".alert_email\").html(\"Sorry, 10times doesn't recognize that email.\");\n $(\".alert_email\").show();\n break;\n }\n }); \n}", "function reset() { \n passwordLength = 0;\n specialCharacters = false;\n numbers = false;\n uppercase = false;\n lowercase = false;\n validInput = false;\n }", "function wrongPass() {\n const alert = document.createElement(\"ion-alert\");\n alert.cssClass = \"my-custom-class\";\n alert.header = \"Error\";\n alert.message = \"Wrong Password\";\n alert.buttons = [\"OK\"];\n\n //console.log(\"wrong password alert!\");\n document.body.appendChild(alert);\n return alert.present();\n}", "function displayPasswordValidationResults(result) {\n if (result['password-compare']) {\n $(\"#password-input\").addClass(\"is-valid\");\n $(\"#password-confirm\").addClass(\"is-valid\");\n\n $(\"#password-input-hint\").addClass(\"valid-feedback\");\n $(\"#password-confirm-hint\").addClass(\"valid-feedback\");\n $(\"#password-input-hint\").text(\"Passwords Match\");\n $(\"#password-confirm-hint\").text(\"Passwords Match\");\n }\n else {\n if (result['password'] && result['password-confirm']) {\n //both passwords filled out, don't match\n $(\"#password-input\").addClass(\"is-invalid\");\n $(\"#password-confirm\").addClass(\"is-invalid\");\n\n $(\"#password-input-hint\").addClass(\"invalid-feedback\");\n $(\"#password-confirm-hint\").addClass(\"invalid-feedback\");\n $(\"#password-input-hint\").text(\"Passwords Dont Match\");\n $(\"#password-confirm-hint\").text(\"Passwords Dont Match\");\n }\n else if (result['password'] && !result['password-confirm']) {\n //password is only filled out\n $(\"#password-confirm\").addClass(\"is-invalid\");\n\n $(\"#password-confirm-hint\").addClass(\"invalid-feedback\");\n $(\"#password-confirm-hint\").text(\"Required\");\n }\n else if (!result['password'] && result['password-confirm']) {\n //password-confirm is only filled out\n $(\"#password-input\").addClass(\"is-invalid\");\n\n $(\"#password-input-hint\").addClass(\"invalid-feedback\");\n $(\"#password-input-hint\").text(\"Required\");\n }\n else if (!result['password'] && !result['password-confirm']) {\n //neither password inputs are filled out\n $(\"#password-input\").addClass(\"is-invalid\");\n $(\"#password-confirm\").addClass(\"is-invalid\");\n\n $(\"#password-input-hint\").addClass(\"invalid-feedback\");\n $(\"#password-confirm-hint\").addClass(\"invalid-feedback\");\n $(\"#password-input-hint\").text(\"Required\");\n $(\"#password-confirm-hint\").text(\"Required\");\n }\n }\n}", "function managePasswordForgotten() {\n\t$('#passwordReset').click(function() { \n\t\t// We must reset the document and send a link to the registered email\n\t\t// to a form where the end user can update the password\n\t\tclearDocument();\n\t\tloadHTML(\"navbar.html\");\n\t\tnavbarHover();\n\t\t$(document.body).append(\"<center><h1>Please fill in the following form !</h1><center>\");\n\t\tloadHTML(\"passwordForgotten.html\");\n\t\tloadJS(\"js/forms.js\");\n formSubmission('#passwordForgotten','generatePasswordLnkRst','Reset email successfully sent','Unknown user');\n loadHTML(\"footer.html\");\n\t});\n}" ]
[ "0.7208443", "0.67232597", "0.66359365", "0.6481082", "0.63776284", "0.6299833", "0.6272654", "0.6238553", "0.6217429", "0.6184245", "0.6180472", "0.61693394", "0.616361", "0.6160195", "0.6153026", "0.61497974", "0.6142995", "0.61199033", "0.6092971", "0.6071315", "0.6041526", "0.60285306", "0.6013855", "0.5997027", "0.5967606", "0.59460497", "0.5941902", "0.5940685", "0.59352607", "0.5927691", "0.5917648", "0.59152555", "0.59104127", "0.58967966", "0.5872615", "0.5868968", "0.5849983", "0.58251864", "0.58185446", "0.57992864", "0.5788226", "0.5775835", "0.5771358", "0.5757017", "0.57553804", "0.5737938", "0.5710418", "0.5706936", "0.57056355", "0.57050556", "0.56794727", "0.56792736", "0.56754017", "0.566817", "0.56485087", "0.56427467", "0.56369865", "0.56277823", "0.5622724", "0.56148964", "0.56116045", "0.5609203", "0.5602478", "0.5595907", "0.5590742", "0.5587902", "0.5586226", "0.5584206", "0.55834776", "0.5571535", "0.5570636", "0.55490434", "0.55470383", "0.5543538", "0.5542204", "0.55387884", "0.55368274", "0.5526183", "0.55204177", "0.55171484", "0.5513299", "0.54926926", "0.5491053", "0.54883015", "0.5484335", "0.547961", "0.5471295", "0.54604393", "0.545983", "0.54578", "0.54558396", "0.5451013", "0.54459983", "0.54407465", "0.5436931", "0.54343754", "0.5433646", "0.5420389", "0.5418546", "0.54154915" ]
0.6236474
8
helper function to display reset password form
function ResetCard({ email, onPasswordChange, submitForm, errorCode}) { return ( <Card className="px-5 pt-4"> <Card.Header className="card-header-no-border"> <h2 className="font-weight-bold">Resetting Password for:</h2 > <p className="mb-0">{email}</p> </Card.Header > <Card.Body className="px-0"> {errorCode !== '' && <h6 className="text-danger">{ }</h6>} <Form onSubmit={submitForm}> <Form.Group controlId="password"> <Form.Control className="py-4" required type="password" onChange={onPasswordChange} placeholder="New Password" /> </Form.Group> <Row className="mt-2 px-0"> <Col className="pr-3 py-1"> <CustomButton wide type="submit" className="drop-shadow py-2" > Save </CustomButton> </Col> </Row> <Row> <Col className="mt-4"> <p className="main-text">Don't have an account yet? <a href="/">Sign up!</a></p> </Col> </Row> </Form> </Card.Body> </Card > ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async resetPassword({ view, params, antl }) {\n return view.render('user.password', {\n token: params.token,\n key: params.key,\n action: 'UserController.storeResetPassword',\n header_msg: antl.formatMessage('main.change_password'),\n button_msg: antl.formatMessage('main.change_password'),\n })\n }", "function resetPassword(req, res) {\n res.render(\"resetPassword\");\n}", "function printResetPassword(token) {\n const main = document.getElementById(\"main\");\n main.innerHTML = `<div class=\"resetpage\">\n <div class=\"reset\">\n <h2>Reset password</h2>\n <form id=\"reset\">\n <label for=\"reset-password\">New password</label>\n <input type=\"password\" name=\"reset-password\" required>\n <br>\n <input type=\"submit\" value=\"Reset password\">\n </form>\n </div>\n </div>`;\n // when the user submits the form we call the function resetPassword()\n document.getElementById(\"reset\").addEventListener('submit', function(e) {\n e.preventDefault();\n resetPassword(token);\n })\n}", "function showIncorrectPasswordPage() {\n\n // Retrieve all password elements.\n var passwordInputForm = document.getElementById(\"passwordInputForm\");\n var passwordInputLabel = document.getElementById(\"passwordInputLabel\");\n var scenarios = document.getElementById(\"scenarios\");\n\n passwordInputLabel.innerHTML = \"Enter password\";\n passwordInputForm.className = \"item shown\";\n passwordSubmitButton.className = \"item shown\";\n\n scenarios.className = \"options hide\";\n document.getElementById(\"scenariosLabel\").innerHTML = \"\";\n\n showStartupErrorMessage(\"Incorrect password\");\n }", "function forgotPasswordPage(req, res) {\n res.render('forgotPassword')\n}", "function onPasswordSet() {\n // Back to main form\n hide(pwSetForm);\n show(mainForm);\n\n // Password was just set, so generate right away if\n // site is filled in.\n if (mainForm.siteHost.value) {\n generatePassword();\n } else {\n // If the site has not been filled in, focus it.\n mainForm.siteHost.focus();\n }\n }", "function managePasswordForgotten() {\n\t$('#passwordReset').click(function() { \n\t\t// We must reset the document and send a link to the registered email\n\t\t// to a form where the end user can update the password\n\t\tclearDocument();\n\t\tloadHTML(\"navbar.html\");\n\t\tnavbarHover();\n\t\t$(document.body).append(\"<center><h1>Please fill in the following form !</h1><center>\");\n\t\tloadHTML(\"passwordForgotten.html\");\n\t\tloadJS(\"js/forms.js\");\n formSubmission('#passwordForgotten','generatePasswordLnkRst','Reset email successfully sent','Unknown user');\n loadHTML(\"footer.html\");\n\t});\n}", "function handlePasswordResetPage(req, res) {\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: \"\",\n resetErr: false\n });\n}", "function forgetPassword(req, res) {\n res.render(\"forgetPassword\");\n}", "function showForgotPassword() {\n document.getElementById(\"newAccount\").style.display=\"none\";\n document.getElementById(\"login\").style.display=\"none\";\n document.getElementById(\"forgotPassword\").style.display=\"block\";\n document.getElementById(\"forgotUsername\").value=\"\";\n}", "function reset_password_form() {\n\t// Encode the String\n\tvar encoded_string = Base64.encode('login/reset_password/');\n\tvar encoded_val = encoded_string.strtr(encode_chars_obj);\n\t\n\tvar encoded_login_string = Base64.encode('login/index/');\n\tvar encoded_login_val = encoded_login_string.strtr(encode_chars_obj);\n\t\n\tvar success_msg = 'Successful';\n\tvar failure_msg = 'Failed';\n\t\n\tvar ajaxData = $(\"#resetForm\").serialize();\t\n\t\t$.ajax({\n\t\turl: base_url + encoded_val,\n\t\tdataType: \"json\",\n\t\ttype: \"post\",\n\t\tdata: ajaxData,\t\n\t\tbeforeSend: function() {\n $('.uni_wrapper').addClass('loadingDiv');\t\t\n },\t\t\n\t\tsuccess: function(response) {\n\t\t $('.uni_wrapper').removeClass('loadingDiv');\n\t\t\tif(true == response.status)\n\t\t\t{\t\t\t\t\n\t\t\t\t$(\".error-message .alert\").removeClass('alert-danger');\n\t\t\t\t$(\".error-message .alert\").addClass('alert-success');\n\t\t\t\t$(\".error-message\").show();\n\t\t\t\tif(response.message)\n\t\t\t\t{\n\t\t\t\t\tsuccess_msg = response.message;\n\t\t\t\t}\n\t\t\t\t$(\".alert\").html(success_msg);\n\t\t\t\tsetTimeout(function(){\t\t\t\t\t\t \n\t\t\t\t window.location.href = base_url + encoded_login_val;\t\t\t\t\t\t \n\t\t\t\t}, 500);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$(\".error-message\").show();\n\t\t\t\tif(response.message)\n\t\t\t\t{\n\t\t\t\t\tfailure_msg = response.message;\n\t\t\t\t}\n\t\t\t\t$(\".alert\").html(failure_msg);\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t});\t\n}", "showPassword(e) {\n\t\tif(e){\n\t\t\tvar x = document.getElementById(\"exampleInputPassword1\");\n\t\t if (x.type === \"password\") {\n\t\t x.type = \"text\";\n\t\t } else {\n\t\t x.type = \"password\";\n\t\t }\n\t\t}\n\t}", "function displayPassword() {\n document.querySelector(\"#generate\").blur(); // remove button focus so it doesn't hang there after password is displayed.\n document.querySelector(\"#passwordBox\").value = generatePassword(); // call generate function and place returned value into HTML <input>\n}", "function resetChangePass(massage = \"\") {\n $(\"#successMassage\").html(massage);\n $(\"#verifyMassage\").html(\"\");\n $(\"#confirmMassage\").html(\"\");\n $('#currentPassword').val(\"\");\n $('#newPassword').val(\"\");\n $('#confirmPassword').val(\"\");\n}", "function postResetPassword(data, textStatus, jqXHR, param) {\n\tvar user = param.user;\n\tvar uiDiv = $('#ui');\n\tuiDiv.html('');\n\tvar p = $('<p>');\n\tuiDiv.append(p);\n\tp.html('The password for \"' + user + '\" has been reset.');\n\tvar ul = $('<ul>');\n\tuiDiv.append(ul);\n\tvar li = $('<li>');\n\tul.append(li);\n\tli.html('New password: \"' + data[user] + '\"');\n}", "function forgotPasswordEnterDetails(){\n formLogin.removeClass('is-selected');\n formSignup.removeClass('is-selected');\n formForgotPassword.removeClass('is-selected');\n formForgotPasswordDetailsSignup.removeClass('is-selected'); \n formEnterDetailsOTP.removeClass('is-selected');\n\t\tformEnterLoginDetailsToSignUp.removeClass('is-selected');\n $('.cd-switcher').find('.selected').html(\"Forgot Password\");\n }", "function showPasswordRecovery() {\n const form = document.getElementById(\"forgot-password\");\n form.querySelector(\"span\").classList.toggle(\"hidden\");\n}", "function password_validation(){\n\n if(!checkResetPasswordEmail()) {\n return false;\n } else {\n document.getElementById('get_password').value = \"Sending...\";\n return true;\n }\n}", "forgotPass() \n {\n \tAlert.alert(\n\t\t 'Go To Site',\n\t\t 'Pressing this button would help you restore your password (external source)',\n\t\t [\n\t\t {text: 'OK', onPress: () => console.log('OK Pressed')},\n\t\t ],\n\t\t {cancelable: false},\n\t\t);\n }", "function showChangePasswordDialog(passwordResetToken) {\n\tvar errorCallback = function(error, data) {\n\n\t\t// Special case when old password did not match\n\t\tif(!passwordResetToken && !error && data && data[\"resultCode\"] === \"NOT_FOUND\") {\n\t\t\ttp.dialogs.showDialog(\"errorDialog\", \"#wrong-password\");\n\t\t} else {\n\t\t\tconsole.error(error, data);\n\t\t\ttp.dialogs.showDialog(\"errorDialog\", \"#password-change-failed\")\n\t\t\t\t.on(\"ok\", function() {\n\t\t\t\t\tif(passwordResetToken) {\n\t\t\t\t\t\tdoNavigate(\"/home.html\");\n\t\t\t\t\t}\n\t\t\t\t})\n\t\t\t;\n\t\t}\n\t};\n\tvar changeDispatcher = tp.dialogs.showDialog(\"changePasswordDialog\", tp.lang.getText(passwordResetToken ? \"password-change\" : \"change-password\"));\n\tif(!passwordResetToken) {\n\t\td3.select(\".password-old\").classed(\"hidden\", false);\n\t}\n\tchangeDispatcher\n\t\t.on(\"ok\", function() {\n\t\t\tvar oldPasswordElement = d3.select(\"input[name=password-old]\");\n\t\t\tvar oldPassword = oldPasswordElement.property(\"value\");\n\t\t\tvar newPasswordElement = d3.select(\"input[name=password-new]\");\n\t\t\tvar newPassword = newPasswordElement.property(\"value\");\n\t\t\tvar verifyPassword = d3.select(\"input[name=password-verify]\").property(\"value\");\n\t\t\tif(!passwordResetToken) {\n\t\t\t\tif(tp.util.isEmpty(oldPassword) || oldPassword.length < 6) {\n\t\t\t\t\ttp.dialogs.showDialog(\"errorDialog\", \"#password-too-short\")\n\t\t\t\t\t\t.on(\"ok\", function() {\n\t\t\t\t\t\t\toldPasswordElement.node().select();\n\t\t\t\t\t\t})\n\t\t\t\t\t;\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif(tp.util.isEmpty(newPassword) || newPassword.length < 6) {\n\t\t\t\ttp.dialogs.showDialog(\"errorDialog\", \"#password-too-short\")\n\t\t\t\t\t.on(\"ok\", function() {\n\t\t\t\t\t\tnewPasswordElement.node().select();\n\t\t\t\t\t})\n\t\t\t\t;\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\tif(newPassword !== verifyPassword) {\n\t\t\t\ttp.dialogs.showDialog(\"errorDialog\", \"#passwords-different\")\n\t\t\t\t\t.on(\"ok\", function() {\n\t\t\t\t\t\tnewPasswordElement.node().select();\n\t\t\t\t\t})\n\t\t\t\t;\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\tif(passwordResetToken) {\n\t\t\t\ttp.session.resetPassword(passwordResetToken, newPassword, function(error, data) {\n\t\t\t\t\tif(error) {\n\t\t\t\t\t\terrorCallback(error, data);\n\t\t\t\t\t} else {\n\t\t\t\t\t\ttp.dialogs.showDialog(\"messageDialog\", \"#password-reset-change-successful\")\n\t\t\t\t\t\t\t.on(\"ok\", function() {\n\t\t\t\t\t\t\t\tdoNavigate(\"/home.html?signin=true\");\n\t\t\t\t\t\t\t})\n\t\t\t\t\t\t;\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\ttp.session.changePassword(oldPassword, newPassword, function(error, data) {\n\t\t\t\t\tif(error) {\n\t\t\t\t\t\terrorCallback(error, data);\n\t\t\t\t\t} else {\n\t\t\t\t\t\ttp.dialogs.closeDialogWithMessage(changeDispatcher.target, \"messageDialog\", \"#password-change-successful\");\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}\n\t\t\treturn false;\n\t\t})\n\t\t.on(\"cancel\", function() {\n\t\t\ttp.dialogs.closeDialogWithMessage(changeDispatcher.target, \"messageDialog\", \"#password-no-change\");\n\t\t\treturn false;\n\t\t})\n\t;\n}", "function getForgotPage(req, res) {\n res.render('forgot.ejs', {\n title: 'Forgot Password?',\n user: req.user,\n message: ''\n });\n}", "function showPassword(displayPassword) {\n document.getElementById(\"password\").textContent = displayPassword;\n}", "function generatePassword() {\n var pw = mainForm.master.value,\n sh = mainForm.siteHost.value;\n\n // Don't show error message until needed\n hide(mainForm.pwIncorrect);\n\n // Only generate if a master password has been entered\n if (pw !== '') {\n if (settings.rememberPassword) {\n verifyPassword(pw, correct => {\n if (!correct) {\n // Master password is incorrect so show a warning\n show(mainForm.pwIncorrect);\n mainForm.master.select();\n }\n });\n }\n\n // Only generate if a site has been entered\n if (sh !== '') {\n mainForm.pwResult.value = '';\n mainForm.pwResult.placeholder = 'Generating...';\n\n // Generate a password to use, regardless of correct password\n uniquify(pw, sh, unique => {\n mainForm.pwResult.value = unique;\n mainForm.pwResult.placeholder = '';\n mainForm.pwResult.select();\n }, settings);\n }\n }\n }", "function resetpwRoute() {\n return \"/resetpw?username=\" + encodeURIComponent(user.username) + \"&schoolCode=\" + req.body.schoolCode + \"&school=\" + (user.school ? encodeURIComponent(user.school.name) : \"none\");\n }", "function showPassword() {\n\tvar x = document.getElementById(\"password\");\n\tif (x.type === \"password\") {\n\t x.type = \"text\";\n\t} else {\n\t x.type = \"password\";\n\t}\n}", "passwordReset() {\n Actions.passwordReset();\n }", "function restorePassword(form, email) {\n\tvar emailValue = document.getElementById(email).value;\n\tvar auth = firebase.auth();\n\t\n\tauth.sendPasswordResetEmail(emailValue).then(function() {\n\t\t\tform.unbind().submit();\n\t\t}, function(error) {\n\t\t\t// console.log(error);\n\t\t\taddHidden(form, 'error', error.code);\n\t form.unbind().submit();\n\t\t});\n}", "function retrieveForgotPassword() {\n var userData = {};\n angular.copy(vm.misc.forgotPassword, userData);\n cmnSvc.resetForm(scope.forgotPasswordForm, vm.misc.authData);\n fbaseSvc.resetForgetPassword(userData.emailAdd).then(function(rs){\n alert(rs);\n }, function(err){\n alert('Error! '+err);\n });\n }", "function showForgotPassword(){\n //position the forget password dialog in the middle\n var heighthtml = $('html').height()/2;\n var heightforget = $('#forget_password_dialog').height()/2;\n var widthhtml = $('html').width()/2;\n var widthforget = $('#forget_password_dialog').width()/2;\n $('#forget_password_dialog').css(\"top\", \"\" + (heighthtml - heightforget) + \"px\");\n $('#forget_password_dialog').css(\"left\", \"\" + (widthhtml - widthforget) + \"px\");\n $('#forget_password_dialog_success').css('display', 'none');\n $('#forget_password_dialog_error').css('display', 'none');\n $('#forget_password_dialog_body').css('display', 'block');\n $('#loginregister').fadeOut('normal', function(){\n $('#forget_password_dialog').fadeIn('normal');\n });\n}", "function showPassword(password) {\n $(\"input\").prev(\"p\").show(200);\n $(\"input:hidden\").show(200);\n $(\"#result\").val(password);\n}", "function resetPasswordSuccess() {\n var $formState = $('.reset-password-success');\n\n // check if reset password form was successfully submited.\n if (!$formState.length) {\n return;\n }\n\n // show success message\n $('#ResetSuccess').removeClass('hide');\n }", "function toggleRecoverPasswordForm() {\n $('#RecoverPasswordForm').toggleClass('hide');\n $('#CustomerLoginForm').toggleClass('hide');\n }", "function toggleRecoverPasswordForm() {\n $('#RecoverPasswordForm').toggleClass('hide');\n $('#CustomerLoginForm').toggleClass('hide');\n }", "_sendPasswordReset(user, password) {\n return this.mailer.reset({email: user.email, password: password})\n }", "function checkValidResetFormPassword() {\n let isValid = /^(?=.*\\d)(?=.*[a-z])(?=.*[A-Z])(?=.*[^a-zA-Z0-9])(?!.*\\s).{8,}$/.test(\n ResetForm.elements[\"password-reset\"].value\n );\n\n if (!isValid) {\n let errMes = ResetFormPassword.parentElement.parentElement.querySelector(\n \".error-message\"\n );\n if (errMes) return;\n\n let p = document.createElement(\"p\");\n p.classList.add(\"error-message\");\n\n let img = document.createElement(\"img\");\n img.src = \"./images/popup/exclamation.svg\";\n img.alt = \"icon\";\n\n let span = document.createElement(\"span\");\n span.innerText =\n \"Mật khẩu yêu cầu tối thiểu tám ký tự, ít nhất một chữ cái viết hoa, một chữ cái viết thường, một số và một ký tự đặc biệt\";\n\n p.appendChild(img);\n p.appendChild(span);\n\n ResetFormPassword.parentElement.parentElement.appendChild(p);\n ResetFormError.push(\"error\");\n } else {\n let errMes = ResetFormPassword.parentElement.parentElement.querySelector(\n \".error-message\"\n );\n if (!errMes) return;\n\n ResetFormPassword.parentElement.parentElement.removeChild(errMes);\n ResetFormError.pop();\n }\n}", "show_prompt( text, type ) {\n\t\tif ( 'password' === type ) {\n\t\t\t$( '#passwordField' ).val( '' );\n\t\t\t$( '#passwordArea' ).show();\n\t\t\t$( '#passwordField' ).focus();\n\t\t}\n\t}", "function forgotPasswordEnterDetailsSignup(){\n formLogin.removeClass('is-selected');\n formSignup.removeClass('is-selected');\n formForgotPassword.removeClass('is-selected');\n formForgotPasswordDetailsSignup.addClass('is-selected'); \n formEnterDetailsOTP.removeClass('is-selected');\n formEnterLoginDetailsToSignUp.removeClass('is-selected');\n $('.cd-switcher').find('.selected').html(\"Forgot Password\");\n }", "function showForgotPasswordDIV() {\r\n\tdocument.getElementById('forgotPwd').style.display=\"block\";\r\n}", "function buildPasswordResetView(){\n\tpasswordResetWindow = Ti.UI.createWindow({\n\t\tbackgroundColor:UI_BACKGROUND_COLOR,\n\t\tmodal:true,\n\t\ttranslucent:false,\n\t\tbarImage:iOS7 ? IMAGE_PATH+'common/bar7.png' : IMAGE_PATH+'common/bar.png',\n\t\tbarColor:UI_COLOR,\n\t\ttitle:'Password Reset'\n\t});\n\t\n\t//check if version is ios 7 and higher and create new navigationWindow (3.1.3.GA)\n\t//if(iOS7){\n\t\tpasswordResetNavWin = Ti.UI.iOS.createNavigationWindow({\n\t\t modal: true,\n\t\t window: passwordResetWindow\n\t\t});\n\t//}\n\t\n\tvar passwordResetDoneButton = Titanium.UI.createButton({\n\t\tbackgroundImage:IMAGE_PATH+'common/Done_button.png',\n\t width:48,\n\t height:33\n\t});\n\tpasswordResetWindow.setRightNavButton(passwordResetDoneButton);\n\t\n\tpasswordResetDoneButton.addEventListener('click', function(e){\n\t\t//if(iOS7){\n\t\t\tpasswordResetNavWin.close();\n\t\t//}else{\n\t\t//\tpasswordResetWindow.close();\n\t\t//}\n\t});\n\t\n\tvar passwordResetDogsquareLogo = Ti.UI.createImageView({\n\t\timage:IMAGE_PATH+'signup/dogsquare_logo.png',\n\t\ttop:10\n\t});\n\tpasswordResetWindow.add(passwordResetDogsquareLogo);\n\t\n\tvar passwordResetFormBackground = Ti.UI.createView({\n\t\tbackgroundColor:'e7e6e6',\n\t\ttop:70,\n\t\twidth:262,\n\t\theight:42\n\t});\n\t\n\t//email textfield\n\tpasswordResetFieldEmail = Ti.UI.createTextField({\n\t\twidth:262,\n\t\theight:39,\n\t\tpaddingLeft:4, \n\t\tpaddingRight:4,\n\t\ttop:1,\n\t\tkeyboardType:Ti.UI.KEYBOARD_EMAIL\n\t});\n\tpasswordResetFormBackground.add(passwordResetFieldEmail);\n\tpasswordResetFieldEmail.addEventListener('change', handlePasswordResetTextFieldChange);\n\t\n\tpasswordResetFieldEmailHintTextLabel = Ti.UI.createLabel({\n\t\ttext:'Your Email',\n\t\tcolor:'999999',\n\t\ttextAlign:'left',\n\t\tleft:4,\n\t\topacity:0.7,\n\t\theight:30,\n\t\tfont:{fontSize:17, fontWeight:'regular', fontFamily:'Open Sans'}\n\t});\n\tpasswordResetFieldEmail.add(passwordResetFieldEmailHintTextLabel);\n\t\n\tvar passwordResetSepparator = Ti.UI.createView({\n\t\tbackgroundColor:'CCCCCC',\n\t\twidth:262,\n\t\theight:2,\n\t\ttop:40,\n\t\topacity:0.4\n\t});\n\tpasswordResetFormBackground.add(passwordResetSepparator);\n\t\t\n\tpasswordResetWindow.add(passwordResetFormBackground);\n\t\n\t//button to change password\n\tvar passwordResetButton = Ti.UI.createButton({\n\t\tbackgroundImage:IMAGE_PATH+'common/reset_btn.png',\n\t\twidth:270,\n\t\theight:55,\n\t\ttop:123,\n\t\tbottom:30\n\t});\n\tpasswordResetWindow.add(passwordResetButton);\n\tpasswordResetButton.addEventListener('click', handlePasswordResetButton);\n}", "function showPass() {\n if($scope.checkPass)\n $scope.typeInputPass = 'text';\n else\n $scope.typeInputPass = 'password';\n }", "function password(){\n\t\t\n\t\t\tvar a = document.getElementById(\"pwd1\").value;\n\t\t\tif(a.length <= 8 ){\n\t\t\t\tdocument.getElementById(\"pwd1Hint\").style.display ='block';\n\t\t\t\n\t\t\t}\n\t\t\tif(a.length >= 8){\n\t\t\t\tdocument.getElementById(\"pwd1Hint\").style.display ='none';\n\t\t\t}\n\t\t\n\t\t\t\n\t\t\t\n\t}", "function showPassword(text){\n xapi.command(\"UserInterface Message TextInput Display\", {\n InputType: KEYBOARD_TYPES.PIN\n , Placeholder: \"Meeting Password (numeric)\"\n , Title: \"Meeting Password\"\n , Text: text\n , SubmitText: \"Next\"\n , FeedbackId: DIALPAD_PASSWORD\n } ).catch((error) => { console.error(error); });\n}", "function reset() {\n password = \"\";\n charactersToUse = \"\";\n lengthofPW = 0;\n\n\n\n}", "function onReset() {\n\tdocument.getElementById('username').value = \"\";\n\tdocument.getElementById('password').value = \"\";\n\tdocument.getElementById('email').value = \"\";\n\tdocument.getElementById('result').innerHTML = \"\";\n\tflagUsername = false;\n\tflagPassword = false;\n\tflagEmail = false;\n}", "function handleRecoverPassword(){\n if(emailValid()){\n console.log(`send me my password to: ${email}`)\n setEmail('')\n }else{\n console.log('invalid')\n }\n }", "function toggleResetPswd(e){\n e.preventDefault();\n $('#logreg-forms .form-signin').toggle() // display:block or none\n $('#logreg-forms .form-reset').toggle() // display:block or none\n}", "function checkPassword(form) {\r\n if (form.passwordForm.value == \"\") {\r\n document.getElementById(\"noPassword\").style.display = 'inline-block';\r\n return false;\r\n } else {\r\n return true;\r\n }\r\n}", "function forgotPassword() { \n\n\t\t\t$( \"#load\" ).show();\n\t\t\t\n\t\t\tvar form = new FormData(document.getElementById('reset_form'));\n\t\t\t\n\t\t\tvar validate_url = $('#reset_form').attr('action');\n\t\t\t\n\t\t\t$.ajax({\n\t\t\t\ttype: \"POST\",\n\t\t\t\turl: validate_url,\n\t\t\t\t//data: dataString,\n\t\t\t\tdata: form,\n\t\t\t\t//dataType: \"json\",\n\t\t\t\tcache : false,\n\t\t\t\tcontentType: false,\n\t\t\t\tprocessData: false,\n\t\t\t\tsuccess: function(data){\n\n\t\t\t\t\t\n\t\t\t\t\tif(data.success == true ){\n\t\t\t\t\t\t\n\t\t\t\t\t\t$( \"#load\" ).hide();\n\t\t\t\t\t\t$(\"input\").val('');\n\t\t\t\t\t\t\n\t\t\t\t\t\t$(\".forgot-password-box\").html(data.notif);\n\t\n\t\t\t\t\t\tsetTimeout(function() { \n\t\t\t\t\t\t\t//$(\"#notif\").slideUp({ opacity: \"hide\" }, \"slow\");\n\t\t\t\t\t\t\t//window.location.reload(true);\n\t\t\t\t\t\t}, 2000); \n\n\t\t\t\t\t}else if(data.success == false){\n\t\t\t\t\t\t$( \"#load\" ).hide();\n\t\t\t\t\t\t$(\"#notif\").html(data.notif);\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t},error: function(xhr, status, error) {\n\t\t\t\t\t$( \"#load\" ).hide();\n\t\t\t\t},\n\t\t\t});\n\t\t\treturn false;\n\t\t}", "function postResetPassword() {\n const validatePasswords = validatePasswordMatch(password, confirmPassword);\n if (validatePasswords !== true) {\n setSubmitResult(validatePasswords);\n setIsError(true);\n return;\n }\n setIsLoading(true);\n setIsError(false);\n axios.post(process.env.REACT_APP_API_LINK + \"/password/reset\", {\n \"email\": data.email,\n token,\n password\n }).then(result => {\n setIsLoading(false);\n if (result.status === 200) {\n setIsSuccess(true);\n data.onCloseModal();\n alert(\"Password Reset Successful!\")\n } else {\n setSubmitResult(\"An error has occurred, please contact an administrator.\")\n setIsError(true);\n }\n }).catch(e => {\n setIsLoading(false);\n setSubmitResult(e.response.data.error);\n setIsError(true);\n });\n }", "function resetPasswordSuccess() {\n // check if reset password form was successfully submited\n if (!$('.reset-password-success').length) {\n return;\n }\n\n // show success message\n $('#ResetSuccess').removeClass('hide');\n }", "function ChangePassword() {\n\t}", "function showPassword() {\n let button = document.getElementById('show-button');\n let password_field = document.getElementById('passwd');\n\n // If currently showing the password\n if (password_field.type == 'text') {\n password_field.type = 'password';\n button.innerHTML = 'Show';\n }\n else {\n password_field.type = 'text';\n button.innerHTML = 'Hide';\n }\n}", "recoverPassword({ Bert }, { email }) {\n // Call forgot password procedure\n Accounts.forgotPassword({\n email,\n }, (error) => {\n if (error) {\n Bert.alert(error.reason, 'warning');\n } else {\n Bert.alert('Check your inbox for a reset link!', 'success');\n }\n });\n }", "function pwEvent() {\r\n if (validPW()) {\r\n $password.next().hide(); //next searches through immediate following siblings\r\n } else {\r\n $password.next().show();\r\n }\r\n}", "function resetPassword() {\n\t\t\tif (vm.newPassword != \"\" && vm.newPassword == vm.confirmPassword) {\n\t\t\t\tvm.waiting = true;\n\t\t\t\tserver.resetPassword($stateParams.token, vm.newPassword).then(function(res) {\n\t\t\t\t\tvm.success = 1;\n\t\t\t\t\tvm.waiting = false;\n\t\t\t\t\t$rootScope.$broadcast('loading', false); // TODO (HACK)\n\t\t\t\t}, function(res) {\n\t\t\t\t\tvm.success = 0;\n\t\t\t\t\tvm.waiting = false;\n\t\t\t\t\t$rootScope.$broadcast('loading', false); // TODO (HACK)\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tgui.alertError(\"Passwords do not match.\");\n\t\t\t}\n\t\t}", "function reset() { \n passwordLength = 0;\n specialCharacters = false;\n numbers = false;\n uppercase = false;\n lowercase = false;\n validInput = false;\n }", "function showpassword() {\n\tvar x = document.getElementsByName(\"pass\");\n\tfor (var i = 0; i <= x.length; i++) {\n\t\tif (x[i].type === \"password\") {\n\t\t\tx[i].type = \"text\";\n\t\t} else {\n\t\t\tx[i].type = \"password\";\n\t\t}\n\t}\n}", "function forgotPassword(method,type) {\n hideError('email');\n addFunActionLabel=\"Forgot Pasword Submit\";\n if(pageType=='not_login'){\n var email = $.trim($(\"#TenTimes-Modal #userEmailCopy\").val()); \n }else{\n var email = $.trim($(\"#TenTimes-Modal #userEmail\").val());\n }\n if(!validateEmail12345(email)){\n $(\".alert_email\").show();\n return 0;\n }\n var otpType='password';\n if(type=='N' || type=='U'){\n otpType='otp';\n }\n\n if(method == \"connect\")\n var postData = {'email':email, 'name' : receiverData.name , 'type' : otpType }\n else\n var postData = {'email':email, 'name' : email , 'type' : otpType }\n showloading();\n $.post(site_url_attend+'/user/getpassword',postData,function(response){\n hideloading();\n response=$.parseJSON(response);\n var resText=response.resText;\n var resLink=response.resLink;\n if(type=='N' || type=='U'){\n resText=response.resText_typeN;\n resLink=response.resLink_typeN;\n \n }\n \n switch(response.response) {\n case 'true':\n $('#getpassword').parent().replaceWith(function() { return \"<a style='text-decoration:none'>\" + \"<p class='text-center' style='text-decoration:none;color:#909090;'>\" + resText + \"</p>\"+$('#getpassword').get(0).outerHTML+\"</a>\"; });\n\n $('#getpassword').text(resLink);\n if(method!='signup' && method!='connect' && method!='contact_organizer_venue'){\n $('#TenTimes-Modal .partial-log').hide();\n $('#getpassword').removeAttr(\"onclick\").click(function() {\n partialLog(method,type)\n }).text(resLink).css('color','#335aa1');\n }\n break;\n case 'false':\n $(\".alert_email\").html(\"Sorry, 10times doesn't recognize that email.\");\n $(\".alert_email\").show();\n break;\n }\n }); \n}", "function getForgotPasswordUI() {\n fetch('/api/forgotPassword', {\n method: 'GET'\n }).then(response => response.text())\n .then(res => {\n var mainBody = document.getElementById('main-body');\n mainBody.innerHTML = res;\n selectIcon('home');\n });\n}", "function resetPassword(e) {\n e.preventDefault();\n\n axios\n .put(`${defaults.serverUrl}/account/change-credentials/${accountID}`, {\n security: questions,\n newPW: password,\n })\n .then((res) => {\n localStorage.setItem(\"token\", res.data);\n alert(\"Your password has been changed! Logging you in...\");\n router.push(\"/\");\n })\n .catch(() => {\n alert(\n \"Could not reset password! You likely had the wrong answers to the security questions\"\n );\n });\n }", "function vpb_request_password_link()\n{\n\tvar ue_data = $(\"#ue_data\").val();\n\t\n\tif(ue_data == \"\")\n\t{\n\t\t$(\"#ue_data\").focus();\n\t\t$(\"#this_page_errors\").html('<div class=\"vwarning\">'+$(\"#empty_username_field\").val()+'</div>');\n\t\t$('html, body').animate({\n\t\t\tscrollTop: $('#ue_data').offset().top-parseInt(200)+'px'\n\t\t}, 1600);\n\t\treturn false;\n\t} else {\n\t\tvar dataString = {'ue_data': ue_data, 'page':'reset-password-validation'};\n\t\t$.ajax({\n\t\t\ttype: \"POST\",\n\t\t\turl: vpb_site_url+'forget-password',\n\t\t\tdata: dataString,\n\t\t\tcache: false,\n\t\t\tbeforeSend: function() \n\t\t\t{\n\t\t\t\t$(\"#this_page_errors\").html('');\n\t\t\t\t$(\"#disable_or_enable_this_box\").removeClass('enable_this_box');\n\t\t\t\t$(\"#disable_or_enable_this_box\").addClass('disable_this_box');\n\t\t\t\t\n\t\t\t\t$(\"#forgot_password_buttoned\").hide();\n\t\t\t\t$(\"#log_in_status\").html('<center><div align=\"center\"><img style=\"margin-top:-40px;\" src=\"'+vpb_site_url+'img/loadings.gif\" align=\"absmiddle\" alt=\"Loading\" /></div></center>');\n\t\t\t},\n\t\t\tsuccess: function(response)\n\t\t\t{\n\t\t\t\t$(\"#disable_or_enable_this_box\").removeClass('disable_this_box');\n\t\t\t\t$(\"#disable_or_enable_this_box\").addClass('enable_this_box');\n\t\t\n\t\t\t\t$(\"#log_in_status\").html('');\n\t\t\t\t$(\"#forgot_password_buttoned\").show();\n\t\t\t\t\t\n\t\t\t\tvar response_brought = response.indexOf(\"processCompletedStatus\");\n\t\t\t\t$vlog=JSON.parse(response);\n\t\t\t\tif(response_brought != -1)\n\t\t\t\t{\n\t\t\t\t\tif($vlog.processCompletedStatus==true){\n $(\"#ue_data\").val('');\n $(\"#this_page_errors\").html($vlog.response);\n return false;\n\t\t\t\t\t}else{\n setTimeout(function() {\n \twindow.alert(\"To change the password you first need to verify the account by entering the verification code which was sent to your gmail account earlier while sign up in the 'Enter the verification code ... ' field to proceed.\");\n window.location.replace(vpb_site_url+'verification');\n },500);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$(\"#this_page_errors\").html($vlog.response);\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t}\n}", "function getPassword() {\n if (hasTextEncoder) {\n document.getElementById('create_button').style.display = 'none';\n document.getElementById('passphrase').style.display = 'block';\n }\n else {\n setupKeys();\n }\n}", "async passwordreset({ commit, dispatch }, form) {\n form.busy = true;\n try {\n await App.post(route(\"api.auth.reset-password\"), form).then(() => {\n commit(\"isAuthenticated\", {\n isAuthenticated: vm.$auth.check()\n });\n form.busy = false;\n });\n await dispatch(\"fetchMe\");\n } catch ({ errors, message }) {\n form.errors.set(errors);\n form.busy = false;\n }\n }", "function showPasswordFn() {\n\tinputPassword.type = 'text';\n\twhile (hidePassword.classList.contains('hidePassword')) {\n\t\thidePassword.classList.remove('hidePassword');\n\t}\n\tshowPassword.classList.add('showPassword');\n}", "function showPassword(el)\n{\n var input = document.createElement('input');\n input.id = el.id;\n input.name = el.name;\n input.value = el.value;\n input.className = el.className;\n if (el.type == 'text' )\n { input.type = 'password'; }\n else\n { input.type = 'text'; }\n el.parentNode.replaceChild(input, el);\n}", "async forgotpasswordbtn () {\n await (await this.btnForgotPassword).click();\n }", "function recoverPassword() {\n const email = document.getElementsByName(\"recover-email\").item(0);\n xhttp(\"POST\", \"forgot.php\", { email: email.value }, (response) => {\n // do nothing if it works or if it fails\n });\n const loginpage = document.getElementById(\"main\").querySelector(\"div.loginpage\");\n loginpage.innerHTML += '<p class=\"warn\">If the email is in our database, an email will be sent shortly to recover your account</p>';\n return false;\n}", "renderConfirmationForm() {\n return (\n <form>\n <FormGroup controlId=\"confirmationCode\" bsSize=\"large\">\n <ControlLabel>Confirm your identity via your email address</ControlLabel>\n <HelpBlock>Please check your email for the verification link.</HelpBlock>\n </FormGroup>\n\n </form>\n );\n }", "renderSuccess () {\n this.response.render('auth/password-changed', {\n title: 'Password Changed', returnToUrl: this.returnToUrl\n })\n }", "function confirmPasswordReset (e) {\n e.preventDefault();\n showConfirmation(\"Are you sure you want to reset your password?\").then(function (confirmed) {\n if (confirmed) {\n sendResetPasswordEmail().then(function () {\n $(e.target).parent().html('Password Reset Email Sent.');\n });\n }\n }).catch(function (error) {\n showError(\"Response Error\", error);\n });\n}", "function showRegister() {\n clearErrorMsg();\n showLinks(['loginLink']);\n showView('registerForm');\n}", "function ForgetPasswd(){\n $('#fopasswordModel').modal();\n $('#fopasswordModel').on('shown.bs.modal',function() {\n $('#fopasswordForm').formValidation('resetForm', true);\n });\n}", "function mdm_noecho(message) {\t\n\tmdm_enable();\t\t\n\t// message;\t\n\tdocument.getElementById(\"label\").innerHTML = 'pass';\n\tdocument.getElementById(\"entry\").value = \"\";\n\tdocument.getElementById(\"entry\").type = \"password\";\n\tdocument.getElementById(\"entry\").focus();\n}", "resetPasswordInit(email) {\n return this.afAuth.auth.sendPasswordResetEmail(email, { url: 'https://coincoininsolite-1cf37.firebaseapp.com/__/auth/action' });\n }", "function fnc_cancelar_cambiar_password() {\n\topen_form('/Home/frm_main', gc_group_window);\n}", "async function requestResetPassword(formData) {\n const headers = {};\n attach_headers([HEADERS.CSRF], headers);\n const body = { user: formData };\n\n cleanupAuthState();\n dispatch({ type: LOADING_STARTED });\n const resp = await supervise_rq(() =>\n axios.post(API_PATHS.AUTH_UPDATE_PASSWORD, body, { headers })\n );\n\n if (resp.status === STATUS.SUCCESS) {\n dispatch({\n type: AUTH_ACTIONS.AUTH_REQUEST_RESET_PASSWORD,\n payload:\n \"If an account for the provided email exists, an email with reset instructions will be sent to you. Please check your inbox.\",\n });\n } else {\n dispatch({\n type: AUTH_ACTIONS.AUTH_ERROR,\n payload: \"Oops, something went wrong. Pleas try again later.\",\n });\n }\n }", "function initReset() {\n\tnew JsNameFilter(\"userId\", \"nameInput\", window['g_basePath']);\n\t\n\tif ($(\"successM\").value != '') {\n\t\tMsgBox.message('重置密码成功');\n\t}\n\t\n\t$(\"successM\").value = '';\n\taddCustomCheck('reNewPW', getMessage('js.com.warning.0012'), 'mustsame', function(value) {\n\t\tif (value != $F('newPW')) return false;\n\t\treturn true;\n\t});\n}", "resetFields() {\n this.passwordField.nextElementSibling.innerHTML = Config.EMPTY_STRING;\n this.passwordField.value = Config.EMPTY_STRING;\n }", "function reset() {\n // Flag it to prevent double clicking, and visually communicate\n if ($scope.isSubmitting) {\n return;\n }\n\n $scope.isSubmitting = true;\n\n // Lets try to reset their password\n visitorApiService.resetPassword({\n key: $scope.key,\n password: $scope.visitor.password\n })\n .$promise.then(function(response) {\n // Unlock the submit button\n $scope.isSubmitting = false;\n\n if (response.error === null) {\n return response.result; // email\n } else {\n // Most common error is an expired key\n $scope.message = commonUtilService.getMessage(response);\n return $q.reject();\n }\n })\n .then(function(email) {\n\n // Log them in now\n return visitorApiService.login({\n email: email,\n password: $scope.visitor.password\n })\n .$promise.then(function(response) {\n if (response.error !== null) {\n $scope.message = commonUtilService.getMessage(response);\n return $q.reject();\n }\n });\n })\n .then(function() {\n // Request customer info\n return visitorLoginService.isLoggedIn(true);\n })\n .then(function() {\n // Get their cart info\n cartService.reload();\n })\n .then(function() {\n // Redirect them to their last page\n var path = angular.module(\"visitorModule\").back.path || '/account';\n $location.path(path);\n });\n\n }", "createPasswordResetLink(token, user_id) {\n\t\treturn `${SiteUrl}/auth/password-reset/${token}/${user_id}`;\n\t}", "function forgotPasswordSelected(){\n\t\tformLogin.removeClass('is-selected');\n\t\tformSignup.removeClass('is-selected');\n\t\tformEnterDetailsOTP.removeClass('is-selected');\n formForgotPasswordDetailsSignup.removeClass('is-selected');\n\t formEnterLoginDetailsToSignUp.removeClass('is-selected');\n\t\tformForgotPassword.addClass('is-selected');\n $('.cd-switcher').find('.selected').html(\"Forgot Password\");\n\n\t}", "function forget_password(){\r\n localStorage.setItem(\"time\",\"1000\");\r\n localStorage.setItem(\"link\",\"password_reset.html\");\r\n window.open('loading.html',\"_self\");\r\n }", "function togglePassword(obj, e) {\n\t\t\t\t//alert($(obj).html());\n\t\t\t\te.preventDefault();\n\t\t\t\t\n\t\t\t\t//var upass = document.getElementsByClassName('upass');\n\t\t\t\tvar field = $(obj).parent().parent().find(\".togglePassword\");\n\t\t\t\tvar type = field.attr('type');\n\t\t\t\t\n\t\t\t\t//alert('Type: '+type+'; Val: '+field.val());\n\t\t\t\t\n\t\t\t\tif(type == \"password\"){\n\t\t\t\t\t//field.type = \"text\";\n\t\t\t\t\tfield.attr('type', 'text');\n\t\t\t\t\t$(obj).html(\"Hide\");\n\t\t\t\t} else {\n\t\t\t\t\t//field.type = \"password\";\n\t\t\t\t\t$(obj).html(\"Show\");\n\t\t\t\t\tfield.attr('type', 'password');\n\t\t\t\t}\n\t\t\t}", "function showChangePassword(){\n resetSettingsForms();\n\n $('delete_account_btn').removeClassName('selected'); // remove clicked effect from delete account button\n $('delete_account').hide(); // hide delete account view\n\n $('change_password_btn').addClassName('selected'); // add clicked effect to change password button\n $('change_password').show(); // show change password view\n}", "passwordreset(email) {\r\n return this.auth\r\n .sendPasswordResetEmail(email)\r\n .then(function () {\r\n alert(\"Email Sent!\");\r\n })\r\n .catch(function (error) {\r\n alert(\"An error occured. Please try again\");\r\n });\r\n }", "function resALert() {\n alert(\"The form has been reset. Please try again.\");\n}", "function showPaswrd() {\r\n const paswrd = document.getElementById('paswrd');\r\n if (paswrd.type === 'password') {\r\n paswrd.type = 'text';\r\n } else {\r\n paswrd.type = 'password';\r\n }\r\n}", "function checkforgotpassword()\r\n\t{\r\n\t\tif(document.forgot.email.value==\"\")\r\n\t\t{\r\n\t\t\talert(lng_plsenteremailadd);\r\n\t\t\tdocument.forgot.email.focus();\r\n\t\t\tdocument.forgot.email.select();\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\tif(!validate_email_forgot(document.forgot.email.value,lng_entervalidemail))\r\n\t\t\t\t{\r\n\t\t\t\t\tdocument.forgot.email.select();\r\n\t\t\t\t\treturn false;\r\n\t\t\t\t}\r\n\t\t}\r\n\t}", "resetPassword(actionCode, newPassword) {\n var accountEmail;\n let thisComponent = this;\n // Verify the password reset code is valid.\n auth.verifyPasswordResetCode(actionCode).then(function(email) {\n var accountEmail = email;\n \n // TODO: Show the reset screen with the user's email and ask the user for\n // the new password.\n \n // Save the new password.\n auth.confirmPasswordReset(actionCode, newPassword).then(function(resp) {\n // Password reset has been confirmed and new password updated.\n \n // TODO: Display a link back to the app, or sign-in the user directly\n // if the page belongs to the same domain as the app:\n // auth.signInWithEmailAndPassword(accountEmail, newPassword);\n \n // TODO: If a continue URL is available, display a button which on\n // click redirects the user back to the app via continueUrl with\n // additional state determined from that URL's parameters.\n }).catch(function(error) {\n // Error occurred during confirmation. The code might have expired or the\n // password is too weak.\n });\n }).catch(function(error) {\n // Invalid or expired action code. Ask user to try to reset the password\n // again.\n }).then(function() {\n thisComponent.props.history.push('/signin'); // redirect to home page\n });\n }", "function getPassowrd() {\n let eyeIconShow = document.getElementById('eye-icon-slash-1');\n eyeIconShow.style.display = 'block';\n eyeIconShow.classList = 'fas fa-eye';\n\n let changeType = document.getElementById('singup-pass');\n changeType.type = 'text';\n\n let chars = '0123456789qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM!@#$%^&*()_+=-[]{}><:';\n let password = '';\n\n for (let i = 0; i < 12; i++) {\n let r = Math.floor(Math.random() * chars.length);\n password += chars[r];\n }\n document.getElementById('singup-pass').value = password;\n}", "function handlePasswordReset(req, res) {\n csrf.verify(req);\n\n if (!verifyReferrer(req, '/account/passwordreset')) {\n res.status(403).send('Mismatched referrer');\n return;\n }\n\n var name = req.body.name,\n email = req.body.email;\n\n if (typeof name !== \"string\" || typeof email !== \"string\") {\n res.send(400);\n return;\n }\n\n if (!$util.isValidUserName(name)) {\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: \"\",\n resetErr: \"Invalid username '\" + name + \"'\"\n });\n return;\n }\n\n db.users.getEmail(name, function (err, actualEmail) {\n if (err) {\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: \"\",\n resetErr: err\n });\n return;\n }\n\n if (actualEmail === '') {\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: \"\",\n resetErr: `Username ${name} cannot be recovered because it ` +\n \"doesn't have an email address associated with it.\"\n });\n return;\n } else if (actualEmail.toLowerCase() !== email.trim().toLowerCase()) {\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: \"\",\n resetErr: \"Provided email does not match the email address on record for \" + name\n });\n return;\n }\n\n crypto.randomBytes(20, (err, bytes) => {\n if (err) {\n LOGGER.error(\n 'Could not generate random bytes for password reset: %s',\n err.stack\n );\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: email,\n resetErr: \"Internal error when generating password reset\"\n });\n return;\n }\n\n var hash = bytes.toString('hex');\n // 24-hour expiration\n var expire = Date.now() + 86400000;\n var ip = req.realIP;\n\n db.addPasswordReset({\n ip: ip,\n name: name,\n email: actualEmail,\n hash: hash,\n expire: expire\n }, function (err, _dbres) {\n if (err) {\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: \"\",\n resetErr: err\n });\n return;\n }\n\n Logger.eventlog.log(\"[account] \" + ip + \" requested password recovery for \" +\n name + \" <\" + email + \">\");\n\n if (!emailConfig.getPasswordReset().isEnabled()) {\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: email,\n resetErr: \"This server does not have mail support enabled. Please \" +\n \"contact an administrator for assistance.\"\n });\n return;\n }\n\n const baseUrl = `${req.realProtocol}://${req.header(\"host\")}`;\n\n emailController.sendPasswordReset({\n username: name,\n address: email,\n url: `${baseUrl}/account/passwordrecover/${hash}`\n }).then(_result => {\n sendPug(res, \"account-passwordreset\", {\n reset: true,\n resetEmail: email,\n resetErr: false\n });\n }).catch(error => {\n LOGGER.error(\"Sending password reset email failed: %s\", error);\n sendPug(res, \"account-passwordreset\", {\n reset: false,\n resetEmail: email,\n resetErr: \"Sending reset email failed. Please contact an \" +\n \"administrator for assistance.\"\n });\n });\n });\n });\n });\n}", "function hidePasswordInput() {\n\n // Retrieve all password elements.\n var passwordInputForm = document.getElementById(\"passwordInputForm\");\n var passwordInputLabel = document.getElementById(\"passwordInputLabel\");\n\n passwordInputLabel.innerHTML = \"\";\n passwordInputForm.className = \"item hide\";\n passwordSubmitButton.className = \"item hide\";\n }", "function tooglePasswordFields(status, formPassword, formConfirmPassword) {\n if (status == USER_STATUS_ENABLED) {\n showElemById(formPassword);\n showElemById(formConfirmPassword);\n } else {\n hideElemById(formPassword);\n hideElemById(formConfirmPassword);\n }\n}", "function processResetPasswordReturn (data, $message) {\n\n if (data.result === \"No\") {\n // If result returned no then something went wrong so build and display an\n // error message\n\n // Build HTML for error message\n var result = [\n '<div class=\"alert alert-danger alert-dismissable\">',\n '<button type=\"button\"',\n ' class=\"close\"',\n ' data-dismiss=\"alert\"',\n ' aria-hidden=\"true\">&times;</button>',\n '<h4>Reset Password Error</h4>',\n data.message,\n '</div>'];\n\n // Output error message\n $message.html(result.join(''));\n\n } else {\n\n // Build HTML for success message\n var result = [\n '<div class=\"alert alert-success alert-dismissable\">',\n '<button type=\"button\"',\n ' class=\"close\"',\n ' data-dismiss=\"alert\"',\n ' aria-hidden=\"true\">&times;</button>',\n 'Password successfully reset!',\n '</div>'];\n\n // Output error message\n $message.html(result.join(''));\n\n }\n\n}", "function passwordsMismatched() {\n document.getElementById(\"passwordP\").style.display = \"visible\";\n}", "_showPassword() {\n const that = this;\n\n if (that.disabled || !that.showPasswordIcon) {\n return;\n }\n\n that.$.input.type = 'text';\n that._passwordIconPressed = true;\n }", "function hideIt(password) {\n return ''\n}", "function showRegistrationPassword() \r\n{\r\n var x = document.getElementById(\"registerPassword\");\r\n\r\n if (x.type === \"password\") \r\n x.type = \"text\";\r\n else \r\n x.type = \"password\";\r\n}", "function changePassword() {\n $rootScope.pwdModalTitle = '修改密码';\n $rootScope.pwdModal = $modal({\n scope: $rootScope,\n templateUrl: 'partials/modal.changePassword.html?' + new Date().getTime(),\n show: true,\n backdrop: false\n });\n }", "function passDetails(){\n document.getElementById('vehicleRegistrationForm').style.display =\"none\";\n messageField.innerHTML = \"Choose Pass\";\n document.getElementById(\"passForm\").style.display=\"block\";\n document.getElementById(\"getPass\").style.display=\"block\";\n inputField = \"passChoice\";\n}" ]
[ "0.72689563", "0.6889321", "0.6628089", "0.6615192", "0.6602431", "0.6446871", "0.6413607", "0.640247", "0.64002264", "0.639404", "0.6392925", "0.631702", "0.63133293", "0.63121516", "0.62927014", "0.627489", "0.62289125", "0.6220985", "0.61990076", "0.619573", "0.61789095", "0.6148002", "0.6128637", "0.61240256", "0.6122078", "0.6034439", "0.6032202", "0.6027266", "0.60126626", "0.5989828", "0.59707737", "0.5963679", "0.5963679", "0.5951717", "0.59448606", "0.59330815", "0.59075534", "0.58955306", "0.5882358", "0.58790255", "0.5871278", "0.58698654", "0.5865065", "0.58547014", "0.5853642", "0.585276", "0.5840983", "0.5834779", "0.583061", "0.58256394", "0.5811887", "0.5810058", "0.58070636", "0.5787056", "0.5786708", "0.5784965", "0.5779948", "0.5777264", "0.5770158", "0.57461965", "0.5740242", "0.57386273", "0.5736712", "0.57220066", "0.5721807", "0.5719256", "0.5716655", "0.5702047", "0.56922007", "0.56855774", "0.56792545", "0.56738096", "0.56721306", "0.5671236", "0.56707364", "0.5656456", "0.56539816", "0.56521523", "0.5640937", "0.563356", "0.5629652", "0.5627869", "0.5627693", "0.56258714", "0.56250703", "0.56248766", "0.56152004", "0.56093585", "0.5608366", "0.5600173", "0.5597817", "0.559691", "0.55940914", "0.5591649", "0.55825377", "0.55785304", "0.5577073", "0.5575511", "0.5563621", "0.55579245" ]
0.6168462
21
fetch weather data from openweathermap api needs auth
async function getWeatherReport() { const apiKey = "6e27a113797392f6dee5a23a3d7cc5ef"; const cityName = "London"; const response = await fetch( `http://api.openweathermap.org/data/2.5/weather?q=${cityName},uk&APPID=${apiKey}` ); const myJson = await response.json(); const temperature = myJson.weather; console.log(temperature); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getWeather(data){\n var api_key = '6996386e46f031703c26cea51cac9e6e';\n var url = `https://cors-anywhere.herokuapp.com/http://api.openweathermap.org/data/2.5/weather?units=imperial&APPID=${api_key}&${data}`;\n\n fetch(url).then(response => response.json()).then(json_response => displayWeather(json_response));\n}", "async getWeather() { \n\t\tconst response = await fetch(`https://api.openweathermap.org/data/2.5/weather?q=${this.city},${this.zipcode}&APPID=9d0317c32366d083e6e35b438595476c&units=imperial`);\n\t\tconst responseData = response.json();\n\t\treturn responseData;\n\t}", "async getWeather() {\n const response = await fetch(`http;//api.openweathermap.org/data/2.5/weather?${}`);\n }", "async getWeather() {\t\n\t\tconst response = await fetch(\n\t\t\t`https://api.openweathermap.org/data/2.5/weather?q=${this.city},${this.state},US&units=imperial&mode=json&appid=${this.apiKey}`\n\t\t);\t\n\n\t\tconst responseData = await response.json();\n\n\t\treturn responseData;\n\t}", "async getWeather(){\n const response = await fetch(`https://api.openweathermap.org/data/2.5/weather?q=${this.location}&units=metric&appid=${this.apikey}`);\n\n const responseData = await response.json();\n\n return responseData;\n }", "async getWeather() {\n const response = await fetch(\n `https://api.openweathermap.org/data/2.5/weather?q=${this.city},${this.country}&units=metric&APPID=${this.apiKey}`\n );\n\n const responseData = await response.json();\n\n return responseData;\n }", "async getWeather() {\n const response = await fetch(`http://cors-anywhere.herokuapp.com/https://api.darksky.net/forecast/${this.key}/${this.latitude},${this.longitude}`)\n const result = await response.json();\n\n const ocd = await fetch(`https://api.opencagedata.com/geocode/v1/json?key=${this.ocdkey}&q=${this.latitude}%2C${this.longitude}&language=en`)\n const ocdResult = await ocd.json();\n\n return {\n result,\n ocdResult,\n }\n }", "async getWeather(){\n const response = await fetch(`http://api.openweathermap.org/data/2.5/weather?q=${this.city},${this.state},us&appid=${this.apikey}`);\n\n const responseJSON = await response.json();\n return responseJSON;\n }", "function getWeatherData() {\n\n var url = 'http://api.openweathermap.org/data/2.5/weather?lat=' + latitude + '&lon=' + // build query url.\n longitude + '&APPID=936e860c72edb8cb527707e7d59da1ea' +\n '&units=' + countryUnits + '&preventCache=' + new Date(); // build query url\n\n $.getJSON(url, null, function(json, textStatus) {\n\n console.log(\"weather info \" + JSON.stringify(json) + \"response Satus is \" + textStatus);\n processresponse(json);\n\n });\n }", "async getWeather() {\n const response = await fetch(`https://api.openweathermap.org/data/2.5/weather?q=${this.city},${this.state}&units=imperial&appid=${this.apiKey}`)\n\n const responseData = await response.json();\n\n return responseData\n }", "async getWeather() {\n const response = await fetch(`https://api.openweathermap.org/data/2.5/weather?q=${this._city},${this._state}&appid=${this._apiKey}&units=metric`)\n\n const responseData = await response.json();\n\n return responseData; //todo !!!\n }", "function getWeather(city) {\n fetch(\"https://api.openweathermap.org/data/2.5/weather?q=\"\n + city \n +\"&units=metric&appid=\"+api_key+\"\")\n .then( (response) => response.json())\n .then((data) => displayWeather(data)); \n \n}", "async getWeather() {\r\n const weatherRespone = await fetch(`https://api.openweathermap.org/data/2.5/weather?q=${this.city}&appid=${this.apiKey}&units=metric`);\r\n const weather = await weatherRespone.json();\r\n\r\n return {\r\n weather\r\n };\r\n\r\n }", "async getWeather() {\n const response = await fetch(`https://api.openweathermap.org/data/2.5/weather?q=${this.city},${this.countryCode}&appid=${this.apiKey}`);\n\n const responseData = await response.json();\n\n return responseData;\n }", "static async getWeather() {\n try {\n let pos = await Weather.getGeoData();\n const response = await fetch(`https://api.openweathermap.org/data/2.5/onecall?lat=${pos.lat}&lon=${pos.lon}&exclude=hourly,minutely,alerts&units=metric&appid=${APIKey}`);\n const data = await response.json();\n\t\t\tlet result = data.daily.slice(0,8)\n\t\t\treturn result;\n } catch(err) {\n console.log(err);\n }\n }", "function fetchWeatherInfo(city) {\n let url = \"http://api.openweathermap.org/data/2.5/weather?q=\";\n url += city + \"&appid=\" + APIKey;\n // console.log(\"url is\", url);\n return fetch(url).then(response => response.json());\n}", "async getWeather(){\n // narrow response info to make it faster\n const exclude = '?exclude=minutely,hourly,daily,alerts,flags';\n const response = await fetch(`https://api.darksky.net/forecast/${this.apiKeyDS}/${this.lat},${this.lon}${exclude}`);\n const responseData = await response.json();\n return responseData;\n }", "function getWeather() {\n return fetch(\"https://api.openweathermap.org/data/2.5/weather?q=barcelona&units=metric&appid=644a219f426a3224328405aa28d80b8f\").then(function (res) { return res.json(); })\n .then(function (res) {\n return res;\n });\n}", "function getWeatherInfo(city) {\n\n const apiKey = \" \"; //weather API key\n\n fetch(\"https://api.openweathermap.org/data/2.5/weather?q=\" + city + \",&appid=\" + apiKey)\n .then(response => response.json())\n //.then(response => console.log(response));\n .then(response => displyWeatherInfo(response));\n\n }", "function getWeatherInfo () {\n\n const long = App.city.longitude;\n const lat = App.city.latitude;\n const url = \"https://api.darksky.net/forecast/8877941a6145fd159c584b8f95b52bb9/\" + lat + \",\" + long + \"?callback=?\";\n\n $.ajax({\n url: url,\n dataType: \"jsonp\",\n success: function (json) {\n App.weatherForecast = json;\n }\n }).done(function () {\n updateWeatherInfo(App.weatherForecast);\n });\n\n }", "async getGeoWeather() {\n\t\tconst geoResponse = await fetch(\n\t\t\t`https://api.opencagedata.com/geocode/v1/json?q=${this.lat}+${this.long}&key=${this.geoApiKey}`\n\t\t);\n\t\n\t\t// Convert longtitude latitude to city state\n\t\tconst geoResponseData = await geoResponse.json();\n\n\t\tlet city = geoResponseData.results[0].components.city;\n\t\tlet state = geoResponseData.results[0].components.state_code;\n\n\t\t// Pass city state to API to get current weather data\n\t\tconst response = await fetch(\n\t\t\t`https://api.openweathermap.org/data/2.5/weather?q=${city},${state},US&units=imperial&mode=json&appid=${this.apiKey}`\n\t\t);\n\n\t\tconst responseData = await response.json();\n\n \treturn responseData;\n\t}", "async function getAllWeatherData() {\n let weatherData = await getLocationWeather(\n `https://api.openweathermap.org/data/2.5/weather?q=${input}&APPID=${API}`\n );\n\n try {\n // Extract data needed for fetching forecast data.\n let testLat = weatherData.coord.lat;\n let testLon = weatherData.coord.lon;\n\n let response = await fetch(\n `https://api.openweathermap.org/data/2.5/onecall?lat=${testLat}&lon=${testLon}&exclude=minutely,hourly&appid=${API}`\n );\n let forecastData = await response.json();\n\n handleForecastState(forecastData);\n } catch {\n alert('Getting forecast failed.');\n }\n }", "function findWeatherDetails() {\n let searchLink =\n \"https://api.openweathermap.org/data/2.5/weather?q=copenhagen&appid=\" +\n appKey;\n httpRequestAsync(searchLink, theResponse);\n}", "async getWeather(postcode){\r\n\r\n const tempResponse = await fetch(`//api.openweathermap.org/data/2.5/weather?zip=${this.postcode},gb&units=metric&APPID=${this.apiKey}`);\r\n\r\n const responseData = await tempResponse.json();\r\n \r\n return responseData;\r\n \r\n }", "async getWeather() {\n this.requestURL = this.city;\n const weatherResponse = await fetch(this.requestURL);\n const weatherData = await weatherResponse.json();\n return weatherData\n }", "function getLocation(city) {\n // fetching current conditions\n\n var apiUrl = 'https://api.openweathermap.org/data/2.5/weather?q=' + city + '&appid=a3be7588e2f22d761077e844f13fff0c&units=imperial';\n fetch(apiUrl)\n .then(function(response) {\n if (response.ok) {\n //console.log(response);\n // JSON parse\n response.json().then(function(data) {\n console.log(data)\n getForecast(data.coord.lat, data.coord.lon)\n })\n } else {\n MaterialDialog.alert('Error: ' + response.statusText);\n }\n }).catch(function(error) {\n MaterialDialog.alert('Unable to getLocation: Invalid Connection');\n });\n}", "function getWeather(city) {\n fetch(\n `https://api.openweathermap.org/data/2.5/weather?q=${city}&units=metric&id=524901&appid=${api.key}`\n )\n .then((data) => {\n return data.json();\n })\n .then(displayWeather);\n}", "function tokyoWeather() {\n\n // use fetch to get the weather data from Tokyo\n fetch(\"https://api.openweathermap.org/data/2.5/weather?q=Tokyo,jp&units=imperial&appid=153a1ec8f6b54ec52d519c21641a079f\")\n \n .then(function(resp) { return resp.json() }) // Convert data to json\n .then(function(data) {\n displayWeather(data);\n })\n //catch errors\n .catch(function() {\n \n });\n}", "function fetchWeather(city) {\n fetch('http://api.openweathermap.org/data/2.5/weather?q='\n + city \n + '&units=metric&appid='\n + apiKey)\n .then(response => response.json())\n .then(displayData)\n .catch(error => console.error('error in server, please try again later.'))\n}", "getWeatherInfo(){\n\t\tlet url = 'https://api.openweathermap.org/data/2.5/weather?q=' + this.state.cityname + '&units=metric&appid=ce0cb4b99e8ee814c20a4f76609c8196'\n\t\tfetch(url)\n\t\t.then(response => response.json())\n\t\t.then(data => {\n\t\t\tconsole.log(data);\n\t\t\t// let tempData = JSON.stringify(data);\n \t// console.log(tempData);\n\t\t\t// alert(tempData);\n\t\t\tthis.processData(data);\t\t\t\n\t\t})\n\t\t.catch(function(error){\n\t\t\tconsole.log(error.message);\n\t\t\tthrow error.message;\n\t\t});\n\n\t\t// this.getForecast();\n\t}", "function getGeoWeather() {\n \tweather.getGeoWeather()\n\t\t.then((results) => {\n\t\t\tui.display(results);\n\t\t})\n\t\t.catch((err) => err);\n}", "async function getWeatherData() {\n getLocation();\n const URL = `http://api.openweathermap.org/data/2.5/weather?lat=${LAT}&lon=${LON}&appid=${API_KEY}`;\n const apiRES = await fetch(URL).then((res) => res.json());\n setActualTemperature(Math.ceil(apiRES.main.temp - 273.15));\n setWeatherDescription(apiRES.weather[0].description);\n setWeatherLocation(apiRES.name);\n const iconURL = `http://openweathermap.org/img/wn/${apiRES.weather[0].icon}.png`;\n setWeatherIcon(iconURL);\n }", "function GetGlobalWeather(cityname,apiuri,apitkn){\n let current = httpGet(apiuri+'weather?appid='+apitkn+'&units=metric&q='+cityname);\n console.log(current.cod);\n if(current.cod == 200){\n let city = current.name;\n let coords = current.coord;\n let daily = httpGet(apiuri+'onecall?appid='+apitkn+'&lat='+coords.lat+'&lon='+coords.lon+'&exclude=hourly,current,minutely&units=metric');\n return {'current':current,'daily':daily.daily,'city':city};\n }else{\n alert(cityname+' Not finded')\n }\n \n}", "function fetchWeather () {\n $.ajax({\n type: 'GET',\n dataType: 'jsonp',\n url: urlWeather,\n xhrFields: {\n withCredentials: false\n },\n success: weatherSuccess,\n\n error: fetchError\n });\n}", "function getWeather(zipcode) {\n // make api call and get response\n const weather = fetch(`api.openweathermap.org/data/2.5/weather?zip=${zipcode}&appid=${API_KEY}`)\n .then(res => res.json())\n .then(data => console.log(data))\n}", "function getWeather(latitude, longitude) {\n let api = `http://api.openweathermap.org/data/2.5/weather?lat=${latitude}&lon=${longitude}&appid=${key}`;\n console.log(api)\n\n fetch(api)\n .then(function (response) {\n let data = response.json();\n return data;\n })\n .then(function (data) {\n weather.city = data.name; // City name\n weather.country = data.sys.country; // Country name\n weather.iconId = data.weather[0].icon; // Icon\n weather.temperature.value = Math.floor(data.main.temp - KELVIN); // Temp\n weather.description = data.weather[0].description; // Short description\n weather.sunrise = convertTime(data.sys.sunrise); // Sunrise\n weather.sunset = convertTime(data.sys.sunset); // Sunset\n weather.wind = Math.round(data.wind.speed); // Wind speed\n weather.gust = Math.round(data.wind.gust); // Gust speed\n weather.feels_like = Math.floor(data.main.feels_like - KELVIN); // Feels-like\n weather.humidity = data.main.humidity; // Humidity \n weather.temp_min = Math.floor(data.main.temp_min - KELVIN); // Temp_min\n weather.temp_max = Math.floor(data.main.temp_max - KELVIN); // Temp_max\n })\n .then(function () {\n displayBackground();\n displayWeather();\n });\n}", "function getWeather() {\n\tlet query = \"https://api.openweathermap.org/data/2.5/weather?\" +\n\t\t\"q=\" + city + \"&units=imperial&appid=\" + OWM_API_KEY;\n\t\n\t$.ajax({\n\t\turl: query,\n\t\tmethod: \"GET\"\n\t}).done(data => {\n\t\tif (!data) return;\n\t\t\n\t\tif (data.main && data.main.temp && data.weather && data.weather.length > 0) {\n\t\t\t$('#temp').text(data.main.temp.toFixed(1) + '\\xB0' + 'F');\n\t\t\t\n\t\t\t$('#weather-main > i').remove();\n\t\t\t\n\t\t\tlet weatherData = data.weather[0];\n\t\t\t\n\t\t\tlet icon = $('<i>');\n\t\t\tlet time = weatherData.icon.endsWith('d') ? 'day-' : weatherData.icon.endsWith('n') ? 'night-' : '';\n\t\t\tlet iconClass = 'wi wi-owm-' + time + weatherData.id;\n\t\t\ticon.addClass(iconClass);\n\t\t\t$('#weather-main').prepend(icon);\n\t\t\t\n\t\t\tlet conditions = weatherData.description;\n\t\t\t$('#weather-conditions').text(titleCase(conditions));\n\t\t\t\n\t\t\t//console.log(data);\n\t\t}\n\t});\n\t\n\tquery = 'https://query.yahooapis.com/v1/public/yql?q=select * from weather.forecast where woeid in (select woeid from geo.places(1) where text=\"' + city.toLowerCase() + ', ' + state.toLowerCase() + '\")&format=json';\n\t$.ajax({\n\t\turl: query,\n\t\tmethod: \"GET\"\n\t}).done(data => {\n\t\tif (!data || !data.query || !data.query.results || !data.query.results.channel) return;\n\t\t\n\t\tconsole.log(data.query.results.channel);\n\t\t\n\t\tif (!data.query.results.channel.item || !data.query.results.channel.item.forecast) return;\n\t\t\n\t\tlet forecast = data.query.results.channel.item.forecast;\n\t\t\n\t\tif (forecast.length > 0) {\n\t\t\t$('#temp-high').text(forecast[0].high + '\\xB0' + 'F');\n\t\t\t$('#temp-low').text(forecast[0].low + '\\xB0' + 'F');\n\t\t\t\n\t\t\t$('#weather-weekly').empty();\n\t\t\tfor (let i = 1; i < 6 && i < forecast.length; i++) {\n\t\t\t\tlet col = $('<div>').addClass('col');\n\t\t\t\tlet panel = $('<div>').addClass('panel daily-forecast');\n\t\t\t\tlet dayWeather = forecast[i];\n\t\t\t\t\n\t\t\t\tpanel.append($('<p>').addClass('day').text(dayWeather.day.toUpperCase()));\n\t\t\t\tpanel.append($('<i>').addClass('wi wi-yahoo-' + dayWeather.code));\n\t\t\t\tpanel.append($('<p>').addClass('daily-high').text(dayWeather.high + '\\xB0' + 'F'));\n\t\t\t\tpanel.append($('<p>').addClass('daily-low').text(dayWeather.low + '\\xB0' + 'F'));\n\t\t\t\t\n\t\t\t\tcol.append(panel);\n\t\t\t\t$('#weather-weekly').append(col);\n\t\t\t}\n\t\t}\n\t\t\n\t});\n}", "async getWeather() {\n //Weather API\n let url = \"https://api.darksky.net/forecast/\" + API_KEY + \"/\" +\n this.state.latitutde + \",\" + this.state.longitude;\n \n //Location API\n let loc = \"https://us1.locationiq.com/v1/reverse.php?key=\" + API_LOCATION +\"&lat=\"+ this.state.latitutde +\"&lon=\"\n + this.state.longitude + \"&format=json\";\n\n\n //Get Weather Details from Weather API\n const response = await fetch(url)\n const json = await response.json();\n this.setState({ currentForecast: json.currently });\n this.setState({ hourlyForecast: json.hourly });\n this.setState({ dailyForecast: json.daily });\n\n //Get City Name from Location API\n const responseCity = await fetch(loc)\n const jsonCity = await responseCity.json();\n this.setState({locationJson: jsonCity.address});\n }", "async getWeather(){\n const response = await fetch(`http://api.apixu.com/v1/current.json?key=${this.apiKey}&q=${this.city}&r=${this.region}`);\n const resultsData = await response.json();\n //console.log(resultsData);\n return resultsData;\n \n }", "function getWeatherApi() {\n city = document.querySelector(\"#cityInput\").value;\n\n query = currentUrl + city + apiKey + \"&units=imperial\";\n\n fetch(query)\n .then((response) => response.json())\n .then((response) => {\n currentCity.textContent = response.name;\n currentTemp.textContent = \"Current Temp: \" + response.main.temp + \" F\";\n currentHumidity.textContent =\n \"Current Humidity: \" + response.main.humidity + \" %\";\n currentWindSpeed.textContent =\n \"Current Wind Speed: \" + response.wind.speed + \" MPH\";\n });\n}", "fetchWeatherData(lat,lon){\n\t\t// setting up the api key value and the longitude and latitude of the devices current location to be used in the API request\n\t\tlet rqst = \"https://api.openweathermap.org/data/2.5/weather?lat=\" + lat.toString() + \"&lon=\" + lon.toString() + \"&appid=\" + this.state.apiKey;\n console.log(\"Making API Request ...\");\n\t\t$.ajax({\n\t\t\turl: rqst,\n\t\t\tdataType: \"jsonp\",\n\t\t\tsuccess : this.parseResponse,\n\t\t\terror : function(req, err){ console.log('API call failed ' + err); }\n\t\t})\n\t}", "function getWeather(woeid) {\n fetch(`https://cors-anywhere.herokuapp.com/https://www.metaweather.com/api/location/${woeid}/`)\n .then(result => {\n // console.log(result);\n return result.json();\n })\n .then(data => {\n // console.log(data);\n const today = data.consolidated_weather[0];\n console.log(`Temperatures today in ${data.title} stay between ${today.min_temp} and ${today.max_temp}.`);\n })\n .catch(error => console.log(error));\n}", "getWeather(){\n\n\t\t// Construct the API url to call\n\t\tlet url = 'https://api.openweathermap.org/data/2.5/weather?lat=' + this.state.latitude + '&lon=' + this.state.longitude + '&units=metric&appid=ce0cb4b99e8ee814c20a4f76609c8196';\n\t\t// console.log(url);\n\n\t\t// Call the API, and set the state of the weather forecast\n\t\tfetch(url)\n\t\t.then(response => response.json())\n\t\t.then(data => {\n\t\t\tconsole.log(data);\n\t\t\t// let tempData = JSON.stringify(data);\n\t\t\t\t// console.log(tempData);\n\t\t\t// alert(tempData);\n\t\t\tthis.processData(data);\n\t\t})\n\t\t.catch(function(error){\n\t\t\tconsole.log(error.message);\n\t\t\tthrow error.message;\n\t\t });\n\n\t\t// this.getForecast();\n\t}", "async function fetchInitialWeatherDataForMy(city) {\n try {\n const response = await fetch(`https://api.openweathermap.org/data/2.5/weather?q=${city}&appid=f778724f49d8bcbf6a7c1111529b5d72`, { mode: 'cors' });\n const data = await response.json();\n return data;\n } catch (err) {\n return console.error(err);\n }\n}", "async getWeather() {\n const response = await this._getCall(`${this.#weatherApi}/weather?q=${this.city},${this.country}`);\n return await response.json();\n }", "function getCurrentWeather () {\n\n var key = \"2fd6a7c1addf009b30af95d20e54bde2\";\n var queryURL = \"https://api.openweathermap.org/data/2.5/weather?q=\" + searchCity + \"&units=imperial&appid=\" + key;\n\n $.ajax({\n url: queryURL,\n method: \"GET\"\n }).then(function(response) {\n // console.log(response);\n currentWeatherObj = response\n currentWeatherIcon = currentWeatherObj.weather[0].icon;\n // console.log(currentWeatherIcon);\n displayCurrentWeather();\n cityLongited = currentWeatherObj.coord.lon;\n cityLatitude = currentWeatherObj.coord.lat;\n getUVIndex();\n\n\n });\n}", "function getData({city, country, apiKey, unitsSys}) {\n const url = 'https://api.openweathermap.org/data/2.5/weather?';\n fetch(url + `q=${city},${country}&units=${units[unitsSys]}&appid=${apiKey}`)\n .then(response => response.json())\n .then(data => {\n console.log(data);\n makeWeatherCard({containerSelector: '.output',\n dataObj: data});\n })\n .catch((error) => {\n console.log(error);\n showErrorInfo({containerSelector: '.output',\n errorMsg: 'Oops! Something went wrong :('});\n });\n}", "function getData() {\n var APIkey = \"c19b2f1f085df13be7309df32599c301\";\n var queryURL = \"https://api.openweathermap.org/data/2.5/onecall?lat=\" + lat + \"&lon=\" + lon + \"&exclude=hourly,minutely,alerts&units=imperial&appid=\" + APIkey;\n\n $.ajax({\n url: queryURL,\n method: \"GET\"\n }).then(function(response) {\n console.log(\"--------------------\");\n console.log(\"current date is \" + response.current.dt);\n console.log(\"current temperature is \" + response.current.temp);\n console.log(\"current humidity is \" + response.current.humidity);\n console.log(\"current wind speed is \" + response.current.wind_speed);\n console.log(\"current uv index is \" + response.current.uvi);\n console.log(\"current weather icon is \" + response.current.weather[0].icon);\n console.log(\"--------------------\");\n\n dt = response.current.dt;\n temp = response.current.temp;\n hum = response.current.humidity;\n wind = response.current.wind_speed;\n uvi = response.current.uvi;\n icon = response.current.weather[0].icon;\n daily = response.daily;\n \n currentData(city, dt, temp, hum, wind, uvi, icon);\n forecastData(daily);\n }); \n}", "function getWeather(testCity) {\n var requestOptions = {\n method: 'GET',\n redirect: 'follow'\n };\n\n fetch(\"https://api.openweathermap.org/data/2.5/weather?q=\" + testCity + \"&APPID=de6cda6ee489e5192ad8edc5d0f21166&units=imperial\", requestOptions)\n .then(response => response.text())\n .then(result => {\n if (result) {\n result = JSON.parse(result)\n updateDisplay(result);\n uvIndex(result.coord.lat, result.coord.lon);\n }\n return;\n })\n .catch(error => console.log('error', error))\n .finally(() => { renderCityList() })\n\n}", "function getWeather(lat, lon, city) {\n\n //var city = $(\"#citySearchTextField\").val();\n var baseURL = \"https://api.openweathermap.org/data/2.5/\";\n\n if (lat !== undefined && lon !== undefined) {\n var queryParam = \"lat=\" + lat + \"&lon=\" + lon;\n }\n else {\n var queryParam = \"q=\" + city;\n };\n\n\n var openWeatherUrl = baseURL + \"weather?&units=imperial&\" + queryParam + \"&APPID=\" + apiKey;\n openWeatherUrl = encodeURI(openWeatherUrl);\n\n // Call Weather API for general weather\n $.ajax({\n url: openWeatherUrl,\n method: \"GET\"\n\n\n }).then(function (responseW) {\n\n $(\"#currentDate\").html(\" (\" + moment().format(\"M/D/YYYY\") + \")\");\n\n $(\"#cityName\").html(responseW.name); \n $(\"#temperature\").html(\"Temperature: \"+ responseW.main.temp + \" &#8457\");\n $(\"#humidity\").html(\"Humidity: \"+ responseW.main.humidity + \"%\");\n $(\"#windSpeed\").html(\"Wind Speed: \"+ responseW.wind.speed + \" MPH\");\n\n // Set weather icon\n var image_src = \"https://openweathermap.org/img/wn/\" + responseW.weather[0].icon +\"@2x.png\";\n $(\"#currentImg\").attr(\"src\",image_src);\n \n // Call Weather API for UV Index\n var uvIndexUrl = baseURL + \"uvi?lat=\" + responseW.coord.lat + \"&lon=\" + responseW.coord.lon + \"&APPID=\" + apiKey;\n $.ajax({\n url: uvIndexUrl,\n method: \"GET\"\n\n }).then(function (responseU) {\n $(\"#uvIndex\").html(\"UV Index: <span class='bg-danger text-white py-1 px-2 rounded' >\" + responseU.value +\"</span>\");\n })\n\n });\n }", "function getWeather(city) {\n fetch(`https://api.openweathermap.org/data/2.5/weather?q=${city}&APPID=${apiKey}`)\n .then(response => {\n return response.json();\n })\n .then(data => {\n $(\".date\").text(data.name + \" \" + date);\n latitude = data.coord.lat;\n longitude = data.coord.lon;\n fetch(`https://api.openweathermap.org/data/2.5/onecall?lat=${latitude}&lon=${longitude}&units=imperial&appid=${apiKey}`)\n .then(response => {\n return response.json();\n })\n .then(data => {\n iconCode = data.current.weather[0].icon;\n const iconUrl = \"http://openweathermap.org/img/w/\" + iconCode + \".png\";\n let uvi = data.current.uvi;\n $(\"#icon\").attr('src', iconUrl);\n $(\".temp\").text('Temp: ' + data.current.temp + '°F');\n $(\".wind\").text('Wind: ' + data.current.wind_speed + ' MPH');\n $(\".humidity\").text('Humidity: ' + data.current.humidity + ' %');\n $(\".index\").text(uvi);\n $(\".fiveCast\").empty();\n uvConditions(uvi);\n fiveDayForecast(data);\n console.log(data);\n })\n })\n }", "function fetchWeatherData() {\n if (DEBUG) {\n console.log('Fetching weather data...');\n console.log('Country: ' + country);\n console.log('City: ' + city);\n console.log('WOEID: ' + woeid);\n }\n \n locChanged = (woeid != lastWOEID);\n lastWOEID = woeid;\n\n if (!config.TempUnit || config.TempUnit === '' || config.TempUnit === 'Auto') {\n // Determine temperature units from country code (US gets F, everyone else gets C)\n if (country == 'US')\n unit = 'F';\n else\n unit = 'C';\n } else {\n unit = config.TempUnit;\n }\n\n if (DEBUG) console.log('Unit: ' + unit);\n\n // URL for getting basic weather forecast data in XML format (RSS)\n reqWeather.open('GET', 'http://weather.yahooapis.com/forecastrss?w=' + woeid + '&u=' + unit.toLowerCase(), true);\n // Fetch the weather data\n reqWeather.send(null);\n }", "async getWeather() {\n // Convert location to latitude and longitude using Google Maps geocoder\n const latLong = await this.getLatLong();\n const lat = latLong[0].geometry.location.lat();\n const lng = latLong[0].geometry.location.lng();\n\n // Get general weather API info for this location, including URLs for forecast, city name, etc.\n const weatherApiInfo = await (\n await fetch(`https://api.weather.gov/points/${lat},${lng}`)\n ).json();\n const forecastCity =\n weatherApiInfo.properties.relativeLocation.properties.city;\n const forecastState =\n weatherApiInfo.properties.relativeLocation.properties.state;\n\n // Get list of all weather stations in the area. Use the first station in the list.\n const observationStations = await (\n await fetch(weatherApiInfo.properties.observationStations)\n ).json();\n const weatherStation = observationStations.features[0].properties.name;\n\n // Get the current conditions\n const currentConditions = await (\n await fetch(\n `https://api.weather.gov/stations/${observationStations.features[0].properties.stationIdentifier}/observations/latest?require_qc=false`\n )\n ).json();\n\n // Get daily (7-day) forecast\n const dailyForecast = await (\n await fetch(weatherApiInfo.properties.forecast)\n ).json();\n\n // Get hourly forecast\n const hourlyForecast = await (\n await fetch(weatherApiInfo.properties.forecastHourly)\n ).json();\n\n // Return all this info and let the other module parse it and convert it\n return {\n forecastCity: forecastCity,\n forecastState: forecastState,\n weatherStationLoc: weatherStation,\n currentConditions: currentConditions.properties,\n dailyForecast: dailyForecast.properties,\n hourlyForecast: hourlyForecast.properties,\n };\n }", "async function fetchTheRestOfMyWeatherData(city) {\n try {\n // calls function that fetches weather data and grabs lat / lon / dt from the user's city\n const initialData = await fetchInitialWeatherDataForMy(city);\n\n // takes lat / lon / dt from initialData variable above, and processes it for API below\n const lat = initialData.coord.lat.toFixed(2);\n const lon = initialData.coord.lon.toFixed(2);\n // final API call that is then processed and used by the app\n const response = await fetch(`http://api.openweathermap.org/data/2.5/onecall?lat=${lat}&lon=${lon}&appid=f778724f49d8bcbf6a7c1111529b5d72`, { mode: 'cors' });\n return response;\n } catch (err) {\n return console.error(err);\n }\n}", "function weather(){\r\n\r\n\t\tvar appKey = \"4823e0379d7d603fb2cbfdbad5c5842e\";\r\n\r\n\t\tvar request = $.ajax({\r\n\t\t\ttype: 'GET',\r\n\t\t\turl: \"https://cors-anywhere.herokuapp.com/http://api.openweathermap.org/data/2.5/weather?lat=\"+lat+\"&lon=\"+lon+\"&appid=\"+appKey+\"&units=\"+units+\"\",\r\n\t\t\tcrossDomain: true,\r\n\t\t\tdataType: 'json',\r\n\t\t\tsuccess: function(data){\r\n\t\t\t\tconsole.log('success', data);\r\n\t\t\t},\r\n\t\t\terror: function(e){\r\n\t\t\t\tconsole.log('Error Loading Weather', e);\r\n\t\t\t},\r\n\r\n\t\t});\r\n\r\n\t\t// If everything works get the corresponding image and populate the text fields\r\n\t\trequest.done(function(data){\r\n\t\t\tgetImage(data);\r\n\t\t\tpopulate(data);\r\n\t\t});\r\n\t}", "function getWeather(map, latlng, windy) {\n\tvar xmlHttpRequest = new XMLHttpRequest();\n\txmlHttpRequest.onreadystatechange = function()\n\t{\n\t if( this.readyState == 4 && this.status == 200 )\n\t {\n\t if( this.response )\n\t {\n\t \t//console.log(this.response.list);\n\t showWeather(map, this.response.list, windy);\n\t }\n\t }\n\t}\n\txmlHttpRequest.open( 'GET',\"http://api.openweathermap.org/data/2.5/find?lat=\"+ latlng.lat() + \"&lon=\"+latlng.lng()+\"&cnt=10&appid=\"+ API_KEY , true );\n\txmlHttpRequest.responseType = 'json';\n\txmlHttpRequest.send( null );\n}", "static async getGeoData() {\n try {\n const response = await fetch(`https://api.openweathermap.org/data/2.5/weather?q=${city}&appid=${APIKey}`);\n const data = await response.json();\n return (data.coord);\n } catch(err) {\n alert(err);\n }\n }", "function getWeather(latitude,longitude){\n let fullApi = `http://api.openweathermap.org/data/2.5/weather?lat=${latitude}&lon=${longitude}&appid=${KEY}`\n \n fetch(fullApi)\n .then(function(response){\n let data = response.json();\n return data;\n })\n .then(function(data){\n weather.temperature.value = Math.floor(data.main.temp - KELVIN);\n weather.description = data.weather[0].description;\n weather.iconId = data.weather[0].icon;\n weather.city = data.name;\n weather.country = data.sys.country;\n })\n .then(function(){\n displayWeather();\n });\n \n\n}", "function getData () {\n $.get(`https://nominatim.openstreetmap.org/?q=${cityName}&addressdetails=1&countrycodes=US&format=json&limit=1`, function(response){\n //seting the latitude of the city\n lat = response[0].lat;\n //setting the laongitute of the city\n long = response[0].lon;\n //clean up the city name\n cityName = `${cityName}, ${response[0].address.state}`\n }).then(function(){\n $.get(`https://api.openweathermap.org/data/2.5/onecall?lat=${lat}&lon=${long}&\n exclude=hourly,daily&appid=${api}`, function(response){\n //create a current weather opject to send to the build function\n var currentWeather = {}\n //city name\n currentWeather.name = cityName\n //using moment to convert the unix timestap to human date\n currentWeather.date = moment.unix(response.current.dt).format('L');\n //format the icon url to hit the image source from OWM \n currentWeather.icon = `http://openweathermap.org/img/wn/${response.current.weather[0].icon}.png`\n //weather description, not used right now but could be fun\n currentWeather.desc = response.current.weather[0].description\n //current temp converted from K\n currentWeather.temp = (response.current.temp * (9/5) -459.67).toFixed(1);\n //humidity\n currentWeather.humidity = response.current.humidity;\n //wind speed\n currentWeather.wind = response.current.wind_speed;\n //uv index\n currentWeather.uvi = response.current.uvi;\n //send the current weather object to the build function\n buildCurrent(currentWeather)\n \n //setup fiveDay weather by popping off the last 2 peeps\n var fiveDayWeather = response.daily.slice(1,6)\n buildForcast(fiveDayWeather)\n })\n \n })\n \n }", "function getWeather(longitude, latitude) {\r\n Alert.style.display = \"none\";\r\n let api = `https://api.openweathermap.org/data/2.5/weather?lat=${latitude}&lon=${longitude}&appid=${key}`;\r\n console.log(api);\r\n fetch(api)\r\n .then(function (response) {\r\n let data = response.json();\r\n return data;\r\n })\r\n .then(function (data) {\r\n weather.temperature.value = Math.floor(data.main.temp - KELVIN);\r\n weather.iconId = data.weather[0].icon;\r\n weather.mainDesc = data.weather[0].main;\r\n weather.description = data.weather[0].description;\r\n weather.city = data.name;\r\n weather.country = data.sys.country;\r\n\r\n weather.lon = data.coord.lon;\r\n weather.lat = data.coord.lat;\r\n weather.rise = data.sys.sunrise;\r\n weather.set = data.sys.sunset;\r\n weather.minTemp.value = Math.floor(data.main.temp_min - KELVIN);\r\n weather.maxTemp.value = Math.floor(data.main.temp_max - KELVIN);\r\n weather.press = data.main.pressure;\r\n weather.humid = data.main.humidity;\r\n weather.speedW = data.wind.speed;\r\n weather.dirW = data.wind.deg;\r\n })\r\n .then(function () {\r\n displayWeather();\r\n });\r\n}", "function getWeather(city) {\n var lat = \"\";\n var lon = \"\";\n\n // Grab weather data, then make two additional API calls to get UV index and 5-day forecast\n $.ajax({\n url: `https://api.openweathermap.org/data/2.5/weather?q=${city}&appid=${APIKEY}&units=imperial`,\n method: \"GET\"\n }).then(function(response) {\n lat = response.coord.lat;\n lon = response.coord.lon;\n saveToLocalStorage();\n renderCitySidebar();\n \n // Get UV index data using latitude and longitude from previous API call, then call renderWeatherDisplay function\n $.ajax({\n url: `https://api.openweathermap.org/data/2.5/uvi/forecast?appid=${APIKEY}&lat=${lat}&lon=${lon}&cnt=1`,\n method: \"GET\"\n }).then(function(responseUV) {\n renderWeatherDisplay(response, responseUV);\n });\n\n // Get 5 day forecast by using latitude and longitude from first API call, then call renderFiveDayForecast function\n $.ajax({\n url: `https://api.openweathermap.org/data/2.5/onecall?lat=${lat}&lon=${lon}&appid=${APIKEY}&units=imperial&exclude=current,minutely,hourly`,\n method: \"GET\"\n }).then(renderFiveDayForecast);\n });\n }", "async function getWeatherSearch(city) {\r\n let res = await fetch(`https://api.openweathermap.org/data/2.5/weather?q=${city}&appid=${API_KEY}`)\r\n let data = await res.json()\r\n return data\r\n}", "function callAPI(city) {\n var weatherURL = \"https://api.weatherbit.io/v2.0/forecast/daily?key=125e5091a0b746d9a25859114793888d&days=6&city=\" + city\n return $.ajax({\n url: weatherURL,\n method: \"GET\",\n success: function (data) {\n }\n })\n }", "function getWeatherData(lat, long) {\r\n var key = \"1234f59e5798e86cc9241a1ff070cd36\";\r\n var req1 = new XMLHttpRequest();\r\n req1.open(\r\n \"GET\",\r\n `http://api.openweathermap.org/data/2.5/weather?lat=${lat}&lon=${long}&appid=${key}`,\r\n true\r\n );\r\n req1.send();\r\n req1.onload = function () {\r\n var result = JSON.parse(this.response);\r\n console.log(result);\r\n };\r\n}", "function getWeather() {\n\tweather.getWeather()\n\t\t.then((results) => {\n\t\t\tui.display(results);\n\t\t})\n\t\t.catch((err) => err);\n}", "function getweatherdata(latitude, longitude){ \r\n var key = \"83362a76bd91e5c5b5de9b7fc4202b50\";\r\n var req = new XMLHttpRequest();\r\n req.open('GET', `https://api.openweathermap.org/data/2.5/weather?lat=${latitude}&lon=${longitude}&appid=${key}`, true) \r\n req.send();\r\n req.onload = function(){\r\n if(latitude!==0 && longitude!==0){\r\n var weatherdata = JSON.parse(this.response);\r\n console.log(weatherdata[\"main\"]);\r\n } \r\n }\r\n }", "function getForecastWeather(lat,lon,city){\n var forecastData;\n fetch(\"https://api.openweathermap.org/data/2.5/onecall?lat=\" + lat + \"&lon=\" + lon + \"&exclude=hourly,minutely&units=imperial&appid=43802440c0c6de0f332937c0fa83470c\")\n .then(function(response) {\n if (response.ok) {\n response.json()\n .then(function(data) \n {\n //Load main panel for current day weather\n forecastData = data;\n fetch(\"https://api.openweathermap.org/data/2.5/uvi?lat=\" + lat + \"&lon=\" + lon + \"&appid=43802440c0c6de0f332937c0fa83470c\")\n .then(function(uviresponse) {\n if (uviresponse.ok) {\n uviresponse.json()\n .then(function(uvidata){\n loadCurrentWeather(forecastData,uvidata.value,city)\n });\n }\n });\n \n\n //Load forecast weather for 5 days\n loadForeCastWeather(forecastData);\n });\n } else {\n alert(\"Error: \" + response.statusText);\n }\n }).catch(function(error) {\n // Notice this `.catch()` getting chained onto the end of the `.then()` method\n alert(\"Unable to connect to Weather app\" + error);\n });\n}", "function fetchWeather() {\n\tlog(\"fetchWeather()\");\n\tvar userLocation = preferences.userLocation.value;\n\tvar cityVal = preferences.cityValPref.value;\n\tvar userCity = cityVal ? \"zmw:\"+cityVal : userLocation;\n\t\n\tif (!isLocationValid(userLocation)) {\n\t\tdisplayError( \"Location missing\", \"You haven't entered a location yet. Click here to enter a location.\", showWidgetPreferences);\n\t\treturn false;\n\t}\n\t\n\tvar locale = widget.locale.substr(0, 2);\n\tvar apiLocale = convertKonfabulatorLocaleToWundergroundLocale(locale);\n\tif (apiLocale.match(/api\\.wunderground\\.locales\\./)) apiLocale = \"EN\";\n\tvar _url = weatherURL + apiKey + \"/lang:\" + escape(apiLocale) + \"/conditions/forecast/astronomy/q/\" + escape(userCity) + \".xml\";\n\t\n\tlog(\"Trying to fetch: \"+_url);\n\t\n\tvar urlFetch = new URL();\n\turlFetch.location = _url;\n\ttry {\n\t\turlFetch.fetchAsync(onWeatherDataFetched);\n\t}\n\tcatch (error) {\n\t\tdisplayConnectionError(error,_url);\n\t}\n}", "function getWeather(city){\n fetch(`${api.webUrl}weather?q=${city}&units=metric&appid=${api.apiKey}`)\n .then(weather => {\n return weather.json();\n }).then(displayWeather);\n}", "function getWeather(latitude,longitude){\n let api = `http://api.openweathermap.org/data/2.5/weather?lat=${latitude}&lon=${longitude}&appid=${key}`;\n fetch(api).then(function(response){\n let data = response.json();\n console.log(api);\n \n return data;\n \n })\n .then(function(data){\n weather.temperature.value = Math.floor(data.main.temp - kelvin);\n weather.description = data.weather[0].description;\n weather.iconID = data.weather[0].icon;\n weather.city = data.name;\n weather.country = data.sys.country;\n })\n .then(function(){\n displayWeather();\n });\n}", "async function getWeather(query) {\n let weatherData = {};\n await fetch(\n `${api.base}weather?zip=${query},us&units=imperial&APPID=${api.key}`\n )\n .then((res) => {\n return res.json();\n })\n .then((data) => {\n weatherData.temp = data.main.temp;\n weatherData.cityName = data.name;\n weatherData.iconId = data.weather[0].icon;\n })\n .catch((err) => {\n console.log(err);\n // handle error here better\n localStorage.removeItem('zip');\n inputField.classList.remove('hidden');\n weatherDisplay.classList.add('hidden');\n inputField.value = '';\n displayTempError();\n });\n return weatherData;\n}", "function fetchWeather(city) {\n return fetch(\n `https://api.openweathermap.org/data/2.5/weather?q=${city}&units=metric&appid=${apiKey}`\n )\n .then((response) => response.json())\n .then((response) => {\n\n const lon = response.coord.lon;\n const lat = response.coord.lat;\n\n return fetchOnecall(lon, lat).then((onecallResponse) => {\n return {\n currentWeather: response,\n onecallWeather: onecallResponse,\n };\n });\n })\n .catch(function(err){\n console.log('not founddd');\n alert(\"City not found. Please enter a correct city name.\")\n });\n}", "function getWeather() {\n var queryURL = \"https://api.openweathermap.org/data/2.5/weather?q=\" + currentCity + \"&appid=\" + apiKey;\n $.ajax({\n url: queryURL,\n method: 'GET'\n }).then((response) => {\n //Update the current city weather\n currentCityWeather = response;\n //Update the page with weather information\n updateCurrentWeather();\n //Add the city to the recent cities up to 10\n addCityToRecent();\n //Get the cities uv index\n getUVIndex();\n //Get the 5 day forecast\n get5DayForecast();\n }).fail((error) => {\n $(\"<div class='error-div'><h1>\" + currentCity + \" was not found</h1></div>\").css({\n position: \"absolute\",\n width: \"100%\",\n height: \"100%\",\n left: 0,\n top: 0,\n zIndex: 1000000, // to be on the safe side\n background: '#ffffff',\n textAlign: 'center',\n verticalAlign: 'middle',\n }).appendTo($(\".current-weather\").css(\"position\", \"relative\"));\n \n feedbackTimeout = setTimeout(() => {\n $('.error-div').remove();\n }, 1500);\n })\n }", "function getWeather(city){\n let api = `http://api.openweathermap.org/data/2.5/weather?q=${city}&appid=${apiKey}&units=imperial`;\n \n //Fetch is what sends out the request from openweather to get the data for the given city\n //once it receives the response its converted to JSON and the passed into the display function\n fetch(api)\n .then(response => response.json())\n .then(data => displayWeather(data))\n .catch(e => {\n displayError(); \n })\n}", "function getWeather() {\n \n var queryURL = \"https://api.openweathermap.org/data/2.5/weather?q=Denver&units=imperial&appid=b4e24afa7b1b97b59d4ac32e97c8b68d\";\n \n $.ajax({\n url: queryURL,\n method: \"GET\"\n }).then(function(response) {\n \n $(`p`).text(\"\");\n temp.text(`Current Temperature: ` + Math.floor(response.main.temp) + ` °F`);\n humid.text(`Humidity: ` + response.main.humidity + `%`);\n wind.text(`Wind Speed: ` + response.wind.speed);\n })\n}", "function getWeather() {\n\tfetch(apiCall, {\n\t\tmode: \"cors\",\n\t\theader: {\n\t\t\t\"Access-Control-Allow-Origin\": \"*\",\n\t\t\t\"Cache-Control\": \"no-store\",\n\t\t},\n\t})\n\t\t.then(function (response) {\n\t\t\tif (response.status !== 200) {\n\t\t\t\tconsole.log(\n\t\t\t\t\t\"Looks like there was a problem. Status Code: \" + response.status\n\t\t\t\t);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tresponse.json().then(function (data) {\n\t\t\t\tcurrentWeather = data;\n\t\t\t\tconsole.log(\"Made with love in Stockholm 🏰🇪🇺\");\n\n\t\t\t\tclouds = map(currentWeather.clouds.all, 0, 100, 0, 90);\n\t\t\t\tcloudCoverage = map(currentWeather.clouds.all, 0, 100, 0, 1);\n\t\t\t\thumidity = map(currentWeather.main.humidity, 0, 100, 0, 50);\n\t\t\t\tpressure = map(currentWeather.main.pressure, 800, 1100, 10, 0);\n\t\t\t\ttemperature = map(currentWeather.main.temp, -30, 55, 0, 40);\n\t\t\t\ttempMax = map(currentWeather.main.temp_max, -30, 55, 0, 4);\n\t\t\t\ttempMin = map(currentWeather.main.temp_min, -30, 55, 0, 4);\n\t\t\t\tvisibility = map(currentWeather.visibility, 0, 10000, 0, 4);\n\t\t\t\twindDeg = map(currentWeather.wind.deg, 0, 360, 0, 360);\n\t\t\t\twindSpeed = map(currentWeather.wind.speed, 0, 14, 0.8, 5);\n\t\t\t\tcurrentTemperature = currentWeather.main.temp;\n\n\t\t\t\tdrawSunPath();\n\t\t\t});\n\t\t})\n\t\t.catch(function (err) {\n\t\t\tconsole.log(\"Fetch Error :-S\", err);\n\t\t});\n}", "fetchWeather(searchZipCode) {\n fetch(`https://api.openweathermap.org/data/2.5/forecast?zip=${searchZipCode},us&units=imperial&appid=08d4fea27ae00e7c79b59befd31e8d18`)\n .then(response => response.json())\n .then(results => this.setWeather(results));\n }", "function getWeather(latitude, longitude){\n let api = `http://api.openweathermap.org/data/2.5/weather?lat=${latitude}&lon=${longitude}&appid=${key}`;\n \n \n fetch(api)\n .then(function(response){\n let data = response.json();\n return data;\n })\n .then(function(data){\n weather.temperature.value = Math.floor(data.main.temp - KELVIN);\n weather.description = data.weather[0].description;\n weather.iconID = data.weather[0].icon;\n weather.city = data.name;\n weather.country = data.sys.country;\n })\n .then(function(){\n displayWeather();\n });\n}", "fetchForecast()\n {\n var url = \"http://api.openweathermap.org/data/2.5/forecast?APPID=0cf17e23b1d108b29a4d738d2084baf5&q=\" + this.state.location + \"&units=\" + this.state.units;\n \n $.ajax({\n\t\t\turl: url,\n dataType: \"jsonp\",\n\t\t\tsuccess : this.parseResponse,\n\t\t\terror : function(req, err){ console.log('API call failed ' + err); }\n })\n\n \n }", "function getWeatherData(city) {\n var currentWeatherUrl = `https://api.openweathermap.org/data/2.5/weather?q=${city}&appid=260502960360e1be7ff30b2693e2aa94`\n \n fetch(currentWeatherUrl)\n .then(function (response) {\n return response.json();\n })\n .then(function (data) {\n console.log(data);\n var cityName = data.name;\n var weatherIcon = data.weather[0].icon;\n $('.current-city').append(cityName);\n $(\".todaysWeatherIcon\").attr(\"src\", `http://openweathermap.org/img/wn/${weatherIcon}.png`);\n var lat = data.coord.lat;\n var lon = data.coord.lon;\n \n var oneCallUrl = `https://api.openweathermap.org/data/2.5/onecall?lat=${lat}&lon=${lon}&exclude={part}&appid=260502960360e1be7ff30b2693e2aa94&units=imperial`\n\n fetch(oneCallUrl)\n .then(function (response) {\n return response.json();\n })\n .then(function (cityData) {\n console.log(cityData);\n weatherReport(cityData);\n getFiveDayForecast(cityData);\n })\n })\n }", "async function getWeatherAW(woeid) {\n try {\n const result = await fetch(`https://cors-anywhere.herokuapp.com/https://www.metaweather.com/api/location/${woeid}/`);\n const data = await result.json();\n const tomorrow = data.consolidated_weather[1];\n console.log(`Temperatures tomorrow in ${data.title} stay between ${tomorrow.min_temp} and ${tomorrow.max_temp}.`);\n return data;\n } catch(error) {\n alert(error);\n }\n}", "function searchWeather(cityName){\nfetch(`https://cors-anywhere.herokuapp.com/http://api.openweathermap.org/data/2.5/weather?q=${cityName}&APPID=${apiKey}&units=${unit}`)\n.then(y => {\n return y.json()\n})\n.then(y =>{\n init(y)\n})\n.catch(function(err){\n alert('city not found, please check spelling')\n})\n\n}", "function getWeather(latitude, longitude) {\r\n let api = `https://api.openweathermap.org/data/2.5/weather?lat=${latitude}&lon=${longitude}&appid=${key}&units=metric`;\r\n \r\n fetch(api).then(function (response) {\r\n let data = response.json();\r\n return data;\r\n })\r\n .then(function (data) {\r\n weather.temp = data.main.temp;\r\n weather.city = data.name;\r\n weather.country = data.sys.country;\r\n weather.info = data.weather[0].main;\r\n weather.icon = data.weather[0].icon;\r\n \r\n displayWeather();\r\n forecast(`forecast?lat=${latitude}&lon=${longitude}`, weather.city);\r\n })\r\n\r\n function displayWeather() {\r\n $('.temp').html(Math.round(weather.temp) + \" &deg;C\");\r\n\r\n $('img.icon-img').attr('src', `images/icons/${ weather.icon}.png`);\r\n $('.info').html(weather.info);\r\n $('.city').html(weather.city);\r\n $('.country').html(weather.country);\r\n }\r\n}", "function getCoordinates(city){\n \n let URL = \"https://api.openweathermap.org/data/2.5/weather?q=\"; //here\n let queryURL = URL + city + key;\n \n $.ajax({\n url: queryURL,\n method: \"GET\"\n }).then(function(response) {\n localStorage.setItem(\"city\",response.name);\n localStorage.setItem(response.name+\"lon\",response.coord.lon);\n localStorage.setItem(response.name+\"lat\",response.coord.lat);\n localStorage.setItem(response.name+\"humidityLevel\", response.main.humidity);\n displayStats(response.name);\n fiveDay(response.name);\n displayHistory();\n localStorage.setItem(\"lastCity\", response.name);\n });\n}", "function getWeather(latitude , longitude){\n let api =`http://api.openweathermap.org/data/2.5/weather?lat=${latitude}&lon=${longitude}&appid=${key}`;\n //console.log(api);\n fetch(api)\n .then(function(response){\n let data = response.json();\n return data;\n })\n .then(function(data){\n weather.temperature.value = Math.floor(data.main.temp -kelvin);\n weather.descripition = data.weather[0].descripition;\n weather.iconId = data.weather[0].icon;\n weather.city = data.name;\n weather.country = data.sys.country;\n })\n .then(function(){\n displayWeather();\n })\n}", "async function getWeather() {\n const url = `https://api.openweathermap.org/data/2.5/weather?q=${city.textContent}&lang=en&appid=1964d0a7118d50f00dc12a34ffef2fef&units=metric`;\n const res = await fetch(url);\n const data = await res.json();\n const weather = data.weather;\n\n if (data.cod === '404') {\n weatherInfo.style.display = 'none';\n localStorage.clear();\n popup.style.display = 'block';\n popupBtn.addEventListener('click', () => (popup.style.display = 'none'));\n city.textContent = '';\n } else {\n weatherIcon.src = `http://openweathermap.org/img/w/${weather[0].icon}.png`;\n temperature.textContent = `${data.main.temp.toFixed(0)}°C`;\n weatherDescription.textContent = data.weather[0].description;\n humidity.textContent = `humidity: ${data.main.humidity} %`;\n wind.textContent = `wind: ${data.wind.speed} m/s`;\n }\n}", "function getCurrentWeather() {\n \tvar dataObj = {\n \t\tlat: '',\n \t\tlon: '',\n \t\tAPPID: '923ac7c7344b6f742666617a0e4bd311',\n \t\tunits: 'metric'\n \t}\n }", "async function getCityWeather(lat, lon) {\n var oneCallURL = \"https://api.openweathermap.org/data/2.5/onecall?lat=\" + lat + \"&lon=\" + lon + \"&exclude=minutely&appid=\" + APIkey + units;\n\n const response = await fetch(oneCallURL);\n const data = await response.json();\n console.log(data);\n return data;\n}", "function getWeather() {\n var location = globals.location,\n usrInput = $('.input-div input').val() || '';\n\n getCityWeather(usrInput, location);\n getCityForecast(usrInput, location)\n\n }", "async function getWeatherData(city) {\n let response = await fetch('http://api.openweathermap.org/data/2.5/weather?q=' + city + '&APPID=' + apikey, { mode: 'cors' })\n let weatherData = await response.json()\n //console.log(weatherData.weather[0].description);\n let data = weatherData.weather[0].description;\n return data;\n}", "getWeather(){\n fetch(`https://cors-anywhere.herokuapp.com/https://api.darksky.net/forecast/${process.env.REACT_APP_WEATHER_API_KEY}/${this.state.lat},${this.state.lng}`)\n .then(response => response.json())\n .then(data => {\n this.setState({ weather: data })\n })\n }", "function getWeather(city){\n\t\t$.get(\"http://api.openweathermap.org/data/2.5/weather?q=\"+city+\"&appid=e9eae461e99aa01a4e6115e572b2a66f\", function(data){\n\t\t\t\tconsole.log(data);\n\t\t\t\t$(\"#desc\").html(data.weather[0].description);\n\t\t\t\t$(\"#temp\").html(data.main.temp);\n\t\t\t\t$(\"#humidity\").html(data.main.humidity);\n\n})\n\n\t}", "function getCurrentWeather() {\n // const enteredZipCode = document.getElementById('zip').value;\n const zipCode = document.getElementById('zip').value;\n const apiCall = baseUrl + '?zip=' + zipCode + '&appid=' + apiKey + unit;\n // const apiCall = 'http://api.openweathermap.org/data/2.5/weather?zip=94040&appid=25b7a4527f77b209b126a463a9baa9c0';\n getWeatherAPI(apiCall)\n .then(function (d){\n postData('/send', d)\n .finally(updateUI)});\n}", "async function getWeatherDetails() {\n\n // Hit the weather API\n const weatherApiUrl = 'https://api.openweathermap.org/data/2.5/forecast/daily?q=totnes&units=metric&cnt=1&appid=d94bcd435b62a031771c35633f9f310a';\n const weatherResult = await logFetch(weatherApiUrl);\n\n // Update the temp\n const weatherTemperature = weatherResult.list[0].temp;\n temperature.innerHTML = weatherTemperature.day + ' ° C';\n\n // Update the icon\n weatherIcon.innerHTML = mapWeatherIcon(weatherResult.list[0].weather[0].id);\n}", "function fetchWeatherInfoWithStatAndCountry(city, state, country) {\n let url = \"http://api.openweathermap.org/data/2.5/weather?q=\";\n url = `${url}${city},{state},${country}&appid=${APIKey}`;\n // console.log(\"url is\", url);\n return fetch(url).then(response => response.json());\n}", "function getWeather(latitude, longitude) {\n let api = `http://api.openweathermap.org/data/2.5/weather?lat=${latitude}&lon=${longitude}&appid=${key}`;\n\n fetch(api)\n .then(function (response) {\n let data = response.json();\n Console.log(data);\n return data;\n })\n .then(function (data) {\n weather.temperature.value = Math.floor(data.main.temp - KELVIN);\n weather.description = data.weather[0].description;\n //weather.iconId = data.weather[0].icon;\n weather.city = data.name;\n weather.country = data.sys.country;\n })\n .then(function () {\n displayWeather();\n });\n}", "function fetchLocation(apiKey, latitude, longitude) {\n\n //you don't need a proxy but you need secure your key in the google developer console.\n // var googleApiLink = `https://maps.googleapis.com/maps/api/geocode/json?latlng=${latitude},${longitude}&key=${apiKey}`;\n // console.log(googleApiLink)\n\n fetch(`https://api.openweathermap.org/data/2.5/weather?lat=${latitude}&lon=${longitude}&appid=${apiKey}&units=imperial`)\n .then(response => {\n return response.json()\n })\n .then(data => {\n // Work with JSON data here\n console.log(data)\n //Set values for the location we picked the 4 object in the results becuase show the approximate address\n document.getElementById(\"location\").innerHTML = data.name;\n city = data.name;\n document.getElementById(\"currenttemp\").innerHTML = data.main.temp;\n temp = data.main.temp;\n weather=data.weather[0].main;\n windspeed=data.wind.speed;\n humid = data.clouds.all;\n\t\t\tdocument.getElementById(\"wind_speed\").innerHTML = data.wind.speed;\n\t\t\tdocument.getElementById(\"weather\").innerHTML = data.weather[0].main;\n\t\t\tconsole.log(data.wind.speed, data.weather[0].main, humid)\n\t\t\tdocument.getElementById(\"humidity\").innerHTML = humid;\n\t\t\t document.getElementById(\"currlocation\").innerHTML = data.name;\n\t\t\tdocument.getElementById(\"temp\").innerHTML = data.main.temp;\n\n\t\t\t// var iconcode = data.weather[0].icon;\n\t\t\tconsole.log(data.weather[0].icon)\n\t\t\tvar iconurl = `http://openweathermap.org/img/w/${data.weather[0].icon}.png`;\n\t\t\tconsole.log(iconurl)\n\t\t\tvar locationicon = document.querySelector('.forecast-icon');\n\t\t\tlocationicon.innerHTML = `<img src=\"${iconurl}\" alt=\"\" width=90>`\n })\n .catch(err => {\n // Do something for an error here\n throw (`Sorry, An Error occured. ${err}`);\n })\n}", "getWeather() {\n this.setState({\n loading: true,\n error: '',\n userInput: '',\n data: {},\n data10: [],\n location: {},\n icon: ''\n })\n\n axios.get(`https://api.wunderground.com/api/${config.apiKey}/conditions/q/${this.state.userInput}.json`)\n .then(res =>\n this.setState({\n data: res.data.current_observation,\n location: res.data.current_observation.display_location,\n icon: res.data.current_observation.icon_url\n })\n )\n .catch(() => this.weatherFail());\n }", "function useCurrentWeatherApi(input) {\n\tif (alphabetRegex.test(input)) {\n\t\t// get weather by city name\n\t\tfetch(\n\t\t\t`https://api.openweathermap.org/data/2.5/weather?q=${input},us&appid=${apikey}&units=imperial`\n\t\t)\n\t\t\t.then(res => res.json())\n\t\t\t.then(data => {\n\t\t\t\tconsole.log('current weather: ' + data);\n\t\t\t\tshowCurrentWeather(data);\n\t\t\t\tuseOneCallApi(data);\n\t\t\t});\n\t} else {\n\t\t// get weather by zip code\n\t\tfetch(\n\t\t\t`https://api.openweathermap.org/data/2.5/weather?zip=${input},us&appid=${apikey}&units=imperial`\n\t\t)\n\t\t\t.then(res => res.json())\n\t\t\t.then(data => {\n\t\t\t\tconsole.log('current weather: ', data);\n\t\t\t\tshowCurrentWeather(data);\n\t\t\t\tuseOneCallApi(data);\n\t\t\t});\n\t}\n}", "function getWeather(){\r\n let api = `http://api.openweathermap.org/data/2.5/forecast?q=hanoi&appid=${key}`;\r\n\r\n fetch(api)\r\n .then(function(response){\r\n let data = response.json();\r\n return data;\r\n })\r\n .then(function(data){\r\n weather.temperature.value[0] = Math.floor(data.list[6].main.temp - KELVIN);\r\n weather.temperature.value[1] = Math.floor(data.list[12].main.temp - KELVIN);\r\n weather.temperature.value[2] = Math.floor(data.list[18].main.temp - KELVIN);\r\n weather.temperature.value[3] = Math.floor(data.list[24].main.temp - KELVIN);\r\n weather.temperature.value[4] = Math.floor(data.list[30].main.temp - KELVIN);\r\n\r\n weather.description[0] = data.list[6].weather[0].description;\r\n weather.description[1] = data.list[12].weather[0].description;\r\n weather.description[2] = data.list[18].weather[0].description;\r\n weather.description[3] = data.list[24].weather[0].description;\r\n weather.description[4] = data.list[30].weather[0].description;\r\n\r\n weather.iconId[0] = data.list[6].weather[0].icon;\r\n weather.iconId[1] = data.list[12].weather[0].icon;\r\n weather.iconId[2] = data.list[18].weather[0].icon;\r\n weather.iconId[3] = data.list[24].weather[0].icon;\r\n weather.iconId[4] = data.list[30].weather[0].icon;\r\n \r\n weather.time[0] = data.list[6].dt_txt;\r\n weather.time[1] = data.list[12].dt_txt;\r\n weather.time[2] = data.list[18].dt_txt;\r\n weather.time[3] = data.list[24].dt_txt;\r\n weather.time[4] = data.list[30].dt_txt;\r\n\r\n \r\n //Location\r\n weather.city = data.city.name;\r\n weather.country = data.city.country;\r\n })\r\n .then(function(){\r\n displayWeather();\r\n })\r\n}" ]
[ "0.7700457", "0.76259696", "0.7566452", "0.753374", "0.7515647", "0.7472935", "0.74516594", "0.74449676", "0.7429668", "0.74257815", "0.7421122", "0.74142784", "0.7383334", "0.7372995", "0.73702353", "0.73059416", "0.72946644", "0.72866285", "0.7266296", "0.72584003", "0.7255942", "0.71885043", "0.71875566", "0.7176721", "0.71589017", "0.7148192", "0.7147864", "0.7135735", "0.71150714", "0.7090542", "0.70880234", "0.7087675", "0.7080845", "0.70747477", "0.70731527", "0.7071897", "0.70667046", "0.7054273", "0.70464015", "0.7046388", "0.7041238", "0.70362866", "0.7025173", "0.70131195", "0.70093834", "0.7007695", "0.7007492", "0.6992327", "0.6975849", "0.69754195", "0.695717", "0.69532746", "0.6952117", "0.694386", "0.69419616", "0.69316554", "0.69158417", "0.69132924", "0.6896131", "0.6893366", "0.6890978", "0.6881418", "0.68804806", "0.68802416", "0.6878675", "0.6878306", "0.68722117", "0.68717366", "0.68695784", "0.6865459", "0.6864988", "0.68622315", "0.6851005", "0.6842811", "0.68413615", "0.6836862", "0.6832214", "0.6825968", "0.6825218", "0.6819968", "0.6813906", "0.6811534", "0.6805347", "0.6804688", "0.6803297", "0.6802497", "0.6800352", "0.6799729", "0.6795494", "0.6795124", "0.679423", "0.6793029", "0.6789712", "0.6789427", "0.6787254", "0.67854774", "0.6784115", "0.6783164", "0.6771043", "0.6770523" ]
0.70304394
42
used to support hot reloading
_reload() { js2py = require("../../shift-codegen-py/src"); this._generator = new js2py.PyCodeGen({ topLevelComment: false, }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "_configureHTTP() {\n let source\n\n// Configuring express to serve from example directory...\n app.use('/', express.static(this.options.watchOpts.serve))\n// Setting the port...\n app.set('port', process.env.PORT || this.options.watchOpts.port)\n\n// HMR endpoint...\n app.get('/hot-module', (req, res)=> {\n/// Isolate the updated module....\n // console.log('MODULEDEPSJSON');console.log(this.moduleDepsJSON);\n let hotMod = this.moduleDepsJSON.filter(\n dep=> dep.id.includes(req.query.file)\n )[0]\n // console.log('HOTMOD');console.log(hotMod);\n// Get module id....\n let moduleId = hotMod.id\n// wrap the module code around JSONP callback function\n let hotModuleScript = `hotModule({ \"${moduleId}\": [function(require, module, exports) {`\n\n// if User is using valence UI library, remove 'use strict'...\n if (this.options.valence || this.options.strict) {\n// Remove code....\n source = this._loosyGoosy(hotMod.source)\n }\n\n// Add the updated module's source to the hotModuleScript text....\n hotModuleScript += source\n // log('hotMod.source', ['yellow', 'bold']);log(source, ['yellow', 'bold'])\n// Finish up the script....\n hotModuleScript += `},`\n// Append dependencies....\n hotModuleScript += JSON.stringify(hotMod.deps)\n// Add finishing touches, brackets and parens....\n hotModuleScript += `]});`\n\n// Send the script...\n res.send(hotModuleScript)\n })\n }", "function reload() { if(!production) { bsyncReload(); } }", "enableForceReload() {\n this.compiler.plugin('compilation', (compilation) => {\n compilation.plugin('html-webpack-plugin-after-emit', (data, cb) => {\n this.hotMiddleware.publish({ action: 'reload' });\n cb();\n });\n });\n }", "function LiveReloadJsHandler() {\n}", "__debug() {\n const watchPath = this.util.getRootPath('templates')\n if (fs.existsSync(watchPath)) {\n const self = this\n const reloadServer = reload(self.app, {\n https: this.config.ssl.enabled ? this.config.ssl.opts : undefined,\n })\n reloadServer.then(function (reloadReturned) {\n watch.watchTree(watchPath, (f, curr, prev) => {\n /// TODO: reset page cache for all paths that match the changed filepath\n /// TODO: to support the above, change the cacheKeys in rendering.js to drop the filename extension\n self.log('Asset change detected, reloading connection')\n reloadReturned.reload()\n })\n })\n } else {\n this.log.error('cannot watch because folder does not exist', {\n watchPath,\n })\n }\n }", "function autoReloadServer (entryPath, outputPath) {\n var g_ws = undefined;\n\n var htmlScriptOffsetLine = 0;\n function bundleIntoHtml (scriptBody, sourceMap) {\n // sourceMap.base64() - source map file ready to serve.\n fs.writeFileSync(outputPath, '<html><head><script>' + scriptBody + '\\n' + sourceMap.comment() + '</script><style>' +\n // fs.readFileSync('./qp.css', 'utf-8') + \n '</style></head><body><div id=\"container\"></div></body></html>', 'utf-8');\n }\n\n bundleWatch(entryPath, htmlScriptOffsetLine, function onRebuilt (scriptBody, sourceMap) {\n bundleIntoHtml(scriptBody, sourceMap);\n\n if (g_ws) {\n g_ws.send('reload');\n }\n });\n\n var WebSocketServer = require('ws').Server;\n var wss = new WebSocketServer({ port: 8080 });\n\n wss.on('connection', function connection (ws) {\n console.log('Debugging browser connected.');\n\n g_ws = ws;\n\n });\n}", "reloadBrowsers() {\n this.emit( 'reloadBrowsers' );\n // check if we have hmr enabled first\n if( typeof ((this.bundler || {}).hmr || {}).broadcast !== 'function' ) {\n console.log(\n chalk.bold.yellow(`${this.pluginName} activate parcel's hmr to reload browsers on file change.`)\n );\n return;\n }\n this.bundler.hmr.broadcast({\n type: 'reload'\n });\n }", "reload() {\n\n }", "function reloadApp({ hot, liveReload }, status) {\n if (status.isUnloading) {\n return;\n }\n\n const { currentHash, previousHash } = status;\n const isInitial = currentHash.indexOf(previousHash) >= 0;\n\n if (isInitial) {\n return;\n }\n\n function applyReload(rootWindow, intervalId) {\n clearInterval(intervalId);\n\n log_log.info(\"App updated. Reloading...\");\n\n rootWindow.location.reload();\n }\n\n const search = self.location.search.toLowerCase();\n const allowToHot = search.indexOf(\"webpack-dev-server-hot=false\") === -1;\n const allowToLiveReload =\n search.indexOf(\"webpack-dev-server-live-reload=false\") === -1;\n\n if (hot && allowToHot) {\n log_log.info(\"App hot update...\");\n\n emitter_default().emit(\"webpackHotUpdate\", status.currentHash);\n\n if (typeof self !== \"undefined\" && self.window) {\n // broadcast update to window\n self.postMessage(`webpackHotUpdate${status.currentHash}`, \"*\");\n }\n }\n // allow refreshing the page only if liveReload isn't disabled\n else if (liveReload && allowToLiveReload) {\n let rootWindow = self;\n\n // use parent window for reload (in case we're in an iframe with no valid src)\n const intervalId = self.setInterval(() => {\n if (rootWindow.location.protocol !== \"about:\") {\n // reload immediately if protocol is valid\n applyReload(rootWindow, intervalId);\n } else {\n rootWindow = rootWindow.parent;\n\n if (rootWindow.parent === rootWindow) {\n // if parent equals current window we've reached the root which would continue forever, so trigger a reload anyways\n applyReload(rootWindow, intervalId);\n }\n }\n });\n }\n}", "function main() {\n return __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_0__angular_platform_browser_dynamic__[\"platformBrowserDynamic\"])()\n .bootstrapModule(__WEBPACK_IMPORTED_MODULE_3__app__[\"a\" /* AppModule */]).then(function(MODULE_REF) {\n if (false) {\n module[\"hot\"][\"accept\"]();\n \n if (MODULE_REF.instance[\"hmrOnInit\"]) {\n module[\"hot\"][\"data\"] && MODULE_REF.instance[\"hmrOnInit\"](module[\"hot\"][\"data\"]);\n }\n if (MODULE_REF.instance[\"hmrOnStatus\"]) {\n module[\"hot\"][\"apply\"](function(status) {\n MODULE_REF.instance[\"hmrOnStatus\"](status);\n });\n }\n if (MODULE_REF.instance[\"hmrOnCheck\"]) {\n module[\"hot\"][\"check\"](function(err, outdatedModules) {\n MODULE_REF.instance[\"hmrOnCheck\"](err, outdatedModules);\n });\n }\n if (MODULE_REF.instance[\"hmrOnDecline\"]) {\n module[\"hot\"][\"decline\"](function(dependencies) {\n MODULE_REF.instance[\"hmrOnDecline\"](dependencies);\n });\n }\n module[\"hot\"][\"dispose\"](function(store) {\n MODULE_REF.instance[\"hmrOnDestroy\"] && MODULE_REF.instance[\"hmrOnDestroy\"](store);\n MODULE_REF.destroy();\n MODULE_REF.instance[\"hmrAfterDestroy\"] && MODULE_REF.instance[\"hmrAfterDestroy\"](store);\n });\n }\n return MODULE_REF;\n})\n .then(__WEBPACK_IMPORTED_MODULE_1__app_environment__[\"a\" /* decorateModuleRef */])\n .catch(function (err) { return console.error(err); });\n}", "async reload() {}", "function reloadCallback () {\n // Manual reset if left in wrong stated\n app.use(`${reloadPath}-reset`, function (req, res) {\n process.send({ cmd: 'reload-reset' })\n res.send('reload status reset...try again')\n })\n\n if (clusterEnabled) {\n app.use(reloadPath, async function (req, res) {\n res.send('<h1>starting cluster reload</h1>')\n process.send({ cmd: 'reload' })\n })\n return\n }\n\n app.use(reloadPath, async function (req, res) {\n try {\n // restart microlib\n await startMicroLib({ hot: true })\n res.send('<h1>hot reload complete</h1>')\n } catch (error) {\n console.error(error)\n }\n })\n}", "liveReload () {\n (async () => {\n try {\n await this.call('http_server.dev_subscribe')\n this.ws.removeEventListener('message', this._cmdHandler)\n this.ws.addEventListener('message', this._cmdHandler)\n } catch (e) {\n console.log(e.message)\n }\n })()\n }", "function main() {\n return platform_browser_dynamic_1.platformBrowserDynamic()\n .bootstrapModule(app_1.AppModule).then(function(MODULE_REF) {\n if (false) {\n module[\"hot\"][\"accept\"]();\n \n if (MODULE_REF.instance[\"hmrOnInit\"]) {\n module[\"hot\"][\"data\"] && MODULE_REF.instance[\"hmrOnInit\"](module[\"hot\"][\"data\"]);\n }\n if (MODULE_REF.instance[\"hmrOnStatus\"]) {\n module[\"hot\"][\"apply\"](function(status) {\n MODULE_REF.instance[\"hmrOnStatus\"](status);\n });\n }\n if (MODULE_REF.instance[\"hmrOnCheck\"]) {\n module[\"hot\"][\"check\"](function(err, outdatedModules) {\n MODULE_REF.instance[\"hmrOnCheck\"](err, outdatedModules);\n });\n }\n if (MODULE_REF.instance[\"hmrOnDecline\"]) {\n module[\"hot\"][\"decline\"](function(dependencies) {\n MODULE_REF.instance[\"hmrOnDecline\"](dependencies);\n });\n }\n module[\"hot\"][\"dispose\"](function(store) {\n MODULE_REF.instance[\"hmrOnDestroy\"] && MODULE_REF.instance[\"hmrOnDestroy\"](store);\n MODULE_REF.destroy();\n MODULE_REF.instance[\"hmrAfterDestroy\"] && MODULE_REF.instance[\"hmrAfterDestroy\"](store);\n });\n }\n return MODULE_REF;\n})\n .then(environment_1.decorateModuleRef)\n .catch(function (err) { return console.error(err); });\n}", "function _livereload () {\n return lazypipe ()\n .pipe (isWatching ? livereload : gutil.noop) ();\n}", "function selectiveReload() {\r\n script_url = server + \"/build/compositions/\" + composition + \".dre.screens.\" + screen + \".js\";\r\n\r\n\tif (preview) script_url = UpdatePreview(script_url);\r\n\r\n var script = {}\r\n var scripturl = url.parse(script_url);\r\n var base_path = define.filePath(script_url);\r\n script.src = script_url;\r\n script_tags[script_url] = script;\r\n\r\n http.get({\r\n host: scripturl.hostname,\r\n port: scripturl.port,\r\n path: scripturl.path\r\n }, function(res) {\r\n res.src = script_url;\r\n res.data = \"\";\r\n res.on('data', function(buf) {\r\n this.data += buf;\r\n });\r\n res.on('end', function() {\r\n var editable = this.data.indexOf('editable');\r\n //console.log('*****onend. File loaded', editable);\r\n\t if (editable == -1) {\r\n\t\t // Reload because the application is not in edit mode\r\n\t\t Reload();\r\n\t\t}\r\n });\r\n }.bind(this));\r\n }", "function check_server_and_reload()\n{\n if (use_advanced_page_reload)\n sm_send_request(\"GET\", window.location.href, \"\", \"replace_document\", false,\n reload_request_timeout, \"server_or_connect_error\", false, \"\", false);\n else\n sm_send_request(\"GET\", base_uri + \"images/spacer.png\", \"\", \"reload_now\", false,\n reload_request_timeout, \"server_or_connect_error\", false, \"\", true);\n}", "function autoReloadPage() {\n var fs = require('fs');\n\n fs.watch('./', [], function () {\n if (location)\n location.reload(false);\n });\n}", "extend (config, ctx) {\n config.output.publicPath = 'http://0.0.0.0:3000/';\n //config.output.crossOriginLoading = 'anonymous'\n /* const devServer = {\n public: 'http://0.0.0.0:3000',\n port: 3000,\n host: '0.0.0.0',\n hotOnly: true,\n https: false,\n watchOptions: {\n poll: 1000,\n },\n headers: {\n \"Access-Control-Allow-Origin\": \"\\*\",\n }\n };\n config.devServer = devServer; */\n }", "_addHMRClientCode(data) {\n// If we have it, grab supporting code...\n let prependage = fs.readFileSync('./lib/hmr/clientSocket.js'),\n appendage = fs.readFileSync('./lib/hmr/hmr.js')\n\n// Prepend clientSocket.js to bundle.... Append hmr runtime to bundle\n return `${prependage}${data}${appendage}`\n }", "restart() {}", "isLoadedFromServer() {\n return true;\n }", "static register() {\n // register service worker\n let scope = new URL(\"..\", document.getElementsByTagName(\"base\")[0].href);\n let swjs = `${scope}sw.js?${Server.swmtime}`;\n\n navigator.serviceWorker.register(swjs, scope).then(() => {\n // watch for reload requests from the service worker\n navigator.serviceWorker.addEventListener(\"message\", (event) => {\n // ignore requests if any input or textarea element is visible\n let inputs = document.querySelectorAll(\"input, textarea\");\n\n if (Math.max(...Array.from(inputs).map(element => element.offsetWidth)) <= 0) {\n if (event.data.type === \"reload\") {\n window.location.reload()\n } else if (event.data.type === \"latest\" && Main.latest) {\n this.latest(event.data.body)\n }\n }\n });\n\n // preload agenda and referenced pages for next requeset\n let base = document.getElementsByTagName(\"base\")[0].href;\n\n navigator.serviceWorker.ready.then(registration => (\n registration.active.postMessage({\n type: \"preload\",\n url: base + \"bootstrap.html\"\n })\n ))\n });\n\n // fetch bootstrap from server, and update latest once it is received\n if (Main.item === Agenda && Main.latest) {\n fetch(\"bootstrap.html\").then(response => (\n response.text().then(body => this.latest(body))\n ))\n };\n\n window.addEventListener(\"beforeinstallprompt\", (event) => {\n PageCache.#$installPrompt = event;\n event.preventDefault()\n });\n\n this.cleanup(scope.toString(), Server.agendas)\n }", "watch (directory) {\n logger.debug(`Hotloading enabled, watching for code changes...`)\n\n let modules = {}\n\n chokidar.watch('./lib', {alwaysStat: true}).on('all', (event, path, stats) => {\n if (event === 'add') modules[path] = {size: stats.size}\n if (event === 'change') {\n if (modules[path].size !== stats.size) {\n logger.info(`Reloaded code for ${path}...`)\n modules[path].size = stats.size\n\n delete require.cache[path]\n }\n }\n })\n }", "reload(cb) {\n this.reloadClusterInfo();\n if (this.status !== 'online' && this.status !== 'exception') {\n return cb({\n code: 'SERVER_BUSY',\n messsage: 'server is busy now, status:' + this.status\n });\n }\n this.status = 'reload';\n // clean exception retry\n this.retryTimeoutId.forEach((timeout) => {\n clearTimeout(timeout);\n });\n\n let newWorkersNum = this.options.processorNum;\n // reset workers\n this.oldWorkers = this.workers;\n this.workers = {};\n // re-assign new sock files\n this.initTargetSocks(newWorkersNum);\n\n this.once('reload_failed', (err) => {\n cb(err);\n });\n\n this.once('reloaded', (config) => {\n config.reload = true;\n /**\n * tell master that new workers is ready,\n * master will start reload proxy to let\n * new request send to these new workers\n */\n this.emit('ready', config);\n this.status = 'reloaded';\n /**\n * update router in next-tick, and then wait until nginx reloaded\n */\n process.nextTick(() => {\n cb(null, (err) => {\n /**\n * here nginx reloaded, and callback to kill old workers\n */\n if (err) {\n log.error(FLAG_CHILD, `app_reload_failed : ${this.appId}`, err);\n let workers = this.workers;\n this.cleanWorkers(workers, () => {\n this.status = 'online';\n });\n this.workers = this.oldWorkers;\n this.oldWorkers = {};\n } else {\n log.info(FLAG_CHILD, `app_reload_success : ${this.appId} , now stop old workers`);\n this.cleanWorkers(this.oldWorkers, () => {\n this.status = 'online';\n });\n this.oldWorkers = {};\n }\n });\n });\n });\n log.info(FLAG_CHILD, `app_start_reload : ${this.appId} , old workers:`, Object.keys(this.oldWorkers));\n for (let i = 0; i < newWorkersNum; i++) {\n this._create();\n }\n }", "function register() {\n if (\"production\" === 'production' && 'serviceWorker' in navigator) {\n window.addEventListener('load', function () {\n var swUrl = \"\" + '/service-worker.js';\n navigator.serviceWorker.register(swUrl).then(function (registration) {\n registration.onupdatefound = function () {\n var installingWorker = registration.installing;\n installingWorker.onstatechange = function () {\n if (installingWorker.state === 'installed') {\n if (navigator.serviceWorker.controller) {\n // At this point, the old content will have been purged and\n // the fresh content will have been added to the cache.\n // It's the perfect time to display a \"New content is\n // available; please refresh.\" message in your web app.\n console.log('New content is available; please refresh.');\n } else {\n // At this point, everything has been precached.\n // It's the perfect time to display a\n // \"Content is cached for offline use.\" message.\n console.log('Content is cached for offline use.');\n }\n }\n };\n };\n }).catch(function (error) {\n console.error('Error during service worker registration:', error);\n });\n });\n }\n}", "function reload() {\n calipso.log(\"Template module reloaded\");\n}", "function reload() {\n calipso.log(\"Template module reloaded\");\n}", "function forceLoad() {}", "function watch() {\n\tserverInit();\n\tgulp.watch(\"./app/scss/*.scss\", cssHandler);\n\tgulp.watch(\"./app/pug/*.pug\", htmlHandler);\n\tgulp.watch(\"./app/js/*.js\", jsHandler);\n}", "function softReload() {\n Turbolinks.enableTransitionCache(true);\n Turbolinks.visit(location.toString());\n Turbolinks.enableTransitionCache(false);\n}", "function livereload () {\n return lazypipe()\n .pipe(isWatching ? g.livereload : noop)();\n}", "function browserSync() {\r\n // Run serveSass when starting the dev server to make sure the SCSS & dev CSS are the same\r\n serveSass();\r\n\r\n bs.init({\r\n // Dev server will run at localhost:8080\r\n port: 8080,\r\n server: {\r\n baseDir: paths.input,\r\n },\r\n });\r\n\r\n watch(paths.devHTML).on('change', bs.reload);\r\n watch(paths.devCSS).on('change', bs.reload);\r\n watch(paths.devJS).on('change', bs.reload);\r\n}", "async function server() {\n const bs = browserSync.create();\n\n bs.watch(\"./dist/**/*.html\").on(\"change\", bs.reload);\n bs.watch(\"./dist/**/*.js\").on(\"change\", bs.reload);\n bs.watch(\"./dist/**/*.css\", (event) => {\n if (event === \"change\") {\n bs.reload(\"*.css\");\n }\n });\n\n await new Promise(resolve => {\n bs.init({\n server: \"./dist\",\n logPrefix: \"angular-es6-starter-kit\",\n port: 5000\n }, () => {\n resolve();\n });\n });\n}", "if(!content.locals) {\n<<<<<<< Updated upstream\n\t\t\tmodule.hot.accept(\"!!./../../node_modules/css-loader/index.js!./../../node_modules/vue-loader/lib/style-rewriter.js?id=_v-35c91d26&file=index.vue!./../../node_modules/vue-loader/lib/selector.js?type=style&index=0!./index.vue\", function() {\n\t\t\t\tvar newContent = require(\"!!./../../node_modules/css-loader/index.js!./../../node_modules/vue-loader/lib/style-rewriter.js?id=_v-35c91d26&file=index.vue!./../../node_modules/vue-loader/lib/selector.js?type=style&index=0!./index.vue\");\n=======\n\t\t\tmodule.hot.accept(\"!!./../../node_modules/css-loader/index.js!./../../node_modules/vue-loader/lib/style-rewriter.js?id=_v-3557dbdf&file=index.vue!./../../node_modules/vue-loader/lib/selector.js?type=style&index=0!./index.vue\", function() {\n\t\t\t\tvar newContent = require(\"!!./../../node_modules/css-loader/index.js!./../../node_modules/vue-loader/lib/style-rewriter.js?id=_v-3557dbdf&file=index.vue!./../../node_modules/vue-loader/lib/selector.js?type=style&index=0!./index.vue\");\n>>>>>>> Stashed changes\n\t\t\t\tif(typeof newContent === 'string') newContent = [[module.id, newContent, '']];\n\t\t\t\tupdate(newContent);\n\t\t\t});\n\t\t}\n\t\t// When the module is disposed, remove the <style> tags\n\t\tmodule.hot.dispose(function() { update(); });\n\t}", "function init() {\n // In development, we need to open a socket to listen for changes to data\n if (process.env.REACT_STATIC_ENV === 'development') {\n var io = require('socket.io-client');\n\n var run =\n /*#__PURE__*/\n function () {\n var _ref = _asyncToGenerator(\n /*#__PURE__*/\n _regenerator.default.mark(function _callee() {\n var _ref2, port, socket;\n\n return _regenerator.default.wrap(function _callee$(_context) {\n while (1) {\n switch (_context.prev = _context.next) {\n case 0:\n _context.prev = 0;\n _context.next = 3;\n return _axios.default.get('/__react-static__/getMessagePort');\n\n case 3:\n _ref2 = _context.sent;\n port = _ref2.data.port;\n socket = io(\"http://localhost:\".concat(port));\n socket.on('connect', function () {\n console.log('React-Static data hot-loader websocket connected. Listening for data changes...');\n });\n socket.on('message', function (_ref3) {\n var type = _ref3.type;\n\n if (type === 'reloadRoutes') {\n reloadRouteData();\n }\n });\n _context.next = 14;\n break;\n\n case 10:\n _context.prev = 10;\n _context.t0 = _context[\"catch\"](0);\n console.log('React-Static data hot-loader websocket encountered the following error:');\n console.error(_context.t0);\n\n case 14:\n case \"end\":\n return _context.stop();\n }\n }\n }, _callee, this, [[0, 10]]);\n }));\n\n return function run() {\n return _ref.apply(this, arguments);\n };\n }();\n\n run();\n }\n\n if (process.env.REACT_STATIC_DISABLE_PRELOAD === 'false') startPreloader();\n}", "async function start() {\n await build();\n await server(port);\n opn(`http://localhost:${port}`);\n\n watch(\"src\", {recursive: true}, async (evt, name) => {\n console.log(`${name} changed : re-buliding`);\n await build();\n wss.broadcast(\"reload\");\n });\n}", "enableReloadHotkey() {\n window.addEventListener(\"keydown\", function (e) {\n if (e.keyCode === 82 && e.altKey && e.ctrlKey) {\n system_1.System.clearCache({\n cache: true,\n cookies: false,\n localStorage: false,\n appcache: true,\n userData: false\n });\n window.location.reload();\n }\n });\n }", "shouldBackgroundReloadAll() {\n return false;\n }", "function watchTask () {\r\n browserSync.init({\r\n server: {\r\n baseDir: \"pub/\",\r\n index: \"/admin-login.php\"\r\n }\r\n });\r\n \r\n // Look after files´changes \r\n watch([files.htmlPath, files.phpPath, files.jsPath, files.cssPath, files.sassPath, files.imgPath], parallel(htmlFiles, phpFiles, jsFiles, cssFiles, sassFiles, imgFiles, babelTranspile)).on(\"change\", reload); \r\n }", "function swPrecache_callback(error) { console.log(\"Error:\" + error) }", "function reload(cb) {\r\n src([getBuildPath()]) //have to pipe a stream to connect.reload for it to work.\r\n .pipe(connect.reload());\r\n cb();\r\n}", "function hardReload() {\n location.reload();\n}", "function reload() {\n\twindow.location.reload();\n\tif (sync.online) {\n\t\t//window.applicationCache.update();\n\t}\n}", "function serve() {\n browsersync.init({\n server: 'src',\n notify: false,\n open: true,\n cors: true,\n online: true\n })\n}", "watch() {\n chokidar.watch(`${this.app.cwd}/config.json`, { ignoreInitial: true }).on('all', () => this.load());\n }", "function reloadConfig(){\r\n\treturn require(\"./config.json\");\r\n}", "restartBrowser(){\n location.reload();\n }", "function needRefresh() {\n return polling && config && config.autoReload;\n}", "async function main() {\n const config = await jupyterConfigData();\n if (config.baseUrl === new URL(here()).pathname) {\n window.location.href = config.appUrl.replace(/\\/?$/, '/index.html');\n return;\n }\n // rewrite the config\n CONFIG_SCRIPT.textContent = JSON.stringify(config, null, 2);\n addFavicon(config);\n const preloader = document.getElementById(LITE_MAIN);\n const bundle = document.createElement('script');\n bundle.src = preloader.href;\n bundle.main = preloader.attributes.main;\n document.head.appendChild(bundle);\n}", "function loadActivist (prefix, options, rsrc) {\n var config = {};\n var defaultConfig = require('./src/config');\n for (var i in defaultConfig) {\n if (defaultConfig.hasOwnProperty(i) && !options[i]) {\n config[i] = defaultConfig[i];\n } else if (options[i]) {\n config[i] = options[i];\n }\n }\n config.url = prefix + '.js';\n config.frame = prefix + '.html';\n config.offline = prefix + '-offline.html';\n\n rsrc.type = 'text/javascript';\n packager(config, function (data) {\n rsrc.body = data;\n rsrc.headers = {\n 'Cache-Control': 'public, max-age=' + Math.floor(rsrc.maxAge / 1000),\n 'ETag': etag(data)\n };\n });\n}", "function hotlink(name){\n ipcRenderer.send('hotlink',name); \n}", "function _watch() {\r\n\r\n browserSync.init({\r\n notify: false,\r\n \r\n server: paths.dist\r\n });\r\n gulp.watch(paths.src_fonts, _fonts); \r\n gulp.watch('.'+paths.src_js+'**/*.js', _js)\r\n gulp.watch(paths.src_html,_html)\r\n gulp.watch(paths.src_images,_images)\r\n gulp.watch(paths.sub_scss, _sass_to_css) \r\n gulp.watch(paths.dist_html).on('change', browserSync.reload);\r\n \r\n}", "restart() {\n super.restart()\n }", "function BrowserSync() {\n this.bs = require(\"browser-sync\").create('bs-refresh');\n this.bs.init({\n open: false,\n proxy: `http://localhost:${devServerPort}/`,\n port: port,\n host: '0.0.0.0'\n });\n}", "async process () {\n this.context.resolveCacheLoaderOptions()\n this.watchSourceFiles()\n this.watchUserConfig()\n this.watchFrontmatter()\n this.setupDebugTip()\n await this.resolvePort()\n await this.resolveHost()\n this.prepareWebpackConfig()\n return this\n }", "function watch() {\n\tif(!production) {\n\t\tgulp.watch(paths.source, gulp.series( scaffold, reload ));\n\t\tgulp.watch(paths.src.styles + '**/*', styles);\n\t\tgulp.watch(paths.src.scripts + '**/*', scripts);\n\t\tgulp.watch(paths.src.images + '**/*', images);\n\t\tgulp.watch(paths.src.svgs + '**/*', gulp.series( svgSprite, scaffold ));\n\t}\n}", "function visitServer(state) {\n\ttabs.open(\"http://\" + require(\"sdk/simple-prefs\").prefs.pyLoadServer + \":\" + require(\"sdk/simple-prefs\").prefs.pyLoadPort);\n}", "function addHotjar(h, o, t, j, a, r) {\n\t\th.hj = h.hj || function() {\n\t\t\t(h.hj.q = h.hj.q || []).push(arguments);\n\t\t};\n\n\t\th._hjSettings = {\n\t\t\thjid: 61980,\n\t\t\thjsv: 5\n\t\t};\n\n\t\ta = o.getElementsByTagName('head')[0];\n\t\tr = o.createElement('script');\n\t\tr.async = 1;\n\t\tr.src = t + h._hjSettings.hjid + j + h._hjSettings.hjsv;\n\t\ta.appendChild(r);\n\t}", "function reloadWithDebugInfo() {\n window.name = 'NG_ENABLE_DEBUG_INFO!' + window.name;\n //window.location.reload();\n }", "static setup(){\n ejs.fileLoader = (filePath) => {\n return SourceRepository.fetchSync(filePath);\n };\n }", "function livereload() {\n return lazypipe()\n .pipe(isWatching ? browserSync.stream : noop)();\n}", "liveReload() {\n Ember.debug('You should override this method for map layer reload');\n }", "render() {\n return (\n <h1>Hello World!!!!!!!!!! OMG LIVE RELOADING</h1>\n );\n }", "function watchFiles() {\n\tsync.init({\n\t\topen: 'external',\n\t\tproxy: localsite,\n\t\tport: 8080\n\t});\t\n\n\t//watch for scss file changes\n\twatch(watchCss, buildCSS);\n\t//watch for js file changes\n\twatch(watchJs, series(cleanJS, parallel(buildVarsJS, buildsXHRJS, buildJS), concatJS, parallel(removeJssxhrResidue, removeJsvarsResidue, removeJsResidue)));\n\t//reload browser once changes are made\n\twatch([\n\t\tcssDest + cssOut,\n\t\tjsDest + jsOut,\n\t\twatchPhp \n\t\t]).on('change', sync.reload);\n}", "function watchTask() {\n watch(\"./src/html/**/*.+(html|njk)\", series(htmlComp, browsersyncReload));\n watch([\"./src/css/**/*.css\"], series(cssComp, browsersyncReload));\n watch([\"./src/js/**/*.js\"], series(jsComp, browsersyncReload));\n watch([\"./src/images/**/*.+(png|jpg|gif|svg)\"], series(imageminComp, browsersyncReload));\n}", "function startDevServer() {\n const app = express();\n const devConfig = getConfig('dev');\n //\n // devConfig.plugins.push(\n // new webpack.DllReferencePlugin({\n // context: srcPath,\n // manifest: require(manifestPath),\n // })\n // );\n\n const compiler = webpack(devConfig);\n app.use(\n devMiddleware(compiler, {\n publicPath: devConfig.output.publicPath,\n historyApiFallback: true,\n })\n );\n\n app.use(bodyParser.json()); // added by joli44\n\n app.use(hotMiddleware(compiler));\n\n // First, find files from src folder\n app.use(express.static(path.join(__dirname, '../src')));\n\n // Also support files from root folder, mainly for the dev-vendor bundle\n app.use(express.static(path.join(__dirname, '../')));\n\n // Proxy all calls /api when DEV to\n // const { rekit: { proxy: API } } = pkgJson;\n //\n // if (API) {\n // app.get('/api/*', (req, res) => req.pipe(request.get(`${API}${req.originalUrl}`)).pipe(res));\n // app.post('/api/*', (req, res) => req.pipe(request.post(`${API}${req.originalUrl}`)).pipe(res));\n // }\n\n console.log();\n console.log('------------------------------------------------------------');\n console.log('Ecster NOTE: set the no_proxy variable in your dev env to: ');\n console.log('no_proxy=localhost,127.0.0.1,se.shb.biz,shbmain.shb.biz');\n console.log('------------------------------------------------------------');\n console.log();\n\n const { rekit: { restPort } } = pkgJson;\n const proxyUrl = req => 'http://127.0.0.1:' + restPort + req.url;\n const proxyHeaders = req => ({\n 'X-ECSTER-origin': req.header('X-ECSTER-origin'),\n 'X-ECSTER-session': req.header('X-ECSTER-session'),\n cookie: req.header('cookie'),\n });\n\n // proxy all rest requests to Ecster dev server\n app.all('/rest/*', (req, res) => {\n console.log(req.method + ' on ' + req.url);\n request[req.method.toLowerCase()]({\n url: proxyUrl(req),\n rejectUnauthorized: false,\n headers: proxyHeaders(req),\n json: true,\n body: req.body,\n }).pipe(res);\n });\n\n // History api fallback\n app.use(fallback('index.html', { root: path.join(__dirname, '../src') }));\n\n // Other files should not happen, respond 404\n app.get('*', (req, res) => {\n console.log('Warning: unknown req: ', req.path);\n res.sendStatus(404);\n });\n\n app.listen(pkgJson.rekit.devPort, err => {\n if (err) {\n console.error(err);\n }\n console.log(`Dev server listening at http://localhost:${pkgJson.rekit.devPort}/`);\n // if (API) {\n // console.log(`Proxy to API Server(Only for dev): ${API}`);\n // }\n });\n}", "_loadInfo() {\n\t\tthis.taskConfig = JSON.parse(jetpack.read(this.taskData.configPath))\n\n\t\tlibrary.urlExists(this.taskData.serverHome, (err, exists) => {\n\t\t\tif (exists) {\n\t\t\t\tconsole.log(['\\'', this._parseUrl(this.taskData.serverHome), '\\' exist, starting testing...'].join(''))\n\t\t\t\tthis._startJob()\n\t\t\t}\n\t\t\telse {\n\t\t\t\tconsole.log(['\\'', this._parseUrl(this.taskData.serverHome), '\\' doesn\\'t exist, ending testing...'].join(''))\n\t\t\t\tthis._shutDown()\n\t\t\t}\n\t\t})\n\t}", "function openServer() {\n connect.server({\n host: cfg.server.host,\n root: cfg.server.root,\n port: cfg.server.port,\n livereload: true\n });\n }", "function watchTask() {\n browserSync.init({\n server: {\n baseDir: './pub/'\n }\n })\n watch(files.htmlPath, copyHTML).on('change', browserSync.reload);\n watch(files.imgPath, imageMin).on('change', browserSync.reload);\n watch(files.jsPath, jsTask).on('change', browserSync.reload);\n // watch(files.cssPath, cssTask).on('change', browserSync.reload);\n watch(files.sassPath, styleTask).on('change', browserSync.reload);\n}", "replacePublicPath(compiler) {\n const { mainTemplate } = compiler\n this.getHook(mainTemplate, 'require-extensions')((source, chunk, hash) => {\n const buildCode = [\n 'try {',\n ` return '${this.LOCAL_WEBPACK_SERVER.URI}/';`,\n '} catch (e) {',\n `console.error(\"${\n this.PLUGIN_NAME\n }: There was a problem with the public path.\")`,\n '}',\n ].join('\\n')\n\n return [\n source,\n `// ProxyPackDynamicUrl`,\n 'Object.defineProperty(' + mainTemplate.requireFn + ', \"p\", {',\n ' get: function () {',\n buildCode,\n ' }',\n '})',\n ].join('\\n')\n })\n }", "function watchServerCode() {\n gulp.watch(config.assets.server.js.app, {\n debounceDelay: watchDebounceDelay\n }, gulp.series(lintCode));\n}", "function watch_dev() {\r\n\t//re-build the bundles on file changes\r\n\tdetectChanges();\r\n}", "_watch(target, recurse) {\n let start,\n jsFileRE = /[\\w_$-]+\\.(js|jsx|ts)/,\n watchCB\n\n// Configure http and socket communications....\n this._configureHTTP()\n\n// Start the server...\n this._igniteServer(\n process.env.PORT || this.options.watchOpts.port || app.get('port')\n )\n\n watchCB =(fn, pass=false)=> {\n/// If the changed file is valid....\n if (pass || this._validFileName(fn)) {\n// Get start time.....\n start = Date.now()\n\n// Roll up a new bundle....\n this._bundleFiles(this.entryFile, ()=> {\n// Send message via websocket to browser...\n io.emit('file-change', { file: fn })\n })\n// Stop the timer and subtract start time to get elapsed bundle time....\n this.ms = Date.now() - start\n// Stop the spinner with success....\n this.spinner.succeed('🗞')\n }\n }\n\n if (jsFileRE.test(target)) {\n // log('TARGET', 'magenta');log(target)\n// watch the target directory for file changes....\n fs.watchFile(target, (curr, prev)=> {\n// Execute cb.......\n watchCB(target, true)\n })\n } else {\n/// watch the root directory for file changes....\n fs.watch(target, {recursive: recurse}, (event, fileName)=> {\n // log('FILENAME', ['red', 'bold']);log(fileName);log(fileName.includes(this.outputFile));\n// Execute cb.......\n watchCB(fileName)\n })\n }\n }", "function alwaysRunOnload () {\n\t\t// Placeholder/Future use.\n\t}", "function server () {\n browserSync.init({\n server: {\n baseDir: `./${devDir}`,\n },\n })\n\n gulp.watch('src/*.html', html)\n gulp.watch('src/views/**/*.{yml,pug}', views)\n gulp.watch('src/scss/**/*.scss', styles)\n gulp.watch('src/js/**/*.js', scripts)\n gulp.watch('src/img/**/*', images)\n gulp.watch('src/fonts/**/*', fonts)\n gulp.watch('src/static/**/*', statics)\n gulp.watch('src/**/*').on('change', browserSync.reload)\n}", "function loadRuntime()\n{\n var start = new Date().getTime();\n //Rethink runtime is included in index.html\n rethink.default.install(config).then((runtime) => {\n RUNTIME = runtime\n loadHypertyObs()\n });\n}", "function S(){null===_featureset_support_cache_js__WEBPACK_IMPORTED_MODULE_11__[\"default\"].applicationCache&&(_featureset_support_cache_js__WEBPACK_IMPORTED_MODULE_11__[\"default\"].applicationCache=new _featureset_support_cache_js__WEBPACK_IMPORTED_MODULE_11__[\"default\"])}", "function watch() {\n\n\t\t// SCRIPTS\n\t\tgulp.watch('./src/*.js').on('all', gulp.series(latest, browserSync.reload));\n\t\t// gulp.watch(['./src/shopback-plugin.js']).on('change', browserSync.reload);\n\n\t}", "function watcher() {\n src('src/js/livereload.js')\n .pipe(dest('dist/'));\n\n watch(['./src/**/*.html'], { ignoreInitial: false }, html);\n watch(['./src/**/.js'], { ignoreInitial: false }, series(min, cons));\n watch(['./src/**/.styl'], { ignoreInitial: false }, css);\n watch(['./src/images/**'], { ignoreInitial: false }, images);\n}", "function watch() {\n browserSync.init({\n server: {\n baseDir: './public'\n }\n });\n}", "lateLoad() {\n\n }", "function loadScripts(){\n renderer.setIPC();\n inject.uglifyScripts();\n inject.injectScripts();\n}", "'start' (callback) {\n //throw 'stop';\n //var resource_pool = this.resource_pool;\n\n var resource_pool = this.app_server.resource_pool;\n var server_router = this.resource_pool.get_resource('Server Router');\n // Build the client js and include that.\n // Could have been given a different client js file too.\n // By default want to provide the html client from jsgui.\n // /client/client\n\n // build the html client code.\n let js = this.app_server.resource_pool['Site JavaScript'];\n let css = this.app_server.resource_pool['Site CSS'];\n let imgs = this.app_server.resource_pool['Site Images'];\n\n\n\n // will look into the resource publisher to see what is published.\n\n // serve package with replacement options.\n // // the activate app function.\n // Can be put into place in the served JS.\n\n // with replacement option within serve_package\n\n let o_serve_package = {\n //'babel': 'mini'\n }\n\n // babel option.\n // Activation should be defined\n // Or there is some default activation in the client.js\n // It has the maps of controls and Controls\n // Then can activate these controls.\n // There should maybe be some more data services in the client.\n // Could make the client more miniature and modular once it works, and then incorporate react.\n // Data-Resource would be general enough to work on both.\n // The client data resources could then direct their requests to the server ones.\n // Could make a resource-pool for both client and server\n\n //console.log('this.activate_app', this.activate_app);\n //throw 'stop';\n\n // Should do this before the babel compilation. Think that's the sequence anyway.\n // Not sure why it's not working.\n if (this.activate_app) {\n o_serve_package.replace = {\n '/* -- ACTIVATE-APP -- */': this.activate_app.toString()\n }\n //\n }\n // want it to serve with debug code map\n // for the moment\n // want that to be easier to do with a --debug option.\n // should read command line options.\n o_serve_package.js_mode = 'mini';\n if (this.js_mode) {\n o_serve_package.js_mode = this.js_mode;\n } else {\n //o_serve_package.babel = 'mini';\n }\n // need to minify the js.\n // Also, gzip compression as standard.\n // Need HTTPS for Brotli - but want to get HTTPS working more, tested online and running.\n\n // Need to minify js, reduce file size.\n\n // Minifying currently breaks it.\n\n //o_serve_package.js_mode = 'debug';\n\n // Extra functionality for loading / serving icon files?\n // Easily available / usable named icons will be very useful within the app.\n // Could be in sprites / pre-loaded.\n\n\n\n\n // Not sure how to do the replace when loading from disk.\n // Give a reference to the package to serve itself.\n // example servers - \n // serve the css as well.\n if (this.css) {\n each(this.css, (path, serve_as) => {\n css.serve(serve_as, path);\n })\n }\n let js_client = this.client_package || this.js_client || 'jsgui3-client';\n js.serve_package('/js/app.js', js_client, o_serve_package, (err, served) => {\n //var resource_pool = this.resource_pool;\n //console.log('server_router', server_router);\n //console.log('js_client', js_client);\n if (!server_router) {\n throw 'no server_router';\n }\n var routing_tree = server_router.routing_tree;\n routing_tree.set('/', (req, res) => {\n //console.log('root path / request');\n\n const o_spc = {\n 'req': req,\n 'res': res,\n 'resource_pool': resource_pool\n }\n\n if (this.include_server_ref_in_page_context) o_spc.server = this;\n\n\n var server_page_context = new Server_Page_Context(o_spc);\n\n // and .server property?\n // a different way to get the server info to the components is needed.\n\n // Page_Bounds_Specifier\n var hd = new jsgui.Client_HTML_Document({\n 'context': server_page_context\n });\n hd.include_client_css();\n hd.include_css('/css/basic.css')\n\n if (this.css) {\n each(this.css, (path, serve_as) => {\n //css.serve(serve_as, path);\n hd.include_css('/css/' + serve_as);\n });\n }\n\n // include a js script block, having it set up the \n // not include_client_js\n\n // .include_client_config_js()\n // will get the resource config from the resource publisher.\n\n // including data on published resources in the initial html download would be very useful.\n // auto event wiring, so that controls that rely on having this data will have it available.\n\n // Want to get this to work, then greatly slim down the codebase, or at least delete comments, use some more syntactic sugar.\n\n // Calling 'publish' would be a good method.\n //console.log('this.app_server.map_resource_publishers', this.app_server.map_resource_publishers);\n //console.log('this.app_server.def_resource_publishers', this.app_server.def_resource_publishers);\n\n // a script block where we assign the resource publishers.\n // tell the client what resources are available on the server.\n\n // include a js script block.\n // jsgui.register_server_resources({...})\n // o_def\n // an object that describes how the resources are published.\n\n // app_server.def_resource_publishers\n // the urls\n // what data it provides / its schema.\n // a def from each of the publishers\n // with a schema similar to graphql?\n\n //throw 'stop';\n\n var body = hd.body;\n let o_params = this.params || {};\n Object.assign(o_params, {\n 'context': server_page_context\n });\n //console.log('o_params', o_params);\n //console.log('this.Ctrl', this.Ctrl);\n var ctrl = this.ctrl = new this.Ctrl(o_params);\n ctrl.active();\n //var ctrl2 = new jsgui.Control({});\n body.add(ctrl);\n\n let resources_script = new jsgui.script({\n context: server_page_context\n });\n // it will be a client-side function.\n\n // Should not use 'add' here.\n // it's the script content.\n\n // want to get around that escaping.\n // options escaping / escape : false\n\n hd.include_js('/js/app.js');\n\n // Would this be a place to register icons?\n\n\n const strc = new jsgui.String_Control({\n context: server_page_context,\n\n // Won't have access to the context when registering there?\n // Will need to access the client-side context.\n // Setting jsgui.context on the client-side does make sense.\n // There would only be one context per instance of jsgui on the client.\n\n // Could raise an event on jsgui, which the page_context listens to?\n // The calls need to be set up within the page_context, I think.\n\n // Could just set the def_server_resources property.\n // Then later activation with the page_context could refer to it.\n\n // setting up the def_resource_publishers\n // maybe 'resource' will be a generic term for something in some place.\n // can be non-local, but api will localise its use.\n\n text: `jsgui.register_server_resources(${JSON.stringify(this.app_server.def_resource_publishers)});`\n });\n\n resources_script.add(strc);\n body.add(resources_script);\n \n hd.all_html_render(function (err, deferred_html) {\n if (err) {\n throw err;\n } else {\n //console.log('deferred_html', deferred_html);\n var mime_type = 'text/html';\n //console.log('mime_type ' + mime_type);\n res.writeHead(200, {\n 'Content-Type': mime_type\n });\n res.end('<!DOCTYPE html>' + deferred_html, 'utf-8');\n }\n });\n });\n //console.log('pre super start');\n\n super.start(this.port, (err, res_super_start) => {\n if (err) {\n callback(err);\n } else {\n //console.log('res_super_start', res_super_start);\n this.raise('scs_ready');\n callback(null, res_super_start);\n }\n });\n });\n // console.log('this.port', this.port);\n }", "async function appJsUpdate() {\n /** reading content */\n const content = await readFile(\n appSrcFile,\n 'Failed reading test_space/src/app.js.',\n );\n\n /** changing content */\n const updateContent = content.replace(/RESTART_V1/g, 'RESTART_V2');\n await writeFile(\n appSrcFile,\n updateContent,\n 'Failed to update test_space/src/app.js.',\n );\n\n /**\n * Listening to stdout (console)\n */\n await listenToRestart(execOutput.data.childProcess, 'appJsUpdate');\n\n /**\n * webpack compiled\n * No rejection\n *\n * Check the output file\n * */\n\n const outContent = await readFile(appOutFile, 'Fail to read dist/app.js.');\n sm.snap('appJs:recompiled', { content, updateContent, outContent });\n }", "function hotCreateRequire(moduleId) {\n/******/ \t\tvar me = installedModules[moduleId];\n/******/ \t\tif (!me) return __webpack_require__;\n/******/ \t\tvar fn = function(request) {\n/******/ \t\t\tif (me.hot.active) {\n/******/ \t\t\t\tif (installedModules[request]) {\n/******/ \t\t\t\t\tif (installedModules[request].parents.indexOf(moduleId) === -1) {\n/******/ \t\t\t\t\t\tinstalledModules[request].parents.push(moduleId);\n/******/ \t\t\t\t\t}\n/******/ \t\t\t\t} else {\n/******/ \t\t\t\t\thotCurrentParents = [moduleId];\n/******/ \t\t\t\t\thotCurrentChildModule = request;\n/******/ \t\t\t\t}\n/******/ \t\t\t\tif (me.children.indexOf(request) === -1) {\n/******/ \t\t\t\t\tme.children.push(request);\n/******/ \t\t\t\t}\n/******/ \t\t\t} else {\n/******/ \t\t\t\tconsole.warn(\n/******/ \t\t\t\t\t\"[HMR] unexpected require(\" +\n/******/ \t\t\t\t\t\trequest +\n/******/ \t\t\t\t\t\t\") from disposed module \" +\n/******/ \t\t\t\t\t\tmoduleId\n/******/ \t\t\t\t);\n/******/ \t\t\t\thotCurrentParents = [];\n/******/ \t\t\t}\n/******/ \t\t\treturn __webpack_require__(request);\n/******/ \t\t};\n/******/ \t\tvar ObjectFactory = function ObjectFactory(name) {\n/******/ \t\t\treturn {\n/******/ \t\t\t\tconfigurable: true,\n/******/ \t\t\t\tenumerable: true,\n/******/ \t\t\t\tget: function() {\n/******/ \t\t\t\t\treturn __webpack_require__[name];\n/******/ \t\t\t\t},\n/******/ \t\t\t\tset: function(value) {\n/******/ \t\t\t\t\t__webpack_require__[name] = value;\n/******/ \t\t\t\t}\n/******/ \t\t\t};\n/******/ \t\t};\n/******/ \t\tfor (var name in __webpack_require__) {\n/******/ \t\t\tif (\n/******/ \t\t\t\tObject.prototype.hasOwnProperty.call(__webpack_require__, name) &&\n/******/ \t\t\t\tname !== \"e\" &&\n/******/ \t\t\t\tname !== \"t\"\n/******/ \t\t\t) {\n/******/ \t\t\t\tObject.defineProperty(fn, name, ObjectFactory(name));\n/******/ \t\t\t}\n/******/ \t\t}\n/******/ \t\tfn.e = function(chunkId) {\n/******/ \t\t\tif (hotStatus === \"ready\") hotSetStatus(\"prepare\");\n/******/ \t\t\thotChunksLoading++;\n/******/ \t\t\treturn __webpack_require__.e(chunkId).then(finishChunkLoading, function(err) {\n/******/ \t\t\t\tfinishChunkLoading();\n/******/ \t\t\t\tthrow err;\n/******/ \t\t\t});\n/******/\n/******/ \t\t\tfunction finishChunkLoading() {\n/******/ \t\t\t\thotChunksLoading--;\n/******/ \t\t\t\tif (hotStatus === \"prepare\") {\n/******/ \t\t\t\t\tif (!hotWaitingFilesMap[chunkId]) {\n/******/ \t\t\t\t\t\thotEnsureUpdateChunk(chunkId);\n/******/ \t\t\t\t\t}\n/******/ \t\t\t\t\tif (hotChunksLoading === 0 && hotWaitingFiles === 0) {\n/******/ \t\t\t\t\t\thotUpdateDownloaded();\n/******/ \t\t\t\t\t}\n/******/ \t\t\t\t}\n/******/ \t\t\t}\n/******/ \t\t};\n/******/ \t\tfn.t = function(value, mode) {\n/******/ \t\t\tif (mode & 1) value = fn(value);\n/******/ \t\t\treturn __webpack_require__.t(value, mode & ~1);\n/******/ \t\t};\n/******/ \t\treturn fn;\n/******/ \t}", "function watch() {\n gulp.watch([IOWA.appDir + '/**/*.html'], reload);\n gulp.watch([IOWA.appDir + '/{elements,styles}/**/*.{scss,css}'], ['sass', reload]);\n gulp.watch([IOWA.appDir + '/scripts/**/*.js'], ['jshint']);\n gulp.watch([IOWA.appDir + '/images/**/*'], reload);\n gulp.watch([IOWA.appDir + '/bower.json'], ['bower']);\n gulp.watch(dataWorkerScripts, ['generate-data-worker-dev']);\n}", "function watch(){\n\n browser_Sync.init({\n server: {\n baseDir: \"app\"\n }\n });\n\n gulp.watch('app/*.html').on('change', browser_Sync.reload);\n gulp.watch('app/assets/css/**/*.css', styles_files);\n gulp.watch('app/assets/js/**/*.js', scripts_files);\n\n\n}", "function watchTask() {\r\n watch(\r\n [files.scssPath, files.htmlPath],\r\n series(scssTask, reloadTask)\r\n )\r\n}", "function serve() {\n browserSync.init({\n server: 'dist/'\n });\n\n watch(srcPaths.html, { interval: 1000 }, html);\n watch(srcPaths.scripts, { interval: 1000 }, scripts);\n watch(srcPaths.styles, { interval: 1000 }, styles);\n watch(srcPaths.images, { interval: 1000 }, images)\n}", "function hotCreateRequire(moduleId) {\n/******/ \t\tvar me = installedModules[moduleId];\n/******/ \t\tif (!me) return __webpack_require__;\n/******/ \t\tvar fn = function(request) {\n/******/ \t\t\tif (me.hot.active) {\n/******/ \t\t\t\tif (installedModules[request]) {\n/******/ \t\t\t\t\tif (installedModules[request].parents.indexOf(moduleId) === -1)\n/******/ \t\t\t\t\t\tinstalledModules[request].parents.push(moduleId);\n/******/ \t\t\t\t} else {\n/******/ \t\t\t\t\thotCurrentParents = [moduleId];\n/******/ \t\t\t\t\thotCurrentChildModule = request;\n/******/ \t\t\t\t}\n/******/ \t\t\t\tif (me.children.indexOf(request) === -1) me.children.push(request);\n/******/ \t\t\t} else {\n/******/ \t\t\t\tconsole.warn(\n/******/ \t\t\t\t\t\"[HMR] unexpected require(\" +\n/******/ \t\t\t\t\t\trequest +\n/******/ \t\t\t\t\t\t\") from disposed module \" +\n/******/ \t\t\t\t\t\tmoduleId\n/******/ \t\t\t\t);\n/******/ \t\t\t\thotCurrentParents = [];\n/******/ \t\t\t}\n/******/ \t\t\treturn __webpack_require__(request);\n/******/ \t\t};\n/******/ \t\tvar ObjectFactory = function ObjectFactory(name) {\n/******/ \t\t\treturn {\n/******/ \t\t\t\tconfigurable: true,\n/******/ \t\t\t\tenumerable: true,\n/******/ \t\t\t\tget: function() {\n/******/ \t\t\t\t\treturn __webpack_require__[name];\n/******/ \t\t\t\t},\n/******/ \t\t\t\tset: function(value) {\n/******/ \t\t\t\t\t__webpack_require__[name] = value;\n/******/ \t\t\t\t}\n/******/ \t\t\t};\n/******/ \t\t};\n/******/ \t\tfor (var name in __webpack_require__) {\n/******/ \t\t\tif (\n/******/ \t\t\t\tObject.prototype.hasOwnProperty.call(__webpack_require__, name) &&\n/******/ \t\t\t\tname !== \"e\"\n/******/ \t\t\t) {\n/******/ \t\t\t\tObject.defineProperty(fn, name, ObjectFactory(name));\n/******/ \t\t\t}\n/******/ \t\t}\n/******/ \t\tfn.e = function(chunkId) {\n/******/ \t\t\tif (hotStatus === \"ready\") hotSetStatus(\"prepare\");\n/******/ \t\t\thotChunksLoading++;\n/******/ \t\t\treturn __webpack_require__.e(chunkId).then(finishChunkLoading, function(err) {\n/******/ \t\t\t\tfinishChunkLoading();\n/******/ \t\t\t\tthrow err;\n/******/ \t\t\t});\n/******/\n/******/ \t\t\tfunction finishChunkLoading() {\n/******/ \t\t\t\thotChunksLoading--;\n/******/ \t\t\t\tif (hotStatus === \"prepare\") {\n/******/ \t\t\t\t\tif (!hotWaitingFilesMap[chunkId]) {\n/******/ \t\t\t\t\t\thotEnsureUpdateChunk(chunkId);\n/******/ \t\t\t\t\t}\n/******/ \t\t\t\t\tif (hotChunksLoading === 0 && hotWaitingFiles === 0) {\n/******/ \t\t\t\t\t\thotUpdateDownloaded();\n/******/ \t\t\t\t\t}\n/******/ \t\t\t\t}\n/******/ \t\t\t}\n/******/ \t\t};\n/******/ \t\treturn fn;\n/******/ \t}", "function hotCreateRequire(moduleId) {\n/******/ \t\tvar me = installedModules[moduleId];\n/******/ \t\tif (!me) return __webpack_require__;\n/******/ \t\tvar fn = function(request) {\n/******/ \t\t\tif (me.hot.active) {\n/******/ \t\t\t\tif (installedModules[request]) {\n/******/ \t\t\t\t\tif (installedModules[request].parents.indexOf(moduleId) === -1)\n/******/ \t\t\t\t\t\tinstalledModules[request].parents.push(moduleId);\n/******/ \t\t\t\t} else {\n/******/ \t\t\t\t\thotCurrentParents = [moduleId];\n/******/ \t\t\t\t\thotCurrentChildModule = request;\n/******/ \t\t\t\t}\n/******/ \t\t\t\tif (me.children.indexOf(request) === -1) me.children.push(request);\n/******/ \t\t\t} else {\n/******/ \t\t\t\tconsole.warn(\n/******/ \t\t\t\t\t\"[HMR] unexpected require(\" +\n/******/ \t\t\t\t\t\trequest +\n/******/ \t\t\t\t\t\t\") from disposed module \" +\n/******/ \t\t\t\t\t\tmoduleId\n/******/ \t\t\t\t);\n/******/ \t\t\t\thotCurrentParents = [];\n/******/ \t\t\t}\n/******/ \t\t\treturn __webpack_require__(request);\n/******/ \t\t};\n/******/ \t\tvar ObjectFactory = function ObjectFactory(name) {\n/******/ \t\t\treturn {\n/******/ \t\t\t\tconfigurable: true,\n/******/ \t\t\t\tenumerable: true,\n/******/ \t\t\t\tget: function() {\n/******/ \t\t\t\t\treturn __webpack_require__[name];\n/******/ \t\t\t\t},\n/******/ \t\t\t\tset: function(value) {\n/******/ \t\t\t\t\t__webpack_require__[name] = value;\n/******/ \t\t\t\t}\n/******/ \t\t\t};\n/******/ \t\t};\n/******/ \t\tfor (var name in __webpack_require__) {\n/******/ \t\t\tif (\n/******/ \t\t\t\tObject.prototype.hasOwnProperty.call(__webpack_require__, name) &&\n/******/ \t\t\t\tname !== \"e\"\n/******/ \t\t\t) {\n/******/ \t\t\t\tObject.defineProperty(fn, name, ObjectFactory(name));\n/******/ \t\t\t}\n/******/ \t\t}\n/******/ \t\tfn.e = function(chunkId) {\n/******/ \t\t\tif (hotStatus === \"ready\") hotSetStatus(\"prepare\");\n/******/ \t\t\thotChunksLoading++;\n/******/ \t\t\treturn __webpack_require__.e(chunkId).then(finishChunkLoading, function(err) {\n/******/ \t\t\t\tfinishChunkLoading();\n/******/ \t\t\t\tthrow err;\n/******/ \t\t\t});\n/******/\n/******/ \t\t\tfunction finishChunkLoading() {\n/******/ \t\t\t\thotChunksLoading--;\n/******/ \t\t\t\tif (hotStatus === \"prepare\") {\n/******/ \t\t\t\t\tif (!hotWaitingFilesMap[chunkId]) {\n/******/ \t\t\t\t\t\thotEnsureUpdateChunk(chunkId);\n/******/ \t\t\t\t\t}\n/******/ \t\t\t\t\tif (hotChunksLoading === 0 && hotWaitingFiles === 0) {\n/******/ \t\t\t\t\t\thotUpdateDownloaded();\n/******/ \t\t\t\t\t}\n/******/ \t\t\t\t}\n/******/ \t\t\t}\n/******/ \t\t};\n/******/ \t\treturn fn;\n/******/ \t}", "function hotCreateRequire(moduleId) {\n/******/ \t\tvar me = installedModules[moduleId];\n/******/ \t\tif (!me) return __webpack_require__;\n/******/ \t\tvar fn = function(request) {\n/******/ \t\t\tif (me.hot.active) {\n/******/ \t\t\t\tif (installedModules[request]) {\n/******/ \t\t\t\t\tif (installedModules[request].parents.indexOf(moduleId) === -1)\n/******/ \t\t\t\t\t\tinstalledModules[request].parents.push(moduleId);\n/******/ \t\t\t\t} else {\n/******/ \t\t\t\t\thotCurrentParents = [moduleId];\n/******/ \t\t\t\t\thotCurrentChildModule = request;\n/******/ \t\t\t\t}\n/******/ \t\t\t\tif (me.children.indexOf(request) === -1) me.children.push(request);\n/******/ \t\t\t} else {\n/******/ \t\t\t\tconsole.warn(\n/******/ \t\t\t\t\t\"[HMR] unexpected require(\" +\n/******/ \t\t\t\t\t\trequest +\n/******/ \t\t\t\t\t\t\") from disposed module \" +\n/******/ \t\t\t\t\t\tmoduleId\n/******/ \t\t\t\t);\n/******/ \t\t\t\thotCurrentParents = [];\n/******/ \t\t\t}\n/******/ \t\t\treturn __webpack_require__(request);\n/******/ \t\t};\n/******/ \t\tvar ObjectFactory = function ObjectFactory(name) {\n/******/ \t\t\treturn {\n/******/ \t\t\t\tconfigurable: true,\n/******/ \t\t\t\tenumerable: true,\n/******/ \t\t\t\tget: function() {\n/******/ \t\t\t\t\treturn __webpack_require__[name];\n/******/ \t\t\t\t},\n/******/ \t\t\t\tset: function(value) {\n/******/ \t\t\t\t\t__webpack_require__[name] = value;\n/******/ \t\t\t\t}\n/******/ \t\t\t};\n/******/ \t\t};\n/******/ \t\tfor (var name in __webpack_require__) {\n/******/ \t\t\tif (\n/******/ \t\t\t\tObject.prototype.hasOwnProperty.call(__webpack_require__, name) &&\n/******/ \t\t\t\tname !== \"e\"\n/******/ \t\t\t) {\n/******/ \t\t\t\tObject.defineProperty(fn, name, ObjectFactory(name));\n/******/ \t\t\t}\n/******/ \t\t}\n/******/ \t\tfn.e = function(chunkId) {\n/******/ \t\t\tif (hotStatus === \"ready\") hotSetStatus(\"prepare\");\n/******/ \t\t\thotChunksLoading++;\n/******/ \t\t\treturn __webpack_require__.e(chunkId).then(finishChunkLoading, function(err) {\n/******/ \t\t\t\tfinishChunkLoading();\n/******/ \t\t\t\tthrow err;\n/******/ \t\t\t});\n/******/\n/******/ \t\t\tfunction finishChunkLoading() {\n/******/ \t\t\t\thotChunksLoading--;\n/******/ \t\t\t\tif (hotStatus === \"prepare\") {\n/******/ \t\t\t\t\tif (!hotWaitingFilesMap[chunkId]) {\n/******/ \t\t\t\t\t\thotEnsureUpdateChunk(chunkId);\n/******/ \t\t\t\t\t}\n/******/ \t\t\t\t\tif (hotChunksLoading === 0 && hotWaitingFiles === 0) {\n/******/ \t\t\t\t\t\thotUpdateDownloaded();\n/******/ \t\t\t\t\t}\n/******/ \t\t\t\t}\n/******/ \t\t\t}\n/******/ \t\t};\n/******/ \t\treturn fn;\n/******/ \t}", "function watch() {\n\n gulp.watch('src/pages/**/*.html').on('all', gulp.series(pages, browser.reload));\n gulp.watch('src/{layouts,partials}/**/*.html').on('all', gulp.series(resetPages, pages, browser.reload));\n gulp.watch('src/{data}/**/*.json').on('all', gulp.series(resetPages, pages, browser.reload));\n gulp.watch('src/assets/scss/**/*.scss').on('all', sassToCss);\n gulp.watch('src/assets/media/**/*').on('all', gulp.series(images, browser.reload));\n gulp.watch(['src/**/*.js']).on('all', gulp.series(['webpack'], browser.reload));\n\n\n}", "relaunch() {}", "function reload() {\n\tbrowserSync.reload();\n}", "function launchBrowserSync() {\n browserSync.init({\n proxy: {\n target: springWebServerAddress,\n ws: true\n },\n open: false,\n browser: \"chrome\",\n });\n\n /* the reload-trigger file is updated by spring on change */\n gulp.watch(\"reload-trigger\", {usePolling: true}).on(\"change\", browserSync.reload);\n}", "constructor() {\n this.debug = false;\n this.version = 1.6;\n this.production = false;\n this.myRoute = 'serviceWorker.js';\n this.lastRequestTime = 0;\n this.log('running from scratch...');\n this.addEventListeners();\n }", "_environmentChanged() {}", "load() {}", "load() {}" ]
[ "0.70286053", "0.6826523", "0.63319314", "0.62796295", "0.6268212", "0.6264822", "0.62478137", "0.616398", "0.61261386", "0.6096019", "0.6022346", "0.59880954", "0.59849447", "0.59617066", "0.5904842", "0.58831954", "0.5882334", "0.5870729", "0.58478725", "0.5840752", "0.5812762", "0.57868254", "0.5777183", "0.577691", "0.57505697", "0.5739818", "0.5739772", "0.5739772", "0.57266015", "0.57225716", "0.5718021", "0.57083404", "0.56940776", "0.5662976", "0.56613535", "0.56605643", "0.5657415", "0.5653817", "0.5647299", "0.56466436", "0.56170106", "0.5609713", "0.5579388", "0.5579232", "0.5576881", "0.5576587", "0.5563962", "0.5555251", "0.55423737", "0.5538446", "0.5534832", "0.5531248", "0.5530379", "0.552525", "0.5523212", "0.5520388", "0.5520341", "0.55078685", "0.550737", "0.5494785", "0.5494448", "0.54921013", "0.5486605", "0.546725", "0.5466271", "0.54649025", "0.5453278", "0.544675", "0.54436594", "0.54406357", "0.5434819", "0.5434216", "0.54294467", "0.5428275", "0.54202175", "0.54182315", "0.54148805", "0.5408408", "0.5407645", "0.54059744", "0.53987795", "0.5392896", "0.53926426", "0.538683", "0.53833705", "0.5373659", "0.5373519", "0.5369663", "0.5362784", "0.53619", "0.53615797", "0.53615797", "0.53615797", "0.53583175", "0.5355446", "0.5353342", "0.5351747", "0.5349912", "0.5349101", "0.5348258", "0.5348258" ]
0.0
-1
Copy the entire credentials JSON file from creating a service account in GCP.
function getServiceAccountCreds() { return JSON.parse(scriptProperties.getProperty(SERVICE_ACCOUNT_CREDS)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function setUpAuth () {\n const serviceAccount = JSON.parse(fs.readFileSync(program.service_account_json));\n const jwtAccess = new google.auth.JWT();\n jwtAccess.fromJSON(serviceAccount);\n // Note that if you require additional scopes, they should be specified as a\n // string, separated by spaces.\n jwtAccess.scopes = 'https://www.googleapis.com/auth/cloud-platform';\n // Set the default authentication to the above JWT access.\n google.options({ auth: jwtAccess });\n}", "function createCredentialsFile() {\n\tprompt.start();\n\tprompt.get({\n\t\tproperties: {\n\t\t\tusername: {\n\t\t\t\tdescription: 'Your Twitch.tv username',\n\t\t\t\trequired: true\n\t\t\t},\n\t\t\tpassword: {\n\t\t\t\tdescription: 'Your Twitch.tv OAUTH token (http://www.twitchapps.com/tmi/)',\n\t\t\t\trequired: true,\n\t\t\t\thidden: false\n\t\t\t},\n\t\t\tchannel: {\n\t\t\t\tdescription: 'Twitch.tv channel to join',\n\t\t\t\trequired: true\n\t\t\t},\n\t\t\tclient_id: {\n\t\t\t\tdescription: 'Twitch API Client ID',\n\t\t\t\trequired: true\n\t\t\t},\n\t\t\tclient_secret: {\n\t\t\t\tdescription: 'Twitch API Client Secret',\n\t\t\t\trequired: true\n\t\t\t},\n\t\t\tstreamtip_client_id: {\n\t\t\t\tdescription: 'StreamTip API Client ID',\n\t\t\t\trequired: false\n\t\t\t},\n\t\t\tstreamtip_client_access_token: {\n\t\t\t\tdescription: 'StreamTip API Client Access Token',\n\t\t\t\trequired: false\n\t\t\t}\n\t\t}\n\t}, function (err, result) {\n\t\tvar credentials = {\n\t\t\t'username': result.username,\n\t\t\t'password': result.password,\n\t\t\t'channel': result.channel,\n\t\t\t'client_id': result.client_id,\n\t\t\t'client_secret': result.client_secret\n\t\t};\n\t\tfs.writeFileSync('.credentials', JSON.stringify(credentials));\n\n\t\tconsole.log('Created credentials file. Restart the application\\n');\n\t\tprocess.exit();\n\t});\n}", "function replaceServiceAccountJson(options) {\n let svcAccountJson = require(options.serviceAccountFilename);\n let svcAccountStr = JSON.stringify(svcAccountJson).replace(/\\r?\\n|\\r/g, \" \");\n options.serviceAccount = svcAccountStr;\n}", "async function saveKey() {\n try {\n const key = process.env[\"GOOGLE_KEY_VALUE\"];\n const keyFile = join(cwd(), \"gcp-key.json\");\n await writeFile(keyFile, key, { mode: 0o600 });\n } catch (err) {\n console.warn(`Could not find Google service account key: ${err}`);\n }\n}", "function run() {\n fs.readFile('credentials.json', (err, content) => {\n if (err) return console.log('Error loading client secret file:', err);\n // Authorize a client with credentials, then call the Google Sheets API.\n return authorize(JSON.parse(content), getData);\n });\n }", "static get credFilePath () {\n return path.join(__dirname, '..', '.credentials')\n }", "function getCredentials() {\n return new Promise( function( resolve, reject ) {\n // Load the client secret for accessing our project\n fs.readFile( 'client_secret.json', function processClientSecrets( err, content ) {\n if( err ) {\n console.log( 'Error loading client secret file: ' + err );\n reject( err );\n } else {\n //console.log( 'content: ', JSON.stringify( JSON.parse( content ) ) );\n // Hand back the credentials we have currently\n resolve( JSON.parse( content ) );\n }\n } );\n } );\n}", "function run() {\n fs.readFile('credentials.json', (err, content) => {\n if (err) return console.log('Error loading client secret file:', err);\n // Authorize a client with credentials, then call the Google Sheets API.\n authorize(JSON.parse(content), getData);\n });\n}", "function createJSON() {\n return {\n 'private_key_id': 'key123',\n 'private_key': 'privatekey',\n 'client_email': '[email protected]',\n 'client_id': 'client123',\n 'type': 'service_account'\n };\n}", "GivesForCustomerCredentialsToAccesssSwiftAccount(serviceName) {\n let url = `/cdn/webstorage/${serviceName}/credentials`;\n return this.client.request('GET', url);\n }", "function fromCredentialFile(callback) {\n if (!process.env.AWS_CREDENTIAL_FILE) return callback(\"AWS_CREDENTIAL_FILE not in ENV\");\n\n var aws_path = path.resolve(process.env.AWS_CREDENTIAL_FILE.replace(\"~\", process.env.HOME));\n fs.readFile(aws_path, \"utf8\", function(err, aws_creds) {\n if (err) callback(err);\n\n callback(null, {\n key: aws_creds.match(/^AWSAccessKeyId\\s*=\\s*(\\S+)$/mi)[1]\n , secret: aws_creds.match(/^AWSSecretKey\\s*=\\s*(\\S+)$/mi)[1]\n });\n });\n}", "async copyFilesToServiceDirectory () {\n try {\n // Create keys directory\n await fs.ensureDir('/service/keys');\n\n // Copy polkadot node key file\n console.log(`Copying ${config.polkadotNodeKeyFile} from /config/ to /service/keys/...`);\n await fs.copy(`/config/${config.polkadotNodeKeyFile}`, `/service/keys/${config.polkadotNodeKeyFile}`);\n\n // Fix permissions\n await fs.chown('/service', config.polkadotUnixUserId, config.polkadotUnixGroupId);\n await fs.chown('/service/keys', config.polkadotUnixUserId, config.polkadotUnixGroupId);\n await fs.chown(`/service/keys/${config.polkadotNodeKeyFile}`, config.polkadotUnixUserId, config.polkadotUnixGroupId);\n } catch (error) {\n debug('copyFilesToServiceDirectory', error);\n throw error;\n }\n }", "reloadCredentials(){\n return new Promise((resolve, reject)=>{\n creds = new AWS.FileSystemCredentials(this._credentialsFile); //https://docs.aws.amazon.com/AWSJavaScriptSDK/latest/AWS/FileSystemCredentials.html\n checkForCredentials(this._credentialsFile)\n .then(()=>{\n this.haveCredentials = true;\n iam = new AWS.IAM({accessKeyId: creds.accessKeyId, secretAccessKey: creds.secretAccessKey, region: this._region});\n kms = new AWS.KMS({accessKeyId: creds.accessKeyId, secretAccessKey: creds.secretAccessKey, region: this._region});\n getUser()\n .then((dObj)=>{\n this.userName = dObj.User.UserName\n this.userID = dObj.User.UserId\n this.userArn = dObj.User.Arn\n resolve();\n })\n .catch((err)=>{\n this.haveCredentials = false;\n console.error('Error verifying credentials details follow:', err)\n reject(err);\n })\n })\n .catch((err)=>{\n this.haveCredentials = false;\n console.error('Error: awsAccManClass error while reloading credentials for AWS IAM credentials.', err);\n reject(err);\n });\n });\n }", "function saveToGoogleDrive(name, readPath) {\n\tfs.readFile('client_secret_node.json', function processClientSecrets(err, content) {\n\t if (err) {\n\t console.log('Error loading client secret file: ' + err);\n\t return;\n\t }\n\t // Authorize a client with the loaded credentials, then call the\n\t // Drive API.\n\t authorize(JSON.parse(content), listFiles, name, readPath);\n\t});\n}", "function getCredentialsFromFile() {\n // were using the syncronous reaadFile function here because we nee to acquire credentials before performing any other action\n // so we are okay with the exception here.\n const data = fs.readFileSync(homeDir + '/.rf/credentials', 'utf8');\n const file = data.split('\\n');\n const profile = process.env.RF_PROFILE || 'default';\n const index = file.indexOf('[' + profile + ']');\n\n // if we have a match, trim the elements, split on '=' and return the values in an object\n if (index !== -1) {\n return {\n RF_CLIENT_ID: file[index + 1].trim().split('=')[1],\n RF_SECRET: file[index + 2].trim().split('=')[1],\n RF_BASE_URL: file[index + 3].trim().split('=')[1] || ''\n };\n }\n\n return {};\n}", "async getCredentials() {\n\n\t\tconst fileExpiration = this.fileExpiration || this.data.fileExpiration;\n\n\t\tconst requestData = {\n\t\t\t...this.data,\n\t\t\t...fileExpiration && { fileExpiration },\n\t\t\tserviceName: process.env.JANIS_SERVICE_NAME,\n\t\t\tentity: this.entity\n\t\t};\n\n\t\tconst { payload, statusCode } = await Invoker.serviceSafeClientCall('storage', 'GetCredentials', this.session.clientCode, requestData);\n\n\t\tif(statusCode >= 400)\n\t\t\tthrow new Error('Fail getting credentials');\n\n\t\tif(isEmpty(payload))\n\t\t\treturn {};\n\n\t\treturn payload;\n\t}", "function readCredentialsFile(name) { \n return fs.readFileSync(\n path.resolve(__dirname, 'server/credentials', name),\n 'UTF-8'\n );\n}", "function addCredentials(){\n var html = HtmlService.createHtmlOutputFromFile('Credentials')\n .setWidth(400)\n .setHeight(300);\n SpreadsheetApp.getUi() // Or DocumentApp or SlidesApp or FormApp.\n .showModalDialog(html, 'API Credentials')\n }", "function getAuth() {\n const auth = new google.auth.GoogleAuth({\n keyFile: 'credentials.json',\n scopes: 'https://www.googleapis.com/auth/spreadsheets',\n });\n return auth;\n}", "function makeCredentialsProvider(credentials){if(!credentials){return new EmptyCredentialsProvider();}switch(credentials.type){case'gapi':return new FirstPartyCredentialsProvider(credentials.client,credentials.sessionIndex||'0');case'provider':return credentials.client;default:throw new index_esm_FirestoreError(Code.INVALID_ARGUMENT,'makeCredentialsProvider failed due to invalid credential type');}}", "async function initPrivateGit(credentials) {\n await execa_1.default('git', [\n 'config',\n '--global',\n 'credential.helper',\n `store --file ${path_1.join(os_1.homedir(), '.git-credentials')}`,\n ]);\n await fs_extra_1.writeFile(path_1.join(os_1.homedir(), '.git-credentials'), credentials);\n}", "static async ensureServiceUser(parentAccount) {\n const resp = await execPath(\n NODE_INTERPRETER,\n [ensureServiceUser, 'apply', 'service-utapi-user'],\n {\n AWS_ACCESS_KEY_ID: parentAccount.accessKey,\n AWS_SECRET_ACCESS_KEY: parentAccount.secretKey,\n AWS_REGION: 'us-east-1',\n NODE_TLS_REJECT_UNAUTHORIZED: '0',\n PATH: process.env.PATH,\n },\n );\n\n if (!resp) {\n throw new Error('No response from ensureServiceUser');\n }\n\n const { data } = JSON.parse(resp);\n\n return {\n accessKey: data.AccessKeyId,\n secretKey: data.SecretAccessKey,\n name: data.UserName,\n };\n }", "function main(\n bucketName = 'my-bucket',\n contents = 'these are my file contents',\n destFileName = 'file.txt',\n generationMatchPrecondition = 0\n) {\n // [START storage_upload_without_authentication]\n /**\n * TODO(developer): Uncomment the following lines before running the sample.\n */\n // The ID of your GCS bucket\n // const bucketName = 'your-unique-bucket-name';\n\n // The contents that you want to upload\n // const contents = 'these are my contents';\n\n // The new ID for your GCS file\n // const destFileName = 'your-new-file-name';\n\n // Imports the Google Cloud Node.js client library\n const {Storage} = require('@google-cloud/storage');\n\n // Creates a client\n const storage = new Storage();\n\n async function uploadWithoutAuthentication() {\n const file = storage.bucket(bucketName).file(destFileName);\n\n // Returns an authenticated endpoint to which\n // you can make requests without credentials.\n const [location] = await file.createResumableUpload(); //auth required\n\n const options = {\n uri: location,\n resumable: true,\n validation: false,\n\n // Optional:\n // Set a generation-match precondition to avoid potential race conditions\n // and data corruptions. The request to upload is aborted if the object's\n // generation number does not match your precondition. For a destination\n // object that does not yet exist, set the ifGenerationMatch precondition to 0\n // If the destination object already exists in your bucket, set instead a\n // generation-match precondition using its generation number.\n preconditionOpts: {ifGenerationMatch: generationMatchPrecondition},\n };\n\n // Passes the location to file.save so you don't need to\n // authenticate this call\n await file.save(contents, options);\n\n console.log(`${destFileName} uploaded to ${bucketName}`);\n }\n\n uploadWithoutAuthentication().catch(console.error);\n // [END storage_upload_without_authentication]\n}", "function passwordJsonReader() {\n var data = fs.readFileSync(\"./passwd.txt\", 'utf-8');\n var dataJson = '{' + '\\n' + ' ' + data + '\\n' + '}';\n var dataJsonString = JSON.parse(dataJson);\n return dataJsonString;\n}", "function Credentials(name, pass) {\n this.name = name\n this.pass = pass\n}", "function getClient(serviceAccountJson, cb) {\n // the getClient method looks for the GCLOUD_PROJECT and GOOGLE_APPLICATION_CREDENTIALS\n // environment variables if serviceAccountJson is not passed in\n google.auth\n .getClient({\n keyFilename: serviceAccountJson,\n scopes: ['https://www.googleapis.com/auth/cloud-platform'],\n })\n .then(authClient => {\n const discoveryUrl = `${DISCOVERY_API}?version=${API_VERSION}`;\n\n google.options({\n auth: authClient,\n });\n\n google\n .discoverAPI(discoveryUrl)\n .then(client => {\n cb(client);\n })\n .catch(err => {\n console.log('Error during API discovery.', err);\n });\n });\n}", "function exportKeyFile() {\n if (browserAccounts === undefined)\n browserAccounts = new Accounts({minPassphraseLength : 0});\n var accountObject = browserAccounts.new('passphrase');\n var JSONData = \"text/json;charset=utf-8,\" + encodeURIComponent(JSON.stringify(accountObject));\n var link = document.createElement('a');\n link.href = \"data: \" + JSONData;\n link.download = 'data.json';\n link.innerHTML = 'download JSON';\n var container = document.getElementById('exportWallet');\n container.appendChild(link);\n console.log(accountObject);\n}", "async createaccountjson(wpeauth) {\n\t\tconst WPEAccounts = require(\"./wpeaccounts\");\n\t\tconst wpeaccounts = new WPEAccounts(wpeauth);\n\n\t\t/**\n\t\t * Fetch accounts from API\n\t\t */\n\t\tlet fetchedAccounts = await wpeaccounts.getaccounts();\n\n\t\tif (fetchedAccounts && fetchedAccounts.results) {\n\t\t\tlet accountsarr = [];\n\n\t\t\tfetchedAccounts.results.forEach(function(item) {\n\t\t\t\taccountsarr.push({ id: item.id });\n\t\t\t});\n\n\t\t\tconsole.log(\"Add your account ID to config.json:\".green);\n\t\t\tconsole.log('\"accounts\":' + JSON.stringify(accountsarr));\n\t\t} else {\n\t\t\tconsole.log(\"An error occurred\".red);\n\t\t}\n\t}", "getOAuth2Client(cb) {\r\n // Load client secrets\r\n fs.readFile('client_secret.json', function(err, data) {\r\n if (err) {\r\n return cb(err);\r\n }\r\n var credentials = JSON.parse(data);\r\n var clientSecret = credentials.installed.client_secret;\r\n var clientId = credentials.installed.client_id;\r\n var redirectUrl = credentials.installed.redirect_uris[0];\r\n var auth = new googleAuth();\r\n var oauth2Client = new auth.OAuth2(clientId, clientSecret, redirectUrl);\r\n\r\n // Load credentials\r\n fs.readFile('gmail-credentials.json', function(err, token) {\r\n if (err) {\r\n return cb(err);\r\n } else {\r\n oauth2Client.credentials = JSON.parse(token);\r\n return cb(null, oauth2Client);\r\n }\r\n });\r\n });\r\n }", "function readCredentials(cb) {\n fs.readFile(path.join(__dirname, 'credentials.json'), function(err, json) {\n if (err)\n console.warn(\"Missing frontoffice credentials -> You won't be able to authenticate!\");\n\n var creds = JSON.parse(json || '{}');\n if (creds.consumerKey && creds.consumerSecret)\n console.log(\"Front credentials loaded\");\n else\n console.log(\"One or more blank front credential -> You won't be able to authenticate!\");\n\n cb(creds);\n });\n}", "function Credentials (name, pass) {\n this.name = name\n this.pass = pass\n}", "function Credentials (name, pass) {\n this.name = name\n this.pass = pass\n}", "function Credentials (name, pass) {\n this.name = name\n this.pass = pass\n}", "function Credentials (name, pass) {\n this.name = name\n this.pass = pass\n}", "function Credentials (name, pass) {\n this.name = name\n this.pass = pass\n}", "static createFromGoogleCredential(googleCredentials) {\n return CallCredentials.createFromMetadataGenerator((options, callback) => {\n let getHeaders;\n if (isCurrentOauth2Client(googleCredentials)) {\n getHeaders = googleCredentials.getRequestHeaders(options.service_url);\n }\n else {\n getHeaders = new Promise((resolve, reject) => {\n googleCredentials.getRequestMetadata(options.service_url, (err, headers) => {\n if (err) {\n reject(err);\n return;\n }\n if (!headers) {\n reject(new Error('Headers not set by metadata plugin'));\n return;\n }\n resolve(headers);\n });\n });\n }\n getHeaders.then((headers) => {\n const metadata = new metadata_1.Metadata();\n for (const key of Object.keys(headers)) {\n metadata.add(key, headers[key]);\n }\n callback(null, metadata);\n }, (err) => {\n callback(err);\n });\n });\n }", "function ServiceAccountCredential(serviceAccountPathOrObject, httpAgent, implicit) {\n if (implicit === void 0) { implicit = false; }\n this.httpAgent = httpAgent;\n this.implicit = implicit;\n var serviceAccount = (typeof serviceAccountPathOrObject === 'string') ?\n ServiceAccount.fromPath(serviceAccountPathOrObject)\n : new ServiceAccount(serviceAccountPathOrObject);\n this.projectId = serviceAccount.projectId;\n this.privateKey = serviceAccount.privateKey;\n this.clientEmail = serviceAccount.clientEmail;\n this.httpClient = new api_request_1.HttpClient();\n }", "function Credentials(name, pass) {\n this.name = name;\n this.pass = pass;\n}", "function createCredentials(homeDir, apiKey) {\n fs_1.default.mkdirSync(`${homeDir}/.gem`, { recursive: true });\n fs_1.default.writeFileSync(`${homeDir}/.gem/credentials`, `---\\n:rubygems_api_key: ${apiKey}\\n`, { mode: 0o600 });\n}", "createCredential() {\n return new Credential(this);\n }", "function getCloudPrintService() {\n return OAuth2.createService('print')\n .setAuthorizationBaseUrl('https://accounts.google.com/o/oauth2/auth')\n .setTokenUrl('https://accounts.google.com/o/oauth2/token')\n .setClientId(CLIENT_ID) \n .setClientSecret(CLIENT_SECRET)\n .setCallbackFunction('authCallback')\n .setPropertyStore(PropertiesService.getUserProperties())\n .setScope('https://www.googleapis.com/auth/cloudprint')\n .setParam('login_hint', '[email protected]')\n .setParam('access_type', 'offline')\n .setParam('approval_prompt', 'force');\n}", "function readFile() {\n let data = file.readFileSync(\"accounts.json\");\n if (data.length === 0)\n return;\n let parsedData = JSON.parse(data.toString())[\"users\"];\n for (let i = 0; i < parsedData.length; i++) {\n accounts.push(parsedData[i]);\n }\n}", "static get servicePath() {\n return 'secretmanager.googleapis.com';\n }", "function mergeAllCredentials() {\n var argv = common.global.argv;\n var config = common.gotoProjectHome(true);\n\n var mmsCreds = {server:common.DEFAULT_SERVER};\n\n if(argv.profile) {\n common.verbose(\"Reading profile specified on command line.\");\n profileInfo.push(argv.profile);\n mergeCredentials(mmsCreds,readProfile(argv.profile));\n } else {\n if(fs.existsSync(common.EMOTE_PROFILE)) {\n common.verbose(\"Reading profile from \" + common.EMOTE_PROFILE);\n profileInfo.push(common.EMOTE_PROFILE);\n mergeCredentials(mmsCreds,readProfile(common.EMOTE_PROFILE));\n }\n if(fs.existsSync(common.PROJECT_PROFILE)) {\n common.verbose(\"Reading profile from project root.\");\n profileInfo.unshift(common.PROJECT_PROFILE);\n common.global.projectProfile = readProfile(common.PROJECT_PROFILE);\n mergeCredentials(mmsCreds,common.global.projectProfile);\n }\n }\n\n if(argv.username) mergeCredentials(mmsCreds,{username:argv.username});\n if(argv.password) mergeCredentials(mmsCreds,{password:argv.password});\n if(argv.server) mergeCredentials(mmsCreds,{server:argv.server});\n\n return mmsCreds;\n}", "function addCredential() {\n if(window.icPatch) {\n post(window.icPatchUrl, {credential: JSON.stringify(window.icPatch)});\n }\n}", "async function removeCredentialsFromStorage() {\n await AsyncStorage.removeItem('api/credentials');\n}", "function buildAndAuthorizeService (callback) {\n // Imports the Google APIs client library\n const google = require('googleapis');\n\n // Acquires credentials\n google.auth.getApplicationDefault((err, authClient) => {\n if (err) {\n callback(err);\n return;\n }\n\n if (authClient.createScopedRequired && authClient.createScopedRequired()) {\n authClient = authClient.createScoped([\n 'https://www.googleapis.com/auth/cloud-platform'\n ]);\n }\n\n // Instantiates an authorized client\n const cloudkms = google.cloudkms({\n version: 'v1',\n auth: authClient\n });\n\n callback(null, cloudkms);\n });\n }", "async function fetchCredentials() {\n const response = await fetch(`${url}/uploadImage/addFeed`, {\n method: \"GET\",\n });\n const credentials = await response.json();\n if (response.ok) {\n firebaseConfig = credentials.firebaseConfig;\n firebase.initializeApp(firebaseConfig);\n } else {\n return Promise.reject(response);\n }\n}", "async function authorize() {\n let client = await loadSavedCredentialsIfExist();\n if (client) {\n return client;\n }\n client = await authenticate({\n scopes: SCOPES,\n keyfilePath: CREDENTIALS_PATH,\n });\n if (client.credentials) {\n await saveCredentials(client);\n }\n return client;\n}", "function writeBot(botName, userName, password) {\n fs.writeFile('bots/creds/' + botName + '.creds.json', '' \n + '{\\n'\n + '\\t\"accountName\":' + '\"' + userName + '\",\\n'\n + '\\t\"password\":' + '\"' + password + '\"\\n'\n + '}'\n );\n}", "function copyService(service) {\n return {\n id: service.id,\n student: service.student,\n title: service.title,\n description: service.description,\n fulfilled: service.fulfilled,\n fulfilled_date: service.fulfilled_date,\n fulfilled_description: service.fulfilled_description,\n fulfilled_user: service.fulfilled_user,\n type: service.type,\n };\n }", "async function getLogin(docID) {\n let testJSON = fs.readFileSync('./gdocslogin.json');\n textJSON = JSON.parse(testJSON);\n if (textJSON === undefined) {\n return console.log('Error loading client secret file:', err);\n } else {\n textJSON.installed.client_secret = process.env.GOOGLE_CLIENT_SECRET;\n textJSON.installed.client_id = process.env.GOOGLE_CLIENT_ID;\n textJSON.installed.project_id = process.env.GOOGLE_PROJECT_ID;\n const docData = await authorize(textJSON, getDocFromID, docID);\n return docData;\n }\n }", "function onInstall_() {\n\n Log_.functionEntryPoint();\n var ui = SpreadsheetApp.getUi()\n var settingsSheet = SpreadsheetApp.getActive().getSheetByName('Settings')\n\n // Ask where the copy is to be made to\n \n do {\n \n var response = ui.prompt('What\\'s the ID of the destination folder', ui.ButtonSet.OK_CANCEL)\n var clientFolderId = response.getResponseText()\n \n if (response.getSelectedButton() == ui.Button.CANCEL) {\n return\n }\n\n } while (clientFolderId === '') \n\n // Get a copy of the config sheet template and put it in the client's folder\n \n var configSheetTemplateId = settingsSheet.getRange('A2').getValue()\n var configSheet = SpreadsheetApp.openById(configSheetTemplateId).copy('Config Sheet')\n var configSheetId = configSheet.getId()\n var configSheetFile = DriveApp.getFileById(configSheetId)\n var configSheetParentFolder = configSheetFile.getParents().next()\n \n DriveApp.getFolderById(clientFolderId).addFile(configSheetFile)\n configSheetParentFolder.removeFile(configSheetFile)\n \n Log_.info('Created Config sheet ' + configSheetId)\n \n // Register this user to it\n \n var user = Session.getEffectiveUser().getEmail()\n \n if (user === '') {\n \n Log_.warning('Failed to register user with config sheet')\n \n } else {\n \n Config.initialise({\n email: user,\n spreadsheetId: configSheetId,\n })\n \n Log_.info('Registered ' + user + ' on sheet ' + configSheetId)\n }\n \n // Copy the template folder tree \n \n var fileList = Utils_.getList('Files');\n var folderList = Utils_.getList('Folders');\n var templateFolderId = settingsSheet.getRange('A3').getValue()\n Copy_.startCopy(templateFolderId, clientFolderId, fileList, folderList);\n ui.alert('CloudFire successfully installed to ' + clientFolderId)\n \n} // onInstall_() ", "function storeDocusignUserInfo(service) {\n var url = 'https://' + OAUTH_HOST + '/oauth/userinfo';\n var response = UrlFetchApp.fetch(url, {\n headers: {\n Authorization: 'Bearer ' + service.getAccessToken()\n }\n });\n var result = JSON.parse(response.getContentText());\n\n // Find the default account.\n var account = result.accounts.filter(function (account) {\n return account.is_default;\n })[0];\n\n // Store the base URI and account ID for later.\n var storage = service.getStorage();\n storage.setValue('account_id', account.account_id);\n storage.setValue('base_uri', account.base_uri);\n}", "function handleClientLoad() {\n $.getJSON(\"js/credentials.json\", function (json) {\n creds = json;\n console.log(creds);\n loadGapi();\n });\n}", "function getAuthObj(\n callback,\n keyCredentialsPath = '../' + process.env.GOOGLE_APPLICATION_CREDENTIALS\n) {\n console.time('Authenticating');\n const key = require(keyCredentialsPath);\n const jwtClient = new google.auth.JWT(\n key.client_email,\n null,\n key.private_key,\n ['https://www.googleapis.com/auth/firebase'], // an array of auth scopes\n null\n );\n const projectId = process.env.GCLOUD_PROJECT || key.project_id;\n\n jwtClient.authorize(function(err, tokens) {\n if (err) {\n throw new Error(\n `Could not authorize jwtClient. Check GOOGLE_APPLICATION_CREDENTIALS \n env variable for correct path to key credentials and check that \n key credentials are for the firebase-adminsdk service account \n (created from \"Add Firebase to your app\" step on \n https://firebase.google.com/docs/admin/setup) or check that\n the key credentials have similar scope to firebase-adminsdk.`,\n err\n );\n }\n console.timeEnd('Authenticating');\n callback({ authClient: jwtClient, projectId });\n });\n}", "function clientCredentialsGrant(tokenServiceUrlOrXsuaaServiceCredentials, clientCredentials, options, customBody) {\n if (customBody === void 0) { customBody = {}; }\n var authHeader = headerForClientCredentials(clientCredentials);\n var body = __assign({ grant_type: GrantType.CLIENT_CREDENTIALS }, customBody);\n return post(tokenServiceUrlOrXsuaaServiceCredentials, authHeader, objectToXWwwUrlEncodedBodyString(body), options)\n .then(function (resp) { return resp.data; })\n .catch(function (error) {\n return Promise.reject(accessTokenError(error, GrantType.CLIENT_CREDENTIALS));\n });\n}", "async function copyPackageJson() {\n const packageJson = await fsExtra.readFile(path.resolve(__dirname, '../package.json'), 'utf8');\n const { scripts, devDependencies, files, ...packageDataOther } = JSON.parse(packageJson);\n\n const newPackageJson = {\n ...packageDataOther,\n main: './index.js',\n module: './index.es.js',\n };\n\n const output = path.resolve(__dirname, '../dist/package.json');\n\n await fsExtra.writeFile(output, JSON.stringify(newPackageJson, null, 2), 'utf8');\n console.log(`Created ${output}`);\n}", "function loadSheets(){\nfs.readFile('client_secret.json', function processClientSecrets(err, content) {\n if (err) {\n console.log('Error loading client secret file: ' + err);\n return;\n }\n // Authorize a client with the loaded credentials, then call the\n // Google Sheets API.\n authorize(JSON.parse(content), listMajors);\n});\n}", "async function main() {\n const bucketName = process.env.BUCKET_NAME;\n const objectName = process.env.OBJECT_NAME;\n // Defines a credential access boundary that grants objectViewer access in\n // the specified bucket.\n const cab = {\n accessBoundary: {\n accessBoundaryRules: [\n {\n availableResource: `//storage.googleapis.com/projects/_/buckets/${bucketName}`,\n availablePermissions: ['inRole:roles/storage.objectViewer'],\n availabilityCondition: {\n expression:\n \"resource.name.startsWith('projects/_/buckets/\" +\n `${bucketName}/objects/${objectName}')`,\n },\n },\n ],\n },\n };\n\n const googleAuth = new GoogleAuth({\n scopes: 'https://www.googleapis.com/auth/cloud-platform',\n });\n const projectId = await googleAuth.getProjectId();\n // Obtain an authenticated client via ADC.\n const client = await googleAuth.getClient();\n // Use the client to generate a DownscopedClient.\n const cabClient = new DownscopedClient(client, cab);\n\n // OAuth 2.0 Client\n const authClient = new OAuth2Client();\n // Define a refreshHandler that will be used to refresh the downscoped token\n // when it expires.\n authClient.refreshHandler = async () => {\n const refreshedAccessToken = await cabClient.getAccessToken();\n return {\n access_token: refreshedAccessToken.token,\n expiry_date: refreshedAccessToken.expirationTime,\n };\n };\n\n const storageOptions = {\n projectId,\n authClient: new GoogleAuth({authClient}),\n };\n\n const storage = new Storage(storageOptions);\n const downloadFile = await storage\n .bucket(bucketName)\n .file(objectName)\n .download();\n console.log('Successfully retrieved file. Contents:');\n console.log(downloadFile.toString('utf8'));\n}", "function get_tokens(){\n try {\n var credentials = JSON.parse(fs.readFileSync('./credentials.json'));\n if (credentials === false) {\n console.log(\" No Tokens found\");\n }\n return credentials;\n\n } catch (err) {\n\n console.log('failed to load credentials', err);\n }\n}", "function login() {\r\n\tprompt.get(['username', 'password'], function (err, result) {\r\n\r\n\r\n\t\tvar hash = generateHash(result.password)\r\n\t\tvar credentials = {\r\n\t\t\tpassword: hash,\r\n\t\t\tusername: result.username\r\n\t\t}\r\n\r\n\t\tvar json = fs.readFileSync(\"./data.json\");\r\n\t\tvar credentialsArray = JSON.parse(json);\r\n\r\n\t\tvar exsistingPassword = credentialsArray.filter(function (item) {\r\n\t\t\treturn item.password == credentials.password;\r\n\t\t});\r\n\t\tif (exsistingPassword.length > 0) {\r\n\t\t\tvar json = JSON.stringify(credentialsArray, null, 3);\r\n\t\t\tfs.writeFileSync(\"./data.json\", json);\r\n\t\t} else {\r\n\t\t\tconsole.log('Try Again')\r\n\t\t}\r\n\t});\r\n}", "function authenticateCurator() {\n //READMORE: http://googlecloudplatform.github.io/gcloud-node/#/docs/v0.37.0/storage/file?method=createWriteStream\n return gcloud.storage({\n keyFilename: './auth/curatorKey.json',\n projectId : 'artist-tekuma-4a697'\n });\n console.log(\"connected art storage\");\n }", "function createClientCredentials(legalName, nit, tradeName, ownerName, ownerPhonenumber,\n businessPhonenumber, additionalInformation, email, minOrderPrice) {\n var clientCredentials = {\n legal_name: legalName,\n nit: nit,\n trade_name: tradeName,\n email: email,\n owner_name: ownerName,\n owner_phonenumber: ownerPhonenumber,\n business_phonenumber: businessPhonenumber,\n additional_information: additionalInformation,\n min_order_price: minOrderPrice\n };\n return clientCredentials;\n}", "function createUserCredentials(username, password) {\n password = CriptoService.hashValor(password);\n var userCredentials = {\n username: username,\n password: password,\n role: \"cliente\",\n state: true\n };\n return userCredentials;\n}", "function makeCredentialsProvider(credentials) {\n if (!credentials) {\n return new EmptyCredentialsProvider();\n }\n switch (credentials.type) {\n case 'gapi':\n return new FirstPartyCredentialsProvider(credentials.client, credentials.sessionIndex || '0');\n case 'provider':\n return credentials.client;\n default:\n throw new __WEBPACK_IMPORTED_MODULE_2__util_error__[\"a\" /* FirestoreError */](__WEBPACK_IMPORTED_MODULE_2__util_error__[\"b\" /* Code */].INVALID_ARGUMENT, 'makeCredentialsProvider failed due to invalid credential type');\n }\n}", "generateCredentialsGP () {\n // Generate the Basic Authentication header for a private instance of SLPDB.\n const username = 'BITBOX'\n const password = SLPDB_PASS_GP\n const combined = `${username}:${password}`\n // console.log(`combined: ${combined}`)\n var base64Credential = Buffer.from(combined).toString('base64')\n var readyCredential = `Basic ${base64Credential}`\n\n const options = {\n headers: {\n authorization: readyCredential\n },\n timeout: 15000\n }\n\n return options\n }", "function makeCredentialsProvider(credentials) {\n if (!credentials) {\n return new EmptyCredentialsProvider();\n }\n switch (credentials.type) {\n case 'google-auth':\n return new GoogleCredentialsProvider(credentials.client);\n case 'gapi':\n return new FirstPartyCredentialsProvider(credentials.client, credentials.sessionIndex || '0');\n case 'provider':\n return credentials.client;\n default:\n throw new __WEBPACK_IMPORTED_MODULE_2__util_error__[\"a\" /* FirestoreError */](__WEBPACK_IMPORTED_MODULE_2__util_error__[\"b\" /* Code */].INVALID_ARGUMENT, 'makeCredentialsProvider failed due to invalid credential type');\n }\n}", "function getConsoleServiceCredentials (consoleServiceName) {\n const upServices = VcapServices['user-provided']\n if (upServices == null) return null\n\n for (let service of upServices) {\n if (service.name === consoleServiceName) return service.credentials\n }\n\n return null\n}", "function makeCredentialsProvider(credentials) {\n if (!credentials) {\n return new EmptyCredentialsProvider();\n }\n switch (credentials.type) {\n case 'google-auth':\n return new GoogleCredentialsProvider(credentials.client);\n case 'gapi':\n return new FirstPartyCredentialsProvider(credentials.client, credentials.sessionIndex || '0');\n case 'provider':\n return credentials.client;\n default:\n throw new __WEBPACK_IMPORTED_MODULE_2__util_error__[\"b\" /* FirestoreError */](__WEBPACK_IMPORTED_MODULE_2__util_error__[\"a\" /* Code */].INVALID_ARGUMENT, 'makeCredentialsProvider failed due to invalid credential type');\n }\n}", "loadStoredCredentials() {\n\n let stored = localStorage.getItem(\"__stitch.creds\");\n\n if (stored != null) {\n let obj = JSON.parse(stored);\n this.email = obj.email;\n this.password = obj.password;\n return obj;\n }\n\n // be sure to have clean cache if __stitch.creds are missing\n this.killCachedSessionAndCredentials();\n\n return null;\n }", "generateCredentials () {\n // Generate the Basic Authentication header for a private instance of SLPDB.\n const username = 'BITBOX'\n const password = SLPDB_PASS\n const combined = `${username}:${password}`\n var base64Credential = Buffer.from(combined).toString('base64')\n var readyCredential = `Basic ${base64Credential}`\n\n const options = {\n headers: {\n authorization: readyCredential\n },\n timeout: 15000\n }\n\n return options\n }", "async getClientCredentials(){\n if(!isEmpty(this.credentials) && this.isClientRunning()) return this.credentials;\n const processInformation = await this.getClientProcessInformation();\n this.setClientProcessInformation(processInformation);\n return this.credentials;\n }", "function authorize(credentials, callback) {\n\t\t var clientSecret = credentials.installed.client_secret;\n\t\t var clientId = credentials.installed.client_id;\n\t\t var redirectUrl = credentials.installed.redirect_uris[0];\n\t\t var auth = new googleAuth();\n\t\t var oauth2Client = new auth.OAuth2(clientId, clientSecret, redirectUrl);\n\t\t\tlogger.info('TOKEN_PATH :', TOKEN_PATH);\n\t\t // Check if we have previously stored a token.\n\t\tfs.readFile(TOKEN_PATH, function(err, token) {\n\t\t if (err) {\n\t\t\tlogger.info('authorize error:', err);\n\t\t\t getNewToken(oauth2Client, callback);\n\t\t } else {\n\t\t\t logger.info('authorize not error:', JSON.stringify(token));\n\t\t\t oauth2Client.credentials = JSON.parse(token);\n\t\t\t callback(oauth2Client);\n\t\t }\n\t\t});\n\t}", "eraseCredentials() { }", "buildCognitoCreds(idTokenJwt) {\n let url = 'cognito-idp.' + _REGION.toLowerCase() + '.amazonaws.com/' + _USER_POOL_ID;\n // if (environment.cognito_idp_endpoint) {\n // url = environment.cognito_idp_endpoint + '/' + _USER_POOL_ID;\n // }\n let logins = {};\n logins[url] = idTokenJwt;\n let params = {\n IdentityPoolId: _IDENTITY_POOL_ID, /* required */\n Logins: logins\n };\n let serviceConfigs = {};\n // if (environment.cognito_identity_endpoint) {\n // serviceConfigs.endpoint = environment.cognito_identity_endpoint;\n // }\n let creds = new AWS.CognitoIdentityCredentials(params, serviceConfigs);\n //AWS.config.cognitoidentityserviceprovider\n this.setCognitoCreds(creds);\n //console.log(\"in build cognito creds: \"+JSON.stringify(this.cognitoCreds))\n return creds;\n }", "function getAWSCredentials() {\n AWS.config.credentials.refresh(function(err) {\n if (err) console.log(err, err.stack); // an error occurred\n else { // successful response);\n onCredentialsAvailable(AWS.config.credentials);\n }\n });\n}", "function getGoogleDriveAuthInfo(callback){\n\t\n\tlogger.info('TOKEN_DIR:', TOKEN_DIR);\n\t\n\treturn fs.readFile('client_secret.json', function processClientSecrets(err, content) {\n\t\t if (err) {\n\t\t console.log('Error loading client secret file: ' + err);\n\t\t return;\n\t\t }\n\t\t // Authorize a client with the loaded credentials, then call the\n\t\t // Drive API.\n\t\t authorize(JSON.parse(content), callback);\n });\n\t \n\n\t \n\t\t\n\t// Authorize a client with the loaded credentials, then call the\n\tfunction authorize(credentials, callback) {\n\t\t var clientSecret = credentials.installed.client_secret;\n\t\t var clientId = credentials.installed.client_id;\n\t\t var redirectUrl = credentials.installed.redirect_uris[0];\n\t\t var auth = new googleAuth();\n\t\t var oauth2Client = new auth.OAuth2(clientId, clientSecret, redirectUrl);\n\t\t\tlogger.info('TOKEN_PATH :', TOKEN_PATH);\n\t\t // Check if we have previously stored a token.\n\t\tfs.readFile(TOKEN_PATH, function(err, token) {\n\t\t if (err) {\n\t\t\tlogger.info('authorize error:', err);\n\t\t\t getNewToken(oauth2Client, callback);\n\t\t } else {\n\t\t\t logger.info('authorize not error:', JSON.stringify(token));\n\t\t\t oauth2Client.credentials = JSON.parse(token);\n\t\t\t callback(oauth2Client);\n\t\t }\n\t\t});\n\t}\t\t\n\n\n\t// Generate new token\n\tfunction getNewToken(oauth2Client, callback) {\n\t\t var authUrl = oauth2Client.generateAuthUrl({\n\t\t access_type: 'offline',\n\t\t scope: SCOPES\n\t\t });\n\t\t console.log('Authorize this app by visiting this url: ', authUrl);\n\t\t var rl = readline.createInterface({\n\t\t input: process.stdin,\n\t\t output: process.stdout\n\t\t });\n\t\t rl.question('Enter the code from that page here: ', function(code) {\n\t\t rl.close();\n\t\t oauth2Client.getToken(code, function(err, token) {\t\t\t\n\t\t\t\n\t\t\t if (err) {\n\t\t\t console.log('Error while trying to retrieve access token', err);\n\t\t\t return;\n\t\t\t }\n\t\t\t console.log('token', JSON.stringify(token));\n\t\t\t oauth2Client.credentials = token;\n\t\t\t storeToken(token);\n\t\t\t callback(oauth2Client);\n\t\t });\n\t\t });\n\t}\n\t \n\t// Store if token is new\n\tfunction storeToken(token) {\n\t\t try {\n\t\t fs.mkdirSync(TOKEN_DIR);\n\t\t } catch (err) {\n\t\t if (err.code != 'EEXIST') {\n\t\t\t throw err;\n\t\t }\n\t\t }\n\t\t console.log('Token stored to ' + TOKEN_PATH);\n\t\t fs.writeFile(TOKEN_PATH, JSON.stringify(token));\n\t}\n\n\t\n}", "function makeCredentialsProvider(credentials) {\n if (!credentials) {\n return new EmptyCredentialsProvider();\n }\n switch (credentials.type) {\n case 'gapi':\n return new FirstPartyCredentialsProvider(credentials.client, credentials.sessionIndex || '0');\n case 'provider':\n return credentials.client;\n default:\n throw new FirestoreError(Code.INVALID_ARGUMENT, 'makeCredentialsProvider failed due to invalid credential type');\n }\n}", "function makeCredentialsProvider(credentials) {\n if (!credentials) {\n return new EmptyCredentialsProvider();\n }\n switch (credentials.type) {\n case 'gapi':\n return new FirstPartyCredentialsProvider(credentials.client, credentials.sessionIndex || '0');\n case 'provider':\n return credentials.client;\n default:\n throw new FirestoreError(Code.INVALID_ARGUMENT, 'makeCredentialsProvider failed due to invalid credential type');\n }\n}", "function makeCredentialsProvider(credentials) {\n if (!credentials) {\n return new EmptyCredentialsProvider();\n }\n switch (credentials.type) {\n case 'gapi':\n return new FirstPartyCredentialsProvider(credentials.client, credentials.sessionIndex || '0');\n case 'provider':\n return credentials.client;\n default:\n throw new FirestoreError(Code.INVALID_ARGUMENT, 'makeCredentialsProvider failed due to invalid credential type');\n }\n}", "async getExistingWallets() {\n this.localWallets = JSON.parse(walletFile);\n }", "function create_access_token_cache(authentication_cache, petFinder_auth){\n\tlet petFinder_auth_json = JSON.stringify(petFinder_auth);//convert js obj to JSON string\n\tfs.writeFile(authentication_cache, petFinder_auth_json, function(err){//write petFinder_auth_json to authentication_cache\n\t\tif (err)throw err;\n\t});\n}", "function PdkCredentials(config) {\n RED.nodes.createNode(this, config);\n this.user_email = config.user_email;\n this.user_info = JSON.parse(config.user_info);\n }", "function create_cache(authentication_res_data){\n let authentication_cache = JSON.stringify(authentication_res_data);\n //Writing data to the file.\n fs.writeFile('./auth/authentication_res.json', authentication_cache, function (e) {\n if(e) throw e;\n console.log('Saved to File');\n });\n}", "function getCredentials() {\n let concatenatedString = twittersecret.Key + \":\" + twittersecret.Secret;\n let base64encodedString =\n Buffer.from(concatenatedString).toString(\"base64\");\n return `Basic ${base64encodedString}`;\n}", "function getJwtClient() {\n return new google.auth.JWT(\n functions.config().privatekey.client_email,\n null,\n functions.config().privatekey.private_key,\n ['https://www.googleapis.com/auth/spreadsheets']);\n}", "static credential(idToken, accessToken) {\r\n return OAuthCredential._fromParams({\r\n providerId: GoogleAuthProvider.PROVIDER_ID,\r\n signInMethod: GoogleAuthProvider.GOOGLE_SIGN_IN_METHOD,\r\n idToken,\r\n accessToken\r\n });\r\n }", "static credential(idToken, accessToken) {\r\n return OAuthCredential._fromParams({\r\n providerId: GoogleAuthProvider.PROVIDER_ID,\r\n signInMethod: GoogleAuthProvider.GOOGLE_SIGN_IN_METHOD,\r\n idToken,\r\n accessToken\r\n });\r\n }", "function createServiceConfig () {\n console.log(`Creating ${configFilePath}`)\n\n const content = {\n apps: []\n }\n\n function addServiceConfig (name) {\n return new Promise((resolve, reject) => {\n content.apps.push({\n name,\n script: 'index.js',\n cwd: path.resolve(__dirname, '../../back-end/services', name),\n instances: config.services[name].totalInitialInstances,\n max_restarts: 15,\n env: {\n NODE_ENV: process.env.NODE_ENV\n }\n })\n\n resolve()\n })\n }\n\n return Promise.all(Object.keys(config.services)\n .map(addServiceConfig)\n )\n .then(() => fs.writeFileSync(\n path.resolve(__dirname, configFilePath),\n JSON.stringify(content, undefined, 2),\n 'utf8'\n ))\n .then(() => console.log(`${configFilePath} successfully created`))\n}", "static get servicePath() {\n return 'securitycenter.googleapis.com';\n }", "function copyAppSetting() {\n const config_path = './src/config';\n const app_settings_file = `${config_path}/appsettings.json`;\n const dev_app_settings_file = `${config_path}/appsettings.development.json`;\n\n try {\n if (!fs.existsSync(dev_app_settings_file)) {\n // file not exists, then create one\n fs.copyFileSync(app_settings_file, dev_app_settings_file);\n console.log('Development appsettings file created.');\n } else {\n console.warn(\n 'Warning: Development appsettings file already exists.'\n );\n }\n } catch (error) {\n console.error(error);\n process.exit(1);\n }\n}", "function authorize(credentials, callback) {\n var clientSecret = credentials.installed.client_secret,\n clientId = credentials.installed.client_id,\n redirectUrl = credentials.installed.redirect_uris[0],\n auth = new googleAuth(),\n oauth2Client = new auth.OAuth2(clientId, clientSecret, redirectUrl);\n \n // Check if we have a saved token, if not, tries to get one\n fs.readFile(TOKEN_PATH, function (err, token) {\n if (err) {\n getNewToken(oauth2Client, callback);\n } else {\n oauth2Client.credentials = JSON.parse(token);\n callback(oauth2Client);\n }\n });\n }", "function loadKeyFile() {\n var input, file, fr;\n\n if (typeof window.FileReader !== 'function') {\n alert(\"The file API isn't supported on this browser yet.\");\n return;\n }\n\n input = document.getElementById('keyFileInput');\n if (!input) {\n alert(\"Um, couldn't find the fileinput element.\");\n }\n else if (!input.files) {\n alert(\"This browser doesn't seem to support the `files` property of file inputs.\");\n }\n else if (!input.files[0]) {\n alert(\"Please select a file before clicking 'Load'\");\n }\n else {\n file = input.files[0];\n fr = new FileReader();\n fr.onload = receivedText;\n fr.readAsText(file);\n }\n\n function receivedText(e) {\n lines = e.target.result;\n var newArr = JSON.parse(lines);\n var newAccount = browserAccounts.set(newArr.address, newArr);\n console.log(newArr);\n listAccounts();\n }\n}", "async function createAccount() {\n const subscriptionId =\n process.env[\"COGNITIVESERVICES_SUBSCRIPTION_ID\"] || \"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\";\n const resourceGroupName = process.env[\"COGNITIVESERVICES_RESOURCE_GROUP\"] || \"myResourceGroup\";\n const accountName = \"testCreate1\";\n const account = {\n identity: { type: \"SystemAssigned\" },\n kind: \"Emotion\",\n location: \"West US\",\n properties: {\n encryption: {\n keySource: \"Microsoft.KeyVault\",\n keyVaultProperties: {\n keyName: \"KeyName\",\n keyVaultUri: \"https://pltfrmscrts-use-pc-dev.vault.azure.net/\",\n keyVersion: \"891CF236-D241-4738-9462-D506AF493DFA\",\n },\n },\n userOwnedStorage: [\n {\n resourceId:\n \"/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/myResourceGroup/providers/Microsoft.Storage/storageAccounts/myStorageAccount\",\n },\n ],\n },\n sku: { name: \"S0\" },\n };\n const credential = new DefaultAzureCredential();\n const client = new CognitiveServicesManagementClient(credential, subscriptionId);\n const result = await client.accounts.beginCreateAndWait(resourceGroupName, accountName, account);\n console.log(result);\n}", "function getCredentials(node) {\n // If no keystore file found, we can't connect to any node\n let filepath = __dirname + \"/../.data/credentials.json\";\n if (!fs.existsSync(filepath)) {\n console.log(\"DNE\");\n return;\n }\n\n // Read the keyfile into memory for usage\n let data = fs.readFileSync(filepath);\n\n // Parse the json into an object\n let keyfile = JSON.parse(data);\n\n // return the credentials for the desired node\n return keyfile.nodes[node];\n}", "function run() {\n return __awaiter(this, void 0, void 0, function* () {\n try {\n // Inputs\n const upgrade = core.getInput('upgrade');\n const service_account = core.getInput('service_account');\n // Start Installing\n yield upgradeScript_1.default(upgrade);\n // Initialize Gcloud\n const SABuffer = Buffer.from(service_account, 'base64');\n fs_1.default.writeFileSync('gcloud.json', SABuffer);\n yield exec.exec('gcloud auth activate-service-account --key-file=gcloud.json');\n // Cleanup\n fs_1.default.unlinkSync('gcloud.json');\n }\n catch (error) {\n core.setFailed(error.message);\n }\n });\n}", "async function runSample() {\n // Create a new JWT client using the key file downloaded from the Google Developer Console\n const auth = new google.auth.GoogleAuth({\n keyFile: path.join(__dirname, 'jwt.keys.json'),\n scopes: 'https://www.googleapis.com/auth/drive.readonly',\n });\n const client = await auth.getClient();\n\n // Obtain a new drive client, making sure you pass along the auth client\n const drive = google.drive({\n version: 'v2',\n auth: client,\n });\n\n // Make an authorized request to list Drive files.\n const res = await drive.files.list();\n console.log(res.data);\n\n return res.data;\n}", "async function gcsCopy(srcBucket, srcFile, destBucket, destFile) {\n // console.log('Copy from <gs://' + srcBucket + '/' + srcFile + '> to <gs://' + destBucket + '/' + destFile + '>');\n await storage.bucket(srcBucket).file(srcFile).copy(storage.bucket(destBucket).file(destFile))\n .catch(function (error) {\n console.error('!!!!!!!!!!!!! ERROR: Failed to copy a file: ' + destFile + ' with error: ' + error);\n });\n}", "async getCredentials() {\n try {\n const client = this.getClient();\n const result = await client.authorize();\n return result;\n }\n catch (error) {\n this.log.debug(\"error\", {\n error,\n tag: this.tag,\n });\n throw error;\n }\n }" ]
[ "0.6189491", "0.592305", "0.5912973", "0.5600258", "0.552147", "0.54972243", "0.54588205", "0.5427297", "0.5414779", "0.54107696", "0.5376043", "0.53433216", "0.5336684", "0.53241897", "0.51938325", "0.51627886", "0.51468563", "0.51287645", "0.5078304", "0.50133926", "0.4979839", "0.49772054", "0.49717838", "0.49558914", "0.49134988", "0.4911389", "0.49029034", "0.4901138", "0.48992577", "0.48947012", "0.48754978", "0.48754978", "0.48754978", "0.48754978", "0.48754978", "0.48659512", "0.4855311", "0.48477918", "0.4838445", "0.48366424", "0.48343927", "0.4821875", "0.47999707", "0.47978163", "0.472315", "0.47194278", "0.4713565", "0.47122627", "0.47117108", "0.46995613", "0.46953067", "0.46940634", "0.46886054", "0.46831343", "0.4675496", "0.467099", "0.46691594", "0.46639612", "0.4661537", "0.4655208", "0.46465623", "0.46450672", "0.4633344", "0.46119967", "0.46017945", "0.45987713", "0.45973042", "0.4582685", "0.45817962", "0.4579808", "0.4579675", "0.45769417", "0.45600334", "0.45385182", "0.45332146", "0.45262524", "0.45109645", "0.45037913", "0.45025554", "0.45025554", "0.45025554", "0.45013195", "0.4493062", "0.44890273", "0.4488122", "0.4488091", "0.4487204", "0.4484587", "0.4484587", "0.44832566", "0.44821295", "0.4480748", "0.4480624", "0.44715112", "0.44675168", "0.44625673", "0.44618922", "0.44549048", "0.44493845", "0.44462276" ]
0.5785027
3
This function will use the variables to calculate the answers. It should work.
function calculate () { length = document.getElementById('textbox').value width = document.getElementById('textbox').value length = parseInt(length) width = parseInt(width) alert(length * width) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function questionCalculations()\r\n\t{\r\n\t\t// here, calculations for all the above variables should occur\r\n\t}", "function calcDistictAnswers(answers, question) {\n\n //Check if answers contains more than one submission and question is defined\n if (answers.length < 1 || question == undefined) {\n console.log(\"Error in calculating disctinct answers: No answers provided or question missing\")\n return;\n }\n\n //Prepare return object\n var result = new Array();\n\n if (question.questionType == \"multi-choice\") {\n //All submissions must have same amount of options\n var optionsLength = question.questionOptions.length;\n\n //Get correct answer\n var solution = new Array();\n for (var i = 0; i < optionsLength; i++) {\n if (question.questionType == \"multi-choice\") {\n solution.push(question.questionOptions[i].correct);\n } else {\n solution.push(question.questionOptions[i].text);\n }\n };\n console.log(solution);\n\n //Iterate over answers\n for (var i = 0; i < answers.length; i++) {\n //Check if answer has the correct amount of options\n if (answers[i].submission.length != optionsLength) {\n console.log(\"Error in calculating disctinct options: Multiple choice options differ in length. This can't be as every answer has to have the same length.\")\n }\n\n //Remember id answer is not part of results yet\n var newAnswer = true\n\n //Check if answer was seen before. If yes increase quantity, if no add to results.\n\n for (var j = 0; j < result.length; j++) {\n //Check if answer alreday exists in results and if yes increase quantity\n if (arrayEqual(result[j].submission, answers[i].submission)) {\n result[j].quantity++;\n newAnswer = false;\n break;\n }\n };\n //If still new anser add to reluts\n if (newAnswer) {\n\n //Check if new answer is correct\n var correct = arrayEqual(answers[i].submission, solution);\n\n //text for each dataset\n var optionText = \"\";\n //text that contains all selected answer option texts\n\n var selected = new Array();\n for (var k = 0; k < answers[i].submission.length; k++) {\n if (answers[i].submission[k] == true) {\n selected.push(question.questionOptions[k].text.trim());\n optionText = optionText + String.fromCharCode(65 + k) + \" \";\n }\n };\n\n if (question.questionType == \"multi-choice\") {\n optionText = optionText + \"- \" + selected.join(\", \");\n\n } else {\n console.log(\"Qswefrgth\");\n optionText = selected.join(\", \");\n }\n\n //push new answer to results\n result.push({\n submission : answers[i].submission,\n text : optionText,\n correct : correct,\n quantity : 1 //How often option was selected\n });\n }\n\n };\n }\n //Text questions\n else if (question.questionType = \"text-input\") {\n for (var i = 0; i < answers.length; i++) {\n //Test if answer is new, if no increase quantity in results\n var isNewAnswer = true;\n for (var j = 0; j < result.length; j++) {\n if (arrayEqual(result[j].submission, answers[i].submission)) {\n isNewAnswer = false;\n result[j].quantity++;\n }\n };\n\n //If new answer push to results\n if (isNewAnswer) {\n var newAnswer = {\n submission : answers[i].submission,\n text : answers[i].submission.join(),\n correct : false,\n quantity : 1 //How often option was selected\n }\n if (answers[i].correctness == 100) {\n newAnswer.correct = true;\n }\n result.push(newAnswer)\n }\n };\n }\n //Else (missing or unknown question type) log error\n //else{\n // console.log(\"Error in calculating disctinct options: question type is unknown or mission: \");\n // console.log(question.questionType)\n //}\n\n return result;\n}", "function result()\n\t{\n\t\t{\n\t\t\t/* for( i=0; i<questions.length; i++ )\n\t\t\t\t {\n\t\t\t\t checkAnswers( questions[i]);\t\t\n\t\t\t\t } */\n\t\t\t\t\n\t\t\t//To test in console.log\n\t\t\tconsole.log( \"a1 Score is: \" + checkAnswers( questions[0] ) );\n\t\t\tconsole.log( \"a2 Score is: \" + checkAnswers( questions[1] ) );\n\t\t\tconsole.log( \"a3 Score is: \" + checkAnswers( questions[2] ) );\n\t\t\tconsole.log( \"a4 Score is: \" + checkAnswers( questions[3] ) );\n\t\t\tconsole.log( \"a5 Score is: \" + checkAnswers( questions[4] ) );\n\t\t\t\n\t\t\t// To accumulate total marks in to one variable \n\t\t\tvar m1 = parseInt( checkAnswers( questions[0] ) );\n\t\t\tvar m2 = parseInt( checkAnswers( questions[1] ) );\n\t\t\tvar m3 = parseInt( checkAnswers( questions[2] ) );\n\t\t\tvar m4 = parseInt( checkAnswers( questions[3] ) );\n\t\t\tvar m5 = parseInt( checkAnswers( questions[4] ) );\n\n\t\t\tvar total = m1 + m2 + m3 + m4 + m5;\n\n\t\t\tconsole.log( \"Total Score is: \" + total );\n\t\t\t\n\t\t\tquiz.answersBox.value = \"Total Score is: \" + total;\n\t\t}\n\t}", "function getResult(x){\n if(x===1)\n {score+=questions[questionIndex].a1.s;\n \n if(answersScoreArray[questionIndex]!==\"NULL\") score-=answersScoreArray[questionIndex];\n answersScoreArray[questionIndex]=questions[questionIndex].a1.s;\n console.log(score);}\n\n else if(x===2)\n {score+=questions[questionIndex].a2.s;\n \n if(answersScoreArray[questionIndex]!==\"NULL\") score-=answersScoreArray[questionIndex];\n answersScoreArray[questionIndex]=questions[questionIndex].a2.s;console.log(score);}\n\n \n else if(x===3)\n {score+=questions[questionIndex].a3.s;\n \n if(answersScoreArray[questionIndex]!==\"NULL\") score-=answersScoreArray[questionIndex];\n answersScoreArray[questionIndex]=questions[questionIndex].a3.s;console.log(score);}\n\n\n else \n {score+=questions[questionIndex].a4.s;\n \n if(answersScoreArray[questionIndex]!==\"NULL\") score-=answersScoreArray[questionIndex];\n answersScoreArray[questionIndex]=questions[questionIndex].a4.s;console.log(score);}\n return score;\n}", "function calcWrongAnswers(){\n showVariables();\n $(\"#wrongAns\").html(\"Number of wrong answers : \"+wrongAnswers);\n\n }", "function calculateResult(array) {\n let answer1 = array[0] * 12;\n let answerModified = turnToNumber(1);\n console.log(\"answerModified\", answerModified);\n let answer2 = (answer1 * answerModified) / 100 + answer1;\n console.log(\"answer2\", answer2);\n let terminalValue = answer2 * 2;\n console.log(\"treminalValue\", terminalValue);\n let postMV = terminalValue / 20;\n console.log(\"postMV\", postMV);\n let preMV = postMV - array[0];\n console.log(\"preMV\", preMV);\n let answerThreeModified = turnIndexToNumber(2);\n let answer3 = (answerThreeModified * 30) / 10000;\n console.log(\"answer3\", answer3);\n let answerFourModified = turnIndexToNumber(3);\n let answer4 = (answerFourModified * 25) / 10000;\n let answerFiveModified = turnIndexToNumber(4);\n let answer5 = (answerFiveModified * 15) / 10000;\n let answerSixModified = turnIndexToNumber(5);\n let answer6 = (answerSixModified * 10) / 10000;\n let answerSeventhModified = turnIndexToNumber(6);\n let answer7 = (answerSeventhModified * 10) / 10000;\n // //figure out how to make it prettier\n let answer81 = (answerSeventhModified * 100) / array[0];\n let answer8 = (answer81 * 5) / 10000;\n let answer9 = (array[8] * 5) / 10000;\n let sumOfFactors =\n answer3 + answer4 + answer5 + answer6 + answer7 + answer8 + answer9;\n let preFinalResult = sumOfFactors * preMV;\n //this is THE RESULT\n let finalResult = parseFloat(preFinalResult.toFixed(2));\n // console.log(\"sumOfFactors\", sumOfFactors)\n return finalResult;\n}", "function evaluateAnswers() {\n arrAnswers.forEach(objAnswer => {\n arrAnswerVotes[objAnswer.answer]++;\n\n // If answer is correct, we give the user points\n if(currentReactive.correct[objAnswer.answer] == true)\n {\n let points = 100 - 40*(objAnswer.pastTime/totalTime);\n points = Math.ceil(points);\n objGame.Players.forEach(player => {\n if(player.username === objAnswer.username) player.points = Number(player.points) + points;\n });\n }\n });\n}", "function testDutch() { \nvar q = document.getElementById(\"question\").innerHTML; \n \nvar ans1 = document.getElementById(\"answerInp1\").value;\nvar ans2 = document.getElementById(\"answerInp2\").value;\nvar ans3 = document.getElementById(\"answerInp3\").value;\nvar ans4 = document.getElementById(\"answerInp4\").value;\nvar ans5 = document.getElementById(\"answerInp5\").value;\nvar ans6 = document.getElementById(\"answerInp6\").value;\n\nvar yes1 = document.getElementById(\"yes1\");\nvar no1 = document.getElementById(\"no1\");\nvar yes2 = document.getElementById(\"yes2\");\nvar no2 = document.getElementById(\"no2\");\nvar yes3 = document.getElementById(\"yes3\");\nvar no3 = document.getElementById(\"no3\");\nvar yes4 = document.getElementById(\"yes4\");\nvar no4 = document.getElementById(\"no4\");\nvar yes5 = document.getElementById(\"yes5\");\nvar no5 = document.getElementById(\"no5\");\nvar yes6 = document.getElementById(\"yes6\");\nvar no6 = document.getElementById(\"no6\");\nvar err = document.getElementById(\"error1\");\nvar fault = document.getElementById(\"fault1\");\n//Field to display current score\nvar scoreBoard = document.getElementById(\"scoreboard\");\nvar total = document.getElementById(\"end\");\n//Display correct answers when answered incorrectly\nvar correct1 = document.getElementById(\"correctAns1\");\nvar correct2 = document.getElementById(\"correctAns2\");\nvar correct3 = document.getElementById(\"correctAns3\");\nvar correct4 = document.getElementById(\"correctAns4\");\nvar correct5 = document.getElementById(\"correctAns5\");\nvar correct6 = document.getElementById(\"correctAns6\");\n\n\nfor (var i = 0; i < obj.length; i++) {\n if (obj[i].verb[5] == q) { \n if (obj[i][\"verb\"][0] == ans1) { \n no1.style.display = \"none\";\n yes1.style.display = \"block\";\n score += 1;\n } else yes1.style.display = \"none\", \n no1.style.display = \"block\";\n correct1.style.display = \"block\";\n correct1.innerHTML = \"The correct answer is \" + \"'\" + obj[i][\"verb\"][0] + \"'\";\n if (obj[i][\"verb\"][1] == ans2) { \n no2.style.display = \"none\";\n yes2.style.display = \"block\";\n score += 1;\n } else yes2.style.display = \"none\",\n no2.style.display = \"block\";\n correct2.style.display = \"block\";\n correct2.innerHTML = \"The correct answer is \" + \"'\" + obj[i][\"verb\"][1] + \"'\";\n if (obj[i][\"verb\"][2] == ans3) { \n no3.style.display = \"none\";\n yes3.style.display = \"block\";\n score += 1;\n } else yes3.style.display = \"none\",\n no3.style.display = \"block\";\n correct3.style.display = \"block\";\n correct3.innerHTML = \"The correct answer is \" + \"'\" + obj[i][\"verb\"][2] + \"'\";\n if (obj[i][\"verb\"][3] == ans4) { \n no4.style.display = \"none\";\n yes4.style.display = \"block\";\n score += 1;\n } else yes4.style.display = \"none\",\n no4.style.display = \"block\";\n correct4.style.display = \"block\";\n correct4.innerHTML = \"The correct answer is \" + \"'\" + obj[i][\"verb\"][3] + \"'\";\n if (obj[i][\"verb\"][4] == ans5) { \n no5.style.display = \"none\";\n yes5.style.display = \"block\";\n score += 1;\n } else yes5.style.display = \"none\",\n no5.style.display = \"block\";\n correct5.style.display = \"block\";\n correct5.innerHTML = \"The correct answer is \" + \"'\" + obj[i][\"verb\"][4] + \"'\";\n if (obj[i][\"verb\"][5] == ans6) { \n no6.style.display = \"none\";\n yes6.style.display = \"block\";\n score += 1;\n } else yes6.style.display = \"none\",\n no6.style.display = \"block\";\n correct6.style.display = \"block\";\n correct6.innerHTML = \"The correct answer is \" + \"'\" + obj[i][\"verb\"][5] + \"'\";\n } \n scoreBoard.innerText = score + \" / \" + obj[i][\"verb\"].length;\n verbScore + score;\n total.innerText = \"Total Running Score: \" + verbScore;\n} \nscore = 0;\nif (current == obj.length - 1) {\n scoreBoard.innerText = \"Congratulations your total score is \" + verbScore + \" / \" + (obj.length - 1) * obj[1][\"verb\"].length; //first 'verb' is empty\n}\n}", "function questionClicked() // Function for when the question is clicked. This function should take all the stats from all reviews under the question and combine them\r\n{\r\nvar questionWordCount; // total word count of all the reviews under the question\r\n\r\nvar questionSentimentScore; // sentiment score average of all the reviews\r\nvar questionSentimentWordCount; // total sentiment words in all the reviews\r\nvar questionSentimentPercent; // percentage of sentiment words vs total words\r\n\r\nvar questionActionableScore; // actionable score average of all the reviews\r\nvar questionActionableWordCount // how many actionable-related words are in all the reviews\r\nvar questionActionablePercent; // percentage of actionable words vs total words\r\n\r\nvar questionRudeScore; // rude word score average from all the reviews\r\nvar questionRudeWordCount; // how many rude words are in all the reviews\r\nvar questionRudePercent; // percentage of rude words vs total words\r\n\r\n\tfunction questionCalculations()\r\n\t{\r\n\t\t// here, calculations for all the above variables should occur\r\n\t}\r\n}", "function calcDistictOptions(answers, question) {\n\n //Check if answers contains more than one submission and question is defined\n if (answers.length < 1 || question == undefined) {\n console.log(\"Error in calculating disctinct options: No answers provided or question missing\")\n return;\n }\n\n //Prepare return object\n var result = [];\n //If questiion is a multiple choice question -> submission is array of boolean\n if (question.questionType == \"multi-choice\") {\n\n //All submissions must have same amount of options\n var optionsLength = question.questionOptions.length;\n\n //Fill return object with\n for (var i = 0; i < optionsLength; i++) {\n result.push({\n text : question.questionOptions[i].text,\n correct : question.questionOptions[i].correct,\n quantity : 0 //How often option was selected\n });\n }\n\n //Iterate over answers\n for (var i = 0; i < answers.length; i++) {\n //Check if answer has the correct amount of options\n if (answers[i].submission.length != optionsLength) {\n console.log(\"Error in calculating disctinct options: Multiple choice options differ in length. This can't be as every answer has to have the same length.\")\n console.log(answers[i].submission);\n console.log(optionsLength);\n }\n\n //Update return object\n //For every option in submission of an answer check if selected and if true increase value in return object\n for (var j = 0; j < optionsLength; j++) {\n if (answers[i].submission[j] == true) {\n result[j].quantity++;\n }\n };\n\n };\n }\n //Text questions\n else if (question.questionType = \"text-input\") {\n for (var i = 0; i < answers.length; i++) {\n //Test if answer is new, if no increase quantity in results\n var isNewAnswer = true;\n for (var j = 0; j < result.length; j++) {\n if (arrayEqual(result[j].submission, answers[i].submission)) {\n isNewAnswer = false;\n result[j].quantity++;\n }\n };\n\n //If new answer push to results\n if (isNewAnswer) {\n var newAnswer = {\n submission : answers[i].submission,\n text : answers[i].submission.join(),\n correct : false,\n quantity : 1 //How often option was selected\n }\n if (answers[i].correctness == 100) {\n newAnswer.correct = true;\n }\n result.push(newAnswer)\n }\n };\n }\n\n // Else (missing or unknown question type) log error\n else {\n console.log(\"Error in calculating disctinct options: question type is unknown or mission: \");\n console.log(question.questionType)\n }\n\n return result;\n}", "function getResults(){\n\n // question 1, option 1\n if (selections[0] === \"0\"){\n\n if (selections[1] === \"1\"){\n return 3;\n }\n if (selections[1] === \"2\"){\n return 6;\n }\n if (selections[1] === \"3\"){\n return 8;\n }\n }\n //question 1, option 2\n if (selections[0] === \"1\"){\n\n if (selections[1] === \"0\"){\n return 2;\n }\n if (selections[1] === \"1\"){\n return 4;\n }\n if (selections[1] === \"2\"){\n return 9;\n }\n }\n //question 1, option 3\n if (selections[0] === \"2\"){\n\n if (selections[1] === \"0\"){\n return 1;\n }\n if (selections[1] === \"1\"){\n return 5;\n }\n if (selections[1] === \"2\"){\n return 7;\n }\n }\n}", "function collectAnswer(){\n var onesD = Number($(\"td#onesD > span\").text());\n var tensD = Number($(\"td#tensD > span\").text()) *10;\n var hndsD = Number($(\"td#hndsD > span\").text()) *100;\n var thdsD = Number($(\"td#thdsD > span\").text()) *1000;\n var tthdsD = Number($(\"td#tthdsD > span\").text()) *10000;\n var hthdsD = Number($(\"td#hthdsD > span\").text()) *100000;\n var totalD = onesD+tensD+hndsD+thdsD+tthdsD+hthdsD;\n return{\n totalD: totalD\n };\n}", "function scoreAnswers(){}", "function checkAnsers(){\n var radioValue1 = $(\"input[name='answer1']:checked\").val();\n if (radioValue1 === \"Lake Superior\"){\n correct++;\n unanswered--;\n } else if (radioValue1 === \"Lake Huron\"){\n incorrect++;\n unanswered--;\n } else if (radioValue1 === \"Lake Michigan\"){\n incorrect++;\n unanswered--;\n } else if (radioValue1 === \"Lake Erie\"){\n incorrect++;\n unanswered--;\n }\n var radioValue2 = $(\"input[name='answer2']:checked\").val();\n if (radioValue2 === \"350\"){\n correct++;\n unanswered--;\n } else if (radioValue2 === \"None\"){\n incorrect++;\n unanswered--;\n } else if (radioValue2 === \"143\"){\n incorrect++;\n unanswered--;\n } else if (radioValue2 === \"492\"){\n incorrect++;\n unanswered--;\n }\n var radioValue3 = $(\"input[name='answer3']:checked\").val();\n if (radioValue3 === \"36°F\"){\n correct++;\n unanswered--;\n } else if (radioValue3 === \"12°F\"){\n incorrect++;\n unanswered--;\n } else if (radioValue3 === \"45°F\"){\n incorrect++;\n unanswered--;\n } else if (radioValue3 === \"57°F\"){\n incorrect++;\n unanswered--;\n }\n var radioValue4 = $(\"input[name='answer4']:checked\").val();\n if (radioValue4 === \"Lake Michigan\"){\n correct++;\n unanswered--;\n } else if (radioValue4 === \"Lake Superior\"){\n incorrect++;\n unanswered--;\n } else if (radioValue4 === \"Lake Erie\"){\n incorrect++;\n unanswered--;\n } else if (radioValue4 === \"Lake Ontario\"){\n incorrect++;\n unanswered--;\n }\n var radioValue5 = $(\"input[name='answer5']:checked\").val();\n if (radioValue5 === \"35,000\"){\n correct++;\n unanswered--;\n } else if (radioValue5 === \"700\"){\n incorrect++;\n unanswered--;\n } else if (radioValue5 === \"2,000\"){\n incorrect++;\n unanswered--;\n } else if (radioValue5 === \"11,000\"){\n incorrect++;\n unanswered--;\n }\n var radioValue6 = $(\"input[name='answer6']:checked\").val();\n if (radioValue6 === \"Lake Sturgeon\"){\n correct++;\n unanswered--;\n } else if (radioValue6 === \"Basking Shark\"){\n incorrect++;\n unanswered--;\n } else if (radioValue6 === \"Walleye\"){\n incorrect++;\n unanswered--;\n } else if (radioValue6 === \"Blue Whale\"){\n incorrect++;\n unanswered--;\n }\n var radioValue7 = $(\"input[name='answer7']:checked\").val();\n if (radioValue7 === \"Lake Huron\"){\n correct++;\n unanswered--;\n } else if (radioValue7 === \"Lake Superior\"){\n incorrect++;\n unanswered--;\n } else if (radioValue7 === \"Lake Michigan\"){\n incorrect++;\n unanswered--;\n } else if (radioValue7 === \"Lake Erie\"){\n incorrect++;\n unanswered--;\n }\n var radioValue8 = $(\"input[name='answer8']:checked\").val();\n if (radioValue8 === \"20%\"){\n correct++;\n unanswered--;\n } else if (radioValue8 === \"1%\"){\n incorrect++;\n unanswered--;\n } else if (radioValue8 === \"5%\"){\n incorrect++;\n unanswered--;\n } else if (radioValue8 === \"7%\"){\n incorrect++;\n unanswered--;\n }\n $(\"#page3\").show();\n $(\"#page2\").hide();\n $(\"#correct\").html(\"Correct: \" + correct);\n $(\"#incorrect\").html(\"Incorrect: \" + incorrect);\n $(\"#unanswered\").html(\"Unanswered: \" + unanswered);\n}", "function calcAdvanced(arg) {\r\n let userInput1 = parseInt(document.getElementById('inputNbr11').value);\r\n let userInput2 = parseInt(document.getElementById('inputNbr22').value);\r\n\r\n switch (arg) {\r\n case 'add':\r\n document.getElementById('answer2').textContent = (userInput1 + userInput2);\r\n break;\r\n case 'sub':\r\n document.getElementById('answer2').textContent = (userInput1 - userInput2);\r\n break;\r\n case 'multi':\r\n document.getElementById('answer2').textContent = (userInput1 * userInput2);\r\n break;\r\n case 'divi':\r\n document.getElementById('answer2').textContent = (userInput1 / userInput2);\r\n break;\r\n default:\r\n document.getElementById('answer2').textContent = \"no\";\r\n break;\r\n }\r\n}", "calcVars () {}", "function cals() {\n let age = document.getElementById(\"age\").value;\n let height = document.getElementById(\"height\").value * 2.54;\n let weight = document.getElementById(\"weight\").value / 2.2;\n let resul = 0;\n let BMR\n const numbers = [ height, age, weight ];\n if (document.getElementById(\"male\").checked){\n BMR= numbers.reduce(function(total, curr, index){\n if(index === 0){\n total+= (12.7 * curr);\n }\n if(index === 1){\n total+= (6.8 * curr);\n }\n if(index === 2){\n total+= (6.23 * curr) + 622;\n }\n return total;\n });\n }\n else if (document.getElementById(\"female\").checked){\n BMR= numbers.reduce(function(total, curr, index){\n if(index === 0){\n total+= (4.7 * curr);\n }\n if(index === 1){\n total+= (4.7 * curr);\n }\n if(index === 2){\n total+= (4.35 * curr) + 655;\n }\n return total;\n });\n }\n result = [1.2, 1.375,1.55,1.725,1.9].map( function(num) {\n return Math.round(num * BMR);\n });\n document.getElementById(\"totalCals\").innerHTML =\"<label id='kcals'><br><u><b>\" + result[0] + \"</u></b> kcal per day if you are sedentary (little or no exercise)<br><u><b>\"\n + result[1] + \"</u></b> kcal per day if you are lightly active (light exercise/sports 1-3 days/week)<br><u><b>\" \n + result[2] + \"</u></b> kcal per day if you are moderatetely active (moderate exercise/sports 3-5 days/week)<br><u><b>\" \n + result[3] + \"</u></b> kcal per day if you are very active (hard exercise/sports 6-7 days a week)<br><u><b>\" \n + result[4] + \"</u></b> kcal per day if you are extra active (very hard exercise/sports & physical job or 2x training)</label><br><br><br>\";\n}", "function calculate_respondable(values) {\r\n if(isNaN(values.fleschKincaidGradeLevel)) {\r\n return 0;\r\n }\r\n values.gradeLevel = values.fleschKincaidGradeLevel;\r\n return values.questionCount<=.5?values.wordCount<=8.5?values.wordCount<=1.5?values.subjectWordCount<=1.5?.0733218726262:values.wordCount<=.5?values.subjectWordCount<=3.5?.122914695147:values.subjectWordCount<=6.5?.145072640304:.136819773707:.198588629296:values.subjectWordCount<=1.5?.183093642547:values.gradeLevel<=-.5?.233720662678:values.gradeLevel<=6.60000038147?values.wordCount<=5.5?.298683848408:.331874554526:.239006626723:values.subjectWordCount<=8.5?values.wordCount<=27.5?values.gradeLevel<=9.55000019073?values.subjectWordCount<=1.5?.293673297115:values.wordCount<=14.5?.364595175403:.404888696187:values.subjectWordCount<=2.5?.222421363921:values.wordCount<=18.5?.270453843779:.310890101508:values.gradeLevel<=8.35000038147?values.wordCount<=42.5?values.gradeLevel<=6.94999980927?.440158977657:.342750033472:values.subjectWordCount<=5.5?.488104735817:.444063461816:values.gradeLevel<=12.6499996185?values.wordCount<=45.5?.368664498767:.422755603703:values.subjectWordCount<=2.5?.301067569327:.362248185477:values.subjectWordCount<=11.5?values.gradeLevel<=7.55000019073?values.gradeLevel<=5.75?values.wordCount<=27.5?.358084714549:.395812603648:.349450481024:values.wordCount<=51.5?.279985077411:.32959622704:values.wordCount<=45.5?values.gradeLevel<=5.25?.353435874737:.283088917765:values.subjectWordCount<=14.5?.274152329667:.217044023225:values.gradeLevel<=5.25?values.wordCount<=6.5?.420758888124:values.wordCount<=128.5?values.wordCount<=77.5?values.subjectWordCount<=6.5?values.subjectWordCount<=2.5?.67648619614:.709810436737:values.subjectWordCount<=8.5?.677379753211:.650595011842:values.questionCount<=1.5?.614993253257:.678938269094:values.wordCount<=225.5?.594625955588:.536892361111:values.subjectWordCount<=7.5?values.gradeLevel<=15.0500001907?values.wordCount<=217.5?values.gradeLevel<=6.15000009537?values.wordCount<=57.5?.419728703201:.650999617694:values.gradeLevel<=9.94999980927?.643357674014:.570643437792:values.gradeLevel<=8.35000038147?values.questionCount<=2.5?.527971302363:.564875018061:.498302465998:.35612802498:values.subjectWordCount<=11.5?values.wordCount<=219.5?values.wordCount<=57.5?.436006795099:.556456089708:.413799723545:.371808875454;\r\n }", "function gradeTestME() {\n \n var i;\n for (var i = 0; i < questionsME.length; i++) {\n if (Response = Answer){\n totalScore++;\n }\n if (q2 = a2){\n totalScore++;\n }\n if (q3 = a3){\n totalScore++;\n }\n if (q4 = a5){\n totalScore++;\n } \n if (q6 = a7){\n totalScore++;\n } \n if (q8 = a8){\n totalScore++;\n }\n if (q9 = a9){\n totalScore++;\n }\n if (q10 = a10){\n totalScore++;\n }\n if (q11 = a11){\n totalScore++;\n }\n if (q12 = a12){\n totalScore++;\n }\n return totalScore;\n }\n}", "function calculate() {\r\n //---- FORM VALUES ----\r\n //variables: miles_driving, average_miles_per_gallon, cost_per_gallon, hotel_cost, snacks, other_costs\r\n //Estimate Distance\r\n var miles_driving = Number($(\"#miles_driving\").val()); //YOUR CODE HERE TO GET THE VALUE\r\n console.log(\"miles_driving \" + miles_driving);\r\n //MPG\r\n var average_miles_per_gallon = Number($(\"#average_miles_per_gallon\").val()); //YOUR CODE HERE TO GET THE VALUE\r\n console.log(\"average_miles_per_gallon \" + average_miles_per_gallon);\r\n //PPG\r\n var cost_per_gallon = Number($(\"#cost_per_gallon\").val()); //YOUR CODE HERE TO GET THE VALUE\r\n console.log(\"cost_per_gallon \" + cost_per_gallon);\r\n //Hotel\r\n var hotel_cost = Number($(\"#hotel_cost\").val());\r\n console.log(\"hotel_cost \" + hotel_cost);\r\n //Snacks\r\n var snacks_cost = Number($(\"#snacks_cost\").val());\r\n console.log(\"snacks_cost \" + snacks_cost);\r\n //other_costs\r\n var other_costs = Number($(\"#other_costs\").val());\r\n console.log(\"other_costs\" + other_costs);\r\n\r\n //----- CALCULATED VALUES -----\r\n //calculate: distance / mpg\r\n var number_of_gallons = miles_driving / average_miles_per_gallon; //YOUR CODE HERE TO GET THE VALUE\r\n console.log(\"number_of_gallons\" + number_of_gallons);\r\n //calculate: total_mileage_cost = estimate distance * ppg\r\n var total_mileage_cost = number_of_gallons * cost_per_gallon; //YOUR CODE HERE TO GET THE VALUE\r\n console.log(\"total_mileage_cost \" + total_mileage_cost);\r\n\r\n\r\n var sum = total_mileage_cost + hotel_cost + snacks_cost + other_costs;\r\n\r\n alert(\"$\" + sum);\r\n }", "function getAnswers() {\n $(\"#submit\").on(\"click\", function (event) {\n event.preventDefault();\n\n //First question data and if statement to put data in scoring categories\n var q1Data = $('input[name=q1]:checked').val();\n // console.log(q1Data);\n if (q1Data == \"true\") {\n correct++;\n console.log(q1Data + correct);\n } else if (q1Data == \"false\") {\n incorrect++;\n console.log(q1Data + incorrect);\n } else {\n unanswered++\n console.log(q1Data + unanswered);\n }\n\n //Second question data\n var q2Data = $('input[name=q2]:checked').val();\n if (q2Data == \"true\") {\n correct++;\n console.log(q2Data + correct);\n } else if (q2Data == \"false\") {\n incorrect++;\n console.log(q2Data + incorrect);\n } else {\n unanswered++\n console.log(q2Data + unanswered);\n }\n\n //Third question data\n var q3Data = $('input[name=q3]:checked').val();\n if (q3Data == \"true\") {\n correct++;\n console.log(q3Data + correct);\n } else if (q3Data == \"false\") {\n incorrect++;\n console.log(q3Data + incorrect);\n } else {\n unanswered++\n console.log(q3Data + unanswered);\n }\n //fourth question data\n var q4Data = $('input[name=q4]:checked').val();\n if (q4Data == \"true\") {\n correct++;\n console.log(q4Data + correct);\n } else if (q4Data == \"false\") {\n incorrect++;\n console.log(q4Data + incorrect);\n } else {\n unanswered++\n console.log(q4Data + unanswered);\n }\n\n })\n }", "function evaluate(criterios){\n for(let criterio of criterios){\n let modelo = criterio.notas.modelo\n let resultado = criterio.resultado\n \n /*\n #1\n modelo: {\n peso: 1,\n intervalo: {\n tipo: discreto,\n valor: [0, 5]\n }\n }\n resultado: 3\n \n #2\n modelo: {\n peso: 2,\n lista: [{\n texto: Danificada,\n valor: -1\n }, {...}, ...]\n }\n resultado: [0, 3]\n\n #3\n modelo: {\n peso: 2,\n boleano: {\n texto: Pets,\n valor: true/false\n }\n }\n resultado: true\n */\n \n let normal;\n if(modelo.intervalo){\n normal = (resultado - modelo.intervalo.valor[0])/(modelo.intervalo.valor[1] - modelo.intervalo.valor[0])\n }else if(modelo.booleano){\n normal = +(resultado == modelo.booleano.valor) * modelo.booleano.peso\n }else if(modelo.lista){\n let soma = modelo.lista.filter((v, i) => {\n return i in resultado\n }).reduce((acc, cur) => {\n return acc + cur.valor\n }, 0)\n let lista_ordenada = modelo.lista.sort((a, b) => a.valor - b.valor)\n let len_lista = modelo.lista.length\n \n let minimo = lista_ordenada[0].valor\n let maximo = lista_ordenada[len_lista-1].valor\n \n normal = (soma - minimo) / (maximo - minimo)\n }\n \n criterio.normal = normal\n criterio.normal_ponderada = normal * modelo.peso \n }\n \n let peso_total = criterios.reduce((acc, cur) => {\n return acc + cur.notas.peso\n }, 0)\n let nota_normal_ponderada_total = criterios.reduce((acc, cur) => acc + cur.normal_ponderada, 0)\n \n let nota_final = nota_normal_ponderada_total / peso_total\n \n return {\n final: nota_final,\n criterios: criterios.map(c => {\n return {\n resultado: c.resultado,\n normal: c.normal,\n peso: c.notas.peso,\n ponderada: c.ponderada\n }\n })\n }\n }", "function getAnswer(){\n const arr = data.split('\\n').map(n => parseInt(n))\n for(let i = 0; i < arr.length; i++){\n\n for(let j = arr.length; j > 0; j--){\n\n for (let k = 0; k < arr.length; k++){\n\n if (arr[i] + arr[j] + arr[k] === 2020){\n return (arr[i] * arr[j] * arr[k])\n } \n }\n }\n }\n}", "function checkSum(answer,observation){\n console.log(answer[0]);\n var correctAns = model.prob_OnS()[observation];\n var sum = 0;\n for (var i = 0; i < Object.keys(correctAns).length; i++){\n sum += correctAns[i];\n }\n // console.log(sum);\n if (answer[0].toFixed(3) == sum.toFixed(3)) {return 1;}\n else {return 0;}\n }", "function myFunction() {\n\n //Create variable to count correct answers \n // var correctAnswers = 0;\n var answers = 0;\n //Create variables for each question's input value\n //Create variables for each question's input value\n var quizOne = $(\"input:radio[name=question1]:checked\").val();\n var quizTwo = $(\"input:radio[name=question2]:checked\").val();\n var quizThree = $(\"input:radio[name=question3]:checked\").val();\n var quizFour = $(\"input:radio[name=question4]:checked\").val();\n var quizFive = $(\"input:radio[name=question5]:checked\").val();\n var quizSix = $(\"input:radio[name=question6]:checked\").val();\n var quizSeven = $(\"input:radio[name=question7]:checked\").val();\n var quizEight = $(\"input:radio[name=question8]:checked\").val();\n\n\n\n\n\n\n if (quizOne == \"correct\") {\n answers = answers + 12.5;\n }\n if (quizTwo == \"correct\") {\n answers = answers + 12.5;\n }\n if (quizThree == \"correct\") {\n answers = answers + 12.5;\n }\n if (quizFour == \"correct\") {\n answers = answers + 12.5;\n }\n if (quizFive == \"correct\") {\n answers = answers + 12.5;\n }\n if (quizSix == \"correct\") {\n answers = answers + 12.5;\n }\n if (quizSeven == \"correct\") {\n answers = answers + 12.5;\n }\n if (quizEight == \"correct\") {\n answers = answers + 12.5;\n }\n\n\n\n document.getElementById(\"message\").innerHTML = \"Score is \" + answers + \"%\";\n document.getElementById(\"result\").style.visibility = \"visible\";\n}", "function submitForm() {\nvar check = document.getElementsByClassName(\"q1\")\n\nvar select = document.getElementsByClassName(\"q2\")\n\nvar radio = document.getElementsByClassName(\"q3\")\n\n//store element by id to display results later\nvar result = document.getElementById(\"result\")\n\n//create array for checkbox answers this will become the value for var answer1\nvar checkboxesArray = []\n//create variables to eventually hold the users answers\nvar answers1, answers2, answers3\n\n//loop through all check boxes\nfor(var i = 0; i < check.length; i++) {\n\n\t//check if the current checkbox has been checked by the user, then do this\n\tif(check[i].checked) {\n\t\t//add item to checkboxesarray\n\t\tcheckboxesArray.push(check[i].value)\n\t}\n\tconsole.log(checkboxesArray)\n\tanswers1 = checkboxesArray\n}\n//stop function if no data for question1\nif(answers1.length == 0) {\n\t//add a class of success/failure to results\n\tresult.className = \"failure\"\n\t//update text content of results\n\tresult.textContent = \"you forgot to answer question 1\"\n\t//stop function if no answer\n\treturn\n}\n\n//confirm answer 1value\nconsole.log(\"answer 1: \" + answers1)\n\n//loop through select options\nfor (var i = 0; i < select.length; i++) {\n\n\t//check which was selected by the user, do this\n\tif(select[i].selected) {\n\t\t//set value of answer 2 to the value in the selected item\n\t\tanswers2 = select[i].value\n\t}\n}\n\n//stop funtion if no data for question 2\n\tif(answers2 == \"\") {\n\t\t//add a class of success/failure to results\n\t\treslut.className = \"failure\"\n\n\t\t//update the text content of results\n\t\tresult.textContent = \"you forgot to answer question 2\"\n\n\t\t//stop function if no answer\n\t\treturn\n\t}\n\n//confirm answer 2 value\nconsole.log(\"answer 2: \" + answers2)\n\n//loop through radio options\nfor (var i = 0; i < radio.length; i++) {\n\n\t//if the radio was selected by the user do this\n\tif(radio[i].checked) {\n\t\t//set value of answer 3 to the value in the radio item\n\t\tanswers3 = radio[i].value\n\t}\n}\n\n\n//stop funtion if no data for question 3\nif(answers3 == undefined) {\n\t\n\t//add a class of success/failure to results\n\tresult.className = \"failure\"\n\t\n\t//update the text content of results\n\tresult.textContent = \"you forgot to answer question 3\"\n\n\t//stop function if no answer\n\treturn\n}\n\n//confirm answer 3 value\nconsole.log(\"answer 3: \" + answers3)\n\n//create an object from user answers\nvar surveyAnswer = {\n\tchecked: answers1,\n\tselect: answers2,\n\tradio: answers3\n}\n\n//add a class of success to results\nresult.className = \"success\"\n\n//update the text content of results upon survey completion\nresult.textContent =\"Thanks for completing the Survey\"\n\n//confirm new objects existence\nconsole.log(\"current survey answers: #1 \" + surveyAnswer.checked + \" #2 \" + surveyAnswer.selected + \" #3 \" + surveyAnswer.radio)\n\n\n//add surveyAnswers to surveyArray\nsurveyArray.push(surveyAnswer)\n\n//check survey array to confirm new object\nconsole.log(surveyArray)\n\n//reset form for next user\nform.reset()\n}", "function calculator()\n {\n var worth1=parseFloat(document.getElementById(\"worth1\").value); \n //var worth = parseFloat(document.getElementById('worth1').value)*1;\n var grade1=parseFloat(document.getElementById(\"Assignment1\").value * worth1);\n var worth2=parseFloat(document.getElementById(\"worth2\").value); \n var grade2=parseFloat(document.getElementById(\"Assignment2\").value * worth2);\n var worth3=parseFloat(document.getElementById(\"worth3\").value); \n var grade3=parseFloat(document.getElementById(\"Assignment3\").value* worth3);\n var worth4=parseFloat(document.getElementById(\"worth4\").value); \n var grade4=parseFloat(document.getElementById(\"Assignment4\").value* worth4);\n \n var sum = worth1+worth2+worth3+worth4;\n var total=grade1+grade2+grade3+grade4;\n total = total/sum;\n\n var display=document.getElementById(\"outputDiv\");\n\n display.innerHTML=\"Your average grade is\\: \" +total +\"\\n The combined weigth of these assignments is: \" + sum;\n \n var aplus = (85 - (total*sum/100))/ (100-total);\n document.getElementById(\"A+holder\").innerHTML = aplus.toString();\n var a = (80 - (total*sum/100))/ (100-total);\n \n var worth3;\n var grade3;\n if (document.getElementById(\"worth3\").value != null){\n worth3=parseFloat(document.getElementById(\"worth3\").value); \n grade3=parseFloat(document.getElementById(\"Assignment3\").value* worth3);\n }else{\n worth3 = 0;\n grade3 = 0;\n }\n }", "function checkAnswers(){\n\t\n\tfunction question1 (){\n\t if ($('input[name=\"q1\"]:checked').val() == \"HTML\"){\n \tcorrect++;\n\t }\n\t else if ($('input[name=\"q1\"]:checked').val()== undefined){\n\t \tunanswered++;\n\t }\n\t else {\n\t \tincorrect++;\n\t }\n\t // console.log(question1);\n\t}\n\n\tfunction question2 (){\n\t if ($('input[name=\"q2\"]:checked').val() == \"CSS\"){\n \tcorrect++;\n\t }\n\t else if ($('input[name=\"q2\"]:checked').val()== undefined){\n\t \tunanswered++;\n\t }\n\t else {\n\t \tincorrect++;\n\t }\n\t // console.log(question2);\n\t}\n\n\tfunction question3 (){\n\t if ($('input[name=\"q3\"]:checked').val() == \"Javascript\"){\n \tcorrect++;\n\t }\n\t else if ($('input[name=\"q3\"]:checked').val()== undefined){\n\t \tunanswered++;\n\t }\n\t else {\n\t \tincorrect++;\n\t }\n\t // console.log(question3);\n\t}\n\t//call the above question functions.\n\t// console.log(typeof(correct));\n\t// console.log(typeof(incorrect));\n\t// console.log(typeof(unanswered));\n\t// console.log($('input[name=\"q1\"]:checked').val());\n\t// console.log($('input[name=\"q2\"]:checked').val());\n\t// console.log($('input[name=\"q3\"]:checked'));\n\t// console.log(\"not showResult\");\n\tquestion1();\n\tquestion2();\n\tquestion3();\n\tconsole.log(\"Correct answers: \" + correct);\n\tconsole.log(\"Incorrect answers: \"+ incorrect);\n\tconsole.log(\"Unanswered answers: \" + unanswered);\n\t$(\"#correct\").text(correct);\n\t$(\"#incorrect\").text(incorrect);\n\t$(\"#unanswered\").text(unanswered);\n \n\n}", "function checkAnswers(answers){\n var correctAns = model.transition(false);\n var result = []; var sum = 0;\n var allCorrect = 1;\n var error = {errorName:\"none\",badInputs:[]};//[error name, position that error was found]\n \n for (var i = 0; i < answers.length; i++){\n sum += answers[i];\n if(isNaN(answers[i])){\n error.errorName = \"nonnumber_error\";\n error.badInputs.push(i);\n }\n else if(answers[i] <0){\n error.errorName = \"negative_error\";\n error.badInputs.push(i);\n }\n if (round_number(answers[i],3) == round_number(correctAns[i],3)){\n result[i] = \"right\"; \n }\n else {result[i] = \"wrong\"; allCorrect = 0;}\n }\n result[answers.length] = allCorrect;\n if (round_number(sum,3) != round_number(1,3) && error.errorName==\"none\"){ error.errorName = \"sum_error\"; error.badInputs =[]}\n// else {result[answers.length+1] = \"sum_correct\";}\n \n result[answers.length+1] = error;\n return result;\n }", "function calculate_respondable(values) {\r\n if (isNaN(values.fleschKincaidGradeLevel)) {\r\n return 0;\r\n }\r\n values.gradeLevel = values.fleschKincaidGradeLevel;\r\n return values.questionCount <= .5 ? values.wordCount <= 8.5 ? values.wordCount <= 1.5 ? values.subjectWordCount <= 1.5 ? .0733218726262 : values.wordCount <= .5 ? values.subjectWordCount <= 3.5 ? .122914695147 : values.subjectWordCount <= 6.5 ? .145072640304 : .136819773707 : .198588629296 : values.subjectWordCount <= 1.5 ? .183093642547 : values.gradeLevel <= -.5 ? .233720662678 : values.gradeLevel <= 6.60000038147 ? values.wordCount <= 5.5 ? .298683848408 : .331874554526 : .239006626723 : values.subjectWordCount <= 8.5 ? values.wordCount <= 27.5 ? values.gradeLevel <= 9.55000019073 ? values.subjectWordCount <= 1.5 ? .293673297115 : values.wordCount <= 14.5 ? .364595175403 : .404888696187 : values.subjectWordCount <= 2.5 ? .222421363921 : values.wordCount <= 18.5 ? .270453843779 : .310890101508 : values.gradeLevel <= 8.35000038147 ? values.wordCount <= 42.5 ? values.gradeLevel <= 6.94999980927 ? .440158977657 : .342750033472 : values.subjectWordCount <= 5.5 ? .488104735817 : .444063461816 : values.gradeLevel <= 12.6499996185 ? values.wordCount <= 45.5 ? .368664498767 : .422755603703 : values.subjectWordCount <= 2.5 ? .301067569327 : .362248185477 : values.subjectWordCount <= 11.5 ? values.gradeLevel <= 7.55000019073 ? values.gradeLevel <= 5.75 ? values.wordCount <= 27.5 ? .358084714549 : .395812603648 : .349450481024 : values.wordCount <= 51.5 ? .279985077411 : .32959622704 : values.wordCount <= 45.5 ? values.gradeLevel <= 5.25 ? .353435874737 : .283088917765 : values.subjectWordCount <= 14.5 ? .274152329667 : .217044023225 : values.gradeLevel <= 5.25 ? values.wordCount <= 6.5 ? .420758888124 : values.wordCount <= 128.5 ? values.wordCount <= 77.5 ? values.subjectWordCount <= 6.5 ? values.subjectWordCount <= 2.5 ? .67648619614 : .709810436737 : values.subjectWordCount <= 8.5 ? .677379753211 : .650595011842 : values.questionCount <= 1.5 ? .614993253257 : .678938269094 : values.wordCount <= 225.5 ? .594625955588 : .536892361111 : values.subjectWordCount <= 7.5 ? values.gradeLevel <= 15.0500001907 ? values.wordCount <= 217.5 ? values.gradeLevel <= 6.15000009537 ? values.wordCount <= 57.5 ? .419728703201 : .650999617694 : values.gradeLevel <= 9.94999980927 ? .643357674014 : .570643437792 : values.gradeLevel <= 8.35000038147 ? values.questionCount <= 2.5 ? .527971302363 : .564875018061 : .498302465998 : .35612802498 : values.subjectWordCount <= 11.5 ? values.wordCount <= 219.5 ? values.wordCount <= 57.5 ? .436006795099 : .556456089708 : .413799723545 : .371808875454;\r\n }", "function calc(){\r\n\"use strict\";\r\nnumPFail = (numFail/numTotalRuns)*100;\r\nnumP0 = (num0/numTotalRuns)*100;\r\nnumP1 = (num1/numTotalRuns)*100;\r\nnumP2 = (num2/numTotalRuns)*100;\r\nnumP3 = (num3/numTotalRuns)*100;\r\nnumP4 = (num4/numTotalRuns)*100;\r\nnumP5 = (num5/numTotalRuns)*100;\r\nnumRatePSB = numTotalPSB/numTotalRuns;\r\nnumRateRML = numTotalRML/numTotalRuns;\r\n}", "function solveValue(){\n //ph, pka, a, ha\n // ensure that all 3 inputsValue is not null\n let valid = 0;\n for(let i = 0; i < inputsValue.length; i++){\n if(!solve[i] && (inputsValue[i] != null) && inputsValue[i] != ''){\n valid++;\n }\n }\n\n if(valid == 3){\n switch(getSolve()){\n case 0:\n try{\n if(inputsValue[3] == 0){\n throw \"invalid value\";\n }\n inputs[0].value = Number(inputsValue[1]) + Number(Math.log10(inputsValue[2]/inputsValue[3]));\n inputsValue[0] = inputs[0].value;\n } catch (err){\n inputs[0].value = 0;\n }\n break;\n case 1:\n try{\n if(inputsValue[3] == 0){\n throw \"invalid value\";\n }\n inputs[1].value = -1 * (-Number(inputsValue[0]) + Number(Math.log10(inputsValue[2]/inputsValue[3]) ));\n\n } catch (err){\n inputs[1].value = 0;\n }\n\n break;\n case 2:\n try{\n if(inputsValue[3] == 0){\n throw \"invalid value\";\n }\n inputs[2].value = Math.pow(10, (Number(inputsValue[0]) - Number(inputsValue[1]))) * Number(inputsValue[3]);\n } catch{\n inputs[2].value = 0;\n }\n\n break;\n case 3:\n try{\n if(inputsValue[3] == 0){\n throw \"invalid value\";\n }\n inputs[3].value = Math.pow(Math.pow(10, (Number(inputsValue[0]) - Number(inputsValue[1]))) /Number(inputsValue[2]), -1);\n } catch{\n inputs[3].value = 69;\n }\n break;\n }\n }\n}", "function calculateResults() {\n //UI vars\n const height = document.querySelector('#height').value;\n const weight = document.querySelector('#weight').value;\n const age = document.querySelector('#age').value;\n const sex = document.querySelector('#sex').value;\n const activity = document.querySelector('#activity').value;\n\n //Output vars\n const dailyCalorieRequirements = document.querySelector('#dailyCalorie');\n const daliyProteinIntake = document.querySelector('#dailyProtein');\n const dailyCarbsIntake = document.querySelector('#dailyCarbs');\n const dailyFatIntake = document.querySelector('#dailyFat');\n\n //calculating basal metabolic rate\n const bmr = ((10 * weight) + (6.25 * height) - (5 * age)) + parseFloat(sex);\n \n if (isFinite(bmr)) {\n let dailyCalorie = bmr * parseFloat(activity);\n dailyCalorieRequirements.value = Math.round(dailyCalorie);\n daliyProteinIntake.value = getAmountOfMacronutrient(dailyCalorieRequirements.value, 25, 'p');\n dailyCarbsIntake.value = getAmountOfMacronutrient(dailyCalorieRequirements.value, 35, 'c');\n dailyFatIntake.value = getAmountOfMacronutrient(dailyCalorieRequirements.value, 40, 'f');\n displayResults();\n hideLoading();\n displayMacrosRatioChart();\n } else {\n showError('Please check your numbers');\n }\n}", "function getValues (){\n\tvar num1 = parseInt( document.getElementById(\"first\").value );\n\tvar num2 = parseInt( document.getElementById(\"second\").value );\n\n\t\n\t// this line of code identifies the radio button element by its name (math-function)\n\tvar radiobuttons= document.getElementsByName(\"math-function\")\n\t// console.log (radiobuttons);\n\n\t// created a new variable (thingToDo).\n\tvar thingToDo = null;\n\t\n\t// created a for loop that loops around the number of radio buttons.\n\n\n\tfor (var i = 0; i < radiobuttons.length; i++) {\n\t\t// console.log(\"Is it checked?\", radiobuttons[i].checked)\n\t\t// console.log(\"What's the value?\", radiobuttons[i].value)\n\n\t// If a radio button is checked, it then feeds its value to the variable \"thingToDo\".\n\t\tif (radiobuttons[i].checked) {\n\t\t\tthingToDo=radiobuttons[i].value\n\t\t}\n\t}\n// This part of the program creates a new variable called \"answer\". It then uses if/else if logic\n// to determine which math operation to apply to the 2 input numbers. \n\tconsole.log(thingToDo);\n\tvar answer = null;\n\tif (thingToDo === \"Addition\") {\n\t\tanswer = add(num1, num2);\n\t} else if (thingToDo===\"Subtraction\"){\n\t\tanswer = subtract (num1, num2)\n\n\t}else if (thingToDo===\"Multiplication\"){\n\t\tanswer = multiply (num1, num2)\n}\n\n\telse if (thingToDo===\"Division\"){\n\t\tanswer = divide (num1, num2)\n}\n\n\tconsole.log(\"TADA!\", answer);\t\n\toutputToDom(answer)\n}", "function exam(a)\r\n{\r\n //solving fexam\r\nlet fexam = (60/100)*a\r\n//allowing access to fexam result\r\nreturn fexam\r\n\r\n}", "function fillQAndA(){\t\t\n\t\tvar count = 0;\n\t\tvar arraySpot = 0;\n\t\twhile(count <=15){\n\t\t\t\n\t\t\n\t\t\t/* **get 2 random numbers from array ranNum1,ranNum2 */\n\t\t\t\n\t\t\tvar ranNum1 = Math.floor(Math.random() * nums.length);\n\t\t\tvar ranNum2 = Math.floor(Math.random() * nums.length);\n\t\t\t\n\t\t\t\n\t\t\t/* **get and operator */ \n\t\t\t\n\t\t\tvar whichOperator = Math.floor(Math.random() * operands.length);\n\t\t\tvar operator = operands[whichOperator];\n\t\t\t\n\t\t\t\n\t\t\t\tif (operator == '+') /* creates correct problems for operand */\n\t\t\t\t\t{\n\t\t\t\t\t\t\n\t\t\t\t\t\tvar answer = ranNum1 + ranNum2;\n\t\t\t\t\t\tanswer = answer.toFixed(1);\n\t\t\t\t\t\tqAndA[count] = ranNum1+ ' + ' +ranNum2;\n\t\t\t\t\t\tquestions[arraySpot] = ranNum1+ ' + ' +ranNum2;\n\t\t\t\t\t\tanswers[arraySpot]= answer;\n\t\t\t\t\t\tqAndA[count+1] = answer;\n\t\t\t\t\t\tcount = count+2;\n\t\t\t\t\t\tarraySpot++;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\telse if (operator == '-')\n\t\t\t\t\t{\n\t\t\t\t\t\t\n\t\t\t\t\t\tvar answer = ranNum1 - ranNum2;\n\t\t\t\t\t\tanswer = answer.toFixed(1);\n\t\t\t\t\t\tqAndA[count] = ranNum1+ ' - ' +ranNum2;\n\t\t\t\t\t\tquestions[arraySpot] = ranNum1+ ' - ' +ranNum2;\n\t\t\t\t\t\tanswers[arraySpot]= answer;\n\t\t\t\t\t\tqAndA[count+1] = answer;\n\t\t\t\t\t\tcount = count+2;\n\t\t\t\t\t\tarraySpot++;\n\t\t\t\t\t}\n\t\t\t\t\n\t\t\t\telse if (operator == '*')\n\t\t\t\t\t{\n\t\t\t\t\t\t\n\t\t\t\t\t\tvar answer = ranNum1 * ranNum2;\n\t\t\t\t\t\tanswer = answer.toFixed(1);\n\t\t\t\t\t\tqAndA[count] = ranNum1+ ' * ' +ranNum2;\n\t\t\t\t\t\tquestions[arraySpot] = ranNum1+ ' * ' +ranNum2;\n\t\t\t\t\t\tanswers[arraySpot]= answer;\n\t\t\t\t\t\tqAndA[count+1] = answer;\t\n\t\t\t\t\t\tcount = count+2;\n\t\t\t\t\t\tarraySpot++;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\telse if (operator == '/')\n\t\t\t\t\t{\n\t\t\t\t\t\tvar answer = ranNum1 / ranNum2;\n\t\t\t\t\t\tanswer = answer.toFixed(1);\n\t\t\t\t\t\tqAndA[count] = ranNum1+ ' / ' +ranNum2;\n\t\t\t\t\t\tquestions[arraySpot] = ranNum1+ ' / ' +ranNum2;\n\t\t\t\t\t\tanswers[arraySpot]= answer;\n\t\t\t\t\t\tqAndA[count+1] = answer;\n\t\t\t\t\t\tcount = count+2;\n\t\t\t\t\t\tarraySpot++;\n\t\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\twindow.alert(\"Error in Operand\");\n\t\t\t\t\t}\n\t\t\t\t}\n}", "function getVals() {\n\n //Get Current Grade\n var currentGrade = document.getElementById(\"currentGrade\").value;\n currentGrade /= 100;\n\n //Get Desired Grade\n var desiredGrade = document.getElementById(\"desiredGrade\").value;\n desiredGrade /= 100;\n\n //Get Weight\n var weight = document.getElementById(\"weight\").value;\n weight /= 100;\n\n //Calcuate Final Grade\n var finalGrade = (desiredGrade - (1-weight)*currentGrade) / weight;\n finalGrade = Math.round(finalGrade * 100)\n\n\n if(finalGrade > 90){\n document.getElementById(\"result\").innerHTML = \"You need a \" + finalGrade + \"% on your final exam to get a \" + desiredGrade * 100 + \" in the class. Better start studying.\";\n } else if (finalGrade <= 90 && finalGrade > 80) {\n document.getElementById(\"result\").innerHTML = \"You need a \" + finalGrade + \"% on your final exam to get a \" + desiredGrade * 100 + \" in the class. Could be worse.\";\n } else if (finalGrade <= 80 && finalGrade > 70) {\n document.getElementById(\"result\").innerHTML = \"You need a \" + finalGrade + \"% on your final exam to get a \" + desiredGrade * 100 + \" in the class. No sweat, you got this.\";\n } else if (finalGrade <= 70 && finalGrade > 60) {\n document.getElementById(\"result\").innerHTML = \"You need a \" + finalGrade + \"% on your final exam to get a \" + desiredGrade * 100 + \" in the class. This'll be easy.\";\n } else {\n document.getElementById(\"result\").innerHTML = \"You need a \" + finalGrade + \"% on your final exam to get a \" + desiredGrade * 100 + \" in the class. Enjoy not studying!\";\n }\n\n\n }", "function calcResults() {\n\t\trbAge.innerText = parseInt(currentAge)+parseInt(yearsToRetirement);\n\t\trbIncome.innerText = rawNestAmount*targetRetirementIncomePercentage;\n\t\trbInterest.innerText = (rawNestAmount-(rawNestAmount*targetRetirementIncomePercentage))*targetInterestRateToNest;\n\t\trbBalance.innerText = (rawNestAmount-(rawNestAmount*targetRetirementIncomePercentage))+(rawNestAmount-(rawNestAmount*targetRetirementIncomePercentage))*targetInterestRateToNest;\n\t}", "function evaluateAnswers(answer) {\n\n\tif(answer === answers[0].answer.toUpperCase()) {\n\t\tcorrectAnswer = answers[0].isCorrect;\n\t}\n\n\telse if(answer === answers[1].answer.toUpperCase()) {\n\t\tcorrectAnswer = answers[1].isCorrect;\n\t}\n\telse if(answer === answers[2].answer.toUpperCase()) {\n\t\tcorrectAnswer = answers[2].isCorrect;\n\t}\n\telse if(answer === answers[3].answer.toUpperCase()) {\n\t\tcorrectAnswer = answers[3].isCorrect;\n\t}\n\n\telse {\n\t\tunanswered = true;\n\t}\n}", "function pazymiuVidurkis(q,w,e,r,t) {\n var atsakymas = (q+w+e+r+t)/5;\n console.log(atsakymas);\n}", "function grade() {\n\n//question 1 answer r1\nif (answer1 === \"r1\") {\n correct++;\n } else if ((answer1 === \"r2\") || (answer1 === \"r3\")) {\n incorrect++;\n } else {\n unanswered++;\n }\n\n//question 2 answer r3\nif (answer2 === \"r3\") {\n correct++;\n } else if ((answer2 === \"r2\") || (answer2 === \"r1\")) {\n incorrect++;\n } else {\n unanswered++;\n }\n//question 3 answer r1\nif (answer3 === \"r1\") {\n correct++;\n } else if ((answer3 === \"r2\") || (answer3 === \"r3\")) {\n incorrect++;\n } else {\n unanswered++;\n }\n//question 4 answer r2\nif (answer4 === \"r2\") {\n correct++;\n } else if ((answer4 === \"r1\") || (answer4 === \"r3\")) {\n incorrect++;\n } else {\n unanswered++;\n }\n//question 5 answer r3\nif (answer5 === \"r3\") {\n correct++;\n } else if ((answer5 === \"r2\") || (answer5 === \"r1\")) {\n incorrect++;\n } else {\n unanswered++;\n }\n}", "function calc() {\n // 4. Display output to user\n answer.innerText = parseInt(first.value) + parseInt(second.value);\n}", "function do_math() {\n\n\t\t\t\tvar end = Mt;\n\n\t\t\t\tfor (var i = end; i >= Mf; i--) {\n\n\t\t\t\t\tX = (W - ((B - 1) * i)) / B;\n\n\t\t\t\t\tif (X % 1 == 0) {\n\n\t\t\t\t\t\tsolutions++;\n\n\t\t\t\t\t\t$('.tbody').append('<tr class=\"trow\"><td class=\"td_block\">' + X + '</td><td class=\"td_margin\">' + i + '</td></tr>');\n\n\t\t\t\t\t};\n\n\t\t\t\t};\n\n\t\t\t\t$('.output_title').html('You have ' + solutions + ' solution(s):');\n\n\n\t\t\t}", "function calc_power()\n {\n //military_science = parseInt(GM_getValue(\"milisci\", parseInt($('#milisci option:selected').text()).toString()));\n //magic_science = parseInt(GM_getValue(\"magisci\", parseInt($('#milisci option:selected').text()).toString());\n military_science = parseInt($('#milisci option:selected').text());\n magic_science = parseInt($('#magisci option:selected').text());\n unit_op[1][4] = 3*magic_science;\n unit_dp[1][4] = 3*magic_science;\n\n raw_op = parseInt($('#s1').text().replace(',',''))*unit_op[race-1][0] + parseInt($('#s2').text().replace(',',''))*unit_op[race-1][1] + parseInt($('#s3').text().replace(',',''))*unit_op[race-1][2] +\n parseInt($('#s4').text().replace(',',''))*unit_op[race-1][3] + parseInt($('#s5').text().replace(',',''))*unit_op[race-1][4];\n raw_dp = parseInt($('#s1').text().replace(',',''))*unit_dp[race-1][0] + parseInt($('#s2').text().replace(',',''))*unit_dp[race-1][1] + parseInt($('#s3').text().replace(',',''))*unit_dp[race-1][2] +\n parseInt($('#s4').text().replace(',',''))*unit_dp[race-1][3] + parseInt($('#s5').text().replace(',',''))*unit_dp[race-1][4] + parseInt($('#army_peasants').text().replace(',',''))*0.05;\n mod_op = Math.round(raw_op*(1 + military_science*0.1)); //*(1 + parseInt($('#experience'))*0.015)*(parseInt($('#morale'))/100);\n mod_dp = Math.round(raw_dp*(1 + military_science*0.1)); //Math.round((raw_dp*(1 + military_science*0.1) + 0.00001)*100)/100 //*(1 + parseInt($('#experience'))*0.015)*(parseInt($('#morale'))/100);\n if (in_self_city)\n {\n craw_op = parseInt($('#cityS1').text().replace(',',''))*unit_op[race-1][0] + parseInt($('#cityS2').text().replace(',',''))*unit_op[race-1][1] + parseInt($('#cityS3').text().replace(',',''))*unit_op[race-1][2] +\n parseInt($('#cityS4').text().replace(',',''))*unit_op[race-1][3] + parseInt($('#cityS5').text().replace(',',''))*unit_op[race-1][4];\n craw_dp = parseInt($('#cityS1').text().replace(',',''))*unit_dp[race-1][0] + parseInt($('#cityS2').text().replace(',',''))*unit_dp[race-1][1] + parseInt($('#cityS3').text().replace(',',''))*unit_dp[race-1][2] +\n parseInt($('#cityS4').text().replace(',',''))*unit_dp[race-1][3] + parseInt($('#cityS5').text().replace(',',''))*unit_dp[race-1][4] + parseInt($('#city_peasants').text().replace(',',''))*0.05;\n cmod_op = Math.round(craw_op*(1 + military_science*0.1)); //*(1 + parseInt($('#experience'))*0.015)*(parseInt($('#morale'))/100);\n cmod_dp = Math.round(craw_dp*(1 + military_science*0.1)); //*(1 + parseInt($('#experience'))*0.015)*(parseInt($('#morale'))/100);\n }\n }", "function main() {\n finalDerivative = \"\";\n tempDerivative = \"\";\n\n var funcInput = $(\".input\").val();\n\n funcInput = cleanFunction(funcInput);\n var funcTerms = findTerms(funcInput);\n //calculateDerivative(funcInput);\n\n for (i in funcTerms) {\n //console.log(funcTerms[i]);\n console.log(determineWhichRule(funcTerms[i]));\n }\n\n console.log(\"input: \" + funcInput);\n\n //$(\".answer\").text(tempDerivative);\n $(\".input\").val(\"\");\n}", "function calcScore(givenAnswers, correctAnswers) {\r\n givenAnswers.forEach((answer, i) => {\r\n if (answer === correctAnswers[i]) {\r\n score++;\r\n }\r\n });\r\n}", "function tabulateAnswers() {\n // initialize variables for each choice's score\n // If you add more choices and outcomes, you must add another variable here.\n var yes1score = 0;\n var no1score = 0;\n var yes2score = 0;\n var no2score = 0;\n var yes3score = 0;\n var no3score = 0;\n var yes4score = 0;\n var no4score = 0;\n var yes5score = 0;\n var no5score = 0;\n var yes9score = 0;\n var no9score = 0;\n\n var c1score = 0;\n var c2score = 0;\n var c3score = 0;\n var c4score = 0;\n\n // get a list of the radio inputs on the page\n var choices = document.getElementsByTagName('input');\n console.log(choices)\n // loop through all the radio inputs\n for (i=0; i<choices.length; i++) {\n // if the radio is checked..\n if (choices[i].checked) {\n // add 1 to that choice's score\n if (choices[i].value == 'yes1score') {\n yes1score = yes1score + 1;\n }\n if (choices[i].value == 'no1score') {\n no1score = no1score + 1;\n }\n if (choices[i].value == 'yes2score') {\n yes2score = yes2score + 1;\n }\n if (choices[i].value == 'yes3score') {\n yes3score = yes3score + 1;\n }\n if (choices[i].value == 'no2score') {\n no3score = no3score + 1;\n }\n if (choices[i].value == 'c4') {\n c4score = c4score + 1;\n }\n if (choices[i].value == 'yes1') {\n c1score = c1score + 1;\n }\n if (choices[i].value == 'c2') {\n c2score = c2score + 1;\n }\n if (choices[i].value == 'c3') {\n c3score = c3score + 1;\n }\n if (choices[i].value == 'c4') {\n c4score = c4score + 1;\n }\n if (choices[i].value == 'c4') {\n c4score = c4score + 1;\n }\n if (choices[i].value == 'c4') {\n c4score = c4score + 1;\n }\n\n //calling all the text boxes\n var answerbox = document.getElementById('box');\n\n // If you add more choices and outcomes, you must add another if statement below.\n }\n }\n // Find out which choice got the highest score.\n // If you add more choices and outcomes, you must add the variable here.\n var maxscore = Math.max(yes1score,no1score,yes2score,no2score,yes3score,no3score,yes4score,no4score,yes5score,no5score,yes9score,no9score);\n\n // Display answer corresponding to that choice\n var answerbox = document.getElementById('answer');\n if (c1score == maxscore) { // If user chooses the first choice the most, this outcome will be displayed.\n answerbox.innerHTML = \"Thank you for taking our survey! Feel free to contact us for more questions or feedback\";\n }\n if (c2score == maxscore) { // If user chooses the second choice the most, this outcome will be displayed.\n answerbox.innerHTML = \"Thank you for taking our survey! Feel free to contact us for more questions or feedback\";\n }\n if (c3score == maxscore) { // If user chooses the third choice the most, this outcome will be displayed.\n answerbox.innerHTML = \"Thank you for taking our survey! Feel free to contact us for more questions or feedback\";\n }\n if (c4score == maxscore) { // If user chooses the fourth choice the most, this outcome will be displayed.\n answerbox.innerHTML = \"Thank you for taking our survey! Feel free to contact us for more questions or feedback\";\n }\n // If you add more choices, you must add another response below.\n}", "function results() {\n // Answer variables.\n correct = 0;\n incorrect = 0;\n unanswered = 0;\n\n for (var i = 1; i < 11; i++) {\n\n if ($(\"input[name='q\" + i + \"']:checked\").val() == \"x\") {\n\n correct++;\n } else if ($(\"input[name='q\" + i + \"']:checked\").val() === undefined) {\n\n unanswered++;\n } else {\n\n incorrect++;\n }\n\n // Display results and hide unwanted elements.\n \n $(\"#quiz\").hide();\n $(\"#whichState\").hide();\n $(\"#validate\").hide();\n $(\"#score\").html(\"Correct: \" + correct + \"<br/>Incorrect: \" + incorrect + \"<br/>Unanswered: \" + unanswered);\n $(\"#timer\").hide();\n $(\"#tally\").show();\n $(\"#clear\").show();\n $(\"#jack\").show();\n }\n\n }", "function check_correctness() {\n\tvar answerText = document.getElementById(\"answer-input\").value.replace(/,/g , \"\");\n\tvar answerSplit = answerText.split(\" \");\n\tvar weightTotal = 0; //sums weight of matching user input matching keywords\n\tvar keywords = [];\n\tvar toCheck;\n\t//brute force, but should be okay with the low amount of keywords we expect\n\tfor (var i = 0; i < answerSplit.length; i++) {\n\t\tfor (var j = 0; j < chosenTopics[numAnswered].keywords.length; j++) {\n\t\t\tkeywords.push(chosenTopics[numAnswered].keywords[j].keyword);\n\t\t}\n\t\ttoCheck = $.inArray(answerSplit[i], keywords);\n\t\tif (toCheck !== -1) {\n\t\t\tweightTotal += parseInt(chosenTopics[numAnswered].keywords[toCheck].weight);\n\t\t\tpresentKeywordIds.push(chosenTopics[numAnswered].keywords[toCheck].id);\n\t\t}\n\t}\n\tchosenTopics[numAnswered].answerWeightSum = weightTotal;\n}", "function calculateOptionsCosts() {\n let tollCheck = document.getElementById(\"tollTagCheck\").checked;\n let gpsCheck = document.getElementById(\"gpsCheck\").checked;\n let roadCheck = document.getElementById(\"roadSideCheck\").checked;\n let optionsCost = 0;\n\n if (tollCheck) {\n optionsCost += 3.95;\n }\n \n if (gpsCheck) {\n optionsCost += 2.95;\n }\n \n if (roadCheck) {\n optionsCost += 2.95;\n }\n optionsCost *= document.getElementById(\"numDaysInput\").value;\n return optionsCost;\n}", "function questionAnswers(answer) {\r\n weightquestion[qstNum] = document.getElementById(\"questionW\").checked;\r\n answers[qstNum] = answer;\r\n console.log(answers);\r\n nextQuestion(\"up\");\r\n}", "function evaluate() {\n $('#quizBoard').hide();\n $('#results').show();\n if ($('#q1f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q2t').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q3f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q4f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q5t').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q6t').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q7f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q8f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n if ($('#q9f').is(':checked')) {\n correct++\n } else {\n incorrect++\n }\n $('#corr').html(correct)\n $('#incorr').html(incorrect)\n $('#percent').html(correct/9)\n}", "function askMath() {\n var a = Math.floor(Math.random() * 10) + 1\n var b = Math.floor(Math.random() * 10) + 1\n var op = [\"*\", \"+\", \"/\", \"-\"][Math.floor(Math.random() * 4)]\n var promptString = \"How much is \" + a + \" \" + op + \" \" + b + \"?\"\n var answer = Math.round(eval(a + op + b) * 100) / 100\n // randomly generated N = 40 length array 0 <= A[N] <= 39\n var answers = Array(3)\n .fill()\n .map(() => Math.round(Math.random() * 40))\n // Add correct answer to array of wrong answers\n answers.push(answer)\n // Shuffle array\n answers.sort(() => Math.random() - 0.5)\n\n // Fill math object, which is passed by reference\n mathObj.promptString = promptString\n mathObj.answers = answers\n mathObj.correctAnswer = answer\n} // Returns nothing, math object is passed by reference and manipulated", "function COMPUTE() {\n\n var result, final_result, R1i, R2i, decade1, decade2, error, min_error, best_R1, best_R2, R1, R2, qcurrent, best_qcurrent, qcurrent_error, min_qcurrent_error;\n \n // Gather all the input fields from the HTML page. Should probably use Jquery on this project.\n var voltage = document.getElementById(\"vin\").value;\n var target_qcurrent = document.getElementById(\"qcurrent_in\").value;\n var voltage_out = document.getElementById(\"vout\").value;\n var eseries_selected = document.getElementById(\"eseries\").value;\n \n // Thanks to math.js, we simply pass the equation input by the user directly into the math.compile method and \n // it gets parsed into javascript which we later access using the .evaluate method.\n var equation = math.compile(document.getElementById(\"equation\").value); \n\n\n // The core of this algorithm is this loop, so this seems as good a place as any to describe it's whole approach.\n // This algorithm is EXTREMELY crude, but it works. It could definitely be improved to be more of an intelligent sort.\n // Four nested implicit for loops iterate through every possible common value resistor for the chosen e-series.\n // For E12 that isn't too bad, but for E192 that means 2,359,296 iterations of executing that inner code. Computers are great!\n for (R1i = 0; R1i < eseries[eseries_selected].length; R1i++) {\n for (R2i = 0; R2i < eseries[eseries_selected].length; R2i++) {\n for (decade1 = 1; decade1 < 8; decade1++) {\n for (decade2 = 1; decade2 < 8; decade2++) {\n // To iterate through every e-series resistor, we need to multiply the base values by their magnitude (ex. 1.2ohm versus 12kohm)\n R1 = eseries[eseries_selected][R1i] * (10 ** decade1);\n R2 = eseries[eseries_selected][R2i] * (10 ** decade2);\n //result = voltage * (R2/(R1+R2));\n result = equation.evaluate({vin:voltage, R1:R1, R2:R2});\n error = Math.abs(voltage_out - result) / voltage_out;\n qcurrent = voltage / (R1 + R2);\n qcurrent_error = Math.abs(qcurrent - target_qcurrent) / target_qcurrent;\n if (((error <= min_error) && (qcurrent_error <= min_qcurrent_error)) || ((min_error == undefined) || (min_qcurrent_error == undefined))) {\n min_error = error;\n min_qcurrent_error = qcurrent_error;\n final_result = result;\n best_R1 = R1;\n best_R2 = R2;\n best_qcurrent = qcurrent;\n }\n }\n }\n }\n }\n\n // Pass results back to the HTML page in their copy-able fields.\n document.getElementById(\"R1\").value = best_R1;\n document.getElementById(\"R2\").value = best_R2;\n document.getElementById(\"qcurrent_out\").value = best_qcurrent;\n}", "function doLogic() {\n \"use strict\";\n // Here we snatch values from the answer box....\n var Formula = document.getElementById(\"answerBox\").value;\n // Evaluate the formula....\n var Result = eval(\"(\" + Formula + \")\");\n // Display results!\n li(Result);\n\n // Check and handle any errors that occur during formula evaluation.\n if (answerBox.value === \"undefined\") {\n document.getElementById(\"answerBox\").value = \"Syntax Error\";\n }\n if (answerBox.value === \"NaN\") {\n document.getElementById(\"answerBox\").value = \"Not Possible!\";\n }\n}", "evaluateAnswer(userAnswer){\n \tconst {value1, value2, value3, proposedAnswer} = this.state;\n \tconst corrAnswer = value1 + value2 + value3;\n \treturn(\n \t\t (corrAnswer === proposedAnswer && userAnswer === 'true') ||\n \t\t (corrAnswer !== proposedAnswer && userAnswer === 'false')\n \t);\n }", "function calculation () {\n number = document.getElementById('base-a').value\n number = parseInt(number)\n number2 = document.getElementById('base-b').value\n number2 = parseInt(number2)\n height = document.getElementById('height').value\n height = parseInt(height)\n number = number + number2\n number = number * height / 2\n document.getElementById('answer').innerHTML = number\n}", "function equalResult(){\n equation.push(aNumber);\n aNumber = \"\";\n var result = math.eval(equation.join(\"\"));\n equation = [];\n equation.push(result);\n if (Number.isNaN(result)){\n result = \"Error\"; \n }\n answerBox.textContent = result;\n eqtext += \" \" + \"=\" + \" \" + result;\n result = \"\";\n equationBox.textContent = eqtext;\n eqtext = \"\";\n \n}", "function question3() {\n var n1 = Number(document.getElementById(\"n1\").value); \n var n2 = Number(document.getElementById(\"n2\").value); \n var operator = document.getElementById(\"operation\").value;\n var answer = document.getElementById(\"answer\");\n var result = 0\n //switch\n switch (operator) {\n //operations\n case \"add\": result = n1 + n2; break;\n case \"subtract\": result = n1 - n2; break; \n case \"multiply\": result = n1 * n2; break;\n case \"divide\": result = n1 / n2; break;\n case \"modulus\": result = n1 % n2; break;\n }\n //get by text content\n answer.textContent = result + \" is your answer \" + username + \"!\";\n}", "function calculate()\n {\n if (operator == 1)\n {\n current_input = eval(memory) * eval(current_input);\n };\n if (operator == 2)\n {\n current_input = eval(memory) / eval(current_input);\n // If divide by 0 give an ERROR message\n var initial_value = current_input.toString();\n if (initial_value == \"Infinity\")\n {\n current_input = \"ERROR\"\n };\n };\n if (operator == 3)\n {\n current_input = eval(memory) + eval(current_input);\n };\n if (operator == 4)\n {\n current_input = eval(memory) - eval(current_input);\n };\n if (operator == 5)\n {\n current_input = Math.pow(eval(memory), eval(current_input));\n };\n operator = 0; //clear operator\n memory = \"0\"; //clear memory\n displayCurrentInput();\n }", "function standardCalculations() {\n // 1. has been populated for the first time, mark default checkboxes\n const perPhone = $( '#perPhone' ).prop('checked');\n const perPhoneLongDistance = $( '#perPhoneLongDistance' ).prop('checked');\n if (isCheckboxOff('#perPhone') && isCheckboxOff('#allPhones')) {\n $( '#perPhone' ).prop('checked', true);\n }\n if (isCheckboxOff('#perPhoneLongDistance') && isCheckboxOff('#allPhonesLongDistance')) {\n $( '#perPhoneLongDistance' ).prop('checked', true);\n }\n\n const plansCount = parseInt($( '#plansCount' ).val().replace(/,/g, ''));\n const monthlyPayment = valueOf('#monthlyPayment');\n const longDistance = valueOf('#longDistance');\n\n let monthlyExpense = 0;\n monthlyExpense += perPhone ? plansCount * monthlyPayment : monthlyPayment\n monthlyExpense += perPhoneLongDistance ? plansCount * longDistance : longDistance\n\n $( '#monthlyExpense' ).text(`$ ${addCommas(monthlyExpense)}`);\n $( '#yearlyExpense' ).text(`$ ${addCommas(12 * monthlyExpense)}`);\n\n const nineYearExpense = 9 * 12 * monthlyExpense;\n $( '#nineYearExpense' ).text(`$ ${addCommas(nineYearExpense)}`);\n\n let newNineYearExpense\n if ($('#viewDetailsButtonBottom').css('display') === 'none') {\n newNineYearExpense = plansCount * 500;\n $( '#newNineYearExpense' ).text(`$ ${addCommas(newNineYearExpense)}`);\n\n \n } else {\n newNineYearExpense = $('#newNineYearExpense').text().replace(/(\\s|\\$|,)/g, '');\n newNineYearExpense = parseFloat(newNineYearExpense);\n\n }\n\n const nineYearSaving = nineYearExpense - newNineYearExpense;\n $( '#nineYearSaving' ).text(`$ ${addCommas(nineYearSaving)}`);\n\n $( '#yearlySaving' ).text(`$ ${addCommas(nineYearSaving / 9)}`);\n}", "function woodCalculator(value1, value2, value3) {\n var result1 = value1 * 1;\n var result2 = value2 * 3;\n var result3 = value3 * 5;\n var totalResult = result1 + result2 + result3;\n return totalResult;\n}", "function calculate_results() {\n let e_val = 20 + r[0] - r[5] + r[10] - r[15] + r[20] - r[25] + r[30] - r[35] + r[40] - r[45];\n let a_val = 14 - r[1] + r[6] - r[11] + r[16] - r[21] + r[26] - r[31] + r[36] + r[41] + r[46];\n let c_val = 14 + r[2] - r[7] + r[12] - r[17] + r[22] - r[27] + r[32] - r[37] + r[42] + r[47];\n let n_val = 38 - r[3] + r[8] - r[13] + r[18] - r[23] - r[28] - r[33] - r[38] - r[43] - r[48];\n let o_val = 8 + r[4] - r[9] + r[14] - r[19] + r[24] - r[29] + r[34] + r[39] + r[44] + r[49];\n\n o_val = Math.round((o_val/40)*100);\n c_val = Math.round((c_val/40)*100);\n e_val = Math.round((e_val/40)*100);\n a_val = Math.round((a_val/40)*100);\n n_val = Math.round((n_val/40)*100);\n\n console.log(e_val + \" \" + a_val + \" \" + c_val + \" \" + n_val + \" \" + o_val);\n\n save_results(e_val, a_val, c_val, n_val, o_val);\n}", "function getQbig(needChair, needTable, needKhat) {\r\n// Qbig Fixed Hisab\r\nchair = 1;\r\ntable = 3;\r\nkhat = 5;\r\n\r\n needTotal = (needChair * chair + needTable * table + needKhat * khat);\r\n console.log(\"Need total qbig feet wood = \"+needTotal);\r\n\r\n}", "doCalculation() {\n const { questAPI, idAPI, timer } = this.props;\n const { difficulty } = questAPI[idAPI];\n const staticPoint = 10;\n let points = 1;\n const TRES = 3;\n switch (difficulty) {\n case \"hard\":\n points = TRES;\n break;\n case \"medium\":\n points = 2;\n break;\n default:\n points = 1;\n }\n return staticPoint + points * timer;\n }", "function calculateResult() {\r\n var PRACTICALITY_RATIO = 0.7; \r\n var MARKET_RATIO = 0.3; \r\n practicalityScore = $('#results_practicality_hidden').val();\r\n marketScore = $('#results_market_hidden').val();\r\n var effectScore = (practicalityScore * PRACTICALITY_RATIO) +\r\n (marketScore * MARKET_RATIO);\r\n // we round the result to the second decimal place \r\n return effectScore;\r\n}", "function calcul(randq)\n{\n\t\n randq = randq.trim(); \n temp=randq.split(\"(\");\n temp1=temp[1].split(\")\");\n chars=temp1[0].split(\"\");\n //here we are taking out number and operator in 2 diffrent arrent number in array n and operator in array op\n var n = [], op = [], index = 0, oplast = true;\n \n for(c=0;c<chars.length;c++)\n {\n if (isNaN(parseInt(chars[c])))\n {\n op[index] = chars[c];\n index++;\n n[index] = \"\";\n oplast = true;\n }\n else\n { if(n[index])\n n[index] += chars[c];\n else\n n[index]= chars[c];\n oplast = false;\n }\n \n }\n //alert(randq);\n //here we are removing the blank entry from number array.\n var n = n.filter(function(v){return v!==''});\n //alert(n);\n // As some case we will get only one operator that case in op array first position adding oeration plus operator.\n if(op.length==1)\n {\n\t op.unshift(\"+\");\n }\n //alert(op);\nres=0;\n // res = op[0] + parseInt(n[0]) + op[1] + parseInt(n[1]);\n\t //here we are calculating the number value\n\t for(i=0;i<op.length;i++)\n\t {\t\t \n\t\t if(op[i].trim()==\"+\")\n\t\t res=res + parseInt(n[i]);\n\t\t else\n\t\t res=res - parseInt(n[i]);\n\t }\n\t \n//here calculating final result value and doing round of to dicimal 2 digit.\t \nif(temp[0].trim()=='sin')\n {\t \n\t ans=Math.round(Math.sin(Math.radians(res))*100)/100;\n\t }\nif(temp[0].trim()=='cos')\n {\n\t ans=Math.round(Math.cos(Math.radians(res))*100)/100;\n }\n //alert(res);\n //alert(ans);\n return ans;\n}", "function showAnswer(){\n equalsToIsClicked=true;\n numberIsClicked=true;\n numberOfOperand=1;\n if(numberIsClicked && operatorIsClicked && numberOfOperand===1 && equalsToIsClicked===true){\n switch(myoperator){\n case \"*\":\n num1*=(Number($values.innerText));\n $values.innerText=num1;\n if($values.innerText.length>8){\n $values.innerText=num1.toPrecision(3);\n throw \"the number of digits exceeded\";\n \n }\n break;\n case \"+\":\n num1+=(Number($values.innerText));\n $values.innerText=num1;\n if($values.innerText.length>8){\n $values.innerText=num1.toPrecision(3);\n throw \"the number of digits exceeded\";\n }\n break;\n case \"-\":\n num1-=(Number($values.innerText));\n $values.innerText=num1;\n if($values.innerText.length>8){\n $values.innerText=num1.toPrecision(2);\n throw \"the number of digits exceeded\";\n }\n break;\n case \"/\":\n num1/=(Number($values.innerText));\n $values.innerText=num1;\n if($values.innerText.length>8){\n $values.innerText=num1.toPrecision(3);\n throw \"the number of digits exceeded\";\n }\n break;\n\n }\n }\n numberIsClicked=false;\n operatorIsClicked=false;\n equalsToIsClicked=false;\n numberOfOperand=0;\n numberChecker=0;\n\n}", "function calculate(){\r\n var output = document.getElementById(\"ans\").value;\r\n var sol = eval(output);\r\n document.getElementById(\"ans\").value = sol;\r\n}", "function evaluateAnswer(){\n\tvar y = parseInt(second.innerHTML);\n\tvar x = parseInt(first.innerHTML);\n\tvar i = operator.innerHTML;\n\t// checks the operator passed\n\tswitch(i){\n\t\tcase '+':\n\t\t\tcompute = x + y;\n\t\t\tbreak;\n\t\tcase '-': \n\t\t\tcompute = x - y;\n\t\t\tbreak;\n\t\tcase '*':\n\t\t\tcompute = x * y;\n\t\t\tbreak;\n\t\tcase '/': \n\t\t\tcompute = x / y;\n\t\t\tbreak;\n\t}\n\n\tif (compute === parseFloat(document.getElementById('result').value)){\n\t\tdocument.getElementById('right').innerHTML = ++right;\n\t\tdisplayMessage('Congrats, you have won the game');\n\t}\n\telse{\n\t\tdocument.getElementById('wrong').innerHTML = ++wrong;\n\t\tdisplayMessage('That is not correct, Please try next problem');\t\t\n\t}\n\tsetTimeout(init, 5000);\n }", "function calculateScore (answerArray, questionArray) {\n answerArray.forEach(function (question) {\n if (question.answer === undefined || question.answer === '') {\n score.noOfUnanswered += 1\n } else {\n questionArray.forEach(function (answer) {\n if (answer.id === question.id) {\n if (answer.answer === question.answer) {\n score.noOfCorrect += 1\n } else {\n score.noOfIncorrect += 1\n }\n }\n })\n }\n })\n }", "function checkAnswer(answer, answerSelection) {\n //Write your code in here\n // if the \"veryPositive\" values in the possibleAnswers object include the string assigned to \"answer\" at the index specified by \"answerSelection\", then return \"very positive\"\n if (possibleAnswers.veryPositive.includes(answer, [answerSelection])) {\n return \"very positive\";\n }\n // if the \"positive\" values in the possibleAnswers object include the string assigned to \"answer\" at the index specified by \"answerSelection\", then return \"positive\"\n else if (possibleAnswers.positive.includes(answer, [answerSelection])) {\n return \"positive\";\n }\n // if the \"negative\" values in the possibleAnswers object include the string assigned to \"answer\" at the index specified by \"answerSelection\", then return \"negative\"\n else if (possibleAnswers.negative.includes(answer, [answerSelection])) {\n return \"negative\";\n }\n // if the \"veryNegative\" values in the possibleAnswers object include the string assigned to \"answer\" at the index specified by \"answerSelection\", then return \"very negative\"\n else if (possibleAnswers.veryNegative.includes(answer, [answerSelection])) {\n return \"very negative\";\n }\n}", "function createEquations() {\n // Randomly choose how many correct equations there should be\n // const correctEquations = \n // Set amount of wrong equations\n // const wrongEquations = \n // Loop through, multiply random numbers up to 9, push to array\n // for (let i = 0; i < correctEquations; i++) {\n // firstNumber = \n // secondNumber = \n // const equationValue = firstNumber * secondNumber;\n // const equation = `${firstNumber} x ${secondNumber} = ${equationValue}`;\n // equationObject = { value: equation, evaluated: 'true' };\n // equationsArray.push(equationObject);\n // }\n // Loop through, mess with the equation results, push to array\n // for (let i = 0; i < wrongEquations; i++) {\n // firstNumber = \n // secondNumber = \n // const equationValue = firstNumber * secondNumber;\n // wrongFormat[0] = `${firstNumber} x ${secondNumber + 1} = ${equationValue}`;\n // wrongFormat[1] = `${firstNumber} x ${secondNumber} = ${equationValue - 1}`;\n // wrongFormat[2] = `${firstNumber + 1} x ${secondNumber} = ${equationValue}`;\n // const formatChoice = \n // const equation = wrongFormat[formatChoice];\n // equationObject = { value: equation, evaluated: 'false' };\n // equationsArray.push(equationObject);\n // }\n}", "function calculateCorrectAnswer() {\n let operand1 = parseInt(document.getElementById('operand1').innerText);\n let operand2 = parseInt(document.getElementById('operand2').innerText);\n let operator = document.getElementById(\"operator\").innerText;\n\n if (operator === \"+\") {\n return [operand1 + operand2, \"addition\"];\n } else if (operator === \"x\") {\n return [operand1 * operand2, \"multiply\"];\n } else if (operator === \"-\") {\n return [operand1 - operand2, \"subtract\"];\n }\n else {\n alert(`Unimplemented operator ${operator}`);\n throw `Unimplemented operator ${operator}. Aborting!`;\n }\n\n}", "function solve(meal_cost, tip_percent=, tax_percent) {\n // Write your code here\n let total_cost;\n total_cost = meal_cost + meal_cost * tip_percent/100 + meal_cost * tax_percent/100;\n console.log(Math.round(total_cost)); \n }", "function calc (one, two, three){\n //start by declaring our new var. & whatever it is (calculation/value holder).\n let total = one + two + three;// base logic\n let average = Math.round(total/3);//clean base logic\n return average;\n}", "function getResult() {\n console.log(\"getResult ran\");\n wrong = total - correct;\n $(\"#end_total_right b\").text(correct);\n $(\"#end_total_wrong b\").text(wrong);\n var answer_percent = correct / total;\n if (answer_percent >= 0.67) {\n $(\"#end\").prepend(responses[0]);\n } else if (answer_percent >= 0.34) {\n $(\"#end\").prepend(responses[1]);\n } else {\n $(\"#end\").prepend(responses[2]);\n }\n }", "function basicCalc(){\n //prompt to chose what operator to use\n var operator = parseInt(prompt(\"please chose your operation \\n\" + \"1 - Addition (+)\\n\" +\" 2 - Subtraction (-)\\n\"+\" 3 - Mulitplication (*) Root\\n\"+\" 4 - Division (/)\\n\" ));\n // use our function with 2 prompts, and default messages for 2 values\n // save the returned value_array\n var value_array = prompt_for_values(2);\n //assign the returned value_array values from index 0 and 1 into the numbers to use\n number_1 = value_array[0];\n number_2 = value_array[1];\n // switch on the operator\n switch (operator) {\n //if operator is 1= +,\n case 1:\n // then preform the addition and return the value as an alert\n return alert(\"The addition of numbers: \" +number_1 + \" + \" + number_2+ \" = \" + (number_1+number_2));\n break;\n // if operator is 2 = -\n case 2:\n // then preform the addition and return the value as an alert\n return alert(\"The subtraction of numbers: \" +number_1 + \" - \" + number_2+ \" = \"+ (number_1-number_2));\n break;\n // if operator is 3 = *\n case 3:\n // then preform the addition and return the value as an alert\n return alert(\"The mulitplication of numbers: \" +number_1 + \" * \" + number_2 +\" = \"+ (number_1*number_2));\n break;\n // if operator is 4 = /\n case 4:\n // then preform the addition and return the value as an alert\n return alert(\"The division of numbers: -:\" +number_1 + \" / \" + number_2 +\" = \"+ (number_1/number_2));\n break;\n default:\n }\n}", "function results(){\n gameStart=false;\n correct=0;\n //checking if selected answer is correct\n var yes1=$(\"input#qb\").prop(\"checked\");\n var yes2=$(\"input#qf\").prop(\"checked\");\n var yes3=$(\"input#qg\").prop(\"checked\");\n //increase correct total with correct answer\n if(yes1===true){\n correct++;\n }\n if(yes2===true){\n correct++;\n }\n if(yes3===true){\n correct++;\n }\n if (correct===3){\n $(\"#timeRemain\").html(\"<h1>Right. Off you go.</h1>\");\n }\n else{\n $(\"#timeRemain\").html(\"<h1>Auuuuuuuugh!</h1>\"+\"YOU ONlY GOT \"+correct+\" CORRECT!\");\n }\n correct=0;\n clearTimeout(timerEnd);\n clearInterval(timerCount);\n $(\"#start\").prop(\"disabled\",false);\n }", "function score_indicate (){\r\n //\r\n Substitute the array of [national score, English score, math score, science score, social score] into the variable \"subject_points\"\r\n let subject_points = [Number ( $ ( ' #national_language ' ).val()),\r\n Number( $ ( ' #english ' ).val()),\r\n Number( $ ( ' #mathematics ' ).val()),\r\n Number( $ ( ' #science ' ).val()),\r\n Number( $ ( ' #society ' ).val())\r\n ]; // in the variable \"sum\" // [National score, English score, math [Score, Science score, Social score] respectively. // Hint! Take out the arrays one by one and add them.\r\n let sum = subject_points[ 0 ];\r\n sum = sum + subject_points[ 1 ];\r\n sum = sum + subject_points[ 2 ];\r\n sum = sum + subject_points[ 3 ];\r\n sum = sum + subject_points[ 4 ];\r\n\r\n\r\n\r\n // Output the variable \"sum\" (total points) to \"Total points:\" (class=\"sum_indicate\").\r\n $ ( \" #sum_indicate \" ).text(sum);\r\n let average = sum / subject_points.length;\r\n $ (\"#average_indicate\").text(average);\r\n //\r\n Assign the average value to the\r\n variable \"average\" . (Total number of points you want to average (sum) / total number) // Hint! Use the length method to find the total number. (length method: a method to get the length of the string and the number of elements in the array)\r\n }", "function exam(a)\n{\n\n//Assign fexm the final result from the math equation\nlet fexam = (60/100)*a\n\n//return value for fexam\nreturn fexam\n\n}", "function scoreKeep(){\n var userAnswer1 = $(\"input[name='answer1']:checked\").val();\n var userAnswer2 = $(\"input[name='answer2']:checked\").val();\n var userAnswer3 = $(\"input[name='answer3']:checked\").val();\n var userAnswer4 = $(\"input[name='answer4']:checked\").val();\n var userAnswer5 = $(\"input[name='answer5']:checked\").val();\n var userAnswer6 = $(\"input[name='answer6']:checked\").val();\n var userAnswer7 = $(\"input[name='answer7']:checked\").val();\n\n //now keep score for all questions and answers\n if (userAnswer1 === undefined) {\n\n unanswered++;\n } else if (userAnswer1 == questions[0].answer) {\n\n correctAnswers++;\n } else {\n\n incorrectAnswers++;\n }\n if(userAnswer2 === undefined) {\n unanswered++;\n } else if (userAnswer2 == questions[1].answer){\n correctAnswers++;\n } else {\n incorrectAnswers++;\n }\n if(userAnswer3 === undefined) {\n unanswered++;\n } else if (userAnswer3 == questions[2].answer){\n correctAnswers++;\n } else {\n incorrectAnswers++;\n }\n if(userAnswer4 === undefined) {\n unanswered++;\n } else if (userAnswer4 == questions[3].answer){\n correctAnswers++;\n } else {\n incorrectAnswers++;\n }\n if(userAnswer5 === undefined) {\n unanswered++;\n } else if (userAnswer5 == questions[4].answer){\n correctAnswers++;\n } else {\n incorrectAnswers++;\n }\n if(userAnswer6 === undefined) {\n unanswered++;\n } else if (userAnswer6 == questions[5].answer){\n correctAnswers++;\n } else {\n incorrectAnswers++;\n }\n if(userAnswer7 === undefined) {\n unanswered++;\n } else if (userAnswer7 == questions[6].answer){\n correctAnswers++;\n } else {\n incorrectAnswers++;\n }\n}", "function showAnswers(){\t\n\t\tvar rightAnswers = 0;\n\t\tvar wrongAnswers = 0;\n\t\tvar userInput1 = $('#a1 input:checked').val();\n\t\tvar userInput2 = $('#a2 input:checked').val();\n\t\tvar userInput3 = $('#a3 input:checked').val();\n\t\tvar userInput4 = $('#a4 input:checked').val();\n\t\tvar userInput5 = $('#a5 input:checked').val();\n\t\tif (userInput1 === 'quail'){\n\t\t\trightAnswers++;\n\t\t}\n\t\telse {\n\t\t\twrongAnswers++;\n\t\t}\n\t\tif (userInput2 === 'frog') {\n\t\t\trightAnswers++;\n\t\t}\n\t\telse {\n\t\t\twrongAnswers++;\n\t\t}\n\t\tif (userInput3 === 'bear') {\n\t\t\trightAnswers++;\n\t\t}\n\t\telse {\n\t\t\twrongAnswers++;\n\t\t}\n\t\tif (userInput4 === 'avacado') {\n\t\t\trightAnswers++;\n\t\t}\n\t\telse {\n\t\t\twrongAnswers++;\n\t\t}\n\t\tif (userInput5 === 'artichoke') {\n\t\t\trightAnswers++;\n\t\t}\n\t\telse {\n\t\t\twrongAnswers++;\n\t\t}\n\t\tconsole.log('Input1:' + userInput1);\n\t\tconsole.log('Input2: ' + userInput2);\n\t\tconsole.log('Input3: ' + userInput3);\n\t\tconsole.log('Input4: ' + userInput4);\n\t\tconsole.log('Input5: ' + userInput5);\n\t\tconsole.log('Right Answers: ' + rightAnswers);\n\t\tconsole.log('Wrong Answers: ' + wrongAnswers);\n\t\t$('#time').remove();\n\t\t$('#submitButton').remove();\n\t\t$('#formQuestions').remove();\n\t\t$('#questions').html('<div id=\"results\">Results</div>');\n\t\t$('#questions').html(\"<div>\" + 'Right Answers: ' + rightAnswers + \"</div>\");\n\t\t$('#questions').append(\"<div>\" + 'Wrong or Empty Answers: ' + wrongAnswers + \"</div>\");\n\n\t}", "function submitAnswers() {\n var correctAnswer1 = document.getElementById(\"1a\");\n if (correctAnswer1.checked === true) {\n correct++;\n console.log(\"Correct: \" + correct);\n } else {\n incorrect++;\n console.log(\"Incorrect: \" + incorrect);\n }\n\n\n var correctAnswer2 = document.getElementById(\"2c\");\n if (correctAnswer2.checked === true) {\n correct++;\n console.log(\"Correct: \" + correct);\n } else {\n incorrect++;\n console.log(\"Incorrect: \" + incorrect);\n }\n\n\n var correctAnswer3 = document.getElementById(\"3d\");\n if (correctAnswer3.checked === true) {\n correct++;\n console.log(\"Correct: \" + correct);\n } else {\n incorrect++;\n console.log(\"Incorrect: \" + incorrect);\n }\n\n\n var correctAnswer4 = document.getElementById(\"4c\");\n if (correctAnswer4.checked === true) {\n correct++;\n console.log(\"Correct: \" + correct);\n } else {\n incorrect++;\n console.log(\"Incorrect: \" + incorrect);\n }\n\n\n var correctAnswer5 = document.getElementById(\"5b\");\n if (correctAnswer5.checked === true) {\n correct++;\n console.log(\"Correct: \" + correct);\n } else {\n incorrect++;\n console.log(\"Incorrect: \" + incorrect);\n }\n\n\n var correctAnswer6 = document.getElementById(\"6d\");\n if (correctAnswer6.checked === true) {\n correct++;\n console.log(\"Correct: \" + correct);\n } else {\n incorrect++;\n console.log(\"Incorrect: \" + incorrect);\n }\n\n\n var correctAnswer7 = document.getElementById(\"7b\");\n if (correctAnswer7.checked === true) {\n correct++;\n console.log(\"Correct: \" + correct);\n } else {\n incorrect++;\n console.log(\"Incorrect: \" + incorrect);\n }\n\n var correctAnswer8 = document.getElementById(\"8c\");\n if (correctAnswer8.checked === true) {\n correct++;\n console.log(\"Correct: \" + correct);\n } else {\n incorrect++;\n console.log(\"Incorrect: \" + incorrect);\n }\n\n var correctAnswer9 = document.getElementById(\"9d\");\n if (correctAnswer9.checked === true) {\n correct++;\n console.log(\"Correct: \" + correct);\n } else {\n incorrect++;\n console.log(\"Incorrect: \" + incorrect);\n }\n\n var correctAnswer10 = document.getElementById(\"10d\");\n if (correctAnswer10.checked === true) {\n correct++;\n console.log(\"Correct: \" + correct);\n } else {\n incorrect++;\n console.log(\"Incorrect: \" + incorrect);\n }\n\n var correctAnswer11 = document.getElementById(\"11c\");\n if (correctAnswer11.checked === true) {\n correct++;\n console.log(\"Correct: \" + correct);\n } else {\n incorrect++;\n console.log(\"Incorrect: \" + incorrect);\n }\n\n //alert(\"Correct: \" + correct);\n //alert(\"Incorrect: \" + incorrect);\n //window.location.href = 'results.html';\n\n //Displays results\n $(\"#main-body\").html(\"<h3>\" + \"Correct: \" + correct + \"</h3>\" +\n \"<h3>\" + \"Incorrect: \" + incorrect + \"</h3>\" +\n \"<h3>\" + \"Percentage Correct: \" + Math.floor(correct / (correct + incorrect) * 100) + \"%\" + \"</h3>\");\n $(\"#main-body\").append(\"<br>\" + '<a id=\"start-over\" href=\"index.html\">Start Over</a>')\n\n }", "function keepingScore() {\n\n var userAnswer1 = $(\"input[name='answer1']:checked\").val();\n var userAnswer2 = $(\"input[name='answer2']:checked\").val();\n var userAnswer3 = $(\"input[name='answer3']:checked\").val();\n var userAnswer4 = $(\"input[name='answer4']:checked\").val();\n var userAnswer5 = $(\"input[name='answer5']:checked\").val();\n var userAnswer6 = $(\"input[name='answer6']:checked\").val();\n var userAnswer7 = $(\"input[name='answer7']:checked\").val();\n var userAnswer8 = $(\"input[name='answer8']:checked\").val();\n var userAnswer9 = $(\"input[name='answer9']:checked\").val();\n var userAnswer10 = $(\"input[name='answer10']:checked\").val();\n \n \n // Question 1\n if (userAnswer1 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer1 == questions[0].answer) {\n\n correctAnswers++;\n }\n else {\n\n incorrectAnswers++;\n }\n\n // Question 2\n if (userAnswer2 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer2 == questions[1].answer) {\n\n correctAnswers++;\n }\n else {\n\n incorrectAnswers++;\n }\n\n // Question 3\n if (userAnswer3 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer3 == questions[2].answer) {\n\n correctAnswers++;\n }\n else {\n\n incorrectAnswers++;\n }\n\n // Question 4\n if (userAnswer4 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer4 == questions[3].answer) {\n\n correctAnswers++;\n }\n else {\n\n incorrectAnswers++;\n }\n\n // Question 5\n if (userAnswer5 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer5 == questions[4].answer) {\n\n correctAnswers++;\n }\n else {\n\n incorrectAnswers++;\n }\n\n // Question 6\n if (userAnswer6 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer6 == questions[5].answer) {\n\n correctAnswers++;\n }\n else {\n\n incorrectAnswers++;\n }\n\n // Question 7\n if (userAnswer7 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer7 == questions[6].answer) {\n\n correctAnswers++;\n }\n else {\n\n incorrectAnswers++;\n }\n\n // Question 8\n if (userAnswer8 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer8 == questions[7].answer) {\n\n correctAnswers++;\n }\n else {\n\n incorrectAnswers++;\n }\n\n // Question 9\n if (userAnswer9 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer9 == questions[8].answer) {\n\n correctAnswers++;\n }\n else {\n\n incorrectAnswers++;\n }\n\n // Question 10\n if (userAnswer10 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer10 == questions[9].answer) {\n\n correctAnswers++;\n }\n else {\n\n incorrectAnswers++;\n }\n\n \n}", "function calculate() {\n var operand1 = '';\n var operator = '';\n var operand2 = '';\n\n //calls the function special_cases to condition the equation variable to correct format\n special_cases();\n\n if (divid_by_zero) {\n return;\n }\n\n //checks to see if the equation array has a need to be calculated. If not it just\n //returns the equation array as the answer\n if (equation_array.length == 1) {\n answer = equation_array[0];\n }\n\n var done = false;\n while (!done) {\n\n\n done = order_of_operations(equation_array);\n operand1 = equation_array[ordered_index - 1];\n operator = equation_array[ordered_index];\n operand2 = equation_array[ordered_index + 1];\n console.log(\"calculated equation_array:\", equation_array)\n console.log(\"ordered_index:\", ordered_index)\n switch (operator) {\n case \"+\":\n answer = parseFloat(operand1) + parseFloat(operand2);\n break;\n case \"-\":\n answer = parseFloat(operand1) - parseFloat(operand2);\n break;\n case \"x\":\n answer = parseFloat(operand1) * parseFloat(operand2);\n break;\n case \"/\":\n answer = parseFloat(operand1) / parseFloat(operand2);\n break;\n case \"^\":\n answer = Math.pow(parseFloat(operand1), parseFloat(operand2));\n break;\n case \"%\":\n answer = parseFloat(operand1) / parseFloat(operand2);\n break;\n }\n equation_array.splice(ordered_index - 1, 3, answer);\n }\n\n}", "function getPazymiuVidurkis2(x1,x2,x3,x4,x5){\n var atsakymas=(x1 + x2 + x3 + x4 + x5)/5;\n return atsakymas;\n}", "function solve(args){\n\tvar elements = args,\n\tnum = elements.length,\n\tlugageFuel,\n\tbaseFuel = [],\n\tsnowyFuel, fuel, luggage;\n\n\tfor(var i = 0; i < num; i+= 1){\n\t\telements[i] = elements[i].split(' ');\n\t}\n\n\tfor(var j = 0; j < num; j+= 1){\n\t\tluggage = parseFloat(elements[j][3]);\n//100 km\nlugageFuel = luggage*0.01;\nfuel = 10 + lugageFuel;\n\nfuel = lugageFuel + 10;\nsnowyFuel = 0.3*fuel;\n\nif(elements[j][2] === '1'){\n\n\tbaseFuel[j] = 110*fuel/100;\n\t\n\n\tsnowyFuel = snowyFuel*10/100;\n\tbaseFuel[j] += snowyFuel;\n\n\n}\nelse if(elements[j][2] === '2'){\n\n\tbaseFuel[j] = 95*fuel/100;\n\t\n\tsnowyFuel = snowyFuel*30/100;\n\tbaseFuel[j] += snowyFuel;\n\n\n\n}\n\nif(elements[j][1]==='gas'){\n\tbaseFuel[j] = baseFuel[j]*1.2;\n}\nelse if(elements[j][1] === 'diesel'){\n\tbaseFuel[j] = baseFuel[j]*0.8;\n}\n\n\nbaseFuel[j] = Math.round(baseFuel[j]);\nconsole.log(elements[j][0] + ' ' + elements[j][1] + ' '+elements[j][2] + ' '+baseFuel[j])\n\n}\n\n\t\n}", "function CalculateResults()\r\n {\r\n var inputsAllValid;\r\n\r\n // Fetch all input values from the on-screen form.\r\n\r\n inputsAllValid = FetchInputValues();\r\n\r\n // If the fetched input values are all valid...\r\n\r\n if (inputsAllValid)\r\n {\r\n // Do the natural gas pressure loss calculation.\r\n\r\n DoCalculation();\r\n\r\n // Display the results of the calculation.\r\n\r\n DisplayResults();\r\n }\r\n }", "function Calculate() {\n var a, b, h, myResult;\n\n a = document.getElementById('a').value;\n b = document.getElementById('b').value;\n h = document.getElementById('h').value;\n myResult = ((+a + +b) / 2) * +h ;\n\n document.getElementById('out').innerHTML = myResult;\n}", "function calculate() {\n\tgetTempBonuses();\n\tgetNumberBoonsValues();\n\tgetRelicBonuses();\n\tgetFatebondBonuses();\n\tgetCoreTraitsValues();\n\tgetAttributesValues();\n\tgetSkillsValues();\n\tgetVirtuesValues();\n\tgetBoonsDiceValues();\n\tgetPresetRolls();\n\tgetAttackBonuses();\n}", "function getObjectiveFucntion(noOfDecisionVariables, ourPosition){\n if(noOfDecisionVariables > 0){\n inquirer.prompt([\n {\n type: \"input\",\n name: \"decisionCoefficient\",\n message: \"Input the coefficient of decision variable \" + ourPosition + \" \",\n validate: function(input){\n input = parseFloat(input)\n if(!isNaN(input)){\n return true;\n }else{\n return \"Enter a valid number please\"\n }\n }\n }\n ])\n .then( answer => {\n num =parseFloat(answer.decisionCoefficient)\n objFunc.push(num);\n noOfDecisionVariables--;\n ourPosition++;\n getObjectiveFucntion(noOfDecisionVariables, ourPosition);\n })\n }else{\n objFunc.push(0);\n getNumberOfConstrainsts()\n noOfDecVar = objFunc.length;\n }\n}", "function keepingScore() {\n\n var userAnswer1 = $(\"input[name='answer1']:checked\").val();\n var userAnswer2 = $(\"input[name='answer2']:checked\").val();\n var userAnswer3 = $(\"input[name='answer3']:checked\").val();\n var userAnswer4 = $(\"input[name='answer4']:checked\").val();\n var userAnswer5 = $(\"input[name='answer5']:checked\").val();\n var userAnswer6 = $(\"input[name='answer6']:checked\").val();\n var userAnswer7 = $(\"input[name='answer7']:checked\").val();\n\n // Q1\n if (userAnswer1 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer1 == questions[0].answer) {\n\n correctAnswers++;\n }\n else {\n\n wrongAnswers++;\n }\n\n // Q2\n if (userAnswer2 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer2 == questions[1].answer) {\n\n correctAnswers++;\n }\n else {\n\n wrongAnswers++;\n }\n\n // Q3\n if (userAnswer3 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer3 == questions[2].answer) {\n\n correctAnswers++;\n }\n else {\n\n wrongAnswers++;\n }\n\n // Q4\n if (userAnswer4 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer4 == questions[3].answer) {\n\n correctAnswers++;\n }\n else {\n\n wrongAnswers++;\n }\n\n // Q5\n if (userAnswer5 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer5 == questions[4].answer) {\n\n correctAnswers++;\n }\n else {\n\n wrongAnswers++;\n }\n\n // Q6\n if (userAnswer6 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer6 == questions[5].answer) {\n\n correctAnswers++;\n }\n else {\n\n wrongAnswers++;\n }\n\n // Q7\n if (userAnswer7 === undefined) {\n\n unanswered++;\n }\n else if (userAnswer7 == questions[6].answer) {\n\n correctAnswers++;\n }\n else {\n\n wrongAnswers++;\n } \n\n}", "function advancedCalc() {\n var type = parseInt(prompt(\"please chose \\n\" + \"1 - Power\\n\" +\" 2- Square Root\\n\" ));\n if (type==1) {\n // call for 2 prompts\n var value_array = prompt_for_values(2);\n number_1 = value_array[0];\n number_2 = value_array[1];\n return alert(Math.pow(number_1, number_2));\n }else if (type==2) {\n //call for single prompt and return value used in the sqrt.\n return alert(Math.sqrt(prompt_for_values(1)));\n }\n}", "function calculates(a, b, c, d) {\n var rez;\n rez = (a + b + c + d) / 4;\n return rez;\n}", "function calculate(){}", "function Check(){\n\n var answers=[];\n\n var q1=document.getElementsByName(\"ques1\");\n var q1Final;\n for(i=0;i<q1.length;i++){\n if(document.getElementsByName(\"ques1\")[i].checked){\n q1Final=document.getElementsByName(\"ques1\")[i].value;\n answers.push(q1Final);\n }\n }\n\n\n var q2=document.getElementsByName(\"ques2\");\n var q2Final;\n for(i=0;i<q2.length;i++){\n if(document.getElementsByName(\"ques2\")[i].checked){\n q2Final=document.getElementsByName(\"ques2\")[i].value;\n answers.push(q2Final);\n }\n }\n\n\n var q3=document.getElementsByName(\"ques3\");\n var q3Final;\n for(i=0;i<q3.length;i++){\n if(document.getElementsByName(\"ques3\")[i].checked){\n q3Final=document.getElementsByName(\"ques3\")[i].value;\n answers.push(q3Final);\n }\n }\n\n\n var trueAnswers =[\"B\",\"B\",\"C\"];\n var counter=0;\n for(i=0;i<answers.length;i++){\n if(trueAnswers[i]==answers[i]){\n counter++;\n }\n }\n\n document.getElementById(\"tes\").innerHTML=\"Your Result Is : \"+counter+\"/3\";\n\n}", "function f_out (){\n console.log(y1.checked);\n console.log(y2.checked);\n console.log(y3.checked);\n\n if (y1.checked){ n_a = 1;}\n if (y2.checked){ n_a = 2;}\n if (y3.checked){ n_a = 3;}\n console.log(n_a);\n \n if (n_a == n_right_answer){\n right_answers += 1;\n right_div.classList.remove(\"hidden\");\n wrong_div.classList.add(\"hidden\");\n console.log(\"n_question.value = \"+n_question.value);\n console.log(\"n_answer = \"+n_answer);\n if (n_question.value == n_answer){\n btn2.classList.add(\"hidden\");\n let el1 = document.createElement(\"p\");\n el1.innerHTML = \"<b>\"+right_answers+\"</b>\";\n right_div.appendChild(el1);\n }\n }\n else{\n right_answers-=1;\n right_div.classList.add(\"hidden\");\n wrong_div.classList.remove(\"hidden\");\n }\n}", "function checkAnswer() {\n let userAnswer = document.getElementsByName('ans');\n let cAns;\n for (i = 0; i < userAnswer.length; i++) {\n if (userAnswer[i].checked) {\n cAns = userAnswer[i].value;\n }\n }\n if (cAns == correct[qtrack]) {\n score++;\n wright.push(qtrack);\n }\n else wrong.push(qtrack);\n}", "function calculate() {\n if (operator == 1) {\n current_input = eval(memory) * eval(current_input);\n }\n if (operator == 2) {\n if (eval(current_input) == 0) {\n current_input = \"undefined\";\n }\n else {\n current_input = eval(memory) / eval(current_input);\n }\n }\n if (operator == 3) {\n current_input = eval(memory) + eval(current_input);\n }\n if (operator == 4) {\n current_input = eval(memory) - eval(current_input);\n }\n if (operator == 5 && current_input < 0) {\n var power_of = -1 * eval(current_input);\n var base = eval(memory);\n var final = 1;\n for (i = 0; i < power_of; i++) {\n final = final * base;\n console.log(base + \"^\" + (i + 1) + \" = \" + final);\n }\n current_input = 1 / final;\n }\n else if (operator == 5) {\n var power_of = eval(current_input);\n var base = eval(memory);\n var final = 1;\n for (i = 0; i < power_of; i++) {\n final = final * base;\n console.log(base + \"^\" + (i + 1) + \" = \" + final);\n }\n current_input = final;\n }\n operator = 0; //clear operator\n memory = \"0\"; //clear memory\n displayCurrentInput();\n}", "function check() {\n var question1 = document.quiz.question1.value;\n var question2 = document.quiz.question2.value;\n var question3 = document.quiz.question3.value;\n var question4 = document.quiz.question4.value;\n var question5 = document.quiz.question5.value;\n var question6 = document.quiz.question6.value;\n var question7 = document.quiz.question7.value;\n var question8 = document.quiz.question8.value;\n var question9 = document.quiz.question9.value;\n var question10 = document.quiz.question10.value;\n var question11 = document.quiz.question11.value;\n var question12 = document.quiz.question12.value;\n var question13 = document.quiz.question13.value;\n var question14 = document.quiz.question14.value;\n var question15 = document.quiz.question15.value;\n var question16 = document.quiz.question16.value;\n var question17 = document.quiz.question17.value;\n var question18 = document.quiz.question18.value;\n var question19 = document.quiz.question19.value;\n var question20 = document.quiz.question20.value;\n\n var correct = 0;\n var wrong = 0;\n var notAnswered = 0;\n\n // IF STATEMENTS ===================================================================================================\n // question 1\n if (question1 == \"Lane Cake\") {\n correct++;\n }\n else if ($(\"[name=question1]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 2\n if (question2 == \"Arkansas\") {\n correct++;\n }\n else if ($(\"[name=question2]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n //question 3\n if (question3 == \"Colorado\") {\n correct++;\n }\n else if ($(\"[name=question3]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n //question 4\n if (question4 == \"Pepsi\") {\n correct++;\n }\n else if ($(\"[name=question4]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 5\n if (question5 == \"Watermellon\") {\n correct++;\n }\n else if ($(\"[name=question5]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 6\n if (question6 == \"Philly Cheesesteak\") {\n correct++;\n }\n else if ($(\"[name=question6]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 7\n if (question7 == \"Dried Fruit\") {\n correct++;\n }\n else if ($(\"[name=question7]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 8\n if (question8 == \"Deep-dish Pizza\") {\n correct++;\n }\n else if ($(\"[name=question8]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 9\n if (question9 == \"Ice Cream\") {\n correct++;\n }\n else if ($(\"[name=question9]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 10\n if (question10 == \"November 3\") {\n correct++;\n }\n else if ($(\"[name=question10]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 11\n if (question11 == \"Bread\") {\n correct++;\n }\n else if ($(\"[name=question11]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 12\n if (question12 == \"Fried Chicken\") {\n correct++;\n }\n else if ($(\"[name=question12]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 13\n if (question13 == \"Georgia\") {\n correct++;\n }\n else if ($(\"[name=question13]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 14\n if (question14 == \"Turkey\") {\n correct++;\n }\n else if ($(\"[name=question14]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 15\n if (question15 == \"Key Lime Pie\") {\n correct++;\n }\n else if ($(\"[name=question15]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 16\n if (question16 == \"Ketchup\") {\n correct++;\n }\n else if ($(\"[name=question16]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 17\n if (question17 == \"Ginger Ale\") {\n correct++;\n }\n else if ($(\"[name=question17]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 18\n if (question18 == \"Chocolate Milk\") {\n correct++;\n }\n else if ($(\"[name=question18]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 19\n if (question19 == \"Smores\") {\n correct++;\n }\n else if ($(\"[name=question19]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // question 20\n if (question20 == \"Cherries\") {\n correct++;\n }\n else if ($(\"[name=question20]:checked\").length) {\n wrong++\n }\n else {\n notAnswered++;\n }\n\n // $(\"#results:visible\");\n document.getElementById(\"results\").style.visibility = \"visible\";\n $(\"#numCorrect\").html(\"Correct Answers: \" + correct);\n // document.getElementById(\"numCorrect\").innerHTML = \"Correct Answers: \" + correct;\n $(\"#numWrong\").html(\"Incorrect Answers: \" + wrong);\n // document.getElementById(\"numWrong\").innerHTML = \"Incorrect Answers: \" + wrong;\n $(\"#notAnswered\").html(\"Unanswered: \" + notAnswered);\n // document.getElementById(\"notAnswered\").innerHTML = \"Unanswered: \" + notAnswered;\n $(\"#mainContainer\").remove();\n // document.getElementById(\"mainContainer\").style.display = \"none\";\n\n}" ]
[ "0.7732249", "0.66374815", "0.6455912", "0.6449502", "0.64194083", "0.63356066", "0.6290932", "0.6209945", "0.6203061", "0.6182897", "0.6172524", "0.6153146", "0.61409616", "0.61293274", "0.61242443", "0.6110876", "0.60848236", "0.6083805", "0.6064427", "0.60345024", "0.6029825", "0.6025689", "0.6024523", "0.60053205", "0.6004021", "0.60016364", "0.5996144", "0.59946066", "0.5988374", "0.5981565", "0.5969558", "0.5966675", "0.5961073", "0.5949743", "0.5943766", "0.5939086", "0.5931974", "0.59086865", "0.59035486", "0.58983546", "0.58976257", "0.5893927", "0.5887449", "0.58749115", "0.58740443", "0.5869709", "0.58672607", "0.5861632", "0.586073", "0.5858028", "0.58570695", "0.5848244", "0.5842853", "0.58300537", "0.58296406", "0.5829605", "0.5810245", "0.5806971", "0.57993525", "0.5782122", "0.5777796", "0.5776961", "0.5776324", "0.5772569", "0.5767963", "0.5765906", "0.57586193", "0.57584566", "0.57556087", "0.5754701", "0.5752619", "0.57517993", "0.57504094", "0.57464826", "0.5738436", "0.573159", "0.57315475", "0.573114", "0.57239604", "0.57238793", "0.57190937", "0.571189", "0.5709575", "0.5706315", "0.5701125", "0.5698765", "0.56978416", "0.5696276", "0.56914663", "0.56903964", "0.5689255", "0.5687681", "0.568653", "0.56821597", "0.5679242", "0.5678325", "0.5673527", "0.5672584", "0.5668384", "0.5663294", "0.5662663" ]
0.0
-1
function for calculating the needed cubic feet wood for given number of chair, table and bad. one chair needs 1 cubic feet wood, one table needs 3 cubic feet wood and one bed needs 5 cubic feet wood. the input order should be first chair, then table and in the end bed.
function woodCalculator(chair, table, bed) { //first condition to check if any valu is negative or not. If negative necessary warnings given if(chair<0 || table<0 || bed<0) { return "Physical entity can not be negative" } //take inputs and multiply it with cubic feet wood needed to make single one and add all three else { var chairWood = chair*1; var tableWood = table*3; var bedWood = bed*5; var totalWood = chairWood + tableWood + bedWood; } return totalWood; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function woodCalculator(chair, table, bed){\n\n var i, totalWood = 0;\n\n //for a chair 1 cubic feet needed.\n for(i = 1; i <= chair; i++){\n totalWood++;\n }\n\n //for a table 3 cubic feet needed.\n for(i = 1; i <= table; i++){\n totalWood = totalWood + 3;\n }\n\n //for a bed 5 cubic feet needed.\n for(i = 1; i <= bed; i++){\n totalWood = totalWood + 5;\n }\n\n return totalWood;\n}", "function woodCalculator(chair, table, bed) {\n const oneChair = 1;\n let totalChair = Math.abs(chair) * oneChair;\n const oneTable = 3;\n let totalTable = Math.abs(table) * oneTable;\n const oneBed = 5;\n let totalBed = Math.abs(bed) * oneBed;\n let totalVolume = totalChair + totalTable + totalBed;\n return totalVolume;\n}", "function woodCalculator (chair, table, bed) {\n if(chair < 0 || table < 0 || bed < 0) {\n return \"haha! you cannot make me fool... Give the correct input.\"\n }\n else {\n var totalNeededWood = (chair*1) + (table*3) + (bed*5);\n return \"You need \"+ totalNeededWood+ \" Cubic Fit of wood\";\n }\n\n}", "function woodCalculator(chair,table,bed){\n var chairCount=chair*28.3168;\n var tableCount=table*84.9505;\n var bedCount=bed*141.584;\n var totalWood=chairCount+tableCount+bedCount;\n return totalWood;\n}", "function woodCalculator(chair, tabile, bed) {\n let woodNeedFor1Chair = 1; // that is one cubic feet\n let woodNeedFor1Tabile = 3; // that is three cubic feet\n let woodNeedFor1bed = 5; // that is five cubic feet\n\n if (chair < 0) {\n console.log(\"you can not put negative number in chair. That's why we set a default value 0.\");\n chair = 0;\n }\n\n if (tabile < 0) {\n console.log(\"you can not put negative number in tabile. That's why we set a default value 0.\");\n tabile = 0;\n }\n\n if (bed < 0) {\n console.log(\"you can not put negative number in bed.That's why we set a default value 0.\");\n bed = 0;\n }\n\n totalWoodForChair = woodNeedFor1Chair * chair;\n\n totalWoodForTabile = woodNeedFor1Tabile * tabile;\n\n totalWoodForBed = woodNeedFor1bed * bed;\n\n return (totalWoodNeed = totalWoodForChair + totalWoodForTabile + totalWoodForBed);\n}", "function woodCalculator(numOfChair, numOfTable, numOfBed) {\n\tconst chair = numOfChair * 1;\n\tconst table = numOfTable * 3;\n\tconst bed = numOfBed * 5;\n\n\tlet totalWood = chair + table + bed;\n\n\treturn `🌳 Wood needed = ${totalWood} cubic feet`;\n}", "function woodCalculator(chair, table, bed) {\n var chairCount = chair * 1;\n var tableCount = table * 3;\n var bedCount = bed * 5;\n var totalWood = chairCount + tableCount + bedCount;\n return totalWood;\n}", "function woodCalculator(chair, table, bed){\n if(chair > 0 ){\n var chairCount = chair * 1;\n }\n else{\n \n var warning = \"warning : number of chair can not be negative\";\n return warning;\n }\n if(table > 0 ){\n var tableCount = table * 3;\n }\n else{\n \n var warning = \"warning : number of table can not be negative\";\n return warning;\n }\n if(bed > 0 ){\n var bedCount = bed *5;\n }\n else{\n \n var warning = \"warning : number of bed can not be negative\";\n return warning;\n }\n\n var totalWood = chairCount + tableCount + bedCount ;\n return totalWood;\n}", "function woodCalculator(chair,table,bed){\n\n var woodForChair= chair*1 ;\n var woodForTable = table*3;\n var woodForBed = bed*5;\n\n var totalWood = woodForChair+woodForTable+woodForBed;\n return totalWood;\n}", "function woodCalculator(chair, table, bed){\n\n var chairWood = chair * 1;\n var tableWood = table * 3;\n var bedWood = bed * 5;\n\n var totalWood = chairWood + tableWood + bedWood;\n return totalWood;\n }", "function woodCalculator(chair, table, bed){\n var countChair = chair * 1;\n var countTable = table * 3;\n var countBed = bed * 5; \n var totalWood = countChair + countTable + countBed; \n return totalWood;\n}", "function woodCalculator(chair, table, bed) {\n\n if(chair >= 0 && table >= 0 && bed >= 0) {\n chairWoodCount = chair * 1;\n tableWoodCount = table * 3;\n bedWoodCount = bed * 5;\n totalWoodCount = chairWoodCount + tableWoodCount + bedWoodCount;\n return totalWoodCount;\n }\n else {\n console.log(\"Error: Physical quantities can never be negative.\")\n }\n\n}", "function woodCalculator(chair, table, bed) {\n\t// If any of the inputs is negative or not numbers, then return the error message\n\tif (chair < 0 || table < 0 || bed < 0) {\n\t\treturn \"Inputs cannot be negative. Please recheck the inputs.\";\n\t} else if (\n\t\ttypeof chair != \"number\" ||\n\t\ttypeof table != \"number\" ||\n\t\ttypeof bed != \"number\"\n\t) {\n\t\treturn \"Inputs must be numbers.Please recheck the inputs\";\n\t} else {\n\t\tvar chairCount = chair * 1; // 1 chair = 1 wood;\n\t\tvar tableCount = table * 3; // 1 table = 3 wood\n\t\tvar bedCount = bed * 5; // 1 bed = 5 bed\n\t\tvar totalWood = chairCount + tableCount + bedCount; // calculates the total wood\n\t\treturn totalWood;\n\t}\n}", "function woodCalculator (chair, table, bed) {\n var chairWood = chair * 1;\n var tableWood = table * 3;\n var bedWood = bed * 5;\n var totalWood = chairWood + tableWood + bedWood;\n return totalWood;\n}", "function woodCalculator(chair, table, bed) {\n if ((chair < 0 || table < 0 || bed < 0)) {\n return \"Please enter a positive value.\";\n };\n var totalChair = chair * 1;\n var totalTable = table * 3;\n var totalBed = bed * 5;\n var totalElement = totalChair + totalTable + totalBed;\n return totalElement;\n}", "function getQbig(needChair, needTable, needKhat) {\r\n// Qbig Fixed Hisab\r\nchair = 1;\r\ntable = 3;\r\nkhat = 5;\r\n\r\n needTotal = (needChair * chair + needTable * table + needKhat * khat);\r\n console.log(\"Need total qbig feet wood = \"+needTotal);\r\n\r\n}", "function woodCalculator(chair,table,bed){\n\n var woodForChair = chair * 1;\n var woodForTable = table * 3;\n var woodForBed = bed * 5;\n var total = woodForChair + woodForTable + woodForBed;\n return total;\n}", "function woodCalculator(chair, table, bed) {\n if (chair < 0 || table < 0 || bed < 0) {\n const errorMsg =\n \"Invalid Furniture Value.Please double check your Furniture value and try again.Thank You\";\n return errorMsg;\n } else {\n let totalWood = chair * 1 + table * 3 + bed * 5;\n return totalWood;\n }\n}", "function woodCalculator (chair , table , bed) {\n\n var woodChair = chair * 1;\n\n var woodTable = table * 3;\n\n var woodBed = bed * 5;\n\n var totalWood = woodChair + woodTable + woodBed;\n \n return totalWood;\n\n}", "function woodCalculator(chair,table,bed){\n const invalidMassege = \"Please input valid number.\";\n const validOutput = `Total wood needed : ${chair*1 + table*3 + bed*5} cubic feet.`;\n //return the value\n return (chair < 0 || table < 0 || bed < 0) ? invalidMassege : validOutput;\n }", "function woodCalculator(chair,table,bed) {\n var chairTableBed = chair * table * bed;\n return chairTableBed;\n \n}", "function woodCalculator(chair,table,bed)\n{\n var chair_wood = chair*1;\n var table_wood = table*3;\n var bed_wood = bed*5;\n var total_wood = chair_wood + table_wood + bed_wood;\n return total_wood;\n}", "function woodCalculator(chairPcs, tablePcs, bedPcs){\n if(chairPcs >= 0 && tablePcs >=0 && bedPcs >=0){\n var woodQuantity = chairPcs*1 + tablePcs*3 + bedPcs*5;\n return \"Total wood required: \" + woodQuantity + \" \" + \"cft\";\n }\n else{\n return \"Negative value is not accepted\"\n }\n}", "function woodCalculator(chair, table, bed){\n var chairNumber = chair *1;\n var tableNumber = table * 3;\n var bedNumber = bed * 5;\n var totalWood = chairNumber + tableNumber + bedNumber;\n return totalWood;\n}", "function woodCalculator(chair, table, bed){\n\n let chairRawWood = chair*1;\n let tableRawWood = table*3;\n let bedRawWood = bed*5;\n\n let TotalWoood = chairRawWood + tableRawWood + bedRawWood;\n\n return TotalWoood;\n\n\n}", "function woodCalculator(chair, table, khat){\n var total = (chair*1) + (table*3) + (khat * 5);\n return total;\n\n}", "function woodCalculator(chair, table, bed) {\n\n var amountOfChair = chair * 1;\n var amountOfTable = table * 3;\n var amountOfBed = bed * 5;\n\n var totalWood = amountOfChair + amountOfTable + amountOfBed;\n\n\n return totalWood;\n}", "function woodCalculator(chair, table, bed){\n if(chair<0 || table<0 || bed<0){\n console.log(\"Negative value is not accepted! \")\n return \"Invalid\";\n }\n else if(chair >=0 && table>=0 && bed>=0){\n var amountOfWood = (chair*1 + table*3 + bed *5);\n return amountOfWood;\n }\n}", "function woodCalculator(chair, table, bed){\n var woodChair = chair *1;\n var woodTable = table * 3;\n var woodBed = bed * 5;\n var woodTotal = woodChair + woodTable + woodBed;\n return woodTotal;\n\n}", "function woodCalculator(chair, table, bed){\n const woodForChair =chair * 1; //sft\n const woodForTable =table * 3; //sft\n const woodForBed =bed * 5; //sft\n const totalWood = woodForChair + woodForTable + woodForBed;\n let returnData =[woodForChair, woodForTable, woodForBed, totalWood];\n return returnData;\n}", "function woodCalculator (chair, table, bed){\n var numberOfChair = chair;\n var numberOfTable = table*3;\n var numberOfBed = bed*5;\n\n var result = numberOfChair + numberOfTable + numberOfBed;\n console.log(result,\"Cubic metre\");\n}", "function woodCalculator(chair,table,bed){\n if(chair < 0 || table < 0 || bed < 0){\n console.log(\"Amount can't be negative\");\n }\n else{\n var totalAmountOfWood = chair*1 + table*3 + bed*5;\n return totalAmountOfWood;\n }\n}", "function solve(args){\n\tvar elements = args,\n\tnum = elements.length,\n\tlugageFuel,\n\tbaseFuel = [],\n\tsnowyFuel, fuel, luggage;\n\n\tfor(var i = 0; i < num; i+= 1){\n\t\telements[i] = elements[i].split(' ');\n\t}\n\n\tfor(var j = 0; j < num; j+= 1){\n\t\tluggage = parseFloat(elements[j][3]);\n//100 km\nlugageFuel = luggage*0.01;\nfuel = 10 + lugageFuel;\n\nfuel = lugageFuel + 10;\nsnowyFuel = 0.3*fuel;\n\nif(elements[j][2] === '1'){\n\n\tbaseFuel[j] = 110*fuel/100;\n\t\n\n\tsnowyFuel = snowyFuel*10/100;\n\tbaseFuel[j] += snowyFuel;\n\n\n}\nelse if(elements[j][2] === '2'){\n\n\tbaseFuel[j] = 95*fuel/100;\n\t\n\tsnowyFuel = snowyFuel*30/100;\n\tbaseFuel[j] += snowyFuel;\n\n\n\n}\n\nif(elements[j][1]==='gas'){\n\tbaseFuel[j] = baseFuel[j]*1.2;\n}\nelse if(elements[j][1] === 'diesel'){\n\tbaseFuel[j] = baseFuel[j]*0.8;\n}\n\n\nbaseFuel[j] = Math.round(baseFuel[j]);\nconsole.log(elements[j][0] + ' ' + elements[j][1] + ' '+elements[j][2] + ' '+baseFuel[j])\n\n}\n\n\t\n}", "function findTemp() {\r\n // get combustible from dropdown menu\r\n oxidant_ratio = Number(document.getElementById(\"oxidantratio\").innerHTML);\r\n combustible = document.getElementById(\"combustible\").value;\r\n\r\n // get all data for combustible\r\n hc = heat_capacity[combustible];\r\n\r\n // gets chemical subscripts of combustible\r\n sub = subscripts[combustible];\r\n n = sub[0];\r\n m = sub[1];\r\n l = sub[2];\r\n\r\n // initial guess for combustible\r\n r0 = sub[3];\r\n\r\n // get N2/O2 ratio from user input (0-3.762)\r\n w = Number(document.getElementById(\"n2o2ratio\").innerHTML);\r\n\r\n u = oxidant_ratio + l/2;\r\n st = n + m/4;\r\n\r\n // y*CO2 + z*H2O + s*CnHmOl + t*O2 + w*N2\r\n var y = 0;\r\n var z = 0;\r\n var s = 0;\r\n var t = 0;\r\n\r\n if (u == st) {\r\n // stoichiometric\r\n y = n;\r\n z = m/2;\r\n } else if (u > st) {\r\n // excess oxidant\r\n y = n;\r\n z = m/2;\r\n t = u - st;\r\n } else {\r\n // lack of oxidant\r\n s = (4*(n-u)+m)/(4*n+m);\r\n z = 2*(u+n*(s-1));\r\n y = u - 0.5*z;\r\n }\r\n \r\n // calculate equivalence ratio\r\n let er = (u+0.5*l)/(n+0.25*m);\r\n /*er = Math.max(0.05, er); // no smaller than 0.05\r\n er = Math.min(2.5, er); // no larger than 2.5*/\r\n\r\n // coefficient placeholders in f(T)\r\n a = [0, 1, 2, 3, 4, 5];\r\n\r\n // -c\r\n a[0] = -(y*heat_capacity[\"CO2\"][2]+z*heat_capacity[\"H2O\"][2]+s*heat_capacity[combustible][2]+t*heat_capacity[\"O2\"][2]+w*heat_capacity[\"N2\"][2]);\r\n \r\n // a\r\n a[2] = y*heat_capacity[\"CO2\"][0]+z*heat_capacity[\"H2O\"][0]+s*heat_capacity[combustible][0]+t*heat_capacity[\"O2\"][0]+w*heat_capacity[\"N2\"][0];\r\n \r\n // 0.5*b\r\n a[3] = 0.5*(y*heat_capacity[\"CO2\"][1]+z*heat_capacity[\"H2O\"][1]+s*heat_capacity[combustible][1]+t*heat_capacity[\"O2\"][1]+w*heat_capacity[\"N2\"][1]);\r\n\r\n // 0.333333*d\r\n a[4] = (y*heat_capacity[\"CO2\"][3]+z*heat_capacity[\"H2O\"][3]+s*heat_capacity[combustible][3]+t*heat_capacity[\"O2\"][3]+w*heat_capacity[\"N2\"][3])/3;\r\n\r\n // 0.25*e\r\n a[5] = 0.25*(y*heat_capacity[\"CO2\"][4]+z*heat_capacity[\"H2O\"][4]+s*heat_capacity[combustible][4]+t*heat_capacity[\"O2\"][4]+w*heat_capacity[\"N2\"][4]);\r\n\r\n // A\r\n a[1] = (1-s)*enthalpy[combustible]-T0*(a[2]+T0*(a[3]+T0*(a[4]+T0*a[5])))-a[0]/T0;\r\n \r\n // improve guess by bracketing the root\r\n let Ti = sub[4];\r\n let p0 = Math.sign(ply_val(Ti, a));\r\n\r\n let T1 = Ti + 200;\r\n let p1 = Math.sign(ply_val(T1, a));\r\n\r\n let p = p0*p1;\r\n \r\n Ti = T1;\r\n p0 = p1;\r\n while(p > 0){\r\n T1 = Ti + 200;\r\n p1 = ply_val(T1, a);\r\n p = p0*p1;\r\n p0 = p1;\r\n Ti = T1;\r\n }\r\n \r\n Tf = newt_p5(a, Ti);\r\n\r\n Tf = Tf.toFixed(4);\r\n document.getElementById(\"temp_display\").innerHTML = Tf.toString() + \" K\";\r\n \r\n \r\n var newData = [];\r\n let dic = chart_lookup[combustible];\r\n if(!(w in dic)){\r\n dic[w] = chart.series.length;\r\n chart.addSeries({\r\n data:[[er, Number(Tf)]],\r\n name: combustible + \"[ratio:\" + w + \"]\",\r\n lineWidth: 2,\r\n });\r\n } else {\r\n let inserted = false;\r\n let ind = dic[w];\r\n for(i = 0; i < chart.series[ind].data.length; i++){\r\n if(chart.series[ind].data[i].x > er && !inserted){\r\n inserted = true;\r\n newData.push([er, Number(Tf)]);\r\n }\r\n newData.push([chart.series[ind].data[i].x, chart.series[ind].data[i].y] );\r\n }\r\n if(!inserted){\r\n newData.push([er, Number(Tf)]);\r\n }\r\n\r\n chart.series[ind].update({\r\n data: newData\r\n }, true);\r\n }\r\n\r\n setColor(Tf);\r\n}", "function calcualteCavity(casting_length,casting_breadth,length,breadth)\r\n{\r\n var temp_casting_length=casting_length+30;\r\n var temp_casting_breadth=casting_breadth+30;\r\n row_count=0,column_count=0;\r\n temp_casting_length=parseInt(temp_casting_length);\r\n temp_casting_breadth=parseInt(temp_casting_breadth);\r\n if(length>temp_casting_length&&breadth>temp_casting_breadth)\r\n {\r\n while((length - 30) > temp_casting_length)\r\n {\r\n column_count++;\r\n temp_casting_length+=casting_length+30;\r\n }\r\n while((breadth - 30) > temp_casting_breadth)\r\n {\r\n row_count++;\r\n temp_casting_breadth += casting_breadth + 30;\r\n }\r\n }\r\n else if(length<temp_casting_length&&breadth>temp_casting_breadth)\r\n {\r\n length=parseInt(length)-30;\r\n breadth=parseInt(breadth)-30;\r\n length=Math.sqrt(parseFloat(length*length)+parseFloat(breadth*breadth));\r\n while((length - 30) > temp_casting_length)\r\n {\r\n column_count++;\r\n temp_casting_length+=casting_length+30;\r\n }\r\n /*while((breadth - 30) > temp_casting_breadth)\r\n {\r\n row_count++;\r\n temp_casting_breadth += casting_breadth + 30;\r\n }*/\r\n }\r\n else if(breadth<temp_casting_breadth&&length>temp_casting_length)\r\n {\r\n length=parseInt(length)-30;\r\n breadth=parseInt(breadth)-30;\r\n length=Math.sqrt(parseFloat(length*length)+parseFloat(breadth*breadth));\r\n while((breadth - 30) > temp_casting_breadth)\r\n {\r\n row_count++;\r\n temp_casting_breadth += casting_breadth + 30;\r\n }\r\n }\r\n if(row_count == 1 && column_count ==1)\r\n {\r\n return row_count;\r\n }\r\n //drawDiagram(casting_length,casting_breadth,avl_length,avl_breadth,dimension[0],dimension[1],row_count,column_count,(column_count*row_count));\r\n if(row_count == 0)\r\n {\r\n return column_count;\r\n }\r\n if(column_count == 0)\r\n {\r\n return row_count;\r\n }\r\n return column_count*row_count;\r\n}", "function Chests() {\n\tfor (i = 1; i < 9; i++) {\n\t\tif (i%2 != 0) {\n\t\t\tfor (j = 1; j < 17; j++) {\n\t\t\t\tcheck();\n\t\t\t}\n\t\t} else {\n\t\t\tfor (j = 0; j < 16; j++) {\n\t\t\t\tcheck();\n\t\t\t}\n\t\t}\n\t\tappendBr();\n\t}\n}", "function amountChairs(chair){ //chair is the parameters\n var amountChairs =chair*12; //the 12 is the square ft for each chair,\n return amountChairs; //this lets it get pushed into the other parts\n\n}", "function carrycheck(){\n // var troops = cotg.city.troops();\n var loot;\n var total;\n var total_number=0;\n var total_lootx=0;\n var i=0;\n for(var x in citytc) {\n total=Number(citytc[x]);\n total_number+=total*Number(TS_type[i]);\n total_lootx+=total*Number(ttloot[i]);\n i+=1;\n if (i === 17) { break; }\n }\n var lootpertroop=total_lootx/total_number;\n for (var i = 1; i < $(\"#commandtable tbody tr\").length; i++) {\n var trlist = $(\"#commandtable tbody tr:nth-child(\"+i+\")\");\n var lvlprog=$(trlist).find(\".commandinntabl tbody tr:nth-child(2) td:nth-child(1) span:nth-child(1)\").text();//td:nth-child(1) span:nth-child(1)\n var splitlp=lvlprog.split(\"(\");\n if (splitlp.length === 1) { continue; }\n var Dungeon_lvl=Number(splitlp[0].match(/\\d+/gi));\n var Dungeion_prog=Number(splitlp[1].match(/\\d+/gi));\n var dungeon=splitlp[0].substring(0,splitlp[0].indexOf(','));\n if(dungeon===\"Mountain Cavern\"){loot=mountain_loot;}\n else{loot=other_loot;}\n var total_loot_c= Math.ceil(loot[Number(Dungeon_lvl)-1] * ((1-Number(Dungeion_prog)/100)+1));\n var Unitno=$(trlist).find(\".commandinntabl tbody tr:nth-child(1) td:nth-child(2) span\").text();//td:nth-child(1) span:nth-child(1)\n var temp7=Unitno.match(/[\\d,]+/g);\n var Units_raiding=Number(temp7[0].replace(',', ''));\n var lootperraid=lootpertroop*Units_raiding;\n var percentage_ofloot=Math.ceil((lootperraid/total_loot_c)*100);\n $(trlist).find(\".toptdinncommtbl1.outgblink.shRAin\").text(\"Carry:\" + percentage_ofloot + \"%\");\n $(trlist).find(\".commandinntabl tbody tr:nth-child(4) td:nth-child(1)\").attr('colspan',1);\n\t\t}\n }", "function optimal_compos_golden(adr)//mam sklad 7, szukam czy ktos na lawce sie nadaje//szukanie lepszego perfo-nie roz problem\n{\n if(adr==1)\n {\n \ttea = team1;//z tempo odczyt, a do tempz zapisuje;\n }\n else \n {\n \ttea = team2;//z tempo odczyt, a do tempz zapisuje;\n }\n//console.log(changes);\n var all_lawka = [];\n var item1 = [];\n var item2 = [];\n var item3 = [];\n var item4 = [];\n for(var i=1;i<=6;i++)//mam gwaracje, że przejdzie przez każdego R na ławce, ale dalej zawsze wybierze najlepszego\n {\t\n tea[0]=Array(0,0,0,0,0,0,0,0,0,0,0,0);\n item1 = [];item2 = [];item3 = [];item4 = [];\n\t\t\tfor(var j=8;j<=12;j++)\n\t\t\t{\n\t\t\t //item = [];\n if(tea[j][4]==\"R\" && i == 1)// i = 1 - sprawdzam każdego z ławki konkretnie za R\n\t\t\t {\n\t\t\t \tif(tea[j][11] > (tea[i][11]+1))\n {\n nadwyzka = tea[j][11] - tea[i][11];nadwyzka = zaokr(nadwyzka); \n item1 = [j, i, nadwyzka];\n all_lawka.unshift(item1);// \n }\n\t\t\t }\n if(tea[j][4]==\"A\" && i == 4)// i = 4\t\n\t\t\t {\n\t\t\t \tif(tea[j][6] > (tea[i][6]+1))\n {\n nadwyzka = tea[j][6] - tea[i][6];nadwyzka = zaokr(nadwyzka);\n item2 = [j, i, nadwyzka];\n all_lawka.unshift(item2);// \n }\n\t\t\t }\n item3 =[];\n if(tea[j][4]==\"P\" && (i == 2 || i == 5))// i = 2; i =5;\n\t\t\t {\n\t\t\t \tif( (tea[j][6]+tea[j][7])/2 > ((tea[i][6]+tea[i][7])/2)+1)\n {\n nadwyzka = (tea[j][6]+tea[j][7])/2 - ((tea[i][6]+tea[i][7])/2);nadwyzka = zaokr(nadwyzka);\n item3=[];\n item3 = [j, i, nadwyzka];\n test = all_lawka.unshift(item3);//\n //alert(\"test-length: \"+test+\" item: \"+item3);\n }\n\t\t\t }\n if(tea[j][4]==\"S\" && (i == 3 || i == 6))// i = 3; i =6;\n\t\t\t {\n\t\t\t \tif( (tea[j][6]+tea[j][9])/2 > ((tea[i][6]+tea[i][9])/2)+1)\n {\n nadwyzka = (tea[j][6]+tea[j][9])/2 - ((tea[i][6]+tea[i][9])/2);nadwyzka = zaokr(nadwyzka);\n item4 = [j, i, nadwyzka];\n all_lawka.unshift(item4);// \n }\n\t\t\t }\n } //end of for j=8..12\n //console.log(all_lawka);\n }//end of for i=1..6\n //sortowanie\n for(u=0; u<all_lawka.length; u++)\n {\n for(w=1; w<all_lawka.length; w++)\n {\n if(all_lawka[w][2] > all_lawka[w-1][2])\n {\n temp = all_lawka[w-1];\n all_lawka[w-1] = all_lawka[w];\n all_lawka[w] = temp;\n }\n }\n }\n //próba wykoanania zmiany\n for(u=0; u<all_lawka.length; u++)\n {\n out_id = all_lawka[u][1];\n in_id = all_lawka[u][0];\n out_nr = tea[out_id][3]; //na indeksie 1 mam wyznaczonego do zejścia - nr dla funkcji possible_change\n in_nr = tea[in_id][3]; //\n if(adr == 1)\n {\n if(possible_change(adr, out_nr, in_nr) < 6)\n {\nvar fffv = document.getElementById(\"screen3\").innerHTML;\ndocument.getElementById(\"screen3\").innerHTML=fffv+\"<br>(\"+pkt1+\":\"+pkt2+\") \"+tea[in_id][5]+\" za: \"+tea[out_id][5]+\" (stan: \"+mm1+\" : \"+mm2+\") \";\n//2021-01-13: nowy screen do zapisu zmian na czas seta\nvar fffv = document.getElementById(\"change_info1\").innerHTML;\ndocument.getElementById(\"change_info1\").innerHTML=fffv+\"<br>(\"+pkt1+\":\"+pkt2+\") \"+tea[in_id][5]+\" za \"+tea[out_id][5];\n change1(out_id,in_id); flag_golden1 = 1; return 0;\n }\n }\n else\n {\n if(possible_change(adr, out_nr, in_nr) < 6)\n {\nvar fffv = document.getElementById(\"screen6\").innerHTML;\ndocument.getElementById(\"screen6\").innerHTML=fffv+\"<br>(\"+pkt1+\":\"+pkt2+\") \"+tea[in_id][5]+\" za: \"+tea[out_id][5]+\" (stan: \"+mm1+\" : \"+mm2+\") \";\n//2021-01-13: nowy screen do zapisu zmian na czas seta\nvar fffv = document.getElementById(\"change_info2\").innerHTML;\ndocument.getElementById(\"change_info2\").innerHTML=fffv+\"<br>(\"+pkt1+\":\"+pkt2+\") \"+tea[in_id][5]+\" za \"+tea[out_id][5];\n change2(out_id,in_id); flag_golden2 = 1; return 0;\n }\n }\n }\n\n\n if(adr==1)\n {\n team1 = tea;\n }\n else \n {\n team2 = tea;\n }\n\n banch_ins();\n return 1;\n}", "function numberToComb(val,en,kay)\n{\n var positions =[]\n var total = 0;\n var manVal = val;\n var manEn =en;\n var enDrops =-1;\n var manKay = kay-1;\n var priorTotal = 0;\n var pushVal=0;\n var firstRun = true;\n var lastManKay = 0;\n var lastManEn = 0;\n\n var lastCombo=0;\n// var lastOrigCombo=0;\n// var newCombo=0;\n \n// var testingArray =[];\n \n \n while (manKay>=0)\n {\n manEn--;\n enDrops++;\n priorTotal=total;\n\n \n \n // var testingTotal = total;\n if (((lastManEn-manEn)==1)&&(Math.abs(lastManKay-manKay)==1)&&(lastManKay>3)&&(lastManEn>3))\n {\n lastCombo=lastCombo*(Math.min(lastManKay,(lastManEn-lastManKay))/lastManEn)\n }\n else\n {\n lastCombo=(new AFastCombinatorial(manEn,manKay)).prod\n }\n total+=lastCombo\n// testingTotal+=lastCombo\n// lastOrigCombo=newCombo;\n// newCombo = (new AFastCombinatorial(manEn,manKay)).prod\n// total+=newCombo;\n// total+=(new AFastCombinatorial(manEn,manKay)).prod\n \n// testingArray.push(total,testingTotal)\n lastManEn=manEn;\n lastManKay=manKay;\n\n if (manVal<=total)\n {\n\n if (manKay==0)\n {\n if (!firstRun)\n {\n manVal-=priorTotal;\n }\n positions.push([enDrops+manVal]);\n }\n else\n {\n if (manVal==total)\n {\n enDrops++;\n positions.push([enDrops]);\n manVal=0;\n }\n else\n {\n if (!firstRun)\n {\n manVal-=priorTotal;\n }\n positions.push([enDrops]);\n }\n }\n total=0;\n priorTotal=0;\n manKay--;\n firstRun=true;\n }\n else\n {\n firstRun=false;\n }\n }\n return positions;\n}", "function brickCalulator (floors) {\n if(floors < 0) {\n return \"haha! you cannot make me fool...Underground floors are not invented yet:3 Give the correct input.\"\n }\n else {\n var heightTo10th = 0;\n var heightFrom10To20th = 0;\n var heightFrom20ToUp = 0;\n for(var i = 0; i <= floors; i++) {\n // to determine the height from 0 to 10th floor.\n if(i <= 10) {\n heightTo10th = i * 15;\n }\n // to determine the height from 10 to 20th floor.\n if(i <= 20 && i > 10) { \n heightFrom10To20th = (i-10) * 12;\n }\n // to determine the height from 20th to upper floor.\n if(i > 20) {\n heightFrom20ToUp = (i-20) * 10;\n }\n }\n var totalHeight = heightTo10th + heightFrom10To20th + heightFrom20ToUp;\n var brickNeeded = totalHeight * 1000;\n return \"You need \"+ brickNeeded+ \" pcs of brick\";\n }\n}", "function pascGenOut()\n{\n actSheet.clear()\n var em = 7;\n var tea = 7;\n //var pasc = makeSevenBruitForce();\n var pascB = genTwoPascal(12);\n //the em is a number above 2.\n var pasc= pascGen(pascB,em-2,7,0,pascB)\n var level=0;\n while (level!=em)\n {\n //cA is first row\n var newStructure = [];\n for (var cA=0;cA<tea+1;cA++)\n {\n //cBgoes across first row\n var tempArray =[];\n for (var cB=0;cB<cA+1;cB++)\n {\n //so we get the structures in the last dimension accordig to cb\n //there is something wrong with the multipliers\n var multip = basePascal[cA][cB];\n var curS = pCurrentStructure[cB]\n // Logger.log(\"level: \"+level+\" cA: \"+cA+\" cB: \"+cB+\" multip: \"+multip +\"ohter: \"+basePascal[cA][cB])\n var cloeMultRes=cloneAndMultiply(pCurrentStructure[cB],basePascal[cA][cB])\n tempArray.push(cloeMultRes);\n }\n newStructure.push(tempArray);\n }\n pCurrentStructure = newStructure;\n level++;\n }\n// var captRes = makePasc(newStructure,em,tea,level,basePascal);\n return pCurrentStructure;\n}", "function bagTheBestDeal(n, c){\n\t\t// n: remaining items to consider\n\t\t// c: remaining capacity of the bag\n\n\t\t//console.log(`\\nConsidering item at index ${n} with weight: ${w[n]} and value: ${v[n]}`)\n\t\t//console.log(['remaining items', 'remaining capacity'])\n\t\t//console.log([n, c])\n\t\t\n\t// Base cases\n\t\t// when the result is already calculated in the past\n\t\tif (DPArr[n][c] != null) {\n\t\t\tconsole.log(`Using memo`)\n\t\t\treturn DPArr[n][c]\n\t\t}\t\n\t\t\n\t\t// when no items left, or no capacity left\n\t\tif (n==0 || c == 0){\treturn 0}\n\n\t// Recursive cases\n\t\tlet result = 0\n\t\tif (w[n] > c){ \t// dont put current item but investigate the remaining items\n\t\t\t//console.log('\\tOnly One Way to Go')\n\t\t\tresult = bagTheBestDeal(n-1, c)\t\t\t\n\t\t}else {\n\t\t\t//console.log('\\tConsidering both Options')\n\t\t\tlet putTheItem \t\t= v[n] + bagTheBestDeal(n-1, c-w[n])\n\t\t\tlet dontPutTheItem \t= \t\t bagTheBestDeal(n-1, c)\n\t\t\t\n\t\t\t// Include the item in the baggedItems array (if putTheItem is the way to go) and \n\t\t\t// return the max of the two values\n\t\t\tif (putTheItem >= dontPutTheItem){\n\t\t\t\tlet key = `item ${n}`\n\t\t\t\tif (!baggedItems.get(key)){\n\t\t\t\t\tbaggedItems.set(key, `Weight: ${w[n]}, Value: ${v[n]}`)\n\t\t\t\t} \n\t\t\t\tresult = putTheItem\n\t\t\t}else{\n\t\t\t\tresult = dontPutTheItem\n\t\t\t}\n\t\t\t//result = Math.max(putTheItem, dontPutTheItem)\t\t\t\n\t\t}\n\n\t\tDPArr[n][c] = result\n\t\treturn result\n\n\t}", "function budgetCalculator(quantityOfWatch, quantityOfPhone, quantityOfLaptop){\n if(quantityOfWatch > 0 && quantityOfPhone > 0 && quantityOfLaptop >0){\n var costOfWatch = quantityOfWatch * 50; //each watch is of 50$\n var costOfPhone = quantityOfPhone * 100; //each phone is of 50$\n var costOfLaptop = quantityOfLaptop * 500; //each laptop is of 50$\n var totalCost = costOfWatch + costOfPhone + costOfLaptop;\n return totalCost;\n }else{\n return \"Error: Quantity of electronics cannot be negative or others!\";\n }\n}", "function solution(juice, capacity) {\n // write your code in JavaScript (Node.js 8.9.4)\n\n let newCapacity = capacity;\n newCapacity.sort((a, b) => {\n return b - a;\n });\n let sumJuice = juice.reduce((a, b) => a + b, 0);\n\n if (newCapacity[0] >= sumJuice) {\n return juice.length;\n }\n\n let combine = juice.map((val, index) => {\n let spaceLeftInGlass = capacity[index] - val;\n let arr = [val, capacity[index], spaceLeftInGlass];\n return arr;\n });\n\n combine.sort((a, b) => {\n return b[2] - a[2] || b[1] - a[1];\n });\n\n let biggestSpace = combine[0][2];\n\n combine.splice(0, 1);\n combine.sort((a, b) => {\n return a[0] - b[0];\n });\n\n let maxMix = 1;\n\n for (let i = 0; i < combine.length; i++) {\n biggestSpace -= combine[i][0];\n\n if (biggestSpace < 0) {\n return maxMix;\n }\n maxMix++;\n }\n}", "function findArmor(money)\n{\n let helmet = '';\n let legging = '';\n let chest = '';\n let boot = '';\n let extra = '';\n\n let hNum = 0;\n let hPrice = 0;\n let lNum = 0;\n let lPrice = 0;\n let cNum = 0;\n let cPrice = 0;\n let bNum = 0;\n let bPrice = 0;\n\n let total = 0;\n// go through the helmet array to find one with max value and fits within money limit\n for(let i = 0; i < helmets.length; i++)\n {\n if(hNum < helmets[i].value && helmets[i].price < money)\n {\n hNum = helmets[i].value;\n hPrice = helmets[i].price;\n helmet = helmets[i].name;\n }\n }\n money = money - hPrice;\n// after money is subtracted from helmet, do the same with leggings array\n for(let j = 0; j < leggings.length; j++)\n {\n if(lNum < leggings[j].value && leggings[j].price < money)\n {\n lNum = leggings[j].value;\n lPrice = leggings[j].price;\n legging = leggings[j].name;\n }\n }\n money = money - lPrice;\n// same code to find max of chest\n for(let k = 0; k < chests.length; k++)\n {\n if(cNum < chests[k].value && chests[k].price < money)\n {\n cNum = chests[k].value;\n cPrice = chests[k].price;\n chest = chests[k].name;\n }\n }\n money = money - cPrice;\n// same code to find max of boots\n\nfor(let l = 0; l < boots.length; l++)\n{\n if(bNum < boots[l].value && boots[l].price < money)\n {\n bNum = boots[l].value;\n bPrice = boots[l].price;\n boot = boots[l].name;\n }\n}\n// if money is less than the lowest price to get one extra item then perform this function\n if(money - bPrice < 33)\n {\n let finalSet = getLastItems(money,boots,boot);\n bNum = finalSet[2];\n boot = finalSet[0];\n money = finalSet[3];\n }\n // else just subtract money\n else \n {\n money = money - bPrice; \n }\n// to find the extra item we perform finalArmor function and check with each other to find max value and if it is within money limit\n let lastMaxValue = 0;\n let remainder = 0;\n\n let lastHelmet = finalArmor(money,helmets,helmet);\n let lastLeg = finalArmor(money,leggings,legging);\n let lastChest = finalArmor(money,chests,chest);\n let lastBoot = finalArmor(money,boots,boot);\n\n if(lastMaxValue < lastHelmet[1])\n {\n lastMaxValue = lastHelmet[1];\n extra = lastHelmet[0];\n remainder = lastHelmet[2];\n }\n if(lastMaxValue < lastChest[1])\n {\n lastMaxValue = lastChest[1];\n extra = lastChest[0];\n remainder = lastChest[2];\n }\n if(lastMaxValue < lastLeg[1])\n {\n lastMaxValue = lastLeg[1];\n extra = lastLeg[0];\n remainder = lastLeg[2];\n }\n if(lastMaxValue < lastBoot[1])\n {\n lastMaxValue = lastBoot[1];\n extra = lastBoot[0];\n remainder = lastBoot[2];\n }\n \n total = hNum + lNum + cNum + bNum + lastMaxValue;\n// after we have all the armor, go ahead and append them to the html in the following format\n $('#displayArmor').append(`\n <h1>Summary</h1>\n <h2 class=\"uk-card-title\">Helmet: `+` ${helmet}</h2>\n <h2 class=\"uk-card-title\">Chest: `+` ${chest}</h2>\n <h2 class=\"uk-card-title\">Legging: `+` ${legging}</h2>\n <h2 class=\"uk-card-title\">Boots: `+` ${boot}</h2>\n <h2 class=\"uk-card-title\">Extra item: `+` ${extra}</h2>\n <h2 class=\"uk-card-title\">Max Value: `+` ${total}</h2>\n <h2 class=\"uk-card-title\">Remaining Crowns: `+` ${remainder}</h2>\n `)\n \n}", "function CalcWeight()\n{\n if (disable_autocalc())\n return;\n\n var total = 0.0;\n var slots = document.getElementById(\"gear\").rows.length - 3;\n for (var i = 1; i <= slots; i++)\n {\n var num = parseFloat(sheet()[\"Gear\" + FormatNumber(i) + \"W\"].value);\n if (!isNaN(num))\n total += num;\n }\n\n document.getElementById(\"bagWeight\").innerHTML = total.toFixed(1);\n\n // Add the armor weight.\n for ( var i = 1; i <= 4; i++ )\n {\n // If the armor is flagged as not carried, then don't add it to the weight.\n if ( !sheet()[\"Armor\" + i + \"Carried\"].checked )\n continue;\n\n var num = parseFloat(sheet()[\"Armor\" + i + \"Weight\"].value);\n if (!isNaN(num))\n total += num;\n }\n\n // Add the weapon weight\n for ( var i = 1; i <= 4; i++ )\n {\n if ( sheet()[ \"Weapon\" + i + \"Carried\" ].checked )\n {\n var num = parseFloat(sheet()[\"Weapon\" + i + \"Weight\"].value);\n if (!isNaN(num))\n total += num;\n }\n }\n\n sheet().TotalWeight.value = total.toFixed(1);\n\n // Check to see if the character is encumbered. If so, then set the background\n // color of \"Total Weight\", Speed, and DexMod input fields to red.\n if ( Clean( sheet().TotalWeight.value ) > Clean( sheet().LightLoad.value ) )\n {\n debug.trace(\"Character is encumbered.\");\n var maxDexMod = 99;\n\n if ( Clean( sheet().TotalWeight.value ) > Clean( sheet().MediumLoad.value ) )\n {\n maxDexMod = 1;\n sheet().TotalWeight.title = \"Check penalty of -6 while encumbered\";\n }\n else\n {\n maxDexMod = 3;\n sheet().TotalWeight.title = \"Check penalty of -3 while encumbered\";\n }\n\n debug.trace(\"MaxDexMod = \" + maxDexMod + \" DexMod = \" + Clean( sheet().DexMod.value ) );\n if ( Clean( sheet().DexMod.value ) > maxDexMod )\n {\n sheet().DexMod.title = \"Max dex bonus to AC is +\" + maxDexMod + \" while encumbered.\";\n sheet().DexMod.style.color = \"white\";\n sheet().DexMod.style.backgroundColor = \"red\";\n }\n else\n {\n sheet().DexMod.title = sheet().DexMod.value;\n sheet().DexMod.style.color = \"black\";\n sheet().DexMod.style.backgroundColor = \"white\";\n }\n\n sheet().TotalWeight.style.color = \"white\";\n sheet().TotalWeight.style.backgroundColor = \"red\";\n\n sheet().Speed.title = \"Max speed is reduced by roughly 1/3 due to encumbrance\";\n sheet().Speed.style.color = \"white\";\n sheet().Speed.style.backgroundColor = \"red\";\n\n ACCheckMaxDex(); // Check if the dex bonus to AC should be reduced.\n }\n else\n {\n sheet().TotalWeight.title = sheet().TotalWeight.value;\n sheet().TotalWeight.style.color = \"black\";\n sheet().TotalWeight.style.backgroundColor = \"white\";\n\n sheet().DexMod.title = sheet().DexMod.value;\n sheet().DexMod.style.color = \"black\";\n sheet().DexMod.style.backgroundColor = \"white\";\n\n sheet().Speed.title = sheet().Speed.value;\n sheet().Speed.style.color = \"black\";\n sheet().Speed.style.backgroundColor = \"white\";\n }\n\n\n SkillsUpdateCheckPen();\n\n debug.trace(\"Calculated total weight.\");\n}", "function calcular_chi2_critico(tabla_de_contingencia, alpha) {\n let grado_de_libertad = calcular_grado_libertad(tabla_de_contingencia);\n if (grado_de_libertad > 5) {\n // si se quiere usar la tabla para calculo de chi completa deben ser agregados los valores en la tabla chi criticos\n alert(\"La tabla de chi critico actual, solo admite grado de libertad menores o iguales que 5\"); \n return 0;\n } else {\n return tabla_chi_criticos[alpha][grado_de_libertad];\n }\n}", "function chairTotal(a,b){\n\n var totalChairs = a*b;\n return totalChairs;\n}", "function FoodDistribution(arr) {\n\t// get our helper functions\n\tconst helpers = createHelpers();\n\t// get the number of meals as a separate item;\n\tlet treats = arr.shift();\n\t// get the hunger numbers as a separate item;\n\tconst myArray = arr.slice(0);\n\tconst len = myArray.length;\n\t// get the hunger index of the least hungry individual;\n\tconst arrMin = Math.min(...myArray);\n\n\t// check to see if we have enough treats to get everybody to the current best level\n\t// this is the easy case\n\tconst testCount = myArray.reduce((val1, val2) => val1 + (val2 - arrMin), 0);\n\tif (testCount <= treats) {\n\t\treturn 0;\n\t}\n\t// get an array of the values in order, paired with a count of how many of them in a row\n\tlet valQuantArr = helpers.objectify(myArray);\n\n\tfor (let i = 1; i < len; i++) {\n\t\tlet arrayLen = valQuantArr.length;\n\t\tconst resp = helpers.flattenMid(valQuantArr, treats, i);\n\t\tvalQuantArr = resp[0];\n\t\tarrayLen = valQuantArr.length;\n\t\ttreats = resp[1];\n\t\twhile (valQuantArr[0].quant <= i && valQuantArr[0].value > valQuantArr[1].value &&\n\t\t\ttreats >= i) {\n\t\t\tif (valQuantArr[0].quant <= treats) {\n\t\t\t\tvalQuantArr[0].value -= 1;\n\t\t\t\ttreats -= valQuantArr[0].quant;\n\t\t\t\tvalQuantArr = helpers.objectify(valQuantArr);\n\t\t\t\tarrayLen = valQuantArr.length;\n\t\t\t}\n\t\t}\n\n\t\twhile (valQuantArr[arrayLen - 1].quant <= i &&\n\t\t\tvalQuantArr[arrayLen - 1].value > valQuantArr[arrayLen - 2].value && treats >= i) {\n\t\t\tif (valQuantArr[arrayLen - 1].quant <= treats) {\n\t\t\t\tvalQuantArr[arrayLen - 1].value -= 1;\n\t\t\t\ttreats -= valQuantArr[arrayLen - 1].quant;\n\t\t\t\tvalQuantArr = helpers.objectify(valQuantArr);\n\t\t\t\tarrayLen = valQuantArr.length;\n\t\t\t}\n\t\t}\n\t}\n\n\tlet count = 0;\n\tfor (let i = 0, leng = valQuantArr.length; i < leng - 1; i++) {\n\t\tcount += Math.abs(valQuantArr[i].value - valQuantArr[i + 1].value);\n\t}\n\treturn count;\n}", "function rightTotal(threeK, fourk, fullH, smallS, largeS, yahtzee, extraY, chance) {\n return threeK + fourk + fullH + smallS + largeS + yahtzee + extraY + chance;\n}", "function checkCashRegister(price, cash, cid) {\n var result = [];\n // Corresponding order amout of currency\n var curr = [0.01, 0.05, 0.1, 0.25, 1, 5, 10, 20, 100];\n // toFixed method would return a string representing the number, '+' sign would convert string into number type\n var change = +(cash - price).toFixed(2);\n // Here is your change, ma'am.\n var sum = 0;\n cid.forEach(function(arr) {\n sum += arr[1];\n });\n sum = +sum.toFixed(2);\n if (sum === change) {\n return \"Closed\";\n } else if (sum < change) {\n return \"Insufficient Funds\";\n } else {\n for (var i = cid.length - 1; i >= 0; i--) {\n var currAmount = cid[i][1].toFixed(2);\n var numOfOrder = Math.floor(change / curr[i]);\n if (numOfOrder > 0) {\n if (numOfOrder > currAmount / curr[i]) {\n change = (change - currAmount).toFixed(2);\n result.push([cid[i][0], +currAmount]);\n } else {\n change = (change - curr[i] * numOfOrder).toFixed(2);\n result.push([cid[i][0], +(curr[i] * numOfOrder).toFixed(2)]);\n }\n }\n }\n if (change > 0) {\n return \"Insufficient Funds\";\n } else {\n return result;\n }\n }\n}", "function brickCalculator(floorCount)\n{\n //first condition to check if the bulding is more than 20 floors and then calculate needed bricks. for first 20 floor needed bricks are pre-defined.\n if(floorCount>20)\n {\n var excess = floorCount - 20;\n var feetCount = excess*10;\n var totalFeet = feetCount + (10*12) + (10*15);\n var neededBricks = totalFeet*1000;\n }\n //second condition to check if the building is more than 10 floors but less than or equal 20 floors. For first 10 floors needed bricks are pre-defined.\n else if(floorCount>10 && floorCount<=20)\n {\n var excess = floorCount - 10;\n var feetCount = excess*12;\n var totalFeet = feetCount + (10*15);\n var neededBricks = totalFeet*1000;\n }\n //third condition to check if the bulding is less than or equal 10 floors.\n else if(floorCount>0 && floorCount<=10)\n {\n var feetCount = floorCount*15;\n var neededBricks = feetCount*1000;\n }\n //if input is invalid necessary warnings are given.\n else\n {\n return \"Floor can not be negative or you do not need any bricks\";\n }\n return neededBricks;\n}", "function budgetCalculator(numberOfWatch, numberOfMobile, numberOfLaptop) {\n\n //when the quantity is negative\n if (numberOfWatch < 0) {\n return \"Number of watch is invalid\";\n }\n\n if (numberOfMobile < 0) {\n return \"Number of mobile is invalid\";\n }\n if (numberOfLaptop < 0) {\n return \"Number of laptop is invalid\";\n }\n\n\n\n var singleWatchPrice = 50;//price of a watch is given 50 tk\n var singleMobilePrice = 100;// price of a mobile is given 100tk\n var singleLaptopPrice = 500;// price of a laptop is given 500 tk\n\n\n\n var totalPriceOfWatch = singleWatchPrice * numberOfWatch;//total price of watch\n\n\n var totalPriceOfMobile = singleMobilePrice * numberOfMobile;//total price of mobile\n\n var totalPriceOfLaptop = singleLaptopPrice * numberOfLaptop;//total price of laptop\n\n //Total cost calculation\n var totalCost = totalPriceOfWatch + totalPriceOfMobile + totalPriceOfLaptop;\n\n\n return (totalCost);\n\n\n}", "function beeStung(weight) {\n \n //calculate for bee stings\n var stings=8.666666667*weight\n \n //Return number of Bee stings\n return stings;\n}", "function handleDeficit(remaining,id){\r\n\tvar productCode = findValue('code',id);\r\n\tvar whouseId = parseInt(findValue('whouse',id));\r\n\tvar shelf_numbers = alasql('SELECT * FROM shelves WHERE warehouseid=? AND productcode=?',[whouseId,productCode]);\r\n\tfor(var i=0;i<shelf_numbers.length && remaining>0;i++){\r\n\t\tvar total = alasql('SELECT SUM(quantity) AS total FROM shelves WHERE shelfnumber=?',[shelf_numbers[i].shelfnumber])[0].total;\r\n\t\tvar deficit = 200-total;\r\n\t\tif(deficit==0)\r\n\t\t\tcontinue;\r\n\t\tif(deficit>=remaining){\r\n\t\t\tvar elems = alasql('SELECT * FROM shelves WHERE shelfnumber=? AND warehouseid=? AND productcode=?',[shelf_numbers[i].shelfnumber,whouseId,productCode]);\r\n\t\t\tif(elems.length==0){\r\n\t\t\t\tvar shelfId = alasql('SELECT MAX(id) + 1 as id FROM shelves')[0].id;\r\n\t\t\t\talasql('INSERT INTO shelves VALUES(?,?,?,?,?)',[shelfId,shelf_numbers[i].shelfnumber,shelf_numbers[i].warehouseid,productCode, remaining]);\r\n\t\t\t}else{\r\n\t\t\t\talasql('UPDATE shelves SET quantity=? WHERE shelfnumber=? AND warehouseid=? AND productcode=?',[elems[0].quantity+remaining,shelf_numbers[i].shelfnumber,whouseId,productCode]);\r\n\t\t\t}\r\n\t\t}else{\r\n\t\t\tvar elems = alasql('SELECT * FROM shelves WHERE shelfnumber=? AND warehouseid=? AND productcode=?',[shelf_numbers[i].shelfnumber,whouseId,productCode]);\r\n\t\t\tif(elems.length==0){\r\n\t\t\t\tvar shelfId = alasql('SELECT MAX(id) + 1 as id FROM shelves')[0].id;\r\n\t\t\t\talasql('INSERT INTO shelves VALUES(?,?,?,?,?)',[shelfId,shelf_numbers[i].shelfnumber,shelf_numbers[i].warehouseid,productCode, deficit]);\r\n\t\t\t}else{\r\n\t\t\t\talasql('UPDATE shelves SET quantity=? WHERE shelfnumber=? AND warehouseid=? AND productcode=?',[elems[0].quantity+deficit,shelf_numbers[i].shelfnumber,whouseId,productCode]);\r\n\t\t\t}\r\n\t\t}\r\n\t\tremaining -= deficit;\t\t\r\n\t}\r\n\tvar rows = alasql('SELECT * FROM shelves WHERE warehouseid=?',[whouseId] );\r\n\tfor(var i=0;i<rows.length && remaining>0;i++){\r\n\t\tvar total = alasql('SELECT SUM(quantity) AS total FROM shelves WHERE shelfnumber=?',[rows[i].shelfnumber])[0].total;\r\n\t\tvar deficit = 200-total;\r\n\t\tif(deficit==0)\r\n\t\t\tcontinue;\r\n\t\tif(deficit>=remaining){\r\n\t\t\tvar elems = alasql('SELECT * FROM shelves WHERE shelfnumber=? AND warehouseid=? AND productcode=?',[rows[i].shelfnumber,whouseId,productCode]);\r\n\t\t\tif(elems.length==0){\r\n\t\t\t\tvar shelfId = alasql('SELECT MAX(id) + 1 as id FROM shelves')[0].id;\r\n\t\t\t\talasql('INSERT INTO shelves VALUES(?,?,?,?,?)',[shelfId,rows[i].shelfnumber,rows[i].warehouseid,productCode, remaining]);\r\n\t\t\t}else{\r\n\t\t\t\talasql('UPDATE shelves SET quantity=? WHERE shelfnumber=? AND warehouseid=? AND productcode=?',[elems[0].quantity+remaining,rows[i].shelfnumber,whouseId,productCode]);\r\n\t\t\t}\r\n\t\t}else{\r\n\t\t\tvar elems = alasql('SELECT * FROM shelves WHERE shelfnumber=? AND warehouseid=? AND productcode=?',[rows[i].shelfnumber,whouseId,productCode]);\r\n\t\t\tif(elems.length==0){\r\n\t\t\t\tvar shelfId = alasql('SELECT MAX(id) + 1 as id FROM shelves')[0].id;\r\n\t\t\t\talasql('INSERT INTO shelves VALUES(?,?,?,?,?)',[shelfId,rows[i].shelfnumber,rows[i].warehouseid,productCode, deficit]);\r\n\t\t\t}else{\r\n\t\t\t\talasql('UPDATE shelves SET quantity=? WHERE shelfnumber=? AND warehouseid=? AND productcode=?',[elems[0].quantity+deficit,rows[i].shelfnumber,whouseId,productCode]);\r\n\t\t\t}\r\n\t\t}\r\n\t\tremaining -= deficit;\r\n\t}\r\n\tif(remaining>0){\r\n\t\talert(\"Not enough shelves in warehouse to hold current item.\");\r\n\t}\r\n\treturn remaining;\r\n}", "function CH(W,V,D,T){\n var X, E, x, z, m, S=W+3, a=D+2, k=MV[3], B=R;\n for(;W<S;W++){\n for(m=D-2;++m<a;){\n E=B[W+m];\n if(E&&(E&8)==V&&((E&8)==1||(E&7)==6)) return 0;\n E=0, X=W;\n while(!E){\n X+=m, E=B[X];\n if((E==V+2+(m!=D)*2)||E==V+5) return 0;\n }\n }\n for(z=0;z<8;) if(B[W+k[z++]]-V==3) return 0;\n }\n E=0, W-=3;\n while(!E){\n W-=T, E=B[W];\n if(E==V+2||E==V+5) return 0;\n }\n return 1;\n }", "function calcCorHybr (numFloors, numBasements, numOccupants){ \n var totalOccupantsCorHybr= numOccupants * (numFloors + numBasements);\n var numShaftsRequired= Math.ceil(totalOccupantsCorHybr / 1000);\n numColumnsCorHybr= Math.ceil((numFloors + numBasements) / 20);\n var numShaftsColumm= Math.ceil(numShaftsRequired / numColumnsCorHybr);\n numTotalShaftsCorHybr= numShaftsColumm * numColumnsCorHybr;\n }", "function budgetCalculator(x,y,z) {\n\n if (x>0 && y>0 && z>0)\n {\n\n var watchCost = 50 * x ;//cost-per-watch=50\n\n var mobileCost = 100 * y ;//cost-per-mobile=100\n\n var laptopCost = 500 * z ;//cost-per-laptop=500\n\n var totalCost = watchCost + mobileCost + laptopCost ;\n\n return totalCost ; \n\n }\n\n else{\n\n return \"Number of goods must be greater than zero\";\n }\n}", "function brickCalculator(numOfFloor){\n const brickPerFeet = 1000;\n var totalAmountOfBricks=0;\n for(var floorNo=1; floorNo<=numOfFloor; floorNo++){\n if(floorNo<=10){\n var j=0;\n j++;\n totalAmountOfBricks = totalAmountOfBricks + (j * (15 * brickPerFeet));\n }\n else if(floorNo<=20){\n var k=0;\n k++;\n totalAmountOfBricks = totalAmountOfBricks + (k * (12 * brickPerFeet));\n }\n else{\n var l=0;\n l++;\n totalAmountOfBricks = totalAmountOfBricks + (l * (10 * brickPerFeet));\n }\n }\n return totalAmountOfBricks;\n}", "function coffeeShop(inputArr) {\n let orders = inputArr.shift();\n let result = 0;\n let i = 0;\n let price = inputArr[i];\n let days = inputArr[i + 1];\n let capsules = inputArr[i + 2];\n\n while (orders != 0) {\n let sum = (days * capsules) * price;\n result += sum;\n console.log(`The price for the coffee is: $${sum.toFixed(2)}`);\n i += 3\n price = inputArr[i];\n days = inputArr[i + 1];\n capsules = inputArr[i + 2];\n orders--;\n }\n\n // for(let i = 0; i < inputArr.length; i += 3) {\n // let price = inputArr[i];\n // let days = inputArr[i + 1];\n // let capsules = inputArr[i + 2];\n // let sum = (days * capsules) * price;\n // result += sum;\n // console.log(`The price for the coffee is: $${sum.toFixed(2)}`);\n // }\n console.log(`Total: $${result.toFixed(2)}`);\n}", "function main() {\n //let [n, k] = readLine().split(' ').map(Number), c = readLine().split(' ').map(Number);\n\n let n = 8, k = 2, c = [0, 0, 1, 0, 0, 1, 1, 0]; // 4\n\n let E = 100, i;\n for (i = 0; i < n; i += k) {\n if(c[i]) {\n E -= 3;\n } else {\n E -= 1;\n }\n }\n console.log(E);\n}", "function bucle_dowhile() {\n i = 1;\n do {\n tabla += \"<td>\" + Math.pow(i, 3) + \"</td>\";\n i++\n } while (i <= 10);\n }", "function checkCashRegister(price, cash, cid) {\n let change = cash - price;\n let totalChange = 0;\n let ret = [];\n\n const table = [['PENNY', 0.01],\n ['NICKEL', 0.05],\n ['DIME', 0.10],\n ['QUARTER', 0.25],\n ['ONE', 1],\n ['FIVE', 5],\n ['TEN', 10],\n ['TWENTY', 20],\n ['ONE HUNDRED', 100]];\n\n let leftCid = cid.map((v, i) => {\n totalChange = +(totalChange + v[1]).toFixed(2);\n console.log(table[i]);\n return [v[0], +(v[1] / table[i][1]).toFixed(2)];\n });\n\n for(let i=8; i > -1; i--){\n if(change < table[i][1]) continue;\n let num = 0;\n while(change >= table[i][1] && leftCid[i][1] > 0 && totalChange > 0){\n leftCid[i][1] = +(leftCid[i][1]-1).toFixed(2);\n change = +(change - table[i][1]).toFixed(2);\n totalChange = +(totalChange - table[i][1]).toFixed(2);\n num++;\n }\n ret.push([table[i][0], +(table[i][1] * num).toFixed(2)]);\n if(change === 0) break;\n }\n if(change > 0) return 'Insufficient Funds';\n if(totalChange === 0) return 'Closed';\n return ret;\n}", "function ContainerWeight(container)\n{\n if (disable_autocalc())\n return;\n\n var total = 0.0;\n var slots = document.getElementById(container).rows.length - 3;\n for (var i = 1; i <= slots; i++)\n {\n var num = parseFloat(sheet()[container + \"Gear\" + FormatNumber(i) + \"W\"].value);\n if (!isNaN(num))\n total += num;\n }\n\n document.getElementById(container + \"Weight\").innerHTML = total.toFixed(1);\n}", "function mathHeavyStuff(sizeFeet, sizeInches, i) {\n $scope[\"lum_quant_\" + sizeFeet].push((Math.ceil((schem.cuts[i].piece_num * quant) / Math.floor(sizeInches / schem.cuts[i].piece_length))));\n $scope[\"total_cost_\" + sizeFeet].push(Number(($scope[\"lum_quant_\" + sizeFeet][i] * $scope.lumberPrices[schem.cuts[i].lumber_size][\"price_\" + sizeFeet])));\n $scope[\"total_scrap_\" + sizeFeet].push(($scope[\"lum_quant_\" + sizeFeet][i] * sizeInches) - (schem.cuts[i].piece_num * quant * schem.cuts[i].piece_length));\n }", "function special_poth(number) {\n\n for (var c = 1; c < number; c++) {\n for (var b = 1; b < c; b++) {\n for (var a = 0; a <b; a++) {\n if ((a+b+c) === number && (Math.pow(a,2) + Math.pow(b,2) === Math.pow(c,2))) {\n return a * b * c\n }\n }\n }\n }\n}", "function getEffectiveWeight(helmet, chest, hand, feet) {\n\thelmet = parseFloat(helmet);\n\tchest = parseFloat(chest);\n\thand = parseFloat(hand);\n\tfeet = parseFloat(feet);\n\n\tvar eweight = Math.max(0, 3*helmet + chest + feet + 2*hand - 7);\n\treturn eweight;\n}", "function fillUp(creep, towerOrContainer) {\n //var highest = undefined;\n \n if(towerOrContainer=='container') {\n var highest = getHighestContainer();\n \n if(highest.transfer(creep, RESOURCES_ALL, creep.carryCapacity) == ERR_NOT_IN_RANGE) {\n creep.moveTo(highest, {reusePath:3});\n } \n if(creep.carry.energy == creep.carryCapacity) {\n return;\n }\n \n \n } else if(towerOrContainer=='tower') {\n var highest = getHighestTower();\n console.log('highest tower: '+highest);\n \n if(highest.transferEnergy(creep, creep.carryCapacity) == ERR_NOT_IN_RANGE) {\n creep.moveTo(highest, {reusePath:3});\n } \n if(creep.carry.energy == creep.carryCapacity) {\n return;\n }\n }\n\n \n}", "function ACombinatorialWithDivide(pEn,pKay) {\nthis.en = pEn\nthis.kay = pKay\n//make a list of the number size that is just for the reminant of the top with the bottom crossed out.\nthis.newList = Array.apply(null, new Array(this.kay)).map(Function.call, Number).map(function(it){return it+this.en-this.kay+1},this)\n//reverse the list\nvar revList=this.newList.map(function(item,index){return this.newList[this.newList.length-index-1]},this)\n//make the other denominator number, that was not cancelled\nthis.botList=this.newList.map(function(item){return item-(this.en-this.kay)},this)\n//reverse that list\nvar revBot=this.botList.map(function(item,index){return this.botList[this.botList.length-index-1]},this)\nvar tallyList = infiniteArrayClone(revBot);\n// Logger.log(\" tallyList: \"+tallyList+\" revBot: \"+revBot+\" revList: \"+revList) \nfor (var cA=0;cA<revList.length;cA++)\n{\n var cB=0;\n //while you still have numbers to use and your count is less than length\n //and the item is greater than 1\n// Logger.log(\" tallyList: \"+tallyList+\" revBot: \"+revBot+\" revList[cA]: \"+revList[cA]+\" cB: \"+cB)\n while ((tallyList)&&(cB<revBot.length)&&(revList[cA]!=1))\n {\n //if the top list item is divisible by the bottom item\n //eliminate the bottom list item and make the top the result of the division\n if ((revList[cA]%revBot[cB])==0)\n {\n revList[cA]=revList[cA]/revBot[cB];\n// Logger.log(\" tallyList: \"+tallyList+\" revBot: \"+revBot+\" revList[cA]: \"+revList[cA]+\" cB: \"+cB)\n\n tallyList.splice(tallyList.indexOf(revBot[cB]),1);\n Logger.log(\" tallyList: \"+tallyList+\" revBot: \"+revBot+\" revList[cA]: \"+revList[cA]+\" cB: \"+cB)\n }\n cB++;\n }\n revBot=infiniteArrayClone(tallyList);\n}\nthis.prod=1\n//do the multiplication of the remnant\nif (revBot)\n{\nrevBot.forEach(function(item,ind){this.prod=this.prod*revList[ind]/item},this) ;\n}\nfor (var cH=revBot.length;cH<revList.length;cH++)\n{\n this.prod*=revList[cH];\n}\n//this.sum=0\n//revList.forEach(function(item){this.sum+=item},this);\n}", "function runProgram(input) {\n input = input.trim().split(\"\\n\");\n\n let C = Number(input[0]),\n n = Number(input[1]);\n\n // console.log(\"C, n\", C, n);\n\n let values = input[2].trim().split(\" \").map(Number),\n weights = input[3].trim().split(\" \").map(Number);\n\n // console.log(\"values, weights\", values, weights);\n\n let arr = [];\n\n for (let i = 0; i < n; i++) {\n arr.push([values[i] / weights[i], values[i], weights[i]]);\n }\n\n // console.log(\"arr\", arr);\n\n arr.sort((a, b) => b[0] - a[0]);\n // console.log(\"arr\", arr);\n\n let currWt = 0,\n currValue = 0;\n let i = 0,\n result = 0;\n\n while (currWt < C && i < n) {\n currValue = currValue + arr[i][1];\n currWt = currWt + arr[i][2];\n\n if (currWt >= C) {\n let fraction = Math.round(((currWt - C) * arr[i][1]) / arr[i][2]);\n result = currValue - fraction;\n }\n i++;\n }\n console.log(result)\n}", "function Bef_Calc(n) {\n // Get Data\n l = Number(document.getElementById(\"Beam-length\").value);\n w = Number(document.getElementById(\"Beam-width\").value);\n h = Number(document.getElementById(\"Beam-height\").value);\n E = Number(document.getElementById(\"Young\").value)*Math.pow(10,9);\n\n var f1 = 0, f2 = 0, s1 = 0, s2 = 0;\n\n //Check!!\n if (data.length < 2) {\n window.alert(\"Please make sure that you input correct situation!!\");\n Back();\n return 0;\n }\n\n for (var i=0; i<data.length; i++) {\n if (data[i][0] == 0 ) {\n f1 = f1 + 1;\n if (data[i][1] < 0 || data[i][1] > l) {\n Back();\n window.alert(\"Please enter correct Situation!!\");\n return 1;\n }\n }\n\n if (data[i][0] == 1) {\n f2 = f2 + 1;\n if (data[i][1] < 0 || data[i][1] > l || data[i][2] < 0 || data[i][2] > l) {\n Back();\n window.alert(\"Please enter correct Situation!!\");\n return 1;\n }\n }\n\n if (data[i][0] == 2) {\n s1 = s1 + 1;\n if (data[i][1] < 0 || data[i][1] > l) {\n Back();\n window.alert(\"Please enter correct Situation!!\");\n return 1;\n }\n }\n\n if (data[i][0] == 3) {\n s2 = s2 + 1;\n if (data[i][1] < 0 || data[i][1] > l) {\n Back();\n window.alert(\"Please enter correct Situation!!\");\n return 1;\n }\n }\n }\n\n if (f1 + f2 < 1) {\n Back();\n window.alert(\"Please input Load!!\");\n return 1;\n }\n\n if (s1 + s2 < 1) {\n window.alert(\"Please input Support!!\");\n Back();\n return 1;\n }\n\n if (s1 < 2 && s2 == 0) {\n window.alert(\"To support the beam, we need at least 1 fixed support or 2 rotatable support!!\");\n Back();\n return 1;\n }\n\n // Nodes\n int = l/n;\n x = [];\n for (var i=0; i<n+1; i++) {\n x[i] = l*i/n;\n }\n\n // Sorting Data\n var suparray = [];\n var supnum = 0;\n for (var i=0; i<data.length; i++) {\n if (data[i][0] == 1) {\n var sp,ep,sv,ev;\n if (data[i][1] > data[i][2]) {\n ep = data[i][1];\n sp = data[i][2];\n ev = data[i][3];\n sv = data[i][4];\n\n data[i][1] = sp;\n data[i][2] = ep;\n data[i][3] = sv;\n data[i][4] = ev;\n } else {\n sp = data[i][1];\n ep = data[i][2];\n sv = data[i][3];\n ev = data[i][4];\n }\n\n var a = (ev-sv)/(ep-sp);\n var bb = ev-a*ep;\n\n data[i][5] = a;\n data[i][6] = bb;\n }\n\n if (data[i][0] == 2 || data[i][0] == 3) {\n suparray[supnum] = i;\n supnum = supnum + 1;\n }\n }\n\n // Solving Support Force\n var amount = 0;\n for (var i=0; i<data.length; i++) {\n if (data[i][0] == 0) {\n amount = amount - data[i][2];\n } else if (data[i][0] == 1) {\n amount = amount - (data[i][3]+data[i][4])*(data[i][2]-data[i][1])/2;\n }\n }\n\n if (supnum <= 0) {\n document.getElementByID(\"Calc_Form\").style.display = \"none\";\n window.alert(\"No Support!!\");\n Back();\n return 0;\n } else if (supnum == 1) {\n data[suparray[0]][2] = amount;\n } else {\n var S = new Array(supnum);\n for (var i=0;i<supnum;i++) {\n S[i] = new Array(supnum);\n if (i == 0) {\n for (var k=0; k<supnum; k++) {\n S[i][k] = 1;\n }\n } else {\n for (var k=0; k<supnum; k++) {\n S[i][k] = 0;\n }\n }\n }\n\n for (var i=1; i<supnum; i++) {\n for (var k=0; k<supnum; k++) {\n if (i!=k) {\n S[i][k] = data[suparray[i]][1] - data[suparray[k]][1];\n }\n }\n }\n\n b = new Array(supnum);\n for (var i=0; i<supnum; i++) {\n b[i] = 0;\n }\n b[0] = amount;\n\n for (var i=1; i<supnum; i++) {\n for (var k=0; k<data.length; k++) {\n if (data[k][0] == 0) {\n b[i] = b[i] + (data[k][1]-data[suparray[i]][1])*data[k][2];\n }\n if (data[k][0] == 1) {\n b[i] = b[i] - data[k][5]/3*(2*Math.pow(data[suparray[i]][1],3)-Math.pow(data[k][2],3)-Math.pow(data[k][1],3)) - (data[k][6]-data[k][5]*data[suparray[i]][1])/2*(2*Math.pow(data[suparray[i]][1],2)-Math.pow(data[k][2],2)-Math.pow(data[k][1],2)) + data[k][6]*data[suparray[i]][1]*(2*data[suparray[i]][1]-data[k][2]-data[k][1]);\n }\n }\n }\n\n var check = 1;\n var j = supnum;\n do {\n if (j == 1) {\n data[suparray[0]][2] = 0;\n for (var i=0; i<data.length; i++) {\n if (data[i][0] == 0) {\n data[suparray[0]][2] = data[suparray[0]][2] - data[i][2];\n } else if (data[i][0] == 1) {\n data[suparray[0]][2] = data[suparray[0]][2] - (data[i][3]+data[i][4])*(Math.abs(data[i][1]-data[i][2]))/2;\n }\n }\n check = 0;\n } else {\n check = 0;\n var SF = Solver(S,b);\n for (var i=0; i<SF.length; i++) {\n if (isNaN(SF[i])) {\n djudge = 1;\n }\n }\n if (djudge > 0) {\n check = 0;\n } else {\n for (var i=0; i<j; i++) {\n if (SF[i] > 0 && data[suparray[i]][0] == 2) {\n data[suparray[i]][2] = 0;\n for (var k=0; k<j; k++) {\n S[k].splice(i,1);\n }\n S.splice(i,1);\n b.splice(i,1);\n suparray.splice(i,1);\n check = check + 1;\n j = j - 1;\n } else {\n data[suparray[i]][2] = SF[i];\n }\n }\n }\n }\n } while (check > 0);\n }\n Solve_SF();\n}", "function buyCharm() {\n if(charm.quantity < charm.maxQuantity) {\n if(zenny >= charm.price) {\n zenny -= charm.price;\n charm.quantity++;\n }\n }\n}", "function bomberMan(n, grid) {\n const r = grid.length,\n c = grid[0].length;\n let full = '';\n for(let i=0; i<c; i++) full += 'O';\n\n function detoantion(){\n const dy = [0,1,-1,0,0],\n dx = [0,0,0,1,-1];\n // detonation\n // for(let y=0; y<r; y++){\n for(let b of bombs){\n let y = b[0], x = b[1];\n // console.log('y : '+ y + 'x : ' + x + 'bomb : ', bombs[[y,x]])\n if(bombs[[y,x]] != 1){\n for(let d=0; d<5; d++){\n let ny = y + dy[d], nx = x + dx[d];\n if(ny < 0 || ny >= r || nx < 0 || nx >= c) continue;\n grid[ny] = grid[ny].substr(0,nx) + '.' + grid[ny].substr(nx+1);\n }\n }\n }\n // }\n bombs = [];\n }\n function fill(){\n for(let i=0; i<r; i++){\n for(let j =0; j<c; j++){\n if(grid[i][j] == 'O') bombs.push([i,j]);\n }\n grid[i] = full;\n }\n }\n let bombs = [];\n \n \n if(n <= 1) return grid // 0~1\n fill(); if(n % 2 == 0) return grid; // 2\n detoantion(); if(n==3) return grid; // 3\n let v2 = [].concat(grid);\n fill();\n detoantion();\n let v1 = [].concat(grid);\n if(n >5){ // 3~n\n if( (n+1) % 4 == 0 ) return v2;\n if( (n-1) % 4 == 0 ) return v1;\n }\n\n return grid;\n}", "function calcHtotal() {\n\t//* G00 (PRODUTO B)\n\t$('#matGPF' + pad(0))\n\t\t\t.html(mESQ[0][0]+'<br>'+mESQ[0][1]+'<br>'+mESQ[0][2]+'<br>'+mESQ[0][3])\n\t$('#matCUT' + pad(0))\n\t\t\t.html(mCOD1[0][0]+'<br>'+mCOD1[0][1]+'<br>'+mCOD1[0][2]+'<br>'+mCOD1[0][3])\n\n\t//* PRIMEIRA À PENÚLTIMA\n\tfor (let index = 1; index < nGavs; index++) {\n\t\tlet nGPF = pad(index)\n\t\tlet source = document.getElementById('rngG' + nGPF)\n\t\tlet j = 1 * index\n\t\ttry {\n\t\t\tmESQ[j][0][0] = parseInt(source.value, 10)\n\t\t\t$('#codGPF' + pad(index)).html(calcCOD(index))\n\t\t\t$('#matGPF' + pad(index))\n\t\t\t.html(mESQ[index][0]+'<br>'+mESQ[index][1]+'<br>'+mESQ[index][2]+'<br>'+mESQ[index][3])\n\t\t\t$('#matCUT' + pad(index))\n\t\t\t.html(mCOD1[index][0]+'<br>'+mCOD1[index][1]+'<br>'+mCOD1[index][2]+'<br>'+mCOD1[index][3])\n\t\t\t\n\t\t\t//> Código incompleto\n\t\t\tif (mESQ[index][1][0] == 0 || (mESQ[index][2][0] == 0 && mESQ[index][3][0] == 0)\n\t\t\t\t|| ((mESQ[index][2][1] == index && mESQ[index][2][2] == 0) &&\n\t\t\t\t\t(mESQ[index][3][1] == index && mESQ[index][3][2] == 0))) {\n\t\t\t\t$('#codGPF' + pad(index)).css('opacity', 0.1)\n\t\t\t} else {\n\t\t\t\t$('#codGPF' + pad(index)).css('opacity', 1)\n\t\t\t}\n\t\t} catch (error) { }\n\t}\n\t//* ÚLTIMA GAVETA\n\t\t//_ console.log('nGavs='+nGavs)\n\t\tmESQ[nGavs][0][0] = 32\n\t\t$('#codGPF' + pad(nGavs)).html(calcCOD(nGavs))\n\t\t$('#matGPF' + pad(nGavs))\n\t\t.html(mESQ[nGavs][0] + '<br>' + mESQ[nGavs][1] + '<br>' + mESQ[nGavs][2] + '<br>' + mESQ[nGavs][3])\n\t\t$('#matCUT' + pad(nGavs))\n\t\t.html(mCOD1[nGavs][0] + '<br>' + mCOD1[nGavs][1] + '<br>' + mCOD1[nGavs][2] + '<br>' + mCOD1[nGavs][3])\n\t\t//> Código incompleto\n\t\tif (mESQ[nGavs][1][0]==0 || (mESQ[nGavs][2][0]==0 && mESQ[nGavs][3][0]==0)) {\n\t\t\t$('#codGPF' + pad(nGavs)).css('opacity', 0.1)\n\t\t} else {\n\t\t\t$('#codGPF' + pad(nGavs)).css('opacity', 1)\n\t\t}\n\n\thTotal = 0\n\tfor (let index = 1; index <= nGavs; index++) {\n\t\thTotal = hTotal + 1 * parseInt(mESQ[index][0][0])\n\t\tif (mESQ[index][0][0]=== NaN) { $('#z-flow-clog').html(index) } \n\t}\n\t//_ let target = document.getElementById('hTotal')\n\t//_ target.innerHTML = '&nbsp' + hTotal + 'mm'\n\t$('#hTotal').html('&nbsp' + hTotal + 'mm');\n\n\t$('#divESQ').css({ 'height': 220 + yOff * nGavs + \"px\" })\n}", "function displayItems(chest)\r\n{\r\n\tvar t=document.getElementById(\"itemsTable\")\r\n\tvar wps=[]\r\n\tvar items=[]\r\n\tvar tempitems=[]\r\n\tvar itemsCount = {}\r\n\tvar totalVal=0\r\n\tvar totalWeight=0\r\n\tvar ic = 0\r\n\tfor (var i in chest)\r\n\t{\r\n\t\tif (chest[i].type===\"Melee Weapon\"\r\n\t\t || chest[i].type===\"Ranged Weapon\"\r\n\t\t || chest[i].type===\"Armor\")\r\n\t\t\twps.push(chest[i])\r\n\t\telse\r\n\t\t{\r\n\t\t\ttotalVal+=chest[i].val\r\n\t\t\ttotalWeight+=chest[i].weight\r\n\t\t\tif (itemsCount[chest[i].name])\r\n\t\t\t\titemsCount[chest[i].name]++\r\n\t\t\telse\r\n\t\t\t{\r\n\t\t\t\ttempitems.push(chest[i])\r\n\t\t\t\titemsCount[chest[i].name]=1\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\t\r\n\tfor (var i in tempitems)\r\n\t{\r\n\t\tif (itemsCount[tempitems[i].name]>1)\r\n\t\t{\r\n\t\t\ttempitems[i].weight = \"<b style=\\\"color:#C00\\\">\"+itemsCount[tempitems[i].name]*tempitems[i].weight +\"</b> <br>(\"+tempitems[i].weight+\")\"\r\n\t\t\ttempitems[i].val = \"<b style=\\\"color:#C00\\\">\"+itemsCount[tempitems[i].name]*tempitems[i].val +\"</b> <br>(\"+tempitems[i].val+\")\"\r\n\t\t\ttempitems[i].name = \"<b style=\\\"color:#C00\\\">\"+itemsCount[tempitems[i].name]+\"x</b> \"+tempitems[i].name\r\n\t\t}\r\n\t\titems.push(tempitems[i])\r\n\t}\r\n\t\r\n\t\r\n\tdisplayWeapons(wps, {total:true, colors:true})\r\n\t\r\n\tfor (var i in items)\r\n\t{\r\n\t\tvar tr=document.createElement(\"tr\")\r\n\t\tvar tdn = document.createElement(\"td\")\r\n\t\ttdn.innerHTML=items[i].name\r\n\t\ttdn.title = getItemHelpText(\"name\")\r\n\t\ttr.appendChild(tdn)\r\n\t\tvar tdt = document.createElement(\"td\")\r\n\t\ttdt.innerHTML=items[i].type\r\n\t\tif (items[i].type !== \"Gold\")\r\n\t\t\ttdt.style.backgroundColor = getLightRGBfromString(items[i].type+\"\")\r\n\t\telse\r\n\t\t\ttr.style.backgroundColor = \"#FFC\"\r\n\t\ttr.appendChild(tdt)\r\n\t\tvar tdc = document.createElement(\"td\")\r\n\t\tif (items[i].cat)\r\n\t\t{\r\n\t\t\ttdc.innerHTML=items[i].cat\r\n\t\t\ttdc.style.backgroundColor = getLightRGBfromString(items[i].cat+\"\")\r\n\t\t}\r\n\t\ttdc.title = getItemHelpText(\"cat\")\r\n\t\ttr.appendChild(tdc)\r\n\t\tvar tdu = document.createElement(\"td\")\r\n\t\tif (items[i].uses)\r\n\t\t\ttdu.innerHTML=items[i].uses\r\n\t\ttdu.style.textAlign=\"right\"\r\n\t\ttdu.title = getItemHelpText(\"uses\")\r\n\t\ttr.appendChild(tdu)\r\n\t\tvar tdw = document.createElement(\"td\")\r\n\t\ttdw.innerHTML=items[i].weight\r\n\t\ttdw.style.textAlign=\"right\"\r\n\t\ttdw.title = getItemHelpText(\"weight\")\r\n\t\ttr.appendChild(tdw)\r\n\t\tvar tdv = document.createElement(\"td\")\r\n\t\ttdv.innerHTML=items[i].val\r\n\t\ttdv.style.textAlign=\"right\"\r\n\t\ttdv.title = getItemHelpText(\"val\")\r\n\t\ttr.appendChild(tdv)\r\n\t\tvar tdd = document.createElement(\"td\")\r\n\t\ttdd.innerHTML=items[i].desc\r\n\t\ttdd.title = getItemHelpText(\"desc\")\r\n\t\ttr.appendChild(tdd)\r\n\t\tif (ic%2==0)\r\n\t\t\ttr.className=\"gray\"\r\n\t\tt.appendChild(tr)\r\n\t\tic++\r\n\t}\r\n\t\r\n\tif (ic===0)\r\n\t{\r\n\t\tvar tr=document.createElement(\"tr\")\r\n\t\tvar td = document.createElement(\"td\")\r\n\t\ttd.innerHTML=\"<i>No other items</i>\"\r\n\t\ttd.colSpan=7\r\n\t\ttr.appendChild(td)\r\n\t\ttr.className=\"gray\"\r\n\t\tt.appendChild(tr)\r\n\t\treturn\r\n\t}\r\n\t\r\n\t// total\r\n\tvar tr=document.createElement(\"tr\")\r\n\tvar tdt = document.createElement(\"td\")\r\n\ttdt.innerHTML=\"Total (items)\"\r\n\ttdt.colSpan=4\r\n\ttr.appendChild(tdt)\r\n\tvar tdw = document.createElement(\"td\")\r\n\ttdw.innerHTML=totalWeight\r\n\ttdw.id=\"totalItemsWeight\"\r\n\ttdw.style.textAlign=\"right\"\r\n\ttr.appendChild(tdw)\r\n\tvar tdv = document.createElement(\"td\")\r\n\ttdv.innerHTML=totalVal\r\n\ttdv.id=\"totalItemsVal\"\r\n\ttdv.style.textAlign=\"right\"\r\n\ttr.appendChild(tdv)\r\n\t//tr.appendChild(document.createElement(\"td\"))\r\n\ttr.style.backgroundColor=\"#DDF\"\r\n\ttr.style.fontWeight=\"bold\"\r\n\tt.appendChild(tr)\r\n\t\r\n\t\r\n\t// debug\r\n\tif (window.location.search.substr(1).indexOf(\"debug\") >=0)\r\n\t{\r\n\t\tdocument.getElementById(\"debug\").innerHTML=\"\"\r\n\t\tfor (var w in chest)\r\n\t\t{\r\n\t\t\tvar p = document.createElement('p')\r\n\t\t\tp.innerHTML=JSON.stringify(chest[w],2)\r\n\t\t\tdocument.getElementById(\"debug\").appendChild(p)\r\n\t\t}\r\n\t}\r\n}", "function multiplyThreeRestZebra(numA, numB, numC){\n let value = numA * numB * numC\n if (value % 3 === 0){\n //alert(\"ZEBRA\")\n return value\n }else return value\n}", "function checkCashRegister(price, cash, cid) {\n let cost = price;\n let givinCash = cash;\n let allCash = 0;\n for(let i = 0; i < cid.length; i++){\n allCash += cid[i][1];\n }\n allCash = allCash.toFixed(2);\n console.log(allCash);\n let fund = givinCash - cost;\n // First Condition: \n if(fund > allCash){\n return {\n status: \"INSUFFICIENT_FUNDS\",\n change: []\n }\n }\n let standard = [[\"PENNY\", 0.01], [\"NICKEL\", 0.05], [\"DIME\", 0.1], [\"QUARTER\", 0.25], [\"ONE\", 1], [\"FIVE\", 5], [\"TEN\", 10], [\"TWENTY\", 20], [\"ONE HUNDRED\", 100]];\n\n fund = fund.toFixed(2);\n console.log(fund);\n if(fund === allCash){\n return {\n status: \"CLOSED\",\n change: cid\n }\n }\nlet change = [];\n for(let x = 8; x >= 0; x--){\n if(fund > standard[x][1]){\n if(fund >= cid[x][1]){\n change.push([cid[x][0],cid[x][1]]);\n fund = (fund - cid[x][1]).toFixed(2);\n }else if(fund < cid[x][1]){\n let available = (fund - (fund % standard[x][1])).toFixed(2);\n fund = (fund % standard[x][1]).toFixed(2)\n console.log(fund);\n change.push([cid[x][0], parseFloat(available)]);\n }\n }\n }\n\n let finalCheck = 0;\n for(let j = 0; j < change.length; j++){\n finalCheck += change[j][1];\n }\n finalCheck = finalCheck.toFixed(2);\n fund = givinCash - cost;\n if(finalCheck != fund){\n return {\n status: \"INSUFFICIENT_FUNDS\",\n change: []\n }\n }\n return {\n status: \"OPEN\",\n change: change\n }\n\n}", "function getTotalBiomass(reef_fish_arr, c_timeStep, netlock_arr){\n\t\t\t\n\t\t\ttotal_biomass = reef_fish_arr.model[c_timeStep-1].total_biomass;\n\t\t\ttotal_bioRes = reef_fish_arr.model[c_timeStep-1].biomass_inside;\n\t\t\ttotalBiomass_data.push(total_biomass);\n\t\t\tbiomass_reserve_data.push(total_bioRes);\n\t\t\t//kg to metric tons\n\t\t\ttotal_bioRes = total_bioRes / 1000;\n\t\t\ttotal_biomass = total_biomass / 1000;\n\t\t\t\n\t\t\t// push data to data sets \n\t\t\tif(total_bioRes != 0){\n\t\t\t\treserveBio_perArea = total_bioRes / reserve_area;\n\t\t\t}else{\n\t\t\t\treserveBio_perArea = 0;\n\t\t\t}\n\t\t\treserveBiomass_perArea.push(reserveBio_perArea); \n\t\t\t\n\t\t\ttotal_biomass = total_biomass - total_bioRes;\n\t\t\t\n\t\t\tnon_reserve_bioMass.push(total_biomass);\n\t\t\t\n\t\t\tnonReserve_bioPerArea = total_biomass / reef_fish_area;\n\t\t\tnon_reserve_data_perArea.push(nonReserve_bioPerArea);\n\t\n\t}", "function calculate_value()\n{\n\tvar row_val = rowCount - 1;\n\tvar total_val = 0;\n\tfor (row of document.getElementById(\"abacus-bottom\").childNodes)\n\t{\n\t\tvar col_val = 0;\n\t\tfor(bead of row.childNodes)\n\t\t{\n\t\t\tif(bead.className.includes(\"grow-space\")) break;\n\t\t\tif(bead.className.includes(\"bead\")) col_val++;\n\t\t}\n\t\ttotal_val += col_val * Math.pow(10, row_val)\n\t\trow_val --;\n\t}\n\tvar row_val = rowCount - 1;\n\tfor (row of document.getElementById(\"abacus-top\").childNodes)\n\t{\n\t\tvar col_val = 2;\n\t\tfor(bead of row.childNodes)\n\t\t{\n\t\t\tif(bead.className.includes(\"grow-space\")) break;\n\t\t\tif(bead.className.includes(\"bead\")) col_val--;\n\t\t}\n\t\ttotal_val += col_val * Math.pow(10, row_val) * 5\n\t\trow_val --;\n\t}\n\treturn total_val;\n}", "function chairs(arr) {\n const arrLength = arr.length;\n const needChairs = arr[arrLength - 1];\n const roomsCount = arrLength - 1;\n let chairsHave = 0;\n let chairsTake = new Array();\n for(let i = 0; i < roomsCount; i++){\n if(chairsHave != needChairs){\n const peopleInRoom = arr[i][0].length;\n const chairsInRoom = arr[i][1];\n const availableChairs = chairsInRoom - peopleInRoom;\n if(availableChairs > 0){\n if((chairsHave + availableChairs) > needChairs){\n chairsTake.push(needChairs - chairsHave);\n chairsHave = needChairs;\n }\n else{\n chairsTake.push(availableChairs);\n chairsHave += availableChairs;\n }\n }\n else{\n chairsTake.push(0);\n }\n }\n else{\n break;\n }\n }\n chairsTake.join(', ');\n if(chairsHave < needChairs){\n document.getElementById('otvetChair').innerHTML = \"Порядок взятия стульев: \" + chairsTake;\n document.getElementById('otvetChairTwo').innerHTML = \"но стульев не хватило!\";\n }\n else{\n document.getElementById('otvetChair').innerHTML = \"Порядок взятия стульев: \" + chairsTake;\n document.getElementById('otvetChairTwo').innerHTML = \"Стульев достаточно!\";\n }\n}", "function getFiveCombo(flush, straight) {\n if (flush && straight) {\n if (flush == 'A') {\n return [10, 'A'];\n }\n else return [9, flush]\n }\n else if (flush) {\n return [6, flush]\n }\n else if (straight) {\n return [5, straight]\n }\n}", "function cappyJuice(input) {\n let data = input.slice(0);\n let factory = {};\n let bottles = {};\n data.forEach((row) => {\n let tokens = row.split(\" => \");\n let fruit = tokens[0];\n let quantity = +tokens[1];\n if(!factory.hasOwnProperty(fruit)) {\n factory[fruit] = 0;\n } \n factory[fruit] += quantity;\n \n if(factory[fruit] >= 1000) {\n bottles[fruit] = parseInt(factory[fruit] / 1000) ;\n }\n });\n Object.keys(bottles).forEach(bottle => {\n console.log(`${bottle} => ${bottles[bottle]}`);\n });\n}", "function calcPrice(part) {\n var markup,\n cost = part.costPrice,\n quantity = part.quantity,\n matrix = part.matrix;\n if (matrix === 'tire' || part.tire) {\n markup = 1.25;\n } else if (matrix === 'dealer' || part.dealer) {\n if (cost <= 1) {\n markup = 3.5;\n } else if (cost > 1 && cost <= 5) {\n markup = 3.25;\n } else if (cost > 5 && cost < 50) {\n markup = 2.25;\n } else if (cost > 50 && cost <= 100) {\n markup = 1.82;\n } else if (cost > 100 && cost <= 175) {\n markup = 1.67;\n } else {\n markup = 1.54;\n }\n } else {\n if (cost <= 5) {\n markup = 3.25;\n } else if (cost > 5 && cost <= 10) {\n markup = 2.5;\n } else if (cost > 10 && cost <= 75) {\n markup = 2.25;\n } else if (cost > 75 && cost <= 150) {\n markup = 2;\n } else if (cost > 150 && cost <= 750) {\n markup = 1.85;\n } else {\n markup = 1.54;\n }\n }\n return markup * cost * quantity;\n }", "function budgetCalculator(watch,phone,laptop){\n // Step.1 In case of unexpected input\n if(watchPrice<0 || phonePrice<0 || laptopPrice<0){\n return \"Quantity can not be negative\"\n }\n function fragmentedNumber(number) {\n return Number (number) === number && number % 1 !== 0; \n }\n if(fragmentedNumber(watch)==true || fragmentedNumber(phone)==true || fragmentedNumber(laptop)==true ) {\n return \" Insert a valid product quantity\";\n }\n // Step.2 calculation of price for each product\n var watchPrice = watch*50;\n var phonePrice = phone*100;\n var laptopPrice = laptop*500;\n\n // Step.3 total cost \n var totalCost = watchPrice + phonePrice + laptopPrice;\n\n \n return totalCost;\n\n }", "function main() {\n var n_temp = readLine().split(' ');\n var n = parseInt(n_temp[0]);\n var k = parseInt(n_temp[1]);\n c = readLine().split(' ');\n c = c.map(Number);\n \n let jumpCnt = n/k;\n let e = 100;\n let index = k;\n while (jumpCnt-->0) {\n if (c[index] == 0) {\n e -= 1;\n } else if (index == n) {\n if (c[0] == 0)\n e -= 1;\n else\n e -= 3;\n } else {\n e -= 3;\n }\n index += k;\n } \n console.log(e);\n}", "function Part2(input) {\n return countContents(input, find(input, \"shiny gold\"));\n\n function countContents(input, container) {\n return container.contents.reduce((acc, bag) => {\n let count = countContents(input, find(input, bag.color)) * bag.quantity;\n return acc + bag.quantity + count;\n }, 0);\n }\n}", "function Part1(input) {\n return (\n input.reduce((acc, container) => {\n let count = countBags(input, container, \"shiny gold\");\n return acc + (count > 0);\n }, 0) - 1\n );\n\n function countBags(input, container, searchColor) {\n return (\n container.color === searchColor ||\n container.contents.filter(innerBag =>\n countBags(input, find(input, innerBag.color), searchColor)\n ).length\n );\n }\n}", "function hotelCost(number){\n var sum = 0;\n if(number < 0){\n return \"empty array does not accepted any quary!\";\n }\n else{\n if(number <= 10){\n sum = number * 100;\n }\n else if(number <= 20){\n var firstTour = 10 * 100;\n var secondTour = 10 * 80;\n sum = firstTour + secondTour;\n } \n else{\n var firstTour = 10 * 100;\n var secondTour = 10 * 80;\n var remaining = number - 20;\n var thirdTour = remaining * 50;\n sum = firstTour + secondTour + thirdTour;\n } \n }\n return sum;\n}", "function CityCalc() {\n // the last is the discard pile\n this.deck = [];\n this.cdeck = [];\n this.Copy = function () {\n var cc = new CityCalc();\n cc.deck = this.deck.slice();\n cc.cdeck = this.cdeck.slice();\n return cc;\n };\n this.SingleEventOdds = function (event, times) {\n if (times < 0)\n return 0;\n // event = -1 means \"Epidemic\"\n if (event === -1) {\n if (times > 1)\n return 0;\n\t\t\t/* old Epidemic\n var odds = this.cdeck[0] / this.deck[0];*/\n\t\t\t// new Epidemic\n\t\t\tvar odds = 0;\n if (times === 1)\n return odds;\n else\n return 1 - odds;\n\t\t\treturn 0;\n }\n // event >= 0 means \"Draw event cards\"\n var l = this.deck.length - 2;\n if (event >= this.deck[l]) {\n // there is no enough cards to draw\n if (l === 0)\n return 0;\n var cc = this.Copy();\n cc.deck.splice(l, 1);\n cc.cdeck.splice(l, 1);\n return cc.SingleEventOdds(event - this.deck[l], times - this.cdeck[l]);\n }\n // at most this.cdeck[l] or event cards can be drawn\n if (times > this.cdeck[l] || times > event)\n return 0;\n // last simple case with binomial coefficients\n return binom.get(this.deck[l] - this.cdeck[l], event - times)\n * binom.get(this.cdeck[l], times)\n / binom.get(this.deck[l], event);\n };\n this.Change = function (event, times) {\n var l;\n if (times < 0)\n return -1; // error\n // event = -1 means \"Epidemic\"\n if (event === -1) {\n if (times > 1)\n return -1; // error\n if (this.cdeck[0] < times)\n return -1; // error\n \n\t\t\t/* old Epidemic\n this.deck[0] -= 1;\n this.cdeck[0] -= times;\n\t\t\t*/\n\t\t\t// new Epidemic\n\t\t\t/* nothing else */\n\t\t\t\n l = this.deck.length - 1;\n this.deck[l] += 1;\n this.cdeck[l] += times;\n this.deck.push(0);\n this.cdeck.push(0);\n return 0; // no error\n }\n // event >= 0 means \"Draw event cards\"\n l = this.deck.length - 2;\n if (event >= this.deck[l]) {\n var pcards = this.deck[l],\n ptimes = this.cdeck[l];\n this.deck[l+1] += this.deck[l];\n this.cdeck[l+1] += this.cdeck[l];\n this.deck.splice(l,1);\n this.cdeck.splice(l,1);\n return this.Change(event - pcards, times - ptimes);\n }\n if (times > this.cdeck[l] || times > event)\n return -1; // error\n \n this.deck[l+1] += event;\n this.cdeck[l+1] += times;\n this.deck[l] -= event;\n this.cdeck[l] -= times;\n return 0; // no error\n }\n this.ListEventsOdds = function (eventList, times) {\n var i,\n odds = 0,\n scc,\n sodds;\n // no events\n if (eventList.length === 0) {\n if (times === 0)\n return 1;\n return 0;\n }\n // single event\n if (eventList.length === 1)\n return this.SingleEventOdds(eventList[0], times);\n // more events, recursion\n for (i = 0; i <= times; i++) {\n sodds = this.SingleEventOdds(eventList[0], i);\n if (sodds > 0) {\n scc = this.Copy();\n if (scc.Change(eventList[0],i) != 0)\n continue;\n odds += sodds * scc.ListEventsOdds(eventList.slice(1, eventList.length), times - i);\n }\n }\n return odds;\n }\n}", "function getEffectiveWeight(helmet, chest, hand, feet) {\n\thelmet = parseFloat(helmet);\n\tchest = parseFloat(chest);\n\thand = parseFloat(hand);\n\tfeet = parseFloat(feet);\n\n\tvar eweight = Math.pow(Math.max(0, 2*helmet + chest + feet + 4*hand - 10), 1.12);\n\treturn eweight;\n}", "CubicHermite(A, B, C, D, t) {\n\n var a = -A / 2.0 + (3.0 * B) / 2.0 - (3.0 * C) / 2.0 + D / 2.0;\n var b = A - (5.0 * B) / 2.0 + 2.0 * C - D / 2.0;\n var c = -A / 2.0 + C / 2.0;\n var d = B;\n\n return a * t * t * t + b * t * t + c * t + d;\n }", "function buildTable(Str) {\n let str = Str;\n var table = function (str) {\n\n return table;\n\n }\n\n //using ASCII code build key and weight table\n this.buildKey = function (i) {\n \n var items = [];\n let num1 = i;\n for (var i = 0; i < 48; i ++) {\n items[i] = null;\n } \n\n for (var j = 48; j <= 122; j++) {\n items[j] = 0;\n }\n\n for(var k = 0; k < str.length; k++) {\n items[str.charCodeAt(k)] ++;\n }\n\n var table = new Array();\n for (var y = 0; y < 62; y++) {\n table[y] = new Array();\n for (var x = 0; x < 2; x++) {\n table[y][x] = \" \";\n }\n }\n\n let m = 0;\n for (var num = 48; num <= 122; num++) {\n if ((num >= 91 && num <= 96) || (num >= 58 && num <= 64))\n continue;\n let char = String.fromCharCode(num);\n \n table[m][0] = char;\n m ++;\n }\n m = 0;\n for (var num = 48; num <= 122; num++) {\n if ((num >= 91 && num <= 96) || (num >= 58 && num <= 64))\n continue;\n table[m][1] = items[num];\n m ++;\n }\n\n\n\n //sort\n table = sort(table);\n\n //console.log(table);\n\n var key = new Array();\n var weight = new Array();\n for (var i = 0; i < table.length; i ++) {\n key[i] = table[i][0];\n weight[i] = table[i][1];\n }\n //console.log(weight);\n\n while(weight[0] === 0) {\n key.shift();\n weight.shift();\n }\n //weight = weight.filter(v=>v!=' ');\n //console.log(key);\n if (num1 == 1)\n return key;\n else \n return weight;\n }\n\n this.buildWeight = function () {\n\n }\n}", "function checkCashRegister(price, cash, cid) {\n //all money values are multiplied by 100 to deal with precision errors involved with decimals\n const denomination = [10000, 2000, 1000, 500, 100, 25, 10, 5, 1];\n\n function transaction(price, cash, cid) {\n let changeNeeded = (cash - price) * 100;\n //money will be pushed to the second value in each array\n let moneyProvided = [\n [\"ONE HUNDRED\", 0],\n [\"TWENTY\", 0],\n [\"TEN\", 0],\n [\"FIVE\", 0],\n [\"ONE\", 0],\n [\"QUARTER\", 0],\n [\"DIME\", 0],\n [\"NICKEL\", 0],\n [\"PENNY\", 0],\n ];\n //take the cid, reverse it (like in Roman Numerals exercise), multiply values by 100\n let availCash = [...cid].reverse().map((el) => [el[0], el[1] * 100]);\n //get the total sum of all cash and divide by 100\n let sumOfCash = availCash.reduce((a, b) => a + b[1], 0) / 100;\n //if sumOfCash is exact change needed return\n if (sumOfCash === changeNeeded / 100) {\n return { status: \"CLOSED\", change: [...cid] };\n }\n //else, run this function\n else {\n for (let i = 0; i < availCash.length; i++) {\n //if denomination values are less than changeNeeded and availableCash values are greater than 0, run the while loop\n while (denomination[i] <= changeNeeded && availCash[i][1] > 0) {\n //1. moneyProvided array is increased by denomination value\n moneyProvided[i][1] += denomination[i];\n //2. changeNeeded is decreased by same denomination value\n changeNeeded -= denomination[i];\n //3. availCash is also decreased by same denomination value\n availCash[i][1] -= denomination[i];\n }\n }\n\n //clean up the moneyProvided array by\n let change = moneyProvided\n //1. resetting the money values by dividing by 100\n .map((el) => [el[0], el[1] / 100])\n //2. filtering out all non-empty dollar and value arrays\n .filter((el) => el[1] !== 0);\n //calculate the total of the change array\n let changeTotal = change.reduce((a, b) => a + b[1], 0);\n //if the total change is less than the change needed\n if (changeTotal < changeNeeded) {\n return { status: \"INSUFFICIENT_FUNDS\", change: [] };\n }\n return { status: \"OPEN\", change };\n }\n }\n\n //this is where the transaction function is called\n let answer = transaction(price, cash, cid);\n //here the final answer is provided if the 2 if statements don't catch it first\n console.log(answer);\n}", "function lettersSCalc(weight) {\n\n var result;\n\n if(weight <= 1) {\n return result = 0.49;\n }\n else if (weight <= 2) {\n return result = 0.70;\n }\n else if (weight <= 3) {\n return result = 0.91;\n }\n else if (weight <= 3.5) {\n return result = 1.12;\n }\n else {\n return result = -1;\n }\n}", "function triangle(row) {\n\t// first need to check if length is mod 3 = 0 \n\t// this is to ensure that the solution can work for it.\n\t// will need a seperate solution for less than 3.\n\t// once lenght is 2, do a normal solve.\n\n\tvar MAX_N_LOG_3 = 11;\n\tvar sum = 0;\n\tvar n = row.length;\n\t\n // calculate digits of n - 1\n var dig_n = [MAX_N_LOG_3];\n var len_n = conv_base_3(n - 1, MAX_N_LOG_3, dig_n);\n\n\tif (n == 1)\n\t\treturn row[0];\n\t\n\tfor (var km1 = 0; km1 < n; km1++){\n // calculate digits of k - 1\n\t\tvar dig_k = [MAX_N_LOG_3];\n\t\tvar len_k = conv_base_3(km1, MAX_N_LOG_3, dig_k);\n\t\t\n // calculate C(n - 1, k - 1) mod 3\n var Cnk_mod3 = lucas_3(len_n, dig_n, len_k, dig_k);\n\n // add using the modulo rule\n sum = (sum + Cnk_mod3 * strToNum(input[km1])) % 3;\n\t}\n\t\n // value of (-1) ** (n - 1)\n // (no need for pow; just need to know if n is odd or even)\n var sign = (n % 2) * 2 - 1;\n\n // for negative numbers, must resolve the difference\n // between C's % operator and mathematical mod\n var sum_mod3 = (3 + (sign * (sum % 3))) % 3;\n return numToStr(sum_mod3);\n\n}", "function brickCalculator (floor) {\n let perFeetBrick = 1000;\n let upperFloorFeet = 10;\n let middleFloodFeet = 12;\n let lowerFloorFeet = 15;\n\n if (floor < 0){\n console.log(\"floor can not be in negative\");\n\n }else if (floor > 20) {\n upperFloor = floor - 20;\n\n upperFloorBrick = upperFloor * upperFloorFeet * perFeetBrick;\n\n middleFloor = floor - upperFloor - 10;\n\n middleFloorBrick = middleFloor * middleFloodFeet * perFeetBrick;\n\n lowerFloor = middleFloor;\n\n lowerFloorBrick = lowerFloor * lowerFloorFeet * perFeetBrick;\n\n return totalBrick = upperFloorBrick + middleFloorBrick + lowerFloorBrick; \n\n }else if (floor <= 20 && floor > 10){\n middleFloor = floor - 10;\n\n middleFloorBrick = middleFloor * middleFloodFeet * perFeetBrick;\n\n lowerFloor = floor - middleFloor;\n\n lowerFloorBrick = lowerFloor * lowerFloorFeet * perFeetBrick;\n\n return total = middleFloorBrick + lowerFloorBrick;\n\n }else if (floor <= 10) {\n lowerFloor = floor;\n\n return lowerFloor * lowerFloorFeet * perFeetBrick;\n\n }\n}", "function findWather(array) {\n\n var max_one = array[0],\n index_one = 0,\n max_two = array[array.length-1],\n index_two = 0,\n count = 0,\n water_one = 0,\n water_two = 0,\n water = 0;\n\n\n do{\n\n for (var i = 0; i < array.length; i++) {\n if (array[i] >= max_one) {\n water += max_one * index_one - water_one;\n water_one = 0;\n index_one = 0;\n max_one = array[i];\n console.log(max_one);\n } else {\n water_one += array[i];\n index_one += 1;\n }\n }\n\n\n for ( i = array.length-1; i >= 0; i--) {\n if (array[i] > max_two) {\n water += max_two * index_two - water_two;\n water_two = 0;\n index_two = 0;\n max_two = array[i];\n console.log(max_two)\n } else {\n water_two += array[i];\n index_two +=1;\n }\n }\n\n if (max_one === max_two) {\n index_two = array.length;\n continue;\n }\n\n} while (index_two < array.length);\n console.log('water = ', water);\n}", "function budgetCalculator(watch, phone, laptop){\n // cost every single item\n var watchCost = watch * 50;\n var phoneCost = phone * 100;\n var laptopCost = laptop * 500;\n //total cost of all item.\n var totalCost = watchCost + phoneCost + laptopCost;\n return totalCost;\n\n}", "function brickCalculator(numberOfFloor){\n const brickForPerFeet =1000;\n let totalBrick;\n\n if(numberOfFloor>0 && numberOfFloor<11){\n return totalBrick = numberOfFloor * 15 *1000;\n }\n else if(numberOfFloor>10 && numberOfFloor<21){\n return totalBrick = numberOfFloor * 12 *1000;\n }\n else if(numberOfFloor>20){\n return totalBrick = numberOfFloor * 10 *1000;\n }\n else {\n return \"Yor input data is not valid to calculate brick !!!\";\n } \n return totalBrick;\n}" ]
[ "0.72120124", "0.69677794", "0.68666846", "0.68131447", "0.6808526", "0.6754234", "0.67305523", "0.6717835", "0.6714915", "0.6701545", "0.66820085", "0.6668046", "0.66452867", "0.66440207", "0.6642435", "0.6640691", "0.66372585", "0.66076785", "0.660246", "0.6592661", "0.6572986", "0.65564835", "0.6528423", "0.65260863", "0.6472905", "0.6465849", "0.63912207", "0.63291687", "0.63144475", "0.6313644", "0.6243559", "0.61966205", "0.5830724", "0.57693446", "0.57322454", "0.5706138", "0.56942546", "0.569237", "0.556498", "0.55420196", "0.55361056", "0.55048627", "0.55020523", "0.54743785", "0.54429406", "0.5390629", "0.53656906", "0.5353789", "0.53534645", "0.5334099", "0.53328705", "0.5284855", "0.5280626", "0.5278875", "0.52720755", "0.5247253", "0.52380556", "0.5237125", "0.52337444", "0.52333546", "0.5228622", "0.5225299", "0.522432", "0.5218781", "0.52130806", "0.52122074", "0.5210183", "0.52056915", "0.5203487", "0.51874554", "0.5186388", "0.51843286", "0.5181031", "0.5179917", "0.51788986", "0.5161927", "0.5158888", "0.51576257", "0.5155027", "0.51546985", "0.5150432", "0.51487345", "0.5140889", "0.514026", "0.5133933", "0.51281506", "0.51266044", "0.51250386", "0.5116557", "0.51120996", "0.51075536", "0.5105033", "0.51036316", "0.50989157", "0.5093017", "0.5092169", "0.5091868", "0.5090078", "0.50887233", "0.5087049" ]
0.69362503
2
function for calculating bricks needed to build a multi store building. hight of first ten floor is 15 feet, next 10 floor is 12 feet and after that is 10 feet. bricks neede to build per feet is 1000.
function brickCalculator(floorCount) { //first condition to check if the bulding is more than 20 floors and then calculate needed bricks. for first 20 floor needed bricks are pre-defined. if(floorCount>20) { var excess = floorCount - 20; var feetCount = excess*10; var totalFeet = feetCount + (10*12) + (10*15); var neededBricks = totalFeet*1000; } //second condition to check if the building is more than 10 floors but less than or equal 20 floors. For first 10 floors needed bricks are pre-defined. else if(floorCount>10 && floorCount<=20) { var excess = floorCount - 10; var feetCount = excess*12; var totalFeet = feetCount + (10*15); var neededBricks = totalFeet*1000; } //third condition to check if the bulding is less than or equal 10 floors. else if(floorCount>0 && floorCount<=10) { var feetCount = floorCount*15; var neededBricks = feetCount*1000; } //if input is invalid necessary warnings are given. else { return "Floor can not be negative or you do not need any bricks"; } return neededBricks; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function brickCalculator(numOfFloor){\n const brickPerFeet = 1000;\n var totalAmountOfBricks=0;\n for(var floorNo=1; floorNo<=numOfFloor; floorNo++){\n if(floorNo<=10){\n var j=0;\n j++;\n totalAmountOfBricks = totalAmountOfBricks + (j * (15 * brickPerFeet));\n }\n else if(floorNo<=20){\n var k=0;\n k++;\n totalAmountOfBricks = totalAmountOfBricks + (k * (12 * brickPerFeet));\n }\n else{\n var l=0;\n l++;\n totalAmountOfBricks = totalAmountOfBricks + (l * (10 * brickPerFeet));\n }\n }\n return totalAmountOfBricks;\n}", "function brickCalculator(floor) {\n var bricks;\n if(floor<=10)\n bricks = 1000*15*floor; // 1-10 floors are 15feet and each feet needed 1000 bricks,\n else if(floor>=11&&floor<=20)\n bricks = 1000*12*floor; // 11-20 floors are 12feet and each feet needed 1000 bricks,\n else\n bricks = 1000*10*floor; // more than 20 floors are 10feet and as always its also needed 1000 bricks\n return bricks //returns total bricks;\n}", "function brickCalculator(numOfFloor) {\n let n = Math.abs(parseInt(numOfFloor));\n const perFloor_1to10 = 15000;\n const perFloor_11to20 = 12000;\n const perFloor_21above = 10000;\n\n if (n > 0 && n <= 10) {\n let totalBrick = perFloor_1to10 * n;\n return totalBrick;\n } else if (n > 10 && n <= 20) {\n let totalBrick = n - 10;\n totalBrick = totalBrick * perFloor_11to20 + perFloor_1to10 * 10;\n return totalBrick;\n } else {\n let totalBrick = n - 20;\n totalBrick =\n totalBrick * perFloor_21above +\n perFloor_11to20 * 10 +\n perFloor_1to10 * 10;\n return totalBrick;\n }\n}", "function brickCalculator(floor){ \n var numOfBricks = 0; \n for (var i = 1; i <= floor; i++) {\n if (i <= 10) {\n numOfBricks = numOfBricks + 1500;\n \n} else if (i <= 20 && i > 10 ) {\n numOfBricks = numOfBricks + 1200;\n \n} else \n numOfBricks = numOfBricks + 1000;\n\n}\n return numOfBricks;\n}", "function brickCalculator(numOfFloor) {\n\tlet oneToTenth = 10 * 15;\n\tlet tenToTwentieth = 10 * 12;\n\tlet restOfFloors = 0;\n\n\tlet totalFeet = 0;\n\tlet totalBrick = 0;\n\n\tif (numOfFloor > 20) {\n\t\trestOfFloors = (numOfFloor - 20) * 10;\n\t\ttotalFeet = oneToTenth + tenToTwentieth + restOfFloors;\n\t} else {\n\t\tif (numOfFloor > 10) {\n\t\t\trestOfFloors = (numOfFloor - 10) * 12;\n\t\t\ttotalFeet = oneToTenth + restOfFloors;\n\t\t} else {\n\t\t\ttotalFeet = numOfFloor * 15;\n\t\t}\n\t}\n\n\ttotalBrick = totalFeet * 1000;\n\treturn `🏠 Brick needed = ${totalBrick}`;\n}", "function brickCalculator(floor){\n var countBrick = 0;\n if (floor <=10){\n countBrick = floor * 15 * 1000;\n \n }\n else if( floor <=20){\n var firstPart = 10 * 15 * 1000;\n var remaining = floor - 10;\n var secondPart = remaining * 12;\n countBrick = firstPart + secondPart;\n\n }\n else {\n var firstPart = 10 * 15 * 1000;\n var secondPart = 10 * 12 * 1000;\n var remaining = floor - 20;\n var thirdPart = remaining * 10;\n countBrick = firstPart + secondPart + thirdPart;\n }\n return countBrick;\n}", "function brickCalculator (floor) {\n let perFeetBrick = 1000;\n let upperFloorFeet = 10;\n let middleFloodFeet = 12;\n let lowerFloorFeet = 15;\n\n if (floor < 0){\n console.log(\"floor can not be in negative\");\n\n }else if (floor > 20) {\n upperFloor = floor - 20;\n\n upperFloorBrick = upperFloor * upperFloorFeet * perFeetBrick;\n\n middleFloor = floor - upperFloor - 10;\n\n middleFloorBrick = middleFloor * middleFloodFeet * perFeetBrick;\n\n lowerFloor = middleFloor;\n\n lowerFloorBrick = lowerFloor * lowerFloorFeet * perFeetBrick;\n\n return totalBrick = upperFloorBrick + middleFloorBrick + lowerFloorBrick; \n\n }else if (floor <= 20 && floor > 10){\n middleFloor = floor - 10;\n\n middleFloorBrick = middleFloor * middleFloodFeet * perFeetBrick;\n\n lowerFloor = floor - middleFloor;\n\n lowerFloorBrick = lowerFloor * lowerFloorFeet * perFeetBrick;\n\n return total = middleFloorBrick + lowerFloorBrick;\n\n }else if (floor <= 10) {\n lowerFloor = floor;\n\n return lowerFloor * lowerFloorFeet * perFeetBrick;\n\n }\n}", "function brickCalculator(floor) {\n\t// If the floor input is negative and not number, then return error message\n\tif (floor < 0 || typeof floor != \"number\") {\n\t\treturn \"Floor cannot be negative and must be a number\";\n\t}\n\n\tvar totalBricks = 0;\n\n\tfor (var i = 1; i <= floor; i++) {\n\t\tif (i <= 10) {\n\t\t\ttotalBricks = totalBricks + 15 * 1000;\n\t\t} else if (i > 10 && i <= 20) {\n\t\t\ttotalBricks = totalBricks + 12 * 1000;\n\t\t} else {\n\t\t\ttotalBricks = totalBricks + 10 * 1000;\n\t\t}\n\t}\n\treturn totalBricks;\n}", "function brickCalculator(brickAmount) {\n var brick = 0;\n var everyFloorNeededBrick = 1000;\n if (brickAmount <= 10) {\n brick = brickAmount * 15 * everyFloorNeededBrick;\n }\n else if (brickAmount <= 20) {\n var first10Floor = 10 * 15 * everyFloorNeededBrick;\n var remainingFloor = brickAmount - 10;\n var secound10Floor = remainingFloor * 12 * everyFloorNeededBrick;\n brick = first10Floor + secound10Floor;\n }\n else {\n var first10Floor = 10 * 15 * everyFloorNeededBrick;\n var secound10Floor = 10 * 12 * everyFloorNeededBrick;\n var remainingFloor = brickAmount - 20;\n var third10Floor = remainingFloor * 10 * everyFloorNeededBrick;\n brick = first10Floor + secound10Floor + third10Floor;\n }\n return brick;\n}", "function brickCalculator(storey){\n\n var totalBrick, brickForTenStorey, brickForTwentyStorey;\n\n //for 1 feet, need 1000 brick.\n\n //for 1-10 storey, 15 feet needed for per storey.\n if(storey <= 10){\n totalBrick = storey * 15 * 1000;\n }\n\n //for 11-20 storey, 12 feet needed for per storey.\n else if(storey >10 && storey <= 20){\n brickForTenStorey = 10 * 15 * 1000;\n totalBrick = (storey-10) * 12 * 1000 + brickForTenStorey;\n }\n \n //for more than 20 storey, 10 feet needed for per storey.\n else{\n brickForTenStorey = 10 * 15 * 1000;\n brickForTwentyStorey = (20-10) * 12 * 1000 + brickForTenStorey;\n totalBrick = (storey-20) * 10 * 1000 + brickForTwentyStorey;\n }\n\n return totalBrick;\n}", "function brickCalculator(numberOfFloor) {\n if (numberOfFloor < 0) {\n return \"Enter a positive value.\";\n } else if (numberOfFloor <= 10) {\n var totalBrick = numberOfFloor * 15 * 1000;\n } else if (numberOfFloor <= 20) {\n var totalBrick = ((numberOfFloor - 10) * 12 * 1000) + (10 * 15 * 1000);\n } else if (numberOfFloor > 20) {\n var totalBrick = ((numberOfFloor - 20) * 10 * 1000) + (10 * 12 * 1000) + (10 * 15 * 1000);\n }\n return totalBrick;\n}", "function brickCalculator(numberOfFloor){\n const brickForPerFeet =1000;\n let totalBrick;\n\n if(numberOfFloor>0 && numberOfFloor<11){\n return totalBrick = numberOfFloor * 15 *1000;\n }\n else if(numberOfFloor>10 && numberOfFloor<21){\n return totalBrick = numberOfFloor * 12 *1000;\n }\n else if(numberOfFloor>20){\n return totalBrick = numberOfFloor * 10 *1000;\n }\n else {\n return \"Yor input data is not valid to calculate brick !!!\";\n } \n return totalBrick;\n}", "function brickCalculator(floor){\n // for every feet brick needed = 1000\n // less than or equal to ten, floor = 15 feet\n // greater than ten and less or equal to twenty, floor = 12 feet\n // greater than twenty, floor = 10feet\n const invalidMassege = \"Please input a valid number\"\n const firtstRange = 10*15*1000;\n const secondRange = 10*12*1000;\n // according to conditons, gives them their suitable value\n const oneToTen = `Total bricks required: ${floor*15*1000}`;\n const oneToTwenty = `Total bricks required: ${firtstRange + (floor-10)*12*1000}`;\n const aboveTwenty = `Total bricks required: ${firtstRange + secondRange + (floor-20)*10*1000}`;\n \n if(floor <= 0){\n return invalidMassege;\n }\n else if(floor <= 10){\n return oneToTen;\n }\n else if(floor <= 20){\n return elevenToTwenty;\n }\n else{\n return aboveTwenty;\n }\n }", "function brickCalculator(n){\n var floors = n;\n\n if( floors < 0){\n var warning = \"number of floors can not be negative\";\n return warning;\n }\n\n if(floors <= 10){\n var bricks = n * 15000;\n return bricks;\n } \n if( floors > 10 && floors <= 20 ){\n var bricks = 150000 + ((n-10) * 12000);\n return bricks;\n }\n \n if(floors > 20){\n var bricks = 270000 + ((n-20) * 10000);\n return bricks;\n\n }\n \n \n }", "function brickCalculator(floorCount) {\n\n var bricksPerFloor = floorCount * 1000;\n var floorLength;\n\n if(floorCount >= 0 && floorCount <= 10) {\n floorLength = bricksPerFloor * 15;\n }\n else if(floorCount > 10 && floorCount <= 20) {\n floorLength = (bricksPerFloor * 12) + 30000;\n }\n else if(floorCount > 20) {\n floorLength = (bricksPerFloor * 10) + 70000;\n }\n else {\n console.log('Error: Physical quantities can never be negative.')\n }\n return floorLength;\n \n}", "function brickCalculator(floor) {\n let bricks = 0;\n if (floor < 0) {\n const errorMsg =\n \"Invalid Floor Input.Please check your floor input and try again.Thank You\";\n return errorMsg;\n } else if (floor <= 10) {\n bricks = floor * (15 * 1000);\n return bricks;\n } else if (floor >= 11 && floor <= 20) {\n floor -= 10;\n bricks = 10 * (15 * 1000) + floor * (12 * 1000);\n return bricks;\n } else {\n floor -= 20;\n bricks = 10 * (15 * 1000) + 10 * (12 * 1000) + floor * (10 * 1000);\n return bricks;\n }\n}", "function brickCalculator(numberOfFloor) {\n if(numberOfFloor<=0){\n console.log(\"Negative value is not accepted! \")\n return \"Invalid!\"\n }\n else if (1 <= numberOfFloor && numberOfFloor <= 10) {\n var floorBricks1 = 15 * 1000;\n var brickAmount1 = (numberOfFloor * floorBricks1);\n return brickAmount1;\n }\n else if (11 <= numberOfFloor && numberOfFloor <= 20) {\n var floorBricks2 = 12 * 1000;\n var secondPart = ((numberOfFloor - 10) * floorBricks2);\n var brickAmount2 = (150000 + secondPart);\n return brickAmount2;\n }\n else if (numberOfFloor >= 21) {\n var floorBricks3 = 10 * 1000;\n var thirdPart = ((numberOfFloor - 20) * floorBricks3);\n var brickAmount3 = (150000 + 120000 + thirdPart);\n return brickAmount3;\n }\n}", "function brickCalculator(floor){\n const brickPerFeet = 1000;\n\n if (floor < 0) {\n return \"Please Provide Valid Number\";\n }else if (floor <=10 ){\n let feetPerFloor = 15;\n\n const totalFeet = feetPerFloor * floor;\n return totalBrick = brickPerFeet * totalFeet;\n\n }else if(floor > 10 && floor <= 20){\n let feetPerFloor = 12;\n\n const totalFeet = feetPerFloor * (floor - 10);\n return totalBrick = brickPerFeet * totalFeet + 150000;\n }else{\n let feetPerFloor = 10;\n\n const totalFeet = feetPerFloor * (floor - 20);\n return totalBrick = brickPerFeet * totalFeet + 270000;\n }\n\n}", "function brickCalculator(floor) {\n var brick;\n if (floor >= 1 && floor <= 10) {\n brick = floor * 15000;\n return brick;\n }\n else if (floor >= 11 && floor <= 20) {\n floor = floor - 10;\n brick = 150000 + (floor * 12000);\n\n return brick;\n }\n else {\n\n\n floor = floor - 20;\n brick = 270000 + (floor * 10000);\n\n return brick;\n }\n\n}", "function brickCalculator(floor){\n var floorAbsolute = Math.abs(floor);\n if(floorAbsolute != floor){\n return \"please enter your valid floor number\";\n }\n else if(floor<=10){\n var smallBuildingFeet = floor * 15;\n var totalBrickForSmall = smallBuildingFeet * 1000;\n return totalBrickForSmall;\n }\n else if(floor>=11 && floor<=20){\n var topFloor = floor - 10;\n var belowTenFloor = floor - topFloor;\n var mediumBuildingFeet = belowTenFloor * 15 + topFloor * 12;\n var totalBrickForMedium = mediumBuildingFeet * 1000;\n return totalBrickForMedium;\n }\n else{\n var buildingTop = floor - 20;\n var buildingMiddle = 10;\n var buildingBottom = 10;\n var highBuildingFeet = buildingBottom * 15 + buildingMiddle * 12 + buildingTop * 10; \n var totalBrickForHigh = highBuildingFeet * 1000;\n return totalBrickForHigh;\n }\n}", "function brickCalculator(floor) {\n var feet = 1000;\n var feet15 = feet * 15;\n var feet12 = feet * 12;\n var feet10 = feet * 10;\n // var total = feet15 + feet12 + feet10;\n return total;\n}", "function brickCalculator (floor){\n\n if( floor <= 10){\n var brick = 15 * floor * 1000;\n }\n \n else if (floor>10 && floor <= 20){\n var brick = floor * 12 * 1000;\n }\n \n else if ( floor > 20) {\n var brick = 10 * floor * 1000;\n }\n return brick\n }", "function brickCalulator (floors) {\n if(floors < 0) {\n return \"haha! you cannot make me fool...Underground floors are not invented yet:3 Give the correct input.\"\n }\n else {\n var heightTo10th = 0;\n var heightFrom10To20th = 0;\n var heightFrom20ToUp = 0;\n for(var i = 0; i <= floors; i++) {\n // to determine the height from 0 to 10th floor.\n if(i <= 10) {\n heightTo10th = i * 15;\n }\n // to determine the height from 10 to 20th floor.\n if(i <= 20 && i > 10) { \n heightFrom10To20th = (i-10) * 12;\n }\n // to determine the height from 20th to upper floor.\n if(i > 20) {\n heightFrom20ToUp = (i-20) * 10;\n }\n }\n var totalHeight = heightTo10th + heightFrom10To20th + heightFrom20ToUp;\n var brickNeeded = totalHeight * 1000;\n return \"You need \"+ brickNeeded+ \" pcs of brick\";\n }\n}", "function brickCalculator(floor){\n \n if(floor != Math.ceil(floor) || floor < 1)\n {\n return(\"Input cannot be a fructional number or less than 1!!!\");\n }\n else{\n var brickNeed;\n\n if(floor <= 10){\n brickNeed = floor * 15 * 15000;\n return brickNeed;\n }\n\n else if(floor <= 20){\n brickNeed = (floor - 10) * 12 *15000;\n floor = 10;\n }\n\n else{\n brickNeed = (floor - 20) * 10* 15000;\n floor = 20;\n }\n\n return brickNeed + brickCalculator(floor);\n }\n \n}", "function brickCalculation(a) {\r\n let perFeet = 1000;\r\n if (a <= 10) {\r\n result = a * 15 * perFeet;\r\n console.log(result);\r\n }\r\n else if(a > 10 && a <= 20){\r\n needbrickupto10 = 10 * 15 * perFeet;\r\n extraFloor = a - 20;\r\n extraBrick = extraFloor * 12 * perFeet;\r\n result = needbrickupto10 + extraBrick;\r\n console.log(result);\r\n\r\n }\r\n else if(a>20) {\r\n needbrickupto10 = 10 * 15 * perFeet;\r\n needBrickupto20 = 10 * 12 * perFeet;\r\n extraFloor = a - 20;\r\n extraBrick = extraFloor * 10 * perFeet;\r\n result = needbrickupto10 + needBrickupto20 + extraBrick;\r\n console.log(result);\r\n\r\n }\r\n else {\r\n console.log('Sorry, Input correct data');\r\n }\r\n\r\n\r\n}", "function brickCalculator (storied) {\n \n if (storied <= 10){\n\n var feet1 = storied * 15;\n \n var brick = feet1 * 1000;\n\n return brick;\n \n }\n\n else if (storied >10 && storied <= 20){\n\n var brick = (10 * 15 * 1000) + (storied - 10) * 12 * 1000;\n\n return brick;\n\n }\n\n else if (storied > 20) { \n\n var brick = (10 * 15 * 1000) + (10 * 12 * 1000) + (storied - 20) * 10 * 1000;\n\n return brick;\n\n }\n\n\n}", "function create_bricks() {\n\tif(level==0) {\n\t\tfor(i = 0; i < 32; i++) {\n\t\t\tif(i < 8) {\n\t\t\t\tplace1 = 0;\n\t\t\t\tplace2 = i;\n\t\t\t\thp = 4;\n\t\t\t}\n\t\t\telse if(i < 16) {\n\t\t\t\tplace1 = 1;\n\t\t\t\tplace2 = i-8;\n\t\t\t\thp = 3;\n\t\t\t}\n\t\t\telse if(i < 24) {\n\t\t\t\tplace1 = 2;\n\t\t\t\tplace2 = i-16;\n\t\t\t\thp = 2;\n\t\t\t}\n\t\t\telse if(i < 32) {\n\t\t\t\tplace1 = 3;\n\t\t\t\tplace2 = i-24;\n\t\t\t\thp = 1;\n\t\t\t}\n\t\t\tbricks[bricks.length] = new brick(place2*100+25, 50+(25*place1), 50, 5, hp);\n\t\t\tbricks_left += 1;\n\t\t}\n\t}\n\telse if(level==1) {\n\t\tfor(i = 0; i < 6; i++) {\n\t\t\tbricks[bricks.length] = new brick(i*100+125, 50, 50, 5, 4);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 16; i++) {\n\t\t\tbricks[bricks.length] = new brick(i*50+25, 100, 5, 50, 3);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 8; i++) {\n\t\t\tbricks[bricks.length] = new brick(i*100+25, 200, 50, 5, 2);\n\t\t\tbricks_left += 1;\n\t\t}\n\t}\n\telse if(level==2) {\n\t\tfor(i = 0; i < 1; i++) {\n\t\t\tbricks[bricks.length] = new brick(375, 25, 50, 5, 4);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 2; i++) {\n\t\t\tbricks[bricks.length] = new brick(i*100+325, 50, 50, 5, 4);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 3; i++) {\n\t\t\tbricks[bricks.length] = new brick(i*100+275, 75, 50, 5, 3);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 4; i++) {\n\t\t\tbricks[bricks.length] = new brick(i*100+225, 100, 50, 5, 3);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 5; i++) {\n\t\t\tbricks[bricks.length] = new brick(i*100+175, 125, 50, 5, 2);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 6; i++) {\n\t\t\tbricks[bricks.length] = new brick(i*100+125, 150, 50, 5, 2);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 7; i++) {\n\t\t\tbricks[bricks.length] = new brick(i*100+75, 175, 50, 5, 1);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 8; i++) {\n\t\t\tbricks[bricks.length] = new brick(i*100+25, 200, 50, 5, 1);\n\t\t\tbricks_left += 1;\n\t\t}\n\t}\n\telse if(level==3) {\n\t\tfor(i = 0; i < 1; i++) {\n\t\t\tbricks[bricks.length] = new brick(75, 50, 100, 5, 4);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 1; i++) {\n\t\t\tbricks[bricks.length] = new brick(75, 50, 5, 200, 2);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 1; i++) {\n\t\t\tbricks[bricks.length] = new brick(175, 50, 5, 200, 2);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 1; i++) {\n\t\t\tbricks[bricks.length] = new brick(75, 150, 105, 5, 3);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 1; i++) {\n\t\t\tbricks[bricks.length] = new brick(225, 50, 100, 5, 4);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 1; i++) {\n\t\t\tbricks[bricks.length] = new brick(275, 50, 5, 200, 2);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 1; i++) {\n\t\t\tbricks[bricks.length] = new brick(350, 50, 100, 5, 4);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 1; i++) {\n\t\t\tbricks[bricks.length] = new brick(350, 50, 5, 200, 3);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 1; i++) {\n\t\t\tbricks[bricks.length] = new brick(450, 50, 5, 200, 3);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 1; i++) {\n\t\t\tbricks[bricks.length] = new brick(350, 150, 105, 5, 2);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 1; i++) {\n\t\t\tbricks[bricks.length] = new brick(500, 50, 100, 5, 4);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 1; i++) {\n\t\t\tbricks[bricks.length] = new brick(500, 50, 5, 200, 3);\n\t\t\tbricks_left += 1;\n\t\t}\n\t\tfor(i = 0; i < 1; i++) {\n\t\t\tbricks[bricks.length] = new brick(675, 50, 5, 200, 1);\n\t\t\tbricks_left += 1;\n\t\t}\n\t}\n}", "function brickCalculator(storedBuilding){\n if(storedBuilding <= 10 && storedBuilding > 0){\n var brick = storedBuilding*15*1000;\n return \"Total Brick required:\" + \" \" + brick + \" \" + \"Pcs\";\n }\n else if(storedBuilding >= 11 && storedBuilding <= 20){\n var brick = 10*15*1000 + (storedBuilding-10)*12*1000;\n return \"Total Brick required:\" + \" \" + brick + \" \" + \"Pcs\";\n }\n else if(storedBuilding >= 21){\n var brick = 10*15*1000 + 10*12*1000 + (storedBuilding-20)*10*1000;\n return \"Total Brick required:\" + \" \" + brick + \" \" + \"Pcs\";\n }\n else{\n return \"undefined input value\"\n }\n}", "function createBricks(){\n let brickX = 2,brickY=10,j=0,a=0;\n for(var i=0;i<60;i++){\n let brick={\n x: brickX,\n y: brickY,\n w: brickWidth,\n h: 10,\n color: colors[j]\n }\n bricks.push(brick);\n brickX+=brickWidth+2;\n if(brickX+brickWidth+2>Width){\n brickY+=12;\n brickX=2;\n j++;\n }\n }\n }", "function brickCalculator(floor) {\n\n\n\n if (isNaN(floor) || floor == null || floor <= 0) {\n\n console.log(\"Please enter a valid number!\");\n\n } else {\n var totalbrick = 0;\n if (floor <= 10) {\n\n var totalbrick = floor * 15000;\n\n } else if (floor <= 20) {\n\n var totalbrick = 30000 + floor * 12000;\n\n } else {\n\n var totalbrick = 70000 + floor * 10000;\n }\n\n\n return totalbrick;\n }\n\n\n}", "function calcBoxes(bottles, boxCapacity){\n let boxesCount = Math.ceil(bottles / boxCapacity);\n return boxesCount;\n }", "function brickCalculator(storey) { // Declaring a function for calculating the number of brick needed in a number of stories of the parameter given\r\n let totalFeet; // Declaring the totalFeet variable\r\n if (storey === 0) { // Checking if the number of storey is \"0\" or not\r\n return `You can't give the number of stories \"0\"`; // Returning that you can't give the number of stories 0\r\n }\r\n else if (storey < 0) { // Checking if the number of storey is negative or not\r\n return `You can't give a negative number of stories`; // Returning that you can't give a negative number of stories\r\n }\r\n else if (storey <= 10) { // Checking if the number of storey is less than or equals to \"10\" or not\r\n totalFeet = storey * 15; // Calculating the number of feet in the number of stories\r\n }\r\n else if (storey > 10 && storey <= 20) { // Checking if the number of storey is greater than 10 and less than or equals to 20 or not\r\n const first10StoreyFeet = 10 * 15; // Calculating the number of feet in the first 10 stories by multiplying 10 with 15\r\n storey -= 10; // Subtracting 10 from the number of stories\r\n totalFeet = first10StoreyFeet + storey * 12; // Calculating the number of total feet in the number of stories by adding the number of storey we just calculated with the feet needed in the first 10 stories\r\n }\r\n else { // Checking if the number of storey doesn't match any of these conditions\r\n const first10StoreyFeet = 10 * 15; // Calculating the number of feet in the first 10 stories by multiplying 10 with 15\r\n const second10StoreyFeet = 10 * 12; // Calculating the number of feet in the second 20 stories by multiplying 10 with 12\r\n storey -= 20; // Subtracting 20 from the number of stories\r\n totalFeet = first10StoreyFeet + second10StoreyFeet + storey * 10; // Calculating the number of total feet in the number of stories by adding the number of storey we just calculated with the feet needed in the first 10 stories and the feet needed in the second 10 stories\r\n }\r\n const totalBrick = totalFeet * 1000; // Calculating how much brick is needed \r\n return `Total brick needed is: ${totalBrick}`; // Returning How much brick is needed\r\n}", "function detectBricks() {\n\n for (var i = 0; i < 9; i++) {\n for (var j = 0; j < 3; j++) {\n var getValueOfBricks = ceilBricks[i][j];\n // console.log(getValueOfBricks);\n if (getValueOfBricks.z == 0) {\n //checking if ball is touching bricks\n if (initialValueX > getValueOfBricks.x && initialValueX < getValueOfBricks.x + 75 + radiusOfBall && initialValueY > getValueOfBricks.y && initialValueY < getValueOfBricks.y + 20 + radiusOfBall) {\n moveY = -moveY;\n getValueOfBricks.z = 1;\n score++;\n }\n }\n }\n }\n }", "function calcBottles(startingMoney, costPerBottle) {\n var numberOfBottles = Math.floor(startingMoney / costPerBottle);\n return numberOfBottles;\n}", "function buildBricks(){\n\tfor(c = 0;c<brickColumnCount;c++){\n\t\tbricks[c] = [];\n\t\tfor(r = 0;r<brickRowCount;r++){\n\t\t\tbricks[c][r] = {x:0, y:0, status:1};\n\t\t}\n\t}\n}", "function calc_group_numbers( tier ){\n // Calculate the numbe of units in a group\n var workers = Math.pow( 7, tier );\n var nursers = 0;\n for( var i = 0; i < tier; i++){\n nursers += Math.pow( 7, i );\n }\n return {n: nursers, w:workers};\n}", "function createBricks() {\n for (var i = 0; i < 9; i++) {\n for (var j = 0; j < 3; j++) {\n if (ceilBricks[i][j].z == 0) {\n\n\n var brickX = (i * (75 + 10)) + 20;\n var brickY = (j * (20 + 10)) + 10;\n ceilBricks[i][j].x = brickX;\n ceilBricks[i][j].y = brickY;\n canvasContext.beginPath();\n canvasContext.rect(brickX, brickY, 75, 20);\n canvasContext.fillStyle = '#E6D4A4';\n canvasContext.fill();\n canvasContext.closePath();\n }\n }\n }\n }", "function createBricksL1() {\n brick.rows = 3;\n for (r = 0; r < brick.rows; r++) {\n bricks[r]=[];\n for (c = 0; c < brick.columns; c++) {\n bricks[r][c]={\n x: c*brick.x + 70,\n y: r*brick.y + 20,\n unbroken:true\n };\n }\n }\n}", "function brickCalculator(buildingNumber){\n \n switch(buildingNumber){\n case 1:\n case 2:\n case 3:\n case 4:\n case 5:\n case 6:\n case 7:\n case 8:\n case 9:\n case 10:\n console.log(15*1000);\n break;\n case 11:\n case 12:\n case 13:\n case 14:\n case 15:\n case 16:\n case 17:\n case 18:\n case 19:\n case 20:\n console.log(12*1000);\n break;\n case 1:\n case 21:\n case 23:\n case 24:\n case 25:\n case 26:\n case 27:\n case 28:\n case 29:\n case 30:\n console.log(10*1000);\n break;\n default:\n console.log(10*1000);\n }\n }", "function createBricksL4() {\n brick.rows = 6;\n for (r = 0; r < brick.rows; r++) {\n bricks[r]=[];\n for (c = 0; c < brick.columns; c++) {\n bricks[r][c]={\n x: c*brick.x + 70,\n y: r*brick.y + 20,\n unbroken:true\n };\n }\n }\n}", "function createBricksL2() {\n brick.rows = 6;\n for (r = 0; r <brick.rows; r++) {\n bricks[r]=[];\n for (c = 0; c < brick.columns; c++) {\n bricks[r][c]={\n x: c*brick.x + 70,\n y: r*brick.y + 20,\n unbroken:true\n };\n }\n }\n}", "function buildBricks(){\n\t\tvar arrLen = mapper.length;\n\t\t\n\t\tfor(var i=0; i< arrLen; i++){\n\t\t\tvar colLen = mapper[i].length;\n\t\t\t\n\t\t\tfor(var j=0; j< colLen; j++){\n\t\t\t\tvar val = mapper[i][j];\n\t\t\t\t\n\t\t\t\tif (val){\n\t\t\t\t\tvar b = new Brick({\n\t\t\t\t\t\tctx: ctx,\n\t\t\t\t\t\tx: (j * bSize),\n\t\t\t\t\t\ty: (i * bSize),\n\t\t\t\t\t\twidth: bSize,\n\t\t\t\t\t\theight: bSize,\n\t\t\t\t\t\tcolor: color,\n\t\t\t\t\t\tvalue: val\n\t\t\t\t\t});\n\t\t\t\t\t\n\t\t\t\t\tbricks.push(b);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "function calcBottles(totalMoney, pricePerDrink) {\n return Math.floor(totalMoney / pricePerDrink);\n}", "function bricks(x5, y5, bw, bh) {\r\n let brown = color(92, 39, 41);\r\n let lightbrown = color(174, 132, 123);\r\n let white = color(255, 231, 197);\r\n let mainbrown = color(202, 123, 70);\r\n let redbrown = color(97, 40, 48);\r\n let pink = color('rgba(251, 151, 158, 0.75)');\r\n let pink05 = color('rgba(251, 151, 158, 0.4)');\r\n let lightpink = color(255, 190, 169);\r\n let pinkwhite = color(239, 178, 145);\r\n let whitebrown = color(226, 171, 128);\r\n let brown208 = color(208, 123, 74);\r\n let darkbrown = color(143, 72, 38);\r\n let brown185 = color(185, 108, 59);\r\n let brown193 = color(193, 114, 71);\r\n let brown169 = color(169, 98, 56);\r\n let dredbrown = color(108, 44, 45);\r\n\r\n fill(lightbrown);\r\n rect(x5 + 1 * bw, y5 + 22 * bh, 18 * bw, 1 * bh);\r\n\r\n fill(brown208);\r\n rect(x5 + 11 * bw, y5 + 22 * bh, 1 * bw, 2 * bh);\r\n rect(x5 + 14 * bw, y5 + 38 * bh, 2 * bw, 1 * bh);\r\n\r\n fill(mainbrown);\r\n rect(x5 + 2 * bw, y5 + 24 * bh, 10 * bw, 6 * bh);\r\n rect(x5 + 12 * bw, y5 + 24 * bh, 5 * bw, 3 * bh);\r\n rect(x5 + 3 * bw, y5 + 30 * bh, 6 * bw, 4 * bh);\r\n rect(x5 + 4 * bw, y5 + 31 * bh, 5 * bw, 4 * bh);\r\n rect(x5 + 5 * bw, y5 + 32 * bh, 4 * bw, 4 * bh);\r\n rect(x5 + 2 * bw, y5 + 38 * bh, 6 * bw, 1 * bh);\r\n rect(x5 + 7 * bw, y5 + 37 * bh, 1 * bw, 2 * bh);\r\n rect(x5 + 14 * bw, y5 + 30 * bh, 3 * bw, 8 * bh);\r\n\r\n fill(white);\r\n rect(x5 + 1 * bw, y5 + 23 * bh, 18 * bw, 1 * bh);\r\n rect(x5 + 1 * bw, y5 + 23 * bh, 1 * bw, 7 * bh);\r\n rect(x5 + 13 * bw, y5 + 24 * bh, 1 * bw, 12 * bh);\r\n rect(x5 + 11 * bw, y5 + 38 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 14 * bw, y5 + 29 * bh, 1 * bw, 1 * bh);\r\n\r\n fill('rgba(156,110,104,0.5)'); //browngrey\r\n rect(x5 + 12 * bw, y5 + 24 * bh, 1 * bw, 12 * bh);\r\n rect(x5 + 2 * bw, y5 + 36 * bh, 5 * bw, 2 * bh);\r\n rect(x5 + 18 * bw, y5 + 32 * bh, 1 * bw, 5 * bh);\r\n rect(x5 + 13 * bw, y5 + 36 * bh, 1 * bw, 4 * bh);\r\n\r\n fill('rgba(134,68,72,0.5)'); //lightbrowngrey\r\n rect(x5 + 12 * bw, y5 + 28 * bh, 2 * bw, 1 * bh);\r\n rect(x5 + 12 * bw, y5 + 29 * bh, 2 * bw, 2 * bh);\r\n rect(x5 + 12 * bw, y5 + 39 * bh, 2 * bw, 1 * bh);\r\n\r\n\r\n fill(redbrown);\r\n rect(x5 + 17 * bw, y5 + 30 * bh, 1 * bw, 3 * bh);\r\n\r\n fill(pink);\r\n rect(x5 + 10 * bw, y5 + 22 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 10 * bw, y5 + 23 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 17 * bw, y5 + 22 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 17 * bw, y5 + 23 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 3 * bw, y5 + 24 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 1 * bw, y5 + 30 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 12 * bw, y5 + 26 * bh, 2 * bw, 1 * bh);\r\n rect(x5 + 13 * bw, y5 + 30 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 11 * bw, y5 + 39 * bh, 1 * bw, 1 * bh);\r\n\r\n fill(pink05);\r\n rect(x5 + 3 * bw, y5 + 25 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 9 * bw, y5 + 22 * bh, 1 * bw, 2 * bh);\r\n rect(x5 + 2 * bw, y5 + 30 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 18 * bw, y5 + 22 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 18 * bw, y5 + 23 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 12 * bw, y5 + 25 * bh, 2 * bw, 1 * bh);\r\n rect(x5 + 16 * bw, y5 + 29 * bh, 1 * bw, 1 * bh);\r\n\r\n fill(lightpink);\r\n rect(x5 + 2 * bw, y5 + 24 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 13 * bw, y5 + 29 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 2 * bw, y5 + 38 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 3 * bw, y5 + 37 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 10 * bw, y5 + 38 * bh, 1 * bw, 1 * bh);\r\n\r\n fill(pinkwhite);\r\n rect(x5 + 2 * bw, y5 + 25 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 13 * bw, y5 + 31 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 13 * bw, y5 + 35 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 12 * bw, y5 + 36 * bh, 1 * bw, 2 * bh);\r\n rect(x5 + 4 * bw, y5 + 37 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 15 * bw, y5 + 29 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 16 * bw, y5 + 30 * bh, 1 * bw, 1 * bh);\r\n\r\n fill(226, 202, 180);\r\n rect(x5 + 11 * bw, y5 + 36 * bh, 1 * bw, 2 * bh);\r\n\r\n fill(whitebrown);\r\n rect(x5 + 2 * bw, y5 + 26 * bh, 1 * bw, 4 * bh);\r\n rect(x5 + 18 * bw, y5 + 24 * bh, 1 * bw, 6 * bh);\r\n rect(x5 + 10 * bw, y5 + 39 * bh, 1 * bw, 1 * bh);\r\n\r\n fill(darkbrown);\r\n rect(x5 + 10 * bw, y5 + 24 * bh, 1 * bw, 12 * bh);\r\n rect(x5 + 1 * bw, y5 + 32 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 17 * bw, y5 + 25 * bh, 1 * bw, 3 * bh);\r\n rect(x5 + 17 * bw, y5 + 33 * bh, 1 * bw, 2 * bh);\r\n rect(x5 + 9 * bw, y5 + 36 * bh, 1 * bw, 2 * bh);\r\n rect(x5 + 6 * bw, y5 + 36 * bh, 3 * bw, 1 * bh);\r\n rect(x5 + 3 * bw, y5 + 35 * bh, 3 * bw, 1 * bh);\r\n rect(x5 + 1 * bw, y5 + 33 * bh, 1 * bw, 1 * bh);\r\n\r\n fill(brown185);\r\n rect(x5 + 1 * bw, y5 + 31 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 9 * bw, y5 + 24 * bh, 1 * bw, 12 * bh);\r\n rect(x5 + 17 * bw, y5 + 24 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 17 * bw, y5 + 28 * bh, 1 * bw, 2 * bh);\r\n rect(x5 + 6 * bw, y5 + 35 * bh, 3 * bw, 1 * bh);\r\n rect(x5 + 3 * bw, y5 + 34 * bh, 3 * bw, 1 * bh);\r\n rect(x5 + 3 * bw, y5 + 33 * bh, 2 * bw, 1 * bh);\r\n rect(x5 + 9 * bw, y5 + 39 * bh, 1 * bw, 1 * bh);\r\n\r\n fill(brown193);\r\n rect(x5 + 2 * bw, y5 + 31 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 1 * bw, y5 + 39 * bh, 1 * bw, 1 * bh);\r\n\r\n fill(brown169);\r\n rect(x5 + 2 * bw, y5 + 32 * bh, 1 * bw, 3 * bh);\r\n rect(x5 + 2 * bw, y5 + 37 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 17 * bw, y5 + 35 * bh, 1 * bw, 3 * bh);\r\n rect(x5 + 8 * bw, y5 + 37 * bh, 1 * bw, 2 * bh);\r\n rect(x5 + 14 * bw, y5 + 38 * bh, 2 * bw, 1 * bh);\r\n rect(x5 + 16 * bw, y5 + 37 * bh, 1 * bw, 1 * bh);\r\n\r\n fill(dredbrown);\r\n rect(x5 + 11 * bw, y5 + 24 * bh, 1 * bw, 12 * bh);\r\n rect(x5 + 2 * bw, y5 + 34 * bh, 1 * bw, 3 * bh);\r\n rect(x5 + 1 * bw, y5 + 33 * bh, 1 * bw, 6 * bh);\r\n rect(x5 + 12 * bw, y5 + 27 * bh, 2 * bw, 1 * bh);\r\n rect(x5 + 10 * bw, y5 + 36 * bh, 1 * bw, 2 * bh);\r\n rect(x5 + 3 * bw, y5 + 36 * bh, 3 * bw, 1 * bh);\r\n\r\n fill(darkbrown);\r\n rect(x5 + 2 * bw, y5 + 34 * bh, 1 * bw, 3 * bh);\r\n rect(x5 + 3 * bw, y5 + 35 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 3 * bw, y5 + 34 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 14 * bw, y5 + 27 * bh, 2 * bw, 1 * bh);\r\n rect(x5 + 17 * bw, y5 + 28 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 18 * bw, y5 + 30 * bh, 1 * bw, 2 * bh);\r\n rect(x5 + 18 * bw, y5 + 37 * bh, 1 * bw, 3 * bh);\r\n rect(x5 + 17 * bw, y5 + 37 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 12 * bw, y5 + 38 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 2 * bw, y5 + 39 * bh, 2 * bw, 1 * bh);\r\n rect(x5 + 9 * bw, y5 + 38 * bh, 1 * bw, 1 * bh);\r\n\r\n fill(dredbrown);\r\n rect(x5 + 3 * bw, y5 + 36 * bh, 3 * bw, 1 * bh);\r\n rect(x5 + 2 * bw, y5 + 35 * bh, 2 * bw, 2 * bh);\r\n rect(x5 + 7 * bw, y5 + 36 * bh, 3 * bw, 1 * bh);\r\n rect(x5 + 14 * bw, y5 + 28 * bh, 3 * bw, 1 * bh);\r\n rect(x5 + 16 * bw, y5 + 27 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 17 * bw, y5 + 26 * bh, 1 * bw, 2 * bh);\r\n rect(x5 + 17 * bw, y5 + 29 * bh, 1 * bw, 1 * bh);\r\n rect(x5 + 16 * bw, y5 + 38 * bh, 2 * bw, 2 * bh);\r\n rect(x5 + 14 * bw, y5 + 39 * bh, 2 * bw, 1 * bh);\r\n rect(x5 + 4 * bw, y5 + 39 * bh, 5 * bw, 1 * bh);\r\n\r\n fill(lightpink);\r\n rect(x5 + 18 * bw, y5 + 29 * bh, 1 * bw, 1 * bh);\r\n\r\n fill(brown193);\r\n rect(x5 + 17 * bw, y5 + 31 * bh, 1 * bw, 4 * bh);\r\n}", "calcTroops(villageId,buildings)\n {\n let barrackList =[]\n let barrackQ;\n let barrack = this.troopres['club'].split(',');\n let res = m.villageData[villageId][\"res\"];\n console.log(barrack)\n \n barrackList.push(parseInt(res.wood/barrack[0]))\n barrackList.push(parseInt(res.clay/barrack[1]))\n barrackList.push(parseInt(res.iron/barrack[2]))\n barrackList.push(parseInt(res.crop/barrack[3]))\n barrackQ = Math.min.apply(null, barrackList);\n console.log(barrackQ)\n let rcrop = parseInt(res.crop) - barrackQ*barrack[3]; \n if(rcrop>200)\n {\n \n return barrackQ;\n }\n else\n {\n return 0;\n }\n }", "function howManyStickers(n) {\n return Math.pow(n,2) * 6;\n }", "function calcBills (water, power, rent, netflix) {\n\tvar totalBill = water + power + rent + netflix;\n\tconsole.log(totalBill);\n}", "function createBricksL3() {\n brick.rows = 6;\n for (r = 0; r < brick.rows; r++) {\n bricks[r]=[];\n for (c = 0; c < brick.columns; c++) {\n bricks[r][c]={\n x: c*brick.x + 70,\n y: r*brick.y + 20,\n unbroken:true\n };\n }\n }\n}", "function squaresNeeded(grains){\n return Math.ceil(Math.log2(grains+1))\n}", "function beeStung(weight) {\n \n //calculate for bee stings\n var stings=8.666666667*weight\n \n //Return number of Bee stings\n return stings;\n}", "function calcCorHybr (numFloors, numBasements, numOccupants){ \n var totalOccupantsCorHybr= numOccupants * (numFloors + numBasements);\n var numShaftsRequired= Math.ceil(totalOccupantsCorHybr / 1000);\n numColumnsCorHybr= Math.ceil((numFloors + numBasements) / 20);\n var numShaftsColumm= Math.ceil(numShaftsRequired / numColumnsCorHybr);\n numTotalShaftsCorHybr= numShaftsColumm * numColumnsCorHybr;\n }", "function balls() {\n return Math.floor(innerHeight / 100 + innerWidth / 200);\n}", "function mathHeavyStuff(sizeFeet, sizeInches, i) {\n $scope[\"lum_quant_\" + sizeFeet].push((Math.ceil((schem.cuts[i].piece_num * quant) / Math.floor(sizeInches / schem.cuts[i].piece_length))));\n $scope[\"total_cost_\" + sizeFeet].push(Number(($scope[\"lum_quant_\" + sizeFeet][i] * $scope.lumberPrices[schem.cuts[i].lumber_size][\"price_\" + sizeFeet])));\n $scope[\"total_scrap_\" + sizeFeet].push(($scope[\"lum_quant_\" + sizeFeet][i] * sizeInches) - (schem.cuts[i].piece_num * quant * schem.cuts[i].piece_length));\n }", "function metersOfFabric() {\n const sizes = {\n size_XS: (1.8 - 0.4),\n size_S: (1.8 - 0.2),\n size_M: 1.8,\n size_L: 1.8 + 0.2,\n size_XL: 1.8 + 0.4,\n \n }\n const metersPerSize = {\n XS: (sizes.size_XS * 50),\n S: (sizes.size_S * 50),\n M: (sizes.size_M * 50),\n L: (sizes.size_L * 50),\n XL: Math.round((sizes.size_XL * 50)),\n } \n //this is one way to calculate the total of meters needed:\n // const totalFabricNeeded = Object.values(metersPerSize).reduce((a, b) => a + b, 0); \n \n //this is other way to calculate the total of meters needed:\n let totalFabricNeeded = sum( metersPerSize );\n function sum( obj ) {\n let sum = 0;\n for( let metersEachSize in obj ) {\n if( obj.hasOwnProperty( metersEachSize ) ) {\n sum += parseFloat( obj[metersEachSize] );\n }\n }\n return sum;\n }\n \n const totalFabricRolls = Math.ceil(totalFabricNeeded / 40); \n \n const fabricForLining = (totalFabricNeeded * 0.8);\n const totalLiningFabricRolls = Math.ceil(fabricForLining / 50);\n \n \n //console.log(sizes);//HELPER LOG\n //console.log(metersPerSize);//HELPER LOG\n //console.log( \"sum of meters needed: \"+ totalFabricNeeded );//HELPER LOG\n console.log(\"The amount of fabric rolls needed is \" + totalFabricRolls);\n //console.log( \"sum of lining meters needed: \"+ fabricForLining);//HELPER LOG\n console.log(\"The amount of lining fabric rolls needed is \" + totalLiningFabricRolls);\n console.log(`If fabric is double width: all jackets in production require ${totalFabricRolls / 2} rolls of fabric and ${totalLiningFabricRolls / 2} rolls of lining.`);\n }", "function calcNumberOfParts (b, t, b){\n\tvar numberOfParts = b + t + b;\n\treturn numberOfParts;\n}", "function useBricks( settings ) {\n\t//var DEG_TO_RAD = Math.PI*2;\n\tfunction makeBrickMesh( brickSettings, color ) {\n\t var brick = new THREE.Mesh( new THREE.CubeGeometry(brickSettings.size.x,\n\t\t\t\t\t\t\t brickSettings.size.y,\n\t\t\t\t\t\t\t brickSettings.size.z),\n\t\t\t\t\tnew THREE.MeshPhongMaterial( { color : color, transparent : true, opacity : 0.5 } ) );\n\t return brick;\n\t}\n\tvar meshBase = makeBrickMesh( settings.base, settings.base.color );\n\tvar meshBrickA = makeBrickMesh( settings.brickA, settings.brickA.color );\n\tvar meshBrickB = makeBrickMesh( settings.brickB, settings.brickB.color );\n\tvar meshBrickC = makeBrickMesh( settings.brickC, settings.brickC.color );\n\tvar meshBrickD = makeBrickMesh( settings.brickD, settings.brickD.color );\n\tapplyMeshRotation( meshBase, deg2rad(settings.base.rotation) );\n\tapplyMeshRotation( meshBrickA, deg2rad(settings.brickA.rotation) );\n\tapplyMeshRotation( meshBrickB, deg2rad(settings.brickB.rotation) );\n\tapplyMeshRotation( meshBrickC, deg2rad(settings.brickC.rotation) );\n\tapplyMeshRotation( meshBrickD, deg2rad(settings.brickD.rotation) );\n\tapplyMeshTranslation( meshBase, settings.base.translation );\n\tapplyMeshTranslation( meshBrickA, settings.brickA.translation );\n\tapplyMeshTranslation( meshBrickB, settings.brickB.translation );\n\tapplyMeshTranslation( meshBrickC, settings.brickC.translation );\n\tapplyMeshTranslation( meshBrickD, settings.brickD.translation );\n\tvar bspBase = new ThreeBSP( meshBase );\n\tvar bspBrickA = new ThreeBSP( meshBrickA );\n\tvar bspBrickB = new ThreeBSP( meshBrickB );\n\tvar bspBrickC = new ThreeBSP( meshBrickC );\n\tvar bspBrickD = new ThreeBSP( meshBrickD );\n\n\tvar mesh = new THREE.Mesh();\n\n\tfunction _applyIntersectWithDiff( bspBase, colorBase, bspSub, colorSub, callback ) {\n\t var bspIntersection = bspBase.intersect( bspSub );\n\t var bspDiffBase = bspBase.subtract( bspSub );\n\t var bspDiffSub = bspSub.subtract( bspBase );\n\t var meshDiffBase = bspDiffBase.toMesh( new THREE.MeshPhongMaterial( { color : colorBase, transparent : true, opacity : 0.5 } ) );\n\t var meshDiffSub = bspDiffSub.toMesh( new THREE.MeshPhongMaterial( { color : colorSub, transparent : true, opacity : 0.5 } ) );\n\t callback( meshDiffBase, meshDiffSub );\n\n\t return bspIntersection;\n\t}\n\n\tvar bspIntersection = bspBase;\n\tbspIntersection = _applyIntersectWithDiff( bspIntersection, settings.base.color,\n\t\t\t\t\t\t bspBrickA, settings.brickA.color,\n\t\t\t\t\t\t function( difBase, difA ) { if( !settings.showBricks ) return; mesh.add(difA); }\n\t\t\t\t\t\t );\n\tbspIntersection = _applyIntersectWithDiff( bspIntersection, settings.base.color,\n\t\t\t\t\t\t bspBrickB, settings.brickB.color,\n\t\t\t\t\t\t function( difBase, difB ) { if( !settings.showBricks ) return; mesh.add(difBase); mesh.add(difB); }\n\t\t\t\t\t\t );\t\n\tbspIntersection = _applyIntersectWithDiff( bspIntersection, settings.base.color,\n\t\t\t\t\t\t bspBrickC, settings.brickC.color,\n\t\t\t\t\t\t function( difBase, difC ) { if( !settings.showBricks ) return; mesh.add(difBase); mesh.add(difC); }\n\t\t\t\t\t\t );\n\t\n\tbspIntersection = _applyIntersectWithDiff( bspIntersection, settings.base.color,\n\t\t\t\t\t\t bspBrickD, settings.brickD.color,\n\t\t\t\t\t\t function( difBase, difD ) { if( !settings.showBricks ) return; mesh.add(difBase); mesh.add(difD); }\n\t\t\t\t\t\t );\n\t\n\tmesh.add( bspIntersection.toMesh( new THREE.MeshPhongMaterial( { color : 0x00ff00 } ) ) );\n\treturn mesh;\n } // END useBricks", "function calcFuel(n) {\n const fuel = {\n lava: 0,\n blazeRod: 0,\n coal: 0,\n wood: 0,\n stick: 0,\n };\n let time = n * 11;\n while (time > 0) {\n if (time >= 800) {\n time -= 800;\n fuel.lava += 1;\n } else if (time >= 120) {\n time -= 120;\n fuel.blazeRod += 1;\n } else if (time >= 80) {\n time -= 80;\n fuel.coal += 1;\n } else if (time >= 15) {\n time -= 15;\n fuel.wood += 1;\n } else {\n time -= 1;\n fuel.stick += 1;\n }\n }\n return fuel;\n}", "function drawMapBricks() {\n\tfor (var i = 0; i < maps[currentMap].bricks.length; i++) {\n\t\t// Check if brick exists, if not skip\n\t\tif (maps[currentMap].bricks[i].hits >= maps[currentMap].brickColors.length) {\n\t\t\tcontinue;\n\t\t}\n\t\t// Border\n\t\tcolorRect(maps[currentMap].bricks[i].x, maps[currentMap].bricks[i].y,\n\t\t\tmaps[currentMap].brickWidth, maps[currentMap].brickHeight, maps[currentMap].brickColors[maps[currentMap].bricks[i].hits]);\n\t\t// Fill\n\t\tcolorRect(maps[currentMap].bricks[i].x + maps[currentMap].brickBorderWidth,\n\t\t\tmaps[currentMap].bricks[i].y + maps[currentMap].brickBorderWidth,\n\t\t\tmaps[currentMap].brickWidth - (maps[currentMap].brickBorderWidth * 2),\n\t\t\tmaps[currentMap].brickHeight - (maps[currentMap].brickBorderWidth * 2), '#111');\n\t}\n}", "function generateBricks(rowSize, columnSize){ // TODO: makes rowSize and columnSize upon canva's width and height\r\n brickRows = rowSize;\r\n brickColumns = columnSize;\r\n\r\n // mazzutti's famous matriz generator Ahead\r\n const array = [];\r\n for(let i=0; i<brickRows; i++){\r\n array[i] = [];\r\n for(let j=0; j<brickColumns; j++){\r\n const x = i * (brickInfo.width + brickInfo.padding) + brickInfo.offsetX;\r\n const y = j * (brickInfo.height + brickInfo.padding) + brickInfo.offsetY;\r\n array[i][j] = {x, y, ...brickInfo}; // puts the whole bricks info inside array\r\n }\r\n }\r\n return array\r\n}", "function drawBricks() {\n \n bricksCollection = [];\n\n blocksLengthArray.forEach(function ( index, element){\n\n let brickX = (element * ( brickWidth + brickPadding )) + brickOffsetLeft;\n let rectangle = new Rect(brickX, brickOffsetTop, brickWidth, brickHeight, '#FA7268');\n if(selfie.length !== 0) { \n \n if(selfie[index] !== undefined) {\n\n if(selfie[index].status == 1) {\n\n rectangle.status = 1;\n rectangle.render(cavnasContext);\n bricksCollection.push(rectangle);\n \n }\n\n }\n\n } else {\n \n rectangle.status = 1;\n rectangle.render(cavnasContext);\n bricksCollection.push(rectangle);\n\n };\n \n\n });\n \n \n }", "function countBricks () {\n var brickIds = Crafty(\"Brick\");\n counts = {normals: 0, diamonds: 0};\n\n for (var i = 0; i < brickIds.length; i++) {\n if (brickIsNormal(Crafty(brickIds[i]).type)) {\n counts.normals++;\n }\n if (brickIsDiamond(Crafty(brickIds[i]).type)) {\n counts.diamonds++;\n }\n }\n\n return counts;\n}", "function generateBricks (i, j) {\n\t\tif(i > 0 && i < 18 && j > 0 && j < 14 && Crafty.randRange(0, 50) > 40 && !(i == 1 && j == 1) && !(i == 1 && j == 2)\n\t\t\t&& !(i == 1 && j == 3) && !(i == 1 && j == 4) && !(i == 2 && j == 1) && !(i == 3 && j == 2) && !(i == 4 && j == 1)\n\t\t && !(i == 17 && j == 13) && !(i == 16 && j == 13) && !(i == 15 && j == 13) && !(i == 17 && j == 12) && !(i == 17 && j == 11)){\n\t\t\t//fill Array, return true\n\t\t\tif(Crafty.randRange(0, 50) > 45){\n\t\t\t\tbrick_array[i][j] = 4;\n\t\t\t}else {\n\t\t\t\tbrick_array[i][j] = 2;\n\t\t\t}\n\t\t\treturn true;\n\t\t} else {\n\t\t\treturn false;\n\t\t};\n\t}", "function spawnBricks() {\n //inticates columns in the bricks\n for(var c=0; c<columns; c++) {\n //shows the amount of rows\n for(var r=0; r<rows; r++) {\n if(bricks[c][r].status == 1) {\n var brickX = (r*(bwidth+brickPadding))+brickleft;\n var brickY = (c*(bheight+brickPadding))+brickright;\n bricks[c][r].x = brickX;\n bricks[c][r].y = brickY;\n //color and shape of brick\n ctx.beginPath();\n ctx.rect(brickX, brickY, bwidth, bheight);\n ctx.fillStyle = \"#FFFF00\";\n ctx.fill();\n ctx.closePath();\n }\n }\n }\n}", "function calculateBMR() {\n\n // Sedentary (little or no exercise): BMR x 1.2\n // Lightly active (light exercise/sports 1-3 days/week): BMR x 1.375\n // Moderately active (moderate exercise/sports 3-5 days/week): BMR x 1.55\n // Very active (hard exercise/sports 6-7 days a week): BMR x 1.725\n // Extra active (very hard exercise/sports & physical job or 2x training): BMR x 1.9 \n\n // you can simply add 0.175 to each level to get the next. but if we set this up in the database instead\n // of the actual varchar value of the level we can quickly calculate the BMR\n\n return calculateBEE() * activityLevel;\n}", "function bricCalculator(tala){\n if(tala<=10){\n var bric = tala * 15 * 1000;\n }\n else if(tala<=20){\n var bric = (10*15*1000)+((tala-10)*12*1000);\n }\n else if(tala>20)\n {\n var bric = (10*15*1000)+(10*12*1000)+((tala-20)*10*1000)\n }\n return bric;\n}", "function getBandIndex(\n vizState: {maxPrice: number, minPrice: number, priceGranularity: number}, price: number\n): number {\n // price range between the bottom and top of each band\n const bandPriceSpan = (+vizState.maxPrice - +vizState.minPrice) / vizState.priceGranularity;\n\n if(price == vizState.maxPrice) {\n return vizState.priceGranularity - 1;\n } else {\n return Math.floor((+price - +vizState.minPrice) / bandPriceSpan);\n }\n}", "function calcNumBeeStings (w){\n\n //declare and define a variable to calculate the total number of bee stings based on the input of the user.\n var totalBeeStings = w * 8.666666667;\n\n //return the total number of bee stings back to the main code.\n return totalBeeStings;\n }", "function CheckBrickBallCollision() {\n\t// Check if ball is colliding with each brick\n\tfor (var i = 0; i < maps[currentMap].bricks.length; i++) {\n\t\t// console.log(maps[currentMap].bricks[i]);\n\t\t// Check if brick still exists, skip if not\n\t\tif (maps[currentMap].bricks[i].hits >= maps[currentMap].brickColors.length) {\n\t\t\tcontinue;\n\t\t}\n\t\t// Right-side of brick collision\n\t\tif (ballX - ballR < maps[currentMap].bricks[i].x + maps[currentMap].brickWidth &&\n\t\t\tballX + ballR > maps[currentMap].bricks[i].x + maps[currentMap].brickWidth &&\n\t\t\tballY >= maps[currentMap].bricks[i].y &&\n\t\t\tballY <= maps[currentMap].bricks[i].y + maps[currentMap].brickHeight) {\n\t\t\tmaps[currentMap].bricks[i].hits++;\n\t\t\tballSpeedX = -ballSpeedX;\n\t\t}\n\t\t// Left-side of brick collision\n\t\telse if (ballX + ballR > maps[currentMap].bricks[i].x &&\n\t\t\tballX - ballR < maps[currentMap].bricks[i].x &&\n\t\t\tballY >= maps[currentMap].bricks[i].y &&\n\t\t\tballY <= maps[currentMap].bricks[i].y + maps[currentMap].brickHeight) {\n\t\t\tmaps[currentMap].bricks[i].hits++;\n\t\t\tballSpeedX = -ballSpeedX;\n\t\t}\n\t\t// Top of brick collision\n\t\telse if (ballY + ballR > maps[currentMap].bricks[i].y &&\n\t\t\tballY - ballR < maps[currentMap].bricks[i].y &&\n\t\t\tballX >= maps[currentMap].bricks[i].x &&\n\t\t\tballX <= maps[currentMap].bricks[i].x + maps[currentMap].brickWidth) {\n\t\t\tmaps[currentMap].bricks[i].hits++;\n\t\t\tballSpeedY = -ballSpeedY;\n\t\t}\n\t\t// Bottom of brick collision\n\t\telse if (ballY - ballR < maps[currentMap].bricks[i].y + maps[currentMap].brickHeight &&\n\t\t\tballY + ballR > maps[currentMap].bricks[i].y + maps[currentMap].brickHeight &&\n\t\t\tballX >= maps[currentMap].bricks[i].x &&\n\t\t\tballX <= maps[currentMap].bricks[i].x + maps[currentMap].brickWidth) {\n\t\t\tmaps[currentMap].bricks[i].hits++;\n\t\t\tballSpeedY = -ballSpeedY;\n\t\t}\n\n\t\t// Update total bricks broken\n\t\tif (maps[currentMap].bricks[i].hits == maps[currentMap].brickColors.length) {\n\t\t\tbrokenBricks++;\n\t\t}\n\n\t\t// Check if all bricks are broken\n\t\t// con\n\t\tif (brokenBricks >= maps[currentMap].bricks.length) {\n\t\t\tbrokenBricks = 0;\n\t\t\tcurrentMap++;\n\t\t\tresetBall();\n\t\t\tresetPaddle();\n\t\t\troundStart = true;\n\t\t\tif (currentMap === maps.length) {\n\t\t\t\tgameOver = true;\n\t\t\t} else {\n\t\t\t\tmapComplete = true;\n\t\t\t}\n\t\t\treturn;\n\t\t}\n\t}\n}", "function makeBricks(small ,big, goal) {\n possible = false;\n if (big * 5 === goal || small * 1 === goal || small * 1 + big * 5 === goal)\n {possible = true;}\n console.log(possible);\n return big * 5 === goal || small * 1 === goal || small * 1 + big * 5 === goal\n}", "function computeNodeBreadths() {\n // var remainingNodes = nodes,\n // nextNodes,\n // x = 0\n\n // var test=1;\n nodes.forEach(function (node) {\n node.x = node.pos * nodeOffset;////pos is in the Json data jixiangyu\n\n //console.log(node.cluster);\n //test++;\n\n node.dx = nodeWidth;\n });\n }", "function fuelRequired(value){\n\n return (Math.floor(value/3)) - 2;\n}", "drawBricks(ctx) {\n for (let i = 0; i < this.brickCols; i++) {\n for(let j = 0; j < this.brickRows; j++) {\n if (this.isBrickAtTileCoord(i, j)) {\n let brickLeftEdgeX = i * this.brickWidth;\n let brickTopEdgeY = j * this.brickThickness;\n this.drawBrick(ctx, brickLeftEdgeX, brickTopEdgeY)\n }\n }\n }\n }", "function calculatePrice(bldg) {\r\n\tlet price = 0,\r\n\t\thave = IO.buildings[bldg].in.value !== '' ? parseInt(IO.buildings[bldg].in.value) : 0,\r\n\t\tquantity = parseInt(IO.controls.quantity.value),\r\n\t\tfree = (bldg==='cursor' && IO.hasDiscount('starter-kit') ? 10 : (bldg==='grandma' && IO.hasDiscount('starter-kitchen') ? 5 : 0)),\r\n\t\tsellMode = IO.controls.sellmode.checked,\r\n\t\tfrom = (sellMode ? have - quantity : have),\r\n\t\tto = (sellMode ? have : have + quantity);\r\n\r\n\tfor (let i = Math.max(0, from); i < Math.max(0, to); i++)\r\n\t\tprice += CONSTANTS.base[bldg] * Math.pow(CONSTANTS.increase, Math.max(0, i-free));\r\n\r\n\treturn Math.ceil(price * getMultiplier(bldg));\r\n}", "function ballBrickHandling() {\n let ballBrickCol = Math.floor(ballX / BRICK_WIDTH);\n let ballBrickRow = Math.floor(ballY / BRICK_HEIGHT);\n let brickIndexUnderBall = rowColToArrayIndex(ballBrickCol, ballBrickRow);\n\n if (ballBrickCol >= 0 && ballBrickCol < BRICK_COLUMNS && ballBrickRow >= 0 && ballBrickRow < BRICK_ROWS) {\n\n if (isBrickAtRowCol(ballBrickCol, ballBrickRow)) {\n brickArr[brickIndexUnderBall] = false;\n score += 100;\n bricksLeft--;\n\n let prevBallX = ballX - speedBallX;\n let prevBallY = ballY - speedBallY;\n let prevBrickCol = Math.floor(prevBallX / BRICK_WIDTH);\n let prevBrickRow = Math.floor(prevBallY / BRICK_HEIGHT);\n\n let bothTestsFailed = true;\n\n if (prevBrickCol != ballBrickCol) {\n if (isBrickAtRowCol(prevBrickCol, prevBrickRow) == false) {\n speedBallX *= -1;\n bothTestsFailed = false;\n }\n }\n if (prevBrickRow != ballBrickRow) {\n if (isBrickAtRowCol(prevBrickCol, prevBrickRow) == false) {\n speedBallY *= -1;\n bothTestsFailed = false;\n }\n }\n if (bothTestsFailed) {\n speedBallX *= -1;\n speedBallY *= -1;\n }\n }\n }\n}", "function bricksCollisionDetection () {\n for (var c = 0; c < store.state.brickColumnCount; c++) {\n for (var r = 0; r < store.state.brickRowCount; r++) {\n var b = store.state.bricks[c][r];\n if (b.status == 1) {\n if (\n store.state.ballX > b.x &&\n store.state.ballX < b.x + store.state.brickWidth &&\n store.state.ballY + store.state.ballRadius > b.y &&\n store.state.ballY - store.state.ballRadius <\n b.y + store.state.brickHeight\n ) {\n // A brick was hit\n store.commit ('setBallDirectionX', store.state.ballDirectionX * -1);\n store.commit ('setBallForceY', -store.state.ballForceY);\n if (r % 2 == 1 && r != 0 && r < store.state.highestBrickRowBroken) {\n store.commit (\n 'setBallSpeed',\n store.state.ballSpeed + store.state.config.ballSpeedMultiplier\n );\n applyBallForce (store.state.ballSpeed);\n }\n store.commit ('setHighestBrickBroken', r);\n b.status = 0;\n store.commit ('incrementScore');\n if (\n store.state.score ==\n store.state.brickRowCount * store.state.brickColumnCount\n ) {\n store.commit ('toggleGameRunning', false);\n drawYouWin ();\n }\n // Only break one brick\n return;\n }\n }\n }\n }\n}", "calcCeilingPrice( cb ){\n\t\tconst price = this.calcAreaPaintingPrice( this.state.roomArea, this.state.paintingPrice, this.state.ceilingPaintPrice );\n\t\t this.setState({ ceilingPrice: price },cb);\n\t}", "function bucketLane() {\r\n\t\r\n\tvar bucketArray = document.querySelectorAll(\".bucket\");\r\n\t\r\n\tif (bucketArray[0].location == 1)\r\n\t\treturn 15;\r\n\tif (bucketArray[1].location == 1)\r\n\t\treturn 45;\r\n\tif (bucketArray[2].location == 1)\r\n\t\treturn 30;\r\n\t\r\n}", "function gratuity(bill) {\n return bill * .20;\n}", "function drawBricks() {\n for (r = 0; r < brick.rows; r++) {\n for (c = 0; c < brick.columns; c++) {\n if (r = 1) {\n context.fillStyle = 'pink';\n context.fillRect(c * brick.x + 70, r * brick.y + 20, brick.width, brick.height);\n }\n if (r = 2) {\n context.fillStyle = 'lightblue';\n context.fillRect(c * brick.x + 70, r * brick.y + 20, brick.width, brick.height);\n }\n if (r = 3) {\n context.fillStyle = 'yellow';\n context.fillRect(c * brick.x + 70, r * brick.y + 20, brick.width, brick.height);\n }\n }\n }\n}", "spawnBricks() {\r\n let space = 40;\r\n for (let i = 0; i < 9 + this.lvl; i++) {\r\n let ready = false;\r\n let pos;\r\n\r\n while(ready == false) {\r\n pos = createVector(random(20, width - 20), random(50, height - 300));\r\n if(this.bricks.length == 0) {\r\n ready = true;\r\n }else {\r\n let tempReady = false;\r\n for(let i = 0; i < this.bricks.length; i++) {\r\n let d = p5.Vector.dist(this.bricks[i].pos, pos);\r\n if(d > space) {\r\n tempReady = true;\r\n }\r\n }\r\n\r\n if(tempReady) ready = true;\r\n }\r\n }\r\n this.bricks.push(new Brick(pos.x, pos.y));\r\n }\r\n }", "function calculateBill(bill) {\r\n if (bill < 50) {\r\n return (bill * 0.2) + bill;\r\n } else if (bill >= 50 && bill < 200) {\r\n return (bill * 0.15) + bill;\r\n } else {\r\n return (bill * 0.1) + bill;\r\n }\r\n}", "function budgetCalculator(watch, phone, laptop){\n // cost every single item\n var watchCost = watch * 50;\n var phoneCost = phone * 100;\n var laptopCost = laptop * 500;\n //total cost of all item.\n var totalCost = watchCost + phoneCost + laptopCost;\n return totalCost;\n\n}", "function budgetCalculator(watch,phone,laptop){\n var watchPrize=watch*50;\n var phonePrize=phone*100;\n var laptopPrize=laptop*500;\n var total= watchPrize+phonePrize+laptopPrize;\n return total;\n }", "calcWallsPrice( cb ){\n\t\t\n\t\tlet stucco = null;\n\t\tlet plaster = null;\n\t\t\n\t\tif( this.state.wallConditions === 'paintStucco' ){\n\t\t\tstucco = this.state.stuccoPrice;\n\t\t}else if( this.state.wallConditions === 'paintStuccoPlaster' ){\n\t\t\tplaster = this.state.plasterPrice;\n\t\t}\n\t\t\n\t\tlet price = this.calcAreaPaintingPrice( this.state.wallsArea, this.state.paintingPrice, this.state.wallPaintPrice, stucco, plaster );\n\t\t\n\t\tif(this.state.wallCeramics ){\n\t\t\tprice += this.state.roomArea * this.state.wallCeramicsWorkCost + this.state.wallCeramicsPrice *this.state.roomArea;\n\t\t}\n\t\t\n\t\tthis.setState({ wallsPrice: price },cb);\n\t}", "function layers(n){\n let base\n for (let i = 1; true; i += 2) {\n if (n <= i ** 2) {\n base = i\n break\n }\n }\n return n === 1 ? 1 : Math.ceil(base / 2)\n}", "function box_capacity(length, width, height) {\n const crate = 1.33333333333; //in feet\n const totalCrates = (length / crate) * (width / crate) * (height / crate);\n //output to round to whole num\n const rounded = Math.round(totalCrates);\n //returns num boxes fit\n return rounded;\n}", "function budgetCalculator(watch, phone, laptop) {\n let allPrice = watch * 50 + phone * 100 + laptop * 500;\n return allPrice;\n}", "function budgetCalculator(watch, mobile, laptop) {\n var preiceOfWatch = watch * 50;\n var preiceOfMobile = mobile * 100;\n var preiceOfLaptop = laptop * 500;\n var total = preiceOfWatch + preiceOfMobile + preiceOfLaptop;\n return total;\n}", "function budgetCalculator (watch, mobile, laptop) {\n var ghori = watch * 50;\n var phone = mobile * 100;\n var computer = laptop * 500;\n var amount = ghori + phone + computer;\n\n return amount;\n}", "calcFloorPrice(cb){\n\t\tconst floorPrice = this.state.floorMakingPrice * this.state.roomArea + this.state.floorMaterialPrice * this.state.roomArea;\n\t\tthis.setState({ floorPrice :floorPrice },cb);\n\t}", "function budgetCalculator (watch,phone,laptop) {\n var watch = Math.abs (watch);\n var phone= Math.abs (phone);\n var laptop = Math.abs (laptop);\n var totalWatchCost = watch * 50;\n var totalPhoneCost = phone * 100;\n var totalLaptopCost = laptop * 500;\n var totalCost = totalWatchCost + totalPhoneCost + totalLaptopCost;\n return totalCost;\n }", "function getSmartTicks(val) {\n // Base step between nearby two ticks\n var step = Math.pow(10, Math.trunc(val).toString().length - 1);\n\n // Modify steps either: 1, 2, 5, 10, 20, 50, 100, 200, 500, 1000, 2000...\n if (val / step < 2) {\n step = step / 5;\n } else if (val / step < 5) {\n step = step / 2;\n }\n\n // Add one more step if the last tick value is the same as the max value\n // If you don't want to add, remove \"+1\"\n var slicesCount = Math.ceil((val + 1) / step);\n\n return {\n endPoint: slicesCount * step,\n count: Math.min(10, slicesCount), //show max 10 ticks\n };\n }", "gomoryCut() {\n\t\tvar bbb = 0;\n\t\tvar ind, rest;\n\t\tfor (let i=0; i<this.n; i++) {\n\t\t\trest = this.b_numerator[i] % this.b_denominator[i];\n\t\t\tif (rest < 0) rest += this.b_denominator[i];\n\t\t\trest = rest / this.b_denominator[i];\n\t\t\tif (rest > bbb) {\n\t\t\t\tind = i;\n\t\t\t\tbbb = rest;\n\t\t\t}\n\t\t}\n\t\trest = this.b_numerator[ind] % this.b_denominator[ind];\n\t\tif (rest < 0) rest += this.b_denominator[ind];\n\t\tthis.b_numerator[this.n] = -rest;\n\t\tthis.b_denominator[this.n] = this.b_denominator[ind];\n\n\t\tvar arr_n = new Array(this.m);\n\t\tvar arr_d = new Array(this.m);\n\t\tfor (let i=0; i<this.m; i++) {\n\t\t\trest = this.numerator[ind][i] % this.denominator[ind][i];\n\t\t\tif (rest < 0) rest += this.denominator[ind][i];\n\t\t\tif (rest === 0) {\n\t\t\t\tarr_n[i] = 0;\n\t\t\t\tarr_d[i] = 1;\n\t\t\t} else {\n\t\t\t\tarr_n[i] = -rest;\n\t\t\t\tarr_d[i] = this.denominator[ind][i];\n\t\t\t}\n\t\t}\n\t\tthis.numerator[this.n] = arr_n;\n\t\tthis.denominator[this.n] = arr_d;\n\t\tthis.basis[this.n] = this.n + this.m + 1;\n\t\tthis.n += 1; \n\t}", "function generateBrickBottom() {\n let row = 12;\n for(let i = 1; i <= canvas.width; i++) {\n ctx.fillStyle = '#000';\n ctx.save();\n ctx.fillRect((6 + row)*i, canvas.height - 8, 2, 6);\n ctx.fillRect((0 + row)*i, canvas.height - 14, 2, 6);\n ctx.fillRect((6 + row)*i, canvas.height - 20, 2, 6);\n }\n }", "function getTotalBiomass(reef_fish_arr, c_timeStep, netlock_arr){\n\t\t\t\n\t\t\ttotal_biomass = reef_fish_arr.model[c_timeStep-1].total_biomass;\n\t\t\ttotal_bioRes = reef_fish_arr.model[c_timeStep-1].biomass_inside;\n\t\t\ttotalBiomass_data.push(total_biomass);\n\t\t\tbiomass_reserve_data.push(total_bioRes);\n\t\t\t//kg to metric tons\n\t\t\ttotal_bioRes = total_bioRes / 1000;\n\t\t\ttotal_biomass = total_biomass / 1000;\n\t\t\t\n\t\t\t// push data to data sets \n\t\t\tif(total_bioRes != 0){\n\t\t\t\treserveBio_perArea = total_bioRes / reserve_area;\n\t\t\t}else{\n\t\t\t\treserveBio_perArea = 0;\n\t\t\t}\n\t\t\treserveBiomass_perArea.push(reserveBio_perArea); \n\t\t\t\n\t\t\ttotal_biomass = total_biomass - total_bioRes;\n\t\t\t\n\t\t\tnon_reserve_bioMass.push(total_biomass);\n\t\t\t\n\t\t\tnonReserve_bioPerArea = total_biomass / reef_fish_area;\n\t\t\tnon_reserve_data_perArea.push(nonReserve_bioPerArea);\n\t\n\t}", "function budgetCalculator(watch, phone, laptop) {\n var watchBudget = watch * 50;\n var phoneBudget = phone * 100;\n var laptopBudget = laptop * 500;\n var totalBudget = watchBudget +phoneBudget + laptopBudget;\n return totalBudget;\n}", "function computeNodeBreadths() {\n\t //\n\t var remainingNodes = nodes,\n\t nextNodes,\n\t x = 0;\n\n\t // Work from left to right.\n\t // Keep updating the breath (x-position) of nodes that are target of recently updated nodes.\n\t //\n\t while (remainingNodes.length && x < nodes.length) {\n\t nextNodes = [];\n\t remainingNodes.forEach(function(node) {\n\t node.x = x;\n\t node.dx = nodeWidth;\n\t node.sourceLinks.forEach(function(link) {\n\t if (nextNodes.indexOf(link.target) < 0) {\n\t nextNodes.push(link.target);\n\t }\n\t });\n\t });\n\t remainingNodes = nextNodes;\n\t ++x;\n\t //\n\t }\n\n\t // Optionally move pure sinks always to the right.\n\t if (sinksRight) {\n\t moveSinksRight(x);\n\t }\n\n\t scaleNodeBreadths((size[0] - nodeWidth) / (x - 1));\n\t }", "function drawBricks () {\n gradients = [];\n for (var c = 0; c < store.state.brickColumnCount; c++) {\n gradients[c] = [];\n for (var r = 0; r < store.state.brickRowCount; r++) {\n if (store.state.bricks[c][r].status == 1) {\n var brickX =\n c * (store.state.brickWidth + store.state.brickPadding) +\n store.state.brickOffsetLeft;\n var brickY =\n r * (store.state.brickHeight + store.state.brickPadding) +\n store.state.brickOffsetTop;\n store.state.bricks[c][r].x = brickX;\n store.state.bricks[c][r].y = brickY;\n ctx.beginPath ();\n ctx.rect (\n brickX,\n brickY,\n store.state.brickWidth,\n store.state.brickHeight\n );\n gradients[c][r] = ctx.createLinearGradient (\n brickX,\n brickY,\n brickX,\n brickY + store.state.brickHeight\n );\n gradients[c][r].addColorStop (\n 0,\n store.state.config.colors.bricks[r][0]\n );\n gradients[c][r].addColorStop (\n 1,\n store.state.config.colors.bricks[r][1]\n );\n ctx.fillStyle = gradients[c][r];\n\n ctx.fill ();\n ctx.closePath ();\n }\n }\n }\n}", "function buildspeed(){\n let buildspeed = 0.001*engine.counter('Nworkers');\n let diggerspeed = 1;\n if( engine.perks.lander.diggerspeed )\n diggerspeed = engine.perks.lander.diggerspeed;\n buildspeed += diggerspeed*engine.counter('Ndiggers');\n return check_out_of_resource()*buildspeed;\n}", "function budgetCalculator(watch, phone, laptop) {\n let calculateWatch = watch * 50;\n let calculatePhone = phone * 100;\n let calculateLaptop = laptop * 500;\n let totalCost = calculateWatch + calculatePhone + calculateLaptop;\n return totalCost; \n}" ]
[ "0.8148356", "0.8072053", "0.8037299", "0.7857096", "0.7629519", "0.76155823", "0.75702214", "0.754358", "0.7465463", "0.74312323", "0.7406452", "0.7400688", "0.73857015", "0.7381502", "0.73701406", "0.73399365", "0.7312891", "0.7286587", "0.71886533", "0.7187406", "0.7149952", "0.7139935", "0.7115598", "0.6949386", "0.6884878", "0.67868656", "0.6696811", "0.6647308", "0.6623747", "0.65423125", "0.65046227", "0.6290718", "0.6223908", "0.61238575", "0.60899466", "0.6087123", "0.6054968", "0.60267794", "0.60171664", "0.59972394", "0.59909695", "0.5951729", "0.5924683", "0.59160036", "0.5896589", "0.58606106", "0.5830138", "0.57533824", "0.57446617", "0.5701332", "0.5667843", "0.5643468", "0.56426233", "0.56335974", "0.5625495", "0.55896306", "0.5570576", "0.5565036", "0.55597204", "0.555272", "0.5531079", "0.55042887", "0.54965866", "0.54779303", "0.5466152", "0.5463432", "0.5460153", "0.54522717", "0.54295105", "0.5421719", "0.5412555", "0.5412225", "0.5384279", "0.53841776", "0.5376477", "0.53688353", "0.5354732", "0.5350274", "0.5337693", "0.5333035", "0.5330964", "0.5329022", "0.5327968", "0.53269136", "0.53233534", "0.53181857", "0.5313109", "0.5310028", "0.53074354", "0.5304402", "0.52956355", "0.52920365", "0.5291668", "0.5290969", "0.5286176", "0.5285882", "0.5276407", "0.52762747", "0.5275696", "0.527569" ]
0.75024444
8
function for checking the smallest name from an array. the input shuld be in an array
function tinyFriend(nameArray) { //initial variable are decleared to store the temporary values of string length and sname. Initial values are determined as that do not effect future values. var tinyLength = Infinity; var tinyest = ""; //first condition to check the array have any component in it. if(nameArray.length>0) { //loop is run to itarate the array for(var i = 0; i < nameArray.length; i++) { //nested condition to check if the value is string. if(typeof nameArray[i]=='string') { //another nested condition to find the shortest naame. if(nameArray[i].length<=tinyLength) { tinyLength = nameArray[i].length; tinyest = nameArray[i]; } } //if the value is not string necessary warnings are given. else { return "Digit can not be a Name"; } } //if there are no input then necessary warnings are given. } else { return "No input found"; } return tinyest; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function tinyFriend(nameArr){\n /*sometimes array gives me more than one items which may have equal length for being the minimum one.\n for this reason i want to sort the array and Output the first one.........*/\n const sortedArr = nameArr.sort();\n let minName = sortedArr[0];\n\n //test all the name which one is greater\n for(let i = 0; i < sortedArr.length; i++) {\n if(minName.length > sortedArr[i].length){\n minName = sortedArr[i];\n }\n }\n return minName;\n }", "function tinyFriend(name){\n var smallestName = name[0];\n for(var i = 0; i < name.length; i++){\n var elements = name[i];\n if(elements.length < smallestName.length){\n smallestName = elements;\n } \n }\n return smallestName;\n}", "function tinyFriend(name) {\n\n var smallest = name[0].length;\n var smallestName = name[0];\n\n for (var i = 0; i < name.length; i++) {\n\n if (name[i].length <= 0 || undefined) {\n\n console.log(\"Your field is empty\")\n\n } else {\n\n if (smallest > name[i].length) {\n\n smallest = name[i].length;\n smallestName = name[i];\n\n }\n\n }\n\n\n\n\n }\n return smallestName;\n}", "function tinyFriend(names){\n var smallest = names[0].length;\n for(var i = 0 ; i < names.length; i++){\n var currentNumber = names[i].length;\n if( currentNumber < smallest){\n smallest = currentNumber\n }\n }\n return smallest;\n}", "function tinyName(name){\n var prevName = name[0];\n for (var i=0; i<name.length; i++){\n var newName = name[i];\n if (newName.length < prevName.length){\n prevName = newName;\n }\n }\n return prevName + \" is the smallest name.\";\n}", "function megaFriend(arr){\n //check the array is empty or not\n if(arr.length > 0){\n var firstName = arr[0];\n for(var i = 1; i < arr.length; i++){\n // check the largest name using length\n if(firstName.length < arr[i].length){\n firstName = arr[i];\n }\n }\n return firstName;\n }else{\n return \"Array should not be empty \";\n } \n}", "function bestFriend(array) {\n let bigName = array[0];\n for (let i = 0; i < array.length; i++) {\n const name = array[i];\n if (bigName.length < name.length) {\n bigName = name;\n }\n }\n return bigName;\n}", "function tinyFriend(names){\n var shortest = names[0];\n for(var i=0; i<names.length; i++){\n var element = names[i];\n var elementLength = element.length;\n if (elementLength < shortest.length){\n shortest = element;\n }\n }\nconsole.log(shortest);\n}", "function tinyFriend(name){\n\n var min = name[0].length;\n for(var i = 0; i < name.length; i++){\n var element = name[i].length;\n if(element < min){\n min = element;\n tinyName = name[i];\n }\n }\n\n return tinyName;\n}", "function tinyFriend(name) {\n var min = name[0];\n for (var i = 1; i < name.length; i++) {\n var store = name[i];\n if (min.length > store.length) {\n min = store;\n }\n }\n return min;\n}", "function minInArray(array){\n \n let minelemnt=array[0];\n for (let i=1 ;i<array.length;i++){\n if(array[i]<minelemnt){\n minelemnt = array[i];\n }\n \n }\n return minelemnt;\n}", "function min(a){\n\n var min = a[0];\n for(let i=1;i<a.length;i++){\n\n if(min>a[i]){\n min = a[i];\n }\n\n }\n return min;\n}", "function tinyFriend (array){\n var smallWord = array[0];\n\nfor( var i = 0; i < array.length; i++){\n var tinyName = array[i];\n if(tinyName.length < smallWord.length ){\n smallWord = tinyName;\n }\n \n \n if(smallWord.length == 0){\n var warning = \"empty array\";\n return warning;\n }\n}\n return smallWord \n}", "function tinyFriend(friendsArray) {\n\tlet smallestName = friendsArray[0];\n\n\tfor (let i = 0; i < friendsArray.length; i++) {\n\t\tif (friendsArray[i].length <= 1) {\n\t\t\tsmallestName = \"\";\n\t\t\tconsole.log(`The names are not valid 😏`);\n\t\t} else if (smallestName.length > friendsArray[i].length) {\n\t\t\tsmallestName = friendsArray[i];\n\t\t}\n\t}\n\treturn smallestName;\n}", "function findMin(array) {\n\t\tvar min = array[0];\n\t\tfor (var i = 1; i < array.length; i++) {\n\t\t\tif(min > array[i]){\n\t\t\t\tmin = array[i];\n\t\t\t}\n\t\t};\t\n\t\treturn min;\n\t}", "function minInArray(arr){\r\n\tvar min=arr[0];\r\n\tfor (i=1;i<arr.length;i++){\r\n\t\tif(arr[i]<min){\r\n\t\t\tmin=arr[i]\r\n\t\t}\r\n\t\treturn min\r\n\t}\r\n}", "function findMin(array){\n var min = array[0];\n var index = 0;\n for (var i = 0; i < array.length; i++) {\n if (array[i] < min) {\n min = array[i];\n index = i;\n }\n \n }\n return \"Minimum je \" + min + \", a njegov index je \" + index;\n}", "function minInArray(arr){\n var min = arr[0];\n for (i=0 ; i <arr.length ; i++){\n if(min > arr[i] ){\n \tmin = arr[i]\n }\n }return min;\n}", "function megaFriend(bigName){\n var naam = bigName[0];\n //loop for single name\n for(var i = 0; i < bigName.length; i++){\n //to find largest name\n if(naam.length < bigName[i].length){\n naam = bigName[i];\n }\n }\n return naam;\n}", "function megaFriend(name) {\n var nameLength = 0;\n var largeName;\n if (name.length == 0) {\n return \"Enter any word inside array\";\n }\n\n for (var i = 0; i < name.length; i++) {\n if (name[i].length > nameLength) {\n var nameLength = name[i].length;\n largeName = name[i];\n }\n }\n return largeName;\n}", "function minInArray(input){\n if (toString.call(input) !== \"[object Array]\"){\n return false;\n }\n return Math.min.apply(null, input);\n}", "function megaFriend(name) {\n if (name.length > 0 && Array.isArray(name)) {\n var largestName = name[0];\n var largestNameLength = largestName.length;\n\n for (var i = 1; i < name.length; i++) {\n var currentLength = name[i].length;\n if (currentLength > largestNameLength) {\n largestName = name[i];\n largestNameLength = currentLength;\n }\n }\n return largestName;\n } else {\n return 'Please input right name. '\n }\n}", "function min(array){\n\n let minimum = array[0]; \n\n for(let i = 0 ; i < array.length ; i++){\n\n if(array[i] < minimum)\n minimum = array[i]; \n }\n\n return minimum ; \n}", "function findMin(array){\n \n var min = array[0];\n\n for (var i = 0; i < array.length; i++) {\n\n if(array[i] < min)\n min = array[i]; \n \n }\n\n return min;\n}", "function findMin(arr){\n var min = arr[0];\n for(var i = 0; i<arr.length; i++){\n if(arr[i]<min){\n min = arr[i];\n }\n }\n return min;\n \n}", "function frindsname(arr) {\n if(arr.length==0){\n return \"plz enter a valid array\";\n }\n for (const i = 0; i < arr.length; i++) {\n const name = arr[0];\n if (name.length == 5) {\n return name;\n }\n }\n}", "function min(array) {\n //Write your code here\n}", "function tinyFriend(names) {\n var smallest = names[0];\n for (var i=0; i<names.length; i++){\n var friendList = names[i];\n if (friendList.length<smallest.length){\n smallest=friendList;\n }\n }\n return smallest;\n }", "function indexOfSmallest(a) {\n var lowest = 0;\n for (var i = 1; i < a.length; i++) {\n if (a[i] < a[lowest]) lowest = i;\n }\n return lowest;\n }", "function arrayMin(data) {\n var i = data.length,\n min = data[0];\n \n while (i--) {\n if (data[i] < min) {\n min = data[i];\n }\n }\n return min;\n }", "function megaFriend(name){\n var letter = 0\n var emptyName = \"\"\n\n if (name.length == 0){// For empty input shows error\n return 'Sorry there is no name!!'\n }\n for (var i=0; i< name.length; i++){\n if (name[i].length > letter){ \n letter = name[i].length\n var biggestName = i \n } \n } \n letter = name[biggestName] \n return letter \n }", "function minimum(a) {\n var min = a[0];\n\n for (var i = 0; i < a.length; i++) {\n if (min > a[i]) {\n min = a[i];\n }\n }\n var res = \"Min value is\" + min;\n return res;\n}", "function findSmallest(array) {\n smallest = array[0]\n for(i = 1; i < array.length; i++) {\n if(array[i] < smallest) {\n smallest = array[i]\n }\n }\n return smallest\n}", "function smallestNumArray(array) {\n\tlet small = array[0];\n\tfor (var i = 0; i < array.length; i++) {\n\t\tif (array[i] < small) {\n\t\t\tsmall = array[i];\n\t\t}\n\t}\n\treturn small\n}", "function arrayMin(data) {\n var i = data.length,\n min = data[0];\n\n while (i--) {\n if (data[i] < min) {\n min = data[i];\n }\n }\n return min;\n }", "function arrayMin(data) {\n var i = data.length,\n min = data[0];\n\n while (i--) {\n if (data[i] < min) {\n min = data[i];\n }\n }\n return min;\n }", "function findSmallest() {\n var a = arguments;\n if(a.length>0){\n var small=a[0];\n for(var i = 1; i<a.length;i++){\n if(small>a[i]){\n small=a[i];\n }\n }console.log(small)\n }\n else\n return console.log(Number.MIN_VALUE);\n}", "function indexOfSmallest(a){\n\t\tvar lowest = 0;\n\t\tfor (var i = 1; i < a.length; i++){\n\t\t\tif(a[i] < a[lowest]) lowest = i;\n\t\t}\n\t\treturn lowest;\n\t}", "function min(arr){\n return sortNumbers(arr)[0];\n }", "function smallest(array){\r\n\treturn Math.min.apply(Math,array);\r\n}", "function minimum (arr) {\n var min = arr[0]\n for (var i = 0; i < arr.length; i++) {\n if (arr[i] < min) {\n min = arr[i]\n }\n }\n return min\n}", "function tinyFriend(name){\n \n var shortestWord = name[0].length;\n\n for (var i = 0; i <name.length; i++ ){\n\n var prsentName = name[i].length\n if(prsentName.length< shortestWord){\n\n shortestWord = prsentName;\n }\n }\n\n return shortestWord;\n }", "function tinyFriend(arr) {\n let shortest = \"\";\n\n if (arr.length > 0) {\n for (let i = 0; i < arr.length; i++) {\n if (\n typeof arr[i] === \"string\" &&\n (shortest == \"\" || arr[i].length < shortest.length)\n ) {\n shortest = arr[i];\n }\n }\n }\n\n return shortest;\n}", "function megaFriend(arr){\n var longName = arr[0];\n if(arr == \"\" ){ //condition for blank name\n return \"There is No any Friends Name\";\n }\n if( arr == \" \"*arr.length){ //condition for whitespace\n return \"Blank Name\";\n }\n else{\n for (var i = 0; i < arr.length; i++){ //main condition for friends name\n var element = arr[i];\n if (element.length > longName.length){\n longName = element;\n }\n }\n return longName;\n }\n}", "function getsmallname(ss) {\r\ntotalArray= ss.length;\r\n//console.log(totalArray);\r\n// console.log(ss[1]);\r\n// n = (ss[0].length);\r\n// console.log(n);\r\n oldNumber = 0;\r\n oldName = '';\r\n\r\n for(let i=0; i<totalArray; i++){\r\n\r\n targetNumber = ss[i].length;\r\n targetName = ss[i];\r\n\r\n newNumber = targetNumber;\r\n newName = targetName;\r\n //if (oldNumber == \"\") { oldNumber = 0;}\r\n if (newNumber < oldNumber) {\r\n oldNumber = newNumber;\r\n oldName = newName;\r\n } else {\r\n oldNumber = oldNumber;\r\n oldName = oldName;\r\n\r\n }\r\n console.log(oldName);\r\n\r\n }\r\n\r\n\r\n\r\n}", "function minArray(arr){\r\n\tvar min = arr[1];\r\n\tvar i = 1;\r\n\twhile(arr[i]!=null){\r\n\t\tif(arr[i]<min){\r\n\t\t\tmin = arr[i];\r\n\t\t}\r\n\t\ti++;\r\n\t}\r\n\treturn min;\r\n}", "function arrayMin(data) {\n\t\tvar i = data.length,\n\t\t\tmin = data[0];\n\n\t\twhile (i--) {\n\t\t\tif (data[i] < min) {\n\t\t\t\tmin = data[i];\n\t\t\t}\n\t\t}\n\t\treturn min;\n\t}", "function arrayMin(data) {\n\t\tvar i = data.length,\n\t\t\tmin = data[0];\n\n\t\twhile (i--) {\n\t\t\tif (data[i] < min) {\n\t\t\t\tmin = data[i];\n\t\t\t}\n\t\t}\n\t\treturn min;\n\t}", "function arrayMin(data) {\n\tvar i = data.length,\n\t\tmin = data[0];\n\n\twhile (i--) {\n\t\tif (data[i] < min) {\n\t\t\tmin = data[i];\n\t\t}\n\t}\n\treturn min;\n}", "function findMinimum(arr) {\n let min = arr[0]\n for (i=1; i<arr.length; i++) {\n if (arr[i] < min) {\n min = arr[i]\n }\n }\n return min;\n}", "function minArr( inputArr ){\n var minNumber = Infinity;\n minArr.forEach(element => {\n if(element < minNumber)\n minNumber = element;\n });\n return minNumber;\n}", "function fitFirst(arr){\n if (arr[0] > arr.length){\n console.log(\"Too big!\")\n }else if (arr[0] < arr.length){\n console.log(\"Too small!\")\n }else{\n console.log(\"Just right!\")\n }\n}", "function megaFriend(names) {\n if (names.length < 1) {\n //checking the empty array\n console.log(\"The Array is empty\");\n }\n var mega = names[0];\n for (var i = 0; i < names.length; i++) {\n var element = names[i];\n if (mega.length < element.length) {\n // checking the positions and comparing with the previous names for length,\n mega = element;\n // if true replacing the mega(tmp) value.\n }\n } return mega;\n}", "function findMinmum(array){\n var min; \n var index;\n for( var i = 0; i < array.length - 1; i++) {\n if(array[i] < array[i+1]){\n min = array[i]\n index = i\n }\n else {\n min = array[i+1]\n index = i + 1\n }\n }\n return min + ' je minimum niza a indeks je ' + index;\n}", "function min_array(arr) {\n var min = arr[0];\n for (var i = 0; i < arr.length; i++) {\n if (arr[i] < min) {\n min = arr[i];\n }\n }\n\n console.log(min);\n}", "function getMin(arr) {\n let min = arr[0];\n for (let i = 1; i < arr.length; i++) {\n if (arr[i] < min) {\n min = arr[i];\n }\n }\n return min;\n}", "function getShortest(wordArray) {\n\n}", "function my_min2(arr){\n let min = arr[0];\n for (let i=1; i<arr.length; i++){\n if (arr[i]<min){\n min = arr[i];\n }\n }\n return min;\n}", "function lowestNum(arr){\n var min = arr[0]\n for(i=0;i<arr.length;i++){\n if(min>arr[i]){\n min = arr[i]\n }\n }\n return min\n}", "function megaFriend(nameArray) {\n\n // to hold the counted values of string and and initializing the variable as '0'\n var max = 0;\n\n // to hold the biggest name / string\n var megaName = '';\n\n // error texts\n var errorTxt = 'Sorry, There is an Empty String, Try Again.';\n\n for (var i = 0; i < nameArray.length; i++) {\n var element = nameArray[i];\n var num = element.length;\n if (num == 0) { //validation - if the string legth is Zero / '0'\n return errorTxt;\n }\n else if (num > max) { // comparing the length of the string with previous one\n max = num;\n megaName = nameArray[i];\n }\n }\n return megaName;\n}", "function megaFriend(names) {\n var max = [];\n // checking if the array is empty or have only one element\n if ((names.length == 0) || (names.length == 1)) {\n // error message-1\n return \"Error: Number of element in the array cannot be zero or one. Enter two or more valid names to compare.\";\n }\n else {\n for (var i = 0; i < names.length; i++) {\n var megaName = names[i];\n // checking if the array contains any blank name\n if (names[i].length == 0) {\n // error message-2\n return \"Error: There is a empty string! Please fill up the string with a name\";\n }\n else if (megaName.length > max.length) {\n max = megaName;\n }\n }\n return max;\n }\n}", "function megaFriend(name) {\n var longestName = name[0];\n for (var i = 0; i < name.length; i++) {\n var element = name[i];\n if (longestName.length < element.length) {\n longestName = element;\n }\n else if (longestName.length = element.length) {\n var temp = longestName;\n longestName = temp;\n }\n\n }\n return longestName;\n}", "function min(array){\n\tvar num1= array[0];\n\tvar num2;\n\tfor (var i = 0; i< array.length; i++){\n\t\tnum2= array[i]\n\t\tnum1= Math.min(num1, num2);\n\t}\n return num1;\n}", "function megaFriend(array) {\n var longestName = \"\";\n \n array.forEach(function(name) {\n if(name.length > longestName.length) {\n longestName = name;\n }\n });\n \n return longestName;\n }", "function tinyFriend (names) {\n let tinyName = names[0]\n if (!names || !names.length) {\n return console.log(\"Put some name in the array.\")\n }else {\n for(let i = 0; i < names.length; i++){\n let currentName = names[i];\n if (currentName.length < tinyName.length){\n tinyName = currentName;\n }\n }\n }\n\n return tinyName;\n}", "function indexOfSmallest(a) {\n\t\t\tvar smallest = 0;\n\t\t\tfor (var i = 0; i < a.length; i++) {\n\t\t\t\tif (a[i] < a[smallest]) smallest = i;\n\t\t\t}\n\t\t\treturn smallest;\n\t\t}", "function megaFriend(largestName){\n var larger= largestName[0];\n for(var i=0 ; i<largestName.length ; i++){\n var element= largestName[i];\n if(element > larger){\n larger =element ;\n }\n }\n return larger;\n }", "function findShortestWordAmongMixedElements(arr) {\n // your code here\n if(!arr.length) {\n return \"\";\n }\n \n function hasString(arr) {\n return arr.some(element => typeof element === \"string\");\n }\n //var strings = arr.filter(element => typeof element === \"string\");\n //var shortestPos = Math.min(...strings.map(string => return string.length));\n if(!arr.length || !hasString(arr)) {\n return \"\";\n }\n var strings = arr.filter(element => typeof element === \"string\");\n var stringLengths = strings.map(string => string.length);\n console.log(stringLengths);\n var pos = Math.min(...stringLengths);\n var shortest = stringLengths.indexOf(pos);\n console.log(shortest);\n var ans = strings[shortest];\n return ans;\n}", "function indexOfMin(a) {\n\tvar nMin = 0;\n\tfor (i in a) {\n\t\tif (a[i] < a[nMin])\n\t\t\tnMin = i;\n\t}\n\treturn nMin;\n}// 2015 (c) dr.Igor Mazurok: [email protected]", "function min(array) {\n\tvar a = Infinity;\n\tfor (var i = 0 ; i < array.length ; i++) {\n\t\tif (array[i] < a) {\n\t\t\ta = array[i] ;\n\t\t}\n\t}\n\treturn a ;\n}", "function findSmallestElement(arr) {\n\t// EDGE CASE:\n\t// if the arr length is zero\n\tif (arr.length === 0) {\n\t\t// return 0\n\t\treturn 0;\n\t}\n\t// return Math.min(...arr)\n\tlet min = arr[0];\n\t//iterate through the arr for the element\n\tfor (let element of arr) {\n\t\tif (element < min) {\n\t\t\t// reassign min\n\t\t\tmin = element;\n\t\t}\n\t}\n\t// return min\n\treturn min;\n}", "function indexOfSmallest() {\n\t\t\tindex = 0;\n\t\t\tvar value = diffArray[0];\n\t\t\tfor (var i = 1; i < diffArray.length; i++) {\n \t\t\t\tif (diffArray[i] < value) {\n \t\t\t\tvalue = diffArray[i];\n \t\t\t\tindex = i;\n \t\t\t\t}\n\t\t\t}\n\t\t\tmatchSelect();\n\t\t}", "function indexOfMin(arr) {\n\n var min = arr[0];\n var minIndex = 0;\n\n for (var i = 1; i < arr.length; i++) {\n if (arr[i] < min) {\n minIndex = i;\n min = arr[i];\n }\n }\n return minIndex;\n }", "function fitTheFirstValue(arr){\n if(arr[0] > arr.length){\n console.log(\"Too big!\");\n } else if (arr[0] < arr.length) {\n console.log(\"Too small!\");\n } else {\n console.log(\"Just right!\");\n }\n}", "function tinyFriend(friendName){\n\n let smallerName = friendName[0];\n for(var i = 0; i<friendName.length; i++){\n let name = friendName[i];\n if(name.length < smallerName.length){\n smallerName = name;\n } \n }\n return smallerName;\n}", "function arrayMin( array ) {\n\n\tif ( array.length === 0 ) { return Infinity; }\n\n\tvar min = array[ 0 ];\n\n\tfor ( var i = 1, l = array.length; i < l; ++ i ) {\n\n\t\tif ( array[ i ] < min ) { min = array[ i ]; }\n\n\t}\n\n\treturn min;\n\n}", "function tinyFriend(array){\n var result=[]; \n var count = 0; \n var smallest = array[0].length;\n for(var i=1;i<array.length;i++) \n { if(array[i].length<smallest) \n {\n smallest=array[i].length; \n }\n }\n for(var i=0;i<array.length;i++) \n {\n if(array[i].length==smallest) \n { \n result[count]=array[i];\n count++; \n } \n }\n return result; \n}", "function getMinArray(arrNun1) {\n return Math.min.apply(null, arrNun1);\n}", "function minIndex(array) {\n var min = array[0];\n var index = 0;\n for (var i = 0; i < array.length; i++) {\n if (array[i] < min) {\n min = array[i];\n index = i;\n }\n }\n return min + \" \" + index;\n}", "function find_smallest()\n{\n indexOfSmallest = 0;\n smallestNumber = box_arr[0];\n for (var i = 0; i < box_arr.length; i++) \n {\n if (box_arr[i] < smallestNumber) \n {\n smallestNumber = box_arr[i];\n indexOfSmallest = i;\n }\n //console.log(\"Array in Box -------> \"+box_arr[i]);\n }\n console.log(\"final smallest ---> \"+smallestNumber);\n}", "checkname(array, strName){\r\n const nombres = array.map((elem) => elem.getName().toLowerCase());\r\n if(nombres.includes(strName.toLowerCase())){\r\n throw ({cod: 409, message:'Ya existe ese nombre'});\r\n }\r\n }", "function minOfSorted(arr) {\n for (var i=0; i<arr.length; i++){\n if (arr[i] > arr[i+1]){\n return arr[i+1];\n }\n }\n}", "function megaFriend(nameList) {\n if (nameList.length == 0){\n return \"Array is empty\";\n } else {\n var max = nameList[0].length;\n var name = nameList[0];\n for( var i=1; i<nameList.length; i++ ){\n var element = nameList[i].length;\n if ( element> max ){\n max = element;\n name = nameList[i];\n }\n }\n return name;\n }\n }", "function shorterInArray(arr){\r\n\t\tvar short=arr[0]\r\n\t\tvar length=short.length\r\n\t\tfor(i=1;i<arr.length;i++){\r\n\t\t\tif(arr[i].length<length){\r\n\t\t\t\tshort=arr[i];\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn short;\r\n\t}", "function findLargestSmallest(array) {\n\n validateArrayForNumbersAndStrings(array);\n const stringifiedArray = stringifyArray(array);\n let result = initializeResults(stringifiedArray);\n for (let i = 0; i < stringifiedArray.length; i++) {\n if (stringifiedArray[i] <= result.smallest) {\n result.smallest = stringifiedArray[i];\n }\n if (stringifiedArray[i] >= result.largest) {\n result.largest = stringifiedArray[i];\n }\n }\n return result;\n}", "function findMinNumber(array){\n if(array.length==1){\n return array[0];\n }else{\n let previousMin=findMinNumber(array.slice(1));\n return array[0]<previousMin ? array[0] : previousMin ;\n }\n}", "lowestDistance(arr){\n\t let lowest = arr[0]\n\t let prevLowest = this.totalDistance(arr,arr[0])\n\t\tfor(let i = 0; i<arr.length; i++){\n\t let nextLowest = this.totalDistance(arr,arr[i])\n\t \tif(nextLowest<prevLowest){\n\t prevLowest = nextLowest\n\t \tlowest = arr[i]\n\t }\n\t }\n\t return lowest\n\t}", "function min(x) {\n var i;\n var mmin = x[0];\n\n for (i = 0; i < x.length; i++) {\n if (x[i] < mmin) {\n mmin =x[i];\n }\n }\n return mmin;\n}", "function findMin(arr) {\n let min = 1;\n for (let element of arr) {\n if (element < min) {\n min = element;\n }\n }\n return min;\n}", "function findSmallestNumberAmongMixedElements(arr) {\n if (arr.length < 1) {\n return '';\n } else {\n\n var auxArray = [];\n for (i = 0; i < arr.length; i++) {\n if (typeof arr[i] === 'number') {\n auxArray.push(arr[i]);\n }\n }\n\n if (auxArray.length < 1) {\n return '';\n } else {\n\n auxArray.sort(function compareStrings(a, b) {return b - a;});\n\n return auxArray[0];\n }\n }\n}", "function megaFriend(nameList) {\n var largestName = nameList[0];\n for (var i = 0; i < nameList.length; i++) {\n var test = nameList[i];\n if (test.length > largestName.length) {\n largestName = test;\n }\n\n }\n return largestName;\n}", "function indexOfSmallest(a) {\n return a.indexOf(Math.min.apply(Math, a))\n }", "function megaFriend(array) {\n\n var breadth = 0;\n var longestName;\n\n for (var i = 0; i < array.length; i++) {\n if (array[i].length > breadth) {\n breadth = array[i].length;\n longestName = array[i];\n }\n }\n return longestName;\n}", "function shortestString(array) {\n //Write your code here\n}", "function sortByName2(cnt, array){\n let newArray =array.slice();\n let sortByFirstName = newArray.sort(function (a, b) {\n let nameA = a.name.toLowerCase();\n let nameB = b.name.toLowerCase();\n if (cnt===0) {\n if (nameA < nameB) {\n return -1;\n }\n if (nameA > nameB) {\n return 1;\n }\n return 0;\n }else if(cnt === 1){\n if (nameA > nameB) {\n return -1;\n }\n if (nameA < nameB) {\n return 1;\n }\n return 0;\n }\n });\n return sortByFirstName\n console.log(\"sortByFirstName\")\n console.log(sortByFirstName)\n }", "function my_min1(arr){\n\n for (let i=0; i<arr.length; i++){\n let min= true;\n for(let k=i+1; k<arr.length; k++){\n if (arr[k]<arr[i]){\n min = false;\n }\n\n }\n if (min){\n console.log(arr[i]);\n return arr[i];\n }\n }\n}", "function getMinValue(array){\n return Math.min.apply(null, array);\n}", "searcForName(name, array){\r\n return array.find((ele) => ele.getName().toLowerCase() === name.toLowerCase());\r\n\r\n }", "function shortestWord(strinArray) {\n return Math.min(...strinArray.split(' ').map(item => item.length));\n}", "function findSmallest(arr) {\n\tlet smallest = arr[0];\n\tlet smallest_index = 0;\n\tfor (let i = 1; i < arr.length; i++) {\n\t\tif (arr[i] < smallest) {\n\t\t\tsmallest = arr[i];\n\t\t\tsmallest_index = i;\n\t\t}\n\t}\n\treturn smallest_index;\n}" ]
[ "0.81436825", "0.7581533", "0.74932206", "0.7441095", "0.7299658", "0.715987", "0.70790493", "0.6970749", "0.690564", "0.6881365", "0.68288213", "0.68105567", "0.67774457", "0.6776542", "0.67218417", "0.67113745", "0.6663169", "0.66568935", "0.6647739", "0.66285014", "0.6601047", "0.6591131", "0.6582419", "0.657834", "0.6575515", "0.6476784", "0.64708036", "0.6469231", "0.6467909", "0.6458856", "0.6439624", "0.6395036", "0.63921213", "0.63562137", "0.63553405", "0.63553405", "0.63518256", "0.6350783", "0.63479877", "0.63460696", "0.63210964", "0.63184494", "0.6317416", "0.6305289", "0.6302154", "0.6297081", "0.6296569", "0.6296569", "0.6287723", "0.6279316", "0.62754714", "0.62744504", "0.6261937", "0.6260078", "0.6256641", "0.6250294", "0.62499154", "0.62435997", "0.623844", "0.6227363", "0.62215316", "0.6207672", "0.62075853", "0.62009245", "0.62006694", "0.6193495", "0.6168596", "0.6165781", "0.6164036", "0.6134115", "0.61304605", "0.61245644", "0.6120956", "0.61193186", "0.60977894", "0.6085842", "0.60714346", "0.6066435", "0.6062143", "0.6060897", "0.6060393", "0.6047141", "0.60347575", "0.60301876", "0.6026553", "0.6020151", "0.60198367", "0.60102075", "0.6007157", "0.6002748", "0.6002453", "0.59977037", "0.599156", "0.59678185", "0.595959", "0.5959347", "0.5956781", "0.59544504", "0.5951971", "0.5931548" ]
0.68323696
10
testSchnorrSignature(); TEST FUNCTIONS ================================================================================================
function testHash() { const steps = fRounds + pRounds + 1; // create control values const hash = utils_1.createHash(field, sBoxExp, fRounds, pRounds, stateWidth, roundConstants); const controls = hash([42n, 43n, 44n, 45n]); // set up inputs and assertions const inputs = [[42n], [43n], [44n], [45n]]; const assertions = [ { step: steps - 1, register: 0, value: controls[0] }, { step: steps - 1, register: 1, value: controls[1] } ]; // generate a proof const proof = hashStark.prove(assertions, inputs); console.log('-'.repeat(20)); // verify the proof hashStark.verify(assertions, proof); console.log('-'.repeat(20)); console.log(`Proof size: ${Math.round(hashStark.sizeOf(proof) / 1024 * 100) / 100} KB`); console.log(`Security level: ${hashStark.securityLevel}`); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function test(){\n\tassert.ok(ostatus.salmon.verify_signature(me, key));\n}", "function verifySignature(msg, signature, pub_key) {\n //return curve.sign.detached.verify(str2buf(msg, 'ascii'), str2buf(signature, 'base64'), pub_key);\n return curve.sign.detached.verify(msg, str2buf(signature, 'base64'), pub_key);\n}", "signatureExport (obj, sig) {\n const sigR = sig.subarray(0, 32)\n const sigS = sig.subarray(32, 64)\n if (new BN(sigR).cmp(ecparams.n) >= 0) return 1\n if (new BN(sigS).cmp(ecparams.n) >= 0) return 1\n\n const { output } = obj\n\n // Prepare R\n let r = output.subarray(4, 4 + 33)\n r[0] = 0x00\n r.set(sigR, 1)\n\n let lenR = 33\n let posR = 0\n for (; lenR > 1 && r[posR] === 0x00 && !(r[posR + 1] & 0x80); --lenR, ++posR);\n\n r = r.subarray(posR)\n if (r[0] & 0x80) return 1\n if (lenR > 1 && (r[0] === 0x00) && !(r[1] & 0x80)) return 1\n\n // Prepare S\n let s = output.subarray(6 + 33, 6 + 33 + 33)\n s[0] = 0x00\n s.set(sigS, 1)\n\n let lenS = 33\n let posS = 0\n for (; lenS > 1 && s[posS] === 0x00 && !(s[posS + 1] & 0x80); --lenS, ++posS);\n\n s = s.subarray(posS)\n if (s[0] & 0x80) return 1\n if (lenS > 1 && (s[0] === 0x00) && !(s[1] & 0x80)) return 1\n\n // Set output length for return\n obj.outputlen = 6 + lenR + lenS\n\n // Output in specified format\n // 0x30 [total-length] 0x02 [R-length] [R] 0x02 [S-length] [S]\n output[0] = 0x30\n output[1] = obj.outputlen - 2\n output[2] = 0x02\n output[3] = r.length\n output.set(r, 4)\n output[4 + lenR] = 0x02\n output[5 + lenR] = s.length\n output.set(s, 6 + lenR)\n\n return 0\n }", "verifyTrxSignature() {\n const publicKey = this.data.publicKey;\n const publicKeyBuffer = Buffer.from(publicKey, 'hex'); // Need to use a JS buffer object for Crypto's verify function\n const serial = this.serialize(this.data);\n return pubcrypto.verifySignature(serial, this.signature, publicKeyBuffer);\n }", "function testSign(data) {\n return arCrypt.sign(orgSignKey,data);\n}", "signatureExport(obj, sig) {\n const sigR = sig.subarray(0, 32);\n const sigS = sig.subarray(32, 64);\n if (new BN(sigR).cmp(ecparams.n) >= 0) return 1;\n if (new BN(sigS).cmp(ecparams.n) >= 0) return 1;\n const {\n output\n } = obj; // Prepare R\n\n let r = output.subarray(4, 4 + 33);\n r[0] = 0x00;\n r.set(sigR, 1);\n let lenR = 33;\n let posR = 0;\n\n for (; lenR > 1 && r[posR] === 0x00 && !(r[posR + 1] & 0x80); --lenR, ++posR);\n\n r = r.subarray(posR);\n if (r[0] & 0x80) return 1;\n if (lenR > 1 && r[0] === 0x00 && !(r[1] & 0x80)) return 1; // Prepare S\n\n let s = output.subarray(6 + 33, 6 + 33 + 33);\n s[0] = 0x00;\n s.set(sigS, 1);\n let lenS = 33;\n let posS = 0;\n\n for (; lenS > 1 && s[posS] === 0x00 && !(s[posS + 1] & 0x80); --lenS, ++posS);\n\n s = s.subarray(posS);\n if (s[0] & 0x80) return 1;\n if (lenS > 1 && s[0] === 0x00 && !(s[1] & 0x80)) return 1; // Set output length for return\n\n obj.outputlen = 6 + lenR + lenS; // Output in specified format\n // 0x30 [total-length] 0x02 [R-length] [R] 0x02 [S-length] [S]\n\n output[0] = 0x30;\n output[1] = obj.outputlen - 2;\n output[2] = 0x02;\n output[3] = r.length;\n output.set(r, 4);\n output[4 + lenR] = 0x02;\n output[5 + lenR] = s.length;\n output.set(s, 6 + lenR);\n return 0;\n }", "signatureImport(output, sig) {\n if (sig.length < 8) return 1;\n if (sig.length > 72) return 1;\n if (sig[0] !== 0x30) return 1;\n if (sig[1] !== sig.length - 2) return 1;\n if (sig[2] !== 0x02) return 1;\n const lenR = sig[3];\n if (lenR === 0) return 1;\n if (5 + lenR >= sig.length) return 1;\n if (sig[4 + lenR] !== 0x02) return 1;\n const lenS = sig[5 + lenR];\n if (lenS === 0) return 1;\n if (6 + lenR + lenS !== sig.length) return 1;\n if (sig[4] & 0x80) return 1;\n if (lenR > 1 && sig[4] === 0x00 && !(sig[5] & 0x80)) return 1;\n if (sig[lenR + 6] & 0x80) return 1;\n if (lenS > 1 && sig[lenR + 6] === 0x00 && !(sig[lenR + 7] & 0x80)) return 1;\n let sigR = sig.subarray(4, 4 + lenR);\n if (sigR.length === 33 && sigR[0] === 0x00) sigR = sigR.subarray(1);\n if (sigR.length > 32) return 1;\n let sigS = sig.subarray(6 + lenR);\n if (sigS.length === 33 && sigS[0] === 0x00) sigS = sigS.slice(1);\n if (sigS.length > 32) throw new Error('S length is too long');\n let r = new BN(sigR);\n if (r.cmp(ecparams.n) >= 0) r = new BN(0);\n let s = new BN(sig.subarray(6 + lenR));\n if (s.cmp(ecparams.n) >= 0) s = new BN(0);\n output.set(r.toArrayLike(Uint8Array, 'be', 32), 0);\n output.set(s.toArrayLike(Uint8Array, 'be', 32), 32);\n return 0;\n }", "async function verifySignature(qrCodeText, pemPublicKey) {\n\n var result = new Object();\n result.text = null;\n result.signedDataJson = null;\n\n var signedDataJson = null;\n\n try {\n const separatorIndex = qrCodeText.indexOf(\"#\");\n const signatureBase64 = qrCodeText.substr(0, separatorIndex);\n const signedDataText = qrCodeText.substr(separatorIndex+1);\n \n signedDataJson = JSON.parse(signedDataText);\n\n // Decode signature from Base64.\n const signatureBinStr = window.atob(signatureBase64);\n const signature = binaryStrToArrayBuf(signatureBinStr);\n \n // Calculate SHA256 of signed text.\n var signedData = binaryStrToArrayBuf(signedDataText);\n\n if (signedDataJson.et === 1) {\n // \"RSA256-like\" signature type - apply SHA256 over the signed text explicitly\n // (which is also done by the verify() function below, a second time).\n signedData = await sha256DigestPromise(signedData);\n } else if (signedDataJson.et === 2) {\n // \"RSA256\" signature type - standard verification used, no need to perform \n // SHA256 explicitly.\n } else {\n // Unknown signature type.\n result.text = \"UNKNOWN SIGNATURE TYPE!\";\n return result;\n }\n \n // Import public key.\n const publicKey = await importRsaPublicKeyPem(pemPublicKey, \"sha-256\");\n \n // Verify public key signature over signed data.\n const signatureValid = \n await window.crypto.subtle.verify(\"RSASSA-PKCS1-v1_5\", publicKey, signature, signedData);\n\n if (signatureValid) {\n result.text = \"Signature valid\"\n result.signedDataJson = signedDataJson;\n } else {\n result.text = \"SIGNATURE NOT VALID!\"\n }\n } catch {\n result.text = \"ERROR CHECKING SIGNATURE!\"\n }\n\n return result;\n}", "function VerifySignature(message) {\n var cipher = message[0]; //TEMP: message components are stored in array\n var signature = message[1];\n var publicSigningKey = message[2];\n console.log(publicSigningKey.verify(cipher, signature));\n}", "function verifySignatureBox(signature, pub_key) {\n return curve.sign.open(str2buf(signature, 'base64'), pub_key);\n}", "signatureImport (output, sig) {\n if (sig.length < 8) return 1\n if (sig.length > 72) return 1\n if (sig[0] !== 0x30) return 1\n if (sig[1] !== sig.length - 2) return 1\n if (sig[2] !== 0x02) return 1\n\n const lenR = sig[3]\n if (lenR === 0) return 1\n if (5 + lenR >= sig.length) return 1\n if (sig[4 + lenR] !== 0x02) return 1\n\n const lenS = sig[5 + lenR]\n if (lenS === 0) return 1\n if ((6 + lenR + lenS) !== sig.length) return 1\n\n if (sig[4] & 0x80) return 1\n if (lenR > 1 && (sig[4] === 0x00) && !(sig[5] & 0x80)) return 1\n\n if (sig[lenR + 6] & 0x80) return 1\n if (lenS > 1 && (sig[lenR + 6] === 0x00) && !(sig[lenR + 7] & 0x80)) return 1\n\n let sigR = sig.subarray(4, 4 + lenR)\n if (sigR.length === 33 && sigR[0] === 0x00) sigR = sigR.subarray(1)\n if (sigR.length > 32) return 1\n\n let sigS = sig.subarray(6 + lenR)\n if (sigS.length === 33 && sigS[0] === 0x00) sigS = sigS.slice(1)\n if (sigS.length > 32) throw new Error('S length is too long')\n\n let r = new BN(sigR)\n if (r.cmp(ecparams.n) >= 0) r = new BN(0)\n\n let s = new BN(sig.subarray(6 + lenR))\n if (s.cmp(ecparams.n) >= 0) s = new BN(0)\n\n output.set(r.toArrayLike(Uint8Array, 'be', 32), 0)\n output.set(s.toArrayLike(Uint8Array, 'be', 32), 32)\n\n return 0\n }", "function sign_verify(message, smesssage, cryptopk,len){\n\tvar bo = libhel.Ntrusign_Verify(message,smesssage,cryptopk,len);\n\treturn bo;\n}", "function TEST(){\r\n\t\t// TEST:\r\n\t\tvar rand_byte = (window.crypto.getRandomValues(new Uint8Array(1))[0]) + 8;\r\n\t\tconsole.log('rand_byte', rand_byte);\r\n\t\t\r\n\t\tRSABigInteger.GenerateRSAKeys(rand_byte);\t//generate keys\r\n\t\t//console.log('RSABigInteger.RSA_key', RSABigInteger.RSA_key);\r\n\t\t\r\n\t\tvar rand_message = window.crypto.getRandomValues(new Uint8Array(window.crypto.getRandomValues(new Uint8Array(1))[0]));\r\n\t\t//console.log('rand_message', rand_message.toString());\r\n\r\n\t\tvar readyInterval = setInterval(\t\t\t//wait some time to write key.\r\n\t\t\tfunction(){\r\n\t\t\t\tif(ready===false){return;} \t\t\t//if not ready, return and repeat, by interval\r\n\t\t\t\telse{clearInterval(readyInterval)}; //else clearInterval, and continue with this code.\r\n\t\t\t\t\r\n\t\t\t\tvar encdec = false;\t\t\t\t//test encrypt-decrypt\r\n\t\t\t\tconsole.log(\r\n\t\t\t\t\t'RSA encrypt by pub, decrypt by priv:\\t',\r\n\t\t\t\t\t(\r\n\t\t\t\t\t\tencdec =\r\n\t\t\t\t\t\tRSABigInteger.CompareBytes(\r\n\t\t\t\t\t\t\trand_message,\r\n\t\t\t\t\t\t\tRSABigInteger.DecryptBytes(\r\n\t\t\t\t\t\t\t\tRSABigInteger.RSA_key.xml_privKey,\r\n\t\t\t\t\t\t\t\tRSABigInteger.EncryptBytes(\r\n\t\t\t\t\t\t\t\t\tRSABigInteger.RSA_key.xml_pubKey,\r\n\t\t\t\t\t\t\t\t\trand_message,\r\n\t\t\t\t\t\t\t\t\tfalse\r\n\t\t\t\t\t\t\t\t),\r\n\t\t\t\t\t\t\t\tfalse\r\n\t\t\t\t\t\t\t)\r\n\t\t\t\t\t\t)\r\n\t\t\t\t\t\t, encdec\t\t//and return it\r\n\t\t\t\t\t)\r\n\t\t\t\t);\r\n\r\n\t\t\t\tvar signverify = false;\t\t\t//test encrypt-decrypt\r\n\t\t\t\tconsole.log(\r\n\t\t\t\t\t'sign by priv, verify signature by pub:\\t',\r\n\t\t\t\t\t(\r\n\t\t\t\t\t\tsignverify = \r\n\t\t\t\t\t\t\tRSABigInteger.CompareBytes(\r\n\t\t\t\t\t\t\t\trand_message,\r\n\t\t\t\t\t\t\t\tRSABigInteger.DecryptBytes(\r\n\t\t\t\t\t\t\t\t\tRSABigInteger.RSA_key.xml_pubKey,\r\n\t\t\t\t\t\t\t\t\tRSABigInteger.EncryptBytes(\r\n\t\t\t\t\t\t\t\t\t\tRSABigInteger.RSA_key.xml_privKey,\r\n\t\t\t\t\t\t\t\t\t\trand_message,\r\n\t\t\t\t\t\t\t\t\t\ttrue\r\n\t\t\t\t\t\t\t\t\t),\r\n\t\t\t\t\t\t\t\t\ttrue\r\n\t\t\t\t\t\t\t\t)\r\n\t\t\t\t\t\t\t)\r\n\t\t\t\t\t\t, signverify\t//and return it\r\n\t\t\t\t\t)\r\n\t\t\t\t);\r\n\r\n\t\t\t\tif(encdec === false || signverify === false){\r\n\t\t\t\t\tif(encdec === false){console.log('encdec === false');}\r\n\t\t\t\t\telse if(signverify === false){console.log('signverify === false');}\r\n\t\t\t\t\t//\tand show two variables for static-test\r\n\t\t\t\t\tconsole.log(\r\n\t\t\t\t\t\t'//multistring variable with privkey to load it;\\n'+\r\n\t\t\t\t\t\t'var rsaprivkey = (function () {/*'+RSABigInteger.RSA_key.xml_privKey+\r\n\t\t\t\t\t\t'\\n*/}).toString().match(/[^]*\\\\\\/\\\\*([^]*)\\\\*\\\\\\/\\\\}$\\/)[1];'\t+\t'\\n' +\r\n\t\t\t\t\t\t'//bytearray with generated message\\n'+\r\n\t\t\t\t\t\t'var rand_message = new Uint8Array(['+rand_message.toString()+']);'\r\n\t\t\t\t\t);\r\n\t\t\t\t}\r\n\t\t\t},\r\n\t\t\t1\t//wait to generate or load keys, and write it.\r\n\t\t);\r\n\t}", "function signTheFile() {\n var plaintext = document.querySelector('.output').value\n // initialize\n var sig = new KJUR.crypto.Signature({\"alg\": \"SHA1withRSA\"});\n // initialize for signature generation\n sig.init(object_2.private_key); // rsaPrivateKey of RSAKey object\n // update data\n sig.updateString(plaintext)\n // calculate signature\n signature = sig.sign()\n alert(\"signature signed.If you will make any changes in given signature it will become invalid\");\n } // end of signTheFile click handler", "verifySignature(reqq){\n\tif(reqq.address && reqq.signature){\n\t\tlet memdata=this.mempool.get(reqq.address); \n\t\tconsole.log(memdata.message);\n\t let response= bitcoinmsg.verify(memdata.message, reqq.address, reqq.signature);\n\t return response;\n\t}return false;\n}", "function validateSignature(encodedHeader, encodedPayload, signature) {\n var signingInput = encodedHeader + \".\" + encodedPayload;\n var signed = CryptoJS.HmacSHA256(signingInput, client_secret);\n var encodedSigned = b64tob64u(signed.toString(CryptoJS.enc.Base64));\n return encodedSigned == signature;\n}", "static verifySignature(publicKey, signature, dataHash) {\n\treturn ec.keyFromPublic(publicKey, 'hex').verify(dataHash, signature);\n}", "function makeSignature(s) {\n if (typeof s !== \"string\")\n throw Error(`vbios.makeSignature(): Signature must be a string, not '${typeof s}'`);\n\n if (s.length < 2 || s.length > 4)\n throw Error(`vbios.makeSignature(): Signature size must be between 2-4 characters, not '${s.length}'`);\n\n const a = s.charCodeAt(0);\n const b = s.charCodeAt(1);\n const c = s.charCodeAt(2) || 0;\n const d = s.charCodeAt(3) || 0;\n return (d << 24) | (c << 16) | (b << 8) | a;\n}", "async function checkSignature(signedString, key, data) {\n const digestToCompare = await addSignature(key, data);\n return digestToCompare === signedString;\n}", "verifyRequestSignature( req, res, buf ) {\n var signature = req.headers[ \"x-hub-signature\" ];\n\n if ( !signature ) {\n // For testing, let's log an error. In production, you should throw an\n // error.\n console.error( \"Couldn't validate the signature.\" );\n } else {\n var elements = signature.split( '=' );\n var method = elements[ 0 ];\n var signatureHash = elements[ 1 ];\n\n var expectedHash = crypto.createHmac( 'sha1', envVars.APP_SECRET )\n .update( buf )\n .digest( 'hex' );\n\n if ( signatureHash != expectedHash ) {\n throw new Error( \"Couldn't validate the request signature.\" );\n }\n }\n }", "function verify (keys, sig, msg) {\n if(isObject(sig))\n throw new Error('signature should be base64 string, did you mean verifyObj(public, signed_obj)')\n return curves[getCurve(keys)].verify(\n u.toBuffer(keys.public || keys),\n u.toBuffer(sig),\n isBuffer(msg) ? msg : new Buffer(msg)\n )\n}", "function verify (publicKey, sig, msg) {\n if (typeof sig === 'object') {\n throw new Error('signature should be base64 string,' +\n 'did you mean verifyObj(public, signed_obj)')\n }\n\n // if we're given a string, we need to convert that\n // into a publicKey instance\n if (typeof publicKey === 'string') {\n // console.log('****is string*****', publicKey)\n return webcrypto.subtle.importKey(\n 'raw',\n utils.base64ToArrBuf(publicKey),\n { name: 'ECDSA', namedCurve: 'P-256' },\n true,\n ['verify']\n )\n .then(pubKey => {\n console.log(typeof msg)\n return webcrypto.subtle.verify(\n {\n name: ECC_WRITE_ALG,\n hash: { name: DEFAULT_HASH_ALG }\n },\n pubKey,\n utils.normalizeBase64ToBuf(sig),\n utils.normalizeUnicodeToBuf(msg, DEFAULT_CHAR_SIZE)\n )\n })\n .then(isOk => {\n console.log('is ok?????', isOk)\n return isOk\n })\n }\n\n return webcrypto.subtle.verify(\n {\n name: ECC_WRITE_ALG,\n hash: { name: DEFAULT_HASH_ALG }\n },\n publicKey,\n utils.normalizeBase64ToBuf(sig),\n utils.normalizeUnicodeToBuf(msg, DEFAULT_CHAR_SIZE)\n )\n}", "function verifyRequestSignature(req, res, buf) {\n let signature = req.headers[\"x-hub-signature\"];\n if (!signature) {\n //console.error(\"[verifyRequestSignature] La request no contiene la firma de la aplicacion(APP_SECRET).\");\n throw new Error(\"La request no contiene en el encabezado la firma de la aplicacion(APP_SECRET).\");\n }\n console.trace(\"[verifyRequestSignature] Verificando la firma de la aplicacion(APP_SECRET). signature:\", signature);\n\n let elements = signature.split('=');\n // GLOZADA: desuso\n //let method = elements[0];\n let signatureHash = elements[1];\n let expectedHash = crypto.createHmac('sha1', APP_SECRET)\n .update(buf)\n .digest('hex');\n if (signatureHash != expectedHash) {\n //console.error(\"[verifyRequestSignature] La firma de la aplicacion(APP_SECRET) presente en la request no es valida.\");\n throw new Error(\"La firma de la aplicacion(APP_SECRET) presente en la request no es valida.\");\n }\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an\n // error.\n console.error(\"Couldn't validate the signature.\");\n } else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', APP_SECRET)\n .update(buf)\n .digest('hex');\n console.log(expectedHash);\n\n if (signatureHash != expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an \n // error.\n console.error(\"Couldn't validate the signature.\");\n } else {\n //console.error(\"APP_SECRET\", APP_SECRET);\n //console.error(\"PAGE_ACCESS_TOKEN\", PAGE_ACCESS_TOKEN);\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n var expectedHash = crypto.createHmac('sha1', APP_SECRET)\n .update(buf)\n .digest('hex');\n //console.error(\"expectedHash\", expectedHash);\n //console.error(\"signatureHash\", signatureHash);\n //if (signatureHash != expectedHash) {\n // throw new Error(\"Couldn't validate the request signature.\");\n //}\n }\n}", "function isValidSignature (pem_cert, signature, requestBody) {\n const verifier = crypto.createVerify('RSA-SHA1')\n verifier.update(requestBody, 'utf8')\n return verifier.verify(pem_cert, signature, SIGNATURE_FORMAT)\n}", "function test_error_verify_signature_verify_certificate_with_file() {\n\tvar clientPemPath = \"./test/unit/cert/testUser/client.pem\";\n\tvar clientPrvPath = \"./test/unit/cert/testUser/clientPriv.pem\";\n\tvar clientPubPath = \"./test/unit/cert/testUser/clientPub.pem\";\n\tvar rootPemPath = \"./test/unit/cert/root.pem\";\n\tvar otherClientPubPath = \"/home/kyoungmin/tmp/root.pem\";\n\tvar message = \"test-message-for-signature\";\n\tvar hashAlg = \"sha1\"; // \"sha256\"\n\n\tvar keyPair = loadClientCertificatePrvKey(clientPemPath, clientPrvPath);\n\tconsole.log(\"---> 1. load cleint certificate from file\");\n\tvar hashMessage = doHashMessage(hashAlg, message);\n\tvar signedHashMessage = doSignWithClientPrvkey(hashMessage, keyPair.prvKey);\n\tconsole.log(\"---> 2. hash temp message and sign the temp message with client private key\");\n\tvar caCert = loadFabricClientCertificate(rootPemPath);\n\tconsole.log(\"---> 3. load fabric client certificate from file\");\n\tvar clientCert = getClientCertificateFromBlockchain(clientPemPath);\n\tconsole.log(\"---> 4. get client certificate from blockchain\");\n\tif (!verifyClientCertificate(caCert, clientCert)) {\n\t\tconsole.log(\"5. failed to verify client certificate. skip to verify signature\");\n\t\treturn;\n\t} else {\n\t\tconsole.log(\"---> 5. succeeded to verify client certificate\");\n\t}\n\tvar caEc = loadFabricClientECDSA(rootPemPath);\n\tvar pubHex = loadClientPubKey(otherClientPubPath);\n\n\tif (!verifySignature(caEc, pubHex, hashMessage, signedHashMessage)) {\n\t\tconsole.log(\"6. failed to verify signature\");\n\t} else {\n\t\tconsole.log(\"---> 6. succeeded to verify signature\");\n\t\tconsole.log(\"############# successful login ##############\");\n\t}\n}", "function test_verify_signature_verify_certificate_with_file() {\n\tvar clientPemPath = \"./test/unit/cert/testUser/client.pem\";\n\tvar clientPrvPath = \"./test/unit/cert/testUser/clientPriv.pem\";\n\tvar clientPubPath = \"./test/unit/cert/testUser/clientPub.pem\";\n\tvar rootPemPath = \"./test/unit/cert/root.pem\";\n\tvar message = \"test-message-for-signature\";\n\tvar hashAlg = \"sha1\"; // \"sha256\"\n\n\tvar keyPair = loadClientCertificatePrvKey(clientPemPath, clientPrvPath);\n\tconsole.log(\"---> 1. load cleint certificate from file\");\n\tvar hashMessage = doHashMessage(hashAlg, message);\n\tvar signedHashMessage = doSignWithClientPrvkey(hashMessage, keyPair.prvKey);\n\tconsole.log(\"---> 2. hash temp message and sign the temp message with client private key\");\n\tvar caCert = loadFabricClientCertificate(rootPemPath);\n\tconsole.log(\"---> 3. load fabric client certificate from file\");\n\tvar clientCert = getClientCertificateFromBlockchain(clientPemPath);\n\tconsole.log(\"---> 4. get client certificate from blockchain\");\n\tif (!verifyClientCertificate(caCert, clientCert)) {\n\t\tconsole.log(\"5. failed to verify client certificate. skip to verify signature\");\n\t\treturn;\n\t} else {\n\t\tconsole.log(\"---> 5. succeeded to verify client certificate\");\n\t}\n\tvar caEc = loadFabricClientECDSA(rootPemPath);\n\tvar pubHex = loadClientPubKey(clientPubPath);\n\n\tif (!verifySignature(caEc, pubHex, hashMessage, signedHashMessage)) {\n\t\tconsole.log(\"6. failed to verify signature\");\n\t} else {\n\t\tconsole.log(\"---> 6. succeeded to verify signature\");\n\t\tconsole.log(\"############# successful login ##############\");\n\t}\n}", "async function getSigData(sigVer, privKey, noteValue, adnMessage) {\n let sigString = ''\n sigString += adnMessage.text.trim()\n sigString += noteValue.timestamp\n if (noteValue.quote) {\n sigString += noteValue.quote.id\n sigString += noteValue.quote.author\n sigString += noteValue.quote.text.trim()\n if (adnMessage.reply_to) {\n sigString += adnMessage.reply_to\n }\n }\n /*\n sigString += [...attachmentAnnotations, ...previewAnnotations]\n .map(data => data.id || data.image.id)\n .sort()\n .join();\n */\n sigString += sigVer\n const sigData = Buffer.from(bb.wrap(sigString, 'utf8').toArrayBuffer())\n // symKey\n const sig = await libsignal.curve.calculateSignature(privKey, sigData)\n // const sig = makeSymmetricKey(privKey, sigData)\n return sig.toString('hex')\n}", "function verifyRequestSignature(req, res, buf) {\n\tvar signature = req.headers[\"x-hub-signature\"]\n\n\tif (!signature) {\n\t\t// For testing, let's log an error. In production, you should throw an \n\t\t// error.\n\t\tconsole.error(\"Couldn't validate the signature.\")\n\t} else {\n\t\tvar elements = signature.split(\"=\")\n\t\t//var method = elements[0];\n\t\tvar signatureHash = elements[1]\n \n\t\tvar expectedHash = crypto.createHmac(\"sha1\", req.appSecret)\n\t\t\t.update(buf)\n\t\t\t.digest(\"hex\")\n\n\t\tif (signatureHash != expectedHash) {\n\t\t\tthrow new Error(\"Couldn't validate the request signature.\")\n\t\t}\n\t}\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an\n // error.\n console.error(\"Couldn't validate the signature.\");\n } else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', FB_APP_SECRET)\n .update(buf)\n .digest('hex');\n\n if (signatureHash != expectedHash) {\n console.log(signatureHash);\n console.log(expectedHash);\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n // In DEV, log an error. In PROD, throw an error.\n console.error(\"Couldn't validate the signature.\");\n } else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', FB_APP_SECRET)\n .update(buf)\n .digest('hex');\n\n //console.log(\"signatureHash: \" + signatureHash);\n //console.log(\"expectedHash: \" + expectedHash);\n\n if (signatureHash != expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "static verify(data, publicKey, sign){\n if (typeof data !== \"string\") throw new Error(\"Data must be a string\");\n let ic = new iCrypto();\n ic.setRSAKey(\"pubk\", publicKey, \"public\")\n .addBlob(\"sign\", sign)\n .hexToBytes('sign', \"signraw\")\n .addBlob(\"b\", data);\n ic.publicKeyVerify(\"b\", \"sign\", \"pubk\", \"v\");\n return ic.get(\"v\");\n }", "function getSignature(url, params, headers, secretKey) {\n // To remove references, objects are passed by references in JS\n const message = JSON.parse(JSON.stringify(params));\n\n // We are passing the extra key values pairs before serializing our request params\n message['X-NONCE'] = headers['X-NONCE'];\n message['X-RECV-WINDOW'] = headers['X-RECV-WINDOW'];\n\n if (Object.keys(params).length === 0)\n message['X-REQUEST-URL'] = url;\n\n else\n message['X-REQUEST-URL'] = `${url}?${qs.stringify(params)}`;\n\n const messageSorted = sortObjectAlphabetically(message);\n\n console.log('messageSorted', messageSorted);\n\n const messageString = JSON.stringify(messageSorted);\n\n const signature = CryptoJS.HmacSHA256(messageString, secretKey).toString();\n\n console.log('signature', signature);\n\n return signature;\n}", "static createSignature(method, endPoint, headerParameters, bodyParameters, secretKey, tokenSecret) {\n if(typeof jsSHA !== 'undefined') {\n let headerAndBodyParameters = angular.copy(headerParameters);\n let bodyParameterKeys = Object.keys(bodyParameters);\n for(let i = 0; i < bodyParameterKeys.length; i++) {\n headerAndBodyParameters[bodyParameterKeys[i]] = encodeURIComponent(bodyParameters[bodyParameterKeys[i]]);\n }\n let signatureBaseString = method + '&' + encodeURIComponent(endPoint) + '&';\n let headerAndBodyParameterKeys = (Object.keys(headerAndBodyParameters)).sort();\n for(i = 0; i < headerAndBodyParameterKeys.length; i++) {\n if(i == headerAndBodyParameterKeys.length - 1) {\n signatureBaseString += encodeURIComponent(headerAndBodyParameterKeys[i] + '=' + headerAndBodyParameters[headerAndBodyParameterKeys[i]]);\n } else {\n signatureBaseString += encodeURIComponent(headerAndBodyParameterKeys[i] + '=' + headerAndBodyParameters[headerAndBodyParameterKeys[i]] + '&');\n }\n }\n let oauthSignatureObject = new jsSHA(signatureBaseString, 'TEXT');\n\n let encodedTokenSecret = '';\n if (tokenSecret) {\n encodedTokenSecret = encodeURIComponent(tokenSecret);\n }\n\n headerParameters.oauth_signature = encodeURIComponent(oauthSignatureObject.getHMAC(encodeURIComponent(secretKey) + '&' + encodedTokenSecret, 'TEXT', 'SHA-1', 'B64'));\n let headerParameterKeys = Object.keys(headerParameters);\n let authorizationHeader = 'OAuth ';\n for(i = 0; i < headerParameterKeys.length; i++) {\n if(i == headerParameterKeys.length - 1) {\n authorizationHeader += headerParameterKeys[i] + '='' + headerParameters[headerParameterKeys[i]] + ''';\n } else {\n authorizationHeader += headerParameterKeys[i] + '='' + headerParameters[headerParameterKeys[i]] + '',';\n }\n }\n return { signature_base_string: signatureBaseString, authorization_header: authorizationHeader, signature: headerParameters.oauth_signature };\n } else {\n return 'Missing jsSHA JavaScript library';\n }\n }", "function verify_webhook_sig(sig, secret, body)\n{\n var hmac = crypto.createHmac('sha1', secret);\n hmac.update(body);\n var digest = hmac.digest('hex');\n return sig == digest;\n}", "function test_verify_certificate() {\n\ttry {\n\t var caEc = cert_util.generateEcKeypair('secp256r1');\n\n\t var ec_cert = new EC_CERT(caEc);\n\t // var ec_cert = new EC_CERT(); // default curve is 'secp256r1'\n\t ec_cert.initTBSCert();\n\t \n\t var clientEc = cert_util.generateEcKeypair('secp256r1');\n\t \n\t ec_cert.setSubjectPublicKeyByGetKey(clientEc);\n\t \n\t ec_cert.setSerialNumberByParam({'int': 1234});\n\t ec_cert.setSignatureAlgByParam({'name': 'SHA1withRSA', 'paramempty': false}); // NOTE: paramempty: false to get NULL in AlgorithmIdentifier (possibly not required)\n\t var dn = \"/C=US/ST=Maryland/L=Pasadena/O=BrentBaccala/OU=R&BD/[email protected]/SN=Park\";\n\t ec_cert.setIssuerByParam({'str': dn}); \n\n\t var str1 = cert_util.getCurrentDate() + \"Z\";\n\t var obj1 = {'str': str1};\n\t ec_cert.setNotBeforeByParam(obj1);\n\n\t var str2 = cert_util.getAddMonthsDate(null, 3) + \"Z\";\n\t var obj2 = {'str': str2};\n\t ec_cert.setNotAfterByParam(obj2);\n\n\t ec_cert.setSubjectByParam({'str': \"/C=US/O=TEST\"});\n\t // extension\n\t ec_cert.appendExtension(new rs.asn1.x509.BasicConstraints({'cA': false}));\n\t ec_cert.appendExtension(new rs.asn1.x509.KeyUsage({'bin':'11'}));\n\t ec_cert.appendExtension(new rs.asn1.x509.CRLDistributionPoints({'uri':'http://www.infosec/com/newict'}));\n\n\t ec_cert.doSign();\n\t // ec_cert.saveFile(\"/home/kyoungmin/tmp/skbc2.pem\");\n\t var certPEM = ec_cert.getPemString();\n\t // console.log(certPEM);\n\n\t // var caCertPem = getSelfSignCertificate(caEc);\n\t var pemFileFullPath = \"/home/kyoungmin/tmp/root.pem\";\n\t var result = getSelfSignCertificate(caEc, pemFileFullPath);\n\t if (pemFileFullPath != result) {\n\t \tconsole.log(\"failed to save pem file: \" + result);\n\t \treturn;\n\t }\n\t var caCertPem = cert_util.generateCertPEMFromPath(pemFileFullPath);\n\t console.log(\"verify certificate with ca certificate ---> \" + cert_util.verifyCertificate(caCertPem, certPEM));\n\t} catch (exception) {\n\t console.log(exception);\n\t}\n}", "function getSignature() {\r\n var encode = \"\"\r\n for(var i = 0; i < arguments.length; i++) {\r\n encode += arguments[i]\r\n }\r\n encode += secret\r\n return Qt.md5(encode)\r\n}", "verify(signature, msg) {\n const verify = sodium.crypto_auth_hmacsha256_verify(signature, msg, this.key);\n return verify;\n }", "function onSignatureStarted(err, restRes, body) {\n\n if (restPki.checkResponse(err, restRes, body, next)) {\n\n // Read PEM-encoded private-key file for (\"Pierre de Fermat\")\n var pkey = fs.readFileSync('./resources/fermat-pkey.pem', 'binary');\n\n // Get signature algorithm from the digestAlgorithmOid. It will be used by the crypto library\n // to perform the signature.\n var signatureAlgorithm;\n switch(restRes.body.digestAlgorithmOid) {\n case '1.2.840.113549.2.5':\n signatureAlgorithm = 'RSA-MD5';\n break;\n case '1.3.14.3.2.26':\n signatureAlgorithm = 'RSA-SHA1';\n break;\n case '2.16.840.1.101.3.4.2.1':\n signatureAlgorithm = 'RSA-SHA256';\n break;\n case '2.16.840.1.101.3.4.2.2':\n signatureAlgorithm = 'RSA-SHA384';\n break;\n case '2.16.840.1.101.3.4.2.3':\n signatureAlgorithm = 'RSA-SHA512';\n break;\n default:\n signatureAlgorithm = null;\n }\n\n // Create a new signature, setting the algorithm that will be used\n var sign = crypto.createSign(signatureAlgorithm);\n\n // Set the data that will be signed\n sign.write(new Buffer(restRes.body.toSignData, 'base64')); \n sign.end();\n\n // Perform the signature and receiving Base64-enconding of the signature\n var signature = sign.sign({ key: pkey, passphrase: '1234' }, 'base64');\n\n // Call the action POST Api/CadesSignatures/{token}/SignedBytes on REST PKI, which finalizes the signature process and \n // returns the signed PDF\n request.post(client.endpoint + 'Api/CadesSignatures/' + restRes.body.token + '/SignedBytes', {\n \n json: true,\n headers: { 'Authorization': 'Bearer ' + client.accessToken},\n body: { 'signature': signature }\n \n }, onSignatureCompleted);\n }\n }", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an \n // error.\n console.error(\"Couldn't validate the signature.\");\n } else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', APP_SECRET)\n .update(buf)\n .digest('hex');\n\n if (signatureHash != expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an \n // error.\n console.error(\"Couldn't validate the signature.\");\n } else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', APP_SECRET)\n .update(buf)\n .digest('hex');\n\n if (signatureHash != expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an \n // error.\n console.error(\"Couldn't validate the signature.\");\n } else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', APP_SECRET)\n .update(buf)\n .digest('hex');\n\n if (signatureHash != expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an \n // error.\n console.error(\"Couldn't validate the signature.\");\n } else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', APP_SECRET)\n .update(buf)\n .digest('hex');\n\n if (signatureHash != expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an \n // error.\n console.error(\"Couldn't validate the signature.\");\n } else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', APP_SECRET)\n .update(buf)\n .digest('hex');\n\n if (signatureHash != expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an \n // error.\n console.error(\"Couldn't validate the signature.\");\n } else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', APP_SECRET)\n .update(buf)\n .digest('hex');\n\n if (signatureHash != expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "function verifyRequestSignature(req, res, buf) {\n\n const signature = req.headers['x-hub-signature'];\n\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an \n // error.\n console.error(\"Couldn't validate the signature.\");\n } else {\n const elements = signature.split('=');\n const method = elements[0];\n const signatureHash = elements[1];\n\n const expectedHash = crypto.createHmac('sha1', APP_SECRET)\n .update(buf)\n .digest('hex');\n\n if (signatureHash !== expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an\n // error.\n console.error(\"Couldn't validate the signature.\");\n } else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', APP_SECRET)\n .update(buf)\n .digest('hex');\n\n if (signatureHash != expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "function verifyRequestSignature(req, res, buf) {\n try {\n var signature = req.headers[\"x-hub-signature\"];\n if (!signature) {\n throw new Error(\"Could not find a signature.\");\n } else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n var expectedHash = crypto.createHmac('sha1', APP_SECRET).update(buf).digest('hex');\n if (signatureHash != expectedHash) {\n throw new Error(\"Unexpected signature found.\");\n }\n }\n } catch (err) {\n console.error(err);\n throw new Error(err);\n }\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an \n // error.\n console.error(\"Couldn't validate the signature.\");\n }\n else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', APP_SECRET)\n .update(buf)\n .digest('hex');\n\n if (signatureHash != expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "function getSignature() {\n var encode = \"\"\n for(var i = 0; i < arguments.length; i++) {\n encode += arguments[i]\n }\n encode += secret\n return Qt.md5(encode)\n}", "function _getSignatureInputByString(sHead, sPayload) {\r\n\treturn utf8tob64u(sHead) + \".\" + utf8tob64u(sPayload);\r\n }", "function verify(hex, sig, publicKey) {\r\n if (!verify_1.isPublicKey(publicKey)) {\r\n throw new Error(\"Invalid public key\");\r\n }\r\n if (!verify_1.isPublicKey(publicKey, true)) {\r\n publicKey = core_1.getPublicKeyUnencoded(publicKey);\r\n }\r\n const sigObj = getSignatureFromHex(sig);\r\n const messageHash = u_1.sha256(hex);\r\n const publicKeyBuffer = Buffer.from(publicKey, \"hex\");\r\n return exports.curve.verify(messageHash, sigObj, publicKeyBuffer, \"hex\");\r\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n throw new Error(\"Couldn't validate the signature.\");\n } else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', constants.APP_SECRET)\n .update(buf)\n .digest('hex');\n\n if (signatureHash != expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an\n // error.\n console.error(\"Couldn't validate the signature.\");\n } else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', APP_SECRET)\n .update(buf)\n .digest('hex');\n\n if (signatureHash != expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "sign(signatureProvider) {\n const message = this.getSignatureDigest();\n this.signature = signatureProvider.sign(Serialize.arrayToHex(message));\n }", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an\n // error.\n //console.error(\"Couldn't validate the signature.\");\n } else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', config.fbBot.appSecret)\n .update(buf)\n .digest('hex');\n\n if (signatureHash !== expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "_verify(req) {\n const { query } = url.parse(req.url, true);\n const { signature, timestamp, nonce, echostr } = query;\n const $token = this.options.secret;\n let $tmpArr = [$token, timestamp, nonce];\n $tmpArr.sort();\n return sha1($tmpArr.join('')) === signature ? echostr : false;\n }", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n console.log(\"Couldn't validate the signature.\");\n } else {\n var elements = signature.split(\"=\");\n var signatureHash = elements[1];\n var expectedHash = crypto\n .createHmac(\"sha1\", config.appSecret)\n .update(buf)\n .digest(\"hex\");\n if (signatureHash != expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "function getSignature()\n{\n var timeStamp = Math.floor((new Date()).getTime()/1000);\n return (md5(api_key+shared_secret+timeStamp));\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers[\"x-hub-signature\"];\n\n if (!signature) {\n throw new Error('Couldn\\'t validate the signature.');\n } else {\n var elements = signature.split('=');\n var method = elements[0];\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', config.FB_APP_SECRET)\n .update(buf)\n .digest('hex');\n\n if (signatureHash != expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\");\n }\n }\n}", "function test_error_verify_certificate() {\n\ttry {\n\t var caEc = cert_util.generateEcKeypair('secp256r1');\n\n\t var ec_cert = new EC_CERT(caEc);\n\t // var ec_cert = new EC_CERT(); // default curve is 'secp256r1'\n\t ec_cert.initTBSCert();\n\t \n\t var clientEc = cert_util.generateEcKeypair('secp256r1');\n\t \n\t ec_cert.setSubjectPublicKeyByGetKey(clientEc);\n\t \n\t ec_cert.setSerialNumberByParam({'int': 1234});\n\t ec_cert.setSignatureAlgByParam({'name': 'SHA1withRSA', 'paramempty': false}); // NOTE: paramempty: false to get NULL in AlgorithmIdentifier (possibly not required)\n\t var dn = \"/C=US/ST=Maryland/L=Pasadena/O=BrentBaccala/OU=R&BD/[email protected]/SN=Park\";\n\t ec_cert.setIssuerByParam({'str': dn}); \n\n\t var str1 = cert_util.getCurrentDate() + \"Z\";\n\t var obj1 = {'str': str1};\n\t ec_cert.setNotBeforeByParam(obj1);\n\n\t var str2 = cert_util.getAddMonthsDate(null, 3) + \"Z\";\n\t var obj2 = {'str': str2};\n\t ec_cert.setNotAfterByParam(obj2);\n\n\t ec_cert.setSubjectByParam({'str': \"/C=US/O=TEST\"});\n\t // extension\n\t ec_cert.appendExtension(new rs.asn1.x509.BasicConstraints({'cA': false}));\n\t ec_cert.appendExtension(new rs.asn1.x509.KeyUsage({'bin':'11'}));\n\t ec_cert.appendExtension(new rs.asn1.x509.CRLDistributionPoints({'uri':'http://www.infosec/com/newict'}));\n\n\t ec_cert.doSign();\n\t // ec_cert.saveFile(\"/home/kyoungmin/tmp/skbc2.pem\");\n\t var certPEM = ec_cert.getPemString();\n\t // console.log(certPEM);\n\n\t // create new keypair for error testing\n\t var otherCaEc = cert_util.generateEcKeypair('secp256r1');\n\t var pemFileFullPath = \"/home/kyoungmin/tmp/root2.pem\";\n\t var result = getSelfSignCertificate(otherCaEc, pemFileFullPath);\n\t if (pemFileFullPath != result) {\n\t \tconsole.log(\"failed to save pem file: \" + result);\n\t \treturn;\n\t }\n\t var caCertPem = cert_util.generateCertPEMFromPath(pemFileFullPath);\n\t console.log(\"verify certificate with ca certificate ---> \" + cert_util.verifyCertificate(caCertPem, certPEM));\n\n\t} catch (exception) {\n\t console.log(exception);\n\t}\n}", "async function checksignature(did, signature, msg){\n if (!web3) {\n throw new Error(`web3 hasn't been created yet`);\n }\n // get the list of key = 1 of this did\n const workspace_contract_address = '0x' + did.split(\":\")[3];\n const contract = new web3.eth.Contract(workspace_contract_abi, workspace_contract_address);\n const keylist = await contract.methods.getKeysByPurpose(1).call();\n // calculate the keccak256 of the signer\n const signer = web3.eth.accounts.recover(msg, signature);\n const signerpublickey = web3.utils.soliditySha3(signer);\n // return True if signer has a key 1\n return keylist.includes(signerpublickey);\n}", "verifySignature(metadata) {\n const signature = metadata.signatures[this.keyID];\n if (!signature)\n throw new error_1.UnsignedMetadataError('no signature for key found in metadata');\n if (!this.keyVal.public)\n throw new error_1.UnsignedMetadataError('no public key found');\n const publicKey = (0, key_1.getPublicKey)({\n keyType: this.keyType,\n scheme: this.scheme,\n keyVal: this.keyVal.public,\n });\n const signedData = metadata.signed.toJSON();\n try {\n if (!utils_1.crypto.verifySignature(signedData, publicKey, signature.sig)) {\n throw new error_1.UnsignedMetadataError(`failed to verify ${this.keyID} signature`);\n }\n }\n catch (error) {\n if (error instanceof error_1.UnsignedMetadataError) {\n throw error;\n }\n throw new error_1.UnsignedMetadataError(`failed to verify ${this.keyID} signature`);\n }\n }", "function checkSignature({ hash, ...userData }) {\n // create a hash of a secret that both you and Telegram know. In this case, it is your bot token\n const secretKey = createHash('sha256')\n .update(CONFIG.BOT_TOKEN)\n .digest();\n\n // this is the data to be authenticated i.e. telegram user id, first_name, last_name etc.\n const dataCheckString = Object.keys(userData)\n .sort()\n .map(key => (`${key}=${userData[key]}`))\n .join('\\n');\n\n // run a cryptographic hash function over the data to be authenticated and the secret\n const hmac = createHmac('sha256', secretKey)\n .update(dataCheckString)\n .digest('hex');\n\n // compare the hash that you calculate on your side (hmac) with what Telegram sends you (hash) and return the result\n return hmac === hash;\n}", "function recoverPubKey(curve,e,signature,i){_assert2.default.strictEqual(i&3,i,'Recovery param is more than two bits');var n=curve.n;var G=curve.G;var r=signature.r;var s=signature.s;(0,_assert2.default)(r.signum()>0&&r.compareTo(n)<0,'Invalid r value');(0,_assert2.default)(s.signum()>0&&s.compareTo(n)<0,'Invalid s value');// A set LSB signifies that the y-coordinate is odd\n\tvar isYOdd=i&1;// The more significant bit specifies whether we should use the\n\t// first or second candidate key.\n\tvar isSecondKey=i>>1;// 1.1 Let x = r + jn\n\tvar x=isSecondKey?r.add(n):r;var R=curve.pointFromX(isYOdd,x);// 1.4 Check that nR is at infinity\n\tvar nR=R.multiply(n);(0,_assert2.default)(curve.isInfinity(nR),'nR is not a valid curve point');// Compute -e from e\n\tvar eNeg=e.negate().mod(n);// 1.6.1 Compute Q = r^-1 (sR - eG)\n\t// Q = r^-1 (sR + -eG)\n\tvar rInv=r.modInverse(n);var Q=R.multiplyTwo(s,G,eNeg).multiply(rInv);curve.validate(Q);return Q;}", "function createSignature(nonHashedMessage, callback) {\n //make message hash\n var hash = crypto.createHash('sha256').update(nonHashedMessage).digest('hex')\n var pubKey = chainConfig.primaryAccount.pubKey;\n var privKey = chainConfig.primaryAccount.privKey;\n\n var keyPair = { \"publicKey\": new Buffer(pubKey, \"hex\"), \"privateKey\": new Buffer(privKey, \"hex\") }\n\n var signature = ed25519.Sign(new Buffer(hash), keyPair)\n\n signature = signature.toString('hex')\n\n var result = { \"signature\": signature, \"pubKey\": pubKey, \"msg\": hash }\n\n callback(signature, pubKey, hash)\n }", "function test_certificate() {\n\ttry {\n\t var caEc = cert_util.generateEcKeypair('secp256r1');\n\n\t var ec_cert = new EC_CERT(caEc);\n\t // var ec_cert = new EC_CERT(); // default curve is 'secp256r1'\n\t ec_cert.initTBSCert();\n\t \n\t var clientEc = cert_util.generateEcKeypair('secp256r1');\n\t \n\t ec_cert.setSubjectPublicKeyByGetKey(clientEc);\n\t \n\t ec_cert.setSerialNumberByParam({'int': 1234});\n\t ec_cert.setSignatureAlgByParam({'name': 'SHA1withRSA', 'paramempty': false}); // NOTE: paramempty: false to get NULL in AlgorithmIdentifier (possibly not required)\n\t var dn = \"/C=US/ST=Maryland/L=Pasadena/O=BrentBaccala/OU=R&BD/[email protected]/SN=Park\";\n\t ec_cert.setIssuerByParam({'str': dn}); \n\n\t var str1 = cert_util.getCurrentDate() + \"Z\";\n\t var obj1 = {'str': str1};\n\t console.log(obj1);\n\t ec_cert.setNotBeforeByParam(obj1);\n\n\t var str2 = cert_util.getAddMonthsDate(null, 3) + \"Z\";\n\t var obj2 = {'str': str2};\n\t console.log(obj2);\n\t ec_cert.setNotAfterByParam(obj2);\n\n\t ec_cert.setSubjectByParam({'str': \"/C=US/O=TEST\"});\n\t // extension\n\t ec_cert.appendExtension(new rs.asn1.x509.BasicConstraints({'cA': false}));\n\t ec_cert.appendExtension(new rs.asn1.x509.KeyUsage({'bin':'11'}));\n\t ec_cert.appendExtension(new rs.asn1.x509.CRLDistributionPoints({'uri':'http://www.infosec/com/newict'}));\n\n\t ec_cert.doSign();\n\t ec_cert.saveFile(\"/home/kyoungmin/tmp/skbc2.pem\");\n\t // var certPEM = ec_cert.getPemString();\n\t // console.log(certPEM);\n\t console.log(\"Good Job!\");\n\t} catch (exception) {\n\t console.log(exception);\n\t}\n}", "function testHmac()\n{\n var importAlgorithm = {name: 'HMAC', hash: {name: \"SHA-256\"}};\n var algorithm = {name: 'HMAC'};\n\n var key = null;\n\n var testCase = {\n hash: \"SHA-256\",\n key: \"9779d9120642797f1747025d5b22b7ac607cab08e1758f2f3a46c8be1e25c53b8c6a8f58ffefa176\",\n message: \"b1689c2591eaf3c9e66070f8a77954ffb81749f1b00346f9dfe0b2ee905dcc288baf4a92de3f4001dd9f44c468c3d07d6c6ee82faceafc97c2fc0fc0601719d2dcd0aa2aec92d1b0ae933c65eb06a03c9c935c2bad0459810241347ab87e9f11adb30415424c6c7f5f22a003b8ab8de54f6ded0e3ab9245fa79568451dfa258e\",\n mac: \"769f00d3e6a6cc1fb426a14a4f76c6462e6149726e0dee0ec0cf97a16605ac8b\"\n };\n\n var keyData = hexStringToUint8Array(testCase.key);\n var usages = ['sign', 'verify'];\n var extractable = true;\n\n // (1) Import the key\n return crypto.subtle.importKey('raw', keyData, importAlgorithm, extractable, usages).then(function(result) {\n key = result;\n\n // shouldBe() can only resolve variables in global context.\n tmpKey = key;\n shouldEvaluateAsSilent(\"tmpKey.type\", \"secret\");\n shouldEvaluateAsSilent(\"tmpKey.extractable\", true);\n shouldEvaluateAsSilent(\"tmpKey.algorithm.name\", \"HMAC\");\n shouldEvaluateAsSilent(\"tmpKey.algorithm.hash.name\", testCase.hash);\n shouldEvaluateAsSilent(\"tmpKey.algorithm.length\", keyData.length * 8);\n shouldEvaluateAsSilent(\"tmpKey.usages.join(',')\", \"sign,verify\");\n\n // (2) Sign.\n var signPromise = crypto.subtle.sign(algorithm, key, hexStringToUint8Array(testCase.message));\n\n // (3) Verify\n var verifyPromise = crypto.subtle.verify(algorithm, key, hexStringToUint8Array(testCase.mac), hexStringToUint8Array(testCase.message));\n\n // (4) Verify truncated mac (by stripping 1 byte off of it).\n var expectedMac = hexStringToUint8Array(testCase.mac);\n var verifyTruncatedPromise = crypto.subtle.verify(algorithm, key, expectedMac.subarray(0, expectedMac.byteLength - 1), hexStringToUint8Array(testCase.message));\n\n var exportKeyPromise = crypto.subtle.exportKey('raw', key);\n\n return Promise.all([signPromise, verifyPromise, verifyTruncatedPromise, exportKeyPromise]);\n }).then(function(result) {\n // signPromise\n mac = result[0];\n shouldEvaluateAsSilent(\"bytesToHexString(mac)\", testCase.mac);\n\n // verifyPromise\n verifyResult = result[1];\n shouldEvaluateAsSilent(\"verifyResult\", true);\n\n // verifyTruncatedPromise\n verifyResult = result[2];\n shouldEvaluateAsSilent(\"verifyResult\", false);\n\n // exportKeyPromise\n exportedKeyData = result[3];\n shouldEvaluateAsSilent(\"bytesToHexString(exportedKeyData)\", testCase.key);\n });\n}", "function rsa2048Sign(message,privatekey){\r\n var sig = new KJUR.crypto.Signature({\"alg\": \"SHA1withRSA\"});\r\n sig.init(privatekey);\r\n sig.updateString(message);\r\n var hSigVal = sig.sign();\r\n return hSigVal;\r\n}", "async getSignatureSigner() {\n var h = this.state.cert_hash;\n var s = this.state.cert_signature;\n console.log(\"hs \" + h);\n console.log(\"sign :\" + s);\n //this part will work when you provide this with valid signature and its returns signer address\n try {\n var singner_account_add = EthSigUtil.recoverPersonalSignature({\n data: String(h),\n sig: s\n });\n } catch (e) {\n console.log(e);\n }\n\n //\"0x5ec74ed675a04c5752bb92ccf80d43eeabfe984a\";//account address will be something like this\n console.log(\"signer :\" + singner_account_add);\n this.setState({\n signature_signer_add: singner_account_add\n });\n console.log(\"signer :\" + this.state.signature_signer_add);\n this.increment();\n await this.getSignerNamer();\n }", "function verify (signature, sourceFile, PKinfo, output, quiet, pretty) {\n fs.readFile(sourceFile, (err, message) => {\n if (err) throw err\n var sigInfo = minisign.parseSignature(signature)\n if (minisign.verifySignature(sigInfo, message, PKinfo)) {\n if (!quiet && !pretty) {\n console.log('comment and signature verified.')\n console.log(tPrelude + sigInfo.trustedComment)\n } else if (pretty) {\n console.log(sigInfo.trustedComment.toString())\n }\n if (output) {\n console.log(message.toString())\n }\n process.exit()\n } else {\n if (!quiet) {\n console.log('signature verifaction failed.')\n }\n process.exit(1)\n }\n })\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers['x-hub-signature']\n\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an\n // error.\n console.error(\"Couldn't validate the signature.\")\n } else {\n var elements = signature.split('=')\n var signatureHash = elements[1]\n\n var expectedHash = crypto\n .createHmac('sha1', APP_SECRET)\n .update(buf)\n .digest('hex')\n\n if (signatureHash != expectedHash) {\n throw new Error(\"Couldn't validate the request signature.\")\n }\n }\n}", "function serializeSignature(writeStream, object) {\r\n if (object.type === IEd25519Signature_1.ED25519_SIGNATURE_TYPE) {\r\n serializeEd25519Signature(writeStream, object);\r\n }\r\n else {\r\n throw new Error(`Unrecognized signature type ${object.type}`);\r\n }\r\n}", "function verifyRequestSignature(req, res, buf) {\n var signature = req.headers['x-hub-signature'];\n\n if (!signature) {\n // For testing, let's log an error. In production, you should throw an\n // error.\n console.error('Couldn\\'t validate the signature.');\n } else {\n var elements = signature.split('=');\n var signatureHash = elements[1];\n\n var expectedHash = crypto.createHmac('sha1', APP_SECRET).update(buf).digest('hex');\n\n if (signatureHash != expectedHash) {\n throw new Error('Couldn\\'t validate the request signature.');\n }\n }\n}", "function showSignature() {\r\n print(\"Showing signature\");\r\n window.sigCtl.GetSignature(onGetSignature);\r\n function onGetSignature(sigCtlV, sigObjV, status) {\r\n if (window.sdkPtr.ResponseStatus.OK == status) {\r\n var outputFlags = window.sdkPtr.RBFlags.RenderOutputPicture | window.sdkPtr.RBFlags.RenderColor24BPP;\r\n var sigObj = sigObjV;\r\n sigObj.RenderBitmap(SigCaptX_Globals_1.BITMAP_IMAGEFORMAT, sigcaptx_1.HTMLTags.imageBox.clientWidth, sigcaptx_1.HTMLTags.imageBox.clientHeight, SigCaptX_Globals_1.BITMAP_INKWIDTH, SigCaptX_Globals_1.BITMAP_INKCOLOR, SigCaptX_Globals_1.BITMAP_BACKGROUNDCOLOR, outputFlags, SigCaptX_Globals_1.BITMAP_PADDING_X, SigCaptX_Globals_1.BITMAP_PADDING_Y, onRenderBitmap);\r\n }\r\n else {\r\n print(\"Error retrieving signature\");\r\n }\r\n }\r\n function onRenderBitmap(sigObjV, bmpObj, status) {\r\n if (callbackStatusOK(\"Signature Render Bitmap\", status)) {\r\n if (null == sigcaptx_1.HTMLTags.imageBox.firstChild) {\r\n sigcaptx_1.HTMLTags.imageBox.appendChild(bmpObj.image);\r\n }\r\n else {\r\n sigcaptx_1.HTMLTags.imageBox.replaceChild(bmpObj.image, sigcaptx_1.HTMLTags.imageBox.firstChild);\r\n }\r\n if (sigcaptx_1.HTMLTags.chkSigText.checked) {\r\n sigObjV.GetSigText(onGetSigText);\r\n }\r\n else {\r\n SigCaptX_WizSessionCtrl_1.WizardEventController.stop();\r\n }\r\n }\r\n }\r\n // Displays the SigText string in the text box on the HTML document\r\n function onGetSigText(sigObjV, text, status) {\r\n if (callbackStatusOK(\"Signature Render Bitmap\", status)) {\r\n print(\"Sig text successfully obtained: \" + text);\r\n // At this point you can send the contents of \"text\" to the server \r\n // and then validate it at the server end\r\n print(\"Stopping script\");\r\n SigCaptX_WizSessionCtrl_1.WizardEventController.stop();\r\n }\r\n }\r\n }", "function signature(text)\n { \n var sig = 0, len = text.length\n if(len > magic)\n len = magic\n for(var tdx = 0; tdx < len; ++tdx) \n {\n sig <<= 8\n sig += char(text, tdx)\n }\n return sig\n }", "function rsa2048Verify(rsaSign,publickey,message){\r\n var sig2 = new KJUR.crypto.Signature({\"alg\": \"SHA1withRSA\"});\r\n sig2.init(publickey);\r\n sig2.updateString(message);\r\n var isValid = sig2.verify(rsaSign);\r\n return isValid;\r\n}", "async function addSignature(key, data) {\n return CryptoJS.HmacSHA256(data, key).toString(CryptoJS.enc.Hex);\n}", "function verifyRequestSignature(signingSecret, requestHeaders, body) {\n //console.log(`debuging verify: '${signingSecret}', '${requestHeaders}', '${body}' `)\n // Request signature\n const signature = requestHeaders['x-slack-signature'];\n // Request timestamp\n const ts = parseInt(requestHeaders['x-slack-request-timestamp'], 10);\n\n // Divide current date to match Slack ts format\n // Subtract 5 minutes from current time\n const fiveMinutesAgo = Math.floor(Date.now() / 1000) - (60 * 5);\n\n if (ts < fiveMinutesAgo) {\n console.log('request is older than 5 minutes');\n return false;\n }\n\n const hmac = crypto.createHmac('sha256', signingSecret);\n const [version, hash] = signature.split('=');\n hmac.update(`${version}:${ts}:${body}`);\n\n if (!timingSafeCompare(hash, hmac.digest('hex'))) {\n console.log('request signature is not valid');\n return false;\n }\n\n console.log('request signing verification success');\n return true;\n}", "function verifyQRSharedSecret(){\n var authnData = {\n \"authId\": AUTH_ID,\n \"qr\": QR_SHAREDSECRET,\n \"hint\": \"SAVE_QR\" //dont change this value.\n };\n authenticate(authnData);\n}", "function encodeSecp256k1Signature(pubkey, signature) {\n if (signature.length !== 64) {\n throw new Error(\"Signature must be 64 bytes long. Cosmos SDK uses a 2x32 byte fixed length encoding for the secp256k1 signature integers r and s.\");\n }\n return {\n // eslint-disable-next-line @typescript-eslint/camelcase\n pub_key: pubkey_1.encodeSecp256k1Pubkey(pubkey),\n signature: encoding_1.Encoding.toBase64(signature),\n };\n}", "function signRequest(data, sign_key) {\n console.time('signing_time');\n var signature = curve.sign.detached(json2buf(data, encoding='ascii'), sign_key);\n signature = Buffer.from(signature).toString('base64');\n console.timeEnd('signing_time');\n\n return signature;\n}", "function verifyRequestSignature(req, res, buf) {\n\tvar signature = req.headers[\"x-hub-signature\"];\n\n\tif (!signature) {\n\t\t// For testing, let's log an error. In production, you should throw an error.\n\t\tconsole.error(\"Couldn't validate the signature.\");\n\t} else {\n\t\tvar elements = signature.split('=');\n\t\tvar method = elements[0];\n\t\tvar signatureHash = elements[1];\n\n\t\tvar expectedHash = crypto.createHmac('sha1', FB_APP_SECRET)\n\t\t\t\t\t\t\t\t\t\t\t\t.update(buf)\n\t\t\t\t\t\t\t\t\t\t\t\t.digest('hex');\n\n\t\tif (signatureHash != expectedHash) {\n\t\t\tthrow Error(\"Got bad request signature.\");\n\t\t}\n\t}\n}", "function verifyRequestSignature(req, res, buf) {\n\tvar signature = req.headers[\"x-hub-signature\"];\n\n\tif (!signature) {\n\t\tthrow new Error('Couldn\\'t validate the signature.');\n\t} else {\n\t\tvar elements = signature.split('=');\n\t\tvar method = elements[0];\n\t\tvar signatureHash = elements[1];\n\n\t\tvar expectedHash = crypto.createHmac('sha1', config.FB_APP_SECRET)\n\t\t\t.update(buf)\n\t\t\t.digest('hex');\n\n\t\tif (signatureHash != expectedHash) {\n\t\t\tthrow new Error(\"Couldn't validate the request signature.\");\n\t\t}\n\t}\n}", "function verifyRequestSignature(req, res, buf) {\n\tvar signature = req.headers[\"x-hub-signature\"];\n\n\tif (!signature) {\n\t\tthrow new Error('Couldn\\'t validate the signature.');\n\t} else {\n\t\tvar elements = signature.split('=');\n\t\tvar method = elements[0];\n\t\tvar signatureHash = elements[1];\n\n\t\tvar expectedHash = crypto.createHmac('sha1', config.FB_APP_SECRET)\n\t\t\t.update(buf)\n\t\t\t.digest('hex');\n\n\t\tif (signatureHash != expectedHash) {\n\t\t\tthrow new Error(\"Couldn't validate the request signature.\");\n\t\t}\n\t}\n}", "function processSignedMessage( body ) {\n\t// as usual, the sanity checks: do all 3 fields exist? username, message, signature\n\tconsole.log(JSON.stringify(body));\n\tif( typeof body.username == undefined ) {\n\t\textendedfailure = \"missing username\";\n\t\tconsole.log(extendedfailure);\n\t\treturn false;\n\t}\n\tif (typeof body.message == undefined ) {\n\t\textendedfailure = \"missing message\";\n\t\tconsole.log(extendedfailure);\n\t\treturn false;\n\t}\n\tif (typeof body.signature == undefined ) {\n\t\textendedfailure = \"missing signature\";\n\t\tconsole.log(extendedfailure);\n\t\treturn false;\n\t}\n\t\n\tvar username = body.username.trim();\n\tvar signature = body.signature;\n\tvar index = -1;\n\tvar pubkey = '';\n\t// does this user exist? and if so, did they store their public key already?\n\t\n\tindex = findUser(username);\n\tconsole.log(\"index = \" + index);\n\tif( index === -1 ) {\n\t\textendedfailure = \"user not registered\";\n\t\tconsole.log(extendedfailure);\n\t\treturn false;\n\t} else {\n\t\tconsole.log(JSON.stringify(registeredUsers[index]));\n\t\tpubkey = pem_format(registeredUsers[index].publickey);\t\t\n\t\t//console.log(\"pubkey = \" + pubkey);\n\t\tif( pubkey === '' ) {\n\t\t\textendedfailure = \"no publickey found for this user\";\n\t\t\tconsole.log(extendedfailure);\n\t\t\treturn false;\n\t\t}\n\t}\n\t// if we made it here, we found the user and the publickey, now check the signature\n\t\n\tvar verifyagent = crypto.createVerify('sha256');\t// same as used in the client\n\tvar message = body.message;\t\t\t\t\t\t\t// don't trim() this one in case leading/following spaces were part of the hash\n\tverifyagent.update(message);\t\t\t\t\t\t// load the message into the verifyagent\n\tverifyagent.end();\n\t\n\tvar verified = verifyagent.verify(pubkey, signature, 'hex');\n\n\tif( verified === true ) {\n\t\tconsole.log(\"Signature verified!\");\n\t\treturn true;\n\t} else {\n\t\textendedfailure = \"Signature failed verification\";\n\t\tconsole.log(extendedfailure);\n\t\treturn false;\n\t}\n}", "function checkSignedMessage(req, res) {\n //******************opening the signed message ****/\n const publicKeyRaw = nacl.util.encodeBase64(alicePublic);\n const publicKey =alicePublic;\n const messageUint = nacl.sign.open(signedMessageRaw, alicePublic);\n const messageEncoded = nacl.util.encodeBase64(messageUint);\n if(messageEncoded == publicKeyRaw){\n res.json({\"data\":\"PASSED\",\"message\":messageEncoded })\n }else{\n res.json({data:\"FAILED\",\"message\":messageEncoded})\n }\n}", "constructor(raw = null, qb64 = null, qb2 = null, code = codeAndLength.SigTwoCodex.Ed25519, index = 0, qb64b = null) {\n /*\n Validate as fully qualified\n Parameters:\n raw is bytes of unqualified crypto material usable for crypto operations\n qb64 is str of fully qualified crypto material\n qb2 is bytes of fully qualified crypto material\n code is str of derivation code cipher suite\n index is int of offset index into current signing key list\n or if from SigCntDex then its count of attached signatures\n qb64b is bytes of fully qualified crypto material\n\n When raw provided then validate that code is correct for length of raw\n and assign .raw .code and .index\n Else when either qb64 or qb2 provided then extract and assign .raw and .code\n\n */\n\n if (raw) {\n if (!(Buffer.isBuffer(raw) || Array.isArray(raw))) {\n throw new Error(`Not a bytes or bytearray, raw= ${raw}.`);\n }\n const pad = this.getPad(raw);\n\n if (!((pad === 2 && Object.values(JSON.stringify(codeAndLength.SigTwoCodex)).includes(code))\n // eslint-disable-next-line max-len\n || (pad === 0 && Object.values(JSON.stringify(codeAndLength.SigCntCodex).includes(code))\n || (pad === 0 && Object.values(JSON.stringify(codeAndLength.SigFourCodex).includes(code))\n || (pad === 1 && Object.values(JSON.stringify(codeAndLength.SigFiveCodex).includes(code))))))) {\n throw new Error(`Wrong code= ${code} for raw= ${raw} .`);\n }\n if ((Object.values(codeAndLength.SigTwoCodex).includes(code)\n && (index < 0) || (index > codeAndLength.SIGTWOMAX))\n || (Object.values(codeAndLength.SigCntCodex).includes(code) && ((index < 0) || (index > codeAndLength.SIGFOURMAX)))\n || (Object.values(codeAndLength.SigFourCodex).includes(code) && ((index < 0) || (index > codeAndLength.SIGFOURMAX)))\n || (Object.values(codeAndLength.SigFiveCodex).includes(code) && ((index < 0) || (index > codeAndLength.SIGFIVEMAX)))) {\n throw new Error(`Invalid index=${index} for code=${code}.`);\n }\n\n raw = raw.slice(0, codeAndLength.SigRawSizes[code]);\n if (raw.length !== codeAndLength.SigRawSizes[code]) {\n throw new Error(`Unexpected raw size= ${raw.length} for code= ${code}\n not size= ${codeAndLength.cryAllRawSizes[code]}.`);\n }\n this.getCode = code;\n this.getIndex = index;\n this.getRaw = Buffer.from(raw, 'binary'); // crypto ops require bytes not bytearray\n } else if (qb64b != null) {\n qb64b = qb64b.toString('utf-8');\n this.exfil(qb64b);\n } else if (qb64 != null) {\n qb64 = qb64.toString('utf-8');\n this.exfil(qb64);\n } else if (qb2 != null) {\n // encodeB64(qb2).decode(\"utf-8\")\n this.exfil(Base64.encode(qb2));\n } else {\n throw new Error('Improper initialization need raw or b64 or b2.');\n }\n }", "test() {\n return this.hexSHA1(\"abc\") === \"a9993e364706816aba3e25717850c26c9cd0d89d\";\n }", "rsa1_verify(pubkey, data, sign) {\n\t\tconst sig = new rs.KJUR.crypto.Signature({ \"alg\": \"SHA1withRSA\" });\n\t\tsig.init(pubkey);\n\t\tsig.updateString(data);\n\t\tconst is_valid = sig.verify(sign);\n\t\treturn is_valid;\n\t}", "function test_error_certificate() {\n\ttry {\n\t var caEc = cert_util.generateEcKeypair('secp256r1');\n\t \n\t var ec_cert = new EC_CERT(caEc);\n\t // var ec_cert = new EC_CERT(); // default curve is 'secp256r1'\n\t //ec_cert.initTBSCert();\n\t \n\t var clientEc = cert_util.generateEcKeypair('secp256r1');\n\t \n\t ec_cert.setSubjectPublicKeyByGetKey(clientEc);\n\t \n\t ec_cert.setSerialNumberByParam({'int': 1234});\n\t ec_cert.setSignatureAlgByParam({'name': 'SHA1withRSA', 'paramempty': false}); // NOTE: paramempty: false to get NULL in AlgorithmIdentifier (possibly not required)\n\t var dn = \"/C=US/ST=Maryland/L=Pasadena/O=BrentBaccala/OU=R&BD/[email protected]/SN=Park\";\n\t ec_cert.setIssuerByParam({'str': dn}); \n\t \n\t var str1 = cert_util.getCurrentDate() + \"Z\";\n\t var obj1 = {'str': str1};\n\t console.log(obj1);\n\t ec_cert.setNotBeforeByParam(obj1);\n\n\t var str2 = cert_util.getAddMonthsDate(null, 3) + \"Z\";\n\t var obj2 = {'str': str2};\n\t console.log(obj2);\n\t ec_cert.setNotAfterByParam(obj2);\n\n\t ec_cert.setSubjectByParam({'str': \"/C=US/O=TEST\"});\n\t // extension\n\t ec_cert.appendExtension(new rs.asn1.x509.BasicConstraints({'cA': false}));\n\t ec_cert.appendExtension(new rs.asn1.x509.KeyUsage({'bin':'11'}));\n\t ec_cert.appendExtension(new rs.asn1.x509.CRLDistributionPoints({'uri':'http://www.infosec/com/newict'}));\n\n\t ec_cert.doSign();\n\t ec_cert.saveFile(\"/home/kyoungmin/tmp/skbc2.pem\");\n\t // var certPEM = ec_cert.getPemString();\n\t // console.log(certPEM);\n\t console.log(\"Good Job!\");\n\t} catch (exception) {\n\t console.log(exception);\n\t}\n}", "function tryAddCosSignature({ cosSdkInstance, url }) {\n const { host, pathname, searchParams } = new URL(url);\n if (/^([^.]*)\\.cos\\.([^.]*)\\.myqcloud\\.com$/.test(host)) {\n // if url already has signature, return url\n if (searchParams.has('q-signature')) {\n return url;\n }\n const { 1: Bucket, 2: Region } = host.match(/^([^.]*)\\.cos\\.([^.]*)\\.myqcloud\\.com$/);\n const Key = decodeURIComponent(pathname.slice(1));\n return cosSdkInstance.getObjectUrl({\n Bucket,\n Region,\n Key,\n Sign: true,\n Expires: 24 * 60 * 60,\n });\n }\n return url;\n}", "function verifySignature(message, compressedPublicKey, signature) {\n let publicKey = uncompressPublicKey(compressedPublicKey);\n let publicKeyPair = ec.keyFromPublic(publicKey, 'hex');\n let isVerified = publicKeyPair.verify(message, signature);\n return isVerified;\n}", "function verRctSimple(rv, semantics, mixRing, kimgs) {\n return __awaiter(this, void 0, void 0, function* () {\n try {\n if (rv.type === 0x04) {\n throw Error(\"Simple Bulletproof validation not implemented\");\n }\n if (rv.type !== 0x02 && rv.type !== 0x04) {\n throw Error(\"verRctSimple called on non simple rctSig\");\n }\n if (semantics) {\n if (rv.type == 0x04) {\n throw Error(\"Simple Bulletproof validation not implemented\");\n }\n else {\n if (rv.outPk.length !== rv.p.rangeSigs.length) {\n throw Error(\"Mismatched sizes of outPk and rv.p.rangeSigs\");\n }\n if (rv.pseudoOuts.length !== rv.p.MGs.length) {\n throw Error(\"Mismatched sizes of rv.pseudoOuts and rv.p.MGs\");\n }\n // originally the check is rv.p.pseudoOuts.length, but this'll throw\n // until p.pseudoOuts is added as a property to the rv object\n if (rv.p.pseudoOuts) {\n throw Error(\"rv.p.pseudoOuts must be empty\");\n }\n }\n }\n else {\n if (rv.type === 0x04) {\n throw Error(\"Simple Bulletproof validation not implemented\");\n }\n else {\n // semantics check is early, and mixRing/MGs aren't resolved yet\n if (rv.pseudoOuts.length !== mixRing.length) {\n throw Error(\"Mismatched sizes of rv.pseudoOuts and mixRing\");\n }\n }\n }\n // if bulletproof, then use rv.p.pseudoOuts, otherwise use rv.pseudoOuts\n const pseudoOuts = rv.type === 0x04\n ? rv.p.pseudoOuts\n : rv.pseudoOuts;\n if (semantics) {\n let sumOutpks = identity();\n for (let i = 0; i < rv.outPk.length; i++) {\n sumOutpks = ge_add(sumOutpks, rv.outPk[i].mask); // add all of the output commitments\n }\n const txnFeeKey = scalarmultH(xmr_str_utils_1.d2s(rv.txnFee));\n sumOutpks = ge_add(txnFeeKey, sumOutpks); // add txnfeekey\n let sumPseudoOuts = identity();\n for (let i = 0; i < pseudoOuts.length; i++) {\n sumPseudoOuts = ge_add(sumPseudoOuts, pseudoOuts[i]); // sum up all of the pseudoOuts\n }\n if (sumOutpks !== sumPseudoOuts) {\n console.error(\"Sum check failed\");\n return false;\n }\n const results = [];\n for (let i = 0; i < rv.outPk.length; i++) {\n // might want to parallelize this like its done in the c++ codebase\n // via some abstraction library to support browser + node\n if (rv.p.rangeSigs.length === 0) {\n results[i] = bullet_proofs_1.verBulletProof(rv.p.bulletproofs[i]);\n }\n else {\n // mask -> C if public\n results[i] = prove_range_1.verRange(rv.outPk[i].mask, rv.p.rangeSigs[i]);\n }\n }\n for (let i = 0; i < results.length; i++) {\n if (!results[i]) {\n console.error(\"Range proof verification failed for output\", i);\n return false;\n }\n }\n }\n else {\n const message = yield utils_1.get_pre_mlsag_hash(rv, mixRing, defaultHwDev);\n const results = [];\n for (let i = 0; i < mixRing.length; i++) {\n results[i] = prove_ringct_mg_1.verRctMGSimple(message, rv.p.MGs[i], mixRing[i], pseudoOuts[i], kimgs[i]);\n }\n for (let i = 0; i < results.length; i++) {\n if (!results[i]) {\n console.error(\"Range proof verification failed for output\", i);\n return false;\n }\n }\n }\n return true;\n }\n catch (error) {\n console.log(\"[verRctSimple]\", error);\n return false;\n }\n });\n}", "async function signature({platforms, debug, version}) {\n if (!platforms[PLATFORM.FIREFOX_MV2] || debug) {\n throw new Error('Only Firefox builds support signed packages for now.');\n }\n\n const infoPath = `./integrity/firefox/${version}/info.json`;\n const {type, order, manifest} = await readJSON(infoPath);\n await createHashes(type, version, order, manifest);\n\n const destDir = getDestDir({debug, platform: 'firefox'});\n const rsa = `./integrity/firefox/${version}/mozilla.rsa`;\n const rsaDest = `${destDir}/META-INF/mozilla.rsa`;\n const sig = `./integrity/firefox/${version}/cose.sig`;\n const sigDest = `${destDir}/META-INF/cose.sig`;\n const recommendation = `./integrity/firefox/${version}/mozilla-recommendation.json`;\n const recommendationDest = `${destDir}/mozilla-recommendation.json`;\n await copyFile(rsa, rsaDest);\n try {\n await copyFile(sig, sigDest);\n } catch (e) {\n // Do nothing\n }\n try {\n await copyFile(recommendation, recommendationDest);\n } catch (e) {\n // Do nothing\n }\n}", "_generateSignature(opc) {\n if (this._apiToken) {\n opc.headers.Authorization = `${this._apiToken}`;\n }\n if (this._mustSign) {\n let timestamp = new Date().getTime();\n opc.headers['x-logtrust-apikey'] = this._apiKey;\n opc.headers['x-logtrust-timestamp'] = timestamp;\n const body = opc.body ? JSON.stringify(opc.body) : ''\n const signMsg = this._apiKey + body + timestamp;\n opc.headers['x-logtrust-sign'] =\n HmacSHA256(signMsg, this._apiSecret).toString();\n }\n }", "function verifyMessage(headers, body, callback) {\n const baseString = `v0:${headers['X-Slack-Request-Timestamp']}:${body}`;\n const hash = 'v0=' + crypto.createHmac('sha256', SLACK_SIGNING_SECRET)\n .update(baseString)\n .digest('hex');\n const retrievedSignature = headers['X-Slack-Signature'];\n if (hash !== retrievedSignature) {\n callback(null, {\n statusCode: 401,\n body: 'Signature verification failed, Ignoring message'\n });\n }\n}", "function verify(signature, message, publicKey, htfOpts) {\n const P = normP1(publicKey);\n const Hm = normP2Hash(message, htfOpts);\n const G = G1.ProjectivePoint.BASE;\n const S = normP2(signature);\n // Instead of doing 2 exponentiations, we use property of billinear maps\n // and do one exp after multiplying 2 points.\n const ePHm = pairing(P.negate(), Hm, false);\n const eGS = pairing(G, S, false);\n const exp = Fp12.finalExponentiate(Fp12.mul(eGS, ePHm));\n return Fp12.eql(exp, Fp12.ONE);\n }", "function makeSignature(obj, binanceSecret) {\n //console.log(\"makeSignature\", obj, binanceSecret);\n let s = \"\",\n res;\n Object.keys(obj).forEach((e) => {\n s = s + e + \"=\" + obj[e] + \"&\";\n });\n //console.log(s.slice(0, s.length - 1));\n const hmac = crypto.createHmac(\"sha256\", binanceSecret);\n hmac.update(s.slice(0, s.length - 1));\n res = hmac.digest(\"hex\");\n return { qs: s, signature: res };\n}", "function encode(r,s){var lenR=r.length;var lenS=s.length;if(lenR===0)throw new Error('R length is zero');if(lenS===0)throw new Error('S length is zero');if(lenR>33)throw new Error('R length is too long');if(lenS>33)throw new Error('S length is too long');if(r[0]&0x80)throw new Error('R value is negative');if(s[0]&0x80)throw new Error('S value is negative');if(lenR>1&&r[0]===0x00&&!(r[1]&0x80))throw new Error('R value excessively padded');if(lenS>1&&s[0]===0x00&&!(s[1]&0x80))throw new Error('S value excessively padded');var signature=Buffer.allocUnsafe(6+lenR+lenS);// 0x30 [total-length] 0x02 [R-length] [R] 0x02 [S-length] [S]\nsignature[0]=0x30;signature[1]=signature.length-2;signature[2]=0x02;signature[3]=r.length;r.copy(signature,4);signature[4+lenR]=0x02;signature[5+lenR]=s.length;s.copy(signature,6+lenR);return signature;}" ]
[ "0.7091817", "0.6376661", "0.6355904", "0.632866", "0.62962246", "0.62438613", "0.6185131", "0.61671996", "0.61612886", "0.61447453", "0.60907596", "0.6040627", "0.5997651", "0.59582853", "0.59516144", "0.59409165", "0.5826957", "0.5764042", "0.574171", "0.57322925", "0.5711989", "0.56710815", "0.56586933", "0.5647418", "0.56147915", "0.5612186", "0.5611687", "0.55881387", "0.55807287", "0.5580391", "0.55721515", "0.5558742", "0.55384445", "0.55358243", "0.55354446", "0.55299217", "0.55257964", "0.5511153", "0.5505127", "0.54926395", "0.5472433", "0.5472433", "0.5472433", "0.5472433", "0.5472433", "0.5472433", "0.546515", "0.54617107", "0.5459802", "0.5452348", "0.5447748", "0.5445397", "0.54369634", "0.54319614", "0.5431859", "0.5426509", "0.542325", "0.5420416", "0.54182184", "0.5408631", "0.5400938", "0.5387562", "0.5385091", "0.5353178", "0.534918", "0.53487724", "0.5347322", "0.53460974", "0.5340494", "0.5338549", "0.53300226", "0.53284967", "0.5323956", "0.5321479", "0.5316218", "0.53075427", "0.5299825", "0.52995145", "0.52966744", "0.52946454", "0.52879864", "0.5282588", "0.52772033", "0.52602917", "0.5258632", "0.5258632", "0.5252802", "0.52384585", "0.523317", "0.52308774", "0.5219902", "0.5213383", "0.5210852", "0.52093554", "0.52043295", "0.5201239", "0.519891", "0.5193657", "0.5178484", "0.51659155", "0.51633716" ]
0.0
-1
Internal function to perform actions on a user.
function getUserById(id) { var deferred = queue.defer(); var findDeferred = queue.defer(); User.findOne({ _id: mongoose.Types.ObjectId(id) }, findDeferred.makeNodeResolver()); findDeferred.promise.then(resolveOnlyWhenFound(deferred)); return deferred.promise; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "set_user(on) { store.dispatch(hpUser(on)); }", "function user()\n {\n\n }", "getUser(state, action){}", "mutateUser ({dispatch}, payload) {\n if (payload.id) {\n dispatch('editUser', payload)\n } else {\n // TODO creating a user from the admin account\n console.log('this user doesnt exist in database')\n }\n }", "broadcastUserAction (action) {\n this.dispatch({\n type: EventTypes.USER_EVENT,\n action: action\n });\n }", "function proceed () {\n\t\t\t/*\n\t\t\t\tIf the user has been loaded determine where we should\n\t\t\t\tsend the user.\n\t\t\t*/\n\t\t\tif (store.getters.getBearerToken) {\n\t\t\t\tnext();\n\t\t\t} else {\n\t\t\t\t//user is not logged in\n\t\t\t\tconsole.log('you are not logged in');\n\t\t\t}\n\t\t}", "user(obj) {\n\n // Perform action and return promise\n return user.getUser({id: obj.author});\n }", "function updateUserStuff(user) {\n console.log(\"doing stuff for\", user.get('username'));\n}", "function user(){\r\n uProfile(req, res);\r\n }", "loginAction({\n commit\n }, userlikeObj) {\n commit(\"userStatus\", true)\n commit(\"saveUserInfo\", userlikeObj)\n }", "function proceed() {\n\t\t/*\n\t\t\tIf the user has been loaded determine where we should\n\t\t\tsend the user.\n\t\t*/\n if (store.getters.getUserLoadStatus == 2) {\n next();\n } else if (store.getters.getUserLoadStatus == 3) {\n //user is not logged in\n console.log('you are not logged in');\n }\n }", "function proceed () {\n\t\t/*\n\t\t\tIf the user has been loaded determine where we should\n\t\t\tsend the user.\n\t\t*/\n if ( store.getters.getUserLoadStatus() == 2 ) {\n\t\t\t/*\n\t\t\t\tIf the user is not empty, that means there's a user\n\t\t\t\tauthenticated we allow them to continue. Otherwise, we\n\t\t\t\tsend the user back to the home page.\n\t\t\t*/\n\t\t\tif( store.getters.getUser != '' ){\n \tnext();\n\t\t\t}else{\n\t\t\t\tnext('/cafes');\n\t\t\t}\n }\n\t}", "user(state, user) {\n state.user = user;\n }", "function handleUserRequest(userName, chaincodeID, fcn, args) {\n // Register and enroll this user.\n // If this user has already been registered and/or enrolled, this will\n // still succeed because the state is kept in the KeyValStore\n // (i.e. in '/tmp/keyValStore' in this sample).\n var registrationRequest = {\n enrollmentID: userName,\n // Customize account & affiliation\n account: \"bank_a\",\n affiliation: \"00001\"\n };\n chain.registerAndEnroll( registrationRequest, function(err, user) {\n if (err) return console.log(\"ERROR: %s\",err);\n // Issue an invoke request\n var invokeRequest = {\n // Name (hash) required for invoke\n chaincodeID: chaincodeID,\n // Function to trigger\n fcn: fcn,\n // Parameters for the invoke function\n args: args\n };\n // Invoke the request from the user object and wait for events to occur.\n var tx = user.invoke(invokeRequest);\n // Listen for the 'submitted' event\n tx.on('submitted', function(results) {\n console.log(\"submitted invoke: %j\",results);\n });\n // Listen for the 'complete' event.\n tx.on('complete', function(results) {\n console.log(\"completed invoke: %j\",results);\n });\n // Listen for the 'error' event.\n tx.on('error', function(err) {\n console.log(\"error on invoke: %j\",err);\n });\n });\n}", "authUser (state, userData) {\n \t\tstate.idToken = userData.token\n \t\tstate.userId = userData.userId\n \t}", "doSpoofUser() {\n this.spoofUser(this.get('user.id'));\n }", "fetch(id, onSuccess, onError) {\r\n this.get(id, \r\n\t\t// onSuccess\r\n\t\t((payload) => {\r\n\t\t\tlet data = payload['user']\r\n\t\t\t\r\n\t\t\tthis.actions.user.setUser(data)\r\n\t\t\t\r\n\t\t\tif (typeof onSuccess === 'function') {\r\n\t\t\t\tonSuccess(data)\r\n\t\t\t}\r\n\t\t}).bind(this),\r\n\t\tonError)\r\n }", "function userClick(user) {\n if (store.get('profile').user_id == user.user_id) {\n return;\n }\n logger.info('[TEST] Messaging ' + (user.name || user.nickname));\n }", "function onClickActions(userId) {\n if (userId === activeUserId) {\n return setActiveUserId(null);\n }\n\n const user = users.find(user => user.user_id === userId);\n dispatch(setActiveUser({ user }));\n setActiveUserId(userId);\n }", "approveMember() {\n MemberActions.approveUser(this.props.memberID);\n this.props.unselect();\n }", "function setUserActions(){\n $jQ(user.actionElements).each(function(){\n $jQ(this).attr(vars.actions, 'true');\n });\n $jQ(user.actionClick).each(function(){\n var e = $jQ(this);\n e.attr(vars.actions, 'user');\n e.attr(vars.userActions, 'click');\n e.off('click.stopnav');\n e.parents().off('click.stopnav');\n e.on('click.user',setUserClickAction);\n });\n $jQ(user.actionPopup).each(function(){\n var e = $jQ(this);\n e.attr(vars.actions, 'user');\n e.attr(vars.userActions, 'popup');\n e.off('click.stopnav');\n e.parents().off('click.stopnav');\n e.on('click.user',setUserClickAction);\n });\n $jQ(user.modalBox).each(function(){\n $jQ(this).find(user.modalClose).each(function(){\n var e = $jQ(this);\n e.attr(vars.userActions, 'popup.close');\n e.off('click.stopnav');\n e.parents().off('click.stopnav');\n });\n $jQ(this).on(user.modalEventShown, function (){\n $jQ(this).find('*').each(function(){\n var e = $jQ(this);\n var tag = e.prop(\"tagName\");\n if(tag!=\"BR\" && tag!=\"SCRIPT\" && tag!=\"IFRAME\"){\n setColorInfo(e,'');\n setFontInfos(e);\n setSizes(e);\n setPositions(e);\n setBorder(e);\n setTextTransform(e);\n setZIndex(e);\n $jQ(this).attr(vars.visible + ':action', $jQ(this).is(':visible'));\n }\n });\n });\n });\n $jQ(user.actionDrag).each(function() {\n $jQ(this).attr(vars.actions, 'user');\n $jQ(this).attr(vars.userActions, 'drag');\n $jQ(this).attr(vars.userActions + ':counter', 0);\n $jQ(this).on('mousemove.user',setUserDragAction);\n });\n}", "actionOfUser(action) {\n this.setState({userAction:action})\n }", "function onUserChange(newname) {\n var id;\n\n username = newname;\n\n items.username = username;\n\n var fn = !!username? loggedin: loggedout;\n for (i=0, len=fn.length; i<len; i++) {\n fn[i](newname);\n }\n }", "function resolveAuthenticatedUser(data){\n\t\t\tif(data == true){\n\t\t\t\t//$state.go('otp');\n\t\t\t\t//workflow on new user or existing user need to be added here\n\t\t\t\t//api need to return is the user is new or old\n\t\t\t}else{\n\t\t\t\t//wrong otp\n\t\t\t\t//otp authentication failed\n\t\t\t}\n\t\t}", "function resolveAuthenticatedUser(data){\n\t\t\tif(data == true){\n\t\t\t\t//$state.go('otp');\n\t\t\t\t//workflow on new user or existing user need to be added here\n\t\t\t\t//api need to return is the user is new or old\n\t\t\t}else{\n\t\t\t\t//wrong otp\n\t\t\t\t//otp authentication failed\n\t\t\t}\n\t\t}", "function handleUserChangeSuccess() {\n var user = userState.user();\n $scope.userNickname = user ? user.nickname : undefined;\n updateCanShowRootOperations();\n }", "_onUserUpdated() {\n UserActions.setIsUpdating(false);\n UserActions.setIsRequesting(false);\n }", "getUser({ commit, dispatch }, userid) {\n api(`account/${userid}`).then(res => {\n commit('setUserView', res.data)\n })\n }", "user(...args) {\n // emit to eden\n return this.eden.call('slack.user', Array.from(args), true);\n }", "function functionsToExecuteIfUserIsLoggedIn(username) {\n setCurrentUser(username);\n showLoggedInUserInformation(username);\n unlockSubscriptionButtons();\n}", "[types.FETCH_USER_SUCCESS] (state, { user }) {\n state.user = user\n }", "AUTH_USER (state, userData) {\n state.idToken = userData.token\n state.userId = userData.userId\n }", "setUser (user) {\n AppStorage.setUserData(user)\n AppDispatcher.handleAction({\n actionType: 'USER_SET',\n data: user\n })\n }", "async postProcessInvitedUsers () {\n\t\tif (this.userInviter) {\n\t\t\treturn this.userInviter.postProcess();\n\t\t}\n\t}", "function selectUser(user) {\n $rootScope.$emit(\"changeUser\", user);\n }", "onAuthenticated(user) {\n if (isFunction(onAuthenticated)) {\n onAuthenticated(user);\n }\n }", "function action_all_users(action) {\n // Gets all users\n var allrows = document.getElementsByName('userid'+action);\n for (var i = 0; i < allrows.length; i++) {\n // userid via innerHTML, substring for id, and passed action\n if (action == 'remove' ) {\n \tif (manageContact(allrows[i].id, allrows[i].value, action, '')) {\n \t// Changes display of user row to show it was removed\n \ttoggleRemoveAction(allrows[i].value);\n \t}\n } else {\n \tif (manageContact(allrows[i].id, allrows[i].value, 'add', action)) {\n \t// Changes display of user row to show it was added\n \ttoggleRemoveAction(allrows[i].value);\n \t}\n }\n }\n}", "function doSomething(user, userAccount){}", "onClickUser1Button() {\n const userData = {\n 'user': 'Adam Smith',\n 'role': 'Broker Admin',\n 'permission': ' List all companies and users under the broker including self.',\n };\n this.props.fetchAccessToken(\"[email protected]\", userData);\n this.props.closePopup();\n }", "authorizedUser(user) { \n this.user = user;\n }", "function loginUserCallback() {\n loginUser();\n }", "function fetchUser() {\n const userId = document.getElementById('user-id').value\n client.user.fetch(userId)\n}", "target_user(state, payload){\n Object.assign(state.AdminPanel.userEdit, payload)\n }", "function doExecute(user) {\n logController.log(user.userID + ' has expired');\n user.contactList.forEach(function (contact) {\n logController.log('Sending message \"' + user.message + '\" to ' + contact);\n // twilio.sendSMS(contact, user.message);\n //console.log(contact);\n });\n User.collection.remove(user);\n}", "async function manageUser()\n{\n\tlet server = objActualServer.server\n\tlet txt = \"Choissisez la personne que vous souhaitez manager : \"\n\n\tlet choice = [\n\t{\n\t\tname: \"Retournez au menu précédent\",\n\t\tvalue: -1\n\t}]\n\tchoice.push(returnObjectLeave())\n\tserver.members.forEach((usr) =>\n\t{\n\t\tlet actualUser = usr.user\n\t\tchoice.unshift(\n\t\t{\n\t\t\tname: actualUser.username,\n\t\t\tvalue: actualUser\n\t\t})\n\t})\n\n\tlet data = await ask(\n\t{\n\t\ttype: \"list\",\n\t\tname: \"selectedUser\",\n\t\tmessage: txt,\n\t\tchoices: choice,\n\t})\n\n\tif (data.selectedUser == -1)\n\t{\n\t\tchooseWhatToHandle(data)\n\t}\n\telse if (data.selectedUser == -2)\n\t{\n\t\tendProcess()\n\t}\n\telse\n\t{\n\t\tmanageSingleUser(data.selectedUser)\n\t}\n\n}", "function userinfo_requester_routines() {\n\n}", "get user() { return this.args.user }", "function gotUser(err, user) {\n if (err) return callback(err);\n callback(null, user);\n }", "function user(user) {\n return dispatch => {\n try {\n dispatch(success(user));\n } catch (err) {\n dispatch(failure(err.toString()));\n }\n function success(user) {\n return { type: userConstants.GETUSER_SUCCESS, user };\n }\n function failure(error) {\n return { type: userConstants.GETUSER_FAILURE, error };\n }\n };\n}", "handleUserDetails(id) {\n let user = this.props.users[id];\n this.props.getUser(user);\n }", "function successGetUserById(user) {\n return {\n type: ACTION.GET_USER_BY_ID_SUCCESS,\n user\n }\n}", "function userCheck(req, res, next) {\n if(new ObjectId(req.params.user_id).equals(req.user._id)){\n next();\n }else {\n res.status(401).send('You trying to access others data');\n }\n }", "updateUser (context, user) {\n context.commit('updateUser', user)\n }", "function execute(userChoice) {\n switch (userChoice) {\n case \"viewEmp\":\n viewEmp();\n break;\n case \"viewEmpMan\":\n viewEmpMan();\n break;\n case \"viewDept\":\n viewDept();\n break;\n case \"viewRoles\":\n viewRoles();\n break;\n case \"addEmp\":\n addEmp();\n break;\n case \"addDept\":\n addDept();\n break;\n case \"addRole\":\n addRole();\n break;\n case \"updateRole\":\n updateRole();\n break;\n case \"updateManager\":\n updateManager();\n break;\n case \"deleteDept\":\n deleteDept();\n break;\n case \"deleteRole\":\n deleteRole();\n break;\n case \"deleteEmp\":\n deleteEmp();\n break;\n case \"end\":\n connection.end();\n }\n}", "async run(msg, { targetUser }) {\n\t\tsuper.run(msg);\n\n\t\t// Without any target\n\t\tif (targetUser === '') targetUser = msg.author;\n\n\t\t// Requires a valid user.\n\t\tif (!targetUser) \n\t\t\treturn MessagesHelper.selfDestruct(msg, '!lastsac requires a valid user target to provide results.');\n\n\t\t// Default status for last sacrifice date.\n\t\tlet lastSacrificeFmt = 'unknown';\n\n\t\t// Load and format last sacrifice time.\n\t\tconst lastSacSecs = await SacrificeHelper.getLastSacrificeSecs(targetUser.id);\n\t\tif (lastSacSecs) lastSacrificeFmt = TimeHelper.secsLongFmt(lastSacSecs);\n\t\t\n\t\t// Provide the result to the user.\n\t\tconst msgText = `${targetUser.username}'s last sacrifice was: ${lastSacrificeFmt}.`;\n\t\tMessagesHelper.selfDestruct(msg, msgText);\n }", "function updateUser() {\n try {\n selectedUser.username = $usernameFld.val();\n selectedUser.password = $passwordFld.val();\n selectedUser.firstName = $firstNameFld.val();\n selectedUser.lastName = $lastNameFld.val();\n selectedUser.role = $roleFld.val();\n userService.updateUser(selectedUserId, selectedUser)\n .then(function (userServerInfo) {\n users[editIndex] = selectedUser;\n renderUsers(users);\n resetInputFields();\n clearSelected();\n });\n }\n // In future could catch null error or could grey out checkmark icon.\n catch (err) {\n console.log(err.name + \": \" + err.message);\n }\n }", "onUserEditEnd(user) {\n const action = this.state.editUser\n ? {\n type: userActions.USER_REPLACE,\n oldUser: this.state.editUser,\n newUser: user\n }\n : {\n type: userActions.USER_ADD,\n user: user\n };\n this._userStore.getDispatcher().dispatch(action);\n this.setState({ editUser: null, editedUser: null });\n }", "function setUser (user, fetchTrips) {\n return function (dispatch, getState) {\n positionHomeAndWorkFirst(user)\n\n dispatch(setCurrentUser(user))\n\n if (fetchTrips) {\n dispatch(fetchMonitoredTrips())\n }\n }\n}", "async sendUserOp (userId, op, requestId) {\n\t\t// send pubnub update on user's me-channel\n\t\tconst message = {\n\t\t\tuser: Object.assign(op, { id: userId }),\n\t\t\trequestId\n\t\t};\n\t\tconst channel = `user-${userId}`;\n\t\ttry {\n\t\t\tawait this.pubnub.publish(\n\t\t\t\tmessage,\n\t\t\t\tchannel\n\t\t\t);\n\t\t}\n\t\tcatch (error) {\n\t\t\t// this doesn't break the chain, but it is unfortunate\n\t\t\tthis.warn(`WARNING: Unable to publish user op to channel ${channel}: ${JSON.stringify(error)}`);\n\t\t}\n\t}", "function setUser(u) {\n user = u\n}", "function userLogin(user) {\n loginStateChange(user);\n console.log(user.id);\n}", "_updateUser() {\n\t\tconst user = UserStore.activeUser();\n\t\tconst authInfo = UserStore.activeAuthInfo();\n\t\tconst emails = user && user.UID ? UserStore.emails.get(user.UID) : null;\n\t\tconst primaryEmail = emails && !emails.Error ? emails.filter(e => e.Primary).map(e => e.Email)[0] : null;\n\n\t\tif (this._authInfo !== authInfo) {\n\t\t\tif (this._authInfo && this._authInfo.UID && (!authInfo || this._authInfo.UID !== authInfo.UID)) {\n\t\t\t\t// The user logged out or another user logged in on the same browser.\n\n\t\t\t\t// Distinguish between 2 users who log in from the same browser; see\n\t\t\t\t// https://github.com/amplitude/Amplitude-Javascript#logging-out-and-anonymous-users.\n\t\t\t\tif (this._amplitude) this._amplitude.regenerateDeviceId();\n\n\t\t\t\t// Prevent the next user who logs in (e.g., on a public terminal) from\n\t\t\t\t// seeing the previous user's Intercom messages.\n\t\t\t\tif (this._intercom) this._intercom(\"shutdown\");\n\n\t\t\t\tif (this._fullStory) this._fullStory.clearUserCookie();\n\t\t\t}\n\n\t\t\tif (authInfo) {\n\t\t\t\tif (this._amplitude && authInfo.Login) this._amplitude.setUserId(authInfo.Login || null);\n\t\t\t\tif (window.ga && authInfo.Login) window.ga(\"set\", \"userId\", authInfo.Login);\n\n\t\t\t\tif (this._telligent && authInfo.Login) this._telligent(\"setUserId\", authInfo.Login);\n\n\t\t\t\tif (authInfo.UID) this.setIntercomProperty(\"user_id\", authInfo.UID.toString());\n\t\t\t\tif (authInfo.IntercomHash) this.setIntercomProperty(\"user_hash\", authInfo.IntercomHash);\n\t\t\t\tif (this._fullStory && authInfo.Login) {\n\t\t\t\t\tthis._fullStory.identify(authInfo.Login);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (this._intercom) this._intercom(\"boot\", this._intercomSettings);\n\t\t}\n\t\tif (this._user !== user && user) {\n\t\t\tif (user.Name) this.setIntercomProperty(\"name\", user.Name);\n\t\t\tif (this._fullStory) this._fullStory.setUserVars({displayName: user.Name});\n\t\t\tif (user.RegisteredAt) {\n\t\t\t\tthis.setUserProperty(\"registered_at\", new Date(user.RegisteredAt).toDateString());\n\t\t\t\tthis.setIntercomProperty(\"created_at\", new Date(user.RegisteredAt).getTime() / 1000);\n\t\t\t}\n\t\t}\n\t\tif (this._primaryEmail !== primaryEmail) {\n\t\t\tif (primaryEmail) {\n\t\t\t\tthis.setUserProperty(\"email\", primaryEmail);\n\t\t\t\tthis.setIntercomProperty(\"email\", primaryEmail);\n\t\t\t\tif (this._fullStory) this._fullStory.setUserVars({email: primaryEmail});\n\t\t\t}\n\t\t}\n\n\t\tthis._user = user;\n\t\tthis._authInfo = authInfo;\n\t\tthis._primaryEmail = primaryEmail;\n\t}", "setUser({\n commit\n }, payload) {\n commit(\"setUser\", payload);\n }", "function handleGetUser(event) {\n\tif (DEBUG) {\n\t\tconsole.log (\"Triggered handleGetUser\")\n\t}\n\t//TODO 2\n\t// This event is triggered by the a.user_link element. Hence, $(this)\n\t// is the <a> that the user has pressed. $(this).parent() is the li element\n\t// containing such anchor.\n\t// Use the method event.preventDefault() in order to avoid default action\n // for anchor links.\n\tevent.preventDefault();//Avoid default link behaviour\n\t// Remove the class \"selected\" from the previous #user_list li element and\n\t// add it to the current #user_list li element. Remember, the current \n\t// #user_list li element is $(this).parent()\n\n // e.target is the clicked element!\n // If it was a list item\n $(this).parent().parent().children().each(function(){\n var user = $(this).children();\n if(user.hasClass(\"selected\")){\n user.removeClass(\"selected\");\n }\n });\n $(this).addClass(\"selected\");\n\t// Finally extract the href attribute from the current anchor ($(this)\n\t// and call the method getUser(url) to make the corresponding HTTP call \n\t// to the RESTful API. You can extract an HTML attribute using the \n\t// attr(\"attribute_name\") method from JQuery.\n var url = $(this).attr(\"href\");\n getUser(url);\n\n\treturn false; //IMPORTANT TO AVOID <A> DEFAULT ACTIONS\n}", "function resolveAuthenticatedUser(data){\n\t\t\tif(data.status == true){\n\t\t\tif(data.applicationStatus == \"none\")\n\t\t\t\t$state.go('roorrmu',{userId: $state.params.userId});\n\t\t\t\telse if(data.applicationStatus == \"applicableForRenewal\")\n\t\t\t\t$state.go('loanrenewal',{mdnid: $state.params.mdnid , phone: $state.params.phone,userId: $state.params.userId});\n\t\t\t\telse\n\t\t\t\t$state.go('statusmessage',{statusmessage: data.applicationStatus,userId:$state.params.userId});\n\t\t\t\t//workflow on new user or existing user need to be added here\n\t\t\t\t//api need to return is the user is new or old\n\t\t\tloaderService.toggle(false);\n\t\t\t}else{\n\t\t\t\t//wrong otp\n\t\t\t\t//otp authentication failed\n\t\t\t\tvm.errorMessage = data.errorText;\n\t\t\t\tloaderService.toggle(false);\n\n\t\t\t}\n\t\t}", "function getUserById(userid) {\n}", "function activeUser(user) {\n\tViewHeader.activeUser(user);\n}", "function onRendered() {\n identifyUser();\n}", "function selectUser(user) {\n\t vm.currentUser = user;\n\t\t}", "function currentUser(callback) {\n\tsendRequest({ request: 'current user' }, callback);\n}", "function useSaveButton() {\r\n var user = document.getElementById(\"userID\").value;\r\n editASingleUser(user)\r\n startPage()\r\n}", "getUser() {\n const userName = this.refs.userName.value\n this.props.dispatch(actions.fetchAddUser(userName))\n }", "currentUser(state, user) {\n state.currentUser = user;\n }", "function grantUserAccess(username) {\n \n document.getElementById(\"greeting-name\").innerHTML = username; //rewrite greeting to 'Hello, <username>!'\n document.getElementById(\"greeting\").style = 'visibility: visible';\n \n enableCommentBox(); //for posting comments\n hideEnterButton(false); //for posting comments\n hideLogoutButton(false);\n hideLoginAndSignupButtons(true);\n hideUsersEditAndDoneEditButtons(false);\n\n}", "authUser (state, userData) {\n state.token = userData.token\n state.userId = userData.userId\n state.refreshToken = userData.refreshToken\n }", "function editUser(event) {\n $button= $(event.currentTarget);\n $userId=$button.parent().parent().parent().attr(\"id\");\n findUserById($userId).then(renderUser);\n }", "User(userData) {\n\t\tthis.utils.logger.debug({description: 'Account Action called.', userData: userData, user: new Account(userData), func: 'user', obj: 'Grout'});\n\t\treturn new Account(userData);\n\t}", "SET_USER(state, data) {\n state.user = data;\n }", "function helper() {\n user.sayHello();\n}", "function getNicknameAndFireOffAction (userId, action, text) {\n var getQuery = {\n text: 'SELECT nickname FROM nicknames WHERE id=$1;',\n values: [userId]\n }\n pg.connect(process.env.DATABASE_URL, (err, client, done) => {\n if (err) {\n console.error(err)\n }\n client.query(getQuery, (err, result) => {\n done()\n if (err) {\n console.error(err)\n } else {\n if (result.rows[0]) {\n action(text, result.rows[0].nickname, userId)\n } else {\n action(text, null, userId)\n }\n }\n })\n })\n}", "getUserByID(userid, cb) {\n\t\tvar query = {\n\t\t\t_id: global.dbController.convertIdToObjectID(userid)\n\t\t}\n\t\tthis.getUserDetails(query, cb)\n\t}", "SET_USER(state, user) {\n state.user = user;\n }", "function handleGetUser(event) {\n if (DEBUG) {\n console.log (\"Triggered handleGetUser\");\n }\n\n event.preventDefault();\n $(\"#user_list li\").removeClass(\"active\");\n\n // Make the user element 'active' visually\n $(this).parent().addClass(\"active\");\n\n prepareUserDataVisualization();\n\n var url = $(this).attr(\"href\");\n get_user(url);\n\n return;\n}", "editUser(username, userPhoto, handler) {\n if (username) {\n this.user.displayName = username;\n }\n\n if (userPhoto) {\n this.user.photo = userPhoto;\n }\n\n handler();\n }", "checkUser() {\n this.socket.on(\"CheckUser\", async () => {\n try {\n if (this.socket.request.user) {\n await UserController.checkUser(this.socket.request.user.id);\n this.socket.emit(\"UserAuthorized\", this.socket.request.user);\n } else {\n this.socket.emit(\"UserAuthorized\", false);\n }\n } catch (error) {\n console.error(error.message);\n }\n });\n }", "function handleEditUser(event){\n //Extract the url of the resource from the form action attribute.\n if (DEBUG) {\n console.log (\"Triggered handleEditUser\");\n }\n var $form = $(this).closest(\"form\");\n var body = serializeFormTemplate($form);\n var user_url = $(this).closest(\"form\").attr(\"action\");\n edit_user(user_url, body);\n return false;\n}", "async loadUser({ commit, dispatch }) {\n let user = await dispatch(\"getUser\");\n if (user) {\n commit(\"setUser\", user);\n }\n }", "execute(message, args) {\n const taggedUser = message.mentions.users.first();\n message.channel.send(`Jo ${taggedUser.username}, iemand probeert je de ober uit te trappen`);\n }", "function directUserFromMain () {\n if (nextStep == \"View departments, roles, or employees\") {\n // Prompt them which info they would like to view\n viewInfoPrompt()\n // Then capture the response and invoke the direct user from view info function\n .then (response => {\n nextStep = response.itemToView;\n directUserFromViewInfo();\n })\n // If there is an error, log the error\n .catch(err => {if (err) throw err});\n }\n if (nextStep == \"Add new departments, roles, or employees\") {\n // Prompt them for what specific information they would like to add...\n addInfoPrompt()\n // Then capture the response and invoke the direct user from add info function...\n .then (response => {\n nextStep = response.itemToAdd;\n directUserFromAddInfo();\n })\n // If there is an error, log the error\n .catch(err => {if (err) throw err});\n }\n if (nextStep == \"Update the role for an existing employee\") {\n // Prompt them for what specific information they would like to update on role, and for whom they would like to update for\n updateInfoPrompt()\n // Then capture the response and invoke the direct user from updtate info functoin\n .then(response => {\n nextStep = response.itemToUpdate\n directUserFromUpdateInfo();\n })\n // If there is an error, log the error\n .catch(err => {if (err) throw err});\n }\n if (nextStep == \"Finish session\") {\n // Log to the user the session is completed..\n console.log(`\\nsession completed!\\n`);\n // And end the connectoin to the DB...\n endConnectionToSQL();\n return;\n }\n }", "function getUserAction(){\n process.stdin.once('data', (chunk) => {\n userAction = chunk.toString().trim();\n checkAction()\n\n});\n}", "function displayUsers(users) {\n for (var i = 0; i < users.length; i++) { \n var user=users[i];\n user.displayUser();\n }\n\n}", "function userinfo_dispatcher_routines() {\n\n\n}", "function getUser () {return user;}", "fetchUser({\n commit\n }, user) {\n commit('SET_LOGGED_IN', user !== null);\n if (user) {\n commit('SET_USER', {\n userName: user.userName,\n email: user.email\n });\n } else {\n commit('SET_USER', null);\n }\n }", "async updateUser () {\n\t\tawait this.getFirstTeam();\t\t// get the first team the user is on, if needed, this becomes the \"origin\" team\n\t\tawait this.getTeamCreator();\t// get the creator of that team\n\t\tawait this.doUserUpdate();\t\t// do the actual update\n\t}", "async fetchUser(){\n\t\treturn res.status(200).send({\n\t\t\tmessage: 'Successful Operation',\n\t\t\tuser: req.user\n\t\t})\n\t}", "auth_user_data(state, user){\n state.auth_user = user\n }", "function HttpUserEvent() { }", "function HttpUserEvent() { }", "function HttpUserEvent() { }", "checkUser(user, onTakePill, onNotify){\n console.log('checking user', user);\n \n let handler = (err, res) => { \n console.log('checked user with res', res);\n let d = moment(res.d);\n \n if(that.checkIfShouldTakePill(user, d)){\n onTakePill(user);\n\n if(that.checkIfShouldNotify(user)){\n console.log('notifying');\n onNotify(user)\n }\n }\n \n };\n this.db.getLastTakenDate(user.id, handler)\n }" ]
[ "0.66447324", "0.6609724", "0.65335166", "0.623834", "0.61780006", "0.6171464", "0.61690974", "0.6145827", "0.61251837", "0.6012342", "0.5987544", "0.5952207", "0.59098077", "0.5875212", "0.58679193", "0.58532405", "0.58496934", "0.5840773", "0.5840561", "0.5818845", "0.5803755", "0.5783958", "0.578007", "0.5773447", "0.5773447", "0.5770793", "0.57617176", "0.5757657", "0.57421446", "0.5735338", "0.5722552", "0.5682399", "0.56735706", "0.56726074", "0.5672091", "0.5667236", "0.56426954", "0.5631284", "0.5620225", "0.5618682", "0.56036687", "0.5594881", "0.5582081", "0.5581468", "0.55776197", "0.55760074", "0.5575939", "0.5571644", "0.5570728", "0.5566499", "0.55496824", "0.55466866", "0.55448747", "0.55361205", "0.55344105", "0.55296403", "0.5526465", "0.552449", "0.55210674", "0.55184495", "0.55076516", "0.55056715", "0.5484759", "0.54666615", "0.54635274", "0.54625124", "0.54602855", "0.5457277", "0.5451605", "0.5450167", "0.54489887", "0.54465383", "0.54465145", "0.5442879", "0.5442011", "0.54405624", "0.5440303", "0.5439878", "0.54375875", "0.54256344", "0.5423307", "0.5421432", "0.54192567", "0.5409859", "0.5404596", "0.54044074", "0.5403346", "0.5402168", "0.5399023", "0.5398947", "0.5398505", "0.53969246", "0.53962463", "0.539301", "0.538925", "0.53879184", "0.5387624", "0.5387589", "0.5387589", "0.5387589", "0.5383203" ]
0.0
-1
Callback function which sends the intial get requst to Investopedia
function termLookup(info, tab){ var term = info.selectionText.replace(/\s+/g, '-').toLowerCase(), firstLetter = term.charAt(0); var DOMAIN = 'http://www.investopedia.com', PATH = /terms/+firstLetter+'/'+term+'.asp', URL = DOMAIN+PATH; $.get(URL, parseResponse); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function _run() {\n let url = 'https://maker.ifttt.com/trigger/' + this.action + '/with/key/' + this.key;\n\n var xmlhttp = new XMLHttpRequest();\n xmlhttp.open('GET', url, true);\n // xmlhttp.onreadystatechange = (e) => { console.log(e); };\n xmlhttp.send();\n}", "function sendGet(url, params)\n{\n\t\n}", "function sendGet(url, params)\n{\n\t\n}", "getInvoice(param,callback){\n const api_data = {\n api_name:'/get-invoice',\n coin:this.coin,\n api_key: this.apikey,\n password : this.api_password,\n };\n api_call.apiPostCall(api_data,param,callback);\n }", "function on_dispatch_auto_get(node) {\n // get local flow, try http without authentication\n node.url = node.local_url;\n node.protocol = \"http\";\n var send_url = node.protocol + \"://\" + node.url + \"/flows\";\n\n send_request(node, send_url, METHOD_GET, {\"Authorization\": VALUE_AUTH}, null\n , function(resp) { // callback on response returned\n on_dispatch_get_end(node, resp);\n }\n , function(resp) { // callback on error occurs\n on_dispatch_get_error(node, resp);\n }\n );\n }", "function http_get(req_url){\n request.get(\n bal_query,\n function(error, response, body) {\n console.log(\"Clickatell GET:\")\n node.send(\"Clickatell GET:\");\n if (!error && response.statusCode == 200) {\n if (DEBUG){\n console.log(body, response)\n }\n console.log(req_url)\n console.log(body)\n node.send(body);\n }\n }\n );\n }", "function eosRequest(method, elementID) {\n console.log(method, elementID);\n switch (method) {\n case 'pull':\n switch (elementID) {\n case 'hat-hotspot':\n break;\n\n case 'claim-notifications':\n break;\n\n }\n break;\n\n case 'push':\n switch (elementID) {\n case 'want-button':\n $('#purchase-response').hide();\n $('#want-response').show();\n break;\n\n case 'purchase-button':\n eos.contract('promoteit')\n .then((contract) => {\n console.log(\"CONTRACT INIT\");\n contract.buyitem( {\n \"serialnum\": \"0\",\n \"buyername\": \"james\"\n }, {authorization: EOS_CONFIG.contractSender} ) \n .then((res) => {\n console.log(\"POST CALL\");\n console.log(res);\n $('#purchase-response').show();\n $('#want-response').hide();\n $('#hidden-hat').show();\n }).catch((err) => { console.log(err) })\n }).catch((err) => { console.log(err) })\n break;\n\n case 'add-item-button':\n $('#add-item-button').hide();\n $('#add-item-response').show();\n setTimeout(function() {$('#claim-notifications').show()}, 3000);\n break;\n\n case 'receive-reward-button':\n $('#receive-reward-button').hide();\n $('#receive-reward-response').show();\n $('#claim-notifications').hide();\n $('#token-balance-amount').html('3.45');\n break;\n }\n break;\n }\n}", "function get(e){\n\t\t\t\n\t\t\tvar start = new Date().getTime(),\n\t\t\t\t$this = $(this).removeClass(\"queued\").addClass('calling');\n\t\t\t\n\t\t\t$.ajax( $this.find(\"a.url\").text(), {\n\t\t\t\terror:function( xhr, status, err ){\n\t\t\t\t\t// Just notification for now but this could handle redirects later\n\t\t\t\t\tconsole && console.error(err);\n\t\t\t\t\t$this.addClass(\"error\").append(\"<div>\"+err+\"</div>\");\n\t\t\t\t\t$gc.trigger('next')\n\t\t\t\t},\n\t\t\t\tsuccess: function( data, status, xhr ){\n\t\t\t\t\tvar time = new Date().getTime() - start;\n\t\t\t\t\t$this.addClass(\"done\")\n\t\t\t\t\t\t.trigger(\"done\",data)\n\t\t\t\t\t\t.find(\".time\").html(time+\"ms\");\n\t\t\t\t},\n\t\t\t\tcomplete:function(xhr, status){\n\t\t\t\t\t$this.removeClass(\"calling\");\n\t\t\t\t},\n\t\t\t\tconverters:{\n\t\t\t\t\t\"* text\": window.String,\n\t\t\t\t\t\"text html\": true,\n\t\t\t\t\t\"text xml\": true\n\t\t\t\t},\n\t\t\t\tdataType:'html'\n\t\t\t});\n\t\t}", "function getRequest(callback) {\n console.log(\"text \" + text);\n request({\n url: 'https://api.wit.ai/message?q=' + encodeURI(text), \n method: 'GET', \n headers: { \n 'Authorization': 'Bearer ' + config.wit_access_token\n }\n }, function(error, response, body){\n if(!error && response.statusCode == 200) {\n var bodyjsonparse = JSON.parse(body);\n var intent = \"\";\n \n //console.log(\"JSON Body \" + bodyjsonparse);\n //console.log(\"Entities \" + bodyjsonparse['entities']['intent'][0]['value']);\n \n \n try {\n intent = bodyjsonparse['entities']['intent'][0]['value']['value'];\n if (intent == undefined) {\n intent = bodyjsonparse['entities']['intent'][0]['value'];\n }\n \n } catch (err) {\n intent = '';\n \n } finally {\n console.log(\"intent \" + intent);\n \n executeIntent(intent);\n }\n\n /*\n var entities = bodyjsonparse[\"outcomes\"][0][\"entities\"];\n var intent;\n console.log(entities);\n if (entities.length == 0) {\n intent = \"\";\n } else if (entities[\"intent\"] == undefined) {\n intent = \"\";\n } else {\n intent = entities[\"intent\"][0][\"value\"];\n }\n */\n\n }\n });\n}", "function request(){\n\n var remoteID = getPrevious();\n\n if ( !remoteID ) return; // entry\n\n CONNECTIONS[ remoteID ].send( 'start', { request: true }, true );\n}", "function doTheWork(){\n console.log('Getting the stock price...')\n request(url, getStockInfoBody);\n}", "function quest5(RequestStore, SessionID, callback) {\n RequestStore.post(\n {\n url:'https://store.steampowered.com/holidayquests/ajaxclaimitem/', \n form: { sessionid: SessionID, type: 1 }\n }, function (error, response, body){\n var data = JSON.parse(body);\n if(data.success){\n callback();\n }else{\n console.log('error getting free token');\n callback();\n }\n })\n}", "function callback(action) {\n if (req.readyState === 4) {\n if (req.status === 200) {\n if (action === \"findUser\") {\n processSearchResults(req.responseXML);\n } else if (action === \"addNote\") {\n refreshCurrentNotes();\n } else if (action===\"getNote\") {\n changeNote(req.responseXML);\n } else if (action===\"getHistory\") {\n changeArea(req.responseXML);\n } else if (action===\"getNotes\") {\n changeArea(req.responseXML);\n } else if (action===\"getPersonalNotes\") {\n changeArea(req.responseXML);\n } else if (action===\"disable\") {\n historyViewImg.trigger(\"click\");\n } else if (action===\"resetNotifications\") {\n $(\"#personalBar\").children().first().trigger(\"click\");\n } else if (action===\"findUserInfo\") {\n updateUserInfo(req.responseXML);\n } else if (action===\"findUserInfoSelf\") {\n updateUserInfo(req.responseXML, sessionStorage.getItem(\"loggedInUser\"));\n }\n }\n }\n }", "function GET(){\n \n}", "function getLink(gameName, type, callback){\n var finalData = '';\n var preview;\n var testUrl;\n var search;\n // search = users game name iputted in discord chat\n //console.log(type);\n if (type === 'track' || type === 'playlist'){\n search = gameName + ' soundtrack';\n }\n else if (type === 'artist' || type === 'album') {\n search = gameName;\n }\n else if (search === undefined){\n callback(null, null);\n }\n //console.log(search);\n //spotify api requires spaces be replaced with %20 or +\n var i = 0,strLength = search.length;\n \n for(i; i < strLength; i++) {\n \n search = search.replace(\" \", \"+\");\n \n }\n\n //api url + search + apikey to get results\n //console.log('22 : ' + search);\n var url = 'https://api.spotify.com/v1/search?q='+ search + '&type='+type+'&client_id='+apiKey;\n //console.log(url);\n \n //use http.get to call url and get response\n https.get(url, function(response) {\n\n //while http is responding with \"data\" event get stream and add to finaldata\n response.on(\"data\", function (data) {\n finalData += data;\n });\n \n // when the end event is sent parse recieved data and get first\n // result from the parsed json and assign to items variable\n response.on(\"end\", function() {\n var temp = JSON.parse(finalData);\n //console.log(temp);\n var items;\n if (type === 'playlist'){\n items = temp.playlists.items[0].external_urls.spotify;\n }\n if (type === 'track'){\n items = temp.tracks.items[0].external_urls.spotify;\n preview = temp.tracks.items[0].preview_url;\n //console.log(temp.tracks.items[0]);\n }\n if (type === 'album'){\n items = temp.albums.items[0].external_urls.spotify;\n }\n if (type === 'artist'){\n items = temp.artists.items[0].external_urls.spotify;\n }\n //console.log(items);\n testUrl = items;\n callback(testUrl, preview);\n });\n\n});\n\n}", "function RequestToVolunteer (){\nkony.application.showLoadingScreen(null, \"Loading..\", \nconstants.LOADING_SCREEN_POSITION_ONLY_CENTER, true, true, { \nshouldShowLabelInBottom: \"false\", separatorHeight: 20} );\n // Let's get the news type the user selected\n //var selectedKey = frmFoxNews.lstNewsType.selectedKey;\n //alert (\"########## Selected Key:\" + selectedKey);\n // Let's first check that the user picked a valid value\n //if (!kony.string.equalsIgnoreCase(selectedKey, \"none\")){\n // Populating the input params for the service call and invoking the service\n // We're passing in the selected key for the user's selection in the combobox\n // var inputParams = {serviceID:\"getFoxNews\",newsType:selectedKey};\n // Now we make the call to the service using our input parameters and specifying\n // the function processServiceResults as our callback when the service returns results\n // appmiddlewareinvokerasync(inputParams, processServiceResults);\n if (!mobileFabricConfigurationForIndigenousRequestToVolunteer.isKonySDKObjectInitialized)\n {\n initializeMobileFabricForIndegenoueRequestToVolunteer();\n \n }\n else if (mobileFabricConfigurationForIndigenousRequestToVolunteer.isKonySDKObjectInitialized)\n {\n getIndigenousRequestToVolunteer();\n }\n }", "function sendRetestQuery(current_org, current_repo, current_pull_number) {\n $.get( \"retest\", { organization: current_org, repository: current_repo, pull_number: current_pull_number }, function(data) {\n if (data == \"success\") {\n $(\"#confirmation-dialog\").hide();\n $(\"#success-dialog\").show(100).delay(1000).hide(100);\n } else {\n $(\"#confirmation-dialog\").hide();\n $(\"#error-dialog\").show(100).delay(3000).hide(100);\n }\n});\n}", "function getPartnerEventInvitations() {\n request(GET_LINK, (err, res, body) => {\n const partners = JSON.parse(body).partners;\n const countries = parsePartners(partners);\n request.post(POST_LINK, {json: {countries : countries}}, (err, httpResponse, body) => {\n console.log(httpResponse.statusCode)\n });\n });\n}", "function emailReturning(survey_id,event_id,participant_id,hash,email,page) {\r\n\t$.get(page, { s: hash, survey_id: survey_id, event_id: event_id, participant_id: participant_id, email: email }, function(data) {\r\n\t\tif (data == '0') {\r\n\t\t\talert(woops);\r\n\t\t} else if (data == '2') {\r\n\t\t\t$('#autoEmail').hide();\r\n\t\t\t$('#provideEmail').show();\r\n\t\t} else if (email != '') {\r\n\t\t\tsimpleDialog('The email was successfully sent to '+data,'Email sent!');\r\n\t\t}\r\n\t});\r\n}", "function modalCall(searchTerm) {\n var queryUrlBase = `https://app.ticketmaster.com/discovery/v2/events.json?keyword=${searchTerm}&${authKey}`\n $.ajax({\n method: \"GET\",\n url: queryUrlBase\n }).then(function(response) {\n // console.log(response._embedded.events[0])\n modalInfo(response._embedded.events)\n console.log(response._embedded.events[1])\n \n });\n }", "function sendGet\r\n\t\t(\r\n\t\t\turi,\r\n\t\t\tcallbackFun\r\n\t\t)\r\n\t\t{\r\n\t\t\tvar xhr = new XMLHttpRequest();\r\n\t\t\t\r\n\t\t\txhr.open(\"GET\", uri, true);\r\n\t\t\t\r\n\t\t\txhr.onreadystatechange = function()\r\n\t\t\t{\r\n\t\t\t\tif (this.readyState != 4)\r\n\t\t\t\t\treturn;\r\n\t\t\t\t\r\n\t\t\t\tif (this.status != 200)\r\n\t\t\t\t{\r\n\t\t\t\t\talert( \"error: \" + (this.status ? this.statusText : \"request failed\") ); // handle error\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tcallbackFun(this.responseText, this.responseXML);\r\n\t\t\t};\r\n\t\t\t\r\n\t\t\txhr.send();\r\n\t\t}", "function fetchData() {\n queryType=document.querySelector('#queryType').value;\n itemID=document.querySelector('#itemID').value;\n getFromSWAPI(queryType, itemID)\n}", "function sendRequest(url) {\n $.getJSON( url, function adinfo (data) {\n var zodiac = {};\n zodiac.quote = data.horoscope;\n zodiac.sign = data.sunsign.toLowerCase();\n update(zodiac);\n });\n }", "function sendRequest(url, callback) {\n console.log(\"Sending GET to \" + url);\n request_lib.get(url, function (error, response, body) {\n if (!error && response.statusCode == 200) {\n console.log(\"Fact is \" + body);\n callback(body);\n } else {\n console.log(\"Error=\" + error);\n }\n });\n }", "function queryDataGet(url,dataSend,callback){\n \n $.ajax({\n type: 'GET',\n url: url,\n data: dataSend,\n async: true,\n dataType: 'text',\n success: callback\n });\n}", "function kodi_request(msg,callback){\n\tconsole.log(JSON.stringify(msg));\n\n\tvar options = {\n\t\thostname: \"BedroomRPi\",\n\t\tport: 80,\n\t\tpath: \"/jsonrpc?request=\"+qs.escape(JSON.stringify(msg)),\n\t\tmethod: \"GET\",\n\t\theaders:{\n\t\t\t'Content-Type': 'application/json'\n\t\t}\n\t}\n\tvar req = http.request(options,function(res){\n\t\tres.setEncoding('utf8');\n\t\tres.on('data',function(chunk){\n\t\t\tconsole.log(chunk);\n\t\t\tcallback(JSON.parse(chunk));\n\t\t});\n\t\n\t});\n\n\treq.on('error',function(e){\n\t\tconsole.log(\"Error Talking to Kodi\", options[\"hostname\"],\n\t\t\t\te.message);\n\t});\n\n\treq.setTimeout(20000,function(e){\n\t\tconsole.log(\"Request Timeout\");\n\t});\n\n\treq.end();\n\n}", "get(form_data, success_callback, failure_callback) {\n let url = \"/global/str/subscription\";\n return WebClient.basicGet(\n form_data,\n url,\n success => {\n success.data.subscription = new EliteAPI.Models.STR.Subscription(success.data.subscription);\n if (success_callback) success_callback(success);\n },\n failure_callback\n );\n }", "function Apiai() {\n return {\n request: function(text, callback) {\n var req = apiClient.textRequest(text, {sessionId: '54321'})\n\n req.on('response', function(response) {\n var chatbotSpeech = response.result.fulfillment.speech\n if(!response.result.actionIncomplete && response.result.contexts[response.result.contexts.length - 1].name == 'no-additem') {\n callback(true, {name: 'Chair', description: 'This is a chair', picture: 'url.to.picture'}, chatbotSpeech)\n } else {\n callback(false, null, chatbotSpeech)\n }\n })\n\n req.on('error', function(error) {\n console.log(error)\n })\n\n req.end()\n }\n }\n}", "function getHotelInterest(event,edition,visitor,itemType,bookingStatus,itemId,callback){\n\n if(typeof itemId!='undefined'){\n var itemstring=\"&itemId=\" + itemId;\n }else{\n var itemstring='';\n }\n if(visitor!=''){\n var visitortring=\"&visitor_id=\" + visitor;\n }else{\n var visitortring='';\n }\n\n $.ajax({\n type: \"GET\",\n url: site_url_attend + \"/ajax?for=bookingInterest&edition=\" + edition + \"&event_id=\" + event + visitortring + \"&booking_type=\" + itemType + \"&bookingStatus=\" + bookingStatus + itemstring,\n success: function(d) {\n result = $.parseJSON(d);\n if(result.status.code == 1){\n var data = result.data;\n callback(data);\n }\n },\n error: function() {}\n });\n\n}", "function requestcommand(jeedomcmd) {\n\n var myKeyValue, myIPValue, myHttps;\n\n myKeyValue = localStorage.getItem(\"KEY\");\n myIPValue = localStorage.getItem(\"IP\");\n myHttps = \"\";\n if (JSON.parse(localStorage.getItem(\"HTTPS\"))) {\n myHttps = \"s\";\n }\n\n var client = new XMLHttpRequest();\n client.open(\"GET\", \"http\" + myHttps + \"://\" + myIPValue + \"/core/api/jeeApi.php?apikey=\" + myKeyValue + \"&type=cmd&id=\" + jeedomcmd);\n console.log(\"http\" + myHttps + \"://\" + myIPValue + \"/core/api/jeeApi.php?apikey=\" + myKeyValue + \"&type=cmd&id=\" + jeedomcmd);\n client.onreadystatechange = function () {\n if (client.readyState == 4) {\n if (client.status == 200) {\n console.log(client.responseText);\n navigator.vibrate([500, 500, 500]);\n }\n }\n };\n client.send();\n}", "function getSymbol(symbol){\nrequest('GET', \"http://api.fixer.io/latest\").done(function (res) {\ndata = JSON.parse(res.getBody());\ngetGes(data,symbol)\n\n});\n}", "function symptoms(agent) {\n var body=JSON.stringify(request.body);\n console.log(body);\n var obj = JSON.parse(body);\n let symptoms=obj.queryResult.queryText;\n // use outputContext[2] when testing in dialogflow console\n //let insuranceNumber=obj.queryResult.outputContexts[2].parameters.Insurance_Number; \n let insuranceNumber=obj.queryResult.outputContexts[6].parameters.Insurance_Number;\n console.log(insuranceNumber);\n console.log(symptoms);\n let data = '';\n let url = encodeURI(`https://hook.integromat.com/avnuxe3kkygvng5g6c2f8f4eq2sjilss?Symptoms=` + symptoms);\n\treturn new Promise((resolve, reject) => { \n const request = https.get(url, (res) => {\n res.on('data', (d) => {\n data += d;\n console.log(JSON.stringify(data));\n var answer=JSON.stringify(data);\n if (answer.includes('no diagnosis')){\n \t agent.add(`Sorry I could determine a diagnosis.`);\n agent.add(`Please propose a date when you have time to see a doctor. The date has to be in the following format: DD/MM/YYYY HH:mm`);\n }else{\n \treturn new Promise((resolve, reject) => {\n \tconsole.log(`Start process`);\n \tlet url = encodeURI(`https://hook.integromat.com/38joojtm894r9ag9mlpc623y1ouu13y4?InsuranceNumber=`+ insuranceNumber + `&Symptoms=` + symptoms + `&dateTime=nodate`);\n \t\tagent.add(`Thank you, please check your e-mail to see which further actions are required`);\n \t\t\tagent.add(`I hope I could help. Get well soon and until next time.`);\n console.log(`Request sent`);\n \tconst request = https.get(url, (res) => {\n \t\t\tres.on('data', (d) => {\n \t\tdata += d;\n \t\t\t});\n \t\t\tres.on('end', resolve);\n \t\t\t});\n \t\t\trequest.on('error', reject);\n \t\t\t\t});\n }\n });\n res.on('end', resolve);\n });\n request.on('error', reject);\n });\n }", "function getObject(searchTerm, callback) {\nvar res=$.ajax({\n type: \"GET\",\n data: {\n apikey: '758a9c4eb110abe05628670f79cacb15',\n q: searchTerm,\n format: \"jsonp\",\n callback: \" \"\n // f_has_lyrics: searchTerm,\n // lyrics object parameters\n // track_id: The musiXmatch track id,\n // track_mbid: The musicbrainz track id,\n // format: Decide the output type(json or xml)\n },\n url: \"http://api.musixmatch.com/ws/1.1/\"\n });\n\nconsole.log(res);\n\n// .done(function(data) {\n// var dataString = data.slice(2, -2);\n// var dataObject = JSON.parse(dataString);\n\n// function getTrackId(){\n// var idArray = dataObject.message.body.track_list\n// idArray.map(function(obj){\n// var ajaxId = obj.track.track_id\n// return ajaxId;\n// })\n// }\n// })\n }", "function SendToFiWareGet(url, callback)\n{\n\tvar req = new XMLHttpRequest();\n\treq.onreadystatechange = function(e)\n\t{\n\t\tif (this.readyState == 4 && this.status == 200)\n\t\t{\n\t\t\ttry \n\t\t\t{\n\t\t\t\tvar json = JSON.parse(this.responseText);\n\t\t\t}\n\t\t\tcatch (e)\n\t\t\t{\n\t\t\t\talert(this.responseText);\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tcallback(json);\n\t\t}\n\t}\n\treq.open(\"GET\", url);\n\treq.send();\n}", "function sendRequest (search, callback) {\n\t // First get the access token\n\trequest.post(authOptions, function(error, response, body) {\n\t if (!error && response.statusCode === 200) {\n\t var token = body.access_token;\n\t var options = {\n\t url: 'https://api.spotify.com/v1/' + search,\n\t headers: {\n\t 'Authorization': 'Bearer ' + token\n\t },\n\t json: true\n\t };\n\t // Then send request to spotify\n\t request.get(options, function(error, response, body) {\n\t \t// As JSON response can be album or artist type, data must be sorted \n\t \tfct.sortData(response.body, function(data){\n\t \t\t// Now HTML page can be generated and control is\n\t\t \tcallback(data);\n\t \t})\n\t });\n\t }\n\n\t});\n}", "function found() {\n\t\t\t\t\tconsole.log(\"In stock!\");\n\t\t\t\t\t// alert(\"Found!\");\n\n\t\t\t\t\t// Check if Pick up is an option\n\t\t\t\t\tif ($(`[data-test=\"orderPickupButton\"]`).length) {\n\t\t\t\t\t\t// Add to cart\n\t\t\t\t\t\t$(`[data-test=\"orderPickupButton\"]`).click();\n\n\t\t\t\t\t\t// Stop bot\n\t\t\t\t\t\ttargetBotActive = false;\n\n\t\t\t\t\t\t// Trigger notification\n\t\t\t\t\t\tconsole.log(\"GET \" + finishedEndpoint);\n\t\t\t\t\t\tconst xmlHttp = new XMLHttpRequest();\n\t\t\t\t\t\txmlHttp.open(\"GET\", finishedEndpoint, true);\n\t\t\t\t\t\txmlHttp.send();\n\t\t\t\t\t}\n\t\t\t\t}", "function twinkle() {\n result = httpGet('/mailbox/twinkle');\n}", "function getResult() {\n\n //search again by Show ID\n var showId = this.value;\n console.log(\"Show ID is: \" + showId);\n\n var request = new XMLHttpRequest();\n request.addEventListener(\"load\", displaySelected);\n request.open(\"GET\", `http://api.tvmaze.com/shows/${showId}`);\n request.send();\n\n}", "function getCurrentSong(callback) {\n botobj.fetchJSON(\"http://radio.djazz.se/icecast.php\", function(success, content) {\n if(success) {\n if(content.listeners != null) {\n botobj.fetchJSON(\"http://radiodev.djazz.se/api/now/json\", function(xe, xt) {\n if(xt.title != null && xe) {\n var theTitle = new Buffer(xt.title, \"utf8\").toString(\"utf8\");\n var artist = xt.artist;\n if(artist!=null) {\n theTitle=theTitle+\" by \"+artist;\n }\n callback(theTitle, content.listeners, true);\n return;\n } else {\n var theTitle = new Buffer(content.title, \"utf8\").toString(\"utf8\");\n var splitUp = theTitle.replace(/\\&amp;/g, \"&\").split(\" - \");\n if(splitUp.length===2) {\n theTitle=splitUp[1]+(splitUp[0]?\" by \"+splitUp[0]:\"\");\n }\n callback(theTitle, content.listeners, true);\n }\n });\n } else {\n callback(\"\\u000307Parasprite Radio\\u000f is \\u000304offline!\", \"\", false);\n }\n } else {\n callback(\"\\u000307Parasprite Radio\\u000f is \\u000304offline!\", \"\", false);\n }\n });\n}", "function goGetta (){\n AjaxGet(\"api/get.php\",button);\n }", "function getInvInfo() {\n //create new request\n var req = new XMLHttpRequest();\n if (!req) {\n throw \"Unable to create HttpRequest.\";\n }\n //url should be appropriate php reference\n var url = 'http://web.engr.oregonstate.edu/~weckwera/290/wk10/lab.php';\n req.onload = function () {\n if (this.readyState === 4) {\n console.log(this.status); //tell me that you're doing something\n console.log(this.responseText);//check out server response\n \n //var response = JSON.parse(this.responseText);\n var response = (this.responseText);\n \n //call function with results\n drawInvInfo(response);\n }\n }\n\n var args = \"getInvInfo=true\";\n \n req.open('POST', url);\n req.setRequestHeader(\"Content-Type\", \"application/x-www-form-urlencoded\");\n req.send(args);\n}", "function searchSpotify(){ \r\n console.log(\"got here 2\")\r\n var query = $search.val();\r\n console.log(\"got here 3 value of query = ...\")\r\n console.log(query);\r\n console.log(\"------\");\r\n \r\n// var searchType = $radioBtn.val();\r\n var searchType = $(\"input:radio[name=qryType]:checked\").val();\r\n var params = {q: query, type: searchType};\r\n \r\n $.get(searchURL, params).done(onDataReceive).fail(onError)\r\n \r\n }", "singleReadTest(id, film, resolve, reject, totalReq) {\n\n /* This instance object reference */\n let self = this;\n /* Callback function names */\n let cb_ok = 'films-ok-' + id;\n let cb_fail = 'films-fail-' + id;\n /* Query for filtering vertices */\n let q = \"{\\\"bool\\\":{\\\"filter\\\":{\\\"term\\\":{\\\"\" + query_read[self._dbName] + \"\\\":\\\"\" + film + \"\\\"}}}}\";\n\n /* the payload object */\n var internal = {\n query: q,\n index: self._dbName,\n type: \"v\",\n size: 1000\n };\n\n var payload = {\n callbackIdOK: cb_ok,\n callbackIdError: cb_fail,\n action: \"search\",\n object: internal\n };\n\n\n ws.send(JSON.stringify(payload));\n /* adding callback */\n self.callbacks[cb_ok] = function(results){\n console.log('[%d] {%d | %s} (%s) ==> ', self._nproc, id, film, q, self._ctrl, results); //results._source.prop.control, results);\n let control = self.getControl(results);\n self._ctrl = self._ctrl + control;\n\n self._nproc++;\n self._size += sizeof(results);\n self._receivedReq++;\n\n\n if(self._receivedReq >= totalReq){\n resolve({nproc: self._nproc, size: self._size, ctrl: self._ctrl});\n }\n };\n\n /* adding failure callback */\n self.callbacks[cb_fail] = function(results){\n console.log('ERR [%d] ==> ', id, results);\n reject(results);\n };\n\n }", "function enpoints() {\n var directivo = getGET().idDirectivo;\n //code\n gapi.client.load('communicationchannel', 'v1', function(){\n gapi.client.communicationchannel.listDirectivo_Proyecto({\"directivo\":directivo}).execute(function(resp){\n if (resp.code) {\n //code\n }else{\n ProyectoItems = resp.items;\n console.log(\"Proyectos Directivo: \" + ProyectoItems.length);\n }\n });\n },ROOT);\n}", "function song_startfirst(){\nvar request = createXMLHttpRequest();\nurl=foobarctrlurl + \"?cmd=SeekSecond&param1=0\";\nrequest.open(\"GET\", url, true);\nrequest.send(\"\");\n\n}", "get(form_data, success_callback, failure_callback) {\n let url = \"/global/str/order\";\n return WebClient.basicGet(\n form_data,\n url,\n success => {\n success.data.order = new EliteAPI.Models.STR.Order(success.data.order);\n if (success_callback) success_callback(success);\n },\n failure_callback\n );\n }", "function getRequest(searchItem) {\n // define search and data type parameters\n var params = {\n s: searchItem,\n r: 'json'\n };\n // define url of the server website\n url = 'http://www.omdbapi.com';\n // request to get results as JSON from server\n $.getJSON(url, params, function(data){\n showResults(data.Search);\n });\n }", "function spotifySearch() {\n\n console.log(\"initializing funciton\");\n var spotify = new Spotify(keys.spotify);\n\n if(!value) {\n value = \"The Sign by Ace of Base\";\n }\n\n \n\n spotify.search({ type: 'track', query: value }, function(error, data, response) {\n if (error) {\n\n console.log('Error occurred: ' + error);\n return;\n }\n var songInfo = data.tracks.items[0];\n var songData =\n \"\\r\\n Artist: \" + songInfo.artists[0].name +\n \"\\r\\n Song Title: \" + songInfo.name +\n \"\\r\\n Song Preview: \" + songInfo.preview_url ;\n\n console.log(songData);\n }); \n \n }", "function getSpotify(b){\n\n // Test to see if Spotify works\n // console.log(\"Spotify works!\");\n\n // Paste the sample code from npm\n spotify.search({ type: 'track', query: b }, function(err, data) {\n\n if ( err ) {\n \n console.log('Error occurred: ' + err);\n \n return;\n \n }\n\n // console.log(\"The raw data: \" + JSON.stringify(data, null, 3));\n \n for(var i = 0; i < data.tracks.items.length; i++) {\n\n // Do something with 'data' \n console.log(\"=================================================================\");\n\n console.log(\"Potential Song Origin ~ \" + i);\n \n for(var j = 0; j < data.tracks.items[i].artists.length; j++) {\n\n console.log(\"Artist involved: \" + data.tracks.items[i].artists[j].name);\n \n }\n\n console.log(\"Album Name: \" + data.tracks.items[i].album.name);\n\n console.log(\"Song Name: \" + value);\n\n console.log(\"=================================================================\");\n\n console.log(\"\");\n\n console.log(\"\");\n\n }\n\n checkConfirm();\n \n });\n\n}", "function _getInvitations() {\n self.invitationsIndex = 1;\n self.hasInvitationsReachedEnd = false;\n requestsLoad.start();\n getInvitations(self.selectedInvitationType).then(function (response) {\n self.invitations = response.content;\n requestsLoad.stop();\n }, function () {\n requestsLoad.stop();\n });\n }", "get(callback) {\n const uri = buildUri()\n log(uri)\n api.get(\n uri,\n null,\n null,\n result.$createListener(callback)\n )\n }", "generateMessage (callback) {\n\t\tthis.doApiRequest(\n\t\t\t{\n\t\t\t\tmethod: 'get',\n\t\t\t\tpath: this.path,\n\t\t\t\ttestTracking: true,\n\t\t\t\treallyTrack: true,\n\t\t\t\trequestOptions: {\n\t\t\t\t\tnoJsonInResponse: true,\n\t\t\t\t\texpectRedirect: true\n\t\t\t\t}\n\t\t\t},\n\t\t\tcallback\n\t\t);\n\t}", "function _request(model, query64, _t){\n\t\t\t\t$.getJSON(_.template(model.API, { network: options.network || \"umg.fyre.co\" , query: query64} ), requestParams, \n\t\t\t\t\t\t_.bind(self.handleResponse, self, {requestCount:_batches.length, _batch: batch}, callback));\n\t\t\t}", "function sendRequestIcecastStatus() {\n xhrIcecast.open(\"GET\", icecastStatusUrl, true);\n xhrIcecast.send();\n}", "async function insideGeofenceCallBack() {\n api\n .notification()\n .content(\"We are inside the geofence!\")\n .id(g_notification_id + 1)\n .title(\"Geofencing done\")\n // .url('...')\n .run();\n}", "function getGoals() {\n sendCommand('get_goals');\n}", "function callPendingSurvey()\n {\n var userInfo = getUserInfo(false);\n userInfo.initial_flag = 1;\n userInfo.channel = 'ui';\n userInfo.uid = userInfo.emp_id;\n userInfo.context_type = 'all';\n socket.emit('getsurveylist',userInfo);\n }", "function vendItem(itemId, totalMoney) {\n var call = \" http://localhost:8080/money/\"\n + totalMoney + \"/item/\" + itemId;\n\n $.ajax({\n type: \"GET\",\n url: call,\n\n // on success, returns change and a thank you message\n success: function (change) {\n $(\"#msgTxt\").html(\"Thank you!!! \");\n displayChange(change);\n timeReset();\n },\n\n // if the call fails, the cause is ascertained. If the server is still available,\n // the server side exception is displayed: insufficient funds or sold out. If the\n // server can't be reached, the server error message is displayed\n error: function (errmsg, txtstatus) {\n\n if (errmsg.readyState === 4) {\n var msg = JSON.parse(errmsg.responseText).message;\n $(\"#msgTxt\").html(msg);\n }\n else if (errmsg.readyState === 0) {\n $(\"#serverError\").show();\n }\n\n timeResetMsg();\n }\n });\n\n}", "function receive(uid, num, gift) {\r\n if(num--)\r\n $.get(this_url + \"gift_accept.php?act=acpt&rqtp=gift&uid=\" + uid, function() {\r\n if(display)\r\n get_sub_panel('ca_gift').text(\"There are \" + num + \" more gifts to send...\"); \r\n send(uid, num, gift);\r\n });\r\n}", "function date(agent) {\n var body=JSON.stringify(request.body);\n console.log(body);\n let obj = JSON.parse(body);\n let dateTime=obj.queryResult.queryText;\n // use outputContext[2] when testing in dialogflow console\n //let insuranceNumber=obj.queryResult.outputContexts[2].parameters.Insurance_Number; \n let insuranceNumber=obj.queryResult.outputContexts[5].parameters.Insurance_Number;\n console.log(insuranceNumber);\n let data = '';\n let url = encodeURI(`https://hook.integromat.com/vqxboiqh8flb8mv1c5ityfg7f8i8pg4l?dateTime=` + dateTime);\n console.log(url);\n\treturn new Promise((resolve, reject) => { \n const request = https.get(url, (res) => {\n res.on('data', (d) => {\n data += d;\n var answer=JSON.stringify(data);\n \tif (answer.includes('false')){\n \t \tagent.add(`The time slot you entered is not available anymore. Please propose another date.`);\n \t}else{\n \tagent.add(`An appointment has been scheduled for you. Please check your emails for further information.`);\n \tagent.add(`I hope I could help. Get well soon and until next time.`);\n \n return new Promise((resolve, reject) => {\n \tconsole.log(`Start process`);\n \tlet url = encodeURI(`https://hook.integromat.com/38joojtm894r9ag9mlpc623y1ouu13y4?InsuranceNumber=`+ insuranceNumber + `&Symptoms=nosymptoms&dateTime=` + dateTime);\n \t\tconst request = https.get(url, (res) => {\n \t\t\tres.on('data', (d) => {\n \t\tdata += d;\n console.log(`Request sent`);\n \tagent.end();\n \t\t\t});\n \t\t\tres.on('end', resolve);\n \t\t\t});\n \t\t\trequest.on('error', reject);\n \t\t\t\t});\n \t\t}\n });\n res.on('end', resolve);\n });\n request.on('error', reject);\n });\n }", "function sendQuery(){\n \n if(APP && APP.network){\n var netStat = APP.network()\n , info = '';\n if(!netStat){\n info = '网络错误,请检查网络连接。'\n callError(info);\n return;\n }\n }\n \n var xhr = new XMLHttpRequest()\n , url = 'http://bistulib.dmdgeeker.com/search?key=' + context.key + '&match=' + context.match;\n \n xhr.onreadystatechange = function(){\n var response = null;\n if(xhr.readyState === 4){\n if((xhr.status >= 200 && xhr.status < 300)|| xhr.status === 304){\n response = xhr.responseText;\n pageState.success(response);\n }\n else {\n var serverError = '服务器出错了:' + xhr.status;\n callError(serverError);\n }\n }\n else {\n // pageState.loading();\n }\n };\n \n xhr.onprogress = function(evt){\n if(evt.lengthComputable){\n //loadProgress.innerText = Math.round(100*evt.loaded/evt.total) + '%';\n }\n };\n \n xhr.timeout = 70000;\n xhr.ontimeout = function(){\n var timeoutError = '加载超时,请检查网络连接。';\n callError(timeoutError);\n xhr.abort();\n };\n \n xhr.open('GET', url);\n xhr.send(null);\n }", "function voicerecord (start, url)\n{\n if (typeof (webphone_api.plhandler) !== 'undefined' && webphone_api.plhandler !== null)\n webphone_api.plhandler.Voicerecord(start, url);\n}", "get(form_data, success_callback, failure_callback) {\n let url = \"/global/str/payment/method\";\n return WebClient.basicGet(\n form_data,\n url,\n success => {\n success.data.payment_method = new EliteAPI.Models.STR.PaymentMethod(success.data.payment_method);\n if (success_callback) success_callback(success);\n },\n failure_callback\n );\n }", "function createNewInvoice(){\n client_id = invoice.client.client_id;\n\n getInvoiceItems();\n\n function getClientDetails()\n {\n var callbackClient = function(response)\n {\n var str = '';\n //another chunk of data has been recieved, so append it to `str`\n response.on('data', function (chunk) {\n str += chunk;\n });\n\n //the whole response has been recieved, so we just print it out here\n response.on('end', function () {\n var data = JSON.parse(str)\n invoice.client = data.result;\n\n invoice.getTaxInvoice().then(function(result){\n\n if(result)\n {\n var invoiceData = invoice.toJSON();\n\n function callBackInvoice(error, response, body)\n {\n if(body.success)\n {\n if (!error) {\n var callbackSync = function(response)\n {\n var str = '';\n response.on('data', function (chunk) {\n str += chunk;\n });\n response.on('end', function () {\n //invoice.send();\n recordTrack({success:true,msg:\"success\",api:\"/invoice/sync-daily-rates?order_id=\"+body.order_id});\n console.log(\"Done creating invoice for client \"+invoice.client.client_id);\n done(null,{success:true});\n\n\n });\n };\n http.get(njsUrl + \"/invoice/sync-daily-rates?order_id=\" + body.order_id,callbackSync);\n }\n else {\n console.log('Error happened: '+ error);\n done(null,{success:true});\n }\n }\n else\n {\n recordTrack({success:false,msg:body.errors.errmsg,api:\"/invoice/sync-daily-rates?order_id=\"});\n console.log({success:false,msg:body.errors.errmsg});\n done(null,{success:true});\n }\n\n }\n var options = {\n method: 'POST',\n url: njsUrl + '/invoice/save/',\n headers: {\n 'Content-Type': 'application/json'\n },\n json: invoiceData\n };\n\n\n request(options,callBackInvoice);\n }\n else\n {\n done(null,{success:true});\n }\n });\n });\n\n };\n\n http.get(njsUrl + '/invoice/get-client-invoices/?id='+client_id, callbackClient);\n\n }\n\n function getInvoiceItems()\n {\n\n //get items for timesheet (-30 days group)\n var callback = function(response) {\n var str = '';\n\n //another chunk of data has been recieved, so append it to `str`\n response.on('data', function (chunk) {\n str += chunk;\n });\n\n //the whole response has been recieved, so we just print it out here\n response.on('end', function () {\n var data = JSON.parse(str)\n\n if(typeof data.result !== \"undefined\" && data.result.length > 0)\n {\n item_added.push(data.result);\n var result_item = data.result;\n var regularRosteredCount = 0;\n function getItems(i)\n {\n\n if(i < result_item.length)\n {\n var item = result_item[i];\n var invoice_items = {};\n\n if(item.item_type == \"Regular Rostered Hours\"){regularRosteredCount = regularRosteredCount + 1;}\n\n itemId = i+1;\n invoice_items.item_id = itemId;\n invoice_items.description = item.description;\n invoice_items.item_type = item.item_type;\n invoice_items.qty = item.qty;\n invoice_items.unit_price = parseFloat(item.staff_hourly_rate.toFixed(2));\n invoice_items.selected_date = {\n startDate : new Date(moment_tz(item.start_date).format(\"YYYY-MM-DD HH:mm:ss\")),\n endDate : new Date(moment_tz(item.end_date).format(\"YYYY-MM-DD HH:mm:ss\"))\n };\n invoice_items.selected = true;\n invoice_items.subcontractors_id = item.subcontractors_id;\n invoice_items.current_rate = parseInt(item.current_rate);\n invoice_items.staff_name = item.staff_name;\n invoice_items.start_date = new Date(moment_tz(item.start_date).format(\"YYYY-MM-DD HH:mm:ss\"));\n invoice_items.end_date = new Date(moment_tz(item.end_date).format(\"YYYY-MM-DD HH:mm:ss\"));\n invoice_items.job_designation = (typeof item.job_designation !== 'undefined' ? item.job_designation : \"\" );\n invoice.invoice_item.push(invoice_items);\n getItems(i+1);\n }\n else {\n\n if(regularRosteredCount > 0 )\n {\n http.get(njsUrl + '/timesheet/currency-adjustments?client_id='+client_id+'&month_year='+month_year2, callback2);\n\n }\n else\n {\n recordTrack({success:false,msg:\"No Regular Rostered items Found\",api:'/timesheet/invoice-items?client_id='+client_id+'&month_year='+month_year,client_id:client_id});\n console.log({success:false,msg:\"No Regular Rostered items Found\"});\n done(null,{success:true});\n }\n\n }\n }\n getItems(0);\n\n }\n else {\n recordTrack({success:false,msg:\"No data Found\",api:'/timesheet/invoice-items?client_id='+client_id+'&month_year='+month_year,client_id:client_id});\n console.log({success:false,msg:\"No data Found\"});\n done(null,{success:true});\n }\n\n });\n };\n\n\n\n var callback2 = function(response)\n {\n var str = '';\n\n //another chunk of data has been recieved, so append it to `str`\n response.on('data', function (chunk) {\n str += chunk;\n });\n\n //the whole response has been recieved, so we just print it out here\n response.on('end', function () {\n var data = JSON.parse(str)\n\n if(typeof data.result !== \"undefined\" && data.result.length > 0)\n {\n item_added.push(data.result);\n invoice.hasCurrencyAdj = true;\n var result_item = data.result;\n function getItems(i)\n {\n if(i < result_item.length)\n {\n var item = result_item[i];\n var invoice_items = {};\n itemId = itemId +1;\n invoice_items.item_id = itemId;\n invoice_items.description = item.description;\n invoice_items.item_type = item.item_type;\n invoice_items.qty = item.qty;\n invoice_items.unit_price = parseFloat(item.currency_adjustment.toFixed(2));\n invoice_items.selected_date = {\n startDate : new Date(moment_tz(item.start_date).format(\"YYYY-MM-DD HH:mm:ss\")),\n endDate : new Date(moment_tz(item.end_date).format(\"YYYY-MM-DD HH:mm:ss\"))\n };\n invoice_items.selected = true;\n invoice_items.subcontractors_id = item.subcontractors_id;\n invoice_items.current_rate = parseInt(item.current_rate);\n invoice_items.staff_name = item.staff_name;\n invoice_items.start_date = new Date(moment_tz(item.start_date).format(\"YYYY-MM-DD HH:mm:ss\"));\n invoice_items.end_date = new Date(moment_tz(item.end_date).format(\"YYYY-MM-DD HH:mm:ss\"));\n invoice_items.job_designation = (typeof item.job_designation !== 'undefined' ? item.job_designation : \"\" );\n invoice.invoice_item.push(invoice_items);\n getItems(i+1);\n }\n\n else {\n\n console.log(\"Done adding items\");\n\n getClientDetails();\n\n\n }\n }\n getItems(0);\n }\n else\n {\n\n getClientDetails();\n console.log({msg:\"No data Found2\"});\n // recordTrack({success:false,msg:\"No data Found\",api:'/timesheet/currency-adjustments?client_id='+client_id+'&month_year='+month_year2,client_id:client_id});\n // console.log({success:false,msg:\"No data Found2\"});\n // done(null,{success:true});\n }\n\n });\n\n };\n\n\n\n http.get(njsUrl + '/timesheet/invoice-items?client_id='+client_id+'&month_year='+month_year, callback);\n\n }\n\n\n\n //for tracking\n function recordTrack(msg)\n {\n var db = mongoose.createConnection(\"mongodb://\"+mongoCredentials.host+\":\"+mongoCredentials.port+\"/prod\",mongoCredentials.options);\n var InvoiceCreation = db.model(\"InvoiceCreationTrack\", invoiceCreationTrack);\n\n var fname = \"\",lname=\"\",email=\"\";\n\n if(typeof invoice.client.lead !== \"undefined\")\n {\n fname = (typeof invoice.client.lead.fname !== \"undefined\" ? invoice.client.lead.fname :\"\");\n lname = (typeof invoice.client.lead.lname !== \"undefined\" ? invoice.client.lead.lname :\"\");\n email = (typeof invoice.client.lead.email !== \"undefined\" ? invoice.client.lead.email :\"\");\n }\n\n var document = {\n client_id : (typeof invoice.client.client_id !== \"undefined\" ? invoice.client.client_id : msg.client_id),\n client_fname : fname,\n client_lname : lname,\n client_email : email,\n client_names : [fname.toLowerCase(), lname.toLowerCase()],\n order_id : (invoice.tax_invoice_no ? invoice.tax_invoice_no : \"\"),\n invoice_date : month_year,\n due_date : invoice.due_date,\n date_created : configs.getDateToday(),\n queue : \"pending\",\n status:{\n success:msg.success,\n msg:msg.msg,\n api:msg.api\n },\n currency: (typeof invoice.client.currency !== 'undefined' ? invoice.client.currency : \"\"),\n total_amount: (invoice.getTotal() ? parseFloat(invoice.getTotal()) : null)\n }\n\n var filter = {\n client_id:parseInt(document.client_id),\n date_created:{'$gte':new Date()}\n };\n\n db.once('open', function(){\n\n try {\n\n InvoiceCreation.findOneAndUpdate(filter,document,{upsert:true},function(err,doc){\n\n if (err){\n console.log(err);\n }\n db.close();\n console.log(\"Success adding track\");\n\n });\n }catch(e)\n {\n db.close();\n console.log(\"Error recording track\");\n }\n });\n }\n }", "function getmatche(link){\n request(link, cb);\n }", "function doGet(e) {\n // do whatever this webapp is for\n var result = doSomeStuff(e); \n // prepare the result\n var s = JSON.stringify(result);\n // publish result\n return ContentService\n .createTextOutput(result.params.callback ? result.params.callback + \"(\" + s + \")\" : s )\n .setMimeType(result.params.callback ? ContentService.MimeType.JAVASCRIPT : ContentService.MimeType.JSON); \n}", "function sendSelfEmail(survey_id,url) {\r\n\t$.get(app_path_webroot+'Surveys/email_self.php', { pid: pid, survey_id: survey_id, url: url }, function(data) {\r\n\t\tif (data != '0') {\r\n\t\t\tsimpleDialog('The survey link was successfully emailed to '+data,'Email sent!');\r\n\t\t} else {\r\n\t\t\talert(woops);\r\n\t\t}\r\n\t});\r\n}", "function sendGetToServer(config) {\n ajaxConfig.method = \"GET\";\n ajax.request(config)\n .then(data => {\n let responseObj = JSON.parse(data);\n view.updateQuestion(responseObj);\n if (responseObj.nextURL !== undefined) {\n ajaxConfig.url = responseObj.nextURL;\n }\n })\n .catch(error => {\n let errorMessage = \"Network error \" + error;\n endGame(\"failed\");\n webStorage.logError(errorMessage);\n });\n}", "function retrieve(){\n\tloading(true);\n\t$.post('retrieve.php', \n\t\t\t{id: $('#watchID').val()},\n\t\t\tfunction(response){\n\t\t\t\tif(response === 'false'){\n\t\t\t\t\talert('Wallet retrieval error\\nCheck your Identifier');\n\t\t\t\t\tloading(false);\n\t\t\t\t} else {\n\t\t\t\t\topenWallet(response)\n\t\t\t\t}\n\t\t\t}\n\t);\n}", "function searchSpotify() {\n inquirer.prompt([\n {\n type: \"input\",\n name: \"query\",\n message: \"Search Spotify:\"\n }\n ]).then(function(input) {\n var query = input.query;\n if (input.query == \"\") {\n query = \"The Sign Ace of Base\"\n }\n var spotify = new Spotify({\n id: spotifyKeys.id,\n secret: spotifyKeys.secret\n });\n spotify.search({ type: \"track\", query: query }, function (error, data) {\n if(error) {\n console.log(error)\n } else {\n var title = data.tracks.items[0].name;\n var artist = data.tracks.items[0].artists[0].name;\n var album = data.tracks.items[0].album.name;\n var previewLink = data.tracks.items[0].preview_url;\n if(!previewLink) {\n previewLink = \"No preview available :(\"\n }\n console.log(\"~Siri~ Here is some information about \" + title + \".\")\n console.log(\"...\");\n console.log(\"Title: \" + title);\n console.log(\"Artist: \" + artist);\n console.log(\"Album: \" + album);\n console.log(\"Preview: \" + previewLink); \n console.log(\"...\");\n logData(\"Searched Spotify for \" + title + \" by \" + artist);\n }\n })\n \n })\n}", "function urlHandler(data) {\r\n // Called from either setUrlHandler or using window.location on load, so normalise the path\r\n var path = data.path || data;\r\n\r\n\r\n var request_ids = getParameterByName(path, 'request_ids');\r\n var latest_request_id = request_ids.split(',')[0];\r\n\r\n if (latest_request_id) {\r\n // Probably a challenge request. Play against sender\r\n getRequestInfo(latest_request_id, function(request) {\r\n \tplayAgainstSomeone(request.from.id);\r\n \tdeleteRequest(latest_request_id);\r\n });\r\n}\r\n}", "function get_venue_details(venue,callback)\n{\n \n var config = {\n authUrl: 'https://foursquare.com/',\n apiUrl: 'https://api.foursquare.com/'\n };\n var item;\n var venue_id = venue['id'];\n //$.ajaxSettings.async = false;\n $.getJSON(config.apiUrl + 'v2/venues/'+venue_id+'?'+auth+'&v='+getDateString())\n .done(function(data) {\n item = data['response']['venue'];\n callback(item);\n })\n .fail(function(error)\n {\n callback(null);\n });\n \n}", "Call(req) {\n return this.api.Request(req, this.player.playerInfo)\n }", "function callTourGeneration(){\n\t\tdisableButtons();\n\t\tclearAll();\n\n\t\tvar parameters = Parameters.getAllParameters();\n\t\tvar callUri = Parameters.getUrlForTourGenerationRequest(serverUri, parameters);\n\t\t$.get(callUri, handleTourResult)\n\t\t.fail(function(xhr, status, error) {clearAll()\n\t\t\t$(\"#displayedMessage\").html('<span class=\"message_error\">Error when trying to call server.</span>');\n\t\t\tenableButtons();\n\t\t});\n\t}", "function requestData(){\n\tloadJSON(\"https://dweet.io/get/dweets/for/money-tracker\", gotData);\n}", "function requestscenario(jeedomscenario) {\n\n var myKeyValue, myIPValue, myHttps;\n\n myKeyValue = localStorage.getItem(\"KEY\");\n myIPValue = localStorage.getItem(\"IP\");\n myHttps = \"\";\n if (JSON.parse(localStorage.getItem(\"HTTPS\"))) {\n myHttps = \"s\";\n }\n\n\n var client = new XMLHttpRequest();\n client.open(\"GET\", \"http\" + myHttps + \"://\" + myIPValue + \"/core/api/jeeApi.php?apikey=\" + myKeyValue + \"&type=scenario&id=\" + jeedomscenario + \"&action=start\");\n console.log(\"http\" + myHttps + \"://\" + myIPValue + \"/core/api/jeeApi.php?apikey=\" + myKeyValue + \"&type=scenario&id=\" + jeedomscenario + \"&action=start\");\n client.onreadystatechange = function () {\n if (client.readyState == 4) {\n if (client.status == 200) {\n console.log(client.responseText);\n navigator.vibrate([500, 500, 500]);\n }\n }\n };\n client.send();\n}", "onSuccess() {}", "async function getOpenOrders() {\n await traderBot.api('OpenOrders')\n .then((res) => console.log(res))\n .catch((rej) => console.log(rej));\n}", "function song_next(){\nvar request = createXMLHttpRequest();\nurl=foobarctrlurl + \"?cmd=Stop&param1=0\";\nrequest.open(\"GET\", url, true);\nrequest.send(\"\");\n}", "function doGet(e) {\n// var html = HtmlService.createTemplateFromFile(\"view_request.html\");\n// html.id = e.parameter.id;\n// html.action = e.parameter.action;\n var id = e.parameter.id;\n var action = e.parameter.action;\n \n if (action === \"accept\") {accept(id); Logger.log(\"accepted id\" + id);}\n else if (action === \"reject\") {reject(id); Logger.log(\"rejected id\" + id);}\n}", "function load_info() {\n Waypoint.disableAll();\n\n var xhttp = new XMLHttpRequest();\n xhttp.onreadystatechange = function() {\n if (this.readyState == 4 && this.status == 200){\n console.log(this.responseText);\n\n if(this.responseText == \"[]\"){\n if(n_info_box > 0){\n $('#end').html(\"<i>That's all, folks!</i>\");\n Waypoint.destroyAll();\n } else{\n $('#end').html(\"<i>That last search had no results...<br/>Time to try again!</i>\");\n Waypoint.destroyAll();\n }\n }else{\n json_info = JSON.parse(this.responseText);\n json_info.forEach( async function(deal) { \n $('#main-body').append(load_info_box(deal));\n });\n }\n }\n };\n\n if(query == undefined){\n xhttp.open(\"GET\", \"http://127.0.0.1:5000/info?from=\"+n_info_box+\"&to=\"+(n_info_box+3), true);\n } else{\n xhttp.open(\"GET\", \"http://127.0.0.1:5000/info?from=\"+n_info_box+\"&to=\"+(n_info_box+3)+\"&query=\"+query, true);\n }\n xhttp.send();\n\n Waypoint.enableAll();\n}", "function doGet(e) {\n return postToSlack(makeResponse(e));\n}", "QueryFromNECAIServer(queryText, eventcall) {\n\n request\n .post(queryUrl)\n .set('contentType', 'application/json; charset=utf-8')\n .set('dataType', 'json')\n .send({\n parentID: this.state.botinfo.parentID,\n sessionID: this.state.botinfo.sessionID,\n query: queryText,\n e: eventcall,\n tokenId: tokenID,\n chatbotCollectionName: this.state.botinfo.chatbotCollectionName\n })\n .end((err, res) => {\n\n if(err) {\n console.log('NEC AI query error: ' + err);\n }\n else {\n\n let querysuccess = res.body.success;\n\n if(querysuccess) {\n\n let fulfillment = res.body.res.result.fulfillment;\n let AllMessages = [];\n\n if (fulfillment.messages) {\n\n for (let i = 0; i < fulfillment.messages.length; ++i) {\n\n let message = fulfillment.messages[i];\n\n switch (message.type) {\n case 0:\n\n // Text Response\n AllMessages.push({\n type: 0, \n text:message.speech\n });\n break;\n\n case 4:\n\n // Payload\n switch (message.payload.type) {\n\n case 0:\n\n // Quick Replies\n AllMessages.push({\n type: 1,\n title: message.payload.title,\n qrs: message.payload.quick_replies\n });\n\n break;\n\n case 1:\n\n // link\n AllMessages.push({\n type: 2,\n link: message.payload.link\n });\n\n break;\n\n case 2:\n\n // event\n AllMessages.push({\n type: 3,\n event: message.payload.e\n });\n\n break;\n\n case 3:\n\n // images\n AllMessages.push({\n type: 4,\n title: message.payload.title,\n imageURL: message.payload.imageUrl\n });\n\n break;\n\n case 4:\n\n // Quick Replies\n AllMessages.push({\n type: 5,\n title: message.payload.title,\n qrs: message.payload.quick_replies\n });\n\n console.log(message.payload.quick_replies);\n\n break;\n \n default:\n break;\n\n }\n\n break;\n \n default:\n break;\n }\n\n }\n\n }\n\n let newItem = {\n user: 'ai',\n id: Date.now(),\n AiMessages: AllMessages\n };\n\n // store the msg return from api ai pls\n this.StoreMsg(newItem);\n\n // check got any events\n for (let i = 0; i < AllMessages.length; ++i) {\n\n let message = AllMessages[i];\n\n if (message.type === 3) {\n // got any event to fire?\n // if got any event call?\n console.log('got event pls: ' + message.event);\n this.QueryFromNECAIServer('', message.event);\n }\n }\n\n }\n else {\n console.log('query not success');\n }\n\n }\n \n });\n\n }", "function geniusRef(artist, track) {\n\n const ajaxUrl = \"http://localhost:3000/api/tracks?track=\" + track + \"&artist=\" + artist;\n \n sendAjaxRequest(\"GET\", ajaxUrl, handleResponseGeniusRef);\n\n}", "function concertFunc() {\n axios.get(\"https://rest.bandsintown.com/artists/\" + searchReq + \"/events?app_id=codingbootcamp\").then(\n function (response) {\n console.log(response);\n\n });\n}", "fetch() {\n let editor\n // to check get the reference of active editor in atom\n if (editor = atom.workspace.getActiveTextEditor()) {\n // static url to call\n let selection = \"https://acadstaging.com/py/api/student/projects/objectives?projectStudentId=1522\";\n // call to download function to get the objectives from api\n this.download(selection).then( apiResponse => {\n console.log(\"api call successful\");\n // call the method to display the result\n this.showResult(apiResponse).then( viewResponse => {\n console.log(\"back to functionality\");\n });\n }).catch( error => {\n // if error in response display the error message on the modal\n atom.notifications.addWarning(error.reason);\n });\n // call the function to track user movement\n this.trackUser();\n /////////////////////////////////////////TESTING CODE//////////////////////////////////////////////////////////\n // on add new file and delete a file or change a file\n this.trackProject();\n }\n }", "function endRetrieval() {\n console.info(\"Fine recupero notizie.\");\n}", "function identification(agent){\n var body=JSON.stringify(request.body);\n console.log(body);\n var obj = JSON.parse(body);\n let fever=obj.queryResult.parameters.number2;\n let fracture=obj.queryResult.parameters.Fracture;\n let precon=obj.queryResult.parameters.Precondition;\n let headInj=obj.queryResult.parameters.Head_Injury; \n console.log(fracture);\n let insuranceNumber=obj.queryResult.parameters.Insurance_Number;\n console.log(insuranceNumber);\n\tlet data = '';\n let url = `https://hook.integromat.com/eyucscywke51f6tnpjmapr5h6t2lcd1q?InsuranceNumber=` + insuranceNumber;\n\treturn new Promise((resolve, reject) => { \n const request = https.get(url, (res) => {\n res.on('data', (d) => {\n data += d;\n \tconsole.log(JSON.stringify(data)); \n \t\tvar name=JSON.stringify(data);\n \tname = name.substr(13);\n \tname = name.replace(/[^a-zA-Z ]/g, \"\");\n \tif (name === ''){\n \tagent.add(`Looks like we have never met before. Please tell me your full name.`);\n }else{\n \t\tconsultationNeededPrompt(agent, name, fever, precon, headInj, fracture);\n }\n });\n res.on('end', resolve);\n });\n request.on('error', reject);\n });\n }", "function BOT_resolveRequest() {\r\n\tBOT_theLastAnswerShort = BOT_reqAnswerShort;\r\n\tBOT_theLastAnswerLong = BOT_reqAnswerLong;\r\n\t\r\n\tBOT_reqSuccess = true;\t\t// contains the result of request on model\r\n\tBOT_reqEmote = \"\";\t\t// contains the emote string\r\n\tBOT_reqAnswerShort = \"\";\t\t// contains the answer string -- mode short\r\n\tBOT_reqAnswerLong = \"\";\t\t// contains the answer string -- mode long\r\n\tBOT_reqFilled = false;\t// true when BOT_reqSuccess, BOT_reqEmote,BOT_reqAnswerShort/long filled\r\n\r\n\r\n\t// ASSUMPTIONS: BOT_theReqPerformative and BOT_theReqTopic exist\r\n\tswitch (BOT_theReqPerformative) { // there is always one (z)\r\n \t\tcase \"a\": BOT_onAsk(); break;\r\n \t\tcase \"b\": BOT_onBravo(); break;\r\n \t\tcase \"c\": BOT_onCriticize(); break;\r\n \t\tcase \"d\": BOT_onDislike(); break;\r\n \t\tcase \"e\": BOT_onEffect(); break;\r\n \t\tcase \"f\": BOT_onFeel(); break;\r\n \t\tcase \"g\": BOT_onGreet(); break;\r\n \t\tcase \"h\": BOT_onHow(); break;\r\n \t\tcase \"i\": BOT_onIntent(); break;\r\n \t\tcase \"j\": BOT_onJudge(); break;\r\n \t\tcase \"k\": BOT_onKnow(); break;\r\n \t\tcase \"l\": BOT_onLike(); break;\r\n \t\tcase \"m\": BOT_onMore(); break;\r\n \t\tcase \"n\": BOT_onNo(); break;\r\n \t\tcase \"o\": BOT_onObject(); break;\r\n \t\tcase \"p\": BOT_onPossible(); break;\r\n \t\tcase \"q\": BOT_onQuit(); break;\r\n \t\tcase \"r\": BOT_onReply(); break;\r\n \t\tcase \"s\": BOT_onSuggest(); break;\r\n \t\tcase \"t\": BOT_onTell(); break;\r\n \t\tcase \"u\": BOT_onUndo(); break;\r\n \t\tcase \"v\": BOT_onVerify(); break;\r\n \t\tcase \"w\": BOT_onWhy(); break;\r\n \t\tcase \"x\": BOT_onExecute(); break;\r\n \t\tcase \"y\": BOT_onYes(); break;\r\n \t\tcase \"z\": BOT_onZee(); break; // future extensions\r\n \t\tdefault : break;\r\n\t\t};\r\n\t\r\n\t// ------------------------------ EPILOG ----------------------------------- \r\n\t\r\n\t\r\n\tBOT_reqApplicationPostProcessing(); \r\n\t\r\n\tif(BOT_theReqPerformative != \"z\")\tBOT_theLastPerformative = BOT_theReqPerformative;\r\n\tif(BOT_theReqTopic) {\r\n\t\tBOT_theLastTopic = BOT_theReqTopic;\r\n\t\tBOT_theTopicId = BOT_theReqTopic // sets also the current topic id\r\n\t}\r\n\r\n\tif(BOT_theReqAttribute)\t\tBOT_theLastAttribute = BOT_theReqAttribute;\r\n\tif(BOT_theReqRelation)\t\tBOT_theLastRelation = BOT_theReqRelation;\r\n\tif(BOT_theReqValue)\t\t\tBOT_theLastValue = BOT_theReqValue;\r\n\tif(BOT_theReqStresser)\t\tBOT_theLastStresser = BOT_theReqStresser;\r\n\tif(BOT_theReqText)\t\t\tBOT_theLastText = BOT_theReqText; \r\n\r\n\tBOT_reqAnswerShort = BOT_fillMetaString(BOT_reqAnswerShort); \r\n\tBOT_reqAnswerLong = BOT_fillMetaString(BOT_reqAnswerLong); \r\n\t\r\n\tBOT_traceString += \"SUCCESS \" + BOT_reqSuccess + \"\\n\";\r\n\tBOT_traceString += \"EMOTE \" + BOT_reqEmote + \"\\n\";\r\n\tBOT_traceString += \"SHORT ANSWER \" + BOT_reqAnswerShort + \"\\n\";\r\n\tBOT_traceString += \"LONG ANSWER \" + BOT_reqAnswerLong + \"\\n\";\r\n}", "function fetchDetails(search){\n \n console.log('called ')\n var xhrRequest =new XMLHttpRequest();\n xhrRequest.onload = function(){\n var responseJSON = JSON.parse(xhrRequest.response);\n\n if(responseJSON.response === 'error'){\n\n alert('Sorry your super Hero lost in space');\n }\n\n addToContainer(responseJSON);\n\n \n }\n xhrRequest.open('GET',`https://superheroapi.com/api/936106680158599/search/${search}`);\n \n xhrRequest.send();\n}", "function getTranscription() {\n\n //API CALL: Download transcription by job ID.\n var apiDownloadURL = 'https://api.speechmatics.com/v1.0/user/' + global.arguments.userId + '/jobs/' + global.jobID + '/transcript?auth_token=' + global.arguments.authToken;\n\n request(apiDownloadURL, function (error, response, body) {\n\n if (error) {\n return console.log('\\nREQUEST ERROR:', error);\n }\n\n try {\n\n var json = JSON.parse(body);\n if (json['error']) {\n return console.log('\\nAPI ERROR', json['error']);\n }\n } catch (parseError) {\n return console.log('\\nPARSE ERROR', parseError);\n }\n\n global.end = new Date().getTime();\n\n var speed = (global.end - global.start) / 1000;\n\n var textResult = getWords(json[\"words\"]);\n\n //print the result of the testing\n results.print(speed, textResult, \"Speechmatics testing results\", global.arguments);\n\n global.server.close();\n\n });\n}", "function spotify(song) {\n\n//this song is a default if user did not request the song\nsong = \"The Sign by Ace of Base\"\nif (parameter ==\"\"){\n parameter = song;\n}\n\n//send request to spotify queryURL\nvar spotify = require ('spotify');\n\n//run the request to spotify with specific song the user entered\nspotify.search({ type: 'track', query: parameter }, function(err, data) {\n if ( err ) {\n //console.log('Error occurred: ' + err);\n return;\n }\n\n\n //loop through all the data requested\n //for (var i=0; i<11; i++) {\n\n //console.log(JSON.stringify(data, null, 2));\n //log all necessary information of the song user requested\n ////console.log(\"----------------------------------------------------------------\");\n ////console.log(\"Artist: \" + data.tracks.items[i].artists[0].name);\n ////console.log(\"Song Name: \" + data.tracks.items[i].name);\n ////console.log(\"Spotify Link: \" + data.tracks.items[i].external_urls.spotify);\n ////console.log(\"Album Name: \" + data.tracks.items[i].album.name);\n ////console.log(\"----------------------------------------------------------------\");\n // };\n });\n}", "requestQuality(e) {\n //Do AJAX HERE, cant be an object must be a string sent to store\n Actions.fetchData(\"AJAX\");\n }", "_request() {\n var options = url.parse(this._url);\n options.headers = {\n 'User-Agent': 'Benjamin Tambourine',\n 'If-None-Match': this._etag\n };\n https.get(options, this._onResponse.bind(this));\n }", "function spotifyCall() {\n\nvar spotifyQuestion = [\n {\n type: 'input',\n name: 'spotifyInput',\n message: \"Input the Spotify song you'd like information on.\"\n }\n]\n\nfunction displaySpotify() {\n\n inquirer.prompt(spotifyQuestion).then(function(answers) {\n\n var spotifyApi = new spotify( {\n clientId: spotifyKeys.client_id,\n clientSecret: spotifyKeys.client_secret,\n })\n\n // Retrieve an access token.\n spotifyApi.clientCredentialsGrant().then(function(data) {\n console.log('The access token expires in ' + data.body['expires_in']);\n console.log('The access token is ' + data.body['access_token']);\n //console.log(params)\n // Save the access token so that it's used in future calls\n spotifyApi.setAccessToken(data.body['access_token']);\n\n var spotifySong = answers.spotifyInput;\n params = spotifySong;\n console.log(params);\n\n spotifyApi.searchTracks(params).then(function(data) {\n console.log('Results for tracks titled ' + params,(JSON.stringify(data.body, null, 2)));\n }, function(err) {\n console.log(err);\n })\n\n\n }, function(err) {\n console.log(spotifyApi);\n console.log('Something went wrong when retrieving an access token', err);\n });\n })\n }\n\ndisplaySpotify()\n}", "async function RestaurantForwardOrderInfo(openid) {\n var tool = new tools;\n var query = tool.query;\n var sql = '', row = ''\n\n sql = 'select * from restaurant_subscribe_message where tag = ?'\n row = await query(sql, 'xdtz')\n\n if (row.length > 0) {\n let TEMPLATE_ID = row[0].template_id\n\n var options = {\n host: 'api.weixin.qq.com',\n path: '/cgi-bin/token?grant_type=client_credential&appid=' + appid + '&secret=' + secret,\n method: 'GET',\n headers: {\n 'Content-Type': 'application/json'\n }\n };\n\n async function Call() {\n var e = await HttpsGet(options)\n\n let access_token = JSON.parse(e).access_token\n console.info(access_token)\n\n let postData = JSON.stringify({\n \"touser\": openid,\n \"template_id\": TEMPLATE_ID,\n \"data\": {\n \"number1\": {\n \"value\": \"测试\"\n },\n \"date4\": {\n \"value\": formatTime(new Date())\n },\n }\n })\n\n options = {\n host: 'api.weixin.qq.com',\n path: '/cgi-bin/message/subscribe/send?access_token=' + access_token,\n method: 'POST',\n form: postData,\n headers: {\n // 'Content-Type': 'application/x-www-form-urlencoded',\n 'Content-Type': 'application/json',\n 'Content-Length': postData.length\n },\n // encoding: 'binary'\n }\n\n async function CallCODE() {\n e = await HttpsPost(options, postData)\n console.info(e)\n // fs.writeFile('./index.png', e, function (err) {\n // if (err) {\n // throw err;\n // }\n // })\n }\n\n await CallCODE()\n }\n\n await Call()\n }\n\n\n}", "connectedCallback(){\n // if(!this.ivoiceLineItemData)\n this.getINVL();\n }", "function callback_get(target)\n{\n var xmlhttp;\n if (window.XMLHttpRequest)\n {// code for IE7+, Firefox, Chrome, Opera, Safari\n xmlhttp=new XMLHttpRequest();\n }\n else\n {// code for IE6, IE5\n xmlhttp=new ActiveXObject(\"Microsoft.XMLHTTP\");\n }\n xmlhttp.open(\"GET\",target,false);\n xmlhttp.send();\n return xmlhttp.responseText;\n}", "function sendRequestCurrentTrack() {\n xhrTrack.open(\"GET\", currentTrackJsonUrl, true);\n xhrTrack.send();\n}", "function ajaxSendTaskTriviaStayRequest(difficulty, onload) {\n var xmlHttpRequest = createRequest(\"GET\", \"/API/SQL/Trivia/\" + difficulty + \"/stay\", onload);\n\n xmlHttpRequest.send();\n\n return xmlHttpRequest;\n}", "function sndReq() {\n \n var meetingRaumID = window.location.toString().split('=');\n var raumID = meetingRaumID[1].toString().split(\"#\");\n\n alert(\"Rsum ID in ajaxjson: \" + raumID);\n // alert(\"meetingraumid: \"+raumID[0]);\n resOb.open('get', '../php/jsonDeliverer.php?&raumID='+raumID[0], true);\n resOb.onreadystatechange = function () {\n handleResponse();\n }\n resOb.send(null);\n}" ]
[ "0.5838593", "0.5786786", "0.5786786", "0.5731679", "0.5724769", "0.568553", "0.5683198", "0.5660793", "0.5660567", "0.5562685", "0.5560424", "0.55602425", "0.55554515", "0.5554074", "0.5541787", "0.5529845", "0.5520172", "0.55177546", "0.5509169", "0.5426427", "0.5415939", "0.54137033", "0.5401707", "0.5401108", "0.5399493", "0.539504", "0.53910553", "0.53855085", "0.53716534", "0.53687984", "0.53687686", "0.53636783", "0.5358028", "0.5353472", "0.53489226", "0.5348533", "0.5342778", "0.5327818", "0.5324471", "0.5323502", "0.5312161", "0.53117764", "0.5311676", "0.52971506", "0.52951396", "0.5288833", "0.528314", "0.52810687", "0.5278866", "0.5277267", "0.5269367", "0.5267484", "0.5265882", "0.52645177", "0.52629715", "0.5255171", "0.5242626", "0.52417946", "0.5239953", "0.5238757", "0.52306175", "0.5228397", "0.5228295", "0.5225021", "0.52166617", "0.52135664", "0.5211255", "0.5209382", "0.52058804", "0.52039945", "0.5200314", "0.51983964", "0.519834", "0.5198063", "0.5197887", "0.519596", "0.51956457", "0.5193196", "0.51917535", "0.5189888", "0.5186699", "0.51850003", "0.5181644", "0.5179576", "0.51782495", "0.51745254", "0.51738447", "0.5171895", "0.51658624", "0.5158947", "0.51586807", "0.5155333", "0.5154224", "0.5153026", "0.51527023", "0.5151545", "0.5151537", "0.5147564", "0.51466346", "0.5146587", "0.514551" ]
0.0
-1
Parses response text from Investopedia
function parseResponse(responseText){ //var definition = ''; $(responseText).find('.content-box-term').children().each(function(i, element){ //This condition handles the definition text and needs to be improved if($(this).is('p')){ //$(this).dialog(); <-- This is the method for jQuery UI dialog box but doesn't work yet //definition.concat($(this).text()); <-- This is to avoid multiple alert boxes but doesn't work alert($(this).text()); } else if ($(this).is('div#NextUpBox')){ return false; } }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function processResponse(text){\r\n\r\n\t\t\tvar tSplit = text.split('<?xml version=\"1.0\" encoding=\"iso-8859-1\"?>')[1];\r\n\t\t\tvar profile = new XML(tSplit);\r\n\t\t\t/*var jsonTracklist = {\r\n\r\n\t\t\t 'title':'ZOMGBBQ!', \r\n\t\t\t 'tracklist':[]\r\n\r\n\t\t\t}\r\n\r\n\t\t\tvar i=0;\r\n\t\t\tfor each(var song in profile.playlist.song){\r\n\t\t\t\t\r\n\t\t\t\tjsonTracklist.tracklist[i] = {\r\n\t\t\t\t\t\r\n\t\t\t\t\t'track':{\r\n\r\n\t\t\t\t\t\t'location': song.@durl,\r\n\t\t\t\t\t\t'image':song.@imagename,\r\n\t\t\t\t\t\t'title': song.@title,\r\n\t\t\t\t\t\t'creator':'múm', \r\n\t\t\t\t\t\t'annotation':'',\r\n\t\t\t\t\t\t'info':'http://www.myspace.com/mumtheband' \r\n\r\n\t\t\t\t\t}\r\n\t\t\t \r\n\t\t\t };\r\n\t\t\t\ti++;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tjsonTracklist = jsonTracklist.toSource().toString().split('(')[1].split(')')[0];\r\n\t\t\t\t\tunsafeWindow.console.log(jsonTracklist);*/\r\n\t\t\t//var songs = profile.playlist.song;\r\n\t\t\t//unsafeWindow.console.log(songs);\r\n\t\t\tvar i=0;\r\n\t\t\tvar tracks = '';\r\n\t\t\tfor each(var song in profile.playlist.song){\r\n\r\n\t\t\t\ttracks += '<track>'+\r\n\t\t\t\t\t\t\t\t'<title>'+profile.name+'</title>'+\r\n\t\t\t\t\t\t\t\t'<creator>'+song.@title+'</creator>'+\r\n\t\t\t\t\t\t\t\t'<location>'+song.@durl+'</location>'+\r\n\t\t\t\t\t\t\t\t'<image>'+song.@imagename+'</image>'+\r\n\t\t\t\t\t\t\t\t'<info></info>'+\r\n\t\t\t\t\t\t\t\t'<identifier>'+i+'</identifier>'+\r\n\t\t\t\t\t\t\t'</track>';\r\n\t\t\t\ti++;\r\n\r\n\t\t\t}\r\n\t\t\r\n\t\tvar pathN = document.title.split('MySpace.com - ')[1];\r\n\t\tvar tList = '<?xml version=\"1.0\" encoding=\"UTF-8\"?><playlist version=\"1\" xmlns=\"http://xspf.org/ns/0/\">'+\r\n\t\t\t\t\t\t'<title>'+pathN+'</title>'+\r\n\t\t\t\t\t\t'<creator>'+pathN+'</creator>'+\r\n\t\t\t\t\t\t'<annotation></annotation>'+\r\n\t\t\t\t\t\t'<info></info>'+\r\n\t\t\t\t\t\t'<location></location>'+\r\n\t\t\t\t\t\t'<identifier></identifier>'+\r\n\t\t\t\t\t\t'<image></image>'+\r\n\t\t\t\t\t\t'<date></date>'+\r\n\t\t\t\t\t\t'<trackList>'+\r\n\t\t\t\t\t\t\ttracks+\r\n\t\t\t\t\t\t'</trackList>'+\r\n\t\t\t\t\t'</playlist>';\r\n\t\t\t\t\r\n\t\t\tvar newPlaya = document.createElement('embed');\r\n\t\t\tnewPlaya.src=\"http://forboden.com/coding/flashtest/myspacealt.swf\";\r\n\t\t\tnewPlaya.width=\"438\";\r\n\t\t\tnewPlaya.height=\"283\";\r\n\t\t\tnewPlaya.id=\"newPlaya\";\r\n\t\t\tnewPlaya.pluginspage=\"http://www.macromedia.com/go/getflashplayer\";\r\n\t\t\tnewPlaya.type=\"application/x-shockwave-flash\";\r\n\t\t\tnewPlaya.scale=\"noscale\";\r\n\t\t\tnewPlaya.wmode=\"opaque\";\r\n\t\t\tnewPlaya.setAttribute(\"allowscriptaccess\",\"always\");\r\n\t\t\tnewPlaya.setAttribute(\"allowfullscreen\",\"true\");\r\n\t\t\tnewPlaya.setAttribute(\"flashvars\",\"js_playlist=yes&playlist_url=\"+encodeURIComponent(tList)); \r\n\r\n\t\t\tvar origPlaya = document.getElementById('profile_mp3Player');\r\n\t\t\tvar origPlayaC = origPlaya.firstChild;\r\n\r\n\t\t\t/*var sS = document.styleSheets;\r\n\t\t\tvar newPlayaStyle = '';\r\n\t\t\tfor(var i=0;i<sS.length;i++){\r\n\r\n\t\t\t\tif(!sS[i].href){\r\n\t\t\t\t\tvar cR = sS[i].cssRules;\r\n\r\n\t\t\t\t\tfor(var j=0;j<cR.length;j++){\r\n\r\n\t\t\t\t\t\tvar o = cR[j].selectorText;\r\n\t\t\t\t\t\tvar nR = new RegExp('object$');\r\n\t\t\t\t\t\tif(nR.test(o)){\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\tnewPlayaStyle += cR[j].cssText.split('{')[1].split('}')[0];\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t}\r\n\r\n\t\t\t}*/\r\n\t\t\t\r\n\t\t\t//http://blog.firetree.net/2005/07/04/javascript-find-position/\r\n\t\t\t function findPosX(obj)\r\n\t\t\t {\r\n\t\t\t var curleft = 0;\r\n\t\t\t if(obj.offsetParent)\r\n\t\t\t while(1) \r\n\t\t\t {\r\n\t\t\t curleft += obj.offsetLeft;\r\n\t\t\t if(!obj.offsetParent)\r\n\t\t\t break;\r\n\t\t\t obj = obj.offsetParent;\r\n\t\t\t }\r\n\t\t\t else if(obj.x)\r\n\t\t\t curleft += obj.x;\r\n\t\t\t return curleft;\r\n\t\t\t }\r\n\r\n\t\t\t function findPosY(obj)\r\n\t\t\t {\r\n\t\t\t var curtop = 0;\r\n\t\t\t if(obj.offsetParent)\r\n\t\t\t while(1)\r\n\t\t\t {\r\n\t\t\t curtop += obj.offsetTop;\r\n\t\t\t if(!obj.offsetParent)\r\n\t\t\t break;\r\n\t\t\t obj = obj.offsetParent;\r\n\t\t\t }\r\n\t\t\t else if(obj.y)\r\n\t\t\t curtop += obj.y;\r\n\t\t\t return curtop;\r\n\t\t\t }\r\n\t\t\tvar newStyle = 'left:'+findPosX(origPlayaC)+'px;top:'+findPosY(origPlayaC)+'px;position:absolute;';\r\n\t\t\t\r\n\t\t\tnewPlaya.setAttribute('style',newStyle);\r\n\t\t\torigPlaya.removeChild(origPlayaC);\r\n\t\t\torigPlaya.appendChild(newPlaya);\r\n\r\n\t\t}", "function parseVkResponse (text) {\r\n const answer = text.split('<!>');\r\n let navVersion = intval(answer.shift());\r\n let newStatic = answer.shift();\r\n let langId = intval(answer.shift());\r\n let langVer = intval(answer.shift());\r\n let code = intval(answer.shift());\r\n for (let i = answer.length - 1 ; i >= 0 ; --i) {\r\n let ans = answer[i];\r\n if (ans.substr(0, 2) == '<!') {\r\n const from = ans.indexOf('>');\r\n const type = ans.substr(2, from - 2);\r\n ans = ans.substr(from + 1);\r\n switch (type) {\r\n case 'json' :\r\n answer[i] = JSON.parse(ans);\r\n break;\r\n case 'int' :\r\n answer[i] = intval(ans);\r\n break;\r\n case 'float':\r\n answer[i] = floatval(ans);\r\n break;\r\n case 'bool' :\r\n answer[i] = intval(ans) ? true : false;\r\n break;\r\n case 'null' :\r\n answer[i] = null;\r\n break;\r\n case 'pageview_candidate':\r\n answer.pop(); // <!pageview> must be last one or before <!debug>\r\n break;\r\n case 'debug':\r\n answer.pop(); // <!debug> must be last one\r\n break;\r\n }\r\n }\r\n }\r\n return answer;\r\n}", "_normalizeResponse(response_text) {\n if (typeof response_text !== 'string') {\n // If the query short-circuits, we receive an empty list instead of a string\n return response_text;\n }\n const data = JSON.parse(response_text);\n return data.data;\n }", "function parseResponse(resp) {\n hideStatus();\n return '';\n }", "function parse() {\n if(this.status >= 200 && this.status < 300){\n let parsedData = JSON.parse(this.responseText);\n renderText(parsedData.message);\n } else {\n console.error(\"Invalid status\" + this.status);\n }\n}", "function parseOMDBResponse(data) {\r\n\r\n logContent(\"Title: \" + data.Title);\r\n logContent(\"Year: \" + data.Year);\r\n\r\n // Loop, format and print the movie ratings\r\n var ratings = data.Ratings;\r\n ratings.forEach(rating => {\r\n switch (rating.Source) {\r\n case \"Internet Movie Database\":\r\n logContent(\"IMDB Rating: \" + rating.Value);\r\n break;\r\n case \"Rotten Tomatoes\":\r\n logContent(\"Rotton Tomatoes Rating: \" + rating.Value);\r\n break;\r\n }\r\n });\r\n\r\n logContent(\"Country Produced: \" + data.Country);\r\n logContent(\"Language: \" + data.Language);\r\n logContent(\"Plot: \" + data.Plot);\r\n\r\n // Loop, format and print the actors on their own lines\r\n var actors = data.Actors.split(\", \");\r\n logContent(\"Actors:\");\r\n logContent(\"=======\");\r\n actors.forEach(actor => {\r\n logContent(\" \" + actor);\r\n });\r\n logContent(\"------------------------------------\");\r\n}", "static readResponseAsText(response) {\n return response.text();\n }", "function parseResponse( response ) {\n\n\t// convert the string to an array of letters called chunky\n\tvar chunky = []; // array of objects\n\tfor(var letter = 0; letter < chunk.length; letter++ ) {\n\t\tchunky += chunk[ letter ];\n\t}\n\n\tvar chunky_copy = chunky;\n\tvar chunky_word = chunky;\n\t/*\n\tfor(var p = 0; p < chunky.length; p++) {\n\t\tvar pos = 0;\n\t\tvar wpos = p;\n\t\t// find tags of xml fields\n\t\tif( chunky[ p ] == '<' && chunky[ p + 1 ] != '/' )\n\t\t{\n\t\t\tvar start_tag = '';\n\t\t\tpos = wpos;\n\t\t\twhile( chunky_copy[ pos ] != '>' )\n\t\t\t{\n\t\t\t\tstart_tag += chunky_copy[ pos ];\n\t\t\t\tpos++;\n\t\t\t}\n\t\t\tstart_tag += '>';\n\t\t\tresponse[ 'start_tags' ].push( start_tag );\n\t\t} else if( chunky[ p ] == '>' )\n\t\t{\n\t\t \tvar word = '';\n\t\t \tpos = wpos;\n\t\t\tif ( chunky[ wpos+1 ] != '<' ) {\n\t\t\t \twhile( chunky_word[ pos ] != '<' )\n\t\t\t \t{\n\n\t\t\t \t\t//word += chunky_word[ wpos ];\n\t\t\t \t\tpos++;\n\t\t\t \t}\n\t\t\t} else {\n\t\t\t\tword += 'zzzz';\n\t\t\t}\n\t\t\tresponse[ 'words' ].push( word );\n\t\t}\n\t\t*/\n\n\t}", "function handleResponse(response) {\n // console.log(response.text());\n return response.text().then(text => {\n // console.log((JSON.parse(text).polls).find(x => x.creator == \"5c489f668665512ec004db37\"))\n const data = text && JSON.parse(text);\n if (!response.ok) {\n const error = (data && data.message) || response.statusText;\n console.log(error);\n return Promise.reject(error);\n }\n return data;\n });\n}", "function parseResult() {\n // myRec.resultString is the current result\n //text(myRec.resultString, 25, 25);\n console.log(myRec.resultString);\n parsedSpeech = myRec.resultString;\n speechFlag = true;\n//\t\tvar mostrecentword = myRec.resultString.split(' ').pop();\n}", "parse(str)\r\n {\r\n let jsonObj = str;\r\n //console.log(jsonObj);\r\n let intent = jsonObj.topScoringIntent.intent;\r\n\r\n switch(intent)\r\n {\r\n case \"greet_user\":\r\n this._chat.appendNewMessageRobot(this._answers.greet());\r\n break;\r\n case \"weather_town\":\r\n let cities = [];\r\n let dates = [];\r\n for(let i = 0; i < jsonObj.entities.length; i++)\r\n {\r\n if(jsonObj.entities[i].type === 'city')\r\n {\r\n cities.push(jsonObj.entities[i].entity);\r\n }\r\n if(jsonObj.entities[i].type === 'city_composite')\r\n {\r\n cities.push(jsonObj.entities[i].entity);\r\n }\r\n if(jsonObj.entities[i].type === 'builtin.datetimeV2.date' || jsonObj.entities[i].type === 'builtindatetimeV2.daterange' )\r\n {\r\n dates.push(jsonObj.entities[i].resolution);\r\n }\r\n }\r\n // console.log(dates);\r\n if (dates.length === 0)\r\n {\r\n this._requests.queryWeatherTownCurrent(cities);\r\n }\r\n else if (dates.length > 0)\r\n {\r\n this._requests.queryWeatherTown(cities, dates);\r\n }\r\n if (cities.length === 0)\r\n {\r\n this._chat.appendNewMessageRobot(this._answers.iNeedTown());\r\n }\r\n\r\n break;\r\n case \"current_weather_no_town\":\r\n this._chat.appendNewMessageRobot(this._answers.iNeedTown());\r\n break;\r\n case \"None\":\r\n this._chat.appendRawMessageRobot(\"I'm sorry but I could not understand your question ! Please rephrase :D\");\r\n }\r\n }", "async function AnalyzeApieceOfText() {\n let sentimentService = new sentiment.SentimentService(\n process.env.MICRO_API_TOKEN\n );\n let rsp = await sentimentService.analyze({\n text: \"this is amazing\",\n });\n console.log(rsp);\n}", "parse (text) {\r\n var result = {}\r\n var find = null\r\n\r\n try {\r\n // CUIT\r\n find = text.match(/(?:C\\.U\\.I\\.T\\. )(\\d{2}-\\d{8}-\\d)/)\r\n result.CUIT = find[1]\r\n\r\n // Periodo (Mes/Año)\r\n find = text.match(/(\\d{2}\\/\\d{4})(?:\\sServicios\\sEventuales)/)\r\n result.Periodo = find[1]\r\n\r\n // Revisión - Orig. (0) - Rect. (1/9)\r\n find = text.match(/(?:Orig\\.\\s\\(0\\)\\s-\\sRect\\.\\s\\(1\\/9\\):\\s)(\\d+)/)\r\n result.Revision = parseInt(find[1], 10)\r\n\r\n // Empleados en Nomina\r\n find = text.match(/(?:Empleados\\sen\\snómina:\\s)(\\d+)/)\r\n result.EmpleadosEnNomina = parseInt(find[1], 10)\r\n\r\n // Suma de REM\r\n find = text.match(/(?:Suma\\sde\\sRem\\.\\s)(\\d):\\s([\\d\\.]+,[\\d]{2})/g)\r\n result.SumaDeREM = find.map(function (s) {\r\n var f = s.match(/(?:Suma\\sde\\sRem\\.\\s)(\\d):\\s([\\d\\.]+,[\\d]{2})/)\r\n return {\r\n REM: parseInt(f[1], 10),\r\n value: parseFloatB(f[2])\r\n }\r\n })\r\n\r\n // Montos que se Ingresan\r\n find = text.match(/(\\d{3})\\s-\\s([A-Za-z\\s\\.]+)([\\d\\.]+,[\\d]{2})/g)\r\n result.MontosQueSeIngresan = find.map(function (s) {\r\n var f = s.match(/(\\d{3})\\s-\\s([A-Za-z\\s\\.]+)([\\d\\.]+,[\\d]{2})/)\r\n return {\r\n code: parseInt(f[1], 10),\r\n name: f[2].trim(),\r\n value: parseFloatB(f[3])\r\n }\r\n })\r\n\r\n } catch (e) {\r\n console.log('Error', e)\r\n return null\r\n }\r\n\r\n return result\r\n }", "function introResponse(recipientId, text) {\n text = text || \"\";\n\n var sobre = text.match(/sobre/gi);\n var platzi = text.match(/platzi/gi);\n var ayuda = text.match(/ayuda/gi);\n var testimonios = text.match(/testimonios/gi);\n\n if(sobre != null && platzi != null) {\n message = {\n text: \"Platzi es la mejor plataforma de habla hispana con Cursos profesionales de desarrollo web y de apps, marketing online, diseño de interfaces, servidores. Con clases en vivo y profesores sabios de la industria. Bienvenido :).\"\n }\n sendMessage(recipientId, message);\n return true;\n }\n if(ayuda != null) {\n message = {\n text: \"Platzi Bot Ver. 1.0 \"+ \"\\n\" +\" Comandos disponibles: \"+ \"\\n\" +\" 1)Buscar blog Javascript, etc.(Puedes buscar Android, Javascript, PHP, UX, Python, Ruby) \"+ \"\\n\" +\" 2)Sobre Platzi. \"+ \"\\n\" +\" 3)Testimonios. \"+ \"\\n\" +\" 4)Ayuda.\"\n }\n sendMessage(recipientId, message);\n return true;\n }\n \n return false;\n}", "function parseGenre () {\n console.log(\"parseGenre: \");\n const userkey = 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VybmFtZSI6ImNvb3BlckBtcG9pbnRpbmMuY29tIiwiaWQiOjM5Nywib3JnX2lkIjozMzEsIm9yZ19yb2xlIjoxfQ._M233oOb-MuhaXGAnLGow95r0Ap6YHZ2stt7Nxlxn9M';\n var domainString = window.location.href;\n console.log(\"parseGenre - domainString: \", domainString );\n\n var xhttp1 = new XMLHttpRequest()\n xhttp1.onreadystatechange = function(){\n if ( this.readyState == 4 && this.status == 200 ) {\n console.log(\"parseGenre response: \", this.responseText )\n return this.resonseText \n }\n }//end xttp call\n\n xhttp1.open(\"GET\", \"https://api.frase.io/api/v1/analysis_for_url?url=\"+domainString+\"&fields=genre\", true)\n xhttp1.setRequestHeader('key', userkey );\n xhttp1.send();\n\n}//end parseGenre", "async function get_nlpResp(val) {\n let got_nlpResp = await fetch(\"/response.json?sentence=\" +\n encodeURIComponent(val));\n let data = await got_nlpResp.json();\n return data[\"result\"];\n}", "function parseResponse(rs, m) {\n var r = rs.match(/^SIP\\/(\\d+\\.\\d+)\\s+(\\d+)\\s*(.*)\\s*$/);\n\n if(r) {\n m.version = r[1];\n m.status = +r[2];\n m.reason = r[3];\n\n return m;\n } \n}", "function parseResult() {\n // recognition system will often append words into phrases.\n // so hack here is to only use the last word:\n var mostrecentword = listener.resultString.split(' ').pop();\n var resultstring = listener.resultString;\n spoken_text = mostrecentword;\n\n // print(listener.resultJSON['timeStamp']);\n print(\"confidence: \" + listener.resultConfidence)\n print(resultstring);\n print(mostrecentword);\n }", "function urlResponse(obj, engineTitle) {\n // create placeholder for results\n var su = document.getElementById('results');\n var resultDiv = document.createElement('div');\n su.appendChild(resultDiv);\n // if there are no errors, parse the results\n if (obj.status == 200) {\n resultDiv.className = 'searchEngine';\n var stringDom = obj.content;\n var domdata=opensocial.xmlutil.parseXML(stringDom);\n if (domdata != null) {\n var entries = domdata.getElementsByTagName('entry');\n resultDiv.innerHTML = resultDiv.innerHTML + engineTitle + ':<br/>';\n if (entries.legnth == 0) {\n resultDiv.innerHTML = resultDiv.innerHTML + ('No results found');\n } else {\n var resultCount = entries.length;\n if (resultCount > 15) {\n resultCount = 15;\n }\n for (i = 0; i < resultCount; i++) {\n if (entries[i].getElementsByTagName('title').length > 0) {\n titles = entries[i].getElementsByTagName('title');\n title = titles[0].childNodes[0].nodeValue;\n } else {\n title = 'Untitled';\n }\n var link = null;\n //for standard atom results, we can extract the link\n if (entries[i].getElementsByTagName('link').length > 0) {\n links = entries[i].getElementsByTagName('link');\n link = links[0].attributes.href.nodeValue;\n }\n var summaryNode = entries[i].getElementsByTagName('summary')[0];\n if (summaryNode == null) {\n summaryNode = entries[i].getElementsByTagName('description')[0];\n }\n if (link == null) {\n resultDiv.innerHTML = resultDiv.innerHTML\n + '<p style=\\\"color:blue\\\"/>'\n + gadgets.util.escapeString(title);\n } else {\n resultDiv.innerHTML = resultDiv.innerHTML\n + '<p style=\\\"color:blue\\\"/>'\n + '<a href=\\\"'+ link + '\\\" target=\\\"_blank\\\">'\n + gadgets.util.escapeString(title)\n + '</a>';\n }\n if (summaryNode != null) {\n var summary = summaryNode.textContent;\n if (summary != null) {\n resultDiv.innerHTML = resultDiv.innerHTML\n + gadgets.util.escapeString(summary);\n }\n }\n }\n }\n }\n } else { // errors occured, notify the user.\n resultDiv.innerHTML = resultDiv.innerHTML + engineTitle\n + '<br/> An error has occured:' + obj.status;\n }\n }", "function parseResponse(rs, m) {\n var r = rs.match(/^SIP\\/(\\d+\\.\\d+)\\s+(\\d+)\\s*(.*)\\s*$/);\n if (r) {\n m.version = r[1];\n m.status = +r[2];\n m.reason = r[3];\n return m;\n }\n}", "function getSentiment(articleText, appendScoreHere) {\r\n $.post(\r\n 'https://apiv2.indico.io/apis/multiapi?apis=political,emotion',\r\n JSON.stringify({\r\n 'api_key': \"99883d108820881bbdf367b594a55cf0\",\r\n 'data': articleText,\r\n })\r\n ).then(function (res) {\r\n\r\n res = JSON.parse(res);\r\n console.log(res);\r\n console.log(res.results.emotion.results.anger);\r\n console.log(res.results.emotion.results.joy);\r\n console.log(res.results.emotion.results.sadness);\r\n console.log(res.results.emotion.results.fear);\r\n console.log(res.results.emotion.results.surprise);\r\n\r\n var anger = res.results.emotion.results.anger;\r\n var joy = res.results.emotion.results.joy;\r\n var sadness = res.results.emotion.results.sadness;\r\n var fear = res.results.emotion.results.fear;\r\n var surprise = res.results.emotion.results.surprise;\r\n\r\n // Sentimental analysis\r\n if ( anger > joy && anger > sadness && anger > fear && anger > surprise) {\r\n anger = (anger * 100);\r\n anger = (anger.toFixed(2) + \"%\");\r\n anger = \"Anger \" + anger; \r\n console.log(\"Anger is the greatest \" + anger);\r\n appendScoreHere.after($(\"<h6>\").html(\"Strongest Emotion: \" + anger.bold()));\r\n \r\n } else if (joy > anger && joy > sadness && joy > fear && joy > surprise) {\r\n joy = (joy * 100);\r\n joy = (joy.toFixed(2) + \"%\")\r\n joy = \"Joy \" + joy;\r\n console.log(\"Joy is the greatest \" + joy);\r\n appendScoreHere.after($(\"<h6>\").html(\"Strongest Emotion: \" + joy.bold()));\r\n } else if (sadness > anger && sadness > joy && sadness > fear && sadness > surprise) {\r\n sadness = (sadness * 100);\r\n sadness = (sadness.toFixed(2) + \"%\");\r\n sadness = \"Sadness \" + sadness;\r\n console.log(\"Sadness is the greatest \" + sadness);\r\n appendScoreHere.after($(\"<h6>\").html(\"Strongest Emotion: \" + sadness.bold()));\r\n } else if (fear > anger && fear > joy && fear > sadness && fear > surprise) {\r\n fear = (fear * 100);\r\n fear = (fear.toFixed(2) + \"%\");\r\n fear = \"Fear \" + fear;\r\n console.log(\"sadness is the greatest \" + fear);\r\n appendScoreHere.after($(\"<h6>\").html(\"Strongest Emotion: \" + fear.bold()));\r\n } else {\r\n surprise = (surprise * 100);\r\n surprise = (surprise.toFixed(2) + \"%\");\r\n surprise = \"Surprise \" + surprise;\r\n console.log(\"surpirse is the greatest: \" + surprise);\r\n appendScoreHere.after($(\"<h6>\").html(\"Strongest Emotion: \" + surprise.bold()));\r\n }\r\n\r\n var libertarian = res.results.political.results.Libertarian;\r\n var green = res.results.political.results.Green;\r\n var liberal = res.results.political.results.Liberal;\r\n var conservative = res.results.political.results.Conservative;\r\n \r\n // Political analysis \r\n if (libertarian > green && libertarian > liberal && libertarian > conservative) {\r\n libertarian = (libertarian * 100);\r\n libertarian = (libertarian.toFixed(2) + \"%\");\r\n libertarian = \"Libertarian \" + libertarian;\r\n console.log(\"libertarian is the greatest \" + libertarian);\r\n appendScoreHere.after($(\"<h6>\").html(\"Political Ideology: \" + libertarian.bold()));\r\n } else if (green > libertarian && green > liberal && green > conservative) {\r\n green = (green * 100);\r\n green = (green.toFixed(2) + \"%\");\r\n green = \"Green \" + green;\r\n \r\n console.log(\"Anger is the greatest \" + green);\r\n appendScoreHere.after($(\"<h6>\").html(\"Political Ideology: \" + green.bold()));\r\n } else if (liberal > libertarian && liberal > green && liberal > conservative) {\r\n liberal = (liberal * 100);\r\n liberal = (liberal.toFixed(2) + \"%\");\r\n liberal = \"Liberal \" + liberal;\r\n console.log(\"Liberal is the greatest \" + liberal);\r\n appendScoreHere.after($(\"<h6>\").html(\"Political Ideology: \" + liberal.bold()));\r\n } else {\r\n conservative = (conservative * 100);\r\n conservative = (conservative.toFixed(2) + \"%\");\r\n conservative = \"Conservative \" + conservative; \r\n console.log(\"conservative is the greatest: \" + conservative);\r\n appendScoreHere.after($(\"<h6>\").html(\"Political Ideology: \" + conservative.bold()));\r\n }\r\n\r\n\r\n console.log(res.results.political.results.Libertarian);\r\n console.log(res.results.political.results.Green);\r\n console.log(res.results.political.results.Liberal);\r\n console.log(res.results.political.results.Conservative);\r\n\r\n });\r\n }", "async function analyzeText(res) {\n\n // GRAB SUBJECT OF TEXT\n let subject = res.data.payload.headers;\n subject.forEach( (name) => {\n if(name['name'] == 'Subject') {\n subject = name['value'];\n }\n });\n\n // PUT CONTENT INTO READABLE TEXT\n let text = null; //used later\n if (res.data.payload.parts[0].body.data != null) {\n text = new Buffer.from(res.data.payload.parts[0].body.data, 'base64').toString();\n } else { //email has multimedia so its pushed to somewhere else\n text = new Buffer.from(res.data.payload.parts[0].parts[0].body.data, 'base64').toString();\n }\n\n //Only get emails with \"Position\" or \"Intern\" in the email\n let internREGEX = /intern|position/i;\n if(!internREGEX.test(text)) {\n //dont want to execute rest of the function :^)\n return ;\n }\n\n // INITIALIZE EMAILOBJECT TO STORE LATER\n let emailObject = {};\n let document = {\n content: text,\n type: 'PLAIN_TEXT'\n };\n\n // ANALYZE SENTIMENT OF EACH TEXT\n const [result] = await languageClient.analyzeSentiment({document:document});\n //console.log(result);\n const sentiment = result.documentSentiment;\n\n //regex to find Capital words\n // first way: look for positions\n // second way: look for number (before and after)\n let senderREGEX = /(?<=\\s)([A-Z])+[a-z]*(?=\\s)/gm;\n //possibleOrgs = nlp(possibleOrgs[0]).organizations().out('topk'); // organizations\n //console.log(\"POSSIBLE ORGS:\");\n //console.log(possibleOrgs);\n\n emailObject.subject = subject; //possible ORG\n emailObject.text = text;\n emailObject.sentiment = sentiment;\n\n //append to big array which parentObject contains\n arrayOfEmails.push(emailObject);\n\n // CLASSIFY TEXT INTO CATEGORIES\n let nextStageRegex = /Congratulation|challenge|problem|algorithm/;\n if(nextStageRegex.test(text)) {\n //probably a bad review\n emailObject.status = 'NEXT STAGE';\n } else {\n //probably a good review\n emailObject.status = 'DECLINED';\n }\n\n arrayOfLines = text.split('\\n');\n emailObject.position = arrayOfLines[arrayOfLines.length - 4];\n emailObject.company = arrayOfLines[arrayOfLines.length - 2];\n\n search = emailObject.company;\n let engineID = '005572698672398171083:ivrztdlnswq';\n let apiKEY = 'AIzaSyD3LznTS-2wAG8JP0AV_2g7HTO94ycY1pM';\n const Url = `https://www.googleapis.com/customsearch/v1?${apiKEY}&cx=${engineID}&q=${search}`;\n const request = await new Request(Url);\n console.log(request.uri.query);\n\n //WRITE TO FILE OUTPUT\n await new Promise((resolve, reject) => {\n fs.writeFile('emailOUTPUT.json', JSON.stringify(arrayOfEmails, null, 2), function (err) {\n if (err)\n reject(err);\n else\n resolve();\n });\n\n }); //REMOVE COMMENT LATER\n}", "function responseParser (response) {\n let data = [];\n response.data.results.forEach(character => {\n data.push({\n 'id': character.id,\n 'name': character.name,\n 'description': character.description,\n 'wiki': character.urls[0].url,\n 'comics': character.urls[1].url\n });\n });\n return data;\n}", "handleTextMessage() {\n /*console.log(\n \"Received text:\",\n `${this.webhookEvent.message.text} for ${this.user.psid}`\n );*/\n\n // check greeting is here and is confident\n let greeting = this.firstEntity(this.webhookEvent.message.nlp, \"greetings\");\n\n let message = this.webhookEvent.message.text.trim().toLowerCase();\n\n let response;\n\n if (\n (greeting && greeting.confidence > 0.8) ||\n message.includes(\"start over\")\n ) {\n response = Response.genNuxMessage(this.user);\n } else if (message.includes(\"#\")) {\n response = Survey.handlePayload(\"CSAT_SUGGESTION\");\n } else if(message.includes(i18n.__(\"ucl.timetable\").toLowerCase())){\n let ucl = new UCL(this.user, this.webhookEvent);\n response = ucl.handlePayload(\"UCL_TIMETABLE_NOW\");\n } else if(message.includes(\"now\")) {\n let ucl = new UCL(this.user, this.webhookEvent);\n response = ucl.handlePayload(\"UCL_TIMETABLE_NOW\");\n } else if(message.includes(\"monday\")) {\n let ucl = new UCL(this.user, this.webhookEvent);\n response = ucl.handlePayload(\"UCL_TIMETABLE_MONDAY\");\n } else if(message.includes(\"tuesday\")) {\n let ucl = new UCL(this.user, this.webhookEvent);\n response = ucl.handlePayload(\"UCL_TIMETABLE_TUESDAY\");\n } else if(message.includes(\"wednesday\")) {\n let ucl = new UCL(this.user, this.webhookEvent);\n response = ucl.handlePayload(\"UCL_TIMETABLE_WEDNESDAY\");\n } else if(message.includes(\"thursday\")) {\n let ucl = new UCL(this.user, this.webhookEvent);\n response = ucl.handlePayload(\"UCL_TIMETABLE_THURSDAY\");\n } else if(message.includes(\"friday\")) {\n let ucl = new UCL(this.user, this.webhookEvent);\n response = ucl.handlePayload(\"UCL_TIMETABLE_FRIDAY\");\n } else if(message.includes(\"saturday\")) {\n let ucl = new UCL(this.user, this.webhookEvent);\n response = ucl.handlePayload(\"UCL_TIMETABLE_SATURDAY\");\n } else if(message.includes(\"sunday\")) {\n let ucl = new UCL(this.user, this.webhookEvent);\n response = ucl.handlePayload(\"UCL_TIMETABLE_SUNDAY\");\n } else if (message.includes(\"email\")) {\n response = [Response.genText(\"No worries buddy! I've drafted the following email:\"), Response.genText(\"Dear Dr. Earl Barr. Unfortunately due to unavoidable circumstances I will not be able to attend your lecture. Please excuse me for that.\"), Response.genText(\"Sending from your email...\"), Response.genText(\"Sent!\")]\n } else {\n response = [\n Response.genText(\n i18n.__(\"fallback.any\", {\n message: this.webhookEvent.message.text\n })\n ),\n Response.genText(i18n.__(\"get_started.guidance\")),\n Response.genQuickReply(i18n.__(\"get_started.help\"), [\n {\n title: i18n.__(\"menu.suggestion\"),\n payload: \"TIMETABLE\"\n },\n {\n title: i18n.__(\"menu.help\"),\n payload: \"ROOM\"\n }\n ])\n ];\n }\n\n return response;\n }", "function parseSubBreed() {\n let parsedSub = JSON.parse(this.responseText);\n renderSubText(parsedSub.message);\n}", "function commandResponse() {\n if (command === \"spotify-this-song\")\n inquirer.prompt([{\n name: 'song',\n message: 'Type in the name of a song.'\n\n }]).\n\n then(function(answers) {\n spotify.search({\n type: 'track',\n query: answers.song,\n limit: 1\n }, function(err, data, answer) {\n if (err) {\n return console.log('Error occurred: ' + err);\n }\n var artist = data.tracks.items[0].album.artists[0].name;\n var song = data.tracks.items[0].name;\n var preview = data.tracks.items[0].album.artists[0].href;\n var album = data.tracks.items[0].album.name;\n\n console.log(\" \")\n console.log(\"Artist: \" + artist)\n console.log(\"Album: \" + album);\n console.log(\"Preview: \" + preview);\n console.log(\"Song: \" + song)\n console.log(\" \")\n\n });\n });\n if (command === \"my-tweets\") {\n\n var params = {\n screen_name: 'khayes1993'\n };\n client.get('statuses/user_timeline', params, function(error, tweets, response) {\n if (!error) {\n console.log(tweets);\n }\n });\n\n }\n\n //twitter command works but was unable to narrow it down to just the text property when console.logging tweets object\n}", "function parseResponse(rO){\n\t\t//FIRST TRY IT AS XML\n\t\tif(rO.getResponseHeader(\"Content-Type\").split(';')[0] == 'text/xml'){\t\n\t\t\treturn rO.responseXML;\n\t\t}\t\n\t\t\n\t\tvar str = rO.responseText;\n\t\t// [email protected], 2006-02-16, weird error: some IEs show the responseText followed by the complete response (header and body again) \n\t\tvar i = str.indexOf(\"HTTP/1\");\n\t\tif (i > -1) {\n\t\t\tstr = str.substring(i, str.length);\n\t\t\ti = str.indexOf(String.fromCharCode(13, 10, 13, 10));\n\t\t\tif (i > -1) {\n\t\t\t\tstr = str.substring(i + 2, str.length);\n\t\t\t}\n\t\t}\t\t\n\t\t\n\t\t//NEXT TRY IT AS WDDX\n\t\tif(str.indexOf(\"<wddxPacket\") > -1){\n\t\t\treturn parseWDDX(str);\t\n\t\t}\n\t\t\n\t\t\n\t\t//DO THE STRING EVAL\n\t\ttry{//next try JSON eval();\n\t\t\treturn parseJSON(str);\n\t\t}catch(e){//then try Classic eval();\n\t\t\treturn parseJS(str);\n\t\t}\n\t}", "function parseTypografAnswer(text) {\r\n var re = /<ProcessTextResult>\\s*((.|\\n)*?)\\s*<\\/ProcessTextResult>/m;\r\n var response = re.exec(text);\r\n response = RegExp.$1;\r\n response = response.replace(/&gt;/g, '>');\r\n response = response.replace(/&lt;/g, '<');\r\n response = response.replace(/&amp;/g, '&');\r\n\r\n if (textarea) { // To be sure that user was not faster than script\r\n textarea.value = response;\r\n if (shouldSubmit) {\r\n submitForm(textarea);\r\n }\r\n }\r\n textarea = null;\r\n}", "function parseResult(response)\n{\n\tvar res = response.match(/\\<response\\>((.|\\s)+?)\\<\\/response\\>/gm);\n\tvar fields = new Array();\n\tif (res != null)\n\t{\n\t\tcontents = RegExp.$1;\n\t\tres = contents.match(/\\<.+?\\>((.|\\s)+?)\\<\\/.+?\\>/gm);\n\t\tif (res == null)\n\t\t{\n\t\t\treturn fields;\n\t\t}\n\t\t\n\t\tfor (var i = 0; i < res.length; i++)\n\t\t{\n\t\t\tvar field = new Array();\n\t\t\tres[i].match(/^\\<(.+?)\\>/g);\n\t\t\tfield.push(RegExp.$1);\n\t\t\tres[i].match(/\\<.+?\\>((.|\\s)+)\\<\\/.+?\\>/gm);\n\t\t\tfield.push(unhtmlspecialchars(RegExp.$1));\n\t\t\t\n\t\t\tfields.push(field)\n\t\t}\n\t}\n\t\n\treturn fields;\n}", "function getSearchResponse(text) {\n // First, get bing :( response\n let res = rp(`https://www.bing.com/search?q=${text}`).then((body) => {\n var soup = new JSSoup(body);\n // Get the regular responses\n var resultsHTML = soup.findAll('li', 'b_algo');\n const DESC_SIZE = 100;\n let results = resultsHTML.slice(0, 4).map(e => {\n let titleHtml = e.find(\"h2\");\n if (titleHtml) {\n let urlHtml = titleHtml.find(\"a\");\n let descHtml = e.find(\"p\") ? e.find(\"p\") : e.find(\"span\");\n if (urlHtml && descHtml) {\n return {\n title: titleHtml.text,\n url: urlHtml.attrs[\"href\"],\n desc: descHtml.text.substring(0, DESC_SIZE - 3) + \"...\"\n }\n } else {\n return null\n }\n }\n }).filter(e => e != null);\n // Get the card, if there is one\n let x = soup.find(\"div\", \"b_entityTP\");\n if (x) {\n // Ensure the card has the right things in it\n let descHtml = x.find(\"div\", \"b_snippet\")\n let urlHtml = x.find(\"div\", \"infoCardIcons\") ? x.find(\"div\", \"infoCardIcons\").find(\"a\") : null;\n let titleHtml = x.find(\"div\", \"b_clearfix\") || x.find(\"h2\"); \n const CARD_DESC_SIZE = 300;\n if (descHtml && urlHtml && titleHtml) {\n results = results.concat({\n type: \"card\",\n desc: descHtml.text.substring(0, CARD_DESC_SIZE - 3) + \"...\",\n url: urlHtml.attrs[\"href\"],\n title: titleHtml.text\n });\n }\n }\n return results;\n });\n return res;\n}", "function leetSpeakVal(msg){\n //get input\n var input = msg.match[1];\n //create call to pass into request.\n var options = {\n url: \"https://montanaflynn-l33t-sp34k.p.mashape.com/encode?text=\"+input,\n headers: {\n \"X-Mashape-Key\": \"pn0XgML39Pmshmju3yspkVYxWrVdp1Sd4wHjsn7zYGIwfyILBD\",\n \"Accept\": \"text/plain\"\n }\n };\n //check if only nubers ( numbers don't leet speak well.)\n if(!isNaN(input)){\n msg.send('Please enter some words!');\n }else{\n //request using the options above to convert leet speak.\n request(options, function (error, response, body) {\n // Conditional to make sure the connection went successfully through.\n if (!error && response.statusCode < 300){\n // get body\n var text = body;\n msg.send(text);\n }else{\n msg.send(\"Sorry, an error has occurred.\");\n };\n });\n }\n \n}", "function ProcessProxyVttResponse(obj) {\n if (obj.status == \"error\")\n alert(\"Error loading caption file: \" + obj.message);\n else if (obj.status == \"success\") {\n // delete any captions we've got\n captionsArray.length = 0;\n\n if (obj.response.indexOf(\"<tt\") != -1) {\n ParseAndLoadTTML(obj.response);\n } else if (obj.response.indexOf(\"WEBVTT\") == 0) {\n ParseAndLoadWebVTT(obj.response);\n } else {\n alert(\"Unrecognised caption file format.\");\n }\n }\n}", "handleGoogleResponse(result) {\n let text = result.queryResult.fulfillmentMessages[0].text.text[0];\n this.sendBotResponse(text);\n }", "handleGoogleResponse(result) {\n let text = result.queryResult.fulfillmentMessages[0].text.text[0];\n this.sendBotResponse(text);\n }", "function parseMetadata(data, text_status, req_url) {\n var result = {meta:\n {req_id:$(\"RequestId\", data).text(),\n box_usage:parseFloat($(\"BoxUsage\", data).text()),\n status:text_status,\n req_url:req_url\n }\n };\n return result;\n }", "function handleResponse(xml) {\n\t\tconsole.log(\"in hr\");\n\t\t\n\t\t\t$(\"#movie2\").append(\"<p class='imgformat'>\" +\n\t\t\t\t\t\t\t\t\t\t\t \"<img src='_images/\" +\n\t\t\t\t\t\t\t\t\t\t\t $(xml).find(\"moviePoster:nth(1)\").text() +\n\t\t\t\t\t\t\t\t\t\t\t \"' width='100'>\" + \n\t\t\t\t\t\t\t\t\t\t\t\"</p>\"\n\t\t\t\t\t\t\t\t\t\t\t);\t\t\n\t\t\t\n\t\t\t$(\"h2\").css(\"text-align\", \"center\").css(\"font-weight\", \"bold\");\n\t\t\t\n\t\t\t$(\"h2\").append(\"MovieName: \" + $(xml).find(\"movie:nth(1)\").attr(\"movieName\") +\t// +1\n\t\t\t\t\t\t\t\t\t\t\t\t\"<br><br>\"); \n\t\t\t$(xml).find(\"movie:nth(1)\").each(function() {\n\t\t\t\t$(\"h2\").append(\"Movie Director: <span style='text-decoration:underline;'>\" +\n\t\t\t\t\t\t\t\t\t\t\t\t\t$(xml).find(\"movieDirector:nth(1)\").text() + \n\t\t\t\t\t\t\t\t\t\t\t\t\t\"</span><br><br>\");\n\t\t\t\t$(\"h2\").append(\"Movie Type:\" + $(xml).find(\"movieType:nth(1)\").text() + \n\t\t\t\t\t\t\t\t\t\t\t\t\t\"<br><br>\");\t\n\t\t\t\t\n\t\t\t});\t\t\t\t\t\t\n\t}", "function parseResp(res) {\n const parsedResp = {\n action: res.readUInt32BE(0),\n transactionId: res.readUInt32BE(4),\n connId: res.slice(8)\n };\n return (parsedResp);\n}", "function parseResponse(event)\n{\n // find body\n var newBody = ''\n if ('body' in event )\n {\n\tnewBody = event.body\n }\n else if ('payload' in event && 'body' in event.payload )\n {\n\tnewBody = event.payload.body\n }\n\n // if there's anything to do...\n if ( newBody.length > 0)\n {\n newBody = newBody.replace(/\\n/g, \"\\\\n\").replace(/\\r/g, \"\\\\r\").replace(/\\t/g, \"\\\\t\").replace(/\\f/g, \"\\\\f\")\n newBody = newBody.replace(/\\\\(^\\\\)+/g, '$1')\n newBody = newBody.replace(/\\\\(\\\\)+/g, '$1')\n \n //this.log(cleaned_body);\n return JSON.parse(newBody);\n \n } else {\n \n return null;\n \n } \n}", "function handleAnswerNoScreen(res, app) {\n\n if (res.length == 0) {\n app.ask(addSpeak(\"<p><s>No offers matching your request.</s> <s>Do you want to ask something else ?</s>\"));\n } else if (res.length == 1) {\n app.ask(app.buildRichResponse()\n .addSimpleResponse(\"There is one offer matching your request. \\n\")\n .addSimpleResponse(tellOneOffer(app, res[0], true))\n )\n } else if (res.length > 1 && res.length <= 10) {\n app.ask(app.buildRichResponse()\n .addSimpleResponse(\"There several offers matching your request. \\n\")\n .addSimpleResponse(addSpeak('After every offer you can say next, select or quit'))\n .addSimpleResponse(tellOneOffer(app, res[0]))\n )\n }\n}", "static parse(instruction) {\n // Strip punctutation.\n var punctuationless = instruction.replace(/[',\\/#!$%\\^&\\*;:{}=\\-_`~()]/g,\"\");\n var instruction = punctuationless.replace(/\\s{2,}/g,\" \");\n\n // Send request to ScratchNLP via websockets.\n var getTranslation = () => {\n return wsp.sendRequest({\n 'type': 'translation',\n 'instruction': instruction\n }).then((result) => {\n console.log('RESULT OF SEND REQUEST IN SCRATCH INSTRUCTION');\n console.log(result.response);\n if (result.response == \"I don't understand.\") {\n return false\n } else {\n return result.response\n }\n })\n }\n\n // Send request to ScratchNLP via websockets.\n if (wsp.isClosed) {\n return wsp.open().then(getTranslation)\n }\n return getTranslation();\n }", "function fetchText() {\n // TODO\n fetch('examples/words.txt')\n\t.then(validateResponse)\n\t.then(readResponseAsText)\n\t.then(showText)\n\t.catch(logError);\n}", "function extractResponse() {\n // parse user login name, add it to the html\n setLoginName(validUserNameJason.login);\n // create html for repositories, pass repos url api and number of repositories\n setRepositories(validUserNameJason.repos_url, validUserNameJason.public_repos);\n // create html for followers repositories, pass followers url api and number of followers\n setFollowers(validUserNameJason.followers_url, validUserNameJason.followers);\n // show the user info html the was generated from the response\n let userSection = document.getElementById(\"userInfo\");\n showElement(userSection);\n }", "function watsonAnalyze( senderID, messageText ){\n conversation.message({\n input: {\n text: messageText\n },\n workspace_id: config.WATSON_WORKSPACE\n }, function(err, response) {\n if (err) {\n console.error(JSON.stringify(err));\n sendTextMessage( senderID, 'Sorry, didnt get that, please try again.')\n } else {\n console.log('Intents and Confidence raitings for: '+messageText);\n console.log(response.intents)\n if(response.intents[0].intent == 'greeting'){\n sendTextMessage( senderID, DEFAULT_GREETING)\n }else if( response.intents[0].intent == 'profanity' && response.intents[0].confidence > .8 ){\n insultgenerator(function(insult){\n sendTextMessage( senderID, insult );\n });\n }else if( response.intents[0].intent == 'confirmation' && response.intents[0].confidence > .75 ){\n sendTextMessage( senderID, config.CONFIRMATION[Math.floor(Math.random() * config.CONFIRMATION.length) ]+'.');\n }else{\n// sendTextMessage( senderID, DEFAULT_GREETING)\n sendTextMessage( senderID, config.CONFIRMATION[Math.floor(Math.random() * config.CONFIRMATION.length) ]+'.');\n\n }\n }\n });\n}", "handleTextMessage(lastevent) {\n console.log(\"---------Llamando a handleTextMessage----------\");\n console.log(\"Payload handleTextMessage\");\n console.log(\n \"Received text:\",\n `${this.webhookEvent.message.text} for ${this.user.psid}`\n );\n\n // check greeting is here and is confident\n console.log(\"Es un message nlp\");\n console.log(this.webhookEvent.message.nlp);\n console.log(\"Entidades\");\n console.log(this.webhookEvent.message.nlp.entities);\n\n let greeting = this.firstEntity(this.webhookEvent.message.nlp, \"greetings\");\n console.log(\"Greeting\");\n console.log(greeting);\n let message = this.webhookEvent.message.text.trim().toLowerCase();\n console.log(\"message\");\n console.log(message);\n let response;\n if (\n (greeting && greeting.confidence > 0.8) ||\n message.includes(\"start over\")\n ) {\n response = Response.genNuxMessage(this.user);\n } else {\n if (lastevent === \"getstarted\") {\n response = [Response.genText(i18n.__(\"fallback.wrong\"))];\n } else if (lastevent === \"select_input\") {\n response = [\n Response.genQuickReply(i18n.__(\"fallback.wrong\"), [\n {\n title: i18n.__(\"menu.complaints_1\"),\n payload: \"complaints_1\"\n },\n {\n title: i18n.__(\"menu.complaints_2\"),\n payload: \"complaints_2\"\n },\n {\n title: i18n.__(\"menu.complaints_3\"),\n payload: \"complaints_3\"\n },\n {\n title: i18n.__(\"menu.complaints_4\"),\n payload: \"complaints_4\"\n }\n ])\n ];\n } else if (lastevent === \"confirm_input\") {\n if (this.user.complaintType === \"complaints_1\") {\n response = [\n Response.genQuickReply(i18n.__(\"fallback.wrong\"), [\n {\n title: i18n.__(\"menu.yes\"),\n payload: \"yes_1\"\n },\n {\n title: i18n.__(\"menu.no\"),\n payload: \"no\"\n }\n ]),\n { complaintType: \"complaints_1\" }\n ];\n }\n if (this.user.complaintType === \"complaints_2\") {\n response = [\n Response.genQuickReply(i18n.__(\"fallback.wrong\"), [\n {\n title: i18n.__(\"menu.yes\"),\n payload: \"yes_2\"\n },\n {\n title: i18n.__(\"menu.no\"),\n payload: \"no\"\n }\n ]),\n { complaintType: \"complaints_2\" }\n ];\n }\n if (this.user.complaintType === \"complaints_3\") {\n response = [\n Response.genQuickReply(i18n.__(\"fallback.wrong\"), [\n {\n title: i18n.__(\"menu.yes\"),\n payload: \"yes_3\"\n },\n {\n title: i18n.__(\"menu.no\"),\n payload: \"no\"\n }\n ]),\n { complaintType: \"complaints_3\" }\n ];\n }\n if (this.user.complaintType === \"complaints_4\") {\n response = [\n Response.genQuickReply(i18n.__(\"fallback.wrong\"), [\n {\n title: i18n.__(\"menu.yes\"),\n payload: \"yes_4\"\n },\n {\n title: i18n.__(\"menu.no\"),\n payload: \"no\"\n }\n ]),\n { complaintType: \"complaints_4\" }\n ];\n }\n } else if (lastevent === \"nombre\") {\n let responseData = Response.genText(\n i18n.__(\"fallback.dni\", {\n message: this.webhookEvent.message.text\n })\n );\n let payloadData = {\n payload: this.webhookEvent.message.text,\n user: this.user.psid\n };\n response = [responseData, payloadData];\n } else if (lastevent === \"dni\") {\n let first = Response.genText(i18n.__(\"fallback.birthday\"));\n let payloadData = {\n payload: this.webhookEvent.message.text,\n user: this.user.psid\n };\n response = [first, payloadData];\n } else if (lastevent === \"birthday\") {\n let first = Response.genText(i18n.__(\"fallback.cel\"));\n let payloadData = {\n payload: this.webhookEvent.message.text,\n user: this.user.psid\n };\n response = [first, payloadData];\n } else if (lastevent === \"cel\") {\n let celMessage = this.firstEntity(\n this.webhookEvent.message.nlp,\n \"phone_number\"\n );\n if (celMessage && celMessage.confidence > 0.8) {\n let first = Response.genText(i18n.__(\"fallback.email\"));\n let payloadData = {\n payload: this.webhookEvent.message.text,\n user: this.user.psid\n };\n response = [first, payloadData];\n } else {\n response = [Response.genText(i18n.__(\"fallback.wrong\"))];\n }\n } else if (lastevent === \"email\") {\n let emailMessage = this.firstEntity(\n this.webhookEvent.message.nlp,\n \"email\"\n );\n if (emailMessage && emailMessage.confidence > 0.8) {\n let first = Response.genText(i18n.__(\"fallback.address\"));\n let payloadData = {\n payload: this.webhookEvent.message.text,\n user: this.user.psid\n };\n response = [first, payloadData];\n } else {\n response = [Response.genText(i18n.__(\"fallback.wrong\"))];\n }\n } else if (lastevent === \"address\") {\n let first = Response.genText(i18n.__(\"fallback.photoquestion\"));\n let payloadData = {\n payload: this.webhookEvent.message.text,\n user: this.user.psid\n };\n response = [first, payloadData];\n } else if (lastevent === \"preparationquestion\") {\n response = [\n Response.genQuickReply(i18n.__(\"fallback.wrong\"), [\n {\n title: i18n.__(\"menu.yes\"),\n payload: \"yes_confirmation\"\n },\n {\n title: i18n.__(\"menu.no\"),\n payload: \"deny_confirmation\"\n }\n ])\n ];\n console.log(\"Receive.js 135 help\");\n console.log(\"---------Llamando a handleAttachmentMessage----------\");\n console.log(\"Payload handleAttachmentMessage\");\n console.log(response);\n } else if (lastevent === \"when\") {\n let first = Response.genText(i18n.__(\"fallback.scenefact\"));\n let payloadData = {\n payload: this.webhookEvent.message.text,\n user: this.user.psid\n };\n response = [first, payloadData];\n } else if (lastevent === \"where\") {\n let first = Response.genText(i18n.__(\"fallback.specificfact\"));\n let second;\n if (this.user.typeOfReport === \"yes_1\") {\n second = Response.genText(i18n.__(\"fallback.details1\"));\n } else if (this.user.typeOfReport === \"yes_2\") {\n second = Response.genText(i18n.__(\"fallback.details2\"));\n } else if (this.user.typeOfReport === \"yes_3\") {\n second = Response.genText(i18n.__(\"fallback.details3\"));\n } else if (this.user.typeOfReport === \"yes_4\") {\n second = Response.genText(i18n.__(\"fallback.details4\"));\n }\n let payloadData = {\n payload: this.webhookEvent.message.text,\n user: this.user.psid\n };\n response = [first, second, payloadData];\n }\n //how\n else if (lastevent === \"recomendation1\") {\n let first = Response.genText(i18n.__(\"fallback.recomendation1\"));\n\n let second = Response.genQuickReply(i18n.__(\"fallback.evidence\"), [\n {\n title: i18n.__(\"menu.yes\"),\n payload: \"accept_evidence\"\n },\n {\n title: i18n.__(\"menu.no\"),\n payload: \"decline_evidence\"\n }\n ]);\n let payloadData = {\n payload: this.webhookEvent.message.text,\n user: this.user.psid\n };\n response = [first, second, payloadData];\n } else if (lastevent === \"recomendation2\") {\n let first = Response.genText(i18n.__(\"fallback.recomendation2\"));\n\n let second = Response.genQuickReply(i18n.__(\"fallback.evidence\"), [\n {\n title: i18n.__(\"menu.yes\"),\n payload: \"accept_evidence\"\n },\n {\n title: i18n.__(\"menu.no\"),\n payload: \"decline_evidence\"\n }\n ]);\n let payloadData = {\n payload: this.webhookEvent.message.text,\n user: this.user.psid\n };\n response = [first, second, payloadData];\n } else if (lastevent === \"recomendation3\") {\n let first = Response.genText(i18n.__(\"fallback.recomendation3\"));\n\n let second = Response.genQuickReply(i18n.__(\"fallback.evidence\"), [\n {\n title: i18n.__(\"menu.yes\"),\n payload: \"accept_evidence\"\n },\n {\n title: i18n.__(\"menu.no\"),\n payload: \"decline_evidence\"\n }\n ]);\n let payloadData = {\n payload: this.webhookEvent.message.text,\n user: this.user.psid\n };\n response = [first, second, payloadData];\n } else if (lastevent === \"recomendation4\") {\n let first = Response.genText(i18n.__(\"fallback.recomendation4\"));\n\n let second = Response.genQuickReply(i18n.__(\"fallback.evidence\"), [\n {\n title: i18n.__(\"menu.yes\"),\n payload: \"accept_evidence\"\n },\n {\n title: i18n.__(\"menu.no\"),\n payload: \"decline_evidence\"\n }\n ]);\n let payloadData = {\n payload: this.webhookEvent.message.text,\n user: this.user.psid\n };\n response = [first, second, payloadData];\n } else {\n let first = Response.genText(\n i18n.__(\"fallback.any\", {\n message: this.webhookEvent.message.text\n })\n );\n let second = {\n payload: \"incorrect\",\n user: this.user.psid\n };\n\n response = [first, second];\n }\n console.log(\"Receive 114.js help\");\n }\n\n return response;\n }", "function cwParse() {\n cwRequest.open(\"GET\", \"http://messagehub.herokuapp.com/a3.json\", true);\n cwRequest.send(null);\n cwRequest.onreadystatechange = cwCallback;\n}", "function parseResponse(response) {\n if(!/^\\s*\\d+\\s*-\\s*\\d+\\s*$/.test(response)) {\n return null;\n }\n else {\n return response\n .match(/\\d+/g)\n .map(Number);\n }\n}", "function parseWeather(weatherResponse, res) {\n var weatherData = '';\n weatherResponse.on('data', function (chunk) {\n weatherData += chunk;\n });\n weatherResponse.on('end', function () {\n var weatherObj = JSON.parse(weatherData);\n weatherString = weatherObj.name + \", \" + weatherObj.sys.country + \": \" + Math.round((weatherObj.main.temp-273.15)) + \" degrees celsius and \" + weatherObj.weather[0].description;\n });\n}", "getTextFromAPI() {\n fetch('https://baconipsum.com/api/?type=all-meat&paras=' + this.state.paragraphs + '&start-with-lorem=1')\n .then((response) => response.json())\n .then((responseJson) => {\n this.setState({\n additionalDisplay: this.returnAdditionalDisplay(responseJson)\n }, function() {\n console.log(this.state);\n });\n }).catch((error) => {\n console.log(error);\n });\n }", "function getMeaning() {\n\n if (inputText.value == '') {\n alert(\"The input field is empty...\");\n \n }\n else {\n const xhr = new XMLHttpRequest();\n xhr.open('GET', `https://translate.yandex.net/api/v1.5/tr.json/translate?key=${api_key}&text=${inputText.value}&lang=${language.value}`, true);\n\n xhr.onload = function () {\n if (this.status == 200) {\n var meaning = JSON.parse(this.responseText);\n console.log(meaning);\n\n result.innerHTML = `<h1 class=\"text-center text-danger\">${meaning.text[0]}</h1>`;\n\n\n }\n }\n\n xhr.send();\n }\n}", "function ventanaRespuesta_processResponse(res) {\n try {\n var info = eval('(' + res + ')');\n\n switch (info) {\n case -1:\n muestraVentana(mensajemenosuno);\n break;\n case 1:\n muestraVentana('Información almacenada correctamente');\n $.fancybox.close();\n listarCargos(1);\n idGlobal = \"-1\";\n break;\n case 2:\n muestraVentana('Información Actualizada correctamente');\n $.fancybox.close();\n listarCargos(1);\n idGlobal = \"-1\";\n break;\n case 3:\n muestraVentana('Información Eliminada correctamente');\n $.fancybox.close();\n listarCargos(1);\n idGlobal = \"-1\";\n break;\n case 4:\n muestraVentana('NO SE PUEDE BORRAR EL &Aacute;REA, HAY CARGOS');\n $.fancybox.close();\n listarCargos(1);\n idGlobal = \"-1\";\n break;\n\n }\n } catch (elError) {\n }\n}", "function load_text(result){\n\tvar parsed = JSON.parse(result);\n\tvar title = parsed[\"AVAIL:Title\"];\n\tvar date = parsed[\"AVAIL:DateCreated\"];\n\tvar center = parsed[\"AVAIL:Center\"];\n\tvar description = parsed[\"AVAIL:Description\"];\n\tvar nasa_id = parsed[\"AVAIL:NASAID\"];\n\n\tvar photographer = parsed[\"AVAIL:Photographer\"];\n\tvar location_data = parsed[\"AVAIL:Location\"];\n\tvar keywords = parsed[\"AVAIL:Keywords\"];\n\tvar owner = parsed[\"AVAIL:Owner\"];\n\tvar secondary_creator = parsed[\"AVAIL:SecondaryCreator\"];\n\tvar album = parsed[\"AVAIL:Album\"];\n\t\n\tvar meta = document.getElementById('meta_data');\n\n\tvar title_h = document.getElementById('title');\n\tvar loading = document.getElementById('loading');\n\tloading.style.display = \"none\";\n\t\n\ttitle_h.innerHTML = title;\n\t\n\tmeta.innerHTML += \"<b>Date Created:</b> \" + date + \"<br><br>\";\n\tmeta.innerHTML += \"<b>Center:</b> \" + center + \"<br><br>\";\n\tmeta.innerHTML += \"<b>NASA ID:</b> \" + nasa_id + \"<br><br>\";\n\n\tif(photographer != \"\"){\n\t\tmeta.innerHTML += \"<b>Photographer:</b> \" + photographer + \"<br><br>\";\n\t}\n\tif(location_data != \"\"){\n\t\tmeta.innerHTML += \"<b>Location:</b> \" + location_data + \"<br><br>\";\n\t}\n\tif(owner != \"\"){\n\t\tmeta.innerHTML += \"<b>Owner:</b> \" + owner + \"<br><br>\";\n\t}\n\tif(secondary_creator != \"\"){\n\t\tmeta.innerHTML += \"<b>Secondary Creator:</b> \" + secondary_creator + \"<br><br>\";\n\t}\n\tif(album != \"\"){\n\t\tmeta.innerHTML += \"<b>Album:</b> \" + album + \"<br><br>\";\n\t}\n\t\n\tif(keywords.length > 1)\n\t{\n\t\tmeta.innerHTML += \"<b>Keywords:</b> \";\n\n\t\tfor (index = 0; index < keywords.length; ++index) {\n\t\t\tmeta.innerHTML += \"<span class='mdl-chip'><span class='mdl-chip__text'>\" + keywords[index] + \"</span></span>&nbsp;\";\n\t\t}\n\t\tmeta.innerHTML += \"<br><br>\";\n\t}\n\n\t\n\tmeta.innerHTML += \"<i>\" + description;\n\tmeta.innerHTML += \"<br><br><button onclick='back();' class='mdl-button mdl-js-button mdl-button--raised mdl-js-ripple-effect mdl-button--accent'>Back</button>\"\n}", "getSampleText() {\n axios.get(`https://baconipsum.com/api/?type=meat-and-filler&paras=${this.state.paras}&format=${this.state.format}`)\n .then(response => this.setState(\n { text: response.data },\n ()=> console.log(\"data retrieved\")\n ))\n .catch(e=>console.log(e))\n }", "function extractResponse(json) {\n return JSON.stringify(json['output']['text'][0], null, 2);\n}", "function getMovieInfo() {\n inquirer.prompt([{\n type: 'input',\n name: 'movie',\n message: \"Name a movie:\"\n }\n ]).then(answers => {\n if (!answers.movie) {\n answers.movie = \"Mr Nobody\";\n console.log(\"If you haven't watched Mr. Nobody, then you should: http://www.imdb.com/title/tt0485947/\");\n console.log(\"It's on Netflix!\")\n }\n\n request(\"http://www.omdbapi.com/?t=\" + answers.movie + \"&apikey=trilogy\", function (error, response, body) {\n\n if (!error && response.statusCode === 200) {\n var movieInfo = JSON.parse(body);\n\n var movieResult =\n //Line break\n \"=======================================================================================================\" + \"\\r\\n\" +\n //Output the liri command plus answers.movie\n \"movie-this ---> \" + answers.movie + \"\\r\\n\" +\n //Line break\n \"=======================================================================================================\" + \"\\r\\n\" +\n // title of the movie\n \"Title: \" + movieInfo.Title + \"\\r\\n\" +\n // year the movie came out\n \"Year movie was released: \" + movieInfo.Year + \"\\r\\n\" +\n // IMDB rating of the movie\n \"IMDB movie rating (out of 10): \" + movieInfo.imdbRating + \"\\r\\n\" +\n // rotten tomatoes rating of the movie\n \"Rotten Tomatoes rating (out of 100%): \" + movieInfo.Ratings[1].Value + \"\\r\\n\" +\n // country where the movie was produced.\n \"Filmed in: \" + movieInfo.Country + \"\\r\\n\" +\n // language of the movie.\n \"Language: \" + movieInfo.Language + \"\\r\\n\" +\n // plot of the movie.\n \"Movie plot: \" + movieInfo.Plot + \"\\r\\n\" +\n // actors in the movie.\n \"Actors: \" + movieInfo.Actors + \"\\r\\n\" +\n // line break\n \"=======================================================================================================\"\n\n console.log(movieResult);\n // output the movie information to the log.txt file.\n logData(movieResult);\n }\n });\n });\n}", "function getParsings(text) {\n const url = `${BASE_URL}/dep`\n return axios.post(url, { text });\n }", "handleGetResponse(response) {\n \n return response.text().then(text => {\n const data = text && JSON.parse(text);\n if (!response.ok) {\n const error = (data && data.message) || response.statusText;\n return Promise.reject(error);\n }\n return data;\n });\n}", "function test(text){\n url = \"https://api.susi.ai/susi/chat.json?timezoneOffset=-480&q=\"+encodeURI(text)+\"&instant=\"+encodeURI(SUSISkill);\n url = \"https://api.susi.ai/susi/chat.json?timezoneOffset=-480&q=\"+text+\"&instant=\"+SUSISkillEncoded;\n console.log(url);\n document.getElementById(\"susioutput\").innerHTML = \"loading....\";\n \n var xhttp = new XMLHttpRequest();\n xhttp.onreadystatechange = function() {\n if (this.readyState == 4 && this.status == 200) {\n //alert(this.responseText);\n data = this.responseText;\n document.getElementById(\"susioutput\").innerHTML = JSON.parse(data).answers[0].actions[0].expression; \n }\n };\n xhttp.open(\"POST\", url, true);\n xhttp.setRequestHeader(\"Content-type\", \"application/json\");\n xhttp.send();//\"?timezoneOffset=-480&q=\"+decodeURI(text));\n \n\n \n\n}", "function TreatResponse(response) {\n console.log(response);\n var text = response.response;\n if (text == GET) {\n showGetTranslation();\n }\n else if (text == NO_THANKS) {\n $(\"#header\").html(NO_THANKS).removeClass(\"hide\").show();\n }\n else {\n $(\"#header\").html(\"This is the current translation. Do you approve?\").removeClass(\"hide\").show();\n $(\"#translation-card\").removeClass(\"hide\").show();\n console.log(text);\n $(\"#content\").html(text);\n }\n}", "parse(r) {\r\n return r.text().then(t => {\r\n if (!r.ok) {\r\n throw Error(t);\r\n }\r\n try {\r\n return JSON.parse(t);\r\n }\r\n catch (e) {\r\n // special case in ProcessQuery where we got an error back, but it is not in json format\r\n throw Error(t);\r\n }\r\n }).then((parsed) => {\r\n // here we need to check for an error body\r\n if (parsed.length > 0 && hOP(parsed[0], \"ErrorInfo\") && parsed[0].ErrorInfo !== null) {\r\n throw Error(jsS(parsed[0].ErrorInfo));\r\n }\r\n return this.findResult(parsed);\r\n });\r\n }", "function processWithNLP(slackEvent) {\n return new Promise ((resolve, reject) => {\n \n console.log(\"Sending to API.ai for processing: \\n\", slackEvent);\n \n // slack links can arrive like this <http://nyc.gov> \n // or this <http://nyc.gov|nyc.gov> ... so pulling out \n // the core link in either case.\n // also remove users and channels <@UABC123555>\n // even at the end of a line\n // and trim\n const text_to_send = slackEvent.text.replace(/\\|.*>/,'').replace(/<http(\\S*)>/,'http$1').replace(/<@\\S*>[ $]?/,'').trim();\n \n const content = {\n \"query\": text_to_send,\n \"timezone\": \"America/New_York\",\n \"lang\": \"en\",\n \"sessionId\": slackEvent.user\n }; \n \n request.post({\n url: 'https://api.api.ai/v1/query?v=20150910',\n headers: {\n \"Authorization\": \"Bearer \" + slackEvent.env.API_AI_TOKEN\n },\n body: content,\n json: true\n }, function(error, response, body){\n if (error) {\n reject(null);\n console.log(error);\n return;\n }\n \n console.log(\"API.AI returned: \\n\", response);\n resolve(body.result);\n return;\n });\n \n });\n}", "function getBotResponse(rawText) {\n\n $('<div class=\"message loading new\"><figure class=\"avatar\"><img src=\"static/img/help.png\" /></figure><span></span></div>').appendTo($('.mCSB_container'));\n updateScrollbar();\n\n // document.getElementById('userInput').scrollIntoView({block: 'start', behavior: 'smooth'});\n\n $.get(\"/get\", { msg: rawText }).done(function(data) {\n $('.message.loading').remove();\n if (data=='reload'){\n\n data_new = \"Sorry Invalid selection. Please try again\"\n $('<div class=\"message new\"><figure class=\"avatar\"><img src=\"static/img/help.png\" /></figure>' + data_new + '</div>').appendTo($('.mCSB_container')).addClass('new');\n setDate();\n updateScrollbar();\n // document.getElementById('userInput').scrollIntoView({block: 'start', behavior: 'smooth'});\n setTimeout(location.reload.bind(location), 1000);\n }\n else{\n\n var data_new = data.replace(/\\n/g, \"<br />\");\n var auto_data = data.split(\"\\n\");\n $('<div class=\"message new\"><figure class=\"avatar\"><img src=\"static/img/help.png\" /></figure>' + data_new + '</div>').appendTo($('.mCSB_container')).addClass('new');\n \n setDate();\n updateScrollbar();\n // document.getElementById('userInput').scrollIntoView({block: 'start', behavior: 'smooth'});\n\n }\n\n \n \n });\n }", "function analyseSentiment(data){\n\tconst params = {\n\t\ttext : data\n\t};\n\treturn new Promise(function(fulfill, reject){\n\t\ttry{\n\t\t\trequest.get({url:\"http://localhost:4000/aylien/sentiment\", qs: params}, function(error, response, data){\n\t\t\t\t//console.log(\"Error: \", error);\n\t\t\t\t//console.log(\"Response: \", response);\n\t\t\t\t//console.log(\"Data: \", data);\n\t\t\t\tif(error){\n\t\t\t\t\treject({status: \"400\", data: error});\n\t\t\t\t} else{\n\t\t\t\t\tfulfill({status: \"200\", data: data});\n\t\t\t\t}\n\t\t\t});\n\t\t} catch(ex){\n\t\t\treject({status: \"400\", data: ex});\n\t\t}\n\t\t\n\t});\n}", "function getMsg(text) {\n $.ajax({\n method: 'GET',\n url: 'http://www.liulongbin.top:3006/api/robot',\n data: {\n spoken: text,\n },\n success: (res) => {\n // console.log(res);\n if (res.message === 'success') {\n let msg = res.data.info.text;\n $('#talk_list').append('<li class=\"left_word\"><img src=\"img/person01.png\" /> <span>' + msg + ' </span></li>');\n resetui();\n\n getVoice(msg);\n }\n }\n })\n }", "function onSuccessText(recognizedText) {\n //var element = document.getElementById('pp');\n //element.innerHTML=recognizedText.blocks.blocktext;\n //Use above two lines to show recognizedText in html\n console.log(recognizedText);\n alert(\"Text: \" + recognizedText.blocktext);\n }", "function parseResponse(xmlRequest)\n{\n if (xmlRequest.status == 200) {\n if (DEBUG) {\n alert('Response XML: ' + xmlRequest.responseXML);\n alert('Response: ' + xmlRequest.responseText);\n }\n clearTextArea('messageTextArea');\n updateCharacterCount();\n } else {\n if (DEBUG) {\n alert('HTTP Code: ' + xmlRequest.status);\n alert('HTTP Status: ' + xmlRequest.statusText);\n alert('Response: ' + xmlRequest.responseText);\n }\n }\n}", "function NWTIOResponse (request) {\n\tthis.request = request;\n\ttry {\n\t\tthis.obj = JSON.parse(request.responseText);\n\t} catch(e) {}\n}", "function handleApiAiResponse(sender, response) {\n let responseText = response.result.fulfillment.speech;\n let responseData = response.result.fulfillment.data;\n let messages = response.result.fulfillment.messages;\n let action = response.result.action;\n let contexts = response.result.contexts;\n let parameters = response.result.parameters;\n\n sendTypingOff(sender);\n\n if (\n isDefined(messages) &&\n ((messages.length == 1 && messages[0].type != 0) || messages.length > 1)\n ) {\n let timeoutInterval = 1500;\n let previousType;\n let cardTypes = [];\n let timeout = 0;\n for (var i = 0; i < messages.length; i++) {\n if (\n previousType == 1 &&\n (messages[i].type != 1 || i == messages.length - 1)\n ) {\n timeout = (i - 1) * timeoutInterval;\n setTimeout(handleCardMessages.bind(null, cardTypes, sender), timeout);\n cardTypes = [];\n timeout = i * timeoutInterval;\n setTimeout(handleMessage.bind(null, messages[i], sender), timeout);\n } else if (messages[i].type == 1 && i == messages.length - 1) {\n cardTypes.push(messages[i]);\n timeout = (i - 1) * timeoutInterval;\n setTimeout(handleCardMessages.bind(null, cardTypes, sender), timeout);\n cardTypes = [];\n } else if (messages[i].type == 1) {\n cardTypes.push(messages[i]);\n } else {\n timeout = i * timeoutInterval;\n setTimeout(handleMessage.bind(null, messages[i], sender), timeout);\n }\n\n previousType = messages[i].type;\n }\n } else if (responseText == \"\" && !isDefined(action)) {\n //api ai could not evaluate input.\n console.log(\"Unknown query\" + response.result.resolvedQuery);\n sendTextMessage(\n sender,\n \"I'm not sure what you want. Can you be more specific?\"\n );\n } else if (isDefined(action)) {\n handleApiAiAction(sender, action, responseText, contexts, parameters);\n } else if (isDefined(responseData) && isDefined(responseData.facebook)) {\n try {\n console.log(\"Response as formatted message\" + responseData.facebook);\n sendTextMessage(sender, responseData.facebook);\n } catch (err) {\n sendTextMessage(sender, err.message);\n }\n } else if (isDefined(responseText)) {\n sendTextMessage(sender, responseText);\n }\n}", "function newResponse(recipientId, text) {\n text = text || \"\";\n var testimonios = text.match(/testimonios/gi);\n\n if(testimonios != null) {\n var query = \"\";\n\n //sendMessage(recipientId, message);\n if(testimonios != null) {\n query = \"Historias\";\n } \n sendButtonMessage(recipientId, query);\n return true\n }\n return false;\n}", "function displayAnswer(response) {\n var question = document.getElementById(\"question\").value;\n $('.answer').text(response[\"output\"][\"text\"][0]);\n}", "function getInvInfo() {\n //create new request\n var req = new XMLHttpRequest();\n if (!req) {\n throw \"Unable to create HttpRequest.\";\n }\n //url should be appropriate php reference\n var url = 'http://web.engr.oregonstate.edu/~weckwera/290/wk10/lab.php';\n req.onload = function () {\n if (this.readyState === 4) {\n console.log(this.status); //tell me that you're doing something\n console.log(this.responseText);//check out server response\n \n //var response = JSON.parse(this.responseText);\n var response = (this.responseText);\n \n //call function with results\n drawInvInfo(response);\n }\n }\n\n var args = \"getInvInfo=true\";\n \n req.open('POST', url);\n req.setRequestHeader(\"Content-Type\", \"application/x-www-form-urlencoded\");\n req.send(args);\n}", "function getRequest(callback) {\n console.log(\"text \" + text);\n request({\n url: 'https://api.wit.ai/message?q=' + encodeURI(text), \n method: 'GET', \n headers: { \n 'Authorization': 'Bearer ' + config.wit_access_token\n }\n }, function(error, response, body){\n if(!error && response.statusCode == 200) {\n var bodyjsonparse = JSON.parse(body);\n var intent = \"\";\n \n //console.log(\"JSON Body \" + bodyjsonparse);\n //console.log(\"Entities \" + bodyjsonparse['entities']['intent'][0]['value']);\n \n \n try {\n intent = bodyjsonparse['entities']['intent'][0]['value']['value'];\n if (intent == undefined) {\n intent = bodyjsonparse['entities']['intent'][0]['value'];\n }\n \n } catch (err) {\n intent = '';\n \n } finally {\n console.log(\"intent \" + intent);\n \n executeIntent(intent);\n }\n\n /*\n var entities = bodyjsonparse[\"outcomes\"][0][\"entities\"];\n var intent;\n console.log(entities);\n if (entities.length == 0) {\n intent = \"\";\n } else if (entities[\"intent\"] == undefined) {\n intent = \"\";\n } else {\n intent = entities[\"intent\"][0][\"value\"];\n }\n */\n\n }\n });\n}", "function response(err, data) {\n if (err) {\n console.err(err);\n }\n showText(data[0].label);\n}", "function parseTextResult(data) {\r\n $(\"#text_noencoding\").val(data.textNoCoding);\r\n $(\"#text_decoded\").val(data.textWithCoding);\r\n}", "function newSlideReceived() {\n if ((req.readyState == 4) && (req.status == 200))\n {\n// var uncompressed = pako.inflate(new Uint8Array(req.responseText), {to: 'string'});\n\n // Convert utf8 -> utf16 (native JavaScript string format)\n// var decoded = decodeURIComponent(escape(uncompressed));\n document.getElementById(\"slide\").innerHTML = req.responseText;\n }\n}", "function getResponse(handleResponse, handleError) {\r\n // reset the result textarea\r\n resultTextarea.value = \"\";\r\n var matches = handleResponse.results;\r\n\r\n for (var i = 0; i < matches.length; i++) {\r\n resultTextarea.value += matches[i];\r\n }\r\n \r\n if (matches.length == 0 || matches == undefined){\r\n matchesCount.innerText = \"No Matches Found\";\r\n } else {\r\n matchesCount.innerText = `${matches.length} match${ matches.length > 1 ? 'es' : '' } found`;\r\n }\r\n // store current values in the storage so user doesn't have to type again when he comes back to popup\r\n storeCurrent();\r\n }", "function parseResponse (r) {\n if(r[0] === \"[\" || r[0] === \"{\" ) return JSON.parse(r);\n return r;\n }", "function tenorCallback_search(responsetext) {\n // parse the json response\n var response_objects = JSON.parse(responsetext);\n res = response_objects[\"results\"];\n\n // load the GIFs -- for our example we will load the first GIFs preview size (nanogif) and share size (tinygif)\n // document.getElementById(\"preview_gif\").src = top_10_gifs[0][\"media\"][0][\"nanogif\"][\"url\"];\n // document.getElementById(\"share_gif\").src = \n return res[0][\"media\"][0][\"tinygif\"][\"url\"];;\n}", "function handleMovieResponse(response) {\n console.log(\"handleMovieResponse\");\n console.log(response);\n const genreArr = response.Genre.split(\", \");\n var genreData;\n // spliting the response to return 1 result, each movie can have multiple genres\n for (let i = 0; i < genreArr.length; i++) {\n if (genreArr[i] == \"Western\") {\n genreData = genreArr[i].split();\n console.log(genreData);\n } else if (genreArr[i] == \"Romance\") {\n genreData = genreArr[i].split();\n console.log(genreData);\n } else if (genreArr[i] == \"Horror\") {\n genreData = genreArr[i].split();\n console.log(genreData);\n } else if (genreArr[i] == \"Sci-Fi\") {\n genreData = genreArr[i].split();\n console.log(genreData);\n } else {\n genreData = response.Genre.split(\", \");\n }\n }\n\n // checks if there is at least one genre associated with this movie\n if (genreData.length > 0) {\n // the div gets updated with the movie information\n updateMovieDiv(response);\n\n //calls getSpiritForGenre with our genreData gathered above\n let spirit = getSpiritForGenre(genreData);\n if (spirit) {\n // If spirit is found in our array then it is sent to cocktailDBquery to return a drink\n cocktailDBquery(spirit);\n } else {\n // error case\n let message = `Spirit not found for ${response.Genre}`;\n updateErrorDiv(message);\n }\n } else {\n // error case\n let message = `Genre not found for ${movie}`;\n updateErrorDiv(message);\n }\n}", "function processResponse(err, response) {\n if (err) {\n console.error(err); // something went wrong\n return;\n }\n\n // Display the output from dialog, if any.\n if (response.output.text.length != 0) {\n console.log(response.output.text[0]);\n }\n}", "function interpretMessage(watsonResponse) {\n logExpression(\"In interpretMessage, watsonResponse is: \", 2);\n logExpression(watsonResponse, 2);\n let intents = watsonResponse.intents;\n let entities = watsonResponse.entities;\n let cmd = {};\n if (intents[0].intent == \"Offer\" && intents[0].confidence > 0.2) {\n let extractedOffer = extractOfferFromEntities(entities);\n cmd = {\n quantity: extractedOffer.quantity\n };\n if(extractedOffer.price) {\n cmd.price = extractedOffer.price;\n if(watsonResponse.input.role == \"buyer\") {\n cmd.type = \"BuyOffer\";\n }\n else if (watsonResponse.input.role == \"seller\") {\n cmd.type = \"SellOffer\";\n }\n }\n else {\n if(watsonResponse.input.role == \"buyer\") {\n cmd.type = \"BuyRequest\";\n }\n else if (watsonResponse.input.role == \"seller\") {\n cmd.type = \"SellRequest\";\n }\n }\n }\n else if (intents[0].intent == \"AcceptOffer\" && intents[0].confidence > 0.2) {\n cmd = {\n type: \"AcceptOffer\"\n };\n }\n else if (intents[0].intent == \"RejectOffer\" && intents[0].confidence > 0.2) {\n cmd = {\n type: \"RejectOffer\"\n };\n }\n else if (intents[0].intent == \"Information\" && intents[0].confidence > 0.2) {\n cmd = {\n type: \"Information\"\n };\n }\n else {\n cmd = {\n type: \"NotUnderstood\"\n };\n }\n if(cmd) {\n cmd.metadata = JSON.parse(JSON.stringify(watsonResponse.input));\n if(!cmd.metadata.addressee || cmd.metadata.addressee.length == 0) {\n cmd.metadata.addressee = extractAddressee(entities); // Expect the addressee to be provided, but extract it if necessary\n }\n cmd.metadata.timeStamp = new Date();\n }\n logExpression(\"Returning from interpretMessage with cmd: \", 2);\n logExpression(cmd, 2);\n return cmd;\n}", "function parse_response_body(data) {\n\tvar response = {'headers':{}, 'body':''};\n\tpass(split(/\\n\\n/, \"\"+data, 2)).on(function(headers, body) {\n\t\tforeach(headers.split(\"\\n\")).do(function(line) {\n\t\t\tpass(split(/: */, \"\"+line, 2)).on(function(name, value) {\n\t\t\t\tresponse.headers[(\"\"+name).toLowerCase()] = value;\n\t\t\t});\n\t\t});\n\t\tif (body) {\n\t\t\tresponse.body = body;\n\t\t}\n\t});\n\treturn response;\n}", "function parse_requests(client_requests) {\n\t$('p').remove();\n\t$.each(client_requests, function(k, v) {\n\t\t$.each(v, function(key, value) {\n\t\t\t$('#results')\n\t\t\t\t.append($(\"<p></p>\")\n\t\t\t\t\t.text(key + ': ' + value));\n\t\t});\n\t});\n\t$('form').hide();\n\t$('#results').show();\n}", "function parseResults(response){\n $(\"#status\").html(response.results.length + \" risultati trovati\");\n $.each(response.results, function(index,element){\n populateResults(element);\n })\n}", "buildResult(response) {\n return {\n text: response.data,\n };\n }", "buildResult(response) {\n return {\n text: response.data,\n };\n }", "function parseTextMessage(data) {\n var timeSeparator = data.indexOf(\"|\", 2);\n var time = data.slice(2, timeSeparator);\n var usernameSeparator = data.indexOf(\"|\", timeSeparator + 1);\n var username = data.slice(timeSeparator + 1, usernameSeparator);\n var message = data.slice(usernameSeparator + 1);\n return { time: parseFloat(time), username: username, message: message };\n}", "dataParser(data) {\n console.log(\"Je commence fini\");\n for (var i = 0; i < data.results; i++) {\n this.responses[i] = data.response[i];\n this.tabInt[i] = i;\n }\n }", "function getTextResponse(sender, title, subtitle, directions, gameText) {\n var messageDataImg = JSON.stringify({\n recipient: {\n id: sender\n },\n messaging_type: \"RESPONSE\",\n message: {\n text: gameText + \"\\n\"+ title + \"\\n\" + subtitle,\n quick_replies: directions\n }\n });\n console.log(\"game text msg:\" + JSON.stringify(messageDataImg));\n return messageDataImg;\n}", "function getElements(response) {\n if (response instanceof Error) {\n alert(response);\n } else {\n addMovieResults(response.Similar.Results);\n }\n}", "function parsing_conv_respone(convrespose){\r\n var entity_chemical_name = \"\";\r\n if(convrespose.entities.length !== 0){\r\n for(var i=0;i<convrespose.entities.length;i++){\r\n entity_chemical_name = convrespose.entities[i].value;\r\n //console.log(convrespose.entities[i].value);\r\n } \r\n } else {\r\n entity_chemical_name = null;\r\n //console.log(\"Entities are empty\");\r\n } \r\n return entity_chemical_name;\r\n}", "function movie(){request(\"http://www.omdbapi.com/?apikey=40e9cece&t=Mr.+Nobody\", function(error, response, body) {\n if (!error && response.statusCode === 200) {\n\n // Then log the body from the site!\n console.log(body);\n }\n});\n}", "function piiParser(tweetContent) {\n\tlet matchArray = [];\n\t\n\tlet telephone = /1?\\W*([2-9][0-8][0-9])\\W*([2-9][0-9]{2})\\W*([0-9]{4})(\\se?x?t?(\\d*))?/;\n\tif (telephone.test(tweetContent)) {\n\t\tmatchArray.push(\"Tweet contains a telephone number\");\n\t}\n\t\n\tlet email = /([a-zA-Z0-9_\\-\\.]+)@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.)|(([a-zA-Z0-9\\-]+\\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\\]?)/;\n\tif (email.test(tweetContent)) {\n\t\tmatchArray.push(\"Tweet contains an email address\");\n\t}\n\t\n\tlet date = /([12]\\d{3}\\/(0[1-9]|1[0-2])\\/(0[1-9]|[12]\\d|3[01]))/;\n\tif (date.test(tweetContent)) {\n\t\tmatchArray.push(\"Tweet contains a potential significant date\");\n\t}\n\t\n\tlet ipv4 = /[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}$/;\n\tif (ipv4.test(tweetContent)) {\n\t\tmatchArray.push(\"Tweet contains an IP address\");\n\t}\n\treturn matchArray;\n}", "function parseGettext(locale, data, options = {}) {\n const out = {\n charset: 'utf-8',\n headers: {\n 'project-id-version': options.project || 'i18next-conv',\n 'mime-version': '1.0',\n 'content-type': 'text/plain; charset=utf-8',\n 'content-transfer-encoding': '8bit'\n },\n translations: {}\n };\n const ext = plurals.getRule(locale);\n const trans = {};\n out.headers['plural-forms'] = `nplurals=${ext.nplurals}; plural=${ext.plurals}`;\n\n if (!options.noDate) {\n out.headers['pot-creation-date'] = new Date().toISOString();\n out.headers['po-revision-date'] = new Date().toISOString();\n if (options.potCreationDate && typeof options.potCreationDate.toISOString === 'function') out.headers['pot-creation-date'] = options.potCreationDate.toISOString();\n if (options.poRevisionDate && typeof options.poRevisionDate.toISOString === 'function') out.headers['po-revision-date'] = options.poRevisionDate.toISOString();\n }\n\n if (options.language) {\n out.headers.language = options.language;\n }\n\n const delkeys = [];\n Object.keys(data).forEach(m => {\n const kv = data[m];\n\n if (kv.plurals) {\n const pArray = [];\n\n for (let i = 0, len = kv.plurals.length; i < len; i += 1) {\n const plural = kv.plurals[i];\n pArray.splice(getGettextPluralPosition(ext, plural.pluralNumber - 1), 0, plural.value);\n }\n\n if (ext.nplurals !== 1) {\n pArray.splice(getGettextPluralPosition(ext, kv.pluralNumber - 1), 0, kv.value);\n }\n\n if (typeof trans[kv.context] !== 'object') trans[kv.context] = {};\n\n if (options.keyasareference) {\n if (typeof trans[kv.context][kv.value] === 'object') {\n // same context and msgid. this could theorically be merged.\n trans[kv.context][kv.value].comments.reference.push(kv.key);\n } else {\n trans[kv.context][kv.value] = {\n msgctxt: kv.context,\n msgid: pArray[0],\n msgid_plural: pArray.slice(1, pArray.length),\n msgstr: kv.translated_value,\n comments: {\n reference: [kv.key]\n }\n };\n }\n\n if (kv.key !== kv.value) {\n delkeys.push([kv.context, kv.key]);\n }\n } else {\n let msgid = kv.key; // eslint-disable-next-line camelcase\n\n let msgid_plural = kv.key;\n\n if (kv.key.indexOf('|#|') > -1) {\n const p = kv.key.split('|#|');\n msgid = p[0]; // eslint-disable-next-line camelcase\n\n msgid_plural = p[1];\n }\n\n trans[kv.context][kv.key] = {\n msgctxt: kv.context,\n msgid,\n msgid_plural,\n msgstr: pArray\n };\n }\n } else {\n if (typeof trans[kv.context] !== 'object') trans[kv.context] = {};\n\n if (options.keyasareference) {\n if (typeof trans[kv.context][kv.value] === 'object') {\n // same context and msgid. this could theorically be merged.\n trans[kv.context][kv.value].comments.reference.push(kv.key);\n } else {\n trans[kv.context][kv.value] = {\n msgctxt: kv.context,\n msgid: kv.value,\n msgstr: kv.translated_value,\n comments: {\n reference: [kv.key]\n }\n };\n }\n\n if (kv.key !== kv.value) {\n delkeys.push([kv.context, kv.key]);\n }\n } else {\n trans[kv.context][kv.key] = {\n msgctxt: kv.context,\n msgid: kv.key,\n msgstr: kv.value\n };\n }\n }\n });\n delkeys.forEach(a => {\n const c = a[0];\n const k = a[1];\n delete trans[c][k];\n }); // re-format reference comments to be able to compile with gettext-parser...\n\n Object.keys(trans).forEach(ctxt => {\n Object.keys(trans[ctxt]).forEach(id => {\n if (trans[ctxt][id].comments && trans[ctxt][id].comments.reference) {\n trans[ctxt][id].comments.reference = trans[ctxt][id].comments.reference.join('\\n');\n }\n });\n });\n out.translations = trans;\n return Promise.resolve(out);\n}", "function parseControlResponse(text) {\n const lines = text.split(/\\r?\\n/).filter(isNotBlank);\n const messages = [];\n let startAt = 0;\n let tokenRegex;\n for (let i = 0; i < lines.length; i++) {\n const line = lines[i];\n // No group has been opened.\n if (!tokenRegex) {\n if (isMultiline(line)) {\n // Open a group by setting an expected token.\n const token = line.substr(0, 3);\n tokenRegex = new RegExp(`^${token}(?:$| )`);\n startAt = i;\n }\n else if (isSingleLine(line)) {\n // Single lines can be grouped immediately.\n messages.push(line);\n }\n }\n // Group has been opened, expect closing token.\n else if (tokenRegex.test(line)) {\n tokenRegex = undefined;\n messages.push(lines.slice(startAt, i + 1).join(LF));\n }\n }\n // The last group might not have been closed, report it as a rest.\n const rest = tokenRegex ? lines.slice(startAt).join(LF) + LF : \"\";\n return { messages, rest };\n}", "function scrapeinfo(name){\n var spotify;\n var soundcloud;\n var twitter;\n var other;\n var wikipedia;\n var youtube;\n var instagram;\n var facebook;\n var info = [];\n var search=name.split(\"-\")[0].split(\"&\")[0].trim().split(\",\")[0].trim().split(\"ft.\")[0].trim().split(\"vs\")[0].trim().split(\"Ft.\")[0].trim().split(\"feat.\")[0].trim().split(\"Feat.\")[0].trim().split(' ').join('-');\n search = deUmlaut(search);\n info.push(search);\n var callbackinfo = [search,,];\n var linksearch = name.split(\"-\")[0].split(\"&\")[0].split(' ').join('+');\n linksearch = linksearch.slice(0, -1);\n var url = encodeURIComponent('https://genius.com/artists/' + search);\n var geniusurl = 'https://genius.com/artists/' + search;\n //////console.log('https://google.com/search?q='+linksearch);\n var linkurl = encodeURIComponent('https://google.com/search?q='+linksearch+\"+website\");\n //////console.log(linkurl);\n \n fetch(`https://api.allorigins.win/get?url=${url}`)\n .then(response => {\n\tif (response.ok) return response.json()\n\tthrow new Error('Network response was not ok.')\n })\n .then(function(data){\n //var res = data.find();\n var quick = data.contents;\n //////console.log(quick);\n var index = quick.search(\"rich_text_formatting\");\n var quick = quick.substring(index,quick.lenght);\n index = quick.search(\"<p>\");\n quick = quick.substring(index,quick.lenght);\n var desc; \n try{\n desc = quick.split(\"</p>\")[0];\n desc += quick.split(\"</p>\")[1].split(\"</p>\")[0];\n }\n catch(e){}\n if(desc.includes('img')){\n try{\n desc = quick.split(\"</p>\")[1].split(\"</p>\")[0];\n desc+= quick.split(\"</p>\")[1].split(\"</p>\")[1].split(\"</p>\")[0];\n }\n catch(e){}\n }\n if(desc.includes('img')){\n try{\n desc = quick.split(\"</p>\")[0];\n desc += quick.split(\"</p>\")[1].split(\"</p>\")[0];\n }\n catch(e){}\n }\n desc = desc.split(\" \",60).join(\" \") + \"...\" +\"</p>\";\n if(desc == \"...\" +\"</p>\"){\n desc = \"this artist doesn't currently have a description.\";\n }\n desc.replace(\"....\",\"...\");\n //console.log(\"description:\" + desc);\n info[1]=desc;\n var lenghtLim = info[1].split(\" \",60) + \"\";\n \n $(\"#artistInfo\").html(info[1].trim());\n if($(\"#artistInfo\").html().includes(\"</div>\") || $(\"#artistInfo\").html().includes(\"html\") || $(\"#artistInfo\").html().includes(\"You can search Genius by using the search bar above, or\")){\n $(\"#artistInfo\").html(\"this artist doesn't currently have a description.\");\n }\n \n ////console.log(info);\n });\n \n fetch(`https://api.allorigins.win/get?url=${linkurl}`)\n .then(response => {\tif (response.ok) return response.json()\n\tthrow new Error('Network response was not ok.')\n })\n .then(function(data){\n //var res = data.find();\n var quick = data.contents;\n ////////console.log(quick);\n var index = quick.search(\"kCrYT\");\n quick = quick.substring(index,quick.lenght);\n var n=20;var i=0;\n for(i=2;i<n+2;i++){\n var index = quick.search(\"kCrYT\");\n quick = quick.substring(index,quick.lenght);\n index = quick.search(\"<a href=\");\n if((quick.substring(index,index+20).includes(\"/search?q=\"))){\n continue;\n }\n //////console.log(quick);\n quick = quick.substring(index+16,quick.lenght);\n var link = quick.split('\"')[0];\n //////console.log(link);\n link = link.split(\"&amp\")[0];\n //////console.log(\"link:\" + link);\n info[i] = decodeURIComponent(link);\n //////console.log(link);\n try{\n var domain = info[i].split(\"//\")[1].split(\".com\")[0].split(\".org\")[0];\n if(domain.includes(\".\")){\n domain=domain.split(\".\")[1];\n }\n }\n catch(e){\n \n }\n ////console.log(domain);\n if(typeof domain !== 'undefined'){\n if(domain === \"spotify\" && typeof spotify === 'undefined'){\n ////////console.error(\"spotify be like whoa\");\n spotify = info[i];\n //////console.log(\"spotify :\" + spotify);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink2\")\n .prop(\"href\",spotify)\n .html(\"Spotify\");\n }\n }\n else if(domain === \"soundcloud\" && typeof soundcloud === 'undefined'){\n ////////console.error(\"soundcloud be like whoa\");\n soundcloud = info[i];\n //////console.log(\"soundcloud :\" + soundcloud);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink3\")\n .prop(\"href\",soundcloud)\n .html(\"SoundCloud\");\n }\n }\n else if(domain === \"twitter\" && typeof twitter === 'undefined'){\n ////////console.error(\"twitter be like whoa\");\n twitter = info[i];\n //////console.log(\"twitter :\" + twitter);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink4\")\n .prop(\"href\",twitter)\n .html(\"Twitter\");\n }\n }\n else if(domain === \"wikipedia\" && typeof wikipedia === 'undefined'){\n ////////console.error(\"wiki be like whoa\");\n wikipedia = info[i];\n //////console.log(\"wiki :\" + wikipedia);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink5\")\n .prop(\"href\",wikipedia)\n .html(\"Wikipedia\");\n }\n }\n else if(domain.includes(info[0].split(\"-\")[0]) && typeof other === 'undefined'){\n ////////console.error(\"artist be like whoa\");\n other = info[i];\n //////console.log(\"artist website:\" + other);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink1\")\n .prop(\"href\",other)\n .html(\"Official Website\");\n }\n }\n else if(domain === \"youtube\" && typeof youtube === 'undefined'){\n ////////console.error(\"artist be like whoa\");\n youtube = info[i];\n ////////console.log(\"youtube:\" + youtube);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink6\")\n .prop(\"href\",youtube)\n .html(\"Youtube\");\n }\n }\n else if(domain === \"instagram\" && typeof instagram === 'undefined'){\n ////////console.error(\"artist be like whoa\");\n instagram = info[i];\n ////////console.log(\"instagram:\" + instagram);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink7\")\n .prop(\"href\",instagram)\n .html(\"Instagram\");\n }\n }\n else if(domain === \"facebook\" && typeof facebook === 'undefined'){\n ////////console.error(\"artist be like whoa\");\n facebook = info[i];\n ////////console.log(\"facebook:\" + facebook);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink8\")\n .prop(\"href\",facebook)\n .html(\"Facebook\");\n }\n }\n }\n else{\n $(\"#artistlink8\")\n .html(\"We're sorry!We failed to load links...\");\n ////console.log(\"failed to load links...\");\n }\n \n\n }\n $(\"#about\").html(\"About \" + titleCase(info[0].replace(\"-\",\" \")) + \"\");\n $(\"#geniuslink\").prop(\"href\",geniusurl); \n if(info[2]!=\"ick=\"){\n $(\".artistlinks\").css(\"pointer-events\",\"auto\");\n }\n else{\n $(\".artistlinks\")\n .css(\"pointer-events\",\"none\")\n .css(\"cursor\",\"not-allowed\");\n }\n });\n\n}", "function getResponseJSON(){\n return {\n \"version\": \"1.0\",\n \"response\": {\n \"outputSpeech\": {\n \"type\": \"PlainText\",\n \"text\": \"God Bless Silicon Valley.\"\n },\n \"card\": {\n \"content\": \"I pushed a lever for you.\",\n \"title\": \"Toilet Flusher\",\n \"type\": \"Simple\"\n },\n \"shouldEndSession\": true\n },\n \"sessionAttributes\": {}\n };\n}", "async function message(context, text, sessionId) {\n var payload = {\n context,\n assistantId,\n sessionId,\n input: {\n text,\n message_type: 'text',\n options: {\n return_context: true\n }\n }\n }\n return new Promise(function (resolve, reject) {\n assistant.message(payload, function (err, data) {\n if (err) reject(err)\n else {\n var text = '';\n var responses = data.result.output.generic;\n var intent = '';\n var entity = '';\n var nombre = '';\n var grado = '';\n \n var contexto = data.result.context.skills['main skill'].user_defined;\n if(contexto){\n //console.log(JSON.stringify(contexto, null, 2));\n //console.log(contexto.carrera);\n if(contexto.nombres){\n nombre += contexto.nombres;\n }\n if(contexto.grado_colegio){\n grado += contexto.grado_colegio;\n } \n }\n \n var entities = data.result.output.entities;\n //console.log(JSON.stringify(entities, null, 2));\n var intents = data.result.output.intents;\n //console.log(JSON.stringify(intents, null, 2));\n //console.log(intents.length);\n \n if(intents){\n if(intents.length >0){\n intents.forEach(res =>{\n if(res.intent == \"hacer_review\"){\n //console.log(res.intent);\n intent += res.intent;\n }\n })\n }\n }\n if(entities){\n if(entities.length > 0){\n entities.forEach(respt => {\n if(respt.entity == \"carreras_ing\"){\n entity += respt.entity;\n }\n })\n }\n }\n \n if (responses) {\n if (responses.length > 0) {\n responses.forEach(resp => {\n switch (resp.response_type) {\n case 'text':\n //console.log(response.output.generic[0].text);\n text += resp.text;\n break;\n case 'option':\n // una lista de opciones.\n //console.log(response.output.generic[0].title);\n text += resp.title;\n text += '<br/>';\n const options = resp.options;\n // Listar las opciones por etiqueta.\n //text += '<ul>';\n for (let i = 0; i < options.length; i++) {\n //console.log((i+1).toString() + '. ' + options[i].label);\n text += '<img src=\"img/circulo.png\" class=\"circle\"></img>&nbsp;<span style=\"color:#e34949;cursor:pointer\" id=\"opcion\" onclick=\"enviarMensajeAssistant({},\\'' + options[i].value.input.text + '\\', sessionId);\">'+ options[i].label + '</span>';\n text += '<br/>';\n }\n //text += '</ul>'\n break;\n }\n })\n }\n }\n resolve({\n text , intent , entity ,nombre, grado\n })\n }\n })\n })\n}", "function MyEpisodes(error, response, body) {\n // Is request successful?\n if (!error && response.statusCode == 200)\n {\n // Parse result from XML to Object\n parseString(body, function(err, result) {\n // Save useful info\n var r = result.rss.channel[0].item;\n\n // No shows today\n if (r.length == 0) {\n return false;\n }\n\n // Set title to something more useful\n data.title = \"Shows airing today\";\n\n // Go through each show\n for (var i = 0; i < r.length; i++)\n {\n // Save title\n var info = parseTitle(r[i].title[0]);\n\n // Add to data-text\n data.body += info[0]+\"\\n\";\n }\n\n // Save data to data-object\n requestSettings.PushBulletSettings.body = JSON.stringify(data);\n\n // Push to PushBullet\n request(requestSettings.PushBulletSettings, PushBullet);\n });\n }\n}", "function parseImg() {\n let parsedData = JSON.parse(this.responseText);\n renderImg(parsedData.message);\n}", "function parseLattice1Response(r) {\n const parsed = {\n err: null,\n data: null,\n }\n const b = Buffer.from(r, 'hex');\n let off = 0;\n \n // Get protocol version\n const protoVer = b.readUInt8(off); off++;\n if (protoVer !== VERSION_BYTE) {\n parsed.err = 'Incorrect protocol version. Please update your SDK';\n return parsed;\n }\n\n // Get the type of response\n // Should always be 0x00\n const msgType = b.readUInt8(off); off++;\n if (msgType !== 0x00) {\n parsed.err = 'Incorrect response from Lattice1';\n return parsed;\n }\n\n // Get the payload\n b.readUInt32BE(off); off+=4; // First 4 bytes is the id, but we don't need that anymore\n const len = b.readUInt16BE(off); off+=2;\n const payload = b.slice(off, off+len); off+=len;\n\n // Get response code\n const responseCode = payload.readUInt8(0);\n if (responseCode !== responseCodes.RESP_SUCCESS) {\n parsed.err = `Error from device: ${responseMsgs[responseCode] ? responseMsgs[responseCode] : 'Unknown Error'}`;\n parsed.responseCode = responseCode;\n return parsed;\n } else {\n parsed.data = payload.slice(1, payload.length);\n }\n\n // Verify checksum\n const cs = b.readUInt32BE(off);\n const expectedCs = checksum(b.slice(0, b.length - 4));\n if (cs !== expectedCs) {\n parsed.err = 'Invalid checksum from device response'\n parsed.data = null;\n return parsed;\n }\n \n return parsed;\n}" ]
[ "0.6124493", "0.6070044", "0.60401046", "0.601658", "0.594756", "0.5944022", "0.58137923", "0.5715947", "0.5695403", "0.56927407", "0.55704355", "0.552475", "0.55208033", "0.5520296", "0.5505458", "0.5476078", "0.5475715", "0.54719347", "0.543121", "0.54224634", "0.5422113", "0.5400817", "0.5385475", "0.53644496", "0.5356984", "0.5332687", "0.5316213", "0.52973413", "0.52869236", "0.5279147", "0.524841", "0.5246593", "0.524639", "0.524639", "0.523805", "0.5221924", "0.52206933", "0.52193713", "0.5208398", "0.5204487", "0.52043724", "0.520435", "0.51799345", "0.51786345", "0.51750535", "0.51617813", "0.5160347", "0.51569223", "0.5149595", "0.51445585", "0.5131467", "0.5130942", "0.5122056", "0.5116011", "0.51056105", "0.5103258", "0.5099553", "0.5095394", "0.5084599", "0.50836474", "0.50766194", "0.5075361", "0.5072672", "0.5072136", "0.50644624", "0.5061315", "0.5059697", "0.5053239", "0.5044203", "0.503097", "0.5030499", "0.50290614", "0.50289017", "0.5026709", "0.5026278", "0.5021998", "0.50192195", "0.501401", "0.50020564", "0.49973458", "0.49899858", "0.49894285", "0.49861035", "0.49853325", "0.49853325", "0.49838293", "0.49828613", "0.49765047", "0.4963841", "0.49636722", "0.4963445", "0.49602368", "0.49599263", "0.49569374", "0.4950415", "0.49494773", "0.49445963", "0.49428254", "0.49399278", "0.49318957" ]
0.5913698
6
Javascript placed here will be applied to the Wikia skin. / / THEME STYLES / / Fancy background animation (requires styles in Wikia.css)
function renderbganim() { // generate the html var bganimhtml = '<div class="bganim-outer">'; bganimhtml += '<div class="bganim-inner">'; bganimhtml += '</div>'; bganimhtml += '</div>'; // add it to the DOM tree $( "#WikiaPage" ).prepend( bganimhtml ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function theme_script(){\n\n}", "function wintheme() {\t\n\t\t\t\tvar bgColour = new Array(teal,cyan,cobalt,indigo,violet,pink,magenta,crimson,red,orange,amber,yellow);\t\n\t\t\t\t// random colours\n\t\t\t\tvar randNum = Math.random();\n\t\t\t\tvar i = Math.round(randNum * 12);\n\t\t\t\t\t// animate colours over 2 seconds\t\n\t\t\t\t\t$('.hero, .subpagesvces, .footerlinks').animate({\n\t\t\t\t\t backgroundColor: bgColour[i+1]\n\t\t\t\t\t},2000);\t\n\t\t\t\t\t$('body').animate({\n\t\t\t\t\t backgroundColor: bgColour[i]\n\t\t\t\t\t},2000);\t\n\t\t\t\tsetTimeout(wintheme,15000)\t// retart function every 15 seconds\t\n\t\t\t\t}", "function changeSkin() {\r\n var RotatorImage = $(\"#slider.animate a.active img\");\r\n\r\n changeSkinBackground(RotatorImage.attr(\"movieid\"), RotatorImage.attr(\"skin\"));\r\n changeCallToActionInfo(RotatorImage.attr(\"movieid\"), \"/movie\" + RotatorImage.attr(\"movieUrl\"));\r\n\r\n if (RotatorImage.attr(\"align-title\") == \"left\") {\r\n $(\".call-to-action .button-wrapper\").css(\"float\", RotatorImage.attr(\"align-title\"));\r\n } else {\r\n $(\".call-to-action .button-wrapper\").css(\"float\", \"right\");\r\n }\r\n\r\n if (RotatorImage.attr(\"hastrailer\") == \"false\") {\r\n $(\".call-to-action .poptrailer\").hide();\r\n } else {\r\n $(\".call-to-action .poptrailer\").show();\r\n }\r\n\r\n $(\".call-to-action .btn.blue\").text(RotatorImage.attr(\"btn-title\"));\r\n if ($(\".call-to-action .btn.blue\").text().length == 0) {\r\n $(\".call-to-action .btn.blue\").attr(\"style\", \"display: none;\");\r\n } else {\r\n $(\".call-to-action .btn.blue\").attr(\"style\", \"\");\r\n }\r\n\r\n $(\".call-to-action .btn.blue\").attr(\"data-firstsession\", RotatorImage.attr(\"data-firstsession\"));\r\n $(\".call-to-action .btn.blue\").attr(\"data-lastsession\", RotatorImage.attr(\"data-lastsession\"));\r\n\r\n}", "function setSkin(){\n //read skin files\n skinType = \"regular\";\n}", "function init() {\n body = $('body');\n switcher = $('#bottomBar a.backgroundSwitcher');\n\n backgroundList = $('.backgroundList', switcher);\n activeBackground = $('.activeBackground', switcher);\n\n backgroundList.hide();\n switcher.click(function() {\n backgroundList.fadeToggle(100);\n });\n\n var i,len;\n for(i=0, len = themeNames.length; i < len; i++) {\n backgroundList.append('<a class=\"icon\" rel=\"' + themeNames[i] + '\"> </a>');\n }\n\n backgroundList.delegate('a', 'click', switchBg);\n\n switchBg(null, settings.getString('active_theme', 'one'));\n\n }", "function updateThemeWithAppSkinInfo(appSkinInfo) {\r\n //Update the background color of the panel\r\n var panelBackgroundColor = appSkinInfo.panelBackgroundColor.color;\r\n document.body.bgColor = toHex(panelBackgroundColor);\r\n \r\n document.body.style.color=reverseColor(appSkinInfo.panelBackgroundColor);\r\n\r\n document.styleSheets[0].addRule(\"button.fw\",\"background-color:#\"+document.body.bgColor+\";color:\"+document.body.style.color+\";\");\r\n document.styleSheets[0].addRule(\"button.hw\",\"background-color:#\"+document.body.bgColor+\";color:\"+document.body.style.color+\";\");\r\n document.styleSheets[0].addRule(\"button.qw\",\"background-color:#\"+document.body.bgColor+\";color:\"+document.body.style.color+\";\");\r\n document.styleSheets[0].addRule(\"A\",\"background-color:#\"+document.body.bgColor+\";color:\"+document.body.style.color+\";\");\r\n}", "function study() {\n document.body.style.backgroundImage = \"url('work.jfif')\";\n}", "function setPageBackground() {\n TweenMax.set(page, {backgroundColor: '#000'});\n TweenMax.set(pageContent, {opacity: '1'});\n TweenLite.to(revealContainer, 1, {opacity:'0', ease: Power3.easeOut, onComplete: removeFromDom});\n }", "function stoptDragEffect(){\n $(globalOptions.full_page_content).css(\"background\",genPageBgColor);\n globalSubpageBuild.css({\n background: \"none\",\n borderRadius: \"0px\",\n border: \"none\"\n });\n}//stoptDragEffect", "function animateBackground() {\n\t\tbgStateOn = !bgStateOn;\n\t\tswitch (bgStateOn) {\n\t\tcase true:\n\t\t\t$.alertT10.backgroundImage = \"/images/blueiPadBg.png\";\n\t\t\tbreak;\n\n\t\tcase false:\n\t\t\t$.alertT10.backgroundImage = \"/images/rediPadBg.png\";\n\t\t\tbreak\n\t\t}\n\t}", "function main() {\n landingPageEffects();\n introSlideShow();\n}", "function backgroundFunction() {\n document.body.style.backgroundImage = \"url('images/Teine.gif')\";\n \n}", "function colorBackground() {\r\n\t\r\n\t\t// INIT VEGAS SLIDESHOW PLUGIN\r\n\t\t$(\"body\").append('<div class=\"bg-color\" style=\"background-color:' + option_hero_background_color + '\"></div>');\r\n\t\r\n\t}", "function changeBackground(theme)\n {\n document.body.className = theme ;\n }", "function changeBackground(){\n if($('#town-pressure').html().length > 0){\n var iconCode = $('#town-stats').attr('data-background').substr(0, 2);\n //console.log(imageLinks[iconCode]);\n $('.jumbotron').css(\"background-image\", imageLinks[iconCode]); //imageLinks is hardcoded in index.html.twig\n $('.jumbotron').css(\"background-size\", \"cover\");\n }\n\n }", "function nectarLiquidBGFP() {\r\n\t\t\t\t\t\r\n\t\t\t\t\t$('.nectar-liquid-bg').removeClass('animated-in');\r\n\t\t\t\t\t\r\n\t\t\t\t\tfor (var k = 0; k < $liquidBG_EL.length; k++) {\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tif ($liquidBG_EL[k].animationType == 'displace-filter-fade' && $($liquidBG_EL[k].canvasContainer).parents('.fp-section.active').length > 0) {\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t//add bg to container\r\n\t\t\t\t\t\t\tif ($($liquidBG_EL[k].canvasContainer).find('.image-added-to-stage').length == 0) {\r\n\t\t\t\t\t\t\t\t$liquidBG_EL[k].imgContainer.addChild($liquidBG_EL[k].bg);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t$($liquidBG_EL[k].canvasContainer)\r\n\t\t\t\t\t\t\t\t.find('.nectar-liquid-bg')\r\n\t\t\t\t\t\t\t\t.addClass('image-added-to-stage');\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t$liquidBG_EL[k].animateProps($liquidBG_EL[k]);\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}", "defineSkin(){\n this.skins = [\n 'Assassin',\n 'Beardy',\n 'Chuck',\n 'Fletch',\n 'Gabriel',\n 'Pamela-1',\n 'Pamela-2',\n 'Pamela-3',\n 'Pamela-4',\n 'Pamela-5',\n 'Ducky',\n 'Stumpy',\n 'Truck',\n 'Young',\n 'Buck',\n 'Turbo',\n 'Dummy',\n 'MetalMan',\n 'Commander',\n 'default'\n ]\n // add to change - for _ in meleeSwing1_fullBody and meleeSwing2_fullBody\n this.animations1 = {\n walk: { repeat:true },\n walk2: { repeat:true },\n crouchIdle: { repeat:true },\n crouchWalk: { repeat:true },\n block: { repeat:true },\n hitBig: { repeat:false },\n floorIdle: { repeat:true },\n floorGetUp: { repeat:false },\n meleeSwing1: { repeat:true },\n meleeSwing2: { repeat:true },\n meleeSwing1_fullBody: { repeat:false },\n meleeSwing2_fullBody: { repeat:false },\n hideSword: { repeat:false },\n jump: { repeat:false },\n idleTired: { repeat:true },\n idle: { repeat:true },\n punch1: { repeat:false },\n punch2: { repeat:false },\n roll: { repeat:false },\n run: { repeat:true },\n run2: { repeat:true },\n empty: { repeat:true },\n };\n this.animations2 = [{\n name: 'walk',\n repeat: true\n }, {\n name: 'walk2',\n repeat: true\n }, {\n name: 'crouchIdle',\n repeat: true\n }, {\n name: 'crouchWalk',\n repeat: true\n }, {\n name: 'block',\n repeat: true\n }, {\n name: 'hitBig',\n repeat: false\n }, {\n name: 'floorIdle',\n repeat: true\n }, {\n name: 'floorGetUp',\n repeat: false\n }, {\n name: 'meleeSwing1',\n repeat: false\n }, {\n name: 'meleeSwing2',\n repeat: false\n }, {\n name: 'meleeSwing1-fullBody',\n repeat: false\n }, {\n name: 'meleeSwing2-fullBody',\n repeat: false\n }, {\n name: 'hideSword',\n repeat: false\n }, {\n name: 'jump',\n repeat: false\n }, {\n name: 'idleTired',\n repeat: true\n }, {\n name: 'idle',\n repeat: true\n }, {\n name: 'punch1',\n repeat: false\n }, {\n name: 'punch2',\n repeat: false\n }, {\n name: 'roll',\n repeat: false\n }, {\n name: 'run',\n repeat: true\n }, {\n name: 'run2',\n repeat: true\n }, {\n name: 'empty',\n repeat: true\n }]\n }", "function LIGHT$static_(){ToolbarSkin.LIGHT=( new ToolbarSkin(\"light\"));}", "function imagesh(e, fw) {\n\tif (fw) {\n\t\tif(!Modernizr.csstransitions){\n\t\t\t$('.'+fw).animate({'opacity':1,'filter':'alpha(opacity=100)'}, 500);\n\t\t} else {\n\t\t\t$('.'+fw).addClass('animated');\n\t\t\t$('.'+fw).css('opacity', '1');\n\t\t\t$('body > .fullwidth-section .'+fw).css({\n\t\t\t\t'animation':$('.everything .'+fw).css('animation'),\n\t\t\t\t'-webkit-animation':$('.everything .'+fw).css('-webkit-animation'),\n\t\t\t\t'-moz-animation':$('.everything .'+fw).css('-moz-animation'),\n\t\t\t\t'-ms-animation':$('.everything .'+fw).css('-ms-animation'),\n\t\t\t\t'-o-animation':$('.everything .'+fw).css('-o-animation')\n\t\t\t});\n\t\t\tif (window.BrowserDetect.browser === \"Firefox\" || window.BrowserDetect.browser === \"Explorer\" || window.BrowserDetect.browser === \"Chrome\"){\n\t\t\t\tvar effect = getEffect($('.'+fw));\n\t\t\t\t$('.'+fw).css('animation-name',effect);\n\t\t\t\t$('body > .fullwidth-section .'+fw).css({\n\t\t\t\t\t'animation-delay':$('.everything .'+fw).css('animation-delay'),\n\t\t\t\t\t'-moz-animation-delay':$('.everything .'+fw).css('-moz-animation-delay'),\n\t\t\t\t});\n\t\t\t}\t\n\t\t}\n\t} else {\n\t\t$('.image-sh:not(.shortcode-img)').eq(e).addClass('animated');\n\t}\n}", "function initAF() {\n\t\t// remove conflicting elements\n\t\t$('.wordmark audio, style.AF17, #fegelFlop, #fegelDebug').remove();\n\t\t// add keyframe styles\n\t\tvar keyframeCSS = '\\\n\t\t\t@keyframes bgScrollLeft {\\\n\t\t\t\tfrom {background-position: center right}\\\n\t\t\t\tto {background-position: center left}\\\n\t\t\t} @keyframes bgScrollRight {\\\n\t\t\t\tfrom {background-position: center left}\\\n\t\t\t\tto {background-position: center right}\\\n\t\t\t} @keyframes bgScrollUp {\\\n\t\t\t\tfrom {background-position: bottom center}\\\n\t\t\t\tto {background-position: top center}\\\n\t\t\t} @keyframes bgScrollDown {\\\n\t\t\t\tfrom {background-position: top center}\\\n\t\t\t\tto {background-position: bottom center}\\\n\t\t\t} @keyframes bgZoomIn {\\\n\t\t\t\tfrom {background-size: cover}\\\n\t\t\t\tto {background-size: 130% !important}\\\n\t\t\t} @keyframes bgZoomOut {\\\n\t\t\t\tfrom {background-size: 130% !important}\\\n\t\t\t\tto {background-size: cover}\\\n\t\t\t}';\n\t\t$('<style class=\"AF17\">').text(keyframeCSS).appendTo(document.body);\n\t\t\n\t\t// add FegelFlop\n\t\t$fegelFlop = $('<div>').prop({id: 'fegelFlop'}).css({\n\t\t\tdisplay: 'inline-block',\n\t\t\tbackground: 'url(https://vignette.wikia.nocookie.net/hitlerparody/images/b/b3/FegelFlop.gif)',\n\t\t\tposition: 'fixed',\n\t\t\tleft: '50%', top: '50%',\n\t\t\twidth: '320px', height: '180px',\n\t\t\ttransform: 'translate(-50%, -50%)'\n\t\t}).hide().prependTo('body');\n\t\t$fegelDebug = $('<span>').prop({id:'fegelDebug'}).css({position: 'fixed', left: 0, bottom: '27px', \"z-index\":9000}).hide().appendTo('body');\n\t\t\n\t\t// add audio \n\t\tvar $au = $('<audio>').prop({\n\t\t\t\tid: 'ShootingStars',\n\t\t\t\tcontrols: true,\n\t\t\t\t//src: 'https://vignette.wikia.nocookie.net/communitytest/images/e/e9/AF17.ogg'\n\t\t\t\t src: 'https://vignette.wikia.nocookie.net/hitlerparody/images/e/e9/AF17.ogg/revision/latest'\n\t\t});\n\t\t$au.on('ended', function (e) {\n\t\t\t// when audio ended\n\t\t\t// seek back to 10.96s and play\n\t\t\tthis.currentTime = 10.96;\n\t\t\tthis.play();\n\t\t}).on('pause', function (e) {\n\t\t\t// when paused\n\t\t\t// move back to start\n\t\t\t// animating=false;\n\t\t\tthis.currentTime = 0;\n\t\t}).on('play', function (e) {\n\t\t\t// start playing\n\t\t\t// rmv bg and preload images\n\t\t\tif (this.currentTime > 9) return;\n\t\t\t$('body.skin-oasis').css({ // default bg here\n\t\t\t\t\"background-image\": 'url(https://vignette.wikia.nocookie.net/hitlerparody/images/6/63/AF17_default.png)',\n\t\t\t\t\"background-size\" : 'auto auto',\n\t\t\t\t\"background-repeat\": \"repeat\",\n\t\t\t\t\"animation\" : \"none\"\n\t\t\t});\n\t\t\t$('.wordmark img').get(0).src = 'https://vignette.wikia.nocookie.net/hitlerparody/images/6/6e/Wordmark_blank.png' // blank wordmark here\n\t\t\tanimating = false;\n\t\t\t$fegelFlop.hide();\n\t\t\tpreloadBgs();\n\t\t}).appendTo($('.wordmark'));\n\t\n\t\t// cue track\n\t\tvar track = $au.get(0).addTextTrack('metadata');\n\t\ttrack.mode = 'showing';\n\t\ttrack.default = true;\n\t\tfor (var i=0; i<bgChgCues.length; i++) {\n\t\t\tvar cue = new VTTCue(bgChgCues[i], bgChgCues[i]+0.02, \"\");\n\t\t\tif (i===0) {\n\t\t\t\tcue.onenter = function() { \n\t\t\t\t\trandBg();\n\t\t\t\t\t//console.log('first!')\n\t\t\t\t\tanimating = true;\n\t\t\t\t\tanimate();\n\t\t\t\t\tanimId = setInterval(function () { animate() }, timeStep);\n\t\t\t\t};\n\t\t\t} else {\n\t\t\t\tcue.onenter = function() { randBg(); }\n\t\t\t}\n\t\t\ttrack.addCue(cue);\n\t\t}\n\t}", "function transitionToStarryBackground() {\n\t\t$('.container').removeClass('valign-wrapper');\n\t\tlet imageUrl = 'assets/img/stars.jpg';\n\t\t$('body').css('background', 'url(' + imageUrl + ')');\n\t\t$('body').css('background-size', 'cover');\n\t\t$('body').css('background-position', 'bottom');\n\t\t$('body').css('height', '100vh');\n\t\t$('#intro').remove();\n\t}", "function seven_skin_setup()\n\t\t{\n\t\t\t switch(option.skin)\n\t\t\t {\n\t\t\t\t case 'default':\n\t\t\t\t\t if(option.bullet==null)\t option.bullet=true;\n\t\t\t\t\t if(option.carousel==null)\toption.carousel=false;\n\t\t\t\t break;\n\t\t\t\t case 'round':\n\t\t\t\t\t if(option.bullet==null) option.bullet=true;\n\t\t\t\t\t if(option.carousel==null) option.carousel=false;\n\t\t\t\t break;\n\t\t\t\t case 'sharp':\n\t\t\t\t\t if(option.bullet==null)\toption.bullet=true;\n\t\t\t\t\t if(option.carousel==null) option.carousel=true;\n\t\t\t\t break;\n\t\t\t\t case 'clean':\n\t\t\t\t\t if(option.bullet==null)\toption.bullet=true;\n\t\t\t\t\t if(option.carousel==null) option.carousel=false;\n\t\t\t\t break;\n\t\t\t\t case 'square':\n\t\t\t\t\t if(option.bullet==null) option.bullet=true;\n\t\t\t\t\t if(option.carousel==null) option.carousel=true;\n\t\t\t\t break;\n\t\t\t }\n\t\t\t //initialization for bullet\n\t\t\t if(option.bullet)\n\t\t\t {\n\t\t\t\t\tseven_bullet_setup(handle);\n\t\t\t\t\thandle.find(\".seven_hcarousel\").addClass(\"seven_bullet\");\n\t\t\t }\n\t\t\t \n\t\t\t //initialization for carousel\n\t\t\t if(option.carousel!=false)\n\t\t\t {\n\t\t\t\t seven_carousel_setup(option.carousel,handle);\n\t\t\t }\n\t\t\t \n\t\t\t handle.addClass(\"seven_\"+option.skin);\n\t\t}", "function map_trans_wis() {\n current_background = Graphics[\"background2\"];\n actors.push( new BigText(\"Level 1 Complete\") );\n actors.push( new SubText(\"Hmmm... Gurnok must be close.\", 330) );\n actors.push( new Continue(\"Click to continue!\", map_wizard1) );\n }", "function SetCSS()\n{\n\t$(\"head\").append($(\"<!--Start of IMDB Enhancement v\" + GM.info.script.version + \" CSS-->\"));\n\n\t/*Settings Filled icon by Icons8 */\n\t/* Customizes Settings Filled icon */\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\"div.imdbe_image {width: 40px;height: 40px;background-image: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iaXNvLTg4NTktMSI/Pg0KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjAuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPg0KPHN2ZyB2ZXJzaW9uPSIxLjEiIGlkPSJDYXBhXzEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4Ig0KCSB2aWV3Qm94PSIwIDAgNTEyIDUxMiIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAgNTEyIDUxMjsiIHhtbDpzcGFjZT0icHJlc2VydmUiPg0KPGNpcmNsZSBzdHlsZT0iZmlsbDojRkZENDAwOyIgY3g9IjI1NiIgY3k9IjI1NiIgcj0iMjU2Ii8+DQo8cGF0aCBzdHlsZT0iZmlsbDojRkY5RjAwOyIgZD0iTTUxMiwyNTZjMC01LTAuMTU5LTkuOTYzLTAuNDQyLTE0Ljg5MkwzNjguNzI1LDk4LjI3NUwzNjIsMTE4bC0yMS4yODktMWwtNTIuOTg3LTUzTDY0LDI4Ny43MjQNCglsNTMsNTIuOTg3bDI2LjAwMyw3Mi43NDJsOTguMTA1LDk4LjEwNUMyNDYuMDM3LDUxMS44NDEsMjUxLDUxMiwyNTYsNTEyQzM5Ny4zODUsNTEyLDUxMiwzOTcuMzg1LDUxMiwyNTZ6Ii8+DQo8cGF0aCBzdHlsZT0iZmlsbDojNUE1QTVBOyIgZD0iTTQ0OCwyODcuNzI0di02My40NDlsLTUyLjA1MS0xMC4zNWMtMi45MjQtOS40NS02LjUyNS0xOC40NS0xMS4yNS0yNy4yMjVsMjkuMDI2LTQzLjQyNWwtNDUtNDUNCglMMzI1LjMsMTI3LjMwMWMtOC43NzUtNC43MjUtMTcuNzc2LTguMzI2LTI3LjIyNS0xMS4yNUwyODcuNzI0LDY0aC02My40NDlsLTEwLjM1LDUyLjA1MWMtOS40NSwyLjkyNC0xOC40NSw2LjUyNS0yNy4yMjUsMTEuMjUNCglsLTQzLjQyNS0yOS4wMjZsLTQ1LDQ1bDI5LjAyNiw0My40MjVjLTQuNzI1LDguNzc1LTguMzI2LDE3Ljc3Ni0xMS4yNSwyNy4yMjVMNjQsMjI0LjI3NnY2My40NDlsNTIuMDUxLDEwLjM1DQoJYzIuOTI0LDkuNDUsNi41MjUsMTguNDUsMTEuMjUsMjcuMjI1bC0yOS4wMjYsNDMuNDI1bDQ1LDQ1bDQzLjQyNS0yOS4wMjZjOC43NzUsNC43MjUsMTcuNzc2LDguMzI2LDI3LjIyNSwxMS4yNUwyMjQuMjc2LDQ0OA0KCWg2My40NDlsMTAuMzUtNTIuMDUxYzkuNDUtMi45MjQsMTguNDUtNi41MjUsMjcuMjI1LTExLjI1bDQzLjQyNSwyOS4wMjZsNDUtNDVMMzg0LjY5OSwzMjUuMw0KCWM0LjcyNS04Ljc3NSw4LjMyNi0xNy43NzYsMTEuMjUtMjcuMjI1TDQ0OCwyODcuNzI0eiBNMjU2LDMzNC43NWMtNDMuNDI1LDAtNzguNzUtMzUuMzI1LTc4Ljc1LTc4Ljc1czM1LjMyNS03OC43NSw3OC43NS03OC43NQ0KCXM3OC43NSwzNS4zMjUsNzguNzUsNzguNzVTMjk5LjQyNSwzMzQuNzUsMjU2LDMzNC43NXoiLz4NCjxwYXRoIHN0eWxlPSJmaWxsOiM0NDQ0NDQ7IiBkPSJNMzk1Ljk0OSwyOTguMDc1Yy0yLjkyNCw5LjQ1LTYuNTI1LDE4LjQ1LTExLjI1LDI3LjIyNWwyOS4wMjYsNDMuNDI1bC00NSw0NUwzMjUuMywzODQuNjk5DQoJYy04Ljc3NSw0LjcyNS0xNy43NzYsOC4zMjYtMjcuMjI1LDExLjI1TDI4Ny43MjQsNDQ4SDI1NlYzMzQuNzVjNDMuNDI1LDAsNzguNzUtMzUuMzI1LDc4Ljc1LTc4Ljc1cy0zNS4zMjUtNzguNzUtNzguNzUtNzguNzVWNjQNCgloMzEuNzI0bDEwLjM1LDUyLjA1MWM5LjQ1LDIuOTI0LDE4LjQ1LDYuNTI1LDI3LjIyNSwxMS4yNWw0My40MjUtMjkuMDI2bDQ1LDQ1TDM4NC42OTksMTg2LjcNCgljNC43MjUsOC43NzUsOC4zMjYsMTcuNzc2LDExLjI1LDI3LjIyNUw0NDgsMjI0LjI3NnY2My40NDlMMzk1Ljk0OSwyOTguMDc1eiIvPg0KPGc+DQo8L2c+DQo8Zz4NCjwvZz4NCjxnPg0KPC9nPg0KPGc+DQo8L2c+DQo8Zz4NCjwvZz4NCjxnPg0KPC9nPg0KPGc+DQo8L2c+DQo8Zz4NCjwvZz4NCjxnPg0KPC9nPg0KPGc+DQo8L2c+DQo8Zz4NCjwvZz4NCjxnPg0KPC9nPg0KPGc+DQo8L2c+DQo8Zz4NCjwvZz4NCjxnPg0KPC9nPg0KPC9zdmc+DQo=)}\"));\n\n\t/* Customizes all icons at once */\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\".icon { \\\n\tdisplay: inline-block; \\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\"#imdbe_setbutton { \\\n\tdisplay: inline-flex;\\\n\tcursor: pointer;\\\n\torder: 10;\\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\"#imdbe_settings { \\\n\tposition: fixed;\\\n\tz-index: 500;\\\n\tbackground: #1f1f1f;\\\n\tfont-family: Roboto,Helvetica,Arial,sans-serif;\\\n\tcolor:#dddddd;\\\n\tpadding:10px;\\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\".imdbe_revBarC { \\\n\tfloat:left;\\\n padding-top:11px;\\\n\tpadding-left:15px;\\\n\tpadding-bottom:0px;\\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\"#imdbe_field { \\\n\tpadding-left:15px;\\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\"#imdbe_divtrailer { \\\n\tpadding-left:20px;\\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\"#imdbe_popupDiv { \\\n\tbackground: #1f1f1f;\\\n\tz-index: 500;\\\n\tmax-width: 700px;\\\n\tmin-height: 200px;\\\n\tborder: 2px solid #f5c518;\\\n\tcolor:#bcbcbc;\\\n\t\tpadding:5px;\\\n\t\tdisplay: flex\\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\".imdbe_mode-advanced { \\\n\tfont-size: 14px;\\\n\tpadding: 5px 10px;\\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\".imdbe_lister-item-image { \\\n\tdisplay: inline-block;\\\n\tvertical-align: top;\\\n\tmargin-right: 20px;\\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\".imdbe_lister-item-content { \\\n\tmax-width: 90%;\\\n\tdisplay: inline-block;\\\n\tvertical-align: top;\\\n}\"));\n\n\t$(\"head\").append($(\"<!--End of IMDB Enhancement v\" + GM.info.script.version + \" CSS-->\"));\n}", "function PREVIEW$static_(){ToolbarSkin.PREVIEW=( new ToolbarSkin(\"preview\"));}", "function initThemeJs() {\n\t\t(function($) {\n\n\t\t\t\"use strict\";\n\n\t\t\tskel.breakpoints({\n\t\t\t\txlarge: '(max-width: 1680px)',\n\t\t\t\tlarge: '(max-width: 1280px)',\n\t\t\t\tmedium: '(max-width: 980px)',\n\t\t\t\tsmall: '(max-width: 736px)',\n\t\t\t\txsmall: '(max-width: 480px)'\n\t\t\t});\n\n\t\t\t$(function() {\n\n\t\t\t\tvar $window = $(window),\n\t\t\t\t\t$body = $('body'),\n\t\t\t\t\t$header = $('#header'),\n\t\t\t\t\t$banner = $('#banner');\n\n\t\t\t\t// Disable animations/transitions until the page has loaded.\n\t\t\t\t$body.addClass('is-loading');\n\n\t\t\t\t$window.on('load', function() {\n\t\t\t\t\twindow.setTimeout(function() {\n\t\t\t\t\t\t$body.removeClass('is-loading');\n\t\t\t\t\t}, 100);\n\t\t\t\t});\n\n\t\t\t\t// Fix: Placeholder polyfill.\n\t\t\t\t$('form').placeholder();\n\n\t\t\t\t// Prioritize \"important\" elements on medium.\n\t\t\t\tskel.on('+medium -medium', function() {\n\t\t\t\t\t$.prioritize(\n\t\t\t\t\t\t'.important\\\\28 medium\\\\29',\n\t\t\t\t\t\tskel.breakpoint('medium').active\n\t\t\t\t\t);\n\t\t\t\t});\n\n\t\t\t\t// Header.\n\t\t\t\tif (skel.vars.IEVersion < 9)\n\t\t\t\t\t$header.removeClass('alt');\n\n\t\t\t\tif ($banner.length > 0 &&\n\t\t\t\t\t$header.hasClass('alt')) {\n\n\t\t\t\t\t$window.on('resize', function() {\n\t\t\t\t\t\t$window.trigger('scroll');\n\t\t\t\t\t});\n\n\t\t\t\t\t$banner.scrollex({\n\t\t\t\t\t\tbottom: $header.outerHeight(),\n\t\t\t\t\t\tterminate: function() {\n\t\t\t\t\t\t\t$header.removeClass('alt');\n\t\t\t\t\t\t},\n\t\t\t\t\t\tenter: function() {\n\t\t\t\t\t\t\t$header.addClass('alt');\n\t\t\t\t\t\t},\n\t\t\t\t\t\tleave: function() {\n\t\t\t\t\t\t\t$header.removeClass('alt');\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\n\t\t\t\t}\n\n\t\t\t\t// Menu.\n\t\t\t\tvar $menu = $('#menu');\n\n\t\t\t\t$menu._locked = false;\n\n\t\t\t\t$menu._lock = function() {\n\n\t\t\t\t\tif ($menu._locked)\n\t\t\t\t\t\treturn false;\n\n\t\t\t\t\t$menu._locked = true;\n\n\t\t\t\t\twindow.setTimeout(function() {\n\t\t\t\t\t\t$menu._locked = false;\n\t\t\t\t\t}, 350);\n\n\t\t\t\t\treturn true;\n\n\t\t\t\t};\n\n\t\t\t\t$menu._show = function() {\n\n\t\t\t\t\tif ($menu._lock())\n\t\t\t\t\t\t$body.addClass('is-menu-visible');\n\n\t\t\t\t};\n\n\t\t\t\t$menu._hide = function() {\n\n\t\t\t\t\tif ($menu._lock())\n\t\t\t\t\t\t$body.removeClass('is-menu-visible');\n\n\t\t\t\t};\n\n\t\t\t\t$menu._toggle = function() {\n\n\t\t\t\t\tif ($menu._lock())\n\t\t\t\t\t\t$body.toggleClass('is-menu-visible');\n\n\t\t\t\t};\n\n\t\t\t\t$menu\n\t\t\t\t\t.appendTo($body)\n\t\t\t\t\t.on('click', function(event) {\n\n\t\t\t\t\t\tevent.stopPropagation();\n\n\t\t\t\t\t\t// Hide.\n\t\t\t\t\t\t$menu._hide();\n\n\t\t\t\t\t})\n\t\t\t\t\t.find('.inner')\n\t\t\t\t\t.on('click', '.close', function(event) {\n\n\t\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t\t\tevent.stopImmediatePropagation();\n\n\t\t\t\t\t\t// Hide.\n\t\t\t\t\t\t$menu._hide();\n\n\t\t\t\t\t})\n\t\t\t\t\t.on('click', function(event) {\n\t\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t\t})\n\t\t\t\t\t.on('click', 'a', function(event) {\n\n\t\t\t\t\t\tvar href = $(this).attr('href');\n\n\t\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\t\tevent.stopPropagation();\n\n\t\t\t\t\t\t// Hide.\n\t\t\t\t\t\t$menu._hide();\n\n\t\t\t\t\t\t// Redirect.\n\t\t\t\t\t\twindow.setTimeout(function() {\n\t\t\t\t\t\t\twindow.location.href = href;\n\t\t\t\t\t\t}, 350);\n\n\t\t\t\t\t});\n\n\t\t\t\t$body\n\t\t\t\t\t.on('click', 'a[href=\"#menu\"]', function(event) {\n\n\t\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t\t\tevent.preventDefault();\n\n\t\t\t\t\t\t// Toggle.\n\t\t\t\t\t\t$menu._toggle();\n\n\t\t\t\t\t})\n\t\t\t\t\t.on('keydown', function(event) {\n\n\t\t\t\t\t\t// Hide on escape.\n\t\t\t\t\t\tif (event.keyCode == 27)\n\t\t\t\t\t\t\t$menu._hide();\n\n\t\t\t\t\t});\n\t\t\t});\n\t\t})(jQuery);\n\t}", "function init_css()\r\n{\r\n\tGM_addStyle(\r\n\t\r\n\t\t'@import url(http://fonts.googleapis.com/css?family=Merienda:700);'+\r\n\t\t\r\n\t\t'*.btn-tumblr_no-older { '+\r\n\t\t'top:130px; !important;'+\r\n\t\t'left:50px;!important;'+\r\n\t\t'display: block !important;'+\r\n\t\t'position: fixed !important;'+\r\n\t\t'float: none !important;'+\r\n\t\t'}'+\r\n\t\t\r\n\t\t'*.btn-tumblr_no-newer { '+\r\n\t\t'top:130px !important;'+\r\n\t\t'left:145px !important;'+\r\n\t\t'display: block !important;'+\r\n\t\t'position: fixed !important;'+\r\n\t\t'float: none !important;'+\r\n\t\t'}'+\r\n\t\t\r\n\t\t'.thoughtbot a:link { color: #fff!important; text-decoration: none !important; background: none !important;}'+\r\n\t\t'.thoughtbot a:hover { color: #fff !important; text-decoration: none !important; background: none !important;}'+\r\n\t\t'.thoughtbot a:active { color: #fff !important; text-decoration: none !important; background: none !important;}'+\r\n\t\t'.thoughtbot a:visited { color: #fff !important; text-decoration: none !important; background: none !important;}'+\r\n\t\t\r\n\t\t'.thoughtbot {'+\r\n\t\t'background-color: #ee432e;'+\r\n\t\t'background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #ee432e), color-stop(50%, #c63929), color-stop(50%, #b51700), color-stop(100%, #891100));'+\r\n\t\t'background-image: -webkit-linear-gradient(top, #ee432e 0%, #c63929 50%, #b51700 50%, #891100 100%);'+\r\n\t\t'background-image: -moz-linear-gradient(top, #ee432e 0%, #c63929 50%, #b51700 50%, #891100 100%);'+\r\n\t\t'background-image: -ms-linear-gradient(top, #ee432e 0%, #c63929 50%, #b51700 50%, #891100 100%);'+\r\n\t\t'background-image: -o-linear-gradient(top, #ee432e 0%, #c63929 50%, #b51700 50%, #891100 100%);'+\r\n\t\t'background-image: linear-gradient(top, #ee432e 0%, #c63929 50%, #b51700 50%, #891100 100%);'+\r\n\t\t'border: 1px solid #951100;'+\r\n\t\t'border-radius: 5px;'+\r\n\t\t'-webkit-box-shadow: inset 0px 0px 0px 1px rgba(255, 115, 100, 0.4), 0 1px 3px #333333;'+\r\n\t\t'box-shadow: inset 0px 0px 0px 1px rgba(255, 115, 100, 0.4), 0 1px 3px #333333;'+\r\n\t\t'color: #fff !important;'+\r\n\t\t'font-size: 24px !important;'+\r\n\t\t'font-family: \"Merienda\", cursive !important;'+\r\n\t\t'padding: 12px 0 14px 0 !important;'+\r\n\t\t'margin: 0 !important;'+\r\n\t\t'text-align: center !important;'+\r\n\t\t'text-shadow: 0 -1px 1px rgba(19,65,88,.8);'+\r\n\t\t'line-height: 100% !important;'+\r\n\t\t'width: 90px !important; }'+\r\n\t\t \r\n\t\t'.thoughtbot:hover {'+\r\n\t\t\t'background-color: #f37873;'+\r\n\t\t\t'background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #f37873), color-stop(50%, #db504d), color-stop(50%, #cb0500), color-stop(100%, #a20601));'+\r\n\t\t\t'background-image: -webkit-linear-gradient(top, #f37873 0%, #db504d 50%, #cb0500 50%, #a20601 100%);'+\r\n\t\t\t'background-image: -moz-linear-gradient(top, #f37873 0%, #db504d 50%, #cb0500 50%, #a20601 100%);'+\r\n\t\t\t'background-image: -ms-linear-gradient(top, #f37873 0%, #db504d 50%, #cb0500 50%, #a20601 100%);'+\r\n\t\t\t'background-image: -o-linear-gradient(top, #f37873 0%, #db504d 50%, #cb0500 50%, #a20601 100%);'+\r\n\t\t\t'background-image: linear-gradient(top, #f37873 0%, #db504d 50%, #cb0500 50%, #a20601 100%);'+\r\n\t\t\t'cursor: pointer; }'+\r\n\t\t\t\r\n\t\t'.thoughtbot:active {'+\r\n\t\t\t'background-color: #d43c28;'+\r\n\t\t\t'background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #d43c28), color-stop(50%, #ad3224), color-stop(50%, #9c1500), color-stop(100%, #700d00));'+\r\n\t\t\t'background-image: -webkit-linear-gradient(top, #d43c28 0%, #ad3224 50%, #9c1500 50%, #700d00 100%);'+\r\n\t\t\t'background-image: -moz-linear-gradient(top, #d43c28 0%, #ad3224 50%, #9c1500 50%, #700d00 100%);'+\r\n\t\t\t'background-image: -ms-linear-gradient(top, #d43c28 0%, #ad3224 50%, #9c1500 50%, #700d00 100%);'+\r\n\t\t\t'background-image: -o-linear-gradient(top, #d43c28 0%, #ad3224 50%, #9c1500 50%, #700d00 100%);'+\r\n\t\t\t'background-image: linear-gradient(top, #d43c28 0%, #ad3224 50%, #9c1500 50%, #700d00 100%);'+\r\n\t\t\t'-webkit-box-shadow: inset 0px 0px 0px 1px rgba(255, 115, 100, 0.4);'+\r\n\t\t\t'box-shadow: inset 0px 0px 0px 1px rgba(255, 115, 100, 0.4); }'\r\n\t);\r\n}", "function WORKAREA$static_(){ToolbarSkin.WORKAREA=( new ToolbarSkin(\"workarea\"));}", "function onThemeChange() {\n var info = apiHandle.themeBackgroundInfo;\n if (!info)\n return;\n var background = [info.colorRgba,\n info.imageUrl,\n info.imageTiling,\n info.imageHorizontalAlignment,\n info.imageVerticalAlignment].join(' ').trim();\n document.body.style.background = background;\n var isCustom = !!background && WHITE.indexOf(background) == -1;\n document.body.classList.toggle('custom-theme', isCustom);\n updateAttribution(info.attributionUrl);\n}", "function updateSettings(){\n document.documentElement.style.setProperty(`--accent`, settings.accentColor);\n document.documentElement.style.setProperty(`--bg-color`, settings.bgColor );\n if(settings.bgHidden == 'false'){\n document.documentElement.style.setProperty(`--bg-image`, `url(${settings.bgImage})` );\n }else{\n document.documentElement.style.setProperty(`--bg-image`, `url('')` );\n\n }\n\n}", "function init_wowanimation()\n {\n var wow = new WOW(\n {\n mobile: false\n });\n wow.init();\n }", "function playTheme() {\n themeSong.play();\n}", "function background(param)\n{\n novel_changeBackground(param, false);\n}", "function domEffects(){\n charSelectedAudio.play();\n body.style.backgroundPosition = 'center';\n body.style.backgroundSize = 'cover';\n body.style.backgroundAttachment = 'fixed';\n arenaName.style.color = 'yellow';\n}", "function sunnyjar_theme_sc_init(cont) {\n\t\"use strict\";\n\t// Put here your theme-specific code to init shortcodes\n\t// It will be called before core init shortcodes\n\t// @param cont - jQuery-container with shortcodes (init only inside this container)\n}", "function homeAnim() { //homepage animation on load \n qsCl(\"home__logo-fill\").left = '-177px';\n qsCl(\"home__logo-dolya\").color = 'black';\n qsCl(\"home__logo-consulting\").color = 'black';\n qsCl(\"home__logo-frame\").opacity = '1';\n qsCl(\"home__tagline-line\").width = '60px';\n qsCl(\"home__mission-statement\").color = '#303030';\n qsCl(\"home__tagline\").color = '#303030';\n qsCl(\"home__golden-thread\").color = 'var(--gold)';\n qsCl(\"path-logo\").animation = 'dash 3s ease-in forwards 1s'\n qsCl(\"path-home\").animation = 'dash 5s ease-in-out forwards 4s';\n drawn.home = true;\n}", "function clock() {\n document.body.style.backgroundImage = \"url('clock.jpg')\";\n}", "function aliceBG () {\n\n aliceBGInterval = setInterval( function() {\n\n $(\"body\").animate({\n backgroundColor: '#333',\n }, 1250);\n\n setTimeout( function() {\n $(\"body\").animate({\n backgroundColor: '#665F5C',\n }, 750);\n }, 2250);\n\n }, 3000);\n }", "function SarahLoadBackground() {\n\tSarahBackground = \"SarahBedroom0\";\n\tSarahBackground = \"SarahBedroom\" + (SarahCharacter.length - 2).toString();\n\tif (!SarahInside || (Sarah == null) || !Sarah.IsKneeling()) SarahBackground = \"SarahBedroom3\";\n}", "function myFunction(screeziz) {\n if (screenziz.matches) { // If media query matches\n //document.body.style.backgroundColor = \"yellow\";\n document.body.style.backgroundImage = null;\n document.body.style.backgroundColor = '#1d212b';\n randomImage.style.animation = \"superstill 0s linear infinite\";\n } else {\n //document.body.style.backgroundColor = \"pink\";\n var images = [];\n function preload() {\n for (var i = 0; i < arguments.length; i++) {\n images[i] = new Image();\n images[i].url = preload.arguments[i];\n }\n }\n\n //-- usage --//\n preload(\n \"img/penguin.png\",\n \"img/arsotzdragon.gif\",\n \"img/penguin.png\"\n )\n }\n }", "function setBG () {\n document.body.style.backgroundImage = \"url('venice.jpg')\"\n document.body.setAttribute('class','questionBG');\n}", "function enterSettings()\n{\n\t_canvas.style.backgroundImage = \"url(images/background.png)\";\n}", "function pano2vrSkin(player,base) {\n\tplayer.addVariable('vis_image_popup', 2, false);\n\tplayer.addVariable('category_visible', 2, false);\n\tplayer.addVariable('node_visible', 2, false);\n\tvar me=this;\n\tvar skin=this;\n\tvar flag=false;\n\tvar hotspotTemplates={};\n\tvar skinKeyPressed = 0;\n\tthis.player=player;\n\tthis.player.skinObj=this;\n\tthis.divSkin=player.divSkin;\n\tthis.ggUserdata=player.userdata;\n\tthis.lastSize={ w: -1,h: -1 };\n\tvar basePath=\"\";\n\t// auto detect base path\n\tif (base=='?') {\n\t\tvar scripts = document.getElementsByTagName('script');\n\t\tfor(var i=0;i<scripts.length;i++) {\n\t\t\tvar src=scripts[i].src;\n\t\t\tif (src.indexOf('skin.js')>=0) {\n\t\t\t\tvar p=src.lastIndexOf('/');\n\t\t\t\tif (p>=0) {\n\t\t\t\t\tbasePath=src.substr(0,p+1);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t} else\n\tif (base) {\n\t\tbasePath=base;\n\t}\n\tthis.elementMouseDown=[];\n\tthis.elementMouseOver=[];\n\tvar cssPrefix='';\n\tvar domTransition='transition';\n\tvar domTransform='transform';\n\tvar prefixes='Webkit,Moz,O,ms,Ms'.split(',');\n\tvar i;\n\tvar hs,el,els,elo,ela,elHorScrollFg,elHorScrollBg,elVertScrollFg,elVertScrollBg,elCornerBg;\n\tif (typeof document.body.style['transform'] == 'undefined') {\n\t\tfor(var i=0;i<prefixes.length;i++) {\n\t\t\tif (typeof document.body.style[prefixes[i] + 'Transform'] !== 'undefined') {\n\t\t\t\tcssPrefix='-' + prefixes[i].toLowerCase() + '-';\n\t\t\t\tdomTransition=prefixes[i] + 'Transition';\n\t\t\t\tdomTransform=prefixes[i] + 'Transform';\n\t\t\t}\n\t\t}\n\t}\n\t\n\tplayer.setMargins(0,0,0,0);\n\t\n\tthis.updateSize=function(startElement) {\n\t\tvar stack=[];\n\t\tstack.push(startElement);\n\t\twhile(stack.length>0) {\n\t\t\tvar e=stack.pop();\n\t\t\tif (e.ggUpdatePosition) {\n\t\t\t\te.ggUpdatePosition();\n\t\t\t}\n\t\t\tif (e.hasChildNodes()) {\n\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\t\n\tthis.callNodeChange=function(startElement) {\n\t\tvar stack=[];\n\t\tstack.push(startElement);\n\t\twhile(stack.length>0) {\n\t\t\tvar e=stack.pop();\n\t\t\tif (e.ggNodeChange) {\n\t\t\t\te.ggNodeChange();\n\t\t\t}\n\t\t\tif (e.hasChildNodes()) {\n\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tplayer.addListener('changenode', function() { me.ggUserdata=player.userdata; me.callNodeChange(me.divSkin); });\n\t\n\tvar parameterToTransform=function(p) {\n\t\tvar hs='translate(' + p.rx + 'px,' + p.ry + 'px) rotate(' + p.a + 'deg) scale(' + p.sx + ',' + p.sy + ')';\n\t\treturn hs;\n\t}\n\t\n\tthis.findElements=function(id,regex) {\n\t\tvar r=[];\n\t\tvar stack=[];\n\t\tvar pat=new RegExp(id,'');\n\t\tstack.push(me.divSkin);\n\t\twhile(stack.length>0) {\n\t\t\tvar e=stack.pop();\n\t\t\tif (regex) {\n\t\t\t\tif (pat.test(e.ggId)) r.push(e);\n\t\t\t} else {\n\t\t\t\tif (e.ggId==id) r.push(e);\n\t\t\t}\n\t\t\tif (e.hasChildNodes()) {\n\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn r;\n\t}\n\t\n\tthis.addSkin=function() {\n\t\tvar hs='';\n\t\tthis.ggCurrentTime=new Date().getTime();\n\t\tel=me.__menu=document.createElement('div');\n\t\tel.ggId=\" Menu\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='bottom : 0px;';\n\t\ths+='height : 100%;';\n\t\ths+='position : absolute;';\n\t\ths+='right : 0px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 30%;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='100% 100%';\n\t\tme.__menu.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme.__menu.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._rectangle_1=document.createElement('div');\n\t\tel.ggId=\"Rectangle 1\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_rectangle \";\n\t\tel.ggType='rectangle';\n\t\ths ='';\n\t\ths+='background : rgba(0,0,0,0.666667);';\n\t\ths+='border : 1px solid #000000;';\n\t\ths+='cursor : default;';\n\t\ths+='height : 100%;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 100%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='100% 50%';\n\t\tme._rectangle_1.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._rectangle_1.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._rectangle_1);\n\t\tel=me._image_16=document.createElement('div');\n\t\tels=me._image_16__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_16';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHIAAABXCAYAAADYvBH4AAAHSUlEQVR4nO2ca2xbVx3Af/dev908mjhN29QlTVmyFLp2g0mLk4pOGqCtIDXt0AAhBBIfQAKNbkJCCGmahJAmCgO+AR9AY0g8Ji0TW9HWjaKpXDM2dY1AfSBWsqRd2zVp86jzsn0PH2zf3HvtNLabxN7R+Ult73n/fX8+595aOkdjBfoSiU6gc6V6ijXndNI0J5cr1Epl9iUS+4FHgYNrFJSiOkaAIeBnSdMccRa4RPYlEs3Ar1EC651J4EjSNH9TyDAKF3mJJ4D96x6WolJCwMF4PN58cWzsZXDMyL5E4nlKzEQjHCWytQsBOP6iRDJ/KeyEoyiXJUrU9FQS7op4mrhHL2OMW8ZZ1Kc3buHp0zvOSnGuzr3QM/OEbl4uDiLHYNI0h3xgPxNdEoMt7e'+\n\t\t\t'x45Nts2PlRhCD/RyDI/ytELs9O5wa1BIh85JYo3AhRoj0l+7D7Bk+dpfLy+i4Rb+EGVt2nN15vvQripbJ7oKfnaLlo0jbyV6/Ip4EhAyAejz8N3OmU+JHHfk6ofdty34JlEctcrzZr0Xc9x2vpflLNO0gHm2mcOOssao7H48N6PuGajV1fOIIvHL3NoRVrwY3N93Cj/W5v9if0vkRirzPHCEdp3Ll7/SJTVMx0rNebtVcHmp050Y6udQtIUR1ZX6goTy9RT/EBRImUBCVSEpRISVAiJUGJlAQlUhKUSElQIiVBiZQEJVISlEhJUCIlQYmUBCVSEpRISVAiJUGJlAQlUhKUSElQIiVBiZQEJVISlEhJUCIlQYmUBCVSEpRISfDVYlBrfpaFKyP2htjA9l2u8sWxswhAb4yhN8QQCynS778LgNYQw5qfxVpIgQA9FodA'+\n\t\t\t'xNU++9753GbWQARtQytiYnRpMy4sbQ8WwOZuWJyDiTE0BCLaCtGWsj+L79p/cxt8/WHSTR1V35PbpSYiF6+OcPXZJ+106+HHCd3xcTt9/fc/ACCaOESk7xCZa6NM/+mHAITvG0RviJE6/isAgvu+SGDPp+y2YmaCxReeAkDv6cfo7ifz5x+VjEMDxFd/gXZ9DP3lnwCQ3fMZsnc9tOJn0BbniLz5LP5L/wIg3fZhpvZ9s9xbsOrUxdI69eozWPOzZdf37/yYfZ0+e9JVlv3fKfva6O53lWmtcbQtPbClB7Z052ZjFRg3LrLh+FO2xHqgJjPSS2bqGjff+gsN/YfLqq8FIwR2DbB45iTW+CjWzDjahtZcX+f+nqvTEEPf2oP13vmldvc9kpPo2MdfzZ7w0D9/h566jvCHEYEweup65Z2sMjWfkf72TgBmTj5H+v2Rst'+\n\t\t\t'sFevfZ15kLuVkopsexxkcBMO56oLjRxBhcPg+X/wNXzufSVTA38DUybXcwfeAJrEj5z9O1pOYimwYextfUBsD0a78tu53RcSd6YwyA7KVzAGScy2rPQFEb6x9/wHrpKOLYUTj2Y7Q3/lhVzFa0ldT930L4w1W1XwtqLlIPRWh64MsALIyeYe7fr5fd1p+flZkLpxCLs/ayauy4G83zJgslnpGt8VX4BPVBXTwjw933Ety+i4XRM0y/9kzZ7QK9Ayy88TwA6eHjS8tqidkIq/eMrEdqPiMLbDzwdfRgBGuh/LdXvTGGryN3PFB6+BUg95Jj7Cg6vkR66mJGAhhNbUTvfYiZk89V1M7fO0Dm0jlE/gtwK4nWS0ddaQ3gwcddk9IYfhFj+EU7nd59gPTuByuKqRbUzYwEaOg/jJF/8SkXX9c9aMGl56F/zydXO6wPBDWZ'+\n\t\t\t'kYH2Ttq/9AQCgX9Tp6us9fPfJzN1zf6JDsDXtp3Gz30PyC2dTrRghPDgdxHzKUS+3HkIoNYax/fZ77h+onOdBdeyDSEg++nH7Gem/QueEFgr/Fw3u+cQ2uIsVo3fYGsiUg9FCH1ol+tAvQJGUxt6Y8x1oJ4WjOKP97oO6XNixLa7DgB0EYzk3lTtQ/0KHYNtTQjY3G239R4WWPJ4yDzZ5g5Hvervye1SV0uronqUSElQIiVBiZQEJVISlEhJUCIlQYmUBCVSEpRISVAiJUGJlAQlUhKUSElQIiVBiZQEJVISlEhJUCIlQYmUBCVSEpRISVAiJUGJlAQlUhKUSElQIiVBByadGalLF2oUiqJcjMx8UZ6eNM3TzozsXIrpd+rn2BFFMY3jZ71ZI4WldciZ++7QL8nMpdYlKEVlbLxyio1X3/Zmv2AAxOPxq8BXCrnpmR'+\n\t\t\t'tMnTtFeNM2Ai2bKhpILHO92qxF3/Ucr5GZIzb6OpvfOeYtGkma5je0QqovkTgB7C/qIBwlsrXLsf9vKSTvnkDhDLnEOQtL2wwdNT2VvPsRPU3co5cxxi3jLOrTG7djT2XJcVaKc3XuhZ6ZJ3TzcnEQOQaTpjnk3Og6CJwA9jprZedSzEj+zNRWSNcxP02a5hA4/vuRNM1J4H7gbzUKSlEZR5KmeaSQKPnl60sk9gOPAgfXKShFeUySezF9MmmaI86CFVeRvkRiL9C8NnEpKuB0ftUsyf8BmoBIdgY9qTQAAAAASUVORK5CYII=';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 16\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 9.78261%;';\n\t\ths+='left : 11.8056%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 87.1739%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 20.3125%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_16.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_16.onclick=function (e) {\n\t\t\tplayer.openNext(\"{node89}\",\"\");\n\t\t}\n\t\tme._image_16.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._image_16);\n\t\tel=me._image_17=document.createElement('div');\n\t\tels=me._image_17__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_17';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAL8AAABXCAYAAABV/ZTpAAAJiUlEQVR4nO2dP2wbRxbGPyUpDp7GKbidgN16t3AaCmLlZRsauGu8KZJcxO4ACQguhd3YQMhGKnI+gAIu11C5zmvAdiG6uIajADEFsTkVZHHVLpCrho2bcePirljOaHa5pKSLSFua9wMMeGdnd0bEN2/evPmzaziHzVrNBeCel48gPjSOB4OjRffXyhI3a7W7AP4I4PcAbl9xnQhilZwC+AeAn44HgzfmjRnxb9ZqTwB8u6KKEcSqSAH84XgwOFUJOfFv1moHAL5ZbZ0IYmW8ARCqBqDFv8jiB4G/mqoRxBUhxARCiLJbbwB4x4PBm08APajNCZ8xhmZzC/UwXHpFCWIZCCHQ7R7gZDg0k28DeAJgaw2YtfqMMbRbLXieu7qaEsSS6HT20ee8mPzpR9'+\n\t\t\t'P/3DVT7zUaJHzixtBsboExVky+q8R/x0wNw7urqBNBrATGGDaq1WLynY/KMjuOs/waEcQKKdN0qfgJwgZI/IS1kPgJayHxE9ZC4ieshcRPWAuJn7AWEj9hLSR+wlpI/IS1kPgJayHxE9ZC4ieshcRPWAuJn7AWEj9hLZ+87wpcJ6SU2N3bAwA0t5q01fOaQ5b/EnQ6+xiNxgjDkIR/AyDLf0GklGjcayCKIhL+DcE68Y/GY8RxDACoVqu412jk7ne7B0jSBADQbrV0eq/3CqPxCACws709syf00ePHAADP9dBsbl26rOZWE92Drv6/57kz+dS7+5yDT4/iOM/92t3dg3wrwW4xPHz4YMEvYx/WiT/wfewmKaSUEGKSE6SUEoe9HgDkdvsLIfB0KmIgawhK4IrRaPybypJvpX6HfCtz70nSJPf+iZjMzWvS5zx3YNPJ'+\n\t\t\t'cFh2ioG1WOnzKwEIIZAkqU43hRLWz06q4/wo93zJAUhXVtZVwgv15P2L19sGrBR/w7DApkCGJ5kgHcfJWUgldnV0o5Tywg3gsmVdFUII3Tuoep8Mh/POr7QSK8Xvea72k5UfL6XU1tg8n7TPuRZMFN3Xh/b2pi7LVZZ1lcTxMwBZ4zJPLOv1Xi2lvOuIleIHgHAquiRJIYTIuyHGiXXKWgeBD8dxcs+ZbsxVlHVVFBuXeWLZZVy2m4614jct7slwqN0QJXIgE6s50IzjZ0gNwV/U+l+krKukzzmkzAbCQgjE8TN9fRmX7aZjrfhNa8iNqEhoCNUU92g0xtM41hEaIC+y31qWybgQORJicpE/yaj3mWvT5xxP4zjX21y00d50rAt1moT1ECfDoXZfGGO5Qa0SjOM4cJyKfk5KqZ/pc54LYQox0f42AFScCuphuLAsIA'+\n\t\t\t'uLMsZ0CLTiVOA4DnqHPT3mCPxg5m/gfZ5rLBWnovN7nps7nVh9sEG5bJ7nXubnunFYLf6NalULTl0rTKvebG7NRGS+/OprSCnR670qiD8/JxAEPuphuLAsRbO5hU5nH1JKdDr7uXue56LR+HzmmaILY4q93WrlrpMkxZ+/+w5AZv13drZnfxSLsFr8QBbBGU4tvBmWTJMUQeCD3So93jr3XDLNW4bneueWpaiHobb2qtdRLpMZsak4lXM/FRX4wcyZ9J7noh6GEBMBMaGQp/oyy3/NxJcvnr+f2hDEkojjZ7keGcD31g54CcJ6t2cVCCEgJlnEJvDpy5YfCmT5V8Du3h4ePXpMSws+MEj8S6bPORhj2NnZps+6fmBY5/aMxrNLjxWeexYXF0KA8yMIIcAYg+u5OlxpujFFnEoFjDEkaZpdOw6iKMqVHfh+NlcwzWPC'+\n\t\t\t'brFc/D1JUr1suegyqaUS6XTZtOd5qFarpfF7VbZTqdA316ZYJ/5Hjx7PvddutxD4Pvqcz8TZASB2HLRb34Pzo2LkQPNFFMEP/IXlvHzxHEmazs0TBD4ePngAxhi6B129xMKMwnW7B7nZZiBbOvE0jlEPw1wM3/x7HMfB33/829y62YR14lcUZ22BzOpKKdHtHug89TDUFjbwZ9fieF5+FrVSeGfxfhkqj5o5Ho3G6HT25+68KgpfxfyTaQ/gF+YAzOUMQgiMxmMaeMNi8dfDEFF0fyZ9NB7rWdgouq/99EiIUneh2WzOCMl0rcruL3qH+lq4uRbHRAihhc8YQ7vV0m6OlBKj8Tg3KWeuPlUNjPc5iR8Wi19ZQJPA9+FUziy3WqOzUa3+335ykiS566JPP1Ov6czrvPLMXWXN5lbuXWUfW1ZW3/NchGGIbvcAfc4RRf'+\n\t\t\t'et9/2tFX+f85l1MS9fPNeujtrE0unso4Ospyj7jH3Rb2+3W7lr5UIpgsDPbYzP8nSzQfLUbQHmb3IxG9N54jWXL4dhiPpU/EDWiMp6PpuwVvxlPr9iZ2cbfuBjeDLU7kefcyRpgr/88MOlyvG8vM9vrvVRmJtiGGNoNrfmiv+88YOJubTZ3NRyMhxq628z1op/ns9v3q+HoT6lbTQaZ4PRgquUuR5ngvZcNxfCvIjP3263MJ7uF5BSLrTorucC0w5rPFo8cDV7ti+/+jp3TwiBPudWzz3QJFcJfc5zg8R5m04AwPM8BL6v/13GMps0Gp/rZ7vd7tx8pk9/2OvlBsbKTVN7Ec6bUS6e7mAb1lr+p3E8E6v/IopQcSo6Jq4mtczlxYHvz+y0WkRZLL84LlDvjqL72QFVSYo4flbaMzmOg52dbS3y3d09OI4Dxm7pBpuk'+\n\t\t\t'iW5IjM0eVqWWTI9GY4g5USwbIMtfIBsLZGJQvrGUUocVl8m9RkOXfdjrzbXcahLLnI02e6qN6oaeGNuoVnM9U+D7aNw720tg7jqzDevW8y9a3mBO/atlA0A2caV6ASC/StNcEqGYt3RB4bkuAOg8xWUV6t1OpQIp385d3qDcm8l0j6+qp5RyYf3M3+G80OtNoWw9v3XiJ+yENrMQhAGJn7AWEj9hLSR+wlpI/IS1kPgJayHxE9ZC4ieshcRPWAuJn7AWEj9hLSR+wlpI/IS1kPgJayHxE9ZC4ieshcRPWAuJn7AWEj9hLSR+wlpKxX+Rr4oTxHWi7BgYJf5TM9E845EgrjvqiJcCp0r8R2bqYa+XOzyVIK4z3e5BmTdz9DEArK+v/xvAtyr13bt3+OX1a9z+9HbuEFaCuE6os0t/ef26eOun48EgXlNXm7XaExgNwO'+\n\t\t\t'S8T90TxIeGEJN5xz2+AfDZ8WCQrpmpm7XavwDcWUXlCOI9ER4PBkdAIdpzPBh8BuCvq68PQSydFJnFP1IJHxdz/OfXX/+5vr7+8/TSBfC75deLIJbGKYA9AH86HgxS88ZaaXaDzVrNRdYICOJaYVr5Mv4HDiqkHRP638IAAAAASUVORK5CYII=';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 17\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 9.67391%;';\n\t\ths+='left : 34.7222%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 87.1739%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 27.2569%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_17.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_17.onclick=function (e) {\n\t\t\tplayer.openNext(\"{node89}\",\"\");\n\t\t}\n\t\tme._image_17.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._image_17);\n\t\tel=me._image_18=document.createElement('div');\n\t\tels=me._image_18__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_18';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHIAAABXCAYAAADYvBH4AAAGWElEQVR4nO2cTW8bRRiAn9m1naRuIdDGtBS3SYECSgQFpEB8Ic6BU5BokQgHEIQzFfwAUoQ4wAUhLkhcknDkgop6A4ShSGsSRNVKCRJQmiBK1aZfbsFx6o9dDhuv1x+NnbS13eF9Tpn3ndl9V09mdtbSLghaoGoFh2KxYeBVYBjobV45Qh2OA58B00nLSvkTZSKHYrFu4B3grebVJmyAFDCetKzDxYAnclViAtjXgsKEjTGetKxpAMMX/AiReLsxtXobJADePfE1f4+wbTKe2sVweltp3qrVP3xt5bVV7X5lY/x91hhTbNfIqXpjbui85f3UdXMNHLuR6/ONUf54jT5LhWWOLJ/kyPJJKpgC+kyAaDT6EfBwMRO2TT458yh7s+G6xYjI5ogMG0Ge6N'+\n\t\t\t'xOxAwzc+0MPrqj0eiJ4tL6vD8zfnkXYdtEaD9GunYzEOqpDD9jDMVivZXR4X+3NqUoYWOMbNpdGdpnUPGc2L+ypVn1CBskYm6qihk1+gm3ISJSE0SkJohITRCRmiAiNUFEaoKI1AQRqQkiUhNEpCaISE0QkZogIjVBRGqCiNQEEakJIlITRKQmiEhNEJGaICI1QURqgojUBBGpCSJSE0SkJohITQi0uoDbmQX7KnP2JcIqyIC5lYjqalktLRE5H7zCoS1zXvvDfx6n197stV+44wcAxrK7eTG7m3kjxaGuE24s1wsKPg8sAnAw9whxe7s3Nq3yvBI8CsCg08NzdpQJ89h1a/mCZ5nnMhP2T+7xjQcYU/evWX+aHB9kjzFnXyyLPxfs4/VQf52rvzW0xdI62XVqXf3j+ZK4GfN8WW5WldpPOVUvhN4U/BIHjK2EVRCA'+\n\t\t\t'I7kFvs2fviXnrEdbLK3zgSskQueIZ+9pqH/E6WTA7mbOSDFrXCBNnvDqpcwYFwAIEyBu72BeXfbGvec8ST93UfZK+DpZcjKexJeCDzIW2EuaHC9nvgJgtnCWkeB9Gzv4DdDyGRl2XAFTnadIq3zD4/yzctZ05aXJM2u4MzJu77iJVZaIqC4+7YjzXuhpRs3eqnyY4C05bz1aLnI8s4ewEyCt8kytY4mNF7Z7/wRzq7OuKBFg1N5VNWZC/cwB9Q0H1Ncc4GsO8fOGao6oLgaMu70ldTL3S6muFsxGaAOREbuD0Wv3ApAInmM+cKXhsYP2NqA0I4vLap+zmQidN7nSatJOjolrP3r3xYMdjzFgtOb7C21xj3xxZReJ0BJLxgqTHX80PG40fx8J8yxp8iTMs96MHLWjNfvfjHtkkTQ5JrIzLNhXAVfiSKA1sxHaYEYWeS'+\n\t\t\t'OzF4BFM93wmD5nCxHHnXmfmwuAu8kZtG/NbrXIgnPVkxhWQQ6GHmPEbJ1EaJMZCdCfv5N49h4SoXPrGjdaiDIZ+J0ltQLAoN3j7WArmVS/VeXGS9+JAiBh/828uuS148ZORsydZX0msjOknRzg/uMkCqdJFNzltc+4g9c7mv8s2TYiAcZX9jAbvLiu3etgYRuTgd+99sgau9UF/qmKLVN+riUyLDkZrz3A3VVjihLBfRxZKmSq+jSblojsKXQytuLuKnvs0qYk7AR4I7PXXV4V9Be63T5Op/uLDjBgd5cdK+J0cjD/iDcj++3usvtfD12MOXvKC1DKl3fP7/2a48spoF9Vi3wp8CBlnSh9aqxHVX8Dpxmo1Q8KJoqB/pUtvHvuoYa/pybfomvOt+j87bnced6+eBQf37XNZke4MUSkJohITRCRmiAiNUFEaoKI1AQR'+\n\t\t\t'qQkiUhNEpCaISE0QkZogIjVBRGqCiNQEEakJIlITRKQmiEhNEJGaICI1QURqgojUBBGpCSJSE0SkJohITTCAlD+wGFpuUSlCo6TtXFXMSFrW8bJORoH5zurXz4T2YWblTGVosbi0HvZHp+76i7RRaEpRwvqYy57n28yfleHviyK/9EcXQ8u8E/mV82a2KcUJjXEkfZL3U8nKcCppWdPeW51DsVgCGK7s1ZvbRNg2fZGKd/ZqUZVTdfK1crU7qTXH1vnCQ810A9dTlV/H9ZTla3SsO9btsJBLlb0p7WN/0rIO+99Y3g8sAGWvBC8G/yebH+cG861hOmlZh8H3+JG0rBTQBxy/3iihrXg3aVnjxUbNiT0Ui70GvAnsa1JRQuNMAx9XPm2suUIPxWLdiMy2IWlZ310v9x/spKOLao6wZAAAAABJRU5ErkJggg==';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 18\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 9.78261%;';\n\t\ths+='left : 11.8056%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 76.3043%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 20.3125%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_18.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_18.onclick=function (e) {\n\t\t\tplayer.openNext(\"{node74}\",\"\");\n\t\t}\n\t\tme._image_18.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._image_18);\n\t\tel=me._image_19=document.createElement('div');\n\t\tels=me._image_19__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_19';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAL8AAABXCAYAAABV/ZTpAAAL+UlEQVR4nO2dMWzcyBWGf+euEhtdsewMcGqycJpVtJW5XWAKuEsAr8vT1hZySALYjeREaiTgfJfDql5dkkY0kASB6Hbp4ryCtnJBFqlI4FJRjZtx4yIpuDM7HHJXki3Ju8v3AQJWQ+5wSP4z8+bNm9k7uID1VusegNWLziOIOeTN6XD4dtrBO1WJ663WfQC/A/DlDRWKIG6LFMBfAfxFrwgF8a+3WqsAvgfw9W2VjCBuibcAvjodDl+JhF9oJ4Qg4RPLySqAcL3VktaMbPnXW63vAXyjf8MwDDBm3ULZCOL64JwjSdKqQ28B/PJ0OEw/B4D1VsuCJnzDMNDtbqLtujddToK4EbIsQ79/hLPRSE1eBfAMwOYdoNzqG4aBvd1davGJpaDXO8QgDPXkL4'+\n\t\t\t'TNf19N7XY3SfjE0tDtbsIwDD35vhD/PTV1rdm8lUIRxG1gGEaVpu/p3h55MkEsE6ZpltIqxU8QdYDET9QWEj9RW0j8RG0h8RO1hcRP1BYSP1FbSPxEbSHxE7WFxE/UFhI/UVtI/ERtIfETtYXET9QWEj9RW0j8RG0h8RO1hcRP1BYS/ww454ji+FMX49pIkhRZln3qYswNn3/qAnwsgzBEWN6WAmbDRKfzUK7d7PePkKRJZR6u68r9iTjnCIKXGIRhQSimmecnzhP5MYuh292U5yVJiv5RHwDQ3eyCMQvbOzsAUDpX52w0QhAEAADP80qLrqfdA7MYmmtNOLZdOhbFMYKToLB3jVjQrT4fALKcs57PMrHw4j/PzhFFVa1zjLPRSO4/lKTJlPMAx3YA5MLf3tmp3OkryzL0eodgFpuZH3/HZTp/xwFg6nV1+v0jWeE4'+\n\t\t\t'5yXxT7tmFMU4CQK0XRdbW49l+iAM0esdlsvIOQZhWHg+s8oZRTHiKC7kvQwsvPhV9vZ2AUyEmrfiQeGlMWah2+0Wvmc2GgDGLetY+IxZ6HQ6cGwbURzD9314nndj+xlFcVzoaZIkRZKklddjbHIPcRTLXmoQhrKHEs9A8KjTge3kPYPoCTjn2D84wHfPvy3s2NF2XbjtvKX3fR/R+Bp6T7HoLJX4Zbdv2wiCILdxz4s2rmEYleaBEA+Qmzh7u7tSEGvN5o3vZRQO8ms7jo0sO0eWZaWKK1DvwbFteN4D/P4Pf0SWZTgJAnQ6D+H7L+T53e4mNjxP/u/YNvb3D3A2GiHLMpyNRgWzxjRNmT/3PNkjZOfnJP55RQxOR2cj2YI3ddMhSUu2bXezW6gknvdACn8QhjjPzuUx27ErK8/HoFY813Vxnp3j2PcxCMNpu40VMA'+\n\t\t\t'wDbdfFse/LQbo6NlCFL+h0OnIckCYpoJj0WZbJnkiMQaY1GovMUol/e7soasexSwM1znnJtuXveC6AMYwx+TkMw8L5j9C5dhGE4SsAk4Eo5xzHvg8gr3xV4r0IUfkdp7qsjFmTc7VB9CAMC3tbik2Ll42lEv+jTgcnQQDOORzHxt7ubukcxso2P7Os/EOuN8RRLAXuui4c2yl5f66TE6V1DYKX8rPwPF1G/Jxz+dlYMeA4NqIoRhTF4JyXeg/VhcssVjjmODaMFUP2DE+fPlm6Vh9YMj9/p/NQCiWK4kofvei+1T/DMCYVAHnLJ8TUdt3xQK9Rec0kSQvCu2oFUa+VZRmOfV+aLyJN22K7sgzqeIUxqyBoUaFU/HHPAkAOhAWO7WBr67GsMOq5y8RStfxAbq+L1r/XOyx5MrLsvDAYBICG2UDbdbHheTgJAmRZhu2d'+\n\t\t\t'HXieB9M0wTlHptj9QD6WEK1qr3cIb8OT+8EDKFWoqms3zIaco6j6ERBhboWDsDDgVvNRxwsApHnieQ9kxTr2fWRZhuZablKpphxjVuVg3jAMbHgejsfenpMg+CDza55ZOvEL+7TXOxwP2F6i03koj4vWVUWMDbrdTekDT5K00kcuaLsuwvF5Z6NRqXWuGqjq1xamjchPt6uFR0Z4ZWbdg7hvIWThsdre2ZH3pO9Rz5iFp0+eTL3HTuehNPd8/wXarrtUmxgvvPgbZqM0qGu7LkZno3zCKY7g8Qclu1ZFPba19Ri2Y5cGuoxZcGwHrnsfwOQHPPTZYMby+QG1NZ026FTxvAfltA1vMlEWx5X3YKwYsMeVVxcmYxa+e/4tfP9FYR6BMQtrzbWCV0stZ0Mx8brdTenx+dDB97wifpnlf2riv/75j09TGoK4IXz/hd5b/n'+\n\t\t\t'mpBrwEcRVI/ERtIfETtYXET9SWuff2TFtMUjXjmCSp9I7omI1GIShLzVfPi3OOJE3l9zh/d2G+Ij9jZfaPdp+NRkiTFFEcgVkMFsv97NNciGKSKx1PpjHG0Gw2wZhVKqdpmlOfAbOsmW7KLMuQnedzGbOeh8pF9zrvzL349XgdFeEbFy+1f9SfGpP+qNMp+PvDwcTv/d3z54WXeDYaSR//1tbjktuzKl9RzmlhFUmSYv/goOCvF3n2p/zgd79/JEMf1LId+74MOxbXFeWY9Qwcx5YLbHS2d57Jsm1tPS6UJUnTqe9BTIapz3ZRWBizxzRNOI5deHGDMJSTOCqGkce2qH8NLTyhuTbxw+srwUZnI5mP6q+/TL5ViBljIS79XsQssTpRpgtfXE9UdD0kQUctqyCK4srFOvokWtXKOAFjFhzHlr2omEGeNSE4r8x9yy8Q'+\n\t\t\t'MTZA/sD7/SM5E6vP4jJmVba+KmvNJkzTlGaFmF3lnEsR6ubIZfKtwvdfFGZyp6226vUOsfb3v8m4fGAymcaYJcsXxTHWms2Z64v1sp4EAfr9o/zZHfULx8RaAjHjHEX5hFhV7H6325VmUZZl2D84kLFFbttdqAC4hWn5VQzDwNbWY/ly9Gl7IRD1T+8dAMiuPcsy2Rqqra+nzWZeNl8dNehMX5zS1tYPR3EsQ5yBfIaVMatw7x+ysGbD8+R1hLiBYuBcMZjtRXVGCqZpFsIjRCVaFBam5a/CNBv5QE2LpEySso26t7dbapVc976c9YviCIxZ0uRhzCrZxpfNV/+OYNp5zbWmrCBJkiBJJvH117lySs1LrMpSQ6jXmk3ErouTIF/m2K0IhZ6d52LtDLHQ4p9GVYSksVJ+icL2jqIYYRii7bqyFXQrdiu4bL7F76xcWN'+\n\t\t\t'6qMcttIALegEkv6I7FL8y/Zdy1QbCw4uecFxabqzB2edvcdV1EUSzHDoKql36VfAWmaUpbelprKnobYLKTBMYWhLqw5mOJ4kh+ZpYlF7ED+ZhA9yyJSM7ZeU5fFDPvLKTNH8Vxwcuj2+ZXQR3Uipd/3aG7wkYXA3W1pRcmBjBZiKLa9OpxoLgzxWXJsgz7+wfSBSruL9DEXvW9WYPqQRhif/9A/l8VmTrPLEzLL1Y46agDRkEUxfjqN78tpE3zvwtbV11RpbpBr5qvfo7j2Hj65AmSNJFekUEYwnHs0iowMXgUA2Mh8v39g3EPsiJ7uyRNSssxLyorIJZxbuaL3Md5bXhe4Z7FNYF8ECu2MQGmz7uoDohFYWHEr6PvoPYxuG234JG57m1KhLty/2DS+qoTUcJrwpgl09Sd4fKVZFkhv6v2dmIySsTwq54Zz3tQEq4Y'+\n\t\t\t'Cw3CcOacguPYcn+jRWPu4/mrul09VEEwK7zhoqn4WeEJl8l3mnmg55eMQxve8XcALt4KRYwVxPYpDbMhTbXLhjdU3dNF4RhquIPZaMjPKheFTMwTVfH8cy9+grgOaDELQSiQ+InaQuInaguJn6gtJH6itpD4idpC4idqC4mfqC0kfqK2kPiJ2kLiJ2oLiZ+oLSR+oraQ+InaQuInaguJn6gtJH6itpD4idpC4idqC4mfqC2V4r/qr4gTxLxTpWkh/jdqorpLMEEsOuq28wpvhPhfqaknQVD6AQOCWFT0LSLHvPoMAO7evfsfAN+I1Pfv3+On16+x+sUqGFuszUcJQiD2Nf3p9Wv90I+nw6F/R/y33mr9CcCzqkwYW5yduQgCQGkfVIW3ANjpcPj2jpq63modAfj6FspGEJ+CtwDc0+HwDQB8ph75788///vu3burAH'+\n\t\t\t'71KUpGEDdICuDXQvjAeKNanfVWy0JuAn0JYPU2SkYQN8QbAD+cDoc/6gcqxa+z3mrdv+YCEcRNk54Oh+msE/4P2ByK34nDE3cAAAAASUVORK5CYII=';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 19\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 9.8913%;';\n\t\ths+='left : 34.7222%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 76.3043%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 27.2569%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_19.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_19.onclick=function (e) {\n\t\t\tplayer.openNext(\"{node83}\",\"\");\n\t\t}\n\t\tme._image_19.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._image_19);\n\t\tel=me._image_20=document.createElement('div');\n\t\tels=me._image_20__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_20';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHIAAABXCAYAAADYvBH4AAAHSUlEQVR4nO2czW8jVwHAfzNje7z2ZpykGyepMklKsylKGkC0SMRlYVeAWqQeioQESwu0R07cuEL/Aw7cOIAQUHHqVuLAR2GLytoVZZelJQuilXDiFWm8y248jbOeZDzDYezx+CtxnA+Hp/eTLL2PefOe5zfvzZuR3lPYg+VMZhj4xF7HSE6MzVw2e7NbptIpcTmTeRH4DlLiaWMTuAK8nMtm8+GMJpG1HvgqcPGkWibpm5dz2ez36xGtHqhJvAp8egCNkhyci6Zpzt4uFF6DUI9czmSu0qEnxoZ1YsM6AF490aM5zuHjXfO8zsccZd1BvK0upSXeW1t6Pv4A1zFxp4xmOx1q4su5bPZKBIJn4sVw7pmJBFNPz5CcMYITuzT+cBBGCcIe4HmhcOuvn7'+\n\t\t\t'y2dKXn87mhC9EU9hoXq/E/amEvnK702cZ+8vavK/3X//DwW4VWoT8GrmgApml+D/hoPScxkWD+mwvEz53peuc1wkrHO/L46Dg/68j+bd8v3Htdh2f/urYmh9iaHOLcrWI4OW6a5qpaizwXzpl6eoZIXENy+rCmUtxdSLcmf05dzmSaXjG0uMbQrHFyLZMcmPsfeag1aVYFhsMpiYnkiTVI0h+O3j5aqh2Ok/wfIkUKghQpCFKkIEiRgiBFCoIUKQhSpCBIkYIgRQqCFCkIUqQgSJGCIEUKghQpCFKkIEiRgiBFCoIUKQhSpCBIkYIgRQqCFCkIUqQgSJGCIEUKghQpCFKkIEQGUalbqbK7UQ4WcEZnmld/7a5ZeICa0lEMHa9SpVr0jycVx6s4uHYVzwNlPAF689/w1ix/wWpcg5QOG9sotboU/Lu3XjemgWI7KMVt'+\n\t\t\t'FA9cQ8dN6fv+B82yif+9SKRYpmro7KSTlBfblrudGAMRubtR5u7PbgXx4a88Rmx+JIhbtbwzF6bQPzNFtVim/HM/LXbBREnp2L96H4DIF2bRnpwMynolG/cXK35kaQweT6O8stJ1GemD7y6jFrfRX/HL7DxlYmem9mx/fKXI0B/yKKGVw0ng7I11PvjGx3u6BkfNqRhaP/xdHrdS7fl47XxDevXdO0153nv3GpHHm3uIl07iTRt40wZu7XdQVNsJJDrpJFsZk8rcKADRYpnkSnGfMxwPA+mRrVRLNg/eXidxYe+eUEeJR4gsjeG8ewdvo4xXsv0hFPDqYlM6TBuwZgXl3M/P+hI9+l4u7+oR7n91kWjBonJ+FMfQoeIw+cM/A/6QOwgG3iOj4/7C2vKbt3E2tnsup32s0dvcWi/0SjbeRhkAJTTc1lGKZZQ1C7Xg/5'+\n\t\t\t'Riua82O+kk209MolYcYgULI1cI8h48OtrXOQ/LwHvk2c9OYf02T7Vks/V6ntTzCz2V06YNlJTuPxPXLNQnJ5uH1aWxtjLq7/NNcXfaoPq1xb7bPnQ1T6xQ8s+lR7j/zBy76cGs+B54j1R0jaEvzgKwu2phv3Nn7wIhtCW/V7r/uodnO7i1YVWZH0XR2+/R1mekd8iL7qQT7JgpXD2CajuM/Pp9on328sMy8B4JoD82QmzGYGfVYuv11Z7LRZbGcP7kD2vu2x80htUOvRGO5hkZxrr0iH+eisP4j274E6Eb6/z3mbkjOPvBGHiPrDP07KMo8QhepePuTh1RUjpqbeZZ/cu6n5jSUc4f33MqUixz9uq/GfnlCmrt9cPTI3i1DRoiA5rsnIoeCaCldBKfmqD85u2DlVtK465ZULsB1PnuErXau2IY+3LzMzJ2rUDsWmPy'+\n\t\t\t'UnnKZDtjBnHVrpK47t80D/30b1TmRokVrGC2uj03mMnOqemRAIkLU2g9fFUJo86PQLxxP3aarR4lO6aB9SV/6NRKNsnr68FzcXsxzdYnj7f+bgykR0bHk5x7YQEPiIw3TzhSLyzglOzgEx2Alk6SfH4h+EQXRtEjxL6+gFup+p/gUnrz8288gXd5sfFJjpY93tIJPKByeTHY/61xjELVaL+xKotpdswU+nv3UGwHD/+1Y2dAM1YYkEg1rhGrbVYYvsDgy4vWZNQ311PiGtq0EVzc1omKkk42fz8No0dg2mgS5LYJA880um4q2ImqoVN+YrJpA8BBcqqGVkn/SJGCIEUKghQpCFKkIEiRgiBFCoIUKQhSpCBIkYIgRQqCFCkIUqQgSJGCIEUKghQpCFKkIEiRgiBFCoIUKQhSpCBIkYIgRQqCFCkIUqQgSJGCIEUKgg'+\n\t\t\t'rkwwkf5q3OR0pODXqHNZhqLpvNtyZu/vP+SbRH0idj/2jbAuZmfWi9Ek4t/GYV5wD73khOjrFbRYZul1qT/6gBmKa5AbxYT61Wqty9vkH0bJQzE401f+GlY41w96Vnx0O3Paza6dzeg4R7r+vw7F1XzLJ5+K0CU9fa9ljI57LZbwellzOZV4Hnjr6BkmPmUi6bfSM8a30JuDmgxkj646VcNvsGhF4/ctnsJnCJluel5FSyiS/xJ/WEjgPzciZzEfgW/lA7fBItk/TETeA14Ae1jicRjf8BAgCyUHbOBAkAAAAASUVORK5CYII=';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 20\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 9.8913%;';\n\t\ths+='left : 11.8056%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 65.3261%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 20.3125%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_20.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_20.onclick=function (e) {\n\t\t\tplayer.openNext(\"{node28}\",\"\");\n\t\t}\n\t\tme._image_20.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._image_20);\n\t\tel=me._image_21=document.createElement('div');\n\t\tels=me._image_21__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_21';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAL8AAABXCAYAAABV/ZTpAAAKeElEQVR4nO2dP2wcxxXGP1k2EXAbNzeNfMBufVcozV54FZetTkCcADo3NsBtbAM8xEgCyA2phGxIwJKTHAHbzTHudARsJ+CqvWURH3FbqdgtomY2oKpVw2bZqEiKuxnO7u3xjySSys77AQfwZnZmH8hv37yZeTu8gTNYaDYXz7qGIN5S4oPhMJ5VeaOocCL43wH49eXYRBBXRgzgewB/ORgOj9SKjPgXms33AeyARE+UjyMAywfD4T9EwU3xw0T4PoDFq7eLIC6dXwD4qFqt/uf54eFTQPH8C83m1wC+yLdgjIGxytWZSBBviDCMioqPAPzyYDiM3wWAhWbTRE74jDF0Oiuo12qXbiRBXAZpmqLX28HA99Xi9wE8ALB8EwCq1eoDAL8StYZhYLv7N3'+\n\t\t\t'xw69aVGksQb5K5uTk0GjaO02M8e/ZMrbpdrVb/+s7ky6Ja47rLMAzjqmwkiEvFdZfBGMsXLwrx31ZLG7Z9JUYRxFVRoOnb7xRdSF6fKBtFmi4UP0HoAImf0BYSP6EtJH5CW0j8hLaQ+AltIfET2kLiJ7SFxE9oC4mf0BYSP6EtJH5CW0j8hLaQ+AltIfET2kLiJ7SFxE9oC4mf0BYS/4QkSZCm6aW3Id4e3r1uA66TonNdGGNote7gbqsFzmP0dnoAAMdxsOQ4p7YxDAN+9oyYKdxlV/Y5qx5A5pp6rY52+17mus3NLaTHJw/exvp6pj5JEnS3t2e2JzQX/+bW1tSpXkmSoN/fRcO2kR6nsr5eq5+rzYxTwiRqn7PqgexpY5zHGfFyHmMUBKfep9/flX2EYSQfTuIEbcXPeSzFcbfVgusuI0kSeN4TOI4DxhiSFy8u'+\n\t\t\t'1MYw5uEsOQAAf+DL0cF1l2FZFgDAMk3Z35LjyOsFlmmCx3GmLE1TjIJAHr9x1ugirlcZ+D7utlpn/Vq0QlvxqyGDgDEG111+rTbicKRI8dyWZRUe+8gYO/M4SMYYkiSBP/Cl+IWwRV2eURAgTVMYhoF6rYZREMDznpD4c2gr/nqtBsMwkKYp9jxPetZW607R6V6v3OY0Br6PMAozZfnYvWHb8l5pmiJJXkjBi7o8/f6urHeWHIyCAEmSZEYPQvPVno31dSnaJEmw53n49LPP8webvnabWSRJgjCMMp88dsOWsfooCGTIs+Q4hTF8GEXy4XCWHNRrNWmvP7i4jWVGW88PAJZl4rtvvwHnMXzfl160292eGY6c1eYiI0BRzF9Ew7Yx8H34vo8kGc9D7IaNmMdT13p7JyNBFEaIwgiGMQ8AcgR4lVGqjGgtfhEXW5YJy1'+\n\t\t\t'qGaZnodsfLg/nJ7nnbXERY54n5AaDVao1DpMnIYBgGGva0+EVoI3jc70/15XlPTp3X6IS24k/TFKtra2AVhna7DcOYRzA6EQ6rVKYegPO0uQhhFAI5fdbq0w+DZZmZye2SUzxa+P6+/Lme64fzGGmaYuD7JP4J2oq/398F53HhmvnSjKXO87S5CEVx/kdoFz4A6uTWmSF+UW9Z5tTEec/z0OvtyAdg1gOkE9qK33XHIYvneeCT8IExhiXHkRtKxrwhPWiFVdB27p3ZRlBhFdnWmM9OTPNeOd9Ova9o22rdAY85WIXBssype4RRJMtbBUuaS46DYPLAxjwGSPvj/8m10Gz+Vy386ccfrscagrgk+v3d/Bzoz1ovdRJ6o23Yowtpmsp0Ccs0Kb9HgTx/yen3d7G6ugZ/4JPwc5DnLzGcx+Axl0l4RJZSiF8d2ovIZ0qq'+\n\t\t\t'G0tJksglTVapZJYrR0GAmMcIoxCWacG0TDTscbqB2q4oEzOPMW/I1ZjzhiJi0yqerNFblgXbtmU/YRRN9S3gPEYQBDDmT3KRGrY9tRwr+iiyhfMY6XFa2H8ZKIX4eRxjdXVtZv1PP/6Afr8v19Q3NtblA7C5tQXOYxiGgUcPvxr3x2Nsbm1lMiZF255hYGN9HUEQyNWDjY31U+8PjJc3xdq7+jLMkuOg01mZur7X25lKWhtN7inaiHuqfadpWvjOAfxxn/lRQLU7X9fb6SEMo0z/ZaJ0Mb9lmajXa5kPAHRWVqRXE+kIe8p6fbt9T+6irq6tSeEzxlCv16TnY6wCxqZ3cvP3A8ZpCKLMMsf5/GKTSSCyNVXywhd9CPuLNsEEq2trmTSIvE1is6sI9fehA6Xw/Cqu687Mne90VrC5Ofboqvet12sy173f35VizHvlUR'+\n\t\t\t'DItOY8qmf88De/BVC80yruKVKjxYsnYsdVZIqKazbW1zPhUhhFM9OSB74vxSvuLWzlPMbq2poMgRzHKQxleju9Unr5Ikrn+TnnCKNIflRP1rBtKZw9z5NJap2VE4ELcYqHRUXE+6+D5z0BMH6whC0i/x7I5ueM3wAz5XeR0DYL9Q2vL+/fz9hqWWYmpAly6RniPmEYFb4jUEZK5/nzQ3o+Xu10VjD6+BP5/W6rJSeB6oNSFNq8LiKlGBjn5yQvElkWRhHqtRo454oNF8sVUlMuito2bBtdeS3P1TXAKgyjIEC/v6tF7k/pPL9lZWN+EWsLhOcVDHxfhjki7/2y8JTEM8syMyOJeNHkdUaWs9qedcyK6y7LcGzWvKBMlM7zz4r5gbFnFCs0lmWC81ievOC6y2CMyT++SAF+UxtD4q0tYYeYFwgGvo92e5w4h0n0EoXR'+\n\t\t\t'ufL9BZZpjpdglZFERc1ELZo0M8Zwt9XC434fA7/8m2Kl8/yn0d0eD/qGYeDL+/flKsie58n1bhFTp2mKbnc74y33PO+VXlcEpkecInx/PxPTi3d3BUmSTNmkYjdO2vZ6vexSbRRl5haz5g7t9r3MBLvMlM7zF623b2ysIwpPJr8izu+srOD3f/jjeG18cwvfffsNXHcZPOYyZ3/08Seo12tyJAAuHpqoy5v1eg3tdjtT3+1uI0kS6f07nRUp8s3NrcmINC/t5zHHo4cPp+6z5DiIwkiu+nz62eewLBNpepx5EMQoNwvXdc/ctygDWnh+dfmQMSZz78UwD5x4erG8qK6Nh2EkhV+v1y4UigDZtXzHGb9Urn7UZU7xokmnc7IvkSSJFL5hGIX5+oJOZyVzRIkI7UTbfH0Rqk1lphT5/GelNxjzhjxzJ5/CAGS3+FVhix'+\n\t\t\t'QBgZpakE9vUEeDfNqBSBPI919kv2qf2AN4MXlpvcIqmUnyaekNIu4XbU3LLNyjEH3kfy+qTWVIbyjK5y+F+AniLOhlFoJQIPET2kLiJ7SFxE9oC4mf0BYSP6EtJH5CW0j8hLaQ+AltIfET2kLiJ7SFxE9oC4mf0BYSP6EtJH5CW0j8hLaQ+AltIfET2kLiJ7SFxE9oS6H41TNeCKIMFGlaiP+pWqieFEwQ/++II2By7Avx76uluv2TAqLciP88r3AE4OlNAKhWq/8G8IWoefnyJf718894b+49fHDrFubm5q7WWoJ4A3Ae49HXj4q8/uOD4bB/Q3xbaDb/BODBVRpHENfAEQDrYDg8uilKnh8e7lerVRPA7WsziyAulyMAzsFwGAPATbXm+eHhP6vV6g0Ai1dvF0FcKk8BfHgwHMrFnRtFVy00mybGIdAiAPMKDCOI'+\n\t\t\t'y2IfwPcHw+Hfr9kOgnh7+B9ozHihBDfiEAAAAABJRU5ErkJggg==';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 21\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 9.8913%;';\n\t\ths+='left : 34.7222%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 65.3261%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 27.2569%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_21.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_21.onclick=function (e) {\n\t\t\tplayer.openNext(\"{node28}\",\"\");\n\t\t}\n\t\tme._image_21.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._image_21);\n\t\tel=me._image_2=document.createElement('div');\n\t\tels=me._image_2__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_2';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHIAAACOCAYAAADtjVwfAAAHYUlEQVR4nO3dW2xbdx3A8e85duzYbq5N0q2bm6RkJIVlTdb1Eq/dRXRM66r1ooGEJtCKRjUuEiDxDjygIW574AnE2Bhi2pAQmxBtkQpq2GQPKrWRwtLSliYhHWRNm6ZlcezY8Z8Hxye+JJqdm9Offp+X2P9z8T/99n/svPhYzKMnFGoBDgIHgEfm20etuiGgD3grEg6/kr/Ryh/oCYW+A3x7pWellmQIOBQJh/syAzkhe0Khl4FnV3dOagmOZFanE7InFHoR+Ea5ZqQWrTsSDve5AXpCoS7yIrp8ATbsOUDtvbvw3dmKMWCMwTD705j0mPMcMIaUAUN6Q8oYyNqeezzznsM5d/p0WfvMbS/u3PPMd8nnzJ9v/n4lnJvS/g3WjQ1QfyVMYGIwP+SLwK'+\n\t\t\t'MugGAw+ALQlR2x4ysvsL77ISqqakv672EWeLzcVuLca3m+cX8jE3d040rG8N8ayd7UEgwGe+3ZJweztzQfPEpg4+YlvrRaCf/92D4ma1vzhw/Ys39q5Cy7xu17V2teahFubOjOH+qygZbskeq2ztWaj1qk6crCtzt7nv3UbUhDCqEhhdCQQmhIITSkEBpSCA0phIYUQkMKoSGF0JBCaEghNKQQGlIIDSmEhhRCQwqhIYXQkEJoSCE0pBAaUggNKYSGFEJDCqEhhdCQQmhIITSkEBpSCA0phIYUQkMKoSGF0JBCaEghNKQQGlIIDSmEhhRCQwqhIYXQkEK4y/GiseEBRn/9Xef5hi9+H3dTs/N89IfPABAIHcbfc5jElXPc/O33APDtOoQBYu/+HoDKvc9R0bHbOdbEo0y99DUA7JZuXJ2PkfjDD+adhwWYIz/DGr2A'+\n\t\t\t'feInuICZrfuZuW9f0b9LVe9PcY9dAiDR2MbE7q8WfexyWhMrcuLkqyXt792yx3mcvHwmZ9vM4Fnnsd1S8HWYy8p7sdeJWG5lWZH54v8eINrfi+/eh4va365uwH13B8kr50lePoOJR8HjA7JCev242h8k9Z9/zh335Lfgzvacr6Ne7Fcb25PjVL53PP2atXfhmnh/cSdaJmVfkXZlAICbJ18lFZ8s+jhP9qocTK9KE48yM/vY1f7gMs6ykO/0b7ASUyQ2djK9sfzfcVv2kLV7v4BdGSAVj3Lrz8VfYiu27Mby+gGYef98+ufg3GXW3flYwTGpP/6I1C++hHnpKPzyKNaxHy9qzp4Lp3BfvYip8DG5/ZlFnWO5lT2ku6aRdQ88AUC0/69Mj5wr+tiKzfcDc++Tycvpy6rdsAmrqmGZZ5pmT47j/ccxAGKffAJT4VuR1y'+\n\t\t\t'nVmniPrN7zNJP9vczcHCtpVXq6Hmf63DuYeJTE+XfmLqv3Fa5GWJ73SO/Z32ElpjAVPqzEFL6BE84HHtfkOIHzf2IquJ2kv660Ey9R2VdkRt2TzwOQuDpc9DGuxk3Y1emVN/33twCwvH5cK/hp1UpMOT8r3ztO5cBxJ6QdHcd/7gSu6PiKvf5C1sSKBPBu+gT+zoeJ9veWdJxn66eJvf0a5n/XAHC1dmN5/Zh5Vpp59w3w+GcXocEyYHZ+Nmcf+18RrNELmSNItu4iuXmnsz3RupNkY9vcQjbgGf4b9uQ4KX89seYdzPjrS/odlsOaCQlQ/anPE7twmlQ8WvQx7s33w9uvOc9d7bsX3NdcHykYs6ancq6u1ofXsT68Pve86eM5+ydadhbcicc9dhF7cpyZQD2THY/P/idaydvBFCpLSHdNIzUPfQaMwVXT6Izb3gA1'+\n\t\t\t'+55PX14NVAQ7AHBVN+DvOYwxBvfdW3LOZVc3ULn3OVK3rmEMuO5qz12NVeuxtz2Vfpx5XwRnH7NuPcYYUl37cd4yjXEypJru+cjfJ968g0RDW1lWYkZ5QtY2Urvn6Zz7QmVU3vMA3rZtOfeFsqsb8fUcyrnXVLaKjt0597HKZlU14Nr2lLOdrHM4H3aMwWzdv+C9sea9TmeJN+9w5vtR+66UNfNhRy2NhhRCQwqhIYXQkEJoSCE0pBAaUggNKYSGFEJDCqEhhdCQQmhIITSkEBpSCA0phIYUQkMKoSGF0JBCaEghNKQQGlIIDSmEhhRCQwqhIYXQkEJoSCE0pBAaUggNKYSGFEJDCqEhhdCQQmhIITSkEBpSCA0phIYUQkMKoSGF0JBCaEghNKQQGlIIDSmEhhRCQwqhIYXQkEJoSCE0pBAaUggNKYSGFEJDCqEhhd'+\n\t\t\t'CQQmhIITSkEBpSCA0phIYUQkMKoSGFsIGh7IFbl/rLMxNVNE9somDMjoTDQ/mDY6dPrsZ81CLVfXA2f6gvc2l9M3t0+M2fE79xdVUmpUpTN3qGwMRg/nCvCyAYDH4APJsZNckE106fpKKqHm9dE5bbU/QLmQUeL7eVOPdanq8ndoM7Lh2jafgv+ZuGIuHwl63Ms55Q6GWyYqrbxqORcPhU9qfWbwJ9ZZqMWpwjkXD4FIArM3JlZCQWDAbfACqBXWWZlirWBPC5SDj8embAmm+vnlCoC/g68AjQshozU0XpA34FvBIJhwv/BlG3v/8DgQrciRNjTVsAAAAASUVORK5CYII=';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 2\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 12.6087%;';\n\t\ths+='left : 11.6319%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 51.6304%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 20.4861%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_2.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_2.onclick=function (e) {\n\t\t\tplayer.openNext(\"{node16}\",\"\");\n\t\t}\n\t\tme._image_2.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._image_2);\n\t\tel=me._image_3=document.createElement('div');\n\t\tels=me._image_3__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_3';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAL8AAABDCAYAAADNutRkAAAHU0lEQVR4nO2dMWzjRhaGf2eDbdjsFZpOgFiLxV5DwapMdYflIpfGTHlWc3eAhcslxbpZX2I3dpG7wgay18hbLg0kh8XqimtEH3ChIDbZgqyHgLeiGjeTxkWukDkmKcr2Jpa89LwPEEDOkMM34j9v3jxD4xXMYbXd/gOATwA8mncNQVSA/wJ4OfL9uFixUixYbbd/D+AfABoLN4sglsdLAH8d+f5ZWpAT/4W3P1quTQSxNN4CsNIB8FFaeuHxSfjEfeYxAC89WQGA1Xb7EQCOQnzfsSyYLROapi3VQoK4DTjncN1jCCGKVV+PfP+rVPyfYxrnS3q9TXQsa0lmEsRiEELg+fY2OI+zxWcj3/9NGvZ8kq3pWBYJn7gXaJqGrWfPisWPVtvttVT8a9ka27'+\n\t\t\t'aXYRdBLAXGGFqmWSx+/FHZxbreWLA5BLFcdF0vFj0qFT9BqACJn1AWEj+hLCR+QllI/ISykPgJZSHxE8pC4ieUhcRPKAuJn1AWEj+hLCR+QllI/ISykPgJZSHxE8ry8V0bQCyfJEngeScAANt+ouxvtMnzK8jB4SFeuS5qrKas8AHy/MrBeQyjacC27bKf9ilFpcTPeYwgCAAATaMJo9nM1Q89D5NkAgCwrDU5tZfhOOsIowhRGAEAaqyW+9F+NjS4rq30fsaYbM+y1sAYg+sel7Z/Vd9M05z7U9Kh5yEYB+BxDCEEdL0B0zTRsSxomjb3eUKI6b1BAM5jaJoGb+jBbJkzdqVtZPuRff4kmVzbnypQKfEzVsMr1wUA6EEDf//mm1x9v38kBdE0mvLaMhxnHVEY5a5hjMkBlUwmsu66tgDAMJowmkbuHsaYPDeM5pVi'+\n\t\t\t'6R/1EV4MHM45trbyOw7M2YIDYRghDCMEQYDdnZ3S53Ee4/n2dm7/GiEEkiTBOAgwGAywu7MjQ6BsX8MoxO7Ojjz3PA9hGF3bnypQKfFrmoaWaWJ84b2SJJFeaRwE8uUWd5/oWFbOe82j3+/PDKiUzxxHHqfiYIxJAdRYTc4670uSJFL4wLQv2b4BwN7+vhR+9rlhFILzGN2Nbmnb6aBJv5t0kAJTL54kCTiPsbe/nxN5ShhGGAfBvQyRKiV+ALA6FsYX4cE4CPD0QujBeFqWDhAex7l7iiFSGZzHeDMYyDazOM66PL4Ufy1Xng0X3ofB4N8X7TEIISCEgOedyLbDKJKDQ9cbOS/tYH1moBTbToXfsSz0epuyzrafyNnkKpH3+0cwms17tziuXLanZZryRacxMgA5IFrm7PaK3tCD6x7Lz9DzUCR96a57jCRJFmX+DG'+\n\t\t\t'ksDkzFmNrxZjCQ10SZWcFxnJn+XTWrhVEoj7vdjVydpmlwMjNaXAipUluSJPnFA/tDpnLiBy5fShhGEEJcGfIA0+n9levKj1ci/l5vE5qmQQiBfn95+/VmbW+ZprQ/OyiyAn5f75udMcruzXr67HOm9+gy3HszGMysN6pOJcVv20/k8TgIZMjDGCvNknQsC585jvxYJQu1qRdcl21mve0iST2qrjeQTCYQPwkp0nSQ6o2ZDZdujK43AADJnPVIVtCsNjuD2PYTObP0j/q/2I4PkcrF/MClyDmPEYwDhNFUqNlBkeWmMf9T24bneeA8vja7cxuEUSRDLM5jPH++na8PI3Aeo6E3ZJk39G7UlxS9oYPzWM4kxQxNdhZsGrPtapqGbncDe3v7uUX5faCSnh+4DG+yYcO81BvnfLpozHxKtq0GAPQ2ewuxVwiRez7nMbzh'+\n\t\t\t'bPhVZDAY5NYxQ89Dv3+EJEmkoP/4pz/PDUmszuV30u8fYeh5Ms3pusdybZEmCspomSZlez4kWqaJg8L5vHi4LIbf3Z1N6wHTMOGpbecWnLdB0bMzxqTXL2ZhAOCLL78E5zHGQYBudwO7OzsyZflmMJixb29/H/988e3Mc41mE73eJg4ODiGEwMHBYe57Ay52Mt56duV6otvduNJpVJHKen5N03KePuvhfi2Os77wtF42o1Rme3Hhq+vTFKdREpoYRrNsG25Jx7KwtfWsNCtkGM1pu9eEUoyx0hRwlUn/OcXP2cJ/ff/d3VhD3IgkSZBMpgtYVqvd6A94ZffqjfIM0H3EdY+L67ivKxv2qAxj7L0Ef1v33jcqG/YQxK+FxE8oC4mfUBYSP6EsJH5CWUj8hLKQ+AllIfETykLiJ5SFxE8oC4mfUBYSP6EsJH5CWUj8hL'+\n\t\t\t'KQ+AllIfETykLiJ5SFxE8oS6n4l7ldH0EsgzJNp+J/my28bi96gqgS6ZaWBU5S8b/Olt7HfRkJdUn3LMpwNvL9kwcAUK/XYwCfpzXn5+f43w8/4Pz8HLrewMOHD5doKkHcDmEU4eDwED/++LZY9eLd6el/VtKz1Xb7KwB/W6ZxBHEHxAB+O/L9swdpybvT05N6vd4A8PiurCKIBXMG4Hcj348B4EG25t3p6et6vb4CYG35dhHEQnkL4NOR78sYaKXsqtV2uwHgL5gOApoJiKpyBuAEwOuR77+8W1MI4gPi/3dLO61K3iYaAAAAAElFTkSuQmCC';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 3\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 5.54348%;';\n\t\ths+='left : 34.7222%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 58.6957%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 27.2569%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_3.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_3.onclick=function (e) {\n\t\t\tplayer.openNext(\"{node97}\",\"\");\n\t\t}\n\t\tme._image_3.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._image_3);\n\t\tel=me._image_4=document.createElement('div');\n\t\tels=me._image_4__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_4';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAL8AAABDCAYAAADNutRkAAALVUlEQVR4nO2dPWzbSBbH/8luZTZpPJ0BTk0WW8mwqtBtZFyyC4Qu7stqkgAWFogLu7H21r7CBjbBAjaQpJH3uijVAtYV14g5YCNDrFKQNQVkq3Hjhgauu0Ka0Qw/JDmxZa04P0CwzM+Z4Zs3b968R91BBivl8j0Afwfwp6z9Gs0fhAsA/wXwy1mnc5HceSe5YaVc/geA7wHcu/GiaTTT4QLAj2edzs/yRkX4V8rlE/Q1vkYzj/xy1uls8H++4l+04GsKwDdLS0v3fv/06T/AQPOvlMv3AXjyUYZhYK1SgWVb0y+iRnMN+F0fp61W1i561un0vh788728xzAM7O/tgVLzZkun0dwgtmXBcRzs1uuI41je9QOAjbsDz85DeU+ttqkFXzMXUGrCdR8nNz'+\n\t\t\t'8EgLsAvpG3EkKwXCpNpWAazTRYq1SSm+6tlMvm3eRWQhanUyKNZorY6blrWvg1mqKghV9TWLTwawqLFn5NYdHCryksWvg1hUULv6awaOHXFBYt/NdIIn5EM+N8Pf6Q6ycIQwCAsWCAUhOMMbDzc2UbJ45jRL0eAICaJgzDSJ0vE0U9+L6PKIpgGAZMamK5VAIhRLkPv5Z8n67voxf1EPUi2JYtzp2Ug8NDMHaO/b0fQQhRyhRfZncMsrgIQohyDN/GSZabt0ceZHFRHJ/EtvKjdHm7Ju8/qg7Jdkwil33UvW+DWxH+3d06gP6S8/7eHjzvPd42mwD6EaUvX/wkGj/q9cTx+/t7sC0rdT7QF96Dw0MEQajezAMajRPUaps4Z+fiPvxaAND2PDQaJ4rm5tchhGBne3tsoB9jDEEQglIzJTiNk0a6XAPWXReu+1g5hlIT'+\n\t\t\t'L1+8GFZBap/9/T1R/zzWXVccnySvPm3Pw9HRsTjmzetXE9fBti1UN6qZbbRb/wGMMQD9gMlVxxlZ9mkyc2ZPHMdoNE6ufN5uvS4ejmEYsG1LxHMYhgFq0szzur6Po6NjIfiUmrBtSwgwYwy79bp4gHm0Wv8GAFTSQVQCuVz8s5gRSxVFvbw4dBgLw2tQaorthJDMa8rb5fqkyz+8H2NMjAKj6sAJghC79TqiqKcc2/V9pd08T0kZuXVuRfOPo+v7CMJw4mGy7Xmi4Sk1sb+3J4Ziebvv+6lz5Y6W1ExHR8doe57okDs72yPLYBjGSDOJl20Sms13WHWclEkhXyMIQzEKrDqOErrLtbi8nWv3OI6V9o2inmgnwzAQxzG8tpfZ/sk6nLZaYtRsnDSUfV7bU64ZBCEYY6mR8baYOc1PqQkAijYeh6xRdra3FYGh1Mw1WY'+\n\t\t\t'IwFJpp1XFSQ3KttikeVDej43B4B1kulUbav1zo5E+yjoQQISxcgK+LczacB5DF4ejAtT6lptJRxo12QD9cmLcbF26gP3rwNqvVNkW7NJvvvrge18XMCX9tswag33jclBiHPNxeRatEUSS+56Vrypo8OaxzeOcbZfLw83d368onOXklZFEIIB8Bv4S252G3XseTp8/EPEA26+I4RntQfiehADzv/UT3UCbng8ktf3Z8NOTX7fr+zHjFZk74KTVF8sHbZnMi7TNK237peeMelDzRpdQce7+kzW8spMuwVqkoI+CXwMvH23HddbGzPTTfZAXDzSze4dufaaPLHYoLvTP4y71qs8BM2vyu+1ixtcdBTVM83KvMFeRJsOd5KbOHmynAYNJMzdQ1uHYcp/WBq9n81WoVu7v9iXbe5HcS1l0Xlm0pHiK508sC/ue//FU5lzGG'+\n\t\t\t'dka7JAnCQHynpqlo99NWK1V+Pp+5bWZO8wP9h1OrbQKYbOGotDw0TRqNhmKeBGGY24EoHbolgyBUHhLveLxT5U1kJ5nofg62ZYkR8EvNBNsaemdOWy1Rp6Q3JotRHhrGGA4Ohu5lPnK0xnTWUd6kaTKTmh/oC5ttW7m+ZZlVx0EYhMLr83xrC5SaiONL5eFmmTk729siu7/ROEGz+Q6Umsp9CSGoVjdS53LhyfLKZBEEIR59+52yTV6rSCKPgF9KdaOK51tb/Yn08TH29/aEkBqGkfJktU5b/TmHZDLl1QHoK5JqdQNBGArls1apKIopjmMcHBwCQK43aZrMpObn1DY3Jz+2tqkkKkdRTzw0QoiwOZNQ2jdF5AmgLPi2beHli58yhZu78iYxeT4HwzAyO93nQKmpeGVOWy1Rz+VSqT86SJ/K2rBOozw0hmFg3XWFe5'+\n\t\t\t'm3CQBUKg+Ua3KFBkzuTbpJ7iRfWDVKE10Xo8IbktpAXlafJLyBu9gu40sAUEIURoU38HKFA4FYMBZgW/bISezBwSHYOVNWY7MYFd7A68CPyaqTbCLI7SOHfiRDErJCFeTjZfJCFOR2BpCqw6iyZu0Dxj+Dm0JeBB3g3IrwazTTJkv4Z9rs0WhuEi38msKihV9TWLTwawrLzPr5b5IgDOG1PUS9CFHU64cHmxSVyoNUbNBpq4XL+BILxoLiSuXbAaRehMoYEyu/lm2BMaYElclYdt8NmOdOdJz7w4U4yRu1SBaVVVL5nvI5HJ6oA/RdkNPysswyhRN+HqYsEwQhgsEi2ZvXr4RgJFeHZdfnOTsXK8LJjK+u74sgsh26Dc/z8pNZ4MK2rNzkk7fNpgi1DoNQOY4QIlyf7HyYqGNJgWsARIQoXyxLduSiUiizp9l8JwSf'+\n\t\t\t'//jGuusKDVqtbigaUV6wAdSED3nRzO+qgVo8JCD5xmtCCNZdV/kko0lt2xL7uADnhXc3Go2J6p2MpJw0WnbeKYzmj+NYaOqsH99w3ccpbck7CqX9Raiu76MaxyLITd5eG5zHGBPL+8ngLTlcOQ/bssUxJjVFOEDW4hTP+BqnxeV4fb7yfZUAwHmlMJo/6vWE9lt1nNTqY9JGluPReQiw3CGAYViDHP0ph+s6zn3lmoydo9l8p3zylvgZY8rIQ021vHxEGXUNAEqsTW2zJurZOv38SNF5oTDCH0o29ySTPS7k/M0PXNhkk0E2abjp4yXOk2GM4W2zqXySb1l422zi0bff4cnTZ6IjrVUqqTLz7KhxYd+8AxFCQKmJSuUBgMkiOuedwgi/Sc2Jj5WDrkxqIghDJaFdjvGXM5Rkk0eOZuRk2fxyOiE/Ru40OzvbmcFthm'+\n\t\t\t'EoGV9hxoSax+MD/ZigIAzVOc2EmVrzSmFsftlsaHveSNtbjmHP0qqt05awl0vLJdFZuLtS7hQyk9j8q44Dx7mPJ0+fAeiPKHm5AmuVCrxBGHeWt0gW7rbnpbxcp63W2PLMM4XR/PwVHsDw9R1cS3d9H8+3toQQj8shkE0G2bxJpu4lyUpgz8oLJoSIa7Q9b2TiB895zmJcGmJyDlM0CqP5gWHiShT1EAQhnm9tKfuPjo6V99G8ef1KMUG6vj9MxvDeC625XCopWWB5uQM8gV0mL4q2Wt0QLsqjo+PUS6Q4lPZznpOpgrLplnwlSxzHImUxK32zKBRG8wNDF2e2SUJQq20KTWwnFooAVcvLwsYnkcDoV6VctazchSmbVFm47uPUhNiT1jOSZpNslgVB9uhTBAobzy8nduQlXmjmh6x4/kKZPTKGYRR+kafoFMrs0Whk'+\n\t\t\t'tPBrCosWfk1h0cKvKSxa+DWFRQu/prBo4dcUFi38msKihV9TWLTwawpLSvhn5SdjNJrrJCN47+IugI/Jg2bhhwM0musi64f/zjqdj3fPOp0LJDpAo9HQI4BmLsj5VctfAeArAFhaWvofgId8z8XFBX778GHwio7sH2/WaGaZOI7x24cP2N//Jy4uLpK7n/3+6VPvDv9vpVz2ANyfZgE1mlvg17NO5xGgTngfIWH+aDRzxkcA4lUYQvgHtr+DgT2k0cwZPwNwBnIOALiTddQgtfFv6M8D7k2laBrN9dMD8B7Av846nfe3WA6NZrb4P2wST5qZb/yFAAAAAElFTkSuQmCC';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 4\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 5.54348%;';\n\t\ths+='left : 65.4514%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 58.6957%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 26.3889%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_4.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_4.onclick=function (e) {\n\t\t\tplayer.openNext(\"{node16}\",\"\");\n\t\t}\n\t\tme._image_4.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._image_4);\n\t\tel=me._image_5=document.createElement('div');\n\t\tels=me._image_5__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_5';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAL8AAABDCAYAAADNutRkAAAMWElEQVR4nO2dP2zj1h3Hv9cUGfQWdxDRxQA5k8N1oWpNR62Rh7aAeUMSwFqSABbStAXsxU7PXnzA2QggA+0kI9vRQJIC5g1dTE0yxCkDOZNAOlFLF2ZtB+o9vcc/su/OshzzfQADEvlE/0h+9d7v997vRz3BAjba7WcAni1qI5E8YGIAo+vxOC7b+SS/YaPdXgPwZwBfAlhbpmUSyT0xAvDiejwe8RsF8W+0208B/ABAvR+bJJJ75Zvr8fgr+uYD+mKj3VYBXAP47QqMkkjug9+vr6+v/eenn/4NcD3/RrvtIeffE0LQMk0oinK/Jkokd8DEnyCK4rJd1vV4PHoCsMDW4/e2TBP9/g4IIcu2USJZGleeh+HwHGma8ptH1+Ox9QEArK+vfw3gKd2jaS'+\n\t\t\t'qOjg7x4Ycf3quhEsldo2ka1n6zBt/3+c3q+vr6t7+avXnG77Ft+75sk0iWTseyoGlqfvMzKn5hT8s0l26QRHKftMxWfpP6q7KGEkkdkOKX1BYpfkltkeKX1BYpfkltkeKX1BYpfkltkeKX1BYpfkltqZX40zRFEIZ3dryKjEHJL4Rfr9qAZZOmKVz3Da48D0mSsO2apsK2bSGVI0kSDM7OAACGbsC2twrHm/g+hsNz4Vgt00Svtw1FUbB/cFBpi2VZ8Dyvcj9t07EsAIDjXCAIAwBAf2dnYWr5cHiOKI4K2zVVg9kyYeg623bleZV2aKqGXm97oY2PhUct/jRNsX9wUNpDR1GMweAMxj//wdK2HecCQZCNDEEQotv9SEjpDsIQx8cvC8ea+D4URUGvt80+X4ahGwv30zZA9kV87Thsu+u+WSjKKI5Kjx0EIS5dFx3L'+\n\t\t\t'Qr+/AwCYJtMb7agDj1r8w+E5E76mZT09IQRJksBxLrC3u8vEnaYpJmLaK648D5vdLnvvXroAsiKf05NXUBQFE99HGIQFYXYsC1bHErYpzSZ0I+uBoyjCcHheaKs0mwAAzxsVbLlNj6xpKnq9HgAgDEI24l15HhRFKYxmR0eHwnvSqE/9xqMVP73hAKAoCo4OD+e9uK4z14Iy8X2kaQpCCAxdx8T34bpvBPGnPwsFEQAyl6csC1ZRFMHV4Lffpi21vWNZuPI8pGmKK88r2J2H2g8Ahq6j2/0If/nr35AkCS5dtyD+MhvrwqMVfxTH7HXHsm6sSHOcCwCZmK2OhYnvI0kSTHyfids0TQRBiDRN8dnnX6BlmjBbZqkgrzyP+euUo8PDQrsy+PjEtreQTBMEQQh35r68DYQQdCwLrx2nNODPxyh8zPHYebTij99iJiYIQy'+\n\t\t\t'Y2q2PB0HUoioIkSeBdeUz8m90upskUl27m/kx8fzZCuOLIgmzk4YPit4EGo4aR2WFZFoIgRBTFiKK4rDDjncn7/jTmqAOPVvy6oQOzeDFXv1mA+vJA5ieHQQhCGgDARgDqrvR627DtLSZ6Ksjh8JwFlEC5z38boigWBOk4F4L9rusK/+c28J/P+/R5n5/GHHXg0YpfU1X2+srzYNtbhZ6Z9u58oMvPsFD4mRYaF3Rm7sFnn3+R9fJTsZev8vlvwnXnX8QgCAs9Mw18b/tggSiKhdhH01ShnlX6/I8QQgg2u11cui7z0W17C5qmwZ/4uPK8wmNZDEMUQhTFLNDs9bbZkwB6vW20TFNwl5SmGMgGYcBGHopu6AvFxs84KYoCRWkK++jMVX4WiidJpix+4YN+AKWzRbQtT9n6xmPk0YofyG42FW+apmxqkUJneIDZEyty'+\n\t\t\t'Aeml67LHXjjOBfsiDQZnGHDtCCHo5sRY1ms/h71Q/NROant+FunjTz5li3bV4k8KoxchpPR4QPlIJ8X/SOj3d6AbOvPPgfnDuHRDZ8FlXrxA5rdTFyFNU5yevILjXAhfmpZpwrZtFoTmRw+eJteTkwZhben2OIphGDpIg5QK1ba3mD35wFdTtUJ70iDQDb0w29VUmgvtrAv0oVX/4zf+8P13q7FGIlkSjnORH+Ve1CqxTSLhkeKX1BYpfkltkeKX1JZ7n+3JFoSmpftIg7AZDDpFOU2mSNMUqqaWPi6dLlLFszl5TdNgmmYhBeC27aIoLk1g01S1kN7M28yfV75tWfu3vSZVbZRmszRZjq4ZxFGMKI5g6Aa7hmXQax1FUeW1yduan7al58jbRO8jTTdRNfVWuVb3wb3P9pRE3QzD0HF0eIgoirF/cFBISyCEoN/fYT'+\n\t\t\t'dwODxneTZ5+Pz1Re0MQxdSm/cPDipz3fv9HZb09Yc//kmwmT+vo6PDgjDy7Xluc00WtdnsdoUFrIrHcgPIFs/2dneFTqaq5uG5bRfm/Hk78jqh50g/F0Uxjl++LOQ48Snh90XZbM9K5/nzc810rnp4PhTSCIBsQYqQBhNVXtAGy5PPenaaN39TuyAIsX9wgNOTE8EWQuY9NG07GJyhZZpL7bWqrklZmySZslTlptLEZreLie9jMDibf15TZzUMU5Zsl51vJj7XfcOE37GsWY3CBEkyhfmeDyweng+RJAlbbU/TlC0UOs7FW+co3TUrFX9Vii/teWl5IDBfdaTFKFTQhBAcHR4KPVkQhmiZ5o3taI8XRTEuXVdYNdW0+YrvxPdZBVcUx0vNh7lN2jPfhuYW+b6PzW5XWMXmRyoAGAzOhNXuvb1dlnatKAoTo21vCcl8'+\n\t\t\t'70p/ZwdBGAp5TkEYIIriQi7UKlhpwBuEofDH8mRmF33i+3CcC9Z70B6Xr3Lq9bYF35Su3t6m3d7uLnuf+/EC9iUKwhD+ZJ5vs+xEsKprUkaapsy1UZqK0L5Tkpff7+8I15Z+DpjVLw/O2ChwFy6JoijZaNJsIgizqjJ6/PcdVe6Clfb8+/tiIQX1FW17C4PBGdI0xWvHwWvHgWHo6G33oGkqomheqL3oJvHtqqqqsuPFBZ83imLBvqwa7MXbnN47UXVNhDazAhQ+NrE6lnC+ekX6Qss02WgYRTG6M1eJBqa03LEqF+hd8LyR4G8/t+3K3KT7ZKU9v2Howh/NcelYFo6ODoVZAeqb01HgNtymXZr+XPlZahd1tfYPvr6xNuB9qbomPHzSnKapLMC+3fmK9muaitOTV9jsdllHkiQJjo9fFmqa3xWaS0SP/9pxhGzTVf'+\n\t\t\t'EgfX4g66kNXUcf86A1TVN43giqprKfzwuDsNIV4dt53qjQg0ZRzNyE/DE0be7zp2mKjz/5FEmSwHXfLDXr8TY+/w/ff8dmpZJkymoX+ODYK6n35csY+YCe9vS93rYQ37iuu7D3p5MSN8G7YNRux7lYebnkg1zk4gswAKDb/UjYz9+QS9cVeijqu6ZpWmjH169mz+iZJyabreqbnCTlc/CrhP5uGp05AbIvLO1d6SNLKDTIpV92em34z9Pti1xJfiRy3TfsNf+/GqTBjrt/cCBcdz7GWDUr7fnpvDDP6ckJm+N3XReGbgjiNmc3p9/fYSI/Pn4JRVFASIP57lEc4fTkRGi3v39QaAdkNzzfC9G1BkD0rVVNvfG88n47XyoYBKFw3oahC3WzZdekbN3F0HW0TBMT38el67IHU+3t7rLrNxyew3EuoGmqcA60p+dnvGhx'+\n\t\t\t'TxAGTJhlQWnLNDEkhMVjE38CAEK6OL2WdLSOopdomaZQrPMQfvftwfX8hDSE+fVL12U3o9/fYfvoIhYddpMkEW4Azc9f1A7IFoj29uazPhS6BkBFQwjB89wT3lYNv7A1HA4BzN01foWVF75h6Dg9ecWuB/+QrEuu5qFjWaVBKZ0ypsfnJwvoPjozR1/TYJoKX9PUlc/xAytY4V20lA/Mfe8oitn0Y4M0Kodj2ptMZ65JU2mWLkRRf5cuszeVJntKA09VekPVUv5N6QdAlu7AP0qFhzQICGnceE2q0gp4e8tSMMKZ8BukAUM3KlMWJr6Pn2fBf1VqQx6aPgEsvu78/VmUYrFMylZ4ZTGLpBbIYhaJhEOKX1JbpPgltUWKX1JbpPgltUWKX1JbpPgltUWKX1JbpPgltUWKX1JbpPgltaCsCImKP+Y3PoQqG4nkLimpSo'+\n\t\t\t'up+Ef81vxP4Ugkv2T4tHiOERX/t/xW+myXh1BtI5G8D/QHRnKMrsfj+Al9t9FuewCe5VvlK40kkl8CSZIsevSLdT0ej3jxrwGIAKzdk30SySr46no8/gbgZnuux+P/AvgdgB9XZZVEsmSY8IFZGWOejXb77wC+hBwFJI+DfwF4cT0eCx17qfgpG+32UwBPAajLs0siWRojAD/OvJoC/wfN9hpS+7JQWwAAAABJRU5ErkJggg==';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 5\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 6.08696%;';\n\t\ths+='left : 34.7222%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 51.7391%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 27.2569%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_5.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_5.onclick=function (e) {\n\t\t\tplayer.openNext(\"{node32}\",\"\");\n\t\t}\n\t\tme._image_5.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._image_5);\n\t\tel=me._image_6=document.createElement('div');\n\t\tels=me._image_6__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_6';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAL8AAABDCAYAAADNutRkAAAIUklEQVR4nO2dMWzbSBaGf3uvOGSaNGEXgFOTRSoJVhW6NY3byky3azZJABuL2xywt4UEnN3YQBIsIAO729B3XejmbmGmFbONDLHagqxJYK8aN2549RXSjEiRXiu7sqyY7wMMSDMUZ/j4z5s3Q/AZIIiGslZXuNHpPAXwBYDPATxcZocIYoFkAD4A+NfFcPhhtrIk/o1O5yGAU4xFTxD3ie8A/ONiOLySBUr8E+GHAJ7cQccIYhn8AsCSA2C9UPFvkPCJ+80TjCMbABPPv9HpfFksBABN0+A4O9i0rKX2jiAWQZ7nGEURPO8UeZ7PVlsXw+EH6fm/KtZwruPtm9ckfOKThTGGTcvCjz98D03TZqu/AoD1SaxfCndc1wVjbEndJIjbgzGG/f292eLPgX'+\n\t\t\t'HMXxI+5zpMw1hKxwhiGZiGUXHmG53Ok/XZA8njE/cRzvXZoocV8RNEUyDxE42FxE80FhI/0VhI/ERjIfETjYXETzQWEj/RWEj8RGMh8RONhcRPNBYSP9FYSPxEYyHxE42FxE80FhI/0VhI/ERjuffiz/McQoiltxknyVLbvG3SNJvbjkKIuowJK8ef7roDkm6vV1tuWVYli8QoihAEAQDAtm20W63K73z/DOdBoG6CfJvfcXYgxCW8U690fs87RZqlAIDDg4PSudI0qxw/S57nCIL3GIRhSSSc67Btu/Y3gzBEGIa11128/rpj2AMGe9uufd/6JvsUr3UWd9dVr/zFSYLgPMAoiqbtMoZ2qwXH2SllRcjzHJ53ikGhr5qmwba3sG3bv3mNd8XKiD+O6z1lHCfI0gyuu6vKPO9UCSzP88rN9f0zvPP9Ulme5zgPAhjm'+\n\t\t\t'+GVm2Z5pmACANEuv7UP+v7xy/Oy5u70e0jSr1KVphn7/BEmcVLIIXIrLa9uUmIZ57TGjKML+/l5lYN1kn5uuFRgPzH7/pFqf5xiEIUZRhMODAzVQjo6PK+cUQsD3z9ButerSh9w5KyN+Cec6XNcFAHiehzTNcB4ESvxxkpQ8a5pmSNOs9ILy+cTrmaaBv3/zDYDxzZRea9EhieedKuFzrsNxHDDGIIRQSZMGYQid6yUvaFlPYZhjzx0OQuU1XXcXnHMAKIUPslx6WSmuovjnsU+Rw8PyLMd1HUKIkvCfOY7qp5wJ8jzH0fEx3r55DVEYxNu2DdfdhRACQfAelmWtpPCBFRQ/Y0xN5e1WW4lK3sBwMBaIaRoQ4nJi5KDkVWfjTcbYrU29QgglWk3TcHhwMM2AYRjgOsfXr14BAILgfakfmqYpYSQFr8k5VzYoDtRieR'+\n\t\t\t'InOA+CShw+j32K1IVNnjdN3ue6u6U+m4aBo6NjjKIIQgiMoqhW3JqmlWbrVWTlFrxysTgIp56QMQbO9ZLQirH3IAxLgpfTfBwneP7iJfr9k1tbgKZZpj5vWlYl9QvnuurPH10IpmmKOBmLXtqhGNLMa58ivn9W+htf03Q9UOc0HMdRn7M0K+XFOQ8CPH/xshR6rSorJ/40zdDt9tDvnyjjSQ8Shh8ATBddlvVU/a640Nrf34M5maZlyCHPuWiyQpwvQ4NZZAgDlAfLx+J5p+h2eyqUGudTnQpxXvsUeef7pT8AarY1r70eXX0ubhLIGUAIoQbBde2uAisZ9nCuAwC4ztFqt9TULGN5xhiC4L36LHdapJdijOHw4EBNy75/pgaBYRoLjUEN0wAma+toFNWGEXESq89c1393W5uWhTRLkaYZGGN4++Z1aaaZ1z5F6gRu'+\n\t\t\t'mgbiOEEcJ8jzvDKblUIxfTywOdfx4w/fI00zhGGo+tLvn8A0FmvzRbFy4udcr2w1AuWpWwhR2c2RQpdhgPSM25OtvucvXgIY77As8kYUxTwIQzjOTkkscZKoxSDn+h/KiGdtWrBgodvtKUE7zo5q+2PsI6mzNde56nOxDYlfOLdRmGGl4+J8FzrX1UwrLhdr80WxcuK/jnAm/i8ib1Q4CNFutdDvnyDNUjiOA9MwVDgAAI+0Rze2JWNfSTGciZNYeXpZt23b6pnC16/+BtveAucc0SgqTfvFEOX3YhqG8szvfB+tVmu8EfAR9rkJ295Sg+md70MIgVa7hTzPEYZhaTC3Wy211as90iY7XQ8QjabPBrRHN9v8LvgkxJ+mmTL4pmVVdhHk7sMoikqLwaOj49JxnI9v1k1x96zXPDSn3lGGA5JncOC6uyqsktubs7ju7l'+\n\t\t\t'zCm4f9vT01k3mnHtxdd277zLMIlbtW3V5PXdds7M65rraRff9MbakWH4jJ/qyi1wdWSPwy9pQxZJE4iVW9bW9V6u1tWz2cYYzh8PCg9GRSLgBddxeMMbAHTJ1PzgR17UqKx88if7+/vwfDNEqeUW7bXvckdvY8sg32YBoaFduW5Zqm4ZnjqLVEEARz2ydOkt+8Vgnn4//R4PtnpWcHnOtot9qw7S0VwrnuOMwJgkAtljVNU0/UV5W1yX9eVMPaNI3aOJAgPmW6vd7sE2hr5bY6CWJZkPiJxkLiJxoLiZ9oLCR+orGQ+InGQuInGguJn2gsJH6isZD4icZC4icaC4mfaCwkfqKxkPiJxkLiJxoLiZ9oLCR+orGQ+InGQuInGktF/EJc3kU/COJWqclKna0D+KVYIpMbEcR9QWaPK3B1MRxm6xfD4RWA/xRr+v2T2lzz'+\n\t\t\t'BPGpkaZZJQkZJnpfA4DZ9CXANK33dclXCWLViUZRndcHAH4xHGZr8ttGp3MK4MtldYwg7ojvLobDvwLAZ7Lkv7/++tPjx491AE/uqlcEccv882I4fCm/fFasmQyANYwHwJ+X3TOCuCWuAHx7MRx+Wyxcqztyo9N5iHEI9Jfb7xdB3BpXAH7G2ONfzVb+H2yNMoUXAfajAAAAAElFTkSuQmCC';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 6\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 6.08696%;';\n\t\ths+='left : 65.4514%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 51.7391%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 26.3889%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_6.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_6.onclick=function (e) {\n\t\t\tplayer.openNext(\"{node61}\",\"\");\n\t\t}\n\t\tme._image_6.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._image_6);\n\t\tel=me._image_7=document.createElement('div');\n\t\tels=me._image_7__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_7';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHIAAABWCAYAAAAT4MJdAAAG7UlEQVR4nO2cQWzb1hmAv0fSkWTVjd3EaoI5iYxlLTYZRQZsbqRT5MMuc7Cd4h3nnDd062WXOlvr2y7t0PPi7OjLsCHZ1c66gVoyrGsHuxgGb1KRrE3lpHFjS5YlkdxBEkNSjC1LieW+vQ+QQf7vPfKnP71HisB7ghDSmUwSeA04B1wIq6M4cDaAm8Dvc6Z5LVgogoF0JvML4OfPOitFTxSA2Zxp3mwFfCLTmcwC8MMDTEjRG7Ot3umKTGcybwM/6VdGiq75Zs40PzAA0pnMBQIS47bOdzdfJFs+zqgVaQRF03tLvxCNzdYfT9yt52vjrbNLm9Z+SJnYq01P5/XXE08s6+DYnVyfp43wxkPqrFTvc728xq2dTwjwNpAV0D6kxm2dN4svk6wN7pmMEn'+\n\t\t\t'kwIlv718tr/PrRhwTIas2N73ujsw9Pk6wOBisrDgEXB88ycWQ0GP6e1vypMeyNXtg6dlB5KbpgavBMMHROA5LeSKoydFD5KLokobePllpIPcWXECVSEpRISVAiJUGJlAQlUhKUSElQIiVBiZQEJVISlEhJUCIlQYmUBCVSEpRISVAiJUGJlAQlUhKUSElQIiVBiZQEJVISlEhJUCIlQYmUBCVSEpRISTD6cdKSqFMwSrSmnaXqR33lq8YXgGDUiZBwopSoU9C3AEg4MUpanTJ1EJB0hogHLmNVbICAQQwSxCiIRtvH03rdDVK80Dg+mwCMEiNBbPf8qZG3NwPT6RqM60eJM7CP/8bToS8iC0aJK0Mr7v7PSl9nsn7c3b8y+A8AZqpnuFQ9Q0Hb4kq0MSdwppYk4UR598g/Abhc/xrT1pjbtigqzBnvA5B1TjJln2RO'+\n\t\t\t'e/+JufyW71Bgkzn7r43ja2eZEV/dNf+8vclc9S+hZfOxNBP6wc9m64vIIAuxPKmtYeJOZ+lM2o+lL+uf+kTe1tbd7Sn7pK/dOO29txtW7Qfu9oR2zNcj+9Eb4ZCILGoV/hD5hEuV0x3VjzsGWesEy/o98mKLoqiQcKIALGufApAgSsoZYVU8dNtddl4ixQi+mcQ9kBAx5iPn22cs94G+P+wkrTgAi5GPKeiljttN1U+427e1+0BjWM0374fTdvuXIs8mqzx0P/nmfbEX3q1+yNXqRyzV7/Z8rF7oe4+cqZxmIZanqFW4Gv03b5Vf6ahdyh4m4UQpigor2kOmrTHfsJoNDKsAV8W/fPsTvMBbfKvr3IvONkvWY4E36nnmY+m+DK9975Fxx2B2exxoPK0uD3zWcdus1eiVt7X7lKi7w+qkPRp6LxxniAlG3E+S57rKOa'+\n\t\t\t'k9z+WBbzAfOc985Dyv6i8CkLcfcaOW7+qYvdL3HgkwWTtGqn6UVeMLFqL/6bhd1jrBolEA4IZx1x1Wp5wTofWf1j3yVa0hrnVPnIgc4/XKn8jbj1ixHjDT/aG7pu89ssWPtl8i7hiURL3jNgknxoTdWMfihn6nGYsyabetevHUKDrbXLcKzFVvUXS2ASg5NUpODYC4+D9+agVI2FGmq19hMfLxvtplrZOsaBuUaHwBJp0nS5wTf2uLzfNt3/6ivcYia+7+D/SzzOhnfXWu1j4C4PWdPzOlj3HLuudKndTDR4NnzaHpkQCXKqdJ2NF9tZm0j/vuh9PWqaedlo+EiPHjgVeIiwFKTo3r9bwr8eLAOFPG2B5HeDaI5vJly61AqjLEm5+93PHqTd2sfOV9RZe0440XAc16Rb3CuraD7xWdsHyv6BJEfefJa1uURR2EIGUP'+\n\t\t\t'+85bEvXwV3TN7aR4HoCCCPwUaeabEDESWqzt+krUWLL+S5kaIMgaY/56z2jlK4CV2jpvPHjPm+3Nvgytccdovl9tf+hI2NFGr/RcUByDlDXcvoRZk3HnOXB4fOHec2GQckYabRxCfrQ3ttsegrxLmIVdAwNcNJKh19APDtXQqugeJVISlEhJUCIlQYmUBCVSEpRISVAiJUGJlAQlUhKUSElQIiVBiZQEJVISlEhJUCIlQYmUBCVSEpRISVAiJUGJlAQlUhKUSElQIiVBiZQEJVISlEhJUCIlQQM2vIHCkXKfUlH0gpYzzQ+8gZJmKZmHnKVy22TgQmto9clcGLlzIAkp9k++vsHSdpvIP7ZE/sobXY1u8svRNdb16oEkp+iMleo6b3z+XjC8AfzOnaKZzmT+DpwL1krtDAUigVm0YbSViT3Kw8rCK+0y93SPwicdso'+\n\t\t\t'PraSvfx/X4ykMq7tm2OZPbKlG0Qm95P82Z5jveGcuzNKagD3trrUZ6Xx3qS4HTY3l/uJYzzXfA8/Oj+dCTBQp9SkqxP67lTHO2taN7S+7euXPv1KlTvwF2gCSB3qk4FNwEZnOm6Xuu2XWETmcy51AyDxOFnGkWwgr+B1gy24lYA+h6AAAAAElFTkSuQmCC';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 7\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 9.78261%;';\n\t\ths+='left : 11.6319%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 40.3261%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 20.6597%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_7.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_7.onclick=function (e) {\n\t\t\tplayer.openNext(\"{node87}\",\"\");\n\t\t}\n\t\tme._image_7.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._image_7);\n\t\tel=me._image_8=document.createElement('div');\n\t\tels=me._image_8__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_8';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAL8AAABWCAYAAACeoUdMAAAKfElEQVR4nO2dPWzcRhbH/75LtWzsQuwMkE2uIItcs4K2MtVGRs42YKq0tkkCaIHACiA1Wl+kRi6U4LACbDer3CWFKSBxIbpdqlph2UQFWXNrqvEVo/auoGY0/Fh92ZaznPcDBO8OuaOh/H8zb2bem72FCuZardsAngD4CsC9qnsIYgoYAzgA8O/D4fCgePFWsWCu1foOwDMAtz9qswjiZjkA8OBwOHzHC3Lin2u1dpH1+ARRR94BcA6HwyMA+AsvPe3xn3yiRhHETXAbwO6pW4/PAOHjPyveuei6aDabME3jBttHEO8PYwyjMITv+0iSsXzpCwDfAfjnLUD0+j/Jd6ytrWK22bypthLER4ExhvVut2gA7w6Hwzvc7flKvrLouiR8ohZomobNjQ1omi'+\n\t\t\t'YX355rte5x8d+TrzhO7i1BTDWapsG2rGKxEH8OXdc/fosI4gYxTbNUVil+glABEj+hLCR+QllI/ISykPgJZSHxE8pC4ieUhcRPKAuJn1AWEj+hLCR+QllI/ISykPgJZSHxE8pC4ieUhcRPKAuJn1AWEj+hLCR+Qlk++9QN+DMQxTH8fR/pcQrGTmAaBpx5p3SCBWMMvv8WAGCYRul6FMeIoxhAdgjAebnQ+76PE3aChtbA/YWFifelaYogOCiVN7QGbMsunak0CAIcp8eVdVm2VZXIrSzKi38Uhtjaep4rS9MUozBEp7OMeccR5b7/Fq89D0B2IsDsL//JfS6OYnHdsq2J4o/iGP3+rnhfJWLRluNjUWcVtm1hbXVVHM0RBAGiUwMssgiXxC+hvPi5CHVdR7u9BAAIBgE0TcsJH8h6VQ5jDIMgKN1zGYJBkHvv+z46'+\n\t\t\t'neULPzfvONB1HWmaIorj7N8oxnq3ix+3t3P36rpeaptlk/BllBd/mqYAANuyhBtTdWDXKAzFvaZpIEnGCK4hfm40cj2jMESbseLBSiWceSfXc/d6OxgEAZJkXDJEXZ+B6z6+UttUQ/kJr2kaALJefb3bxSAIwBgr3ef7PoDMMBZOffQoiovH4F0InzNomoa11VUAeYO4CnykAoBwFOaupekxPG8v98ONl8hQXvyd5Y7ocaMoRq+3g6+/+TYnRu5eAEBztol5xxGf4UZxWXi9s80mdF0Xoww3iqsgjxTsJG+waZriteflftLj6omwqijv9pimgVcvX2AUhghHIUZhCMYYer0d6LoO27LgeXvifl3XEcUxTNNAFMWXdlmATPi89zVMA1Eci0kx9+M/1IS0yufXZ2Y+SN11QXnxAxCT23nHya3+xFEM0zAwCs9civX1bu'+\n\t\t\t'6z3GU5b7mSE0ijibzaw/H3/SuJf18adZqFeQr5/BejvPgHQYA4itFuL0HTtFwP3tAaYiQ4D99/WxJ/kiS591pDm7gEyeGT6klLpHKdwSAQLlTVyhRjDFGc/31aQ6PvWpBQWvyjMESvtwMgMwLTNMQEVtM0zDabWO9m39mh6zpevXyR+3y/v4t93xcuS/GajCzoVy9f5N7Lo00QHEzssatGiwlHcCNJxqVRyrYtbG5sVNatIkpPeGebTSy6rhAOF76u69jc2EB6fCx89KolzYWFL8Vrf//8ia9YUq3Y/OKTXyDvypyHaRpYdF28evmCevNrwr+Z5X9y4Zvff/s0rfmE8J6bXIN64nl7xZ3yH5R2e2Ro2189lHZ7CLUh8decra3nePDwkZjYE2eQ+GvMIAgwCkPMO86lAudUo5Y+f5qmSMZjjJMxLNuCaRiX2oH9MxLF'+\n\t\t\t'MZIkgaZpMA3z0pNxxhh0Xcei68IwjXP3D1SlVuJPkjH6u/38ZtLpBH/eccRGFlA5+wdwFto822wiiuPSWrnMm99/u1Q9Rda7XdHGzc2Nysm25+1h3/dLG2y6rmNtdRXshIm2Lbqu2BtgjKHf360MlLNtC+2ltjCg4vP9uL2dM64HDx+V6q8TtXF7kmScE1URHrV50W5tmqbY2npe2rS6KrweOTSCt1NuYzG2H8hClV97XmVbs1EtKZUDZ1+4PClClMf+T4pE7e/2Jz1OLalNz9/f7QuxyL18mqbYev4cSTJGkozheXu5UGDgrPdNkjGerqwAyEKEm7PN0j3nwfdH0jTF05XvwRhDMAhyvX8xCnQQBLkRKYrjXNjC2tqq+L37vi9CGaqM0/ffCmGbpoG11VXoup4bDRhj6O30SskvQGYc103QmUZq0fPLvaltW+h0lo'+\n\t\t\t'WY+G4tf39e3LxpGuL1RSPEeei6XjnHYIyJkUA2QDmcWd4ploUPAPcXFs4VJt8d5iEP3MfXNA2dzjLs00wu3hHI8Pb2+7vv9ezTRD3EL7kBxehG4CxOB8gEWEzqCAYBPG8PX3/zrSgrpvytr3fx4OEj8bPeLc8FeNLI05UV8Tvk0UNOlOFRpLz87FnG4vVVNt7SNBV125ZVaXyOZDhF14mPPnyUUIFaiF/uqSataMhiKCZ1DIIgS/aQ4niuM/TzpJEkGUPTNCy6bikBntevaZowDJ4wX3yWq8DYiXh9mb9B8YQHXddFZOogCN57zjMN1MLnl79aPhyFlSssURyJ17ZliSNGgLPE8EnHgQCX8/k3NzfQ6+2cLivm4+nlHOAojksjh+/7mG02RZIMgCstT8ptHoVhaV4DIPfMVcnsrvtYJNz0+/Wf/Nai55eHeZ7QLbPv'+\n\t\t\t'+6KsyjCceQeu+xj3FxbeK6jNtiwh+CQZ5yI05VUdnhYpr/pEUXYag+y2Ff1vec5QBX+2NE1L0aFyezRNm2jIfDPsqrnJ00gten4g81n5Fv7TlZXTXtTEKBzlYvRd171W/f1+v+RHt5fapfvmHQf+qbF53p4QJBetbVuwLVvczxgTovT9t3DdxwhODXgUhkhWvsdssymEzxhDp7NcOSK4rosojoXfHgQBZpuzSJIkZzRVowLHtizMO861EuqnjdqIn/vW3ABGYZj7D+fLhqZpXKv+qp6wmDTOabfbWF/vChHKQpU3mTjcJRoEAVz3MTY3NsR6fFUvPgnTNMRnGWOVqzrt9tKF85l2e+lSGWzTTm3ED2QGYFsWguBA+PhaQ4NlW7kTF4DM511ENgpMSuzWZ2aweM5Ioc/MAFI9HNuy0G4v4eR0EtrQGlh0XTS0RqXxdT'+\n\t\t\t'rLwh/nYQk/bm9jEAQIR6EwMtMwsbDwpTi4irdN9t9NM0vI5+mZ/LO2ZZeOUJSfT/4b8KXR8anh1PWwK0pmIZSgKpmlFhNegrgOJH5CWUj8hLKQ+AllIfETykLiJ5SFxE8oC4mfUBYSP6EsJH5CWUj8hLKQ+AllIfETykLiJ5SFxE8oC4mfUBYSP6EsJH5CWUj8hLKQ+AllqRR/3Y+sINSjStNc/GO58LxTwQhiGqnQ9BEX/4Fc6nl71PsTtWHf90sncwM4+isA3L17978AnvBSxhj+OPoDn3/+N9y5c/vmWkkQHxjP28Mvv/5aLD44HA7/dYu/m2u13gD4R/Eu05zeL3Mj1CZJxpM8mL8fDodH8nGFSwAMAF8UKyCIGrF0OBweAdJqz+Fw+A6AA+DoU7WKID4i75AJ/2decKvqrrlW6wmAZ8hGAoKYdn4G8MPhcDiW'+\n\t\t\t'CyvFz5lrtQyQARBTzOFweDDp2v8B/NX+XPLmJ4AAAAAASUVORK5CYII=';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 8\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 9.78261%;';\n\t\ths+='left : 34.7222%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 40.3261%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 27.2569%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_8.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_8.onclick=function (e) {\n\t\t\tplayer.openNext(\"{node59}\",\"\");\n\t\t}\n\t\tme._image_8.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._image_8);\n\t\tel=me._image_9=document.createElement('div');\n\t\tels=me._image_9__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_9';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAL8AAABWCAYAAACeoUdMAAAJJElEQVR4nO2dMWzbyhnH/84rjMJc0kHcDIjL60AOyULBmkKtoYE3hVmlpS1goe300sEqIC8x0Oa1lYC8t8hr6KWDmNX00CdDWp4HciYBJ0BBL1kuQJGlA3XMkaJkOXakxPf9AAES73j33d1f3313FHQbKGGnXq8C+COARwAelOUhiK+AcwCnAP55NhrFxcQN8cNOvX4fwF8B/GkVlhHECvnH2Wj0Z/FCJv6p8H2QpyfuLqdno5HFP9wTEo5AwifuNo926vUf+IcNANip178D8G8xl6IoaLWaqJkmFEVZsY0EcTOSJIHvn2LoeWCMFZOts9Ho9BsA2N7efgmgylNUVUW/9y/89ttvsbm5uTKDCeK2UBQFhqHj4cOH+M/PP+PDhw9i8v03FxfuvWms/0'+\n\t\t\t'hMabf3yNsTdwJNq6LVahYvfwekMX8uzldVFYaur8QwglgFDcuaceY79fqDe8WMqlpZmVEEsSo0rVq8dH9G/AQhCyR+QlpI/IS0kPgJaSHxE9JC4iekhcRPSAuJn5AWEj8hLSR+QlpI/IS0kPgJaSHxE9JC4iekhcRPSAuJn5AWEj8hLSR+QlpI/IS0kPgJaSHxE9JC4iekhcRPSAuJn5AWEj8hLb9atwHEzWCM4fnhIQCg1WyV/TMZMQfy/F85vV4fQRDCsiwS/jVZu/iTJCn7//S1s2q7gjC8dn2MMZg1E+32HhqWdfUNt8Cn2Al8meO8lrCHMYbB4Agnvp9dU1UVtv0Yu7aNKIoxOBoAmJ3KB4MjRHEEraqh1WrixPfhC+Vk5VVU2Lad3bvf6cy1h9exyK7L5BJRHC1s10G3CyAd6F6/DwAwdAOO86Q0/4nvw/M8'+\n\t\t\t'RFGcq69hWXCcJ1lbxbJ5+a57jPFkkgmq1+ujZpqwd+3cv2yLZZimiV3bztXP+04sfxk7FUXBrm3Dth9DUZRcWcv0p2jHuliL+J8fHiIIwtw1PqA10wR7z7J09j7vLaI4yt17mVzOlJUSYjyZ4MXf/wZVVefkQa6ORXYpioIkSZZqn+seZ+UEQZgJRKTX6+dEIdb3ynWhG/pMWwEgimLsdzqlXnQ8mWA8meRmArGMIAhRM02oqgpgUd9dbSdjDK9cF1vKFnZtO1fWMv0p2rEuVi7+KIqzDtm1bbRaTSRJAs97DcuyoKoqksvLTyr74KA7rSPCYHAExhjGk0nOyzQsC1YjHyJo1eqVdgEfB3UwGGRekNfJ4XWKnPj+jMflguLHP6mqCsYYXNeFbafe2y1p4/PDw0z43NMDQBiEeOWmd/R6fWhVrXQN0Ov3F3r5ot1FO2'+\n\t\t\t'umiSiO4Q29zPuXscw4r5uVi7/oyYF0Kiw5PePa8Oleq1YxGBwBwIzHnXf4BnsfL22XWGaxLB6KKIoCQ9cxnkzgea9zInHd4+z9QbebE2nNNOe278T3s9mnZpp49uz7nB1bylbWbs/z0G7vzZQRBOmMuKieq+w0dP3KA0w+5zjfFisXv6HrUBQFjDEMPS8bCNt+fGNvwOP6JElnDsPQZxaCJ76PIAxy1w663VuziwumZpqwGhbGkwmSJMnKY4xlAjYM/Vo7NLEQc3OPL7Jr23DdYzDGZtYnhpGKNQhC9Hp9GD++XFiXaGfNNDM7gzBEKIQyFbVSutj+nON8W6xlt+eg2806IEkSDD0Pv/v9H0pjy+sQBCGCIESSJFPPa8zExkmSZPn467bsCsIwE4zVsGDoelaef5KWEcXxJ7dPFPQ8z6tp1TSv8EXhtPfSmSANr45n'+\n\t\t\t'0vN1fbxf07TsPQ+v+Ktss4Hzucb5tljLglfTqvjpx5eIohi+72PoeQDSWPUm54Hx+DtJEgwGR3jlumCM5abasph/Wbuu8lje0Mveh0HqIRVlCwCyGUBs33W3/gzdyL6s80IXnq5p1Zk0VVXx1HHwynUx9LyFoY9oZxAGcJDuWOmGjqdwEITBlYtlTbtZf35u1uL5+aBrWnpSnhibFhe7YVDcLZi/GOaxaEN44FOc/nnML74+xa4iPLThcM8oemDPe52VD0wXhWG+fYyxuV+K6vS+tCxvJl305oZulJYhhh3FhXkRbmcQhFk7DF2H4zyZW77ITfpzFax+wcsY9jsdqBUVjuNAUbYwGX8cBLVSgaqquXixoqbXvKH3MV4u6XwupLAQzuTzBChuo+iGDq1avdKuRfj+afaex9ecKIrBGMOJ76PVasJxHDx/nv4kYX+/g1'+\n\t\t\t'3bhlkzEUURPO81FGWrdEeGx958J2W/04E1PWlwMp7kdmZs+3GpnYqioN3ew/7+/OcenJydnQ4c50kWAhXXTUWWGed1s3Lxu+4xoihGFMUznqchbIG1Wk30en0wxtDr9XP5NK1aOrhlA+o4Tu5zMc4HgKdwMBlPlrJrHnxK17TqjHCHnpdtvZ74PhqWhXZ7L2vX0POy+zM7w/Iv70G3i/1OJ/sCFNuiKAqePft+ob2GrqNmmld6/pppZnbyB1bLsuw4r5OVi7/VaqKqVXNPDMWnmhzeQd7QyzpPURTUTBOtVjPbbqyolRlPCwBaVctN8WV5OBW1Asd6spRdvGyRIAyzEMEu2fduWBYm0zbEUQxY5e0DkHtKWwz5eB8cdLvwvNcYT8Y5W3lIIgqL21q0udVqlm5HltnO7RR/2sDr4+sncRyULWXpcV4nGzv1+iMA2fLb'+\n\t\t\t'MPSlH4IQxNfCfqdTnCWttf+wjSDWBYmfkBYSPyEtJH5CWkj8hLSQ+AlpIfET0kLiJ6SFxE9IC4mfkBYSPyEtJH5CWkj8hLSQ+AlpIfET0kLiJ6SFxE9IC4mfkBYSPyEtJH5CWkj8hLSQ+AlpIfET0kLiJ6SFxE9IC4mfkBYSPyEtJH5CWkj8hBSUHWpyD8A78UIQfNoJ2wTxpZIkycwZymej0em9s9HoHEAsJhQPgyCIr5lef0bP5wDwDQBsb2//BsAjnvL27VtcJpcwDB2bm5urspEgbhXGGF68+AG//HJeTPrLm4uL8w0A2KnX7wOIANwv5lp0oglBfMnMOZft/Gw0eggAG/zKTr3+AOkJLTNfAIK4I7wDYE1D/Y+7PdMLFgoLYIK4I8QQhA9MY37Om4uL/25vb/8E4H8AHgD49UrNI4jb5x2AQwDNs9EoFhM2Sr'+\n\t\t\t'NPmR5WRxBfK+9ET1/k/8Szyt8rBZzaAAAAAElFTkSuQmCC';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 9\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 9.67391%;';\n\t\ths+='left : 65.4514%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 40.4348%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 26.3889%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_9.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_9.onclick=function (e) {\n\t\t\tplayer.openNext(\"{node15}\",\"\");\n\t\t}\n\t\tme._image_9.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._image_9);\n\t\tel=me._map_1=document.createElement('div');\n\t\tel.ggFilter = '';\n\t\tel.ggFilteredIds = [];\n\t\tel.ggMapNotLoaded = true;\n\t\tel.ggId=\"Map 1\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_map \";\n\t\tel.ggType='map';\n\t\ths ='';\n\t\ths+=cssPrefix + 'background-clip : padding-box;';\n\t\ths+='background-clip : padding-box;';\n\t\ths+='background : #ffffff;';\n\t\ths+='border : 0px solid rgba(255,255,255,0);';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 25.5435%;';\n\t\ths+='overflow : hidden;';\n\t\ths+='position : absolute;';\n\t\ths+='right : 2.25694%;';\n\t\ths+='top : 6.30435%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 89.5833%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='100% 0%';\n\t\tme._map_1.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._map_1.ggUpdateConditionResize=function () {\n\t\t\tvar mapDetails = player.getMapDetails(me._map_1.ggMapId);\n\t\t\tif (!(mapDetails.hasOwnProperty('title'))) return;\n\t\t\tme._map_1.ggCalculateFloorplanSize(mapDetails);\n\t\t\tme._map_1.ggShowSimpleFloorplan(mapDetails);\n\t\t\tme._map_1.ggPlaceMarkersOnSimpleFloorplan();\n\t\t\tme._map_1.ggRadar.update();\n\t\t}\n\t\tme._map_1.ggUpdateConditionTimer=function () {\n\t\t\tme._map_1.ggRadar.update();\n\t\t}\n\t\tme._map_1.ggUpdatePosition=function (useTransition) {\n\t\t\tme._map_1.ggUpdateConditionResize();\n\t\t}\n\t\tme._map_1.ggNodeChange=function () {\n\t\t\tvar mapDetails = player.getMapDetails(me._map_1.ggMapId);\n\t\t\tif (!(mapDetails.hasOwnProperty('title'))) return;\n\t\t\tme._map_1.ggCalculateFloorplanSize(mapDetails);\n\t\t\tme._map_1.ggShowSimpleFloorplan(mapDetails);\n\t\t\tme._map_1.ggPlaceMarkersOnSimpleFloorplan();\n\t\t\tme._map_1.ggRadar.update();\n\t\t\tif (me._map_1.ggLastNodeId) {\n\t\t\t\tvar lastActiveMarker = me._map_1.ggSimpleFloorplanMarkerArray[me._map_1.ggLastNodeId];\n\t\t\t\tif (lastActiveMarker && lastActiveMarker.ggDeactivate) lastActiveMarker.ggDeactivate();\n\t\t\t}\n\t\t\tvar id = player.getCurrentNode();\n\t\t\tvar marker = me._map_1.ggSimpleFloorplanMarkerArray[id];\n\t\t\tif (marker) {\n\t\t\t\tif (marker.ggActivate) marker.ggActivate();\n\t\t\t}\n\t\t\tif (player.getMapType(me._map_1.ggMapId) == 'file') {\n\t\t\t\tvar coords = player.getNodeMapCoords(id, me._map_1.ggMapId);\n\t\t\t\tif (coords.length < 2) {\n\t\t\t\t\tvar mapId = player.getMapContainingNode(id);\n\t\t\t\t\tif (mapId != '') {\n\t\t\t\t\t\t\tme._map_1.ggChangeMap(mapId);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tme._map_1.ggLastNodeId = id;\n\t\t}\n\t\tme.__menu.appendChild(me._map_1);\n\t\tel=me._out=document.createElement('div');\n\t\tels=me._out__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_out';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASAAAABwCAYAAAC+eq3DAAAa9UlEQVR4nO2dbXAb9Z3Hv9KutLLkSLYT2TGNHFM7SevEDuHpYENa00I5KKXp47XAHaE3cy+u0wKvrnMzNy0zN7y6m9K+uTftQe/6dNBeobR0mHLFTcLSEgJ5ctrETnFsE9tSoqdYslZaSfdCK2l3tZJ2V5Ilh99nRmNZ//0/yGt99Xv4PwAEQRAEQRAEQRAEQRAEQRAEQRAEQRAEQRAEQWx0bO0eQKMIgjCp+HWyymUEcS0xVXzC8/xU9cs6nw0jQIIgDKMgMHsB3CA/eto4JILoFKIATsiPkwCmeJ6fa+uIDNLRAiQIwkEAn0ZBeIbbOhiC2FjMoWApvcjz/AvtHUp1Ok6AZJfqEQAHQRYOQTSDKIAXAPyg01y2jhAgQRB6ABwC8BjI0iGIVjIH4E'+\n\t\t\t'kAL/A8H23zWNorQLLwPI6C8JC1QxDrRxTAdwA83U4hapsACYLwOIBvgoSHINpJFMATPM8/247O112A5BjPMyBXiyA6iRMoCNHUena6bgIku1vfRMHlIgiiM3kawJPr5ZatiwAJgnADgF+ArB6C2AjMAfgMz/MnWt2RvdUdyLGed0DiQxAbhWEA7wiCcKjVHbXUAhIE4RkU0usEQWxMnuV5/tFWNd4SAZLjPa+hsFyiZVzJRpHOZ7CUDQEAruaSuJpLIC+XF38ir3iuLVM8r3pNvvo1evUb6kv7PG/gGsVtrLgmX7u/uu/L5Hs30pfh6/P6r6vbtOleY+a9V20/b2yctdrUKzN8jc69H2Dc6GfdAIAJpx8euwMjDp9Oi01lCgWXrOlxoaYLUCvFJ5yN4qJ0CUtSEEtSSHF/bLo3sJaA1PrnqSVgZuqXnregfvm5/ns3'+\n\t\t\t'2n/d8dTse33r69ezNVhfv6yRusq+a9VrvH754zvBbcEE5wfvGmyVIJ0AcGezRaipAtQK8VnNJTCdnsF85hKu5hIA9G4gCZDV/kmA9Ms2mgApywYYN/iuQXyuexQDjBtNpOki1DQBarb4LGdDOCFOY0kquFe1P8QkQFb7JwHSL9vIAqSsv5fbgr/zfhh7uS1oEk0VoaYIUDPFpyg8y7LwGBMBEiCr/ZMA6ZddKwJU/LGX24JHmidEJ3ie39eMhpqVhv82GhSf1VwCryUFvJKYwkrR6iEIoimcFC/jidAR/MuVP2A5m2y0uRvkDHfDNGwBCYLwLRRmOFvmT+kZnBSnkc5nLFohZAFZ7Z8sIP2ya80CUv702B14xPthfL57BA3yBM/zTzfSQEMCJK/res1q/XQ+A2HtGOal90qvkQCRAJEAtVaAij/3dw3iG703odvuQA'+\n\t\t\t'Pc2cj6McsCJMd93oXF1eyRbBSvp44hko0au8kkQFXqkQA1Vl+/7P0gQAAw4vDhG303YdR66j4K4HqrQelGYkDPoAHx+W1yCpFs2/dDIoj3NbOZGB4PHcFsJma1iR4UtMASlgRI3qv5oJW6RfFJ5zNWqhME0WRWcxk81pgIHZQ1wTSmBUh2vSwpHokPQXQmTRChb8vaYAorFtDjsOB6RbJRvJqcQobEhyA6ktVcBl+3LkLDsLDXlykBks/m+qbZTtL5DA6vCWT5EESHs5rL4J+v/AGrOUuf1cdkjTCMWQvItPgAwJG115GQ13ERBNHZLEtJPBU5bqVqcddTwxgWIFnZDpkbD3A6fRYrWZrZTBAbiSNrS3j+6gUrVQ+ZsYLMWECmrZ9ILorT4rTZagRBdAD/Gf8TliVLyzYeM3qhIQGSo9um02xvp1q+pSxBEC1iNZfB'+\n\t\t\t'U2FLrtghoxkxoxbQIZjMfL2bmUOQXC+C2NC8I17GkbUls9UMGyxGBegRsyM4nT5rtgpBEB3Id6OnrFQz5IbVFSA5oGRqq413M3OU9SKIa4QlKYnfJObNVrvBSDDaiAVkOvZzhqwfgrim+H78T1aq1dUO1kAjptyv96T3yPohWo7rd3NgggkANuRdDBL3jiLPGfl3JqywLCXxjngZ+8ztqPgICietVqWmBSRHsk25X4vSJTOXE4RpnMeXwB1fArsQBxNMIMUHSHzWgZcTF81WuaFeNqyeCzZpprdMPoN3M3NmqhCEKZhgAq7fzQEA8hyL1S/tRrbf095BvU84bD4bBtTRkHpfGx8109OiYmdDgmgFtpgIcX8AAJAZ7SPxWUdWcxkcXlvCR7oGzVT7KIAXqhXWEyBT7te1MO9HiolIXYxDioqlneNcQ144t3sNt5G+GE'+\n\t\t\t'd6Pl763e7l4NjuBePjmjzaAvmUhFwwiex8HHkANo6BfcAD+5DxMefn48grxgwXAwx5AX9nfcClHX2QdvSpdvW7VnEvxuFeLKxMzwPIciyS27xYa+M9ObJ2yawA1dSQegI0aaanUBsFKHkxjvn/Umffrv/aPrA9xj70yXMRRA4vIr1SGUCPAbC7WHTt7IXv7mHYXUzFNblUFrHfzkE8H0EuJen2wQ544D6wDdzO3tJrl5/6g6HxAYDnoTEwClHJp7JIH11E5nQIeZ0+bT4O7Hg/2Du26baXj4nIHl1AbiYCVBkzfBxs4/3Afv02qmGbj4P9Se1lOPl+D7I7+pC5eStgIIbDCYtwvr5Q+j3n4xD/h5tq1tn8b0LNcqnfg3TAi8RN1yHrVf+vbHluGs6F8tYUoS/ugRgo//2H/r1O214O6X4PEiN9SIz2IWvgPTriIja/'+\n\t\t\t'sYBNs2HYRf17kvFyiOzuR/C2obrtNZu3xctmq0zWKqz6FxEEwZT1k8gl2pr9ivxxufK1N5fh/8T2mvVyqSyCL11A8ly4znUSEqdCWDsfgf/hMbAD5RMnU+cjiL50oarwFJFWEoj/7BxcE35039/YiQT5VBbJH59FTkcwS9fERGSOLiA7H4Pzwd3q93M6BOn/5qoLT5GYiPzRBeB8GPjkCNBEl8cWTIANJsC8tQTxy2PI1Wnb8ZY6BmGPiXDMhJHZ0Wd5DKw8BvfxJcTuHcXa7n7LbVW0HRfBxkW4Z8PYPMXi8uQwrtZo3zsdRP/UXFXhKeKIi+h/YwHe2TAW79mB1DpaRMtSEqu5jKmN7AVBGOZ5fk6vrFYQ2tTSi2iuffs7Z6IiruoISPxkCLlUtmbdlefP1RWfWogX4wg/f66u+DSb9FtLuuJjH1D/M9pcLBx3Da'+\n\t\t\t'tey82EIf16tr74KAkmgB+fBWKileHWxCZK4H5yFrYaHzzHmZBuOXfcUmBUF99vZsHEm//+AMAuSuh/ZRb9r8zqlnfPhrH1ldm64qPEFUrg+ufPwNGiMVdjxvyGZcPVCmrZhKYsoGjO8laODRM9pe/65VISVs+F4Z3w65ZHDi9i7WK84nXvrYPo2lV2k1ZPhpA4FYLdxcL/8BgcA27kUbCewj87X1HfMeCB+9atYHxcwXePikgcWUQ2JsI14cem+0eqxjC6DpRdHe01dkUMKX1MbfE5DwTgkF2tXEqC9NYypGNLcD44Bnu/p9yWKCHz68ptFmxDXthvGQQ4tnBtTETu6IJacEQJeHkW+PLuivr1yPd7IH18uNzffByswp2yiRKYmQikPfr3ynEmqPs6uxCDPSYiazC+Fv2bPaXnTDCBbmFBJWzu45cQv/N6Q21pifEB'+\n\t\t\t'1T1zz4ThDKm/JDZNB7Equ2RF7KKErTrClNzmQ/jGwZLr5oin4H9jQSU4jChh2ysz+MsX9lTUbxVvm58PNFytoJYAmbKA2ut+lb8FHT0cMtHyDYr+cVlXgHKpLGJvqj/EdheLrX9bEBigLADckBfcdi+cAx6V65U4tlRh+XRN+OH7VNm9ygPAEMDt7EPy2BLcB2rHUroObDN2rI6mX+cd5Xo2FwvHHdvA3rwVcLEqJZOOLlZYPswdAdh04kT2nb3I/ehswfopMh8vPEwEuAEALgY5RfwkH/AWREfhVtmqWFf2YALMQvmLIufjYFdcyx2/hOTHjIlGRh5DHgDk55tee7dU7ghaPzU0entAdZ8itwXgWoxj4MU/qyybgVdm8ZfRW0u/b35jocLyuXx7AJdvC5THCiAPL+IjfRh+fhouhbB5FmPwLMaQ2Gb5aB1TrObSZq'+\n\t\t\t'sMVyuo5YKZejftEqDYyRCyCjer99ZBdO8qf7uIKwldKyd5PlwhHn2f2A6nQmCUeCb8JWEqkjiptrwYH4eeT+nHdmwuBp464tMI6aOLOn1Wfr9kT6vHbBvywl4lSA2Ohf3BscoAcRVrxCxGJw86NW5W8uAuVV1nFffMCEYtJ6uktnmx8ukPqV6zixI8s2W33zutvifJgA+Xbw/otpfjWMx9YXdFQLt3ujn3xAgz6eZ5O01zwdpF9KQ6Kt+9qxd2F4NVRVwnfioElyaNrhUltodDdxVXTY9sTERW84296SONC8zakbKQaF0wTiEU7JAXkiJtnj6ygMypINidfWDG/RWxIADIBRMV1o/9ljopVY6FbWcv8krhmq8UdLPYF+JgNUHlvI4Y2EQJ7Eyk9HvOxyHX70FmRy+cZ0KlaxwzYaT3mAsg2+MiuoUF1WuZfv0voEZY'+\n\t\t\t'2+ZF2u9RuWNcKIHV0T5woUSF9RPZV/ueZDkWV0f60HO2LDqexfaFQAywt1rBhp6/nlpJIqkQku5dfXD0cOh29QEoxzniJ0PYokmfS1G1eLAmvwm19QE0ZZ6PUoC0KAXIeWAbpB+ppx3kYyIyx5aQObYE+4AH7B3bwOxUZIh0AvKG5goFfIBSgCwEom0rSTh+WkjL23UELO/jkN3RW/E6q7Fu0jcVPpzSaF9JgADAdXzJkAD1/I88hngKjM77EEc3123DCmsBr0qAuhYLfwO7WHlPkoH69yQR8KoEyLnOgWiTVA3nNHIyqop2TEIMa1Lvm+TAMeNi4N2rtmaib9bOljh1LAazsE1ow3BfQ164HxpTBaaV5FYSSP/8HNK/0s+6lDDiBjXDTREl2OfjVcVH/MwuXZdM635JcvA2s6MPOcW4mGAC7EJ9y8yxEINjIaYrPs'+\n\t\t\t'mbBpE28OG3Qs7EWjUj12a8rkaG0zE0TYDWm2wqi5giBsO4WFXsR/kcAK5WyZQV0ZuAaBapCW2w273qx1D5oYUZ8sLzjzfCdf8o2J36c2Gyp0PIzlSfZpAPGhizgQ+2VaT9AaQOTejOAWJnwqrAdDbgVYlOZlT9njmLsamsj0P04IcsZ7+MoM2GSd7qos6F6t+TDne5DNM0F6yf8a+rFRQ7WdnXe8+dq3p9JioicS4Ct2wlOQc8qjhQ6mIcuVRWd5azHg4dayd1PmJqyYYe3ofGambB9GDH/WDH/cilJGRnIki/OqfKkknHluDc0QebToA9Px+Hrc4EwPy85p/dbAYMQH7Ii/SXdoN9eRaMwnWyBRNVrTD2jCZgHhfh+el0OduncV+cZ4JIfmy4ZnA7qUiVpwM+ZH1cxQzoZmMXJXRpRFyUJw+K/sp74l6I151c6Na0'+\n\t\t\t't14ZsGazYS2gK5oUejYlIXkxrnpoiSusoC4doYjXcNO0ExrtLqZChNZO1Z74WG9SZKPYXCzYcX/FxMNSOcfCphlz9uhiYX5PNRbilUHnBmYeZ/erszvMTBh2HQvLFhPBaiw3e0wEsxAHKz8YHevNeab2l2CCDyDJB5DgA8gEvC0XHwDYrDO7uTgPKMexJTEqsuWNBTA17olnMV5hAcVHrd+TdaDqLOVaAtSxR1pcPRdRzfUxSuJcGJJs0rt39VasE4seXkT0cGUQOJfKIvzSBYRfuqASke5bt2qukxD+4VlIK5VzScTzEUS+fwqZJmSQSm2+ehGS1jpBYTFqNZibNRmWlASp2gzn+Thy/6uxKjkWGDeeLdSS93HIaiYbOl+ujFM5LM5wdh3vnP2onKEEBn75Z2zSpMiv7u5HRiF80RvV98QuShh6blp3hrN7MY7AL/'+\n\t\t\t'+sei3LsYiMNW8JSQs4Wa2glgtmysn02D3AOrlg2uCze7sX7mHFJDdFWfxkqGJi4hZ5fVj/p0Zw6b/VmaTo4UWsyml7xsdBiolYO1deYJpeScL/8BhsLgbuCT+Sp0IQFdZWZiWBy987Bef28gr61LlIKT4U/eFZbLp/BFyVlH9ck9lSvhn7gAeuuwpjX/vVBWROh4BjS3CM+wvZLheLfEpCWjPTWZmSZ8b9yJ0OIqcQwvxKAtJ/vA3bzr6SO5afCSOvF9OSZ0s3gvTxYTAzkZLlZYuJcLy+iIy84NUmSmA185Uye/zI+dSB19JuBYoZ1faYCOdMGOkGrDSrDDxXXnzrDFam14FC7Cc0Oax6Lb67H96zIXQpFr5yoQRGvn8cV0f6IMoz2TfNhlUTEItcufE6Qwtdm8UOZ/PcvaaN2mNfnwxQOioioXGvBu7ZDk7+kCln'+\n\t\t\t'ohafX/l92aq5eipUEiDXdi/8D4wg9Ev1B1aKiliN6otpZiWB1WNL2CRPKuz7/C5c/uFZZDQf1vTFONI6biAArL56Ec6dfbDpxJukKnWA8s1KvXqxID7FMZ0OqX5XYnOxFVaP43O7kP7x2QqByZ8PI3++xrq4cb/pVfG6cCykmwdVSzEcry9A2uNH3seBmYmoUu95jkXq3tHC8+JrpZ82sPNxsIoPr3M62BYBci3U/s4W/R6E/npUN8v13gO7EHhuuiIAvelCGJsuVL8n0bF+BG/Tn7TYKrrtTrNVLLlgU2Z66LGvTxAsrIn9uAbccNVIf2/SWBq5lKTKiG2a8MP/wAjsOrOG9ei+dRBexYxmu4vB5ofHwBkMPjM+Dj0PjemKj1Ec434wBlL+NhdbWAumTaNzLBwPjsFeJXOm29YdAeC+UbNDrUpWZwsO7jcFV0y76j'+\n\t\t\t'1TZX1YkbTWpZsJq5ZqtJscxyJyewCXvri7It6jvGbhi7uxaiKWE7x9CIv37GjWMA1zo7l1YECNcE6tT52p5e09dlNLxyyTjorwbPeWvgF79tb+Yzh6OPT81SDE5fI3i7icRPdE+ZruCT/cO/sQe3MJq6dCFZMMi3sBeSb8ulmuogiJF+NIvLmMlI4VwQ544JrwwzXuh83FlMbv0LRXke3SuGAAwAy44fnKONKnQ5DORyBp+rO5WDA7esEeCMDm4/RTaBwL9rO7kJuPF1wyvT2BfBxsO/qAmwfNzwVyMcgrsmXaNHueY5G5bwSMJtbDzISRdzHIDnlL464vQP0VwWd2IYasrx+ZgPUvxky/W/Wny2lia6Kibb0/cWqbF6LfUwo419tELcexeO+BD8G9GId3Oqi7J1DGyyE+0ocrN16HdJvmAu1wmP6bzlUrsNWqJQiC'+\n\t\t\t'qY3nfpV4GavymjCtqay7oFJ7Ta2yGvUBm26Zsbr6ZSnZFWJ6OLBeznT9bExEVt5V0Tnktfaei891xl9+XnjvuZiIXEyEvd9dWIBap77uz5iIfKwwZtuAu5DOrtm3gbIm1tevZ2uwvn5ZI3WVfdeqZ6S+Q95TCABSfjeyxd0KUH7vVvuvOzad+ltZN34+eA/MwPN8VZ2p53dMwcSuiH7GXxKgjY5LYWXV/erSgfFxpe04rNQ3i93HFaydRrpTtEF0Bhkvh7S3wfvaRCy4X1O1CuvNAzKViu9nrKdnCYLofA50XWe2Sk0NqSdAVfP3emxjP2DmcoIgNhgWLKDf1yqsJ0BVj9PQw2FzkAgRxDXKfZ4hU3tBy0zVKqwpQDzPR2HSDbvesd3M5QRBbBDu85j+bJ+QNaQqRtaCvWimxw+wH1i3SYkEQawPW1m32X2gAeAH9S'+\n\t\t\t'4wIkCm3DAA2OMcM1uFIIgO5u+9H7ZSra521BUgnudPwLQbNkxWEEFcIwyybtzrMX0I4olqZ4EpMbodR11TSss4WUEEcU3wFWvWz3eMXGRUgJ6FyaUZ1zuGaV4QQWxw9nFbrFg/URgM3RgSIDmSbToWdKNrQxysQRBEFb7WO1H/okqerZf9KmJmR8QnzY6i196Dcc78KZoEQbSfr/dMWFl4Chh0vwATAiQHlJ41O5Jx5xgGyBUjiA3FPm4LvrBJ/5DNOjxrJPhcxOye0KatIAA40LUfDpvpGZQEQbSBrawbT22+zWp1UxphSoBkZXvaTB0AcNocuMs9CSeJEEF0NN12B57afJuVJRcA8KQZ6wewdirGkzCZEQOAXqYHd7knLXRHEMR60G134Lv+Axi1FveZgwXjxLQAydHtR83WAwoidHvXLVaqEgTRQrrtDnzHuvgA'+\n\t\t\t'wBNGM19KLJ0LxvP8C7CQlgeADzqG8UnP3eSOEUSH0ATxeUHWBNM0cjDho7DgigEFS+hu9yS6abkGQbSVrawbTzcmPpY9IqABAWrEFQMKIvRJz90YYClFTxDtYH/XIL7X/7FGxAcAPmPF9SrS0NHMstllKTUPFLJjn3BP4hbXDeSSEcQ60W134Ks9E/hX69muIk/yPD/VSAM1T8UwiiAIvwBwsJE2VnMJvJ46hmWpcLxKu0/FMN63tVMtmn0qhtX+1/NUCzoVo9n1zZ+KsZfbgn/quwlbGTca5Fme5y17QEWadTLqowCGAVhe/NVt9+Ae9ySWsyEcXTt2zZyuQRCdwIjDh6/2TGCv+U3F9DgB4IlmNNQUCwgABEHoAfAaGhAhJbOZOcxm5rAkW0RkAVWrRxZQY/X1y64VC2gvtwWf7R7F/i718dwNcALAnY3EfZQ0TY'+\n\t\t\t'CA5osQAISzUcxk5jCbnoOYzwAgAVLXIwFqrL5+2UYWoG67A3e7h3CPeztGGgswa2mq+ABNFiCgNSJUZFkKYSkbwpIUxJIUIgECQAJEAgQAE9wWTHB+8K7BZotOkaaLD9ACAQJaK0JKrmSjWM0lcCUXAwBcMhDAhrZM7/oa9bXX6NVvqC/t87yBa3S+CUvP85Wv642j6vsy+d6N9GX4+rz+6+o2bbrXmHnvVduvIkC1x1OJ4b+19meVez8ux3E+6OjBAONuleAoaYn4AC0SIKAkQt8GcKhVfRAE0XKaku2qRssEqIggCI+jIEQEQWwsnuB53vQCUzO0XIAAQBCESQDPoJCqJwiis5lDYYazqdNwrNDQTGijyLMl98HCcn2CINaVpwHsWw/xAdbJAlJC1hBBdCRzAB5tdGmFWdZdgIoIgvAtAI8B6GnXGAiCQBSFNV1t'+\n\t\t\t'8U7aJkBAKVP2OEiICGK9iaJwesXTrUivG6WtAlREFqJDKAjRcFsHQxDXNnMoCI/hs7taSUcIkBJBEA4C+DRo/hBBNIviwaIvWt25sFV0nAAVka2iSRTE6CDIRSMIM8wBmEIHio6SjhUgLYIg3IDC0o698s/Jtg6IIDqLKRSWTJwEMGX2eJx2sWEESA/ZSiquNxsGxY+I9wdz8gPrnTYnCIIgCIIgCIIgCIIgCIIgCIIgCIIgCIIgCILQ8v9Pl9fKF90j8QAAAABJRU5ErkJggg==';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_button';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASAAAABwCAYAAAC+eq3DAAAbMUlEQVR4nO2dfXAU93nHv/ey97J3QgfojF6AEyBhkIN4b+CMQTaGOGlsbMd23E4T25102hlPYmeaaeIkU4dO62mbNrbzR6czSWOnyTSt0wScJo6dmCDALHYkG4GNMEjAHQYJOIFOcO97L/3j9k67q72X3dt7EXk+MxpJu/vs73dv33ue5/f7PT+AIAiCIAiCIAiCIAiCIAiCIAiCIAiCIAiCIIjZjqHeHdATjuNcANbUux8EUUWGvF5vsN6d0ItZJUAigekD4AHQKfohiD80fKIfP4B+zDKBamgBEgSnD8Au4XdnHbtDELOFIWTF6ACA/kYWpIYUII7jHkdWdO6vc1cI4mZgL4BXvV7vy/XuiJyGESCO4zoBPAXgcQCuunaGIG5OggBeBvCi1+v11b'+\n\t\t\t'crWeouQBzH9SErPOTtEETteBnA7noLUd0ESPB4ngcJD0HUk5dRRyGquQAJieVnATxd67YJgijIbgAv1DphXVMB4jjufmS9ns5atksQRFn4ADzh9Xr7a9VgTQRI8HqeRzbBTBBEY/MCsmFZ1b2hqgsQx3FrAOwBeT0EMZsYQtYbGqpmI8Zq3lyYz7MfJD4EMdtYA2C/8BmuGlXzgDiO+xayyeaqczUVRCLDAwAmUkEkkP07k7sgM31tBjORH9PrmvyxTJXum8dQsm3t967wmgqfe73a1v3e5djp3L7DwGApk50i5zQyWMo0K9yhKnzZ6/W+UI0bV0WAOI57CVXK91xLBTGeDGA8FcDVVBA30mGIP4Di32IBUjqPAsdmXKPRPv93Feyn/1Z+7OW2X7I/Rduurb2ynaFCe+VzldiK2y5mV7m9AQtMLJYxzei1utFrbcGy'+\n\t\t\t'6onSy16v9wm9b6q7AFVDfC4lAxjhffDzF5HI8AovIAmQ1vZJgJTPzRYBkts7jAy8tjbsZD1YbW2BzuguQroKkJ7ik8jwGOV9OJEYQSgdLvEhJgHS2j4JkPK52SpA4t+tJhYPOruwk10Mp5GBTugqQroJkF7ik8jwGE6MYDhxWuLtkAAVsiMBqsxe+dzNIEC5fxxGBg86u/AZ5zK9hOgFr9f7ZT1upIsACZnylyq9z8nECIbiJ5TDLBKgAnYkQJXZK5+7mQQod8xhZPCkqxefYBdDB57QY3V9xQIkLCbdX8k9rqWCGIwP4VIyoFEESIC0tk8CpHzuZhSg3O/V1hZ8dd56tJpYVMidlc6arkiAhAWlR1FB+YwzvA8DsaH8MDoJEAkQCVB1BSiD7DD+k65e3FOZNxQEsKSSGdOVTkTcA43ik8jw4KID4KIDefEhCKI2hN'+\n\t\t\t'I8/unau/jHyXcruY0LWQ3QjGYBEiYaaioAn8jw+G2kH2d4n9bmCYLQgdfD5/GFy79DKK3ZCegTtEATmkIwYX3XUS22OfGZTAXVueYUghWwoxCsMnvlczd7CCa3W8Y040X3HZWMki3RUlNIqwf0vBajRIbHm4L4EATROIzyU3gqcKgST+glLUaqBUgYcu9Ta0fiQxCNzSg/hS9pF6E+LQtXVQmQqK6Pat6ODpD4EESDM8pP4Tntieln1Rqo9YCehoZRr/fjw7iQvKjWjCCIOvBWdBwvXf9Qi2mn2oR02QIkeD9Pqe3RlVQA7ydOqDUjCKKO/OD6SRyNT2gxfUrQirJQ4wE9DpXeTyLD40hsQI0JQRANwnPX3tWSD3JBxU43agRItffzQeIEwumwWjOCIBqAS8kIfnD9pBbTsnNBZQmQsJtFp5oeTKaDOJUYUWNCEESD'+\n\t\t\t'8dMbZzDCT6k16xQ0oyTlekCPqe3Be7Gq1rImCKJGfHfyuBazXeVcVFKAhISSqt1Lr6QCuJIKqDEhCKJBORqf0JKQfrycZHQ5HpDqrZM/iNOoF0HcTLxyY1SLWUntMJdxk7JcqRzhdJi8H6LqrLW2Y5GwQ0QkzeM3EU0fEKJMDkXHMZ6MoM2sqobQLmT3ni+I7h7QaZ4Sz0R1mW9i8UTzBtznWIm72S58mKAvvFrwSki1yPeVuqCoAAnVDlVxjkpsEFXmSddmsAYGkQyPf752EB8lVY/SEBo4FB1Xa+IqpSGlPKCixnKupAJUXIyoKmus7YikeZxKBPBtEp+aMp6MaBmS7yt2slQOaJuali7Sei+iygzFxzAUH5PUgiJqx2thP55y9aoxWV3sZCkBUlXx8EqyvrH4OluP5P/j8RHEVXhkC81urLB0osPsxhzjdLItkA'+\n\t\t\t'riQjKAo7FRTBWZ2d1sdGCdrQuLzG7cYpoegZxKR3CeD2CEv4jTiTGJzRa7tM8ZzCR3bCjmR1DWvs3AYJO9GyuYNrSap9s8xwdwMjGG9+J+xIo8B3YDg/U2D3os7VjKuCXnzvABnIiPYSDmR1SDZ/tJR4/kAckf29VUGKf5AK6mImXdb5HZhTW29vx9PuKDeC9ePCzYYvegRSi+Lm8/A2AiFcHJRAABhT70WN1YaZne3K8/4pdc90jTSsm95Pe+kozAxwdxVqXXsMDE4j5nF1ZZ3JLtl8NpHscTAXDRcXCxMYTSSVX31YOjMdXD8X3FThb8+hDG8CfLbYXP8Ph5aK+mqoJlVZ0rWlXQgFazG592SB22/dFBnEr4SlYkbDI6sJ3dgA6z9AOoxNH4CPojx2b0+U52NdZZu0van08G8KvQYF5Inpn3UEmbHD+8fgA+flrk'+\n\t\t\t'b7W0437nRtgMhavYxTI8fnZjEMOC8Ikf/91sD263dxW1B4BohsdvwsM4GJ1OQpbzGr7o/kzJxwQAv4uM4pfh4bzIFapo+PicDfDaPXm7SIbHVwOvIyLeP05m/7W5W7HCUnqH0INRP3504zgiaT5fEfEh50p8xjktMruvHsJwYnrnllfaHizr8V1JRbA/4sdPbpyc+fhEfzuMDP6kaSV2ObpK3jOU5vGvk++Ci40r3lNtRUQ19ocXPVCyfzLmFipcXywHpMr7mUzXt9bPcqZzxrFeS+kXssXkwmeb7i5LfABgrbUbC0XXWg0MPjfn7rLEBwAWm93YYCvdr1K0ml14tMlbUjwAYDI989v94aYN2M6uLMvebmCwy7kajzZt0NTXUtzFduGxOcXvPd/ESsQHAFgDg7W2dl36sNXuwTfnbdXlXnJuMbH4bNNKPO/eDkeBkq'+\n\t\t\t'cOI4Pn5m8tS3yA7K4Wz87fhB367PGlCg2TEgtqSbEQrFNNC8E6FhtzGlkst3hmHJ9vcqHF5MJEUrlvVgOD+53bYJV9CC8mA7ggCic7zO686LwRHpSc+4RjoyTcArIh1yh/EXHhm7nZ4EC3pR1WA4P3437sixxT7M9UOoJjcd+M47lvnqDI/d8mC92Oxv3YHxlGMB1BJ+PGZlsXVlra8R9TB3FJ9vi3sz1YZ5U+X/EMj2NxH/z8FOIAFphcuN3uASt6bjbaPJhMR/BGeFix/8UIp8M4xfsRTgPhtAGskcVWkaCstrZjucWN0wWG1L32TsXjO9guHI76y+7H8fgwQmkglDEgAwZbbJ68KHjMzbjD7sFBFffLEU6HMcr7Ec8ANoMDTiOLNrMLdtHzt4Rpxt/P34pvXD2IsGyV+dOu9ZJwC8i+H4biPvj4KRjBYAnjxjpr'+\n\t\t\t'O1iRiH1l7nqE0zwOx1SPUGnmdGIKa9XtO19wRrRuAhTO1G/V+3JLZ/7vnBufe+FXWbqxP6lcEmSLfc0M8XkzMojhhA+ANPxbKbSROwcAi8xudDHSb+ATCT/2RYbyuaecKzsn6sDHrB68FS384Q2mwzgUHZ7pIsuKowNApyxfszc0mL/mHB/AOT4Al5Gd4f3MNbHYzq6UHDuV8GFf9BiupXiE0waEMkA4fR7/deMk/rJ5PTaJvIyd7EoMxHxl521yhDMRHI0N43IKuJwy4ErKgN/HJvCVuevz1yxnigiQbVqsohk+//ouMjfjVou77LlAx+IncDllwKWUAZeSBrwZGce3W+7In99ga9MmQJkIjsVP4HragKk0MJU24HoauN3WjQedK/Mit4Rpxhfm9OLF4HTVwVVWt+Q5BoBTCT9+FR4QXgsDQmlgX/Q8WMNJfGXuZo'+\n\t\t\t'lY/ZWrF4cv1U6AQurzgWsA7FU6Uem+YHnq6QF9zDId/rwX8+Od2PQb6FaLZ4bIAFnvZ4XMazoUPYaTIoERM5zwScQHANbapGHXR8kAfh0eUEx8T6XDOFxEfNQiD52UQqmgQujllfV5MhXEweig4vSJcJrHdybfxWWZ2NxhLy/cLMUl2X3tBcJBr92D+aJdPF+YfBMRUX9vt2kPQ+ThhMNg0XwvJV6LjOLvr70tOXYX65GEYvc6lknOn09eRH9U+UvzSiqCv7v2tqROzwITi501DMWOxvQbbComQEWHzxqF5ZZOWERv3OMJHzjZN9itIg8pxxKmQ/J/PMNjKK5uFrfc+3k3VrtZ4B/KRtOemLMVa62ekjmdHqu0zx+WKJkSzvB4WVYTpotR5X4XpEsWchQaaRN7P5dTQQTTEQzFph+/PFRUgzyUCGcSmu5TjGOJAIZk'+\n\t\t\t'Qvdxkccj937ejxf/orqcjOD1yHnJsV5reTnMOtFc6ESxEEzzdsu1pFuUfA6kgriSmsJYEgikInAL35qrrN04JhMX8TA7kM37qGGRQtJ6lB9TuLJ8PGY3vlFgVMzPB/DD6wfy/78TG8EKy/Qbt9XswgPODXgA2XzQycQYTiZm9meu7HGXs25PPvTablb/1nAYWKy19RTMAQHAkZhvht18E4vllunn+mgsOxJ3IOqXJKV3OLrwaqh08awFZjcsBgNaTBbsYN3YYpP2YbBKuZSh+ATWiMRuQf69OfN9FEwHUWp+09F4AA85pz0nHfZ5ryaaktCqqMco2HyTC20iITiVmPZ8/i88ij+fk50w1WRksYRpx7kiAjExy3bs8PEB7A0N4h7H6hlez1qrB2utHpzjA/h5aBCTRfI12dxd8Tf7uMp8jxIOowPrrD0Fz//n9UHFvN'+\n\t\t\t'K9DqnNOT472XU4MYErqQhuET54t9s8ZQnQTrav4LmTiQkc0pD/0ZNyF3LLS6X2qksKNwy65YD4OizBEOd+AEi2ej4SlYqNUhgmRilP1OgMxX349+CbeDs2qpjvWcK48adNm8saai9Gk/bdMktyLD6G567tw5HYzA8+a2CwWhSenOF9SGD6fcaJXuMWE4u1Vu1D8q9HRvGd4BHN9nox16gt8DijfolEQ6CbB+QyugTXsTZYDAw8ojxOMB3EfGE43Gkw4GrKgEvJCFqF8gFLmHY0GR24LkwAlCeKy50HlGNK4QPfbHQUnSldCn8ygB9fP1DWKFiOYDqCX4eP4dfhY1hgdmGzrQtrRUPsbWYX1to84IRJhLEMLxGkDnPHjNnZcuR5kmsaPKILySB+FjqOXks77mSn57qM8AFcKDBNYrMstxNJR7DQ7IbNYMAc40zPbCfb'+\n\t\t\t'haPx4o/lw8RE/rk8mQhIZkIXeo71QB4i5RL7Z3npY2cMDFiDAyEUf467Zfkz+UDBbEE3AbLU2IPoliWfXUbXjJnQcnqtXXgrmp2DI8/5tJhc6DC7y84FXU+HcT0dkeSSbrN6wOk40qWWS8kg9oQGMZ4M4lOO6TGEHkt7XoCGE2OSOUBLGU9JAXrIKZ0cd4ZXPwoSzfAYSQRwgQ9ik92TH/H6Y0cPjkT9klGtHNtlo22rrD1YZS3cxq2WFsw3sZgo8mF87tpBAMqzgqvFAhOLLfY2ybEP4tnnMJzmcY6fwhKRoCxlOnElVfx99FCT9DU5Fp+dJUmKhWC+WnVCC/LwqxzEYdhEKjhDbLbaVxcMxawGBm7ZhMMTsmF5r61nxqREMR+zdhY8pwWX0aF4/FKqsDv+nizUWWTuQDczcxJnjh2sB6tlHtCAQrhULtEMj/2i4m'+\n\t\t\t'F2A4OHm2YOuC63uCVD7+Wyg618lrmeuE0s/nbeZjhFYew7sTFcEYnkL8LSOjurrT2YXyQU++u56yQeVSjN47eyUbEG40ChE8U8IFXvMkbn+RPF8DAdcIo+fDfSEYREoY98nVeT4KVk5/504kNBOAZiw+hwTntNLSYXHm3agXdiwzjLX0Qsw8NqYLCM6cBWNvsheSM8gDNCMvu92Ahus3RKvKDPz7kbXGwYH8T9+XCs29KO9bZuLDa7sdjsxq/CynM8bAYGHsYtDcFE/0QzfH5Wc6vZhcfmbIOPD2BPaFCy4LTVJHXPx0UlK84KkxSXiCYy9rEb4TbfAi46grPp7LWLzc24k+3CNtlI1QfxMU0ekJjXwsP4uG16bs8mmwdHYn7JJMTtdqmQnBatwZJiwK2itV5b7B785IamIuoVYTEwaDW70ZQ2wJUBLHBgEePGamu7'+\n\t\t\t'JIwMp3l8f0rav30RP+51dEkmF97r3IZ3YyMYjPsRFsL9ddY23M12o0e2tm1P+IzW/dw10aquKmJRdAvB5ppcNSvHIf/GPhgdwJjgzYhd6wyyXs+d9ul1Rr3WrrwAXUwGMBAbxkbRKvo5RhY72A0AlNcm3ef04hchDqP8GOIZHq+GODzSJF3O4bX1wGtTHvFZJYQ/v1QQoQUmF/6sqXAY6ROG4nPiYzMwWGFpxzPz7ssvUrUZGMmqeADgZPOTfnT9CP6ieSvaRNfdZvHgNoXlLGLGkkH8943BoteUy2vhYXxOtP7rYWcv/uHaPgDZoffVooTy1VQE/zKpHDplYMDfzN2aFyHWwGCL3YO3ajya5TK6io6wAVnx+ebVgxLvJ8eLwUE8N39rfoKi1cDAa++B11545BAAjscn8GNte3dpps2s7HlroVgIpmpfHdZQm3kITq'+\n\t\t\t'NDknwOpcMYL5K3OZXwSWb5tgjrw3L8PjaMQ1HltVlKBFJBBEQhTiAVxCs3DpRd9iOe4XG+wrIlrQphXifjRifjniE+Pw8NStaQAdlE9PemDmK8QPJXibFkEP8WPKipLIcSb8f8kuTzQrMLnxaG3OW5nzcjxSdLHpaFhI0WhgHAB4kJfDmwD+cKjFad5afw9QLiVAguNo7dslnWtUCeAC+D/kIninlAqoa05hbJfejJbbLcz2m+9DfdqYQPq0Sr1Xut3dgXmfZAjsVHcDEZwB/ZerCUUR7KjWd4HI2P4L3YzBpDV1JBfG/qNayzdWO9tbtgHun9uB9vRYcrGikDICxQDGAb24MVlvaCyzB+FhrEuQLhUjTD47vBfVhn8+ButmfGBMUck6kIfhMZxkDMr3vC9n9Dx/G0a3oF+l1sF47EfNgsC/uGSoxsHY768WhTbz7U'+\n\t\t\t'WWxuxiJzM87XuVriicQEzvFB/C7ixzl+quTzd5afwhcD+7DL0YVdjq6CK+ePxyewJzSaL8VRa1QWpgeKaEnRGWgcx6l6z/3PjZ/WrR6Q0rnybKXHrAYmPyIGZIUnkAziI4UQr1CfFwoFyWxGBhkA5/kALieD+dXxZT/m3N8K/Z/+2wAP40arqRk2owWTqTAupaby3k0he/nvNrMLbeZmzDM6kAEwmQ7jYnIKY3xQW5/L6rs6e2U7Q4X2yucqsRW3XcyulP1SczNWWd15ITqTmMJZPphfQ5cRfXy1tF+ybwr2TiODNzo+DTV4vd6COlMqB+SDilXxHeYOXJjlZVnjGR4XhHIcYgFTw0fJgFSwMqpvoQofH4CPDyi+wcplLBnEmFi0NN6H0I+z/BTOijynRng9VJbhAEqkckrNhO5X09ItpoZeEEcQRIWsU7/otSIBKj'+\n\t\t\t'87C6DDrE91OoIgGpM7ZBMqy6DgHCBAZw/IYXRoXstCEERjs9baoiUB3V/sZFEB8nq9Q1A5I3q5hhnKBEE0Pp9yFJ8npoDP6/X6il1Qzmr4fjUtLjR3gJmFK8sJgiiM08hgq/rwS7EMq5hyBOhVNS0yBga3WparMSEIosF5pKlLsp6tTH5Y6oKSAuT1evdC5aTE5Ux3zVfHEwRRHZxGBo84l5W+UIpPSOEUpdyCZC+radlCXhBB3DRUy/sByhegF9W2vpzpplwQQcxyWs2sFu8HKNNpKUuAhEx2v5rWLQYGm2wb1ZgQBNFgfMnVq8X72Vtq9CuHmprQu9X2YqG5AwvNHaUvJAii4bjD3qZl4iGgImIqW4C8Xm8/VHpBALDJtpES0gQxy2g1sfj6vPWlL5xJv6AVZaF2VwzVXpDFwGC7vU+tGUEQdeS5lk1aQi9ApUao'+\n\t\t\t'EiCtXtBckwub7JQPIojZwDPz1mspOgao9H4AbfuCPaHBBkuZTqygZRoE0dB80dWLT2rfZ161NqgWICG7rToUA4D1tjVYKtpKmSCIxuEex2I8rG3IHQB2lzvyJUbrzqgvQOO2PZvtG8kTIogG44uuXjwzV1PSGQCGvF7vt7QYahIgr9cbhMZQDAA22NZgM+WECKIh+Nq89XhIu+cDVKAFmveGF5JNmkIxAFjGdGKno4+G6AmiTjiNDL6/4C7coz3nA2RDL1U76IgpWpS+HDiO2w+gT6t9IsOjP3oYlwoUfa91UXr1bWsrKq9nUfpK2q9lUXkqSq+3vfai9Fvsbfjq3PVah9pz7PV6vQ9UcgM9NiZ8AMBRqCheL8ZiYLCT7cPJxAiG4icke3gRBKEvDiODJ129lXo9QLbWs+bQK0fFHhAAcBy3BsB+ABXVY01keAzEhj'+\n\t\t\t'DK+8gDKmE//Td5QJXZK5+7GT2gB53L8NiclZV6PUC2PM+dlYReOXQRIEA/EQKyu50OxYclQkQCVMiOBKgye+VzN5MA7XQsxufnrESrSZfdi3UTH0BHAQIAjuP6kBUhXUhkeAwnRjCS8CGUDpMAKdqRAFVmr3xutgvQAhOLB51d2Mku1sPjyaGr+AA6CxCQF6E90METEnMtFcQI78N4MoCrKekGeiRA2tsnAVI+NxsFaBnTjF5rC3ayHizTtpSiGLqLD1AFAQL0DceUSGR4XE0FMZ4KIJQO40Y6IvyEZ76JhH9IgIq3RQI0ewToFhOLBWYHbjGxaDU70GtpwVKmWU9PR05VxAeokgABeRHaA42jYwRBNARDAJ6ohvgAVRQgAOA4zoWsCPVVsx2CIKpCP4AHhJUPVaGqApSD47hvAXi2Fm0RBKELu7Wu71JDTQQIyCen'+\n\t\t\t'XwKFZATRyPiQ9XqqEnLJ0bwWTC3C2rG1yK6kJwii8dgNYG2txAeooQckRkhQPw/KDRFEI9CPbKLZV+uG6yJAOYSw7FmQEBFEPehHNtfTX68O1FWAcpAQEURN6UedhSdHQwhQDo7jOgE8BeBxVGkSI0H8gRJEdrfSF+sRahWioQRIDMdx9wPYBeB+kBgRhBaCAPYCeNXr9e6td2eUaFgBEiMkrfsAbAOwBjSUTxBK+JCduXwA2S1yajaapZVZIUByhBnWOSHqFA5vq1d/CKIOHBB++4SfoWrOWCYIgiAIgiAIgiAIgiAIgiAIgiAIgiAIgiAIgijE/wOebvWiigM4MAAAAABJRU5ErkJggg==';\n\t\tme._out__img.ggOverSrc=hs;\n\t\tel.ggId=\"Out\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_button \";\n\t\tel.ggType='button';\n\t\ths ='';\n\t\ths+='bottom : 3.04348%;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 5.1087%;';\n\t\ths+='position : absolute;';\n\t\ths+='right : 2.08333%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 20.4861%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='100% 100%';\n\t\tme._out.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._out.onclick=function (e) {\n\t\t\tme._in.style[domTransition]='none';\n\t\t\tme._in.style.visibility=(Number(me._in.style.opacity)>0||!me._in.style.opacity)?'inherit':'hidden';\n\t\t\tme._in.ggVisible=true;\n\t\t\tme.__menu.style[domTransition]='none';\n\t\t\tme.__menu.style.visibility='hidden';\n\t\t\tme.__menu.ggVisible=false;\n\t\t}\n\t\tme._out.onmouseover=function (e) {\n\t\t\tme._out__img.src=me._out__img.ggOverSrc;\n\t\t}\n\t\tme._out.onmouseout=function (e) {\n\t\t\tme._out__img.src=me._out__img.ggNormalSrc;\n\t\t}\n\t\tme._out.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__menu.appendChild(me._out);\n\t\tme.divSkin.appendChild(me.__menu);\n\t\tel=me._screentint_image=document.createElement('div');\n\t\tel.ggId=\"screentint_image\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_rectangle \";\n\t\tel.ggType='rectangle';\n\t\ths ='';\n\t\ths+='background : rgba(0,0,0,0.392157);';\n\t\ths+='border : 0px solid #000000;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 100%;';\n\t\ths+='left : 0%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0%;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 100%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._screentint_image.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._screentint_image.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('vis_image_popup') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._screentint_image.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._screentint_image.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._screentint_image.style[domTransition]='';\n\t\t\t\tif (me._screentint_image.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._screentint_image.style.visibility=(Number(me._screentint_image.style.opacity)>0||!me._screentint_image.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._screentint_image.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._screentint_image.style.visibility=\"hidden\";\n\t\t\t\t\tme._screentint_image.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._screentint_image.onclick=function (e) {\n\t\t\tplayer.setVariableValue('vis_image_popup', false);\n\t\t}\n\t\tme._screentint_image.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.divSkin.appendChild(me._screentint_image);\n\t\tel=me._image_popup=document.createElement('div');\n\t\tel.ggId=\"image_popup\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='height : 80%;';\n\t\ths+='left : 10%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 10%;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 80%;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_popup.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_popup.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('vis_image_popup') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._image_popup.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._image_popup.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._image_popup.style[domTransition]='';\n\t\t\t\tif (me._image_popup.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._image_popup.style.visibility=(Number(me._image_popup.style.opacity)>0||!me._image_popup.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._image_popup.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._image_popup.style.visibility=\"hidden\";\n\t\t\t\t\tme._image_popup.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._image_popup.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._loading_image=document.createElement('div');\n\t\tels=me._loading_image__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PHN2ZyBoZWlnaHQ9IjY0IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGZpbGw9IndoaXRlIiB3aWR0aD0iNjQiIHZpZXdCb3g9IjAgMCAzMiAzMiI+CiA8Y2lyY2xlIHI9IjAiIGN5PSIzIiBjeD0iMTYiPgogIDxhbmltYXRlIGNhbGNNb2RlPSJzcGxpbmUiIHJlcGVhdENvdW50PSJpbmRlZmluaXRlIiBhdHRyaWJ1dGVOYW1lPSJyIiBiZWdpbj0iMCIgZHVyPSIxcyIga2V5U3BsaW5lcz0iMC4yIDAuMiAwLjQgMC44OzAuMiAwLjIgMC40IDAuODswLjIgMC4yIDAuNCAwLjgiIHZhbHVlcz0iMDszOzA7MCIvPgogPC9jaXJjbGU+CiA8Y2lyY2xlIHI9IjAiIGN5PSIzIiBjeD0iMT'+\n\t\t\t'YiIHRyYW5zZm9ybT0icm90YXRlKDQ1IDE2IDE2KSI+CiAgPGFuaW1hdGUgY2FsY01vZGU9InNwbGluZSIgcmVwZWF0Q291bnQ9ImluZGVmaW5pdGUiIGF0dHJpYnV0ZU5hbWU9InIiIGJlZ2luPSIwLjEyNXMiIGR1cj0iMXMiIGtleVNwbGluZXM9IjAuMiAwLjIgMC40IDAuODswLjIgMC4yIDAuNCAwLjg7MC4yIDAuMiAwLjQgMC44IiB2YWx1ZXM9IjA7MzswOzAiLz4KIDwvY2lyY2xlPgogPGNpcmNsZSByPSIwIiBjeT0iMyIgY3g9IjE2IiB0cmFuc2Zvcm09InJvdGF0ZSg5MCAxNiAxNikiPgogIDxhbmltYXRlIGNhbGNNb2RlPSJzcGxpbmUiIHJlcGVhdENvdW50PSJpbmRlZmluaXRlIiBhdHRy'+\n\t\t\t'aWJ1dGVOYW1lPSJyIiBiZWdpbj0iMC4yNXMiIGR1cj0iMXMiIGtleVNwbGluZXM9IjAuMiAwLjIgMC40IDAuODswLjIgMC4yIDAuNCAwLjg7MC4yIDAuMiAwLjQgMC44IiB2YWx1ZXM9IjA7MzswOzAiLz4KIDwvY2lyY2xlPgogPGNpcmNsZSByPSIwIiBjeT0iMyIgY3g9IjE2IiB0cmFuc2Zvcm09InJvdGF0ZSgxMzUgMTYgMTYpIj4KICA8YW5pbWF0ZSBjYWxjTW9kZT0ic3BsaW5lIiByZXBlYXRDb3VudD0iaW5kZWZpbml0ZSIgYXR0cmlidXRlTmFtZT0iciIgYmVnaW49IjAuMzc1cyIgZHVyPSIxcyIga2V5U3BsaW5lcz0iMC4yIDAuMiAwLjQgMC44OzAuMiAwLjIgMC40IDAuODswLjIgMC4yID'+\n\t\t\t'AuNCAwLjgiIHZhbHVlcz0iMDszOzA7MCIvPgogPC9jaXJjbGU+CiA8Y2lyY2xlIHI9IjAiIGN5PSIzIiBjeD0iMTYiIHRyYW5zZm9ybT0icm90YXRlKDE4MCAxNiAxNikiPgogIDxhbmltYXRlIGNhbGNNb2RlPSJzcGxpbmUiIHJlcGVhdENvdW50PSJpbmRlZmluaXRlIiBhdHRyaWJ1dGVOYW1lPSJyIiBiZWdpbj0iMC41cyIgZHVyPSIxcyIga2V5U3BsaW5lcz0iMC4yIDAuMiAwLjQgMC44OzAuMiAwLjIgMC40IDAuODswLjIgMC4yIDAuNCAwLjgiIHZhbHVlcz0iMDszOzA7MCIvPgogPC9jaXJjbGU+CiA8Y2lyY2xlIHI9IjAiIGN5PSIzIiBjeD0iMTYiIHRyYW5zZm9ybT0icm90YXRlKDIyNSAx'+\n\t\t\t'NiAxNikiPgogIDxhbmltYXRlIGNhbGNNb2RlPSJzcGxpbmUiIHJlcGVhdENvdW50PSJpbmRlZmluaXRlIiBhdHRyaWJ1dGVOYW1lPSJyIiBiZWdpbj0iMC42MjVzIiBkdXI9IjFzIiBrZXlTcGxpbmVzPSIwLjIgMC4yIDAuNCAwLjg7MC4yIDAuMiAwLjQgMC44OzAuMiAwLjIgMC40IDAuOCIgdmFsdWVzPSIwOzM7MDswIi8+CiA8L2NpcmNsZT4KIDxjaXJjbGUgcj0iMCIgY3k9IjMiIGN4PSIxNiIgdHJhbnNmb3JtPSJyb3RhdGUoMjcwIDE2IDE2KSI+CiAgPGFuaW1hdGUgY2FsY01vZGU9InNwbGluZSIgcmVwZWF0Q291bnQ9ImluZGVmaW5pdGUiIGF0dHJpYnV0ZU5hbWU9InIiIGJlZ2luPSIwLj'+\n\t\t\t'c1cyIgZHVyPSIxcyIga2V5U3BsaW5lcz0iMC4yIDAuMiAwLjQgMC44OzAuMiAwLjIgMC40IDAuODswLjIgMC4yIDAuNCAwLjgiIHZhbHVlcz0iMDszOzA7MCIvPgogPC9jaXJjbGU+CiA8Y2lyY2xlIHI9IjAiIGN5PSIzIiBjeD0iMTYiIHRyYW5zZm9ybT0icm90YXRlKDMxNSAxNiAxNikiPgogIDxhbmltYXRlIGNhbGNNb2RlPSJzcGxpbmUiIHJlcGVhdENvdW50PSJpbmRlZmluaXRlIiBhdHRyaWJ1dGVOYW1lPSJyIiBiZWdpbj0iMC44NzVzIiBkdXI9IjFzIiBrZXlTcGxpbmVzPSIwLjIgMC4yIDAuNCAwLjg7MC4yIDAuMiAwLjQgMC44OzAuMiAwLjIgMC40IDAuOCIgdmFsdWVzPSIwOzM7MDsw'+\n\t\t\t'Ii8+CiA8L2NpcmNsZT4KIDxjaXJjbGUgcj0iMCIgY3k9IjMiIGN4PSIxNiIgdHJhbnNmb3JtPSJyb3RhdGUoMTgwIDE2IDE2KSI+CiAgPGFuaW1hdGUgY2FsY01vZGU9InNwbGluZSIgcmVwZWF0Q291bnQ9ImluZGVmaW5pdGUiIGF0dHJpYnV0ZU5hbWU9InIiIGJlZ2luPSIwLjVzIiBkdXI9IjFzIiBrZXlTcGxpbmVzPSIwLjIgMC4yIDAuNCAwLjg7MC4yIDAuMiAwLjQgMC44OzAuMiAwLjIgMC40IDAuOCIgdmFsdWVzPSIwOzM7MDswIi8+CiA8L2NpcmNsZT4KPC9zdmc+Cg==';\n\t\tme._loading_image__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"loading_image\";\n\t\tel.ggDx=0;\n\t\tel.ggDy=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='height : 40px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 40px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._loading_image.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._loading_image.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=(this.ggDy + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._image_popup.appendChild(me._loading_image);\n\t\tel=me._popup_image=document.createElement('div');\n\t\tels=me._popup_image__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_external';\n\t\tels.setAttribute('style','position: absolute;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.onload=function() {me._popup_image.ggUpdatePosition();}\n\t\tel.ggText=basePath + \"\";\n\t\tels.setAttribute('src', el.ggText);\n\t\tels['ondragstart']=function() { return false; };\n\t\ths ='';\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"popup_image\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_external \";\n\t\tel.ggType='external';\n\t\ths ='';\n\t\ths+='border : 0px solid #000000;';\n\t\ths+='cursor : default;';\n\t\ths+='height : 100%;';\n\t\ths+='left : 0%;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0%;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 100%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._popup_image.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._popup_image.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('vis_image_popup') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._popup_image.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._popup_image.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._popup_image.style[domTransition]='';\n\t\t\t\tif (me._popup_image.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._popup_image.style.visibility=(Number(me._popup_image.style.opacity)>0||!me._popup_image.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._popup_image.ggSubElement.src=me._popup_image.ggText;\n\t\t\t\t\tme._popup_image.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._popup_image.style.visibility=\"hidden\";\n\t\t\t\t\tme._popup_image__img.src = '';\n\t\t\t\t\tme._popup_image.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._popup_image.ggUpdatePosition=function (useTransition) {\n\t\t\tvar parentWidth = me._popup_image.clientWidth;\n\t\t\tvar parentHeight = me._popup_image.clientHeight;\n\t\t\tvar img = me._popup_image__img;\n\t\t\tvar aspectRatioDiv = me._popup_image.clientWidth / me._popup_image.clientHeight;\n\t\t\tvar aspectRatioImg = img.naturalWidth / img.naturalHeight;\n\t\t\tif (img.naturalWidth < parentWidth) parentWidth = img.naturalWidth;\n\t\t\tif (img.naturalHeight < parentHeight) parentHeight = img.naturalHeight;\n\t\t\tvar currentWidth,currentHeight;\n\t\t\tif (aspectRatioDiv > aspectRatioImg) {\n\t\t\t\tcurrentHeight = parentHeight;\n\t\t\t\tcurrentWidth = parentHeight * aspectRatioImg;\n\t\t\t\timg.style.width='';\n\t\t\t\timg.style.height=parentHeight + 'px';\n\t\t\t} else {\n\t\t\t\tcurrentWidth = parentWidth;\n\t\t\t\tcurrentHeight = parentWidth / aspectRatioImg;\n\t\t\t\timg.style.width=parentWidth + 'px';\n\t\t\t\timg.style.height='';\n\t\t\t};\n\t\t\timg.style.left='50%';\n\t\t\timg.style.marginLeft='-' + currentWidth/2 + 'px';\n\t\t\timg.style.top='50%';\n\t\t\timg.style.marginTop='-' + currentHeight/2 + 'px';\n\t\t}\n\t\tme._image_popup.appendChild(me._popup_image);\n\t\tme.divSkin.appendChild(me._image_popup);\n\t\tel=me._x=document.createElement('div');\n\t\tel.ggId=\"X\";\n\t\tel.ggDx=0;\n\t\tel.ggDy=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='height : 100%;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 100%;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._x.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._x.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=(this.ggDy + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._image_popup_close=document.createElement('div');\n\t\tels=me._image_popup_close__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmVyc2lvbj0iMS4xIiB5PSIwcHgiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBiYXNlUHJvZmlsZT0idGlueSIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgaWQ9IkxheWVyXzEiIHg9IjBweCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZmlsbD0iIzAwMDAwMCIgZD0iTS0xMzUuMywzNTcuM2MtMjEuOS0yMS45LTU3LjUtMjEuOS03OS40LDBjLTIxLjksMjEuOS0yMS45LDU3LjUsMCw3OS40YzIxLjksMjEuOSw1Ny41LDIxLjksNzkuNCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTtTLTExMy40LDM3OS4yLTEzNS4zLDM1Ny4zeiBNLTE0NS44LDQxMi43YzAuOCwwLjgsMC44LDEuNS0wLjEsMi40bC0xMC45LDEwLjljLTAuNCwwLjQtMC44LDAuNS0xLjMsMC41Yy0wLjUsMC0wLjktMC4xLTEuMS0wLjQmI3hkOyYjeGE7JiN4OTsmI3g5O2wtMTUuOC0xNS44bC0xNS43LDE1LjdjLTAuNCwwLjQtMC44LDAuNS0x'+\n\t\t\t'LjMsMC41cy0wLjktMC4xLTEuMS0wLjRsLTExLjEtMTEuMWMtMC4zLTAuMy0wLjQtMC42LTAuNC0xLjFjMC0wLjUsMC4xLTAuOSwwLjUtMS4zJiN4ZDsmI3hhOyYjeDk7JiN4OTtsMTUuNy0xNS43bC0xNS44LTE1LjhjLTAuMy0wLjMtMC40LTAuNi0wLjQtMS4xYzAtMC41LDAuMS0wLjksMC41LTEuM2wxMC45LTEwLjljMC45LTAuOSwxLjctMC45LDIuNC0wLjFsMTUuOCwxNS44bDE1LjctMTUuNyYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuOS0wLjksMS43LTAuOSwyLjQtMC4xbDExLjEsMTEuMWMwLjgsMC44LDAuOCwxLjUtMC4xLDIuNGwtMTUuNywxNS43TC0xNDUuOCw0MTIuN3oiLz4KIDwvZz4KID'+\n\t\t\t'xnIGlkPSJMYXllcl8yIj4KICA8cGF0aCBmaWxsPSIjRkZGRkZGIiBkPSJNLTE2MS42LDM5Ni45bDE1LjgsMTUuOGMwLjgsMC44LDAuOCwxLjUtMC4xLDIuNGwtMTAuOSwxMC45Yy0wLjQsMC40LTAuOCwwLjUtMS4zLDAuNSYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjUsMC0wLjktMC4xLTEuMS0wLjRsLTE1LjgtMTUuOGwtMTUuNywxNS43Yy0wLjQsMC40LTAuOCwwLjUtMS4zLDAuNXMtMC45LTAuMS0xLjEtMC40bC0xMS4xLTExLjFjLTAuMy0wLjMtMC40LTAuNi0wLjQtMS4xJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC0wLjUsMC4xLTAuOSwwLjUtMS4zbDE1LjctMTUuN2wtMTUuOC0xNS44Yy0wLjMt'+\n\t\t\t'MC4zLTAuNC0wLjYtMC40LTEuMWMwLTAuNSwwLjEtMC45LDAuNS0xLjNsMTAuOS0xMC45YzAuOS0wLjksMS43LTAuOSwyLjQtMC4xJiN4ZDsmI3hhOyYjeDk7JiN4OTtsMTUuOCwxNS44bDE1LjctMTUuN2MwLjktMC45LDEuNy0wLjksMi40LTAuMWwxMS4xLDExLjFjMC44LDAuOCwwLjgsMS41LTAuMSwyLjRMLTE2MS42LDM5Ni45eiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._image_popup_close__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._image_popup_close__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmVyc2lvbj0iMS4xIiB5PSIwcHgiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBiYXNlUHJvZmlsZT0idGlueSIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgaWQ9IkxheWVyXzEiIHg9IjBweCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZmlsbD0iIzAwMDAwMCIgZD0iTS0xMzAuOSwzNTIuOWMtMjQuNC0yNC40LTYzLjgtMjQuNC04OC4yLDBjLTI0LjQsMjQuNC0yNC40LDYzLjgsMCw4OC4yYzI0LjQsMjQuNCw2My44LDI0LjQsODguMiwwJiN4ZDsmI3hhOyYjeDk7JiN4OTtTLTEwNi41LDM3Ny4zLTEzMC45LDM1Mi45eiBNLTE0Mi41LDQxNC41YzAuOCwwLjgsMC44LDEuNy0wLjEsMi43bC0xMi4yLDEyLjJjLTAuNCwwLjQtMC44LDAuNi0xLjQsMC42Yy0wLjYsMC0xLTAuMS0xLjMtMC40JiN4ZDsmI3hhOyYjeDk7JiN4OTtsLTE3LjUtMTcuNWwtMTcuNCwxNy40Yy0wLjQsMC40LTAuOCwwLjYtMS40'+\n\t\t\t'LDAuNmMtMC42LDAtMS0wLjEtMS4zLTAuNGwtMTIuMy0xMi4zYy0wLjMtMC4zLTAuNC0wLjctMC40LTEuM2MwLTAuNiwwLjEtMSwwLjYtMS40JiN4ZDsmI3hhOyYjeDk7JiN4OTtsMTcuNC0xNy40bC0xNy41LTE3LjVjLTAuMy0wLjMtMC40LTAuNy0wLjQtMS4zYzAtMC42LDAuMS0xLDAuNi0xLjRsMTIuMi0xMi4yYzEtMSwxLjgtMSwyLjctMC4xbDE3LjUsMTcuNWwxNy40LTE3LjQmI3hkOyYjeGE7JiN4OTsmI3g5O2MxLTEsMS44LTEsMi43LTAuMWwxMi4zLDEyLjNjMC44LDAuOCwwLjgsMS43LTAuMSwyLjdsLTE3LjQsMTcuNEwtMTQyLjUsNDE0LjV6Ii8+CiA8L2c+CiA8ZyBpZD0iTGF5ZXJfMi'+\n\t\t\t'I+CiAgPHBhdGggZmlsbD0iI0ZGRkZGRiIgZD0iTS0xNjAuMSwzOTYuOWwxNy41LDE3LjVjMC44LDAuOCwwLjgsMS43LTAuMSwyLjdsLTEyLjIsMTIuMmMtMC40LDAuNC0wLjgsMC42LTEuNCwwLjYmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC42LDAtMS0wLjEtMS4zLTAuNGwtMTcuNS0xNy41bC0xNy40LDE3LjRjLTAuNCwwLjQtMC44LDAuNi0xLjQsMC42Yy0wLjYsMC0xLTAuMS0xLjMtMC40bC0xMi4zLTEyLjNjLTAuMy0wLjMtMC40LTAuNy0wLjQtMS4zJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC0wLjYsMC4xLTEsMC42LTEuNGwxNy40LTE3LjRsLTE3LjUtMTcuNWMtMC4zLTAuMy0wLjQtMC43LTAu'+\n\t\t\t'NC0xLjNjMC0wLjYsMC4xLTEsMC42LTEuNGwxMi4yLTEyLjJjMS0xLDEuOC0xLDIuNy0wLjFsMTcuNSwxNy41JiN4ZDsmI3hhOyYjeDk7JiN4OTtsMTcuNC0xNy40YzEtMSwxLjgtMSwyLjctMC4xbDEyLjMsMTIuM2MwLjgsMC44LDAuOCwxLjctMC4xLDIuN0wtMTYwLjEsMzk2Ljl6Ii8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._image_popup_close__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"image_popup_close\";\n\t\tel.ggDx=25;\n\t\tel.ggDy=-30;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 4.13043%;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 2%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_popup_close.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_popup_close.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('vis_image_popup') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._image_popup_close.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._image_popup_close.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._image_popup_close.style[domTransition]='';\n\t\t\t\tif (me._image_popup_close.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._image_popup_close.style.visibility=(Number(me._image_popup_close.style.opacity)>0||!me._image_popup_close.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._image_popup_close.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._image_popup_close.style.visibility=\"hidden\";\n\t\t\t\t\tme._image_popup_close.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._image_popup_close.onclick=function (e) {\n\t\t\tplayer.setVariableValue('vis_image_popup', false);\n\t\t}\n\t\tme._image_popup_close.onmouseover=function (e) {\n\t\t\tme._image_popup_close__img.style.visibility='hidden';\n\t\t\tme._image_popup_close__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._image_popup_close.onmouseout=function (e) {\n\t\t\tme._image_popup_close__img.style.visibility='inherit';\n\t\t\tme._image_popup_close__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._image_popup_close.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=((this.ggDx * pw)/100.0 + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=((this.ggDy * ph)/100.0 + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._x.appendChild(me._image_popup_close);\n\t\tme.divSkin.appendChild(me._x);\n\t\tel=me._in=document.createElement('div');\n\t\tels=me._in__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_in';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASAAAABwCAYAAAC+eq3DAAAbMUlEQVR4nO2dfXAU93nHv/ey97J3QgfojF6AEyBhkIN4b+CMQTaGOGlsbMd23E4T25102hlPYmeaaeIkU4dO62mbNrbzR6czSWOnyTSt0wScJo6dmCDALHYkG4GNMEjAHQYJOIFOcO97L/3j9k67q72X3dt7EXk+MxpJu/vs73dv33ue5/f7PT+AIAiCIAiCIAiCIAiCIAiCIAiCIAiCIAiCIIjZjqHeHdATjuNcANbUux8EUUWGvF5vsN6d0ItZJUAigekD4AHQKfohiD80fKIfP4B+zDKBamgBEgSnD8Au4XdnHbtDELOFIWTF6ACA/kYWpIYUII7jHkdWdO6vc1cI4mZgL4BXvV7vy/XuiJyGESCO4zoBPAXgcQCuunaGIG5OggBeBvCi1+v11b'+\n\t\t\t'crWeouQBzH9SErPOTtEETteBnA7noLUd0ESPB4ngcJD0HUk5dRRyGquQAJieVnATxd67YJgijIbgAv1DphXVMB4jjufmS9ns5atksQRFn4ADzh9Xr7a9VgTQRI8HqeRzbBTBBEY/MCsmFZ1b2hqgsQx3FrAOwBeT0EMZsYQtYbGqpmI8Zq3lyYz7MfJD4EMdtYA2C/8BmuGlXzgDiO+xayyeaqczUVRCLDAwAmUkEkkP07k7sgM31tBjORH9PrmvyxTJXum8dQsm3t967wmgqfe73a1v3e5djp3L7DwGApk50i5zQyWMo0K9yhKnzZ6/W+UI0bV0WAOI57CVXK91xLBTGeDGA8FcDVVBA30mGIP4Di32IBUjqPAsdmXKPRPv93Feyn/1Z+7OW2X7I/Rduurb2ynaFCe+VzldiK2y5mV7m9AQtMLJYxzei1utFrbcGy'+\n\t\t\t'6onSy16v9wm9b6q7AFVDfC4lAxjhffDzF5HI8AovIAmQ1vZJgJTPzRYBkts7jAy8tjbsZD1YbW2BzuguQroKkJ7ik8jwGOV9OJEYQSgdLvEhJgHS2j4JkPK52SpA4t+tJhYPOruwk10Mp5GBTugqQroJkF7ik8jwGE6MYDhxWuLtkAAVsiMBqsxe+dzNIEC5fxxGBg86u/AZ5zK9hOgFr9f7ZT1upIsACZnylyq9z8nECIbiJ5TDLBKgAnYkQJXZK5+7mQQod8xhZPCkqxefYBdDB57QY3V9xQIkLCbdX8k9rqWCGIwP4VIyoFEESIC0tk8CpHzuZhSg3O/V1hZ8dd56tJpYVMidlc6arkiAhAWlR1FB+YwzvA8DsaH8MDoJEAkQCVB1BSiD7DD+k65e3FOZNxQEsKSSGdOVTkTcA43ik8jw4KID4KIDefEhCKI2hN'+\n\t\t\t'I8/unau/jHyXcruY0LWQ3QjGYBEiYaaioAn8jw+G2kH2d4n9bmCYLQgdfD5/GFy79DKK3ZCegTtEATmkIwYX3XUS22OfGZTAXVueYUghWwoxCsMnvlczd7CCa3W8Y040X3HZWMki3RUlNIqwf0vBajRIbHm4L4EATROIzyU3gqcKgST+glLUaqBUgYcu9Ta0fiQxCNzSg/hS9pF6E+LQtXVQmQqK6Pat6ODpD4EESDM8pP4Tntieln1Rqo9YCehoZRr/fjw7iQvKjWjCCIOvBWdBwvXf9Qi2mn2oR02QIkeD9Pqe3RlVQA7ydOqDUjCKKO/OD6SRyNT2gxfUrQirJQ4wE9DpXeTyLD40hsQI0JQRANwnPX3tWSD3JBxU43agRItffzQeIEwumwWjOCIBqAS8kIfnD9pBbTsnNBZQmQsJtFp5oeTKaDOJUYUWNCEESD'+\n\t\t\t'8dMbZzDCT6k16xQ0oyTlekCPqe3Be7Gq1rImCKJGfHfyuBazXeVcVFKAhISSqt1Lr6QCuJIKqDEhCKJBORqf0JKQfrycZHQ5HpDqrZM/iNOoF0HcTLxyY1SLWUntMJdxk7JcqRzhdJi8H6LqrLW2Y5GwQ0QkzeM3EU0fEKJMDkXHMZ6MoM2sqobQLmT3ni+I7h7QaZ4Sz0R1mW9i8UTzBtznWIm72S58mKAvvFrwSki1yPeVuqCoAAnVDlVxjkpsEFXmSddmsAYGkQyPf752EB8lVY/SEBo4FB1Xa+IqpSGlPKCixnKupAJUXIyoKmus7YikeZxKBPBtEp+aMp6MaBmS7yt2slQOaJuali7Sei+iygzFxzAUH5PUgiJqx2thP55y9aoxWV3sZCkBUlXx8EqyvrH4OluP5P/j8RHEVXhkC81urLB0osPsxhzjdLItkA'+\n\t\t\t'riQjKAo7FRTBWZ2d1sdGCdrQuLzG7cYpoegZxKR3CeD2CEv4jTiTGJzRa7tM8ZzCR3bCjmR1DWvs3AYJO9GyuYNrSap9s8xwdwMjGG9+J+xIo8B3YDg/U2D3os7VjKuCXnzvABnIiPYSDmR1SDZ/tJR4/kAckf29VUGKf5AK6mImXdb5HZhTW29vx9PuKDeC9ePCzYYvegRSi+Lm8/A2AiFcHJRAABhT70WN1YaZne3K8/4pdc90jTSsm95Pe+kozAxwdxVqXXsMDE4j5nF1ZZ3JLtl8NpHscTAXDRcXCxMYTSSVX31YOjMdXD8X3FThb8+hDG8CfLbYXP8Ph5aK+mqoJlVZ0rWlXQgFazG592SB22/dFBnEr4SlYkbDI6sJ3dgA6z9AOoxNH4CPojx2b0+U52NdZZu0van08G8KvQYF5Inpn3UEmbHD+8fgA+flrk'+\n\t\t\t'b7W0437nRtgMhavYxTI8fnZjEMOC8Ikf/91sD263dxW1B4BohsdvwsM4GJ1OQpbzGr7o/kzJxwQAv4uM4pfh4bzIFapo+PicDfDaPXm7SIbHVwOvIyLeP05m/7W5W7HCUnqH0INRP3504zgiaT5fEfEh50p8xjktMruvHsJwYnrnllfaHizr8V1JRbA/4sdPbpyc+fhEfzuMDP6kaSV2ObpK3jOU5vGvk++Ci40r3lNtRUQ19ocXPVCyfzLmFipcXywHpMr7mUzXt9bPcqZzxrFeS+kXssXkwmeb7i5LfABgrbUbC0XXWg0MPjfn7rLEBwAWm93YYCvdr1K0ml14tMlbUjwAYDI989v94aYN2M6uLMvebmCwy7kajzZt0NTXUtzFduGxOcXvPd/ESsQHAFgDg7W2dl36sNXuwTfnbdXlXnJuMbH4bNNKPO/eDkeBkq'+\n\t\t\t'cOI4Pn5m8tS3yA7K4Wz87fhB367PGlCg2TEgtqSbEQrFNNC8E6FhtzGlkst3hmHJ9vcqHF5MJEUrlvVgOD+53bYJV9CC8mA7ggCic7zO686LwRHpSc+4RjoyTcArIh1yh/EXHhm7nZ4EC3pR1WA4P3437sixxT7M9UOoJjcd+M47lvnqDI/d8mC92Oxv3YHxlGMB1BJ+PGZlsXVlra8R9TB3FJ9vi3sz1YZ5U+X/EMj2NxH/z8FOIAFphcuN3uASt6bjbaPJhMR/BGeFix/8UIp8M4xfsRTgPhtAGskcVWkaCstrZjucWN0wWG1L32TsXjO9guHI76y+7H8fgwQmkglDEgAwZbbJ68KHjMzbjD7sFBFffLEU6HMcr7Ec8ANoMDTiOLNrMLdtHzt4Rpxt/P34pvXD2IsGyV+dOu9ZJwC8i+H4biPvj4KRjBYAnjxjpr'+\n\t\t\t'O1iRiH1l7nqE0zwOx1SPUGnmdGIKa9XtO19wRrRuAhTO1G/V+3JLZ/7vnBufe+FXWbqxP6lcEmSLfc0M8XkzMojhhA+ANPxbKbSROwcAi8xudDHSb+ATCT/2RYbyuaecKzsn6sDHrB68FS384Q2mwzgUHZ7pIsuKowNApyxfszc0mL/mHB/AOT4Al5Gd4f3MNbHYzq6UHDuV8GFf9BiupXiE0waEMkA4fR7/deMk/rJ5PTaJvIyd7EoMxHxl521yhDMRHI0N43IKuJwy4ErKgN/HJvCVuevz1yxnigiQbVqsohk+//ouMjfjVou77LlAx+IncDllwKWUAZeSBrwZGce3W+7In99ga9MmQJkIjsVP4HragKk0MJU24HoauN3WjQedK/Mit4Rpxhfm9OLF4HTVwVVWt+Q5BoBTCT9+FR4QXgsDQmlgX/Q8WMNJfGXuZo'+\n\t\t\t'lY/ZWrF4cv1U6AQurzgWsA7FU6Uem+YHnq6QF9zDId/rwX8+Od2PQb6FaLZ4bIAFnvZ4XMazoUPYaTIoERM5zwScQHANbapGHXR8kAfh0eUEx8T6XDOFxEfNQiD52UQqmgQujllfV5MhXEweig4vSJcJrHdybfxWWZ2NxhLy/cLMUl2X3tBcJBr92D+aJdPF+YfBMRUX9vt2kPQ+ThhMNg0XwvJV6LjOLvr70tOXYX65GEYvc6lknOn09eRH9U+UvzSiqCv7v2tqROzwITi501DMWOxvQbbComQEWHzxqF5ZZOWERv3OMJHzjZN9itIg8pxxKmQ/J/PMNjKK5uFrfc+3k3VrtZ4B/KRtOemLMVa62ekjmdHqu0zx+WKJkSzvB4WVYTpotR5X4XpEsWchQaaRN7P5dTQQTTEQzFph+/PFRUgzyUCGcSmu5TjGOJAIZk'+\n\t\t\t'Qvdxkccj937ejxf/orqcjOD1yHnJsV5reTnMOtFc6ESxEEzzdsu1pFuUfA6kgriSmsJYEgikInAL35qrrN04JhMX8TA7kM37qGGRQtJ6lB9TuLJ8PGY3vlFgVMzPB/DD6wfy/78TG8EKy/Qbt9XswgPODXgA2XzQycQYTiZm9meu7HGXs25PPvTablb/1nAYWKy19RTMAQHAkZhvht18E4vllunn+mgsOxJ3IOqXJKV3OLrwaqh08awFZjcsBgNaTBbsYN3YYpP2YbBKuZSh+ATWiMRuQf69OfN9FEwHUWp+09F4AA85pz0nHfZ5ryaaktCqqMco2HyTC20iITiVmPZ8/i88ij+fk50w1WRksYRpx7kiAjExy3bs8PEB7A0N4h7H6hlez1qrB2utHpzjA/h5aBCTRfI12dxd8Tf7uMp8jxIOowPrrD0Fz//n9UHFvN'+\n\t\t\t'K9DqnNOT472XU4MYErqQhuET54t9s8ZQnQTrav4LmTiQkc0pD/0ZNyF3LLS6X2qksKNwy65YD4OizBEOd+AEi2ej4SlYqNUhgmRilP1OgMxX349+CbeDs2qpjvWcK48adNm8saai9Gk/bdMktyLD6G567tw5HYzA8+a2CwWhSenOF9SGD6fcaJXuMWE4u1Vu1D8q9HRvGd4BHN9nox16gt8DijfolEQ6CbB+QyugTXsTZYDAw8ojxOMB3EfGE43Gkw4GrKgEvJCFqF8gFLmHY0GR24LkwAlCeKy50HlGNK4QPfbHQUnSldCn8ygB9fP1DWKFiOYDqCX4eP4dfhY1hgdmGzrQtrRUPsbWYX1to84IRJhLEMLxGkDnPHjNnZcuR5kmsaPKILySB+FjqOXks77mSn57qM8AFcKDBNYrMstxNJR7DQ7IbNYMAc40zPbCfb'+\n\t\t\t'haPx4o/lw8RE/rk8mQhIZkIXeo71QB4i5RL7Z3npY2cMDFiDAyEUf467Zfkz+UDBbEE3AbLU2IPoliWfXUbXjJnQcnqtXXgrmp2DI8/5tJhc6DC7y84FXU+HcT0dkeSSbrN6wOk40qWWS8kg9oQGMZ4M4lOO6TGEHkt7XoCGE2OSOUBLGU9JAXrIKZ0cd4ZXPwoSzfAYSQRwgQ9ik92TH/H6Y0cPjkT9klGtHNtlo22rrD1YZS3cxq2WFsw3sZgo8mF87tpBAMqzgqvFAhOLLfY2ybEP4tnnMJzmcY6fwhKRoCxlOnElVfx99FCT9DU5Fp+dJUmKhWC+WnVCC/LwqxzEYdhEKjhDbLbaVxcMxawGBm7ZhMMTsmF5r61nxqREMR+zdhY8pwWX0aF4/FKqsDv+nizUWWTuQDczcxJnjh2sB6tlHtCAQrhULtEMj/2i4m'+\n\t\t\t'F2A4OHm2YOuC63uCVD7+Wyg618lrmeuE0s/nbeZjhFYew7sTFcEYnkL8LSOjurrT2YXyQU++u56yQeVSjN47eyUbEG40ChE8U8IFXvMkbn+RPF8DAdcIo+fDfSEYREoY98nVeT4KVk5/504kNBOAZiw+hwTntNLSYXHm3agXdiwzjLX0Qsw8NqYLCM6cBWNvsheSM8gDNCMvu92Ahus3RKvKDPz7kbXGwYH8T9+XCs29KO9bZuLDa7sdjsxq/CynM8bAYGHsYtDcFE/0QzfH5Wc6vZhcfmbIOPD2BPaFCy4LTVJHXPx0UlK84KkxSXiCYy9rEb4TbfAi46grPp7LWLzc24k+3CNtlI1QfxMU0ekJjXwsP4uG16bs8mmwdHYn7JJMTtdqmQnBatwZJiwK2itV5b7B785IamIuoVYTEwaDW70ZQ2wJUBLHBgEePGamu7'+\n\t\t\t'JIwMp3l8f0rav30RP+51dEkmF97r3IZ3YyMYjPsRFsL9ddY23M12o0e2tm1P+IzW/dw10aquKmJRdAvB5ppcNSvHIf/GPhgdwJjgzYhd6wyyXs+d9ul1Rr3WrrwAXUwGMBAbxkbRKvo5RhY72A0AlNcm3ef04hchDqP8GOIZHq+GODzSJF3O4bX1wGtTHvFZJYQ/v1QQoQUmF/6sqXAY6ROG4nPiYzMwWGFpxzPz7ssvUrUZGMmqeADgZPOTfnT9CP6ieSvaRNfdZvHgNoXlLGLGkkH8943BoteUy2vhYXxOtP7rYWcv/uHaPgDZoffVooTy1VQE/zKpHDplYMDfzN2aFyHWwGCL3YO3ajya5TK6io6wAVnx+ebVgxLvJ8eLwUE8N39rfoKi1cDAa++B11545BAAjscn8GNte3dpps2s7HlroVgIpmpfHdZQm3kITq'+\n\t\t\t'NDknwOpcMYL5K3OZXwSWb5tgjrw3L8PjaMQ1HltVlKBFJBBEQhTiAVxCs3DpRd9iOe4XG+wrIlrQphXifjRifjniE+Pw8NStaQAdlE9PemDmK8QPJXibFkEP8WPKipLIcSb8f8kuTzQrMLnxaG3OW5nzcjxSdLHpaFhI0WhgHAB4kJfDmwD+cKjFad5afw9QLiVAguNo7dslnWtUCeAC+D/kIninlAqoa05hbJfejJbbLcz2m+9DfdqYQPq0Sr1Xut3dgXmfZAjsVHcDEZwB/ZerCUUR7KjWd4HI2P4L3YzBpDV1JBfG/qNayzdWO9tbtgHun9uB9vRYcrGikDICxQDGAb24MVlvaCyzB+FhrEuQLhUjTD47vBfVhn8+ButmfGBMUck6kIfhMZxkDMr3vC9n9Dx/G0a3oF+l1sF47EfNgsC/uGSoxsHY768WhTbz7U'+\n\t\t\t'WWxuxiJzM87XuVriicQEzvFB/C7ixzl+quTzd5afwhcD+7DL0YVdjq6CK+ePxyewJzSaL8VRa1QWpgeKaEnRGWgcx6l6z/3PjZ/WrR6Q0rnybKXHrAYmPyIGZIUnkAziI4UQr1CfFwoFyWxGBhkA5/kALieD+dXxZT/m3N8K/Z/+2wAP40arqRk2owWTqTAupaby3k0he/nvNrMLbeZmzDM6kAEwmQ7jYnIKY3xQW5/L6rs6e2U7Q4X2yucqsRW3XcyulP1SczNWWd15ITqTmMJZPphfQ5cRfXy1tF+ybwr2TiODNzo+DTV4vd6COlMqB+SDilXxHeYOXJjlZVnjGR4XhHIcYgFTw0fJgFSwMqpvoQofH4CPDyi+wcplLBnEmFi0NN6H0I+z/BTOijynRng9VJbhAEqkckrNhO5X09ItpoZeEEcQRIWsU7/otSIBKj'+\n\t\t\t'87C6DDrE91OoIgGpM7ZBMqy6DgHCBAZw/IYXRoXstCEERjs9baoiUB3V/sZFEB8nq9Q1A5I3q5hhnKBEE0Pp9yFJ8npoDP6/X6il1Qzmr4fjUtLjR3gJmFK8sJgiiM08hgq/rwS7EMq5hyBOhVNS0yBga3WparMSEIosF5pKlLsp6tTH5Y6oKSAuT1evdC5aTE5Ux3zVfHEwRRHZxGBo84l5W+UIpPSOEUpdyCZC+radlCXhBB3DRUy/sByhegF9W2vpzpplwQQcxyWs2sFu8HKNNpKUuAhEx2v5rWLQYGm2wb1ZgQBNFgfMnVq8X72Vtq9CuHmprQu9X2YqG5AwvNHaUvJAii4bjD3qZl4iGgImIqW4C8Xm8/VHpBALDJtpES0gQxy2g1sfj6vPWlL5xJv6AVZaF2VwzVXpDFwGC7vU+tGUEQdeS5lk1aQi9ApUao'+\n\t\t\t'EiCtXtBckwub7JQPIojZwDPz1mspOgao9H4AbfuCPaHBBkuZTqygZRoE0dB80dWLT2rfZ161NqgWICG7rToUA4D1tjVYKtpKmSCIxuEex2I8rG3IHQB2lzvyJUbrzqgvQOO2PZvtG8kTIogG44uuXjwzV1PSGQCGvF7vt7QYahIgr9cbhMZQDAA22NZgM+WECKIh+Nq89XhIu+cDVKAFmveGF5JNmkIxAFjGdGKno4+G6AmiTjiNDL6/4C7coz3nA2RDL1U76IgpWpS+HDiO2w+gT6t9IsOjP3oYlwoUfa91UXr1bWsrKq9nUfpK2q9lUXkqSq+3vfai9Fvsbfjq3PVah9pz7PV6vQ9UcgM9NiZ8AMBRqCheL8ZiYLCT7cPJxAiG4icke3gRBKEvDiODJ129lXo9QLbWs+bQK0fFHhAAcBy3BsB+ABXVY01keAzEhj'+\n\t\t\t'DK+8gDKmE//Td5QJXZK5+7GT2gB53L8NiclZV6PUC2PM+dlYReOXQRIEA/EQKyu50OxYclQkQCVMiOBKgye+VzN5MA7XQsxufnrESrSZfdi3UTH0BHAQIAjuP6kBUhXUhkeAwnRjCS8CGUDpMAKdqRAFVmr3xutgvQAhOLB51d2Mku1sPjyaGr+AA6CxCQF6E90METEnMtFcQI78N4MoCrKekGeiRA2tsnAVI+NxsFaBnTjF5rC3ayHizTtpSiGLqLD1AFAQL0DceUSGR4XE0FMZ4KIJQO40Y6IvyEZ76JhH9IgIq3RQI0ewToFhOLBWYHbjGxaDU70GtpwVKmWU9PR05VxAeokgABeRHaA42jYwRBNARDAJ6ohvgAVRQgAOA4zoWsCPVVsx2CIKpCP4AHhJUPVaGqApSD47hvAXi2Fm0RBKELu7Wu71JDTQQIyCen'+\n\t\t\t'XwKFZATRyPiQ9XqqEnLJ0bwWTC3C2rG1yK6kJwii8dgNYG2txAeooQckRkhQPw/KDRFEI9CPbKLZV+uG6yJAOYSw7FmQEBFEPehHNtfTX68O1FWAcpAQEURN6UedhSdHQwhQDo7jOgE8BeBxVGkSI0H8gRJEdrfSF+sRahWioQRIDMdx9wPYBeB+kBgRhBaCAPYCeNXr9e6td2eUaFgBEiMkrfsAbAOwBjSUTxBK+JCduXwA2S1yajaapZVZIUByhBnWOSHqFA5vq1d/CKIOHBB++4SfoWrOWCYIgiAIgiAIgiAIgiAIgiAIgiAIgiAIgiAIgijE/wOebvWiigM4MAAAAABJRU5ErkJggg==';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('alt','Acceso r\\xe1pido');\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_button';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASAAAABwCAYAAAC+eq3DAAAa9UlEQVR4nO2dbXAb9Z3Hv9KutLLkSLYT2TGNHFM7SevEDuHpYENa00I5KKXp47XAHaE3cy+u0wKvrnMzNy0zN7y6m9K+uTftQe/6dNBeobR0mHLFTcLSEgJ5ctrETnFsE9tSoqdYslZaSfdCK2l3tZJ2V5Ilh99nRmNZ//0/yGt99Xv4PwAEQRAEQRAEQRAEQRAEQRAEQRAEQRAEQRAEQWx0bO0eQKMIgjCp+HWyymUEcS0xVXzC8/xU9cs6nw0jQIIgDKMgMHsB3CA/eto4JILoFKIATsiPkwCmeJ6fa+uIDNLRAiQIwkEAn0ZBeIbbOhiC2FjMoWApvcjz/AvtHUp1Ok6AZJfqEQAHQRYOQTSDKIAXAPyg01y2jhAgQRB6ABwC8BjI0iGIVjIH4E'+\n\t\t\t'kAL/A8H23zWNorQLLwPI6C8JC1QxDrRxTAdwA83U4hapsACYLwOIBvgoSHINpJFMATPM8/247O112A5BjPMyBXiyA6iRMoCNHUena6bgIku1vfRMHlIgiiM3kawJPr5ZatiwAJgnADgF+ArB6C2AjMAfgMz/MnWt2RvdUdyLGed0DiQxAbhWEA7wiCcKjVHbXUAhIE4RkU0usEQWxMnuV5/tFWNd4SAZLjPa+hsFyiZVzJRpHOZ7CUDQEAruaSuJpLIC+XF38ir3iuLVM8r3pNvvo1evUb6kv7PG/gGsVtrLgmX7u/uu/L5Hs30pfh6/P6r6vbtOleY+a9V20/b2yctdrUKzN8jc69H2Dc6GfdAIAJpx8euwMjDp9Oi01lCgWXrOlxoaYLUCvFJ5yN4qJ0CUtSEEtSSHF/bLo3sJaA1PrnqSVgZuqXnregfvm5/ns3'+\n\t\t\t'2n/d8dTse33r69ezNVhfv6yRusq+a9VrvH754zvBbcEE5wfvGmyVIJ0AcGezRaipAtQK8VnNJTCdnsF85hKu5hIA9G4gCZDV/kmA9Ms2mgApywYYN/iuQXyuexQDjBtNpOki1DQBarb4LGdDOCFOY0kquFe1P8QkQFb7JwHSL9vIAqSsv5fbgr/zfhh7uS1oEk0VoaYIUDPFpyg8y7LwGBMBEiCr/ZMA6ZddKwJU/LGX24JHmidEJ3ie39eMhpqVhv82GhSf1VwCryUFvJKYwkrR6iEIoimcFC/jidAR/MuVP2A5m2y0uRvkDHfDNGwBCYLwLRRmOFvmT+kZnBSnkc5nLFohZAFZ7Z8sIP2ya80CUv702B14xPthfL57BA3yBM/zTzfSQEMCJK/res1q/XQ+A2HtGOal90qvkQCRAJEAtVaAij/3dw3iG703odvuQA'+\n\t\t\t'Pc2cj6McsCJMd93oXF1eyRbBSvp44hko0au8kkQFXqkQA1Vl+/7P0gQAAw4vDhG303YdR66j4K4HqrQelGYkDPoAHx+W1yCpFs2/dDIoj3NbOZGB4PHcFsJma1iR4UtMASlgRI3qv5oJW6RfFJ5zNWqhME0WRWcxk81pgIHZQ1wTSmBUh2vSwpHokPQXQmTRChb8vaYAorFtDjsOB6RbJRvJqcQobEhyA6ktVcBl+3LkLDsLDXlykBks/m+qbZTtL5DA6vCWT5EESHs5rL4J+v/AGrOUuf1cdkjTCMWQvItPgAwJG115GQ13ERBNHZLEtJPBU5bqVqcddTwxgWIFnZDpkbD3A6fRYrWZrZTBAbiSNrS3j+6gUrVQ+ZsYLMWECmrZ9ILorT4rTZagRBdAD/Gf8TliVLyzYeM3qhIQGSo9um02xvp1q+pSxBEC1iNZfB'+\n\t\t\t'U2FLrtghoxkxoxbQIZjMfL2bmUOQXC+C2NC8I17GkbUls9UMGyxGBegRsyM4nT5rtgpBEB3Id6OnrFQz5IbVFSA5oGRqq413M3OU9SKIa4QlKYnfJObNVrvBSDDaiAVkOvZzhqwfgrim+H78T1aq1dUO1kAjptyv96T3yPohWo7rd3NgggkANuRdDBL3jiLPGfl3JqywLCXxjngZ+8ztqPgICietVqWmBSRHsk25X4vSJTOXE4RpnMeXwB1fArsQBxNMIMUHSHzWgZcTF81WuaFeNqyeCzZpprdMPoN3M3NmqhCEKZhgAq7fzQEA8hyL1S/tRrbf095BvU84bD4bBtTRkHpfGx8109OiYmdDgmgFtpgIcX8AAJAZ7SPxWUdWcxkcXlvCR7oGzVT7KIAXqhXWEyBT7te1MO9HiolIXYxDioqlneNcQ144t3sNt5G+GE'+\n\t\t\t'd6Pl763e7l4NjuBePjmjzaAvmUhFwwiex8HHkANo6BfcAD+5DxMefn48grxgwXAwx5AX9nfcClHX2QdvSpdvW7VnEvxuFeLKxMzwPIciyS27xYa+M9ObJ2yawA1dSQegI0aaanUBsFKHkxjvn/Umffrv/aPrA9xj70yXMRRA4vIr1SGUCPAbC7WHTt7IXv7mHYXUzFNblUFrHfzkE8H0EuJen2wQ544D6wDdzO3tJrl5/6g6HxAYDnoTEwClHJp7JIH11E5nQIeZ0+bT4O7Hg/2Du26baXj4nIHl1AbiYCVBkzfBxs4/3Afv02qmGbj4P9Se1lOPl+D7I7+pC5eStgIIbDCYtwvr5Q+j3n4xD/h5tq1tn8b0LNcqnfg3TAi8RN1yHrVf+vbHluGs6F8tYUoS/ugRgo//2H/r1O214O6X4PEiN9SIz2IWvgPTriIja/'+\n\t\t\t'sYBNs2HYRf17kvFyiOzuR/C2obrtNZu3xctmq0zWKqz6FxEEwZT1k8gl2pr9ivxxufK1N5fh/8T2mvVyqSyCL11A8ly4znUSEqdCWDsfgf/hMbAD5RMnU+cjiL50oarwFJFWEoj/7BxcE35039/YiQT5VBbJH59FTkcwS9fERGSOLiA7H4Pzwd3q93M6BOn/5qoLT5GYiPzRBeB8GPjkCNBEl8cWTIANJsC8tQTxy2PI1Wnb8ZY6BmGPiXDMhJHZ0Wd5DKw8BvfxJcTuHcXa7n7LbVW0HRfBxkW4Z8PYPMXi8uQwrtZo3zsdRP/UXFXhKeKIi+h/YwHe2TAW79mB1DpaRMtSEqu5jKmN7AVBGOZ5fk6vrFYQ2tTSi2iuffs7Z6IiruoISPxkCLlUtmbdlefP1RWfWogX4wg/f66u+DSb9FtLuuJjH1D/M9pcLBx3Da'+\n\t\t\t'tey82EIf16tr74KAkmgB+fBWKileHWxCZK4H5yFrYaHzzHmZBuOXfcUmBUF99vZsHEm//+AMAuSuh/ZRb9r8zqlnfPhrH1ldm64qPEFUrg+ufPwNGiMVdjxvyGZcPVCmrZhKYsoGjO8laODRM9pe/65VISVs+F4Z3w65ZHDi9i7WK84nXvrYPo2lV2k1ZPhpA4FYLdxcL/8BgcA27kUbCewj87X1HfMeCB+9atYHxcwXePikgcWUQ2JsI14cem+0eqxjC6DpRdHe01dkUMKX1MbfE5DwTgkF2tXEqC9NYypGNLcD44Bnu/p9yWKCHz68ptFmxDXthvGQQ4tnBtTETu6IJacEQJeHkW+PLuivr1yPd7IH18uNzffByswp2yiRKYmQikPfr3ynEmqPs6uxCDPSYiazC+Fv2bPaXnTDCBbmFBJWzu45cQv/N6Q21pifEB'+\n\t\t\t'1T1zz4ThDKm/JDZNB7Equ2RF7KKErTrClNzmQ/jGwZLr5oin4H9jQSU4jChh2ysz+MsX9lTUbxVvm58PNFytoJYAmbKA2ut+lb8FHT0cMtHyDYr+cVlXgHKpLGJvqj/EdheLrX9bEBigLADckBfcdi+cAx6V65U4tlRh+XRN+OH7VNm9ygPAEMDt7EPy2BLcB2rHUroObDN2rI6mX+cd5Xo2FwvHHdvA3rwVcLEqJZOOLlZYPswdAdh04kT2nb3I/ehswfopMh8vPEwEuAEALgY5RfwkH/AWREfhVtmqWFf2YALMQvmLIufjYFdcyx2/hOTHjIlGRh5DHgDk55tee7dU7ghaPzU0entAdZ8itwXgWoxj4MU/qyybgVdm8ZfRW0u/b35jocLyuXx7AJdvC5THCiAPL+IjfRh+fhouhbB5FmPwLMaQ2Gb5aB1TrObSZq'+\n\t\t\t'sMVyuo5YKZejftEqDYyRCyCjer99ZBdO8qf7uIKwldKyd5PlwhHn2f2A6nQmCUeCb8JWEqkjiptrwYH4eeT+nHdmwuBp464tMI6aOLOn1Wfr9kT6vHbBvywl4lSA2Ohf3BscoAcRVrxCxGJw86NW5W8uAuVV1nFffMCEYtJ6uktnmx8ukPqV6zixI8s2W33zutvifJgA+Xbw/otpfjWMx9YXdFQLt3ujn3xAgz6eZ5O01zwdpF9KQ6Kt+9qxd2F4NVRVwnfioElyaNrhUltodDdxVXTY9sTERW84296SONC8zakbKQaF0wTiEU7JAXkiJtnj6ygMypINidfWDG/RWxIADIBRMV1o/9ljopVY6FbWcv8krhmq8UdLPYF+JgNUHlvI4Y2EQJ7Eyk9HvOxyHX70FmRy+cZ0KlaxwzYaT3mAsg2+MiuoUF1WuZfv0voEZY'+\n\t\t\t'2+ZF2u9RuWNcKIHV0T5woUSF9RPZV/ueZDkWV0f60HO2LDqexfaFQAywt1rBhp6/nlpJIqkQku5dfXD0cOh29QEoxzniJ0PYokmfS1G1eLAmvwm19QE0ZZ6PUoC0KAXIeWAbpB+ppx3kYyIyx5aQObYE+4AH7B3bwOxUZIh0AvKG5goFfIBSgCwEom0rSTh+WkjL23UELO/jkN3RW/E6q7Fu0jcVPpzSaF9JgADAdXzJkAD1/I88hngKjM77EEc3123DCmsBr0qAuhYLfwO7WHlPkoH69yQR8KoEyLnOgWiTVA3nNHIyqop2TEIMa1Lvm+TAMeNi4N2rtmaib9bOljh1LAazsE1ow3BfQ164HxpTBaaV5FYSSP/8HNK/0s+6lDDiBjXDTREl2OfjVcVH/MwuXZdM635JcvA2s6MPOcW4mGAC7EJ9y8yxEINjIaYrPs'+\n\t\t\t'mbBpE28OG3Qs7EWjUj12a8rkaG0zE0TYDWm2wqi5giBsO4WFXsR/kcAK5WyZQV0ZuAaBapCW2w273qx1D5oYUZ8sLzjzfCdf8o2J36c2Gyp0PIzlSfZpAPGhizgQ+2VaT9AaQOTejOAWJnwqrAdDbgVYlOZlT9njmLsamsj0P04IcsZ7+MoM2GSd7qos6F6t+TDne5DNM0F6yf8a+rFRQ7WdnXe8+dq3p9JioicS4Ct2wlOQc8qjhQ6mIcuVRWd5azHg4dayd1PmJqyYYe3ofGambB9GDH/WDH/cilJGRnIki/OqfKkknHluDc0QebToA9Px+Hrc4EwPy85p/dbAYMQH7Ii/SXdoN9eRaMwnWyBRNVrTD2jCZgHhfh+el0OduncV+cZ4JIfmy4ZnA7qUiVpwM+ZH1cxQzoZmMXJXRpRFyUJw+K/sp74l6I151c6Na0'+\n\t\t\t't14ZsGazYS2gK5oUejYlIXkxrnpoiSusoC4doYjXcNO0ExrtLqZChNZO1Z74WG9SZKPYXCzYcX/FxMNSOcfCphlz9uhiYX5PNRbilUHnBmYeZ/erszvMTBh2HQvLFhPBaiw3e0wEsxAHKz8YHevNeab2l2CCDyDJB5DgA8gEvC0XHwDYrDO7uTgPKMexJTEqsuWNBTA17olnMV5hAcVHrd+TdaDqLOVaAtSxR1pcPRdRzfUxSuJcGJJs0rt39VasE4seXkT0cGUQOJfKIvzSBYRfuqASke5bt2qukxD+4VlIK5VzScTzEUS+fwqZJmSQSm2+ehGS1jpBYTFqNZibNRmWlASp2gzn+Thy/6uxKjkWGDeeLdSS93HIaiYbOl+ujFM5LM5wdh3vnP2onKEEBn75Z2zSpMiv7u5HRiF80RvV98QuShh6blp3hrN7MY7AL/'+\n\t\t\t'+sei3LsYiMNW8JSQs4Wa2glgtmysn02D3AOrlg2uCze7sX7mHFJDdFWfxkqGJi4hZ5fVj/p0Zw6b/VmaTo4UWsyml7xsdBiolYO1deYJpeScL/8BhsLgbuCT+Sp0IQFdZWZiWBy987Bef28gr61LlIKT4U/eFZbLp/BFyVlH9ck9lSvhn7gAeuuwpjX/vVBWROh4BjS3CM+wvZLheLfEpCWjPTWZmSZ8b9yJ0OIqcQwvxKAtJ/vA3bzr6SO5afCSOvF9OSZ0s3gvTxYTAzkZLlZYuJcLy+iIy84NUmSmA185Uye/zI+dSB19JuBYoZ1faYCOdMGOkGrDSrDDxXXnzrDFam14FC7Cc0Oax6Lb67H96zIXQpFr5yoQRGvn8cV0f6IMoz2TfNhlUTEItcufE6Qwtdm8UOZ/PcvaaN2mNfnwxQOioioXGvBu7ZDk7+kCln'+\n\t\t\t'ohafX/l92aq5eipUEiDXdi/8D4wg9Ev1B1aKiliN6otpZiWB1WNL2CRPKuz7/C5c/uFZZDQf1vTFONI6biAArL56Ec6dfbDpxJukKnWA8s1KvXqxID7FMZ0OqX5XYnOxFVaP43O7kP7x2QqByZ8PI3++xrq4cb/pVfG6cCykmwdVSzEcry9A2uNH3seBmYmoUu95jkXq3tHC8+JrpZ82sPNxsIoPr3M62BYBci3U/s4W/R6E/npUN8v13gO7EHhuuiIAvelCGJsuVL8n0bF+BG/Tn7TYKrrtTrNVLLlgU2Z66LGvTxAsrIn9uAbccNVIf2/SWBq5lKTKiG2a8MP/wAjsOrOG9ei+dRBexYxmu4vB5ofHwBkMPjM+Dj0PjemKj1Ec434wBlL+NhdbWAumTaNzLBwPjsFeJXOm29YdAeC+UbNDrUpWZwsO7jcFV0y76j'+\n\t\t\t'1TZX1YkbTWpZsJq5ZqtJscxyJyewCXvri7It6jvGbhi7uxaiKWE7x9CIv37GjWMA1zo7l1YECNcE6tT52p5e09dlNLxyyTjorwbPeWvgF79tb+Yzh6OPT81SDE5fI3i7icRPdE+ZruCT/cO/sQe3MJq6dCFZMMi3sBeSb8ulmuogiJF+NIvLmMlI4VwQ544JrwwzXuh83FlMbv0LRXke3SuGAAwAy44fnKONKnQ5DORyBp+rO5WDA7esEeCMDm4/RTaBwL9rO7kJuPF1wyvT2BfBxsO/qAmwfNzwVyMcgrsmXaNHueY5G5bwSMJtbDzISRdzHIDnlL464vQP0VwWd2IYasrx+ZgPUvxky/W/Wny2lia6Kibb0/cWqbF6LfUwo419tELcexeO+BD8G9GId3Oqi7J1DGyyE+0ocrN16HdJvmAu1wmP6bzlUrsNWqJQiC'+\n\t\t\t'qY3nfpV4GavymjCtqay7oFJ7Ta2yGvUBm26Zsbr6ZSnZFWJ6OLBeznT9bExEVt5V0Tnktfaei891xl9+XnjvuZiIXEyEvd9dWIBap77uz5iIfKwwZtuAu5DOrtm3gbIm1tevZ2uwvn5ZI3WVfdeqZ6S+Q95TCABSfjeyxd0KUH7vVvuvOzad+ltZN34+eA/MwPN8VZ2p53dMwcSuiH7GXxKgjY5LYWXV/erSgfFxpe04rNQ3i93HFaydRrpTtEF0Bhkvh7S3wfvaRCy4X1O1CuvNAzKViu9nrKdnCYLofA50XWe2Sk0NqSdAVfP3emxjP2DmcoIgNhgWLKDf1yqsJ0BVj9PQw2FzkAgRxDXKfZ4hU3tBy0zVKqwpQDzPR2HSDbvesd3M5QRBbBDu85j+bJ+QNaQqRtaCvWimxw+wH1i3SYkEQawPW1m32X2gAeAH9S'+\n\t\t\t'4wIkCm3DAA2OMcM1uFIIgO5u+9H7ZSra521BUgnudPwLQbNkxWEEFcIwyybtzrMX0I4olqZ4EpMbodR11TSss4WUEEcU3wFWvWz3eMXGRUgJ6FyaUZ1zuGaV4QQWxw9nFbrFg/URgM3RgSIDmSbToWdKNrQxysQRBEFb7WO1H/okqerZf9KmJmR8QnzY6i196Dcc78KZoEQbSfr/dMWFl4Chh0vwATAiQHlJ41O5Jx5xgGyBUjiA3FPm4LvrBJ/5DNOjxrJPhcxOye0KatIAA40LUfDpvpGZQEQbSBrawbT22+zWp1UxphSoBkZXvaTB0AcNocuMs9CSeJEEF0NN12B57afJuVJRcA8KQZ6wewdirGkzCZEQOAXqYHd7knLXRHEMR60G134Lv+Axi1FveZgwXjxLQAydHtR83WAwoidHvXLVaqEgTRQrrtDnzHuvgA'+\n\t\t\t'wBNGM19KLJ0LxvP8C7CQlgeADzqG8UnP3eSOEUSH0ATxeUHWBNM0cjDho7DgigEFS+hu9yS6abkGQbSVrawbTzcmPpY9IqABAWrEFQMKIvRJz90YYClFTxDtYH/XIL7X/7FGxAcAPmPF9SrS0NHMstllKTUPFLJjn3BP4hbXDeSSEcQ60W134Ks9E/hX69muIk/yPD/VSAM1T8UwiiAIvwBwsJE2VnMJvJ46hmWpcLxKu0/FMN63tVMtmn0qhtX+1/NUCzoVo9n1zZ+KsZfbgn/quwlbGTca5Fme5y17QEWadTLqowCGAVhe/NVt9+Ae9ySWsyEcXTt2zZyuQRCdwIjDh6/2TGCv+U3F9DgB4IlmNNQUCwgABEHoAfAaGhAhJbOZOcxm5rAkW0RkAVWrRxZQY/X1y64VC2gvtwWf7R7F/i718dwNcALAnY3EfZQ0TY'+\n\t\t\t'CA5osQAISzUcxk5jCbnoOYzwAgAVLXIwFqrL5+2UYWoG67A3e7h3CPeztGGgswa2mq+ABNFiCgNSJUZFkKYSkbwpIUxJIUIgECQAJEAgQAE9wWTHB+8K7BZotOkaaLD9ACAQJaK0JKrmSjWM0lcCUXAwBcMhDAhrZM7/oa9bXX6NVvqC/t87yBa3S+CUvP85Wv642j6vsy+d6N9GX4+rz+6+o2bbrXmHnvVduvIkC1x1OJ4b+19meVez8ux3E+6OjBAONuleAoaYn4AC0SIKAkQt8GcKhVfRAE0XKaku2qRssEqIggCI+jIEQEQWwsnuB53vQCUzO0XIAAQBCESQDPoJCqJwiis5lDYYazqdNwrNDQTGijyLMl98HCcn2CINaVpwHsWw/xAdbJAlJC1hBBdCRzAB5tdGmFWdZdgIoIgvAtAI8B6GnXGAiCQBSFNV1t'+\n\t\t\t'8U7aJkBAKVP2OEiICGK9iaJwesXTrUivG6WtAlREFqJDKAjRcFsHQxDXNnMoCI/hs7taSUcIkBJBEA4C+DRo/hBBNIviwaIvWt25sFV0nAAVka2iSRTE6CDIRSMIM8wBmEIHio6SjhUgLYIg3IDC0o698s/Jtg6IIDqLKRSWTJwEMGX2eJx2sWEESA/ZSiquNxsGxY+I9wdz8gPrnTYnCIIgCIIgCIIgCIIgCIIgCIIgCIIgCIIgCILQ8v9Pl9fKF90j8QAAAABJRU5ErkJggg==';\n\t\tme._in__img.ggOverSrc=hs;\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASAAAABwCAYAAAC+eq3DAAAa9UlEQVR4nO2dbXAb9Z3Hv9KutLLkSLYT2TGNHFM7SevEDuHpYENa00I5KKXp47XAHaE3cy+u0wKvrnMzNy0zN7y6m9K+uTftQe/6dNBeobR0mHLFTcLSEgJ5ctrETnFsE9tSoqdYslZaSfdCK2l3tZJ2V5Ilh99nRmNZ//0/yGt99Xv4PwAEQRAEQRAEQRAEQRAEQRAEQRAEQRAEQRAEQWx0bO0eQKMIgjCp+HWyymUEcS0xVXzC8/xU9cs6nw0jQIIgDKMgMHsB3CA/eto4JILoFKIATsiPkwCmeJ6fa+uIDNLRAiQIwkEAn0ZBeIbbOhiC2FjMoWApvcjz/AvtHUp1Ok6AZJfqEQAHQRYOQTSDKIAXAPyg01y2jhAgQRB6ABwC8BjI0iGIVjIH4E'+\n\t\t\t'kAL/A8H23zWNorQLLwPI6C8JC1QxDrRxTAdwA83U4hapsACYLwOIBvgoSHINpJFMATPM8/247O112A5BjPMyBXiyA6iRMoCNHUena6bgIku1vfRMHlIgiiM3kawJPr5ZatiwAJgnADgF+ArB6C2AjMAfgMz/MnWt2RvdUdyLGed0DiQxAbhWEA7wiCcKjVHbXUAhIE4RkU0usEQWxMnuV5/tFWNd4SAZLjPa+hsFyiZVzJRpHOZ7CUDQEAruaSuJpLIC+XF38ir3iuLVM8r3pNvvo1evUb6kv7PG/gGsVtrLgmX7u/uu/L5Hs30pfh6/P6r6vbtOleY+a9V20/b2yctdrUKzN8jc69H2Dc6GfdAIAJpx8euwMjDp9Oi01lCgWXrOlxoaYLUCvFJ5yN4qJ0CUtSEEtSSHF/bLo3sJaA1PrnqSVgZuqXnregfvm5/ns3'+\n\t\t\t'2n/d8dTse33r69ezNVhfv6yRusq+a9VrvH754zvBbcEE5wfvGmyVIJ0AcGezRaipAtQK8VnNJTCdnsF85hKu5hIA9G4gCZDV/kmA9Ms2mgApywYYN/iuQXyuexQDjBtNpOki1DQBarb4LGdDOCFOY0kquFe1P8QkQFb7JwHSL9vIAqSsv5fbgr/zfhh7uS1oEk0VoaYIUDPFpyg8y7LwGBMBEiCr/ZMA6ZddKwJU/LGX24JHmidEJ3ie39eMhpqVhv82GhSf1VwCryUFvJKYwkrR6iEIoimcFC/jidAR/MuVP2A5m2y0uRvkDHfDNGwBCYLwLRRmOFvmT+kZnBSnkc5nLFohZAFZ7Z8sIP2ya80CUv702B14xPthfL57BA3yBM/zTzfSQEMCJK/res1q/XQ+A2HtGOal90qvkQCRAJEAtVaAij/3dw3iG703odvuQA'+\n\t\t\t'Pc2cj6McsCJMd93oXF1eyRbBSvp44hko0au8kkQFXqkQA1Vl+/7P0gQAAw4vDhG303YdR66j4K4HqrQelGYkDPoAHx+W1yCpFs2/dDIoj3NbOZGB4PHcFsJma1iR4UtMASlgRI3qv5oJW6RfFJ5zNWqhME0WRWcxk81pgIHZQ1wTSmBUh2vSwpHokPQXQmTRChb8vaYAorFtDjsOB6RbJRvJqcQobEhyA6ktVcBl+3LkLDsLDXlykBks/m+qbZTtL5DA6vCWT5EESHs5rL4J+v/AGrOUuf1cdkjTCMWQvItPgAwJG115GQ13ERBNHZLEtJPBU5bqVqcddTwxgWIFnZDpkbD3A6fRYrWZrZTBAbiSNrS3j+6gUrVQ+ZsYLMWECmrZ9ILorT4rTZagRBdAD/Gf8TliVLyzYeM3qhIQGSo9um02xvp1q+pSxBEC1iNZfB'+\n\t\t\t'U2FLrtghoxkxoxbQIZjMfL2bmUOQXC+C2NC8I17GkbUls9UMGyxGBegRsyM4nT5rtgpBEB3Id6OnrFQz5IbVFSA5oGRqq413M3OU9SKIa4QlKYnfJObNVrvBSDDaiAVkOvZzhqwfgrim+H78T1aq1dUO1kAjptyv96T3yPohWo7rd3NgggkANuRdDBL3jiLPGfl3JqywLCXxjngZ+8ztqPgICietVqWmBSRHsk25X4vSJTOXE4RpnMeXwB1fArsQBxNMIMUHSHzWgZcTF81WuaFeNqyeCzZpprdMPoN3M3NmqhCEKZhgAq7fzQEA8hyL1S/tRrbf095BvU84bD4bBtTRkHpfGx8109OiYmdDgmgFtpgIcX8AAJAZ7SPxWUdWcxkcXlvCR7oGzVT7KIAXqhXWEyBT7te1MO9HiolIXYxDioqlneNcQ144t3sNt5G+GE'+\n\t\t\t'd6Pl763e7l4NjuBePjmjzaAvmUhFwwiex8HHkANo6BfcAD+5DxMefn48grxgwXAwx5AX9nfcClHX2QdvSpdvW7VnEvxuFeLKxMzwPIciyS27xYa+M9ObJ2yawA1dSQegI0aaanUBsFKHkxjvn/Umffrv/aPrA9xj70yXMRRA4vIr1SGUCPAbC7WHTt7IXv7mHYXUzFNblUFrHfzkE8H0EuJen2wQ544D6wDdzO3tJrl5/6g6HxAYDnoTEwClHJp7JIH11E5nQIeZ0+bT4O7Hg/2Du26baXj4nIHl1AbiYCVBkzfBxs4/3Afv02qmGbj4P9Se1lOPl+D7I7+pC5eStgIIbDCYtwvr5Q+j3n4xD/h5tq1tn8b0LNcqnfg3TAi8RN1yHrVf+vbHluGs6F8tYUoS/ugRgo//2H/r1O214O6X4PEiN9SIz2IWvgPTriIja/'+\n\t\t\t'sYBNs2HYRf17kvFyiOzuR/C2obrtNZu3xctmq0zWKqz6FxEEwZT1k8gl2pr9ivxxufK1N5fh/8T2mvVyqSyCL11A8ly4znUSEqdCWDsfgf/hMbAD5RMnU+cjiL50oarwFJFWEoj/7BxcE35039/YiQT5VBbJH59FTkcwS9fERGSOLiA7H4Pzwd3q93M6BOn/5qoLT5GYiPzRBeB8GPjkCNBEl8cWTIANJsC8tQTxy2PI1Wnb8ZY6BmGPiXDMhJHZ0Wd5DKw8BvfxJcTuHcXa7n7LbVW0HRfBxkW4Z8PYPMXi8uQwrtZo3zsdRP/UXFXhKeKIi+h/YwHe2TAW79mB1DpaRMtSEqu5jKmN7AVBGOZ5fk6vrFYQ2tTSi2iuffs7Z6IiruoISPxkCLlUtmbdlefP1RWfWogX4wg/f66u+DSb9FtLuuJjH1D/M9pcLBx3Da'+\n\t\t\t'tey82EIf16tr74KAkmgB+fBWKileHWxCZK4H5yFrYaHzzHmZBuOXfcUmBUF99vZsHEm//+AMAuSuh/ZRb9r8zqlnfPhrH1ldm64qPEFUrg+ufPwNGiMVdjxvyGZcPVCmrZhKYsoGjO8laODRM9pe/65VISVs+F4Z3w65ZHDi9i7WK84nXvrYPo2lV2k1ZPhpA4FYLdxcL/8BgcA27kUbCewj87X1HfMeCB+9atYHxcwXePikgcWUQ2JsI14cem+0eqxjC6DpRdHe01dkUMKX1MbfE5DwTgkF2tXEqC9NYypGNLcD44Bnu/p9yWKCHz68ptFmxDXthvGQQ4tnBtTETu6IJacEQJeHkW+PLuivr1yPd7IH18uNzffByswp2yiRKYmQikPfr3ynEmqPs6uxCDPSYiazC+Fv2bPaXnTDCBbmFBJWzu45cQv/N6Q21pifEB'+\n\t\t\t'1T1zz4ThDKm/JDZNB7Equ2RF7KKErTrClNzmQ/jGwZLr5oin4H9jQSU4jChh2ysz+MsX9lTUbxVvm58PNFytoJYAmbKA2ut+lb8FHT0cMtHyDYr+cVlXgHKpLGJvqj/EdheLrX9bEBigLADckBfcdi+cAx6V65U4tlRh+XRN+OH7VNm9ygPAEMDt7EPy2BLcB2rHUroObDN2rI6mX+cd5Xo2FwvHHdvA3rwVcLEqJZOOLlZYPswdAdh04kT2nb3I/ehswfopMh8vPEwEuAEALgY5RfwkH/AWREfhVtmqWFf2YALMQvmLIufjYFdcyx2/hOTHjIlGRh5DHgDk55tee7dU7ghaPzU0entAdZ8itwXgWoxj4MU/qyybgVdm8ZfRW0u/b35jocLyuXx7AJdvC5THCiAPL+IjfRh+fhouhbB5FmPwLMaQ2Gb5aB1TrObSZq'+\n\t\t\t'sMVyuo5YKZejftEqDYyRCyCjer99ZBdO8qf7uIKwldKyd5PlwhHn2f2A6nQmCUeCb8JWEqkjiptrwYH4eeT+nHdmwuBp464tMI6aOLOn1Wfr9kT6vHbBvywl4lSA2Ohf3BscoAcRVrxCxGJw86NW5W8uAuVV1nFffMCEYtJ6uktnmx8ukPqV6zixI8s2W33zutvifJgA+Xbw/otpfjWMx9YXdFQLt3ujn3xAgz6eZ5O01zwdpF9KQ6Kt+9qxd2F4NVRVwnfioElyaNrhUltodDdxVXTY9sTERW84296SONC8zakbKQaF0wTiEU7JAXkiJtnj6ygMypINidfWDG/RWxIADIBRMV1o/9ljopVY6FbWcv8krhmq8UdLPYF+JgNUHlvI4Y2EQJ7Eyk9HvOxyHX70FmRy+cZ0KlaxwzYaT3mAsg2+MiuoUF1WuZfv0voEZY'+\n\t\t\t'2+ZF2u9RuWNcKIHV0T5woUSF9RPZV/ueZDkWV0f60HO2LDqexfaFQAywt1rBhp6/nlpJIqkQku5dfXD0cOh29QEoxzniJ0PYokmfS1G1eLAmvwm19QE0ZZ6PUoC0KAXIeWAbpB+ppx3kYyIyx5aQObYE+4AH7B3bwOxUZIh0AvKG5goFfIBSgCwEom0rSTh+WkjL23UELO/jkN3RW/E6q7Fu0jcVPpzSaF9JgADAdXzJkAD1/I88hngKjM77EEc3123DCmsBr0qAuhYLfwO7WHlPkoH69yQR8KoEyLnOgWiTVA3nNHIyqop2TEIMa1Lvm+TAMeNi4N2rtmaib9bOljh1LAazsE1ow3BfQ164HxpTBaaV5FYSSP/8HNK/0s+6lDDiBjXDTREl2OfjVcVH/MwuXZdM635JcvA2s6MPOcW4mGAC7EJ9y8yxEINjIaYrPs'+\n\t\t\t'mbBpE28OG3Qs7EWjUj12a8rkaG0zE0TYDWm2wqi5giBsO4WFXsR/kcAK5WyZQV0ZuAaBapCW2w273qx1D5oYUZ8sLzjzfCdf8o2J36c2Gyp0PIzlSfZpAPGhizgQ+2VaT9AaQOTejOAWJnwqrAdDbgVYlOZlT9njmLsamsj0P04IcsZ7+MoM2GSd7qos6F6t+TDne5DNM0F6yf8a+rFRQ7WdnXe8+dq3p9JioicS4Ct2wlOQc8qjhQ6mIcuVRWd5azHg4dayd1PmJqyYYe3ofGambB9GDH/WDH/cilJGRnIki/OqfKkknHluDc0QebToA9Px+Hrc4EwPy85p/dbAYMQH7Ii/SXdoN9eRaMwnWyBRNVrTD2jCZgHhfh+el0OduncV+cZ4JIfmy4ZnA7qUiVpwM+ZH1cxQzoZmMXJXRpRFyUJw+K/sp74l6I151c6Na0'+\n\t\t\t't14ZsGazYS2gK5oUejYlIXkxrnpoiSusoC4doYjXcNO0ExrtLqZChNZO1Z74WG9SZKPYXCzYcX/FxMNSOcfCphlz9uhiYX5PNRbilUHnBmYeZ/erszvMTBh2HQvLFhPBaiw3e0wEsxAHKz8YHevNeab2l2CCDyDJB5DgA8gEvC0XHwDYrDO7uTgPKMexJTEqsuWNBTA17olnMV5hAcVHrd+TdaDqLOVaAtSxR1pcPRdRzfUxSuJcGJJs0rt39VasE4seXkT0cGUQOJfKIvzSBYRfuqASke5bt2qukxD+4VlIK5VzScTzEUS+fwqZJmSQSm2+ehGS1jpBYTFqNZibNRmWlASp2gzn+Thy/6uxKjkWGDeeLdSS93HIaiYbOl+ujFM5LM5wdh3vnP2onKEEBn75Z2zSpMiv7u5HRiF80RvV98QuShh6blp3hrN7MY7AL/'+\n\t\t\t'+sei3LsYiMNW8JSQs4Wa2glgtmysn02D3AOrlg2uCze7sX7mHFJDdFWfxkqGJi4hZ5fVj/p0Zw6b/VmaTo4UWsyml7xsdBiolYO1deYJpeScL/8BhsLgbuCT+Sp0IQFdZWZiWBy987Bef28gr61LlIKT4U/eFZbLp/BFyVlH9ck9lSvhn7gAeuuwpjX/vVBWROh4BjS3CM+wvZLheLfEpCWjPTWZmSZ8b9yJ0OIqcQwvxKAtJ/vA3bzr6SO5afCSOvF9OSZ0s3gvTxYTAzkZLlZYuJcLy+iIy84NUmSmA185Uye/zI+dSB19JuBYoZ1faYCOdMGOkGrDSrDDxXXnzrDFam14FC7Cc0Oax6Lb67H96zIXQpFr5yoQRGvn8cV0f6IMoz2TfNhlUTEItcufE6Qwtdm8UOZ/PcvaaN2mNfnwxQOioioXGvBu7ZDk7+kCln'+\n\t\t\t'ohafX/l92aq5eipUEiDXdi/8D4wg9Ev1B1aKiliN6otpZiWB1WNL2CRPKuz7/C5c/uFZZDQf1vTFONI6biAArL56Ec6dfbDpxJukKnWA8s1KvXqxID7FMZ0OqX5XYnOxFVaP43O7kP7x2QqByZ8PI3++xrq4cb/pVfG6cCykmwdVSzEcry9A2uNH3seBmYmoUu95jkXq3tHC8+JrpZ82sPNxsIoPr3M62BYBci3U/s4W/R6E/npUN8v13gO7EHhuuiIAvelCGJsuVL8n0bF+BG/Tn7TYKrrtTrNVLLlgU2Z66LGvTxAsrIn9uAbccNVIf2/SWBq5lKTKiG2a8MP/wAjsOrOG9ei+dRBexYxmu4vB5ofHwBkMPjM+Dj0PjemKj1Ec434wBlL+NhdbWAumTaNzLBwPjsFeJXOm29YdAeC+UbNDrUpWZwsO7jcFV0y76j'+\n\t\t\t'1TZX1YkbTWpZsJq5ZqtJscxyJyewCXvri7It6jvGbhi7uxaiKWE7x9CIv37GjWMA1zo7l1YECNcE6tT52p5e09dlNLxyyTjorwbPeWvgF79tb+Yzh6OPT81SDE5fI3i7icRPdE+ZruCT/cO/sQe3MJq6dCFZMMi3sBeSb8ulmuogiJF+NIvLmMlI4VwQ544JrwwzXuh83FlMbv0LRXke3SuGAAwAy44fnKONKnQ5DORyBp+rO5WDA7esEeCMDm4/RTaBwL9rO7kJuPF1wyvT2BfBxsO/qAmwfNzwVyMcgrsmXaNHueY5G5bwSMJtbDzISRdzHIDnlL464vQP0VwWd2IYasrx+ZgPUvxky/W/Wny2lia6Kibb0/cWqbF6LfUwo419tELcexeO+BD8G9GId3Oqi7J1DGyyE+0ocrN16HdJvmAu1wmP6bzlUrsNWqJQiC'+\n\t\t\t'qY3nfpV4GavymjCtqay7oFJ7Ta2yGvUBm26Zsbr6ZSnZFWJ6OLBeznT9bExEVt5V0Tnktfaei891xl9+XnjvuZiIXEyEvd9dWIBap77uz5iIfKwwZtuAu5DOrtm3gbIm1tevZ2uwvn5ZI3WVfdeqZ6S+Q95TCABSfjeyxd0KUH7vVvuvOzad+ltZN34+eA/MwPN8VZ2p53dMwcSuiH7GXxKgjY5LYWXV/erSgfFxpe04rNQ3i93HFaydRrpTtEF0Bhkvh7S3wfvaRCy4X1O1CuvNAzKViu9nrKdnCYLofA50XWe2Sk0NqSdAVfP3emxjP2DmcoIgNhgWLKDf1yqsJ0BVj9PQw2FzkAgRxDXKfZ4hU3tBy0zVKqwpQDzPR2HSDbvesd3M5QRBbBDu85j+bJ+QNaQqRtaCvWimxw+wH1i3SYkEQawPW1m32X2gAeAH9S'+\n\t\t\t'4wIkCm3DAA2OMcM1uFIIgO5u+9H7ZSra521BUgnudPwLQbNkxWEEFcIwyybtzrMX0I4olqZ4EpMbodR11TSss4WUEEcU3wFWvWz3eMXGRUgJ6FyaUZ1zuGaV4QQWxw9nFbrFg/URgM3RgSIDmSbToWdKNrQxysQRBEFb7WO1H/okqerZf9KmJmR8QnzY6i196Dcc78KZoEQbSfr/dMWFl4Chh0vwATAiQHlJ41O5Jx5xgGyBUjiA3FPm4LvrBJ/5DNOjxrJPhcxOye0KatIAA40LUfDpvpGZQEQbSBrawbT22+zWp1UxphSoBkZXvaTB0AcNocuMs9CSeJEEF0NN12B57afJuVJRcA8KQZ6wewdirGkzCZEQOAXqYHd7knLXRHEMR60G134Lv+Axi1FveZgwXjxLQAydHtR83WAwoidHvXLVaqEgTRQrrtDnzHuvgA'+\n\t\t\t'wBNGM19KLJ0LxvP8C7CQlgeADzqG8UnP3eSOEUSH0ATxeUHWBNM0cjDho7DgigEFS+hu9yS6abkGQbSVrawbTzcmPpY9IqABAWrEFQMKIvRJz90YYClFTxDtYH/XIL7X/7FGxAcAPmPF9SrS0NHMstllKTUPFLJjn3BP4hbXDeSSEcQ60W134Ks9E/hX69muIk/yPD/VSAM1T8UwiiAIvwBwsJE2VnMJvJ46hmWpcLxKu0/FMN63tVMtmn0qhtX+1/NUCzoVo9n1zZ+KsZfbgn/quwlbGTca5Fme5y17QEWadTLqowCGAVhe/NVt9+Ae9ySWsyEcXTt2zZyuQRCdwIjDh6/2TGCv+U3F9DgB4IlmNNQUCwgABEHoAfAaGhAhJbOZOcxm5rAkW0RkAVWrRxZQY/X1y64VC2gvtwWf7R7F/i718dwNcALAnY3EfZQ0TY'+\n\t\t\t'CA5osQAISzUcxk5jCbnoOYzwAgAVLXIwFqrL5+2UYWoG67A3e7h3CPeztGGgswa2mq+ABNFiCgNSJUZFkKYSkbwpIUxJIUIgECQAJEAgQAE9wWTHB+8K7BZotOkaaLD9ACAQJaK0JKrmSjWM0lcCUXAwBcMhDAhrZM7/oa9bXX6NVvqC/t87yBa3S+CUvP85Wv642j6vsy+d6N9GX4+rz+6+o2bbrXmHnvVduvIkC1x1OJ4b+19meVez8ux3E+6OjBAONuleAoaYn4AC0SIKAkQt8GcKhVfRAE0XKaku2qRssEqIggCI+jIEQEQWwsnuB53vQCUzO0XIAAQBCESQDPoJCqJwiis5lDYYazqdNwrNDQTGijyLMl98HCcn2CINaVpwHsWw/xAdbJAlJC1hBBdCRzAB5tdGmFWdZdgIoIgvAtAI8B6GnXGAiCQBSFNV1t'+\n\t\t\t'8U7aJkBAKVP2OEiICGK9iaJwesXTrUivG6WtAlREFqJDKAjRcFsHQxDXNnMoCI/hs7taSUcIkBJBEA4C+DRo/hBBNIviwaIvWt25sFV0nAAVka2iSRTE6CDIRSMIM8wBmEIHio6SjhUgLYIg3IDC0o698s/Jtg6IIDqLKRSWTJwEMGX2eJx2sWEESA/ZSiquNxsGxY+I9wdz8gPrnTYnCIIgCIIgCIIgCIIgCIIgCIIgCIIgCIIgCILQ8v9Pl9fKF90j8QAAAABJRU5ErkJggg==';\n\t\tme._in__img.ggDownSrc=hs;\n\t\tel.ggId=\"In\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_button \";\n\t\tel.ggType='button';\n\t\ths ='';\n\t\ths+='bottom : 2.71739%;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 5.54348%;';\n\t\ths+='position : absolute;';\n\t\ths+='right : 0.572917%;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 6.25%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='100% 100%';\n\t\tme._in.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._in.onclick=function (e) {\n\t\t\tme.__menu.style[domTransition]='none';\n\t\t\tme.__menu.style.visibility=(Number(me.__menu.style.opacity)>0||!me.__menu.style.opacity)?'inherit':'hidden';\n\t\t\tme.__menu.ggVisible=true;\n\t\t\tme._in.style[domTransition]='none';\n\t\t\tme._in.style.visibility='hidden';\n\t\t\tme._in.ggVisible=false;\n\t\t}\n\t\tme._in.onmouseover=function (e) {\n\t\t\tme._in__img.src=me._in__img.ggOverSrc;\n\t\t}\n\t\tme._in.onmouseout=function (e) {\n\t\t\tme._in__img.src=me._in__img.ggNormalSrc;\n\t\t}\n\t\tme._in.onmousedown=function (e) {\n\t\t\tme._in__img.src=me._in__img.ggDownSrc;\n\t\t}\n\t\tme._in.onmouseup=function (e) {\n\t\t\tif (skin.player.getHasTouch()) {\n\t\t\t\tme._in__img.src = me._in__img.ggNormalSrc;\n\t\t\t} else {\n\t\t\t\tme._in__img.src = me._in__img.ggOverSrc;\n\t\t\t}\n\t\t}\n\t\tme._in.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.divSkin.appendChild(me._in);\n\t\tme._map_1.ggMarkerInstances=[];\n\t\tme._map_1.ggMapId = 'nivel4';\n\t\tme._map_1.ggLastNodeId=null;\n\t\tme._map_1.ggSimpleFloorplanMarkerArray=[];\n\t\tme._map_1.ggFloorplanWidth=0;\n\t\tme._map_1.ggFloorplanHeight=0;\n\t\tme._map_1__mapdiv=document.createElement('div');\n\t\tme._map_1__mapdiv.className='ggskin ggskin_map';\n\t\tme._map_1.appendChild(me._map_1__mapdiv);\n\t\tme._map_1__img=document.createElement('img');\n\t\tme._map_1__img.className='ggskin ggskin_map';\n\t\tme._map_1__mapdiv.appendChild(me._map_1__img);\n\t\tme._map_1.ggRadar={ lastFov : -1, lastPan : -1, xPos : -1, yPos : -1, radarElement : null }\n\t\tme._map_1.ggRadar.update=function() {\n\t\t\tvar radar=me._map_1.ggRadar;\n\t\t\tvar d2r = Math.PI/180 ;\n\t\t\tvar fov = player.getFov();\n\t\t\tvar pan = player.getPanNorth();\n\t\t\tpan -= me._map_1.ggFloorplanNorth;\n\t\t\tvar filterpassed = true;\n\t\t\tvar currentId = player.getCurrentNode();\n\t\t\tif (me._map_1.ggFilteredIds.length > 0 && me._map_1.ggFilteredIds.indexOf(currentId) == -1) filterpassed = false;\n\t\t\tif ((me._map_1.ggSimpleFloorplanMarkerArray.hasOwnProperty(currentId)) && filterpassed) {\n\t\t\t\tvar activeMarker = me._map_1.ggSimpleFloorplanMarkerArray[currentId];\n\t\t\t\tif ((radar.radarElement) && (fov==radar.lastFov) && (pan==radar.lastPan) && (activeMarker.radarXPos==radar.xPos) && (activeMarker.radarYPos==radar.yPos)) return; \n\t\t\t\tradar.lastPan=pan; radar.lastFov=fov;\n\t\t\t\tradar.xPos=activeMarker.radarXPos; radar.yPos=activeMarker.radarYPos;\n\t\t\t\tif (radar.radarElement) me._map_1__mapdiv.removeChild(radar.radarElement);\n\t\t\t\tradar.radarElement = document.createElementNS('http://www.w3.org/2000/svg','svg');\n\t\t\t\tradar.radarElement.setAttributeNS(null,'width',300);\n\t\t\t\tradar.radarElement.setAttributeNS(null,'height',300);\n\t\t\t\tradar.radarElement.setAttributeNS(null,'viewBox','0 0 300 300');\n\t\t\t\tvar radarPath = document.createElementNS('http://www.w3.org/2000/svg','path');\n\t\t\t\tradarPath.setAttributeNS(null,'id','radarPath');\n\t\t\t\tpan = -90 - pan;\n\t\t\t\tvar arcX1 = 150 * Math.cos((pan - fov / 2) * d2r);\n\t\t\t\tvar arcY1 = 150 * Math.sin((pan - fov / 2) * d2r);\n\t\t\t\tvar arcX2 = 150 * Math.cos((pan + fov / 2) * d2r);\n\t\t\t\tvar arcY2 = 150 * Math.sin((pan + fov / 2) * d2r);\n\t\t\t\tarcX1 += 150;\n\t\t\t\tarcY1 += 150;\n\t\t\t\tarcX2 += 150;\n\t\t\t\tarcY2 += 150;\n\t\t\t\tvar radarPathString = 'M150,150 L' + arcX1 + ',' + arcY1 + ' A 150 150 0 0 1 ' + arcX2 + ' ' + arcY2 +' Z';\n\t\t\t\tradarPath.setAttributeNS(null,'d', radarPathString);\n\t\t\t\tradarPath.setAttributeNS(null,'fill', '#00aaff');\n\t\t\t\tradarPath.setAttributeNS(null,'fill-opacity', 0.35);\n\t\t\t\tradarPath.setAttributeNS(null,'stroke', '#00aaff');\n\t\t\t\tradarPath.setAttributeNS(null,'stroke-opacity', 0.8);\n\t\t\t\tradarPath.setAttributeNS(null,'stroke-width', 1);\n\t\t\t\tradarPath.setAttributeNS(null,'stroke-linejoin', 'miter');\n\t\t\t\tradar.radarElement.appendChild(radarPath);\n\t\t\t\tme._map_1__mapdiv.appendChild(radar.radarElement);\n\t\t\t\tvar radarXPos = activeMarker.radarXPos - 150;\n\t\t\t\tvar radarYPos = activeMarker.radarYPos - 150;\n\t\t\t\tradar.radarElement.style['position'] = 'absolute';\n\t\t\t\tradar.radarElement.style['left'] = '' + radarXPos + 'px';\n\t\t\t\tradar.radarElement.style['top'] = '' + radarYPos + 'px';\n\t\t\t\tradar.radarElement.style['z-index'] = me._map_1.style['z-index'] + 1;\n\t\t\t} else {\n\t\t\t\tif (radar.radarElement) {\n\t\t\t\t\tme._map_1__mapdiv.removeChild(radar.radarElement);\n\t\t\t\t\tradar.radarElement = null;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map_1.ggShowSimpleFloorplan=function(mapDetails) {\n\t\t\tvar mapWidth = me._map_1.clientWidth;\n\t\t\tvar mapHeight = me._map_1.clientHeight;\n\t\t\tvar levelLimit = 500;\n\t\t\tvar level = 1;\n\t\t\twhile (mapWidth > levelLimit && mapHeight > levelLimit) {\n\t\t\t\tlevelLimit *= 2;\n\t\t\t\tif (mapDetails['width'] < levelLimit || mapDetails['height'] < levelLimit) break;\n\t\t\t\tlevel++;\n\t\t\t}\n\t\t\tvar imageFilename = basePath + 'images/maptiles/' + me._map_1.ggMapId + '_' + level + '.' + mapDetails['tileformat'];\n\t\t\tme._map_1__img.setAttribute('src', imageFilename);\n\t\tme._map_1__mapdiv.setAttribute('style','position: absolute; left: 50%; margin-left: -' + me._map_1.ggFloorplanWidth / 2 + 'px; top: 50%; margin-top: -' + me._map_1.ggFloorplanHeight / 2 + 'px;width:' + me._map_1.ggFloorplanWidth + 'px;height:' + me._map_1.ggFloorplanHeight + 'px;overflow:hidden;;');\n\t\tme._map_1__img.setAttribute('style','width:' + me._map_1.ggFloorplanWidth + 'px;height:' + me._map_1.ggFloorplanHeight + 'px;-webkit-user-drag:none;pointer-events:none;');\n\t\t}\n\t\tme._map_1.ggCalculateFloorplanSize=function(mapDetails) {\n\t\t\tvar floorplanWidth = mapDetails['width'];\n\t\t\tvar floorplanHeight = mapDetails['height'];\n\t\t\tvar frameAR = me._map_1.clientWidth / me._map_1.clientHeight;\n\t\t\tvar floorplanAR = floorplanWidth / floorplanHeight;\n\t\t\tif (frameAR > floorplanAR) {\n\t\t\t\tme._map_1.ggFloorplanHeight = me._map_1.clientHeight;\n\t\t\t\tme._map_1.ggFloorplanWidth = me._map_1.ggFloorplanHeight * floorplanAR;\n\t\t\t} else {\n\t\t\t\tme._map_1.ggFloorplanWidth = me._map_1.clientWidth;\n\t\t\t\tme._map_1.ggFloorplanHeight = me._map_1.ggFloorplanWidth / floorplanAR;\n\t\t\t}\n\t\t}\n\t\tme._map_1.ggInitMap=function() {\n\t\t\tme._map_1.ggMapNotLoaded = false;\n\t\t\tvar mapDetails = player.getMapDetails(me._map_1.ggMapId);\n\t\t\tme._map_1.style.backgroundColor = mapDetails['bgcolor'];\n\t\t\tif (mapDetails.hasOwnProperty('transparent') && mapDetails['transparent']) {\n\t\t\t\tme._map_1.ggPermeableMap = true;\n\t\t\t} else {\n\t\t\t\tme._map_1.ggPermeableMap = false;\n\t\t\t}\n\t\t\tme._map_1.ggCalculateFloorplanSize(mapDetails);\n\t\t\tme._map_1.ggShowSimpleFloorplan(mapDetails);\n\t\t\tme._map_1.ggFloorplanNorth = mapDetails['floorplannorth'];\n\t\t}\n\t\tme._map_1.ggClearMap=function() {\n\t\t\tme._map_1.ggClearMapMarkers();\n\t\t\tme._map_1.ggMapNotLoaded = true;\n\t\t}\n\t\tme._map_1.ggChangeMap=function(mapId) {\n\t\t\tvar newMapType = player.getMapType(mapId)\n\t\t\tif (newMapType == 'web') {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tme._map_1.ggMapId = mapId;\n\t\t\tme._map_1.ggClearMap();\n\t\t\tme._map_1.ggInitMap();\n\t\t\tme._map_1.ggInitMapMarkers();\n\t\t}\n\t\tme._map_1.ggPlaceMarkersOnSimpleFloorplan=function() {\n\t\t\tvar markers=me._map_1.ggSimpleFloorplanMarkerArray;\n\t\t\tfor (id in markers) {\n\t\t\t\tif (markers.hasOwnProperty(id)) {\n\t\t\t\t\tmarker=markers[id];\n\t\t\t\t\tvar coords = player.getNodeMapCoordsInPercent(id, me._map_1.ggMapId);\n\t\t\t\t\tvar xPos = (me._map_1.ggFloorplanWidth * coords[0]) / 100.0;\n\t\t\t\t\tvar yPos = (me._map_1.ggFloorplanHeight * coords[1]) / 100.0;\n\t\t\t\t\tmarker.radarXPos = xPos;\n\t\t\t\t\tmarker.radarYPos = yPos;\n\t\t\t\t\txPos -= me._map_1.ggHMarkerAnchorOffset;\n\t\t\t\t\tyPos -= me._map_1.ggVMarkerAnchorOffset;\n\t\t\t\t\tmarker.style['position'] = 'absolute';\n\t\t\t\t\tmarker.style['left'] = xPos + 'px';\n\t\t\t\t\tmarker.style['top'] = yPos + 'px';\n\t\t\t\t\tmarker.style['z-index'] = me._map_1.style['z-index'] + 2;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map_1.ggInitMapMarkers=function() {\n\t\t\tme._map_1.ggClearMapMarkers();\n\t\t\tvar ids=player.getNodeIds();\n\t\t\tme._map_1.ggFilteredIds = [];\n\t\t\tif (me._map_1.ggFilter != '') {\n\t\t\t\tvar filter = me._map_1.ggFilter.split(',');\n\t\t\t\tfor (i=0; i < ids.length; i++) {\n\t\t\t\t\tvar nodeId = ids[i];\n\t\t\t\t\tvar nodeData = player.getNodeUserdata(nodeId);\n\t\t\t\t\tfor (var j=0; j < filter.length; j++) {\n\t\t\t\t\t\tif (nodeData['tags'].indexOf(filter[j].trim()) != -1) me._map_1.ggFilteredIds.push(nodeId);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (me._map_1.ggFilteredIds.length > 0) ids = me._map_1.ggFilteredIds;\n\t\t\t}\n\t\t\tfor(var i=0; i < ids.length; i++) {\n\t\t\t\tvar id = ids[i];\n\t\t\t\tvar coords = player.getNodeMapCoordsInPercent(id, me._map_1.ggMapId);\n\t\t\t\tif (coords.length>=2) {\n\t\t\t\t\tme._map_1.ggHMarkerAnchorOffset = 20;\n\t\t\t\t\tme._map_1.ggVMarkerAnchorOffset = 40;\n\t\t\t\t\tvar marker = document.createElement('img');\n\t\t\t\t\tmarker.setAttribute('src', basePath + 'images/_ggMapPin.png');\n\t\t\t\t\tmarker.setAttribute('title', player.getNodeTitle(id));\n\t\t\t\t\tmarker.style['width'] = '40px';\n\t\t\t\t\tmarker.style['width'] = '40px';\n\t\t\t\t\tmarker.style['cursor'] = 'pointer';\n\t\t\t\t\tmarker.ggId = id;\n\t\t\t\t\tmarker.onclick = function() {\n\t\t\t\t\t\tplayer.openNext('{' + this.ggId + '}');\n\t\t\t\t\t}\n\t\t\t\t\tme._map_1.ggSimpleFloorplanMarkerArray[id] = marker;\n\t\t\t\t\tme._map_1__mapdiv.appendChild(marker);\n\t\t\t\t}\n\t\t\t}\n\t\t\tme._map_1.ggPlaceMarkersOnSimpleFloorplan();\n\t\t\tskin.updateSize(me._map_1);\n\t\t}\n\t\tme._map_1.ggClearMapMarkers=function() {\n\t\t\tfor (id in me._map_1.ggSimpleFloorplanMarkerArray) {\n\t\t\t\tif (me._map_1.ggSimpleFloorplanMarkerArray.hasOwnProperty(id)) {\n\t\t\t\t\tme._map_1__mapdiv.removeChild(me._map_1.ggSimpleFloorplanMarkerArray[id]);\n\t\t\t\t}\n\t\t\t}\n\t\t\tme._map_1.ggMarkerInstances=[];\n\t\t\tme._map_1.ggSimpleFloorplanMarkerArray=[];\n\t\t}\n\t\tplayer.addListener('sizechanged', function() {\n\t\t\tme.updateSize(me.divSkin);\n\t\t});\n\t\tplayer.addListener('configloaded', function() {\n\t\t\tme._map_1.ggClearMap();\n\t\t\tme._map_1.ggInitMap(false);\n\t\t\tme._map_1.ggInitMapMarkers(true);\n\t\t});\n\t};\n\tthis.hotspotProxyClick=function(id, url) {\n\t}\n\tthis.hotspotProxyDoubleClick=function(id, url) {\n\t}\n\tme.hotspotProxyOver=function(id, url) {\n\t}\n\tme.hotspotProxyOut=function(id, url) {\n\t}\n\tme.callChildLogicBlocksHotspot_ht_image_changenode = function(){\n\t\tif(hotspotTemplates['ht_image']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_image'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_image'][i]._ht_image_image && hotspotTemplates['ht_image'][i]._ht_image_image.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_image'][i]._ht_image_image.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_image'][i]._tt_ht_image && hotspotTemplates['ht_image'][i]._tt_ht_image.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_image'][i]._tt_ht_image.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_image'][i]._ht_image_customimage && hotspotTemplates['ht_image'][i]._ht_image_customimage.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_image'][i]._ht_image_customimage.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_image_configloaded = function(){\n\t\tif(hotspotTemplates['ht_image']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_image'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_image'][i]._tt_ht_image && hotspotTemplates['ht_image'][i]._tt_ht_image.logicBlock_position) {\n\t\t\t\t\thotspotTemplates['ht_image'][i]._tt_ht_image.logicBlock_position();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_image_mouseover = function(){\n\t\tif(hotspotTemplates['ht_image']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_image'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_image'][i]._tt_ht_image && hotspotTemplates['ht_image'][i]._tt_ht_image.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_image'][i]._tt_ht_image.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_image_hastouch = function(){\n\t\tif(hotspotTemplates['ht_image']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_image'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_image'][i]._tt_ht_image && hotspotTemplates['ht_image'][i]._tt_ht_image.logicBlock_position) {\n\t\t\t\t\thotspotTemplates['ht_image'][i]._tt_ht_image.logicBlock_position();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_image_activehotspotchanged = function(){\n\t\tif(hotspotTemplates['ht_image']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_image'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_image'][i]._ht_image_image && hotspotTemplates['ht_image'][i]._ht_image_image.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_image'][i]._ht_image_image.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_image'][i]._tt_ht_image && hotspotTemplates['ht_image'][i]._tt_ht_image.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_image'][i]._tt_ht_image.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_image'][i]._ht_image_customimage && hotspotTemplates['ht_image'][i]._ht_image_customimage.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_image'][i]._ht_image_customimage.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tplayer.addListener('changenode', function() {\n\t\tme.ggUserdata=player.userdata;\n\t});\n\tme.skinTimerEvent=function() {\n\t\tme.ggCurrentTime=new Date().getTime();\n\t\tme._map_1.ggUpdateConditionTimer();\n\t};\n\tplayer.addListener('timer', me.skinTimerEvent);\n\tfunction SkinHotspotClass_ht_image(parentScope,hotspot) {\n\t\tvar me=this;\n\t\tvar flag=false;\n\t\tvar hs='';\n\t\tme.parentScope=parentScope;\n\t\tme.hotspot=hotspot;\n\t\tvar nodeId=String(hotspot.url);\n\t\tnodeId=(nodeId.charAt(0)=='{')?nodeId.substr(1, nodeId.length - 2):''; // }\n\t\tme.ggUserdata=skin.player.getNodeUserdata(nodeId);\n\t\tme.elementMouseDown=[];\n\t\tme.elementMouseOver=[];\n\t\tme.findElements=function(id,regex) {\n\t\t\treturn skin.findElements(id,regex);\n\t\t}\n\t\tel=me._ht_image=document.createElement('div');\n\t\tel.ggId=\"ht_image\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_hotspot \";\n\t\tel.ggType='hotspot';\n\t\ths ='';\n\t\ths+='height : 0px;';\n\t\ths+='left : 200px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 200px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 0px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_image.ggIsActive=function() {\n\t\t\treturn player.getCurrentNode()==this.ggElementNodeId();\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif (me.hotspot.url!='' && me.hotspot.url.charAt(0)=='{') { // }\n\t\t\t\treturn me.hotspot.url.substr(1, me.hotspot.url.length - 2);\n\t\t\t} else {\n\t\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t\t} else {\n\t\t\t\t\treturn player.getCurrentNode();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_image.onclick=function (e) {\n\t\t\tskin._popup_image.ggText=player.getBasePath()+\"\"+me.hotspot.url;\n\t\t\tskin._popup_image.ggSubElement.style.width = '0px';\n\t\t\tskin._popup_image.ggSubElement.style.height = '0px';\n\t\t\tskin._popup_image.ggSubElement.src='';\n\t\t\tskin._popup_image.ggSubElement.src=skin._popup_image.ggText;\n\t\t\tplayer.setVariableValue('vis_image_popup', true);\n\t\t\tskin._image_popup.style[domTransition]='none';\n\t\t\tskin._image_popup.style.visibility=(Number(skin._image_popup.style.opacity)>0||!skin._image_popup.style.opacity)?'inherit':'hidden';\n\t\t\tskin._image_popup.ggVisible=true;\n\t\t\tskin.__menu.style[domTransition]='none';\n\t\t\tskin.__menu.style.visibility='hidden';\n\t\t\tskin.__menu.ggVisible=false;\n\t\t\tskin._in.style[domTransition]='none';\n\t\t\tskin._in.style.visibility=(Number(skin._in.style.opacity)>0||!skin._in.style.opacity)?'inherit':'hidden';\n\t\t\tskin._in.ggVisible=true;\n\t\t\tskin.hotspotProxyClick(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_image.ondblclick=function (e) {\n\t\t\tskin.hotspotProxyDoubleClick(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_image.onmouseover=function (e) {\n\t\t\tplayer.setActiveHotspot(me.hotspot);\n\t\t\tme.elementMouseOver['ht_image']=true;\n\t\t\tme._tt_ht_image.logicBlock_visible();\n\t\t\tskin.hotspotProxyOver(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_image.onmouseout=function (e) {\n\t\t\tplayer.setActiveHotspot(null);\n\t\t\tme.elementMouseOver['ht_image']=false;\n\t\t\tme._tt_ht_image.logicBlock_visible();\n\t\t\tskin.hotspotProxyOut(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_image.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['ht_image']=false;\n\t\t\tme._tt_ht_image.logicBlock_visible();\n\t\t}\n\t\tme._ht_image.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._ht_image_image=document.createElement('div');\n\t\tels=me._ht_image_image__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmVyc2lvbj0iMS4xIiB5PSIwcHgiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBiYXNlUHJvZmlsZT0idGlueSIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgaWQ9IkxheWVyXzEiIHg9IjBweCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPGc+CiAgIDxwYXRoIGZpbGw9IiMwMDAwMDAiIGQ9Ik0tMTk2LjMsNDE0LjdoNDIuN3YtNDRoLTQyLjdWNDE0Ljd6IE0tMTU1LjUsNDEyLjlILTE4M2wxOS0xOC42YzAuMy0wLjMsMC42LTAuNCwxLTAuNCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC40LDAsMC43LDAuMSwxLDAuNGw2LjUsNi40VjQxMi45eiBNLTE2Mi45LDM3NmMyLjIsMCw0LDEuOCw0LDRjMCwyLjItMS44LDQtNCw0Yy0yLjIsMC00LTEuOC00LTQmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Qy0xNjYuOCwzNzcuOC0xNjUuMSwzNzYtMTYyLjksMzc2eiBNLTE5NC41LDM5Ny44bDkuNy05LjRjMC4zLTAu'+\n\t\t\t'MywwLjYtMC40LDEtMC40YzAuNCwwLDAuNywwLjEsMSwwLjRsMTEuMiwxMC45bC0xMy45LDEzLjZoLTkmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7TC0xOTQuNSwzOTcuOEwtMTk0LjUsMzk3Ljh6Ii8+CiAgIDxwYXRoIGZpbGw9IiMwMDAwMDAiIGQ9Ik0tMTc1LDM0MC45Yy0zMSwwLTU2LjEsMjUuMS01Ni4xLDU2LjFjMCwzMSwyNS4xLDU2LjEsNTYuMSw1Ni4xczU2LjEtMjUuMSw1Ni4xLTU2LjEmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Uy0xNDQsMzQwLjktMTc1LDM0MC45eiBNLTE0OS41LDQyNS41YzAsMS4zLTEsMi4zLTIuMywyLjNoLTQ2LjRjLTEuMywwLTIuMy0xLTIuMy0yLjN2LTU3Yz'+\n\t\t\t'AtMS4zLDEtMi4zLDIuMy0yLjNoNDYuNCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMS4zLDAsMi4zLDEsMi4zLDIuM0wtMTQ5LjUsNDI1LjVMLTE0OS41LDQyNS41eiIvPgogIDwvZz4KIDwvZz4KIDxnIGlkPSJMYXllcl8yIj4KICA8Zz4KICAgPHBhdGggZmlsbD0iI0ZGRkZGRiIgZD0iTS0xNTEuOCwzNjYuMmgtNDYuNGMtMS4zLDAtMi4zLDEtMi4zLDIuM3Y1N2MwLDEuMywxLDIuMywyLjMsMi4zaDQ2LjRjMS4zLDAsMi4zLTEsMi4zLTIuM3YtNTcmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Qy0xNDkuNSwzNjcuMi0xNTAuNSwzNjYuMi0xNTEuOCwzNjYuMnogTS0xNTMuNyw0MTQuN2gtNDIu'+\n\t\t\t'N3YtNDRoNDIuN1Y0MTQuN3oiLz4KICAgPGNpcmNsZSByPSI0IiBmaWxsPSIjRkZGRkZGIiBjeT0iMzc5LjkiIGN4PSItMTYyLjkiLz4KICAgPHBhdGggZmlsbD0iI0ZGRkZGRiIgZD0iTS0xNzEuNywzOTkuM2wtMTEuMi0xMC45Yy0wLjMtMC4zLTAuNi0wLjQtMS0wLjRzLTAuNywwLjEtMSwwLjRsLTkuNyw5LjR2MTUuMWg5TC0xNzEuNywzOTkuM3oiLz4KICAgPHBhdGggZmlsbD0iI0ZGRkZGRiIgZD0iTS0xNjMsMzkzLjljLTAuNCwwLTAuNywwLjEtMSwwLjRsLTE5LDE4LjZoMjcuNXYtMTIuMmwtNi41LTYuNEMtMTYyLjIsMzk0LTE2Mi42LDM5My45LTE2MywzOTMuOXoiLz4KICA8L2c+CiA8L2'+\n\t\t\t'c+Cjwvc3ZnPgo=';\n\t\tme._ht_image_image__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._ht_image_image__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmVyc2lvbj0iMS4xIiB5PSIwcHgiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBiYXNlUHJvZmlsZT0idGlueSIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgaWQ9IkxheWVyXzEiIHg9IjBweCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPGc+CiAgIDxwYXRoIGZpbGw9IiMwMDAwMDAiIGQ9Ik0tMTk4LjcsNDE2LjZoNDcuNHYtNDguOWgtNDcuNFY0MTYuNnogTS0xNTMuMyw0MTQuNmgtMzAuNmwyMS4xLTIwLjZjMC4zLTAuMywwLjctMC41LDEuMS0wLjUmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuNCwwLDAuOCwwLjIsMS4xLDAuNWw3LjIsNy4xVjQxNC42eiBNLTE2MS41LDM3My42YzIuNCwwLDQuNCwyLDQuNCw0LjRjMCwyLjQtMiw0LjQtNC40LDQuNHMtNC40LTItNC40LTQuNCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtDLTE2NS45LDM3NS42LTE2NCwzNzMuNi0xNjEuNSwzNzMuNnogTS0xOTYuNywz'+\n\t\t\t'OTcuOWwxMC43LTEwLjVjMC4zLTAuMywwLjctMC41LDEuMS0wLjVzMC44LDAuMiwxLjEsMC40bDEyLjQsMTIuMmwtMTUuNCwxNS4xaC0xMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtMLTE5Ni43LDM5Ny45TC0xOTYuNywzOTcuOXoiLz4KICAgPHBhdGggZmlsbD0iIzAwMDAwMCIgZD0iTS0xNzUsMzM0LjZjLTM0LjQsMC02Mi40LDI3LjktNjIuNCw2Mi40YzAsMzQuNCwyNy45LDYyLjQsNjIuNCw2Mi40czYyLjQtMjcuOSw2Mi40LTYyLjQmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Uy0xNDAuNiwzMzQuNi0xNzUsMzM0LjZ6IE0tMTQ2LjcsNDI4LjdjMCwxLjQtMS4xLDIuNi0yLjYsMi42aC01MS'+\n\t\t\t'42Yy0xLjQsMC0yLjYtMS4xLTIuNi0yLjZ2LTYzLjRjMC0xLjQsMS4xLTIuNiwyLjYtMi42aDUxLjYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzEuNCwwLDIuNiwxLjEsMi42LDIuNkwtMTQ2LjcsNDI4LjdMLTE0Ni43LDQyOC43eiIvPgogIDwvZz4KIDwvZz4KIDxnIGlkPSJMYXllcl8yIj4KICA8Zz4KICAgPHBhdGggZmlsbD0iI0ZGRkZGRiIgZD0iTS0xNDkuMiwzNjIuOGgtNTEuNmMtMS40LDAtMi42LDEuMS0yLjYsMi42djYzLjRjMCwxLjQsMS4xLDIuNiwyLjYsMi42aDUxLjZjMS40LDAsMi42LTEuMSwyLjYtMi42di02My40JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0MtMTQ2LjcsMzYz'+\n\t\t\t'LjktMTQ3LjgsMzYyLjgtMTQ5LjIsMzYyLjh6IE0tMTUxLjMsNDE2LjZoLTQ3LjR2LTQ4LjloNDcuNFY0MTYuNnoiLz4KICAgPGNpcmNsZSByPSI0LjQiIGZpbGw9IiNGRkZGRkYiIGN5PSIzNzgiIGN4PSItMTYxLjUiLz4KICAgPHBhdGggZmlsbD0iI0ZGRkZGRiIgZD0iTS0xNzEuMywzOTkuNWwtMTIuNC0xMi4yYy0wLjMtMC4zLTAuNy0wLjQtMS4xLTAuNGMtMC40LDAtMC44LDAuMi0xLjEsMC41bC0xMC43LDEwLjV2MTYuOGgxMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtMLTE3MS4zLDM5OS41eiIvPgogICA8cGF0aCBmaWxsPSIjRkZGRkZGIiBkPSJNLTE2MS42LDM5My41Yy0wLjQsMC0wLj'+\n\t\t\t'gsMC4yLTEuMSwwLjVsLTIxLjEsMjAuNmgzMC42VjQwMWwtNy4yLTcuMUMtMTYwLjgsMzkzLjctMTYxLjIsMzkzLjUtMTYxLjYsMzkzLjUmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7eiIvPgogIDwvZz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._ht_image_image__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"ht_image_image\";\n\t\tel.ggDx=0;\n\t\tel.ggDy=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_image_image.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_image_image.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.hotspot.customimage != \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_image_image.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_image_image.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_image_image.style[domTransition]='';\n\t\t\t\tif (me._ht_image_image.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_image_image.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_image_image.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_image_image.style.visibility=(Number(me._ht_image_image.style.opacity)>0||!me._ht_image_image.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_image_image.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_image_image.onmouseover=function (e) {\n\t\t\tme._ht_image_image__img.style.visibility='hidden';\n\t\t\tme._ht_image_image__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._ht_image_image.onmouseout=function (e) {\n\t\t\tme._ht_image_image__img.style.visibility='inherit';\n\t\t\tme._ht_image_image__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._ht_image_image.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=(this.ggDy + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._ht_image.appendChild(me._ht_image_image);\n\t\tel=me._tt_ht_image=document.createElement('div');\n\t\tels=me._tt_ht_image__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"tt_ht_image\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='z-index: 100;';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 24px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 100px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: auto;';\n\t\ths+='height: auto;';\n\t\ths+='pointer-events: none;';\n\t\ths+='background: #000000;';\n\t\ths+='background: rgba(0,0,0,0.666667);';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: nowrap;';\n\t\ths+='padding: 2px 5px 2px 5px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=me.hotspot.title;\n\t\tel.appendChild(els);\n\t\tme._tt_ht_image.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._tt_ht_image.logicBlock_position = function() {\n\t\t\tvar newLogicStatePosition;\n\t\t\tif (\n\t\t\t\t((player.getHasTouch() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStatePosition = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStatePosition = -1;\n\t\t\t}\n\t\t\tif (me._tt_ht_image.ggCurrentLogicStatePosition != newLogicStatePosition) {\n\t\t\t\tme._tt_ht_image.ggCurrentLogicStatePosition = newLogicStatePosition;\n\t\t\t\tme._tt_ht_image.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_ht_image.ggCurrentLogicStatePosition == 0) {\n\t\t\t\t\tthis.ggDx = 0;\n\t\t\t\t\tme._tt_ht_image.style.top='-47px';\n\t\t\t\t\tme._tt_ht_image.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_ht_image.ggDx=0;\n\t\t\t\t\tme._tt_ht_image.style.top='24px';\n\t\t\t\t\tme._tt_ht_image.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_ht_image.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['ht_image'] == true)) && \n\t\t\t\t((me.hotspot.title != \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._tt_ht_image.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._tt_ht_image.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._tt_ht_image.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_ht_image.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._tt_ht_image.style.visibility=(Number(me._tt_ht_image.style.opacity)>0||!me._tt_ht_image.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._tt_ht_image.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_ht_image.style.visibility=\"hidden\";\n\t\t\t\t\tme._tt_ht_image.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_ht_image.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t\tthis.style[domTransition]='left 0';\n\t\t\tthis.ggTextDiv.style.left=((98-this.ggTextDiv.offsetWidth)/2) + 'px';\n\t\t}\n\t\tme._ht_image.appendChild(me._tt_ht_image);\n\t\tel=me._ht_image_customimage=document.createElement('div');\n\t\tels=me._ht_image_customimage__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_external';\n\t\tels.setAttribute('style','position: absolute;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.onload=function() {me._ht_image_customimage.ggUpdatePosition();}\n\t\tif ((hotspot) && (hotspot.customimage)) {\n\t\t\tel.ggText=hotspot.customimage;\n\t\t\tels.setAttribute('src', hotspot.customimage);\n\t\t\tels.style.width=hotspot.customimagewidth + 'px';\n\t\t\tels.style.height=hotspot.customimageheight + 'px';\n\t\t\tme.ggUse3d = hotspot.use3D;\n\t\t\tme.gg3dDistance = hotspot.distance3D;\n\t\t}\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\ths ='';\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"ht_image_CustomImage\";\n\t\tel.ggDx=0;\n\t\tel.ggDy=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_external \";\n\t\tel.ggType='external';\n\t\ths ='';\n\t\ths+='border : 0px solid #000000;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 50px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 50px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_image_customimage.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_image_customimage.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.hotspot.customimage == \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_image_customimage.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_image_customimage.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_image_customimage.style[domTransition]='';\n\t\t\t\tif (me._ht_image_customimage.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_image_customimage.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_image_customimage__img.src = '';\n\t\t\t\t\tme._ht_image_customimage.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_image_customimage.style.visibility=(Number(me._ht_image_customimage.style.opacity)>0||!me._ht_image_customimage.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_image_customimage.ggSubElement.src=me._ht_image_customimage.ggText;\n\t\t\t\t\tme._ht_image_customimage.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_image_customimage.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=(this.ggDy + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t\tvar parentWidth = me._ht_image_customimage.clientWidth;\n\t\t\tvar parentHeight = me._ht_image_customimage.clientHeight;\n\t\t\tvar img = me._ht_image_customimage__img;\n\t\t\tvar aspectRatioDiv = me._ht_image_customimage.clientWidth / me._ht_image_customimage.clientHeight;\n\t\t\tvar aspectRatioImg = img.naturalWidth / img.naturalHeight;\n\t\t\tif (img.naturalWidth < parentWidth) parentWidth = img.naturalWidth;\n\t\t\tif (img.naturalHeight < parentHeight) parentHeight = img.naturalHeight;\n\t\t\tvar currentWidth,currentHeight;\n\t\t\tif ((hotspot) && (hotspot.customimage)) {\n\t\t\t\tcurrentWidth = hotspot.customimagewidth;\n\t\t\t\tcurrentHeight = hotspot.customimageheight;\n\t\t\t}\n\t\t\timg.style.left='50%';\n\t\t\timg.style.marginLeft='-' + currentWidth/2 + 'px';\n\t\t\timg.style.top='50%';\n\t\t\timg.style.marginTop='-' + currentHeight/2 + 'px';\n\t\t}\n\t\tme._ht_image.appendChild(me._ht_image_customimage);\n\t\tif ((hotspot) && (hotspot.customimage)) {\n\t\t\tel.style.width=hotspot.customimagewidth + 'px';\n\t\t\tel.style.height=hotspot.customimageheight + 'px';\n\t\t}\n\t\tme.__div = me._ht_image;\n\t};\n\tme.addSkinHotspot=function(hotspot) {\n\t\tvar hsinst = null;\n\t\t{\n\t\t\thotspot.skinid = 'ht_image';\n\t\t\thsinst = new SkinHotspotClass_ht_image(me, hotspot);\n\t\t\tif (!hotspotTemplates.hasOwnProperty(hotspot.skinid)) {\n\t\t\t\thotspotTemplates[hotspot.skinid] = [];\n\t\t\t}\n\t\t\thotspotTemplates[hotspot.skinid].push(hsinst);\n\t\t\tme.callChildLogicBlocksHotspot_ht_image_changenode();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_image_configloaded();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_image_mouseover();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_image_hastouch();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_image_activehotspotchanged();;\n\t\t}\n\t\treturn hsinst;\n\t}\n\tme.removeSkinHotspots=function() {\n\t\tif(hotspotTemplates['ht_image']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_image'].length; i++) {\n\t\t\t\thotspotTemplates['ht_image'][i] = null;\n\t\t\t}\n\t\t}\n\t\thotspotTemplates = [];\n\t}\n\tme.addSkin();\n\tvar style = document.createElement('style');\n\tstyle.type = 'text/css';\n\tstyle.appendChild(document.createTextNode('.ggskin { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 14px;}'));\n\tdocument.head.appendChild(style);\n\tme._screentint_image.logicBlock_visible();\n\tme._image_popup.logicBlock_visible();\n\tme._popup_image.logicBlock_visible();\n\tme._image_popup_close.logicBlock_visible();\n\tplayer.addListener('changenode', function(args) { me._screentint_image.logicBlock_visible();me._image_popup.logicBlock_visible();me._popup_image.logicBlock_visible();me._image_popup_close.logicBlock_visible(); });\n\tplayer.addListener('varchanged_vis_image_popup', function(args) { me._screentint_image.logicBlock_visible();me._image_popup.logicBlock_visible();me._popup_image.logicBlock_visible();me._image_popup_close.logicBlock_visible(); });\n\tplayer.addListener('changenode', function(args) { me.callChildLogicBlocksHotspot_ht_image_changenode(); });\n\tplayer.addListener('configloaded', function(args) { me.callChildLogicBlocksHotspot_ht_image_configloaded(); });\n\tplayer.addListener('mouseover', function(args) { me.callChildLogicBlocksHotspot_ht_image_mouseover(); });\n\tplayer.addListener('hastouch', function(args) { me.callChildLogicBlocksHotspot_ht_image_hastouch(); });\n\tplayer.addListener('activehotspotchanged', function(args) { me.callChildLogicBlocksHotspot_ht_image_activehotspotchanged(); });\n\tplayer.addListener('hotspotsremoved', function(args) { me.removeSkinHotspots(); });\n\tme.skinTimerEvent();\n}", "function changeHangImage() {\n $(\"#images-render\").css(\"background-image\", \"url(hang_images/\" + getHangImage() + \")\");\n}", "function addBackgroundToLayout() {\n var takeoverBackground = document.createElement('div');\n takeoverBackground.classList.add('guinness-takeover-background');\n $document.body.appendChild(takeoverBackground);\n } // apply styling specific to takeover", "function createBackground (background) {\n\tvar w = new MultiWidgets.JavaScriptWidget();\n\n\tw.setWidth(root.width());\n\tw.setHeight(root.height());\n\tw.setFixed();\n\tw.setAutoRaiseToTop(false);\n\n\tw.image = new MultiWidgets.ImageWidget();\n\n\tif (w.image.load(background)) {\n\t w.image.setWidth(w.width());\n\t w.image.setHeight(w.height());\n \tw.image.setFixed();\n \tw.image.setAutoRaiseToTop(false);\n \tw.addChild(w.image);\n \tw.image.raiseToTop();\n\t}\n\t\n\n\treturn w;\n}", "function createBackground (background) {\n\tvar w = new MultiWidgets.JavaScriptWidget();\n\n\tw.setWidth(root.width());\n\tw.setHeight(root.height());\n\tw.setFixed();\n\tw.setAutoRaiseToTop(false);\n\n\tw.image = new MultiWidgets.ImageWidget();\n\n\tif (w.image.load(background)) {\n\t w.image.setWidth(w.width());\n\t w.image.setHeight(w.height());\n \tw.image.setFixed();\n \tw.image.setAutoRaiseToTop(false);\n \tw.addChild(w.image);\n \tw.image.raiseToTop();\n\t}\n\t\n\n\treturn w;\n}", "function generateBackground(image) {\n $('#sprout-animate').css({\n \"background-size\": \"130px 130px\", \"background-image\": \"url('\" + image + \"')\", \"animation-name\": \"popin\",\n \"animation-duration\": \"1.5s\"\n });\n}", "function startDragEffect(){\n $(\".ui-draggable-dragging\").css({\n background: \"#2e8bd9\",\n border: \"1px solid #155489\"\n });\n var color = bgColorForDragEffect(genPageBgColor,\"0.6\");\n $(globalOptions.full_page_content).css(\"background\",color);\n globalSubpageBuild.css({\n background: genPageBgColor,\n borderRadius: \"5px\",\n border: \"1px dashed black\"\n });\n}//startDragEffect", "function SetCSS()\n{\n\t$(\"head\").append($(\"<!--Start of Youtube Music Lyrics v\" + GM.info.script.version + \" CSS-->\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\"#yml_lyricsPanel { \\\n\tposition: absolute;\\\n\tz-index: 100;\\\n\tbackground-color: #1d1d1d;\\\n\t\tfont-size:16px;\\\n\t\toverflow-y:scroll;\\\n\t\tcolor:#aaaaaa;\\\n\tfont-family: inherit;\\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\"#yml_lyricsText { \\\n\tcolor: inherit;\\\n\tfont-family: inherit;\\\n\tpadding-left: 5%;\\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\"#yml_musicName { \\\n\tfont-family: inherit;\\\n\t\tfont-size:20px;\\\n\tpadding-left: 15%;\\\n\t\tpadding-top: 5%;\\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\"#yml_PanelButtons { \\\n\tfloat: right;\\\n\tpadding:10px;\\\n\tmargin:10px;\\\n\tborder: 3px solid;\\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\"#yml_optionsPanel { \\\n\t\tposition: fixed;\\\n\t\tz-index: 111;\\\n\t\tpadding-left: 5%;\\\n\t\tpadding-bottom: 5%;\\\n\t\tborder: 3px solid;\\\n\t\tbackground-color: #2d2d2d;\\\n\t\tfont-size:16px;\\\n\t\toverflow-y:scroll;\\\n\t\tcolor:#aaaaaa;\\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\".yml_Button { \\\n\tcursor: pointer;\\\n\t\tfont-size:16px;\\\n\t\tcolor:#aaaaaa;\\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\".yml_Button:hover { \\\n\ttext-decoration: underline;\\\n}\"));\n\n\t$(\"head\").append($(\"<style type=text/css></style>\").text(\".ui-state-default { \\\n\tcursor: move;\\\n}\"));\n\n\t$(\"head\").append($(\"<!--End of Youtube Music Lyrics v\" + GM.info.script.version + \" CSS-->\"));\n}", "function simplePageTransition() {\n \"use strict\";\n\n $(\".animsition\").animsition({\n inClass: $(this).data('animsition-in-class'),\n outClass: $(this).data('animsition-out-class'),\n inDuration: $(this).data('animsition-in-duration'),\n outDuration: $(this).data('animsition-out-duration'),\n linkElement: 'a:not([target=\"_blank\"]):not([href^=\"#\"]):not(.lightbox-gallery):not(.zoom)'\n\n\n\n });\n }", "function limpiarGrilla(){\n $(document).ready(function(){\n $(\"#grilla-pixeles\").children().animate({\"backgroundColor\":\"white\"}, 1500);\n });\n}", "function myCreativeInit () {\n\n // Code away!!!\n}", "playbackground1() {\r\n background(\"white\");\r\n\r\n //giving the background image details\r\n background(background_image_one);\r\n\r\n //displaying the variables\r\n\r\n \r\n ground.display();\r\n // drawSprites();\r\n\r\n \r\n \r\n \r\n }", "function page_animations() {\n\n var headerTl = new TimelineMax();\n\n headerTl.to('header', 0.25 ,{ opacity: 1})\n .to('header .logo h2', 0.25 ,{ opacity: 1})\n .staggerTo($('.color-box'), 0.3 ,{ opacity: 1}, 0.15, \"header\")\n .staggerTo($('#raw, #build'), 0.3 ,{ opacity: 0.3}, 0.15)\n .staggerTo($('.preview-window, .status'), 0.5 ,{ opacity: 1}, 0.15, \"header\")\n .to($('.tutorial, .about, footer'), 0.25 ,{ opacity: 1}, \"header\");\n\n\n\n // Animates footer heart.\n TweenMax.to('#heart', 1, {scale: 1.2, repeat: -1});\n\n // Animates Tutorial navigation.\n // Mouse in and out need to be monitored.\n $('.tutorial nav img').hover(over, out);\n function over(){\n TweenMax.to(this, 0.25, {y:5});\n //TweenMax.to('.tutorial_slides img', 1, {rotationY:360, immediateRender: false});\n }\n function out(){\n TweenMax.to(this, 0.25, {y:0});\n //TweenMax.to('.tutorial_slides img', 0, {rotationY:0});\n }\n\n}", "function customtheme () {\ninjecttheme(\"CTH\", \".scrollableContainer-15eg7h { overflow-x: hidden; overflow-y: scroll; background-color: #2a3038; max-height: 50vh; border-radius: 8px } .wordmark-2u86JB > svg { display:none } .bg-1QIAus { background-color: transparent; background-position: var(--backgroundPosition); background-repeat: var(--backgroundRepeat); background-size: var(--backgroundSize); background-image: var(--backgroundImage); opacity: var(--backgroundOpacity); filter: blur(var(--backgroundBlur)) } .homeIcon-r0w4ny path { fill: transparent } .homeIcon-r0w4ny { background: url(https://images-ext-1.discordapp.net/external/JRob--kpQqtzAvUgdlNQbsPs1L2ObqCQlPn6Vml2sMc/%3Fsize%3D1024/https/cdn.discordapp.com/icons/936331893786431488/a_25ed60deaabe6b37751039e104866a1e.gif) center/cover no-repeat; min-width: 48px; min-height: 48px } * { --background-primary: 30,30,30; --background-secondary: 20,20,20; --background-secondary-alt: 15,15,15; --background-accent: 50,50,50; --background-floating: #050506; --scrollbar-thin-track: #2e2e2e; --channeltextarea-background: #A96762 } .ownerIcon-255uKo { color: blue; margin-left: 4px } .icon-Lupfh- { color: blue; background-color: #2e2e2e } .attachButtonPlus-3IYelE { color: dodgerblue } .app-2CXKsg button { color: #9e9e9e } .userPopout-2j1gM4, .bodyInnerWrapper-2bQs1k { background-color: #191C24 } .avatar-2Vndt_ { border: 6px solid #191C24; background-color: #191C24 } .footer-3naVBw { background-color: #191C24 } .body-1Ukv50 { background-color: #191C24 } .tabBarContainer-sCZC4w { background-color: #191C24 } .statusItem-2hiCNB { transition: transform 250ms } .statusItem-2hiCNB:hover { transform: translateX(10px) } .autocompleteRowContent-1cjfD2 { transition: transform 144ms } .autocompleteRowContent-1cjfD2:hover { transform: translateX(-10px) } .typeWindows-2-g3UY withFrame-2dL45i titleBar-1it3bQ horizontalReverse-2QssvL flex-3BkGQD directionRowReverse-HZatnx justifyStart-2Mwniq alignStretch-Uwowzr { border-bottom: #8c38ff }\")\n}", "function pano2vrSkin(player,base) {\n\tplayer.addVariable('opt_thumbnail_menu_tooltip', 2, true);\n\tplayer.addVariable('vis_thumbnail_menu', 2, true);\n\tplayer.addVariable('opt_hotspot_preview', 2, true);\n\tvar me=this;\n\tvar skin=this;\n\tvar flag=false;\n\tvar skinKeyPressed = 0;\n\tthis.player=player;\n\tthis.player.skinObj=this;\n\tthis.divSkin=player.divSkin;\n\tthis.ggUserdata=player.userdata;\n\tthis.lastSize={ w: -1,h: -1 };\n\tvar basePath=\"\";\n\t// auto detect base path\n\tif (base=='?') {\n\t\tvar scripts = document.getElementsByTagName('script');\n\t\tfor(var i=0;i<scripts.length;i++) {\n\t\t\tvar src=scripts[i].src;\n\t\t\tif (src.indexOf('skin.js')>=0) {\n\t\t\t\tvar p=src.lastIndexOf('/');\n\t\t\t\tif (p>=0) {\n\t\t\t\t\tbasePath=src.substr(0,p+1);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t} else\n\tif (base) {\n\t\tbasePath=base;\n\t}\n\tthis.elementMouseDown=[];\n\tthis.elementMouseOver=[];\n\tvar cssPrefix='';\n\tvar domTransition='transition';\n\tvar domTransform='transform';\n\tvar prefixes='Webkit,Moz,O,ms,Ms'.split(',');\n\tvar i;\n\tvar hs,el,els,elo,ela,elHorScrollFg,elHorScrollBg,elVertScrollFg,elVertScrollBg,elCornerBg;\n\tif (typeof document.body.style['transform'] == 'undefined') {\n\t\tfor(var i=0;i<prefixes.length;i++) {\n\t\t\tif (typeof document.body.style[prefixes[i] + 'Transform'] !== 'undefined') {\n\t\t\t\tcssPrefix='-' + prefixes[i].toLowerCase() + '-';\n\t\t\t\tdomTransition=prefixes[i] + 'Transition';\n\t\t\t\tdomTransform=prefixes[i] + 'Transform';\n\t\t\t}\n\t\t}\n\t}\n\t\n\tplayer.setMargins(0,0,0,0);\n\t\n\tthis.updateSize=function(startElement) {\n\t\tvar stack=[];\n\t\tstack.push(startElement);\n\t\twhile(stack.length>0) {\n\t\t\tvar e=stack.pop();\n\t\t\tif (e.ggUpdatePosition) {\n\t\t\t\te.ggUpdatePosition();\n\t\t\t}\n\t\t\tif (e.hasChildNodes()) {\n\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\t\n\tthis.callNodeChange=function(startElement) {\n\t\tvar stack=[];\n\t\tstack.push(startElement);\n\t\twhile(stack.length>0) {\n\t\t\tvar e=stack.pop();\n\t\t\tif (e.ggNodeChange) {\n\t\t\t\te.ggNodeChange();\n\t\t\t}\n\t\t\tif (e.hasChildNodes()) {\n\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tplayer.addListener('changenode', function() { me.ggUserdata=player.userdata; me.callNodeChange(me.divSkin); });\n\t\n\tvar parameterToTransform=function(p) {\n\t\tvar hs='translate(' + p.rx + 'px,' + p.ry + 'px) rotate(' + p.a + 'deg) scale(' + p.sx + ',' + p.sy + ')';\n\t\treturn hs;\n\t}\n\t\n\tthis.findElements=function(id,regex) {\n\t\tvar r=[];\n\t\tvar stack=[];\n\t\tvar pat=new RegExp(id,'');\n\t\tstack.push(me.divSkin);\n\t\twhile(stack.length>0) {\n\t\t\tvar e=stack.pop();\n\t\t\tif (regex) {\n\t\t\t\tif (pat.test(e.ggId)) r.push(e);\n\t\t\t} else {\n\t\t\t\tif (e.ggId==id) r.push(e);\n\t\t\t}\n\t\t\tif (e.hasChildNodes()) {\n\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn r;\n\t}\n\t\n\tthis.addSkin=function() {\n\t\tvar hs='';\n\t\tthis.ggCurrentTime=new Date().getTime();\n\t\tel=me._image_1=document.createElement('div');\n\t\tels=me._image_1__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_1';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAYAAACtWK6eAAAgAElEQVR4nO2deXxcV3n3v2furNpmtG+WbMtybMmJY8d2AtlwAgkNBEhT8hICZitQaNmXFngJLdCXwlsovBRoKdAWSICGhJDFQMiCszu2FW+xJMvWYu37NiPNduee94+RNFpmpJFGy2h8vp/P/Yx0l3PPzD2/e85zznOeAwqFQqFQKBQKhUKhUCgUCoVCoVAoFAqFQqFQKBQKhUKhUCgUCoVCoVAoFAqFQqFQKBQKhUKhUCgUCoVCoVAoFAqFQqFQKBQKhUKhUCgUCoVCoVAoFAqFQqFQKBQKhUKhUCgUCoVCoVAoFAqFQqFQKBQKhUKhUCgUyYtY6wwoVpdje64tl8K0H8SlIMqFNFxSiIDJYFgK0SAkx+x+nttx5pBnrfOaDCiBXATcd8cdWkVTzz'+\n\t\t\t'uBD4O4Ko5LvELykGGS/3ffsWeOr3T+khklkBSn5or9t0oh/wm4dAmXGyB+qYX44u4Th1qWOWvrAiWQFOVP+/ebs0aNb0shPrIMyXlAHNhbc+i3y5DWumLVBSKlLAIMIUTvat/7YuGFV786xxqwPgDsX8ZkDZBf2FvzzDeWMc2kZy0E8gng28AQUAucmfisAU4KIdyrnadU4tiePRYh0x+XQrxmJdKXQnx037FD31uJtJMR8xreOxu4ZmKbQkrZxUzRnAFqhRDeVc/hOkSKjB8CcYlDaFoQi3lABnVBKJQHaAteI+W3j+7bX7/v6KEnEs3remAta5DFoAOtzBINUCeEMJY3h+sHKWU2UDG5df/XPTd3fP/HN853jZaZESx859ssrhuuw1GxKZJWMDgy8uyLvf0PPmodPXy0XEo5X9noB0vl3ponRpbjeyQza1mDLAYz'+\n\t\t\t'kYJw67T9ASnleWaK5owQomn1s7gyTBPBDqCayO+wFciaOi8QpP/Bg/OmlX/HbZT89V++ZM7MvHb2MWGxOF03Xu903Xg93qYWmr/4VbwNjbGSyhN20xeBzy7pS60j1otAYmElXGiqp++UUg4TFsyUaAjbN32rnsMFkFJagDKm1QTTtiogLZ50+h54CH9nV8zjZZ/5KAV3/gVAaKG0HBWb2P6T79P42bsZPXw06jkC8ZlAd8+7LIUFp4AmIr/zK0KI7njyvB5Y7wKJhYuF7ZvJz5eFEOMrmRkppQ0oJVLwp9cGG4mj7b/ADej9n9/EPFx41x2T4ogbk8NOxdf/gfr3fBhfS+uc44bPR/8jfygofv+7Xjc3O3KImaKZ/GxZb03iVBVILIontukPVZdSTto30zsH6oUQC75tJ5ltD8zaNrOC9t5Y3Vn87Z1Rj1mLCyn5yA'+\n\t\t\t'eWlK6WkU755z5Jw4c+GfX40ON/ovj974p2KBvYM7FNxy+lbGSmaJpI4k6Yi00g0Yhl33illLXAacIP8hTQTFhglcCWiW3yb9cq5nkG7mOxvUGK3n0XJqt1yWln7t1N5hWX43755Jxj3qYWgoNDWHKy403ORpQmMZGX1OxaZ827/ZNKIEPeIA+c7uCyIifVhZlk2tY0ew7mvgWfJs4u1NXEe/Z89AMmE64brqPPPU5j7zBNfUO0d3WXbC1wsmNjKRXFhZg104Lpu163P6pAkBLvuUYsV+1N8BvMeEnNaLJNCOcsUAf8VAjxcqI3W2zGkob+MT8feCDyNizOtLOjKIvqgkx2FGZRXZjJFaUu0iyJNdlTjVjGeW9aBqVf/jkjXv/Uvj05ouBkbS0AFrPGluJCqjeWsr2shKryUqrKS9hWVoJJRFqEGTt3xLx3oCN2x8Ay'+\n\t\t\t'UT6x3US4Br94BTKbLrePLrePJ87N9EopzrSzZ4MrLJqCTHYUZbGjMBO7OXWFEwwZtA+O0tw/QlPfMM19wzT3D9PcN8Jnz7exMco1HZhniGNOmnqI+rZO6ttm2i9Ws5mK4gJ2V26iuryU6uxM8mOkEfKMLf1LrQOSWiCx6HL7eLSum0frIr2JFs1EmdNBdWEme0pdUzVOVUHmjLdhMuP2j3O8q4FTPecZdIfwjxTR3D9MbWc/57qH0I3oHUDBGPb/Ur91QNdnCCcvpBOrj8zt9VK4xPusB9alQKIRDBk0DY7RNDg2QzhWzURlXvpUbbNnQzY7CjPZnJ3OWuimfbSfY+1nqe1ronmkja7xTob1XgIMYbJ5AAlAX2sl7fU740qz32KjMkofUEHAtyx5LjBid+bdfd9BnjlUQ1VZCVUTTbXdlZvYubmMDId9We6/lqSMQG'+\n\t\t\t'IRCBnU9rip7ZnZGeK0W6jMTae6MNw8qy7MYt8GF0WZiT/UpqFOXu5o4ExfIy3uVnrGuxgJ9aKbhhDmWU0eLbzNNpVlaGHjeZJ+c/Q8Fwe8FAS99Foci/sCs9jtjy20DrOZYc8YL9ad48W6czOOFeW4qCovoaosbNtsLy9l15aNpNmW3qu22qS8QGIx4gtS0zFMTcfwjP3ZDktENAXhz10lLvLSZz7UoXEfzX3h5k9d50DYHvCeIFT0OCZNn3mzCREspsIS5mDc57bbow+2CySvHerilwUVi7jz7DTgBl9sO6PFHLuwdw8O0z04zJ9O1E7t00wmygtyw50CG0vDNU95KdUbN2CzJF9xTL4crTFD3iDPtwzwfMvAjP2bstPYlye21V1opaV/hIA+t9lhtmpU5WtzBbIE0rLi9wNscGTFPPbOniYezitjzGRZUj6u941z'+\n\t\t\t'STC6oT9k0hgwLa5jJGQYNHf30dzdx++PRrqOrWYz28qK+c3ff5KS3LjHVVac+Ovxi5yWoXEu9I84GroHo4oDQA9YaXz5WgLeuNyn5iU9a4h018DCJwJnHVnIGPVTth7gU221UY8tRK4R4mOj/TGP11ptS0o3GgFd53RzG+P+wLKluRwogSwz46NO6p6/iY6zO/GNZS49ISHZfPlLpDuHFjx1yGKjyZER8/gtgx38VVcDYqIDIB6yQyH+abCH/FBsA/24NTHbZj2gmlgrgGFo9F6opPdCJWnOIQo2niO7qH3R6VhsPrZeeYj+tgq6GqsIBWO3949l5LHFG9sr493d59no8/Bk+o4FX4pX+L18bqSfotD8TcUjNiUQRYKMj2TTcupKPMO5lG2P4q6xAEJI8ssbcRV2hNMZyot63gvOfN7W1zxvWvuHu7nmhb6MRxzpPG'+\n\t\t\t'tLp85qZVyYEEBeKMQVAS83ez3s8y/sN9itmblgXppds55QAlkl+lu3kFPcRrpzcEnXW2w+tux5nsaaa6KKpCYzl0GzjRw99sg5gMUIidvHRrl9bBQArxBYJJgX0fwCeNKRvsgr1ifKBllFQoHE+v9NphCbLjuKyTR3RN1A8EROyaLTdEi5aHEA/HEemyeVUAJZJZz5XWTl9yScjsXujVkL/SG7NOH04+GcxUrzPOMfqYQSyCqQld/F5stfguVqlJii9yzVp2VxPCNnee4xD/+T7lzxeyQLygZZcSTlO2oQ05pFUprwup2MjzrRAzaESWK2BMjM6cPqmN87VkqB1xO7gN5buIXdnqXZOfHQZzLzJ3v6iqWfbCiBrDgC/3gGZssQ46PZDHaVMdxdhh7VHpFsqDpJflnsoCzDvSXo/tj+Yi9m5XHOkcnWebp8E+G+jCyC'+\n\t\t\t'68Q7ejlQAlkFzh3ZH+eZgr4LW2MKxDBM9DRWzZuCRPBfRVv5WvPyzysaMGk84khg8HMdomyQJCN6zRKmo34nXk9sv6tJDrmKVsQW+Y/MHMZNF1eRubi+7TogpFsIeGe18aWg6/wO+tvj98r9zoZqjGVsCp2zWHnMcfHYHpNcdE2sXcOd3NDXyL7BNvICY+QExhmyOuizpVPjKuNPBVs47iqJ6fy3GrSc2kdZ9QnsGSN43U66GqsY7Sue95pyJwyOgycIuQ64ZlcWdaZydtReSDg/BvDSvnIOlESaVyfbfJxo9WEzC966LwuzKfJ7PVk7RvtQkIIsM7dcFhkvMQzJb152M+Y3qC6xsW9zxFVlzBfi/prki1t+0QjkspFuPn7+WXYNz40flR3wkh3wcom7n7e3Hee0s4jvbL2ek875C+VKMTaSQ/2L84bYBUAIuL1K8p'+\n\t\t\t'lrYUc+fPmQ4FvPw84i+PsbJeLabfR+oQ+9J7G4eP+T4eJ9d5VTkBUpLvccHuFEq48ip4W7b83Hag4LREoYC0juPzrCno0OvvSm/KmZm7ohefmCnzOdPm7dmcmHboi4tQ+PGxw8lXzz25MqePW5fg+X/PPjy37P2ztO83dnD6HJ+IP6SQQ/qriKH22+cqo2uTJbHznR2Jw0gwDfe6PkwOXw23rBz07A082gzxpq2ese4P+dP7IoT97ptGkW3pdfin+Veq5O/vDrVJbEnOX+SSHEd1YlIxMkVQ2iGW5eeGsrfl1w5x9L6BnX+PyeAd60OfJm6RzTeOvvwyPGP31dN1tdkfkDT7ancffhPLKsIR64pZN0i0R76AxafcOi8yKQfLDpMHnSx9cqXsMX9gxyZ6U7Y8wfLmidbnj7r8OF5ie3QWVOpAA+dl7wtWeW9BMsimcu'+\n\t\t\t'CH5xCl5oi33OscxcflGwmXf0Lj6edwDBV7ILVk0cyUhSCUQKC0+1pxEwwBMMP5RT/TbSLZHC1zMeyfJzXXbaPJH/j/eGxwe8usahjjS21Dex8w/RxRG0WxkuzSeQbqO7N8TW/h6y9Llzr29vPsErjjxO9m/kkiyH3jUU0AC63ZE8vdgG7aPh/GpCcn5inK4qH35zJ/zwGHz/JQguU1TaMmdYoPe9Et/5/1a6jUu8o+xzx578FI1vO3M5a7k4XEpikVQCMYSdLx6e6al68EIGBy9Ed4z70Zno0T6DBvzr4XQeer5mzrEhq4N/3XItvyveji4mOvHyQZMGr+9p4OPnniU3MLPN/umzz3JbbgV9ozm+E40jE9PoIm/VH8+4TWR/0yDcXwtfuF7yugo48IBgKMFAIxtdcOxDkrt+LXg85uoEMzEQ/MOmXfz32efIjzPSyR'+\n\t\t\t'8dGRxMu7jGPKKRst2872k5RuYs1+9Ou5N3772Th0uqI+KYICRM/K5oOweufDutaTPnRKeH/Ly3JfoyAPPhD8HdT8Ibfi7Ylgf/csviv8ds3rZD4gnA0y2Lu27IbOWLm3ajxzGO0Wix8k1n7tIymGKkpEBMUvLGrroZ+0LCxGd23krnPAEOAHptGXx6560EZwUjuKWnfsmG7rFOuOlngu+/tKTLZ3BDBTzRCIG4485HOJ2ezcGKS+atQtwmE3e7CvCJlCwaiyYlf4VLR7vnNJN+X7Sdhszos/Fm05yew8PFMwOQZwe8bOnvXnJs05ahsFDMCdq7hRlwfmDpiTyxcYv/gbToL4mgEHzJVUj7RTBTMF5SUiAVY3O9WZ8o2LqoNKKdXzI6kHDw30cPSD7+qqW7vf/1o/CTBN2s/jUrh6dneeQaQvCPrnxqbOs/GuJykpIC'+\n\t\t\t'yfd75uxrylhcrKXm9Lm+TFk+b8L9necH4LbZq2MsgsNtgv4E18OaFMMpa0QMP8jMuajc2OMlqXqxlguTTHxiUjQ/JpMMJSyQ0z3w5u1Lv/6De+GpJqa6kpeKXwg+l13Ivwx286LNwX3pWWSna7zjKieaBocbvbzU5MVhMfGea11Yp5WUh094aO4L4HRoXF2ZxpHmcQY8SzCK1gEpKZA+29w3Yfn4MJ32+AfBy8eH5+wbdqQZiU4K7BsTuOwSq7Y0Q/sL14fH9c8PJj545zGZ+HhuMd6Jl8GmHAvvuS4bE5BhM/FSk5e8TI33Xuua4WvVNhCkuS/ADdvT+M/3lRIyJC+c9/K1g3281JSUK6ktmZQUSLSeqht6GzmcE20Vjejc2Hduzr6BNKfBWGKjfYfb4VvPL00ck4hlHNn2TkvreJuPvV+eObjSNhjkyq9GH4X/7X'+\n\t\t\t'E3h/7uHK+tSuf912fz4EfK2fTZBgKh1Il3kpICaciYu9zLm7pqubf8ClrTFl5KsNjn5vaOM3P2t2UXhBhLbIXjTnfYqTBVGB4P8UDNKA/UjJKXYU4pcUCKGumD1rQ5g31WI8Q3Tz1CdmD+JkCW7uObpx7BHpoZXb01zcWozZHw07dqcOWGpSfjDQrGgslZCPs94UiM33l7EZ9+fXxd6slOStYgAC/llFE+PjOubcXYIPfU/Jwf7KrmxdLIAxQSgrqDKzpG+cQrNWzwzo2sfjS7bFny9boK+MUdUPCNpTWzrv0xDPuTuwZq6PbzpbcU8JuXR2nuS65g1Isl5QQihCQ9rYuTl0juiBIOt3Dcy5dfqGHAKTlfZjCaLskcE1S2m8gbjl3wniqoXJb8WTSJSYC2xDI+sA5s4B8/M8wH9+fw4f3Z/O2vE48FtpakhEA0UxCX'+\n\t\t\t'6xwuZyMuZzNms5cRCcNHbbjc0Uti7oggdyS+cb8BaxpHc8rYy9p3ZX7/jXDPSXhx8bGwV41ASPLAsVHeujdLCWQtcTj6yct9hYL8k5i1mS5GhoAjO0LcfDjxr/jipRLNMg4kvh6GIWd+LpY3bpOc7hVJLRCAHz49ROM6b17BOhWIw9HP5o2PkZkxfyl5al+IG4+aMSfw4tfN8MKrh6k23wvddybc+D/ULHjnA2FP31Smd1TnF4fjXyUrWVmHvViSbZW/XlAcAO40yZFLEyuJR3aEGMmQ2O1D+J0/zdC0+NcOjJqnADxcn1AS64I0q+CuVzmXdcxmLVh3AhFCYrXGH/3i4DU6fsvS2jNBM/z+6sgiMjq9pqLKX5KoSD68T5K7xLVnGvoFrXMH+ZOO/dvS+d47ismwKYGsKlKaGByaP7rgdIYzJU9ctbRa5PGrdAazZo'+\n\t\t\t'rL0D0UV963ZJEIAX93Hbz3iqWJ9uafwe/mDvInHTdUpXO2O4Dbt0zzjNeIdScQgKaW19PbtxtDxtcL9cerdLryFvegenIlj706+hJkIX2E4spfIcTihSclHDwrOHB5eNAwFXGladx+RRYPnRhd66wkzLoUiGFYab5wMzXHP86ZugO0XLiJwcHtIKNX57oZfvFneqzDc5ACfv6GIPo8BTiku8kre3EJuYdvvQAbnOGm1mJ59i8lb9menCPpk+zd5MCQ8MNDCy9AmuysS4FMYhgWPGMl9PRdwbmmt9DduzvmuU2lBo9eF9/65Q9fr9NcsnCNY7HGt0zznLwMwd1PCgrSF98+L3NCcWZyt+ufqPVQ9b/PMTS2/rvq1mU3byz00Pzrkz/2Kp2ybsGuhthVw+nKEI9fFZ+QAoGl+xv94Ejk78sKoaF/fXf9ZthMfPr1eQx4'+\n\t\t\t'dL731CD6+jY9pkgpgeS4zs57XAq49xadDb3R3UoGnZKfvyH+pthI9+VLyeYMTAJ+d0Ay6oN7TwkONUNNZ0QsLnskkND0QmcS4Jw2bukPwfhEv4FVg/Rp08rHghG/L7sZ4UqLvCDcPoPQxKhlhs2EWYuEEB3xRhTrdGiREKIhiccfzkxFnoV3X5vNXVc5sVkEH783MW/nZCNlBJKR0UFaWt+C543bJf/x5wE+da8N+7SBXp8Vfnh7kLE4HXY1zUIwkPhCloaEa34k+MSrJe/bLfncdfDpxwQ/OgZ3Xgb/8eaZ+XmwDo51SL5+E3xoX2S/V4dN3xJ4dXj0HfCqssh1x7vgNf8pMAt48L0y026OzLf/6fPDfPJX3VQVW3nu85tnjFt84pfd/OyFYd52pZN/OzAzTvGN/9zCiVYfH9ifzRsuy+SXR0b47uODUx69qULKCC'+\n\t\t\t'Td0Rv3uR0Fkn//iwAf+bUVsw4hE/z4tgDtBYtoFyyjGdA6Ap/6g+Azj8GGLOiaGOZ55Cy8+d7IeSEEL7RCyIDWUfhdQ0QEnkBYHBAO7LBh2pyxzgl/NF3Cpx9irLOrdUrZZ7sDU59v/m4b5mmtz5qWsPvOoyfddI9EurV1A063h2OOff7+Xj5/f/y//XojZQQSDC1u5O1cucE9twQ5cNDCz24NUrd5cY1mQ9ex2N0EfcsXfdCQYbFMMhaAQy0zlViSCX1j0OuBXk90lZ4fjD0lt7ZXhE6enRv1wZDw/Pno0SDG/AZPR7nmYmBd92JNxz1aFrObNxZHq0N85QN+jlUtYTwDSU7x4UVflyhPvgcO7Fr12160pE4Noqfj87uw2xfX997vWvqYgqadJ81ZzfjI6qxPDjAWlGzISu5u3imEgZY2jtnuw2TzolmCCHMQTAZC'+\n\t\t\t'SGRIQ0qBEbRi+O2E/HZCMrlsmJQRCIQHEFcTKSXZhQfRLK/F3b9lznGz1YOr6CQ2RyuCsXDXkDCBcBDwljLYfQW6f3FNtHMDsLtYsgZLuyyIMBmYs4axuYYwZw1hTh+bsfx1PHR5OtnG6r1wFiJlBGKxjONwLNyLtdwYIZ1M5x9x5mbj95Zh6FbMtmEs1m5CIQ9IiTHnpehHMw9TUFaHlBvpabkJIxTfo/j9OcG3/kySbg3bKMmAMIVIL7uAvbATYUnMkTPZSBmB5GbXIcTajE5JJCF9ELNlECbGH0JxtBSkNIBmiit/Tl/rXxDwLryC7X2vQCAkpsY8koGMynrs+anZk5UyRrrVun4n5xi6l4Ly+xGmhVXl0+FXp8OttQ0L62lVsKSnbg9Xygikf/CyuL17kxMD0yJqwEtyofajkq/fJMlc40Wg3M1b0McSHzRNRl'+\n\t\t\t'JGIOPj+dSffTvB4Pz+WMmIpuXR0/x2QqH4S3rDAHzsoODALjj5N5KvvpYpV5AMy+q60uujzrhtqPVGSn0rt6eU2rPvpHrbPVgsyV/tmzQT3tFrGOy+bEnX//cJeLRB8NdXwiW5Eg2BDjzzfklpFhxqhh8cFTzdvIyZFgaaJYjJ5kOz+zGnebDm96DZElxbLklJKYEA+HzZdHRdzabyJ9Y6K/MihGC0/2bcgxUJpdM/Dl85BNO7fd92n+A1m+COSyWP3CX52z8K/n2RK8hZswcxO8YRNi+aNRAWhM2PyRIIR9q7SEg5gQDo+hInfK8imjkrYXHE4txAePtxjeC6TXBhkfOWtHQPzuqTK5K39UbKCSQ9rZuN5U+tdTYWJOAvXJX7PNsS/tzogtdWwMmWha8RF1ENsRApY6RPsnnTY1jMY2udjQXxecpX9X6VOfCdWyS7'+\n\t\t\t'ihd+KepjmQSH566wtVikITD8doLuLALD2fj7C/APFKC7s0h0nZXVIuVqkN6+nWwu70nqdrIQAs8KNa9i8WRTeBHRP98prT99coGTJYzUXYa9sAuLcxiTFh6fMXQz0tCQIQ1CGqGJTxkyIw0Thm6GkBkZ0jCCFoxg9F45YdbJ3nV0XRj2KSiQ3UhpZmPZE2hakvhizMKkOQmtQbfog3XwhevDi0UtFPpUGia8XaV4u5bXL8riHCJza/26EAekYBMLoK//Mk6+8kE6ul6Nz594U2G58Y3PdWxcDZ5pEXh8Uk5fTm01sef14NpxYt2IA1KwBpkkGEynveN62juux2L24nD0YrV6sFpHsVo92CyjWG0j2KyjaJp/1fJl0jSGOves2v2mc7Ib7rzH5A6EZPyLNS4jZudIMjohz0vKCmQ6Qd1B0B17fUK7bZBsVyPFRUewWO'+\n\t\t\t'YuIb2chPTNa9K8SgbGWzdhtnuxOIeS2kaczsX5pGbh8+fQ1ZND/2A1l1b9DKt1ZSICmswa3Y37VyTteCjJhN++V2Zd/X/MdA2v/sQkI2hl+MzlCJMEk47JrIOQCC0UdpPRguTdVbDq+ZqPlLRBlkowmE5b+/Urlr7PvYeQvnaehZW54LQvcl7yCiANgdQthHwOQt40dE8mQXcmweFsrNoae17OQtUgsxidpymWCCZzHgOde1ck7XjZlgd+Xci+UX3NRGLNGsaSPYg5bQyTzYfJrCM0HaEZIAw6Pe1cQvHCCa0SSiCzCATTMQwNk2n5whxqZjtdjW9ZtvSWyhu3wokudN3AsvDZy0/m1jrsBesrsJwSyBwEup62qDVI5sOkWehru42QnvjybYnyVDO4Pfhh9QUiTAb2/PUlDlA2SFRCoeUpzJrZRn/Hn+MfT46xmO8e'+\n\t\t\t'hlOdS1izYRmQhonxruVZSns1UTVIFALBDByO/oTSMFucdDW/Bd2/tjPtdhXBT26TfOM5wX2vrGlWGGuuxNddgjljFJM1iDCFME2LemKENLLtyfEymUQJJAqj7nKcWS1LulYIgR7cRlfzfjDWroLeWwJ/tU9yxw440i54qmnNsjKDkDeNkDf2rM90S3JN3VUCiUJv3y6KCl5e9KChZnHwpaq3cWf15HwUSacbtn833Gl0+INQnR8ZIHvkrOAd90NeGrzyEUnaNMvgK4fgm8+H53M8cpdk0jvEkHD7r+CpJsHHXgX/+NpIel4dLvu+oNcDn7paUu6Cv3kUfnl66ctOX+wogURB1x00tdzCtsr74xrxFUIgZTmdDX/GN/s0fl8fuaZvLNKj+rHfSUqnxYlrmGjFDXjh3Q8K0syR615qD19X0wHv/g0zBHKkLfzPfWegbV'+\n\t\t\t'owF29Q0Dfh6X/X/Ws+3JESKIHEYHikgt7+XRTkH5/3PM1sYXRgP6P94SUFGgagYSB64TzSHn2/lPDYOYjmqDQehIfqo1/X7YYH65QQVhLVizUPXT375g2IbTI76Lnwv6bEoUg9kkogFs1EehIt/erzZROMMb9dM9vpabyLoG9NHGOXhEUzkWm365opqR57UpNUTaxN2Wl4vvpmOkd91PaMcqbHTU3HMLU9o9T2uvEGV78LXw/Z54QQEpqJvvY3oyfB4N9sbGaNkuxMNuc5qch3sTnfxeY8F1UluVxSlIPZZHoloOuvaezsoa61k7rWDurbOqm90EFDexeGVNb8dJJKIJOUZNkpybLzuq0Rz07dkLQOj3Omxz1NPEOc7fNMrbG3EmimubMSQ8Ft+MeWvoBnomSn2cMFP9/J5rywCCryXWzOc7Ixz4lJzG+XWM1mqspL'+\n\t\t\t'qSovBSLruLnHvZzv7KGutYO6tk7qLoTF09y9+kHBk4WkFEg0zCZBRU46FTnpvKmqaGp/MGTQ0O+htsfNmYma5kzPKPW9noTfhiZTCKt1bNY+jZ6W6xJKNx7mE8HmfNeK3DMzzcHuyk3srtw0Y/+wZ4za1k7qWzvCtU5bB680t9M3sjLTAo+WKIsAAAN8SURBVJKJdSOQWFg0EzsKs9hRmMUd09aVcPt1Gvo9nOmOiKa2x03TYPwRT2y2IeaE3zBlLVuYzew0O1UluVSX5E01hTbnO6ksyCHLkTxu366MdK6u3srV1TM7IyaFc/x8C/UTNc7p5lY8vtWbobnSrHuBxCLTZmZPqYs9pTPftsPeII2DY5zpHg3bN71uTneN0OOZ+1DttrkR1ww9/re3RTOxISdrjj2wOd/J9uJc0qxr4lS7bMQSTtfgMPWtndS2dkyJp7'+\n\t\t\t'61E28gOYNozMdaCGRNZ+y7HJYp4bxrTyQ21ZA3OFXLnOkJi6cjWDPnemnMLNTTjeKqkjyqS/KmmkLluU60NQqQsJYU57goznFxw67qqX16yKCtbyDcKTBNPOc6ugkZa7OuSzysydOTUmYBW4EdQPXE516gaL7rVhtDSo52NvF8ey2vDJzjXM9zvs2OK+w3b7yNLQXZbMl3UZCVvtbZXCxPA69Z60xM4gsEOdveSd2FTs60tvPRt7yeAlfMhU8+KYT4zmrmL6leb1LKbGaKZg9wOZAsHmxJVbjiYARonNjOT3xeACqBqoltO7Be/NBXXSBJZYMIIYaA5ya2KaSUJYTFMimcyU/7aucxCRkCmmJszSJ6oN0Zoe+llDbCopn++1agfuPkEkgshBCdQCfwyOQ+KaUFuIS5otlOknkILAPTRVALnJn4+7wQIuG154QQ/ok0'+\n\t\t\t'zwC/ntwvpTQD5cwVzU5gccvzrlPWhUCiIYQIEv2hZhIWzuymWvJEAphLEGgjei1QL4RYk2jcQgh9Wj4emX4sSnN4UkCrG3R4hVm3AomFEMIN1ExsUySBfeMHOpgrgFrg7ERhXDfM0xx2AVuYW+tsA5LH0S5OUk4gsVjAvpkumkTsm/nsgRaxVutUryJCiGGiv6CshHsup4ummnBHQdIuLHnRCCQW0+ybKcN1Vtt7umgM5hGBECJJJrYmH0KIAJEm8RTTfuvpoqkgbOeseZjFpOrmTXaklKaLoRZIFiZq98mu6GrgMSHEw2ubK4VCoVAoFAqFQqFQKBQKhUKhUCgUCoVCoVAoFAqFQqFQKBQKhUKhUCgUCoVCoVAoFAqFQqFQKBQKhUKhUCgUCoVCoVAoFAqFQqFQKBQKhUKhUCgUCoVCoVAoFAqFQqFQKBQKhUKhUC'+\n\t\t\t'gUCoVCoVAoFAqFQqFQKBSK5OH/A8Hc5I864QiXAAAAAElFTkSuQmCC';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 1\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='bottom : 3px;';\n\t\ths+='height : 67px;';\n\t\ths+='left : 3px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 77px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_1.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_1.onclick=function (e) {\n\t\t\tme._map_1.ggVisible = !me._map_1.ggVisible;\n\t\t\tvar flag=me._map_1.ggVisible;\n\t\t\tif (me._map_1.ggMapNotLoaded) {\n\t\t\t\tme._map_1.ggInitMap(false);\n\t\t\t\tme._map_1.ggInitMapMarkers(true);\n\t\t\t}\n\t\t\telse {\n\t\t\t\tme._map_1.ggClearMap();\n\t\t\t}\n\t\t\tme._map_1.style[domTransition]='none';\n\t\t\tme._map_1.style.visibility=((flag)&&(Number(me._map_1.style.opacity)>0||!me._map_1.style.opacity))?'inherit':'hidden';\n\t\t}\n\t\tme._image_1.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.divSkin.appendChild(me._image_1);\n\t\tel=me._map_1=document.createElement('div');\n\t\tel.ggFilter = '';\n\t\tel.ggFilteredIds = [];\n\t\tel.ggMapNotLoaded = true;\n\t\tel.ggId=\"Map 1\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_map \";\n\t\tel.ggType='map';\n\t\ths ='';\n\t\ths+='background : #ffffff;';\n\t\ths+='border : 1px solid #000000;';\n\t\ths+='cursor : default;';\n\t\ths+='height : 306px;';\n\t\ths+='left : 15px;';\n\t\ths+='overflow : hidden;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 6px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 313px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._map_1.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._map_1.ggUpdateConditionTimer=function () {\n\t\t\tme._map_1.ggRadar.update();\n\t\t}\n\t\tme._map_1.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._map_1.ggNodeChange=function () {\n\t\t\tif (me._map_1.ggLastActivMarker) {\n\t\t\t\tif (me._map_1.ggLastActivMarker._div.ggDeactivate) me._map_1.ggLastActivMarker._div.ggDeactivate();\n\t\t\t}\n\t\t\tvar id=player.getCurrentNode();\n\t\t\tif (me.ggMarkerArray) {\n\t\t\tvar marker=me._map_1.ggMarkerArray[id];\n\t\t\tif (marker) {\n\t\t\t\tif (marker._div.ggActivate) marker._div.ggActivate();\n\t\t\t}\n\t\t\tme._map_1.ggLastActivMarker=marker;\n\t\t\t}\n\t\t\tif (player.getMapType(me._map_1.ggMapId) == 'file') {\n\t\t\t\tvar coords = player.getNodeMapCoords(id, me._map_1.ggMapId);\n\t\t\t\tif (coords.length < 2) {\n\t\t\t\t\tvar mapId = player.getMapContainingNode(id);\n\t\t\t\t\tif (mapId != '') {\n\t\t\t\t\t\t\tme._map_1.ggChangeMap(mapId);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tme._map_1.ggLastNodeId = id;\n\t\t}\n\t\tme.divSkin.appendChild(me._map_1);\n\t\tel=me._image_2=document.createElement('div');\n\t\tels=me._image_2__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_2';\n\t\ths=basePath + 'images/image_2.png';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 2\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='bottom : 21px;';\n\t\ths+='height : 49px;';\n\t\ths+='opacity : 0.9;';\n\t\ths+='position : absolute;';\n\t\ths+='right : 23px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 120px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_2.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_2.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.divSkin.appendChild(me._image_2);\n\t\tel=me._thumbnail0=document.createElement('div');\n\t\tel.ggPermeable=false;\n\t\tel.ggId=\"thumbnail\";\n\t\tel.ggDx=12;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='bottom : 91px;';\n\t\ths+='height : 24px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._thumbnail0.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._thumbnail0.onclick=function (e) {\n\t\t\tplayer.setVariableValue('vis_thumbnail_menu', !player.getVariableValue('vis_thumbnail_menu'));\n\t\t}\n\t\tme._thumbnail0.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme.divSkin.appendChild(me._thumbnail0);\n\t\tel=me._button_fullscreen=document.createElement('div');\n\t\tel.ggId=\"button_fullscreen\";\n\t\tel.ggDx=16;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='bottom : 90px;';\n\t\ths+='height : 24px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_fullscreen.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_fullscreen.onclick=function (e) {\n\t\t\tplayer.toggleFullscreen();\n\t\t}\n\t\tme._button_fullscreen.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._button_image_normalscreen=document.createElement('div');\n\t\tels=me._button_image_normalscreen__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPGc+CiAgIDxyZWN0IHg9Ii0yMDYuMiIgaGVpZ2h0PSIyMi4yIiB5PSIzOTciIGZpbGw9IiMwMDAwMDAiIHdpZHRoPSIzMi4xIi8+CiAgIDxwYXRoIGQ9Ik0tMTc1LDM0MC45Yy0zMSwwLTU2LjEsMjUuMS01Ni4xLDU2LjFjMCwzMSwyNS4xLDU2LjEsNTYuMSw1Ni4xYzMxLDAsNTYuMS0yNS4xLDU2LjEtNTYuMSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtDLTExOC45LDM2Ni0xNDQsMzQwLjktMTc1LDM0MC45eiBNLTE2OC42LDQyMC4zYzAsMi4zLTEuOSw0LjItNC4yLDQuMmgtMzQuNWMtMi4zLDAtNC4yLTEuOS00LjItNC4ydi0yNC41YzAtMi4zLDEuOS00LjIsNC4yLTQu'+\n\t\t\t'MiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtoMzQuNWMyLjMsMCw0LjIsMS45LDQuMiw0LjJMLTE2OC42LDQyMC4zTC0xNjguNiw0MjAuM3ogTS0xMzYuOCwzNzIuNmwtMTcuNSwxMi42Yy0wLjEsMC0wLjEsMC4xLTAuMiwwLjFsMC43LDAuOWwzLjMsNC43JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjIsMC4zLDAuMiwwLjUsMC4xLDAuOWMtMC4yLDAuNC0wLjUsMC41LTAuOCwwLjVsLTE2LjIsMC4xYy0wLjQsMC0wLjYtMC4xLTAuOC0wLjRjLTAuMi0wLjItMC4yLTAuNS0wLjEtMC44bDUuMi0xNS40JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjEtMC4zLDAuNC0wLjYsMC44LTAuNmMwLj'+\n\t\t\t'QsMCwwLjcsMC4xLDAuOSwwLjNsMy4zLDQuNmwwLjYsMC44YzAsMCwwLjEtMC4xLDAuMS0wLjFsMTcuNS0xMi42YzAuNy0wLjUsMS42LTAuMywyLjEsMC40bDEuNCwxLjkmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Qy0xMzUuOSwzNzEuMi0xMzYuMSwzNzIuMS0xMzYuOCwzNzIuNnoiIGZpbGw9IiMwMDAwMDAiLz4KICA8L2c+CiA8L2c+CiA8ZyBpZD0iTGF5ZXJfMiI+CiAgPGc+CiAgIDxwYXRoIGQ9Ik0tMTM2LjQsMzcwLjVsLTEuNC0xLjljLTAuNS0wLjctMS41LTAuOC0yLjEtMC40bC0xNy41LDEyLjZjLTAuMSwwLTAuMSwwLjEtMC4xLDAuMWwtMC42LTAuOGwtMy4zLTQuNiYjeGQ7JiN4YTsm'+\n\t\t\t'I3g5OyYjeDk7JiN4OTtjLTAuMi0wLjMtMC40LTAuNC0wLjktMC4zYy0wLjQsMC0wLjcsMC4zLTAuOCwwLjZsLTUuMiwxNS40Yy0wLjEsMC4zLTAuMSwwLjYsMC4xLDAuOGMwLjIsMC4zLDAuNCwwLjQsMC44LDAuNGwxNi4yLTAuMSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC40LDAsMC43LTAuMSwwLjgtMC41YzAuMi0wLjQsMC4yLTAuNi0wLjEtMC45bC0zLjMtNC43bC0wLjctMC45YzAuMSwwLDAuMS0wLjEsMC4yLTAuMWwxNy41LTEyLjYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Qy0xMzYuMSwzNzIuMS0xMzUuOSwzNzEuMi0xMzYuNCwzNzAuNXoiIGZpbGw9IiNGRkZGRkYiLz4KICAgPH'+\n\t\t\t'BhdGggZD0iTS0xNzIuOCwzOTEuNmgtMzQuNWMtMi4zLDAtNC4yLDEuOS00LjIsNC4ydjI0LjVjMCwyLjMsMS45LDQuMiw0LjIsNC4yaDM0LjVjMi4zLDAsNC4yLTEuOSw0LjItNC4ydi0yNC41JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0MtMTY4LjYsMzkzLjUtMTcwLjUsMzkxLjYtMTcyLjgsMzkxLjZ6IE0tMTc0LDQxOS4yaC0zMi4xVjM5N2gzMi4xVjQxOS4yeiIgZmlsbD0iI0ZGRkZGRiIvPgogIDwvZz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._button_image_normalscreen__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._button_image_normalscreen__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPGc+CiAgIDxyZWN0IHg9Ii0yMDkuNiIgaGVpZ2h0PSIyNC42IiB5PSIzOTciIGZpbGw9IiMwMDAwMDAiIHdpZHRoPSIzNS43Ii8+CiAgIDxwYXRoIGQ9Ik0tMTc1LDMzNC42Yy0zNC40LDAtNjIuNCwyNy45LTYyLjQsNjIuNGMwLDM0LjQsMjcuOSw2Mi40LDYyLjQsNjIuNGMzNC40LDAsNjIuNC0yNy45LDYyLjQtNjIuNCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtDLTExMi42LDM2Mi42LTE0MC42LDMzNC42LTE3NSwzMzQuNnogTS0xNjcuOSw0MjIuOWMwLDIuNi0yLjEsNC43LTQuNyw0LjdoLTM4LjNjLTIuNiwwLTQuNy0yLjEtNC43LTQuN3YtMjcuMiYjeGQ7JiN4YTsm'+\n\t\t\t'I3g5OyYjeDk7JiN4OTtjMC0yLjYsMi4xLTQuNyw0LjctNC43aDM4LjNjMi42LDAsNC43LDIuMSw0LjcsNC43TC0xNjcuOSw0MjIuOUwtMTY3LjksNDIyLjl6IE0tMTMyLjUsMzY5LjlsLTE5LjUsMTRjLTAuMSwwLTAuMSwwLjEtMC4yLDAuMSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtsMC43LDFsMy43LDUuMmMwLjIsMC4zLDAuMiwwLjYsMC4xLDFjLTAuMiwwLjQtMC41LDAuNi0wLjksMC42bC0xOCwwLjFjLTAuNCwwLTAuNy0wLjEtMC45LTAuNGMtMC4yLTAuMy0wLjItMC41LTAuMS0wLjkmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7bDUuOC0xNy4xYzAuMS0wLjQsMC40LTAuNywwLjgtMC43Yz'+\n\t\t\t'AuNSwwLDAuNywwLjEsMSwwLjRsMy42LDUuMWwwLjcsMC45YzAuMSwwLDAuMS0wLjEsMC4yLTAuMWwxOS41LTE0YzAuOC0wLjUsMS44LTAuNCwyLjQsMC40JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2wxLjUsMi4xQy0xMzEuNiwzNjguMy0xMzEuOCwzNjkuNC0xMzIuNSwzNjkuOXoiIGZpbGw9IiMwMDAwMDAiLz4KICA8L2c+CiA8L2c+CiA8ZyBpZD0iTGF5ZXJfMiI+CiAgPGc+CiAgIDxwYXRoIGQ9Ik0tMTMyLjEsMzY3LjVsLTEuNS0yLjFjLTAuNS0wLjgtMS42LTAuOS0yLjQtMC40bC0xOS41LDE0Yy0wLjEsMC0wLjEsMC4xLTAuMiwwLjFsLTAuNy0wLjlsLTMuNi01LjEmI3hkOyYjeGE7JiN4'+\n\t\t\t'OTsmI3g5OyYjeDk7Yy0wLjItMC4zLTAuNS0wLjQtMS0wLjRjLTAuNSwwLTAuNywwLjMtMC44LDAuN2wtNS44LDE3LjFjLTAuMSwwLjQtMC4xLDAuNywwLjEsMC45YzAuMiwwLjMsMC41LDAuNCwwLjksMC40bDE4LTAuMSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC40LDAsMC44LTAuMiwwLjktMC42YzAuMi0wLjQsMC4yLTAuNy0wLjEtMWwtMy43LTUuMmwtMC43LTFjMC4xLDAsMC4xLTAuMSwwLjItMC4xbDE5LjUtMTQmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Qy0xMzEuOCwzNjkuNC0xMzEuNiwzNjguMy0xMzIuMSwzNjcuNXoiIGZpbGw9IiNGRkZGRkYiLz4KICAgPHBhdGggZD0iTS0xNz'+\n\t\t\t'IuNiwzOTFoLTM4LjNjLTIuNiwwLTQuNywyLjEtNC43LDQuN3YyNy4yYzAsMi42LDIuMSw0LjcsNC43LDQuN2gzOC4zYzIuNiwwLDQuNy0yLjEsNC43LTQuN3YtMjcuMiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtDLTE2Ny45LDM5My4xLTE3MCwzOTEtMTcyLjYsMzkxeiBNLTE3My45LDQyMS42aC0zNS43VjM5N2gzNS43VjQyMS42eiIgZmlsbD0iI0ZGRkZGRiIvPgogIDwvZz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._button_image_normalscreen__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"button_image_normalscreen\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 63px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 54px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_image_normalscreen.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_image_normalscreen.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getIsFullscreen() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._button_image_normalscreen.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._button_image_normalscreen.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._button_image_normalscreen.style[domTransition]='';\n\t\t\t\tif (me._button_image_normalscreen.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._button_image_normalscreen.style.visibility=(Number(me._button_image_normalscreen.style.opacity)>0||!me._button_image_normalscreen.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._button_image_normalscreen.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._button_image_normalscreen.style.visibility=\"hidden\";\n\t\t\t\t\tme._button_image_normalscreen.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._button_image_normalscreen.onmouseover=function (e) {\n\t\t\tme._button_image_normalscreen__img.style.visibility='hidden';\n\t\t\tme._button_image_normalscreen__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._button_image_normalscreen.onmouseout=function (e) {\n\t\t\tme._button_image_normalscreen__img.style.visibility='inherit';\n\t\t\tme._button_image_normalscreen__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._button_image_normalscreen.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._button_fullscreen.appendChild(me._button_image_normalscreen);\n\t\tel=me._button_image_fullscreen=document.createElement('div');\n\t\tels=me._button_image_fullscreen__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPGc+CiAgIDxwYXRoIGQ9Ik0tMjA2LjIsNDE5LjJoNjIuM3YtNDQuM2gtNjIuM1Y0MTkuMnogTS0xNzguOSwzOTcuM2MwLDAsMTcuNy0xMi43LDE3LjctMTIuN2wtNC01LjYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0wLjItMC4zLTAuMi0wLjUtMC4xLTAuOWMwLjItMC40LDAuNS0wLjUsMC44LTAuNWwxNi4yLTAuMWMwLjQsMCwwLjYsMC4xLDAuOCwwLjRjMC4yLDAuMiwwLjIsMC41LDAuMSwwLjhsLTUuMiwxNS40JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MtMC4xLDAuMy0wLjQsMC42LTAuOCwwLjZjLTAuNCwwLTAuNy0wLjEtMC45LTAuM2wtMy45LTUuNGMwLDAt'+\n\t\t\t'MTcuNywxMi43LTE3LjcsMTIuN2MtMC43LDAuNS0xLjYsMC4zLTIuMS0wLjRsLTEuNC0xLjkmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Qy0xNzkuNywzOTguOC0xNzkuNSwzOTcuOC0xNzguOSwzOTcuM3oiIGZpbGw9IiMwMDAwMDAiLz4KICAgPHBhdGggZD0iTS0xNzUsMzQwLjljLTMxLDAtNTYuMSwyNS4xLTU2LjEsNTYuMXMyNS4xLDU2LjEsNTYuMSw1Ni4xYzMxLDAsNTYuMS0yNS4xLDU2LjEtNTYuMSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtTLTE0NCwzNDAuOS0xNzUsMzQwLjl6IE0tMTM4LjQsNDIwLjNjMCwyLjMtMS45LDQuMi00LjIsNC4yaC02NC43Yy0yLjMsMC00LjItMS45LTQuMi'+\n\t\t\t'00LjJ2LTQ2LjdjMC0yLjMsMS45LTQuMiw0LjItNC4yaDY0LjcmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzIuMywwLDQuMiwxLjksNC4yLDQuMlY0MjAuM3oiIGZpbGw9IiMwMDAwMDAiLz4KICA8L2c+CiA8L2c+CiA8ZyBpZD0iTGF5ZXJfMiI+CiAgPHBhdGggZD0iTS0xNDcuNCwzNzcuOWMtMC4yLTAuMy0wLjQtMC40LTAuOC0wLjRsLTE2LjIsMC4xYy0wLjQsMC0wLjcsMC4xLTAuOCwwLjVjLTAuMiwwLjQtMC4yLDAuNiwwLjEsMC45bDQsNS42JiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuMSwwLTE3LjcsMTIuNy0xNy43LDEyLjdjLTAuNywwLjUtMC44LDEuNS0wLjQsMi4xbDEuNCwxLjljMC41'+\n\t\t\t'LDAuNywxLjUsMC44LDIuMSwwLjRjMCwwLDE3LjYtMTIuNywxNy43LTEyLjdsMy45LDUuNCYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuMiwwLjMsMC40LDAuNCwwLjksMC4zYzAuNCwwLDAuNy0wLjMsMC44LTAuNmw1LjItMTUuNEMtMTQ3LjIsMzc4LjQtMTQ3LjIsMzc4LjEtMTQ3LjQsMzc3Ljl6IiBmaWxsPSIjRkZGRkZGIi8+CiAgPHBhdGggZD0iTS0xNDIuNyw0MjQuNmgtNjQuN2MtMi4zLDAtNC4yLTEuOS00LjItNC4ydi00Ni43YzAtMi4zLDEuOS00LjIsNC4yLTQuMmg2NC43YzIuMywwLDQuMiwxLjksNC4yLDQuMnY0Ni43JiN4ZDsmI3hhOyYjeDk7JiN4OTtDLTEzOC40LDQyMi43LTE0MC4zLD'+\n\t\t\t'QyNC42LTE0Mi43LDQyNC42eiBNLTIwNi4yLDQxOS4yaDYyLjN2LTQ0LjNoLTYyLjNWNDE5LjJ6IiBmaWxsPSIjRkZGRkZGIi8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._button_image_fullscreen__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._button_image_fullscreen__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPGc+CiAgIDxwYXRoIGQ9Ik0tMjA5LjYsNDIxLjZoNjkuM3YtNDkuM2gtNjkuM1Y0MjEuNnogTS0xNzkuMywzOTcuNGMwLDAsMTkuNi0xNC4xLDE5LjctMTQuMWwtNC41LTYuMiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTAuMi0wLjMtMC4yLTAuNi0wLjEtMWMwLjItMC40LDAuNS0wLjYsMC45LTAuNmwxOC0wLjFjMC40LDAsMC43LDAuMSwwLjksMC40YzAuMiwwLjMsMC4yLDAuNSwwLjEsMC45bC01LjgsMTcuMSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTAuMSwwLjQtMC40LDAuNy0wLjgsMC43Yy0wLjUsMC0wLjctMC4xLTEtMC40bC00LjMtNmMtMC4xLDAuMS0x'+\n\t\t\t'OS43LDE0LjEtMTkuNywxNC4xYy0wLjgsMC41LTEuOCwwLjQtMi40LTAuNGwtMS41LTIuMSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtDLTE4MC4yLDM5OS0xODAsMzk3LjktMTc5LjMsMzk3LjR6IiBmaWxsPSIjMDAwMDAwIi8+CiAgIDxwYXRoIGQ9Ik0tMTc1LDMzNC42Yy0zNC40LDAtNjIuNCwyNy45LTYyLjQsNjIuNHMyNy45LDYyLjQsNjIuNCw2Mi40YzM0LjQsMCw2Mi40LTI3LjksNjIuNC02Mi40JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O1MtMTQwLjYsMzM0LjYtMTc1LDMzNC42eiBNLTEzNC40LDQyMi45YzAsMi42LTIuMSw0LjctNC43LDQuN2gtNzEuOGMtMi42LDAtNC43LTIuMS00Lj'+\n\t\t\t'ctNC43di01MS44YzAtMi42LDIuMS00LjcsNC43LTQuN2g3MS44JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MyLjYsMCw0LjcsMi4xLDQuNyw0LjdWNDIyLjl6IiBmaWxsPSIjMDAwMDAwIi8+CiAgPC9nPgogPC9nPgogPGcgaWQ9IkxheWVyXzIiPgogIDxwYXRoIGQ9Ik0tMTQ0LjMsMzc1LjhjLTAuMi0wLjMtMC41LTAuNC0wLjktMC40bC0xOCwwLjFjLTAuNCwwLTAuOCwwLjItMC45LDAuNmMtMC4yLDAuNC0wLjIsMC43LDAuMSwxbDQuNSw2LjImI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC4xLDAtMTkuNywxNC4xLTE5LjcsMTQuMWMtMC44LDAuNS0wLjksMS42LTAuNCwyLjRsMS41LDIuMWMwLjUs'+\n\t\t\t'MC44LDEuNiwwLjksMi40LDAuNGMwLDAsMTkuNi0xNC4xLDE5LjctMTQuMWw0LjMsNiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuMiwwLjMsMC41LDAuNCwxLDAuNGMwLjUsMCwwLjctMC4zLDAuOC0wLjdsNS44LTE3LjFDLTE0NC4xLDM3Ni4zLTE0NC4xLDM3Ni0xNDQuMywzNzUuOHoiIGZpbGw9IiNGRkZGRkYiLz4KICA8cGF0aCBkPSJNLTEzOS4xLDQyNy42aC03MS44Yy0yLjYsMC00LjctMi4xLTQuNy00Ljd2LTUxLjhjMC0yLjYsMi4xLTQuNyw0LjctNC43aDcxLjhjMi42LDAsNC43LDIuMSw0LjcsNC43djUxLjgmI3hkOyYjeGE7JiN4OTsmI3g5O0MtMTM0LjQsNDI1LjUtMTM2LjUsNDI3LjYtMT'+\n\t\t\t'M5LjEsNDI3LjZ6IE0tMjA5LjYsNDIxLjZoNjkuM3YtNDkuM2gtNjkuM1Y0MjEuNnoiIGZpbGw9IiNGRkZGRkYiLz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._button_image_fullscreen__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"button_image_fullscreen\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 63px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 54px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_image_fullscreen.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_image_fullscreen.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getIsFullscreen() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._button_image_fullscreen.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._button_image_fullscreen.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._button_image_fullscreen.style[domTransition]='';\n\t\t\t\tif (me._button_image_fullscreen.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._button_image_fullscreen.style.visibility=\"hidden\";\n\t\t\t\t\tme._button_image_fullscreen.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._button_image_fullscreen.style.visibility=(Number(me._button_image_fullscreen.style.opacity)>0||!me._button_image_fullscreen.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._button_image_fullscreen.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._button_image_fullscreen.onmouseover=function (e) {\n\t\t\tme._button_image_fullscreen__img.style.visibility='hidden';\n\t\t\tme._button_image_fullscreen__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._button_image_fullscreen.onmouseout=function (e) {\n\t\t\tme._button_image_fullscreen__img.style.visibility='inherit';\n\t\t\tme._button_image_fullscreen__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._button_image_fullscreen.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._button_fullscreen.appendChild(me._button_image_fullscreen);\n\t\tme.divSkin.appendChild(me._button_fullscreen);\n\t\tel=me._button_direction=document.createElement('div');\n\t\tel.ggId=\"button_direction\";\n\t\tel.ggDx=11;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='bottom : 15px;';\n\t\ths+='height : 62px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 82px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_direction.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_direction.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._button_image_right=document.createElement('div');\n\t\tels=me._button_image_right__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZD0iTS0xNzUsMzQwLjljLTMxLDAtNTYuMSwyNS4xLTU2LjEsNTYuMWMwLDMxLDI1LjEsNTYuMSw1Ni4xLDU2LjFzNTYuMS0yNS4xLDU2LjEtNTYuMSYjeGQ7JiN4YTsmI3g5OyYjeDk7Qy0xMTguOSwzNjYtMTQ0LDM0MC45LTE3NSwzNDAuOXogTS0xNDksMzk4LjFsLTMwLjEsMzAuMWMtMC42LDAuNi0xLjYsMC42LTIuMiwwbC0xMS4zLTExLjNjLTAuNi0wLjYtMC42LTEuNiwwLTIuMmwxNy43LTE3LjcmI3hkOyYjeGE7JiN4OTsmI3g5O2wtMTcuNy0xNy43Yy0wLjYtMC42LTAuNi0xLjYsMC0yLjJsMTEuMy0xMS4zYzAuNi0wLjYsMS42LTAuNiwyLjIsMGwzMC4x'+\n\t\t\t'LDMwYzAuMywwLjMsMC40LDAuNywwLjQsMS4xJiN4ZDsmI3hhOyYjeDk7JiN4OTtDLTE0OC41LDM5Ny40LTE0OC42LDM5Ny44LTE0OSwzOTguMXoiIGZpbGw9IiMwMDAwMDAiLz4KIDwvZz4KIDxnIGlkPSJMYXllcl8yIj4KICA8cGF0aCBkPSJNLTE5Mi41LDM3OS4zbDE3LjcsMTcuN2wtMTcuNywxNy43Yy0wLjYsMC42LTAuNiwxLjYsMCwyLjJsMTEuMywxMS4zYzAuNiwwLjYsMS42LDAuNiwyLjIsMGwzMC4xLTMwLjEmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjMtMC4zLDAuNS0wLjcsMC40LTEuMWMwLTAuNC0wLjEtMC44LTAuNC0xLjFsLTMwLjEtMzBjLTAuNi0wLjYtMS42LTAuNi0yLjIsMGwtMT'+\n\t\t\t'EuMywxMS4zQy0xOTMuMSwzNzcuNy0xOTMuMSwzNzguNy0xOTIuNSwzNzkuMyYjeGQ7JiN4YTsmI3g5OyYjeDk7eiIgZmlsbD0iI0ZGRkZGRiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._button_image_right__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._button_image_right__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZD0iTS0xNzUsMzM0LjZjLTM0LjQsMC02Mi40LDI3LjktNjIuNCw2Mi40YzAsMzQuNCwyNy45LDYyLjQsNjIuNCw2Mi40czYyLjQtMjcuOSw2Mi40LTYyLjQmI3hkOyYjeGE7JiN4OTsmI3g5O0MtMTEyLjYsMzYyLjYtMTQwLjYsMzM0LjYtMTc1LDMzNC42eiBNLTE0Ni4xLDM5OC4ybC0zMy41LDMzLjRjLTAuNywwLjctMS43LDAuNy0yLjQsMGwtMTIuNS0xMi41Yy0wLjctMC43LTAuNy0xLjcsMC0yLjQmI3hkOyYjeGE7JiN4OTsmI3g5O2wxOS43LTE5LjdsLTE5LjctMTkuN2MtMC43LTAuNy0wLjctMS43LDAtMi40bDEyLjUtMTIuNWMwLjctMC43LDEuNy0wLjcs'+\n\t\t\t'Mi40LDBsMzMuNSwzMy40YzAuMywwLjMsMC41LDAuOCwwLjUsMS4yJiN4ZDsmI3hhOyYjeDk7JiN4OTtDLTE0NS42LDM5Ny40LTE0NS43LDM5Ny45LTE0Ni4xLDM5OC4yeiIgZmlsbD0iIzAwMDAwMCIvPgogPC9nPgogPGcgaWQ9IkxheWVyXzIiPgogIDxwYXRoIGQ9Ik0tMTk0LjQsMzc3LjNsMTkuNywxOS43bC0xOS43LDE5LjdjLTAuNywwLjctMC43LDEuNywwLDIuNGwxMi41LDEyLjVjMC43LDAuNywxLjcsMC43LDIuNCwwbDMzLjUtMzMuNCYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuMy0wLjMsMC41LTAuOCwwLjUtMS4zYzAtMC40LTAuMi0wLjktMC41LTEuMmwtMzMuNS0zMy40Yy0wLjctMC43LT'+\n\t\t\t'EuNy0wLjctMi40LDBsLTEyLjUsMTIuNSYjeGQ7JiN4YTsmI3g5OyYjeDk7Qy0xOTUuMSwzNzUuNi0xOTUuMSwzNzYuNi0xOTQuNCwzNzcuM3oiIGZpbGw9IiNGRkZGRkYiLz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._button_image_right__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"button_image_right\";\n\t\tel.ggDx=26;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='bottom : 15px;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_image_right.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_image_right.onmouseover=function (e) {\n\t\t\tme._button_image_right__img.style.visibility='hidden';\n\t\t\tme._button_image_right__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._button_image_right.onmouseout=function (e) {\n\t\t\tme._button_image_right__img.style.visibility='inherit';\n\t\t\tme._button_image_right__imgo.style.visibility='hidden';\n\t\t\tme.elementMouseDown['button_image_right']=false;\n\t\t}\n\t\tme._button_image_right.onmousedown=function (e) {\n\t\t\tme.elementMouseDown['button_image_right']=true;\n\t\t}\n\t\tme._button_image_right.onmouseup=function (e) {\n\t\t\tme.elementMouseDown['button_image_right']=false;\n\t\t}\n\t\tme._button_image_right.ontouchend=function (e) {\n\t\t\tme.elementMouseDown['button_image_right']=false;\n\t\t}\n\t\tme._button_image_right.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._button_direction.appendChild(me._button_image_right);\n\t\tel=me._button_image_left=document.createElement('div');\n\t\tels=me._button_image_left__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZD0iTS0xNzUsMzQwLjhjLTMxLDAtNTYuMiwyNS4xLTU2LjIsNTYuMnMyNS4xLDU2LjIsNTYuMiw1Ni4yczU2LjItMjUuMSw1Ni4yLTU2LjImI3hkOyYjeGE7JiN4OTsmI3g5O0MtMTE4LjgsMzY2LTE0NCwzNDAuOC0xNzUsMzQwLjh6IE0tMTU3LjUsNDE2LjlsLTExLjMsMTEuM2MtMC42LDAuNi0xLjUsMC42LTIuMiwwbC0zMC4yLTMwLjFjLTAuMy0wLjMtMC40LTAuNy0wLjQtMS4xJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC0wLjUsMC4xLTAuOCwwLjQtMS4ybDMwLjItMzAuMWMwLjYtMC42LDEuNS0wLjYsMi4yLDBsMTEuMywxMS4zYzAuNiwwLjYsMC42LDEuNSww'+\n\t\t\t'LDIuMmwtMTcuNywxNy43bDE3LjcsMTcuNyYjeGQ7JiN4YTsmI3g5OyYjeDk7Qy0xNTYuOSw0MTUuNC0xNTYuOSw0MTYuMy0xNTcuNSw0MTYuOXoiIGZpbGw9IiMwMDAwMDAiLz4KIDwvZz4KIDxnIGlkPSJMYXllcl8yIj4KICA8cGF0aCBkPSJNLTE1Ny41LDQxNC43bC0xNy43LTE3LjdsMTcuNy0xNy43YzAuNi0wLjYsMC42LTEuNSwwLTIuMmwtMTEuMy0xMS4zYy0wLjYtMC42LTEuNS0wLjYtMi4yLDBsLTMwLjIsMzAuMSYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjMsMC4zLTAuNCwwLjctMC40LDEuMmMwLDAuNCwwLjIsMC44LDAuNCwxLjFsMzAuMiwzMC4xYzAuNiwwLjYsMS41LDAuNiwyLjIsMG'+\n\t\t\t'wxMS4zLTExLjNDLTE1Ni45LDQxNi4zLTE1Ni45LDQxNS40LTE1Ny41LDQxNC43JiN4ZDsmI3hhOyYjeDk7JiN4OTt6IiBmaWxsPSIjRkZGRkZGIi8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._button_image_left__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._button_image_left__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZD0iTS0xNzUsMzM0LjZjLTM0LjQsMC02Mi40LDI3LjktNjIuNCw2Mi40czI3LjksNjIuNCw2Mi40LDYyLjRzNjIuNC0yNy45LDYyLjQtNjIuNCYjeGQ7JiN4YTsmI3g5OyYjeDk7Qy0xMTIuNiwzNjIuNi0xNDAuNiwzMzQuNi0xNzUsMzM0LjZ6IE0tMTU1LjYsNDE5LjFsLTEyLjUsMTIuNWMtMC43LDAuNy0xLjcsMC43LTIuNCwwbC0zMy41LTMzLjRjLTAuMy0wLjMtMC41LTAuOC0wLjUtMS4yJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC0wLjUsMC4xLTAuOSwwLjUtMS4zbDMzLjUtMzMuNGMwLjctMC43LDEuNy0wLjcsMi40LDBsMTIuNSwxMi41YzAuNywwLjcsMC43'+\n\t\t\t'LDEuNywwLDIuNGwtMTkuNywxOS43bDE5LjcsMTkuNyYjeGQ7JiN4YTsmI3g5OyYjeDk7Qy0xNTQuOSw0MTcuNC0xNTQuOSw0MTguNC0xNTUuNiw0MTkuMXoiIGZpbGw9IiMwMDAwMDAiLz4KIDwvZz4KIDxnIGlkPSJMYXllcl8yIj4KICA8cGF0aCBkPSJNLTE1NS42LDQxNi43bC0xOS43LTE5LjdsMTkuNy0xOS43YzAuNy0wLjcsMC43LTEuNywwLTIuNGwtMTIuNS0xMi41Yy0wLjctMC43LTEuNy0wLjctMi40LDBsLTMzLjUsMzMuNCYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjMsMC4zLTAuNSwwLjgtMC41LDEuM2MwLDAuNCwwLjIsMC45LDAuNSwxLjJsMzMuNSwzMy40YzAuNywwLjcsMS43LDAuNy'+\n\t\t\t'wyLjQsMGwxMi41LTEyLjVDLTE1NC45LDQxOC40LTE1NC45LDQxNy40LTE1NS42LDQxNi43JiN4ZDsmI3hhOyYjeDk7JiN4OTt6IiBmaWxsPSIjRkZGRkZGIi8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._button_image_left__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"button_image_left\";\n\t\tel.ggDx=-26;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='bottom : 15px;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_image_left.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_image_left.onmouseover=function (e) {\n\t\t\tme._button_image_left__img.style.visibility='hidden';\n\t\t\tme._button_image_left__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._button_image_left.onmouseout=function (e) {\n\t\t\tme._button_image_left__img.style.visibility='inherit';\n\t\t\tme._button_image_left__imgo.style.visibility='hidden';\n\t\t\tme.elementMouseDown['button_image_left']=false;\n\t\t}\n\t\tme._button_image_left.onmousedown=function (e) {\n\t\t\tme.elementMouseDown['button_image_left']=true;\n\t\t}\n\t\tme._button_image_left.onmouseup=function (e) {\n\t\t\tme.elementMouseDown['button_image_left']=false;\n\t\t}\n\t\tme._button_image_left.ontouchend=function (e) {\n\t\t\tme.elementMouseDown['button_image_left']=false;\n\t\t}\n\t\tme._button_image_left.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._button_direction.appendChild(me._button_image_left);\n\t\tel=me._button_image_down=document.createElement('div');\n\t\tels=me._button_image_down__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZD0iTS0xNzUsMzQwLjljLTMxLDAtNTYuMSwyNS4xLTU2LjEsNTYuMXMyNS4xLDU2LjEsNTYuMSw1Ni4xYzMxLDAsNTYuMS0yNS4xLDU2LjEtNTYuMVMtMTQ0LDM0MC45LTE3NSwzNDAuOSYjeGQ7JiN4YTsmI3g5OyYjeDk7eiBNLTE0My44LDM5Mi45bC0zMCwzMC4xYy0wLjMsMC4zLTAuNywwLjQtMS4xLDAuNGMtMC40LDAtMC44LTAuMS0xLjEtMC40bC0zMC4xLTMwLjFjLTAuNi0wLjYtMC42LTEuNiwwLTIuMmwxMS4zLTExLjMmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjYtMC42LDEuNi0wLjYsMi4yLDBsMTcuNywxNy43bDE3LjctMTcuN2MwLjYtMC42LDEuNi0w'+\n\t\t\t'LjYsMi4yLDBsMTEuMywxMS4zQy0xNDMuMiwzOTEuNC0xNDMuMiwzOTIuMy0xNDMuOCwzOTIuOXoiIGZpbGw9IiMwMDAwMDAiLz4KIDwvZz4KIDxnIGlkPSJMYXllcl8yIj4KICA8cGF0aCBkPSJNLTE1Ny4zLDM3OS41bC0xNy43LDE3LjdsLTE3LjctMTcuN2MtMC42LTAuNi0xLjYtMC42LTIuMiwwbC0xMS4zLDExLjNjLTAuNiwwLjYtMC42LDEuNiwwLDIuMmwzMC4xLDMwLjEmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjMsMC4zLDAuNywwLjUsMS4xLDAuNGMwLjQsMCwwLjgtMC4xLDEuMS0wLjRsMzAtMzAuMWMwLjYtMC42LDAuNi0xLjYsMC0yLjJsLTExLjMtMTEuM0MtMTU1LjcsMzc4LjktMTU2Lj'+\n\t\t\t'csMzc4LjktMTU3LjMsMzc5LjV6IiBmaWxsPSIjRkZGRkZGIi8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._button_image_down__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._button_image_down__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZD0iTS0xNzUsMzM0LjZjLTM0LjQsMC02Mi40LDI3LjktNjIuNCw2Mi40czI3LjksNjIuNCw2Mi40LDYyLjRjMzQuNCwwLDYyLjQtMjcuOSw2Mi40LTYyLjQmI3hkOyYjeGE7JiN4OTsmI3g5O1MtMTQwLjYsMzM0LjYtMTc1LDMzNC42eiBNLTE0MC40LDM5Mi41bC0zMy40LDMzLjVjLTAuMywwLjMtMC44LDAuNS0xLjIsMC41Yy0wLjUsMC0wLjktMC4xLTEuMy0wLjVsLTMzLjQtMzMuNSYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjctMC43LTAuNy0xLjcsMC0yLjRsMTIuNS0xMi41YzAuNy0wLjcsMS43LTAuNywyLjQsMGwxOS43LDE5LjdsMTkuNy0xOS43YzAuNy0w'+\n\t\t\t'LjcsMS43LTAuNywyLjQsMGwxMi41LDEyLjUmI3hkOyYjeGE7JiN4OTsmI3g5O0MtMTM5LjcsMzkwLjctMTM5LjcsMzkxLjgtMTQwLjQsMzkyLjV6IiBmaWxsPSIjMDAwMDAwIi8+CiA8L2c+CiA8ZyBpZD0iTGF5ZXJfMiI+CiAgPHBhdGggZD0iTS0xNTUuMywzNzcuNmwtMTkuNywxOS43bC0xOS43LTE5LjdjLTAuNy0wLjctMS43LTAuNy0yLjQsMGwtMTIuNSwxMi41Yy0wLjcsMC43LTAuNywxLjcsMCwyLjRsMzMuNCwzMy41JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4zLDAuMywwLjgsMC41LDEuMywwLjVjMC40LDAsMC45LTAuMiwxLjItMC41bDMzLjQtMzMuNWMwLjctMC43LDAuNy0xLjcsMC0yLj'+\n\t\t\t'RsLTEyLjUtMTIuNUMtMTUzLjYsMzc2LjktMTU0LjYsMzc2LjktMTU1LjMsMzc3LjYmI3hkOyYjeGE7JiN4OTsmI3g5O3oiIGZpbGw9IiNGRkZGRkYiLz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._button_image_down__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"button_image_down\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='bottom : -1px;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_image_down.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_image_down.onmouseover=function (e) {\n\t\t\tme._button_image_down__img.style.visibility='hidden';\n\t\t\tme._button_image_down__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._button_image_down.onmouseout=function (e) {\n\t\t\tme._button_image_down__img.style.visibility='inherit';\n\t\t\tme._button_image_down__imgo.style.visibility='hidden';\n\t\t\tme.elementMouseDown['button_image_down']=false;\n\t\t}\n\t\tme._button_image_down.onmousedown=function (e) {\n\t\t\tme.elementMouseDown['button_image_down']=true;\n\t\t}\n\t\tme._button_image_down.onmouseup=function (e) {\n\t\t\tme.elementMouseDown['button_image_down']=false;\n\t\t}\n\t\tme._button_image_down.ontouchend=function (e) {\n\t\t\tme.elementMouseDown['button_image_down']=false;\n\t\t}\n\t\tme._button_image_down.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._button_direction.appendChild(me._button_image_down);\n\t\tel=me._button_image_up=document.createElement('div');\n\t\tels=me._button_image_up__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZD0iTS0xNzUsMzQwLjljLTMxLDAtNTYuMSwyNS4xLTU2LjEsNTYuMXMyNS4xLDU2LjEsNTYuMSw1Ni4xYzMxLDAsNTYuMS0yNS4xLDU2LjEtNTYuMVMtMTQ0LDM0MC45LTE3NSwzNDAuOSYjeGQ7JiN4YTsmI3g5OyYjeDk7eiBNLTE0My44LDQwMy4ybC0xMS4zLDExLjNjLTAuNiwwLjYtMS42LDAuNi0yLjIsMGwtMTcuNy0xNy43bC0xNy43LDE3LjdjLTAuNiwwLjYtMS42LDAuNi0yLjIsMGwtMTEuMy0xMS4zJiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuNi0wLjYtMC42LTEuNiwwLTIuMmwzMC0zMC4xYzAuMy0wLjMsMC43LTAuNCwxLjEtMC40YzAuNCwwLDAuOCww'+\n\t\t\t'LjEsMS4xLDAuNGwzMC4xLDMwLjFDLTE0My4yLDQwMS43LTE0My4yLDQwMi42LTE0My44LDQwMy4yeiIgZmlsbD0iIzAwMDAwMCIvPgogPC9nPgogPGcgaWQ9IkxheWVyXzIiPgogIDxwYXRoIGQ9Ik0tMTkyLjcsNDE0LjVsMTcuNy0xNy43bDE3LjcsMTcuN2MwLjYsMC42LDEuNiwwLjYsMi4yLDBsMTEuMy0xMS4zYzAuNi0wLjYsMC42LTEuNiwwLTIuMmwtMzAuMS0zMC4xJiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuMy0wLjMtMC43LTAuNS0xLjEtMC40Yy0wLjQsMC0wLjgsMC4xLTEuMSwwLjRsLTMwLDMwLjFjLTAuNiwwLjYtMC42LDEuNiwwLDIuMmwxMS4zLDExLjMmI3hkOyYjeGE7JiN4OTsmI3'+\n\t\t\t'g5O0MtMTk0LjMsNDE1LjEtMTkzLjMsNDE1LjEtMTkyLjcsNDE0LjV6IiBmaWxsPSIjRkZGRkZGIi8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._button_image_up__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._button_image_up__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZD0iTS0xNzUsMzM0LjZjLTM0LjQsMC02Mi40LDI3LjktNjIuNCw2Mi40czI3LjksNjIuNCw2Mi40LDYyLjRjMzQuNCwwLDYyLjQtMjcuOSw2Mi40LTYyLjQmI3hkOyYjeGE7JiN4OTsmI3g5O1MtMTQwLjYsMzM0LjYtMTc1LDMzNC42eiBNLTE0MC40LDQwMy45bC0xMi41LDEyLjVjLTAuNywwLjctMS43LDAuNy0yLjQsMGwtMTkuNy0xOS43bC0xOS43LDE5LjdjLTAuNywwLjctMS43LDAuNy0yLjQsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7bC0xMi41LTEyLjVjLTAuNy0wLjctMC43LTEuNywwLTIuNGwzMy40LTMzLjVjMC4zLTAuMywwLjgtMC41LDEuMi0wLjVjMC41'+\n\t\t\t'LDAsMC45LDAuMSwxLjMsMC41bDMzLjQsMzMuNSYjeGQ7JiN4YTsmI3g5OyYjeDk7Qy0xMzkuNyw0MDIuMi0xMzkuNyw0MDMuMy0xNDAuNCw0MDMuOXoiIGZpbGw9IiMwMDAwMDAiLz4KIDwvZz4KIDxnIGlkPSJMYXllcl8yIj4KICA8cGF0aCBkPSJNLTE5NC43LDQxNi40bDE5LjctMTkuN2wxOS43LDE5LjdjMC43LDAuNywxLjcsMC43LDIuNCwwbDEyLjUtMTIuNWMwLjctMC43LDAuNy0xLjcsMC0yLjRsLTMzLjQtMzMuNSYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjMtMC4zLTAuOC0wLjUtMS4zLTAuNWMtMC40LDAtMC45LDAuMi0xLjIsMC41bC0zMy40LDMzLjVjLTAuNywwLjctMC43LDEuNywwLD'+\n\t\t\t'IuNGwxMi41LDEyLjUmI3hkOyYjeGE7JiN4OTsmI3g5O0MtMTk2LjQsNDE3LjEtMTk1LjQsNDE3LjEtMTk0LjcsNDE2LjR6IiBmaWxsPSIjRkZGRkZGIi8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._button_image_up__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"button_image_up\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='bottom : 31px;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_image_up.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_image_up.onmouseover=function (e) {\n\t\t\tme._button_image_up__img.style.visibility='hidden';\n\t\t\tme._button_image_up__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._button_image_up.onmouseout=function (e) {\n\t\t\tme._button_image_up__img.style.visibility='inherit';\n\t\t\tme._button_image_up__imgo.style.visibility='hidden';\n\t\t\tme.elementMouseDown['button_image_up']=false;\n\t\t}\n\t\tme._button_image_up.onmousedown=function (e) {\n\t\t\tme.elementMouseDown['button_image_up']=true;\n\t\t}\n\t\tme._button_image_up.onmouseup=function (e) {\n\t\t\tme.elementMouseDown['button_image_up']=false;\n\t\t}\n\t\tme._button_image_up.ontouchend=function (e) {\n\t\t\tme.elementMouseDown['button_image_up']=false;\n\t\t}\n\t\tme._button_image_up.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._button_direction.appendChild(me._button_image_up);\n\t\tme.divSkin.appendChild(me._button_direction);\n\t\tel=me._thumbnail=document.createElement('div');\n\t\tel.ggPermeable=false;\n\t\tel.ggId=\"thumbnail\";\n\t\tel.ggDx=12;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='bottom : 86px;';\n\t\ths+='height : 32px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._thumbnail.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._thumbnail.onclick=function (e) {\n\t\t\tplayer.setVariableValue('vis_thumbnail_menu', !player.getVariableValue('vis_thumbnail_menu'));\n\t\t}\n\t\tme._thumbnail.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._thumbnail_hide_button=document.createElement('div');\n\t\tels=me._thumbnail_hide_button__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDIyLjAuMSwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgaWQ9IkxheWVyXzEiIHZlcnNpb249IjEuMSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAgMTMwIDEzMDsiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iMCAwIDEzMCAxMzAiIHhtbDpzcGFjZT0icH'+\n\t\t\t'Jlc2VydmUiPgogPGcgaWQ9IkxheWVyXzFfMV8iPgogIDxwYXRoIGQ9Ik02NSw4LjlDMzQsOC45LDguOSwzNCw4LjksNjVTMzQsMTIxLjEsNjUsMTIxLjFjMzEsMCw1Ni4xLTI1LjEsNTYuMS01Ni4xUzk2LDguOSw2NSw4Ljl6IE01NS40LDU3LjgmI3hhOyYjeDk7JiN4OTtjMC0xLjMsMS4xLTIuNCwyLjUtMi40aDEwLjRMNTUuNCw2OC4zVjU3Ljh6IE0yNy44LDcyLjJWNTcuOGMwLTEuMywxLjEtMi40LDIuNS0yLjRoMTQuM2MxLjQsMCwyLjUsMS4xLDIuNSwyLjR2MTQuMyYjeGE7JiN4OTsmI3g5O2MwLDEuMy0xLjEsMi40LTIuNSwyLjRIMzAuM0MyOC45LDc0LjYsMjcuOCw3My41LDI3LjgsNzIu'+\n\t\t\t'MnogTTMyLjgsMTAwLjRjLTAuNCwwLTAuOC0wLjEtMS4xLTAuNGwtMS43LTEuN2MtMC42LTAuNi0wLjYtMS42LDAtMi4yJiN4YTsmI3g5OyYjeDk7bDY2LTY2YzAuMy0wLjMsMC43LTAuNCwxLjEtMC40YzAuNCwwLDAuOCwwLjEsMS4xLDAuNGwxLjcsMS43YzAuNiwwLjYsMC42LDEuNiwwLDIuMmwtNjYsNjZDMzMuNiwxMDAuMywzMy4yLDEwMC40LDMyLjgsMTAwLjR6JiN4YTsmI3g5OyYjeDk7IE03NC42LDcyLjJjMCwxLjMtMS4xLDIuNC0yLjUsMi40SDYxLjlsMTIuNy0xMi43TDc0LjYsNzIuMkw3NC42LDcyLjJ6IE0xMDIuMiw3Mi4yYzAsMS4zLTEuMSwyLjQtMi41LDIuNEg4NS41JiN4YTsmI3'+\n\t\t\t'g5OyYjeDk7Yy0xLjQsMC0yLjUtMS4xLTIuNS0yLjRWNTcuOGMwLTEuMywxLjEtMi40LDIuNS0yLjRoMTQuMmMxLjQsMCwyLjUsMS4xLDIuNSwyLjRDMTAyLjIsNTcuOCwxMDIuMiw3Mi4yLDEwMi4yLDcyLjJ6IiBmaWxsPSIjMDAwMDAwIi8+CiA8L2c+CiA8ZyBpZD0iTGF5ZXJfMl8xXyI+CiAgPHBhdGggZD0iTTU1LjQsNTcuOGMwLTEuMywxLjEtMi40LDIuNS0yLjRoMTAuNEw1NS40LDY4LjNWNTcuOHogTTI3LjgsNzIuMlY1Ny44YzAtMS4zLDEuMS0yLjQsMi41LTIuNGgxNC4zJiN4YTsmI3g5OyYjeDk7YzEuNCwwLDIuNSwxLjEsMi41LDIuNHYxNC4zYzAsMS4zLTEuMSwyLjQtMi41LDIuNEgz'+\n\t\t\t'MC4zQzI4LjksNzQuNiwyNy44LDczLjUsMjcuOCw3Mi4yeiBNMzIuOCwxMDAuNGMtMC40LDAtMC44LTAuMS0xLjEtMC40JiN4YTsmI3g5OyYjeDk7bC0xLjctMS43Yy0wLjYtMC42LTAuNi0xLjYsMC0yLjJsNjYtNjZjMC4zLTAuMywwLjctMC40LDEuMS0wLjRjMC40LDAsMC44LDAuMSwxLjEsMC40bDEuNywxLjdjMC42LDAuNiwwLjYsMS42LDAsMi4ybC02Niw2NiYjeGE7JiN4OTsmI3g5O0MzMy42LDEwMC4zLDMzLjIsMTAwLjQsMzIuOCwxMDAuNHogTTc0LjYsNzIuMmMwLDEuMy0xLjEsMi40LTIuNSwyLjRINjEuOWwxMi43LTEyLjdMNzQuNiw3Mi4yTDc0LjYsNzIuMnogTTEwMi4yLDcyLjImI3'+\n\t\t\t'hhOyYjeDk7JiN4OTtjMCwxLjMtMS4xLDIuNC0yLjUsMi40SDg1LjVjLTEuNCwwLTIuNS0xLjEtMi41LTIuNFY1Ny44YzAtMS4zLDEuMS0yLjQsMi41LTIuNGgxNC4yYzEuNCwwLDIuNSwxLjEsMi41LDIuNCYjeGE7JiN4OTsmI3g5O0MxMDIuMiw1Ny44LDEwMi4yLDcyLjIsMTAyLjIsNzIuMnogTTU1LjQsNTcuOGMwLTEuMywxLjEtMi40LDIuNS0yLjRoMTAuNEw1NS40LDY4LjNWNTcuOHogTTI3LjgsNzIuMlY1Ny44YzAtMS4zLDEuMS0yLjQsMi41LTIuNCYjeGE7JiN4OTsmI3g5O2gxNC4zYzEuNCwwLDIuNSwxLjEsMi41LDIuNHYxNC4zYzAsMS4zLTEuMSwyLjQtMi41LDIuNEgzMC4zQzI4Ljks'+\n\t\t\t'NzQuNiwyNy44LDczLjUsMjcuOCw3Mi4yeiBNMzIuOCwxMDAuNGMtMC40LDAtMC44LTAuMS0xLjEtMC40JiN4YTsmI3g5OyYjeDk7bC0xLjctMS43Yy0wLjYtMC42LTAuNi0xLjYsMC0yLjJsNjYtNjZjMC4zLTAuMywwLjctMC40LDEuMS0wLjRjMC40LDAsMC44LDAuMSwxLjEsMC40bDEuNywxLjdjMC42LDAuNiwwLjYsMS42LDAsMi4ybC02Niw2NiYjeGE7JiN4OTsmI3g5O0MzMy42LDEwMC4zLDMzLjIsMTAwLjQsMzIuOCwxMDAuNHogTTc0LjYsNzIuMmMwLDEuMy0xLjEsMi40LTIuNSwyLjRINjEuOWwxMi43LTEyLjdMNzQuNiw3Mi4yTDc0LjYsNzIuMnogTTEwMi4yLDcyLjImI3hhOyYjeDk7Ji'+\n\t\t\t'N4OTtjMCwxLjMtMS4xLDIuNC0yLjUsMi40SDg1LjVjLTEuNCwwLTIuNS0xLjEtMi41LTIuNFY1Ny44YzAtMS4zLDEuMS0yLjQsMi41LTIuNGgxNC4yYzEuNCwwLDIuNSwxLjEsMi41LDIuNCYjeGE7JiN4OTsmI3g5O0MxMDIuMiw1Ny44LDEwMi4yLDcyLjIsMTAyLjIsNzIuMnoiIGZpbGw9IiNGRkZGRkYiLz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._thumbnail_hide_button__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._thumbnail_hide_button__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDIyLjAuMSwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgaWQ9IkxheWVyXzEiIHZlcnNpb249IjEuMSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAgMTMwIDEzMDsiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iMCAwIDEzMCAxMzAiIHhtbDpzcGFjZT0icH'+\n\t\t\t'Jlc2VydmUiPgogPGcgaWQ9IkxheWVyXzFfMV8iPgogIDxwYXRoIGQ9Ik02NSwyLjZDMzAuNiwyLjYsMi42LDMwLjYsMi42LDY1czI3LjksNjIuNCw2Mi40LDYyLjRjMzQuNCwwLDYyLjQtMjcuOSw2Mi40LTYyLjRTOTkuNCwyLjYsNjUsMi42eiBNNTQuMyw1Ny4xJiN4YTsmI3g5OyYjeDk7YzAtMS41LDEuMi0yLjcsMi43LTIuN2gxMS42TDU0LjMsNjguN1Y1Ny4xeiBNMjMuNyw3Mi45VjU3LjFjMC0xLjUsMS4yLTIuNywyLjctMi43aDE1LjhjMS41LDAsMi43LDEuMiwyLjcsMi43djE1LjkmI3hhOyYjeDk7JiN4OTtjMCwxLjUtMS4yLDIuNy0yLjcsMi43SDI2LjRDMjQuOSw3NS43LDIzLjcsNzQu'+\n\t\t\t'NCwyMy43LDcyLjl6IE0yOS4zLDEwNC40Yy0wLjQsMC0wLjktMC4yLTEuMi0wLjVsLTEuOC0xLjhjLTAuNy0wLjctMC43LTEuNywwLTIuNCYjeGE7JiN4OTsmI3g5O2w3My4zLTczLjNjMC4zLTAuMywwLjgtMC41LDEuMi0wLjVzMC45LDAuMiwxLjIsMC41bDEuOCwxLjhjMC43LDAuNywwLjcsMS43LDAsMi40bC03My4zLDczLjNDMzAuMSwxMDQuMiwyOS43LDEwNC40LDI5LjMsMTA0LjR6JiN4YTsmI3g5OyYjeDk7IE03NS43LDcyLjljMCwxLjUtMS4yLDIuNy0yLjcsMi43SDYxLjVsMTQuMS0xNC4xTDc1LjcsNzIuOUw3NS43LDcyLjl6IE0xMDYuMyw3Mi45YzAsMS41LTEuMiwyLjctMi43LDIuN0'+\n\t\t\t'g4Ny44JiN4YTsmI3g5OyYjeDk7Yy0xLjUsMC0yLjctMS4yLTIuNy0yLjdWNTcuMWMwLTEuNSwxLjItMi43LDIuNy0yLjdoMTUuOGMxLjUsMCwyLjcsMS4yLDIuNywyLjdDMTA2LjMsNTcuMSwxMDYuMyw3Mi45LDEwNi4zLDcyLjl6IiBmaWxsPSIjMDAwMDAwIi8+CiA8L2c+CiA8ZyBpZD0iTGF5ZXJfMl8xXyI+CiAgPHBhdGggZD0iTTU0LjMsNTcuMWMwLTEuNSwxLjItMi43LDIuNy0yLjdoMTEuNkw1NC4zLDY4LjdWNTcuMXogTTIzLjcsNzIuOVY1Ny4xYzAtMS41LDEuMi0yLjcsMi43LTIuN2gxNS44JiN4YTsmI3g5OyYjeDk7YzEuNSwwLDIuNywxLjIsMi43LDIuN3YxNS45YzAsMS41LTEuMiwy'+\n\t\t\t'LjctMi43LDIuN0gyNi40QzI0LjksNzUuNywyMy43LDc0LjQsMjMuNyw3Mi45eiBNMjkuMywxMDQuNGMtMC40LDAtMC45LTAuMi0xLjItMC41JiN4YTsmI3g5OyYjeDk7bC0xLjgtMS44Yy0wLjctMC43LTAuNy0xLjcsMC0yLjRsNzMuMy03My4zYzAuMy0wLjMsMC44LTAuNSwxLjItMC41czAuOSwwLjIsMS4yLDAuNWwxLjgsMS44YzAuNywwLjcsMC43LDEuNywwLDIuNGwtNzMuMyw3My4zJiN4YTsmI3g5OyYjeDk7QzMwLjEsMTA0LjIsMjkuNywxMDQuNCwyOS4zLDEwNC40eiBNNzUuNyw3Mi45YzAsMS41LTEuMiwyLjctMi43LDIuN0g2MS41bDE0LjEtMTQuMUw3NS43LDcyLjlMNzUuNyw3Mi45ei'+\n\t\t\t'BNMTA2LjMsNzIuOSYjeGE7JiN4OTsmI3g5O2MwLDEuNS0xLjIsMi43LTIuNywyLjdIODcuOGMtMS41LDAtMi43LTEuMi0yLjctMi43VjU3LjFjMC0xLjUsMS4yLTIuNywyLjctMi43aDE1LjhjMS41LDAsMi43LDEuMiwyLjcsMi43JiN4YTsmI3g5OyYjeDk7QzEwNi4zLDU3LjEsMTA2LjMsNzIuOSwxMDYuMyw3Mi45eiBNNTQuMyw1Ny4xYzAtMS41LDEuMi0yLjcsMi43LTIuN2gxMS42TDU0LjMsNjguN1Y1Ny4xeiBNMjMuNyw3Mi45VjU3LjFjMC0xLjUsMS4yLTIuNywyLjctMi43JiN4YTsmI3g5OyYjeDk7aDE1LjhjMS41LDAsMi43LDEuMiwyLjcsMi43djE1LjljMCwxLjUtMS4yLDIuNy0yLjcs'+\n\t\t\t'Mi43SDI2LjRDMjQuOSw3NS43LDIzLjcsNzQuNCwyMy43LDcyLjl6IE0yOS4zLDEwNC40Yy0wLjQsMC0wLjktMC4yLTEuMi0wLjUmI3hhOyYjeDk7JiN4OTtsLTEuOC0xLjhjLTAuNy0wLjctMC43LTEuNywwLTIuNGw3My4zLTczLjNjMC4zLTAuMywwLjgtMC41LDEuMi0wLjVzMC45LDAuMiwxLjIsMC41bDEuOCwxLjhjMC43LDAuNywwLjcsMS43LDAsMi40bC03My4zLDczLjMmI3hhOyYjeDk7JiN4OTtDMzAuMSwxMDQuMiwyOS43LDEwNC40LDI5LjMsMTA0LjR6IE03NS43LDcyLjljMCwxLjUtMS4yLDIuNy0yLjcsMi43SDYxLjVsMTQuMS0xNC4xTDc1LjcsNzIuOUw3NS43LDcyLjl6IE0xMDYuMy'+\n\t\t\t'w3Mi45JiN4YTsmI3g5OyYjeDk7YzAsMS41LTEuMiwyLjctMi43LDIuN0g4Ny44Yy0xLjUsMC0yLjctMS4yLTIuNy0yLjdWNTcuMWMwLTEuNSwxLjItMi43LDIuNy0yLjdoMTUuOGMxLjUsMCwyLjcsMS4yLDIuNywyLjcmI3hhOyYjeDk7JiN4OTtDMTA2LjMsNTcuMSwxMDYuMyw3Mi45LDEwNi4zLDcyLjl6IiBmaWxsPSIjRkZGRkZGIi8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._thumbnail_hide_button__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"thumbnail_hide_button\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._thumbnail_hide_button.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._thumbnail_hide_button.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('vis_thumbnail_menu') == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._thumbnail_hide_button.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._thumbnail_hide_button.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._thumbnail_hide_button.style[domTransition]='opacity 0s';\n\t\t\t\tif (me._thumbnail_hide_button.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tme._thumbnail_hide_button.style.visibility=\"hidden\";\n\t\t\t\t\tme._thumbnail_hide_button.style.opacity=0;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._thumbnail_hide_button.style.visibility=me._thumbnail_hide_button.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._thumbnail_hide_button.style.opacity=1;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._thumbnail_hide_button.onmouseover=function (e) {\n\t\t\tme._thumbnail_hide_button__img.style.visibility='hidden';\n\t\t\tme._thumbnail_hide_button__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._thumbnail_hide_button.onmouseout=function (e) {\n\t\t\tme._thumbnail_hide_button__img.style.visibility='inherit';\n\t\t\tme._thumbnail_hide_button__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._thumbnail_hide_button.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._thumbnail.appendChild(me._thumbnail_hide_button);\n\t\tel=me._thumbnail_show_button=document.createElement('div');\n\t\tels=me._thumbnail_show_button__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZD0iTS0xMTguOSwzOTdjMC0zMS0yNS4xLTU2LjEtNTYuMS01Ni4xYy0zMSwwLTU2LjEsMjUuMS01Ni4xLDU2LjFzMjUuMSw1Ni4xLDU2LjEsNTYuMSYjeGQ7JiN4YTsmI3g5OyYjeDk7Qy0xNDQsNDUzLjEtMTE4LjksNDI4LTExOC45LDM5N3ogTS0yMDkuNyw0MDYuNmMtMS40LDAtMi41LTEuMS0yLjUtMi40di0xNC4zYzAtMS4zLDEuMS0yLjQsMi41LTIuNGgxNC4zYzEuNCwwLDIuNSwxLjEsMi41LDIuNCYjeGQ7JiN4YTsmI3g5OyYjeDk7djE0LjNjMCwxLjMtMS4xLDIuNC0yLjUsMi40TC0yMDkuNyw0MDYuNkwtMjA5LjcsNDA2LjZ6IE0tMTgyLjEsNDA2LjZj'+\n\t\t\t'LTEuNCwwLTIuNS0xLjEtMi41LTIuNHYtMTQuM2MwLTEuMywxLjEtMi40LDIuNS0yLjRoMTQuMiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzEuNCwwLDIuNSwxLjEsMi41LDIuNHYxNC4zYzAsMS4zLTEuMSwyLjQtMi41LDIuNEwtMTgyLjEsNDA2LjZMLTE4Mi4xLDQwNi42eiBNLTE1NC41LDQwNi42Yy0xLjQsMC0yLjUtMS4xLTIuNS0yLjR2LTE0LjMmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLTEuMywxLjEtMi40LDIuNS0yLjRoMTQuMmMxLjQsMCwyLjUsMS4xLDIuNSwyLjR2MTQuM2MwLDEuMy0xLjEsMi40LTIuNSwyLjRMLTE1NC41LDQwNi42eiIgZmlsbD0iIzAwMDAwMCIvPgogPC9nPgogPGcgaWQ9Ik'+\n\t\t\t'xheWVyXzIiPgogIDxnPgogICA8Zz4KICAgIDxwYXRoIGQ9Ik0tMTU0LjUsNDA2LjZjLTEuNCwwLTIuNS0xLjEtMi41LTIuNHYtMTQuM2MwLTEuMywxLjEtMi40LDIuNS0yLjRoMTQuMmMxLjQsMCwyLjUsMS4xLDIuNSwyLjR2MTQuMyYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTsmI3g5O2MwLDEuMy0xLjEsMi40LTIuNSwyLjRMLTE1NC41LDQwNi42eiIgZmlsbD0iI0ZGRkZGRiIvPgogICAgPHBhdGggZD0iTS0xODIuMSw0MDYuNmMtMS40LDAtMi41LTEuMS0yLjUtMi40di0xNC4zYzAtMS4zLDEuMS0yLjQsMi41LTIuNGgxNC4yYzEuNCwwLDIuNSwxLjEsMi41LDIuNHYxNC4zJiN4ZDsmI3hhOyYj'+\n\t\t\t'eDk7JiN4OTsmI3g5OyYjeDk7YzAsMS4zLTEuMSwyLjQtMi41LDIuNEwtMTgyLjEsNDA2LjZMLTE4Mi4xLDQwNi42eiIgZmlsbD0iI0ZGRkZGRiIvPgogICAgPHBhdGggZD0iTS0yMDkuNyw0MDYuNmMtMS40LDAtMi41LTEuMS0yLjUtMi40di0xNC4zYzAtMS4zLDEuMS0yLjQsMi41LTIuNGgxNC4zYzEuNCwwLDIuNSwxLjEsMi41LDIuNHYxNC4zJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5OyYjeDk7YzAsMS4zLTEuMSwyLjQtMi41LDIuNEwtMjA5LjcsNDA2LjZMLTIwOS43LDQwNi42eiIgZmlsbD0iI0ZGRkZGRiIvPgogICA8L2c+CiAgPC9nPgogPC9nPgo8L3N2Zz4K';\n\t\tme._thumbnail_show_button__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._thumbnail_show_button__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZD0iTS0xMTIuNiwzOTdjMC0zNC40LTI3LjktNjIuNC02Mi40LTYyLjRjLTM0LjQsMC02Mi40LDI3LjktNjIuNCw2Mi40czI3LjksNjIuNCw2Mi40LDYyLjQmI3hkOyYjeGE7JiN4OTsmI3g5O0MtMTQwLjYsNDU5LjQtMTEyLjYsNDMxLjQtMTEyLjYsMzk3eiBNLTIxMy42LDQwNy42Yy0xLjUsMC0yLjctMS4yLTIuNy0yLjd2LTE1LjljMC0xLjUsMS4yLTIuNywyLjctMi43aDE1LjgmI3hkOyYjeGE7JiN4OTsmI3g5O2MxLjUsMCwyLjcsMS4yLDIuNywyLjd2MTUuOWMwLDEuNS0xLjIsMi43LTIuNywyLjdMLTIxMy42LDQwNy42TC0yMTMuNiw0MDcuNnogTS0xODIu'+\n\t\t\t'OSw0MDcuNmMtMS41LDAtMi43LTEuMi0yLjctMi43di0xNS45JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC0xLjUsMS4yLTIuNywyLjctMi43aDE1LjhjMS41LDAsMi43LDEuMiwyLjcsMi43djE1LjljMCwxLjUtMS4yLDIuNy0yLjcsMi43TC0xODIuOSw0MDcuNkwtMTgyLjksNDA3LjZ6IE0tMTUyLjIsNDA3LjYmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMS41LDAtMi43LTEuMi0yLjctMi43di0xNS45YzAtMS41LDEuMi0yLjcsMi43LTIuN2gxNS44YzEuNSwwLDIuNywxLjIsMi43LDIuN3YxNS45YzAsMS41LTEuMiwyLjctMi43LDIuN0wtMTUyLjIsNDA3LjZ6IiBmaWxsPSIjMDAwMDAwIi8+CiA8L2c+Ci'+\n\t\t\t'A8ZyBpZD0iTGF5ZXJfMiI+CiAgPGc+CiAgIDxnPgogICAgPHBhdGggZD0iTS0xNTIuMiw0MDcuNmMtMS41LDAtMi43LTEuMi0yLjctMi43di0xNS45YzAtMS41LDEuMi0yLjcsMi43LTIuN2gxNS44YzEuNSwwLDIuNywxLjIsMi43LDIuN3YxNS45JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5OyYjeDk7YzAsMS41LTEuMiwyLjctMi43LDIuN0wtMTUyLjIsNDA3LjZ6IiBmaWxsPSIjRkZGRkZGIi8+CiAgICA8cGF0aCBkPSJNLTE4Mi45LDQwNy42Yy0xLjUsMC0yLjctMS4yLTIuNy0yLjd2LTE1LjljMC0xLjUsMS4yLTIuNywyLjctMi43aDE1LjhjMS41LDAsMi43LDEuMiwyLjcsMi43djE1LjkmI3hk'+\n\t\t\t'OyYjeGE7JiN4OTsmI3g5OyYjeDk7JiN4OTtjMCwxLjUtMS4yLDIuNy0yLjcsMi43TC0xODIuOSw0MDcuNkwtMTgyLjksNDA3LjZ6IiBmaWxsPSIjRkZGRkZGIi8+CiAgICA8cGF0aCBkPSJNLTIxMy42LDQwNy42Yy0xLjUsMC0yLjctMS4yLTIuNy0yLjd2LTE1LjljMC0xLjUsMS4yLTIuNywyLjctMi43aDE1LjhjMS41LDAsMi43LDEuMiwyLjcsMi43djE1LjkmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7JiN4OTtjMCwxLjUtMS4yLDIuNy0yLjcsMi43TC0yMTMuNiw0MDcuNkwtMjEzLjYsNDA3LjZ6IiBmaWxsPSIjRkZGRkZGIi8+CiAgIDwvZz4KICA8L2c+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._thumbnail_show_button__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"thumbnail_show_button\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 0px;';\n\t\ths+='opacity : 0;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._thumbnail_show_button.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._thumbnail_show_button.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('vis_thumbnail_menu') == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._thumbnail_show_button.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._thumbnail_show_button.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._thumbnail_show_button.style[domTransition]='opacity 0s';\n\t\t\t\tif (me._thumbnail_show_button.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tme._thumbnail_show_button.style.visibility=me._thumbnail_show_button.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._thumbnail_show_button.style.opacity=1;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._thumbnail_show_button.style.visibility=\"hidden\";\n\t\t\t\t\tme._thumbnail_show_button.style.opacity=0;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._thumbnail_show_button.onmouseover=function (e) {\n\t\t\tme._thumbnail_show_button__img.style.visibility='hidden';\n\t\t\tme._thumbnail_show_button__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._thumbnail_show_button.onmouseout=function (e) {\n\t\t\tme._thumbnail_show_button__img.style.visibility='inherit';\n\t\t\tme._thumbnail_show_button__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._thumbnail_show_button.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._thumbnail.appendChild(me._thumbnail_show_button);\n\t\tme.divSkin.appendChild(me._thumbnail);\n\t\tel=me._thumbnail_menu=document.createElement('div');\n\t\tels=me._thumbnail_menu__content=document.createElement('div');\n\t\tels.className='ggskin ggskin_subelement ggskin_scrollarea';\n\t\tel.ggContent=els;\n\t\tel.appendChild(els);\n\t\tel.ggHorScrollVisible = false;\n\t\tel.ggVertScrollVisible = false;\n\t\tel.ggContentLeftOffset = 0;\n\t\tel.ggContentTopOffset = 0;\n\t\tel.ggDragInertiaX = 0;\n\t\tel.ggDragInertiaY = 0;\n\t\tel.ggVPercentVisible = 1.0;\n\t\tel.ggHPercentVisible = 1.0;\n\t\ths ='';\n\t\ths+='height : 73px;';\n\t\ths+='left : 50%;';\n\t\ths+='margin-left : -57.5px;';\n\t\ths+='overflow : visible;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='width : 115px;';\n\t\ths+=\"\";\n\t\tels.setAttribute('style',hs);\n\t\tme._thumbnail_menu.ggScrollByX = function(diffX) {\n\t\t\tif(!me._thumbnail_menu.ggHorScrollVisible || diffX == 0 || me._thumbnail_menu.ggHPercentVisible >= 1.0) return;\n\t\t\tme._thumbnail_menu.ggScrollPosX = (me._thumbnail_menu__horScrollFg.offsetLeft + diffX);\n\t\t\tme._thumbnail_menu.ggScrollPosX = Math.max(me._thumbnail_menu.ggScrollPosX, 0);\n\t\t\tme._thumbnail_menu.ggScrollPosX = Math.min(me._thumbnail_menu.ggScrollPosX, me._thumbnail_menu__horScrollBg.offsetWidth - me._thumbnail_menu__horScrollFg.offsetWidth);\n\t\t\tme._thumbnail_menu__horScrollFg.style.left = me._thumbnail_menu.ggScrollPosX + 'px';\n\t\t\tlet percentScrolled = me._thumbnail_menu.ggScrollPosX / (me._thumbnail_menu__horScrollBg.offsetWidth - me._thumbnail_menu__horScrollFg.offsetWidth);\n\t\t\tme._thumbnail_menu__content.style.left = -(Math.round((me._thumbnail_menu.ggContentWidth * (1.0 - me._thumbnail_menu.ggHPercentVisible)) * percentScrolled)) + me._thumbnail_menu.ggContentLeftOffset + 'px';\n\t\t\tme._thumbnail_menu.ggScrollPosXPercent = (me._thumbnail_menu__horScrollFg.offsetLeft / me._thumbnail_menu__horScrollBg.offsetWidth);\n\t\t}\n\t\tme._thumbnail_menu.ggScrollByXSmooth = function(diffX) {\n\t\t\tif(!me._thumbnail_menu.ggHorScrollVisible || diffX == 0 || me._thumbnail_menu.ggHPercentVisible >= 1.0) return;\n\t\t\tvar scrollPerInterval = diffX / 25;\n\t\t\tvar scrollCurrX = 0;\n\t\t\tvar id = setInterval(function() {\n\t\t\t\tscrollCurrX += scrollPerInterval;\n\t\t\t\tme._thumbnail_menu.ggScrollPosX += scrollPerInterval;\n\t\t\t\tif (diffX > 0 && (scrollCurrX >= diffX || me._thumbnail_menu.ggScrollPosX >= me._thumbnail_menu__horScrollBg.offsetWidth - me._thumbnail_menu__horScrollFg.offsetWidth)) {\n\t\t\t\t\tme._thumbnail_menu.ggScrollPosX = Math.min(me._thumbnail_menu.ggScrollPosX, me._thumbnail_menu__horScrollBg.offsetWidth - me._thumbnail_menu__horScrollFg.offsetWidth);\n\t\t\t\t\tclearInterval(id);\n\t\t\t\t}\n\t\t\t\tif (diffX < 0 && (scrollCurrX <= diffX || me._thumbnail_menu.ggScrollPosX <= 0)) {\n\t\t\t\t\tme._thumbnail_menu.ggScrollPosX = Math.max(me._thumbnail_menu.ggScrollPosX, 0);\n\t\t\t\t\tclearInterval(id);\n\t\t\t\t}\n\t\t\tme._thumbnail_menu__horScrollFg.style.left = me._thumbnail_menu.ggScrollPosX + 'px';\n\t\t\tlet percentScrolled = me._thumbnail_menu.ggScrollPosX / (me._thumbnail_menu__horScrollBg.offsetWidth - me._thumbnail_menu__horScrollFg.offsetWidth);\n\t\t\tme._thumbnail_menu__content.style.left = -(Math.round((me._thumbnail_menu.ggContentWidth * (1.0 - me._thumbnail_menu.ggHPercentVisible)) * percentScrolled)) + me._thumbnail_menu.ggContentLeftOffset + 'px';\n\t\t\tme._thumbnail_menu.ggScrollPosXPercent = (me._thumbnail_menu__horScrollFg.offsetLeft / me._thumbnail_menu__horScrollBg.offsetWidth);\n\t\t\t}, 10);\n\t\t}\n\t\tme._thumbnail_menu.ggScrollByY = function(diffY) {\n\t\t\tif(!me._thumbnail_menu.ggVertScrollVisible || diffY == 0 || me._thumbnail_menu.ggVPercentVisible >= 1.0) return;\n\t\t\tme._thumbnail_menu.ggScrollPosY = (me._thumbnail_menu__vertScrollFg.offsetTop + diffY);\n\t\t\tme._thumbnail_menu.ggScrollPosY = Math.max(me._thumbnail_menu.ggScrollPosY, 0);\n\t\t\tme._thumbnail_menu.ggScrollPosY = Math.min(me._thumbnail_menu.ggScrollPosY, me._thumbnail_menu__vertScrollBg.offsetHeight - me._thumbnail_menu__vertScrollFg.offsetHeight);\n\t\t\tme._thumbnail_menu__vertScrollFg.style.top = me._thumbnail_menu.ggScrollPosY + 'px';\n\t\t\tlet percentScrolled = me._thumbnail_menu.ggScrollPosY / (me._thumbnail_menu__vertScrollBg.offsetHeight - me._thumbnail_menu__vertScrollFg.offsetHeight);\n\t\t\tme._thumbnail_menu__content.style.top = -(Math.round((me._thumbnail_menu.ggContentHeight * (1.0 - me._thumbnail_menu.ggVPercentVisible)) * percentScrolled)) + me._thumbnail_menu.ggContentTopOffset + 'px';\n\t\t\tme._thumbnail_menu.ggScrollPosYPercent = (me._thumbnail_menu__vertScrollFg.offsetTop / me._thumbnail_menu__vertScrollBg.offsetHeight);\n\t\t}\n\t\tme._thumbnail_menu.ggScrollByYSmooth = function(diffY) {\n\t\t\tif(!me._thumbnail_menu.ggVertScrollVisible || diffY == 0 || me._thumbnail_menu.ggVPercentVisible >= 1.0) return;\n\t\t\tvar scrollPerInterval = diffY / 25;\n\t\t\tvar scrollCurrY = 0;\n\t\t\tvar id = setInterval(function() {\n\t\t\t\tscrollCurrY += scrollPerInterval;\n\t\t\t\tme._thumbnail_menu.ggScrollPosY += scrollPerInterval;\n\t\t\t\tif (diffY > 0 && (scrollCurrY >= diffY || me._thumbnail_menu.ggScrollPosY >= me._thumbnail_menu__vertScrollBg.offsetHeight - me._thumbnail_menu__vertScrollFg.offsetHeight)) {\n\t\t\t\t\tme._thumbnail_menu.ggScrollPosY = Math.min(me._thumbnail_menu.ggScrollPosY, me._thumbnail_menu__vertScrollBg.offsetHeight - me._thumbnail_menu__vertScrollFg.offsetHeight);\n\t\t\t\t\tclearInterval(id);\n\t\t\t\t}\n\t\t\t\tif (diffY < 0 && (scrollCurrY <= diffY || me._thumbnail_menu.ggScrollPosY <= 0)) {\n\t\t\t\t\tme._thumbnail_menu.ggScrollPosY = Math.max(me._thumbnail_menu.ggScrollPosY, 0);\n\t\t\t\t\tclearInterval(id);\n\t\t\t\t}\n\t\t\tme._thumbnail_menu__vertScrollFg.style.top = me._thumbnail_menu.ggScrollPosY + 'px';\n\t\t\tlet percentScrolled = me._thumbnail_menu.ggScrollPosY / (me._thumbnail_menu__vertScrollBg.offsetHeight - me._thumbnail_menu__vertScrollFg.offsetHeight);\n\t\t\tme._thumbnail_menu__content.style.top = -(Math.round((me._thumbnail_menu.ggContentHeight * (1.0 - me._thumbnail_menu.ggVPercentVisible)) * percentScrolled)) + me._thumbnail_menu.ggContentTopOffset + 'px';\n\t\t\tme._thumbnail_menu.ggScrollPosYPercent = (me._thumbnail_menu__vertScrollFg.offsetTop / me._thumbnail_menu__vertScrollBg.offsetHeight);\n\t\t\t}, 10);\n\t\t}\n\t\tme._thumbnail_menu.ggScrollIntoView = function(posX, posY, width, height) {\n\t\t\tif (me._thumbnail_menu.ggHorScrollVisible) {\n\t\t\t\tif (posX < 0) {\n\t\t\t\t\tvar diffX = Math.floor(posX * me._thumbnail_menu.ggHPercentVisible);\n\t\t\t\t\tme._thumbnail_menu.ggScrollByXSmooth(diffX);\n\t\t\t\t} else if (posX + width > me._thumbnail_menu.clientWidth - (me._thumbnail_menu.ggVertScrollVisible ? 15 : 0)) {\n\t\t\t\t\tvar diffX = Math.ceil(((posX + width) - (me._thumbnail_menu.clientWidth - (me._thumbnail_menu.ggVertScrollVisible ? 15 : 0))) * me._thumbnail_menu.ggHPercentVisible);\n\t\t\t\t\tme._thumbnail_menu.ggScrollByXSmooth(diffX);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (me._thumbnail_menu.ggVertScrollVisible) {\n\t\t\t\tif (posY < 0) {\n\t\t\t\t\tvar diffY = Math.floor(posY * me._thumbnail_menu.ggVPercentVisible);\n\t\t\t\t\tme._thumbnail_menu.ggScrollByYSmooth(diffY);\n\t\t\t\t} else if (posY + height > me._thumbnail_menu.clientHeight - (me._thumbnail_menu.ggHorScrollVisible ? 15 : 0)) {\n\t\t\t\t\tvar diffY = Math.ceil(((posY + height) - (me._thumbnail_menu.clientHeight - (me._thumbnail_menu.ggHorScrollVisible ? 15 : 0))) * me._thumbnail_menu.ggVPercentVisible);\n\t\t\t\t\tme._thumbnail_menu.ggScrollByYSmooth(diffY);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tels.ontouchstart = function(e) {\n\t\t\te = e || window.event;\n\t\t\tvar t = e.touches;\n\t\t\tme._thumbnail_menu.ggDragLastX = t ? t[0].clientX : e.clientX;\n\t\t\tme._thumbnail_menu.ggDragLastY = t ? t[0].clientY : e.clientY;\n\t\t\tme._thumbnail_menu__content.ontouchend = function() {\n\t\t\t\tlet inertiaInterval = setInterval(function() {\n\t\t\t\t\tme._thumbnail_menu.ggDragInertiaX *= 0.65;\n\t\t\t\t\tme._thumbnail_menu.ggDragInertiaY *= 0.65;\n\t\t\t\t\tme._thumbnail_menu.ggScrollByX(me._thumbnail_menu.ggDragInertiaX);\n\t\t\t\t\tme._thumbnail_menu.ggScrollByY(me._thumbnail_menu.ggDragInertiaY);\n\t\t\t\t\tif (Math.abs(me._thumbnail_menu.ggDragInertiaX) < 1.0 && Math.abs(me._thumbnail_menu.ggDragInertiaY) < 1.0) {\n\t\t\t\t\t\tclearInterval(inertiaInterval);\n\t\t\t\t\t}\n\t\t\t\t\t}, 50);\n\t\t\t\tme._thumbnail_menu__content.ontouchend = null;\n\t\t\t\tme._thumbnail_menu__content.ontouchmove = null;\n\t\t\t\tme._thumbnail_menu__content.onpointerup = null;\n\t\t\t\tme._thumbnail_menu__content.onpointermove = null;\n\t\t\t}\n\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\tme._thumbnail_menu__content.onpointerup = me._thumbnail_menu__content.ontouchend;\n\t\t}\n\t\t\tme._thumbnail_menu__content.ontouchmove = function(e) {\n\t\t\t\te = e || window.event;\n\t\t\t\te.preventDefault();\n\t\t\t\tvar t = e.touches;\n\t\t\t\tvar diffX = ((t ? t[0].clientX : e.clientX) - me._thumbnail_menu.ggDragLastX) * me._thumbnail_menu.ggHPercentVisible;\n\t\t\t\tvar diffY = ((t ? t[0].clientY : e.clientY) - me._thumbnail_menu.ggDragLastY) * me._thumbnail_menu.ggVPercentVisible;\n\t\t\t\tme._thumbnail_menu.ggDragInertiaX = -diffX;\n\t\t\t\tme._thumbnail_menu.ggDragInertiaY = -diffY;\n\t\t\t\tme._thumbnail_menu.ggDragLastX = t ? t[0].clientX : e.clientX;\n\t\t\t\tme._thumbnail_menu.ggDragLastY = t ? t[0].clientY : e.clientY;\n\t\t\t\tme._thumbnail_menu.ggScrollByX(-diffX);\n\t\t\t\tme._thumbnail_menu.ggScrollByY(-diffY);\n\t\t\t}\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\t\tme._thumbnail_menu__content.onpointermove = me._thumbnail_menu__content.ontouchmove;\n\t\t\t}\n\t\t}\n\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\tels.onpointerdown = els.ontouchstart;\n\t\t}\n\t\telHorScrollBg = me._thumbnail_menu__horScrollBg = document.createElement('div');\n\t\tel.appendChild(elHorScrollBg);\n\t\telHorScrollBg.setAttribute('style', 'position: absolute; left: 0px; bottom: 0px; visibility: hidden; width: 480px; height: 15px; background-color: rgba(0,0,0,0.392157); pointer-events: auto;');\n\t\telHorScrollBg.className='ggskin ggskin_scrollarea_hscrollbg';\n\t\telHorScrollFg = me._thumbnail_menu__horScrollFg = document.createElement('div');\n\t\telHorScrollBg.appendChild(elHorScrollFg);\n\t\telHorScrollFg.className='ggskin ggskin_scrollarea_hscrollfg';\n\t\telHorScrollFg.setAttribute('style', 'position: absolute; left: 0px; top: 0px; visibility: hidden; width: 480px; height: 15px; background-color: rgba(0,0,0,1); pointer-events: auto;');\n\t\tme._thumbnail_menu.ggScrollPosX = 0;\n\t\tme._thumbnail_menu.ggScrollPosXPercent = 0.0;\n\t\telHorScrollFg.onmousedown = function(e) {\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) return;\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\te.stopPropagation();\n\t\t\tme._thumbnail_menu.ggDragLastX = e.clientX;\n\t\t\tdocument.onmouseup = function() {\n\t\t\t\tlet inertiaInterval = setInterval(function() {\n\t\t\t\t\tme._thumbnail_menu.ggDragInertiaX *= 0.65;\n\t\t\t\t\tme._thumbnail_menu.ggScrollByX(me._thumbnail_menu.ggDragInertiaX);\n\t\t\t\t\tif (Math.abs(me._thumbnail_menu.ggDragInertiaX) < 1.0) {\n\t\t\t\t\t\tclearInterval(inertiaInterval);\n\t\t\t\t\t}\n\t\t\t\t\t}, 50);\n\t\t\t\tdocument.onmouseup = null;\n\t\t\t\tdocument.onmousemove = null;\n\t\t\t}\n\t\t\tdocument.onmousemove = function(e) {\n\t\t\t\te = e || window.event;\n\t\t\t\te.preventDefault();\n\t\t\t\tvar diffX = e.clientX - me._thumbnail_menu.ggDragLastX;\n\t\t\t\tme._thumbnail_menu.ggDragInertiaX = diffX;\n\t\t\t\tme._thumbnail_menu.ggDragLastX = e.clientX;\n\t\t\t\tme._thumbnail_menu.ggScrollByX(diffX);\n\t\t\t}\n\t\t}\n\t\telHorScrollFg.ontouchstart = function(e) {\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\te.stopPropagation();\n\t\t\tvar t = e.touches;\n\t\t\tme._thumbnail_menu.ggDragLastX = t ? t[0].clientX : e.clientX;\n\t\t\tdocument.ontouchend = function() {\n\t\t\t\tlet inertiaInterval = setInterval(function() {\n\t\t\t\t\tme._thumbnail_menu.ggDragInertiaX *= 0.65;\n\t\t\t\t\tme._thumbnail_menu.ggScrollByX(me._thumbnail_menu.ggDragInertiaX);\n\t\t\t\t\tif (Math.abs(me._thumbnail_menu.ggDragInertiaX) < 1.0) {\n\t\t\t\t\t\tclearInterval(inertiaInterval);\n\t\t\t\t\t}\n\t\t\t\t\t}, 50);\n\t\t\t\tdocument.ontouchend = null;\n\t\t\t\tdocument.ontouchmove = null;\n\t\t\t\tdocument.onpointerup = null;\n\t\t\t\tdocument.onpointermove = null;\n\t\t\t}\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\t\tdocument.onpointerup = document.ontouchend;\n\t\t\t}\n\t\t\tdocument.ontouchmove = function(e) {\n\t\t\t\te = e || window.event;\n\t\t\t\te.preventDefault();\n\t\t\t\tvar t = e.touches;\n\t\t\t\tvar diffX = (t ? t[0].clientX : e.clientX) - me._thumbnail_menu.ggDragLastX;\n\t\t\t\tme._thumbnail_menu.ggDragInertiaX = diffX;\n\t\t\t\tme._thumbnail_menu.ggDragLastX = t ? t[0].clientX : e.clientX;\n\t\t\t\tme._thumbnail_menu.ggScrollByX(diffX);\n\t\t\t}\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\t\tdocument.onpointermove = document.ontouchmove;\n\t\t\t}\n\t\t}\n\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\telHorScrollFg.onpointerdown = elHorScrollFg.ontouchstart;\n\t\t}\n\t\telHorScrollBg.onmousedown = function(e) {\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\tvar diffX = me._thumbnail_menu.ggScrollWidth;\n\t\t\tif (e.offsetX < me._thumbnail_menu.ggScrollPosX) {\n\t\t\t\tdiffX = diffX * -1;\n\t\t\t}\n\t\t\tme._thumbnail_menu.ggScrollByXSmooth(diffX);\n\t\t}\n\t\telHorScrollBg.ontouchstart = function(e) {\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\te.stopPropagation();\n\t\t\tvar t = e.touches;\n\t\t\tvar rect = me._thumbnail_menu__horScrollBg.getBoundingClientRect();\n\t\t\tvar diffX = me._thumbnail_menu.ggScrollWidth;\n\t\t\tif ((t[0].clientX - rect.left) < me._thumbnail_menu.ggScrollPosX) {\n\t\t\t\tdiffX = diffX * -1;\n\t\t\t}\n\t\t\tme._thumbnail_menu.ggScrollByXSmooth(diffX);\n\t\t}\n\t\tel.addEventListener('wheel', function(e) {\n\t\t\te.preventDefault();\n\t\t\tvar wheelDelta = Math.sign(e.deltaX);\n\t\t\tme._thumbnail_menu.ggScrollByXSmooth(30 * me._thumbnail_menu.ggHPercentVisible * wheelDelta);\n\t\t});\n\t\telCornerBg = me._thumbnail_menu__cornerBg = document.createElement('div');\n\t\tel.appendChild(elCornerBg);\n\t\telCornerBg.setAttribute('style', 'position: absolute; right: 0px; bottom: 0px; visibility: hidden; width: 15px; height: 15px; background-color: rgba(255,255,255,1);');\n\t\telCornerBg.className='ggskin ggskin_scrollarea_scrollcorner';\n\t\tel.ggId=\"thumbnail_menu\";\n\t\tel.ggDx=1.5;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_scrollarea \";\n\t\tel.ggType='scrollarea';\n\t\ths ='';\n\t\ths+='border : 0px solid #000000;';\n\t\ths+='bottom : 128px;';\n\t\ths+='height : 84px;';\n\t\ths+='left : -10000px;';\n\t\ths+='overflow : hidden;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 60%;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._thumbnail_menu.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._thumbnail_menu.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('vis_thumbnail_menu') == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._thumbnail_menu.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._thumbnail_menu.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._thumbnail_menu.style[domTransition]='opacity 500ms ease 0ms';\n\t\t\t\tif (me._thumbnail_menu.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tsetTimeout(function() { if (me._thumbnail_menu.style.opacity == 0.0) { me._thumbnail_menu.style.visibility=\"hidden\"; } }, 505);\n\t\t\t\t\tme._thumbnail_menu.style.opacity=0;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._thumbnail_menu.style.visibility=me._thumbnail_menu.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._thumbnail_menu.style.opacity=1;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._thumbnail_menu.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=((this.ggDx * pw)/100.0 + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t\t{\n\t\t\t\tvar horScrollWasVisible = this.ggHorScrollVisible;\n\t\t\t\tvar vertScrollWasVisible = this.ggVertScrollVisible;\n\t\t\t\tthis.ggContent.style.left = '0px';\n\t\t\t\tthis.ggContent.style.top = '0px';\n\t\t\t\tthis.ggContentLeftOffset = 0;\n\t\t\t\tthis.ggContentTopOffset = 0;\n\t\t\t\tthis.ggContentWidth = 0;\n\t\t\t\tthis.ggContentHeight = 0;\n\t\t\t\tvar offsetWidthWithScale = this.getBoundingClientRect().width;\n\t\t\t\tvar offsetHeightWithScale = this.getBoundingClientRect().height;\n\t\t\t\tvar domRectContent = this.ggContent.getBoundingClientRect();\n\t\t\t\tvar minX = 0;\n\t\t\t\tvar minY = 0;\n\t\t\t\tvar maxX = 0;\n\t\t\t\tvar maxY = 0;\n\t\t\t\tvar stack=[];\n\t\t\t\tstack.push(this.ggContent);\n\t\t\t\twhile(stack.length>0) {\n\t\t\t\t\tvar e=stack.pop();\n\t\t\t\t\tif (e!=this.ggContent && e.getBoundingClientRect && e.style['display']!='none' && (e.offsetWidth != 0 || e.offsetHeight != 0)) {\n\t\t\t\t\t\tvar domRectChild = e.getBoundingClientRect();\n\t\t\t\t\t\tvar diffX = domRectChild.left - domRectContent.left;\n\t\t\t\t\t\tminX = Math.min(minX, diffX);\n\t\t\t\t\t\tmaxX = Math.max(maxX, diffX + domRectChild.width);\n\t\t\t\t\t\tvar diffY = domRectChild.top - domRectContent.top;\n\t\t\t\t\t\tminY = Math.min(minY, diffY);\n\t\t\t\t\t\tmaxY = Math.max(maxY, diffY + domRectChild.height);\n\t\t\t\t\t}\n\t\t\t\t\tif (e.hasChildNodes() && e.style['display']!='none' && e.style['overflow']!='hidden') {\n\t\t\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (minX < 0) this.ggContentLeftOffset = -minX;\n\t\t\t\tif (minY < 0) this.ggContentTopOffset = -minY;\n\t\t\t\tvar contentWidth = maxX - minX;\n\t\t\t\tvar contentHeight = maxY - minY;\n\t\t\tvar scaleX = this.getBoundingClientRect().width / this.offsetWidth;\n\t\t\t\tthis.ggContentWidth = contentWidth / scaleX;\n\t\t\tvar scaleY = this.getBoundingClientRect().height / this.offsetHeight;\n\t\t\t\tthis.ggContentHeight = contentHeight / scaleY;\n\t\t\t\tthis.ggContent.style.left = this.ggContentLeftOffset + 'px';\n\t\t\t\tthis.ggContent.style.top = this.ggContentTopOffset + 'px';\n\t\t\t\tthis.ggContent.style.width = contentWidth + 'px';\n\t\t\t\tthis.ggContent.style.height = contentHeight + 'px';\n\t\t\t\tvar containerWidth = offsetWidthWithScale;\n\t\t\t\tif (this.ggVertScrollVisible) containerWidth -= 15;\n\t\t\t\tif (contentWidth < containerWidth) {\n\t\t\t\t\tthis.ggContent.style.left = '50%';\n\t\t\t\t\tthis.ggContent.style.marginLeft = ((contentWidth/-2) - (this.ggVertScrollVisible ? (15/2) : 0)) + 'px';\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tthis.ggContent.style.left = this.ggContentLeftOffset + 'px';\n\t\t\t\t\tthis.ggContent.style.marginLeft = '0px';\n\t\t\t\t}\n\t\t\t\tthis.ggContent.style.top = this.ggContentTopOffset + 'px';\n\t\t\t\tthis.ggContent.style.marginTop = '0px';\n\t\t\t\tif (contentWidth > Math.ceil(offsetWidthWithScale)) {\n\t\t\t\t\tme._thumbnail_menu__horScrollBg.style.visibility = 'inherit';\n\t\t\t\t\tme._thumbnail_menu__horScrollFg.style.visibility = 'inherit';\n\t\t\t\t\tme._thumbnail_menu.ggHorScrollVisible = true;\n\t\t\t\t} else {\n\t\t\t\t\tme._thumbnail_menu__horScrollBg.style.visibility = 'hidden';\n\t\t\t\t\tme._thumbnail_menu__horScrollFg.style.visibility = 'hidden';\n\t\t\t\t\tme._thumbnail_menu.ggHorScrollVisible = false;\n\t\t\t\t}\n\t\t\t\tif(me._thumbnail_menu.ggHorScrollVisible) {\n\t\t\t\t\tme._thumbnail_menu.ggAvailableHeight = me._thumbnail_menu.clientHeight - 15;\n\t\t\t\t\tif (me._thumbnail_menu.ggVertScrollVisible) {\n\t\t\t\t\t\tme._thumbnail_menu.ggAvailableWidth = me._thumbnail_menu.clientWidth - 15;\n\t\t\t\t\t\tme._thumbnail_menu.ggAvailableWidthWithScale = me._thumbnail_menu.getBoundingClientRect().width - me._thumbnail_menu__horScrollBg.getBoundingClientRect().height;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tme._thumbnail_menu.ggAvailableWidth = me._thumbnail_menu.clientWidth;\n\t\t\t\t\t\tme._thumbnail_menu.ggAvailableWidthWithScale = me._thumbnail_menu.getBoundingClientRect().width;\n\t\t\t\t\t}\n\t\t\t\t\tme._thumbnail_menu__horScrollBg.style.width = me._thumbnail_menu.ggAvailableWidth + 'px';\n\t\t\t\t\tme._thumbnail_menu.ggHPercentVisible = contentWidth != 0 ? me._thumbnail_menu.ggAvailableWidthWithScale / contentWidth : 0.0;\n\t\t\t\t\tif (me._thumbnail_menu.ggHPercentVisible > 1.0) me._thumbnail_menu.ggHPercentVisible = 1.0;\n\t\t\t\t\tme._thumbnail_menu.ggScrollWidth = Math.round(me._thumbnail_menu__horScrollBg.offsetWidth * me._thumbnail_menu.ggHPercentVisible);\n\t\t\t\t\tme._thumbnail_menu__horScrollFg.style.width = me._thumbnail_menu.ggScrollWidth + 'px';\n\t\t\t\t\tme._thumbnail_menu.ggScrollPosX = me._thumbnail_menu.ggScrollPosXPercent * me._thumbnail_menu.ggAvailableWidth;\n\t\t\t\t\tme._thumbnail_menu.ggScrollPosX = Math.min(me._thumbnail_menu.ggScrollPosX, me._thumbnail_menu__horScrollBg.offsetWidth - me._thumbnail_menu__horScrollFg.offsetWidth);\n\t\t\t\t\tme._thumbnail_menu__horScrollFg.style.left = me._thumbnail_menu.ggScrollPosX + 'px';\n\t\t\t\t\tif (me._thumbnail_menu.ggHPercentVisible < 1.0) {\n\t\t\t\t\t\tlet percentScrolled = me._thumbnail_menu.ggScrollPosX / (me._thumbnail_menu__horScrollBg.offsetWidth - me._thumbnail_menu__horScrollFg.offsetWidth);\n\t\t\t\t\t\tme._thumbnail_menu__content.style.left = -(Math.round((me._thumbnail_menu.ggContentWidth * (1.0 - me._thumbnail_menu.ggHPercentVisible)) * percentScrolled)) + this.ggContentLeftOffset + 'px';\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tme._thumbnail_menu.ggAvailableHeight = me._thumbnail_menu.clientHeight;\n\t\t\t\t\tme._thumbnail_menu.ggScrollPosX = 0;\n\t\t\t\t\tme._thumbnail_menu.ggScrollPosXPercent = 0.0;\n\t\t\t\t}\n\t\t\t\tif(horScrollWasVisible != me._thumbnail_menu.ggHorScrollVisible || vertScrollWasVisible != me._thumbnail_menu.ggVertScrollVisible) {\n\t\t\t\t\tme.updateSize(me._thumbnail_menu);\n\t\t\t\t\tme._thumbnail_menu.ggUpdatePosition();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tel=me._thumbnail_cloner=document.createElement('div');\n\t\tel.ggNumRepeat = 1;\n\t\tel.ggNumRows = 0;\n\t\tel.ggNumCols = 0;\n\t\tel.ggWidth = 96;\n\t\tel.ggHeight = 62;\n\t\tel.ggUpdating = false;\n\t\tel.ggFilter = [];\n\t\tel.ggInstances = [];\n\t\tme._thumbnail_cloner.callChildLogicBlocks_changenode = function(){\n\t\t\tif(me._thumbnail_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._thumbnail_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._thumbnail_cloner.ggInstances[i]._thumbnail_title && me._thumbnail_cloner.ggInstances[i]._thumbnail_title.logicBlock_alpha) {\n\t\t\t\t\t\tme._thumbnail_cloner.ggInstances[i]._thumbnail_title.logicBlock_alpha();\n\t\t\t\t\t}\n\t\t\t\t\tif (me._thumbnail_cloner.ggInstances[i]._checkmark_tick && me._thumbnail_cloner.ggInstances[i]._checkmark_tick.logicBlock_alpha) {\n\t\t\t\t\t\tme._thumbnail_cloner.ggInstances[i]._checkmark_tick.logicBlock_alpha();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._thumbnail_cloner.callChildLogicBlocks_mouseover = function(){\n\t\t\tif(me._thumbnail_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._thumbnail_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._thumbnail_cloner.ggInstances[i]._thumbnail_active && me._thumbnail_cloner.ggInstances[i]._thumbnail_active.logicBlock_bordercolor) {\n\t\t\t\t\t\tme._thumbnail_cloner.ggInstances[i]._thumbnail_active.logicBlock_bordercolor();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._thumbnail_cloner.callChildLogicBlocks_mouseover = function(){\n\t\t\tif(me._thumbnail_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._thumbnail_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._thumbnail_cloner.ggInstances[i]._thumbnail_title && me._thumbnail_cloner.ggInstances[i]._thumbnail_title.logicBlock_alpha) {\n\t\t\t\t\t\tme._thumbnail_cloner.ggInstances[i]._thumbnail_title.logicBlock_alpha();\n\t\t\t\t\t}\n\t\t\t\t\tif (me._thumbnail_cloner.ggInstances[i]._checkmark_tick && me._thumbnail_cloner.ggInstances[i]._checkmark_tick.logicBlock_alpha) {\n\t\t\t\t\t\tme._thumbnail_cloner.ggInstances[i]._checkmark_tick.logicBlock_alpha();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._thumbnail_cloner.callChildLogicBlocks_active = function(){\n\t\t\tif(me._thumbnail_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._thumbnail_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._thumbnail_cloner.ggInstances[i]._thumbnail_active && me._thumbnail_cloner.ggInstances[i]._thumbnail_active.logicBlock_bordercolor) {\n\t\t\t\t\t\tme._thumbnail_cloner.ggInstances[i]._thumbnail_active.logicBlock_bordercolor();\n\t\t\t\t\t}\n\t\t\t\t\tif (me._thumbnail_cloner.ggInstances[i]._checkmark_tick && me._thumbnail_cloner.ggInstances[i]._checkmark_tick.logicBlock_visible) {\n\t\t\t\t\t\tme._thumbnail_cloner.ggInstances[i]._checkmark_tick.logicBlock_visible();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._thumbnail_cloner.callChildLogicBlocks_changevisitednodes = function(){\n\t\t\tif(me._thumbnail_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._thumbnail_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._thumbnail_cloner.ggInstances[i]._checkmark_tick && me._thumbnail_cloner.ggInstances[i]._checkmark_tick.logicBlock_visible) {\n\t\t\t\t\t\tme._thumbnail_cloner.ggInstances[i]._checkmark_tick.logicBlock_visible();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._thumbnail_cloner.callChildLogicBlocks_activehotspotchanged = function(){\n\t\t\tif(me._thumbnail_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._thumbnail_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._thumbnail_cloner.ggInstances[i]._thumbnail_title && me._thumbnail_cloner.ggInstances[i]._thumbnail_title.logicBlock_alpha) {\n\t\t\t\t\t\tme._thumbnail_cloner.ggInstances[i]._thumbnail_title.logicBlock_alpha();\n\t\t\t\t\t}\n\t\t\t\t\tif (me._thumbnail_cloner.ggInstances[i]._checkmark_tick && me._thumbnail_cloner.ggInstances[i]._checkmark_tick.logicBlock_alpha) {\n\t\t\t\t\t\tme._thumbnail_cloner.ggInstances[i]._checkmark_tick.logicBlock_alpha();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._thumbnail_cloner.callChildLogicBlocks_varchanged_opt_thumbnail_menu_tooltip = function(){\n\t\t\tif(me._thumbnail_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._thumbnail_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._thumbnail_cloner.ggInstances[i]._thumbnail_title && me._thumbnail_cloner.ggInstances[i]._thumbnail_title.logicBlock_alpha) {\n\t\t\t\t\t\tme._thumbnail_cloner.ggInstances[i]._thumbnail_title.logicBlock_alpha();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tel.ggUpdate = function(filter) {\n\t\t\tif(me._thumbnail_cloner.ggUpdating == true) return;\n\t\t\tme._thumbnail_cloner.ggUpdating = true;\n\t\t\tvar el=me._thumbnail_cloner;\n\t\t\tvar curNumRows = 0;\n\t\t\tcurNumRows = el.ggNumRepeat;\n\t\t\tif (curNumRows < 1) curNumRows = 1;\n\t\t\tif (typeof filter=='object') {\n\t\t\t\tel.ggFilter = filter;\n\t\t\t} else {\n\t\t\t\tfilter = el.ggFilter;\n\t\t\t};\n\t\t\tif (me.ggTag) filter.push(me.ggTag);\n\t\t\tfilter=filter.sort();\n\t\t\tif ((el.ggNumRows == curNumRows) && (el.ggInstances.length > 0) && (filter.length === el.ggCurrentFilter.length) && (filter.every(function(value, index) { return value === el.ggCurrentFilter[index] }) )) {\n\t\t\t\tme._thumbnail_cloner.ggUpdating = false;\n\t\t\t\treturn;\n\t\t\t} else {\n\t\t\t\tel.ggNumCols = 1;\n\t\t\t\tel.ggNumRows = curNumRows;\n\t\t\t}\n\t\t\tel.ggCurrentFilter = filter;\n\t\t\tel.ggInstances = [];\n\t\t\tif (el.hasChildNodes() == true) {\n\t\t\t\twhile (el.firstChild) {\n\t\t\t\t\tel.removeChild(el.firstChild);\n\t\t\t\t}\n\t\t\t}\n\t\t\tvar tourNodes = player.getNodeIds();\n\t\t\tvar row = 0;\n\t\t\tvar column = 0;\n\t\t\tvar currentIndex = 0;\n\t\t\tfor (var i=0; i < tourNodes.length; i++) {\n\t\t\t\tvar nodeId = tourNodes[i];\n\t\t\t\tvar passed = true;\n\t\t\t\tvar nodeData = player.getNodeUserdata(nodeId);\n\t\t\t\tif (filter.length > 0) {\n\t\t\t\t\tfor (var j=0; j < filter.length; j++) {\n\t\t\t\t\t\tif (nodeData['tags'].indexOf(filter[j]) == -1) passed = false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (passed) {\n\t\t\t\tvar parameter={};\n\t\t\t\tparameter.top=(row * me._thumbnail_cloner.ggHeight) + 'px';\n\t\t\t\tparameter.left=(column * me._thumbnail_cloner.ggWidth) + 'px';\n\t\t\t\tparameter.width=me._thumbnail_cloner.ggWidth + 'px';\n\t\t\t\tparameter.height=me._thumbnail_cloner.ggHeight + 'px';\n\t\t\t\tparameter.index=currentIndex;\n\t\t\t\tparameter.title=nodeData['title'];\n\t\t\t\tvar inst = new SkinCloner_thumbnail_cloner_Class(nodeId, me, el, parameter);\n\t\t\t\tcurrentIndex++;\n\t\t\t\tel.ggInstances.push(inst);\n\t\t\t\tel.appendChild(inst.__div);\n\t\t\t\tinst.__div.ggObj=inst;\n\t\t\t\tskin.updateSize(inst.__div);\n\t\t\t\trow++;\n\t\t\t\tif (row >= el.ggNumRows) {\n\t\t\t\t\trow = 0;\n\t\t\t\t\tcolumn++;\n\t\t\t\t\tel.ggNumCols++;\n\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tme._thumbnail_cloner.callChildLogicBlocks_changenode();\n\t\t\tme._thumbnail_cloner.callChildLogicBlocks_mouseover();\n\t\t\tme._thumbnail_cloner.callChildLogicBlocks_mouseover();\n\t\t\tme._thumbnail_cloner.callChildLogicBlocks_active();\n\t\t\tme._thumbnail_cloner.callChildLogicBlocks_changevisitednodes();\n\t\t\tme._thumbnail_cloner.callChildLogicBlocks_activehotspotchanged();\n\t\t\tme._thumbnail_cloner.callChildLogicBlocks_varchanged_opt_thumbnail_menu_tooltip();\n\t\t\tme._thumbnail_cloner.ggUpdating = false;\n\t\t\tplayer.triggerEvent('clonerchanged');\n\t\t\tif (me._thumbnail_cloner.parentNode.classList.contains('ggskin_subelement') && me._thumbnail_cloner.parentNode.parentNode.classList.contains('ggskin_scrollarea')) me._thumbnail_cloner.parentNode.parentNode.ggUpdatePosition();\n\t\t}\n\t\tel.ggFilter = [];\n\t\tel.ggId=\"thumbnail_cloner\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_cloner \";\n\t\tel.ggType='cloner';\n\t\ths ='';\n\t\ths+='height : 62px;';\n\t\ths+='left : 0px;';\n\t\ths+='overflow : visible;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 96px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._thumbnail_cloner.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._thumbnail_cloner.ggUpdateConditionNodeChange=function () {\n\t\t\tvar cnode=player.getCurrentNode();\n\t\t\tfor(var i=0; i<me._thumbnail_cloner.childNodes.length; i++) {\n\t\t\t\tvar child=me._thumbnail_cloner.childNodes[i];\n\t\t\t\tif (child.ggObj && child.ggObj.ggNodeId==cnode) {\n\t\t\t var childOffX = child.offsetLeft;\n\t\t\t var childOffY = child.offsetTop;\n\t\t\t\t\tvar p = child.parentElement;\n\t\t\t while (p != null && p!==this.divSkin) {\n\t\t\t\t\t\tif (p.ggType && p.ggType == 'scrollarea') {\n\t\t\t\t\t\t\tp.ggScrollIntoView(childOffX, childOffY, child.clientWidth, child.clientHeight);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tchildOffX += p.offsetLeft;\n\t\t\t\t\t\tchildOffY += p.offsetTop;\n\t\t\t\t\t\tp = p.parentElement;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._thumbnail_cloner.ggUpdatePosition=function (useTransition) {\n\t\t\t\tme._thumbnail_cloner.ggUpdate();\n\t\t}\n\t\tme._thumbnail_cloner.ggNodeChange=function () {\n\t\t\tme._thumbnail_cloner.ggUpdateConditionNodeChange();\n\t\t}\n\t\tme._thumbnail_menu__content.appendChild(me._thumbnail_cloner);\n\t\tme.divSkin.appendChild(me._thumbnail_menu);\n\t\tel=me._button_auto_rotate=document.createElement('div');\n\t\tel.ggId=\"button_auto_rotate\";\n\t\tel.ggDx=-54;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='bottom : 28px;';\n\t\ths+='height : 32px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_auto_rotate.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_auto_rotate.onclick=function (e) {\n\t\t\tplayer.toggleAutorotate();\n\t\t}\n\t\tme._button_auto_rotate.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._stop_rotate_image=document.createElement('div');\n\t\tels=me._stop_rotate_image__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZD0iTS0xNzUsMzQwLjljLTMxLDAtNTYuMSwyNS4xLTU2LjEsNTYuMXMyNS4xLDU2LjEsNTYuMSw1Ni4xczU2LjEtMjUuMSw1Ni4xLTU2LjFTLTE0NCwzNDAuOS0xNzUsMzQwLjl6JiN4ZDsmI3hhOyYjeDk7JiN4OTsgTS0xOTYuMSwzNzAuNGM1LjgtNC42LDEzLjEtNy40LDIxLjEtNy40YzcuNywwLDE0LjksMi42LDIwLjYsN2wtNi40LDYuNGMtNC0yLjgtOC45LTQuNC0xNC4yLTQuNGMtNS44LDAtMTEuMSwyLTE1LjMsNS4zJiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuNiwwLjUtMS40LDAuNC0yLTAuMmMtMC41LTAuNS0zLjEtMy41LTQtNC40Qy0xOTYuOSwzNzIt'+\n\t\t\t'MTk2LjgsMzcxLTE5Ni4xLDM3MC40eiBNLTIxNy4yLDM5N2MtMC41LDAtMC44LTAuMi0xLjEtMC43JiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuMy0wLjUtMC4yLTEsMC4xLTEuM2wxMi43LTE3LjhjMC4zLTAuNCwwLjYtMC42LDEuMS0wLjZjMC40LDAsMC43LDAuMiwxLDAuNmwxMi44LDE3LjhjMC4zLDAuNCwwLjQsMC45LDAuMSwxLjMmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC4zLDAuNS0wLjYsMC43LTEuMSwwLjdoLTcuNmgtMC42YzAsNS4yLDEuNywxMC4xLDQuNSwxNC4xbC02LjQsNi40Yy00LjQtNS43LTctMTIuOC03LjEtMjAuNWgtMC41SC0yMTcuMnogTS0yMDcuMiw0MzIuMyYjeGQ7JiN4YT'+\n\t\t\t'smI3g5OyYjeDk7Yy0wLjQsMC0wLjgtMC4xLTEuMS0wLjRsLTEuNy0xLjdjLTAuNi0wLjYtMC42LTEuNiwwLTIuMmw2Ni02NmMwLjMtMC4zLDAuNy0wLjQsMS4xLTAuNHMwLjgsMC4xLDEuMSwwLjRsMS43LDEuNyYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuNiwwLjYsMC42LDEuNiwwLDIuMmwtNjYsNjZDLTIwNi40LDQzMi4yLTIwNi44LDQzMi4zLTIwNy4yLDQzMi4zeiBNLTE1My45LDQyMy4zYy01LjgsNC42LTEzLjEsNy40LTIxLjEsNy40JiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTcuNywwLTE0LjgtMi42LTIwLjUtNi45bDYuNC02LjRjNCwyLjcsOC44LDQuMywxNCw0LjNjNS44LDAsMTEuMS0yLDE1'+\n\t\t\t'LjMtNS4zYzAuNi0wLjUsMS40LTAuNCwyLDAuMmMwLjUsMC41LDMuMSwzLjUsNCw0LjQmI3hkOyYjeGE7JiN4OTsmI3g5O0MtMTUzLjEsNDIxLjgtMTUzLjIsNDIyLjgtMTUzLjksNDIzLjN6IE0tMTQ0LjUsNDE2LjljLTAuMywwLjQtMC42LDAuNi0xLjEsMC42Yy0wLjQsMC0wLjctMC4yLTEtMC42bC0xMi44LTE3LjgmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC4zLTAuNC0wLjQtMC45LTAuMS0xLjNjMC4zLTAuNSwwLjYtMC43LDEuMS0wLjdoNy42aDAuN2MwLTUuMy0xLjYtMTAuMS00LjQtMTQuMmw2LjQtNi40YzQuNCw1LjcsNywxMi45LDcsMjAuNmgwLjVoNy43JiN4ZDsmI3hhOyYjeDk7JiN4OT'+\n\t\t\t'tjMC41LDAsMC44LDAuMiwxLjEsMC43YzAuMywwLjUsMC4yLDEtMC4xLDEuM0wtMTQ0LjUsNDE2Ljl6IiBmaWxsPSIjMDAwMDAwIi8+CiA8L2c+CiA8ZyBpZD0iTGF5ZXJfMiI+CiAgPHBhdGggZD0iTS0xNDIuOCwzNjEuN2MwLjQsMCwwLjgsMC4xLDEuMSwwLjRsMS43LDEuN2MwLjYsMC42LDAuNiwxLjYsMCwyLjJsLTY2LDY2Yy0wLjMsMC4zLTAuNywwLjQtMS4xLDAuNCYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjQsMC0wLjgtMC4xLTEuMS0wLjRsLTEuNy0xLjdjLTAuNi0wLjYtMC42LTEuNiwwLTIuMmw2Ni02NkMtMTQzLjYsMzYxLjgtMTQzLjIsMzYxLjctMTQyLjgsMzYxLjciIGZpbGw9IiNG'+\n\t\t\t'RkZGRkYiLz4KICA8Zz4KICAgPHBhdGggZD0iTS0xOTIuMywzNzcuMWMwLjYsMC42LDEuNCwwLjYsMiwwLjJjNC4yLTMuMyw5LjUtNS4zLDE1LjMtNS4zYzUuMywwLDEwLjEsMS42LDE0LjIsNC40bDYuNC02LjQmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy01LjctNC40LTEyLjktNy0yMC42LTdjLTgsMC0xNS4zLDIuOC0yMS4xLDcuNGMtMC43LDAuNS0wLjgsMS42LTAuMSwyLjNDLTE5NS40LDM3My43LTE5Mi44LDM3Ni42LTE5Mi4zLDM3Ny4xeiIgZmlsbD0iI0ZGRkZGRiIvPgogICA8cGF0aCBkPSJNLTEzMS43LDM5Ny43Yy0wLjMtMC41LTAuNi0wLjctMS4xLTAuN2gtNy43aC0wLjVjMC03Lj'+\n\t\t\t'ctMi42LTE0LjktNy0yMC42bC02LjQsNi40YzIuOCw0LDQuNCw4LjksNC40LDE0LjImI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7aC0wLjdoLTcuNmMtMC41LDAtMC44LDAuMi0xLjEsMC43Yy0wLjMsMC41LTAuMiwxLDAuMSwxLjNsMTIuOCwxNy44YzAuMywwLjQsMC42LDAuNiwxLDAuNmMwLjUsMCwwLjgtMC4yLDEuMS0wLjZsMTIuNy0xNy44JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0MtMTMxLjUsMzk4LjYtMTMxLjQsMzk4LjItMTMxLjcsMzk3Ljd6IiBmaWxsPSIjRkZGRkZGIi8+CiAgPC9nPgogIDxnPgogICA8cGF0aCBkPSJNLTIwOSwzOTdjMC4xLDcuNywyLjcsMTQuOCw3LjEsMjAuNWw2'+\n\t\t\t'LjQtNi40Yy0yLjgtNC00LjUtOC44LTQuNS0xNC4xaDAuNmg3LjZjMC41LDAsMC44LTAuMiwxLjEtMC43JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjMtMC41LDAuMi0xLTAuMS0xLjNsLTEyLjgtMTcuOGMtMC4zLTAuNC0wLjYtMC42LTEtMC42Yy0wLjUsMC0wLjgsMC4yLTEuMSwwLjZsLTEyLjcsMTcuOGMtMC4zLDAuNC0wLjQsMC45LTAuMSwxLjMmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuMywwLjUsMC42LDAuNywxLjEsMC43aDcuN0gtMjA5eiIgZmlsbD0iI0ZGRkZGRiIvPgogICA8cGF0aCBkPSJNLTE1Ny43LDQxNi42Yy0wLjYtMC42LTEuNC0wLjYtMi0wLjJjLTQuMiwzLjMtOS'+\n\t\t\t'41LDUuMy0xNS4zLDUuM2MtNS4yLDAtMTAtMS42LTE0LTQuM2wtNi40LDYuNCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjNS43LDQuMywxMi44LDYuOSwyMC41LDYuOWM4LDAsMTUuMy0yLjgsMjEuMS03LjRjMC43LTAuNSwwLjgtMS42LDAuMS0yLjNDLTE1NC42LDQyMC4xLTE1Ny4yLDQxNy4xLTE1Ny43LDQxNi42eiIgZmlsbD0iI0ZGRkZGRiIvPgogIDwvZz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._stop_rotate_image__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._stop_rotate_image__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZD0iTS0xNzUsMzM0LjZjLTM0LjQsMC02Mi40LDI3LjktNjIuNCw2Mi40czI3LjksNjIuNCw2Mi40LDYyLjRzNjIuNC0yNy45LDYyLjQtNjIuNFMtMTQwLjYsMzM0LjYtMTc1LDMzNC42eiYjeGQ7JiN4YTsmI3g5OyYjeDk7IE0tMTk4LjUsMzY3LjVjNi40LTUuMSwxNC42LTguMiwyMy41LTguMmM4LjYsMCwxNi41LDIuOSwyMi45LDcuOGwtNy4yLDcuMmMtNC41LTMuMS05LjktNC45LTE1LjctNC45Yy02LjQsMC0xMi4zLDIuMi0xNyw1LjkmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC43LDAuNS0xLjYsMC40LTIuMi0wLjJjLTAuNi0wLjYtMy41LTMuOC00LjQtNC45'+\n\t\t\t'Qy0xOTkuMywzNjkuMi0xOTkuMywzNjguMS0xOTguNSwzNjcuNXogTS0yMjEuOSwzOTdjLTAuNSwwLTAuOS0wLjItMS4yLTAuNyYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjMtMC41LTAuMi0xLjEsMC4xLTEuNWwxNC4xLTE5LjhjMC4zLTAuNCwwLjYtMC42LDEuMi0wLjZjMC40LDAsMC43LDAuMiwxLjEsMC42bDE0LjIsMTkuOGMwLjMsMC40LDAuNCwxLDAuMSwxLjUmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC4zLDAuNS0wLjYsMC43LTEuMiwwLjdoLTguNWgtMC43YzAuMSw1LjgsMS45LDExLjIsNSwxNS42bC03LjEsNy4xYy00LjktNi4zLTcuOC0xNC4yLTcuOS0yMi44aC0wLjZILTIyMS45eiBNLT'+\n\t\t\t'IxMC43LDQzNi4zJiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuNCwwLTAuOS0wLjItMS4yLTAuNWwtMS44LTEuOGMtMC43LTAuNy0wLjctMS43LDAtMi40bDczLjMtNzMuM2MwLjMtMC4zLDAuOC0wLjUsMS4yLTAuNXMwLjksMC4yLDEuMiwwLjVsMS44LDEuOCYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuNywwLjcsMC43LDEuNywwLDIuNGwtNzMuMyw3My4zQy0yMDkuOSw0MzYuMS0yMTAuMyw0MzYuMy0yMTAuNyw0MzYuM3ogTS0xNTEuNSw0MjYuM2MtNi40LDUuMS0xNC42LDguMi0yMy41LDguMiYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy04LjUsMC0xNi40LTIuOS0yMi44LTcuN2w3LjItNy4yYzQuNCwzLDku'+\n\t\t\t'OCw0LjgsMTUuNiw0LjhjNi40LDAsMTIuMy0yLjIsMTctNS45YzAuNy0wLjUsMS42LTAuNCwyLjIsMC4yYzAuNiwwLjYsMy41LDMuOCw0LjQsNC45JiN4ZDsmI3hhOyYjeDk7JiN4OTtDLTE1MC43LDQyNC41LTE1MC43LDQyNS43LTE1MS41LDQyNi4zeiBNLTE0MS4xLDQxOS4xYy0wLjMsMC40LTAuNiwwLjYtMS4yLDAuNmMtMC40LDAtMC43LTAuMi0xLjEtMC42bC0xNC4yLTE5LjgmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC4zLTAuNC0wLjQtMS0wLjEtMS41YzAuMy0wLjUsMC42LTAuNywxLjItMC43aDguNGgwLjdjMC01LjgtMS44LTExLjMtNC45LTE1LjdsNy4yLTcuMmM0LjksNi40LDcuOCwxNC'+\n\t\t\t'4zLDcuOCwyMi45aDAuNmg4LjYmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjUsMCwwLjksMC4yLDEuMiwwLjdjMC4zLDAuNSwwLjIsMS4xLTAuMSwxLjVMLTE0MS4xLDQxOS4xeiIgZmlsbD0iIzAwMDAwMCIvPgogPC9nPgogPGcgaWQ9IkxheWVyXzIiPgogIDxwYXRoIGQ9Ik0tMTM5LjMsMzU3LjdjMC40LDAsMC45LDAuMiwxLjIsMC41bDEuOCwxLjhjMC43LDAuNywwLjcsMS43LDAsMi40bC03My4zLDczLjNjLTAuMywwLjMtMC44LDAuNS0xLjIsMC41JiN4ZDsmI3hhOyYjeDk7JiN4OTtzLTAuOS0wLjItMS4yLTAuNWwtMS44LTEuOGMtMC43LTAuNy0wLjctMS43LDAtMi40bDczLjMtNzMuM0MtMTQw'+\n\t\t\t'LjEsMzU3LjktMTM5LjcsMzU3LjctMTM5LjMsMzU3LjciIGZpbGw9IiNGRkZGRkYiLz4KICA8Zz4KICAgPHBhdGggZD0iTS0xOTQuMiwzNzQuOWMwLjYsMC42LDEuNSwwLjcsMi4yLDAuMmM0LjctMy43LDEwLjYtNS45LDE3LTUuOWM1LjgsMCwxMS4zLDEuOCwxNS43LDQuOWw3LjItNy4yJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MtNi40LTQuOS0xNC4zLTcuOC0yMi45LTcuOGMtOC45LDAtMTcsMy4xLTIzLjUsOC4yYy0wLjgsMC42LTAuOCwxLjgtMC4yLDIuNkMtMTk3LjcsMzcxLjEtMTk0LjgsMzc0LjQtMTk0LjIsMzc0Ljl6IiBmaWxsPSIjRkZGRkZGIi8+CiAgIDxwYXRoIGQ9Ik0tMTI2Lj'+\n\t\t\t'ksMzk3LjdjLTAuMy0wLjUtMC42LTAuNy0xLjItMC43aC04LjZoLTAuNmMwLTguNi0yLjktMTYuNS03LjgtMjIuOWwtNy4yLDcuMiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMy4xLDQuNSw0LjksOS45LDQuOSwxNS43aC0wLjdoLTguNGMtMC41LDAtMC45LDAuMi0xLjIsMC43Yy0wLjMsMC41LTAuMiwxLjEsMC4xLDEuNWwxNC4yLDE5LjhjMC4zLDAuNCwwLjYsMC42LDEuMSwwLjYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuNSwwLDAuOS0wLjIsMS4yLTAuNmwxNC4xLTE5LjhDLTEyNi43LDM5OC44LTEyNi42LDM5OC4zLTEyNi45LDM5Ny43eiIgZmlsbD0iI0ZGRkZGRiIvPgogIDwvZz4K'+\n\t\t\t'ICA8Zz4KICAgPHBhdGggZD0iTS0yMTIuNywzOTdjMC4xLDguNiwzLDE2LjUsNy45LDIyLjhsNy4xLTcuMWMtMy4xLTQuNC01LTkuOC01LTE1LjZoMC43aDguNWMwLjUsMCwwLjktMC4yLDEuMi0wLjcmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuMy0wLjUsMC4yLTEuMS0wLjEtMS41bC0xNC4yLTE5LjhjLTAuMy0wLjQtMC42LTAuNi0xLjEtMC42Yy0wLjUsMC0wLjksMC4yLTEuMiwwLjZsLTE0LjEsMTkuOGMtMC4zLDAuNC0wLjQsMS0wLjEsMS41JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjMsMC41LDAuNiwwLjcsMS4yLDAuN2g4LjZILTIxMi43eiIgZmlsbD0iI0ZGRkZGRiIvPgogIC'+\n\t\t\t'A8cGF0aCBkPSJNLTE1NS44LDQxOC44Yy0wLjYtMC42LTEuNS0wLjctMi4yLTAuMmMtNC43LDMuNy0xMC42LDUuOS0xNyw1LjljLTUuOCwwLTExLjEtMS44LTE1LjYtNC44bC03LjIsNy4yJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2M2LjMsNC44LDE0LjIsNy43LDIyLjgsNy43YzguOSwwLDE3LTMuMSwyMy41LTguMmMwLjgtMC42LDAuOC0xLjgsMC4yLTIuNkMtMTUyLjMsNDIyLjYtMTU1LjIsNDE5LjQtMTU1LjgsNDE4Ljh6IiBmaWxsPSIjRkZGRkZGIi8+CiAgPC9nPgogPC9nPgo8L3N2Zz4K';\n\t\tme._stop_rotate_image__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"stop_rotate_image\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._stop_rotate_image.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._stop_rotate_image.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getIsAutorotating() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._stop_rotate_image.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._stop_rotate_image.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._stop_rotate_image.style[domTransition]='';\n\t\t\t\tif (me._stop_rotate_image.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._stop_rotate_image.style.visibility=(Number(me._stop_rotate_image.style.opacity)>0||!me._stop_rotate_image.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._stop_rotate_image.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._stop_rotate_image.style.visibility=\"hidden\";\n\t\t\t\t\tme._stop_rotate_image.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._stop_rotate_image.onmouseover=function (e) {\n\t\t\tme._stop_rotate_image__img.style.visibility='hidden';\n\t\t\tme._stop_rotate_image__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._stop_rotate_image.onmouseout=function (e) {\n\t\t\tme._stop_rotate_image__img.style.visibility='inherit';\n\t\t\tme._stop_rotate_image__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._stop_rotate_image.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._button_auto_rotate.appendChild(me._stop_rotate_image);\n\t\tel=me._start_rotate_image=document.createElement('div');\n\t\tels=me._start_rotate_image__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZD0iTS0xNzUsMzQwLjljLTMxLDAtNTYuMSwyNS4xLTU2LjEsNTYuMXMyNS4xLDU2LjEsNTYuMSw1Ni4xYzMxLDAsNTYuMS0yNS4xLDU2LjEtNTYuMVMtMTQ0LDM0MC45LTE3NSwzNDAuOSYjeGQ7JiN4YTsmI3g5OyYjeDk7eiBNLTE1My45LDQyMy42Yy01LjgsNC42LTEzLjEsNy40LTIxLjEsNy40aDBjLTE4LjcsMC0zNC0xNS4yLTM0LTM0aC0wLjVoLTcuN2MtMC41LDAtMC44LTAuMi0xLjEtMC43Yy0wLjMtMC41LTAuMi0xLDAuMS0xLjMmI3hkOyYjeGE7JiN4OTsmI3g5O2wxMi43LTE3LjhjMC4zLTAuNCwwLjYtMC42LDEuMS0wLjZjMC40LDAsMC43LDAuMiwx'+\n\t\t\t'LDAuNmwxMi44LDE3LjhjMC4zLDAuNCwwLjQsMC45LDAuMSwxLjNjLTAuMywwLjUtMC42LDAuNy0xLjEsMC43aC03LjZoLTAuNyYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAsMTMuOCwxMS4yLDI1LDI1LDI1aDBjNS44LDAsMTEuMS0yLDE1LjMtNS4zYzAuNi0wLjUsMS40LTAuNCwyLDAuMmMwLjUsMC41LDMuMSwzLjUsNCw0LjRDLTE1My4xLDQyMi0xNTMuMiw0MjMuMS0xNTMuOSw0MjMuNnomI3hkOyYjeGE7JiN4OTsmI3g5OyBNLTE3OSwzOTdjMC0yLjIsMS44LTQsNC00YzIuMiwwLDQsMS44LDQsNGMwLDIuMi0xLjgsNC00LDRDLTE3Ny4yLDQwMS0xNzksMzk5LjItMTc5LDM5N3ogTS0xNDQuNSw0MT'+\n\t\t\t'YuOSYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjMsMC40LTAuNiwwLjYtMS4xLDAuNmMtMC40LDAtMC43LTAuMi0xLTAuNmwtMTIuOC0xNy44Yy0wLjMtMC40LTAuNC0wLjktMC4xLTEuM2MwLjMtMC41LDAuNi0wLjcsMS4xLTAuN2g3LjZoMC43JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC0xMy44LTExLjItMjUtMjUtMjVoMGMtNS44LDAtMTEuMSwyLTE1LjMsNS4zYy0wLjYsMC41LTEuNCwwLjQtMi0wLjJjLTAuNS0wLjUtMy4xLTMuNS00LTQuNGMtMC42LTAuNy0wLjYtMS44LDAuMS0yLjMmI3hkOyYjeGE7JiN4OTsmI3g5O2M1LjgtNC42LDEzLjEtNy40LDIxLjEtNy40aDBjMTguNywwLDM0LDE1LjIs'+\n\t\t\t'MzQsMzRoMC41aDcuN2MwLjUsMCwwLjgsMC4yLDEuMSwwLjdjMC4zLDAuNSwwLjIsMS0wLjEsMS4zTC0xNDQuNSw0MTYuOXoiIGZpbGw9IiMwMDAwMDAiLz4KIDwvZz4KIDxnIGlkPSJMYXllcl8yIj4KICA8cGF0aCBkPSJNLTE1My43LDQyMS4zYy0wLjgtMC45LTMuNS0zLjktNC00LjRjLTAuNi0wLjYtMS40LTAuNi0yLTAuMmMtNC4yLDMuMy05LjUsNS4zLTE1LjMsNS4zaDAmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMTMuOCwwLTI1LTExLjItMjUtMjVoMC43aDcuNmMwLjUsMCwwLjgtMC4yLDEuMS0wLjdjMC4zLTAuNSwwLjItMS0wLjEtMS4zbC0xMi44LTE3LjhjLTAuMy0wLjQtMC42LTAuNi0xLT'+\n\t\t\t'AuNiYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjUsMC0wLjgsMC4yLTEuMSwwLjZsLTEyLjcsMTcuOGMtMC4zLDAuNC0wLjQsMC45LTAuMSwxLjNjMC4zLDAuNSwwLjYsMC43LDEuMSwwLjdoNy43aDAuNWMwLDE4LjcsMTUuMiwzNCwzNCwzNGgwJiN4ZDsmI3hhOyYjeDk7JiN4OTtjOCwwLDE1LjMtMi44LDIxLjEtNy40Qy0xNTMuMiw0MjMuMS0xNTMuMSw0MjItMTUzLjcsNDIxLjN6IiBmaWxsPSIjRkZGRkZGIi8+CiAgPHBhdGggZD0iTS0xMzEuNywzOTcuN2MtMC4zLTAuNS0wLjYtMC43LTEuMS0wLjdoLTcuN2gtMC41YzAtMTguNy0xNS4yLTM0LTM0LTM0aDBjLTgsMC0xNS4zLDIuOC0yMS4xLDcu'+\n\t\t\t'NCYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjcsMC41LTAuOCwxLjYtMC4xLDIuM2MwLjgsMC45LDMuNSwzLjksNCw0LjRjMC42LDAuNiwxLjQsMC42LDIsMC4yYzQuMi0zLjMsOS41LTUuMywxNS4zLTUuM2gwYzEzLjgsMCwyNSwxMS4yLDI1LDI1aC0wLjcmI3hkOyYjeGE7JiN4OTsmI3g5O2gtNy42Yy0wLjUsMC0wLjgsMC4yLTEuMSwwLjdjLTAuMywwLjUtMC4yLDEsMC4xLDEuM2wxMi44LDE3LjhjMC4zLDAuNCwwLjYsMC42LDEsMC42YzAuNSwwLDAuOC0wLjIsMS4xLTAuNmwxMi43LTE3LjgmI3hkOyYjeGE7JiN4OTsmI3g5O0MtMTMxLjUsMzk4LjctMTMxLjQsMzk4LjItMTMxLjcsMzk3Ljd6Ii'+\n\t\t\t'BmaWxsPSIjRkZGRkZGIi8+CiAgPGNpcmNsZSByPSI0IiBjeD0iLTE3NSIgY3k9IjM5NyIgZmlsbD0iI0ZGRkZGRiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._start_rotate_image__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._start_rotate_image__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGlkPSJMYXllcl8xIiB2ZXJzaW9uPSIxLjEiIHg9IjBweCIgeT0iMHB4IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZD0iTS0xNzUsMzM0LjdjLTM0LjQsMC02Mi40LDI3LjktNjIuNCw2Mi40czI3LjksNjIuNCw2Mi40LDYyLjRjMzQuNCwwLDYyLjQtMjcuOSw2Mi40LTYyLjQmI3hkOyYjeGE7JiN4OTsmI3g5O1MtMTQwLjYsMzM0LjctMTc1LDMzNC43eiBNLTE1MS41LDQyNi42Yy02LjQsNS4xLTE0LjYsOC4yLTIzLjUsOC4yaDBjLTIwLjgsMC0zNy43LTE2LjktMzcuNy0zNy43aC0wLjZoLTguNiYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjUsMC0wLjktMC4yLTEuMi0wLjdjLTAuMy0wLjUtMC4yLTEuMSwwLjEtMS41bDE0LjEtMTkuOGMwLjMtMC40LDAuNi0wLjYsMS4yLTAuNmMw'+\n\t\t\t'LjQsMCwwLjcsMC4yLDEuMSwwLjZsMTQuMiwxOS44JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4zLDAuNCwwLjQsMSwwLjEsMS41Yy0wLjMsMC41LTAuNiwwLjctMS4yLDAuN2gtOC40aC0wLjdjMCwxNS4zLDEyLjQsMjcuNywyNy43LDI3LjdoMGM2LjQsMCwxMi4zLTIuMiwxNy01LjkmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjctMC41LDEuNi0wLjQsMi4yLDAuMmMwLjYsMC42LDMuNSwzLjgsNC40LDQuOUMtMTUwLjcsNDI0LjgtMTUwLjcsNDI2LTE1MS41LDQyNi42eiBNLTE3OS40LDM5N2MwLTIuNCwyLTQuNCw0LjQtNC40JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMi40LDAsNC40LDIsNC40LDQuNGMwLD'+\n\t\t\t'IuNC0yLDQuNC00LjQsNC40Qy0xNzcuNCw0MDEuNC0xNzkuNCwzOTkuNS0xNzkuNCwzOTd6IE0tMTQxLjEsNDE5LjFjLTAuMywwLjQtMC42LDAuNi0xLjIsMC42JiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuNCwwLTAuNy0wLjItMS4xLTAuNmwtMTQuMi0xOS44Yy0wLjMtMC40LTAuNC0xLTAuMS0xLjVjMC4zLTAuNSwwLjYtMC43LDEuMi0wLjdoOC40aDAuN2MwLTE1LjMtMTIuNC0yNy43LTI3LjctMjcuN2gwJiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTYuNCwwLTEyLjMsMi4yLTE3LDUuOWMtMC43LDAuNS0xLjYsMC40LTIuMi0wLjJjLTAuNi0wLjYtMy41LTMuOC00LjQtNC45Yy0wLjctMC44LTAuNi0y'+\n\t\t\t'LDAuMi0yLjZjNi40LTUuMSwxNC42LTguMiwyMy41LTguMmgwJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMjAuOCwwLDM3LjcsMTYuOSwzNy43LDM3LjdoMC42aDguNmMwLjUsMCwwLjksMC4yLDEuMiwwLjdjMC4zLDAuNSwwLjIsMS4xLTAuMSwxLjVMLTE0MS4xLDQxOS4xeiIgZmlsbD0iIzAwMDAwMCIvPgogPC9nPgogPGcgaWQ9IkxheWVyXzIiPgogIDxwYXRoIGQ9Ik0tMTUxLjQsNDI0Yy0wLjktMS0zLjktNC4zLTQuNC00LjljLTAuNi0wLjYtMS41LTAuNy0yLjItMC4yYy00LjcsMy43LTEwLjYsNS45LTE3LDUuOWgwJiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTE1LjMsMC0yNy43LTEyLjQtMjcuNy0yNy'+\n\t\t\t'43aDAuN2g4LjRjMC41LDAsMC45LTAuMiwxLjItMC43czAuMi0xLjEtMC4xLTEuNWwtMTQuMi0xOS44Yy0wLjMtMC40LTAuNi0wLjYtMS4xLTAuNiYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjUsMC0wLjksMC4yLTEuMiwwLjZsLTE0LjEsMTkuOGMtMC4zLDAuNC0wLjQsMS0wLjEsMS41YzAuMywwLjUsMC42LDAuNywxLjIsMC43aDguNmgwLjZjMCwyMC44LDE2LjksMzcuNywzNy43LDM3LjdoMCYjeGQ7JiN4YTsmI3g5OyYjeDk7YzguOSwwLDE3LTMuMSwyMy41LTguMkMtMTUwLjcsNDI2LTE1MC43LDQyNC44LTE1MS40LDQyNHoiIGZpbGw9IiNGRkZGRkYiLz4KICA8cGF0aCBkPSJNLTEyNi45LDM5'+\n\t\t\t'Ny44Yy0wLjMtMC41LTAuNi0wLjctMS4yLTAuN2gtOC42aC0wLjZjMC0yMC44LTE2LjktMzcuNy0zNy43LTM3LjdoMGMtOC45LDAtMTcsMy4xLTIzLjUsOC4yJiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuOCwwLjYtMC44LDEuOC0wLjIsMi42YzAuOSwxLDMuOSw0LjMsNC40LDQuOWMwLjYsMC42LDEuNSwwLjcsMi4yLDAuMmM0LjctMy43LDEwLjYtNS45LDE3LTUuOWgwYzE1LjMsMCwyNy43LDEyLjQsMjcuNywyNy43JiN4ZDsmI3hhOyYjeDk7JiN4OTtoLTAuN2gtOC40Yy0wLjUsMC0wLjksMC4yLTEuMiwwLjdjLTAuMywwLjUtMC4yLDEuMSwwLjEsMS41bDE0LjIsMTkuOGMwLjMsMC40LDAuNiwwLj'+\n\t\t\t'YsMS4xLDAuNmMwLjUsMCwwLjktMC4yLDEuMi0wLjZsMTQuMS0xOS44JiN4ZDsmI3hhOyYjeDk7JiN4OTtDLTEyNi43LDM5OC45LTEyNi42LDM5OC4zLTEyNi45LDM5Ny44eiIgZmlsbD0iI0ZGRkZGRiIvPgogIDxjaXJjbGUgcj0iNC40IiBjeD0iLTE3NSIgY3k9IjM5NyIgZmlsbD0iI0ZGRkZGRiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._start_rotate_image__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"start_rotate_image\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._start_rotate_image.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._start_rotate_image.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getIsAutorotating() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._start_rotate_image.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._start_rotate_image.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._start_rotate_image.style[domTransition]='';\n\t\t\t\tif (me._start_rotate_image.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._start_rotate_image.style.visibility=\"hidden\";\n\t\t\t\t\tme._start_rotate_image.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._start_rotate_image.style.visibility=(Number(me._start_rotate_image.style.opacity)>0||!me._start_rotate_image.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._start_rotate_image.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._start_rotate_image.onmouseover=function (e) {\n\t\t\tme._start_rotate_image__img.style.visibility='hidden';\n\t\t\tme._start_rotate_image__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._start_rotate_image.onmouseout=function (e) {\n\t\t\tme._start_rotate_image__img.style.visibility='inherit';\n\t\t\tme._start_rotate_image__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._start_rotate_image.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._button_auto_rotate.appendChild(me._start_rotate_image);\n\t\tme.divSkin.appendChild(me._button_auto_rotate);\n\t\tme._map_1.ggMarkerInstances=[];\n\t\tme._map_1.ggMapId = 'googlehybrid';\n\t\tme._map_1.ggLastNodeId=null;\n\t\tme._map_1.ggMarkerArray=[];\n\t\tme._map_1.ggGoogleMarkerArray=[];\n\t\tme._map_1.ggLastZoom = -1;\n\t\tme._map_1.ggRadar={ lastFov : -1, lastPan : -1, lastZoom : -1,activeNodeLatLng : null, poly : null }\n\t\tme._map_1.ggRadar.update=function() {\n\t\t\tif ((typeof google !== 'object') || (typeof google.maps !== 'object')) return;\n\t\t\tvar radar=me._map_1.ggRadar;\n\t\t\tvar map=me._map_1.ggMap;\n\t\t\tif (!map) return;\n\t\t\tvar d2r = Math.PI/180 ;\n\t\t\tvar r2d = 180/Math.PI ;\n\t\t\tvar fov = player.getFov();\n\t\t\tvar pan = player.getPanNorth();\n\t\t\tvar zoom = map.getZoom();\n\t\t\tvar gps;\n\t\t\tif (player.getMapType(me._map_1.ggMapId) == 'web') {\n\t\t\t\tgps=player.getNodeLatLng();\n\t\t\t} else {\n\t\t\t\tgps=player.getNodeMapCoords(null, me._map_1.ggMapId);\n\t\t\t\tpan -= me._map_1.ggFloorplanNorth;\n\t\t\t}\n\t\t\tvar filterpassed = true;\n\t\t\tvar currentId = player.getCurrentNode();\n\t\t\tif (me._map_1.ggFilteredIds.length > 0 && me._map_1.ggFilteredIds.indexOf(currentId) == -1) filterpassed = false;\n\t\t\tif ((gps.length>=2) && ((gps[0]!=0) || (gps[1]!=0)) && filterpassed) {\n\t\t\t\tif (zoom<6) zoom = 6; // avoid large radar beams on world map\n\t\t\t\tif ((radar.poly) && (fov==radar.lastFov) && (pan==radar.lastPan) && (zoom==radar.lastZoom) && (gps[0]==radar.activeNodeLatLng.lat()) && (gps[1]==radar.activeNodeLatLng.lng())) return; \n\t\t\t\tradar.lastPan=pan;radar.lastFov=fov;radar.lastZoom=zoom;\n\t\t\t\tradar.activeNodeLatLng = new google.maps.LatLng(gps[0], gps[1]);\n\t\t\t\tvar tileDeg = 360.0 / Math.pow(2, zoom);\n\t\t\t\tvar rLng = tileDeg * 0.976563;\n\t\t\t\tvar rLat = rLng * Math.cos(radar.activeNodeLatLng.lat() * d2r);\n\t\t\t\tvar radar_path = [];\n\t\t\t\tradar_path.push(radar.activeNodeLatLng);\n\t\t\t\tvar segments=5;\n\t\t\t\tfor (i=-segments; i<=segments; i++) {\n\t\t\t\t\tvar angle = (fov / (2*segments)) * i;\n\t\t\t\t\tvar x = -rLng * Math.sin((pan+angle)*d2r) + radar.activeNodeLatLng.lng();\n\t\t\t\t\tvar y = rLat * Math.cos((pan+angle)*d2r) + radar.activeNodeLatLng.lat();\n\t\t\t\t\tradar_path.push(new google.maps.LatLng(y, x));\n\t\t\t\t}\n\t\t\t\tif (radar.poly) {\n\t\t\t\t\tradar.poly.setMap(null);\n\t\t\t\t\tradar.poly = null;\n\t\t\t\t}\n\t\t\t\tradar.poly = new google.maps.Polygon({\n\t\t\t\t\tpaths: radar_path,\n\t\t\t\t\tstrokeColor: '#55007f',\n\t\t\t\t\tstrokeOpacity: 0.8,\n\t\t\t\t\tstrokeWeight: 1,\n\t\t\t\t\tfillColor: '#55007f',\n\t\t\t\t\tfillOpacity: 0.35\n\t\t\t\t});\n\t\t\t\tradar.poly.setMap(map);\n\t\t\t} else {\n\t\t\t\tif (radar) {\n\t\t\t\t\tactiveNodeLatLng = new google.maps.LatLng(0,0);\n\t\t\t\t\tif (radar.poly) {\n\t\t\t\t\t\tradar.poly.setMap(null);\n\t\t\t\t\t\tradar.poly = null;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map_1.ggTileAvailable=function(x, y, z) {\n\t\t\tvar mapDetails = player.getMapDetails(me._map_1.ggMapId);\n\t\t\tif (z < 7 || z > 7 + (mapDetails['zoomlevels'] - 1)) return false;\n\t\t\tvar mapAR = mapDetails['width'] / mapDetails['height'];\n\t\t\tif (mapDetails['width'] >= mapDetails['height']) {\n\t\t\tvar tilesInX = Math.pow(2, z - 7);\n\t\t\tvar tilesInY = Math.ceil(tilesInX / mapAR);\n\t\t\t} else {\n\t\t\t\tvar tilesInY = Math.pow(2, z - 7);\n\t\t\t\tvar tilesInX = Math.ceil(tilesInY * mapAR);\n\t\t\t}\n\t\t\tvar tilesXStart = Math.pow(2, z - 1);\n\t\t\tvar tilesYStart = tilesXStart;\n\t\t\tvar tilesXEnd = tilesXStart + tilesInX - 1;\n\t\t\tvar tilesYEnd = tilesYStart + tilesInY - 1;\n\t\t\tif (x < tilesXStart || x > tilesXEnd || y < tilesYStart || y > tilesYEnd) return false;\n\t\t\treturn true;\n\t\t}\n\t\tme._map_1.ggInitMap=function(keepZoom) {\n\t\t\tme._map_1.ggMapNotLoaded = false;\n\t\t\tvar mapType = player.getMapType(me._map_1.ggMapId);\n\t\t\tvar mapDetails = player.getMapDetails(me._map_1.ggMapId);\n\t\t\tif (!me._map_1.ggMapId.startsWith('google') && Object.keys(mapDetails).length === 0) return;\n\t\t\tif (mapType == 'file') {\n\t\t\t\tme._map_1.style.backgroundColor = mapDetails['bgcolor'];\n\t\t\t\tme._map_1.ggFloorplanNorth = mapDetails['floorplannorth'];\n\t\t\t} else {\n\t\t\t\tme._map_1.style.backgroundColor = '#fff';\n\t\t\t}\n\t\t\tvar gps;\n\t\t\tif (player.getMapType(me._map_1.ggMapId) == 'web') {\n\t\t\t\tgps=player.getNodeLatLng();\n\t\t\t} else {\n\t\t\t\tgps=player.getNodeMapCoords(null, me._map_1.ggMapId);\n\t\t\t}\n\t\t\tif ((typeof google !== 'object') || (typeof google.maps !== 'object')) return;\n\t\t\tif ((gps.length>=2) && ((gps[0]!=0) || (gps[1]!=0))) {\n\t\t\t\tactiveNodeLatLng = new google.maps.LatLng(gps[0], gps[1]);\n\t\t\t} else {\n\t\t\t\tactiveNodeLatLng = new google.maps.LatLng(0,0);\n\t\t\t}\n\t\t\tif (mapType == 'web') {\n\t\t\t\tvar mapTypeId;\n\t\t\t\tif (me._map_1.ggMapId == 'googleroadmap') {\n\t\t\t\t\tmapTypeId = google.maps.MapTypeId.ROADMAP;\n\t\t\t\t} else if (me._map_1.ggMapId == 'googlehybrid') {\n\t\t\t\t\tmapTypeId = google.maps.MapTypeId.HYBRID;\n\t\t\t\t} else if (me._map_1.ggMapId == 'googlesatellite') {\n\t\t\t\t\tmapTypeId = google.maps.MapTypeId.SATELLITE;\n\t\t\t\t} else if (me._map_1.ggMapId == 'googleterrain') {\n\t\t\t\t\tmapTypeId = google.maps.MapTypeId.TERRAIN;\n\t\t\t\t} else {\n\t\t\t\t\tmapTypeId = mapDetails['mapprovider'];\n\t\t\t\t}\n\t\t\t\tif (me._map_1.ggLastZoom == -1) me._map_1.ggLastZoom = 14;\n\t\t\t\tvar initZoom = keepZoom ? me._map_1.ggLastZoom : 14;\n\t\t\t\tvar mapOptions = {\n\t\t\t\t\tzoom: initZoom,\n\t\t\t\t\tcenter: activeNodeLatLng,\n\t\t\t\t\tmapTypeId: mapTypeId,\n\t\t\t\t\tfullscreenControl: false,\n\t\t\t\t\tmapTypeControl: false,\n\t\t\t\t\tstreetViewControl: false\n\t\t\t\t};\n\t\t\t\tme._map_1.ggMap = new google.maps.Map(me._map_1, mapOptions);\n\t\t\t\tif (mapTypeId == 'googlecustomstyle') {\n\t\t\t\t\tvar styledMapType = new google.maps.StyledMapType(JSON.parse(mapDetails['googlecustomstylecode']), {name: 'Styled Map'});\n\t\t\t\t\tme._map_1.ggMap.mapTypes.set('styled_map', styledMapType);\n\t\t\t\t\tme._map_1.ggMap.setMapTypeId('styled_map');\n\t\t\t\t}\n\t\t\t\tif (mapTypeId == 'openstreetmap') {\n\t\t\t\t\tme._map_1.ggMap.mapTypes.set('openstreetmap', new google.maps.ImageMapType({\n\t\t\t\t\t\tgetTileUrl: function(coord, zoom) {\n\t\t\t\t\t\t\tif (mapDetails['mapstyle'] == 'streets') {\n\t\t\t\t\t\t\t\treturn 'https://tile.openstreetmap.org/' + zoom + '/' + coord.x + '/' + coord.y + '.png';\n\t\t\t\t\t\t\t} else if (mapDetails['mapstyle'] == 'outdoors') {\n\t\t\t\t\t\t\t\treturn 'https://a.tile.opentopomap.org/' + zoom + '/' + coord.x + '/' + coord.y + '.png';\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t},\n\t\t\t\t\t\ttileSize: new google.maps.Size(256, 256),\n\t\t\t\t\t\tname: mapDetails['title'],\n\t\t\t\t\t\tmaxZoom: mapDetails['mapstyle'] == 'outdoors' ? 17 : 18\n\t\t\t\t\t}));\n\t\t\t\t}\n\t\t\t\tif (mapTypeId == 'mapbox') {\n\t\t\t\t\tme._map_1.ggMap.mapTypes.set('mapbox', new google.maps.ImageMapType({\n\t\t\t\t\t\tgetTileUrl: function(coord, zoom) {\n\t\t\t\t\t\t\tif (mapDetails['styleurl'] == '') {\n\t\t\t\t\t\t\t\tif (mapDetails['mapstyle'] == 'satellite') {\n\t\t\t\t\t\t\t\t\treturn 'https://api.mapbox.com/v4/mapbox.' + mapDetails['mapstyle'] + '/' + zoom + '/' + coord.x + '/' + coord.y + '@2x.png?access_token=' + mapDetails['mapkey'];\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\treturn 'https://api.mapbox.com/styles/v1/mapbox/' + mapDetails['mapstyle'] + '-v11/tiles/256/' + zoom + '/' + coord.x + '/' + coord.y + '@2x?access_token=' + mapDetails['mapkey'];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tvar styleurlstring = mapDetails['styleurl'];\n\t\t\t\t\t\t\t\tstyleurlstring = styleurlstring.slice(styleurlstring.indexOf('styles/') + 7);\n\t\t\t\t\t\t\t\treturn 'https://api.mapbox.com/styles/v1/' + styleurlstring + '/tiles/256/' + zoom + '/' + coord.x + '/' + coord.y + '@2x?access_token=' + mapDetails['mapkey'];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t},\n\t\t\t\t\t\ttileSize: new google.maps.Size(256, 256),\n\t\t\t\t\t\tname: mapDetails['title'],\n\t\t\t\t\t\tmaxZoom: 18\n\t\t\t\t\t}));\n\t\t\t\t}\n\t\t\t\tif (mapTypeId == 'custom') {\n\t\t\t\t\tme._map_1.ggMap.mapTypes.set('custom', new google.maps.ImageMapType({\n\t\t\t\t\t\tgetTileUrl: function(coord, zoom) {\n\t\t\t\t\t\t\tvar urlString = mapDetails['mapurltemplate'];\n\t\t\t\t\t\t\turlString = urlString.replace('{s}', 'a');\n\t\t\t\t\t\t\turlString = urlString.replace('{z}', zoom);\n\t\t\t\t\t\t\turlString = urlString.replace('{x}', coord.x);\n\t\t\t\t\t\t\turlString = urlString.replace('{y}', coord.y);\n\t\t\t\t\t\t\treturn urlString;\n\t\t\t\t\t\t},\n\t\t\t\t\t\ttileSize: new google.maps.Size(256, 256),\n\t\t\t\t\t\tname: mapDetails['title'],\n\t\t\t\t\t\tmaxZoom: mapDetails['mapmaxzoom']\n\t\t\t\t\t}));\n\t\t\t\t}\n\t\t\t} else if (mapType == 'file') {\n\t\t\t\tif (me._map_1.ggLastZoom == -1) me._map_1.ggLastZoom = 7;\n\t\t\t\tvar initZoom = keepZoom ? me._map_1.ggLastZoom : 7;\n\t\t\t\tvar mapOptions = {\n\t\t\t\t backgroundColor: mapDetails['bgcolor'],\n\t\t\t\t\tzoom: initZoom,\n\t\t\t\t\tminZoom: 7,\n\t\t\t\t\tmaxZoom: 7 + (mapDetails['zoomlevels'] - 1) + 0,\n\t\t\t\t\tcenter: activeNodeLatLng,\n\t\t\t\t\tfullscreenControl: false,\n\t\t\t\t\tmapTypeControl: false,\n\t\t\t\t\tstreetViewControl: false\n\t\t\t\t};\n\t\t\t\tme._map_1.ggMap = new google.maps.Map(me._map_1, mapOptions);\n\t\t\t\tvar customMapType = new google.maps.ImageMapType({\n\t\t\t\t\tgetTileUrl: function(coord, zoom) {\n\t\t\t\t\t\tif (me._map_1.ggTileAvailable(coord.x, coord.y, zoom)) {\n\t\t\t\t\t\t\treturn basePath + 'images/maptiles/' + me._map_1.ggMapId + '/' + zoom + '/' + coord.x + '_' + coord.y + '.' + mapDetails['tileformat'];\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\treturn null;\n\t\t\t\t\t\t}\n\t\t\t\t\t},\n\t\t\t\t\ttileSize: new google.maps.Size(256, 256),\n\t\t\t\t\tminZoom: 7,\n\t\t\t\t\tmaxZoom: 7 + mapDetails['zoomlevels'],\n\t\t\t\t\tname: mapDetails['title'],\n\t\t\t\t});\n\t\t\t\tme._map_1.ggMap.mapTypes.set(me._map_1.ggMapId, customMapType);\n\t\t\t\tme._map_1.ggMap.setMapTypeId(me._map_1.ggMapId);\n\t\t\t\tme._map_1.ggCalculateFloorplanDimInDeg(mapDetails);\n\t\t\t\tgoogle.maps.event.addListener(me._map_1.ggMap, 'center_changed', function() {\n\t\t\t\t\tme._map_1.ggCheckBounds(mapDetails);\n\t\t\t\t});\n\t\t\t\tgoogle.maps.event.addListener(me._map_1.ggMap, 'zoom_changed', function() {\n\t\t\t\t\tme._map_1.ggCheckBounds(mapDetails);\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\t\tme._map_1.ggClearMap=function() {\n\t\tme._map_1.ggMap = null;\n\t\tme._map_1.ggClearMapMarkers();\n\t\tme._map_1.ggMapNotLoaded = true;\n\t\t}\n\t\tme._map_1.ggClearMapMarkers=function() {\n\t\t\tme._map_1.ggLastActivMarker = null;\n\t\t\tvar id,marker;\n\t\t\tvar markers=me._map_1.ggGoogleMarkerArray;\n\t\t\tfor (id in markers) {\n\t\t\t\tif (markers.hasOwnProperty(id)) {\n\t\t\t\t\tmarker=markers[id];\n\t\t\t\t\tmarker.setMap(null);\n\t\t\t\t}\n\t\t\t}\n\t\t\tme._map_1.ggGoogleMarkerArray=[];\n\t\t}\n\t\tme._map_1.ggCenterNode=function() {\n\t\t\tif (!me._map_1.ggMap) return;\n\t\t\tvar gps;\n\t\t\tif (player.getMapType(me._map_1.ggMapId) == 'web') {\n\t\t\t\tgps=player.getNodeLatLng();\n\t\t\t} else {\n\t\t\t\tgps=player.getNodeMapCoords(null, me._map_1.ggMapId);\n\t\t\t}\n\t\t\tif ((gps.length>=2) && ((gps[0]!=0) || (gps[1]!=0))) {\n\t\t\t\tvar markerLocation = new google.maps.LatLng(gps[0], gps[1]);\n\t\t\t\tme._map_1.ggMap.panTo(markerLocation);\n\t\t\t}\n\t\t}\n\t\tme._map_1.ggFitBounds=function(force) {\n\t\t\tif (me._map_1.ggMapNotLoaded) return;\n\t\t\tif (!me._map_1.ggMarkerBounds.isEmpty()) {\n\t\t\t\tif (me._map_1.ggMarkerInstances.length > 1 || Object.getOwnPropertyNames(me._map_1.ggGoogleMarkerArray).length > 1) {\n\t\t\t\t\tme._map_1.ggMap.fitBounds(me._map_1.ggMarkerBounds, 30);\n\t\t\t\t} else {\n\t\t\t\t\tme._map_1.ggMap.setCenter(me._map_1.ggMarkerBounds.getCenter());\n\t\t\t\t\tif (player.getMapType(me._map_1.ggMapId) == 'web') {\n\t\t\t\t\t\tme._map_1.ggMap.setZoom(18);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tme._map_1.ggMap.setZoom(7);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map_1.ggInitMapMarkers=function(updateMapBounds) {\n\t\t\tme._map_1.ggClearMapMarkers();\n\t\t\tvar ids=player.getNodeIds();\n\t\t\tme._map_1.ggFilteredIds = [];\n\t\t\tif (me._map_1.ggFilter != '') {\n\t\t\t\tvar filter = me._map_1.ggFilter.split(',');\n\t\t\t\tfor (i=0; i < ids.length; i++) {\n\t\t\t\t\tvar nodeId = ids[i];\n\t\t\t\t\tvar nodeData = player.getNodeUserdata(nodeId);\n\t\t\t\t\tfor (var j=0; j < filter.length; j++) {\n\t\t\t\t\t\tif (nodeData['tags'].indexOf(filter[j].trim()) != -1) me._map_1.ggFilteredIds.push(nodeId);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (me._map_1.ggFilteredIds.length > 0) ids = me._map_1.ggFilteredIds;\n\t\t\t}\n\t\t\tvar marker;\n\t\t\tvar markerLocation;\n\t\t\tme._map_1.ggMarkerBounds = new google.maps.LatLngBounds();\n\t\t\tvar currentId = player.getCurrentNode();\n\t\t\tfor(var i=0;i<ids.length;i++) {\n\t\t\t\tvar id=ids[i];\n\t\t\t\tvar gps;\n\t\t\t\tif (player.getMapType(me._map_1.ggMapId) == 'web') {\n\t\t\t\t\tgps=player.getNodeLatLng(id);\n\t\t\t\t} else {\n\t\t\t\t\tgps=player.getNodeMapCoords(id, me._map_1.ggMapId);\n\t\t\t\t}\n\t\t\t\tif ((gps.length>=2) && ((gps[0]!=0) || (gps[1]!=0))) {\n\t\t\t\t\tmarkerLocation = new google.maps.LatLng(gps[0], gps[1]);\n\t\t\t\t\tmarker = new google.maps.Marker({position: markerLocation,map: me._map_1.ggMap});\n\t\t\t\t\tmarker.setTitle(player.getNodeTitle(id));\n\t\t\t\t\tmarker.setClickable(true);\n\t\t\t\t\tmarker.ggId=id;\n\t\t\t\t\tgoogle.maps.event.addListener(marker, 'click', function() {\n\t\t\t\t\t\tplayer.openNext('{' + this.ggId + '}');\n\t\t\t\t\t\tactiveNodeLatLng=me.position;\n\t\t\t\t\t\tlastFov=-1; // force radar update\n\t\t\t\t\t});\n\t\t\t\t\tme._map_1.ggGoogleMarkerArray[id] = marker;\n\t\t\t\t\tme._map_1.ggMarkerBounds.extend(markerLocation);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ids.length > 1 && !me._map_1.ggMarkerBounds.isEmpty() && updateMapBounds) {\n\t\t\t\tme._map_1.ggFitBounds(false);\n\t\t\t}\n\t\t\tskin.updateSize(me._map_1);\n\t\t\tthis.ggLastActivMarker = null;\n\t\t\tif (this.ggUpdateConditionNodeChange) this.ggUpdateConditionNodeChange();\n\t\t\tthis.ggRadar.lastFov = -1;\n\t\t}\n\t\tme._map_1.ggChangeMap=function(mapId) {\n\t\t\tvar newMapType = player.getMapType(mapId)\n\t\t\tif (newMapType == 'file') {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tme._map_1.ggMapId = mapId;\n\t\t\tif (!me._map_1.ggMapNotLoaded) {\n\t\t\t\tif (me._map_1.ggMap) {\n\t\t\t\t\tme._map_1.ggLastZoom = me._map_1.ggMap.getZoom();\n\t\t\t\t}\n\t\t\t\tme._map_1.ggClearMap();\n\t\t\t\tme._map_1.ggInitMap(true);\n\t\t\t\tme._map_1.ggInitMapMarkers(false);\n\t\t\t}\n\t\t}\n\t\tme._map_1.ggCalculateFloorplanDimInDeg=function(mapDetails) {\n\t\t\tvar mapAR = mapDetails['width'] / mapDetails['height'];\n\t\t\tvar tileInDeg = 360.0 / Math.pow(2, 7);\n\t\t\tif (mapDetails['width'] >= mapDetails['height']) {\n\t\t\t\tvar tmpWidth = mapDetails['width'];\n\t\t\t\twhile (tmpWidth > 256) {\n\t\t\t\t\ttmpWidth /= 2;\n\t\t\t\t}\n\t\t\t\tme._map_1.mapWidthInDeg = tileInDeg * (tmpWidth / 256);\n\t\t\t\tme._map_1.mapHeightInDeg = me._map_1.mapWidthInDeg / mapAR;\n\t\t\t} else {\n\t\t\t\tvar tmpHeight = mapDetails['height'];\n\t\t\t\twhile (tmpHeight > 256) {\n\t\t\t\t\ttmpHeight /= 2;\n\t\t\t\t}\n\t\t\t\tme._map_1.mapHeightInDeg = tileInDeg * (tmpHeight / 256);\n\t\t\t\tme._map_1.mapWidthInDeg = me._map_1.mapHeightInDeg * mapAR;\n\t\t\t}\n\t\t}\n\t\tme._map_1.ggInCheckBounds=false;\n\t\tme._map_1.ggCheckBounds=function(mapDetails) {\n\t\t\tif (me._map_1.ggInCheckBounds) return;\n\t\t\tme._map_1.ggInCheckBounds = true;\n\t\t\tvar mapCenter = me._map_1.ggMap.getCenter();\n\t\t\tvar currentZoom = me._map_1.ggMap.getZoom();\n\t\t\tvar pixelInDeg = 360.0 / (Math.pow(2, currentZoom) * 256)\n\t\t\tvar xOffset = (me._map_1.clientWidth / 2.0) * pixelInDeg;\n\t\t\tvar yOffset = (me._map_1.clientHeight / 2.0) * pixelInDeg;\n\t\t\tvar x = mapCenter.lng();\n\t\t\tvar y = mapCenter.lat();\n\t\t\tvar xTemp = x;\n\t\t\tvar yTemp = y;\n\t\t\tif (me._map_1.mapWidthInDeg < me._map_1.clientWidth * pixelInDeg) {\n\t\t\t\tvar xMargin = (me._map_1.clientWidth * pixelInDeg - me._map_1.mapWidthInDeg) / 2;\n\t\t\t\tif (x < me._map_1.mapWidthInDeg / 2 - xMargin) x = me._map_1.mapWidthInDeg / 2 - xMargin;\n\t\t\t\tif (x > me._map_1.mapWidthInDeg / 2 + xMargin) x = me._map_1.mapWidthInDeg / 2 + xMargin;\n\t\t\t} else {\n\t\t\t\tif (x > me._map_1.mapWidthInDeg - xOffset) x = me._map_1.mapWidthInDeg - xOffset;\n\t\t\t\tif (x < xOffset) x = xOffset;\n\t\t\t}\n\t\t\tif (me._map_1.mapHeightInDeg < me._map_1.clientHeight * pixelInDeg) {\n\t\t\t\tvar yMargin = (me._map_1.clientHeight * pixelInDeg - me._map_1.mapHeightInDeg) / 2;\n\t\t\t\tif (y < -me._map_1.mapHeightInDeg / 2 - yMargin) y = -me._map_1.mapHeightInDeg / 2 - yMargin;\n\t\t\t\tif (y > -me._map_1.mapHeightInDeg / 2 + yMargin) y = -me._map_1.mapHeightInDeg / 2 + yMargin;\n\t\t\t} else {\n\t\t\t\tif (y < -me._map_1.mapHeightInDeg + yOffset) y = -me._map_1.mapHeightInDeg + yOffset;\n\t\t\t\tif (y > -yOffset) y = -yOffset;\n\t\t\t}\n\t\t\tif (x != xTemp || y != yTemp) {\n\t\t\t\tme._map_1.ggMap.setCenter(new google.maps.LatLng(y, x));\n\t\t\t}\n\t\t\tme._map_1.ggInCheckBounds = false;\n\t\t}\n\t\tplayer.addListener('sizechanged', function() {\n\t\t\tme.updateSize(me.divSkin);\n\t\t});\n\t\tplayer.addListener('configloaded', function() {\n\t\t\tme._map_1.ggClearMap();\n\t\t\tme._map_1.ggInitMap(false);\n\t\t\tme._map_1.ggInitMapMarkers(true);\n\t\t\tme._thumbnail_cloner.ggUpdate();\n\t\t});\n\t\tplayer.addListener('imagesready', function() {\n\t\t\tme._thumbnail_menu.ggUpdatePosition();\n\t\t});\n\t};\n\tthis.hotspotProxyClick=function(id, url) {\n\t}\n\tthis.hotspotProxyDoubleClick=function(id, url) {\n\t}\n\tme.hotspotProxyOver=function(id, url) {\n\t}\n\tme.hotspotProxyOut=function(id, url) {\n\t}\n\tplayer.addListener('changenode', function() {\n\t\tme.ggUserdata=player.userdata;\n\t});\n\tme.skinTimerEvent=function() {\n\t\tme.ggCurrentTime=new Date().getTime();\n\t\tme._map_1.ggUpdateConditionTimer();\n\t\tif (me.elementMouseDown['button_image_right']) {\n\t\t\tplayer.changePanLog(-0.5,true);\n\t\t}\n\t\tif (me.elementMouseDown['button_image_left']) {\n\t\t\tplayer.changePanLog(0.5,true);\n\t\t}\n\t\tif (me.elementMouseDown['button_image_down']) {\n\t\t\tplayer.changeTiltLog(-0.5,true);\n\t\t}\n\t\tif (me.elementMouseDown['button_image_up']) {\n\t\t\tplayer.changeTiltLog(0.5,true);\n\t\t}\n\t\tif (!player.getLockedKeyboard()) {\n\t\t\tswitch(me.skinKeyPressed) {\n\t\t\t\tcase 37:\n\t\t\t\t\tplayer.changePanLog(0.5,true);\n\t\t\t\t\tbreak;\n\t\t\t\tcase 38:\n\t\t\t\t\tplayer.changeTiltLog(0.5,true);\n\t\t\t\t\tbreak;\n\t\t\t\tcase 39:\n\t\t\t\t\tplayer.changePanLog(-0.5,true);\n\t\t\t\t\tbreak;\n\t\t\t\tcase 40:\n\t\t\t\t\tplayer.changeTiltLog(-0.5,true);\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t};\n\tplayer.addListener('timer', me.skinTimerEvent);\n\tfunction SkinCloner_thumbnail_cloner_Class(nodeId, parentScope,ggParent,parameter) {\n\t\tvar me=this;\n\t\tvar hs='';\n\t\tme.parentScope=parentScope;\n\t\tme.ggParent=ggParent;\n\t\tme.findElements=skin.findElements;\n\t\tme.ggIndex=parameter.index;\n\t\tme.ggNodeId=nodeId;\n\t\tme.ggTitle=parameter.title;\n\t\tme.ggUserdata=skin.player.getNodeUserdata(me.ggNodeId);\n\t\tme.elementMouseDown={};\n\t\tme.elementMouseOver={};\n\t\tme.__div=document.createElement('div');\n\t\tme.__div.setAttribute('style','position: absolute;width: 96px; height: 62px; visibility: inherit; overflow: visible;');\n\t\tme.__div.style.left=parameter.left;\n\t\tme.__div.style.top=parameter.top;\n\t\tme.__div.style.width=parameter.width;\n\t\tme.__div.style.height=parameter.height;\n\t\tme.__div.ggIsActive = function() {\n\t\t\treturn player.getCurrentNode()==me.ggNodeId;\n\t\t}\n\t\tme.__div.ggElementNodeId=function() {\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tel=me._thumbnail_nodeimage=document.createElement('div');\n\t\tels=me._thumbnail_nodeimage__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_nodeimage';\n\t\tels.setAttribute('src',basePath + \"images/thumbnail_nodeimage_\" + nodeId + \".jpg\");\n\t\tel.ggNodeId=nodeId;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_nodeimage';\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"thumbnail_nodeImage\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:0.62,sy:0.58 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_nodeimage \";\n\t\tel.ggType='nodeimage';\n\t\ths ='';\n\t\ths+='height : 90px;';\n\t\ths+='left : -24px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -16px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 140px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tel.style[domTransform]=parameterToTransform(el.ggParameter);\n\t\tme._thumbnail_nodeimage.ggIsActive=function() {\n\t\t\treturn player.getCurrentNode()==this.ggElementNodeId();\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn this.ggNodeId;\n\t\t}\n\t\tme._thumbnail_nodeimage.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.__div.appendChild(me._thumbnail_nodeimage);\n\t\tel=me._thumbnail_active=document.createElement('div');\n\t\tel.ggId=\"thumbnail active\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_rectangle \";\n\t\tel.ggType='rectangle';\n\t\ths ='';\n\t\ths+='border : 3px solid #000000;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 51px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 85px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._thumbnail_active.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._thumbnail_active.logicBlock_bordercolor = function() {\n\t\t\tvar newLogicStateBorderColor;\n\t\t\tif (\n\t\t\t\t((me._thumbnail_active.ggIsActive() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateBorderColor = 0;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((me.elementMouseOver['thumbnail_active'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateBorderColor = 1;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateBorderColor = -1;\n\t\t\t}\n\t\t\tif (me._thumbnail_active.ggCurrentLogicStateBorderColor != newLogicStateBorderColor) {\n\t\t\t\tme._thumbnail_active.ggCurrentLogicStateBorderColor = newLogicStateBorderColor;\n\t\t\t\tme._thumbnail_active.style[domTransition]='border-color 0s';\n\t\t\t\tif (me._thumbnail_active.ggCurrentLogicStateBorderColor == 0) {\n\t\t\t\t\tme._thumbnail_active.style.borderColor=\"rgba(192,192,192,1)\";\n\t\t\t\t}\n\t\t\t\telse if (me._thumbnail_active.ggCurrentLogicStateBorderColor == 1) {\n\t\t\t\t\tme._thumbnail_active.style.borderColor=\"rgba(192,192,192,1)\";\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._thumbnail_active.style.borderColor=\"rgba(0,0,0,1)\";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._thumbnail_active.onclick=function (e) {\n\t\t\tif (\n\t\t\t\t(\n\t\t\t\t\t((me._thumbnail_active.ggIsActive() == false))\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tplayer.openNext(\"{\"+me.ggNodeId+\"}\",\"\");\n\t\t\t}\n\t\t}\n\t\tme._thumbnail_active.onmouseover=function (e) {\n\t\t\tme.elementMouseOver['thumbnail_active']=true;\n\t\t\tme._thumbnail_title.logicBlock_alpha();\n\t\t\tme._checkmark_tick.logicBlock_alpha();\n\t\t\tme._thumbnail_active.logicBlock_bordercolor();\n\t\t}\n\t\tme._thumbnail_active.onmouseout=function (e) {\n\t\t\tme.elementMouseOver['thumbnail_active']=false;\n\t\t\tme._thumbnail_title.logicBlock_alpha();\n\t\t\tme._checkmark_tick.logicBlock_alpha();\n\t\t\tme._thumbnail_active.logicBlock_bordercolor();\n\t\t}\n\t\tme._thumbnail_active.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['thumbnail_active']=false;\n\t\t\tme._thumbnail_title.logicBlock_alpha();\n\t\t\tme._checkmark_tick.logicBlock_alpha();\n\t\t\tme._thumbnail_active.logicBlock_bordercolor();\n\t\t}\n\t\tme._thumbnail_active.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._thumbnail_title=document.createElement('div');\n\t\tels=me._thumbnail_title__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"thumbnail_title\";\n\t\tel.ggDx=0;\n\t\tel.ggDy=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 51px;';\n\t\ths+='left : -10000px;';\n\t\ths+='opacity : 0;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 85px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: 85px;';\n\t\ths+='height: 51px;';\n\t\ths+='background: #000000;';\n\t\ths+='background: rgba(0,0,0,0.784314);';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: pre-wrap;';\n\t\ths+='padding: 0px 1px 0px 1px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=me.ggUserdata.title;\n\t\tel.appendChild(els);\n\t\tme._thumbnail_title.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._thumbnail_title.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['thumbnail_active'] == true)) && \n\t\t\t\t((me.ggUserdata.title != \"\")) && \n\t\t\t\t((player.getVariableValue('opt_thumbnail_menu_tooltip') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._thumbnail_title.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._thumbnail_title.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._thumbnail_title.style[domTransition]='opacity 500ms ease 0ms';\n\t\t\t\tif (me._thumbnail_title.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tme._thumbnail_title.style.visibility=me._thumbnail_title.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._thumbnail_title.style.opacity=1;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tsetTimeout(function() { if (me._thumbnail_title.style.opacity == 0.0) { me._thumbnail_title.style.visibility=\"hidden\"; } }, 505);\n\t\t\t\t\tme._thumbnail_title.style.opacity=0;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._thumbnail_title.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=(this.ggDy + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._thumbnail_active.appendChild(me._thumbnail_title);\n\t\tel=me._checkmark_tick=document.createElement('div');\n\t\tels=me._checkmark_tick__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgaWQ9IkxheWVyXzEiIHZlcnNpb249IjEuMSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAtMjQwIDMzMiAxMzAgMTMwOyIgeD0iMHB4IiB5PSIwcHgiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2aWV3Qm94PSItMjQwIDMzMiAxMzAgMTMwIiB4bW'+\n\t\t\t'w6c3BhY2U9InByZXNlcnZlIj4KIDxzdHlsZSB0eXBlPSJ0ZXh0L2NzcyI+JiN4ZDsKCS5zdDB7ZmlsbDojMDAwMDAwO30mI3hkOwoJLnN0MXtmaWxsOiNGRkZGRkY7fSYjeGQ7Cjwvc3R5bGU+CiA8ZyBpZD0iTGF5ZXJfMV8xXyIvPgogPGcgaWQ9IkxheWVyXzIiPgogIDxwYXRoIGNsYXNzPSJzdDAiIGQ9Ik0tMTIyLjEsMzQxLjVoLTEwNS44Yy0xLjQsMC0yLjYsMS4xLTIuNiwyLjZ2MTA1LjhjMCwxLjQsMS4xLDIuNiwyLjYsMi42aDEwNS44YzEuNCwwLDIuNi0xLjEsMi42LTIuNlYzNDQuMSYjeGQ7JiN4YTsmI3g5OyYjeDk7Qy0xMTkuNiwzNDIuNy0xMjAuNywzNDEuNS0xMjIuMSwzNDEuNXog'+\n\t\t\t'TS0xMzIuOCwzODEuN2wtNTAuOCw1MC44Yy0wLjMsMC4zLTAuOCwwLjUtMS4yLDAuNWMtMC41LDAtMC45LTAuMS0xLjMtMC41bC0zMS43LTMxLjgmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC43LTAuNy0wLjctMS43LDAtMi40bDEyLjUtMTIuNWMwLjctMC43LDEuNy0wLjcsMi40LDBsMTgsMThsMzcuMS0zNy4xYzAuNy0wLjcsMS43LTAuNywyLjQsMGwxMi41LDEyLjUmI3hkOyYjeGE7JiN4OTsmI3g5O0MtMTMyLjEsMzc5LjktMTMyLjEsMzgxLTEzMi44LDM4MS43eiIvPgogIDxwYXRoIGNsYXNzPSJzdDEiIGQ9Ik0tMTQ3LjcsMzY2LjhsLTM3LjEsMzcuMWwtMTgtMThjLTAuNy0wLjctMS43LTAuNy'+\n\t\t\t'0yLjQsMGwtMTIuNSwxMi41Yy0wLjcsMC43LTAuNywxLjcsMCwyLjRsMzEuNywzMS44JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4zLDAuMywwLjgsMC41LDEuMywwLjVjMC40LDAsMC45LTAuMiwxLjItMC41bDUwLjgtNTAuOWMwLjctMC43LDAuNy0xLjcsMC0yLjRsLTEyLjUtMTIuNUMtMTQ1LjksMzY2LjEtMTQ3LDM2Ni4xLTE0Ny43LDM2Ni44eiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._checkmark_tick__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"checkmark_tick\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='height : 19px;';\n\t\ths+='position : absolute;';\n\t\ths+='right : 0px;';\n\t\ths+='top : 1px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 19px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._checkmark_tick.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._checkmark_tick.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.nodeVisited(me._checkmark_tick.ggElementNodeId()) == true)) || \n\t\t\t\t((me._checkmark_tick.ggIsActive() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._checkmark_tick.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._checkmark_tick.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._checkmark_tick.style[domTransition]='opacity 500ms ease 0ms';\n\t\t\t\tif (me._checkmark_tick.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._checkmark_tick.style.visibility=(Number(me._checkmark_tick.style.opacity)>0||!me._checkmark_tick.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._checkmark_tick.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._checkmark_tick.style.visibility=\"hidden\";\n\t\t\t\t\tme._checkmark_tick.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._checkmark_tick.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['thumbnail_active'] == true)) && \n\t\t\t\t((me.ggUserdata.title != \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._checkmark_tick.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._checkmark_tick.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._checkmark_tick.style[domTransition]='opacity 500ms ease 0ms';\n\t\t\t\tif (me._checkmark_tick.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tsetTimeout(function() { if (me._checkmark_tick.style.opacity == 0.0) { me._checkmark_tick.style.visibility=\"hidden\"; } }, 505);\n\t\t\t\t\tme._checkmark_tick.style.opacity=0;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._checkmark_tick.style.visibility=me._checkmark_tick.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._checkmark_tick.style.opacity=1;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._checkmark_tick.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._thumbnail_active.appendChild(me._checkmark_tick);\n\t\tme.__div.appendChild(me._thumbnail_active);\n\t};\n\tme.addSkin();\n\tvar style = document.createElement('style');\n\tstyle.type = 'text/css';\n\tstyle.appendChild(document.createTextNode('.ggskin { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 14px;}'));\n\tdocument.head.appendChild(style);\n\tme._button_image_normalscreen.logicBlock_visible();\n\tme._button_image_fullscreen.logicBlock_visible();\n\tme._thumbnail_hide_button.logicBlock_alpha();\n\tme._thumbnail_show_button.logicBlock_alpha();\n\tme._thumbnail_menu.logicBlock_alpha();\n\tme._stop_rotate_image.logicBlock_visible();\n\tme._start_rotate_image.logicBlock_visible();\n\tplayer.addListener('fullscreenenter', function(args) { me._button_image_normalscreen.logicBlock_visible();me._button_image_fullscreen.logicBlock_visible(); });\n\tplayer.addListener('fullscreenexit', function(args) { me._button_image_normalscreen.logicBlock_visible();me._button_image_fullscreen.logicBlock_visible(); });\n\tplayer.addListener('changenode', function(args) { me._thumbnail_hide_button.logicBlock_alpha();me._thumbnail_show_button.logicBlock_alpha();me._thumbnail_menu.logicBlock_alpha();me._stop_rotate_image.logicBlock_visible();me._start_rotate_image.logicBlock_visible(); });\n\tplayer.addListener('autorotatechanged', function(args) { me._stop_rotate_image.logicBlock_visible();me._start_rotate_image.logicBlock_visible(); });\n\tplayer.addListener('varchanged_vis_thumbnail_menu', function(args) { me._thumbnail_hide_button.logicBlock_alpha();me._thumbnail_show_button.logicBlock_alpha();me._thumbnail_menu.logicBlock_alpha(); });\n\tplayer.addListener('changenode', function(args) { me._thumbnail_cloner.callChildLogicBlocks_changenode(); });\n\tplayer.addListener('mouseover', function(args) { me._thumbnail_cloner.callChildLogicBlocks_mouseover(); });\n\tplayer.addListener('mouseover', function(args) { me._thumbnail_cloner.callChildLogicBlocks_mouseover(); });\n\tplayer.addListener('changenode', function(args) { me._thumbnail_cloner.callChildLogicBlocks_active(); });\n\tplayer.addListener('changevisitednodes', function(args) { me._thumbnail_cloner.callChildLogicBlocks_changevisitednodes(); });\n\tplayer.addListener('activehotspotchanged', function(args) { me._thumbnail_cloner.callChildLogicBlocks_activehotspotchanged(); });\n\tplayer.addListener('varchanged_opt_thumbnail_menu_tooltip', function(args) { me._thumbnail_cloner.callChildLogicBlocks_varchanged_opt_thumbnail_menu_tooltip(); });\n\tdocument.addEventListener('keydown', function(e) {\n\t\tvar key = e.which || e.keyCode;\n\t\tme.skinKeyPressed = key;\n\t});\n\tdocument.addEventListener('keyup', function(e) {\n\t\tvar key = e.which || e.keyCode;\n\t\tme.skinKeyPressed = 0;\n\t});\n\tme.skinTimerEvent();\n}", "function switchBackground() {\n carousel.style.background = \"url('\" + images[currentImage] + \"')\";\n carousel.style.backgroundSize = 'cover';\n carousel.style.backgroundPosition = 'center';\n caption.textContent = captions[currentImage];\n}", "function setDynamicBackground() {\n\tsetUpGame();\n\tprogressGame();\n\tsetInterval(\"progressGame()\", refreshRate);\n}", "function loadFrontPage() {\n checkAccess();\n $('#p_index .show-left .poster').css(\"background-image\", \"url(\\'res/poster_\"+ $('body').attr(\"data-F\") +\".jpg\\')\");\n $('#p_index .show-right .poster').css(\"background-image\", \"url(\\'res/poster_\"+ $('body').attr(\"data-E\") +\".jpg\\')\");\n}", "function Skin() {\n this.init.apply(this, arguments);\n}", "function wowAnimation() {\r\n new WOW({\r\n offset: 100,\r\n animateClass: \"animated\",\r\n mobile: true,\r\n }).init();\r\n }", "function updatePageBackgroundImage(data, callback) { \r\n var $body = $(\"body\");\r\n if(!$body.hasClass(\"dark-background\"))\r\n $body.addClass(\"dark-background\");\r\n\r\n var $termsLink = $(\"#terms-link\");\r\n var $privacyLink = $(\"#privacy-link\");\r\n \r\n isAcceptedLocation((allow)=>{\r\n if(allow){\r\n $termsLink.css({\"display\" : \"inline-block\", \"opacity\" : 0.85});\r\n $privacyLink.css({\"display\" : \"inline-block\", \"opacity\" : 0.85});\r\n\r\n setTimeout(function() {\r\n var $termsLink = $(\"#terms-link\");\r\n var $privacyLink = $(\"#privacy-link\");\r\n var showTime = 750;\r\n var opacity = 0.35;\r\n\r\n $termsLink.animate({ opacity: opacity }, showTime);\r\n $privacyLink.animate({ opacity: opacity }, showTime);\r\n }, 3500);\r\n }else{\r\n $termsLink.remove();\r\n $privacyLink.remove();\r\n $(\"#powered-link\").css(\"margin-right\", 0);\r\n }\r\n });\r\n\r\n if(data.enableParallax) {\r\n data.image = data.image ? data.image : \"\";\r\n var $imageContainer = $(\"#background-image-container\");\r\n var $image = $(\"<img/>\");\r\n $image.attr(\"id\", \"background-image\");\r\n $image.attr(\"src\", data.image);\r\n $image.css({\"opacity\" : 0});\r\n $image.addClass(\"layer\").attr(\"data-depth\", 0.0065 * data.parallaxValue);\r\n $image.addClass(\"fill\");\r\n $imageContainer.html(\"\").append($image);\r\n if(data.enableParallax) {\r\n $imageContainer.addClass(\"parallax\");\r\n if(imageBgParallaxScene)\r\n imageBgParallaxScene.parallax('updateLayers');\r\n else\r\n imageBgParallaxScene = $imageContainer.parallax();\r\n } else {\r\n $imageContainer.addClass(\"static\");\r\n }\r\n themeImageShow($image);\r\n } else {\r\n data.image = data.image ? data.image + \"?d=\" + new Date().getTime() : \"\";\r\n \r\n $(\"body\"/*document.documentElement*/).css({\r\n \"background-image\" : \"url(\"+ data.image.replace( \"(\", \"\\\\(\" ).replace( \")\", \"\\\\)\" ) +\")\",\r\n \"background-position\" : \"center center\",\r\n \"background-size\" : \"cover\",\r\n \"background-repeat\" : \"no-repeat\",\r\n \"background-attachment\" : \"fixed\",\r\n //\"width\": \"100%\",\r\n //\"height\": \"100%\",\r\n });\r\n\r\n $(\"#squaresLoadingProgress\").text(0);\r\n setTimeout(function() {\r\n if(typeof (callback) != \"undefined\")\r\n callback(data);\r\n }, 250);\r\n }\r\n\r\n}", "function changeBackground() {\n if (pixabayJSON != null) {\n if (\"hits\" in pixabayJSON) {\n var hits = pixabayJSON[\"hits\"];\n var len = hits.length;\n var currentNum = generateNumber(1, len) - 1;\n var currentImage = hits[currentNum];\n if (\"webformatURL\" in currentImage) {\n var imageUrl = currentImage[\"webformatURL\"];\n var formatRegex = /_\\d+\\./;\n if (formatRegex.test(imageUrl)) {\n imageUrl = imageUrl.replace(formatRegex, '_960.');\n }\n $('.jumbotron-main').css(\"background-image\", \"url(\" + imageUrl + \")\");\n\n\n }\n\n }\n }\n}", "function ws_page(e,t,i){var n=jQuery,o=e.angle||17,d=n(this),s=n(\"<div>\").addClass(\"ws_effect ws_page\").css({position:\"absolute\",width:\"100%\",height:\"100%\",top:\"0%\",overflow:\"hidden\"}),a=i.find(\".ws_list\");s.hide().appendTo(i),this.go=function(i,p){function u(){s.find(\"div\").stop(1,1),s.hide(),s.empty()}u(),a.hide();var r=n(\"<div>\").css({position:\"absolute\",left:0,top:0,width:\"100%\",height:\"100%\",overflow:\"hidden\",\"z-index\":9}).append(n(t.get(i)).clone()).appendTo(s),h=n(\"<div>\").css({position:\"absolute\",left:0,top:0,width:\"100%\",height:\"100%\",overflow:\"hidden\",outline:\"1px solid transparent\",\"z-index\":10,\"transform-origin\":\"top left\",\"backface-visibility\":\"hidden\"}).append(n(t.get(p)).clone()).appendTo(s);s.show(),e.responsive<3&&(r.find(\"img\").css(\"width\",\"100%\"),h.find(\"img\").css(\"width\",\"100%\"));var c=h,f=(c.width(),c.height(),!document.addEventListener);wowAnimate(c,{rotate:0},{rotate:o},f?0:2*e.duration/3,\"easeOutOneBounce\",function(){wowAnimate(c,{top:0},{top:\"100%\"},(f?2:1)*e.duration/3)}),wowAnimate(r,{top:\"-100%\"},{top:\"-30%\"},f?0:e.duration/2,function(){wowAnimate(r,{top:\"-30%\"},{top:0},(f?2:1)*e.duration/2,\"easeOutBounce\",function(){c.hide(),u(),d.trigger(\"effectEnd\")})})}}", "function changeTextMusic() {\n \n document.getElementById(\"music-description\").style.display=\"block\";\n document.getElementById(\"gym-description\").style.display=\"none\";\n document.getElementById(\"skiing-description\").style.display=\"none\";\n document.getElementById(\"friends-description\").style.display=\"none\";\n document.getElementById(\"about-hobbies\").style.backgroundImage=\"linear-gradient(to right top, #d16ba5, #c378b7, #b385c3, #a590ca, #999acc, #91a5d6, #89b0dd, #83bae2, #71caef, #5cdaf6, #4eeaf6, #53f9ef)\"; \n }", "function playEquationTheme(){\r\n\tif(themeEqu != null)\r\n\t\tthemeEqu.play();\r\n}", "function backgroundImages() {\n tint(255, 140); // Reduces the image's opacity\n image(cherryblossom1, 990, 110);\n image(cherryblossom2, -20, 20);\n image(dragon, -50, 340);\n}", "function bgAnimationComplete() {\n preloadBg.hide();\n\n site = new Site();\n site.init();\n }", "function displayLoadedBackgroundImageTheme(message) { \r\n \r\n \r\n $(\"#circleLoadingProgress\").text(100);\r\n var $popup = $(\"#popupDownloadImageTheme\");\r\n $popup.fadeOut(500, function() {\r\n $(\"#circleLoadingProgress\").text(0);\r\n });\r\n removeCurrentThemeVideo();\r\n updatePageBackgroundImage(message);\r\n displayPageHeader(message);\r\n}", "function preload(){\r\n bg =loadImage(\"cityImage.png\");\r\n balloonImage1=loadAnimation(\"hotairballoon1.png\");\r\n balloonImage2=loadAnimation(\"hotairballoon1.png\",\"hotairballoon1.png\",\r\n \"hotairballoon1.png\",\"hotairballoon2.png\",\"hotairballoon2.png\",\r\n \"hotairballoon2.png\",\"hotairballoon3.png\",\"hotairballoon3.png\",\"hotairballoon3.png\");\r\n }", "function updateBackground()\n{\n\tif( typeof weatherBGImages == 'undefined')\n\t\treturn;\n\n\tif( curWeatherIcon in weatherBGImages ) {\n\t\tvar bgImages = weatherBGImages[curWeatherIcon];\n\t\tif( bgImages.length > 0 ) {\n\t\t\tvar index = Math.floor(Math.random() * 10) % bgImages.length;\n\n\t\t\t$('body').css('backgroundImage', function () {\n\t\t\t\treturn 'url(' + bgImages[index] + ')';\n\t\t\t});\n\n\t\t}\n\t}\n\n\tsetTimeout( updateBackground, weatherVGCycleInterval * 1000 );\n}", "function thememascot_wow() {\n var wow = new WOW({\n mobile: false // trigger animations on mobile devices (default is true)\n });\n wow.init();\n }", "function styleUpdate(){\n hide('.intro');\n show('.mode');\n\n $('body').removeClass('initial');\n $('body').addClass('light-body');\n\n $('.container').addClass('light');\n}", "function updateTheme(){\r\n if (!data.night) {\r\n saveCookies()\r\n document.body.style.backgroundColor = \"white\";\r\n\r\n //document.getElementById(\"myImg\").style.filter = \"brightness(60%)\";\r\n document.getElementById(\"head\").style.borderBottom = \"solid rgba(255, 255, 255, 0.6) .5px\";\r\n\r\n } else if (data.night) {\r\n saveCookies();\r\n document.body.style.backgroundColor = \"#2e3044\";\r\n\r\n //document.getElementById(\"myImg\").style.filter = \"brightness(100%)\";\r\n document.getElementById(\"head\").style.borderBottom = \"solid rgba(0, 0, 0, 0.6) .5px\";\r\n }\r\n}", "function backgroundImage() {\n \n $(\".gear-box h2\").animate({\n \n marginTop: \"202px\",\n opacity: \"1\"\n \n }, 2000);\n \n}", "function pano2vrSkin(player,base) {\n\tplayer.addVariable('opt_thumbnail_menu_tooltip', 2, true);\n\tplayer.addVariable('vis_thumbnail_menu', 2, true);\n\tplayer.addVariable('opt_3d_preview', 2, true);\n\tplayer.addVariable('category_visible', 2, true);\n\tplayer.addVariable('node_visible', 2, true);\n\tplayer.addVariable('open_tag', 0, \"\");\n\tplayer.addVariable('close_nodes', 2, false);\n\tplayer.addVariable('category_follow', 2, true);\n\tplayer.addVariable('category_visible_1', 2, true);\n\tplayer.addVariable('vis_info_popup', 2, false);\n\tvar me=this;\n\tvar skin=this;\n\tvar flag=false;\n\tvar hotspotTemplates={};\n\tvar skinKeyPressed = 0;\n\tthis.player=player;\n\tthis.player.skinObj=this;\n\tthis.divSkin=player.divSkin;\n\tthis.ggUserdata=player.userdata;\n\tthis.lastSize={ w: -1,h: -1 };\n\tvar basePath=\"\";\n\t// auto detect base path\n\tif (base=='?') {\n\t\tvar scripts = document.getElementsByTagName('script');\n\t\tfor(var i=0;i<scripts.length;i++) {\n\t\t\tvar src=scripts[i].src;\n\t\t\tif (src.indexOf('skin.js')>=0) {\n\t\t\t\tvar p=src.lastIndexOf('/');\n\t\t\t\tif (p>=0) {\n\t\t\t\t\tbasePath=src.substr(0,p+1);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t} else\n\tif (base) {\n\t\tbasePath=base;\n\t}\n\tthis.elementMouseDown=[];\n\tthis.elementMouseOver=[];\n\tvar cssPrefix='';\n\tvar domTransition='transition';\n\tvar domTransform='transform';\n\tvar prefixes='Webkit,Moz,O,ms,Ms'.split(',');\n\tvar i;\n\tvar hs,el,els,elo,ela,elHorScrollFg,elHorScrollBg,elVertScrollFg,elVertScrollBg,elCornerBg;\n\tif (typeof document.body.style['transform'] == 'undefined') {\n\t\tfor(var i=0;i<prefixes.length;i++) {\n\t\t\tif (typeof document.body.style[prefixes[i] + 'Transform'] !== 'undefined') {\n\t\t\t\tcssPrefix='-' + prefixes[i].toLowerCase() + '-';\n\t\t\t\tdomTransition=prefixes[i] + 'Transition';\n\t\t\t\tdomTransform=prefixes[i] + 'Transform';\n\t\t\t}\n\t\t}\n\t}\n\t\n\tplayer.setMargins(0,0,0,0);\n\t\n\tthis.updateSize=function(startElement) {\n\t\tvar stack=[];\n\t\tstack.push(startElement);\n\t\twhile(stack.length>0) {\n\t\t\tvar e=stack.pop();\n\t\t\tif (e.ggUpdatePosition) {\n\t\t\t\te.ggUpdatePosition();\n\t\t\t}\n\t\t\tif (e.hasChildNodes()) {\n\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\t\n\tthis.callNodeChange=function(startElement) {\n\t\tvar stack=[];\n\t\tstack.push(startElement);\n\t\twhile(stack.length>0) {\n\t\t\tvar e=stack.pop();\n\t\t\tif (e.ggNodeChange) {\n\t\t\t\te.ggNodeChange();\n\t\t\t}\n\t\t\tif (e.hasChildNodes()) {\n\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tplayer.addListener('changenode', function() { me.ggUserdata=player.userdata; me.callNodeChange(me.divSkin); });\n\t\n\tvar parameterToTransform=function(p) {\n\t\tvar hs='translate(' + p.rx + 'px,' + p.ry + 'px) rotate(' + p.a + 'deg) scale(' + p.sx + ',' + p.sy + ')';\n\t\treturn hs;\n\t}\n\t\n\tthis.findElements=function(id,regex) {\n\t\tvar r=[];\n\t\tvar stack=[];\n\t\tvar pat=new RegExp(id,'');\n\t\tstack.push(me.divSkin);\n\t\twhile(stack.length>0) {\n\t\t\tvar e=stack.pop();\n\t\t\tif (regex) {\n\t\t\t\tif (pat.test(e.ggId)) r.push(e);\n\t\t\t} else {\n\t\t\t\tif (e.ggId==id) r.push(e);\n\t\t\t}\n\t\t\tif (e.hasChildNodes()) {\n\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn r;\n\t}\n\t\n\tthis.addSkin=function() {\n\t\tvar hs='';\n\t\tthis.ggCurrentTime=new Date().getTime();\n\t\tel=me._image_1=document.createElement('div');\n\t\tels=me._image_1__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_image_1';\n\t\ths=basePath + 'images/image_1.png';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"Image 1\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='bottom : 7px;';\n\t\ths+='height : 43px;';\n\t\ths+='position : absolute;';\n\t\ths+='right : 5px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 166px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._image_1.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._image_1.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.divSkin.appendChild(me._image_1);\n\t\tel=me._menu_background=document.createElement('div');\n\t\tel.ggId=\"menu_background\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_rectangle \";\n\t\tel.ggType='rectangle';\n\t\ths ='';\n\t\ths+='background : rgba(0,0,0,0.501961);';\n\t\ths+='border : 1px solid #000000;';\n\t\ths+='cursor : default;';\n\t\ths+='height : 100%;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 178px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._menu_background.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._menu_background.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('category_visible_1') == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._menu_background.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._menu_background.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._menu_background.style[domTransition]='opacity 500ms ease 0ms';\n\t\t\t\tif (me._menu_background.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tsetTimeout(function() { if (me._menu_background.style.opacity == 0.0) { me._menu_background.style.visibility=\"hidden\"; } }, 505);\n\t\t\t\t\tme._menu_background.style.opacity=0;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._menu_background.style.visibility=me._menu_background.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._menu_background.style.opacity=1;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._menu_background.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._category_scroller=document.createElement('div');\n\t\tels=me._category_scroller__content=document.createElement('div');\n\t\tels.className='ggskin ggskin_subelement ggskin_scrollarea';\n\t\tel.ggContent=els;\n\t\tel.appendChild(els);\n\t\tel.ggHorScrollVisible = false;\n\t\tel.ggVertScrollVisible = false;\n\t\tel.ggContentLeftOffset = 0;\n\t\tel.ggContentTopOffset = 0;\n\t\tel.ggDragInertiaX = 0;\n\t\tel.ggDragInertiaY = 0;\n\t\tel.ggVPercentVisible = 1.0;\n\t\tel.ggHPercentVisible = 1.0;\n\t\ths ='';\n\t\ths+='height : 134px;';\n\t\ths+='left : 0px;';\n\t\ths+='overflow : visible;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='width : 154px;';\n\t\ths+=\"\";\n\t\tels.setAttribute('style',hs);\n\t\tme._category_scroller.ggScrollByX = function(diffX) {\n\t\t\tif(!me._category_scroller.ggHorScrollVisible || diffX == 0 || me._category_scroller.ggHPercentVisible >= 1.0) return;\n\t\t\tme._category_scroller.ggScrollPosX = (me._category_scroller__horScrollFg.offsetLeft + diffX);\n\t\t\tme._category_scroller.ggScrollPosX = Math.max(me._category_scroller.ggScrollPosX, 0);\n\t\t\tme._category_scroller.ggScrollPosX = Math.min(me._category_scroller.ggScrollPosX, me._category_scroller__horScrollBg.offsetWidth - me._category_scroller__horScrollFg.offsetWidth);\n\t\t\tme._category_scroller__horScrollFg.style.left = me._category_scroller.ggScrollPosX + 'px';\n\t\t\tlet percentScrolled = me._category_scroller.ggScrollPosX / (me._category_scroller__horScrollBg.offsetWidth - me._category_scroller__horScrollFg.offsetWidth);\n\t\t\tme._category_scroller__content.style.left = -(Math.round((me._category_scroller.ggContentWidth * (1.0 - me._category_scroller.ggHPercentVisible)) * percentScrolled)) + me._category_scroller.ggContentLeftOffset + 'px';\n\t\t\tme._category_scroller.ggScrollPosXPercent = (me._category_scroller__horScrollFg.offsetLeft / me._category_scroller__horScrollBg.offsetWidth);\n\t\t}\n\t\tme._category_scroller.ggScrollByXSmooth = function(diffX) {\n\t\t\tif(!me._category_scroller.ggHorScrollVisible || diffX == 0 || me._category_scroller.ggHPercentVisible >= 1.0) return;\n\t\t\tvar scrollPerInterval = diffX / 25;\n\t\t\tvar scrollCurrX = 0;\n\t\t\tvar id = setInterval(function() {\n\t\t\t\tscrollCurrX += scrollPerInterval;\n\t\t\t\tme._category_scroller.ggScrollPosX += scrollPerInterval;\n\t\t\t\tif (diffX > 0 && (scrollCurrX >= diffX || me._category_scroller.ggScrollPosX >= me._category_scroller__horScrollBg.offsetWidth - me._category_scroller__horScrollFg.offsetWidth)) {\n\t\t\t\t\tme._category_scroller.ggScrollPosX = Math.min(me._category_scroller.ggScrollPosX, me._category_scroller__horScrollBg.offsetWidth - me._category_scroller__horScrollFg.offsetWidth);\n\t\t\t\t\tclearInterval(id);\n\t\t\t\t}\n\t\t\t\tif (diffX < 0 && (scrollCurrX <= diffX || me._category_scroller.ggScrollPosX <= 0)) {\n\t\t\t\t\tme._category_scroller.ggScrollPosX = Math.max(me._category_scroller.ggScrollPosX, 0);\n\t\t\t\t\tclearInterval(id);\n\t\t\t\t}\n\t\t\tme._category_scroller__horScrollFg.style.left = me._category_scroller.ggScrollPosX + 'px';\n\t\t\tlet percentScrolled = me._category_scroller.ggScrollPosX / (me._category_scroller__horScrollBg.offsetWidth - me._category_scroller__horScrollFg.offsetWidth);\n\t\t\tme._category_scroller__content.style.left = -(Math.round((me._category_scroller.ggContentWidth * (1.0 - me._category_scroller.ggHPercentVisible)) * percentScrolled)) + me._category_scroller.ggContentLeftOffset + 'px';\n\t\t\tme._category_scroller.ggScrollPosXPercent = (me._category_scroller__horScrollFg.offsetLeft / me._category_scroller__horScrollBg.offsetWidth);\n\t\t\t}, 10);\n\t\t}\n\t\tme._category_scroller.ggScrollByY = function(diffY) {\n\t\t\tif(!me._category_scroller.ggVertScrollVisible || diffY == 0 || me._category_scroller.ggVPercentVisible >= 1.0) return;\n\t\t\tme._category_scroller.ggScrollPosY = (me._category_scroller__vertScrollFg.offsetTop + diffY);\n\t\t\tme._category_scroller.ggScrollPosY = Math.max(me._category_scroller.ggScrollPosY, 0);\n\t\t\tme._category_scroller.ggScrollPosY = Math.min(me._category_scroller.ggScrollPosY, me._category_scroller__vertScrollBg.offsetHeight - me._category_scroller__vertScrollFg.offsetHeight);\n\t\t\tme._category_scroller__vertScrollFg.style.top = me._category_scroller.ggScrollPosY + 'px';\n\t\t\tlet percentScrolled = me._category_scroller.ggScrollPosY / (me._category_scroller__vertScrollBg.offsetHeight - me._category_scroller__vertScrollFg.offsetHeight);\n\t\t\tme._category_scroller__content.style.top = -(Math.round((me._category_scroller.ggContentHeight * (1.0 - me._category_scroller.ggVPercentVisible)) * percentScrolled)) + me._category_scroller.ggContentTopOffset + 'px';\n\t\t\tme._category_scroller.ggScrollPosYPercent = (me._category_scroller__vertScrollFg.offsetTop / me._category_scroller__vertScrollBg.offsetHeight);\n\t\t}\n\t\tme._category_scroller.ggScrollByYSmooth = function(diffY) {\n\t\t\tif(!me._category_scroller.ggVertScrollVisible || diffY == 0 || me._category_scroller.ggVPercentVisible >= 1.0) return;\n\t\t\tvar scrollPerInterval = diffY / 25;\n\t\t\tvar scrollCurrY = 0;\n\t\t\tvar id = setInterval(function() {\n\t\t\t\tscrollCurrY += scrollPerInterval;\n\t\t\t\tme._category_scroller.ggScrollPosY += scrollPerInterval;\n\t\t\t\tif (diffY > 0 && (scrollCurrY >= diffY || me._category_scroller.ggScrollPosY >= me._category_scroller__vertScrollBg.offsetHeight - me._category_scroller__vertScrollFg.offsetHeight)) {\n\t\t\t\t\tme._category_scroller.ggScrollPosY = Math.min(me._category_scroller.ggScrollPosY, me._category_scroller__vertScrollBg.offsetHeight - me._category_scroller__vertScrollFg.offsetHeight);\n\t\t\t\t\tclearInterval(id);\n\t\t\t\t}\n\t\t\t\tif (diffY < 0 && (scrollCurrY <= diffY || me._category_scroller.ggScrollPosY <= 0)) {\n\t\t\t\t\tme._category_scroller.ggScrollPosY = Math.max(me._category_scroller.ggScrollPosY, 0);\n\t\t\t\t\tclearInterval(id);\n\t\t\t\t}\n\t\t\tme._category_scroller__vertScrollFg.style.top = me._category_scroller.ggScrollPosY + 'px';\n\t\t\tlet percentScrolled = me._category_scroller.ggScrollPosY / (me._category_scroller__vertScrollBg.offsetHeight - me._category_scroller__vertScrollFg.offsetHeight);\n\t\t\tme._category_scroller__content.style.top = -(Math.round((me._category_scroller.ggContentHeight * (1.0 - me._category_scroller.ggVPercentVisible)) * percentScrolled)) + me._category_scroller.ggContentTopOffset + 'px';\n\t\t\tme._category_scroller.ggScrollPosYPercent = (me._category_scroller__vertScrollFg.offsetTop / me._category_scroller__vertScrollBg.offsetHeight);\n\t\t\t}, 10);\n\t\t}\n\t\tme._category_scroller.ggScrollIntoView = function(posX, posY, width, height) {\n\t\t\tif (me._category_scroller.ggHorScrollVisible) {\n\t\t\t\tif (posX < 0) {\n\t\t\t\t\tvar diffX = Math.floor(posX * me._category_scroller.ggHPercentVisible);\n\t\t\t\t\tme._category_scroller.ggScrollByXSmooth(diffX);\n\t\t\t\t} else if (posX + width > me._category_scroller.clientWidth - (me._category_scroller.ggVertScrollVisible ? 15 : 0)) {\n\t\t\t\t\tvar diffX = Math.ceil(((posX + width) - (me._category_scroller.clientWidth - (me._category_scroller.ggVertScrollVisible ? 15 : 0))) * me._category_scroller.ggHPercentVisible);\n\t\t\t\t\tme._category_scroller.ggScrollByXSmooth(diffX);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (me._category_scroller.ggVertScrollVisible) {\n\t\t\t\tif (posY < 0) {\n\t\t\t\t\tvar diffY = Math.floor(posY * me._category_scroller.ggVPercentVisible);\n\t\t\t\t\tme._category_scroller.ggScrollByYSmooth(diffY);\n\t\t\t\t} else if (posY + height > me._category_scroller.clientHeight - (me._category_scroller.ggHorScrollVisible ? 15 : 0)) {\n\t\t\t\t\tvar diffY = Math.ceil(((posY + height) - (me._category_scroller.clientHeight - (me._category_scroller.ggHorScrollVisible ? 15 : 0))) * me._category_scroller.ggVPercentVisible);\n\t\t\t\t\tme._category_scroller.ggScrollByYSmooth(diffY);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tels.ontouchstart = function(e) {\n\t\t\te = e || window.event;\n\t\t\tvar t = e.touches;\n\t\t\tme._category_scroller.ggDragLastX = t ? t[0].clientX : e.clientX;\n\t\t\tme._category_scroller.ggDragLastY = t ? t[0].clientY : e.clientY;\n\t\t\tme._category_scroller__content.ontouchend = function() {\n\t\t\t\tlet inertiaInterval = setInterval(function() {\n\t\t\t\t\tme._category_scroller.ggDragInertiaX *= 0.65;\n\t\t\t\t\tme._category_scroller.ggDragInertiaY *= 0.65;\n\t\t\t\t\tme._category_scroller.ggScrollByX(me._category_scroller.ggDragInertiaX);\n\t\t\t\t\tme._category_scroller.ggScrollByY(me._category_scroller.ggDragInertiaY);\n\t\t\t\t\tif (Math.abs(me._category_scroller.ggDragInertiaX) < 1.0 && Math.abs(me._category_scroller.ggDragInertiaY) < 1.0) {\n\t\t\t\t\t\tclearInterval(inertiaInterval);\n\t\t\t\t\t}\n\t\t\t\t\t}, 50);\n\t\t\t\tme._category_scroller__content.ontouchend = null;\n\t\t\t\tme._category_scroller__content.ontouchmove = null;\n\t\t\t\tme._category_scroller__content.onpointerup = null;\n\t\t\t\tme._category_scroller__content.onpointermove = null;\n\t\t\t}\n\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\tme._category_scroller__content.onpointerup = me._category_scroller__content.ontouchend;\n\t\t}\n\t\t\tme._category_scroller__content.ontouchmove = function(e) {\n\t\t\t\te = e || window.event;\n\t\t\t\te.preventDefault();\n\t\t\t\tvar t = e.touches;\n\t\t\t\tvar diffX = ((t ? t[0].clientX : e.clientX) - me._category_scroller.ggDragLastX) * me._category_scroller.ggHPercentVisible;\n\t\t\t\tvar diffY = ((t ? t[0].clientY : e.clientY) - me._category_scroller.ggDragLastY) * me._category_scroller.ggVPercentVisible;\n\t\t\t\tme._category_scroller.ggDragInertiaX = -diffX;\n\t\t\t\tme._category_scroller.ggDragInertiaY = -diffY;\n\t\t\t\tme._category_scroller.ggDragLastX = t ? t[0].clientX : e.clientX;\n\t\t\t\tme._category_scroller.ggDragLastY = t ? t[0].clientY : e.clientY;\n\t\t\t\tme._category_scroller.ggScrollByX(-diffX);\n\t\t\t\tme._category_scroller.ggScrollByY(-diffY);\n\t\t\t}\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\t\tme._category_scroller__content.onpointermove = me._category_scroller__content.ontouchmove;\n\t\t\t}\n\t\t}\n\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\tels.onpointerdown = els.ontouchstart;\n\t\t}\n\t\telHorScrollBg = me._category_scroller__horScrollBg = document.createElement('div');\n\t\tel.appendChild(elHorScrollBg);\n\t\telHorScrollBg.setAttribute('style', 'position: absolute; left: 0px; bottom: 0px; visibility: hidden; width: 178px; height: 15px; background-color: rgba(128,128,128,1); pointer-events: auto;');\n\t\telHorScrollBg.className='ggskin ggskin_scrollarea_hscrollbg';\n\t\telHorScrollFg = me._category_scroller__horScrollFg = document.createElement('div');\n\t\telHorScrollBg.appendChild(elHorScrollFg);\n\t\telHorScrollFg.className='ggskin ggskin_scrollarea_hscrollfg';\n\t\telHorScrollFg.setAttribute('style', 'position: absolute; left: 0px; top: 0px; visibility: hidden; width: 178px; height: 15px; background-color: rgba(192,192,192,1); pointer-events: auto;');\n\t\tme._category_scroller.ggScrollPosX = 0;\n\t\tme._category_scroller.ggScrollPosXPercent = 0.0;\n\t\telHorScrollFg.onmousedown = function(e) {\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) return;\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\te.stopPropagation();\n\t\t\tme._category_scroller.ggDragLastX = e.clientX;\n\t\t\tdocument.onmouseup = function() {\n\t\t\t\tlet inertiaInterval = setInterval(function() {\n\t\t\t\t\tme._category_scroller.ggDragInertiaX *= 0.65;\n\t\t\t\t\tme._category_scroller.ggScrollByX(me._category_scroller.ggDragInertiaX);\n\t\t\t\t\tif (Math.abs(me._category_scroller.ggDragInertiaX) < 1.0) {\n\t\t\t\t\t\tclearInterval(inertiaInterval);\n\t\t\t\t\t}\n\t\t\t\t\t}, 50);\n\t\t\t\tdocument.onmouseup = null;\n\t\t\t\tdocument.onmousemove = null;\n\t\t\t}\n\t\t\tdocument.onmousemove = function(e) {\n\t\t\t\te = e || window.event;\n\t\t\t\te.preventDefault();\n\t\t\t\tvar diffX = e.clientX - me._category_scroller.ggDragLastX;\n\t\t\t\tme._category_scroller.ggDragInertiaX = diffX;\n\t\t\t\tme._category_scroller.ggDragLastX = e.clientX;\n\t\t\t\tme._category_scroller.ggScrollByX(diffX);\n\t\t\t}\n\t\t}\n\t\telHorScrollFg.ontouchstart = function(e) {\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\te.stopPropagation();\n\t\t\tvar t = e.touches;\n\t\t\tme._category_scroller.ggDragLastX = t ? t[0].clientX : e.clientX;\n\t\t\tdocument.ontouchend = function() {\n\t\t\t\tlet inertiaInterval = setInterval(function() {\n\t\t\t\t\tme._category_scroller.ggDragInertiaX *= 0.65;\n\t\t\t\t\tme._category_scroller.ggScrollByX(me._category_scroller.ggDragInertiaX);\n\t\t\t\t\tif (Math.abs(me._category_scroller.ggDragInertiaX) < 1.0) {\n\t\t\t\t\t\tclearInterval(inertiaInterval);\n\t\t\t\t\t}\n\t\t\t\t\t}, 50);\n\t\t\t\tdocument.ontouchend = null;\n\t\t\t\tdocument.ontouchmove = null;\n\t\t\t\tdocument.onpointerup = null;\n\t\t\t\tdocument.onpointermove = null;\n\t\t\t}\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\t\tdocument.onpointerup = document.ontouchend;\n\t\t\t}\n\t\t\tdocument.ontouchmove = function(e) {\n\t\t\t\te = e || window.event;\n\t\t\t\te.preventDefault();\n\t\t\t\tvar t = e.touches;\n\t\t\t\tvar diffX = (t ? t[0].clientX : e.clientX) - me._category_scroller.ggDragLastX;\n\t\t\t\tme._category_scroller.ggDragInertiaX = diffX;\n\t\t\t\tme._category_scroller.ggDragLastX = t ? t[0].clientX : e.clientX;\n\t\t\t\tme._category_scroller.ggScrollByX(diffX);\n\t\t\t}\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\t\tdocument.onpointermove = document.ontouchmove;\n\t\t\t}\n\t\t}\n\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\telHorScrollFg.onpointerdown = elHorScrollFg.ontouchstart;\n\t\t}\n\t\telHorScrollBg.onmousedown = function(e) {\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\tvar diffX = me._category_scroller.ggScrollWidth;\n\t\t\tif (e.offsetX < me._category_scroller.ggScrollPosX) {\n\t\t\t\tdiffX = diffX * -1;\n\t\t\t}\n\t\t\tme._category_scroller.ggScrollByXSmooth(diffX);\n\t\t}\n\t\telHorScrollBg.ontouchstart = function(e) {\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\te.stopPropagation();\n\t\t\tvar t = e.touches;\n\t\t\tvar rect = me._category_scroller__horScrollBg.getBoundingClientRect();\n\t\t\tvar diffX = me._category_scroller.ggScrollWidth;\n\t\t\tif ((t[0].clientX - rect.left) < me._category_scroller.ggScrollPosX) {\n\t\t\t\tdiffX = diffX * -1;\n\t\t\t}\n\t\t\tme._category_scroller.ggScrollByXSmooth(diffX);\n\t\t}\n\t\tel.addEventListener('wheel', function(e) {\n\t\t\te.preventDefault();\n\t\t\tvar wheelDelta = Math.sign(e.deltaX);\n\t\t\tme._category_scroller.ggScrollByXSmooth(30 * me._category_scroller.ggHPercentVisible * wheelDelta);\n\t\t});\n\t\telVertScrollBg = me._category_scroller__vertScrollBg = document.createElement('div');\n\t\tel.appendChild(elVertScrollBg);\n\t\telVertScrollBg.setAttribute('style', 'position: absolute; right: 0px; top: 0px; visibility: hidden; width: 15px; height: 480px; background-color: rgba(128,128,128,1); pointer-events: auto;');\n\t\telVertScrollBg.className='ggskin ggskin_scrollarea_vscrollbg';\n\t\telVertScrollFg = me._category_scroller__vertScrollFg = document.createElement('div');\n\t\telVertScrollBg.appendChild(elVertScrollFg);\n\t\telVertScrollFg.setAttribute('style', 'position: absolute; left: 0px; top: 0px; visibility: hidden; width: 15px; height: 480px; background-color: rgba(192,192,192,1); pointer-events: auto;');\n\t\telVertScrollFg.className='ggskin ggskin_scrollarea_vscrollfg';\n\t\tme._category_scroller.ggScrollPosY = 0;\n\t\tme._category_scroller.ggScrollPosYPercent = 0.0;\n\t\telVertScrollFg.onmousedown = function(e) {\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) return;\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\te.stopPropagation();\n\t\t\tme._category_scroller.ggDragLastY = e.clientY;\n\t\t\tdocument.onmouseup = function() {\n\t\t\t\tlet inertiaInterval = setInterval(function() {\n\t\t\t\t\tme._category_scroller.ggDragInertiaY *= 0.65;\n\t\t\t\t\tme._category_scroller.ggScrollByY(me._category_scroller.ggDragInertiaY);\n\t\t\t\t\tif (Math.abs(me._category_scroller.ggDragInertiaY) < 1.0) {\n\t\t\t\t\t\tclearInterval(inertiaInterval);\n\t\t\t\t\t}\n\t\t\t\t\t}, 50);\n\t\t\t\tdocument.onmouseup = null;\n\t\t\t\tdocument.onmousemove = null;\n\t\t\t}\n\t\t\tdocument.onmousemove = function(e) {\n\t\t\t\te = e || window.event;\n\t\t\t\te.preventDefault();\n\t\t\t\tvar diffY = e.clientY - me._category_scroller.ggDragLastY;\n\t\t\t\tme._category_scroller.ggDragInertiaY = diffY;\n\t\t\t\tme._category_scroller.ggDragLastY = e.clientY;\n\t\t\t\tme._category_scroller.ggScrollByY(diffY);\n\t\t\t}\n\t\t}\n\t\telVertScrollFg.ontouchstart = function(e) {\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\te.stopPropagation();\n\t\t\tvar t = e.touches;\n\t\t\tme._category_scroller.ggDragLastY = t ? t[0].clientY : e.clientY;\n\t\t\tdocument.ontouchend = function() {\n\t\t\t\tlet inertiaInterval = setInterval(function() {\n\t\t\t\t\tme._category_scroller.ggDragInertiaY *= 0.65;\n\t\t\t\t\tme._category_scroller.ggScrollByY(me._category_scroller.ggDragInertiaY);\n\t\t\t\t\tif (Math.abs(me._category_scroller.ggDragInertiaY) < 1.0) {\n\t\t\t\t\t\tclearInterval(inertiaInterval);\n\t\t\t\t\t}\n\t\t\t\t\t}, 50);\n\t\t\t\tdocument.ontouchend = null;\n\t\t\t\tdocument.ontouchmove = null;\n\t\t\t\tdocument.onpointerup = null;\n\t\t\t\tdocument.onpointermove = null;\n\t\t\t}\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\t\tdocument.onpointerup = document.ontouchend;\n\t\t\t}\n\t\t\tdocument.ontouchmove = function(e) {\n\t\t\t\te = e || window.event;\n\t\t\t\te.preventDefault();\n\t\t\t\tvar t = e.touches;\n\t\t\t\tvar diffY = (t ? t[0].clientY : e.clientY) - me._category_scroller.ggDragLastY;\n\t\t\t\tme._category_scroller.ggDragInertiaY = diffY;\n\t\t\t\tme._category_scroller.ggDragLastY = t ? t[0].clientY : e.clientY;\n\t\t\t\tme._category_scroller.ggScrollByY(diffY);\n\t\t\t}\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\t\tdocument.onpointermove = document.ontouchmove;\n\t\t\t}\n\t\t}\n\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\telVertScrollFg.onpointerdown = elVertScrollFg.ontouchstart;\n\t\t}\n\t\telVertScrollBg.onmousedown = function(e) {\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\tvar diffY = me._category_scroller.ggScrollHeight;\n\t\t\tif (e.offsetY < me._category_scroller.ggScrollPosY) {\n\t\t\t\tdiffY = diffY * -1;\n\t\t\t}\n\t\t\tme._category_scroller.ggScrollByYSmooth(diffY);\n\t\t}\n\t\telVertScrollBg.ontouchstart = function(e) {\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\te.stopPropagation();\n\t\t\tvar t = e.touches;\n\t\t\tvar rect = me._category_scroller__vertScrollBg.getBoundingClientRect();\n\t\t\tvar diffY = me._category_scroller.ggScrollHeight;\n\t\t\tif ((t[0].clientY - rect.top) < me._category_scroller.ggScrollPosY) {\n\t\t\t\tdiffY = diffY * -1;\n\t\t\t}\n\t\t\tme._category_scroller.ggScrollByYSmooth(diffY);\n\t\t}\n\t\tel.addEventListener('wheel', function(e) {\n\t\t\te.preventDefault();\n\t\t\tvar wheelDelta = Math.sign(e.deltaY);\n\t\t\tme._category_scroller.ggScrollByYSmooth(30 * me._category_scroller.ggVPercentVisible * wheelDelta);\n\t\t});\n\t\telCornerBg = me._category_scroller__cornerBg = document.createElement('div');\n\t\tel.appendChild(elCornerBg);\n\t\telCornerBg.setAttribute('style', 'position: absolute; right: 0px; bottom: 0px; visibility: hidden; width: 15px; height: 15px; background-color: rgba(255,255,255,1);');\n\t\telCornerBg.className='ggskin ggskin_scrollarea_scrollcorner';\n\t\tel.ggId=\"category_scroller\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_scrollarea \";\n\t\tel.ggType='scrollarea';\n\t\ths ='';\n\t\ths+='border : 0px solid #000000;';\n\t\ths+='height : calc(100% - 50px);';\n\t\ths+='left : 0px;';\n\t\ths+='overflow : hidden;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 50px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 178px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._category_scroller.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._category_scroller.ggUpdatePosition=function (useTransition) {\n\t\t\t{\n\t\t\t\tvar horScrollWasVisible = this.ggHorScrollVisible;\n\t\t\t\tvar vertScrollWasVisible = this.ggVertScrollVisible;\n\t\t\t\tthis.ggContent.style.left = '0px';\n\t\t\t\tthis.ggContent.style.top = '0px';\n\t\t\t\tthis.ggContentLeftOffset = 0;\n\t\t\t\tthis.ggContentTopOffset = 0;\n\t\t\t\tthis.ggContentWidth = 0;\n\t\t\t\tthis.ggContentHeight = 0;\n\t\t\t\tvar offsetWidthWithScale = this.getBoundingClientRect().width;\n\t\t\t\tvar offsetHeightWithScale = this.getBoundingClientRect().height;\n\t\t\t\tvar domRectContent = this.ggContent.getBoundingClientRect();\n\t\t\t\tvar minX = 0;\n\t\t\t\tvar minY = 0;\n\t\t\t\tvar maxX = 0;\n\t\t\t\tvar maxY = 0;\n\t\t\t\tvar stack=[];\n\t\t\t\tstack.push(this.ggContent);\n\t\t\t\twhile(stack.length>0) {\n\t\t\t\t\tvar e=stack.pop();\n\t\t\t\t\tif (e!=this.ggContent && e.getBoundingClientRect && e.style['display']!='none') {\n\t\t\t\t\t\tvar domRectChild = e.getBoundingClientRect();\n\t\t\t\t\t\tvar diffX = domRectChild.left - domRectContent.left;\n\t\t\t\t\t\tminX = Math.min(minX, diffX);\n\t\t\t\t\t\tmaxX = Math.max(maxX, diffX + domRectChild.width);\n\t\t\t\t\t\tvar diffY = domRectChild.top - domRectContent.top;\n\t\t\t\t\t\tminY = Math.min(minY, diffY);\n\t\t\t\t\t\tmaxY = Math.max(maxY, diffY + domRectChild.height);\n\t\t\t\t\t}\n\t\t\t\t\tif (e.hasChildNodes() && e.style['display']!='none') {\n\t\t\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (minX < 0) this.ggContentLeftOffset = -minX;\n\t\t\t\tif (minY < 0) this.ggContentTopOffset = -minY;\n\t\t\t\tvar contentWidth = maxX - minX;\n\t\t\t\tvar contentHeight = maxY - minY;\n\t\t\t\tthis.ggContentWidth = contentWidth;\n\t\t\t\tthis.ggContentHeight = contentHeight;\n\t\t\t\tthis.ggContent.style.left = this.ggContentLeftOffset + 'px';\n\t\t\t\tthis.ggContent.style.top = this.ggContentTopOffset + 'px';\n\t\t\t\tthis.ggContent.style.width = contentWidth + 'px';\n\t\t\t\tthis.ggContent.style.height = contentHeight + 'px';\n\t\t\t\tthis.ggContent.style.left = -(Math.round(me._category_scroller.ggScrollPosX / me._category_scroller.ggHPercentVisible)) + this.ggContentLeftOffset + 'px';\n\t\t\t\tthis.ggContent.style.marginLeft = '0px';\n\t\t\t\tthis.ggContent.style.top = -(Math.round(me._category_scroller.ggScrollPosY / me._category_scroller.ggVPercentVisible)) + this.ggContentTopOffset + 'px';\n\t\t\t\tthis.ggContent.style.marginTop = '0px';\n\t\t\t\tif (contentWidth > Math.ceil(offsetWidthWithScale)) {\n\t\t\t\t\tme._category_scroller__horScrollBg.style.visibility = 'inherit';\n\t\t\t\t\tme._category_scroller__horScrollFg.style.visibility = 'inherit';\n\t\t\t\t\tme._category_scroller.ggHorScrollVisible = true;\n\t\t\t\t} else {\n\t\t\t\t\tme._category_scroller__horScrollBg.style.visibility = 'hidden';\n\t\t\t\t\tme._category_scroller__horScrollFg.style.visibility = 'hidden';\n\t\t\t\t\tme._category_scroller.ggHorScrollVisible = false;\n\t\t\t\t}\n\t\t\t\tif ((me._category_scroller.ggHorScrollVisible && contentHeight > this.clientHeight - 15) || (!me._category_scroller.ggHorScrollVisible && contentHeight > this.clientHeight)) {\n\t\t\t\t\tme._category_scroller__vertScrollBg.style.visibility = 'inherit';\n\t\t\t\t\tme._category_scroller__vertScrollFg.style.visibility = 'inherit';\n\t\t\t\t\tme._category_scroller.ggVertScrollVisible = true;\n\t\t\t\t\tif (!me._category_scroller.ggHorScrollVisible && (contentWidth > offsetWidthWithScale - me._category_scroller__vertScrollBg.getBoundingClientRect().width)) {\n\t\t\t\t\t\tme._category_scroller__horScrollBg.style.visibility = 'inherit';\n\t\t\t\t\t\tme._category_scroller__horScrollFg.style.visibility = 'inherit';\n\t\t\t\t\t\tme._category_scroller.ggHorScrollVisible = true;\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tme._category_scroller__vertScrollBg.style.visibility = 'hidden';\n\t\t\t\t\tme._category_scroller__vertScrollFg.style.visibility = 'hidden';\n\t\t\t\t\tme._category_scroller.ggVertScrollVisible = false;\n\t\t\t\t}\n\t\t\t\tif(me._category_scroller.ggHorScrollVisible) {\n\t\t\t\t\tme._category_scroller.ggAvailableHeight = me._category_scroller.clientHeight - 15;\n\t\t\t\t\tif (me._category_scroller.ggVertScrollVisible) {\n\t\t\t\t\t\tme._category_scroller.ggAvailableWidth = me._category_scroller.clientWidth - 15;\n\t\t\t\t\t\tme._category_scroller.ggAvailableWidthWithScale = me._category_scroller.getBoundingClientRect().width - me._category_scroller__horScrollBg.getBoundingClientRect().height;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tme._category_scroller.ggAvailableWidth = me._category_scroller.clientWidth;\n\t\t\t\t\t\tme._category_scroller.ggAvailableWidthWithScale = me._category_scroller.getBoundingClientRect().width;\n\t\t\t\t\t}\n\t\t\t\t\tme._category_scroller__horScrollBg.style.width = me._category_scroller.ggAvailableWidth + 'px';\n\t\t\t\t\tme._category_scroller.ggHPercentVisible = contentWidth != 0 ? me._category_scroller.ggAvailableWidthWithScale / contentWidth : 0.0;\n\t\t\t\t\tif (me._category_scroller.ggHPercentVisible > 1.0) me._category_scroller.ggHPercentVisible = 1.0;\n\t\t\t\t\tme._category_scroller.ggScrollWidth = Math.round(me._category_scroller__horScrollBg.offsetWidth * me._category_scroller.ggHPercentVisible);\n\t\t\t\t\tme._category_scroller__horScrollFg.style.width = me._category_scroller.ggScrollWidth + 'px';\n\t\t\t\t\tme._category_scroller.ggScrollPosX = me._category_scroller.ggScrollPosXPercent * me._category_scroller.ggAvailableWidth;\n\t\t\t\t\tme._category_scroller.ggScrollPosX = Math.min(me._category_scroller.ggScrollPosX, me._category_scroller__horScrollBg.offsetWidth - me._category_scroller__horScrollFg.offsetWidth);\n\t\t\t\t\tme._category_scroller__horScrollFg.style.left = me._category_scroller.ggScrollPosX + 'px';\n\t\t\t\t\tif (me._category_scroller.ggHPercentVisible < 1.0) {\n\t\t\t\t\t\tlet percentScrolled = me._category_scroller.ggScrollPosX / (me._category_scroller__horScrollBg.offsetWidth - me._category_scroller__horScrollFg.offsetWidth);\n\t\t\t\t\t\tme._category_scroller__content.style.left = -(Math.round((me._category_scroller.ggContentWidth * (1.0 - me._category_scroller.ggHPercentVisible)) * percentScrolled)) + this.ggContentLeftOffset + 'px';\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tme._category_scroller.ggAvailableHeight = me._category_scroller.clientHeight;\n\t\t\t\t\tme._category_scroller.ggScrollPosX = 0;\n\t\t\t\t\tme._category_scroller.ggScrollPosXPercent = 0.0;\n\t\t\t\t\tme._category_scroller__content.style.left = this.ggContentLeftOffset + 'px';\n\t\t\t\t}\n\t\t\t\tif(me._category_scroller.ggVertScrollVisible) {\n\t\t\t\t\tme._category_scroller.ggAvailableWidth = me._category_scroller.clientWidth - 15;\n\t\t\t\t\tif (me._category_scroller.ggHorScrollVisible) {\n\t\t\t\t\t\tme._category_scroller.ggAvailableHeight = me._category_scroller.clientHeight - 15;\n\t\t\t\t\t\tme._category_scroller.ggAvailableHeightWithScale = me._category_scroller.getBoundingClientRect().height - me._category_scroller__vertScrollBg.getBoundingClientRect().width;\n\t\t\t\t\t\tme._category_scroller__cornerBg.style.visibility = 'inherit';\n\t\t\t\t\t} else {\n\t\t\t\t\t\tme._category_scroller.ggAvailableHeight = me._category_scroller.clientHeight;\n\t\t\t\t\t\tme._category_scroller.ggAvailableHeightWithScale = me._category_scroller.getBoundingClientRect().height;\n\t\t\t\t\t\tme._category_scroller__cornerBg.style.visibility = 'hidden';\n\t\t\t\t\t}\n\t\t\t\t\tme._category_scroller__vertScrollBg.style.height = me._category_scroller.ggAvailableHeight + 'px';\n\t\t\t\t\tme._category_scroller.ggVPercentVisible = contentHeight != 0 ? me._category_scroller.ggAvailableHeightWithScale / contentHeight : 0.0;\n\t\t\t\t\tif (me._category_scroller.ggVPercentVisible > 1.0) me._category_scroller.ggVPercentVisible = 1.0;\n\t\t\t\t\tme._category_scroller.ggScrollHeight = Math.round(me._category_scroller__vertScrollBg.offsetHeight * me._category_scroller.ggVPercentVisible);\n\t\t\t\t\tme._category_scroller__vertScrollFg.style.height = me._category_scroller.ggScrollHeight + 'px';\n\t\t\t\t\tme._category_scroller.ggScrollPosY = me._category_scroller.ggScrollPosYPercent * me._category_scroller.ggAvailableHeight;\n\t\t\t\t\tme._category_scroller.ggScrollPosY = Math.min(me._category_scroller.ggScrollPosY, me._category_scroller__vertScrollBg.offsetHeight - me._category_scroller__vertScrollFg.offsetHeight);\n\t\t\t\t\tme._category_scroller__vertScrollFg.style.top = me._category_scroller.ggScrollPosY + 'px';\n\t\t\t\t\tif (me._category_scroller.ggVPercentVisible < 1.0) {\n\t\t\t\t\t\tlet percentScrolled = me._category_scroller.ggScrollPosY / (me._category_scroller__vertScrollBg.offsetHeight - me._category_scroller__vertScrollFg.offsetHeight);\n\t\t\t\t\t\tme._category_scroller__content.style.top = -(Math.round((me._category_scroller.ggContentHeight * (1.0 - me._category_scroller.ggVPercentVisible)) * percentScrolled)) + me._category_scroller.ggContentTopOffset + 'px';\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tme._category_scroller.ggAvailableWidth = me._category_scroller.clientWidth;\n\t\t\t\t\tme._category_scroller.ggScrollPosY = 0;\n\t\t\t\t\tme._category_scroller.ggScrollPosYPercent = 0.0;\n\t\t\t\t\tme._category_scroller__content.style.top = this.ggContentTopOffset + 'px';\n\t\t\t\t\tme._category_scroller__cornerBg.style.visibility = 'hidden';\n\t\t\t\t}\n\t\t\t\tif(horScrollWasVisible != me._category_scroller.ggHorScrollVisible || vertScrollWasVisible != me._category_scroller.ggVertScrollVisible) {\n\t\t\t\t\tme.updateSize(me._category_scroller);\n\t\t\t\t\tme._category_scroller.ggUpdatePosition();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tel=me._category_cloner=document.createElement('div');\n\t\tel.ggNumRepeat = 1;\n\t\tel.ggNumRows = 0;\n\t\tel.ggNumCols = 0;\n\t\tel.ggWidth = 150;\n\t\tel.ggHeight = 128;\n\t\tel.ggUpdating = false;\n\t\tel.ggFilter = [];\n\t\tel.ggInstances = [];\n\t\tme._category_cloner.callChildLogicBlocks_changenode = function(){\n\t\t\tif(me._category_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._category_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._category_cloner.ggInstances[i]._category && me._category_cloner.ggInstances[i]._category.logicBlock_backgroundcolor) {\n\t\t\t\t\t\tme._category_cloner.ggInstances[i]._category.logicBlock_backgroundcolor();\n\t\t\t\t\t}\n\t\t\t\t\tme._category_cloner.ggInstances[i]._node_cloner.callChildLogicBlocks_changenode();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category_cloner.callChildLogicBlocks_mouseover = function(){\n\t\t\tif(me._category_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._category_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._category_cloner.ggInstances[i]._category && me._category_cloner.ggInstances[i]._category.logicBlock_backgroundcolor) {\n\t\t\t\t\t\tme._category_cloner.ggInstances[i]._category.logicBlock_backgroundcolor();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category_cloner.callChildLogicBlocks_mouseover = function(){\n\t\t\tif(me._category_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._category_cloner.ggInstances.length; i++) {\n\t\t\t\t\tme._category_cloner.ggInstances[i]._node_cloner.callChildLogicBlocks_mouseover();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category_cloner.callChildLogicBlocks_active = function(){\n\t\t\tif(me._category_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._category_cloner.ggInstances.length; i++) {\n\t\t\t\t\tme._category_cloner.ggInstances[i]._node_cloner.callChildLogicBlocks_active();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category_cloner.callChildLogicBlocks_changevisitednodes = function(){\n\t\t\tif(me._category_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._category_cloner.ggInstances.length; i++) {\n\t\t\t\t\tme._category_cloner.ggInstances[i]._node_cloner.callChildLogicBlocks_changevisitednodes();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category_cloner.callChildLogicBlocks_activehotspotchanged = function(){\n\t\t\tif(me._category_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._category_cloner.ggInstances.length; i++) {\n\t\t\t\t\tme._category_cloner.ggInstances[i]._node_cloner.callChildLogicBlocks_activehotspotchanged();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category_cloner.callChildLogicBlocks_varchanged_open_tag = function(){\n\t\t\tif(me._category_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._category_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._category_cloner.ggInstances[i]._category && me._category_cloner.ggInstances[i]._category.logicBlock_backgroundcolor) {\n\t\t\t\t\t\tme._category_cloner.ggInstances[i]._category.logicBlock_backgroundcolor();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tel.ggAutoPosition = function(init) {\n\t\t\tvar currYPos = 0;\n\t\t\tvar numElements = me._category_cloner.ggInstances.length;\n\t\t\tvar currElement = 0;\n\t\t\tfor (var i=0; i<me._category_cloner.ggNumRows; i++) {\n\t\t\t\tvar rowMaxHeight = 0;\n\t\t\t\tfor (var j=0; j<me._category_cloner.ggNumCols; j++) {\n\t\t\t\t\tif (numElements > currElement) {\n\t\t\t\t\t\tif (!init) {\n\t\t\t\t\t\t\tif (me._category_cloner.childNodes[currElement].clientHeight < me._category_cloner.childNodes[currElement].scrollHeight && currElement < (numElements - 1)) {\n\t\t\t\t\t\t\t\tme._category_cloner.childNodes[currElement].style.transition = 'top ' + 1 + 's, height ' + 1 + 's';\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tme._category_cloner.childNodes[currElement].style.transition = 'top ' + 1 + 's';\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tme._category_cloner.childNodes[currElement].style.overflow = 'hidden';\n\t\t\t\t\t\tme._category_cloner.childNodes[currElement].style['top'] = currYPos + 'px';\n\t\t\t\t\t\tme._category_cloner.childNodes[currElement].style['height'] ='0px';\n\t\t\t\t\t\trowMaxHeight = Math.max(rowMaxHeight, me._category_cloner.childNodes[currElement].scrollHeight);\n\t\t\t\t\t\tme._category_cloner.childNodes[currElement].style['height'] = rowMaxHeight + 'px';\n\t\t\t\t\t}\n\t\t\t\t\tcurrElement++;\n\t\t\t\t}\n\t\t\t\tcurrYPos += rowMaxHeight;\n\t\t\t}\n\t\t\tsetTimeout(function() {\n\t\t\t\tvar p = me._category_cloner.parentElement;\n\t\t\t\twhile (p != null && p !== me.divSkin) {\n\t\t\t\t\tif (p.ggType && p.ggType == 'scrollarea') {\n\t\t\t\t\t\tif (p.ggUpdatePosition) {\n\t\t\t\t\t\t\tp.ggUpdatePosition();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tp = p.parentElement;\n\t\t\t\t}\n\t\t\t}, 1000);\n\t\t}\n\t\tel.ggUpdate = function(filter) {\n\t\t\tif(me._category_cloner.ggUpdating == true) return;\n\t\t\tme._category_cloner.ggUpdating = true;\n\t\t\tvar el=me._category_cloner;\n\t\t\tvar curNumCols = 0;\n\t\t\tcurNumCols = me._category_cloner.ggNumRepeat;\n\t\t\tif (curNumCols < 1) curNumCols = 1;\n\t\t\tif (typeof filter=='object') {\n\t\t\t\tel.ggFilter = filter;\n\t\t\t} else {\n\t\t\t\tfilter = el.ggFilter;\n\t\t\t};\n\t\t\tif (me.ggTag) filter.push(me.ggTag);\n\t\t\tfilter=filter.sort();\n\t\t\tif ((el.ggNumCols == curNumCols) && (el.ggInstances.length > 0) && (filter.length === el.ggCurrentFilter.length) && (filter.every(function(value, index) { return value === el.ggCurrentFilter[index] }) )) {\n\t\t\t\tme._category_cloner.ggUpdating = false;\n\t\t\t\treturn;\n\t\t\t} else {\n\t\t\t\tel.ggNumRows = 1;\n\t\t\t\tel.ggNumCols = curNumCols;\n\t\t\t}\n\t\t\tel.ggCurrentFilter = filter;\n\t\t\tel.ggInstances = [];\n\t\t\tif (el.hasChildNodes() == true) {\n\t\t\t\twhile (el.firstChild) {\n\t\t\t\t\tel.removeChild(el.firstChild);\n\t\t\t\t}\n\t\t\t}\n\t\t\tvar tourNodes = player.getNodeIds();\n\t\t\tvar row = 0;\n\t\t\tvar column = 0;\n\t\t\tvar currentIndex = 0;\n\t\t\tvar firstNode;\n\t\t\tfor (var i=0; i < el.ggTagTable.length; i++) {\n\t\t\t\tvar cItem = el.ggTagTable[i];\n\t\t\t\tfirstNode = '';\n\t\t\t\tcItem.nodecount = 0;\n\t\t\t\tfor (var j=0; j < tourNodes.length; j++) {\n\t\t\t\t\tvar nodeData = player.getNodeUserdata(tourNodes[j]);\n\t\t\t\t\tif ((nodeData['tags'].indexOf(cItem.tag) != -1) || (cItem.tag=='')) {\n\t\t\t\t\t\tvar passed = true;\n\t\t\t\t\t\tif (filter.length > 0) {\n\t\t\t\t\t\t\tfor (var k=0; k < filter.length; k++) {\n\t\t\t\t\t\t\t\tif (nodeData['tags'].indexOf(filter[k]) == -1) passed = false;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (passed) {\n\t\t\t\t\t\t\tcItem.nodecount++;\n\t\t\t\t\t\t\tif (firstNode == '') firstNode = tourNodes[j];\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tcItem.firstnode=firstNode;\n\t\t\t\tif (cItem.nodecount == 0) continue;\n\t\t\t\tvar nodeId = {};\n\t\t\t\tnodeId['tag'] = cItem.tag;\n\t\t\t\tnodeId['title'] = cItem.title;\n\t\t\t\tnodeId['nodecount'] = cItem.nodecount;\n\t\t\t\tnodeId['firstnode'] = cItem.firstnode;\n\t\t\t\tvar parameter={};\n\t\t\t\tparameter.top=(row * me._category_cloner.ggHeight) + 'px';\n\t\t\t\tparameter.left=(column * me._category_cloner.ggWidth) + 'px';\n\t\t\t\tparameter.width=me._category_cloner.ggWidth + 'px';\n\t\t\t\tparameter.height=me._category_cloner.ggHeight + 'px';\n\t\t\t\tparameter.index=currentIndex;\n\t\t\t\tvar inst = new SkinCloner_category_cloner_Class(nodeId, me, el, parameter);\n\t\t\t\tcurrentIndex++;\n\t\t\t\tinst.__div.style['height'] = '0px';\n\t\t\t\tel.ggInstances.push(inst);\n\t\t\t\tel.appendChild(inst.__div);\n\t\t\t\tinst.__div.ggObj=inst;\n\t\t\t\tskin.updateSize(inst.__div);\n\t\t\t\tcolumn++;\n\t\t\t\tif (column >= el.ggNumCols) {\n\t\t\t\t\tcolumn = 0;\n\t\t\t\t\trow++;\n\t\t\t\t\tel.ggNumRows++;\n\t\t\t\t}\n\t\t\t}\n\t\t\tme._category_cloner.callChildLogicBlocks_changenode();\n\t\t\tme._category_cloner.callChildLogicBlocks_mouseover();\n\t\t\tme._category_cloner.callChildLogicBlocks_mouseover();\n\t\t\tme._category_cloner.callChildLogicBlocks_active();\n\t\t\tme._category_cloner.callChildLogicBlocks_changevisitednodes();\n\t\t\tme._category_cloner.callChildLogicBlocks_activehotspotchanged();\n\t\t\tme._category_cloner.callChildLogicBlocks_varchanged_open_tag();\n\t\t\tme._category_cloner.ggAutoPosition(true);\n\t\t\tme._category_cloner.ggUpdating = false;\n\t\t\tplayer.triggerEvent('clonerchanged');\n\t\t\tif (me._category_cloner.parentNode.classList.contains('ggskin_subelement') && me._category_cloner.parentNode.parentNode.classList.contains('ggskin_scrollarea')) me._category_cloner.parentNode.parentNode.ggUpdatePosition();\n\t\t}\n\t\tel.ggFilter = [];\n\t\tel.ggTagTable = [\n\t\t\t{tag:\"Outdoor\",title:\"Menu\"},\n\t\t\t];\n\t\tel.ggId=\"category_cloner\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_cloner \";\n\t\tel.ggType='cloner';\n\t\ths ='';\n\t\ths+='height : 128px;';\n\t\ths+='left : 5px;';\n\t\ths+='overflow : visible;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 150px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._category_cloner.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._category_cloner.ggUpdateConditionNodeChange=function () {\n\t\t\tvar cnode=player.getCurrentNode();\n\t\t\tfor(var i=0; i<me._category_cloner.childNodes.length; i++) {\n\t\t\t\tvar child=me._category_cloner.childNodes[i];\n\t\t\t\tif (child.ggObj && child.ggObj.ggNodeId==cnode) {\n\t\t\t var childOffX = child.offsetLeft;\n\t\t\t var childOffY = child.offsetTop;\n\t\t\t\t\tvar p = child.parentElement;\n\t\t\t while (p != null && p!==this.divSkin) {\n\t\t\t\t\t\tif (p.ggType && p.ggType == 'scrollarea') {\n\t\t\t\t\t\t\tp.ggScrollIntoView(childOffX, childOffY, child.clientWidth, child.clientHeight);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tchildOffX += p.offsetLeft;\n\t\t\t\t\t\tchildOffY += p.offsetTop;\n\t\t\t\t\t\tp = p.parentElement;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category_cloner.ggUpdatePosition=function (useTransition) {\n\t\t\t\tme._category_cloner.ggUpdate();\n\t\t}\n\t\tme._category_cloner.ggNodeChange=function () {\n\t\t\tme._category_cloner.ggUpdateConditionNodeChange();\n\t\t}\n\t\tme._category_scroller__content.appendChild(me._category_cloner);\n\t\tme._menu_background.appendChild(me._category_scroller);\n\t\tme.divSkin.appendChild(me._menu_background);\n\t\tel=me._menu_open=document.createElement('div');\n\t\tels=me._menu_open__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJz8+CjwhRE9DVFlQRSBzdmcgUFVCTElDICctLy9XM0MvL0RURCBTVkcgMS4xLy9FTicgJ2h0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCc+CjxzdmcgZmlsbC1vcGFjaXR5PSIxIiBmaWxsPSIjZmZmZmZmIiB4bWw6c3BhY2U9InByZXNlcnZlIiBzdHlsZT0iZW5hYmxlLWJhY2tncm91bmQ6bmV3IDAgMCAzMiAzMjsiIHZpZXdCb3g9IjAgMCAzMiAzMiIgdmVyc2lvbj0iMS4xIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgaGVpZ2h0PSIzMnB4IiB3aWR0aD0iMzJweCIgeG1sbnM9Imh0dHA6Ly'+\n\t\t\t'93d3cudzMub3JnLzIwMDAvc3ZnIiBpZD0iTGF5ZXJfMSI+CiA8cGF0aCBkPSJNNCwxMGgyNGMxLjEwNCwwLDItMC44OTYsMi0ycy0wLjg5Ni0yLTItMkg0QzIuODk2LDYsMiw2Ljg5NiwyLDhTMi44OTYsMTAsNCwxMHogTTI4LDE0SDRjLTEuMTA0LDAtMiwwLjg5Ni0yLDIgIHMwLjg5NiwyLDIsMmgyNGMxLjEwNCwwLDItMC44OTYsMi0yUzI5LjEwNCwxNCwyOCwxNHogTTI4LDIySDRjLTEuMTA0LDAtMiwwLjg5Ni0yLDJzMC44OTYsMiwyLDJoMjRjMS4xMDQsMCwyLTAuODk2LDItMiAgUzI5LjEwNCwyMiwyOCwyMnoiLz4KPC9zdmc+Cg==';\n\t\tme._menu_open__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"menu_open\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 5px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 5px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._menu_open.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._menu_open.logicBlock_position = function() {\n\t\t\tvar newLogicStatePosition;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('category_visible_1') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStatePosition = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStatePosition = -1;\n\t\t\t}\n\t\t\tif (me._menu_open.ggCurrentLogicStatePosition != newLogicStatePosition) {\n\t\t\t\tme._menu_open.ggCurrentLogicStatePosition = newLogicStatePosition;\n\t\t\t\tme._menu_open.style[domTransition]='left 500ms ease 0ms, top 500ms ease 0ms, opacity 500ms ease 0ms';\n\t\t\t\tif (me._menu_open.ggCurrentLogicStatePosition == 0) {\n\t\t\t\t\tme._menu_open.style.left='130px';\n\t\t\t\t\tme._menu_open.style.top='5px';\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._menu_open.style.left='5px';\n\t\t\t\t\tme._menu_open.style.top='5px';\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._menu_open.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['menu_open'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((player.getVariableValue('category_visible_1') == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 1;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._menu_open.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._menu_open.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._menu_open.style[domTransition]='left 500ms ease 0ms, top 500ms ease 0ms, opacity 500ms ease 0ms';\n\t\t\t\tif (me._menu_open.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tme._menu_open.style.visibility=me._menu_open.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._menu_open.style.opacity=1;\n\t\t\t\t}\n\t\t\t\telse if (me._menu_open.ggCurrentLogicStateAlpha == 1) {\n\t\t\t\t\tme._menu_open.style.visibility=me._menu_open.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._menu_open.style.opacity=0.6;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._menu_open.style.visibility=me._menu_open.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._menu_open.style.opacity=1;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._menu_open.onclick=function (e) {\n\t\t\tplayer.setVariableValue('category_visible_1', !player.getVariableValue('category_visible_1'));\n\t\t}\n\t\tme._menu_open.onmouseover=function (e) {\n\t\t\tme.elementMouseOver['menu_open']=true;\n\t\t\tme._menu_open.logicBlock_alpha();\n\t\t}\n\t\tme._menu_open.onmouseout=function (e) {\n\t\t\tme.elementMouseOver['menu_open']=false;\n\t\t\tme._menu_open.logicBlock_alpha();\n\t\t}\n\t\tme._menu_open.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['menu_open']=false;\n\t\t\tme._menu_open.logicBlock_alpha();\n\t\t}\n\t\tme._menu_open.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.divSkin.appendChild(me._menu_open);\n\t\tel=me._screentint_info=document.createElement('div');\n\t\tel.ggId=\"screentint_info\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_rectangle \";\n\t\tel.ggType='rectangle';\n\t\ths ='';\n\t\ths+='background : rgba(0,0,0,0.392157);';\n\t\ths+='border : 0px solid #000000;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 100%;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0%;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 100%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._screentint_info.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._screentint_info.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('vis_info_popup') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._screentint_info.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._screentint_info.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._screentint_info.style[domTransition]='';\n\t\t\t\tif (me._screentint_info.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._screentint_info.style.visibility=(Number(me._screentint_info.style.opacity)>0||!me._screentint_info.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._screentint_info.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._screentint_info.style.visibility=\"hidden\";\n\t\t\t\t\tme._screentint_info.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._screentint_info.onclick=function (e) {\n\t\t\tplayer.setVariableValue('vis_info_popup', false);\n\t\t\tme._info_title.ggText=\"\";\n\t\t\tme._info_title.ggTextDiv.innerHTML=me._info_title.ggText;\n\t\t\tif (me._info_title.ggUpdateText) {\n\t\t\t\tme._info_title.ggUpdateText=function() {\n\t\t\t\t\tvar hs=\"\";\n\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (me._info_title.ggUpdatePosition) {\n\t\t\t\tme._info_title.ggUpdatePosition();\n\t\t\t}\n\t\t\tme._info_title.ggTextDiv.scrollTop = 0;\n\t\t\tme._info_text_body.ggText=\"\";\n\t\t\tme._info_text_body.ggTextDiv.innerHTML=me._info_text_body.ggText;\n\t\t\tif (me._info_text_body.ggUpdateText) {\n\t\t\t\tme._info_text_body.ggUpdateText=function() {\n\t\t\t\t\tvar hs=\"\";\n\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (me._info_text_body.ggUpdatePosition) {\n\t\t\t\tme._info_text_body.ggUpdatePosition();\n\t\t\t}\n\t\t\tme._info_text_body.ggTextDiv.scrollTop = 0;\n\t\t}\n\t\tme._screentint_info.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=((this.ggDx * pw)/100.0 + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme.divSkin.appendChild(me._screentint_info);\n\t\tel=me._information=document.createElement('div');\n\t\tel.ggId=\"information\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='height : 250px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 23.96%;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 300px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._information.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._information.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('vis_info_popup') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._information.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._information.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._information.style[domTransition]='';\n\t\t\t\tif (me._information.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._information.style.visibility=(Number(me._information.style.opacity)>0||!me._information.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._information.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._information.style.visibility=\"hidden\";\n\t\t\t\t\tme._information.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._information.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=((this.ggDx * pw)/100.0 + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._information_bg=document.createElement('div');\n\t\tel.ggId=\"information_bg\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_rectangle \";\n\t\tel.ggType='rectangle';\n\t\ths ='';\n\t\ths+='background : rgba(0,0,0,0.666667);';\n\t\ths+='border : 0px solid #ffffff;';\n\t\ths+='cursor : default;';\n\t\ths+='height : 250px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 300px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._information_bg.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._information_bg.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._information.appendChild(me._information_bg);\n\t\tel=me._info_text_body=document.createElement('div');\n\t\tels=me._info_text_body__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"info_text_body\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='height : 193px;';\n\t\ths+='left : 12px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 47px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 276px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: 276px;';\n\t\ths+='height: 193px;';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: left;';\n\t\ths+='white-space: pre-wrap;';\n\t\ths+='padding: 0px 1px 0px 1px;';\n\t\ths+='overflow: hidden;';\n\t\ths+='overflow-y: auto;';\n\t\tels.setAttribute('style',hs);\n\t\tme._info_text_body.ggUpdateText=function() {\n\t\t\tvar hs=player.hotspot.description;\n\t\t\tif (hs!=this.ggText) {\n\t\t\t\tthis.ggText=hs;\n\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t}\n\t\t}\n\t\tme._info_text_body.ggUpdateText();\n\t\tplayer.addListener('activehotspotchanged', function() {\n\t\t\tme._info_text_body.ggUpdateText();\n\t\t});\n\t\tel.appendChild(els);\n\t\tme._info_text_body.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._info_text_body.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getIsTour() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._info_text_body.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._info_text_body.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._info_text_body.style[domTransition]='';\n\t\t\t\tif (me._info_text_body.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._info_text_body.style.visibility=(Number(me._info_text_body.style.opacity)>0||!me._info_text_body.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._info_text_body.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._info_text_body.style.visibility=(Number(me._info_text_body.style.opacity)>0||!me._info_text_body.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._info_text_body.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._info_text_body.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._information.appendChild(me._info_text_body);\n\t\tel=me._info_title=document.createElement('div');\n\t\tels=me._info_title__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"info_title\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='height : 20px;';\n\t\ths+='left : 12px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 15px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 245px;';\n\t\ths+='pointer-events:auto;';\n\t\ths+='font-weight: bold;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: 245px;';\n\t\ths+='height: 20px;';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: left;';\n\t\ths+='white-space: nowrap;';\n\t\ths+='padding: 0px 1px 0px 1px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=\"\";\n\t\tel.appendChild(els);\n\t\tme._info_title.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._info_title.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._information.appendChild(me._info_title);\n\t\tel=me._info_popup_close=document.createElement('div');\n\t\tels=me._info_popup_close__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWw6c3BhY2U9InByZXNlcnZlIiB5PSIwcHgiIHZpZXdCb3g9Ii0yNDAgMzMyIDEzMCAxMzAiIHZlcnNpb249IjEuMSIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgaWQ9IkxheWVyXzEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZmlsbD0iIzAwMDAwMCIgZD0iTS0xMzUuMywzNTcuM2MtMjEuOS0yMS45LTU3LjUtMjEuOS03OS40LDBjLTIxLjksMjEuOS0yMS45LDU3LjUsMCw3OS40YzIxLjksMjEuOSw1Ny41LDIxLjksNzkuNCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTtTLTExMy40LDM3OS4yLTEzNS4zLDM1Ny4zeiBNLTE0NS44LDQxMi43YzAuOCwwLjgsMC44LDEuNS0wLjEsMi40bC0xMC45LDEwLjljLTAuNCwwLjQtMC44LDAuNS0xLjMsMC41Yy0wLjUsMC0wLjktMC4xLTEuMS0wLjQmI3hkOyYjeGE7JiN4OTsmI3g5O2wtMTUuOC0xNS44bC0xNS43LDE1LjdjLTAuNCwwLjQtMC44LDAuNS0x'+\n\t\t\t'LjMsMC41cy0wLjktMC4xLTEuMS0wLjRsLTExLjEtMTEuMWMtMC4zLTAuMy0wLjQtMC42LTAuNC0xLjFjMC0wLjUsMC4xLTAuOSwwLjUtMS4zJiN4ZDsmI3hhOyYjeDk7JiN4OTtsMTUuNy0xNS43bC0xNS44LTE1LjhjLTAuMy0wLjMtMC40LTAuNi0wLjQtMS4xYzAtMC41LDAuMS0wLjksMC41LTEuM2wxMC45LTEwLjljMC45LTAuOSwxLjctMC45LDIuNC0wLjFsMTUuOCwxNS44bDE1LjctMTUuNyYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuOS0wLjksMS43LTAuOSwyLjQtMC4xbDExLjEsMTEuMWMwLjgsMC44LDAuOCwxLjUtMC4xLDIuNGwtMTUuNywxNS43TC0xNDUuOCw0MTIuN3oiLz4KIDwvZz4KID'+\n\t\t\t'xnIGlkPSJMYXllcl8yIj4KICA8cGF0aCBmaWxsPSIjRkZGRkZGIiBkPSJNLTE2MS42LDM5Ni45bDE1LjgsMTUuOGMwLjgsMC44LDAuOCwxLjUtMC4xLDIuNGwtMTAuOSwxMC45Yy0wLjQsMC40LTAuOCwwLjUtMS4zLDAuNSYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjUsMC0wLjktMC4xLTEuMS0wLjRsLTE1LjgtMTUuOGwtMTUuNywxNS43Yy0wLjQsMC40LTAuOCwwLjUtMS4zLDAuNXMtMC45LTAuMS0xLjEtMC40bC0xMS4xLTExLjFjLTAuMy0wLjMtMC40LTAuNi0wLjQtMS4xJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC0wLjUsMC4xLTAuOSwwLjUtMS4zbDE1LjctMTUuN2wtMTUuOC0xNS44Yy0wLjMt'+\n\t\t\t'MC4zLTAuNC0wLjYtMC40LTEuMWMwLTAuNSwwLjEtMC45LDAuNS0xLjNsMTAuOS0xMC45YzAuOS0wLjksMS43LTAuOSwyLjQtMC4xJiN4ZDsmI3hhOyYjeDk7JiN4OTtsMTUuOCwxNS44bDE1LjctMTUuN2MwLjktMC45LDEuNy0wLjksMi40LTAuMWwxMS4xLDExLjFjMC44LDAuOCwwLjgsMS41LTAuMSwyLjRMLTE2MS42LDM5Ni45eiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._info_popup_close__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._info_popup_close__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWw6c3BhY2U9InByZXNlcnZlIiB5PSIwcHgiIHZpZXdCb3g9Ii0yNDAgMzMyIDEzMCAxMzAiIHZlcnNpb249IjEuMSIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgaWQ9IkxheWVyXzEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZmlsbD0iIzAwMDAwMCIgZD0iTS0xMzAuOSwzNTIuOWMtMjQuNC0yNC40LTYzLjgtMjQuNC04OC4yLDBjLTI0LjQsMjQuNC0yNC40LDYzLjgsMCw4OC4yYzI0LjQsMjQuNCw2My44LDI0LjQsODguMiwwJiN4ZDsmI3hhOyYjeDk7JiN4OTtTLTEwNi41LDM3Ny4zLTEzMC45LDM1Mi45eiBNLTE0Mi41LDQxNC41YzAuOCwwLjgsMC44LDEuNy0wLjEsMi43bC0xMi4yLDEyLjJjLTAuNCwwLjQtMC44LDAuNi0xLjQsMC42Yy0wLjYsMC0xLTAuMS0xLjMtMC40JiN4ZDsmI3hhOyYjeDk7JiN4OTtsLTE3LjUtMTcuNWwtMTcuNCwxNy40Yy0wLjQsMC40LTAuOCwwLjYtMS40'+\n\t\t\t'LDAuNmMtMC42LDAtMS0wLjEtMS4zLTAuNGwtMTIuMy0xMi4zYy0wLjMtMC4zLTAuNC0wLjctMC40LTEuM2MwLTAuNiwwLjEtMSwwLjYtMS40JiN4ZDsmI3hhOyYjeDk7JiN4OTtsMTcuNC0xNy40bC0xNy41LTE3LjVjLTAuMy0wLjMtMC40LTAuNy0wLjQtMS4zYzAtMC42LDAuMS0xLDAuNi0xLjRsMTIuMi0xMi4yYzEtMSwxLjgtMSwyLjctMC4xbDE3LjUsMTcuNWwxNy40LTE3LjQmI3hkOyYjeGE7JiN4OTsmI3g5O2MxLTEsMS44LTEsMi43LTAuMWwxMi4zLDEyLjNjMC44LDAuOCwwLjgsMS43LTAuMSwyLjdsLTE3LjQsMTcuNEwtMTQyLjUsNDE0LjV6Ii8+CiA8L2c+CiA8ZyBpZD0iTGF5ZXJfMi'+\n\t\t\t'I+CiAgPHBhdGggZmlsbD0iI0ZGRkZGRiIgZD0iTS0xNjAuMSwzOTYuOWwxNy41LDE3LjVjMC44LDAuOCwwLjgsMS43LTAuMSwyLjdsLTEyLjIsMTIuMmMtMC40LDAuNC0wLjgsMC42LTEuNCwwLjYmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC42LDAtMS0wLjEtMS4zLTAuNGwtMTcuNS0xNy41bC0xNy40LDE3LjRjLTAuNCwwLjQtMC44LDAuNi0xLjQsMC42Yy0wLjYsMC0xLTAuMS0xLjMtMC40bC0xMi4zLTEyLjNjLTAuMy0wLjMtMC40LTAuNy0wLjQtMS4zJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC0wLjYsMC4xLTEsMC42LTEuNGwxNy40LTE3LjRsLTE3LjUtMTcuNWMtMC4zLTAuMy0wLjQtMC43LTAu'+\n\t\t\t'NC0xLjNjMC0wLjYsMC4xLTEsMC42LTEuNGwxMi4yLTEyLjJjMS0xLDEuOC0xLDIuNy0wLjFsMTcuNSwxNy41JiN4ZDsmI3hhOyYjeDk7JiN4OTtsMTcuNC0xNy40YzEtMSwxLjgtMSwyLjctMC4xbDEyLjMsMTIuM2MwLjgsMC44LDAuOCwxLjctMC4xLDIuN0wtMTYwLjEsMzk2Ljl6Ii8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._info_popup_close__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"info_popup_close\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='position : absolute;';\n\t\ths+='right : 5px;';\n\t\ths+='top : 4px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._info_popup_close.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._info_popup_close.onclick=function (e) {\n\t\t\tplayer.setVariableValue('vis_info_popup', false);\n\t\t\tme._info_title.ggText=\"\";\n\t\t\tme._info_title.ggTextDiv.innerHTML=me._info_title.ggText;\n\t\t\tif (me._info_title.ggUpdateText) {\n\t\t\t\tme._info_title.ggUpdateText=function() {\n\t\t\t\t\tvar hs=\"\";\n\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (me._info_title.ggUpdatePosition) {\n\t\t\t\tme._info_title.ggUpdatePosition();\n\t\t\t}\n\t\t\tme._info_title.ggTextDiv.scrollTop = 0;\n\t\t\tme._info_text_body.ggText=\"\";\n\t\t\tme._info_text_body.ggTextDiv.innerHTML=me._info_text_body.ggText;\n\t\t\tif (me._info_text_body.ggUpdateText) {\n\t\t\t\tme._info_text_body.ggUpdateText=function() {\n\t\t\t\t\tvar hs=\"\";\n\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (me._info_text_body.ggUpdatePosition) {\n\t\t\t\tme._info_text_body.ggUpdatePosition();\n\t\t\t}\n\t\t\tme._info_text_body.ggTextDiv.scrollTop = 0;\n\t\t}\n\t\tme._info_popup_close.onmouseover=function (e) {\n\t\t\tme._info_popup_close__img.style.visibility='hidden';\n\t\t\tme._info_popup_close__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._info_popup_close.onmouseout=function (e) {\n\t\t\tme._info_popup_close__img.style.visibility='inherit';\n\t\t\tme._info_popup_close__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._info_popup_close.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._information.appendChild(me._info_popup_close);\n\t\tme.divSkin.appendChild(me._information);\n\t\tplayer.addListener('sizechanged', function() {\n\t\t\tme.updateSize(me.divSkin);\n\t\t});\n\t\tplayer.addListener('configloaded', function() {\n\t\t\tme._category_cloner.ggUpdate();\n\t\t});\n\t\tplayer.addListener('imagesready', function() {\n\t\t\tme._category_scroller.ggUpdatePosition();\n\t\t});\n\t};\n\tthis.hotspotProxyClick=function(id, url) {\n\t}\n\tthis.hotspotProxyDoubleClick=function(id, url) {\n\t}\n\tme.hotspotProxyOver=function(id, url) {\n\t}\n\tme.hotspotProxyOut=function(id, url) {\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_changenode = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._chevron_white_lower && hotspotTemplates['ht_node'][i]._chevron_white_lower.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._chevron_white_lower.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._chevron_black && hotspotTemplates['ht_node'][i]._chevron_black.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._chevron_black.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._chevron_white && hotspotTemplates['ht_node'][i]._chevron_white.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._chevron_white.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._hs_preview_image && hotspotTemplates['ht_node'][i]._hs_preview_image.logicBlock_alpha) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._hs_preview_image.logicBlock_alpha();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._tt_ht_3d && hotspotTemplates['ht_node'][i]._tt_ht_3d.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._tt_ht_3d.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_node_customimage && hotspotTemplates['ht_node'][i]._ht_node_customimage.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_node_customimage.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._hs_tt && hotspotTemplates['ht_node'][i]._hs_tt.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._hs_tt.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_configloaded = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._hs_preview_image && hotspotTemplates['ht_node'][i]._hs_preview_image.logicBlock_alpha) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._hs_preview_image.logicBlock_alpha();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._tt_ht_3d && hotspotTemplates['ht_node'][i]._tt_ht_3d.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._tt_ht_3d.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_mouseover = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._chevron_white_lower && hotspotTemplates['ht_node'][i]._chevron_white_lower.logicBlock_alpha) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._chevron_white_lower.logicBlock_alpha();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._chevron_black && hotspotTemplates['ht_node'][i]._chevron_black.logicBlock_alpha) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._chevron_black.logicBlock_alpha();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._chevron_white && hotspotTemplates['ht_node'][i]._chevron_white.logicBlock_alpha) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._chevron_white.logicBlock_alpha();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._hs_preview_image && hotspotTemplates['ht_node'][i]._hs_preview_image.logicBlock_alpha) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._hs_preview_image.logicBlock_alpha();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._tt_ht_3d && hotspotTemplates['ht_node'][i]._tt_ht_3d.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._tt_ht_3d.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_active = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._hs_visited && hotspotTemplates['ht_node'][i]._hs_visited.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._hs_visited.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_changevisitednodes = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._hs_visited && hotspotTemplates['ht_node'][i]._hs_visited.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._hs_visited.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_activehotspotchanged = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._chevron_white_lower && hotspotTemplates['ht_node'][i]._chevron_white_lower.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._chevron_white_lower.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._chevron_black && hotspotTemplates['ht_node'][i]._chevron_black.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._chevron_black.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._chevron_white && hotspotTemplates['ht_node'][i]._chevron_white.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._chevron_white.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._tt_ht_3d && hotspotTemplates['ht_node'][i]._tt_ht_3d.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._tt_ht_3d.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_node_customimage && hotspotTemplates['ht_node'][i]._ht_node_customimage.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_node_customimage.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._hs_tt && hotspotTemplates['ht_node'][i]._hs_tt.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._hs_tt.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_varchanged_opt_3d_preview = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._hs_preview_image && hotspotTemplates['ht_node'][i]._hs_preview_image.logicBlock_alpha) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._hs_preview_image.logicBlock_alpha();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._tt_ht_3d && hotspotTemplates['ht_node'][i]._tt_ht_3d.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._tt_ht_3d.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_info_changenode = function(){\n\t\tif(hotspotTemplates['ht_info']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_info'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_info'][i]._ht_info_image && hotspotTemplates['ht_info'][i]._ht_info_image.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_info'][i]._ht_info_image.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_info'][i]._tt_information && hotspotTemplates['ht_info'][i]._tt_information.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_info'][i]._tt_information.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_info'][i]._ht_info_customimage && hotspotTemplates['ht_info'][i]._ht_info_customimage.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_info'][i]._ht_info_customimage.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_info_configloaded = function(){\n\t\tif(hotspotTemplates['ht_info']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_info'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_info'][i]._tt_information && hotspotTemplates['ht_info'][i]._tt_information.logicBlock_position) {\n\t\t\t\t\thotspotTemplates['ht_info'][i]._tt_information.logicBlock_position();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_info_mouseover = function(){\n\t\tif(hotspotTemplates['ht_info']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_info'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_info'][i]._tt_information && hotspotTemplates['ht_info'][i]._tt_information.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_info'][i]._tt_information.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_info_hastouch = function(){\n\t\tif(hotspotTemplates['ht_info']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_info'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_info'][i]._tt_information && hotspotTemplates['ht_info'][i]._tt_information.logicBlock_position) {\n\t\t\t\t\thotspotTemplates['ht_info'][i]._tt_information.logicBlock_position();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_info_activehotspotchanged = function(){\n\t\tif(hotspotTemplates['ht_info']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_info'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_info'][i]._ht_info_image && hotspotTemplates['ht_info'][i]._ht_info_image.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_info'][i]._ht_info_image.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_info'][i]._tt_information && hotspotTemplates['ht_info'][i]._tt_information.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_info'][i]._tt_information.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_info'][i]._ht_info_customimage && hotspotTemplates['ht_info'][i]._ht_info_customimage.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_info'][i]._ht_info_customimage.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tplayer.addListener('changenode', function() {\n\t\tme.ggUserdata=player.userdata;\n\t});\n\tme.skinTimerEvent=function() {\n\t\tme.ggCurrentTime=new Date().getTime();\n\t};\n\tplayer.addListener('timer', me.skinTimerEvent);\n\tfunction SkinHotspotClass_ht_node(parentScope,hotspot) {\n\t\tvar me=this;\n\t\tvar flag=false;\n\t\tvar hs='';\n\t\tme.parentScope=parentScope;\n\t\tme.hotspot=hotspot;\n\t\tvar nodeId=String(hotspot.url);\n\t\tnodeId=(nodeId.charAt(0)=='{')?nodeId.substr(1, nodeId.length - 2):''; // }\n\t\tme.ggUserdata=skin.player.getNodeUserdata(nodeId);\n\t\tme.elementMouseDown=[];\n\t\tme.elementMouseOver=[];\n\t\tme.findElements=function(id,regex) {\n\t\t\treturn skin.findElements(id,regex);\n\t\t}\n\t\tel=me._ht_node=document.createElement('div');\n\t\tel.ggId=\"ht_node\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_hotspot \";\n\t\tel.ggType='hotspot';\n\t\ths ='';\n\t\ths+='height : 0px;';\n\t\ths+='left : 71px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 220px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 0px;';\n\t\ths+='pointer-events:auto;';\n\t\ths+='transform-style: preserve-3d;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_node.ggIsActive=function() {\n\t\t\treturn player.getCurrentNode()==this.ggElementNodeId();\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif (me.hotspot.url!='' && me.hotspot.url.charAt(0)=='{') { // }\n\t\t\t\treturn me.hotspot.url.substr(1, me.hotspot.url.length - 2);\n\t\t\t} else {\n\t\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t\t} else {\n\t\t\t\t\treturn player.getCurrentNode();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_node.onclick=function (e) {\n\t\t\tplayer.openNext(me.hotspot.url,me.hotspot.target);\n\t\t\tskin.hotspotProxyClick(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_node.ondblclick=function (e) {\n\t\t\tskin.hotspotProxyDoubleClick(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_node.onmouseover=function (e) {\n\t\t\tplayer.setActiveHotspot(me.hotspot);\n\t\t\tme.elementMouseOver['ht_node']=true;\n\t\t\tme._chevron_white_lower.logicBlock_alpha();\n\t\t\tme._chevron_black.logicBlock_alpha();\n\t\t\tme._chevron_white.logicBlock_alpha();\n\t\t\tme._hs_preview_image.logicBlock_alpha();\n\t\t\tme._tt_ht_3d.logicBlock_visible();\n\t\t\tskin.hotspotProxyOver(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_node.onmouseout=function (e) {\n\t\t\tplayer.setActiveHotspot(null);\n\t\t\tme.elementMouseOver['ht_node']=false;\n\t\t\tme._chevron_white_lower.logicBlock_alpha();\n\t\t\tme._chevron_black.logicBlock_alpha();\n\t\t\tme._chevron_white.logicBlock_alpha();\n\t\t\tme._hs_preview_image.logicBlock_alpha();\n\t\t\tme._tt_ht_3d.logicBlock_visible();\n\t\t\tskin.hotspotProxyOut(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_node.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['ht_node']=false;\n\t\t\tme._chevron_white_lower.logicBlock_alpha();\n\t\t\tme._chevron_black.logicBlock_alpha();\n\t\t\tme._chevron_white.logicBlock_alpha();\n\t\t\tme._hs_preview_image.logicBlock_alpha();\n\t\t\tme._tt_ht_3d.logicBlock_visible();\n\t\t}\n\t\tme._ht_node.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._chevron_white_lower=document.createElement('div');\n\t\tels=me._chevron_white_lower__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDIyLjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHhtbDpzcGFjZT0icHJlc2VydmUiIHN0eWxlPSJlbmFibGUtYmFja2dyb3VuZDpuZXcgMCAwIDEwMDAgMTAwMDsiIHk9IjBweCIgdmlld0JveD0iMCAwIDEwMDAgMTAwMCIgdmVyc2lvbj0iMS4wIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIG'+\n\t\t\t'lkPSJMYXllcl8xIj4KIDxzdHlsZSB0eXBlPSJ0ZXh0L2NzcyI+Cgkuc3Qwe2ZpbGw6IzAwMmY2Yzt9Cjwvc3R5bGU+CiA8Zz4KICA8cGF0aCBkPSJNMzQuOSw0MzkuN2w0MDAtNDAxYzE3LjktMTcuOSw0MS43LTI1LjQsNjUuMi0yNGMyMy40LTEuNCw0Ny4yLDYuMSw2NS4xLDI0bDQwMCw0MDEmI3hhOyYjeDk7JiN4OTtjMzMuMiwzMy4zLDMzLjIsODcuNCwwLDEyMC43Yy0zMy4yLDMzLjMtODcuMSwzMy4zLTEyMC40LDBMNTAwLDIxNC43TDE1NS4yLDU2MC40Yy0zMy4yLDMzLjMtODcuMSwzMy4zLTEyMC40LDAmI3hhOyYjeDk7JiN4OTtTMS43LDQ3MywzNC45LDQzOS43eiIgY2xhc3M9InN0MCIv'+\n\t\t\t'PgogPC9nPgo8L3N2Zz4K';\n\t\tme._chevron_white_lower__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"chevron_white_lower\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 80px;';\n\t\ths+='left : -10000px;';\n\t\ths+='opacity : 0.6;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -140px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 80px;';\n\t\ths+='pointer-events:auto;';\n\t\ths+='transform:translate3d(0px,0px,-1px);';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._chevron_white_lower.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._chevron_white_lower.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.hotspot.customimage != \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._chevron_white_lower.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._chevron_white_lower.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._chevron_white_lower.style[domTransition]='opacity 500ms ease 0ms';\n\t\t\t\tif (me._chevron_white_lower.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._chevron_white_lower.style.visibility=\"hidden\";\n\t\t\t\t\tme._chevron_white_lower.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._chevron_white_lower.style.visibility=(Number(me._chevron_white_lower.style.opacity)>0||!me._chevron_white_lower.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._chevron_white_lower.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._chevron_white_lower.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['ht_node'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._chevron_white_lower.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._chevron_white_lower.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._chevron_white_lower.style[domTransition]='opacity 500ms ease 0ms';\n\t\t\t\tif (me._chevron_white_lower.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tme._chevron_white_lower.style.visibility=me._chevron_white_lower.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._chevron_white_lower.style.opacity=1;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._chevron_white_lower.style.visibility=me._chevron_white_lower.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._chevron_white_lower.style.opacity=0.6;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._chevron_white_lower.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._ht_node.appendChild(me._chevron_white_lower);\n\t\tel=me._chevron_black=document.createElement('div');\n\t\tels=me._chevron_black__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDIyLjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHhtbDpzcGFjZT0icHJlc2VydmUiIHk9IjBweCIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAgMTAwMCAxMDAwOyIgdmlld0JveD0iMCAwIDEwMDAgMTAwMCIgdmVyc2lvbj0iMS4wIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3'+\n\t\t\t'JnLzIwMDAvc3ZnIj4KIDxnPgogIDxwYXRoIGQ9Ik0zNC45LDQzOS43bDQwMC00MDFjMTcuOS0xNy45LDQxLjctMjUuNCw2NS4yLTI0YzIzLjQtMS40LDQ3LjIsNi4xLDY1LjEsMjRsNDAwLDQwMWMzMy4yLDMzLjMsMzMuMiw4Ny40LDAsMTIwLjcmI3hhOyYjeDk7JiN4OTtjLTMzLjIsMzMuMy04Ny4xLDMzLjMtMTIwLjQsMEw1MDAsMjE0LjdMMTU1LjIsNTYwLjRjLTMzLjIsMzMuMy04Ny4xLDMzLjMtMTIwLjQsMFMxLjcsNDczLDM0LjksNDM5Ljd6Ii8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._chevron_black__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"chevron_black\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 80px;';\n\t\ths+='left : -10000px;';\n\t\ths+='opacity : 0.4;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -140px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 80px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._chevron_black.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._chevron_black.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.hotspot.customimage != \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._chevron_black.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._chevron_black.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._chevron_black.style[domTransition]='opacity 500ms ease 0ms';\n\t\t\t\tif (me._chevron_black.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._chevron_black.style.visibility=\"hidden\";\n\t\t\t\t\tme._chevron_black.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._chevron_black.style.visibility=(Number(me._chevron_black.style.opacity)>0||!me._chevron_black.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._chevron_black.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._chevron_black.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['ht_node'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._chevron_black.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._chevron_black.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._chevron_black.style[domTransition]='opacity 500ms ease 0ms';\n\t\t\t\tif (me._chevron_black.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tme._chevron_black.style.visibility=me._chevron_black.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._chevron_black.style.opacity=1;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._chevron_black.style.visibility=me._chevron_black.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._chevron_black.style.opacity=0.4;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._chevron_black.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._ht_node.appendChild(me._chevron_black);\n\t\tel=me._chevron_white=document.createElement('div');\n\t\tels=me._chevron_white__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDIyLjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHhtbDpzcGFjZT0icHJlc2VydmUiIHN0eWxlPSJlbmFibGUtYmFja2dyb3VuZDpuZXcgMCAwIDEwMDAgMTAwMDsiIHk9IjBweCIgdmlld0JveD0iMCAwIDEwMDAgMTAwMCIgdmVyc2lvbj0iMS4wIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIG'+\n\t\t\t'lkPSJMYXllcl8xIj4KIDxzdHlsZSB0eXBlPSJ0ZXh0L2NzcyI+Cgkuc3Qwe2ZpbGw6IzAwMmY2Yzt9Cjwvc3R5bGU+CiA8Zz4KICA8cGF0aCBkPSJNMzQuOSw0MzkuN2w0MDAtNDAxYzE3LjktMTcuOSw0MS43LTI1LjQsNjUuMi0yNGMyMy40LTEuNCw0Ny4yLDYuMSw2NS4xLDI0bDQwMCw0MDEmI3hhOyYjeDk7JiN4OTtjMzMuMiwzMy4zLDMzLjIsODcuNCwwLDEyMC43Yy0zMy4yLDMzLjMtODcuMSwzMy4zLTEyMC40LDBMNTAwLDIxNC43TDE1NS4yLDU2MC40Yy0zMy4yLDMzLjMtODcuMSwzMy4zLTEyMC40LDAmI3hhOyYjeDk7JiN4OTtTMS43LDQ3MywzNC45LDQzOS43eiIgY2xhc3M9InN0MCIv'+\n\t\t\t'PgogPC9nPgo8L3N2Zz4K';\n\t\tme._chevron_white__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"chevron_white\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 80px;';\n\t\ths+='left : -10000px;';\n\t\ths+='opacity : 0.6;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -140px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 80px;';\n\t\ths+='pointer-events:auto;';\n\t\ths+='transform:translate3d(0px,0px,1px);';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._chevron_white.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._chevron_white.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.hotspot.customimage != \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._chevron_white.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._chevron_white.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._chevron_white.style[domTransition]='opacity 500ms ease 0ms';\n\t\t\t\tif (me._chevron_white.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._chevron_white.style.visibility=\"hidden\";\n\t\t\t\t\tme._chevron_white.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._chevron_white.style.visibility=(Number(me._chevron_white.style.opacity)>0||!me._chevron_white.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._chevron_white.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._chevron_white.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['ht_node'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._chevron_white.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._chevron_white.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._chevron_white.style[domTransition]='opacity 500ms ease 0ms';\n\t\t\t\tif (me._chevron_white.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tme._chevron_white.style.visibility=me._chevron_white.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._chevron_white.style.opacity=1;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._chevron_white.style.visibility=me._chevron_white.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._chevron_white.style.opacity=0.6;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._chevron_white.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._ht_node.appendChild(me._chevron_white);\n\t\tel=me._hs_preview_image=document.createElement('div');\n\t\tels=me._hs_preview_image__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_nodeimage';\n\t\tels.setAttribute('src',basePath + \"images/hs_preview_image_\" + nodeId + \".jpg\");\n\t\tel.ggNodeId=nodeId;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_nodeimage';\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"hs_preview_image\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_nodeimage \";\n\t\tel.ggType='nodeimage';\n\t\ths ='';\n\t\ths+='z-index: -5;';\n\t\ths+='height : 90px;';\n\t\ths+='left : -10000px;';\n\t\ths+='opacity : 0;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -220px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 140px;';\n\t\ths+='pointer-events:none;';\n\t\ths+='border-radius: 5px; overflow: hidden; box-shadow: 0px 0px 2px #000000; transform:translate3d(0px,0px,90px) rotateX(-90deg) scale(1.5); transform-style: preserve-3d; -webkit-backface-visibility: hidden; backface-visibility: hidden;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._hs_preview_image.ggIsActive=function() {\n\t\t\treturn player.getCurrentNode()==this.ggElementNodeId();\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn this.ggNodeId;\n\t\t}\n\t\tme._hs_preview_image.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['ht_node'] == true)) && \n\t\t\t\t((player.getVariableValue('opt_3d_preview') == true)) && \n\t\t\t\t((player.getIsTour() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._hs_preview_image.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._hs_preview_image.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._hs_preview_image.style[domTransition]='opacity 500ms ease 0ms';\n\t\t\t\tif (me._hs_preview_image.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tme._hs_preview_image.style.visibility=me._hs_preview_image.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._hs_preview_image.style.opacity=1;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tsetTimeout(function() { if (me._hs_preview_image.style.opacity == 0.0) { me._hs_preview_image.style.visibility=\"hidden\"; } }, 505);\n\t\t\t\t\tme._hs_preview_image.style.opacity=0;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._hs_preview_image.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._hs_tt=document.createElement('div');\n\t\tels=me._hs_tt__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"hs_tt\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='bottom : 0px;';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 140px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 100%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='bottom: 0px;';\n\t\ths+='width: 140px;';\n\t\ths+='height: auto;';\n\t\ths+='pointer-events: none;';\n\t\ths+='background: #000000;';\n\t\ths+='background: rgba(0,0,0,0.196078);';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='font-size: 12px;';\n\t\ths+='font-weight: inherit;';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: pre-wrap;';\n\t\ths+='padding: 0px 2px 0px 2px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=me.hotspot.title;\n\t\tel.appendChild(els);\n\t\tme._hs_tt.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._hs_tt.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.hotspot.title == \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._hs_tt.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._hs_tt.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._hs_tt.style[domTransition]='';\n\t\t\t\tif (me._hs_tt.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._hs_tt.style.visibility=\"hidden\";\n\t\t\t\t\tme._hs_tt.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._hs_tt.style.visibility=(Number(me._hs_tt.style.opacity)>0||!me._hs_tt.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._hs_tt.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._hs_tt.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._hs_preview_image.appendChild(me._hs_tt);\n\t\tel=me._hs_visited=document.createElement('div');\n\t\tels=me._hs_visited__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHhtbDpzcGFjZT0icHJlc2VydmUiIHk9IjBweCIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAtMjQwIDMzMiAxMzAgMTMwOyIgdmlld0JveD0iLTI0MCAzMzIgMTMwIDEzMCIgdmVyc2lvbj0iMS4xIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3'+\n\t\t\t'cudzMub3JnLzIwMDAvc3ZnIj4KIDxzdHlsZSB0eXBlPSJ0ZXh0L2NzcyI+JiN4ZDsKCS5zdDB7ZmlsbDojMDAwMDAwO30mI3hkOwoJLnN0MXtmaWxsOiNGRkZGRkY7fSYjeGQ7Cjwvc3R5bGU+CiA8ZyBpZD0iTGF5ZXJfMV8xXyIvPgogPGcgaWQ9IkxheWVyXzIiPgogIDxwYXRoIGQ9Ik0tMTIyLjEsMzQxLjVoLTEwNS44Yy0xLjQsMC0yLjYsMS4xLTIuNiwyLjZ2MTA1LjhjMCwxLjQsMS4xLDIuNiwyLjYsMi42aDEwNS44YzEuNCwwLDIuNi0xLjEsMi42LTIuNlYzNDQuMSYjeGQ7JiN4YTsmI3g5OyYjeDk7Qy0xMTkuNiwzNDIuNy0xMjAuNywzNDEuNS0xMjIuMSwzNDEuNXogTS0xMzIuOCwzODEu'+\n\t\t\t'N2wtNTAuOCw1MC44Yy0wLjMsMC4zLTAuOCwwLjUtMS4yLDAuNWMtMC41LDAtMC45LTAuMS0xLjMtMC41bC0zMS43LTMxLjgmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC43LTAuNy0wLjctMS43LDAtMi40bDEyLjUtMTIuNWMwLjctMC43LDEuNy0wLjcsMi40LDBsMTgsMThsMzcuMS0zNy4xYzAuNy0wLjcsMS43LTAuNywyLjQsMGwxMi41LDEyLjUmI3hkOyYjeGE7JiN4OTsmI3g5O0MtMTMyLjEsMzc5LjktMTMyLjEsMzgxLTEzMi44LDM4MS43eiIgY2xhc3M9InN0MCIvPgogIDxwYXRoIGQ9Ik0tMTQ3LjcsMzY2LjhsLTM3LjEsMzcuMWwtMTgtMThjLTAuNy0wLjctMS43LTAuNy0yLjQsMGwtMTIuNS'+\n\t\t\t'wxMi41Yy0wLjcsMC43LTAuNywxLjcsMCwyLjRsMzEuNywzMS44JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4zLDAuMywwLjgsMC41LDEuMywwLjVjMC40LDAsMC45LTAuMiwxLjItMC41bDUwLjgtNTAuOWMwLjctMC43LDAuNy0xLjcsMC0yLjRsLTEyLjUtMTIuNUMtMTQ1LjksMzY2LjEtMTQ3LDM2Ni4xLTE0Ny43LDM2Ni44eiIgY2xhc3M9InN0MSIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._hs_visited__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"hs_visited\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='height : 20px;';\n\t\ths+='position : absolute;';\n\t\ths+='right : 5px;';\n\t\ths+='top : 5px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 20px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._hs_visited.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._hs_visited.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me._hs_visited.ggIsActive() == true)) || \n\t\t\t\t((player.nodeVisited(me._hs_visited.ggElementNodeId()) == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._hs_visited.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._hs_visited.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._hs_visited.style[domTransition]='';\n\t\t\t\tif (me._hs_visited.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._hs_visited.style.visibility=(Number(me._hs_visited.style.opacity)>0||!me._hs_visited.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._hs_visited.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._hs_visited.style.visibility=\"hidden\";\n\t\t\t\t\tme._hs_visited.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._hs_visited.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._hs_preview_image.appendChild(me._hs_visited);\n\t\tme._ht_node.appendChild(me._hs_preview_image);\n\t\tel=me.__code=document.createElement('div');\n\t\tels=me.__code__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"_code\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='height : 37px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -39px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 66px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: 68px;';\n\t\ths+='height: 39px;';\n\t\ths+='pointer-events: none;';\n\t\ths+='background: #ffffff;';\n\t\ths+='border: 1px solid #000000;';\n\t\ths+='color: #000000;';\n\t\ths+='text-align: left;';\n\t\ths+='white-space: nowrap;';\n\t\ths+='padding: 0px 2px 0px 2px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=\"\";\nthis.onUpdatePosition=function(player,hotspot) {\nvar vs=player.getViewerSize();\nvar y=vs.height * (1/6*(1+Math.cos(player.getTilt() * Math.PI/90.0)));\nvar hs= 'translate3d(0px,0px,-1000px) perspective(500px) translate3d(0px,' + (y) + 'px,0px) ';\nhs += 'rotateZ(' + ( player.getRoll()).toFixed(10) + 'deg) ';\nhs += 'rotateX(' + ( player.getTilt()).toFixed(10) + 'deg) ';\nhs += 'rotateY(' + (-player.getPan()).toFixed(10) + 'deg) ';\nhs += 'rotateY(' + ( hotspot.pan).toFixed(2) + 'deg) ';\nhs += 'rotateX(' + (-hotspot.tilt).toFixed(2) + 'deg) ';\nhs += 'rotateX(90deg) ';\nthis.__div.style.transform=hs;\nthis.__div.style.left = vs.width / 2 + \"px\";\nthis.__div.style.top = vs.height / 2 + \"px\";\n};\n\t\tel.appendChild(els);\n\t\tme.__code.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme.__code.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._ht_node.appendChild(me.__code);\n\t\tel=me._tt_ht_3d=document.createElement('div');\n\t\tels=me._tt_ht_3d__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"tt_ht_3d\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='z-index: 100;';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -170px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 140px;';\n\t\ths+='pointer-events:none;';\n\t\ths+='transform:translate3d(0px,0px,40px) rotateX(-90deg); font-size: 15px; -webkit-backface-visibility: hidden; backface-visibility: hidden;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 100%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: auto;';\n\t\ths+='height: auto;';\n\t\ths+='pointer-events: none;';\n\t\ths+='background: #000000;';\n\t\ths+='background: rgba(0,0,0,0.666667);';\n\t\ths+='border: 1px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='font-size: 16px;';\n\t\ths+='font-weight: inherit;';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: nowrap;';\n\t\ths+='padding: 0px 2px 0px 2px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=me.hotspot.title;\n\t\tel.appendChild(els);\n\t\tme._tt_ht_3d.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._tt_ht_3d.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getIsTour() == false)) && \n\t\t\t\t((me.hotspot.title != \"\")) && \n\t\t\t\t((me.elementMouseOver['ht_node'] == true)) && \n\t\t\t\t((player.getVariableValue('opt_3d_preview') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._tt_ht_3d.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._tt_ht_3d.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._tt_ht_3d.style[domTransition]='';\n\t\t\t\tif (me._tt_ht_3d.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._tt_ht_3d.style.visibility=(Number(me._tt_ht_3d.style.opacity)>0||!me._tt_ht_3d.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._tt_ht_3d.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_ht_3d.style.visibility=\"hidden\";\n\t\t\t\t\tme._tt_ht_3d.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_ht_3d.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 2;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t\tthis.style[domTransition]='left 0';\n\t\t\tthis.ggTextDiv.style.left=((142-this.ggTextDiv.offsetWidth)/2) + 'px';\n\t\t}\n\t\tme._ht_node.appendChild(me._tt_ht_3d);\n\t\tel=me._ht_node_customimage=document.createElement('div');\n\t\tels=me._ht_node_customimage__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_external';\n\t\tels.setAttribute('style','position: absolute;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.onload=function() {me._ht_node_customimage.ggUpdatePosition();}\n\t\tif ((hotspot) && (hotspot.customimage)) {\n\t\t\tel.ggText=hotspot.customimage;\n\t\t\tels.setAttribute('src', hotspot.customimage);\n\t\t\tels.style.width=hotspot.customimagewidth + 'px';\n\t\t\tels.style.height=hotspot.customimageheight + 'px';\n\t\t\tme.ggUse3d = hotspot.use3D;\n\t\t\tme.gg3dDistance = hotspot.distance3D;\n\t\t}\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\ths ='';\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"ht_node_CustomImage\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_external \";\n\t\tel.ggType='external';\n\t\ths ='';\n\t\ths+='border : 0px solid #000000;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 50px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -140px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 50px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_node_customimage.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_node_customimage.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.hotspot.customimage == \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_node_customimage.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_node_customimage.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_node_customimage.style[domTransition]='';\n\t\t\t\tif (me._ht_node_customimage.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_node_customimage.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_node_customimage__img.src = '';\n\t\t\t\t\tme._ht_node_customimage.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_node_customimage.style.visibility=(Number(me._ht_node_customimage.style.opacity)>0||!me._ht_node_customimage.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_node_customimage.ggSubElement.src=me._ht_node_customimage.ggText;\n\t\t\t\t\tme._ht_node_customimage.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_node_customimage.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t\tvar parentWidth = me._ht_node_customimage.clientWidth;\n\t\t\tvar parentHeight = me._ht_node_customimage.clientHeight;\n\t\t\tvar img = me._ht_node_customimage__img;\n\t\t\tvar aspectRatioDiv = me._ht_node_customimage.clientWidth / me._ht_node_customimage.clientHeight;\n\t\t\tvar aspectRatioImg = img.naturalWidth / img.naturalHeight;\n\t\t\tif (img.naturalWidth < parentWidth) parentWidth = img.naturalWidth;\n\t\t\tif (img.naturalHeight < parentHeight) parentHeight = img.naturalHeight;\n\t\t\tvar currentWidth,currentHeight;\n\t\t\tif ((hotspot) && (hotspot.customimage)) {\n\t\t\t\tcurrentWidth = hotspot.customimagewidth;\n\t\t\t\tcurrentHeight = hotspot.customimageheight;\n\t\t\t}\n\t\t\timg.style.left='50%';\n\t\t\timg.style.marginLeft='-' + currentWidth/2 + 'px';\n\t\t\timg.style.top='50%';\n\t\t\timg.style.marginTop='-' + currentHeight/2 + 'px';\n\t\t}\n\t\tme._ht_node.appendChild(me._ht_node_customimage);\n\t\tif ((hotspot) && (hotspot.customimage)) {\n\t\t\tel.style.width=hotspot.customimagewidth + 'px';\n\t\t\tel.style.height=hotspot.customimageheight + 'px';\n\t\t}\n\t\tme.__div = me._ht_node;\n\t};\n\tfunction SkinHotspotClass_ht_info(parentScope,hotspot) {\n\t\tvar me=this;\n\t\tvar flag=false;\n\t\tvar hs='';\n\t\tme.parentScope=parentScope;\n\t\tme.hotspot=hotspot;\n\t\tvar nodeId=String(hotspot.url);\n\t\tnodeId=(nodeId.charAt(0)=='{')?nodeId.substr(1, nodeId.length - 2):''; // }\n\t\tme.ggUserdata=skin.player.getNodeUserdata(nodeId);\n\t\tme.elementMouseDown=[];\n\t\tme.elementMouseOver=[];\n\t\tme.findElements=function(id,regex) {\n\t\t\treturn skin.findElements(id,regex);\n\t\t}\n\t\tel=me._ht_info=document.createElement('div');\n\t\tel.ggId=\"ht_info\";\n\t\tel.ggDx=-268;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_hotspot \";\n\t\tel.ggType='hotspot';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 0px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 37px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 0px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_info.ggIsActive=function() {\n\t\t\treturn player.getCurrentNode()==this.ggElementNodeId();\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif (me.hotspot.url!='' && me.hotspot.url.charAt(0)=='{') { // }\n\t\t\t\treturn me.hotspot.url.substr(1, me.hotspot.url.length - 2);\n\t\t\t} else {\n\t\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t\t} else {\n\t\t\t\t\treturn player.getCurrentNode();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_info.onclick=function (e) {\n\t\t\tskin._info_title.ggText=me.hotspot.title;\n\t\t\tskin._info_title.ggTextDiv.innerHTML=skin._info_title.ggText;\n\t\t\tif (skin._info_title.ggUpdateText) {\n\t\t\t\tskin._info_title.ggUpdateText=function() {\n\t\t\t\t\tvar hs=me.hotspot.title;\n\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (skin._info_title.ggUpdatePosition) {\n\t\t\t\tskin._info_title.ggUpdatePosition();\n\t\t\t}\n\t\t\tskin._info_title.ggTextDiv.scrollTop = 0;\n\t\t\tskin._info_text_body.ggText=me.hotspot.description;\n\t\t\tskin._info_text_body.ggTextDiv.innerHTML=skin._info_text_body.ggText;\n\t\t\tif (skin._info_text_body.ggUpdateText) {\n\t\t\t\tskin._info_text_body.ggUpdateText=function() {\n\t\t\t\t\tvar hs=me.hotspot.description;\n\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (skin._info_text_body.ggUpdatePosition) {\n\t\t\t\tskin._info_text_body.ggUpdatePosition();\n\t\t\t}\n\t\t\tskin._info_text_body.ggTextDiv.scrollTop = 0;\n\t\t\tplayer.setVariableValue('vis_info_popup', true);\n\t\t\tskin.hotspotProxyClick(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_info.ondblclick=function (e) {\n\t\t\tskin.hotspotProxyDoubleClick(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_info.onmouseover=function (e) {\n\t\t\tplayer.setActiveHotspot(me.hotspot);\n\t\t\tme.elementMouseOver['ht_info']=true;\n\t\t\tme._tt_information.logicBlock_visible();\n\t\t\tskin.hotspotProxyOver(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_info.onmouseout=function (e) {\n\t\t\tplayer.setActiveHotspot(null);\n\t\t\tme.elementMouseOver['ht_info']=false;\n\t\t\tme._tt_information.logicBlock_visible();\n\t\t\tskin.hotspotProxyOut(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_info.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['ht_info']=false;\n\t\t\tme._tt_information.logicBlock_visible();\n\t\t}\n\t\tme._ht_info.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._ht_info_image=document.createElement('div');\n\t\tels=me._ht_info_image__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWw6c3BhY2U9InByZXNlcnZlIiB5PSIwcHgiIHZpZXdCb3g9Ii0yNDAgMzMyIDEzMCAxMzAiIHZlcnNpb249IjEuMSIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgaWQ9IkxheWVyXzEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZmlsbD0iIzAwMDAwMCIgZD0iTS0xNzUsMzQwLjljLTMxLDAtNTYuMSwyNS4xLTU2LjEsNTYuMXMyNS4xLDU2LjEsNTYuMSw1Ni4xYzMxLDAsNTYuMS0yNS4xLDU2LjEtNTYuMVMtMTQ0LDM0MC45LTE3NSwzNDAuOSYjeGQ7JiN4YTsmI3g5OyYjeDk7eiBNLTE3OC4xLDM2MS4xbDYuMiwwYzMuNSwwLDYuNCwyLjksNi40LDYuNHYyLjljMCwzLjUtMi45LDYuNC02LjQsNi40aC02LjJjLTMuNSwwLTYuNC0yLjktNi40LTYuNGwwLTIuOSYjeGQ7JiN4YTsmI3g5OyYjeDk7Qy0xODQuNSwzNjQtMTgxLjYsMzYxLjEtMTc4LjEsMzYxLjF6IE0tMTY3LDQzMC40SC0xODNj'+\n\t\t\t'LTAuOCwwLTEuNS0wLjctMS41LTEuNWwwLTM3LjdjMC0wLjgsMC43LTEuNSwxLjUtMS41bDE1LjksMCYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuOCwwLDEuNSwwLjcsMS41LDEuNWwwLDM3LjdDLTE2NS41LDQyOS43LTE2Ni4yLDQzMC40LTE2Nyw0MzAuNHoiLz4KIDwvZz4KIDxnIGlkPSJMYXllcl8yIj4KICA8Zz4KICAgPHBhdGggZmlsbD0iI0ZGRkZGRiIgZD0iTS0xNjUuNSwzOTEuMmMwLTAuOC0wLjctMS41LTEuNS0xLjVsLTE1LjksMGMtMC44LDAtMS41LDAuNy0xLjUsMS41bDAsMzcuN2MwLDAuOCwwLjcsMS41LDEuNSwxLjVoMTUuOSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC44LDAsMS'+\n\t\t\t'41LTAuNywxLjUtMS41TC0xNjUuNSwzOTEuMnoiLz4KICAgPHBhdGggZmlsbD0iI0ZGRkZGRiIgZD0iTS0xNzguMSwzNzYuOGg2LjJjMy41LDAsNi40LTIuOSw2LjQtNi40di0yLjljMC0zLjUtMi45LTYuNC02LjQtNi40bC02LjIsMGMtMy41LDAtNi40LDIuOS02LjQsNi40bDAsMi45JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0MtMTg0LjUsMzc0LTE4MS42LDM3Ni44LTE3OC4xLDM3Ni44eiIvPgogIDwvZz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._ht_info_image__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._ht_info_image__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIGJhc2VQcm9maWxlPSJ0aW55IiB4bWw6c3BhY2U9InByZXNlcnZlIiB5PSIwcHgiIHZpZXdCb3g9Ii0yNDAgMzMyIDEzMCAxMzAiIHZlcnNpb249IjEuMSIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgaWQ9IkxheWVyXzEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiA8ZyBpZD0iTG'+\n\t\t\t'F5ZXJfMV8xXyI+CiAgPHBhdGggZmlsbD0iIzAwMDAwMCIgZD0iTS0xNzUsMzM0LjZjLTM0LjQsMC02Mi40LDI3LjktNjIuNCw2Mi40czI3LjksNjIuNCw2Mi40LDYyLjRjMzQuNCwwLDYyLjQtMjcuOSw2Mi40LTYyLjQmI3hkOyYjeGE7JiN4OTsmI3g5O1MtMTQwLjYsMzM0LjYtMTc1LDMzNC42eiBNLTE3OC41LDM1Ny4xbDYuOSwwYzMuOSwwLDcuMSwzLjIsNy4xLDcuMXYzLjNjMCwzLjktMy4yLDcuMS03LjEsNy4xaC02LjljLTMuOSwwLTcuMS0zLjItNy4xLTcuMWwwLTMuMyYjeGQ7JiN4YTsmI3g5OyYjeDk7Qy0xODUuNiwzNjAuMy0xODIuNCwzNTcuMS0xNzguNSwzNTcuMXogTS0xNjYuMSw0'+\n\t\t\t'MzQuMWgtMTcuN2MtMC45LDAtMS43LTAuOC0xLjctMS43bDAtNDEuOWMwLTAuOSwwLjgtMS43LDEuNy0xLjdsMTcuNywwJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC45LDAsMS43LDAuOCwxLjcsMS43bDAsNDEuOUMtMTY0LjQsNDMzLjMtMTY1LjIsNDM0LjEtMTY2LjEsNDM0LjF6Ii8+CiA8L2c+CiA8ZyBpZD0iTGF5ZXJfMiI+CiAgPGc+CiAgIDxwYXRoIGZpbGw9IiNGRkZGRkYiIGQ9Ik0tMTY0LjQsMzkwLjVjMC0wLjktMC44LTEuNy0xLjctMS43bC0xNy43LDBjLTAuOSwwLTEuNywwLjgtMS43LDEuN2wwLDQxLjljMCwwLjksMC44LDEuNywxLjcsMS43aDE3LjcmI3hkOyYjeGE7JiN4OTsmI3g5Oy'+\n\t\t\t'YjeDk7YzAuOSwwLDEuNy0wLjgsMS43LTEuN0wtMTY0LjQsMzkwLjV6Ii8+CiAgIDxwYXRoIGZpbGw9IiNGRkZGRkYiIGQ9Ik0tMTc4LjUsMzc0LjZoNi45YzMuOSwwLDcuMS0zLjIsNy4xLTcuMXYtMy4zYzAtMy45LTMuMi03LjEtNy4xLTcuMWwtNi45LDBjLTMuOSwwLTcuMSwzLjItNy4xLDcuMWwwLDMuMyYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtDLTE4NS41LDM3MS40LTE4Mi40LDM3NC42LTE3OC41LDM3NC42eiIvPgogIDwvZz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._ht_info_image__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"ht_info_image\";\n\t\tel.ggDx=0;\n\t\tel.ggDy=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='height : 32px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_info_image.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_info_image.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.hotspot.customimage != \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_info_image.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_info_image.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_info_image.style[domTransition]='';\n\t\t\t\tif (me._ht_info_image.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_info_image.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_info_image.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_info_image.style.visibility=(Number(me._ht_info_image.style.opacity)>0||!me._ht_info_image.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_info_image.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_info_image.onmouseover=function (e) {\n\t\t\tme._ht_info_image__img.style.visibility='hidden';\n\t\t\tme._ht_info_image__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._ht_info_image.onmouseout=function (e) {\n\t\t\tme._ht_info_image__img.style.visibility='inherit';\n\t\t\tme._ht_info_image__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._ht_info_image.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=(this.ggDy + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._ht_info.appendChild(me._ht_info_image);\n\t\tel=me._tt_information=document.createElement('div');\n\t\tels=me._tt_information__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"tt_information\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='z-index: 100;';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 24px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 100px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: auto;';\n\t\ths+='height: auto;';\n\t\ths+='pointer-events: none;';\n\t\ths+='background: #000000;';\n\t\ths+='background: rgba(0,0,0,0.666667);';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: nowrap;';\n\t\ths+='padding: 2px 5px 2px 5px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=me.hotspot.title;\n\t\tel.appendChild(els);\n\t\tme._tt_information.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._tt_information.logicBlock_position = function() {\n\t\t\tvar newLogicStatePosition;\n\t\t\tif (\n\t\t\t\t((player.getHasTouch() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStatePosition = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStatePosition = -1;\n\t\t\t}\n\t\t\tif (me._tt_information.ggCurrentLogicStatePosition != newLogicStatePosition) {\n\t\t\t\tme._tt_information.ggCurrentLogicStatePosition = newLogicStatePosition;\n\t\t\t\tme._tt_information.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_information.ggCurrentLogicStatePosition == 0) {\n\t\t\t\t\tthis.ggDx = 0;\n\t\t\t\t\tme._tt_information.style.top='-47px';\n\t\t\t\t\tme._tt_information.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_information.ggDx=0;\n\t\t\t\t\tme._tt_information.style.top='24px';\n\t\t\t\t\tme._tt_information.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_information.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['ht_info'] == true)) && \n\t\t\t\t((me.hotspot.title != \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._tt_information.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._tt_information.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._tt_information.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_information.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._tt_information.style.visibility=(Number(me._tt_information.style.opacity)>0||!me._tt_information.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._tt_information.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_information.style.visibility=\"hidden\";\n\t\t\t\t\tme._tt_information.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_information.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t\tthis.style[domTransition]='left 0';\n\t\t\tthis.ggTextDiv.style.left=((98-this.ggTextDiv.offsetWidth)/2) + 'px';\n\t\t}\n\t\tme._ht_info.appendChild(me._tt_information);\n\t\tel=me._ht_info_customimage=document.createElement('div');\n\t\tels=me._ht_info_customimage__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_external';\n\t\tels.setAttribute('style','position: absolute;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.onload=function() {me._ht_info_customimage.ggUpdatePosition();}\n\t\tif ((hotspot) && (hotspot.customimage)) {\n\t\t\tel.ggText=hotspot.customimage;\n\t\t\tels.setAttribute('src', hotspot.customimage);\n\t\t\tels.style.width=hotspot.customimagewidth + 'px';\n\t\t\tels.style.height=hotspot.customimageheight + 'px';\n\t\t\tme.ggUse3d = hotspot.use3D;\n\t\t\tme.gg3dDistance = hotspot.distance3D;\n\t\t}\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\ths ='';\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"ht_info_CustomImage\";\n\t\tel.ggDx=0;\n\t\tel.ggDy=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_external \";\n\t\tel.ggType='external';\n\t\ths ='';\n\t\ths+='border : 0px solid #000000;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 50px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 50px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_info_customimage.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_info_customimage.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.hotspot.customimage == \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_info_customimage.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_info_customimage.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_info_customimage.style[domTransition]='';\n\t\t\t\tif (me._ht_info_customimage.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_info_customimage.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_info_customimage__img.src = '';\n\t\t\t\t\tme._ht_info_customimage.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_info_customimage.style.visibility=(Number(me._ht_info_customimage.style.opacity)>0||!me._ht_info_customimage.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_info_customimage.ggSubElement.src=me._ht_info_customimage.ggText;\n\t\t\t\t\tme._ht_info_customimage.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_info_customimage.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=(this.ggDy + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t\tvar parentWidth = me._ht_info_customimage.clientWidth;\n\t\t\tvar parentHeight = me._ht_info_customimage.clientHeight;\n\t\t\tvar img = me._ht_info_customimage__img;\n\t\t\tvar aspectRatioDiv = me._ht_info_customimage.clientWidth / me._ht_info_customimage.clientHeight;\n\t\t\tvar aspectRatioImg = img.naturalWidth / img.naturalHeight;\n\t\t\tif (img.naturalWidth < parentWidth) parentWidth = img.naturalWidth;\n\t\t\tif (img.naturalHeight < parentHeight) parentHeight = img.naturalHeight;\n\t\t\tvar currentWidth,currentHeight;\n\t\t\tif ((hotspot) && (hotspot.customimage)) {\n\t\t\t\tcurrentWidth = hotspot.customimagewidth;\n\t\t\t\tcurrentHeight = hotspot.customimageheight;\n\t\t\t}\n\t\t\timg.style.left='50%';\n\t\t\timg.style.marginLeft='-' + currentWidth/2 + 'px';\n\t\t\timg.style.top='50%';\n\t\t\timg.style.marginTop='-' + currentHeight/2 + 'px';\n\t\t}\n\t\tme._ht_info.appendChild(me._ht_info_customimage);\n\t\tif ((hotspot) && (hotspot.customimage)) {\n\t\t\tel.style.width=hotspot.customimagewidth + 'px';\n\t\t\tel.style.height=hotspot.customimageheight + 'px';\n\t\t}\n\t\tme.__div = me._ht_info;\n\t};\n\tme.addSkinHotspot=function(hotspot) {\n\t\tvar hsinst = null;\n\t\tif (hotspot.skinid=='ht_node') {\n\t\t\thotspot.skinid = 'ht_node';\n\t\t\thsinst = new SkinHotspotClass_ht_node(me, hotspot);\n\t\t\tif (!hotspotTemplates.hasOwnProperty(hotspot.skinid)) {\n\t\t\t\thotspotTemplates[hotspot.skinid] = [];\n\t\t\t}\n\t\t\thotspotTemplates[hotspot.skinid].push(hsinst);\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_changenode();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_configloaded();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_mouseover();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_active();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_changevisitednodes();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_activehotspotchanged();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_varchanged_opt_3d_preview();;\n\t\t} else\n\t\t{\n\t\t\thotspot.skinid = 'ht_info';\n\t\t\thsinst = new SkinHotspotClass_ht_info(me, hotspot);\n\t\t\tif (!hotspotTemplates.hasOwnProperty(hotspot.skinid)) {\n\t\t\t\thotspotTemplates[hotspot.skinid] = [];\n\t\t\t}\n\t\t\thotspotTemplates[hotspot.skinid].push(hsinst);\n\t\t\tme.callChildLogicBlocksHotspot_ht_info_changenode();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_info_configloaded();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_info_mouseover();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_info_hastouch();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_info_activehotspotchanged();;\n\t\t}\n\t\treturn hsinst;\n\t}\n\tme.removeSkinHotspots=function() {\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\thotspotTemplates['ht_node'][i] = null;\n\t\t\t}\n\t\t}\n\t\tif(hotspotTemplates['ht_info']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_info'].length; i++) {\n\t\t\t\thotspotTemplates['ht_info'][i] = null;\n\t\t\t}\n\t\t}\n\t\thotspotTemplates = [];\n\t}\n\tfunction SkinCloner_category_cloner_Class(item, parentScope,ggParent,parameter) {\n\t\tvar me=this;\n\t\tvar hs='';\n\t\tme.parentScope=parentScope;\n\t\tme.ggParent=ggParent;\n\t\tme.findElements=skin.findElements;\n\t\tme.ggIndex=parameter.index;\n\t\tme.ggTag = item['tag'];\n\t\tme.ggTitle = item['title'];\n\t\tme.ggNodeCount = item['nodecount'];\n\t\tme.ggNodeId=item['firstnode'];\n\t\tme.ggUserdata=skin.player.getNodeUserdata(me.ggNodeId);\n\t\tme.elementMouseDown={};\n\t\tme.elementMouseOver={};\n\t\tme.__div=document.createElement('div');\n\t\tme.__div.setAttribute('style','position: absolute;width: 150px; height: 128px; visibility: inherit; overflow: visible;');\n\t\tme.__div.style.left=parameter.left;\n\t\tme.__div.style.top=parameter.top;\n\t\tme.__div.style.width=parameter.width;\n\t\tme.__div.style.height=parameter.height;\n\t\tme.__div.ggIsActive = function() {\n\t\t\tvar tags = player.userdata.tags;\n\t\t\tif (tags.indexOf(me.ggTag) == -1) return false;\n\t\t\tfor(var i=0;i<me.ggParent.ggCurrentFilter.length;i++) {\n\t\t\t\tif (tags.indexOf(me.ggParent.ggCurrentFilter[i])==-1) return false;\n\t\t\t}\n\t\t\treturn true;\n\t\t}\n\t\tme.__div.ggElementNodeId=function() {\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tel=me._node_cloner=document.createElement('div');\n\t\tel.ggNumRepeat = 1;\n\t\tel.ggNumRows = 0;\n\t\tel.ggNumCols = 0;\n\t\tel.ggWidth = 141;\n\t\tel.ggHeight = 100;\n\t\tel.ggUpdating = false;\n\t\tel.ggFilter = [];\n\t\tel.ggInstances = [];\n\t\tme._node_cloner.callChildLogicBlocks_changenode = function(){\n\t\t\tif(me._node_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._node_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._node_cloner.ggInstances[i]._node_title && me._node_cloner.ggInstances[i]._node_title.logicBlock_visible) {\n\t\t\t\t\t\tme._node_cloner.ggInstances[i]._node_title.logicBlock_visible();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._node_cloner.callChildLogicBlocks_mouseover = function(){\n\t\t\tif(me._node_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._node_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._node_cloner.ggInstances[i]._node_visited && me._node_cloner.ggInstances[i]._node_visited.logicBlock_bordercolor) {\n\t\t\t\t\t\tme._node_cloner.ggInstances[i]._node_visited.logicBlock_bordercolor();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._node_cloner.callChildLogicBlocks_active = function(){\n\t\t\tif(me._node_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._node_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._node_cloner.ggInstances[i]._node_visited && me._node_cloner.ggInstances[i]._node_visited.logicBlock_bordercolor) {\n\t\t\t\t\t\tme._node_cloner.ggInstances[i]._node_visited.logicBlock_bordercolor();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._node_cloner.callChildLogicBlocks_changevisitednodes = function(){\n\t\t\tif(me._node_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._node_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._node_cloner.ggInstances[i]._node_visited && me._node_cloner.ggInstances[i]._node_visited.logicBlock_bordercolor) {\n\t\t\t\t\t\tme._node_cloner.ggInstances[i]._node_visited.logicBlock_bordercolor();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._node_cloner.callChildLogicBlocks_activehotspotchanged = function(){\n\t\t\tif(me._node_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._node_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._node_cloner.ggInstances[i]._node_title && me._node_cloner.ggInstances[i]._node_title.logicBlock_visible) {\n\t\t\t\t\t\tme._node_cloner.ggInstances[i]._node_title.logicBlock_visible();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tel.ggUpdate = function(filter) {\n\t\t\tif(me._node_cloner.ggUpdating == true) return;\n\t\t\tme._node_cloner.ggUpdating = true;\n\t\t\tvar el=me._node_cloner;\n\t\t\tvar curNumCols = 0;\n\t\t\tcurNumCols = me._node_cloner.ggNumRepeat;\n\t\t\tif (curNumCols < 1) curNumCols = 1;\n\t\t\tif (typeof filter=='object') {\n\t\t\t\tel.ggFilter = filter;\n\t\t\t} else {\n\t\t\t\tfilter = el.ggFilter;\n\t\t\t};\n\t\t\tfilter=filter.sort();\n\t\t\tif ((el.ggNumCols == curNumCols) && (el.ggInstances.length > 0) && (filter.length === el.ggCurrentFilter.length) && (filter.every(function(value, index) { return value === el.ggCurrentFilter[index] }) )) {\n\t\t\t\tme._node_cloner.ggUpdating = false;\n\t\t\t\treturn;\n\t\t\t} else {\n\t\t\t\tel.ggNumRows = 1;\n\t\t\t\tel.ggNumCols = curNumCols;\n\t\t\t}\n\t\t\tel.ggCurrentFilter = filter;\n\t\t\tel.ggInstances = [];\n\t\t\tif (el.hasChildNodes() == true) {\n\t\t\t\twhile (el.firstChild) {\n\t\t\t\t\tel.removeChild(el.firstChild);\n\t\t\t\t}\n\t\t\t}\n\t\t\tvar tourNodes = player.getNodeIds();\n\t\t\tvar row = 0;\n\t\t\tvar column = 0;\n\t\t\tvar currentIndex = 0;\n\t\t\tfor (var i=0; i < tourNodes.length; i++) {\n\t\t\t\tvar nodeId = tourNodes[i];\n\t\t\t\tvar passed = true;\n\t\t\t\tvar nodeData = player.getNodeUserdata(nodeId);\n\t\t\t\tif (filter.length > 0) {\n\t\t\t\t\tfor (var j=0; j < filter.length; j++) {\n\t\t\t\t\t\tif (nodeData['tags'].indexOf(filter[j]) == -1) passed = false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (passed) {\n\t\t\t\tvar parameter={};\n\t\t\t\tparameter.top=(row * me._node_cloner.ggHeight) + 'px';\n\t\t\t\tparameter.left=(column * me._node_cloner.ggWidth) + 'px';\n\t\t\t\tparameter.width=me._node_cloner.ggWidth + 'px';\n\t\t\t\tparameter.height=me._node_cloner.ggHeight + 'px';\n\t\t\t\tparameter.index=currentIndex;\n\t\t\t\tparameter.title=nodeData['title'];\n\t\t\t\tvar inst = new SkinCloner_node_cloner_Class(nodeId, me, el, parameter);\n\t\t\t\tcurrentIndex++;\n\t\t\t\tel.ggInstances.push(inst);\n\t\t\t\tel.appendChild(inst.__div);\n\t\t\t\tinst.__div.ggObj=inst;\n\t\t\t\tskin.updateSize(inst.__div);\n\t\t\t\tcolumn++;\n\t\t\t\tif (column >= el.ggNumCols) {\n\t\t\t\t\tcolumn = 0;\n\t\t\t\t\trow++;\n\t\t\t\t\tel.ggNumRows++;\n\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tme._node_cloner.callChildLogicBlocks_changenode();\n\t\t\tme._node_cloner.callChildLogicBlocks_mouseover();\n\t\t\tme._node_cloner.callChildLogicBlocks_active();\n\t\t\tme._node_cloner.callChildLogicBlocks_changevisitednodes();\n\t\t\tme._node_cloner.callChildLogicBlocks_activehotspotchanged();\n\t\t\tme._node_cloner.ggUpdating = false;\n\t\t\tplayer.triggerEvent('clonerchanged');\n\t\t\tif (me._node_cloner.parentNode.classList.contains('ggskin_subelement') && me._node_cloner.parentNode.parentNode.classList.contains('ggskin_scrollarea')) me._node_cloner.parentNode.parentNode.ggUpdatePosition();\n\t\t}\n\t\tel.ggFilter = [];\n\t\tel.ggFilter[0] = \"_nop_\";\n\t\tel.ggId=\"node_cloner\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_cloner \";\n\t\tel.ggType='cloner';\n\t\ths ='';\n\t\ths+='height : 100px;';\n\t\ths+='left : -10000px;';\n\t\ths+='overflow : visible;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 35px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 141px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._node_cloner.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._node_cloner.ggUpdateConditionNodeChange=function () {\n\t\t\tvar cnode=player.getCurrentNode();\n\t\t\tfor(var i=0; i<me._node_cloner.childNodes.length; i++) {\n\t\t\t\tvar child=me._node_cloner.childNodes[i];\n\t\t\t\tif (child.ggObj && child.ggObj.ggNodeId==cnode) {\n\t\t\t var childOffX = child.offsetLeft;\n\t\t\t var childOffY = child.offsetTop;\n\t\t\t\t\tvar p = child.parentElement;\n\t\t\t while (p != null && p!==this.divSkin) {\n\t\t\t\t\t\tif (p.ggType && p.ggType == 'scrollarea') {\n\t\t\t\t\t\t\tp.ggScrollIntoView(childOffX, childOffY, child.clientWidth, child.clientHeight);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tchildOffX += p.offsetLeft;\n\t\t\t\t\t\tchildOffY += p.offsetTop;\n\t\t\t\t\t\tp = p.parentElement;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._node_cloner.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.ggWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t\t\tme._node_cloner.ggUpdate();\n\t\t}\n\t\tme._node_cloner.ggNodeChange=function () {\n\t\t\tme._node_cloner.ggUpdateConditionNodeChange();\n\t\t}\n\t\tme.__div.appendChild(me._node_cloner);\n\t\tel=me._category=document.createElement('div');\n\t\tels=me._category__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"category\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 27px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 4px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 141px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: 141px;';\n\t\ths+='height: auto;';\n\t\ths+='background: #a1a1a1;';\n\t\ths+='border: 0px solid #ffffff;';\n\t\ths+='color: rgba(0,0,0,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: pre-wrap;';\n\t\ths+='padding: 2px 1px 2px 1px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=me.ggTitle;\n\t\tel.appendChild(els);\n\t\tme._category.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._category.logicBlock_backgroundcolor = function() {\n\t\t\tvar newLogicStateBackgroundColor;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['category'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateBackgroundColor = 0;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((player.getVariableValue('open_tag') == me.ggTag))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateBackgroundColor = 1;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateBackgroundColor = -1;\n\t\t\t}\n\t\t\tif (me._category.ggCurrentLogicStateBackgroundColor != newLogicStateBackgroundColor) {\n\t\t\t\tme._category.ggCurrentLogicStateBackgroundColor = newLogicStateBackgroundColor;\n\t\t\t\tme._category__text.style[domTransition]='background-color 0s';\n\t\t\t\tif (me._category.ggCurrentLogicStateBackgroundColor == 0) {\n\t\t\t\t\tme._category__text.style.backgroundColor=\"rgba(255,255,255,1)\";\n\t\t\t\t}\n\t\t\t\telse if (me._category.ggCurrentLogicStateBackgroundColor == 1) {\n\t\t\t\t\tme._category__text.style.backgroundColor=\"rgba(255,255,255,1)\";\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._category__text.style.backgroundColor=\"rgba(161,161,161,1)\";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category.onclick=function (e) {\n\t\t\tif (\n\t\t\t\t(\n\t\t\t\t\t((player.getVariableValue('open_tag') == me.ggTag))\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tplayer.setVariableValue('close_nodes', true);\n\t\t\t}\n\t\t\tif (\n\t\t\t\t(\n\t\t\t\t\t((player.getVariableValue('open_tag') != me.ggTag))\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tplayer.setVariableValue('close_nodes', false);\n\t\t\t}\n\t\t\tif (\n\t\t\t\t(\n\t\t\t\t\t((player.getVariableValue('open_tag') != me.ggTag))\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tplayer.setVariableValue('open_tag', me.ggTag);\n\t\t\t}\n\t\t\tif (\n\t\t\t\t(\n\t\t\t\t\t((player.getVariableValue('close_nodes') == true))\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tplayer.setVariableValue('open_tag', \"_nop_\");\n\t\t\t}\n\t\t}\n\t\tme._category.onmouseover=function (e) {\n\t\t\tme.elementMouseOver['category']=true;\n\t\t\tme._category.logicBlock_backgroundcolor();\n\t\t}\n\t\tme._category.onmouseout=function (e) {\n\t\t\tif (e && e.toElement) {\n\t\t\t\tvar current = e.toElement;\n\t\t\t\twhile (current = current.parentNode) {\n\t\t\t\tif (current == me._category__text)\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t\tme.elementMouseOver['category']=false;\n\t\t\tme._category.logicBlock_backgroundcolor();\n\t\t}\n\t\tme._category.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['category']=false;\n\t\t\tme._category.logicBlock_backgroundcolor();\n\t\t}\n\t\tme._category.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._category.ggNodeChange=function () {\n\t\t\tif (\n\t\t\t\t(\n\t\t\t\t\t((me._category.ggIsActive() == true)) && \n\t\t\t\t\t((player.getVariableValue('category_follow') == true))\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tplayer.setVariableValue('open_tag', me.ggTag);\n\t\t\t}\n\t\t}\n\t\tme.__div.appendChild(me._category);\n\t\tme._node_cloner.style['display']='none';\n\t\tvar p = me._node_cloner.parentElement;\n\t\twhile (p != null && p!==this.divSkin) {\n\t\t\tif (p.ggType && p.ggType == 'cloner') {\n\t\t\t\tif (p.ggAutoPosition) {\n\t\t\t\t\tp.ggAutoPosition(false);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (p.ggType && p.ggType == 'scrollarea') {\n\t\t\t\tif (p.ggUpdatePosition) {\n\t\t\t\t\tp.ggUpdatePosition();\n\t\t\t\t}\n\t\t\t}\n\t\t\tp = p.parentElement;\n\t\t}\n\t\tskin.updateSize(me._node_cloner);\n\t\tme.event_varchanged_open_tag=function() {if (\n\t\t\t(\n\t\t\t\t((player.getVariableValue('open_tag') != me.ggTag))\n\t\t\t)\n\t\t) {\n\t\t\tme._node_cloner.ggText=\"_nop_\";\n\t\t\tif (me._node_cloner.ggText=='') {\n\t\t\t\tme._node_cloner.ggUpdate([]);\n\t\t\t} else {\n\t\t\t\tme._node_cloner.ggUpdate(me._node_cloner.ggText.split(','));\n\t\t\t}\n\t\t\tskin.updateSize(skin.divSkin);\n\t\t}\n\t\tif (\n\t\t\t(\n\t\t\t\t((player.getVariableValue('open_tag') != me.ggTag))\n\t\t\t)\n\t\t) {\n\t\t\tme._node_cloner.style['display']='none';\n\t\t\tvar p = me._node_cloner.parentElement;\n\t\t\twhile (p != null && p!==this.divSkin) {\n\t\t\t\tif (p.ggType && p.ggType == 'cloner') {\n\t\t\t\t\tif (p.ggAutoPosition) {\n\t\t\t\t\t\tp.ggAutoPosition(false);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (p.ggType && p.ggType == 'scrollarea') {\n\t\t\t\t\tif (p.ggUpdatePosition) {\n\t\t\t\t\t\tp.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tp = p.parentElement;\n\t\t\t}\n\t\t\tskin.updateSize(me._node_cloner);\n\t\t}\n\t\tif (\n\t\t\t(\n\t\t\t\t((player.getVariableValue('open_tag') == me.ggTag))\n\t\t\t)\n\t\t) {\n\t\t\tme._node_cloner.ggText=me.ggTag;\n\t\t\tif (me._node_cloner.ggText=='') {\n\t\t\t\tme._node_cloner.ggUpdate([]);\n\t\t\t} else {\n\t\t\t\tme._node_cloner.ggUpdate(me._node_cloner.ggText.split(','));\n\t\t\t}\n\t\t\tskin.updateSize(skin.divSkin);\n\t\t}\n\t\tif (\n\t\t\t(\n\t\t\t\t((player.getVariableValue('open_tag') == me.ggTag))\n\t\t\t)\n\t\t) {\n\t\t\tme._node_cloner.style['display']='inline';\n\t\t\tvar p = me._node_cloner.parentElement;\n\t\t\twhile (p != null && p!==this.divSkin) {\n\t\t\t\tif (p.ggType && p.ggType == 'cloner') {\n\t\t\t\t\tif (p.ggAutoPosition) {\n\t\t\t\t\t\tp.ggAutoPosition(false);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (p.ggType && p.ggType == 'scrollarea') {\n\t\t\t\t\tif (p.ggUpdatePosition) {\n\t\t\t\t\t\tp.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tp = p.parentElement;\n\t\t\t}\n\t\t\tskin.updateSize(me._node_cloner);\n\t\t}};\n\t};\n\tfunction SkinCloner_node_cloner_Class(nodeId, parentScope,ggParent,parameter) {\n\t\tvar me=this;\n\t\tvar hs='';\n\t\tme.parentScope=parentScope;\n\t\tme.ggParent=ggParent;\n\t\tme.findElements=skin.findElements;\n\t\tme.ggIndex=parameter.index;\n\t\tme.ggNodeId=nodeId;\n\t\tme.ggTitle=parameter.title;\n\t\tme.ggUserdata=skin.player.getNodeUserdata(me.ggNodeId);\n\t\tme.elementMouseDown={};\n\t\tme.elementMouseOver={};\n\t\tme.__div=document.createElement('div');\n\t\tme.__div.setAttribute('style','position: absolute;width: 141px; height: 100px; visibility: inherit; overflow: visible;');\n\t\tme.__div.style.left=parameter.left;\n\t\tme.__div.style.top=parameter.top;\n\t\tme.__div.style.width=parameter.width;\n\t\tme.__div.style.height=parameter.height;\n\t\tme.__div.ggIsActive = function() {\n\t\t\treturn player.getCurrentNode()==me.ggNodeId;\n\t\t}\n\t\tme.__div.ggElementNodeId=function() {\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tel=me._node_image=document.createElement('div');\n\t\tels=me._node_image__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_nodeimage';\n\t\tels.setAttribute('src',basePath + \"images/node_image_\" + nodeId + \".jpg\");\n\t\tel.ggNodeId=nodeId;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_nodeimage';\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"node_image\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_nodeimage \";\n\t\tel.ggType='nodeimage';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 90px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 141px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._node_image.ggIsActive=function() {\n\t\t\treturn player.getCurrentNode()==this.ggElementNodeId();\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn this.ggNodeId;\n\t\t}\n\t\tme._node_image.onclick=function (e) {\n\t\t\tif (\n\t\t\t\t(\n\t\t\t\t\t((me._node_image.ggIsActive() == false))\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tplayer.openNext(\"{\"+me.ggNodeId+\"}\",player.hotspot.target);\n\t\t\t}\n\t\t}\n\t\tme._node_image.onmouseover=function (e) {\n\t\t\tme.elementMouseOver['node_image']=true;\n\t\t\tme._node_visited.logicBlock_bordercolor();\n\t\t}\n\t\tme._node_image.onmouseout=function (e) {\n\t\t\tme.elementMouseOver['node_image']=false;\n\t\t\tme._node_visited.logicBlock_bordercolor();\n\t\t}\n\t\tme._node_image.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['node_image']=false;\n\t\t\tme._node_visited.logicBlock_bordercolor();\n\t\t}\n\t\tme._node_image.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._node_title=document.createElement('div');\n\t\tels=me._node_title__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"node_title\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='bottom : 0px;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 136px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 100%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='left: 0px;';\n\t\ths+='bottom: 0px;';\n\t\ths+='width: 136px;';\n\t\ths+='height: auto;';\n\t\ths+='background: #000000;';\n\t\ths+='background: rgba(0,0,0,0.392157);';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: pre-wrap;';\n\t\ths+='padding: 2px 1px 2px 1px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=me.ggUserdata.title;\n\t\tel.appendChild(els);\n\t\tme._node_title.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._node_title.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.ggUserdata.title == \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._node_title.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._node_title.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._node_title.style[domTransition]='';\n\t\t\t\tif (me._node_title.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._node_title.style.visibility=\"hidden\";\n\t\t\t\t\tme._node_title.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._node_title.style.visibility=(Number(me._node_title.style.opacity)>0||!me._node_title.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._node_title.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._node_title.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._node_image.appendChild(me._node_title);\n\t\tel=me._node_visited=document.createElement('div');\n\t\tel.ggId=\"node_visited\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_rectangle \";\n\t\tel.ggType='rectangle';\n\t\ths ='';\n\t\ths+='border : 3px solid #a1a1a1;';\n\t\ths+='cursor : default;';\n\t\ths+='height : 87px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 135px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._node_visited.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._node_visited.logicBlock_bordercolor = function() {\n\t\t\tvar newLogicStateBorderColor;\n\t\t\tif (\n\t\t\t\t((me._node_visited.ggIsActive() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateBorderColor = 0;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((me.elementMouseOver['node_image'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateBorderColor = 1;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((player.nodeVisited(me._node_visited.ggElementNodeId()) == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateBorderColor = 2;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateBorderColor = -1;\n\t\t\t}\n\t\t\tif (me._node_visited.ggCurrentLogicStateBorderColor != newLogicStateBorderColor) {\n\t\t\t\tme._node_visited.ggCurrentLogicStateBorderColor = newLogicStateBorderColor;\n\t\t\t\tme._node_visited.style[domTransition]='border-color 0s';\n\t\t\t\tif (me._node_visited.ggCurrentLogicStateBorderColor == 0) {\n\t\t\t\t\tme._node_visited.style.borderColor=\"rgba(255,255,255,1)\";\n\t\t\t\t}\n\t\t\t\telse if (me._node_visited.ggCurrentLogicStateBorderColor == 1) {\n\t\t\t\t\tme._node_visited.style.borderColor=\"rgba(255,255,255,1)\";\n\t\t\t\t}\n\t\t\t\telse if (me._node_visited.ggCurrentLogicStateBorderColor == 2) {\n\t\t\t\t\tme._node_visited.style.borderColor=\"rgba(209,209,209,1)\";\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._node_visited.style.borderColor=\"rgba(161,161,161,1)\";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._node_visited.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._node_image.appendChild(me._node_visited);\n\t\tme.__div.appendChild(me._node_image);\n\t};\n\tplayer.addListener('varchanged_open_tag', function() {\n\t\tvar inst_j=skin;\n\t\tfor(var i = 0; i < inst_j._category_cloner.ggInstances.length; i++) {\n\t\t\tvar inst_i=inst_j._category_cloner.ggInstances[i];\n\t\t\tinst_i.event_varchanged_open_tag();\n\t\t}\n\t});\n\tme.addSkin();\n\tvar style = document.createElement('style');\n\tstyle.type = 'text/css';\n\tstyle.appendChild(document.createTextNode('.ggskin { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 14px;}'));\n\tdocument.head.appendChild(style);\n\tme._menu_background.logicBlock_alpha();\n\tme._menu_open.logicBlock_position();\n\tme._menu_open.logicBlock_alpha();\n\tme._screentint_info.logicBlock_visible();\n\tme._information.logicBlock_visible();\n\tme._info_text_body.logicBlock_visible();\n\tplayer.addListener('changenode', function(args) { me._menu_background.logicBlock_alpha();me._menu_open.logicBlock_position();me._menu_open.logicBlock_alpha();me._screentint_info.logicBlock_visible();me._information.logicBlock_visible(); });\n\tplayer.addListener('configloaded', function(args) { me._info_text_body.logicBlock_visible(); });\n\tplayer.addListener('varchanged_category_visible_1', function(args) { me._menu_background.logicBlock_alpha();me._menu_open.logicBlock_position();me._menu_open.logicBlock_alpha(); });\n\tplayer.addListener('varchanged_vis_info_popup', function(args) { me._screentint_info.logicBlock_visible();me._information.logicBlock_visible(); });\n\tplayer.addListener('changenode', function(args) { me._category_cloner.callChildLogicBlocks_changenode(); });\n\tplayer.addListener('mouseover', function(args) { me._category_cloner.callChildLogicBlocks_mouseover(); });\n\tplayer.addListener('mouseover', function(args) { me._category_cloner.callChildLogicBlocks_mouseover(); });\n\tplayer.addListener('changenode', function(args) { me._category_cloner.callChildLogicBlocks_active(); });\n\tplayer.addListener('changevisitednodes', function(args) { me._category_cloner.callChildLogicBlocks_changevisitednodes(); });\n\tplayer.addListener('activehotspotchanged', function(args) { me._category_cloner.callChildLogicBlocks_activehotspotchanged(); });\n\tplayer.addListener('varchanged_open_tag', function(args) { me._category_cloner.callChildLogicBlocks_varchanged_open_tag(); });\n\tplayer.addListener('changenode', function(args) { me.callChildLogicBlocksHotspot_ht_node_changenode();me.callChildLogicBlocksHotspot_ht_info_changenode(); });\n\tplayer.addListener('configloaded', function(args) { me.callChildLogicBlocksHotspot_ht_node_configloaded();me.callChildLogicBlocksHotspot_ht_info_configloaded(); });\n\tplayer.addListener('mouseover', function(args) { me.callChildLogicBlocksHotspot_ht_node_mouseover();me.callChildLogicBlocksHotspot_ht_info_mouseover(); });\n\tplayer.addListener('changenode', function(args) { me.callChildLogicBlocksHotspot_ht_node_active(); });\n\tplayer.addListener('changevisitednodes', function(args) { me.callChildLogicBlocksHotspot_ht_node_changevisitednodes(); });\n\tplayer.addListener('hastouch', function(args) { me.callChildLogicBlocksHotspot_ht_info_hastouch(); });\n\tplayer.addListener('activehotspotchanged', function(args) { me.callChildLogicBlocksHotspot_ht_node_activehotspotchanged();me.callChildLogicBlocksHotspot_ht_info_activehotspotchanged(); });\n\tplayer.addListener('varchanged_opt_3d_preview', function(args) { me.callChildLogicBlocksHotspot_ht_node_varchanged_opt_3d_preview(); });\n\tplayer.addListener('hotspotsremoved', function(args) { me.removeSkinHotspots(); });\n\tme.skinTimerEvent();\n}", "function MAIN_NAVIGATION$static_(){ToolbarSkin.MAIN_NAVIGATION=( new ToolbarSkin(\"main-navigation\"));}", "function onionSkin(){ //start script\n app.beginUndoGroup(\"Create Onion Skin Layer\");\n\n //if(parseFloat(app.version) >= 10.5){\n var theComp = app.project.activeItem; //only selected\n\n // check if comp is selected\n if (theComp == null || !(theComp instanceof CompItem)){\n // if no comp selected, display an alert\n alert(\"Please establish a comp as the active item and run the script again.\");\n } else { \n var solid = theComp.layers.addSolid([0, 1.0, 1.0], \"Onion Skinning\", theComp.width, theComp.height, 1);\n solid.adjustmentLayer = true;\n var echo = solid.property(\"Effects\").addProperty(\"Echo\");\n var slider = solid.property(\"Effects\").addProperty(\"Slider Control\");\n slider.name = \"Number of Frames\";\n slider.property(\"Slider\").setValue(1);\n \n var prop1 = solid.effect(\"Echo\")(\"Echo Time (seconds)\");\n var prop2 = solid.effect(\"Echo\")(\"Number Of Echoes\");\n var prop3 = solid.effect(\"Echo\")(\"Starting Intensity\");\n var prop4 = solid.effect(\"Echo\")(\"Decay\");\n var prop5 = solid.effect(\"Echo\")(\"Echo Operator\");\n\n prop1.expression = \"var s = effect(\\\"Number of Frames\\\")(\\\"Slider\\\");\" + \"\\r\" + \n \"var d = thisComp.frameDuration;\" + \"\\r\" + \n \"var rd;\" + \"\\r\" + \n \"if(s>=0){\" + \"\\r\" + \n \"rd = -d;\" + \"\\r\" + \n \"}else if (s<0){\" + \"\\r\" + \n \"rd = d;\" + \"\\r\" + \n \"}\";\n\n prop2.expression = \"var s = effect(\\\"Number of Frames\\\")(\\\"Slider\\\");\" + \"\\r\" +\n \"var rs;\" + \"\\r\" +\n \"if (s>0){\" + \"\\r\" +\n \"rs = s;\" + \"\\r\" +\n \"}else if (s==0){\" + \"\\r\" +\n \"rs = 0;\" + \"\\r\" +\n \"}else if (s<0){\" + \"\\r\" +\n \"rs = -s;\" + \"\\r\" +\n \"}\" + \"\\r\" +\n \"rs;\";\n prop3.expression = \"var val = 0.5;\" + \"\\r\" +\n \"var offset = 0.175;\" + \"\\r\" +\n \"var s = effect(\\\"Number of Frames\\\")(\\\"Slider\\\");\" + \"\\r\" +\n \"var rtn;\" + \"\\r\" +\n \"if(s<0) s = -s;\" + \"\\r\" +\n \"if(s!=0){\" + \"\\r\" +\n \"rtn = val + (offset/s);\" + \"\\r\" +\n \"}else{\" + \"\\r\" +\n \"rtn=1;\" + \"\\r\" +\n \"}\" + \"\\r\" +\n \"rtn;\";\n prop4.setValue(0.5);\n prop5.setValue(7);\n\n solid.locked = true;\n }\n \n app.endUndoGroup();\n} //end script", "function FIELD$static_(){ToolbarSkin.FIELD=( new ToolbarSkin(\"field\", \"Transparent Background with centered scrollers.\"));}", "function background()\n {\n var images =\n [\n './menuJapanBG.gif',\n './menuJapanBG2.gif',\n './menuJapanBG3.gif',\n './menuSpaceBG4.gif',\n './menuSpaceBG5.gif',\n './menuOPMerryBG6.gif',\n ];\n\n var randomImage = Math.floor(Math.random() * images.length);\n document.getElementById(\"navList\").style.backgroundImage = 'url(' + images[randomImage] + ')';\n }", "function changeBGAct4 (){\n removeClasses();\n body.classList.add(\"act4\");\n}", "function changeBGImage() {\n\t\t// get the custom data attribute from the clicked button\n\t\tlet currentImage = this.dataset.imageref;\n\n\t\t// `` is NOT a quote. it's a JavaScript template string\n\t\tdropZoneContainer.style.backgroundImage = `url(images/backGround${currentImage}.jpg)`;\n\n\n\t\t// this is an intermediate way to do the same something\n\t\t// dropZoneContainer.style.backgroundImage = `url(images/backGround${this.dataset.imageref}.jpg)`;\n\t\t// debugger;\n\t}", "function setBackground(){\n if(weather.iconId == \"01d\"){\n document.body.style.backgroundImage=\"url('./background_images/01d.jpg')\";\n }\n else if(weather.iconId == \"01n\"){\n document.body.style.backgroundImage=\"url('./background_images/01n.jpg')\";\n }\n else if(weather.iconId == \"02d\"){\n document.body.style.backgroundImage=\"url('./background_images/02d.jpg')\";\n }\n else if(weather.iconId == \"02n\"){\n document.body.style.backgroundImage=\"url('./background_images/02n.jpg')\";\n }\n else if(weather.iconId == \"03d\"){\n document.body.style.backgroundImage=\"url('./background_images/03d.jpg')\";\n }\n else if(weather.iconId == \"03n\"){\n document.body.style.backgroundImage=\"url('./background_images/03n.jpg')\";\n }\n else if(weather.iconId == \"04d\"){\n document.body.style.backgroundImage=\"url('./background_images/04d.jpg')\";\n }\n else if(weather.iconId == \"04n\"){\n document.body.style.backgroundImage=\"url('./background_images/04n.jpg')\";\n }\n else if(weather.iconId == \"09d\"){\n document.body.style.backgroundImage=\"url('./background_images/09n.jpg')\";\n }\n else if(weather.iconId == \"09n\"){\n document.body.style.backgroundImage=\"url('./background_images/09n.jpg')\";\n }\n else if(weather.iconId == \"10d\"){\n document.body.style.backgroundImage=\"url('./background_images/10d.jpg')\";\n }\n else if(weather.iconId == \"10n\"){\n document.body.style.backgroundImage=\"url('./background_images/10n.jpg')\";\n }\n else if(weather.iconId == \"11d\"){\n document.body.style.backgroundImage=\"url('./background_images/11d.jpg')\";\n }\n else if(weather.iconId == \"11n\"){\n document.body.style.backgroundImage=\"url('./background_images/11n.jpg')\";\n }\n else if(weather.iconId == \"13d\"){\n document.body.style.backgroundImage=\"url('./background_images/13d.jpg')\";\n }\n else if(weather.iconId == \"13n\"){\n document.body.style.backgroundImage=\"url('./background_images/13n.jpg')\";\n }\n else if(weather.iconId == \"50d\"){\n document.body.style.backgroundImage=\"url('./background_images/50d.jpg')\";\n }\n else if(weather.iconId == \"50n\"){\n document.body.style.backgroundImage=\"url('./background_images/50n.jpg')\";\n }\n}", "function changeBGAct3 (){\n removeClasses();\n body.classList.add(\"act3\");\n}", "function heroImage() {\n $.anystretch(\"http://davidmurray.is/wp-content/themes/davidmurrayis/_/img/intro_bg2.jpg\", {speed: 150});\n }", "function _generateBackground() {\n var t = new Trianglify();\n var pattern = t.generate(document.body.clientWidth, document.body.clientHeight);\n\n this.backSurface = new ImageSurface({\n size: [undefined, undefined],\n content: pattern.dataUri\n });\n\n var backModifier = new StateModifier({\n origin: [0.5, 0.5],\n align: [0.5, 0.5],\n opacity: 0\n });\n\n this.add(backModifier).add(this.backSurface);\n\n backModifier\n .setOpacity(0, { duration: this.options.animationDuration / 3 })\n // TODO: make showGUI after login\n .setOpacity(1, { duration: this.options.animationDuration / 3 });\n }", "function drinkNow(){\n\t// Do a bunch of stuff here.\n\t// Change the background color\n\tbackFlash(); \n\t// Show the \"drink now\" message\n\t$('overlay').setStyle('color', '#'+Math.floor(Math.random()*16777215).toString(16));\n\t$('overlay').show();\n\tsetTimeout(function(){$('overlay').hide()},250);\n\t// Now play a sound or something\n\t// Now change the song the chromeless player is playing\n\n}", "function bgImage() {\r\n $('[data-bgi]').each(function () {\r\n var src = $(this).attr('data-bgi');\r\n $(this).css({\r\n 'background-image': 'url(' + src + ')'\r\n });\r\n });\r\n }", "function lordfase2a() {\n elem = document.querySelector('#pagFase');\n elem.style.backgroundImage = \"url('img/lord/fase3.0.png')\";\n setTimeout(function() {\n setTimeout(function() {\n lordCombate2a()\n }, 3000)\n\n\n }, 3000)\n}", "function pano2vrSkin(player,base) {\n\tplayer.addVariable('ht_ani', 2, false);\n\tplayer.addVariable('opt_hotspot_preview', 2, true);\n\tplayer.addVariable('opt_zoom', 2, true);\n\tplayer.addVariable('opt_autorotate', 2, true);\n\tplayer.addVariable('opt_info', 2, false);\n\tplayer.addVariable('opt_thumbnail', 2, true);\n\tplayer.addVariable('vis_thumbnail_menu_show', 2, false);\n\tplayer.addVariable('opt_thumbnail_tooltip', 2, true);\n\tplayer.addVariable('opt_projection', 2, true);\n\tplayer.addVariable('opt_gyro', 2, true);\n\tplayer.addVariable('opt_fullscreen', 2, true);\n\tplayer.addVariable('opt_loader', 2, true);\n\tplayer.addVariable('opt_loader_mulires', 2, true);\n\tplayer.addVariable('opt_url', 2, false);\n\tplayer.addVariable('opt_autohide', 2, false);\n\tplayer.addVariable('vis_userdata', 2, false);\n\tplayer.addVariable('vis_image_popup', 2, false);\n\tplayer.addVariable('vis_info_popup', 2, false);\n\tplayer.addVariable('vis_video_popup_file', 2, false);\n\tplayer.addVariable('vis_video_popup_url', 2, false);\n\tplayer.addVariable('vis_video_popup_vimeo', 2, false);\n\tplayer.addVariable('vis_video_popup_youtube', 2, false);\n\tplayer.addVariable('vis_website', 2, false);\n\tplayer.addVariable('vis_thumbnail_menu_mobile', 2, false);\n\tplayer.addVariable('vis_thumbnail_menu_auto_hide', 2, true);\n\tplayer.addVariable('vis_360image_once', 2, true);\n\tplayer.addVariable('vis_loader', 2, true);\n\tplayer.addVariable('vis_timer', 2, false);\n\tplayer.addVariable('pos_autorotate', 1, 0);\n\tplayer.addVariable('pos_information', 1, 0);\n\tplayer.addVariable('pos_thumbnail', 1, 0);\n\tplayer.addVariable('pos_projection', 1, 0);\n\tplayer.addVariable('pos_gyro', 1, 0);\n\tplayer.addVariable('pos_fullscreen', 1, 0);\n\tplayer.addVariable('pos_controller', 1, 0);\n\tplayer.addVariable('pos_360image', 1, 0);\n\tplayer.addVariable('pos_enter_vr', 1, 0);\n\tvar me=this;\n\tvar skin=this;\n\tvar flag=false;\n\tvar hotspotTemplates={};\n\tvar skinKeyPressed = 0;\n\tthis.player=player;\n\tthis.player.skinObj=this;\n\tthis.divSkin=player.divSkin;\n\tthis.ggUserdata=player.userdata;\n\tthis.lastSize={ w: -1,h: -1 };\n\tvar basePath=\"\";\n\t// auto detect base path\n\tif (base=='?') {\n\t\tvar scripts = document.getElementsByTagName('script');\n\t\tfor(var i=0;i<scripts.length;i++) {\n\t\t\tvar src=scripts[i].src;\n\t\t\tif (src.indexOf('skin.js')>=0) {\n\t\t\t\tvar p=src.lastIndexOf('/');\n\t\t\t\tif (p>=0) {\n\t\t\t\t\tbasePath=src.substr(0,p+1);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t} else\n\tif (base) {\n\t\tbasePath=base;\n\t}\n\tthis.elementMouseDown=[];\n\tthis.elementMouseOver=[];\n\tvar cssPrefix='';\n\tvar domTransition='transition';\n\tvar domTransform='transform';\n\tvar prefixes='Webkit,Moz,O,ms,Ms'.split(',');\n\tvar i;\n\tvar hs,el,els,elo,ela,elHorScrollFg,elHorScrollBg,elVertScrollFg,elVertScrollBg,elCornerBg;\n\tif (typeof document.body.style['transform'] == 'undefined') {\n\t\tfor(var i=0;i<prefixes.length;i++) {\n\t\t\tif (typeof document.body.style[prefixes[i] + 'Transform'] !== 'undefined') {\n\t\t\t\tcssPrefix='-' + prefixes[i].toLowerCase() + '-';\n\t\t\t\tdomTransition=prefixes[i] + 'Transition';\n\t\t\t\tdomTransform=prefixes[i] + 'Transform';\n\t\t\t}\n\t\t}\n\t}\n\t\n\tplayer.setMargins(0,0,0,0);\n\t\n\tthis.updateSize=function(startElement) {\n\t\tvar stack=[];\n\t\tstack.push(startElement);\n\t\twhile(stack.length>0) {\n\t\t\tvar e=stack.pop();\n\t\t\tif (e.ggUpdatePosition) {\n\t\t\t\te.ggUpdatePosition();\n\t\t\t}\n\t\t\tif (e.hasChildNodes()) {\n\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\t\n\tthis.callNodeChange=function(startElement) {\n\t\tvar stack=[];\n\t\tstack.push(startElement);\n\t\twhile(stack.length>0) {\n\t\t\tvar e=stack.pop();\n\t\t\tif (e.ggNodeChange) {\n\t\t\t\te.ggNodeChange();\n\t\t\t}\n\t\t\tif (e.hasChildNodes()) {\n\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tplayer.addListener('changenode', function() { me.ggUserdata=player.userdata; me.callNodeChange(me.divSkin); });\n\t\n\tvar parameterToTransform=function(p) {\n\t\tvar hs='translate(' + p.rx + 'px,' + p.ry + 'px) rotate(' + p.a + 'deg) scale(' + p.sx + ',' + p.sy + ')';\n\t\treturn hs;\n\t}\n\t\n\tthis.findElements=function(id,regex) {\n\t\tvar r=[];\n\t\tvar stack=[];\n\t\tvar pat=new RegExp(id,'');\n\t\tstack.push(me.divSkin);\n\t\twhile(stack.length>0) {\n\t\t\tvar e=stack.pop();\n\t\t\tif (regex) {\n\t\t\t\tif (pat.test(e.ggId)) r.push(e);\n\t\t\t} else {\n\t\t\t\tif (e.ggId==id) r.push(e);\n\t\t\t}\n\t\t\tif (e.hasChildNodes()) {\n\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn r;\n\t}\n\t\n\tthis.addSkin=function() {\n\t\tvar hs='';\n\t\tthis.ggCurrentTime=new Date().getTime();\n\t\tel=me._timer_1=document.createElement('div');\n\t\tel.ggTimestamp=this.ggCurrentTime;\n\t\tel.ggLastIsActive=true;\n\t\tel.ggTimeout=1000;\n\t\tel.ggId=\"Timer 1\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_timer \";\n\t\tel.ggType='timer';\n\t\ths ='';\n\t\ths+='height : 15px;';\n\t\ths+='left : 58px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 20px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 58px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._timer_1.ggIsActive=function() {\n\t\t\treturn (me._timer_1.ggTimestamp==0 ? false : (Math.floor((me.ggCurrentTime - me._timer_1.ggTimestamp) / me._timer_1.ggTimeout) % 2 == 0));\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._timer_1.ggActivate=function () {\n\t\t\tplayer.setVariableValue('ht_ani', true);\n\t\t}\n\t\tme._timer_1.ggDeactivate=function () {\n\t\t\tplayer.setVariableValue('ht_ani', false);\n\t\t}\n\t\tme._timer_1.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.divSkin.appendChild(me._timer_1);\n\t\tel=me._container_1=document.createElement('div');\n\t\tel.ggId=\"Container 1\";\n\t\tel.ggDx=14;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='bottom : 3px;';\n\t\ths+='height : 67px;';\n\t\ths+='left : -10000px;';\n\t\ths+='opacity : 0.49999;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 350px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._container_1.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._container_1.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._button_fullscreen=document.createElement('div');\n\t\tel.ggId=\"button_fullscreen\";\n\t\tel.ggDx=86;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='bottom : 20px;';\n\t\ths+='height : 32px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_fullscreen.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_fullscreen.onclick=function (e) {\n\t\t\tplayer.toggleFullscreen();\n\t\t}\n\t\tme._button_fullscreen.onmouseover=function (e) {\n\t\t\tme.elementMouseOver['button_fullscreen']=true;\n\t\t\tme._tt_fullscreen.logicBlock_visible();\n\t\t}\n\t\tme._button_fullscreen.onmouseout=function (e) {\n\t\t\tme.elementMouseOver['button_fullscreen']=false;\n\t\t\tme._tt_fullscreen.logicBlock_visible();\n\t\t}\n\t\tme._button_fullscreen.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['button_fullscreen']=false;\n\t\t\tme._tt_fullscreen.logicBlock_visible();\n\t\t}\n\t\tme._button_fullscreen.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._button_image_normalscreen=document.createElement('div');\n\t\tels=me._button_image_normalscreen__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSI+CiAgPHBhdGggZD0iTTE2LDE0LjgwNEg0LjY5N2MtMC4zMTUsMC0wLjYyNCwwLjEyOC0wLjg0NiwwLjM1MUMzLjYyNywxNS4zNzcsMy41LDE1LjY4NiwzLjUsMTZ2OC4xMiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAsMC4zMTUsMC4xMjcsMC42MjQsMC4zNSwwLjg0NmMwLjIyMywwLjIyNCwwLjUzMSwwLjM1MSwwLjg0NiwwLjM1MUgxNmMwLjMyLDAsMC42Mi0wLjEyNCwwLjg0'+\n\t\t\t'Ni0wLjM1MSYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuMjI2LTAuMjI2LDAuMzUtMC41MjUsMC4zNS0wLjg0NlYxNmMwLTAuMzE0LTAuMTI4LTAuNjIzLTAuMzUtMC44NDZDMTYuNjIzLDE0LjkzMiwxNi4zMTQsMTQuODA0LDE2LDE0LjgwNHogTTE0LjgwNCwyMi45MjQmI3hkOyYjeGE7JiN4OTsmI3g5O0g1Ljg5M3YtNS43MjhoOC45MTFWMjIuOTI0eiBNNC42OTcsMTMuOTk4YzAuNjYxLDAsMS4xOTYtMC41MzYsMS4xOTYtMS4xOTZ2LTAuMzA4YzAtMC42Ni0wLjUzNi0xLjE5NS0xLjE5Ni0xLjE5NSYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjY2MSwwLTEuMTk2LDAuNTM1LTEuMTk2LDEuMTk1djAuMz'+\n\t\t\t'A4QzMuNSwxMy40NjIsNC4wMzYsMTMuOTk4LDQuNjk3LDEzLjk5OHogTTQuNjk3LDEwLjQ3N2MwLjY2MSwwLDEuMTk3LTAuNTM2LDEuMTk3LTEuMTk3aDAmI3hkOyYjeGE7JiN4OTsmI3g5O1Y5LjA3NmMwLjY2MSwwLDEuMTk2LTAuNTM1LDEuMTk2LTEuMTk2YzAtMC42Ni0wLjUzNi0xLjE5Ni0xLjE5Ni0xLjE5Nkg0LjY5N2MtMC4zMTUsMC0wLjYyMywwLjEyNy0wLjg0NiwwLjM1JiN4ZDsmI3hhOyYjeDk7JiN4OTtDMy42MjgsNy4yNTcsMy41LDcuNTY0LDMuNSw3Ljg4djEuMzk5QzMuNSw5Ljk0LDQuMDM2LDEwLjQ3Nyw0LjY5NywxMC40Nzd6IE0xOS4yODksOS4wNzZoMC4yNDJjMC42NjEsMCwx'+\n\t\t\t'LjE5Ni0wLjUzNiwxLjE5Ni0xLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7cy0wLjUzNS0xLjE5Ni0xLjE5Ni0xLjE5NmgtMC4yNDJjLTAuNjYxLDAtMS4xOTcsMC41MzYtMS4xOTcsMS4xOTZTMTguNjI4LDkuMDc2LDE5LjI4OSw5LjA3NnogTTE2LjEyMiw2LjY4NGgtMC4yNDMmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC42NjEsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5NnMwLjUzNiwxLjE5NiwxLjE5NiwxLjE5NmgwLjI0M2MwLjY2MSwwLDEuMTk3LTAuNTM2LDEuMTk3LTEuMTk2UzE2Ljc4Miw2LjY4NCwxNi4xMjIsNi42ODR6JiN4ZDsmI3hhOyYjeDk7JiN4OTsgTTIyLjY5OCw5LjA3NmgwLjI0M2'+\n\t\t\t'MwLjY2LDAsMS4xOTYtMC41MzYsMS4xOTYtMS4xOTZzLTAuNTM2LTEuMTk2LTEuMTk2LTEuMTk2aC0wLjI0M2MtMC42NiwwLTEuMTk2LDAuNTM2LTEuMTk2LDEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtTMjIuMDM4LDkuMDc2LDIyLjY5OCw5LjA3NnogTTkuMDYsOS4wNzZoMC4yNDJjMC42NiwwLDEuMTk2LTAuNTM2LDEuMTk2LTEuMTk2UzkuOTYyLDYuNjg0LDkuMzAyLDYuNjg0SDkuMDYmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC42NjEsMC0xLjE5NywwLjUzNi0xLjE5NywxLjE5NlM4LjM5OSw5LjA3Niw5LjA2LDkuMDc2eiBNMTIuNDY5LDkuMDc2aDAuMjQzYzAuNjYxLDAsMS4xOTYtMC41MzYs'+\n\t\t\t'MS4xOTYtMS4xOTYmI3hkOyYjeGE7JiN4OTsmI3g5O3MtMC41MzYtMS4xOTYtMS4xOTYtMS4xOTZoLTAuMjQzYy0wLjY2MSwwLTEuMTk2LDAuNTM2LTEuMTk2LDEuMTk2UzExLjgwOCw5LjA3NiwxMi40NjksOS4wNzZ6IE0yNy4zMDQsMTEuMTExJiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuNjYxLDAtMS4xOTYsMC41MzUtMS4xOTYsMS4xOTZ2MC4zMDhjMCwwLjY2LDAuNTM1LDEuMTk2LDEuMTk2LDEuMTk2YzAuNjYsMCwxLjE5Ni0wLjUzNiwxLjE5Ni0xLjE5NnYtMC4zMDgmI3hkOyYjeGE7JiN4OTsmI3g5O0MyOC41LDExLjY0NiwyNy45NjQsMTEuMTExLDI3LjMwNCwxMS4xMTF6IE0yNy4zMDQsMT'+\n\t\t\t'QuNjVjLTAuNjYxLDAtMS4xOTYsMC41MzUtMS4xOTYsMS4xOTZ2MC4zMDhjMCwwLjY2LDAuNTM1LDEuMTk2LDEuMTk2LDEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC42NiwwLDEuMTk2LTAuNTM2LDEuMTk2LTEuMTk2di0wLjMwOEMyOC41LDE1LjE4NiwyNy45NjQsMTQuNjUsMjcuMzA0LDE0LjY1eiBNMjcuMzA0LDIxLjcyOGMtMC42NjEsMC0xLjE5NiwwLjUzNS0xLjE5NiwxLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7aC0wLjIzNGMtMC42NiwwLTEuMTk2LDAuNTM2LTEuMTk2LDEuMTk2YzAsMC42NjEsMC41MzYsMS4xOTYsMS4xOTYsMS4xOTZoMS40MzFjMC4zMTQsMCwwLjYyMy0wLjEyOCww'+\n\t\t\t'Ljg0Ni0wLjM1MSYjeGQ7JiN4YTsmI3g5OyYjeDk7czAuMzUxLTAuNTMsMC4zNTEtMC44NDZ2LTEuMTk2QzI4LjUsMjIuMjY0LDI3Ljk2NCwyMS43MjgsMjcuMzA0LDIxLjcyOHogTTI3LjMwNCwxOC4xODljLTAuNjYxLDAtMS4xOTYsMC41MzYtMS4xOTYsMS4xOTZ2MC4zMDgmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLDAuNjYsMC41MzUsMS4xOTYsMS4xOTYsMS4xOTZjMC42NiwwLDEuMTk2LTAuNTM2LDEuMTk2LTEuMTk2di0wLjMwOEMyOC41LDE4LjcyNiwyNy45NjQsMTguMTg5LDI3LjMwNCwxOC4xODl6IE0yOC4xNDksNy4wMzMmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC4yMjMtMC4yMjItMC41Mz'+\n\t\t\t'EtMC4zNS0wLjg0Ni0wLjM1aC0xLjE5NmMtMC42NjEsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5NmMwLDAuNjYxLDAuNTM1LDEuMTk2LDEuMTk2LDEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMCwwLjY2MSwwLjUzNSwxLjE5NiwxLjE5NiwxLjE5NmMwLjY2LDAsMS4xOTYtMC41MzUsMS4xOTYtMS4xOTZWNy44OEMyOC41LDcuNTY0LDI4LjM3Miw3LjI1NywyOC4xNDksNy4wMzN6IE0yMS44NjMsMTMuMjYxJiN4ZDsmI3hhOyYjeDk7JiN4OTtsMC4yMjEtMC4xNDdjMC40MjgtMC4yODUsMC41NDItMC44NjMsMC4yNTctMS4yOTFjLTAuMjg2LTAuNDI4LTAuODYzLTAuNTQyLTEuMjkxLTAuMjU2bC0w'+\n\t\t\t'LjIyMSwwLjE0NiYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjQyNywwLjI4Ni0wLjU0MiwwLjg2My0wLjI1NywxLjI5MWMwLjE4LDAuMjY5LDAuNDc0LDAuNDE0LDAuNzc0LDAuNDE0QzIxLjUyNCwxMy40MTgsMjEuNzA0LDEzLjM2NywyMS44NjMsMTMuMjYxeiYjeGQ7JiN4YTsmI3g5OyYjeDk7IE0xOS4zMjksMjIuOTI0aC0wLjI0MmMtMC42NjEsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5NmMwLDAuNjYxLDAuNTM1LDEuMTk2LDEuMTk2LDEuMTk2aDAuMjQyYzAuNjYxLDAsMS4xOTYtMC41MzUsMS4xOTYtMS4xOTYmI3hkOyYjeGE7JiN4OTsmI3g5O0MyMC41MjUsMjMuNDYsMTkuOTksMjIuOTI0LD'+\n\t\t\t'E5LjMyOSwyMi45MjR6IE0xOC41ODQsMTUuMjY0YzAuMTc4LDAsMC4zNTctMC4wNTEsMC41MTctMC4xNTdsMC4yMjEtMC4xNDcmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjQyOC0wLjI4NSwwLjU0Mi0wLjg2MywwLjI1Ny0xLjI5Yy0wLjI4NS0wLjQyOC0wLjg2My0wLjU0Mi0xLjI5MS0wLjI1N2wtMC4yMjIsMC4xNDdjLTAuNDI3LDAuMjg2LTAuNTQyLDAuODYzLTAuMjU2LDEuMjkxJiN4ZDsmI3hhOyYjeDk7JiN4OTtDMTcuOTg5LDE1LjExOSwxOC4yODMsMTUuMjY0LDE4LjU4NCwxNS4yNjR6IE0yMi43MzksMjIuOTI0aC0wLjI0MmMtMC42NjEsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5NiYjeGQ7'+\n\t\t\t'JiN4YTsmI3g5OyYjeDk7YzAsMC42NjEsMC41MzUsMS4xOTYsMS4xOTYsMS4xOTZoMC4yNDJjMC42NiwwLDEuMTk2LTAuNTM1LDEuMTk2LTEuMTk2QzIzLjkzNiwyMy40NiwyMy4zOTksMjIuOTI0LDIyLjczOSwyMi45MjR6IE0yNS4xMDQsOS45NzYmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC4yODUtMC40MjctMC44NjMtMC41NDItMS4yOTEtMC4yNTZsLTAuMjIxLDAuMTQ3Yy0wLjQyOCwwLjI4NS0wLjU0MiwwLjg2My0wLjI1NiwxLjI5YzAuMTc5LDAuMjY5LDAuNDc0LDAuNDE0LDAuNzc0LDAuNDE0JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4xNzgsMCwwLjM1Ny0wLjA1MSwwLjUxNi0wLjE1NmwwLj'+\n\t\t\t'IyMi0wLjE0OEMyNS4yNzQsMTAuOTgxLDI1LjM4OSwxMC40MDMsMjUuMTA0LDkuOTc2eiIvPgogPC9nPgogPGcgc3Ryb2tlPSIjMDAwMDAwIiBmaWxsPSIjRkZGRkZGIiBzdHJva2Utd2lkdGg9IjAuMiI+CiAgPHBhdGggZD0iTTE2LDE0LjgwNEg0LjY5N2MtMC4zMTUsMC0wLjYyNCwwLjEyOC0wLjg0NiwwLjM1MUMzLjYyNywxNS4zNzcsMy41LDE1LjY4NiwzLjUsMTZ2OC4xMiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAsMC4zMTUsMC4xMjcsMC42MjQsMC4zNSwwLjg0NmMwLjIyMywwLjIyNCwwLjUzMSwwLjM1MSwwLjg0NiwwLjM1MUgxNmMwLjMyLDAsMC42Mi0wLjEyNCwwLjg0Ni0wLjM1MSYjeGQ7'+\n\t\t\t'JiN4YTsmI3g5OyYjeDk7YzAuMjI2LTAuMjI2LDAuMzUtMC41MjUsMC4zNS0wLjg0NlYxNmMwLTAuMzE0LTAuMTI4LTAuNjIzLTAuMzUtMC44NDZDMTYuNjIzLDE0LjkzMiwxNi4zMTQsMTQuODA0LDE2LDE0LjgwNHogTTE0LjgwNCwyMi45MjQmI3hkOyYjeGE7JiN4OTsmI3g5O0g1Ljg5M3YtNS43MjhoOC45MTFWMjIuOTI0eiBNNC42OTcsMTMuOTk4YzAuNjYxLDAsMS4xOTYtMC41MzYsMS4xOTYtMS4xOTZ2LTAuMzA4YzAtMC42Ni0wLjUzNi0xLjE5NS0xLjE5Ni0xLjE5NSYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjY2MSwwLTEuMTk2LDAuNTM1LTEuMTk2LDEuMTk1djAuMzA4QzMuNSwxMy40Nj'+\n\t\t\t'IsNC4wMzYsMTMuOTk4LDQuNjk3LDEzLjk5OHogTTQuNjk3LDEwLjQ3N2MwLjY2MSwwLDEuMTk3LTAuNTM2LDEuMTk3LTEuMTk3aDAmI3hkOyYjeGE7JiN4OTsmI3g5O1Y5LjA3NmMwLjY2MSwwLDEuMTk2LTAuNTM1LDEuMTk2LTEuMTk2YzAtMC42Ni0wLjUzNi0xLjE5Ni0xLjE5Ni0xLjE5Nkg0LjY5N2MtMC4zMTUsMC0wLjYyMywwLjEyNy0wLjg0NiwwLjM1JiN4ZDsmI3hhOyYjeDk7JiN4OTtDMy42MjgsNy4yNTcsMy41LDcuNTY0LDMuNSw3Ljg4djEuMzk5QzMuNSw5Ljk0LDQuMDM2LDEwLjQ3Nyw0LjY5NywxMC40Nzd6IE0xOS4yODksOS4wNzZoMC4yNDJjMC42NjEsMCwxLjE5Ni0wLjUzNiwx'+\n\t\t\t'LjE5Ni0xLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7cy0wLjUzNS0xLjE5Ni0xLjE5Ni0xLjE5NmgtMC4yNDJjLTAuNjYxLDAtMS4xOTcsMC41MzYtMS4xOTcsMS4xOTZTMTguNjI4LDkuMDc2LDE5LjI4OSw5LjA3NnogTTE2LjEyMiw2LjY4NGgtMC4yNDMmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC42NjEsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5NnMwLjUzNiwxLjE5NiwxLjE5NiwxLjE5NmgwLjI0M2MwLjY2MSwwLDEuMTk3LTAuNTM2LDEuMTk3LTEuMTk2UzE2Ljc4Miw2LjY4NCwxNi4xMjIsNi42ODR6JiN4ZDsmI3hhOyYjeDk7JiN4OTsgTTIyLjY5OCw5LjA3NmgwLjI0M2MwLjY2LDAsMS4xOT'+\n\t\t\t'YtMC41MzYsMS4xOTYtMS4xOTZzLTAuNTM2LTEuMTk2LTEuMTk2LTEuMTk2aC0wLjI0M2MtMC42NiwwLTEuMTk2LDAuNTM2LTEuMTk2LDEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtTMjIuMDM4LDkuMDc2LDIyLjY5OCw5LjA3NnogTTkuMDYsOS4wNzZoMC4yNDJjMC42NiwwLDEuMTk2LTAuNTM2LDEuMTk2LTEuMTk2UzkuOTYyLDYuNjg0LDkuMzAyLDYuNjg0SDkuMDYmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC42NjEsMC0xLjE5NywwLjUzNi0xLjE5NywxLjE5NlM4LjM5OSw5LjA3Niw5LjA2LDkuMDc2eiBNMTIuNDY5LDkuMDc2aDAuMjQzYzAuNjYxLDAsMS4xOTYtMC41MzYsMS4xOTYtMS4xOTYm'+\n\t\t\t'I3hkOyYjeGE7JiN4OTsmI3g5O3MtMC41MzYtMS4xOTYtMS4xOTYtMS4xOTZoLTAuMjQzYy0wLjY2MSwwLTEuMTk2LDAuNTM2LTEuMTk2LDEuMTk2UzExLjgwOCw5LjA3NiwxMi40NjksOS4wNzZ6IE0yNy4zMDQsMTEuMTExJiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuNjYxLDAtMS4xOTYsMC41MzUtMS4xOTYsMS4xOTZ2MC4zMDhjMCwwLjY2LDAuNTM1LDEuMTk2LDEuMTk2LDEuMTk2YzAuNjYsMCwxLjE5Ni0wLjUzNiwxLjE5Ni0xLjE5NnYtMC4zMDgmI3hkOyYjeGE7JiN4OTsmI3g5O0MyOC41LDExLjY0NiwyNy45NjQsMTEuMTExLDI3LjMwNCwxMS4xMTF6IE0yNy4zMDQsMTQuNjVjLTAuNjYxLD'+\n\t\t\t'AtMS4xOTYsMC41MzUtMS4xOTYsMS4xOTZ2MC4zMDhjMCwwLjY2LDAuNTM1LDEuMTk2LDEuMTk2LDEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC42NiwwLDEuMTk2LTAuNTM2LDEuMTk2LTEuMTk2di0wLjMwOEMyOC41LDE1LjE4NiwyNy45NjQsMTQuNjUsMjcuMzA0LDE0LjY1eiBNMjcuMzA0LDIxLjcyOGMtMC42NjEsMC0xLjE5NiwwLjUzNS0xLjE5NiwxLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7aC0wLjIzNGMtMC42NiwwLTEuMTk2LDAuNTM2LTEuMTk2LDEuMTk2YzAsMC42NjEsMC41MzYsMS4xOTYsMS4xOTYsMS4xOTZoMS40MzFjMC4zMTQsMCwwLjYyMy0wLjEyOCwwLjg0Ni0wLjM1MSYj'+\n\t\t\t'eGQ7JiN4YTsmI3g5OyYjeDk7czAuMzUxLTAuNTMsMC4zNTEtMC44NDZ2LTEuMTk2QzI4LjUsMjIuMjY0LDI3Ljk2NCwyMS43MjgsMjcuMzA0LDIxLjcyOHogTTI3LjMwNCwxOC4xODljLTAuNjYxLDAtMS4xOTYsMC41MzYtMS4xOTYsMS4xOTZ2MC4zMDgmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLDAuNjYsMC41MzUsMS4xOTYsMS4xOTYsMS4xOTZjMC42NiwwLDEuMTk2LTAuNTM2LDEuMTk2LTEuMTk2di0wLjMwOEMyOC41LDE4LjcyNiwyNy45NjQsMTguMTg5LDI3LjMwNCwxOC4xODl6IE0yOC4xNDksNy4wMzMmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC4yMjMtMC4yMjItMC41MzEtMC4zNS0wLjg0Ni'+\n\t\t\t'0wLjM1aC0xLjE5NmMtMC42NjEsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5NmMwLDAuNjYxLDAuNTM1LDEuMTk2LDEuMTk2LDEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMCwwLjY2MSwwLjUzNSwxLjE5NiwxLjE5NiwxLjE5NmMwLjY2LDAsMS4xOTYtMC41MzUsMS4xOTYtMS4xOTZWNy44OEMyOC41LDcuNTY0LDI4LjM3Miw3LjI1NywyOC4xNDksNy4wMzN6IE0yMS44NjMsMTMuMjYxJiN4ZDsmI3hhOyYjeDk7JiN4OTtsMC4yMjEtMC4xNDdjMC40MjgtMC4yODUsMC41NDItMC44NjMsMC4yNTctMS4yOTFjLTAuMjg2LTAuNDI4LTAuODYzLTAuNTQyLTEuMjkxLTAuMjU2bC0wLjIyMSwwLjE0NiYj'+\n\t\t\t'eGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjQyNywwLjI4Ni0wLjU0MiwwLjg2My0wLjI1NywxLjI5MWMwLjE4LDAuMjY5LDAuNDc0LDAuNDE0LDAuNzc0LDAuNDE0QzIxLjUyNCwxMy40MTgsMjEuNzA0LDEzLjM2NywyMS44NjMsMTMuMjYxeiYjeGQ7JiN4YTsmI3g5OyYjeDk7IE0xOS4zMjksMjIuOTI0aC0wLjI0MmMtMC42NjEsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5NmMwLDAuNjYxLDAuNTM1LDEuMTk2LDEuMTk2LDEuMTk2aDAuMjQyYzAuNjYxLDAsMS4xOTYtMC41MzUsMS4xOTYtMS4xOTYmI3hkOyYjeGE7JiN4OTsmI3g5O0MyMC41MjUsMjMuNDYsMTkuOTksMjIuOTI0LDE5LjMyOSwyMi45Mj'+\n\t\t\t'R6IE0xOC41ODQsMTUuMjY0YzAuMTc4LDAsMC4zNTctMC4wNTEsMC41MTctMC4xNTdsMC4yMjEtMC4xNDcmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjQyOC0wLjI4NSwwLjU0Mi0wLjg2MywwLjI1Ny0xLjI5Yy0wLjI4NS0wLjQyOC0wLjg2My0wLjU0Mi0xLjI5MS0wLjI1N2wtMC4yMjIsMC4xNDdjLTAuNDI3LDAuMjg2LTAuNTQyLDAuODYzLTAuMjU2LDEuMjkxJiN4ZDsmI3hhOyYjeDk7JiN4OTtDMTcuOTg5LDE1LjExOSwxOC4yODMsMTUuMjY0LDE4LjU4NCwxNS4yNjR6IE0yMi43MzksMjIuOTI0aC0wLjI0MmMtMC42NjEsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5NiYjeGQ7JiN4YTsmI3g5OyYj'+\n\t\t\t'eDk7YzAsMC42NjEsMC41MzUsMS4xOTYsMS4xOTYsMS4xOTZoMC4yNDJjMC42NiwwLDEuMTk2LTAuNTM1LDEuMTk2LTEuMTk2QzIzLjkzNiwyMy40NiwyMy4zOTksMjIuOTI0LDIyLjczOSwyMi45MjR6IE0yNS4xMDQsOS45NzYmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC4yODUtMC40MjctMC44NjMtMC41NDItMS4yOTEtMC4yNTZsLTAuMjIxLDAuMTQ3Yy0wLjQyOCwwLjI4NS0wLjU0MiwwLjg2My0wLjI1NiwxLjI5YzAuMTc5LDAuMjY5LDAuNDc0LDAuNDE0LDAuNzc0LDAuNDE0JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4xNzgsMCwwLjM1Ny0wLjA1MSwwLjUxNi0wLjE1NmwwLjIyMi0wLjE0OEMyNS'+\n\t\t\t'4yNzQsMTAuOTgxLDI1LjM4OSwxMC40MDMsMjUuMTA0LDkuOTc2eiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._button_image_normalscreen__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._button_image_normalscreen__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC0xNiwtMTYpIj4KICA8cGF0aCBkPSJNMTYsMTQuODA0SDQuNjk3Yy0wLjMxNSwwLTAuNjI0LDAuMTI4LTAuODQ2LDAuMzUxQzMuNjI3LDE1LjM3NywzLjUsMTUuNjg2LDMuNSwxNnY4LjEyJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMCwwLjMxNSwwLjEyNywwLjYyNCwwLjM1LDAuODQ2YzAu'+\n\t\t\t'MjIzLDAuMjI0LDAuNTMxLDAuMzUxLDAuODQ2LDAuMzUxSDE2YzAuMzIsMCwwLjYyLTAuMTI0LDAuODQ2LTAuMzUxJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4yMjYtMC4yMjYsMC4zNS0wLjUyNSwwLjM1LTAuODQ2VjE2YzAtMC4zMTQtMC4xMjgtMC42MjMtMC4zNS0wLjg0NkMxNi42MjMsMTQuOTMyLDE2LjMxNCwxNC44MDQsMTYsMTQuODA0eiBNMTQuODA0LDIyLjkyNCYjeGQ7JiN4YTsmI3g5OyYjeDk7SDUuODkzdi01LjcyOGg4LjkxMVYyMi45MjR6IE00LjY5NywxMy45OThjMC42NjEsMCwxLjE5Ni0wLjUzNiwxLjE5Ni0xLjE5NnYtMC4zMDhjMC0wLjY2LTAuNTM2LTEuMTk1LTEuMTk2LTEuMT'+\n\t\t\t'k1JiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuNjYxLDAtMS4xOTYsMC41MzUtMS4xOTYsMS4xOTV2MC4zMDhDMy41LDEzLjQ2Miw0LjAzNiwxMy45OTgsNC42OTcsMTMuOTk4eiBNNC42OTcsMTAuNDc3YzAuNjYxLDAsMS4xOTctMC41MzYsMS4xOTctMS4xOTdoMCYjeGQ7JiN4YTsmI3g5OyYjeDk7VjkuMDc2YzAuNjYxLDAsMS4xOTYtMC41MzUsMS4xOTYtMS4xOTZjMC0wLjY2LTAuNTM2LTEuMTk2LTEuMTk2LTEuMTk2SDQuNjk3Yy0wLjMxNSwwLTAuNjIzLDAuMTI3LTAuODQ2LDAuMzUmI3hkOyYjeGE7JiN4OTsmI3g5O0MzLjYyOCw3LjI1NywzLjUsNy41NjQsMy41LDcuODh2MS4zOTlDMy41LDku'+\n\t\t\t'OTQsNC4wMzYsMTAuNDc3LDQuNjk3LDEwLjQ3N3ogTTE5LjI4OSw5LjA3NmgwLjI0MmMwLjY2MSwwLDEuMTk2LTAuNTM2LDEuMTk2LTEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtzLTAuNTM1LTEuMTk2LTEuMTk2LTEuMTk2aC0wLjI0MmMtMC42NjEsMC0xLjE5NywwLjUzNi0xLjE5NywxLjE5NlMxOC42MjgsOS4wNzYsMTkuMjg5LDkuMDc2eiBNMTYuMTIyLDYuNjg0aC0wLjI0MyYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjY2MSwwLTEuMTk2LDAuNTM2LTEuMTk2LDEuMTk2czAuNTM2LDEuMTk2LDEuMTk2LDEuMTk2aDAuMjQzYzAuNjYxLDAsMS4xOTctMC41MzYsMS4xOTctMS4xOTZTMTYuNzgyLD'+\n\t\t\t'YuNjg0LDE2LjEyMiw2LjY4NHomI3hkOyYjeGE7JiN4OTsmI3g5OyBNMjIuNjk4LDkuMDc2aDAuMjQzYzAuNjYsMCwxLjE5Ni0wLjUzNiwxLjE5Ni0xLjE5NnMtMC41MzYtMS4xOTYtMS4xOTYtMS4xOTZoLTAuMjQzYy0wLjY2LDAtMS4xOTYsMC41MzYtMS4xOTYsMS4xOTYmI3hkOyYjeGE7JiN4OTsmI3g5O1MyMi4wMzgsOS4wNzYsMjIuNjk4LDkuMDc2eiBNOS4wNiw5LjA3NmgwLjI0MmMwLjY2LDAsMS4xOTYtMC41MzYsMS4xOTYtMS4xOTZTOS45NjIsNi42ODQsOS4zMDIsNi42ODRIOS4wNiYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjY2MSwwLTEuMTk3LDAuNTM2LTEuMTk3LDEuMTk2UzguMzk5'+\n\t\t\t'LDkuMDc2LDkuMDYsOS4wNzZ6IE0xMi40NjksOS4wNzZoMC4yNDNjMC42NjEsMCwxLjE5Ni0wLjUzNiwxLjE5Ni0xLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7cy0wLjUzNi0xLjE5Ni0xLjE5Ni0xLjE5NmgtMC4yNDNjLTAuNjYxLDAtMS4xOTYsMC41MzYtMS4xOTYsMS4xOTZTMTEuODA4LDkuMDc2LDEyLjQ2OSw5LjA3NnogTTI3LjMwNCwxMS4xMTEmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC42NjEsMC0xLjE5NiwwLjUzNS0xLjE5NiwxLjE5NnYwLjMwOGMwLDAuNjYsMC41MzUsMS4xOTYsMS4xOTYsMS4xOTZjMC42NiwwLDEuMTk2LTAuNTM2LDEuMTk2LTEuMTk2di0wLjMwOCYjeGQ7JiN4YTsmI3'+\n\t\t\t'g5OyYjeDk7QzI4LjUsMTEuNjQ2LDI3Ljk2NCwxMS4xMTEsMjcuMzA0LDExLjExMXogTTI3LjMwNCwxNC42NWMtMC42NjEsMC0xLjE5NiwwLjUzNS0xLjE5NiwxLjE5NnYwLjMwOGMwLDAuNjYsMC41MzUsMS4xOTYsMS4xOTYsMS4xOTYmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjY2LDAsMS4xOTYtMC41MzYsMS4xOTYtMS4xOTZ2LTAuMzA4QzI4LjUsMTUuMTg2LDI3Ljk2NCwxNC42NSwyNy4zMDQsMTQuNjV6IE0yNy4zMDQsMjEuNzI4Yy0wLjY2MSwwLTEuMTk2LDAuNTM1LTEuMTk2LDEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtoLTAuMjM0Yy0wLjY2LDAtMS4xOTYsMC41MzYtMS4xOTYsMS4xOTZj'+\n\t\t\t'MCwwLjY2MSwwLjUzNiwxLjE5NiwxLjE5NiwxLjE5NmgxLjQzMWMwLjMxNCwwLDAuNjIzLTAuMTI4LDAuODQ2LTAuMzUxJiN4ZDsmI3hhOyYjeDk7JiN4OTtzMC4zNTEtMC41MywwLjM1MS0wLjg0NnYtMS4xOTZDMjguNSwyMi4yNjQsMjcuOTY0LDIxLjcyOCwyNy4zMDQsMjEuNzI4eiBNMjcuMzA0LDE4LjE4OWMtMC42NjEsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5NnYwLjMwOCYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAsMC42NiwwLjUzNSwxLjE5NiwxLjE5NiwxLjE5NmMwLjY2LDAsMS4xOTYtMC41MzYsMS4xOTYtMS4xOTZ2LTAuMzA4QzI4LjUsMTguNzI2LDI3Ljk2NCwxOC4xODksMjcuMzA0LD'+\n\t\t\t'E4LjE4OXogTTI4LjE0OSw3LjAzMyYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjIyMy0wLjIyMi0wLjUzMS0wLjM1LTAuODQ2LTAuMzVoLTEuMTk2Yy0wLjY2MSwwLTEuMTk2LDAuNTM2LTEuMTk2LDEuMTk2YzAsMC42NjEsMC41MzUsMS4xOTYsMS4xOTYsMS4xOTYmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLDAuNjYxLDAuNTM1LDEuMTk2LDEuMTk2LDEuMTk2YzAuNjYsMCwxLjE5Ni0wLjUzNSwxLjE5Ni0xLjE5NlY3Ljg4QzI4LjUsNy41NjQsMjguMzcyLDcuMjU3LDI4LjE0OSw3LjAzM3ogTTIxLjg2MywxMy4yNjEmI3hkOyYjeGE7JiN4OTsmI3g5O2wwLjIyMS0wLjE0N2MwLjQyOC0wLjI4NSwwLjU0'+\n\t\t\t'Mi0wLjg2MywwLjI1Ny0xLjI5MWMtMC4yODYtMC40MjgtMC44NjMtMC41NDItMS4yOTEtMC4yNTZsLTAuMjIxLDAuMTQ2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuNDI3LDAuMjg2LTAuNTQyLDAuODYzLTAuMjU3LDEuMjkxYzAuMTgsMC4yNjksMC40NzQsMC40MTQsMC43NzQsMC40MTRDMjEuNTI0LDEzLjQxOCwyMS43MDQsMTMuMzY3LDIxLjg2MywxMy4yNjF6JiN4ZDsmI3hhOyYjeDk7JiN4OTsgTTE5LjMyOSwyMi45MjRoLTAuMjQyYy0wLjY2MSwwLTEuMTk2LDAuNTM2LTEuMTk2LDEuMTk2YzAsMC42NjEsMC41MzUsMS4xOTYsMS4xOTYsMS4xOTZoMC4yNDJjMC42NjEsMCwxLjE5Ni0wLjUzNS'+\n\t\t\t'wxLjE5Ni0xLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7QzIwLjUyNSwyMy40NiwxOS45OSwyMi45MjQsMTkuMzI5LDIyLjkyNHogTTE4LjU4NCwxNS4yNjRjMC4xNzgsMCwwLjM1Ny0wLjA1MSwwLjUxNy0wLjE1N2wwLjIyMS0wLjE0NyYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuNDI4LTAuMjg1LDAuNTQyLTAuODYzLDAuMjU3LTEuMjljLTAuMjg1LTAuNDI4LTAuODYzLTAuNTQyLTEuMjkxLTAuMjU3bC0wLjIyMiwwLjE0N2MtMC40MjcsMC4yODYtMC41NDIsMC44NjMtMC4yNTYsMS4yOTEmI3hkOyYjeGE7JiN4OTsmI3g5O0MxNy45ODksMTUuMTE5LDE4LjI4MywxNS4yNjQsMTguNTg0LDE1LjI2NHog'+\n\t\t\t'TTIyLjczOSwyMi45MjRoLTAuMjQyYy0wLjY2MSwwLTEuMTk2LDAuNTM2LTEuMTk2LDEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMCwwLjY2MSwwLjUzNSwxLjE5NiwxLjE5NiwxLjE5NmgwLjI0MmMwLjY2LDAsMS4xOTYtMC41MzUsMS4xOTYtMS4xOTZDMjMuOTM2LDIzLjQ2LDIzLjM5OSwyMi45MjQsMjIuNzM5LDIyLjkyNHogTTI1LjEwNCw5Ljk3NiYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjI4NS0wLjQyNy0wLjg2My0wLjU0Mi0xLjI5MS0wLjI1NmwtMC4yMjEsMC4xNDdjLTAuNDI4LDAuMjg1LTAuNTQyLDAuODYzLTAuMjU2LDEuMjljMC4xNzksMC4yNjksMC40NzQsMC40MTQsMC43NzQsMC'+\n\t\t\t'40MTQmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjE3OCwwLDAuMzU3LTAuMDUxLDAuNTE2LTAuMTU2bDAuMjIyLTAuMTQ4QzI1LjI3NCwxMC45ODEsMjUuMzg5LDEwLjQwMywyNS4xMDQsOS45NzZ6Ii8+CiA8L2c+CiA8ZyBzdHJva2U9IiMwMDAwMDAiIGZpbGw9IiNGRkZGRkYiIHN0cm9rZS13aWR0aD0iMC4yIiB0cmFuc2Zvcm09InRyYW5zbGF0ZSgxNiwxNikgc2NhbGUoMS4xKSB0cmFuc2xhdGUoLTE2LC0xNikiPgogIDxwYXRoIGQ9Ik0xNiwxNC44MDRINC42OTdjLTAuMzE1LDAtMC42MjQsMC4xMjgtMC44NDYsMC4zNTFDMy42MjcsMTUuMzc3LDMuNSwxNS42ODYsMy41LDE2djguMTImI3hkOyYj'+\n\t\t\t'eGE7JiN4OTsmI3g5O2MwLDAuMzE1LDAuMTI3LDAuNjI0LDAuMzUsMC44NDZjMC4yMjMsMC4yMjQsMC41MzEsMC4zNTEsMC44NDYsMC4zNTFIMTZjMC4zMiwwLDAuNjItMC4xMjQsMC44NDYtMC4zNTEmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjIyNi0wLjIyNiwwLjM1LTAuNTI1LDAuMzUtMC44NDZWMTZjMC0wLjMxNC0wLjEyOC0wLjYyMy0wLjM1LTAuODQ2QzE2LjYyMywxNC45MzIsMTYuMzE0LDE0LjgwNCwxNiwxNC44MDR6IE0xNC44MDQsMjIuOTI0JiN4ZDsmI3hhOyYjeDk7JiN4OTtINS44OTN2LTUuNzI4aDguOTExVjIyLjkyNHogTTQuNjk3LDEzLjk5OGMwLjY2MSwwLDEuMTk2LTAuNTM2LD'+\n\t\t\t'EuMTk2LTEuMTk2di0wLjMwOGMwLTAuNjYtMC41MzYtMS4xOTUtMS4xOTYtMS4xOTUmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC42NjEsMC0xLjE5NiwwLjUzNS0xLjE5NiwxLjE5NXYwLjMwOEMzLjUsMTMuNDYyLDQuMDM2LDEzLjk5OCw0LjY5NywxMy45OTh6IE00LjY5NywxMC40NzdjMC42NjEsMCwxLjE5Ny0wLjUzNiwxLjE5Ny0xLjE5N2gwJiN4ZDsmI3hhOyYjeDk7JiN4OTtWOS4wNzZjMC42NjEsMCwxLjE5Ni0wLjUzNSwxLjE5Ni0xLjE5NmMwLTAuNjYtMC41MzYtMS4xOTYtMS4xOTYtMS4xOTZINC42OTdjLTAuMzE1LDAtMC42MjMsMC4xMjctMC44NDYsMC4zNSYjeGQ7JiN4YTsmI3g5OyYj'+\n\t\t\t'eDk7QzMuNjI4LDcuMjU3LDMuNSw3LjU2NCwzLjUsNy44OHYxLjM5OUMzLjUsOS45NCw0LjAzNiwxMC40NzcsNC42OTcsMTAuNDc3eiBNMTkuMjg5LDkuMDc2aDAuMjQyYzAuNjYxLDAsMS4xOTYtMC41MzYsMS4xOTYtMS4xOTYmI3hkOyYjeGE7JiN4OTsmI3g5O3MtMC41MzUtMS4xOTYtMS4xOTYtMS4xOTZoLTAuMjQyYy0wLjY2MSwwLTEuMTk3LDAuNTM2LTEuMTk3LDEuMTk2UzE4LjYyOCw5LjA3NiwxOS4yODksOS4wNzZ6IE0xNi4xMjIsNi42ODRoLTAuMjQzJiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuNjYxLDAtMS4xOTYsMC41MzYtMS4xOTYsMS4xOTZzMC41MzYsMS4xOTYsMS4xOTYsMS4xOT'+\n\t\t\t'ZoMC4yNDNjMC42NjEsMCwxLjE5Ny0wLjUzNiwxLjE5Ny0xLjE5NlMxNi43ODIsNi42ODQsMTYuMTIyLDYuNjg0eiYjeGQ7JiN4YTsmI3g5OyYjeDk7IE0yMi42OTgsOS4wNzZoMC4yNDNjMC42NiwwLDEuMTk2LTAuNTM2LDEuMTk2LTEuMTk2cy0wLjUzNi0xLjE5Ni0xLjE5Ni0xLjE5NmgtMC4yNDNjLTAuNjYsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7UzIyLjAzOCw5LjA3NiwyMi42OTgsOS4wNzZ6IE05LjA2LDkuMDc2aDAuMjQyYzAuNjYsMCwxLjE5Ni0wLjUzNiwxLjE5Ni0xLjE5NlM5Ljk2Miw2LjY4NCw5LjMwMiw2LjY4NEg5LjA2JiN4ZDsmI3hhOyYj'+\n\t\t\t'eDk7JiN4OTtjLTAuNjYxLDAtMS4xOTcsMC41MzYtMS4xOTcsMS4xOTZTOC4zOTksOS4wNzYsOS4wNiw5LjA3NnogTTEyLjQ2OSw5LjA3NmgwLjI0M2MwLjY2MSwwLDEuMTk2LTAuNTM2LDEuMTk2LTEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtzLTAuNTM2LTEuMTk2LTEuMTk2LTEuMTk2aC0wLjI0M2MtMC42NjEsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5NlMxMS44MDgsOS4wNzYsMTIuNDY5LDkuMDc2eiBNMjcuMzA0LDExLjExMSYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjY2MSwwLTEuMTk2LDAuNTM1LTEuMTk2LDEuMTk2djAuMzA4YzAsMC42NiwwLjUzNSwxLjE5NiwxLjE5NiwxLjE5NmMwLj'+\n\t\t\t'Y2LDAsMS4xOTYtMC41MzYsMS4xOTYtMS4xOTZ2LTAuMzA4JiN4ZDsmI3hhOyYjeDk7JiN4OTtDMjguNSwxMS42NDYsMjcuOTY0LDExLjExMSwyNy4zMDQsMTEuMTExeiBNMjcuMzA0LDE0LjY1Yy0wLjY2MSwwLTEuMTk2LDAuNTM1LTEuMTk2LDEuMTk2djAuMzA4YzAsMC42NiwwLjUzNSwxLjE5NiwxLjE5NiwxLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuNjYsMCwxLjE5Ni0wLjUzNiwxLjE5Ni0xLjE5NnYtMC4zMDhDMjguNSwxNS4xODYsMjcuOTY0LDE0LjY1LDI3LjMwNCwxNC42NXogTTI3LjMwNCwyMS43MjhjLTAuNjYxLDAtMS4xOTYsMC41MzUtMS4xOTYsMS4xOTYmI3hkOyYjeGE7JiN4'+\n\t\t\t'OTsmI3g5O2gtMC4yMzRjLTAuNjYsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5NmMwLDAuNjYxLDAuNTM2LDEuMTk2LDEuMTk2LDEuMTk2aDEuNDMxYzAuMzE0LDAsMC42MjMtMC4xMjgsMC44NDYtMC4zNTEmI3hkOyYjeGE7JiN4OTsmI3g5O3MwLjM1MS0wLjUzLDAuMzUxLTAuODQ2di0xLjE5NkMyOC41LDIyLjI2NCwyNy45NjQsMjEuNzI4LDI3LjMwNCwyMS43Mjh6IE0yNy4zMDQsMTguMTg5Yy0wLjY2MSwwLTEuMTk2LDAuNTM2LTEuMTk2LDEuMTk2djAuMzA4JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMCwwLjY2LDAuNTM1LDEuMTk2LDEuMTk2LDEuMTk2YzAuNjYsMCwxLjE5Ni0wLjUzNiwxLjE5Ni'+\n\t\t\t'0xLjE5NnYtMC4zMDhDMjguNSwxOC43MjYsMjcuOTY0LDE4LjE4OSwyNy4zMDQsMTguMTg5eiBNMjguMTQ5LDcuMDMzJiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuMjIzLTAuMjIyLTAuNTMxLTAuMzUtMC44NDYtMC4zNWgtMS4xOTZjLTAuNjYxLDAtMS4xOTYsMC41MzYtMS4xOTYsMS4xOTZjMCwwLjY2MSwwLjUzNSwxLjE5NiwxLjE5NiwxLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAsMC42NjEsMC41MzUsMS4xOTYsMS4xOTYsMS4xOTZjMC42NiwwLDEuMTk2LTAuNTM1LDEuMTk2LTEuMTk2VjcuODhDMjguNSw3LjU2NCwyOC4zNzIsNy4yNTcsMjguMTQ5LDcuMDMzeiBNMjEuODYzLDEzLjI2MSYj'+\n\t\t\t'eGQ7JiN4YTsmI3g5OyYjeDk7bDAuMjIxLTAuMTQ3YzAuNDI4LTAuMjg1LDAuNTQyLTAuODYzLDAuMjU3LTEuMjkxYy0wLjI4Ni0wLjQyOC0wLjg2My0wLjU0Mi0xLjI5MS0wLjI1NmwtMC4yMjEsMC4xNDYmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC40MjcsMC4yODYtMC41NDIsMC44NjMtMC4yNTcsMS4yOTFjMC4xOCwwLjI2OSwwLjQ3NCwwLjQxNCwwLjc3NCwwLjQxNEMyMS41MjQsMTMuNDE4LDIxLjcwNCwxMy4zNjcsMjEuODYzLDEzLjI2MXomI3hkOyYjeGE7JiN4OTsmI3g5OyBNMTkuMzI5LDIyLjkyNGgtMC4yNDJjLTAuNjYxLDAtMS4xOTYsMC41MzYtMS4xOTYsMS4xOTZjMCwwLjY2MSwwLj'+\n\t\t\t'UzNSwxLjE5NiwxLjE5NiwxLjE5NmgwLjI0MmMwLjY2MSwwLDEuMTk2LTAuNTM1LDEuMTk2LTEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtDMjAuNTI1LDIzLjQ2LDE5Ljk5LDIyLjkyNCwxOS4zMjksMjIuOTI0eiBNMTguNTg0LDE1LjI2NGMwLjE3OCwwLDAuMzU3LTAuMDUxLDAuNTE3LTAuMTU3bDAuMjIxLTAuMTQ3JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC40MjgtMC4yODUsMC41NDItMC44NjMsMC4yNTctMS4yOWMtMC4yODUtMC40MjgtMC44NjMtMC41NDItMS4yOTEtMC4yNTdsLTAuMjIyLDAuMTQ3Yy0wLjQyNywwLjI4Ni0wLjU0MiwwLjg2My0wLjI1NiwxLjI5MSYjeGQ7JiN4YTsmI3g5OyYj'+\n\t\t\t'eDk7QzE3Ljk4OSwxNS4xMTksMTguMjgzLDE1LjI2NCwxOC41ODQsMTUuMjY0eiBNMjIuNzM5LDIyLjkyNGgtMC4yNDJjLTAuNjYxLDAtMS4xOTYsMC41MzYtMS4xOTYsMS4xOTYmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLDAuNjYxLDAuNTM1LDEuMTk2LDEuMTk2LDEuMTk2aDAuMjQyYzAuNjYsMCwxLjE5Ni0wLjUzNSwxLjE5Ni0xLjE5NkMyMy45MzYsMjMuNDYsMjMuMzk5LDIyLjkyNCwyMi43MzksMjIuOTI0eiBNMjUuMTA0LDkuOTc2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuMjg1LTAuNDI3LTAuODYzLTAuNTQyLTEuMjkxLTAuMjU2bC0wLjIyMSwwLjE0N2MtMC40MjgsMC4yODUtMC41NDIsMC'+\n\t\t\t'44NjMtMC4yNTYsMS4yOWMwLjE3OSwwLjI2OSwwLjQ3NCwwLjQxNCwwLjc3NCwwLjQxNCYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuMTc4LDAsMC4zNTctMC4wNTEsMC41MTYtMC4xNTZsMC4yMjItMC4xNDhDMjUuMjc0LDEwLjk4MSwyNS4zODksMTAuNDAzLDI1LjEwNCw5Ljk3NnoiLz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._button_image_normalscreen__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"button_image_normalscreen\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_image_normalscreen.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_image_normalscreen.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getIsFullscreen() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._button_image_normalscreen.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._button_image_normalscreen.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._button_image_normalscreen.style[domTransition]='';\n\t\t\t\tif (me._button_image_normalscreen.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._button_image_normalscreen.style.visibility=(Number(me._button_image_normalscreen.style.opacity)>0||!me._button_image_normalscreen.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._button_image_normalscreen.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._button_image_normalscreen.style.visibility=\"hidden\";\n\t\t\t\t\tme._button_image_normalscreen.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._button_image_normalscreen.onmouseover=function (e) {\n\t\t\tme._button_image_normalscreen__img.style.visibility='hidden';\n\t\t\tme._button_image_normalscreen__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._button_image_normalscreen.onmouseout=function (e) {\n\t\t\tme._button_image_normalscreen__img.style.visibility='inherit';\n\t\t\tme._button_image_normalscreen__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._button_image_normalscreen.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._button_fullscreen.appendChild(me._button_image_normalscreen);\n\t\tel=me._button_image_fullscreen=document.createElement('div');\n\t\tels=me._button_image_fullscreen__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSI+CiAgPHBhdGggZD0iTTI4LjE0OSw3LjAzNGMtMC4yMjMtMC4yMjMtMC41MzEtMC4zNTEtMC44NDYtMC4zNTFINC42OTdjLTAuMzE1LDAtMC42MjQsMC4xMjgtMC44NDYsMC4zNTEmI3hkOyYjeGE7JiN4OTsmI3g5O1MzLjUsNy41NjUsMy41LDcuODh2MTYuMjRjMCwwLjMxNSwwLjEyOCwwLjYyMywwLjM1MSwwLjg0NmMwLjIyMywwLjIyNCwwLjUzMSwwLjM1MSwwLjg0Niww'+\n\t\t\t'LjM1MWgyMi42MDcmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjMxOSwwLDAuNjItMC4xMjQsMC44NDYtMC4zNTFjMC4yMjctMC4yMjYsMC4zNTEtMC41MjYsMC4zNTEtMC44NDZWNy44OEMyOC41LDcuNTY1LDI4LjM3Miw3LjI1NywyOC4xNDksNy4wMzR6IE01Ljg5MywyMi45MjQmI3hkOyYjeGE7JiN4OTsmI3g5O1Y5LjA3NmgyMC4yMTV2MTMuODQ4SDUuODkzeiBNMTYsMTkuMjRjLTAuNjYxLDAtMS4xOTcsMC41MzUtMS4xOTcsMS4xOTZ2MC40NDhjMCwwLjY2MSwwLjUzNiwxLjE5NiwxLjE5NywxLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuNjYsMCwxLjE5Ni0wLjUzNSwxLjE5Ni0xLjE5NnYtMC'+\n\t\t\t'40NDhDMTcuMTk2LDE5Ljc3NSwxNi42NjEsMTkuMjQsMTYsMTkuMjR6IE0xMS42NywxNC44MDRoLTAuMzQyJiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuNjYxLDAtMS4xOTcsMC41MzUtMS4xOTcsMS4xOTZjMCwwLjY2MSwwLjUzNiwxLjE5NiwxLjE5NywxLjE5NmgwLjM0MmMwLjY2MSwwLDEuMTk2LTAuNTM1LDEuMTk2LTEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtDMTIuODY2LDE1LjMzOSwxMi4zMzEsMTQuODA0LDExLjY3LDE0LjgwNHogTTguMTk1LDE0LjgwNEg3Ljg1NGMtMC42NjEsMC0xLjE5NywwLjUzNS0xLjE5NywxLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAsMC42NjEsMC41MzYsMS4x'+\n\t\t\t'OTYsMS4xOTcsMS4xOTZoMC4zNDFjMC42NiwwLDEuMTk2LTAuNTM1LDEuMTk2LTEuMTk2QzkuMzkyLDE1LjMzOSw4Ljg1NSwxNC44MDQsOC4xOTUsMTQuODA0eiBNMTguMjg3LDEzLjQxMiYjeGQ7JiN4YTsmI3g5OyYjeDk7bC0wLjIyMiwwLjE0OGMtMC40MjcsMC4yODUtMC41NDEsMC44NjMtMC4yNTYsMS4yOWMwLjE4LDAuMjY5LDAuNDc0LDAuNDE0LDAuNzc0LDAuNDE0YzAuMTc4LDAsMC4zNTctMC4wNSwwLjUxNy0wLjE1NyYjeGQ7JiN4YTsmI3g5OyYjeDk7bDAuMjIxLTAuMTQ4YzAuNDI4LTAuMjg1LDAuNTQyLTAuODYzLDAuMjU3LTEuMjlDMTkuMjkzLDEzLjI0MiwxOC43MTUsMTMuMTI2LD'+\n\t\t\t'E4LjI4NywxMy40MTJ6IE0yMy44MTMsOS43MmwtMC4yMjIsMC4xNDcmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC40MjcsMC4yODYtMC41NDIsMC44NjQtMC4yNTYsMS4yOTFjMC4xNzksMC4yNjksMC40NzQsMC40MTQsMC43NzQsMC40MTRjMC4xNzgsMCwwLjM1Ny0wLjA1LDAuNTE3LTAuMTU3bDAuMjIxLTAuMTQ4JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC40MjctMC4yODUsMC41NDItMC44NjMsMC4yNTYtMS4yOTFDMjQuODE4LDkuNTQ5LDI0LjI0MSw5LjQzNCwyMy44MTMsOS43MnogTTE2LDE0LjgwNGgtMS4xOTZjLTAuNjYxLDAtMS4xOTYsMC41MzYtMS4xOTYsMS4xOTYmI3hkOyYjeGE7JiN4OTsm'+\n\t\t\t'I3g5O2MwLDAuNjYsMC41MzUsMS4xOTYsMS4xOTYsMS4xOTZjMCwwLjY2MSwwLjUzNSwxLjE5NiwxLjE5NiwxLjE5NmMwLjY2LDAsMS4xOTYtMC41MzUsMS4xOTYtMS4xOTZWMTYmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLTAuMzE1LTAuMTI4LTAuNjIzLTAuMzUtMC44NDZDMTYuNjIzLDE0LjkzMSwxNi4zMTQsMTQuODA0LDE2LDE0LjgwNHogTTIxLjA1LDExLjU2NWwtMC4yMjEsMC4xNDgmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC40MjcsMC4yODYtMC41NDIsMC44NjMtMC4yNTcsMS4yOTFjMC4xOCwwLjI2OCwwLjQ3NSwwLjQxMywwLjc3NCwwLjQxM2MwLjE3OCwwLDAuMzU3LTAuMDUxLDAuNTE3LT'+\n\t\t\t'AuMTU3bDAuMjIxLTAuMTQ4JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC40MjgtMC4yODYsMC41NDItMC44NjMsMC4yNTctMS4yOTFTMjEuNDc4LDExLjI4LDIxLjA1LDExLjU2NXoiLz4KIDwvZz4KIDxnIHN0cm9rZT0iIzAwMDAwMCIgZmlsbD0iI0ZGRkZGRiIgc3Ryb2tlLXdpZHRoPSIwLjIiPgogIDxwYXRoIGQ9Ik0yOC4xNDksNy4wMzRjLTAuMjIzLTAuMjIzLTAuNTMxLTAuMzUxLTAuODQ2LTAuMzUxSDQuNjk3Yy0wLjMxNSwwLTAuNjI0LDAuMTI4LTAuODQ2LDAuMzUxJiN4ZDsmI3hhOyYjeDk7JiN4OTtTMy41LDcuNTY1LDMuNSw3Ljg4djE2LjI0YzAsMC4zMTUsMC4xMjgsMC42MjMsMC4zNTEs'+\n\t\t\t'MC44NDZjMC4yMjMsMC4yMjQsMC41MzEsMC4zNTEsMC44NDYsMC4zNTFoMjIuNjA3JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4zMTksMCwwLjYyLTAuMTI0LDAuODQ2LTAuMzUxYzAuMjI3LTAuMjI2LDAuMzUxLTAuNTI2LDAuMzUxLTAuODQ2VjcuODhDMjguNSw3LjU2NSwyOC4zNzIsNy4yNTcsMjguMTQ5LDcuMDM0eiBNNS44OTMsMjIuOTI0JiN4ZDsmI3hhOyYjeDk7JiN4OTtWOS4wNzZoMjAuMjE1djEzLjg0OEg1Ljg5M3ogTTE2LDE5LjI0Yy0wLjY2MSwwLTEuMTk3LDAuNTM1LTEuMTk3LDEuMTk2djAuNDQ4YzAsMC42NjEsMC41MzYsMS4xOTYsMS4xOTcsMS4xOTYmI3hkOyYjeGE7JiN4OTsmI3'+\n\t\t\t'g5O2MwLjY2LDAsMS4xOTYtMC41MzUsMS4xOTYtMS4xOTZ2LTAuNDQ4QzE3LjE5NiwxOS43NzUsMTYuNjYxLDE5LjI0LDE2LDE5LjI0eiBNMTEuNjcsMTQuODA0aC0wLjM0MiYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjY2MSwwLTEuMTk3LDAuNTM1LTEuMTk3LDEuMTk2YzAsMC42NjEsMC41MzYsMS4xOTYsMS4xOTcsMS4xOTZoMC4zNDJjMC42NjEsMCwxLjE5Ni0wLjUzNSwxLjE5Ni0xLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7QzEyLjg2NiwxNS4zMzksMTIuMzMxLDE0LjgwNCwxMS42NywxNC44MDR6IE04LjE5NSwxNC44MDRINy44NTRjLTAuNjYxLDAtMS4xOTcsMC41MzUtMS4xOTcsMS4xOTYm'+\n\t\t\t'I3hkOyYjeGE7JiN4OTsmI3g5O2MwLDAuNjYxLDAuNTM2LDEuMTk2LDEuMTk3LDEuMTk2aDAuMzQxYzAuNjYsMCwxLjE5Ni0wLjUzNSwxLjE5Ni0xLjE5NkM5LjM5MiwxNS4zMzksOC44NTUsMTQuODA0LDguMTk1LDE0LjgwNHogTTE4LjI4NywxMy40MTImI3hkOyYjeGE7JiN4OTsmI3g5O2wtMC4yMjIsMC4xNDhjLTAuNDI3LDAuMjg1LTAuNTQxLDAuODYzLTAuMjU2LDEuMjljMC4xOCwwLjI2OSwwLjQ3NCwwLjQxNCwwLjc3NCwwLjQxNGMwLjE3OCwwLDAuMzU3LTAuMDUsMC41MTctMC4xNTcmI3hkOyYjeGE7JiN4OTsmI3g5O2wwLjIyMS0wLjE0OGMwLjQyOC0wLjI4NSwwLjU0Mi0wLjg2MywwLj'+\n\t\t\t'I1Ny0xLjI5QzE5LjI5MywxMy4yNDIsMTguNzE1LDEzLjEyNiwxOC4yODcsMTMuNDEyeiBNMjMuODEzLDkuNzJsLTAuMjIyLDAuMTQ3JiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuNDI3LDAuMjg2LTAuNTQyLDAuODY0LTAuMjU2LDEuMjkxYzAuMTc5LDAuMjY5LDAuNDc0LDAuNDE0LDAuNzc0LDAuNDE0YzAuMTc4LDAsMC4zNTctMC4wNSwwLjUxNy0wLjE1N2wwLjIyMS0wLjE0OCYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuNDI3LTAuMjg1LDAuNTQyLTAuODYzLDAuMjU2LTEuMjkxQzI0LjgxOCw5LjU0OSwyNC4yNDEsOS40MzQsMjMuODEzLDkuNzJ6IE0xNiwxNC44MDRoLTEuMTk2Yy0wLjY2MSwwLTEu'+\n\t\t\t'MTk2LDAuNTM2LTEuMTk2LDEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMCwwLjY2LDAuNTM1LDEuMTk2LDEuMTk2LDEuMTk2YzAsMC42NjEsMC41MzUsMS4xOTYsMS4xOTYsMS4xOTZjMC42NiwwLDEuMTk2LTAuNTM1LDEuMTk2LTEuMTk2VjE2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC0wLjMxNS0wLjEyOC0wLjYyMy0wLjM1LTAuODQ2QzE2LjYyMywxNC45MzEsMTYuMzE0LDE0LjgwNCwxNiwxNC44MDR6IE0yMS4wNSwxMS41NjVsLTAuMjIxLDAuMTQ4JiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuNDI3LDAuMjg2LTAuNTQyLDAuODYzLTAuMjU3LDEuMjkxYzAuMTgsMC4yNjgsMC40NzUsMC40MTMsMC'+\n\t\t\t'43NzQsMC40MTNjMC4xNzgsMCwwLjM1Ny0wLjA1MSwwLjUxNy0wLjE1N2wwLjIyMS0wLjE0OCYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuNDI4LTAuMjg2LDAuNTQyLTAuODYzLDAuMjU3LTEuMjkxUzIxLjQ3OCwxMS4yOCwyMS4wNSwxMS41NjV6Ii8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._button_image_fullscreen__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._button_image_fullscreen__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC0xNiwtMTYpIj4KICA8cGF0aCBkPSJNMjguMTQ5LDcuMDM0Yy0wLjIyMy0wLjIyMy0wLjUzMS0wLjM1MS0wLjg0Ni0wLjM1MUg0LjY5N2MtMC4zMTUsMC0wLjYyNCwwLjEyOC0wLjg0NiwwLjM1MSYjeGQ7JiN4YTsmI3g5OyYjeDk7UzMuNSw3LjU2NSwzLjUsNy44OHYxNi4yNGMwLDAu'+\n\t\t\t'MzE1LDAuMTI4LDAuNjIzLDAuMzUxLDAuODQ2YzAuMjIzLDAuMjI0LDAuNTMxLDAuMzUxLDAuODQ2LDAuMzUxaDIyLjYwNyYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuMzE5LDAsMC42Mi0wLjEyNCwwLjg0Ni0wLjM1MWMwLjIyNy0wLjIyNiwwLjM1MS0wLjUyNiwwLjM1MS0wLjg0NlY3Ljg4QzI4LjUsNy41NjUsMjguMzcyLDcuMjU3LDI4LjE0OSw3LjAzNHogTTUuODkzLDIyLjkyNCYjeGQ7JiN4YTsmI3g5OyYjeDk7VjkuMDc2aDIwLjIxNXYxMy44NDhINS44OTN6IE0xNiwxOS4yNGMtMC42NjEsMC0xLjE5NywwLjUzNS0xLjE5NywxLjE5NnYwLjQ0OGMwLDAuNjYxLDAuNTM2LDEuMTk2LDEuMTk3LD'+\n\t\t\t'EuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC42NiwwLDEuMTk2LTAuNTM1LDEuMTk2LTEuMTk2di0wLjQ0OEMxNy4xOTYsMTkuNzc1LDE2LjY2MSwxOS4yNCwxNiwxOS4yNHogTTExLjY3LDE0LjgwNGgtMC4zNDImI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC42NjEsMC0xLjE5NywwLjUzNS0xLjE5NywxLjE5NmMwLDAuNjYxLDAuNTM2LDEuMTk2LDEuMTk3LDEuMTk2aDAuMzQyYzAuNjYxLDAsMS4xOTYtMC41MzUsMS4xOTYtMS4xOTYmI3hkOyYjeGE7JiN4OTsmI3g5O0MxMi44NjYsMTUuMzM5LDEyLjMzMSwxNC44MDQsMTEuNjcsMTQuODA0eiBNOC4xOTUsMTQuODA0SDcuODU0Yy0wLjY2MSwwLTEu'+\n\t\t\t'MTk3LDAuNTM1LTEuMTk3LDEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMCwwLjY2MSwwLjUzNiwxLjE5NiwxLjE5NywxLjE5NmgwLjM0MWMwLjY2LDAsMS4xOTYtMC41MzUsMS4xOTYtMS4xOTZDOS4zOTIsMTUuMzM5LDguODU1LDE0LjgwNCw4LjE5NSwxNC44MDR6IE0xOC4yODcsMTMuNDEyJiN4ZDsmI3hhOyYjeDk7JiN4OTtsLTAuMjIyLDAuMTQ4Yy0wLjQyNywwLjI4NS0wLjU0MSwwLjg2My0wLjI1NiwxLjI5YzAuMTgsMC4yNjksMC40NzQsMC40MTQsMC43NzQsMC40MTRjMC4xNzgsMCwwLjM1Ny0wLjA1LDAuNTE3LTAuMTU3JiN4ZDsmI3hhOyYjeDk7JiN4OTtsMC4yMjEtMC4xNDhjMC40Mj'+\n\t\t\t'gtMC4yODUsMC41NDItMC44NjMsMC4yNTctMS4yOUMxOS4yOTMsMTMuMjQyLDE4LjcxNSwxMy4xMjYsMTguMjg3LDEzLjQxMnogTTIzLjgxMyw5LjcybC0wLjIyMiwwLjE0NyYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjQyNywwLjI4Ni0wLjU0MiwwLjg2NC0wLjI1NiwxLjI5MWMwLjE3OSwwLjI2OSwwLjQ3NCwwLjQxNCwwLjc3NCwwLjQxNGMwLjE3OCwwLDAuMzU3LTAuMDUsMC41MTctMC4xNTdsMC4yMjEtMC4xNDgmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjQyNy0wLjI4NSwwLjU0Mi0wLjg2MywwLjI1Ni0xLjI5MUMyNC44MTgsOS41NDksMjQuMjQxLDkuNDM0LDIzLjgxMyw5LjcyeiBNMTYsMTQu'+\n\t\t\t'ODA0aC0xLjE5NmMtMC42NjEsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAsMC42NiwwLjUzNSwxLjE5NiwxLjE5NiwxLjE5NmMwLDAuNjYxLDAuNTM1LDEuMTk2LDEuMTk2LDEuMTk2YzAuNjYsMCwxLjE5Ni0wLjUzNSwxLjE5Ni0xLjE5NlYxNiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAtMC4zMTUtMC4xMjgtMC42MjMtMC4zNS0wLjg0NkMxNi42MjMsMTQuOTMxLDE2LjMxNCwxNC44MDQsMTYsMTQuODA0eiBNMjEuMDUsMTEuNTY1bC0wLjIyMSwwLjE0OCYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjQyNywwLjI4Ni0wLjU0MiwwLjg2My0wLjI1NywxLjI5MWMwLj'+\n\t\t\t'E4LDAuMjY4LDAuNDc1LDAuNDEzLDAuNzc0LDAuNDEzYzAuMTc4LDAsMC4zNTctMC4wNTEsMC41MTctMC4xNTdsMC4yMjEtMC4xNDgmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjQyOC0wLjI4NiwwLjU0Mi0wLjg2MywwLjI1Ny0xLjI5MVMyMS40NzgsMTEuMjgsMjEuMDUsMTEuNTY1eiIvPgogPC9nPgogPGcgc3Ryb2tlPSIjMDAwMDAwIiBmaWxsPSIjRkZGRkZGIiBzdHJva2Utd2lkdGg9IjAuMiIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC0xNiwtMTYpIj4KICA8cGF0aCBkPSJNMjguMTQ5LDcuMDM0Yy0wLjIyMy0wLjIyMy0wLjUzMS0wLjM1MS0wLjg0'+\n\t\t\t'Ni0wLjM1MUg0LjY5N2MtMC4zMTUsMC0wLjYyNCwwLjEyOC0wLjg0NiwwLjM1MSYjeGQ7JiN4YTsmI3g5OyYjeDk7UzMuNSw3LjU2NSwzLjUsNy44OHYxNi4yNGMwLDAuMzE1LDAuMTI4LDAuNjIzLDAuMzUxLDAuODQ2YzAuMjIzLDAuMjI0LDAuNTMxLDAuMzUxLDAuODQ2LDAuMzUxaDIyLjYwNyYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuMzE5LDAsMC42Mi0wLjEyNCwwLjg0Ni0wLjM1MWMwLjIyNy0wLjIyNiwwLjM1MS0wLjUyNiwwLjM1MS0wLjg0NlY3Ljg4QzI4LjUsNy41NjUsMjguMzcyLDcuMjU3LDI4LjE0OSw3LjAzNHogTTUuODkzLDIyLjkyNCYjeGQ7JiN4YTsmI3g5OyYjeDk7VjkuMDc2aD'+\n\t\t\t'IwLjIxNXYxMy44NDhINS44OTN6IE0xNiwxOS4yNGMtMC42NjEsMC0xLjE5NywwLjUzNS0xLjE5NywxLjE5NnYwLjQ0OGMwLDAuNjYxLDAuNTM2LDEuMTk2LDEuMTk3LDEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC42NiwwLDEuMTk2LTAuNTM1LDEuMTk2LTEuMTk2di0wLjQ0OEMxNy4xOTYsMTkuNzc1LDE2LjY2MSwxOS4yNCwxNiwxOS4yNHogTTExLjY3LDE0LjgwNGgtMC4zNDImI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC42NjEsMC0xLjE5NywwLjUzNS0xLjE5NywxLjE5NmMwLDAuNjYxLDAuNTM2LDEuMTk2LDEuMTk3LDEuMTk2aDAuMzQyYzAuNjYxLDAsMS4xOTYtMC41MzUsMS4xOTYtMS4x'+\n\t\t\t'OTYmI3hkOyYjeGE7JiN4OTsmI3g5O0MxMi44NjYsMTUuMzM5LDEyLjMzMSwxNC44MDQsMTEuNjcsMTQuODA0eiBNOC4xOTUsMTQuODA0SDcuODU0Yy0wLjY2MSwwLTEuMTk3LDAuNTM1LTEuMTk3LDEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMCwwLjY2MSwwLjUzNiwxLjE5NiwxLjE5NywxLjE5NmgwLjM0MWMwLjY2LDAsMS4xOTYtMC41MzUsMS4xOTYtMS4xOTZDOS4zOTIsMTUuMzM5LDguODU1LDE0LjgwNCw4LjE5NSwxNC44MDR6IE0xOC4yODcsMTMuNDEyJiN4ZDsmI3hhOyYjeDk7JiN4OTtsLTAuMjIyLDAuMTQ4Yy0wLjQyNywwLjI4NS0wLjU0MSwwLjg2My0wLjI1NiwxLjI5YzAuMTgsMC'+\n\t\t\t'4yNjksMC40NzQsMC40MTQsMC43NzQsMC40MTRjMC4xNzgsMCwwLjM1Ny0wLjA1LDAuNTE3LTAuMTU3JiN4ZDsmI3hhOyYjeDk7JiN4OTtsMC4yMjEtMC4xNDhjMC40MjgtMC4yODUsMC41NDItMC44NjMsMC4yNTctMS4yOUMxOS4yOTMsMTMuMjQyLDE4LjcxNSwxMy4xMjYsMTguMjg3LDEzLjQxMnogTTIzLjgxMyw5LjcybC0wLjIyMiwwLjE0NyYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjQyNywwLjI4Ni0wLjU0MiwwLjg2NC0wLjI1NiwxLjI5MWMwLjE3OSwwLjI2OSwwLjQ3NCwwLjQxNCwwLjc3NCwwLjQxNGMwLjE3OCwwLDAuMzU3LTAuMDUsMC41MTctMC4xNTdsMC4yMjEtMC4xNDgmI3hkOyYj'+\n\t\t\t'eGE7JiN4OTsmI3g5O2MwLjQyNy0wLjI4NSwwLjU0Mi0wLjg2MywwLjI1Ni0xLjI5MUMyNC44MTgsOS41NDksMjQuMjQxLDkuNDM0LDIzLjgxMyw5LjcyeiBNMTYsMTQuODA0aC0xLjE5NmMtMC42NjEsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAsMC42NiwwLjUzNSwxLjE5NiwxLjE5NiwxLjE5NmMwLDAuNjYxLDAuNTM1LDEuMTk2LDEuMTk2LDEuMTk2YzAuNjYsMCwxLjE5Ni0wLjUzNSwxLjE5Ni0xLjE5NlYxNiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAtMC4zMTUtMC4xMjgtMC42MjMtMC4zNS0wLjg0NkMxNi42MjMsMTQuOTMxLDE2LjMxNCwxNC44MDQsMT'+\n\t\t\t'YsMTQuODA0eiBNMjEuMDUsMTEuNTY1bC0wLjIyMSwwLjE0OCYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjQyNywwLjI4Ni0wLjU0MiwwLjg2My0wLjI1NywxLjI5MWMwLjE4LDAuMjY4LDAuNDc1LDAuNDEzLDAuNzc0LDAuNDEzYzAuMTc4LDAsMC4zNTctMC4wNTEsMC41MTctMC4xNTdsMC4yMjEtMC4xNDgmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjQyOC0wLjI4NiwwLjU0Mi0wLjg2MywwLjI1Ny0xLjI5MVMyMS40NzgsMTEuMjgsMjEuMDUsMTEuNTY1eiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._button_image_fullscreen__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"button_image_fullscreen\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_image_fullscreen.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_image_fullscreen.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getIsFullscreen() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._button_image_fullscreen.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._button_image_fullscreen.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._button_image_fullscreen.style[domTransition]='';\n\t\t\t\tif (me._button_image_fullscreen.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._button_image_fullscreen.style.visibility=\"hidden\";\n\t\t\t\t\tme._button_image_fullscreen.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._button_image_fullscreen.style.visibility=(Number(me._button_image_fullscreen.style.opacity)>0||!me._button_image_fullscreen.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._button_image_fullscreen.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._button_image_fullscreen.onmouseover=function (e) {\n\t\t\tme._button_image_fullscreen__img.style.visibility='hidden';\n\t\t\tme._button_image_fullscreen__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._button_image_fullscreen.onmouseout=function (e) {\n\t\t\tme._button_image_fullscreen__img.style.visibility='inherit';\n\t\t\tme._button_image_fullscreen__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._button_image_fullscreen.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._button_fullscreen.appendChild(me._button_image_fullscreen);\n\t\tel=me._tt_fullscreen=document.createElement('div');\n\t\tels=me._tt_fullscreen__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"tt_fullscreen\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 32px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 100px;';\n\t\ths+='pointer-events:auto;';\n\t\ths+='text-shadow: 1px 1px 4px #000000;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: auto;';\n\t\ths+='height: auto;';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: nowrap;';\n\t\ths+='padding: 0px 1px 0px 1px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=\"\";\n\t\tel.appendChild(els);\n\t\tme._tt_fullscreen.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._tt_fullscreen.logicBlock_position = function() {\n\t\t\tvar newLogicStatePosition;\n\t\t\tif (\n\t\t\t\t((player.getHasTouch() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStatePosition = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStatePosition = -1;\n\t\t\t}\n\t\t\tif (me._tt_fullscreen.ggCurrentLogicStatePosition != newLogicStatePosition) {\n\t\t\t\tme._tt_fullscreen.ggCurrentLogicStatePosition = newLogicStatePosition;\n\t\t\t\tme._tt_fullscreen.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_fullscreen.ggCurrentLogicStatePosition == 0) {\n\t\t\t\t\tthis.ggDx = 0;\n\t\t\t\t\tme._tt_fullscreen.style.top='-25px';\n\t\t\t\t\tme._tt_fullscreen.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_fullscreen.ggDx=0;\n\t\t\t\t\tme._tt_fullscreen.style.top='32px';\n\t\t\t\t\tme._tt_fullscreen.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_fullscreen.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['button_fullscreen'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._tt_fullscreen.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._tt_fullscreen.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._tt_fullscreen.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_fullscreen.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._tt_fullscreen.style.visibility=(Number(me._tt_fullscreen.style.opacity)>0||!me._tt_fullscreen.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._tt_fullscreen.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_fullscreen.style.visibility=\"hidden\";\n\t\t\t\t\tme._tt_fullscreen.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_fullscreen.logicBlock_text = function() {\n\t\t\tvar newLogicStateText;\n\t\t\tif (\n\t\t\t\t((player.getIsFullscreen() == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateText = 0;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((player.getIsFullscreen() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateText = 1;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateText = -1;\n\t\t\t}\n\t\t\tif (me._tt_fullscreen.ggCurrentLogicStateText != newLogicStateText) {\n\t\t\t\tme._tt_fullscreen.ggCurrentLogicStateText = newLogicStateText;\n\t\t\t\tme._tt_fullscreen.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_fullscreen.ggCurrentLogicStateText == 0) {\n\t\t\t\t\tme._tt_fullscreen.ggText=\"Enter Fullscreen\";\n\t\t\t\t\tme._tt_fullscreen__text.innerHTML=me._tt_fullscreen.ggText;\n\t\t\t\t\tif (me._tt_fullscreen.ggUpdateText) {\n\t\t\t\t\tme._tt_fullscreen.ggUpdateText=function() {\n\t\t\t\t\t\tvar hs=\"Enter Fullscreen\";\n\t\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (me._tt_fullscreen.ggUpdatePosition) me._tt_fullscreen.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse if (me._tt_fullscreen.ggCurrentLogicStateText == 1) {\n\t\t\t\t\tme._tt_fullscreen.ggText=\"Exit Fullscreen\";\n\t\t\t\t\tme._tt_fullscreen__text.innerHTML=me._tt_fullscreen.ggText;\n\t\t\t\t\tif (me._tt_fullscreen.ggUpdateText) {\n\t\t\t\t\tme._tt_fullscreen.ggUpdateText=function() {\n\t\t\t\t\t\tvar hs=\"Exit Fullscreen\";\n\t\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (me._tt_fullscreen.ggUpdatePosition) me._tt_fullscreen.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_fullscreen.ggText=\"\";\n\t\t\t\t\tme._tt_fullscreen__text.innerHTML=me._tt_fullscreen.ggText;\n\t\t\t\t\tif (me._tt_fullscreen.ggUpdateText) {\n\t\t\t\t\tme._tt_fullscreen.ggUpdateText=function() {\n\t\t\t\t\t\tvar hs=\"\";\n\t\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (me._tt_fullscreen.ggUpdatePosition) me._tt_fullscreen.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_fullscreen.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t\tthis.style[domTransition]='left 0';\n\t\t\tthis.ggTextDiv.style.left=((98-this.ggTextDiv.offsetWidth)/2) + 'px';\n\t\t}\n\t\tme._button_fullscreen.appendChild(me._tt_fullscreen);\n\t\tme._container_1.appendChild(me._button_fullscreen);\n\t\tel=me._gyro=document.createElement('div');\n\t\tel.ggId=\"gyro\";\n\t\tel.ggDx=123;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='bottom : 20px;';\n\t\ths+='height : 32px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._gyro.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._gyro.onclick=function (e) {\n\t\t\tplayer.setUseGyro(!(player.getUseGyro()));\n\t\t}\n\t\tme._gyro.onmouseover=function (e) {\n\t\t\tme.elementMouseOver['gyro']=true;\n\t\t\tme._tt_gyro.logicBlock_visible();\n\t\t}\n\t\tme._gyro.onmouseout=function (e) {\n\t\t\tme.elementMouseOver['gyro']=false;\n\t\t\tme._tt_gyro.logicBlock_visible();\n\t\t}\n\t\tme._gyro.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['gyro']=false;\n\t\t\tme._tt_gyro.logicBlock_visible();\n\t\t}\n\t\tme._gyro.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._gyro_on=document.createElement('div');\n\t\tels=me._gyro_on__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\tme._gyro_on__img.setAttribute('src',basePath + 'images/gyro_on.svg');\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._gyro_on__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\tme._gyro_on__imgo.setAttribute('src',basePath + 'images/gyro_on__o.svg');\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"gyro_on\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 0px;';\n\t\ths+='opacity : 0;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._gyro_on.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._gyro_on.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((player.getUseGyro() == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._gyro_on.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._gyro_on.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._gyro_on.style[domTransition]='opacity 0s';\n\t\t\t\tif (me._gyro_on.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tme._gyro_on.style.visibility=me._gyro_on.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._gyro_on.style.opacity=1;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._gyro_on.style.visibility=\"hidden\";\n\t\t\t\t\tme._gyro_on.style.opacity=0;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._gyro_on.onmouseover=function (e) {\n\t\t\tme._gyro_on__img.style.visibility='hidden';\n\t\t\tme._gyro_on__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._gyro_on.onmouseout=function (e) {\n\t\t\tme._gyro_on__img.style.visibility='inherit';\n\t\t\tme._gyro_on__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._gyro_on.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._gyro.appendChild(me._gyro_on);\n\t\tel=me._gyro_off=document.createElement('div');\n\t\tels=me._gyro_off__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\tme._gyro_off__img.setAttribute('src',basePath + 'images/gyro_off.svg');\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._gyro_off__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\tme._gyro_off__imgo.setAttribute('src',basePath + 'images/gyro_off__o.svg');\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"gyro_off\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 0px;';\n\t\ths+='opacity : 0;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._gyro_off.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._gyro_off.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((player.getUseGyro() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._gyro_off.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._gyro_off.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._gyro_off.style[domTransition]='opacity 0s';\n\t\t\t\tif (me._gyro_off.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tme._gyro_off.style.visibility=me._gyro_off.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._gyro_off.style.opacity=1;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._gyro_off.style.visibility=\"hidden\";\n\t\t\t\t\tme._gyro_off.style.opacity=0;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._gyro_off.onmouseover=function (e) {\n\t\t\tme._gyro_off__img.style.visibility='hidden';\n\t\t\tme._gyro_off__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._gyro_off.onmouseout=function (e) {\n\t\t\tme._gyro_off__img.style.visibility='inherit';\n\t\t\tme._gyro_off__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._gyro_off.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._gyro.appendChild(me._gyro_off);\n\t\tel=me._tt_gyro=document.createElement('div');\n\t\tels=me._tt_gyro__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"tt_gyro\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 32px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 100px;';\n\t\ths+='pointer-events:auto;';\n\t\ths+='text-shadow: 1px 1px 4px #000000;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: auto;';\n\t\ths+='height: auto;';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: nowrap;';\n\t\ths+='padding: 0px 1px 0px 1px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=\"\";\n\t\tel.appendChild(els);\n\t\tme._tt_gyro.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._tt_gyro.logicBlock_position = function() {\n\t\t\tvar newLogicStatePosition;\n\t\t\tif (\n\t\t\t\t((player.getHasTouch() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStatePosition = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStatePosition = -1;\n\t\t\t}\n\t\t\tif (me._tt_gyro.ggCurrentLogicStatePosition != newLogicStatePosition) {\n\t\t\t\tme._tt_gyro.ggCurrentLogicStatePosition = newLogicStatePosition;\n\t\t\t\tme._tt_gyro.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_gyro.ggCurrentLogicStatePosition == 0) {\n\t\t\t\t\tthis.ggDx = 0;\n\t\t\t\t\tme._tt_gyro.style.top='-25px';\n\t\t\t\t\tme._tt_gyro.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_gyro.ggDx=0;\n\t\t\t\t\tme._tt_gyro.style.top='32px';\n\t\t\t\t\tme._tt_gyro.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_gyro.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['gyro'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._tt_gyro.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._tt_gyro.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._tt_gyro.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_gyro.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._tt_gyro.style.visibility=(Number(me._tt_gyro.style.opacity)>0||!me._tt_gyro.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._tt_gyro.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_gyro.style.visibility=\"hidden\";\n\t\t\t\t\tme._tt_gyro.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_gyro.logicBlock_text = function() {\n\t\t\tvar newLogicStateText;\n\t\t\tif (\n\t\t\t\t((player.getUseGyro() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateText = 0;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((player.getUseGyro() == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateText = 1;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateText = -1;\n\t\t\t}\n\t\t\tif (me._tt_gyro.ggCurrentLogicStateText != newLogicStateText) {\n\t\t\t\tme._tt_gyro.ggCurrentLogicStateText = newLogicStateText;\n\t\t\t\tme._tt_gyro.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_gyro.ggCurrentLogicStateText == 0) {\n\t\t\t\t\tme._tt_gyro.ggText=\"Gyroscope Off\";\n\t\t\t\t\tme._tt_gyro__text.innerHTML=me._tt_gyro.ggText;\n\t\t\t\t\tif (me._tt_gyro.ggUpdateText) {\n\t\t\t\t\tme._tt_gyro.ggUpdateText=function() {\n\t\t\t\t\t\tvar hs=\"Gyroscope Off\";\n\t\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (me._tt_gyro.ggUpdatePosition) me._tt_gyro.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse if (me._tt_gyro.ggCurrentLogicStateText == 1) {\n\t\t\t\t\tme._tt_gyro.ggText=\"Gyroscope On\";\n\t\t\t\t\tme._tt_gyro__text.innerHTML=me._tt_gyro.ggText;\n\t\t\t\t\tif (me._tt_gyro.ggUpdateText) {\n\t\t\t\t\tme._tt_gyro.ggUpdateText=function() {\n\t\t\t\t\t\tvar hs=\"Gyroscope On\";\n\t\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (me._tt_gyro.ggUpdatePosition) me._tt_gyro.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_gyro.ggText=\"\";\n\t\t\t\t\tme._tt_gyro__text.innerHTML=me._tt_gyro.ggText;\n\t\t\t\t\tif (me._tt_gyro.ggUpdateText) {\n\t\t\t\t\tme._tt_gyro.ggUpdateText=function() {\n\t\t\t\t\t\tvar hs=\"\";\n\t\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (me._tt_gyro.ggUpdatePosition) me._tt_gyro.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_gyro.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t\tthis.style[domTransition]='left 0';\n\t\t\tthis.ggTextDiv.style.left=((98-this.ggTextDiv.offsetWidth)/2) + 'px';\n\t\t}\n\t\tme._gyro.appendChild(me._tt_gyro);\n\t\tme._container_1.appendChild(me._gyro);\n\t\tel=me._button_auto_rotate=document.createElement('div');\n\t\tel.ggId=\"button_auto_rotate\";\n\t\tel.ggDx=48;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='bottom : 20px;';\n\t\ths+='height : 32px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_auto_rotate.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_auto_rotate.onclick=function (e) {\n\t\t\tplayer.toggleAutorotate();\n\t\t}\n\t\tme._button_auto_rotate.onmouseover=function (e) {\n\t\t\tme.elementMouseOver['button_auto_rotate']=true;\n\t\t\tme._tt_rotate_start.logicBlock_visible();\n\t\t}\n\t\tme._button_auto_rotate.onmouseout=function (e) {\n\t\t\tme.elementMouseOver['button_auto_rotate']=false;\n\t\t\tme._tt_rotate_start.logicBlock_visible();\n\t\t}\n\t\tme._button_auto_rotate.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['button_auto_rotate']=false;\n\t\t\tme._tt_rotate_start.logicBlock_visible();\n\t\t}\n\t\tme._button_auto_rotate.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._stop_rotate_image=document.createElement('div');\n\t\tels=me._stop_rotate_image__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSI+CiAgPHBhdGggZD0iTTE2LDMuNUM5LjA5NiwzLjUsMy41LDkuMDk2LDMuNSwxNmMwLDYuOTA0LDUuNTk2LDEyLjUsMTIuNSwxMi41YzYuOTAzLDAsMTIuNDk5LTUuNTk2LDEyLjUtMTIuNSYjeGQ7JiN4YTsmI3g5OyYjeDk7QzI4LjQ5OCw5LjA5NiwyMi45MDMsMy41LDE2LDMuNXogTTIzLjE0NiwyMy4xNDdjLTEuODMzLDEuODMxLTQuMzUyLDIuOTU5LTcuMTQ2LDIuOTYx'+\n\t\t\t'Yy0yLjc5Ni0wLjAwMi01LjMxNS0xLjEzLTcuMTQ3LTIuOTYxJiN4ZDsmI3hhOyYjeDk7JiN4OTtDNy4wMjEsMjEuMzE0LDUuODkzLDE4Ljc5NSw1Ljg5MiwxNmMwLjAwMS0yLjc5NSwxLjEzLTUuMzE0LDIuOTYxLTcuMTQ3YzEuODMzLTEuODMxLDQuMzUyLTIuOTU5LDcuMTQ3LTIuOTYmI3hkOyYjeGE7JiN4OTsmI3g5O2MyLjc5NSwwLjAwMSw1LjMxMywxLjEzLDcuMTQ2LDIuOTZjMS44MzEsMS44MzMsMi45Niw0LjM1MiwyLjk2LDcuMTQ3UzI0Ljk3OCwyMS4zMTQsMjMuMTQ2LDIzLjE0N3ogTTIzLjkwNywxMy4zOTImI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC43NjMtMS4wMjQtMS45MDYtMS43Nz'+\n\t\t\t'YtMy4yNjItMi4zMDVDMTkuMjg3LDEwLjU2MiwxNy43LDEwLjI3LDE2LDEwLjI2OWMtMi4yNjgsMC4wMDMtNC4zMzMsMC41MTYtNS45MjUsMS40MjQmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC43OTUsMC40NTYtMS40NzcsMS4wMTYtMS45ODMsMS43Yy0wLjUwNSwwLjY4LTAuODI4LDEuNTA4LTAuODI2LDIuMzkyYy0wLjAwMiwwLjgxOSwwLjI3NiwxLjU5NSwwLjcyMiwyLjI0MyYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuNDQ1LDAuNjUxLDEuMDQ5LDEuMTk0LDEuNzU1LDEuNjQ2YzAuMTk5LDAuMTI4LDAuNDIzLDAuMTg4LDAuNjQzLDAuMTg4YzAuMzk1LDAsMC43ODEtMC4xOTUsMS4wMDktMC41NTMm'+\n\t\t\t'I3hkOyYjeGE7JiN4OTsmI3g5O2MwLjM1Ni0wLjU1NywwLjE5My0xLjI5Ni0wLjM2My0xLjY1MWwtMC4wMDEtMC4wMDFjLTAuNDktMC4zMTItMC44NDgtMC42NTUtMS4wNjUtMC45NzdjLTAuMjE4LTAuMzI0LTAuMzA0LTAuNjA4LTAuMzA2LTAuODk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4wMDItMC4zMSwwLjEwMi0wLjYxNywwLjM1OC0wLjk3MWMwLjM4MS0wLjUyNSwxLjE1LTEuMDkyLDIuMi0xLjQ5NWMxLjA0OC0wLjQwNiwyLjM2MS0wLjY1OCwzLjc4My0wLjY1NyYjeGQ7JiN4YTsmI3g5OyYjeDk7YzEuODk1LTAuMDAzLDMuNTk5LDAuNDUxLDQuNzM0LDEuMTA3YzAuNTY5LDAuMzI1LDAuOT'+\n\t\t\t'kyLDAuNjk2LDEuMjQ4LDEuMDQ1YzAuMjU4LDAuMzU0LDAuMzU2LDAuNjYxLDAuMzU4LDAuOTcxJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4wMDUsMC41MDMtMC4zMDUsMS4xMDUtMS4xMzUsMS43MTJjLTAuNTM2LDAuMzg3LTAuNjU2LDEuMTM1LTAuMjcxLDEuNjcxYzAuMzg3LDAuNTM1LDEuMTM1LDAuNjU2LDEuNjcxLDAuMjcxJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMS4yMTItMC44NjcsMi4xMjMtMi4xMywyLjEyNy0zLjY1M0MyNC43MzUsMTQuOSwyNC40MTIsMTQuMDcyLDIzLjkwNywxMy4zOTJ6IE0xOS4zNjQsMTYuMTgyYy0wLjQ2OC0wLjQ2Ny0xLjIyNi0wLjQ2Ny0xLjY5MiwwJiN4ZDsmI3hh'+\n\t\t\t'OyYjeDk7JiN4OTtsLTEuNTU3LDEuNTU4bC0xLjU1OC0xLjU1OGMtMC40NjctMC40NjctMS4yMjQtMC40NjctMS42OTEsMGMtMC40NjcsMC40NjctMC40NjcsMS4yMjUsMCwxLjY5MmwxLjU1NywxLjU1N2wtMS41NTcsMS41NTcmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC40NjcsMC40NjgtMC40NjcsMS4yMjYsMCwxLjY5MmMwLjIzMywwLjIzMywwLjU0LDAuMzUxLDAuODQ2LDAuMzUxYzAuMzA3LDAsMC42MTItMC4xMTcsMC44NDYtMC4zNTFsMS41NTgtMS41NThsMS41NTcsMS41NTgmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjIzMywwLjIzMywwLjU0LDAuMzUxLDAuODQ2LDAuMzUxYzAuMzA3LDAsMC'+\n\t\t\t'42MTItMC4xMTcsMC44NDctMC4zNTFjMC40NjctMC40NjcsMC40NjctMS4yMjUsMC0xLjY5MmwtMS41NTgtMS41NTdsMS41NTgtMS41NTcmI3hkOyYjeGE7JiN4OTsmI3g5O0MxOS44MzEsMTcuNDA2LDE5LjgzMSwxNi42NDgsMTkuMzY0LDE2LjE4MnoiLz4KIDwvZz4KIDxnIHN0cm9rZT0iIzAwMDAwMCIgZmlsbD0iI0ZGRkZGRiIgc3Ryb2tlLXdpZHRoPSIwLjIiPgogIDxwYXRoIGQ9Ik0xNiwzLjVDOS4wOTYsMy41LDMuNSw5LjA5NiwzLjUsMTZjMCw2LjkwNCw1LjU5NiwxMi41LDEyLjUsMTIuNWM2LjkwMywwLDEyLjQ5OS01LjU5NiwxMi41LTEyLjUmI3hkOyYjeGE7JiN4OTsmI3g5O0MyOC40'+\n\t\t\t'OTgsOS4wOTYsMjIuOTAzLDMuNSwxNiwzLjV6IE0yMy4xNDYsMjMuMTQ3Yy0xLjgzMywxLjgzMS00LjM1MiwyLjk1OS03LjE0NiwyLjk2MWMtMi43OTYtMC4wMDItNS4zMTUtMS4xMy03LjE0Ny0yLjk2MSYjeGQ7JiN4YTsmI3g5OyYjeDk7QzcuMDIxLDIxLjMxNCw1Ljg5MywxOC43OTUsNS44OTIsMTZjMC4wMDEtMi43OTUsMS4xMy01LjMxNCwyLjk2MS03LjE0N2MxLjgzMy0xLjgzMSw0LjM1Mi0yLjk1OSw3LjE0Ny0yLjk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMi43OTUsMC4wMDEsNS4zMTMsMS4xMyw3LjE0NiwyLjk2YzEuODMxLDEuODMzLDIuOTYsNC4zNTIsMi45Niw3LjE0N1MyNC45NzgsMj'+\n\t\t\t'EuMzE0LDIzLjE0NiwyMy4xNDd6IE0yMy45MDcsMTMuMzkyJiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuNzYzLTEuMDI0LTEuOTA2LTEuNzc2LTMuMjYyLTIuMzA1QzE5LjI4NywxMC41NjIsMTcuNywxMC4yNywxNiwxMC4yNjljLTIuMjY4LDAuMDAzLTQuMzMzLDAuNTE2LTUuOTI1LDEuNDI0JiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuNzk1LDAuNDU2LTEuNDc3LDEuMDE2LTEuOTgzLDEuN2MtMC41MDUsMC42OC0wLjgyOCwxLjUwOC0wLjgyNiwyLjM5MmMtMC4wMDIsMC44MTksMC4yNzYsMS41OTUsMC43MjIsMi4yNDMmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjQ0NSwwLjY1MSwxLjA0OSwxLjE5NCwx'+\n\t\t\t'Ljc1NSwxLjY0NmMwLjE5OSwwLjEyOCwwLjQyMywwLjE4OCwwLjY0MywwLjE4OGMwLjM5NSwwLDAuNzgxLTAuMTk1LDEuMDA5LTAuNTUzJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4zNTYtMC41NTcsMC4xOTMtMS4yOTYtMC4zNjMtMS42NTFsLTAuMDAxLTAuMDAxYy0wLjQ5LTAuMzEyLTAuODQ4LTAuNjU1LTEuMDY1LTAuOTc3Yy0wLjIxOC0wLjMyNC0wLjMwNC0wLjYwOC0wLjMwNi0wLjg5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuMDAyLTAuMzEsMC4xMDItMC42MTcsMC4zNTgtMC45NzFjMC4zODEtMC41MjUsMS4xNS0xLjA5MiwyLjItMS40OTVjMS4wNDgtMC40MDYsMi4zNjEtMC42NTgsMy43OD'+\n\t\t\t'MtMC42NTcmI3hkOyYjeGE7JiN4OTsmI3g5O2MxLjg5NS0wLjAwMywzLjU5OSwwLjQ1MSw0LjczNCwxLjEwN2MwLjU2OSwwLjMyNSwwLjk5MiwwLjY5NiwxLjI0OCwxLjA0NWMwLjI1OCwwLjM1NCwwLjM1NiwwLjY2MSwwLjM1OCwwLjk3MSYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuMDA1LDAuNTAzLTAuMzA1LDEuMTA1LTEuMTM1LDEuNzEyYy0wLjUzNiwwLjM4Ny0wLjY1NiwxLjEzNS0wLjI3MSwxLjY3MWMwLjM4NywwLjUzNSwxLjEzNSwwLjY1NiwxLjY3MSwwLjI3MSYjeGQ7JiN4YTsmI3g5OyYjeDk7YzEuMjEyLTAuODY3LDIuMTIzLTIuMTMsMi4xMjctMy42NTNDMjQuNzM1LDE0LjksMjQuNDEy'+\n\t\t\t'LDE0LjA3MiwyMy45MDcsMTMuMzkyeiBNMTkuMzY0LDE2LjE4MmMtMC40NjgtMC40NjctMS4yMjYtMC40NjctMS42OTIsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7bC0xLjU1NywxLjU1OGwtMS41NTgtMS41NThjLTAuNDY3LTAuNDY3LTEuMjI0LTAuNDY3LTEuNjkxLDBjLTAuNDY3LDAuNDY3LTAuNDY3LDEuMjI1LDAsMS42OTJsMS41NTcsMS41NTdsLTEuNTU3LDEuNTU3JiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTAuNDY3LDAuNDY4LTAuNDY3LDEuMjI2LDAsMS42OTJjMC4yMzMsMC4yMzMsMC41NCwwLjM1MSwwLjg0NiwwLjM1MWMwLjMwNywwLDAuNjEyLTAuMTE3LDAuODQ2LTAuMzUxbDEuNTU4LTEuNT'+\n\t\t\t'U4bDEuNTU3LDEuNTU4JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4yMzMsMC4yMzMsMC41NCwwLjM1MSwwLjg0NiwwLjM1MWMwLjMwNywwLDAuNjEyLTAuMTE3LDAuODQ3LTAuMzUxYzAuNDY3LTAuNDY3LDAuNDY3LTEuMjI1LDAtMS42OTJsLTEuNTU4LTEuNTU3bDEuNTU4LTEuNTU3JiN4ZDsmI3hhOyYjeDk7JiN4OTtDMTkuODMxLDE3LjQwNiwxOS44MzEsMTYuNjQ4LDE5LjM2NCwxNi4xODJ6Ii8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._stop_rotate_image__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._stop_rotate_image__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC0xNiwtMTYpIj4KICA8cGF0aCBkPSJNMTYsMy41QzkuMDk2LDMuNSwzLjUsOS4wOTYsMy41LDE2YzAsNi45MDQsNS41OTYsMTIuNSwxMi41LDEyLjVjNi45MDMsMCwxMi40OTktNS41OTYsMTIuNS0xMi41JiN4ZDsmI3hhOyYjeDk7JiN4OTtDMjguNDk4LDkuMDk2LDIyLjkwMywzLjUs'+\n\t\t\t'MTYsMy41eiBNMjMuMTQ2LDIzLjE0N2MtMS44MzMsMS44MzEtNC4zNTIsMi45NTktNy4xNDYsMi45NjFjLTIuNzk2LTAuMDAyLTUuMzE1LTEuMTMtNy4xNDctMi45NjEmI3hkOyYjeGE7JiN4OTsmI3g5O0M3LjAyMSwyMS4zMTQsNS44OTMsMTguNzk1LDUuODkyLDE2YzAuMDAxLTIuNzk1LDEuMTMtNS4zMTQsMi45NjEtNy4xNDdjMS44MzMtMS44MzEsNC4zNTItMi45NTksNy4xNDctMi45NiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzIuNzk1LDAuMDAxLDUuMzEzLDEuMTMsNy4xNDYsMi45NmMxLjgzMSwxLjgzMywyLjk2LDQuMzUyLDIuOTYsNy4xNDdTMjQuOTc4LDIxLjMxNCwyMy4xNDYsMjMuMTQ3ei'+\n\t\t\t'BNMjMuOTA3LDEzLjM5MiYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjc2My0xLjAyNC0xLjkwNi0xLjc3Ni0zLjI2Mi0yLjMwNUMxOS4yODcsMTAuNTYyLDE3LjcsMTAuMjcsMTYsMTAuMjY5Yy0yLjI2OCwwLjAwMy00LjMzMywwLjUxNi01LjkyNSwxLjQyNCYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjc5NSwwLjQ1Ni0xLjQ3NywxLjAxNi0xLjk4MywxLjdjLTAuNTA1LDAuNjgtMC44MjgsMS41MDgtMC44MjYsMi4zOTJjLTAuMDAyLDAuODE5LDAuMjc2LDEuNTk1LDAuNzIyLDIuMjQzJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC40NDUsMC42NTEsMS4wNDksMS4xOTQsMS43NTUsMS42NDZjMC4xOTksMC4x'+\n\t\t\t'MjgsMC40MjMsMC4xODgsMC42NDMsMC4xODhjMC4zOTUsMCwwLjc4MS0wLjE5NSwxLjAwOS0wLjU1MyYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuMzU2LTAuNTU3LDAuMTkzLTEuMjk2LTAuMzYzLTEuNjUxbC0wLjAwMS0wLjAwMWMtMC40OS0wLjMxMi0wLjg0OC0wLjY1NS0xLjA2NS0wLjk3N2MtMC4yMTgtMC4zMjQtMC4zMDQtMC42MDgtMC4zMDYtMC44OTYmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjAwMi0wLjMxLDAuMTAyLTAuNjE3LDAuMzU4LTAuOTcxYzAuMzgxLTAuNTI1LDEuMTUtMS4wOTIsMi4yLTEuNDk1YzEuMDQ4LTAuNDA2LDIuMzYxLTAuNjU4LDMuNzgzLTAuNjU3JiN4ZDsmI3hhOyYjeD'+\n\t\t\t'k7JiN4OTtjMS44OTUtMC4wMDMsMy41OTksMC40NTEsNC43MzQsMS4xMDdjMC41NjksMC4zMjUsMC45OTIsMC42OTYsMS4yNDgsMS4wNDVjMC4yNTgsMC4zNTQsMC4zNTYsMC42NjEsMC4zNTgsMC45NzEmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjAwNSwwLjUwMy0wLjMwNSwxLjEwNS0xLjEzNSwxLjcxMmMtMC41MzYsMC4zODctMC42NTYsMS4xMzUtMC4yNzEsMS42NzFjMC4zODcsMC41MzUsMS4xMzUsMC42NTYsMS42NzEsMC4yNzEmI3hkOyYjeGE7JiN4OTsmI3g5O2MxLjIxMi0wLjg2NywyLjEyMy0yLjEzLDIuMTI3LTMuNjUzQzI0LjczNSwxNC45LDI0LjQxMiwxNC4wNzIsMjMuOTA3LDEzLjM5'+\n\t\t\t'MnogTTE5LjM2NCwxNi4xODJjLTAuNDY4LTAuNDY3LTEuMjI2LTAuNDY3LTEuNjkyLDAmI3hkOyYjeGE7JiN4OTsmI3g5O2wtMS41NTcsMS41NThsLTEuNTU4LTEuNTU4Yy0wLjQ2Ny0wLjQ2Ny0xLjIyNC0wLjQ2Ny0xLjY5MSwwYy0wLjQ2NywwLjQ2Ny0wLjQ2NywxLjIyNSwwLDEuNjkybDEuNTU3LDEuNTU3bC0xLjU1NywxLjU1NyYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjQ2NywwLjQ2OC0wLjQ2NywxLjIyNiwwLDEuNjkyYzAuMjMzLDAuMjMzLDAuNTQsMC4zNTEsMC44NDYsMC4zNTFjMC4zMDcsMCwwLjYxMi0wLjExNywwLjg0Ni0wLjM1MWwxLjU1OC0xLjU1OGwxLjU1NywxLjU1OCYjeGQ7Ji'+\n\t\t\t'N4YTsmI3g5OyYjeDk7YzAuMjMzLDAuMjMzLDAuNTQsMC4zNTEsMC44NDYsMC4zNTFjMC4zMDcsMCwwLjYxMi0wLjExNywwLjg0Ny0wLjM1MWMwLjQ2Ny0wLjQ2NywwLjQ2Ny0xLjIyNSwwLTEuNjkybC0xLjU1OC0xLjU1N2wxLjU1OC0xLjU1NyYjeGQ7JiN4YTsmI3g5OyYjeDk7QzE5LjgzMSwxNy40MDYsMTkuODMxLDE2LjY0OCwxOS4zNjQsMTYuMTgyeiIvPgogPC9nPgogPGcgc3Ryb2tlPSIjMDAwMDAwIiBmaWxsPSIjRkZGRkZGIiBzdHJva2Utd2lkdGg9IjAuMiIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC0xNiwtMTYpIj4KICA8cGF0aCBkPSJN'+\n\t\t\t'MTYsMy41QzkuMDk2LDMuNSwzLjUsOS4wOTYsMy41LDE2YzAsNi45MDQsNS41OTYsMTIuNSwxMi41LDEyLjVjNi45MDMsMCwxMi40OTktNS41OTYsMTIuNS0xMi41JiN4ZDsmI3hhOyYjeDk7JiN4OTtDMjguNDk4LDkuMDk2LDIyLjkwMywzLjUsMTYsMy41eiBNMjMuMTQ2LDIzLjE0N2MtMS44MzMsMS44MzEtNC4zNTIsMi45NTktNy4xNDYsMi45NjFjLTIuNzk2LTAuMDAyLTUuMzE1LTEuMTMtNy4xNDctMi45NjEmI3hkOyYjeGE7JiN4OTsmI3g5O0M3LjAyMSwyMS4zMTQsNS44OTMsMTguNzk1LDUuODkyLDE2YzAuMDAxLTIuNzk1LDEuMTMtNS4zMTQsMi45NjEtNy4xNDdjMS44MzMtMS44MzEsNC'+\n\t\t\t'4zNTItMi45NTksNy4xNDctMi45NiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzIuNzk1LDAuMDAxLDUuMzEzLDEuMTMsNy4xNDYsMi45NmMxLjgzMSwxLjgzMywyLjk2LDQuMzUyLDIuOTYsNy4xNDdTMjQuOTc4LDIxLjMxNCwyMy4xNDYsMjMuMTQ3eiBNMjMuOTA3LDEzLjM5MiYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjc2My0xLjAyNC0xLjkwNi0xLjc3Ni0zLjI2Mi0yLjMwNUMxOS4yODcsMTAuNTYyLDE3LjcsMTAuMjcsMTYsMTAuMjY5Yy0yLjI2OCwwLjAwMy00LjMzMywwLjUxNi01LjkyNSwxLjQyNCYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjc5NSwwLjQ1Ni0xLjQ3NywxLjAxNi0xLjk4MywxLjdj'+\n\t\t\t'LTAuNTA1LDAuNjgtMC44MjgsMS41MDgtMC44MjYsMi4zOTJjLTAuMDAyLDAuODE5LDAuMjc2LDEuNTk1LDAuNzIyLDIuMjQzJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC40NDUsMC42NTEsMS4wNDksMS4xOTQsMS43NTUsMS42NDZjMC4xOTksMC4xMjgsMC40MjMsMC4xODgsMC42NDMsMC4xODhjMC4zOTUsMCwwLjc4MS0wLjE5NSwxLjAwOS0wLjU1MyYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuMzU2LTAuNTU3LDAuMTkzLTEuMjk2LTAuMzYzLTEuNjUxbC0wLjAwMS0wLjAwMWMtMC40OS0wLjMxMi0wLjg0OC0wLjY1NS0xLjA2NS0wLjk3N2MtMC4yMTgtMC4zMjQtMC4zMDQtMC42MDgtMC4zMDYtMC44OT'+\n\t\t\t'YmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjAwMi0wLjMxLDAuMTAyLTAuNjE3LDAuMzU4LTAuOTcxYzAuMzgxLTAuNTI1LDEuMTUtMS4wOTIsMi4yLTEuNDk1YzEuMDQ4LTAuNDA2LDIuMzYxLTAuNjU4LDMuNzgzLTAuNjU3JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMS44OTUtMC4wMDMsMy41OTksMC40NTEsNC43MzQsMS4xMDdjMC41NjksMC4zMjUsMC45OTIsMC42OTYsMS4yNDgsMS4wNDVjMC4yNTgsMC4zNTQsMC4zNTYsMC42NjEsMC4zNTgsMC45NzEmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjAwNSwwLjUwMy0wLjMwNSwxLjEwNS0xLjEzNSwxLjcxMmMtMC41MzYsMC4zODctMC42NTYsMS4xMzUtMC4y'+\n\t\t\t'NzEsMS42NzFjMC4zODcsMC41MzUsMS4xMzUsMC42NTYsMS42NzEsMC4yNzEmI3hkOyYjeGE7JiN4OTsmI3g5O2MxLjIxMi0wLjg2NywyLjEyMy0yLjEzLDIuMTI3LTMuNjUzQzI0LjczNSwxNC45LDI0LjQxMiwxNC4wNzIsMjMuOTA3LDEzLjM5MnogTTE5LjM2NCwxNi4xODJjLTAuNDY4LTAuNDY3LTEuMjI2LTAuNDY3LTEuNjkyLDAmI3hkOyYjeGE7JiN4OTsmI3g5O2wtMS41NTcsMS41NThsLTEuNTU4LTEuNTU4Yy0wLjQ2Ny0wLjQ2Ny0xLjIyNC0wLjQ2Ny0xLjY5MSwwYy0wLjQ2NywwLjQ2Ny0wLjQ2NywxLjIyNSwwLDEuNjkybDEuNTU3LDEuNTU3bC0xLjU1NywxLjU1NyYjeGQ7JiN4YTsmI3'+\n\t\t\t'g5OyYjeDk7Yy0wLjQ2NywwLjQ2OC0wLjQ2NywxLjIyNiwwLDEuNjkyYzAuMjMzLDAuMjMzLDAuNTQsMC4zNTEsMC44NDYsMC4zNTFjMC4zMDcsMCwwLjYxMi0wLjExNywwLjg0Ni0wLjM1MWwxLjU1OC0xLjU1OGwxLjU1NywxLjU1OCYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuMjMzLDAuMjMzLDAuNTQsMC4zNTEsMC44NDYsMC4zNTFjMC4zMDcsMCwwLjYxMi0wLjExNywwLjg0Ny0wLjM1MWMwLjQ2Ny0wLjQ2NywwLjQ2Ny0xLjIyNSwwLTEuNjkybC0xLjU1OC0xLjU1N2wxLjU1OC0xLjU1NyYjeGQ7JiN4YTsmI3g5OyYjeDk7QzE5LjgzMSwxNy40MDYsMTkuODMxLDE2LjY0OCwxOS4zNjQsMTYuMTgy'+\n\t\t\t'eiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._stop_rotate_image__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"stop_rotate_image\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._stop_rotate_image.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._stop_rotate_image.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getIsAutorotating() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._stop_rotate_image.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._stop_rotate_image.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._stop_rotate_image.style[domTransition]='';\n\t\t\t\tif (me._stop_rotate_image.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._stop_rotate_image.style.visibility=(Number(me._stop_rotate_image.style.opacity)>0||!me._stop_rotate_image.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._stop_rotate_image.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._stop_rotate_image.style.visibility=\"hidden\";\n\t\t\t\t\tme._stop_rotate_image.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._stop_rotate_image.onmouseover=function (e) {\n\t\t\tme._stop_rotate_image__img.style.visibility='hidden';\n\t\t\tme._stop_rotate_image__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._stop_rotate_image.onmouseout=function (e) {\n\t\t\tme._stop_rotate_image__img.style.visibility='inherit';\n\t\t\tme._stop_rotate_image__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._stop_rotate_image.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._button_auto_rotate.appendChild(me._stop_rotate_image);\n\t\tel=me._start_rotate_image=document.createElement('div');\n\t\tels=me._start_rotate_image__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSI+CiAgPGc+CiAgIDxwYXRoIGQ9Ik0zLjUsMTZjMC02LjkwNCw1LjU5Ni0xMi41LDEyLjUtMTIuNWwwLDBjNi45MDQsMCwxMi40OTksNS41OTYsMTIuNSwxMi41bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTsmI3g5O2MtMC4wMDEsNi45MDQtNS41OTYsMTIuNDk5LTEyLjUsMTIuNWwwLDBDOS4wOTYsMjguNDk5LDMuNSwyMi45MDQsMy41LDE2TDMuNSwxNnogTTguODUz'+\n\t\t\t'LDguODU0JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5OyYjeDk7Yy0xLjgzMSwxLjgzMy0yLjk2LDQuMzUyLTIuOTYsNy4xNDdsMCwwYzAsMi43OTQsMS4xMjksNS4zMTQsMi45Niw3LjE0N2wwLDBjMS44MzIsMS44Myw0LjM1MiwyLjk2LDcuMTQ3LDIuOTZsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5OyYjeDk7YzIuNzk1LDAsNS4zMTQtMS4xMyw3LjE0Ny0yLjk2bDAsMGMxLjgzMS0xLjgzMywyLjk1OS00LjM1MywyLjk2LTcuMTQ3bDAsMGMtMC4wMDEtMi43OTUtMS4xMjktNS4zMTQtMi45Ni03LjE0N2wwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7JiN4OTtjLTEuODMzLTEuODMyLTQuMz'+\n\t\t\t'UzLTIuOTYtNy4xNDctMi45NmwwLDBDMTMuMjA1LDUuODk0LDEwLjY4Niw3LjAyMiw4Ljg1Myw4Ljg1NEw4Ljg1Myw4Ljg1NHoiLz4KICA8L2c+CiAgPHBhdGggZD0iTTE4LjA3LDIwLjAwMWMtMC4xNzQtMC42MzgsMC4yMDMtMS4yOTUsMC44NDEtMS40NjlsMCwwYzEuMTM0LTAuMzA2LDIuMDU1LTAuNzg5LDIuNjMzLTEuMzA1bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC41ODQtMC41MjYsMC43OTctMS4wMDgsMC43OTgtMS40NDRsMCwwYy0wLjAwMi0wLjMxLTAuMTAyLTAuNjE3LTAuMzU5LTAuOTdsMCwwYy0wLjI1Ni0wLjM1LTAuNjc4LTAuNzIxLTEuMjQ3LTEuMDQ1bDAsMCYjeGQ7'+\n\t\t\t'JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTEuMTM3LTAuNjU2LTIuODQtMS4xMS00LjczNS0xLjEwNmwwLDBjLTEuNDIyLTAuMDAxLTIuNzM1LDAuMjUtMy43ODMsMC42NTdsMCwwYy0xLjA1MSwwLjQwMi0xLjgxOSwwLjk2OS0yLjIwMSwxLjQ5NWwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0wLjI1NywwLjM1NC0wLjM1NiwwLjY2MS0wLjM1OCwwLjk3bDAsMGMwLjAwMSwwLjI4OCwwLjA4NywwLjU3MSwwLjMwNiwwLjg5NWwwLDBjMC4yMTcsMC4zMjEsMC41NzUsMC42NjYsMS4wNjUsMC45NzhsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2gwLjAwMWMwLjU1NywwLjM1NiwwLjcyLDEuMD'+\n\t\t\t'k2LDAuMzY0LDEuNjUybDAsMGMtMC4zNTUsMC41NTctMS4wOTUsMC43Mi0xLjY1MiwwLjM2NGwwLDBjLTAuNzA2LTAuNDUxLTEuMzEtMC45OTQtMS43NTUtMS42NDZsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MtMC40NDQtMC42NDctMC43MjMtMS40MjMtMC43MjItMi4yNDNsMCwwYy0wLjAwMS0wLjg4MywwLjMyMS0xLjcxMiwwLjgyNy0yLjM5MmwwLDBjMC41MDctMC42ODQsMS4xODgtMS4yNDQsMS45ODMtMS43bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMS41OTItMC45MDcsMy42NTctMS40MTksNS45MjUtMS40MjNsMCwwYzEuNywwLDMuMjg4LDAuMjkzLDQuNjQ2LDAuODE4'+\n\t\t\t'bDAsMGMxLjM1NSwwLjUyOSwyLjQ5OCwxLjI4MSwzLjI2MSwyLjMwNWwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuNTA2LDAuNjgsMC44MjksMS41MDgsMC44MjYsMi4zOTJsMCwwYzAuMDAxLDEuMjg4LTAuNjY4LDIuNDEzLTEuNjAyLDMuMjMzbDAsMGMtMC45NDIsMC44MzItMi4xNzgsMS40MzgtMy41OTQsMS44MjVsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MtMC4xMDQsMC4wMjgtMC4yMTEsMC4wNDItMC4zMTQsMC4wNDJsMCwwQzE4LjY5NiwyMC44ODQsMTguMjE0LDIwLjUzMywxOC4wNywyMC4wMDFMMTguMDcsMjAuMDAxeiIvPgogIDxwYXRoIGQ9Ik0xNi4zOTYsMjMuNj'+\n\t\t\t'IxbC0zLjM3My0zLjAzOWMtMC4yNTEtMC4yMjYtMC4zOTYtMC41NTEtMC4zOTYtMC44ODlsMCwwYzAtMC4zMzcsMC4xNDYtMC42NjMsMC4zOTYtMC44ODkmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7bDAsMGwzLjM3NC0zLjAzOWMwLjQ5MS0wLjQ0MiwxLjI0Ny0wLjQwMywxLjY4OSwwLjA4OGwwLDBjMC40NDIsMC40OTEsMC40MDIsMS4yNDctMC4wODgsMS42ODlsMCwwbC0yLjM4NiwyLjE1bDIuMzg2LDIuMTQ5JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjQ5LDAuNDQyLDAuNTMsMS4xOTksMC4wODgsMS42OWwwLDBjLTAuMjM2LDAuMjYyLTAuNTYyLDAuMzk1LTAuODksMC4zOTVsMCwwQzE2'+\n\t\t\t'LjkxMiwyMy45MjgsMTYuNjI1LDIzLjgyNiwxNi4zOTYsMjMuNjIxJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0wxNi4zOTYsMjMuNjIxeiIvPgogPC9nPgogPGcgc3Ryb2tlPSIjMDAwMDAwIiBmaWxsPSIjRkZGRkZGIiBzdHJva2Utd2lkdGg9IjAuMiI+CiAgPGc+CiAgIDxwYXRoIGQ9Ik0zLjUsMTZjMC02LjkwNCw1LjU5Ni0xMi41LDEyLjUtMTIuNWwwLDBjNi45MDQsMCwxMi40OTksNS41OTYsMTIuNSwxMi41bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTsmI3g5O2MtMC4wMDEsNi45MDQtNS41OTYsMTIuNDk5LTEyLjUsMTIuNWwwLDBDOS4wOTYsMjguNDk5LDMuNSwyMi45MDQsMy41LD'+\n\t\t\t'E2TDMuNSwxNnogTTguODUzLDguODU0JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5OyYjeDk7Yy0xLjgzMSwxLjgzMy0yLjk2LDQuMzUyLTIuOTYsNy4xNDdsMCwwYzAsMi43OTQsMS4xMjksNS4zMTQsMi45Niw3LjE0N2wwLDBjMS44MzIsMS44Myw0LjM1MiwyLjk2LDcuMTQ3LDIuOTZsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5OyYjeDk7YzIuNzk1LDAsNS4zMTQtMS4xMyw3LjE0Ny0yLjk2bDAsMGMxLjgzMS0xLjgzMywyLjk1OS00LjM1MywyLjk2LTcuMTQ3bDAsMGMtMC4wMDEtMi43OTUtMS4xMjktNS4zMTQtMi45Ni03LjE0N2wwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7JiN4OTtj'+\n\t\t\t'LTEuODMzLTEuODMyLTQuMzUzLTIuOTYtNy4xNDctMi45NmwwLDBDMTMuMjA1LDUuODk0LDEwLjY4Niw3LjAyMiw4Ljg1Myw4Ljg1NEw4Ljg1Myw4Ljg1NHoiLz4KICA8L2c+CiAgPHBhdGggZD0iTTE4LjA3LDIwLjAwMWMtMC4xNzQtMC42MzgsMC4yMDMtMS4yOTUsMC44NDEtMS40NjlsMCwwYzEuMTM0LTAuMzA2LDIuMDU1LTAuNzg5LDIuNjMzLTEuMzA1bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC41ODQtMC41MjYsMC43OTctMS4wMDgsMC43OTgtMS40NDRsMCwwYy0wLjAwMi0wLjMxLTAuMTAyLTAuNjE3LTAuMzU5LTAuOTdsMCwwYy0wLjI1Ni0wLjM1LTAuNjc4LTAuNzIxLTEuMj'+\n\t\t\t'Q3LTEuMDQ1bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTEuMTM3LTAuNjU2LTIuODQtMS4xMS00LjczNS0xLjEwNmwwLDBjLTEuNDIyLTAuMDAxLTIuNzM1LDAuMjUtMy43ODMsMC42NTdsMCwwYy0xLjA1MSwwLjQwMi0xLjgxOSwwLjk2OS0yLjIwMSwxLjQ5NWwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0wLjI1NywwLjM1NC0wLjM1NiwwLjY2MS0wLjM1OCwwLjk3bDAsMGMwLjAwMSwwLjI4OCwwLjA4NywwLjU3MSwwLjMwNiwwLjg5NWwwLDBjMC4yMTcsMC4zMjEsMC41NzUsMC42NjYsMS4wNjUsMC45NzhsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2gwLjAwMWMwLjU1'+\n\t\t\t'NywwLjM1NiwwLjcyLDEuMDk2LDAuMzY0LDEuNjUybDAsMGMtMC4zNTUsMC41NTctMS4wOTUsMC43Mi0xLjY1MiwwLjM2NGwwLDBjLTAuNzA2LTAuNDUxLTEuMzEtMC45OTQtMS43NTUtMS42NDZsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MtMC40NDQtMC42NDctMC43MjMtMS40MjMtMC43MjItMi4yNDNsMCwwYy0wLjAwMS0wLjg4MywwLjMyMS0xLjcxMiwwLjgyNy0yLjM5MmwwLDBjMC41MDctMC42ODQsMS4xODgtMS4yNDQsMS45ODMtMS43bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMS41OTItMC45MDcsMy42NTctMS40MTksNS45MjUtMS40MjNsMCwwYzEuNywwLDMuMjg4LD'+\n\t\t\t'AuMjkzLDQuNjQ2LDAuODE4bDAsMGMxLjM1NSwwLjUyOSwyLjQ5OCwxLjI4MSwzLjI2MSwyLjMwNWwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuNTA2LDAuNjgsMC44MjksMS41MDgsMC44MjYsMi4zOTJsMCwwYzAuMDAxLDEuMjg4LTAuNjY4LDIuNDEzLTEuNjAyLDMuMjMzbDAsMGMtMC45NDIsMC44MzItMi4xNzgsMS40MzgtMy41OTQsMS44MjVsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MtMC4xMDQsMC4wMjgtMC4yMTEsMC4wNDItMC4zMTQsMC4wNDJsMCwwQzE4LjY5NiwyMC44ODQsMTguMjE0LDIwLjUzMywxOC4wNywyMC4wMDFMMTguMDcsMjAuMDAxeiIvPgogIDxwYXRo'+\n\t\t\t'IGQ9Ik0xNi4zOTYsMjMuNjIxbC0zLjM3My0zLjAzOWMtMC4yNTEtMC4yMjYtMC4zOTYtMC41NTEtMC4zOTYtMC44ODlsMCwwYzAtMC4zMzcsMC4xNDYtMC42NjMsMC4zOTYtMC44ODkmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7bDAsMGwzLjM3NC0zLjAzOWMwLjQ5MS0wLjQ0MiwxLjI0Ny0wLjQwMywxLjY4OSwwLjA4OGwwLDBjMC40NDIsMC40OTEsMC40MDIsMS4yNDctMC4wODgsMS42ODlsMCwwbC0yLjM4NiwyLjE1bDIuMzg2LDIuMTQ5JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjQ5LDAuNDQyLDAuNTMsMS4xOTksMC4wODgsMS42OWwwLDBjLTAuMjM2LDAuMjYyLTAuNTYyLDAuMzk1LT'+\n\t\t\t'AuODksMC4zOTVsMCwwQzE2LjkxMiwyMy45MjgsMTYuNjI1LDIzLjgyNiwxNi4zOTYsMjMuNjIxJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0wxNi4zOTYsMjMuNjIxeiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._start_rotate_image__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._start_rotate_image__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC0xNiwtMTYpIj4KICA8Zz4KICAgPHBhdGggZD0iTTMuNSwxNmMwLTYuOTA0LDUuNTk2LTEyLjUsMTIuNS0xMi41bDAsMGM2LjkwNCwwLDEyLjQ5OSw1LjU5NiwxMi41LDEyLjVsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5OyYjeDk7Yy0wLjAwMSw2LjkwNC01LjU5NiwxMi40OTkt'+\n\t\t\t'MTIuNSwxMi41bDAsMEM5LjA5NiwyOC40OTksMy41LDIyLjkwNCwzLjUsMTZMMy41LDE2eiBNOC44NTMsOC44NTQmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7JiN4OTtjLTEuODMxLDEuODMzLTIuOTYsNC4zNTItMi45Niw3LjE0N2wwLDBjMCwyLjc5NCwxLjEyOSw1LjMxNCwyLjk2LDcuMTQ3bDAsMGMxLjgzMiwxLjgzLDQuMzUyLDIuOTYsNy4xNDcsMi45NmwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7JiN4OTtjMi43OTUsMCw1LjMxNC0xLjEzLDcuMTQ3LTIuOTZsMCwwYzEuODMxLTEuODMzLDIuOTU5LTQuMzUzLDIuOTYtNy4xNDdsMCwwYy0wLjAwMS0yLjc5NS0xLjEyOS01LjMxNC0yLj'+\n\t\t\t'k2LTcuMTQ3bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTsmI3g5O2MtMS44MzMtMS44MzItNC4zNTMtMi45Ni03LjE0Ny0yLjk2bDAsMEMxMy4yMDUsNS44OTQsMTAuNjg2LDcuMDIyLDguODUzLDguODU0TDguODUzLDguODU0eiIvPgogIDwvZz4KICA8cGF0aCBkPSJNMTguMDcsMjAuMDAxYy0wLjE3NC0wLjYzOCwwLjIwMy0xLjI5NSwwLjg0MS0xLjQ2OWwwLDBjMS4xMzQtMC4zMDYsMi4wNTUtMC43ODksMi42MzMtMS4zMDVsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjU4NC0wLjUyNiwwLjc5Ny0xLjAwOCwwLjc5OC0xLjQ0NGwwLDBjLTAuMDAyLTAuMzEtMC4xMDItMC42MTct'+\n\t\t\t'MC4zNTktMC45N2wwLDBjLTAuMjU2LTAuMzUtMC42NzgtMC43MjEtMS4yNDctMS4wNDVsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MtMS4xMzctMC42NTYtMi44NC0xLjExLTQuNzM1LTEuMTA2bDAsMGMtMS40MjItMC4wMDEtMi43MzUsMC4yNS0zLjc4MywwLjY1N2wwLDBjLTEuMDUxLDAuNDAyLTEuODE5LDAuOTY5LTIuMjAxLDEuNDk1bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTAuMjU3LDAuMzU0LTAuMzU2LDAuNjYxLTAuMzU4LDAuOTdsMCwwYzAuMDAxLDAuMjg4LDAuMDg3LDAuNTcxLDAuMzA2LDAuODk1bDAsMGMwLjIxNywwLjMyMSwwLjU3NSwwLjY2NiwxLjA2NSwwLj'+\n\t\t\t'k3OGwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7aDAuMDAxYzAuNTU3LDAuMzU2LDAuNzIsMS4wOTYsMC4zNjQsMS42NTJsMCwwYy0wLjM1NSwwLjU1Ny0xLjA5NSwwLjcyLTEuNjUyLDAuMzY0bDAsMGMtMC43MDYtMC40NTEtMS4zMS0wLjk5NC0xLjc1NS0xLjY0NmwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0wLjQ0NC0wLjY0Ny0wLjcyMy0xLjQyMy0wLjcyMi0yLjI0M2wwLDBjLTAuMDAxLTAuODgzLDAuMzIxLTEuNzEyLDAuODI3LTIuMzkybDAsMGMwLjUwNy0wLjY4NCwxLjE4OC0xLjI0NCwxLjk4My0xLjdsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MxLjU5Mi0wLjkw'+\n\t\t\t'NywzLjY1Ny0xLjQxOSw1LjkyNS0xLjQyM2wwLDBjMS43LDAsMy4yODgsMC4yOTMsNC42NDYsMC44MThsMCwwYzEuMzU1LDAuNTI5LDIuNDk4LDEuMjgxLDMuMjYxLDIuMzA1bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC41MDYsMC42OCwwLjgyOSwxLjUwOCwwLjgyNiwyLjM5MmwwLDBjMC4wMDEsMS4yODgtMC42NjgsMi40MTMtMS42MDIsMy4yMzNsMCwwYy0wLjk0MiwwLjgzMi0yLjE3OCwxLjQzOC0zLjU5NCwxLjgyNWwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0wLjEwNCwwLjAyOC0wLjIxMSwwLjA0Mi0wLjMxNCwwLjA0MmwwLDBDMTguNjk2LDIwLjg4NCwxOC4yMTQsMj'+\n\t\t\t'AuNTMzLDE4LjA3LDIwLjAwMUwxOC4wNywyMC4wMDF6Ii8+CiAgPHBhdGggZD0iTTE2LjM5NiwyMy42MjFsLTMuMzczLTMuMDM5Yy0wLjI1MS0wLjIyNi0wLjM5Ni0wLjU1MS0wLjM5Ni0wLjg4OWwwLDBjMC0wLjMzNywwLjE0Ni0wLjY2MywwLjM5Ni0wLjg4OSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtsMCwwbDMuMzc0LTMuMDM5YzAuNDkxLTAuNDQyLDEuMjQ3LTAuNDAzLDEuNjg5LDAuMDg4bDAsMGMwLjQ0MiwwLjQ5MSwwLjQwMiwxLjI0Ny0wLjA4OCwxLjY4OWwwLDBsLTIuMzg2LDIuMTVsMi4zODYsMi4xNDkmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuNDksMC40NDIsMC41MywxLjE5'+\n\t\t\t'OSwwLjA4OCwxLjY5bDAsMGMtMC4yMzYsMC4yNjItMC41NjIsMC4zOTUtMC44OSwwLjM5NWwwLDBDMTYuOTEyLDIzLjkyOCwxNi42MjUsMjMuODI2LDE2LjM5NiwyMy42MjEmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7TDE2LjM5NiwyMy42MjF6Ii8+CiA8L2c+CiA8ZyBzdHJva2U9IiMwMDAwMDAiIGZpbGw9IiNGRkZGRkYiIHN0cm9rZS13aWR0aD0iMC4yIiB0cmFuc2Zvcm09InRyYW5zbGF0ZSgxNiwxNikgc2NhbGUoMS4xKSB0cmFuc2xhdGUoLTE2LC0xNikiPgogIDxnPgogICA8cGF0aCBkPSJNMy41LDE2YzAtNi45MDQsNS41OTYtMTIuNSwxMi41LTEyLjVsMCwwYzYuOTA0LDAsMTIuNDk5LD'+\n\t\t\t'UuNTk2LDEyLjUsMTIuNWwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7JiN4OTtjLTAuMDAxLDYuOTA0LTUuNTk2LDEyLjQ5OS0xMi41LDEyLjVsMCwwQzkuMDk2LDI4LjQ5OSwzLjUsMjIuOTA0LDMuNSwxNkwzLjUsMTZ6IE04Ljg1Myw4Ljg1NCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTsmI3g5O2MtMS44MzEsMS44MzMtMi45Niw0LjM1Mi0yLjk2LDcuMTQ3bDAsMGMwLDIuNzk0LDEuMTI5LDUuMzE0LDIuOTYsNy4xNDdsMCwwYzEuODMyLDEuODMsNC4zNTIsMi45Niw3LjE0NywyLjk2bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTsmI3g5O2MyLjc5NSwwLDUuMzE0LTEuMTMsNy4xNDct'+\n\t\t\t'Mi45NmwwLDBjMS44MzEtMS44MzMsMi45NTktNC4zNTMsMi45Ni03LjE0N2wwLDBjLTAuMDAxLTIuNzk1LTEuMTI5LTUuMzE0LTIuOTYtNy4xNDdsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5OyYjeDk7Yy0xLjgzMy0xLjgzMi00LjM1My0yLjk2LTcuMTQ3LTIuOTZsMCwwQzEzLjIwNSw1Ljg5NCwxMC42ODYsNy4wMjIsOC44NTMsOC44NTRMOC44NTMsOC44NTR6Ii8+CiAgPC9nPgogIDxwYXRoIGQ9Ik0xOC4wNywyMC4wMDFjLTAuMTc0LTAuNjM4LDAuMjAzLTEuMjk1LDAuODQxLTEuNDY5bDAsMGMxLjEzNC0wLjMwNiwyLjA1NS0wLjc4OSwyLjYzMy0xLjMwNWwwLDAmI3hkOyYjeGE7JiN4OT'+\n\t\t\t'smI3g5OyYjeDk7YzAuNTg0LTAuNTI2LDAuNzk3LTEuMDA4LDAuNzk4LTEuNDQ0bDAsMGMtMC4wMDItMC4zMS0wLjEwMi0wLjYxNy0wLjM1OS0wLjk3bDAsMGMtMC4yNTYtMC4zNS0wLjY3OC0wLjcyMS0xLjI0Ny0xLjA0NWwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0xLjEzNy0wLjY1Ni0yLjg0LTEuMTEtNC43MzUtMS4xMDZsMCwwYy0xLjQyMi0wLjAwMS0yLjczNSwwLjI1LTMuNzgzLDAuNjU3bDAsMGMtMS4wNTEsMC40MDItMS44MTksMC45NjktMi4yMDEsMS40OTVsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MtMC4yNTcsMC4zNTQtMC4zNTYsMC42NjEtMC4zNTgsMC45N2ww'+\n\t\t\t'LDBjMC4wMDEsMC4yODgsMC4wODcsMC41NzEsMC4zMDYsMC44OTVsMCwwYzAuMjE3LDAuMzIxLDAuNTc1LDAuNjY2LDEuMDY1LDAuOTc4bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtoMC4wMDFjMC41NTcsMC4zNTYsMC43MiwxLjA5NiwwLjM2NCwxLjY1MmwwLDBjLTAuMzU1LDAuNTU3LTEuMDk1LDAuNzItMS42NTIsMC4zNjRsMCwwYy0wLjcwNi0wLjQ1MS0xLjMxLTAuOTk0LTEuNzU1LTEuNjQ2bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTAuNDQ0LTAuNjQ3LTAuNzIzLTEuNDIzLTAuNzIyLTIuMjQzbDAsMGMtMC4wMDEtMC44ODMsMC4zMjEtMS43MTIsMC44MjctMi4zOTJsMC'+\n\t\t\t'wwYzAuNTA3LTAuNjg0LDEuMTg4LTEuMjQ0LDEuOTgzLTEuN2wwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzEuNTkyLTAuOTA3LDMuNjU3LTEuNDE5LDUuOTI1LTEuNDIzbDAsMGMxLjcsMCwzLjI4OCwwLjI5Myw0LjY0NiwwLjgxOGwwLDBjMS4zNTUsMC41MjksMi40OTgsMS4yODEsMy4yNjEsMi4zMDVsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjUwNiwwLjY4LDAuODI5LDEuNTA4LDAuODI2LDIuMzkybDAsMGMwLjAwMSwxLjI4OC0wLjY2OCwyLjQxMy0xLjYwMiwzLjIzM2wwLDBjLTAuOTQyLDAuODMyLTIuMTc4LDEuNDM4LTMuNTk0LDEuODI1bDAsMCYjeGQ7JiN4YTsmI3g5'+\n\t\t\t'OyYjeDk7JiN4OTtjLTAuMTA0LDAuMDI4LTAuMjExLDAuMDQyLTAuMzE0LDAuMDQybDAsMEMxOC42OTYsMjAuODg0LDE4LjIxNCwyMC41MzMsMTguMDcsMjAuMDAxTDE4LjA3LDIwLjAwMXoiLz4KICA8cGF0aCBkPSJNMTYuMzk2LDIzLjYyMWwtMy4zNzMtMy4wMzljLTAuMjUxLTAuMjI2LTAuMzk2LTAuNTUxLTAuMzk2LTAuODg5bDAsMGMwLTAuMzM3LDAuMTQ2LTAuNjYzLDAuMzk2LTAuODg5JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2wwLDBsMy4zNzQtMy4wMzljMC40OTEtMC40NDIsMS4yNDctMC40MDMsMS42ODksMC4wODhsMCwwYzAuNDQyLDAuNDkxLDAuNDAyLDEuMjQ3LTAuMDg4LDEuNj'+\n\t\t\t'g5bDAsMGwtMi4zODYsMi4xNWwyLjM4NiwyLjE0OSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC40OSwwLjQ0MiwwLjUzLDEuMTk5LDAuMDg4LDEuNjlsMCwwYy0wLjIzNiwwLjI2Mi0wLjU2MiwwLjM5NS0wLjg5LDAuMzk1bDAsMEMxNi45MTIsMjMuOTI4LDE2LjYyNSwyMy44MjYsMTYuMzk2LDIzLjYyMSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtMMTYuMzk2LDIzLjYyMXoiLz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._start_rotate_image__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"start_rotate_image\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._start_rotate_image.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._start_rotate_image.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getIsAutorotating() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._start_rotate_image.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._start_rotate_image.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._start_rotate_image.style[domTransition]='';\n\t\t\t\tif (me._start_rotate_image.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._start_rotate_image.style.visibility=\"hidden\";\n\t\t\t\t\tme._start_rotate_image.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._start_rotate_image.style.visibility=(Number(me._start_rotate_image.style.opacity)>0||!me._start_rotate_image.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._start_rotate_image.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._start_rotate_image.onmouseover=function (e) {\n\t\t\tme._start_rotate_image__img.style.visibility='hidden';\n\t\t\tme._start_rotate_image__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._start_rotate_image.onmouseout=function (e) {\n\t\t\tme._start_rotate_image__img.style.visibility='inherit';\n\t\t\tme._start_rotate_image__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._start_rotate_image.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._button_auto_rotate.appendChild(me._start_rotate_image);\n\t\tel=me._tt_rotate_start=document.createElement('div');\n\t\tels=me._tt_rotate_start__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"tt_rotate_start\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 32px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 100px;';\n\t\ths+='pointer-events:auto;';\n\t\ths+='text-shadow: 1px 1px 4px #000000;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: auto;';\n\t\ths+='height: auto;';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: nowrap;';\n\t\ths+='padding: 0px 1px 0px 1px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=\"\";\n\t\tel.appendChild(els);\n\t\tme._tt_rotate_start.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._tt_rotate_start.logicBlock_position = function() {\n\t\t\tvar newLogicStatePosition;\n\t\t\tif (\n\t\t\t\t((player.getHasTouch() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStatePosition = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStatePosition = -1;\n\t\t\t}\n\t\t\tif (me._tt_rotate_start.ggCurrentLogicStatePosition != newLogicStatePosition) {\n\t\t\t\tme._tt_rotate_start.ggCurrentLogicStatePosition = newLogicStatePosition;\n\t\t\t\tme._tt_rotate_start.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_rotate_start.ggCurrentLogicStatePosition == 0) {\n\t\t\t\t\tthis.ggDx = 0;\n\t\t\t\t\tme._tt_rotate_start.style.top='-25px';\n\t\t\t\t\tme._tt_rotate_start.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_rotate_start.ggDx=0;\n\t\t\t\t\tme._tt_rotate_start.style.top='32px';\n\t\t\t\t\tme._tt_rotate_start.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_rotate_start.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['button_auto_rotate'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._tt_rotate_start.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._tt_rotate_start.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._tt_rotate_start.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_rotate_start.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._tt_rotate_start.style.visibility=(Number(me._tt_rotate_start.style.opacity)>0||!me._tt_rotate_start.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._tt_rotate_start.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_rotate_start.style.visibility=\"hidden\";\n\t\t\t\t\tme._tt_rotate_start.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_rotate_start.logicBlock_text = function() {\n\t\t\tvar newLogicStateText;\n\t\t\tif (\n\t\t\t\t((player.getIsAutorotating() == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateText = 0;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((player.getIsAutorotating() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateText = 1;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateText = -1;\n\t\t\t}\n\t\t\tif (me._tt_rotate_start.ggCurrentLogicStateText != newLogicStateText) {\n\t\t\t\tme._tt_rotate_start.ggCurrentLogicStateText = newLogicStateText;\n\t\t\t\tme._tt_rotate_start.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_rotate_start.ggCurrentLogicStateText == 0) {\n\t\t\t\t\tme._tt_rotate_start.ggText=\"Start Auto Rotate\";\n\t\t\t\t\tme._tt_rotate_start__text.innerHTML=me._tt_rotate_start.ggText;\n\t\t\t\t\tif (me._tt_rotate_start.ggUpdateText) {\n\t\t\t\t\tme._tt_rotate_start.ggUpdateText=function() {\n\t\t\t\t\t\tvar hs=\"Start Auto Rotate\";\n\t\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (me._tt_rotate_start.ggUpdatePosition) me._tt_rotate_start.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse if (me._tt_rotate_start.ggCurrentLogicStateText == 1) {\n\t\t\t\t\tme._tt_rotate_start.ggText=\"Stop Auto Rotate\";\n\t\t\t\t\tme._tt_rotate_start__text.innerHTML=me._tt_rotate_start.ggText;\n\t\t\t\t\tif (me._tt_rotate_start.ggUpdateText) {\n\t\t\t\t\tme._tt_rotate_start.ggUpdateText=function() {\n\t\t\t\t\t\tvar hs=\"Stop Auto Rotate\";\n\t\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (me._tt_rotate_start.ggUpdatePosition) me._tt_rotate_start.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_rotate_start.ggText=\"\";\n\t\t\t\t\tme._tt_rotate_start__text.innerHTML=me._tt_rotate_start.ggText;\n\t\t\t\t\tif (me._tt_rotate_start.ggUpdateText) {\n\t\t\t\t\tme._tt_rotate_start.ggUpdateText=function() {\n\t\t\t\t\t\tvar hs=\"\";\n\t\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (me._tt_rotate_start.ggUpdatePosition) me._tt_rotate_start.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_rotate_start.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t\tthis.style[domTransition]='left 0';\n\t\t\tthis.ggTextDiv.style.left=((98-this.ggTextDiv.offsetWidth)/2) + 'px';\n\t\t}\n\t\tme._button_auto_rotate.appendChild(me._tt_rotate_start);\n\t\tme._container_1.appendChild(me._button_auto_rotate);\n\t\tel=me._button_direction=document.createElement('div');\n\t\tel.ggId=\"button_direction\";\n\t\tel.ggDx=-48;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='bottom : 5px;';\n\t\ths+='height : 62px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 82px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_direction.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_direction.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._button_image_right=document.createElement('div');\n\t\tels=me._button_image_right__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSI+CiAgPHBhdGggZD0iTTMuNSwxNkMzLjUwMSw5LjA5Niw5LjA5NiwzLjUwMSwxNiwzLjVsMCwwQzIyLjkwNCwzLjUwMSwyOC40OTksOS4wOTYsMjguNSwxNmwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0wLjAwMSw2LjkwNC01LjU5NiwxMi40OTktMTIuNSwxMi41bDAsMEM5LjA5NiwyOC40OTksMy41MDEsMjIuOTA0LDMuNSwxNkwzLjUsMTZ6IE04Ljg1Myw4Ljg1'+\n\t\t\t'MyYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtDNy4wMjIsMTAuNjg2LDUuODk0LDEzLjIwNSw1Ljg5MywxNmwwLDBjMCwyLjc5NSwxLjEyOSw1LjMxNCwyLjk2LDcuMTQ2bDAsMGMxLjgzMywxLjgzMSw0LjM1MywyLjk2LDcuMTQ3LDIuOTYxbDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMi43OTUtMC4wMDEsNS4zMTQtMS4xMyw3LjE0Ni0yLjk2MWwwLDBjMS44MzItMS44MzIsMi45NjEtNC4zNTIsMi45NjEtNy4xNDZsMCwwYzAtMi43OTUtMS4xMjktNS4zMTQtMi45NjEtNy4xNDdsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0MyMS4zMTQsNy4wMjIsMTguNzk1LDUuODk0LDE2LDUuOD'+\n\t\t\t'kzbDAsMEMxMy4yMDYsNS44OTQsMTAuNjg2LDcuMDIyLDguODUzLDguODUzTDguODUzLDguODUzeiIvPgogIDxwYXRoIGQ9Ik0xMi45MiwyMi42NTdjLTAuNDQyLTAuNDkxLTAuNDAzLTEuMjQ3LDAuMDg4LTEuNjg5bDAsMGw1LjQ4MS00LjkzOGwtNS40ODEtNC45Mzd2MCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTAuNDkxLTAuNDQyLTAuNTMtMS4xOTktMC4wODgtMS42OWwwLDBjMC40NDEtMC40OTEsMS4xOTgtMC41MzEsMS42ODktMC4wODhsMCwwbDYuNDY4LDUuODI2JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjI1MSwwLjIyNiwwLjM5NiwwLjU1MSwwLjM5NiwwLjg4OWwwLDBjMCww'+\n\t\t\t'LjMzNy0wLjE0NSwwLjY2My0wLjM5NiwwLjg4OWwwLDBsLTYuNDY4LDUuODI2Yy0wLjIyOSwwLjIwNi0wLjUxNSwwLjMwOC0wLjgsMC4zMDgmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7bDAsMEMxMy40ODIsMjMuMDUzLDEzLjE1NiwyMi45MTksMTIuOTIsMjIuNjU3TDEyLjkyLDIyLjY1N3oiLz4KIDwvZz4KIDxnIHN0cm9rZT0iIzAwMDAwMCIgZmlsbD0iI0ZGRkZGRiIgc3Ryb2tlLXdpZHRoPSIwLjIiPgogIDxwYXRoIGQ9Ik0zLjUsMTZDMy41MDEsOS4wOTYsOS4wOTYsMy41MDEsMTYsMy41bDAsMEMyMi45MDQsMy41MDEsMjguNDk5LDkuMDk2LDI4LjUsMTZsMCwwJiN4ZDsmI3hhOyYjeDk7Ji'+\n\t\t\t'N4OTsmI3g5O2MtMC4wMDEsNi45MDQtNS41OTYsMTIuNDk5LTEyLjUsMTIuNWwwLDBDOS4wOTYsMjguNDk5LDMuNTAxLDIyLjkwNCwzLjUsMTZMMy41LDE2eiBNOC44NTMsOC44NTMmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7QzcuMDIyLDEwLjY4Niw1Ljg5NCwxMy4yMDUsNS44OTMsMTZsMCwwYzAsMi43OTUsMS4xMjksNS4zMTQsMi45Niw3LjE0NmwwLDBjMS44MzMsMS44MzEsNC4zNTMsMi45Niw3LjE0NywyLjk2MWwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzIuNzk1LTAuMDAxLDUuMzE0LTEuMTMsNy4xNDYtMi45NjFsMCwwYzEuODMyLTEuODMyLDIuOTYxLTQuMzUyLDIuOTYxLTcu'+\n\t\t\t'MTQ2bDAsMGMwLTIuNzk1LTEuMTI5LTUuMzE0LTIuOTYxLTcuMTQ3bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtDMjEuMzE0LDcuMDIyLDE4Ljc5NSw1Ljg5NCwxNiw1Ljg5M2wwLDBDMTMuMjA2LDUuODk0LDEwLjY4Niw3LjAyMiw4Ljg1Myw4Ljg1M0w4Ljg1Myw4Ljg1M3oiLz4KICA8cGF0aCBkPSJNMTIuOTIsMjIuNjU3Yy0wLjQ0Mi0wLjQ5MS0wLjQwMy0xLjI0NywwLjA4OC0xLjY4OWwwLDBsNS40ODEtNC45MzhsLTUuNDgxLTQuOTM3djAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0wLjQ5MS0wLjQ0Mi0wLjUzLTEuMTk5LTAuMDg4LTEuNjlsMCwwYzAuNDQxLTAuNDkxLDEuMTk4LT'+\n\t\t\t'AuNTMxLDEuNjg5LTAuMDg4bDAsMGw2LjQ2OCw1LjgyNiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC4yNTEsMC4yMjYsMC4zOTYsMC41NTEsMC4zOTYsMC44ODlsMCwwYzAsMC4zMzctMC4xNDUsMC42NjMtMC4zOTYsMC44ODlsMCwwbC02LjQ2OCw1LjgyNmMtMC4yMjksMC4yMDYtMC41MTUsMC4zMDgtMC44LDAuMzA4JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2wwLDBDMTMuNDgyLDIzLjA1MywxMy4xNTYsMjIuOTE5LDEyLjkyLDIyLjY1N0wxMi45MiwyMi42NTd6Ii8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._button_image_right__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._button_image_right__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC0xNiwtMTYpIj4KICA8cGF0aCBkPSJNMy41LDE2QzMuNTAxLDkuMDk2LDkuMDk2LDMuNTAxLDE2LDMuNWwwLDBDMjIuOTA0LDMuNTAxLDI4LjQ5OSw5LjA5NiwyOC41LDE2bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTAuMDAxLDYuOTA0LTUuNTk2LDEyLjQ5OS0xMi41LDEy'+\n\t\t\t'LjVsMCwwQzkuMDk2LDI4LjQ5OSwzLjUwMSwyMi45MDQsMy41LDE2TDMuNSwxNnogTTguODUzLDguODUzJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0M3LjAyMiwxMC42ODYsNS44OTQsMTMuMjA1LDUuODkzLDE2bDAsMGMwLDIuNzk1LDEuMTI5LDUuMzE0LDIuOTYsNy4xNDZsMCwwYzEuODMzLDEuODMxLDQuMzUzLDIuOTYsNy4xNDcsMi45NjFsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MyLjc5NS0wLjAwMSw1LjMxNC0xLjEzLDcuMTQ2LTIuOTYxbDAsMGMxLjgzMi0xLjgzMiwyLjk2MS00LjM1MiwyLjk2MS03LjE0NmwwLDBjMC0yLjc5NS0xLjEyOS01LjMxNC0yLjk2MS03LjE0N2wwLD'+\n\t\t\t'AmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7QzIxLjMxNCw3LjAyMiwxOC43OTUsNS44OTQsMTYsNS44OTNsMCwwQzEzLjIwNiw1Ljg5NCwxMC42ODYsNy4wMjIsOC44NTMsOC44NTNMOC44NTMsOC44NTN6Ii8+CiAgPHBhdGggZD0iTTEyLjkyLDIyLjY1N2MtMC40NDItMC40OTEtMC40MDMtMS4yNDcsMC4wODgtMS42ODlsMCwwbDUuNDgxLTQuOTM4bC01LjQ4MS00LjkzN3YwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MtMC40OTEtMC40NDItMC41My0xLjE5OS0wLjA4OC0xLjY5bDAsMGMwLjQ0MS0wLjQ5MSwxLjE5OC0wLjUzMSwxLjY4OS0wLjA4OGwwLDBsNi40NjgsNS44MjYmI3hkOyYjeGE7'+\n\t\t\t'JiN4OTsmI3g5OyYjeDk7YzAuMjUxLDAuMjI2LDAuMzk2LDAuNTUxLDAuMzk2LDAuODg5bDAsMGMwLDAuMzM3LTAuMTQ1LDAuNjYzLTAuMzk2LDAuODg5bDAsMGwtNi40NjgsNS44MjZjLTAuMjI5LDAuMjA2LTAuNTE1LDAuMzA4LTAuOCwwLjMwOCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtsMCwwQzEzLjQ4MiwyMy4wNTMsMTMuMTU2LDIyLjkxOSwxMi45MiwyMi42NTdMMTIuOTIsMjIuNjU3eiIvPgogPC9nPgogPGcgc3Ryb2tlPSIjMDAwMDAwIiBmaWxsPSIjRkZGRkZGIiBzdHJva2Utd2lkdGg9IjAuMiIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC'+\n\t\t\t'0xNiwtMTYpIj4KICA8cGF0aCBkPSJNMy41LDE2QzMuNTAxLDkuMDk2LDkuMDk2LDMuNTAxLDE2LDMuNWwwLDBDMjIuOTA0LDMuNTAxLDI4LjQ5OSw5LjA5NiwyOC41LDE2bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTAuMDAxLDYuOTA0LTUuNTk2LDEyLjQ5OS0xMi41LDEyLjVsMCwwQzkuMDk2LDI4LjQ5OSwzLjUwMSwyMi45MDQsMy41LDE2TDMuNSwxNnogTTguODUzLDguODUzJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0M3LjAyMiwxMC42ODYsNS44OTQsMTMuMjA1LDUuODkzLDE2bDAsMGMwLDIuNzk1LDEuMTI5LDUuMzE0LDIuOTYsNy4xNDZsMCwwYzEuODMzLDEuODMxLDQuMzUz'+\n\t\t\t'LDIuOTYsNy4xNDcsMi45NjFsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MyLjc5NS0wLjAwMSw1LjMxNC0xLjEzLDcuMTQ2LTIuOTYxbDAsMGMxLjgzMi0xLjgzMiwyLjk2MS00LjM1MiwyLjk2MS03LjE0NmwwLDBjMC0yLjc5NS0xLjEyOS01LjMxNC0yLjk2MS03LjE0N2wwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7QzIxLjMxNCw3LjAyMiwxOC43OTUsNS44OTQsMTYsNS44OTNsMCwwQzEzLjIwNiw1Ljg5NCwxMC42ODYsNy4wMjIsOC44NTMsOC44NTNMOC44NTMsOC44NTN6Ii8+CiAgPHBhdGggZD0iTTEyLjkyLDIyLjY1N2MtMC40NDItMC40OTEtMC40MDMtMS4yNDcsMC4wODgtMS'+\n\t\t\t'42ODlsMCwwbDUuNDgxLTQuOTM4bC01LjQ4MS00LjkzN3YwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MtMC40OTEtMC40NDItMC41My0xLjE5OS0wLjA4OC0xLjY5bDAsMGMwLjQ0MS0wLjQ5MSwxLjE5OC0wLjUzMSwxLjY4OS0wLjA4OGwwLDBsNi40NjgsNS44MjYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuMjUxLDAuMjI2LDAuMzk2LDAuNTUxLDAuMzk2LDAuODg5bDAsMGMwLDAuMzM3LTAuMTQ1LDAuNjYzLTAuMzk2LDAuODg5bDAsMGwtNi40NjgsNS44MjZjLTAuMjI5LDAuMjA2LTAuNTE1LDAuMzA4LTAuOCwwLjMwOCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtsMCwwQzEzLjQ4Miwy'+\n\t\t\t'My4wNTMsMTMuMTU2LDIyLjkxOSwxMi45MiwyMi42NTdMMTIuOTIsMjIuNjU3eiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._button_image_right__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"button_image_right\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : -47px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 15px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_image_right.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_image_right.onmouseover=function (e) {\n\t\t\tme._button_image_right__img.style.visibility='hidden';\n\t\t\tme._button_image_right__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._button_image_right.onmouseout=function (e) {\n\t\t\tme._button_image_right__img.style.visibility='inherit';\n\t\t\tme._button_image_right__imgo.style.visibility='hidden';\n\t\t\tme.elementMouseDown['button_image_right']=false;\n\t\t}\n\t\tme._button_image_right.onmousedown=function (e) {\n\t\t\tme.elementMouseDown['button_image_right']=true;\n\t\t}\n\t\tme._button_image_right.onmouseup=function (e) {\n\t\t\tme.elementMouseDown['button_image_right']=false;\n\t\t}\n\t\tme._button_image_right.ontouchend=function (e) {\n\t\t\tme.elementMouseDown['button_image_right']=false;\n\t\t}\n\t\tme._button_image_right.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._button_direction.appendChild(me._button_image_right);\n\t\tel=me._button_image_left=document.createElement('div');\n\t\tels=me._button_image_left__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSI+CiAgPHBhdGggZD0iTTMuNSwxNkMzLjUwMSw5LjA5Niw5LjA5NiwzLjUwMSwxNiwzLjVsMCwwQzIyLjkwMywzLjUwMSwyOC40OTksOS4wOTYsMjguNSwxNmwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0wLjAwMSw2LjkwNC01LjU5NywxMi40OTktMTIuNSwxMi41bDAsMEM5LjA5NiwyOC40OTksMy41LDIyLjkwNCwzLjUsMTZMMy41LDE2eiBNNS44OTIsMTZjMCwy'+\n\t\t\t'Ljc5NSwxLjEyOSw1LjMxNCwyLjk2MSw3LjE0NmwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzEuODMzLDEuODMxLDQuMzUzLDIuOTYsNy4xNDcsMi45NjFsMCwwYzIuNzk0LTAuMDAxLDUuMzE0LTEuMTMsNy4xNDctMi45NjFsMCwwYzEuODMtMS44MzIsMi45NTktNC4zNTIsMi45Ni03LjE0NmwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0wLjAwMS0yLjc5NS0xLjEzLTUuMzE0LTIuOTYtNy4xNDdsMCwwQzIxLjMxNCw3LjAyMiwxOC43OTQsNS44OTQsMTYsNS44OTNsMCwwYy0yLjc5NCwwLTUuMzE0LDEuMTI5LTcuMTQ3LDIuOTZsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0'+\n\t\t\t'M3LjAyMSwxMC42ODYsNS44OTMsMTMuMjA1LDUuODkyLDE2TDUuODkyLDE2TDUuODkyLDE2eiIvPgogIDxwYXRoIGQ9Ik0xNy4zOTEsMjIuNjg2bC02LjQ2OC01LjgyN2MtMC4yNS0wLjIyNi0wLjM5Ni0wLjU1Mi0wLjM5Ni0wLjg4OWwwLDBjMC0wLjMzNywwLjE0Ni0wLjY2MywwLjM5Ni0wLjg4OSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtsMCwwbDYuNDY4LTUuODI2YzAuNDkxLTAuNDQyLDEuMjQ3LTAuNDAzLDEuNjg5LDAuMDg4bDAsMGMwLjQ0MiwwLjQ5LDAuNDAyLDEuMjQ3LTAuMDg4LDEuNjg5bDAsMGwtNS40ODEsNC45MzhsNS40ODEsNC45MzhsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsm'+\n\t\t\t'I3g5O2MwLjQ5LDAuNDQyLDAuNTMsMS4xOTgsMC4wODgsMS42ODlsMCwwYy0wLjIzNiwwLjI2My0wLjU2MiwwLjM5Ni0wLjg4OSwwLjM5NmwwLDBDMTcuOTA2LDIyLjk5MywxNy42MiwyMi44OTEsMTcuMzkxLDIyLjY4NiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtMMTcuMzkxLDIyLjY4NnoiLz4KIDwvZz4KIDxnIHN0cm9rZT0iIzAwMDAwMCIgZmlsbD0iI0ZGRkZGRiIgc3Ryb2tlLXdpZHRoPSIwLjIiPgogIDxwYXRoIGQ9Ik0zLjUsMTZDMy41MDEsOS4wOTYsOS4wOTYsMy41MDEsMTYsMy41bDAsMEMyMi45MDMsMy41MDEsMjguNDk5LDkuMDk2LDI4LjUsMTZsMCwwJiN4ZDsmI3hhOyYjeDk7Ji'+\n\t\t\t'N4OTsmI3g5O2MtMC4wMDEsNi45MDQtNS41OTcsMTIuNDk5LTEyLjUsMTIuNWwwLDBDOS4wOTYsMjguNDk5LDMuNSwyMi45MDQsMy41LDE2TDMuNSwxNnogTTUuODkyLDE2YzAsMi43OTUsMS4xMjksNS4zMTQsMi45NjEsNy4xNDZsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MxLjgzMywxLjgzMSw0LjM1MywyLjk2LDcuMTQ3LDIuOTYxbDAsMGMyLjc5NC0wLjAwMSw1LjMxNC0xLjEzLDcuMTQ3LTIuOTYxbDAsMGMxLjgzLTEuODMyLDIuOTU5LTQuMzUyLDIuOTYtNy4xNDZsMCwwJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MtMC4wMDEtMi43OTUtMS4xMy01LjMxNC0yLjk2LTcuMTQ3bDAs'+\n\t\t\t'MEMyMS4zMTQsNy4wMjIsMTguNzk0LDUuODk0LDE2LDUuODkzbDAsMGMtMi43OTQsMC01LjMxNCwxLjEyOS03LjE0NywyLjk2bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtDNy4wMjEsMTAuNjg2LDUuODkzLDEzLjIwNSw1Ljg5MiwxNkw1Ljg5MiwxNkw1Ljg5MiwxNnoiLz4KICA8cGF0aCBkPSJNMTcuMzkxLDIyLjY4NmwtNi40NjgtNS44MjdjLTAuMjUtMC4yMjYtMC4zOTYtMC41NTItMC4zOTYtMC44ODlsMCwwYzAtMC4zMzcsMC4xNDYtMC42NjMsMC4zOTYtMC44ODkmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7bDAsMGw2LjQ2OC01LjgyNmMwLjQ5MS0wLjQ0MiwxLjI0Ny0wLjQwMywxLj'+\n\t\t\t'Y4OSwwLjA4OGwwLDBjMC40NDIsMC40OSwwLjQwMiwxLjI0Ny0wLjA4OCwxLjY4OWwwLDBsLTUuNDgxLDQuOTM4bDUuNDgxLDQuOTM4bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC40OSwwLjQ0MiwwLjUzLDEuMTk4LDAuMDg4LDEuNjg5bDAsMGMtMC4yMzYsMC4yNjMtMC41NjIsMC4zOTYtMC44ODksMC4zOTZsMCwwQzE3LjkwNiwyMi45OTMsMTcuNjIsMjIuODkxLDE3LjM5MSwyMi42ODYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7TDE3LjM5MSwyMi42ODZ6Ii8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._button_image_left__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._button_image_left__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC0xNiwtMTYpIj4KICA8cGF0aCBkPSJNMy41LDE2QzMuNTAxLDkuMDk2LDkuMDk2LDMuNTAxLDE2LDMuNWwwLDBDMjIuOTAzLDMuNTAxLDI4LjQ5OSw5LjA5NiwyOC41LDE2bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTAuMDAxLDYuOTA0LTUuNTk3LDEyLjQ5OS0xMi41LDEy'+\n\t\t\t'LjVsMCwwQzkuMDk2LDI4LjQ5OSwzLjUsMjIuOTA0LDMuNSwxNkwzLjUsMTZ6IE01Ljg5MiwxNmMwLDIuNzk1LDEuMTI5LDUuMzE0LDIuOTYxLDcuMTQ2bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMS44MzMsMS44MzEsNC4zNTMsMi45Niw3LjE0NywyLjk2MWwwLDBjMi43OTQtMC4wMDEsNS4zMTQtMS4xMyw3LjE0Ny0yLjk2MWwwLDBjMS44My0xLjgzMiwyLjk1OS00LjM1MiwyLjk2LTcuMTQ2bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTAuMDAxLTIuNzk1LTEuMTMtNS4zMTQtMi45Ni03LjE0N2wwLDBDMjEuMzE0LDcuMDIyLDE4Ljc5NCw1Ljg5NCwxNiw1Ljg5M2wwLDBjLT'+\n\t\t\t'IuNzk0LDAtNS4zMTQsMS4xMjktNy4xNDcsMi45NmwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7QzcuMDIxLDEwLjY4Niw1Ljg5MywxMy4yMDUsNS44OTIsMTZMNS44OTIsMTZMNS44OTIsMTZ6Ii8+CiAgPHBhdGggZD0iTTE3LjM5MSwyMi42ODZsLTYuNDY4LTUuODI3Yy0wLjI1LTAuMjI2LTAuMzk2LTAuNTUyLTAuMzk2LTAuODg5bDAsMGMwLTAuMzM3LDAuMTQ2LTAuNjYzLDAuMzk2LTAuODg5JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2wwLDBsNi40NjgtNS44MjZjMC40OTEtMC40NDIsMS4yNDctMC40MDMsMS42ODksMC4wODhsMCwwYzAuNDQyLDAuNDksMC40MDIsMS4yNDctMC4wODgs'+\n\t\t\t'MS42ODlsMCwwbC01LjQ4MSw0LjkzOGw1LjQ4MSw0LjkzOGwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuNDksMC40NDIsMC41MywxLjE5OCwwLjA4OCwxLjY4OWwwLDBjLTAuMjM2LDAuMjYzLTAuNTYyLDAuMzk2LTAuODg5LDAuMzk2bDAsMEMxNy45MDYsMjIuOTkzLDE3LjYyLDIyLjg5MSwxNy4zOTEsMjIuNjg2JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0wxNy4zOTEsMjIuNjg2eiIvPgogPC9nPgogPGcgc3Ryb2tlPSIjMDAwMDAwIiBmaWxsPSIjRkZGRkZGIiBzdHJva2Utd2lkdGg9IjAuMiIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC'+\n\t\t\t'0xNiwtMTYpIj4KICA8cGF0aCBkPSJNMy41LDE2QzMuNTAxLDkuMDk2LDkuMDk2LDMuNTAxLDE2LDMuNWwwLDBDMjIuOTAzLDMuNTAxLDI4LjQ5OSw5LjA5NiwyOC41LDE2bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTAuMDAxLDYuOTA0LTUuNTk3LDEyLjQ5OS0xMi41LDEyLjVsMCwwQzkuMDk2LDI4LjQ5OSwzLjUsMjIuOTA0LDMuNSwxNkwzLjUsMTZ6IE01Ljg5MiwxNmMwLDIuNzk1LDEuMTI5LDUuMzE0LDIuOTYxLDcuMTQ2bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMS44MzMsMS44MzEsNC4zNTMsMi45Niw3LjE0NywyLjk2MWwwLDBjMi43OTQtMC4wMDEsNS4zMTQtMS4x'+\n\t\t\t'Myw3LjE0Ny0yLjk2MWwwLDBjMS44My0xLjgzMiwyLjk1OS00LjM1MiwyLjk2LTcuMTQ2bDAsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTAuMDAxLTIuNzk1LTEuMTMtNS4zMTQtMi45Ni03LjE0N2wwLDBDMjEuMzE0LDcuMDIyLDE4Ljc5NCw1Ljg5NCwxNiw1Ljg5M2wwLDBjLTIuNzk0LDAtNS4zMTQsMS4xMjktNy4xNDcsMi45NmwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7QzcuMDIxLDEwLjY4Niw1Ljg5MywxMy4yMDUsNS44OTIsMTZMNS44OTIsMTZMNS44OTIsMTZ6Ii8+CiAgPHBhdGggZD0iTTE3LjM5MSwyMi42ODZsLTYuNDY4LTUuODI3Yy0wLjI1LTAuMjI2LTAuMzk2LTAuNT'+\n\t\t\t'UyLTAuMzk2LTAuODg5bDAsMGMwLTAuMzM3LDAuMTQ2LTAuNjYzLDAuMzk2LTAuODg5JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2wwLDBsNi40NjgtNS44MjZjMC40OTEtMC40NDIsMS4yNDctMC40MDMsMS42ODksMC4wODhsMCwwYzAuNDQyLDAuNDksMC40MDIsMS4yNDctMC4wODgsMS42ODlsMCwwbC01LjQ4MSw0LjkzOGw1LjQ4MSw0LjkzOGwwLDAmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuNDksMC40NDIsMC41MywxLjE5OCwwLjA4OCwxLjY4OWwwLDBjLTAuMjM2LDAuMjYzLTAuNTYyLDAuMzk2LTAuODg5LDAuMzk2bDAsMEMxNy45MDYsMjIuOTkzLDE3LjYyLDIyLjg5MSwxNy4zOTEs'+\n\t\t\t'MjIuNjg2JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0wxNy4zOTEsMjIuNjg2eiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._button_image_left__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"button_image_left\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : -77px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 15px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_image_left.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_image_left.onmouseover=function (e) {\n\t\t\tme._button_image_left__img.style.visibility='hidden';\n\t\t\tme._button_image_left__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._button_image_left.onmouseout=function (e) {\n\t\t\tme._button_image_left__img.style.visibility='inherit';\n\t\t\tme._button_image_left__imgo.style.visibility='hidden';\n\t\t\tme.elementMouseDown['button_image_left']=false;\n\t\t}\n\t\tme._button_image_left.onmousedown=function (e) {\n\t\t\tme.elementMouseDown['button_image_left']=true;\n\t\t}\n\t\tme._button_image_left.onmouseup=function (e) {\n\t\t\tme.elementMouseDown['button_image_left']=false;\n\t\t}\n\t\tme._button_image_left.ontouchend=function (e) {\n\t\t\tme.elementMouseDown['button_image_left']=false;\n\t\t}\n\t\tme._button_image_left.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._button_direction.appendChild(me._button_image_left);\n\t\tel=me._button_image_down=document.createElement('div');\n\t\tels=me._button_image_down__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSI+CiAgPHBhdGggZD0iTTIwLjkwOCwxMy4wMDdsLTQuOTM4LDUuNDgxbC00LjkzOC01LjQ4MWMtMC40NDMtMC40OTEtMS4xOTktMC41MzEtMS42ODktMC4wODgmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0wLjQ5MSwwLjQ0Mi0wLjUzLDEuMTk5LTAuMDg4LDEuNjg5bDUuODI3LDYuNDY4YzAuMjI2LDAuMjUsMC41NTEsMC4zOTYsMC44ODksMC4zOTZzMC42NjMtMC4xNDYs'+\n\t\t\t'MC44ODktMC4zOTZsNS44MjctNi40NjgmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuNDQyLTAuNDkxLDAuNDAyLTEuMjQ4LTAuMDg4LTEuNjg5QzIyLjEwNiwxMi40NzcsMjEuMzUsMTIuNTE3LDIwLjkwOCwxMy4wMDd6IE0xNiwzLjVDOS4wOTYsMy41LDMuNSw5LjA5NiwzLjUsMTYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAsNi45MDMsNS41OTYsMTIuNDk5LDEyLjUsMTIuNWM2LjkwMy0wLjAwMSwxMi40OTktNS41OTcsMTIuNS0xMi41QzI4LjQ5OSw5LjA5NiwyMi45MDMsMy41LDE2LDMuNXogTTIzLjE0NywyMy4xNDYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0xLjgzMywxLjgzMS'+\n\t\t\t'00LjM1MywyLjk2LTcuMTQ3LDIuOTZzLTUuMzE0LTEuMTI5LTcuMTQ2LTIuOTZDNy4wMjIsMjEuMzE0LDUuODk0LDE4Ljc5NSw1Ljg5MywxNiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC4wMDEtMi43OTUsMS4xMjktNS4zMTQsMi45NjEtNy4xNDdjMS44MzMtMS44MzEsNC4zNTItMi45Niw3LjE0Ni0yLjk2MWMyLjc5NSwwLjAwMSw1LjMxMywxLjEzLDcuMTQ3LDIuOTYxJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MxLjgzMSwxLjgzMywyLjk1OSw0LjM1MiwyLjk2LDcuMTQ3QzI2LjEwNiwxOC43OTUsMjQuOTc5LDIxLjMxNCwyMy4xNDcsMjMuMTQ2eiIvPgogPC9nPgogPGcgc3Ryb2tlPSIj'+\n\t\t\t'MDAwMDAwIiBmaWxsPSIjRkZGRkZGIiBzdHJva2Utd2lkdGg9IjAuMiI+CiAgPHBhdGggZD0iTTIwLjkwOCwxMy4wMDdsLTQuOTM4LDUuNDgxbC00LjkzOC01LjQ4MWMtMC40NDMtMC40OTEtMS4xOTktMC41MzEtMS42ODktMC4wODgmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0wLjQ5MSwwLjQ0Mi0wLjUzLDEuMTk5LTAuMDg4LDEuNjg5bDUuODI3LDYuNDY4YzAuMjI2LDAuMjUsMC41NTEsMC4zOTYsMC44ODksMC4zOTZzMC42NjMtMC4xNDYsMC44ODktMC4zOTZsNS44MjctNi40NjgmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuNDQyLTAuNDkxLDAuNDAyLTEuMjQ4LTAuMDg4LTEuNjg5Qz'+\n\t\t\t'IyLjEwNiwxMi40NzcsMjEuMzUsMTIuNTE3LDIwLjkwOCwxMy4wMDd6IE0xNiwzLjVDOS4wOTYsMy41LDMuNSw5LjA5NiwzLjUsMTYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAsNi45MDMsNS41OTYsMTIuNDk5LDEyLjUsMTIuNWM2LjkwMy0wLjAwMSwxMi40OTktNS41OTcsMTIuNS0xMi41QzI4LjQ5OSw5LjA5NiwyMi45MDMsMy41LDE2LDMuNXogTTIzLjE0NywyMy4xNDYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0xLjgzMywxLjgzMS00LjM1MywyLjk2LTcuMTQ3LDIuOTZzLTUuMzE0LTEuMTI5LTcuMTQ2LTIuOTZDNy4wMjIsMjEuMzE0LDUuODk0LDE4Ljc5NSw1Ljg5MywxNiYjeGQ7'+\n\t\t\t'JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC4wMDEtMi43OTUsMS4xMjktNS4zMTQsMi45NjEtNy4xNDdjMS44MzMtMS44MzEsNC4zNTItMi45Niw3LjE0Ni0yLjk2MWMyLjc5NSwwLjAwMSw1LjMxMywxLjEzLDcuMTQ3LDIuOTYxJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MxLjgzMSwxLjgzMywyLjk1OSw0LjM1MiwyLjk2LDcuMTQ3QzI2LjEwNiwxOC43OTUsMjQuOTc5LDIxLjMxNCwyMy4xNDcsMjMuMTQ2eiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._button_image_down__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._button_image_down__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC0xNiwtMTYpIj4KICA8cGF0aCBkPSJNMjAuOTA4LDEzLjAwN2wtNC45MzgsNS40ODFsLTQuOTM4LTUuNDgxYy0wLjQ0My0wLjQ5MS0xLjE5OS0wLjUzMS0xLjY4OS0wLjA4OCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTAuNDkxLDAuNDQyLTAuNTMsMS4xOTktMC4wODgsMS42ODls'+\n\t\t\t'NS44MjcsNi40NjhjMC4yMjYsMC4yNSwwLjU1MSwwLjM5NiwwLjg4OSwwLjM5NnMwLjY2My0wLjE0NiwwLjg4OS0wLjM5Nmw1LjgyNy02LjQ2OCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC40NDItMC40OTEsMC40MDItMS4yNDgtMC4wODgtMS42ODlDMjIuMTA2LDEyLjQ3NywyMS4zNSwxMi41MTcsMjAuOTA4LDEzLjAwN3ogTTE2LDMuNUM5LjA5NiwzLjUsMy41LDkuMDk2LDMuNSwxNiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMCw2LjkwMyw1LjU5NiwxMi40OTksMTIuNSwxMi41YzYuOTAzLTAuMDAxLDEyLjQ5OS01LjU5NywxMi41LTEyLjVDMjguNDk5LDkuMDk2LDIyLjkwMywzLjUsMT'+\n\t\t\t'YsMy41eiBNMjMuMTQ3LDIzLjE0NiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTEuODMzLDEuODMxLTQuMzUzLDIuOTYtNy4xNDcsMi45NnMtNS4zMTQtMS4xMjktNy4xNDYtMi45NkM3LjAyMiwyMS4zMTQsNS44OTQsMTguNzk1LDUuODkzLDE2JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjAwMS0yLjc5NSwxLjEyOS01LjMxNCwyLjk2MS03LjE0N2MxLjgzMy0xLjgzMSw0LjM1Mi0yLjk2LDcuMTQ2LTIuOTYxYzIuNzk1LDAuMDAxLDUuMzEzLDEuMTMsNy4xNDcsMi45NjEmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzEuODMxLDEuODMzLDIuOTU5LDQuMzUyLDIuOTYsNy4xNDdDMjYuMTA2'+\n\t\t\t'LDE4Ljc5NSwyNC45NzksMjEuMzE0LDIzLjE0NywyMy4xNDZ6Ii8+CiA8L2c+CiA8ZyBzdHJva2U9IiMwMDAwMDAiIGZpbGw9IiNGRkZGRkYiIHN0cm9rZS13aWR0aD0iMC4yIiB0cmFuc2Zvcm09InRyYW5zbGF0ZSgxNiwxNikgc2NhbGUoMS4xKSB0cmFuc2xhdGUoLTE2LC0xNikiPgogIDxwYXRoIGQ9Ik0yMC45MDgsMTMuMDA3bC00LjkzOCw1LjQ4MWwtNC45MzgtNS40ODFjLTAuNDQzLTAuNDkxLTEuMTk5LTAuNTMxLTEuNjg5LTAuMDg4JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MtMC40OTEsMC40NDItMC41MywxLjE5OS0wLjA4OCwxLjY4OWw1LjgyNyw2LjQ2OGMwLjIyNiwwLjI1LDAuNT'+\n\t\t\t'UxLDAuMzk2LDAuODg5LDAuMzk2czAuNjYzLTAuMTQ2LDAuODg5LTAuMzk2bDUuODI3LTYuNDY4JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjQ0Mi0wLjQ5MSwwLjQwMi0xLjI0OC0wLjA4OC0xLjY4OUMyMi4xMDYsMTIuNDc3LDIxLjM1LDEyLjUxNywyMC45MDgsMTMuMDA3eiBNMTYsMy41QzkuMDk2LDMuNSwzLjUsOS4wOTYsMy41LDE2JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLDYuOTAzLDUuNTk2LDEyLjQ5OSwxMi41LDEyLjVjNi45MDMtMC4wMDEsMTIuNDk5LTUuNTk3LDEyLjUtMTIuNUMyOC40OTksOS4wOTYsMjIuOTAzLDMuNSwxNiwzLjV6IE0yMy4xNDcsMjMuMTQ2JiN4ZDsm'+\n\t\t\t'I3hhOyYjeDk7JiN4OTsmI3g5O2MtMS44MzMsMS44MzEtNC4zNTMsMi45Ni03LjE0NywyLjk2cy01LjMxNC0xLjEyOS03LjE0Ni0yLjk2QzcuMDIyLDIxLjMxNCw1Ljg5NCwxOC43OTUsNS44OTMsMTYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuMDAxLTIuNzk1LDEuMTI5LTUuMzE0LDIuOTYxLTcuMTQ3YzEuODMzLTEuODMxLDQuMzUyLTIuOTYsNy4xNDYtMi45NjFjMi43OTUsMC4wMDEsNS4zMTMsMS4xMyw3LjE0NywyLjk2MSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMS44MzEsMS44MzMsMi45NTksNC4zNTIsMi45Niw3LjE0N0MyNi4xMDYsMTguNzk1LDI0Ljk3OSwyMS4zMTQsMjMuMT'+\n\t\t\t'Q3LDIzLjE0NnoiLz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._button_image_down__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"button_image_down\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 15px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 15px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_image_down.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_image_down.onmouseover=function (e) {\n\t\t\tme._button_image_down__img.style.visibility='hidden';\n\t\t\tme._button_image_down__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._button_image_down.onmouseout=function (e) {\n\t\t\tme._button_image_down__img.style.visibility='inherit';\n\t\t\tme._button_image_down__imgo.style.visibility='hidden';\n\t\t\tme.elementMouseDown['button_image_down']=false;\n\t\t}\n\t\tme._button_image_down.onmousedown=function (e) {\n\t\t\tme.elementMouseDown['button_image_down']=true;\n\t\t}\n\t\tme._button_image_down.onmouseup=function (e) {\n\t\t\tme.elementMouseDown['button_image_down']=false;\n\t\t}\n\t\tme._button_image_down.ontouchend=function (e) {\n\t\t\tme.elementMouseDown['button_image_down']=false;\n\t\t}\n\t\tme._button_image_down.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._button_direction.appendChild(me._button_image_down);\n\t\tel=me._button_image_up=document.createElement('div');\n\t\tels=me._button_image_up__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSI+CiAgPHBhdGggZD0iTTE2LjkxOSwxMC45MjNjLTAuMjI3LTAuMjUxLTAuNTUxLTAuMzk2LTAuODg5LTAuMzk2Yy0wLjMzNywwLTAuNjYzLDAuMTQ1LTAuODg5LDAuMzk2bC01LjgyNyw2LjQ2OCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTAuNDQyLDAuNDkxLTAuNDAzLDEuMjQ4LDAuMDg4LDEuNjg5YzAuNDkxLDAuNDQyLDEuMjQ3LDAuNDAzLDEuNjg5LTAuMDg4bDQu'+\n\t\t\t'OTM4LTUuNDgxbDQuOTM4LDUuNDgxJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjIzNiwwLjI2MywwLjU2MywwLjM5NiwwLjg5LDAuMzk2YzAuMjg1LDAsMC41NzEtMC4xMDIsMC44LTAuMzA4YzAuNDkxLTAuNDQxLDAuNTMtMS4xOTgsMC4wODgtMS42ODlMMTYuOTE5LDEwLjkyM3ogTTE2LDMuNSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtDOS4wOTYsMy41LDMuNSw5LjA5NiwzLjUsMTZjMCw2LjkwMyw1LjU5NiwxMi40OTksMTIuNSwxMi41YzYuOTAzLTAuMDAxLDEyLjQ5OS01LjU5NywxMi41LTEyLjVDMjguNDk5LDkuMDk2LDIyLjkwMywzLjUsMTYsMy41eiYjeGQ7JiN4YTsmI3g5OyYjeD'+\n\t\t\t'k7JiN4OTsgTTIzLjE0NywyMy4xNDZjLTEuODMzLDEuODMxLTQuMzUzLDIuOTYtNy4xNDcsMi45NnMtNS4zMTQtMS4xMjktNy4xNDYtMi45NkM3LjAyMiwyMS4zMTQsNS44OTQsMTguNzk1LDUuODkzLDE2JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjAwMS0yLjc5NSwxLjEyOS01LjMxNCwyLjk2MS03LjE0N2MxLjgzMy0xLjgzMSw0LjM1Mi0yLjk2LDcuMTQ2LTIuOTYxYzIuNzk1LDAuMDAxLDUuMzEzLDEuMTMsNy4xNDcsMi45NjEmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzEuODMxLDEuODMzLDIuOTU5LDQuMzUyLDIuOTYsNy4xNDdDMjYuMTA2LDE4Ljc5NSwyNC45NzksMjEuMzE0LDIz'+\n\t\t\t'LjE0NywyMy4xNDZ6Ii8+CiA8L2c+CiA8ZyBzdHJva2U9IiMwMDAwMDAiIGZpbGw9IiNGRkZGRkYiIHN0cm9rZS13aWR0aD0iMC4yIj4KICA8cGF0aCBkPSJNMTYuOTE5LDEwLjkyM2MtMC4yMjctMC4yNTEtMC41NTEtMC4zOTYtMC44ODktMC4zOTZjLTAuMzM3LDAtMC42NjMsMC4xNDUtMC44ODksMC4zOTZsLTUuODI3LDYuNDY4JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MtMC40NDIsMC40OTEtMC40MDMsMS4yNDgsMC4wODgsMS42ODljMC40OTEsMC40NDIsMS4yNDcsMC40MDMsMS42ODktMC4wODhsNC45MzgtNS40ODFsNC45MzgsNS40ODEmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuMj'+\n\t\t\t'M2LDAuMjYzLDAuNTYzLDAuMzk2LDAuODksMC4zOTZjMC4yODUsMCwwLjU3MS0wLjEwMiwwLjgtMC4zMDhjMC40OTEtMC40NDEsMC41My0xLjE5OCwwLjA4OC0xLjY4OUwxNi45MTksMTAuOTIzeiBNMTYsMy41JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0M5LjA5NiwzLjUsMy41LDkuMDk2LDMuNSwxNmMwLDYuOTAzLDUuNTk2LDEyLjQ5OSwxMi41LDEyLjVjNi45MDMtMC4wMDEsMTIuNDk5LTUuNTk3LDEyLjUtMTIuNUMyOC40OTksOS4wOTYsMjIuOTAzLDMuNSwxNiwzLjV6JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5OyBNMjMuMTQ3LDIzLjE0NmMtMS44MzMsMS44MzEtNC4zNTMsMi45Ni03LjE0'+\n\t\t\t'NywyLjk2cy01LjMxNC0xLjEyOS03LjE0Ni0yLjk2QzcuMDIyLDIxLjMxNCw1Ljg5NCwxOC43OTUsNS44OTMsMTYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuMDAxLTIuNzk1LDEuMTI5LTUuMzE0LDIuOTYxLTcuMTQ3YzEuODMzLTEuODMxLDQuMzUyLTIuOTYsNy4xNDYtMi45NjFjMi43OTUsMC4wMDEsNS4zMTMsMS4xMyw3LjE0NywyLjk2MSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMS44MzEsMS44MzMsMi45NTksNC4zNTIsMi45Niw3LjE0N0MyNi4xMDYsMTguNzk1LDI0Ljk3OSwyMS4zMTQsMjMuMTQ3LDIzLjE0NnoiLz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._button_image_up__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._button_image_up__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC0xNiwtMTYpIj4KICA8cGF0aCBkPSJNMTYuOTE5LDEwLjkyM2MtMC4yMjctMC4yNTEtMC41NTEtMC4zOTYtMC44ODktMC4zOTZjLTAuMzM3LDAtMC42NjMsMC4xNDUtMC44ODksMC4zOTZsLTUuODI3LDYuNDY4JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MtMC40NDIsMC40OTEtMC40'+\n\t\t\t'MDMsMS4yNDgsMC4wODgsMS42ODljMC40OTEsMC40NDIsMS4yNDcsMC40MDMsMS42ODktMC4wODhsNC45MzgtNS40ODFsNC45MzgsNS40ODEmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuMjM2LDAuMjYzLDAuNTYzLDAuMzk2LDAuODksMC4zOTZjMC4yODUsMCwwLjU3MS0wLjEwMiwwLjgtMC4zMDhjMC40OTEtMC40NDEsMC41My0xLjE5OCwwLjA4OC0xLjY4OUwxNi45MTksMTAuOTIzeiBNMTYsMy41JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0M5LjA5NiwzLjUsMy41LDkuMDk2LDMuNSwxNmMwLDYuOTAzLDUuNTk2LDEyLjQ5OSwxMi41LDEyLjVjNi45MDMtMC4wMDEsMTIuNDk5LTUuNTk3LD'+\n\t\t\t'EyLjUtMTIuNUMyOC40OTksOS4wOTYsMjIuOTAzLDMuNSwxNiwzLjV6JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5OyBNMjMuMTQ3LDIzLjE0NmMtMS44MzMsMS44MzEtNC4zNTMsMi45Ni03LjE0NywyLjk2cy01LjMxNC0xLjEyOS03LjE0Ni0yLjk2QzcuMDIyLDIxLjMxNCw1Ljg5NCwxOC43OTUsNS44OTMsMTYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuMDAxLTIuNzk1LDEuMTI5LTUuMzE0LDIuOTYxLTcuMTQ3YzEuODMzLTEuODMxLDQuMzUyLTIuOTYsNy4xNDYtMi45NjFjMi43OTUsMC4wMDEsNS4zMTMsMS4xMyw3LjE0NywyLjk2MSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMS44MzEs'+\n\t\t\t'MS44MzMsMi45NTksNC4zNTIsMi45Niw3LjE0N0MyNi4xMDYsMTguNzk1LDI0Ljk3OSwyMS4zMTQsMjMuMTQ3LDIzLjE0NnoiLz4KIDwvZz4KIDxnIHN0cm9rZT0iIzAwMDAwMCIgZmlsbD0iI0ZGRkZGRiIgc3Ryb2tlLXdpZHRoPSIwLjIiIHRyYW5zZm9ybT0idHJhbnNsYXRlKDE2LDE2KSBzY2FsZSgxLjEpIHRyYW5zbGF0ZSgtMTYsLTE2KSI+CiAgPHBhdGggZD0iTTE2LjkxOSwxMC45MjNjLTAuMjI3LTAuMjUxLTAuNTUxLTAuMzk2LTAuODg5LTAuMzk2Yy0wLjMzNywwLTAuNjYzLDAuMTQ1LTAuODg5LDAuMzk2bC01LjgyNyw2LjQ2OCYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTAuNDQyLD'+\n\t\t\t'AuNDkxLTAuNDAzLDEuMjQ4LDAuMDg4LDEuNjg5YzAuNDkxLDAuNDQyLDEuMjQ3LDAuNDAzLDEuNjg5LTAuMDg4bDQuOTM4LTUuNDgxbDQuOTM4LDUuNDgxJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjIzNiwwLjI2MywwLjU2MywwLjM5NiwwLjg5LDAuMzk2YzAuMjg1LDAsMC41NzEtMC4xMDIsMC44LTAuMzA4YzAuNDkxLTAuNDQxLDAuNTMtMS4xOTgsMC4wODgtMS42ODlMMTYuOTE5LDEwLjkyM3ogTTE2LDMuNSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtDOS4wOTYsMy41LDMuNSw5LjA5NiwzLjUsMTZjMCw2LjkwMyw1LjU5NiwxMi40OTksMTIuNSwxMi41YzYuOTAzLTAuMDAxLDEyLjQ5'+\n\t\t\t'OS01LjU5NywxMi41LTEyLjVDMjguNDk5LDkuMDk2LDIyLjkwMywzLjUsMTYsMy41eiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTsgTTIzLjE0NywyMy4xNDZjLTEuODMzLDEuODMxLTQuMzUzLDIuOTYtNy4xNDcsMi45NnMtNS4zMTQtMS4xMjktNy4xNDYtMi45NkM3LjAyMiwyMS4zMTQsNS44OTQsMTguNzk1LDUuODkzLDE2JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjAwMS0yLjc5NSwxLjEyOS01LjMxNCwyLjk2MS03LjE0N2MxLjgzMy0xLjgzMSw0LjM1Mi0yLjk2LDcuMTQ2LTIuOTYxYzIuNzk1LDAuMDAxLDUuMzEzLDEuMTMsNy4xNDcsMi45NjEmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeD'+\n\t\t\t'k7YzEuODMxLDEuODMzLDIuOTU5LDQuMzUyLDIuOTYsNy4xNDdDMjYuMTA2LDE4Ljc5NSwyNC45NzksMjEuMzE0LDIzLjE0NywyMy4xNDZ6Ii8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._button_image_up__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"button_image_up\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : -16px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 15px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_image_up.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_image_up.onmouseover=function (e) {\n\t\t\tme._button_image_up__img.style.visibility='hidden';\n\t\t\tme._button_image_up__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._button_image_up.onmouseout=function (e) {\n\t\t\tme._button_image_up__img.style.visibility='inherit';\n\t\t\tme._button_image_up__imgo.style.visibility='hidden';\n\t\t\tme.elementMouseDown['button_image_up']=false;\n\t\t}\n\t\tme._button_image_up.onmousedown=function (e) {\n\t\t\tme.elementMouseDown['button_image_up']=true;\n\t\t}\n\t\tme._button_image_up.onmouseup=function (e) {\n\t\t\tme.elementMouseDown['button_image_up']=false;\n\t\t}\n\t\tme._button_image_up.ontouchend=function (e) {\n\t\t\tme.elementMouseDown['button_image_up']=false;\n\t\t}\n\t\tme._button_image_up.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._button_direction.appendChild(me._button_image_up);\n\t\tme._container_1.appendChild(me._button_direction);\n\t\tel=me._button_zoom=document.createElement('div');\n\t\tel.ggId=\"button_zoom\";\n\t\tel.ggDx=-5;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='bottom : 20px;';\n\t\ths+='height : 32px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 64px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_zoom.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_zoom.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._zoomout=document.createElement('div');\n\t\tels=me._zoomout__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSI+CiAgPHBhdGggZD0iTTIxLjc1OCwxNC44MDRIMTAuMjQxYy0wLjY2LDAtMS4xOTYsMC41MzUtMS4xOTYsMS4xOTZjMCwwLjY2MSwwLjUzNiwxLjE5NiwxLjE5NiwxLjE5NmgxMS41MTcmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuNjYxLDAsMS4xOTctMC41MzYsMS4xOTctMS4xOTZDMjIuOTU1LDE1LjMzOSwyMi40MTksMTQuODA0LDIxLjc1OCwxNC44MDR6IE0xNiwz'+\n\t\t\t'LjVDOS4wOTYsMy41LDMuNSw5LjA5NiwzLjUsMTYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAsNi45MDMsNS41OTYsMTIuNDk5LDEyLjUsMTIuNWM2LjkwMy0wLjAwMSwxMi40OTktNS41OTcsMTIuNS0xMi41QzI4LjQ5OSw5LjA5NiwyMi45MDMsMy41LDE2LDMuNXogTTIzLjE0NiwyMy4xNDYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0xLjgzMiwxLjgzMS00LjM1MiwyLjk2LTcuMTQ2LDIuOTZzLTUuMzE0LTEuMTI5LTcuMTQ2LTIuOTZDNy4wMjIsMjEuMzE0LDUuODk0LDE4Ljc5NSw1Ljg5MywxNiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC4wMDEtMi43OTUsMS4xMjktNS4zMTQsMi'+\n\t\t\t'45NjEtNy4xNDdjMS44MzMtMS44MzEsNC4zNTItMi45Niw3LjE0Ni0yLjk2MWMyLjc5NSwwLjAwMSw1LjMxMywxLjEzLDcuMTQ2LDIuOTYxJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MxLjgzMiwxLjgzMywyLjk2LDQuMzUyLDIuOTYxLDcuMTQ3QzI2LjEwNiwxOC43OTUsMjQuOTc5LDIxLjMxNCwyMy4xNDYsMjMuMTQ2eiIvPgogPC9nPgogPGcgc3Ryb2tlPSIjMDAwMDAwIiBmaWxsPSIjRkZGRkZGIiBzdHJva2Utd2lkdGg9IjAuMiI+CiAgPHBhdGggZD0iTTIxLjc1OCwxNC44MDRIMTAuMjQxYy0wLjY2LDAtMS4xOTYsMC41MzUtMS4xOTYsMS4xOTZjMCwwLjY2MSwwLjUzNiwxLjE5NiwxLjE5'+\n\t\t\t'NiwxLjE5NmgxMS41MTcmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuNjYxLDAsMS4xOTctMC41MzYsMS4xOTctMS4xOTZDMjIuOTU1LDE1LjMzOSwyMi40MTksMTQuODA0LDIxLjc1OCwxNC44MDR6IE0xNiwzLjVDOS4wOTYsMy41LDMuNSw5LjA5NiwzLjUsMTYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAsNi45MDMsNS41OTYsMTIuNDk5LDEyLjUsMTIuNWM2LjkwMy0wLjAwMSwxMi40OTktNS41OTcsMTIuNS0xMi41QzI4LjQ5OSw5LjA5NiwyMi45MDMsMy41LDE2LDMuNXogTTIzLjE0NiwyMy4xNDYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7Yy0xLjgzMiwxLjgzMS00LjM1MiwyLjk2LT'+\n\t\t\t'cuMTQ2LDIuOTZzLTUuMzE0LTEuMTI5LTcuMTQ2LTIuOTZDNy4wMjIsMjEuMzE0LDUuODk0LDE4Ljc5NSw1Ljg5MywxNiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC4wMDEtMi43OTUsMS4xMjktNS4zMTQsMi45NjEtNy4xNDdjMS44MzMtMS44MzEsNC4zNTItMi45Niw3LjE0Ni0yLjk2MWMyLjc5NSwwLjAwMSw1LjMxMywxLjEzLDcuMTQ2LDIuOTYxJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MxLjgzMiwxLjgzMywyLjk2LDQuMzUyLDIuOTYxLDcuMTQ3QzI2LjEwNiwxOC43OTUsMjQuOTc5LDIxLjMxNCwyMy4xNDYsMjMuMTQ2eiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._zoomout__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._zoomout__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC0xNiwtMTYpIj4KICA8cGF0aCBkPSJNMjEuNzU4LDE0LjgwNEgxMC4yNDFjLTAuNjYsMC0xLjE5NiwwLjUzNS0xLjE5NiwxLjE5NmMwLDAuNjYxLDAuNTM2LDEuMTk2LDEuMTk2LDEuMTk2aDExLjUxNyYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC42NjEsMCwxLjE5Ny0wLjUzNiwx'+\n\t\t\t'LjE5Ny0xLjE5NkMyMi45NTUsMTUuMzM5LDIyLjQxOSwxNC44MDQsMjEuNzU4LDE0LjgwNHogTTE2LDMuNUM5LjA5NiwzLjUsMy41LDkuMDk2LDMuNSwxNiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMCw2LjkwMyw1LjU5NiwxMi40OTksMTIuNSwxMi41YzYuOTAzLTAuMDAxLDEyLjQ5OS01LjU5NywxMi41LTEyLjVDMjguNDk5LDkuMDk2LDIyLjkwMywzLjUsMTYsMy41eiBNMjMuMTQ2LDIzLjE0NiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjLTEuODMyLDEuODMxLTQuMzUyLDIuOTYtNy4xNDYsMi45NnMtNS4zMTQtMS4xMjktNy4xNDYtMi45NkM3LjAyMiwyMS4zMTQsNS44OTQsMTguNzk1LD'+\n\t\t\t'UuODkzLDE2JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjAwMS0yLjc5NSwxLjEyOS01LjMxNCwyLjk2MS03LjE0N2MxLjgzMy0xLjgzMSw0LjM1Mi0yLjk2LDcuMTQ2LTIuOTYxYzIuNzk1LDAuMDAxLDUuMzEzLDEuMTMsNy4xNDYsMi45NjEmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzEuODMyLDEuODMzLDIuOTYsNC4zNTIsMi45NjEsNy4xNDdDMjYuMTA2LDE4Ljc5NSwyNC45NzksMjEuMzE0LDIzLjE0NiwyMy4xNDZ6Ii8+CiA8L2c+CiA8ZyBzdHJva2U9IiMwMDAwMDAiIGZpbGw9IiNGRkZGRkYiIHN0cm9rZS13aWR0aD0iMC4yIiB0cmFuc2Zvcm09InRyYW5zbGF0ZSgxNiwxNikgc2Nh'+\n\t\t\t'bGUoMS4xKSB0cmFuc2xhdGUoLTE2LC0xNikiPgogIDxwYXRoIGQ9Ik0yMS43NTgsMTQuODA0SDEwLjI0MWMtMC42NiwwLTEuMTk2LDAuNTM1LTEuMTk2LDEuMTk2YzAsMC42NjEsMC41MzYsMS4xOTYsMS4xOTYsMS4xOTZoMTEuNTE3JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjY2MSwwLDEuMTk3LTAuNTM2LDEuMTk3LTEuMTk2QzIyLjk1NSwxNS4zMzksMjIuNDE5LDE0LjgwNCwyMS43NTgsMTQuODA0eiBNMTYsMy41QzkuMDk2LDMuNSwzLjUsOS4wOTYsMy41LDE2JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLDYuOTAzLDUuNTk2LDEyLjQ5OSwxMi41LDEyLjVjNi45MDMtMC4wMDEsMT'+\n\t\t\t'IuNDk5LTUuNTk3LDEyLjUtMTIuNUMyOC40OTksOS4wOTYsMjIuOTAzLDMuNSwxNiwzLjV6IE0yMy4xNDYsMjMuMTQ2JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MtMS44MzIsMS44MzEtNC4zNTIsMi45Ni03LjE0NiwyLjk2cy01LjMxNC0xLjEyOS03LjE0Ni0yLjk2QzcuMDIyLDIxLjMxNCw1Ljg5NCwxOC43OTUsNS44OTMsMTYmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzAuMDAxLTIuNzk1LDEuMTI5LTUuMzE0LDIuOTYxLTcuMTQ3YzEuODMzLTEuODMxLDQuMzUyLTIuOTYsNy4xNDYtMi45NjFjMi43OTUsMC4wMDEsNS4zMTMsMS4xMyw3LjE0NiwyLjk2MSYjeGQ7JiN4YTsmI3g5OyYjeDk7'+\n\t\t\t'JiN4OTtjMS44MzIsMS44MzMsMi45Niw0LjM1MiwyLjk2MSw3LjE0N0MyNi4xMDYsMTguNzk1LDI0Ljk3OSwyMS4zMTQsMjMuMTQ2LDIzLjE0NnoiLz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._zoomout__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"zoomout\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 32px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._zoomout.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._zoomout.onmouseover=function (e) {\n\t\t\tme._zoomout__img.style.visibility='hidden';\n\t\t\tme._zoomout__imgo.style.visibility='inherit';\n\t\t\tme.elementMouseOver['zoomout']=true;\n\t\t\tme._tt_zoomout.logicBlock_visible();\n\t\t}\n\t\tme._zoomout.onmouseout=function (e) {\n\t\t\tme._zoomout__img.style.visibility='inherit';\n\t\t\tme._zoomout__imgo.style.visibility='hidden';\n\t\t\tme.elementMouseDown['zoomout']=false;\n\t\t\tme.elementMouseOver['zoomout']=false;\n\t\t\tme._tt_zoomout.logicBlock_visible();\n\t\t}\n\t\tme._zoomout.onmousedown=function (e) {\n\t\t\tme.elementMouseDown['zoomout']=true;\n\t\t}\n\t\tme._zoomout.onmouseup=function (e) {\n\t\t\tme.elementMouseDown['zoomout']=false;\n\t\t}\n\t\tme._zoomout.ontouchend=function (e) {\n\t\t\tme.elementMouseDown['zoomout']=false;\n\t\t\tme.elementMouseOver['zoomout']=false;\n\t\t\tme._tt_zoomout.logicBlock_visible();\n\t\t}\n\t\tme._zoomout.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._tt_zoomout=document.createElement('div');\n\t\tels=me._tt_zoomout__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"tt_zoomout\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='z-index: 100;';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 32px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 100px;';\n\t\ths+='pointer-events:auto;';\n\t\ths+='text-shadow: 1px 1px 4px #000000;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: auto;';\n\t\ths+='height: auto;';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: nowrap;';\n\t\ths+='padding: 0px 1px 0px 1px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=\"Zoom Out\";\n\t\tel.appendChild(els);\n\t\tme._tt_zoomout.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._tt_zoomout.logicBlock_position = function() {\n\t\t\tvar newLogicStatePosition;\n\t\t\tif (\n\t\t\t\t((player.getHasTouch() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStatePosition = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStatePosition = -1;\n\t\t\t}\n\t\t\tif (me._tt_zoomout.ggCurrentLogicStatePosition != newLogicStatePosition) {\n\t\t\t\tme._tt_zoomout.ggCurrentLogicStatePosition = newLogicStatePosition;\n\t\t\t\tme._tt_zoomout.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_zoomout.ggCurrentLogicStatePosition == 0) {\n\t\t\t\t\tthis.ggDx = 0;\n\t\t\t\t\tme._tt_zoomout.style.top='-25px';\n\t\t\t\t\tme._tt_zoomout.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_zoomout.ggDx=0;\n\t\t\t\t\tme._tt_zoomout.style.top='32px';\n\t\t\t\t\tme._tt_zoomout.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_zoomout.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['zoomout'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._tt_zoomout.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._tt_zoomout.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._tt_zoomout.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_zoomout.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._tt_zoomout.style.visibility=(Number(me._tt_zoomout.style.opacity)>0||!me._tt_zoomout.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._tt_zoomout.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_zoomout.style.visibility=\"hidden\";\n\t\t\t\t\tme._tt_zoomout.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_zoomout.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t\tthis.style[domTransition]='left 0';\n\t\t\tthis.ggTextDiv.style.left=((98-this.ggTextDiv.offsetWidth)/2) + 'px';\n\t\t}\n\t\tme._zoomout.appendChild(me._tt_zoomout);\n\t\tme._button_zoom.appendChild(me._zoomout);\n\t\tel=me._zoomin=document.createElement('div');\n\t\tels=me._zoomin__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSI+CiAgPHBhdGggZD0iTTIyLjA2MSwxNC44MDNoLTQuODY0VjkuOTM4YzAtMC42NjEtMC41MzYtMS4xOTctMS4xOTctMS4xOTdjLTAuNjYsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5N3Y0Ljg2NSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtIOS45MzhjLTAuNjYxLDAtMS4xOTYsMC41MzYtMS4xOTYsMS4xOTdjMCwwLjY2LDAuNTM2LDEuMTk2LDEuMTk2LDEuMTk2aDQuODY2'+\n\t\t\t'djQuODY1YzAsMC42NiwwLjUzNiwxLjE5NiwxLjE5NiwxLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC42NjEsMCwxLjE5Ny0wLjUzNiwxLjE5Ny0xLjE5NnYtNC44NjVoNC44NjRjMC42NjEsMCwxLjE5Ni0wLjUzNiwxLjE5Ni0xLjE5NkMyMy4yNTcsMTUuMzM5LDIyLjcyMiwxNC44MDMsMjIuMDYxLDE0LjgwM3omI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7IE0xNiwzLjVDOS4wOTYsMy41LDMuNSw5LjA5NiwzLjUsMTZjMCw2LjkwMyw1LjU5NiwxMi40OTksMTIuNSwxMi41YzYuOTAzLTAuMDAxLDEyLjQ5OS01LjU5NywxMi41LTEyLjUmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7QzI4Lj'+\n\t\t\t'Q5OSw5LjA5NiwyMi45MDMsMy41LDE2LDMuNXogTTIzLjE0NiwyMy4xNDZjLTEuODMyLDEuODMxLTQuMzUyLDIuOTYtNy4xNDYsMi45NnMtNS4zMTQtMS4xMjktNy4xNDYtMi45NiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtDNy4wMjIsMjEuMzE0LDUuODk0LDE4Ljc5NSw1Ljg5MywxNmMwLjAwMS0yLjc5NSwxLjEyOS01LjMxNCwyLjk2MS03LjE0N2MxLjgzMy0xLjgzMSw0LjM1Mi0yLjk2LDcuMTQ2LTIuOTYxJiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MyLjc5NSwwLjAwMSw1LjMxMywxLjEzLDcuMTQ2LDIuOTYxYzEuODMyLDEuODMzLDIuOTYsNC4zNTIsMi45NjEsNy4xNDdDMjYuMTA2LDE4'+\n\t\t\t'Ljc5NSwyNC45NzksMjEuMzE0LDIzLjE0NiwyMy4xNDZ6Ii8+CiA8L2c+CiA8ZyBzdHJva2U9IiMwMDAwMDAiIGZpbGw9IiNGRkZGRkYiIHN0cm9rZS13aWR0aD0iMC4yIj4KICA8cGF0aCBkPSJNMjIuMDYxLDE0LjgwM2gtNC44NjRWOS45MzhjMC0wLjY2MS0wLjUzNi0xLjE5Ny0xLjE5Ny0xLjE5N2MtMC42NiwwLTEuMTk2LDAuNTM2LTEuMTk2LDEuMTk3djQuODY1JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0g5LjkzOGMtMC42NjEsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5N2MwLDAuNjYsMC41MzYsMS4xOTYsMS4xOTYsMS4xOTZoNC44NjZ2NC44NjVjMCwwLjY2LDAuNTM2LDEuMTk2LDEuMT'+\n\t\t\t'k2LDEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjY2MSwwLDEuMTk3LTAuNTM2LDEuMTk3LTEuMTk2di00Ljg2NWg0Ljg2NGMwLjY2MSwwLDEuMTk2LTAuNTM2LDEuMTk2LTEuMTk2QzIzLjI1NywxNS4zMzksMjIuNzIyLDE0LjgwMywyMi4wNjEsMTQuODAzeiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTsgTTE2LDMuNUM5LjA5NiwzLjUsMy41LDkuMDk2LDMuNSwxNmMwLDYuOTAzLDUuNTk2LDEyLjQ5OSwxMi41LDEyLjVjNi45MDMtMC4wMDEsMTIuNDk5LTUuNTk3LDEyLjUtMTIuNSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtDMjguNDk5LDkuMDk2LDIyLjkwMywzLjUsMTYsMy41eiBN'+\n\t\t\t'MjMuMTQ2LDIzLjE0NmMtMS44MzIsMS44MzEtNC4zNTIsMi45Ni03LjE0NiwyLjk2cy01LjMxNC0xLjEyOS03LjE0Ni0yLjk2JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0M3LjAyMiwyMS4zMTQsNS44OTQsMTguNzk1LDUuODkzLDE2YzAuMDAxLTIuNzk1LDEuMTI5LTUuMzE0LDIuOTYxLTcuMTQ3YzEuODMzLTEuODMxLDQuMzUyLTIuOTYsNy4xNDYtMi45NjEmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzIuNzk1LDAuMDAxLDUuMzEzLDEuMTMsNy4xNDYsMi45NjFjMS44MzIsMS44MzMsMi45Niw0LjM1MiwyLjk2MSw3LjE0N0MyNi4xMDYsMTguNzk1LDI0Ljk3OSwyMS4zMTQsMjMuMTQ2LDIzLj'+\n\t\t\t'E0NnoiLz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._zoomin__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._zoomin__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+Cjxzdmcgd2lkdGg9IjMycHgiIHZlcnNpb249IjEuMSIgeD0iMHB4IiB2aWV3Qm94PSIwIDAgMzIgMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeT0iMHB4IiB4bWw6c3BhY2U9InByZXNlcnZlIiBiYXNlUHJvZmlsZT0iYmFzaW'+\n\t\t\t'MiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBpZD0iTGF5ZXJfMSIgaGVpZ2h0PSIzMnB4Ij4KIDxnIHN0cm9rZT0iIzNDM0MzQyIgb3BhY2l0eT0iMC40IiBzdHJva2Utd2lkdGg9IjEuNSIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC0xNiwtMTYpIj4KICA8cGF0aCBkPSJNMjIuMDYxLDE0LjgwM2gtNC44NjRWOS45MzhjMC0wLjY2MS0wLjUzNi0xLjE5Ny0xLjE5Ny0xLjE5N2MtMC42NiwwLTEuMTk2LDAuNTM2LTEuMTk2LDEuMTk3djQuODY1JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0g5LjkzOGMtMC42NjEsMC0x'+\n\t\t\t'LjE5NiwwLjUzNi0xLjE5NiwxLjE5N2MwLDAuNjYsMC41MzYsMS4xOTYsMS4xOTYsMS4xOTZoNC44NjZ2NC44NjVjMCwwLjY2LDAuNTM2LDEuMTk2LDEuMTk2LDEuMTk2JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O2MwLjY2MSwwLDEuMTk3LTAuNTM2LDEuMTk3LTEuMTk2di00Ljg2NWg0Ljg2NGMwLjY2MSwwLDEuMTk2LTAuNTM2LDEuMTk2LTEuMTk2QzIzLjI1NywxNS4zMzksMjIuNzIyLDE0LjgwMywyMi4wNjEsMTQuODAzeiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTsgTTE2LDMuNUM5LjA5NiwzLjUsMy41LDkuMDk2LDMuNSwxNmMwLDYuOTAzLDUuNTk2LDEyLjQ5OSwxMi41LDEyLjVjNi45MD'+\n\t\t\t'MtMC4wMDEsMTIuNDk5LTUuNTk3LDEyLjUtMTIuNSYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtDMjguNDk5LDkuMDk2LDIyLjkwMywzLjUsMTYsMy41eiBNMjMuMTQ2LDIzLjE0NmMtMS44MzIsMS44MzEtNC4zNTIsMi45Ni03LjE0NiwyLjk2cy01LjMxNC0xLjEyOS03LjE0Ni0yLjk2JiN4ZDsmI3hhOyYjeDk7JiN4OTsmI3g5O0M3LjAyMiwyMS4zMTQsNS44OTQsMTguNzk1LDUuODkzLDE2YzAuMDAxLTIuNzk1LDEuMTI5LTUuMzE0LDIuOTYxLTcuMTQ3YzEuODMzLTEuODMxLDQuMzUyLTIuOTYsNy4xNDYtMi45NjEmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7YzIuNzk1LDAuMDAxLDUuMzEzLDEu'+\n\t\t\t'MTMsNy4xNDYsMi45NjFjMS44MzIsMS44MzMsMi45Niw0LjM1MiwyLjk2MSw3LjE0N0MyNi4xMDYsMTguNzk1LDI0Ljk3OSwyMS4zMTQsMjMuMTQ2LDIzLjE0NnoiLz4KIDwvZz4KIDxnIHN0cm9rZT0iIzAwMDAwMCIgZmlsbD0iI0ZGRkZGRiIgc3Ryb2tlLXdpZHRoPSIwLjIiIHRyYW5zZm9ybT0idHJhbnNsYXRlKDE2LDE2KSBzY2FsZSgxLjEpIHRyYW5zbGF0ZSgtMTYsLTE2KSI+CiAgPHBhdGggZD0iTTIyLjA2MSwxNC44MDNoLTQuODY0VjkuOTM4YzAtMC42NjEtMC41MzYtMS4xOTctMS4xOTctMS4xOTdjLTAuNjYsMC0xLjE5NiwwLjUzNi0xLjE5NiwxLjE5N3Y0Ljg2NSYjeGQ7JiN4YTsmI3'+\n\t\t\t'g5OyYjeDk7JiN4OTtIOS45MzhjLTAuNjYxLDAtMS4xOTYsMC41MzYtMS4xOTYsMS4xOTdjMCwwLjY2LDAuNTM2LDEuMTk2LDEuMTk2LDEuMTk2aDQuODY2djQuODY1YzAsMC42NiwwLjUzNiwxLjE5NiwxLjE5NiwxLjE5NiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtjMC42NjEsMCwxLjE5Ny0wLjUzNiwxLjE5Ny0xLjE5NnYtNC44NjVoNC44NjRjMC42NjEsMCwxLjE5Ni0wLjUzNiwxLjE5Ni0xLjE5NkMyMy4yNTcsMTUuMzM5LDIyLjcyMiwxNC44MDMsMjIuMDYxLDE0LjgwM3omI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7IE0xNiwzLjVDOS4wOTYsMy41LDMuNSw5LjA5NiwzLjUsMTZjMCw2Ljkw'+\n\t\t\t'Myw1LjU5NiwxMi40OTksMTIuNSwxMi41YzYuOTAzLTAuMDAxLDEyLjQ5OS01LjU5NywxMi41LTEyLjUmI3hkOyYjeGE7JiN4OTsmI3g5OyYjeDk7QzI4LjQ5OSw5LjA5NiwyMi45MDMsMy41LDE2LDMuNXogTTIzLjE0NiwyMy4xNDZjLTEuODMyLDEuODMxLTQuMzUyLDIuOTYtNy4xNDYsMi45NnMtNS4zMTQtMS4xMjktNy4xNDYtMi45NiYjeGQ7JiN4YTsmI3g5OyYjeDk7JiN4OTtDNy4wMjIsMjEuMzE0LDUuODk0LDE4Ljc5NSw1Ljg5MywxNmMwLjAwMS0yLjc5NSwxLjEyOS01LjMxNCwyLjk2MS03LjE0N2MxLjgzMy0xLjgzMSw0LjM1Mi0yLjk2LDcuMTQ2LTIuOTYxJiN4ZDsmI3hhOyYjeDk7Ji'+\n\t\t\t'N4OTsmI3g5O2MyLjc5NSwwLjAwMSw1LjMxMywxLjEzLDcuMTQ2LDIuOTYxYzEuODMyLDEuODMzLDIuOTYsNC4zNTIsMi45NjEsNy4xNDdDMjYuMTA2LDE4Ljc5NSwyNC45NzksMjEuMzE0LDIzLjE0NiwyMy4xNDZ6Ii8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._zoomin__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"zoomin\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._zoomin.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._zoomin.onmouseover=function (e) {\n\t\t\tme._zoomin__img.style.visibility='hidden';\n\t\t\tme._zoomin__imgo.style.visibility='inherit';\n\t\t\tme.elementMouseOver['zoomin']=true;\n\t\t\tme._tt_zoomin.logicBlock_visible();\n\t\t}\n\t\tme._zoomin.onmouseout=function (e) {\n\t\t\tme._zoomin__img.style.visibility='inherit';\n\t\t\tme._zoomin__imgo.style.visibility='hidden';\n\t\t\tme.elementMouseDown['zoomin']=false;\n\t\t\tme.elementMouseOver['zoomin']=false;\n\t\t\tme._tt_zoomin.logicBlock_visible();\n\t\t}\n\t\tme._zoomin.onmousedown=function (e) {\n\t\t\tme.elementMouseDown['zoomin']=true;\n\t\t}\n\t\tme._zoomin.onmouseup=function (e) {\n\t\t\tme.elementMouseDown['zoomin']=false;\n\t\t}\n\t\tme._zoomin.ontouchend=function (e) {\n\t\t\tme.elementMouseDown['zoomin']=false;\n\t\t\tme.elementMouseOver['zoomin']=false;\n\t\t\tme._tt_zoomin.logicBlock_visible();\n\t\t}\n\t\tme._zoomin.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._tt_zoomin=document.createElement('div');\n\t\tels=me._tt_zoomin__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"tt_zoomin\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='z-index: 100;';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 32px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 100px;';\n\t\ths+='pointer-events:auto;';\n\t\ths+='text-shadow: 1px 1px 4px #000000;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: auto;';\n\t\ths+='height: auto;';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: nowrap;';\n\t\ths+='padding: 0px 1px 0px 1px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=\"Zoom In\";\n\t\tel.appendChild(els);\n\t\tme._tt_zoomin.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._tt_zoomin.logicBlock_position = function() {\n\t\t\tvar newLogicStatePosition;\n\t\t\tif (\n\t\t\t\t((player.getHasTouch() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStatePosition = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStatePosition = -1;\n\t\t\t}\n\t\t\tif (me._tt_zoomin.ggCurrentLogicStatePosition != newLogicStatePosition) {\n\t\t\t\tme._tt_zoomin.ggCurrentLogicStatePosition = newLogicStatePosition;\n\t\t\t\tme._tt_zoomin.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_zoomin.ggCurrentLogicStatePosition == 0) {\n\t\t\t\t\tthis.ggDx = 0;\n\t\t\t\t\tme._tt_zoomin.style.top='-25px';\n\t\t\t\t\tme._tt_zoomin.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_zoomin.ggDx=0;\n\t\t\t\t\tme._tt_zoomin.style.top='32px';\n\t\t\t\t\tme._tt_zoomin.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_zoomin.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['zoomin'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._tt_zoomin.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._tt_zoomin.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._tt_zoomin.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_zoomin.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._tt_zoomin.style.visibility=(Number(me._tt_zoomin.style.opacity)>0||!me._tt_zoomin.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._tt_zoomin.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_zoomin.style.visibility=\"hidden\";\n\t\t\t\t\tme._tt_zoomin.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_zoomin.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t\tthis.style[domTransition]='left 0';\n\t\t\tthis.ggTextDiv.style.left=((98-this.ggTextDiv.offsetWidth)/2) + 'px';\n\t\t}\n\t\tme._zoomin.appendChild(me._tt_zoomin);\n\t\tme._button_zoom.appendChild(me._zoomin);\n\t\tme._container_1.appendChild(me._button_zoom);\n\t\tme.divSkin.appendChild(me._container_1);\n\t\tplayer.addListener('sizechanged', function() {\n\t\t\tme.updateSize(me.divSkin);\n\t\t});\n\t};\n\tthis.hotspotProxyClick=function(id, url) {\n\t}\n\tthis.hotspotProxyDoubleClick=function(id, url) {\n\t}\n\tme.hotspotProxyOver=function(id, url) {\n\t}\n\tme.hotspotProxyOut=function(id, url) {\n\t}\n\tme.callChildLogicBlocksHotspot_hotspot_1_changenode = function(){\n\t\tif(hotspotTemplates['Hotspot 1']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['Hotspot 1'].length; i++) {\n\t\t\t\tif (hotspotTemplates['Hotspot 1'][i]._rectangle_1 && hotspotTemplates['Hotspot 1'][i]._rectangle_1.logicBlock_scaling) {\n\t\t\t\t\thotspotTemplates['Hotspot 1'][i]._rectangle_1.logicBlock_scaling();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['Hotspot 1'][i]._rectangle_1 && hotspotTemplates['Hotspot 1'][i]._rectangle_1.logicBlock_alpha) {\n\t\t\t\t\thotspotTemplates['Hotspot 1'][i]._rectangle_1.logicBlock_alpha();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_hotspot_1_varchanged_ht_ani = function(){\n\t\tif(hotspotTemplates['Hotspot 1']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['Hotspot 1'].length; i++) {\n\t\t\t\tif (hotspotTemplates['Hotspot 1'][i]._rectangle_1 && hotspotTemplates['Hotspot 1'][i]._rectangle_1.logicBlock_scaling) {\n\t\t\t\t\thotspotTemplates['Hotspot 1'][i]._rectangle_1.logicBlock_scaling();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['Hotspot 1'][i]._rectangle_1 && hotspotTemplates['Hotspot 1'][i]._rectangle_1.logicBlock_alpha) {\n\t\t\t\t\thotspotTemplates['Hotspot 1'][i]._rectangle_1.logicBlock_alpha();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tplayer.addListener('changenode', function() {\n\t\tme.ggUserdata=player.userdata;\n\t});\n\tme.skinTimerEvent=function() {\n\t\tme.ggCurrentTime=new Date().getTime();\n\t\tif (me._timer_1.ggLastIsActive!=me._timer_1.ggIsActive()) {\n\t\t\tme._timer_1.ggLastIsActive=me._timer_1.ggIsActive();\n\t\t\tif (me._timer_1.ggLastIsActive) {\n\t\t\t\tplayer.setVariableValue('ht_ani', true);\n\t\t\t} else {\n\t\t\t\tplayer.setVariableValue('ht_ani', false);\n\t\t\t}\n\t\t}\n\t\tif (me.elementMouseDown['button_image_right']) {\n\t\t\tplayer.changePanLog(-1,true);\n\t\t}\n\t\tif (me.elementMouseDown['button_image_left']) {\n\t\t\tplayer.changePanLog(1,true);\n\t\t}\n\t\tif (me.elementMouseDown['button_image_down']) {\n\t\t\tplayer.changeTiltLog(-1,true);\n\t\t}\n\t\tif (me.elementMouseDown['button_image_up']) {\n\t\t\tplayer.changeTiltLog(1,true);\n\t\t}\n\t\tif (me.elementMouseDown['zoomout']) {\n\t\t\tplayer.changeFovLog(0.5,true);\n\t\t}\n\t\tif (me.elementMouseDown['zoomin']) {\n\t\t\tplayer.changeFovLog(-0.5,true);\n\t\t}\n\t\tif (!player.getLockedKeyboard()) {\n\t\t\tswitch(me.skinKeyPressed) {\n\t\t\t\tcase 37:\n\t\t\t\t\tplayer.changePanLog(1,true);\n\t\t\t\t\tbreak;\n\t\t\t\tcase 38:\n\t\t\t\t\tplayer.changeTiltLog(1,true);\n\t\t\t\t\tbreak;\n\t\t\t\tcase 39:\n\t\t\t\t\tplayer.changePanLog(-1,true);\n\t\t\t\t\tbreak;\n\t\t\t\tcase 40:\n\t\t\t\t\tplayer.changeTiltLog(-1,true);\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t};\n\tplayer.addListener('timer', me.skinTimerEvent);\n\tfunction SkinHotspotClass_hotspot_1(parentScope,hotspot) {\n\t\tvar me=this;\n\t\tvar flag=false;\n\t\tvar hs='';\n\t\tme.parentScope=parentScope;\n\t\tme.hotspot=hotspot;\n\t\tvar nodeId=String(hotspot.url);\n\t\tnodeId=(nodeId.charAt(0)=='{')?nodeId.substr(1, nodeId.length - 2):''; // }\n\t\tme.ggUserdata=skin.player.getNodeUserdata(nodeId);\n\t\tme.elementMouseDown=[];\n\t\tme.elementMouseOver=[];\n\t\tme.findElements=function(id,regex) {\n\t\t\treturn skin.findElements(id,regex);\n\t\t}\n\t\tel=me._hotspot_1=document.createElement('div');\n\t\tel.ggId=\"Hotspot 1\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_hotspot \";\n\t\tel.ggType='hotspot';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 0px;';\n\t\ths+='left : 312px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 221px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 0px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._hotspot_1.ggIsActive=function() {\n\t\t\treturn player.getCurrentNode()==this.ggElementNodeId();\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif (me.hotspot.url!='' && me.hotspot.url.charAt(0)=='{') { // }\n\t\t\t\treturn me.hotspot.url.substr(1, me.hotspot.url.length - 2);\n\t\t\t} else {\n\t\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t\t} else {\n\t\t\t\t\treturn player.getCurrentNode();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._hotspot_1.onclick=function (e) {\n\t\t\tplayer.openNext(me.hotspot.url,me.hotspot.target);\n\t\t\tskin.hotspotProxyClick(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._hotspot_1.ondblclick=function (e) {\n\t\t\tskin.hotspotProxyDoubleClick(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._hotspot_1.onmouseover=function (e) {\n\t\t\tplayer.setActiveHotspot(me.hotspot);\n\t\t\tskin.hotspotProxyOver(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._hotspot_1.onmouseout=function (e) {\n\t\t\tplayer.setActiveHotspot(null);\n\t\t\tskin.hotspotProxyOut(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._hotspot_1.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._ht_ani=document.createElement('div');\n\t\tel.ggId=\"ht_ani\";\n\t\tel.ggDx=-295;\n\t\tel.ggDy=-204;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_ani.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_ani.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=(this.ggDy + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._rectangle_1=document.createElement('div');\n\t\tel.ggId=\"Rectangle 1\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:0.5,sy:0.5 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_rectangle \";\n\t\tel.ggType='rectangle';\n\t\ths ='';\n\t\ths+=cssPrefix + 'border-radius : 999px;';\n\t\ths+='border-radius : 999px;';\n\t\ths+='border : 3px solid #ffffff;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 60px;';\n\t\ths+='left : 286px;';\n\t\ths+='opacity : 0;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 194px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 60px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tel.style[domTransform]=parameterToTransform(el.ggParameter);\n\t\tme._rectangle_1.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._rectangle_1.logicBlock_scaling = function() {\n\t\t\tvar newLogicStateScaling;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('ht_ani') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateScaling = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateScaling = -1;\n\t\t\t}\n\t\t\tif (me._rectangle_1.ggCurrentLogicStateScaling != newLogicStateScaling) {\n\t\t\t\tme._rectangle_1.ggCurrentLogicStateScaling = newLogicStateScaling;\n\t\t\t\tme._rectangle_1.style[domTransition]='' + cssPrefix + 'transform 1000ms ease 0ms, opacity 1000ms ease 0ms';\n\t\t\t\tif (me._rectangle_1.ggCurrentLogicStateScaling == 0) {\n\t\t\t\t\tme._rectangle_1.ggParameter.sx = 1;\n\t\t\t\t\tme._rectangle_1.ggParameter.sy = 1;\n\t\t\t\t\tme._rectangle_1.style[domTransform]=parameterToTransform(me._rectangle_1.ggParameter);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._rectangle_1.ggParameter.sx = 0.5;\n\t\t\t\t\tme._rectangle_1.ggParameter.sy = 0.5;\n\t\t\t\t\tme._rectangle_1.style[domTransform]=parameterToTransform(me._rectangle_1.ggParameter);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._rectangle_1.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('ht_ani') == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._rectangle_1.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._rectangle_1.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._rectangle_1.style[domTransition]='' + cssPrefix + 'transform 1000ms ease 0ms, opacity 1000ms ease 0ms';\n\t\t\t\tif (me._rectangle_1.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tme._rectangle_1.style.visibility=me._rectangle_1.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._rectangle_1.style.opacity=1;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tsetTimeout(function() { if (me._rectangle_1.style.opacity == 0.0) { me._rectangle_1.style.visibility=\"hidden\"; } }, 1005);\n\t\t\t\t\tme._rectangle_1.style.opacity=0;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._rectangle_1.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._ht_ani.appendChild(me._rectangle_1);\n\t\tme._hotspot_1.appendChild(me._ht_ani);\n\t\tme.__div = me._hotspot_1;\n\t};\n\tme.addSkinHotspot=function(hotspot) {\n\t\tvar hsinst = null;\n\t\t{\n\t\t\thotspot.skinid = 'Hotspot 1';\n\t\t\thsinst = new SkinHotspotClass_hotspot_1(me, hotspot);\n\t\t\tif (!hotspotTemplates.hasOwnProperty(hotspot.skinid)) {\n\t\t\t\thotspotTemplates[hotspot.skinid] = [];\n\t\t\t}\n\t\t\thotspotTemplates[hotspot.skinid].push(hsinst);\n\t\t\tme.callChildLogicBlocksHotspot_hotspot_1_changenode();;\n\t\t\tme.callChildLogicBlocksHotspot_hotspot_1_varchanged_ht_ani();;\n\t\t}\n\t\treturn hsinst;\n\t}\n\tme.removeSkinHotspots=function() {\n\t\tif(hotspotTemplates['Hotspot 1']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['Hotspot 1'].length; i++) {\n\t\t\t\thotspotTemplates['Hotspot 1'][i] = null;\n\t\t\t}\n\t\t}\n\t\thotspotTemplates = [];\n\t}\n\tme.addSkin();\n\tvar style = document.createElement('style');\n\tstyle.type = 'text/css';\n\tstyle.appendChild(document.createTextNode('.ggskin { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 14px;}'));\n\tdocument.head.appendChild(style);\n\tme._button_image_normalscreen.logicBlock_visible();\n\tme._button_image_fullscreen.logicBlock_visible();\n\tme._tt_fullscreen.logicBlock_text();\n\tme._gyro_on.logicBlock_alpha();\n\tme._gyro_off.logicBlock_alpha();\n\tme._tt_gyro.logicBlock_text();\n\tme._stop_rotate_image.logicBlock_visible();\n\tme._start_rotate_image.logicBlock_visible();\n\tme._tt_rotate_start.logicBlock_text();\n\tme._tt_fullscreen.logicBlock_position();\n\tme._tt_gyro.logicBlock_position();\n\tme._tt_rotate_start.logicBlock_position();\n\tme._tt_zoomout.logicBlock_position();\n\tme._tt_zoomin.logicBlock_position();\n\tplayer.addListener('fullscreenenter', function(args) { me._button_image_normalscreen.logicBlock_visible();me._button_image_fullscreen.logicBlock_visible();me._tt_fullscreen.logicBlock_text(); });\n\tplayer.addListener('fullscreenexit', function(args) { me._button_image_normalscreen.logicBlock_visible();me._button_image_fullscreen.logicBlock_visible();me._tt_fullscreen.logicBlock_text(); });\n\tplayer.addListener('changenode', function(args) { me._gyro_on.logicBlock_alpha();me._gyro_off.logicBlock_alpha();me._tt_gyro.logicBlock_text();me._stop_rotate_image.logicBlock_visible();me._start_rotate_image.logicBlock_visible();me._tt_rotate_start.logicBlock_text(); });\n\tplayer.addListener('configloaded', function(args) { me._tt_fullscreen.logicBlock_position();me._tt_gyro.logicBlock_position();me._tt_rotate_start.logicBlock_position();me._tt_zoomout.logicBlock_position();me._tt_zoomin.logicBlock_position(); });\n\tplayer.addListener('autorotatechanged', function(args) { me._stop_rotate_image.logicBlock_visible();me._start_rotate_image.logicBlock_visible();me._tt_rotate_start.logicBlock_text(); });\n\tplayer.addListener('gyrochanged', function(args) { me._gyro_on.logicBlock_alpha();me._gyro_off.logicBlock_alpha();me._tt_gyro.logicBlock_text(); });\n\tplayer.addListener('hastouch', function(args) { me._tt_fullscreen.logicBlock_position();me._tt_gyro.logicBlock_position();me._tt_rotate_start.logicBlock_position();me._tt_zoomout.logicBlock_position();me._tt_zoomin.logicBlock_position(); });\n\tplayer.addListener('changenode', function(args) { me.callChildLogicBlocksHotspot_hotspot_1_changenode(); });\n\tplayer.addListener('varchanged_ht_ani', function(args) { me.callChildLogicBlocksHotspot_hotspot_1_varchanged_ht_ani(); });\n\tplayer.addListener('hotspotsremoved', function(args) { me.removeSkinHotspots(); });\n\tdocument.addEventListener('keydown', function(e) {\n\t\tvar key = e.which || e.keyCode;\n\t\tme.skinKeyPressed = key;\n\t});\n\tdocument.addEventListener('keyup', function(e) {\n\t\tvar key = e.which || e.keyCode;\n\t\tme.skinKeyPressed = 0;\n\t});\n\tme.skinTimerEvent();\n}", "function initPageFx() {\n $('.animsition').animsition({\n inClass: 'fade-in-up-sm',\n outClass: 'fade-out-down-sm',\n inDuration: 800,\n outDuration: 800,\n linkElement: '',\n loading: true,\n loadingParentElement: 'body', //animsition wrapper element\n loadingClass: 'loadSpinner',\n unSupportCss: [\n 'animation-duration',\n '-webkit-animation-duration',\n '-o-animation-duration'\n ],\n overlay : false,\n overlayClass : 'animsition-overlay-slide',\n overlayParentElement : 'body'\n });\n }", "function addScript() {\n var script = document.createElement(\"script\");\n script.type = \"text/javascript\";\n script.src = \"./project/Work_2DCharacterShading/work-theme.js\";\n document.getElementsByTagName(\"head\")[0].appendChild(script);\n}", "function preload() {\n bg = loadImage(\"addons/woodgrain.jpg\");\n myFont = loadFont(\"addons/Rye/Rye-Regular.ttf\");\n qFont = loadFont(\"addons/Indie_Flower/IndieFlower.ttf\");\n}", "function scene(param)\n{\n novel_changeBackground(param, true);\n}", "function initAnimation() {\n}", "function setBg(hour) {\n document.body.style.backgroundImage = `url(${bgArray[hour]})`;\n}", "function pano2vrSkin(player,base) {\n\tplayer.addVariable('appear', 2, false);\n\tplayer.addVariable('open_tag', 0, \"\");\n\tplayer.addVariable('close_nodes', 2, false);\n\tplayer.addVariable('category_visible', 2, false);\n\tplayer.addVariable('category_follow', 2, true);\n\tplayer.addVariable('vis_map', 2, true);\n\tplayer.addVariable('vis_map_close_desktop', 2, true);\n\tplayer.addVariable('vis_map_close_mobile', 2, true);\n\tplayer.addVariable('opt_hotspot_preview', 2, true);\n\tplayer.addVariable('opt_hotspot_preview_1', 2, true);\n\tvar me=this;\n\tvar skin=this;\n\tvar flag=false;\n\tvar hotspotTemplates={};\n\tvar skinKeyPressed = 0;\n\tthis.player=player;\n\tthis.player.skinObj=this;\n\tthis.divSkin=player.divSkin;\n\tthis.ggUserdata=player.userdata;\n\tthis.lastSize={ w: -1,h: -1 };\n\tvar basePath=\"\";\n\t// auto detect base path\n\tif (base=='?') {\n\t\tvar scripts = document.getElementsByTagName('script');\n\t\tfor(var i=0;i<scripts.length;i++) {\n\t\t\tvar src=scripts[i].src;\n\t\t\tif (src.indexOf('skin.js')>=0) {\n\t\t\t\tvar p=src.lastIndexOf('/');\n\t\t\t\tif (p>=0) {\n\t\t\t\t\tbasePath=src.substr(0,p+1);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t} else\n\tif (base) {\n\t\tbasePath=base;\n\t}\n\tthis.elementMouseDown=[];\n\tthis.elementMouseOver=[];\n\tvar cssPrefix='';\n\tvar domTransition='transition';\n\tvar domTransform='transform';\n\tvar prefixes='Webkit,Moz,O,ms,Ms'.split(',');\n\tvar i;\n\tvar hs,el,els,elo,ela,elHorScrollFg,elHorScrollBg,elVertScrollFg,elVertScrollBg,elCornerBg;\n\tif (typeof document.body.style['transform'] == 'undefined') {\n\t\tfor(var i=0;i<prefixes.length;i++) {\n\t\t\tif (typeof document.body.style[prefixes[i] + 'Transform'] !== 'undefined') {\n\t\t\t\tcssPrefix='-' + prefixes[i].toLowerCase() + '-';\n\t\t\t\tdomTransition=prefixes[i] + 'Transition';\n\t\t\t\tdomTransform=prefixes[i] + 'Transform';\n\t\t\t}\n\t\t}\n\t}\n\t\n\tplayer.setMargins(0,0,0,0);\n\t\n\tthis.updateSize=function(startElement) {\n\t\tvar stack=[];\n\t\tstack.push(startElement);\n\t\twhile(stack.length>0) {\n\t\t\tvar e=stack.pop();\n\t\t\tif (e.ggUpdatePosition) {\n\t\t\t\te.ggUpdatePosition();\n\t\t\t}\n\t\t\tif (e.hasChildNodes()) {\n\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\t\n\tthis.callNodeChange=function(startElement) {\n\t\tvar stack=[];\n\t\tstack.push(startElement);\n\t\twhile(stack.length>0) {\n\t\t\tvar e=stack.pop();\n\t\t\tif (e.ggNodeChange) {\n\t\t\t\te.ggNodeChange();\n\t\t\t}\n\t\t\tif (e.hasChildNodes()) {\n\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tplayer.addListener('changenode', function() { me.ggUserdata=player.userdata; me.callNodeChange(me.divSkin); });\n\t\n\tvar parameterToTransform=function(p) {\n\t\tvar hs='translate(' + p.rx + 'px,' + p.ry + 'px) rotate(' + p.a + 'deg) scale(' + p.sx + ',' + p.sy + ')';\n\t\treturn hs;\n\t}\n\t\n\tthis.findElements=function(id,regex) {\n\t\tvar r=[];\n\t\tvar stack=[];\n\t\tvar pat=new RegExp(id,'');\n\t\tstack.push(me.divSkin);\n\t\twhile(stack.length>0) {\n\t\t\tvar e=stack.pop();\n\t\t\tif (regex) {\n\t\t\t\tif (pat.test(e.ggId)) r.push(e);\n\t\t\t} else {\n\t\t\t\tif (e.ggId==id) r.push(e);\n\t\t\t}\n\t\t\tif (e.hasChildNodes()) {\n\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn r;\n\t}\n\t\n\tthis.addSkin=function() {\n\t\tvar hs='';\n\t\tthis.ggCurrentTime=new Date().getTime();\n\t\tel=me._menu_background=document.createElement('div');\n\t\tel.ggId=\"menu_background\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_rectangle \";\n\t\tel.ggType='rectangle';\n\t\ths ='';\n\t\ths+='background : rgba(0,0,0,0.501961);';\n\t\ths+='border : 1px solid #000000;';\n\t\ths+='cursor : default;';\n\t\ths+='height : 100%;';\n\t\ths+='position : absolute;';\n\t\ths+='right : 0px;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 178px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._menu_background.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._menu_background.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('category_visible') == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._menu_background.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._menu_background.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._menu_background.style[domTransition]='opacity 500ms ease 0ms';\n\t\t\t\tif (me._menu_background.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tsetTimeout(function() { if (me._menu_background.style.opacity == 0.0) { me._menu_background.style.visibility=\"hidden\"; } }, 505);\n\t\t\t\t\tme._menu_background.style.opacity=0;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._menu_background.style.visibility=me._menu_background.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._menu_background.style.opacity=1;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._menu_background.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._category_scroller=document.createElement('div');\n\t\tels=me._category_scroller__content=document.createElement('div');\n\t\tels.className='ggskin ggskin_subelement ggskin_scrollarea';\n\t\tel.ggContent=els;\n\t\tel.appendChild(els);\n\t\tel.ggHorScrollVisible = false;\n\t\tel.ggVertScrollVisible = false;\n\t\tel.ggContentLeftOffset = 0;\n\t\tel.ggContentTopOffset = 0;\n\t\tel.ggDragInertiaX = 0;\n\t\tel.ggDragInertiaY = 0;\n\t\tel.ggVPercentVisible = 1.0;\n\t\tel.ggHPercentVisible = 1.0;\n\t\ths ='';\n\t\ths+='height : 134px;';\n\t\ths+='left : 0px;';\n\t\ths+='overflow : visible;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='width : 154px;';\n\t\ths+=\"\";\n\t\tels.setAttribute('style',hs);\n\t\tme._category_scroller.ggScrollByX = function(diffX) {\n\t\t\tif(!me._category_scroller.ggHorScrollVisible || diffX == 0 || me._category_scroller.ggHPercentVisible >= 1.0) return;\n\t\t\tme._category_scroller.ggScrollPosX = (me._category_scroller__horScrollFg.offsetLeft + diffX);\n\t\t\tme._category_scroller.ggScrollPosX = Math.max(me._category_scroller.ggScrollPosX, 0);\n\t\t\tme._category_scroller.ggScrollPosX = Math.min(me._category_scroller.ggScrollPosX, me._category_scroller__horScrollBg.offsetWidth - me._category_scroller__horScrollFg.offsetWidth);\n\t\t\tme._category_scroller__horScrollFg.style.left = me._category_scroller.ggScrollPosX + 'px';\n\t\t\tme._category_scroller__content.style.left = -(Math.round(me._category_scroller.ggScrollPosX / me._category_scroller.ggHPercentVisible)) + me._category_scroller.ggContentLeftOffset + 'px';\n\t\t\tme._category_scroller.ggScrollPosXPercent = (me._category_scroller__horScrollFg.offsetLeft / me._category_scroller__horScrollBg.offsetWidth);\n\t\t}\n\t\tme._category_scroller.ggScrollByXSmooth = function(diffX) {\n\t\t\tif(!me._category_scroller.ggHorScrollVisible || diffX == 0 || me._category_scroller.ggHPercentVisible >= 1.0) return;\n\t\t\tvar scrollPerInterval = diffX / 25;\n\t\t\tvar scrollCurrX = 0;\n\t\t\tvar id = setInterval(function() {\n\t\t\t\tscrollCurrX += scrollPerInterval;\n\t\t\t\tme._category_scroller.ggScrollPosX += scrollPerInterval;\n\t\t\t\tif (diffX > 0 && (scrollCurrX >= diffX || me._category_scroller.ggScrollPosX >= me._category_scroller__horScrollBg.offsetWidth - me._category_scroller__horScrollFg.offsetWidth)) {\n\t\t\t\t\tme._category_scroller.ggScrollPosX = Math.min(me._category_scroller.ggScrollPosX, me._category_scroller__horScrollBg.offsetWidth - me._category_scroller__horScrollFg.offsetWidth);\n\t\t\t\t\tclearInterval(id);\n\t\t\t\t}\n\t\t\t\tif (diffX < 0 && (scrollCurrX <= diffX || me._category_scroller.ggScrollPosX <= 0)) {\n\t\t\t\t\tme._category_scroller.ggScrollPosX = Math.max(me._category_scroller.ggScrollPosX, 0);\n\t\t\t\t\tclearInterval(id);\n\t\t\t\t}\n\t\t\tme._category_scroller__horScrollFg.style.left = me._category_scroller.ggScrollPosX + 'px';\n\t\t\tme._category_scroller__content.style.left = -(Math.round(me._category_scroller.ggScrollPosX / me._category_scroller.ggHPercentVisible)) + me._category_scroller.ggContentLeftOffset + 'px';\n\t\t\tme._category_scroller.ggScrollPosXPercent = (me._category_scroller__horScrollFg.offsetLeft / me._category_scroller__horScrollBg.offsetWidth);\n\t\t\t}, 10);\n\t\t}\n\t\tme._category_scroller.ggScrollByY = function(diffY) {\n\t\t\tif(!me._category_scroller.ggVertScrollVisible || diffY == 0 || me._category_scroller.ggVPercentVisible >= 1.0) return;\n\t\t\tme._category_scroller.ggScrollPosY = (me._category_scroller__vertScrollFg.offsetTop + diffY);\n\t\t\tme._category_scroller.ggScrollPosY = Math.max(me._category_scroller.ggScrollPosY, 0);\n\t\t\tme._category_scroller.ggScrollPosY = Math.min(me._category_scroller.ggScrollPosY, me._category_scroller__vertScrollBg.offsetHeight - me._category_scroller__vertScrollFg.offsetHeight);\n\t\t\tme._category_scroller__vertScrollFg.style.top = me._category_scroller.ggScrollPosY + 'px';\n\t\t\tme._category_scroller__content.style.top = -(Math.round(me._category_scroller.ggScrollPosY / me._category_scroller.ggVPercentVisible)) + me._category_scroller.ggContentTopOffset + 'px';\n\t\t\tme._category_scroller.ggScrollPosYPercent = (me._category_scroller__vertScrollFg.offsetTop / me._category_scroller__vertScrollBg.offsetHeight);\n\t\t}\n\t\tme._category_scroller.ggScrollByYSmooth = function(diffY) {\n\t\t\tif(!me._category_scroller.ggVertScrollVisible || diffY == 0 || me._category_scroller.ggVPercentVisible >= 1.0) return;\n\t\t\tvar scrollPerInterval = diffY / 25;\n\t\t\tvar scrollCurrY = 0;\n\t\t\tvar id = setInterval(function() {\n\t\t\t\tscrollCurrY += scrollPerInterval;\n\t\t\t\tme._category_scroller.ggScrollPosY += scrollPerInterval;\n\t\t\t\tif (diffY > 0 && (scrollCurrY >= diffY || me._category_scroller.ggScrollPosY >= me._category_scroller__vertScrollBg.offsetHeight - me._category_scroller__vertScrollFg.offsetHeight)) {\n\t\t\t\t\tme._category_scroller.ggScrollPosY = Math.min(me._category_scroller.ggScrollPosY, me._category_scroller__vertScrollBg.offsetHeight - me._category_scroller__vertScrollFg.offsetHeight);\n\t\t\t\t\tclearInterval(id);\n\t\t\t\t}\n\t\t\t\tif (diffY < 0 && (scrollCurrY <= diffY || me._category_scroller.ggScrollPosY <= 0)) {\n\t\t\t\t\tme._category_scroller.ggScrollPosY = Math.max(me._category_scroller.ggScrollPosY, 0);\n\t\t\t\t\tclearInterval(id);\n\t\t\t\t}\n\t\t\tme._category_scroller__vertScrollFg.style.top = me._category_scroller.ggScrollPosY + 'px';\n\t\t\tme._category_scroller__content.style.top = -(Math.round(me._category_scroller.ggScrollPosY / me._category_scroller.ggVPercentVisible)) + me._category_scroller.ggContentTopOffset + 'px';\n\t\t\tme._category_scroller.ggScrollPosYPercent = (me._category_scroller__vertScrollFg.offsetTop / me._category_scroller__vertScrollBg.offsetHeight);\n\t\t\t}, 10);\n\t\t}\n\t\tme._category_scroller.ggScrollIntoView = function(posX, posY, width, height) {\n\t\t\tif (me._category_scroller.ggHorScrollVisible) {\n\t\t\t\tif (posX < 0) {\n\t\t\t\t\tvar diffX = Math.floor(posX * me._category_scroller.ggHPercentVisible);\n\t\t\t\t\tme._category_scroller.ggScrollByXSmooth(diffX);\n\t\t\t\t} else if (posX + width > me._category_scroller.offsetWidth - (me._category_scroller.ggVertScrollVisible ? 15 : 0)) {\n\t\t\t\t\tvar diffX = Math.ceil(((posX + width) - (me._category_scroller.offsetWidth - (me._category_scroller.ggVertScrollVisible ? 15 : 0))) * me._category_scroller.ggHPercentVisible);\n\t\t\t\t\tme._category_scroller.ggScrollByXSmooth(diffX);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (me._category_scroller.ggVertScrollVisible) {\n\t\t\t\tif (posY < 0) {\n\t\t\t\t\tvar diffY = Math.floor(posY * me._category_scroller.ggVPercentVisible);\n\t\t\t\t\tme._category_scroller.ggScrollByYSmooth(diffY);\n\t\t\t\t} else if (posY + height > me._category_scroller.offsetHeight - (me._category_scroller.ggHorScrollVisible ? 15 : 0)) {\n\t\t\t\t\tvar diffY = Math.ceil(((posY + height) - (me._category_scroller.offsetHeight - (me._category_scroller.ggHorScrollVisible ? 15 : 0))) * me._category_scroller.ggVPercentVisible);\n\t\t\t\t\tme._category_scroller.ggScrollByYSmooth(diffY);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tels.ontouchstart = function(e) {\n\t\t\te = e || window.event;\n\t\t\tvar t = e.touches;\n\t\t\tme._category_scroller.ggDragLastX = t ? t[0].clientX : e.clientX;\n\t\t\tme._category_scroller.ggDragLastY = t ? t[0].clientY : e.clientY;\n\t\t\tme._category_scroller__content.ontouchend = function() {\n\t\t\t\tlet inertiaInterval = setInterval(function() {\n\t\t\t\t\tme._category_scroller.ggDragInertiaX *= 0.65;\n\t\t\t\t\tme._category_scroller.ggDragInertiaY *= 0.65;\n\t\t\t\t\tme._category_scroller.ggScrollByX(me._category_scroller.ggDragInertiaX);\n\t\t\t\t\tme._category_scroller.ggScrollByY(me._category_scroller.ggDragInertiaY);\n\t\t\t\t\tif (Math.abs(me._category_scroller.ggDragInertiaX) < 1.0 && Math.abs(me._category_scroller.ggDragInertiaY) < 1.0) {\n\t\t\t\t\t\tclearInterval(inertiaInterval);\n\t\t\t\t\t}\n\t\t\t\t\t}, 50);\n\t\t\t\tme._category_scroller__content.ontouchend = null;\n\t\t\t\tme._category_scroller__content.ontouchmove = null;\n\t\t\t\tme._category_scroller__content.onpointerup = null;\n\t\t\t\tme._category_scroller__content.onpointermove = null;\n\t\t\t}\n\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\tme._category_scroller__content.onpointerup = me._category_scroller__content.ontouchend;\n\t\t}\n\t\t\tme._category_scroller__content.ontouchmove = function(e) {\n\t\t\t\te = e || window.event;\n\t\t\t\te.preventDefault();\n\t\t\t\tvar t = e.touches;\n\t\t\t\tvar diffX = ((t ? t[0].clientX : e.clientX) - me._category_scroller.ggDragLastX) * me._category_scroller.ggHPercentVisible;\n\t\t\t\tvar diffY = ((t ? t[0].clientY : e.clientY) - me._category_scroller.ggDragLastY) * me._category_scroller.ggVPercentVisible;\n\t\t\t\tme._category_scroller.ggDragInertiaX = -diffX;\n\t\t\t\tme._category_scroller.ggDragInertiaY = -diffY;\n\t\t\t\tme._category_scroller.ggDragLastX = t ? t[0].clientX : e.clientX;\n\t\t\t\tme._category_scroller.ggDragLastY = t ? t[0].clientY : e.clientY;\n\t\t\t\tme._category_scroller.ggScrollByX(-diffX);\n\t\t\t\tme._category_scroller.ggScrollByY(-diffY);\n\t\t\t}\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\t\tme._category_scroller__content.onpointermove = me._category_scroller__content.ontouchmove;\n\t\t\t}\n\t\t}\n\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\tels.onpointerdown = els.ontouchstart;\n\t\t}\n\t\telHorScrollBg = me._category_scroller__horScrollBg = document.createElement('div');\n\t\tel.appendChild(elHorScrollBg);\n\t\telHorScrollBg.setAttribute('style', 'position: absolute; left: 0px; bottom: 0px; visibility: hidden; width: 178px; height: 15px; background-color: rgba(128,128,128,1); pointer-events: auto;');\n\t\telHorScrollBg.className='ggskin ggskin_scrollarea_hscrollbg';\n\t\telHorScrollFg = me._category_scroller__horScrollFg = document.createElement('div');\n\t\telHorScrollBg.appendChild(elHorScrollFg);\n\t\telHorScrollFg.className='ggskin ggskin_scrollarea_hscrollfg';\n\t\telHorScrollFg.setAttribute('style', 'position: absolute; left: 0px; top: 0px; visibility: hidden; width: 178px; height: 15px; background-color: rgba(192,192,192,1); pointer-events: auto;');\n\t\tme._category_scroller.ggScrollPosX = 0;\n\t\tme._category_scroller.ggScrollPosXPercent = 0.0;\n\t\telHorScrollFg.onmousedown = function(e) {\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) return;\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\te.stopPropagation();\n\t\t\tme._category_scroller.ggDragLastX = e.clientX;\n\t\t\tdocument.onmouseup = function() {\n\t\t\t\tlet inertiaInterval = setInterval(function() {\n\t\t\t\t\tme._category_scroller.ggDragInertiaX *= 0.65;\n\t\t\t\t\tme._category_scroller.ggScrollByX(me._category_scroller.ggDragInertiaX);\n\t\t\t\t\tif (Math.abs(me._category_scroller.ggDragInertiaX) < 1.0) {\n\t\t\t\t\t\tclearInterval(inertiaInterval);\n\t\t\t\t\t}\n\t\t\t\t\t}, 50);\n\t\t\t\tdocument.onmouseup = null;\n\t\t\t\tdocument.onmousemove = null;\n\t\t\t}\n\t\t\tdocument.onmousemove = function(e) {\n\t\t\t\te = e || window.event;\n\t\t\t\te.preventDefault();\n\t\t\t\tvar diffX = e.clientX - me._category_scroller.ggDragLastX;\n\t\t\t\tme._category_scroller.ggDragInertiaX = diffX;\n\t\t\t\tme._category_scroller.ggDragLastX = e.clientX;\n\t\t\t\tme._category_scroller.ggScrollByX(diffX);\n\t\t\t}\n\t\t}\n\t\telHorScrollFg.ontouchstart = function(e) {\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\te.stopPropagation();\n\t\t\tvar t = e.touches;\n\t\t\tme._category_scroller.ggDragLastX = t ? t[0].clientX : e.clientX;\n\t\t\tdocument.ontouchend = function() {\n\t\t\t\tlet inertiaInterval = setInterval(function() {\n\t\t\t\t\tme._category_scroller.ggDragInertiaX *= 0.65;\n\t\t\t\t\tme._category_scroller.ggScrollByX(me._category_scroller.ggDragInertiaX);\n\t\t\t\t\tif (Math.abs(me._category_scroller.ggDragInertiaX) < 1.0) {\n\t\t\t\t\t\tclearInterval(inertiaInterval);\n\t\t\t\t\t}\n\t\t\t\t\t}, 50);\n\t\t\t\tdocument.ontouchend = null;\n\t\t\t\tdocument.ontouchmove = null;\n\t\t\t\tdocument.onpointerup = null;\n\t\t\t\tdocument.onpointermove = null;\n\t\t\t}\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\t\tdocument.onpointerup = document.ontouchend;\n\t\t\t}\n\t\t\tdocument.ontouchmove = function(e) {\n\t\t\t\te = e || window.event;\n\t\t\t\te.preventDefault();\n\t\t\t\tvar t = e.touches;\n\t\t\t\tvar diffX = (t ? t[0].clientX : e.clientX) - me._category_scroller.ggDragLastX;\n\t\t\t\tme._category_scroller.ggDragInertiaX = diffX;\n\t\t\t\tme._category_scroller.ggDragLastX = t ? t[0].clientX : e.clientX;\n\t\t\t\tme._category_scroller.ggScrollByX(diffX);\n\t\t\t}\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\t\tdocument.onpointermove = document.ontouchmove;\n\t\t\t}\n\t\t}\n\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\telHorScrollFg.onpointerdown = elHorScrollFg.ontouchstart;\n\t\t}\n\t\telHorScrollBg.onmousedown = function(e) {\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\tvar diffX = me._category_scroller.ggScrollWidth;\n\t\t\tif (e.offsetX < me._category_scroller.ggScrollPosX) {\n\t\t\t\tdiffX = diffX * -1;\n\t\t\t}\n\t\t\tme._category_scroller.ggScrollByXSmooth(diffX);\n\t\t}\n\t\telHorScrollBg.ontouchstart = function(e) {\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\te.stopPropagation();\n\t\t\tvar t = e.touches;\n\t\t\tvar rect = me._category_scroller__horScrollBg.getBoundingClientRect();\n\t\t\tvar diffX = me._category_scroller.ggScrollWidth;\n\t\t\tif ((t[0].clientX - rect.left) < me._category_scroller.ggScrollPosX) {\n\t\t\t\tdiffX = diffX * -1;\n\t\t\t}\n\t\t\tme._category_scroller.ggScrollByXSmooth(diffX);\n\t\t}\n\t\tel.addEventListener('wheel', function(e) {\n\t\t\te.preventDefault();\n\t\t\tvar wheelDelta = Math.sign(e.deltaX);\n\t\t\tme._category_scroller.ggScrollByXSmooth(20 * wheelDelta);\n\t\t});\n\t\telVertScrollBg = me._category_scroller__vertScrollBg = document.createElement('div');\n\t\tel.appendChild(elVertScrollBg);\n\t\telVertScrollBg.setAttribute('style', 'position: absolute; right: 0px; top: 0px; visibility: hidden; width: 15px; height: 480px; background-color: rgba(128,128,128,1); pointer-events: auto;');\n\t\telVertScrollBg.className='ggskin ggskin_scrollarea_vscrollbg';\n\t\telVertScrollFg = me._category_scroller__vertScrollFg = document.createElement('div');\n\t\telVertScrollBg.appendChild(elVertScrollFg);\n\t\telVertScrollFg.setAttribute('style', 'position: absolute; left: 0px; top: 0px; visibility: hidden; width: 15px; height: 480px; background-color: rgba(192,192,192,1); pointer-events: auto;');\n\t\telVertScrollFg.className='ggskin ggskin_scrollarea_vscrollfg';\n\t\tme._category_scroller.ggScrollPosY = 0;\n\t\tme._category_scroller.ggScrollPosYPercent = 0.0;\n\t\telVertScrollFg.onmousedown = function(e) {\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) return;\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\te.stopPropagation();\n\t\t\tme._category_scroller.ggDragLastY = e.clientY;\n\t\t\tdocument.onmouseup = function() {\n\t\t\t\tlet inertiaInterval = setInterval(function() {\n\t\t\t\t\tme._category_scroller.ggDragInertiaY *= 0.65;\n\t\t\t\t\tme._category_scroller.ggScrollByY(me._category_scroller.ggDragInertiaY);\n\t\t\t\t\tif (Math.abs(me._category_scroller.ggDragInertiaY) < 1.0) {\n\t\t\t\t\t\tclearInterval(inertiaInterval);\n\t\t\t\t\t}\n\t\t\t\t\t}, 50);\n\t\t\t\tdocument.onmouseup = null;\n\t\t\t\tdocument.onmousemove = null;\n\t\t\t}\n\t\t\tdocument.onmousemove = function(e) {\n\t\t\t\te = e || window.event;\n\t\t\t\te.preventDefault();\n\t\t\t\tvar diffY = e.clientY - me._category_scroller.ggDragLastY;\n\t\t\t\tme._category_scroller.ggDragInertiaY = diffY;\n\t\t\t\tme._category_scroller.ggDragLastY = e.clientY;\n\t\t\t\tme._category_scroller.ggScrollByY(diffY);\n\t\t\t}\n\t\t}\n\t\telVertScrollFg.ontouchstart = function(e) {\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\te.stopPropagation();\n\t\t\tvar t = e.touches;\n\t\t\tme._category_scroller.ggDragLastY = t ? t[0].clientY : e.clientY;\n\t\t\tdocument.ontouchend = function() {\n\t\t\t\tlet inertiaInterval = setInterval(function() {\n\t\t\t\t\tme._category_scroller.ggDragInertiaY *= 0.65;\n\t\t\t\t\tme._category_scroller.ggScrollByY(me._category_scroller.ggDragInertiaY);\n\t\t\t\t\tif (Math.abs(me._category_scroller.ggDragInertiaY) < 1.0) {\n\t\t\t\t\t\tclearInterval(inertiaInterval);\n\t\t\t\t\t}\n\t\t\t\t\t}, 50);\n\t\t\t\tdocument.ontouchend = null;\n\t\t\t\tdocument.ontouchmove = null;\n\t\t\t\tdocument.onpointerup = null;\n\t\t\t\tdocument.onpointermove = null;\n\t\t\t}\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\t\tdocument.onpointerup = document.ontouchend;\n\t\t\t}\n\t\t\tdocument.ontouchmove = function(e) {\n\t\t\t\te = e || window.event;\n\t\t\t\te.preventDefault();\n\t\t\t\tvar t = e.touches;\n\t\t\t\tvar diffY = (t ? t[0].clientY : e.clientY) - me._category_scroller.ggDragLastY;\n\t\t\t\tme._category_scroller.ggDragInertiaY = diffY;\n\t\t\t\tme._category_scroller.ggDragLastY = t ? t[0].clientY : e.clientY;\n\t\t\t\tme._category_scroller.ggScrollByY(diffY);\n\t\t\t}\n\t\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\t\tdocument.onpointermove = document.ontouchmove;\n\t\t\t}\n\t\t}\n\t\tif (player.getOS() == 1 && navigator.maxTouchPoints > 0) {\n\t\t\telVertScrollFg.onpointerdown = elVertScrollFg.ontouchstart;\n\t\t}\n\t\telVertScrollBg.onmousedown = function(e) {\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\tvar diffY = me._category_scroller.ggScrollHeight;\n\t\t\tif (e.offsetY < me._category_scroller.ggScrollPosY) {\n\t\t\t\tdiffY = diffY * -1;\n\t\t\t}\n\t\t\tme._category_scroller.ggScrollByYSmooth(diffY);\n\t\t}\n\t\telVertScrollBg.ontouchstart = function(e) {\n\t\t\te = e || window.event;\n\t\t\te.preventDefault();\n\t\t\te.stopPropagation();\n\t\t\tvar t = e.touches;\n\t\t\tvar rect = me._category_scroller__vertScrollBg.getBoundingClientRect();\n\t\t\tvar diffY = me._category_scroller.ggScrollHeight;\n\t\t\tif ((t[0].clientY - rect.top) < me._category_scroller.ggScrollPosY) {\n\t\t\t\tdiffY = diffY * -1;\n\t\t\t}\n\t\t\tme._category_scroller.ggScrollByYSmooth(diffY);\n\t\t}\n\t\tel.addEventListener('wheel', function(e) {\n\t\t\te.preventDefault();\n\t\t\tvar wheelDelta = Math.sign(e.deltaY);\n\t\t\tme._category_scroller.ggScrollByYSmooth(20 * wheelDelta);\n\t\t});\n\t\telCornerBg = me._category_scroller__cornerBg = document.createElement('div');\n\t\tel.appendChild(elCornerBg);\n\t\telCornerBg.setAttribute('style', 'position: absolute; right: 0px; bottom: 0px; visibility: hidden; width: 15px; height: 15px; background-color: rgba(255,255,255,1);');\n\t\telCornerBg.className='ggskin ggskin_scrollarea_scrollcorner';\n\t\tel.ggId=\"category_scroller\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_scrollarea \";\n\t\tel.ggType='scrollarea';\n\t\ths ='';\n\t\ths+='border : 1px solid rgba(0, 0, 0, 0);';\n\t\ths+='height : calc(100% - 50px);';\n\t\ths+='left : 0px;';\n\t\ths+='overflow : hidden;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 50px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 178px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._category_scroller.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._category_scroller.ggUpdatePosition=function (useTransition) {\n\t\t\t{\n\t\t\t\tvar horScrollWasVisible = this.ggHorScrollVisible;\n\t\t\t\tvar vertScrollWasVisible = this.ggVertScrollVisible;\n\t\t\t\tthis.ggContent.style.left = '0px';\n\t\t\t\tthis.ggContent.style.top = '0px';\n\t\t\t\tthis.ggContentLeftOffset = 0;\n\t\t\t\tthis.ggContentTopOffset = 0;\n\t\t\t\tvar offsetWidthWithScale = this.getBoundingClientRect().width;\n\t\t\t\tvar offsetHeightWithScale = this.getBoundingClientRect().height;\n\t\t\t\tvar domRectContent = this.ggContent.getBoundingClientRect();\n\t\t\t\tvar minX = 0;\n\t\t\t\tvar minY = 0;\n\t\t\t\tvar maxX = 0;\n\t\t\t\tvar maxY = 0;\n\t\t\t\tvar stack=[];\n\t\t\t\tstack.push(this.ggContent);\n\t\t\t\twhile(stack.length>0) {\n\t\t\t\t\tvar e=stack.pop();\n\t\t\t\t\tif (e!=this.ggContent && e.getBoundingClientRect && e.style['display']!='none') {\n\t\t\t\t\t\tvar domRectChild = e.getBoundingClientRect();\n\t\t\t\t\t\tvar diffX = domRectChild.left - domRectContent.left;\n\t\t\t\t\t\tminX = Math.min(minX, diffX);\n\t\t\t\t\t\tmaxX = Math.max(maxX, diffX + domRectChild.width);\n\t\t\t\t\t\tvar diffY = domRectChild.top - domRectContent.top;\n\t\t\t\t\t\tminY = Math.min(minY, diffY);\n\t\t\t\t\t\tmaxY = Math.max(maxY, diffY + domRectChild.height);\n\t\t\t\t\t}\n\t\t\t\t\tif (e.hasChildNodes() && e.style['display']!='none') {\n\t\t\t\t\t\tfor(var i=0;i<e.childNodes.length;i++) {\n\t\t\t\t\t\t\tstack.push(e.childNodes[i]);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (minX < 0) this.ggContentLeftOffset = -minX;\n\t\t\t\tif (minY < 0) this.ggContentTopOffset = -minY;\n\t\t\t\tvar contentWidth = maxX - minX;\n\t\t\t\tvar contentHeight = maxY - minY;\n\t\t\t\tthis.ggContent.style.left = this.ggContentLeftOffset + 'px';\n\t\t\t\tthis.ggContent.style.top = this.ggContentTopOffset + 'px';\n\t\t\t\tthis.ggContent.style.width = contentWidth + 'px';\n\t\t\t\tthis.ggContent.style.height = contentHeight + 'px';\n\t\t\t\tthis.ggContent.style.left = -(Math.round(me._category_scroller.ggScrollPosX / me._category_scroller.ggHPercentVisible)) + this.ggContentLeftOffset + 'px';\n\t\t\t\tthis.ggContent.style.marginLeft = '0px';\n\t\t\t\tthis.ggContent.style.top = -(Math.round(me._category_scroller.ggScrollPosY / me._category_scroller.ggVPercentVisible)) + this.ggContentTopOffset + 'px';\n\t\t\t\tthis.ggContent.style.marginTop = '0px';\n\t\t\t\tif (contentWidth > Math.ceil(offsetWidthWithScale)) {\n\t\t\t\t\tme._category_scroller__horScrollBg.style.visibility = 'inherit';\n\t\t\t\t\tme._category_scroller__horScrollFg.style.visibility = 'inherit';\n\t\t\t\t\tme._category_scroller.ggHorScrollVisible = true;\n\t\t\t\t} else {\n\t\t\t\t\tme._category_scroller__horScrollBg.style.visibility = 'hidden';\n\t\t\t\t\tme._category_scroller__horScrollFg.style.visibility = 'hidden';\n\t\t\t\t\tme._category_scroller.ggHorScrollVisible = false;\n\t\t\t\t}\n\t\t\t\tif ((me._category_scroller.ggHorScrollVisible && contentHeight > this.offsetHeight - 15) || (!me._category_scroller.ggHorScrollVisible && contentHeight > this.offsetHeight)) {\n\t\t\t\t\tme._category_scroller__vertScrollBg.style.visibility = 'inherit';\n\t\t\t\t\tme._category_scroller__vertScrollFg.style.visibility = 'inherit';\n\t\t\t\t\tme._category_scroller.ggVertScrollVisible = true;\n\t\t\t\t\tif (!me._category_scroller.ggHorScrollVisible && (contentWidth > offsetWidthWithScale - me._category_scroller__vertScrollBg.getBoundingClientRect().width)) {\n\t\t\t\t\t\tme._category_scroller__horScrollBg.style.visibility = 'inherit';\n\t\t\t\t\t\tme._category_scroller__horScrollFg.style.visibility = 'inherit';\n\t\t\t\t\t\tme._category_scroller.ggHorScrollVisible = true;\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tme._category_scroller__vertScrollBg.style.visibility = 'hidden';\n\t\t\t\t\tme._category_scroller__vertScrollFg.style.visibility = 'hidden';\n\t\t\t\t\tme._category_scroller.ggVertScrollVisible = false;\n\t\t\t\t}\n\t\t\t\tif(me._category_scroller.ggHorScrollVisible) {\n\t\t\t\t\tme._category_scroller.ggAvailableHeight = me._category_scroller.offsetHeight - 15;\n\t\t\t\t\tif (me._category_scroller.ggVertScrollVisible) {\n\t\t\t\t\t\tme._category_scroller.ggAvailableWidth = me._category_scroller.offsetWidth - 15;\n\t\t\t\t\t\tme._category_scroller.ggAvailableWidthWithScale = me._category_scroller.getBoundingClientRect().width - me._category_scroller__horScrollBg.getBoundingClientRect().height;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tme._category_scroller.ggAvailableWidth = me._category_scroller.offsetWidth;\n\t\t\t\t\t\tme._category_scroller.ggAvailableWidthWithScale = me._category_scroller.getBoundingClientRect().width;\n\t\t\t\t\t}\n\t\t\t\t\tme._category_scroller__horScrollBg.style.width = me._category_scroller.ggAvailableWidth + 'px';\n\t\t\t\t\tme._category_scroller.ggHPercentVisible = contentWidth != 0 ? me._category_scroller.ggAvailableWidthWithScale / contentWidth : 0.0;\n\t\t\t\t\tif (me._category_scroller.ggHPercentVisible > 1.0) me._category_scroller.ggHPercentVisible = 1.0;\n\t\t\t\t\tme._category_scroller.ggScrollWidth = Math.round(me._category_scroller__horScrollBg.offsetWidth * me._category_scroller.ggHPercentVisible);\n\t\t\t\t\tme._category_scroller__horScrollFg.style.width = me._category_scroller.ggScrollWidth + 'px';\n\t\t\t\t\tme._category_scroller.ggScrollPosX = me._category_scroller.ggScrollPosXPercent * me._category_scroller.ggAvailableWidth;\n\t\t\t\t\tme._category_scroller.ggScrollPosX = Math.min(me._category_scroller.ggScrollPosX, me._category_scroller__horScrollBg.offsetWidth - me._category_scroller__horScrollFg.offsetWidth);\n\t\t\t\t\tme._category_scroller__horScrollFg.style.left = me._category_scroller.ggScrollPosX + 'px';\n\t\t\t\t\tif (me._category_scroller.ggHPercentVisible < 1.0) {\n\t\t\t\t\t\tme._category_scroller__content.style.left = -(Math.round(me._category_scroller.ggScrollPosX / me._category_scroller.ggHPercentVisible)) + this.ggContentLeftOffset + 'px';\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tme._category_scroller.ggAvailableHeight = me._category_scroller.offsetHeight;\n\t\t\t\t\tme._category_scroller.ggScrollPosX = 0;\n\t\t\t\t\tme._category_scroller.ggScrollPosXPercent = 0.0;\n\t\t\t\t\tme._category_scroller__content.style.left = this.ggContentLeftOffset + 'px';\n\t\t\t\t}\n\t\t\t\tif(me._category_scroller.ggVertScrollVisible) {\n\t\t\t\t\tme._category_scroller.ggAvailableWidth = me._category_scroller.offsetWidth - 15;\n\t\t\t\t\tif (me._category_scroller.ggHorScrollVisible) {\n\t\t\t\t\t\tme._category_scroller.ggAvailableHeight = me._category_scroller.offsetHeight - 15;\n\t\t\t\t\t\tme._category_scroller.ggAvailableHeightWithScale = me._category_scroller.getBoundingClientRect().height - me._category_scroller__vertScrollBg.getBoundingClientRect().width;\n\t\t\t\t\t\tme._category_scroller__cornerBg.style.visibility = 'inherit';\n\t\t\t\t\t} else {\n\t\t\t\t\t\tme._category_scroller.ggAvailableHeight = me._category_scroller.offsetHeight;\n\t\t\t\t\t\tme._category_scroller.ggAvailableHeightWithScale = me._category_scroller.getBoundingClientRect().height;\n\t\t\t\t\t\tme._category_scroller__cornerBg.style.visibility = 'hidden';\n\t\t\t\t\t}\n\t\t\t\t\tme._category_scroller__vertScrollBg.style.height = me._category_scroller.ggAvailableHeight + 'px';\n\t\t\t\t\tme._category_scroller.ggVPercentVisible = contentHeight != 0 ? me._category_scroller.ggAvailableHeightWithScale / contentHeight : 0.0;\n\t\t\t\t\tif (me._category_scroller.ggVPercentVisible > 1.0) me._category_scroller.ggVPercentVisible = 1.0;\n\t\t\t\t\tme._category_scroller.ggScrollHeight = Math.round(me._category_scroller__vertScrollBg.offsetHeight * me._category_scroller.ggVPercentVisible);\n\t\t\t\t\tme._category_scroller__vertScrollFg.style.height = me._category_scroller.ggScrollHeight + 'px';\n\t\t\t\t\tme._category_scroller.ggScrollPosY = me._category_scroller.ggScrollPosYPercent * me._category_scroller.ggAvailableHeight;\n\t\t\t\t\tme._category_scroller.ggScrollPosY = Math.min(me._category_scroller.ggScrollPosY, me._category_scroller__vertScrollBg.offsetHeight - me._category_scroller__vertScrollFg.offsetHeight);\n\t\t\t\t\tme._category_scroller__vertScrollFg.style.top = me._category_scroller.ggScrollPosY + 'px';\n\t\t\t\t\tif (me._category_scroller.ggVPercentVisible < 1.0) {\n\t\t\t\t\t\tme._category_scroller__content.style.top = -(Math.round(me._category_scroller.ggScrollPosY / me._category_scroller.ggVPercentVisible)) + this.ggContentTopOffset + 'px';\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tme._category_scroller.ggAvailableWidth = me._category_scroller.offsetWidth;\n\t\t\t\t\tme._category_scroller.ggScrollPosY = 0;\n\t\t\t\t\tme._category_scroller.ggScrollPosYPercent = 0.0;\n\t\t\t\t\tme._category_scroller__content.style.top = this.ggContentTopOffset + 'px';\n\t\t\t\t\tme._category_scroller__cornerBg.style.visibility = 'hidden';\n\t\t\t\t}\n\t\t\t\tif(horScrollWasVisible != me._category_scroller.ggHorScrollVisible || vertScrollWasVisible != me._category_scroller.ggVertScrollVisible) {\n\t\t\t\t\tme.updateSize(me._category_scroller);\n\t\t\t\t\tme._category_scroller.ggUpdatePosition();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tel=me._category_cloner=document.createElement('div');\n\t\tel.ggNumRepeat = 1;\n\t\tel.ggNumRows = 0;\n\t\tel.ggNumCols = 0;\n\t\tel.ggWidth = 150;\n\t\tel.ggHeight = 128;\n\t\tel.ggUpdating = false;\n\t\tel.ggFilter = [];\n\t\tel.ggInstances = [];\n\t\tme._category_cloner.callChildLogicBlocks_changenode = function(){\n\t\t\tif(me._category_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._category_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._category_cloner.ggInstances[i]._category && me._category_cloner.ggInstances[i]._category.logicBlock_backgroundcolor) {\n\t\t\t\t\t\tme._category_cloner.ggInstances[i]._category.logicBlock_backgroundcolor();\n\t\t\t\t\t}\n\t\t\t\t\tme._category_cloner.ggInstances[i]._node_cloner.callChildLogicBlocks_changenode();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category_cloner.callChildLogicBlocks_mouseover = function(){\n\t\t\tif(me._category_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._category_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._category_cloner.ggInstances[i]._category && me._category_cloner.ggInstances[i]._category.logicBlock_backgroundcolor) {\n\t\t\t\t\t\tme._category_cloner.ggInstances[i]._category.logicBlock_backgroundcolor();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category_cloner.callChildLogicBlocks_mouseover = function(){\n\t\t\tif(me._category_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._category_cloner.ggInstances.length; i++) {\n\t\t\t\t\tme._category_cloner.ggInstances[i]._node_cloner.callChildLogicBlocks_mouseover();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category_cloner.callChildLogicBlocks_active = function(){\n\t\t\tif(me._category_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._category_cloner.ggInstances.length; i++) {\n\t\t\t\t\tme._category_cloner.ggInstances[i]._node_cloner.callChildLogicBlocks_active();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category_cloner.callChildLogicBlocks_changevisitednodes = function(){\n\t\t\tif(me._category_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._category_cloner.ggInstances.length; i++) {\n\t\t\t\t\tme._category_cloner.ggInstances[i]._node_cloner.callChildLogicBlocks_changevisitednodes();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category_cloner.callChildLogicBlocks_activehotspotchanged = function(){\n\t\t\tif(me._category_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._category_cloner.ggInstances.length; i++) {\n\t\t\t\t\tme._category_cloner.ggInstances[i]._node_cloner.callChildLogicBlocks_activehotspotchanged();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category_cloner.callChildLogicBlocks_varchanged_open_tag = function(){\n\t\t\tif(me._category_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._category_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._category_cloner.ggInstances[i]._category && me._category_cloner.ggInstances[i]._category.logicBlock_backgroundcolor) {\n\t\t\t\t\t\tme._category_cloner.ggInstances[i]._category.logicBlock_backgroundcolor();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tel.ggAutoPosition = function(init) {\n\t\t\tvar currYPos = 0;\n\t\t\tvar numElements = me._category_cloner.ggInstances.length;\n\t\t\tvar currElement = 0;\n\t\t\tfor (var i=0; i<me._category_cloner.ggNumRows; i++) {\n\t\t\t\tvar rowMaxHeight = 0;\n\t\t\t\tfor (var j=0; j<me._category_cloner.ggNumCols; j++) {\n\t\t\t\t\tif (numElements > currElement) {\n\t\t\t\t\t\tif (!init) {\n\t\t\t\t\t\t\tif (me._category_cloner.childNodes[currElement].clientHeight < me._category_cloner.childNodes[currElement].scrollHeight && currElement < (numElements - 1)) {\n\t\t\t\t\t\t\t\tme._category_cloner.childNodes[currElement].style.transition = 'top ' + 1 + 's, height ' + 1 + 's';\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tme._category_cloner.childNodes[currElement].style.transition = 'top ' + 1 + 's';\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tme._category_cloner.childNodes[currElement].style.overflow = 'hidden';\n\t\t\t\t\t\tme._category_cloner.childNodes[currElement].style['top'] = currYPos + 'px';\n\t\t\t\t\t\tme._category_cloner.childNodes[currElement].style['height'] ='0px';\n\t\t\t\t\t\trowMaxHeight = Math.max(rowMaxHeight, me._category_cloner.childNodes[currElement].scrollHeight);\n\t\t\t\t\t\tme._category_cloner.childNodes[currElement].style['height'] = rowMaxHeight + 'px';\n\t\t\t\t\t}\n\t\t\t\t\tcurrElement++;\n\t\t\t\t}\n\t\t\t\tcurrYPos += rowMaxHeight;\n\t\t\t}\n\t\t\tsetTimeout(function() {\n\t\t\t\tvar p = me._category_cloner.parentElement;\n\t\t\t\twhile (p != null && p !== me.divSkin) {\n\t\t\t\t\tif (p.ggType && p.ggType == 'scrollarea') {\n\t\t\t\t\t\tif (p.ggUpdatePosition) {\n\t\t\t\t\t\t\tp.ggUpdatePosition();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tp = p.parentElement;\n\t\t\t\t}\n\t\t\t}, 1000);\n\t\t}\n\t\tel.ggUpdate = function(filter) {\n\t\t\tif(me._category_cloner.ggUpdating == true) return;\n\t\t\tme._category_cloner.ggUpdating = true;\n\t\t\tvar el=me._category_cloner;\n\t\t\tvar curNumCols = 0;\n\t\t\tcurNumCols = me._category_cloner.ggNumRepeat;\n\t\t\tif (curNumCols < 1) curNumCols = 1;\n\t\t\tif (typeof filter=='object') {\n\t\t\t\tel.ggFilter = filter;\n\t\t\t} else {\n\t\t\t\tfilter = el.ggFilter;\n\t\t\t};\n\t\t\tif (me.ggTag) filter.push(me.ggTag);\n\t\t\tfilter=filter.sort();\n\t\t\tif ((el.ggNumCols == curNumCols) && (el.ggInstances.length > 0) && (filter.length === el.ggCurrentFilter.length) && (filter.every(function(value, index) { return value === el.ggCurrentFilter[index] }) )) {\n\t\t\t\tme._category_cloner.ggUpdating = false;\n\t\t\t\treturn;\n\t\t\t} else {\n\t\t\t\tel.ggNumRows = 1;\n\t\t\t\tel.ggNumCols = curNumCols;\n\t\t\t}\n\t\t\tel.ggCurrentFilter = filter;\n\t\t\tel.ggInstances = [];\n\t\t\tif (el.hasChildNodes() == true) {\n\t\t\t\twhile (el.firstChild) {\n\t\t\t\t\tel.removeChild(el.firstChild);\n\t\t\t\t}\n\t\t\t}\n\t\t\tvar tourNodes = player.getNodeIds();\n\t\t\tvar row = 0;\n\t\t\tvar column = 0;\n\t\t\tvar currentIndex = 0;\n\t\t\tvar firstNode;\n\t\t\tfor (var i=0; i < el.ggTagTable.length; i++) {\n\t\t\t\tvar cItem = el.ggTagTable[i];\n\t\t\t\tfirstNode = '';\n\t\t\t\tcItem.nodecount = 0;\n\t\t\t\tfor (var j=0; j < tourNodes.length; j++) {\n\t\t\t\t\tvar nodeData = player.getNodeUserdata(tourNodes[j]);\n\t\t\t\t\tif ((nodeData['tags'].indexOf(cItem.tag) != -1) || (cItem.tag=='')) {\n\t\t\t\t\t\tvar passed = true;\n\t\t\t\t\t\tif (filter.length > 0) {\n\t\t\t\t\t\t\tfor (var k=0; k < filter.length; k++) {\n\t\t\t\t\t\t\t\tif (nodeData['tags'].indexOf(filter[k]) == -1) passed = false;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (passed) {\n\t\t\t\t\t\t\tcItem.nodecount++;\n\t\t\t\t\t\t\tif (firstNode == '') firstNode = tourNodes[j];\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tcItem.firstnode=firstNode;\n\t\t\t\tif (cItem.nodecount == 0) continue;\n\t\t\t\tvar nodeId = {};\n\t\t\t\tnodeId['tag'] = cItem.tag;\n\t\t\t\tnodeId['title'] = cItem.title;\n\t\t\t\tnodeId['nodecount'] = cItem.nodecount;\n\t\t\t\tnodeId['firstnode'] = cItem.firstnode;\n\t\t\t\tvar parameter={};\n\t\t\t\tparameter.top=(row * me._category_cloner.ggHeight) + 'px';\n\t\t\t\tparameter.left=(column * me._category_cloner.ggWidth) + 'px';\n\t\t\t\tparameter.width=me._category_cloner.ggWidth + 'px';\n\t\t\t\tparameter.height=me._category_cloner.ggHeight + 'px';\n\t\t\t\tparameter.index=currentIndex;\n\t\t\t\tvar inst = new SkinCloner_category_cloner_Class(nodeId, me, el, parameter);\n\t\t\t\tcurrentIndex++;\n\t\t\t\tinst.__div.style['height'] = '0px';\n\t\t\t\tel.ggInstances.push(inst);\n\t\t\t\tel.appendChild(inst.__div);\n\t\t\t\tinst.__div.ggObj=inst;\n\t\t\t\tskin.updateSize(inst.__div);\n\t\t\t\tcolumn++;\n\t\t\t\tif (column >= el.ggNumCols) {\n\t\t\t\t\tcolumn = 0;\n\t\t\t\t\trow++;\n\t\t\t\t\tel.ggNumRows++;\n\t\t\t\t}\n\t\t\t}\n\t\t\tme._category_cloner.callChildLogicBlocks_changenode();\n\t\t\tme._category_cloner.callChildLogicBlocks_mouseover();\n\t\t\tme._category_cloner.callChildLogicBlocks_mouseover();\n\t\t\tme._category_cloner.callChildLogicBlocks_active();\n\t\t\tme._category_cloner.callChildLogicBlocks_changevisitednodes();\n\t\t\tme._category_cloner.callChildLogicBlocks_activehotspotchanged();\n\t\t\tme._category_cloner.callChildLogicBlocks_varchanged_open_tag();\n\t\t\tme._category_cloner.ggAutoPosition(true);\n\t\t\tme._category_cloner.ggUpdating = false;\n\t\t\tplayer.triggerEvent('clonerchanged');\n\t\t\tif (me._category_cloner.parentNode.classList.contains('ggskin_subelement') && me._category_cloner.parentNode.parentNode.classList.contains('ggskin_scrollarea')) me._category_cloner.parentNode.parentNode.ggUpdatePosition();\n\t\t}\n\t\tel.ggFilter = [];\n\t\tel.ggTagTable = [\n\t\t\t{tag:\"First\",title:\"First Apartment\"},\n\t\t\t];\n\t\tel.ggId=\"category_cloner\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_cloner \";\n\t\tel.ggType='cloner';\n\t\ths ='';\n\t\ths+='height : 128px;';\n\t\ths+='left : 5px;';\n\t\ths+='overflow : visible;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 150px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._category_cloner.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._category_cloner.ggUpdateConditionNodeChange=function () {\n\t\t\tvar cnode=player.getCurrentNode();\n\t\t\tfor(var i=0; i<me._category_cloner.childNodes.length; i++) {\n\t\t\t\tvar child=me._category_cloner.childNodes[i];\n\t\t\t\tif (child.ggObj && child.ggObj.ggNodeId==cnode) {\n\t\t\t var childOffX = child.offsetLeft;\n\t\t\t var childOffY = child.offsetTop;\n\t\t\t\t\tvar p = child.parentElement;\n\t\t\t while (p != null && p!==this.divSkin) {\n\t\t\t\t\t\tif (p.ggType && p.ggType == 'scrollarea') {\n\t\t\t\t\t\t\tp.ggScrollIntoView(childOffX, childOffY, child.clientWidth, child.clientHeight);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tchildOffX += p.offsetLeft;\n\t\t\t\t\t\tchildOffY += p.offsetTop;\n\t\t\t\t\t\tp = p.parentElement;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category_cloner.ggUpdatePosition=function (useTransition) {\n\t\t\t\tme._category_cloner.ggUpdate();\n\t\t}\n\t\tme._category_cloner.ggNodeChange=function () {\n\t\t\tme._category_cloner.ggUpdateConditionNodeChange();\n\t\t}\n\t\tme._category_scroller__content.appendChild(me._category_cloner);\n\t\tme._menu_background.appendChild(me._category_scroller);\n\t\tme.divSkin.appendChild(me._menu_background);\n\t\tel=me._menu_open=document.createElement('div');\n\t\tels=me._menu_open__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJz8+CjwhRE9DVFlQRSBzdmcgUFVCTElDICctLy9XM0MvL0RURCBTVkcgMS4xLy9FTicgJ2h0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCc+CjxzdmcgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAzMiAzMiIgd2lkdGg9IjMycHgiIHN0eWxlPSJlbmFibGUtYmFja2dyb3VuZDpuZXcgMCAwIDMyIDMyOyIgZmlsbD0iI2ZmZmZmZiIgaWQ9IkxheWVyXzEiIHhtbDpzcGFjZT0icHJlc2VydmUiIGhlaWdodD0iMzJweCIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudz'+\n\t\t\t'Mub3JnLzE5OTkveGxpbmsiIGZpbGwtb3BhY2l0eT0iMSI+CiA8cGF0aCBkPSJNNCwxMGgyNGMxLjEwNCwwLDItMC44OTYsMi0ycy0wLjg5Ni0yLTItMkg0QzIuODk2LDYsMiw2Ljg5NiwyLDhTMi44OTYsMTAsNCwxMHogTTI4LDE0SDRjLTEuMTA0LDAtMiwwLjg5Ni0yLDIgIHMwLjg5NiwyLDIsMmgyNGMxLjEwNCwwLDItMC44OTYsMi0yUzI5LjEwNCwxNCwyOCwxNHogTTI4LDIySDRjLTEuMTA0LDAtMiwwLjg5Ni0yLDJzMC44OTYsMiwyLDJoMjRjMS4xMDQsMCwyLTAuODk2LDItMiAgUzI5LjEwNCwyMiwyOCwyMnoiLz4KPC9zdmc+Cg==';\n\t\tme._menu_open__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"menu_open\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='position : absolute;';\n\t\ths+='right : 5px;';\n\t\ths+='top : 5px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._menu_open.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._menu_open.logicBlock_position = function() {\n\t\t\tvar newLogicStatePosition;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('category_visible') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStatePosition = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStatePosition = -1;\n\t\t\t}\n\t\t\tif (me._menu_open.ggCurrentLogicStatePosition != newLogicStatePosition) {\n\t\t\t\tme._menu_open.ggCurrentLogicStatePosition = newLogicStatePosition;\n\t\t\t\tme._menu_open.style[domTransition]='right 500ms ease 0ms, top 500ms ease 0ms, opacity 500ms ease 0ms';\n\t\t\t\tif (me._menu_open.ggCurrentLogicStatePosition == 0) {\n\t\t\t\t\tme._menu_open.style.right='130px';\n\t\t\t\t\tme._menu_open.style.top='5px';\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._menu_open.style.right='5px';\n\t\t\t\t\tme._menu_open.style.top='5px';\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._menu_open.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['menu_open'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((player.getVariableValue('category_visible') == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 1;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._menu_open.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._menu_open.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._menu_open.style[domTransition]='right 500ms ease 0ms, top 500ms ease 0ms, opacity 500ms ease 0ms';\n\t\t\t\tif (me._menu_open.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tme._menu_open.style.visibility=me._menu_open.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._menu_open.style.opacity=1;\n\t\t\t\t}\n\t\t\t\telse if (me._menu_open.ggCurrentLogicStateAlpha == 1) {\n\t\t\t\t\tme._menu_open.style.visibility=me._menu_open.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._menu_open.style.opacity=0.6;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._menu_open.style.visibility=me._menu_open.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._menu_open.style.opacity=1;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._menu_open.onclick=function (e) {\n\t\t\tplayer.setVariableValue('category_visible', !player.getVariableValue('category_visible'));\n\t\t}\n\t\tme._menu_open.onmouseover=function (e) {\n\t\t\tme.elementMouseOver['menu_open']=true;\n\t\t\tme._menu_open.logicBlock_alpha();\n\t\t}\n\t\tme._menu_open.onmouseout=function (e) {\n\t\t\tme.elementMouseOver['menu_open']=false;\n\t\t\tme._menu_open.logicBlock_alpha();\n\t\t}\n\t\tme._menu_open.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['menu_open']=false;\n\t\t\tme._menu_open.logicBlock_alpha();\n\t\t}\n\t\tme._menu_open.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.divSkin.appendChild(me._menu_open);\n\t\tel=me._text_=document.createElement('div');\n\t\tels=me._text___text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"Text \\u0661\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='height : 35px;';\n\t\ths+='left : 10px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 10px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 150px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: 150px;';\n\t\ths+='height: auto;';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='font-size: 16px;';\n\t\ths+='font-weight: bold;';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: pre-wrap;';\n\t\ths+='padding: 17px 18px 17px 18px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tme._text_.ggUpdateText=function() {\n\t\t\tvar hs=me.ggUserdata.title;\n\t\t\tif (hs!=this.ggText) {\n\t\t\t\tthis.ggText=hs;\n\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t}\n\t\t}\n\t\tme._text_.ggUpdateText();\n\t\tplayer.addListener('changenode', function() {\n\t\t\tme._text_.ggUpdateText();\n\t\t});\n\t\tel.appendChild(els);\n\t\tme._text_.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._text_.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme.divSkin.appendChild(me._text_);\n\t\tel=me._button_toggle_map=document.createElement('div');\n\t\tel.ggId=\"button_toggle_map\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='bottom : 5px;';\n\t\ths+='height : 32px;';\n\t\ths+='position : absolute;';\n\t\ths+='right : 5px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_toggle_map.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_toggle_map.onclick=function (e) {\n\t\t\tplayer.setVariableValue('vis_map', !player.getVariableValue('vis_map'));\n\t\t}\n\t\tme._button_toggle_map.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._button_open_map=document.createElement('div');\n\t\tels=me._button_open_map__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+CjxzdmcgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAzMiAzMiIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIzMnB4IiBpZD0iTGF5ZXJfMSIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgYmFzZV'+\n\t\t\t'Byb2ZpbGU9ImJhc2ljIiBoZWlnaHQ9IjMycHgiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIj4KIDxnIG9wYWNpdHk9IjAuNCIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZT0iIzNDM0MzQyI+CiAgPHBhdGggZD0iTTI4LjQ5OSwxNS4zNDRsLTcuNjQsMS45ODNWOS4yNDJsNy42NC0xLjkwNVYxNS4zNDR6IE0xOS44MzYsOS4yMjl2Ny45MzNsLTcuNjczLTMuODMzVjUuNDE2JiN4ZDsmI3hhOyYjeDk7JiN4OTtDMTIuMTYzLDUuNDE2LDE5Ljc3OCw5LjIwOSwxOS44MzYsOS4yMjl6IE0xMS4xNDEsNS4xNTV2OC4wOTJMMy41LDE1LjE2NlY3LjA2TDExLjE0MSw1LjE1'+\n\t\t\t'NXogTTMuNSwxNi4yMmw3LjY0MS0xLjkxOXY4LjMyJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMCwwLjA0NSwwLjAwOCwwLjA5LDAuMDE5LDAuMTMyTDMuNSwyNC42NjJWMTYuMjJ6IE0xMi4zMzUsMjIuODM4Yy0wLjA2My0wLjAzMi0wLjEyNy0wLjA1OC0wLjE5NC0wLjA4JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4wMTItMC4wNDQsMC4wMjEtMC4wOSwwLjAyMS0wLjEzN3YtOC4xNDlsNy42NzMsMy44MzJ2OC4yODFMMTIuMzM1LDIyLjgzOHogTTIwLjg1OSwyNi44NDZ2LTguNDYybDcuNjQtMS45ODJMMjguNSwyNC45NCYjeGQ7JiN4YTsmI3g5OyYjeDk7TDIwLjg1OSwyNi44NDZ6Ii8+CiA8L2c+CiA8Zy'+\n\t\t\t'BmaWxsPSIjRkZGRkZGIiBzdHJva2Utd2lkdGg9IjAuMiIgc3Ryb2tlPSIjMDAwMDAwIj4KICA8cGF0aCBkPSJNMjguNDk5LDE1LjM0NGwtNy42NCwxLjk4M1Y5LjI0Mmw3LjY0LTEuOTA1VjE1LjM0NHogTTE5LjgzNiw5LjIyOXY3LjkzM2wtNy42NzMtMy44MzNWNS40MTYmI3hkOyYjeGE7JiN4OTsmI3g5O0MxMi4xNjMsNS40MTYsMTkuNzc4LDkuMjA5LDE5LjgzNiw5LjIyOXogTTExLjE0MSw1LjE1NXY4LjA5MkwzLjUsMTUuMTY2VjcuMDZMMTEuMTQxLDUuMTU1eiBNMy41LDE2LjIybDcuNjQxLTEuOTE5djguMzImI3hkOyYjeGE7JiN4OTsmI3g5O2MwLDAuMDQ1LDAuMDA4LDAuMDksMC4wMTks'+\n\t\t\t'MC4xMzJMMy41LDI0LjY2MlYxNi4yMnogTTEyLjMzNSwyMi44MzhjLTAuMDYzLTAuMDMyLTAuMTI3LTAuMDU4LTAuMTk0LTAuMDgmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjAxMi0wLjA0NCwwLjAyMS0wLjA5LDAuMDIxLTAuMTM3di04LjE0OWw3LjY3MywzLjgzMnY4LjI4MUwxMi4zMzUsMjIuODM4eiBNMjAuODU5LDI2Ljg0NnYtOC40NjJsNy42NC0xLjk4MkwyOC41LDI0Ljk0JiN4ZDsmI3hhOyYjeDk7JiN4OTtMMjAuODU5LDI2Ljg0NnoiLz4KIDwvZz4KPC9zdmc+Cg==';\n\t\tme._button_open_map__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._button_open_map__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEgQmFzaWMvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEtYmFzaWMuZHRkJz4KPCEtLSBHYXJkZW4gR25vbWUgU29mdHdhcmUgLSBTa2luIEJ1dHRvbnMgLS0+CjxzdmcgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAzMiAzMiIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIzMnB4IiBpZD0iTGF5ZXJfMSIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgYmFzZV'+\n\t\t\t'Byb2ZpbGU9ImJhc2ljIiBoZWlnaHQ9IjMycHgiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIj4KIDxnIG9wYWNpdHk9IjAuNCIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZT0iIzNDM0MzQyIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC0xNiwtMTYpIj4KICA8cGF0aCBkPSJNMjguNDk5LDE1LjM0NGwtNy42NCwxLjk4M1Y5LjI0Mmw3LjY0LTEuOTA1VjE1LjM0NHogTTE5LjgzNiw5LjIyOXY3LjkzM2wtNy42NzMtMy44MzNWNS40MTYmI3hkOyYjeGE7JiN4OTsmI3g5O0MxMi4xNjMsNS40MTYsMTkuNzc4LDkuMjA5LDE5'+\n\t\t\t'LjgzNiw5LjIyOXogTTExLjE0MSw1LjE1NXY4LjA5MkwzLjUsMTUuMTY2VjcuMDZMMTEuMTQxLDUuMTU1eiBNMy41LDE2LjIybDcuNjQxLTEuOTE5djguMzImI3hkOyYjeGE7JiN4OTsmI3g5O2MwLDAuMDQ1LDAuMDA4LDAuMDksMC4wMTksMC4xMzJMMy41LDI0LjY2MlYxNi4yMnogTTEyLjMzNSwyMi44MzhjLTAuMDYzLTAuMDMyLTAuMTI3LTAuMDU4LTAuMTk0LTAuMDgmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjAxMi0wLjA0NCwwLjAyMS0wLjA5LDAuMDIxLTAuMTM3di04LjE0OWw3LjY3MywzLjgzMnY4LjI4MUwxMi4zMzUsMjIuODM4eiBNMjAuODU5LDI2Ljg0NnYtOC40NjJsNy42NC0xLjk4Mk'+\n\t\t\t'wyOC41LDI0Ljk0JiN4ZDsmI3hhOyYjeDk7JiN4OTtMMjAuODU5LDI2Ljg0NnoiLz4KIDwvZz4KIDxnIGZpbGw9IiNGRkZGRkYiIHN0cm9rZS13aWR0aD0iMC4yIiBzdHJva2U9IiMwMDAwMDAiIHRyYW5zZm9ybT0idHJhbnNsYXRlKDE2LDE2KSBzY2FsZSgxLjEpIHRyYW5zbGF0ZSgtMTYsLTE2KSI+CiAgPHBhdGggZD0iTTI4LjQ5OSwxNS4zNDRsLTcuNjQsMS45ODNWOS4yNDJsNy42NC0xLjkwNVYxNS4zNDR6IE0xOS44MzYsOS4yMjl2Ny45MzNsLTcuNjczLTMuODMzVjUuNDE2JiN4ZDsmI3hhOyYjeDk7JiN4OTtDMTIuMTYzLDUuNDE2LDE5Ljc3OCw5LjIwOSwxOS44MzYsOS4yMjl6IE0xMS4x'+\n\t\t\t'NDEsNS4xNTV2OC4wOTJMMy41LDE1LjE2NlY3LjA2TDExLjE0MSw1LjE1NXogTTMuNSwxNi4yMmw3LjY0MS0xLjkxOXY4LjMyJiN4ZDsmI3hhOyYjeDk7JiN4OTtjMCwwLjA0NSwwLjAwOCwwLjA5LDAuMDE5LDAuMTMyTDMuNSwyNC42NjJWMTYuMjJ6IE0xMi4zMzUsMjIuODM4Yy0wLjA2My0wLjAzMi0wLjEyNy0wLjA1OC0wLjE5NC0wLjA4JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4wMTItMC4wNDQsMC4wMjEtMC4wOSwwLjAyMS0wLjEzN3YtOC4xNDlsNy42NzMsMy44MzJ2OC4yODFMMTIuMzM1LDIyLjgzOHogTTIwLjg1OSwyNi44NDZ2LTguNDYybDcuNjQtMS45ODJMMjguNSwyNC45NCYjeGQ7Ji'+\n\t\t\t'N4YTsmI3g5OyYjeDk7TDIwLjg1OSwyNi44NDZ6Ii8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._button_open_map__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"button_open_map\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_open_map.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_open_map.onmouseover=function (e) {\n\t\t\tme._button_open_map__img.style.visibility='hidden';\n\t\t\tme._button_open_map__imgo.style.visibility='inherit';\n\t\t\tme.elementMouseOver['button_open_map']=true;\n\t\t\tme._tt_togglemap.logicBlock_visible();\n\t\t}\n\t\tme._button_open_map.onmouseout=function (e) {\n\t\t\tme._button_open_map__img.style.visibility='inherit';\n\t\t\tme._button_open_map__imgo.style.visibility='hidden';\n\t\t\tme.elementMouseOver['button_open_map']=false;\n\t\t\tme._tt_togglemap.logicBlock_visible();\n\t\t}\n\t\tme._button_open_map.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['button_open_map']=false;\n\t\t\tme._tt_togglemap.logicBlock_visible();\n\t\t}\n\t\tme._button_open_map.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._tt_togglemap=document.createElement('div');\n\t\tels=me._tt_togglemap__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"tt_togglemap\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='z-index: 100;';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 32px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 100px;';\n\t\ths+='pointer-events:auto;';\n\t\ths+='text-shadow: 1px 1px 4px #000000;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: auto;';\n\t\ths+='height: auto;';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: nowrap;';\n\t\ths+='padding: 0px 1px 0px 1px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=\"\";\n\t\tel.appendChild(els);\n\t\tme._tt_togglemap.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._tt_togglemap.logicBlock_position = function() {\n\t\t\tvar newLogicStatePosition;\n\t\t\tif (\n\t\t\t\t((player.getHasTouch() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStatePosition = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStatePosition = -1;\n\t\t\t}\n\t\t\tif (me._tt_togglemap.ggCurrentLogicStatePosition != newLogicStatePosition) {\n\t\t\t\tme._tt_togglemap.ggCurrentLogicStatePosition = newLogicStatePosition;\n\t\t\t\tme._tt_togglemap.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_togglemap.ggCurrentLogicStatePosition == 0) {\n\t\t\t\t\tthis.ggDx = 0;\n\t\t\t\t\tme._tt_togglemap.style.top='-25px';\n\t\t\t\t\tme._tt_togglemap.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_togglemap.ggDx=0;\n\t\t\t\t\tme._tt_togglemap.style.top='32px';\n\t\t\t\t\tme._tt_togglemap.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_togglemap.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['button_open_map'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._tt_togglemap.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._tt_togglemap.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._tt_togglemap.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_togglemap.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._tt_togglemap.style.visibility=(Number(me._tt_togglemap.style.opacity)>0||!me._tt_togglemap.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._tt_togglemap.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_togglemap.style.visibility=\"hidden\";\n\t\t\t\t\tme._tt_togglemap.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_togglemap.logicBlock_text = function() {\n\t\t\tvar newLogicStateText;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('vis_map') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateText = 0;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((player.getVariableValue('vis_map') == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateText = 1;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateText = -1;\n\t\t\t}\n\t\t\tif (me._tt_togglemap.ggCurrentLogicStateText != newLogicStateText) {\n\t\t\t\tme._tt_togglemap.ggCurrentLogicStateText = newLogicStateText;\n\t\t\t\tme._tt_togglemap.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_togglemap.ggCurrentLogicStateText == 0) {\n\t\t\t\t\tme._tt_togglemap.ggText=\"Close Map\";\n\t\t\t\t\tme._tt_togglemap__text.innerHTML=me._tt_togglemap.ggText;\n\t\t\t\t\tif (me._tt_togglemap.ggUpdateText) {\n\t\t\t\t\tme._tt_togglemap.ggUpdateText=function() {\n\t\t\t\t\t\tvar hs=\"Close Map\";\n\t\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (me._tt_togglemap.ggUpdatePosition) me._tt_togglemap.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse if (me._tt_togglemap.ggCurrentLogicStateText == 1) {\n\t\t\t\t\tme._tt_togglemap.ggText=\"Open Map\";\n\t\t\t\t\tme._tt_togglemap__text.innerHTML=me._tt_togglemap.ggText;\n\t\t\t\t\tif (me._tt_togglemap.ggUpdateText) {\n\t\t\t\t\tme._tt_togglemap.ggUpdateText=function() {\n\t\t\t\t\t\tvar hs=\"Open Map\";\n\t\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (me._tt_togglemap.ggUpdatePosition) me._tt_togglemap.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_togglemap.ggText=\"\";\n\t\t\t\t\tme._tt_togglemap__text.innerHTML=me._tt_togglemap.ggText;\n\t\t\t\t\tif (me._tt_togglemap.ggUpdateText) {\n\t\t\t\t\tme._tt_togglemap.ggUpdateText=function() {\n\t\t\t\t\t\tvar hs=\"\";\n\t\t\t\t\t\tif (hs!=this.ggText) {\n\t\t\t\t\t\t\tthis.ggText=hs;\n\t\t\t\t\t\t\tthis.ggTextDiv.innerHTML=hs;\n\t\t\t\t\t\t\tif (this.ggUpdatePosition) this.ggUpdatePosition();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (me._tt_togglemap.ggUpdatePosition) me._tt_togglemap.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_togglemap.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t\tthis.style[domTransition]='left 0';\n\t\t\tthis.ggTextDiv.style.left=((98-this.ggTextDiv.offsetWidth)/2) + 'px';\n\t\t}\n\t\tme._button_open_map.appendChild(me._tt_togglemap);\n\t\tme._button_toggle_map.appendChild(me._button_open_map);\n\t\tel=me._button_close_map=document.createElement('div');\n\t\tels=me._button_close_map__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHZlcnNpb249IjEuMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSItMjQwIDMzMiAxMzAgMTMwIiB4PSIwcHgiIHk9IjBweCIgaWQ9IkxheWVyXzEiIHhtbDpzcGFjZT0icHJlc2VydmUiIGJhc2VQcm9maWxlPSJ0aW55IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayI+CiA8ZyBzdHJva2'+\n\t\t\t'Utd2lkdGg9IjIuMCIgaWQ9IkxheWVyXzFfMV8iIHN0cm9rZT0iIzAwMDAwMCI+CiAgPHBhdGggb3BhY2l0eT0iMS4wIiBmaWxsPSIjZmZmZmZmIiBkPSJNLTEzOS4zLDM1Ny44YzAuNCwwLDAuOSwwLjIsMS4yLDAuNWwxLjgsMS44YzAuNywwLjcsMC43LDEuNywwLDIuNGwtNzMuMyw3My4zYy0wLjMsMC4zLTAuOCwwLjUtMS4yLDAuNSYjeGQ7JiN4YTsmI3g5OyYjeDk7cy0wLjktMC4yLTEuMi0wLjVsLTEuOC0xLjhjLTAuNy0wLjctMC43LTEuNywwLTIuNGw3My4zLTczLjNDLTE0MC4xLDM1OC0xMzkuNywzNTcuOC0xMzkuMywzNTcuOCIvPgogPC9nPgogPGcgaWQ9IkxheWVyXzIiLz4KPC9zdmc+'+\n\t\t\t'Cg==';\n\t\tme._button_close_map__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"button_close_map\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._button_close_map.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._button_close_map.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('vis_map') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._button_close_map.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._button_close_map.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._button_close_map.style[domTransition]='';\n\t\t\t\tif (me._button_close_map.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._button_close_map.style.visibility=(Number(me._button_close_map.style.opacity)>0||!me._button_close_map.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._button_close_map.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._button_close_map.style.visibility=\"hidden\";\n\t\t\t\t\tme._button_close_map.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._button_close_map.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._button_toggle_map.appendChild(me._button_close_map);\n\t\tme.divSkin.appendChild(me._button_toggle_map);\n\t\tel=me._map_container=document.createElement('div');\n\t\tel.ggId=\"map_container\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='bottom : 50px;';\n\t\ths+='height : 225px;';\n\t\ths+='position : absolute;';\n\t\ths+='right : 50px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 250px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._map_container.ggIsActive=function() {\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._map_container.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('vis_map') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._map_container.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._map_container.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._map_container.style[domTransition]='';\n\t\t\t\tif (me._map_container.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._map_container.style.visibility=(Number(me._map_container.style.opacity)>0||!me._map_container.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._map_container.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._map_container.style.visibility=\"hidden\";\n\t\t\t\t\tme._map_container.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map_container.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._map=document.createElement('div');\n\t\tel.ggFilter = '';\n\t\tel.ggFilteredIds = [];\n\t\tel.ggMapNotLoaded = true;\n\t\tel.ggId=\"map\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_map \";\n\t\tel.ggType='map';\n\t\ths ='';\n\t\ths+='z-index: 0;';\n\t\ths+='background : #ffffff;';\n\t\ths+='border : 1px solid #000000;';\n\t\ths+='cursor : default;';\n\t\ths+='height : 100%;';\n\t\ths+='left : 0px;';\n\t\ths+='overflow : hidden;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 100%;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._map.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._map.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('vis_map') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._map.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._map.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._map.style[domTransition]='';\n\t\t\t\tif (me._map.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._map.style.visibility=(Number(me._map.style.opacity)>0||!me._map.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tif (me._map.ggMapNotLoaded) {\n\t\t\t\t\t\tme._map.ggInitMap(false);\n\t\t\t\t\t\tme._map.ggInitMapMarkers(true);\n\t\t\t\t\t}\n\t\t\t\t\tme._map.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._map.style.visibility=\"hidden\";\n\t\t\t\t\tme._map.ggClearMap();\n\t\t\t\t\tme._map.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map.ggCurrentLogicStateVisible = -1;\n\t\tme._map.ggUpdateConditionResize=function () {\n\t\t\tvar mapDetails = player.getMapDetails(me._map.ggMapId);\n\t\t\tif (!(mapDetails.hasOwnProperty('title'))) return;\n\t\t\tme._map.ggCalculateFloorplanSize(mapDetails);\n\t\t\tme._map.ggShowSimpleFloorplan(mapDetails);\n\t\t\tme._map.ggPlaceMarkersOnSimpleFloorplan();\n\t\t}\n\t\tme._map.ggUpdatePosition=function (useTransition) {\n\t\t\tme._map.ggUpdateConditionResize();\n\t\t}\n\t\tme._map.ggNodeChange=function () {\n\t\t\tvar mapDetails = player.getMapDetails(me._map.ggMapId);\n\t\t\tif (!(mapDetails.hasOwnProperty('title'))) return;\n\t\t\tme._map.ggCalculateFloorplanSize(mapDetails);\n\t\t\tme._map.ggShowSimpleFloorplan(mapDetails);\n\t\t\tme._map.ggPlaceMarkersOnSimpleFloorplan();\n\t\t\tif (me._map.ggLastNodeId) {\n\t\t\t\tvar lastActiveMarker = me._map.ggSimpleFloorplanMarkerArray[me._map.ggLastNodeId];\n\t\t\t\tif (lastActiveMarker && lastActiveMarker.ggDeactivate) lastActiveMarker.ggDeactivate();\n\t\t\t}\n\t\t\tvar id = player.getCurrentNode();\n\t\t\tvar marker = me._map.ggSimpleFloorplanMarkerArray[id];\n\t\t\tif (marker) {\n\t\t\t\tif (marker.ggActivate) marker.ggActivate();\n\t\t\t}\n\t\t\tif (player.getMapType(me._map.ggMapId) == 'file') {\n\t\t\t\tvar coords = player.getNodeMapCoords(id, me._map.ggMapId);\n\t\t\t\tif (coords.length < 2) {\n\t\t\t\t\tvar mapId = player.getMapContainingNode(id);\n\t\t\t\t\tif (mapId != '') {\n\t\t\t\t\t\t\tme._map.ggChangeMap(mapId);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tme._map.ggLastNodeId = id;\n\t\t}\n\t\tme._map_container.appendChild(me._map);\n\t\tel=me._close=document.createElement('div');\n\t\tels=me._close__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEuZHRkJz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE1LjAuMiwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHZlcnNpb249IjEuMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMzIgMzIiIHg9IjBweCIgeT0iMHB4IiB3aWR0aD0iMzJweCIgZW'+\n\t\t\t'5hYmxlLWJhY2tncm91bmQ9Im5ldyAwIDAgMzIgMzIiIGlkPSJMYXllcl8xIiB4bWw6c3BhY2U9InByZXNlcnZlIiBoZWlnaHQ9IjMycHgiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIj4KIDxnIG9wYWNpdHk9IjAuNCI+CiAgPHBhdGggc3Ryb2tlLXdpZHRoPSIxLjUiIGQ9Ik0yMS4xMzIsMTkuNDM5TDE3LjY5MiwxNmwzLjQ0LTMuNDRjMC40NjgtMC40NjcsMC40NjgtMS4yMjUsMC0xLjY5MyYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjQ2Ny0wLjQ2Ny0xLjIyNS0wLjQ2Ny0xLjY5MSwwLjAwMUwxNiwxNC4zMDhsLTMuNDQxLTMuNDQxYy0wLjQ2Ny0wLjQ2Ny0xLjIy'+\n\t\t\t'NC0wLjQ2Ny0xLjY5MSwwLjAwMSYjeGQ7JiN4YTsmI3g5OyYjeDk7Yy0wLjQ2NywwLjQ2Ny0wLjQ2NywxLjIyNCwwLDEuNjlMMTQuMzA5LDE2bC0zLjQ0LDMuNDRjLTAuNDY3LDAuNDY3LTAuNDY3LDEuMjI2LDAsMS42OTJjMC40NjcsMC40NjcsMS4yMjYsMC40NjcsMS42OTIsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7bDMuNDQtMy40NGwzLjQzOSwzLjQzOWMwLjQ2OCwwLjQ2OCwxLjIyNSwwLjQ2OCwxLjY5MSwwLjAwMUMyMS41OTksMjAuNjY0LDIxLjYsMTkuOTA3LDIxLjEzMiwxOS40Mzl6IE0yNC44MzksNy4xNjEmI3hkOyYjeGE7JiN4OTsmI3g5O2MtNC44ODItNC44ODItMTIuNzk2LTQuODgyLT'+\n\t\t\t'E3LjY3OCwwYy00Ljg4MSw0Ljg4MS00Ljg4MSwxMi43OTUsMCwxNy42NzhjNC44ODEsNC44OCwxMi43OTYsNC44OCwxNy42NzgsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7QzI5LjcyLDE5Ljk1NiwyOS43MiwxMi4wNDIsMjQuODM5LDcuMTYxeiBNMTYsMjYuMTA2Yy0yLjU4OS0wLjAwMS01LjE3LTAuOTg1LTcuMTQ2LTIuOTYxUzUuODk1LDE4LjU5LDUuODk0LDE2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC0yLjU5MSwwLjk4NC01LjE3LDIuOTYtNy4xNDdDMTAuODMsNi44NzgsMTMuNDA5LDUuODk0LDE2LDUuODk0YzIuNTkxLDAuMDAxLDUuMTcsMC45ODQsNy4xNDcsMi45NTkmI3hkOyYjeGE7JiN4OTsm'+\n\t\t\t'I3g5O2MxLjk3NiwxLjk3NywyLjk1Nyw0LjU1NiwyLjk2LDcuMTQ3Yy0wLjAwMSwyLjU5MS0wLjk4NSw1LjE2OS0yLjk2LDcuMTQ4QzIxLjE2OSwyNS4xMjIsMTguNTkxLDI2LjEwNiwxNiwyNi4xMDZ6IiBzdHJva2U9IiMzQzNDM0MiLz4KIDwvZz4KIDxnPgogIDxwYXRoIHN0cm9rZS13aWR0aD0iMC4yIiBmaWxsPSIjRkZGRkZGIiBkPSJNMjEuMTMyLDE5LjQzOUwxNy42OTIsMTZsMy40NC0zLjQ0YzAuNDY4LTAuNDY3LDAuNDY4LTEuMjI1LDAtMS42OTMmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC40NjctMC40NjctMS4yMjUtMC40NjctMS42OTEsMC4wMDFMMTYsMTQuMzA4bC0zLjQ0MS0zLjQ0MW'+\n\t\t\t'MtMC40NjctMC40NjctMS4yMjQtMC40NjctMS42OTEsMC4wMDEmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC40NjcsMC40NjctMC40NjcsMS4yMjQsMCwxLjY5TDE0LjMwOSwxNmwtMy40NCwzLjQ0Yy0wLjQ2NywwLjQ2Ny0wLjQ2NywxLjIyNiwwLDEuNjkyYzAuNDY3LDAuNDY3LDEuMjI2LDAuNDY3LDEuNjkyLDAmI3hkOyYjeGE7JiN4OTsmI3g5O2wzLjQ0LTMuNDRsMy40MzksMy40MzljMC40NjgsMC40NjgsMS4yMjUsMC40NjgsMS42OTEsMC4wMDFDMjEuNTk5LDIwLjY2NCwyMS42LDE5LjkwNywyMS4xMzIsMTkuNDM5eiBNMjQuODM5LDcuMTYxJiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTQuODgyLTQu'+\n\t\t\t'ODgyLTEyLjc5Ni00Ljg4Mi0xNy42NzgsMGMtNC44ODEsNC44ODEtNC44ODEsMTIuNzk1LDAsMTcuNjc4YzQuODgxLDQuODgsMTIuNzk2LDQuODgsMTcuNjc4LDAmI3hkOyYjeGE7JiN4OTsmI3g5O0MyOS43MiwxOS45NTYsMjkuNzIsMTIuMDQyLDI0LjgzOSw3LjE2MXogTTE2LDI2LjEwNmMtMi41ODktMC4wMDEtNS4xNy0wLjk4NS03LjE0Ni0yLjk2MVM1Ljg5NSwxOC41OSw1Ljg5NCwxNiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAtMi41OTEsMC45ODQtNS4xNywyLjk2LTcuMTQ3QzEwLjgzLDYuODc4LDEzLjQwOSw1Ljg5NCwxNiw1Ljg5NGMyLjU5MSwwLjAwMSw1LjE3LDAuOTg0LDcuMTQ3LDIuOT'+\n\t\t\t'U5JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMS45NzYsMS45NzcsMi45NTcsNC41NTYsMi45Niw3LjE0N2MtMC4wMDEsMi41OTEtMC45ODUsNS4xNjktMi45Niw3LjE0OEMyMS4xNjksMjUuMTIyLDE4LjU5MSwyNi4xMDYsMTYsMjYuMTA2eiIgc3Ryb2tlPSIjMDAwMDAwIi8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._close__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\telo=me._close__imgo=document.createElement('img');\n\t\telo.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgJy0vL1czQy8vRFREIFNWRyAxLjEvL0VOJyAnaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEuZHRkJz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE1LjAuMiwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHZlcnNpb249IjEuMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMzIgMzIiIHg9IjBweCIgeT0iMHB4IiB3aWR0aD0iMzJweCIgZW'+\n\t\t\t'5hYmxlLWJhY2tncm91bmQ9Im5ldyAwIDAgMzIgMzIiIGlkPSJMYXllcl8xIiB4bWw6c3BhY2U9InByZXNlcnZlIiBoZWlnaHQ9IjMycHgiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIj4KIDxnIG9wYWNpdHk9IjAuNCIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC0xNiwtMTYpIj4KICA8cGF0aCBzdHJva2Utd2lkdGg9IjEuNSIgZD0iTTIxLjEzMiwxOS40MzlMMTcuNjkzLDE2bDMuNDM5LTMuNDRjMC40NjgtMC40NjcsMC40NjgtMS4yMjYsMC4wMDEtMS42OTMmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC40NjctMC40Njct'+\n\t\t\t'MS4yMjUtMC40NjctMS42OTIsMC4wMDFsLTMuNDQsMy40NGwtMy40NDEtMy40NDFjLTAuNDY4LTAuNDY4LTEuMjI1LTAuNDY3LTEuNjkzLDAmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC40NjcsMC40NjctMC40NjcsMS4yMjUsMCwxLjY5MkwxNC4zMDksMTZsLTMuNDQsMy40NGMtMC40NjcsMC40NjYtMC40NjcsMS4yMjQsMCwxLjY5MWMwLjQ2NywwLjQ2NywxLjIyNiwwLjQ2NywxLjY5MiwwLjAwMSYjeGQ7JiN4YTsmI3g5OyYjeDk7bDMuNDQtMy40NGwzLjQ0LDMuNDM5YzAuNDY4LDAuNDY4LDEuMjI0LDAuNDY3LDEuNjkxLDBDMjEuNTk4LDIwLjY2NCwyMS42LDE5LjkwNywyMS4xMzIsMTkuNDM5ei'+\n\t\t\t'BNMjQuODM5LDcuMTYxJiN4ZDsmI3hhOyYjeDk7JiN4OTtjLTQuODgyLTQuODgyLTEyLjc5Ni00Ljg4Mi0xNy42NzgsMGMtNC44ODEsNC44ODEtNC44ODEsMTIuNzk2LDAsMTcuNjc4YzQuODgyLDQuODgxLDEyLjc5Niw0Ljg4MSwxNy42NzgsMCYjeGQ7JiN4YTsmI3g5OyYjeDk7QzI5LjcyLDE5Ljk1NywyOS43MjEsMTIuMDQzLDI0LjgzOSw3LjE2MXogTTE2LDI2LjEwNmMtMi41OSwwLTUuMTcxLTAuOTg0LTcuMTQ2LTIuOTU5QzYuODc4LDIxLjE3LDUuODk1LDE4LjU5MSw1Ljg5NCwxNiYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAtMi41OTEsMC45ODMtNS4xNywyLjk1OS03LjE0N2MxLjk3Ny0xLjk3'+\n\t\t\t'Niw0LjU1Ni0yLjk1OSw3LjE0OC0yLjk2YzIuNTkxLDAuMDAxLDUuMTcsMC45ODQsNy4xNDcsMi45NTkmI3hkOyYjeGE7JiN4OTsmI3g5O2MxLjk3NSwxLjk3NywyLjk1Nyw0LjU1NiwyLjk1OSw3LjE0N2MtMC4wMDEsMi41OTItMC45ODQsNS4xNy0yLjk2LDcuMTQ4QzIxLjE3LDI1LjEyMywxOC41OTEsMjYuMTA3LDE2LDI2LjEwNnoiIHN0cm9rZT0iIzNDM0MzQyIvPgogPC9nPgogPGcgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMTYsMTYpIHNjYWxlKDEuMSkgdHJhbnNsYXRlKC0xNiwtMTYpIj4KICA8cGF0aCBzdHJva2Utd2lkdGg9IjAuMiIgZmlsbD0iI0ZGRkZGRiIgZD0iTTIxLjEzMiwxOS40Mz'+\n\t\t\t'lMMTcuNjkzLDE2bDMuNDM5LTMuNDQmI3hkOyYjeGE7JiN4OTsmI3g5O2MwLjQ2OC0wLjQ2NywwLjQ2OC0xLjIyNiwwLjAwMS0xLjY5M2MtMC40NjctMC40NjctMS4yMjUtMC40NjctMS42OTIsMC4wMDFsLTMuNDQsMy40NGwtMy40NDEtMy40NDEmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC40NjgtMC40NjgtMS4yMjUtMC40NjctMS42OTMsMGMtMC40NjcsMC40NjctMC40NjcsMS4yMjUsMCwxLjY5MkwxNC4zMDksMTZsLTMuNDQsMy40NGMtMC40NjcsMC40NjYtMC40NjcsMS4yMjQsMCwxLjY5MSYjeGQ7JiN4YTsmI3g5OyYjeDk7YzAuNDY3LDAuNDY3LDEuMjI2LDAuNDY3LDEuNjkyLDAuMDAxbDMu'+\n\t\t\t'NDQtMy40NGwzLjQ0LDMuNDM5YzAuNDY4LDAuNDY4LDEuMjI0LDAuNDY3LDEuNjkxLDAmI3hkOyYjeGE7JiN4OTsmI3g5O0MyMS41OTgsMjAuNjY0LDIxLjYsMTkuOTA3LDIxLjEzMiwxOS40Mzl6IE0yNC44MzksNy4xNjFjLTQuODgyLTQuODgyLTEyLjc5Ni00Ljg4Mi0xNy42NzgsMGMtNC44ODEsNC44ODEtNC44ODEsMTIuNzk2LDAsMTcuNjc4JiN4ZDsmI3hhOyYjeDk7JiN4OTtjNC44ODIsNC44ODEsMTIuNzk2LDQuODgxLDE3LjY3OCwwQzI5LjcyLDE5Ljk1NywyOS43MjEsMTIuMDQzLDI0LjgzOSw3LjE2MXogTTE2LDI2LjEwNmMtMi41OSwwLTUuMTcxLTAuOTg0LTcuMTQ2LTIuOTU5JiN4ZD'+\n\t\t\t'smI3hhOyYjeDk7JiN4OTtDNi44NzgsMjEuMTcsNS44OTUsMTguNTkxLDUuODk0LDE2YzAtMi41OTEsMC45ODMtNS4xNywyLjk1OS03LjE0N2MxLjk3Ny0xLjk3Niw0LjU1Ni0yLjk1OSw3LjE0OC0yLjk2JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMi41OTEsMC4wMDEsNS4xNywwLjk4NCw3LjE0NywyLjk1OWMxLjk3NSwxLjk3NywyLjk1Nyw0LjU1NiwyLjk1OSw3LjE0N2MtMC4wMDEsMi41OTItMC45ODQsNS4xNy0yLjk2LDcuMTQ4JiN4ZDsmI3hhOyYjeDk7JiN4OTtDMjEuMTcsMjUuMTIzLDE4LjU5MSwyNi4xMDcsMTYsMjYuMTA2eiIgc3Ryb2tlPSIjMDAwMDAwIi8+CiA8L2c+Cjwvc3ZnPgo=';\n\t\tme._close__imgo.setAttribute('src',hs);\n\t\telo.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;visibility:hidden;pointer-events:none;;');\n\t\telo['ondragstart']=function() { return false; };\n\t\tel.appendChild(elo);\n\t\tel.ggId=\"close\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 32px;';\n\t\ths+='position : absolute;';\n\t\ths+='right : -40px;';\n\t\ths+='top : -20px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 32px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._close.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._close.onclick=function (e) {\n\t\t\tplayer.setVariableValue('vis_map', false);\n\t\t}\n\t\tme._close.onmouseover=function (e) {\n\t\t\tme._close__img.style.visibility='hidden';\n\t\t\tme._close__imgo.style.visibility='inherit';\n\t\t}\n\t\tme._close.onmouseout=function (e) {\n\t\t\tme._close__img.style.visibility='inherit';\n\t\t\tme._close__imgo.style.visibility='hidden';\n\t\t}\n\t\tme._close.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._map_container.appendChild(me._close);\n\t\tme.divSkin.appendChild(me._map_container);\n\t\tme._map.ggMarkerInstances=[];\n\t\tme._map.ggMapId = 'FloorPlan02';\n\t\tme._map.ggLastNodeId=null;\n\t\tme._map.callChildLogicBlocksHotspot_map_pin_changenode = function(){\n\t\t\tif(me._map.ggMarkerInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._map.ggMarkerInstances.length; i++) {\n\t\t\t\t\tif (me._map.ggMarkerInstances[i]._map_pin_tt && me._map.ggMarkerInstances[i]._map_pin_tt.logicBlock_alpha) {\n\t\t\t\t\t\tme._map.ggMarkerInstances[i]._map_pin_tt.logicBlock_alpha();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map.callChildLogicBlocksHotspot_map_pin_configloaded = function(){\n\t\t\tif(me._map.ggMarkerInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._map.ggMarkerInstances.length; i++) {\n\t\t\t\t\tif (me._map.ggMarkerInstances[i]._map_pin_tt && me._map.ggMarkerInstances[i]._map_pin_tt.logicBlock_position) {\n\t\t\t\t\t\tme._map.ggMarkerInstances[i]._map_pin_tt.logicBlock_position();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map.callChildLogicBlocksHotspot_map_pin_mouseover = function(){\n\t\t\tif(me._map.ggMarkerInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._map.ggMarkerInstances.length; i++) {\n\t\t\t\t\tif (me._map.ggMarkerInstances[i]._map_pin_normal && me._map.ggMarkerInstances[i]._map_pin_normal.logicBlock_scaling) {\n\t\t\t\t\t\tme._map.ggMarkerInstances[i]._map_pin_normal.logicBlock_scaling();\n\t\t\t\t\t}\n\t\t\t\t\tif (me._map.ggMarkerInstances[i]._map_pin_active && me._map.ggMarkerInstances[i]._map_pin_active.logicBlock_scaling) {\n\t\t\t\t\t\tme._map.ggMarkerInstances[i]._map_pin_active.logicBlock_scaling();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map.callChildLogicBlocksHotspot_map_pin_mouseover = function(){\n\t\t\tif(me._map.ggMarkerInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._map.ggMarkerInstances.length; i++) {\n\t\t\t\t\tif (me._map.ggMarkerInstances[i]._map_pin_tt && me._map.ggMarkerInstances[i]._map_pin_tt.logicBlock_alpha) {\n\t\t\t\t\t\tme._map.ggMarkerInstances[i]._map_pin_tt.logicBlock_alpha();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map.callChildLogicBlocksHotspot_map_pin_active = function(){\n\t\t\tif(me._map.ggMarkerInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._map.ggMarkerInstances.length; i++) {\n\t\t\t\t\tif (me._map.ggMarkerInstances[i]._map_pin_normal && me._map.ggMarkerInstances[i]._map_pin_normal.logicBlock_alpha) {\n\t\t\t\t\t\tme._map.ggMarkerInstances[i]._map_pin_normal.logicBlock_alpha();\n\t\t\t\t\t}\n\t\t\t\t\tif (me._map.ggMarkerInstances[i]._map_pin_active && me._map.ggMarkerInstances[i]._map_pin_active.logicBlock_alpha) {\n\t\t\t\t\t\tme._map.ggMarkerInstances[i]._map_pin_active.logicBlock_alpha();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map.callChildLogicBlocksHotspot_map_pin_hastouch = function(){\n\t\t\tif(me._map.ggMarkerInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._map.ggMarkerInstances.length; i++) {\n\t\t\t\t\tif (me._map.ggMarkerInstances[i]._map_pin_tt && me._map.ggMarkerInstances[i]._map_pin_tt.logicBlock_position) {\n\t\t\t\t\t\tme._map.ggMarkerInstances[i]._map_pin_tt.logicBlock_position();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map.callChildLogicBlocksHotspot_map_pin_activehotspotchanged = function(){\n\t\t\tif(me._map.ggMarkerInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._map.ggMarkerInstances.length; i++) {\n\t\t\t\t\tif (me._map.ggMarkerInstances[i]._map_pin_tt && me._map.ggMarkerInstances[i]._map_pin_tt.logicBlock_alpha) {\n\t\t\t\t\t\tme._map.ggMarkerInstances[i]._map_pin_tt.logicBlock_alpha();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map.ggSimpleFloorplanMarkerArray=[];\n\t\tme._map.ggFloorplanWidth=0;\n\t\tme._map.ggFloorplanHeight=0;\n\t\tme._map__mapdiv=document.createElement('div');\n\t\tme._map__mapdiv.className='ggskin ggskin_map';\n\t\tme._map.appendChild(me._map__mapdiv);\n\t\tme._map__img=document.createElement('img');\n\t\tme._map__img.className='ggskin ggskin_map';\n\t\tme._map__mapdiv.appendChild(me._map__img);\n\t\tme._map.ggShowSimpleFloorplan=function(mapDetails) {\n\t\t\tvar mapWidth = me._map.clientWidth;\n\t\t\tvar mapHeight = me._map.clientHeight;\n\t\t\tvar levelLimit = 500;\n\t\t\tvar level = 1;\n\t\t\twhile (mapWidth > levelLimit && mapHeight > levelLimit) {\n\t\t\t\tlevelLimit *= 2;\n\t\t\t\tif (mapDetails['width'] < levelLimit || mapDetails['height'] < levelLimit) break;\n\t\t\t\tlevel++;\n\t\t\t}\n\t\t\tvar imageFilename = basePath + 'images/maptiles/' + me._map.ggMapId + '_' + level + '.' + mapDetails['tileformat'];\n\t\t\tme._map__img.setAttribute('src', imageFilename);\n\t\tme._map__mapdiv.setAttribute('style','position: absolute; left: 0px; top: 0px;width:' + me._map.ggFloorplanWidth + 'px;height:' + me._map.ggFloorplanHeight + 'px;overflow:hidden;;');\n\t\tme._map__img.setAttribute('style','width:' + me._map.ggFloorplanWidth + 'px;height:' + me._map.ggFloorplanHeight + 'px;-webkit-user-drag:none;pointer-events:none;');\n\t\t}\n\t\tme._map.ggCalculateFloorplanSize=function(mapDetails) {\n\t\t\tvar floorplanWidth = mapDetails['width'];\n\t\t\tvar floorplanHeight = mapDetails['height'];\n\t\t\tvar frameAR = me._map.clientWidth / me._map.clientHeight;\n\t\t\tvar floorplanAR = floorplanWidth / floorplanHeight;\n\t\t\tif (frameAR > floorplanAR) {\n\t\t\t\tme._map.ggFloorplanHeight = me._map.clientHeight;\n\t\t\t\tme._map.ggFloorplanWidth = me._map.ggFloorplanHeight * floorplanAR;\n\t\t\t} else {\n\t\t\t\tme._map.ggFloorplanWidth = me._map.clientWidth;\n\t\t\t\tme._map.ggFloorplanHeight = me._map.ggFloorplanWidth / floorplanAR;\n\t\t\t}\n\t\t}\n\t\tme._map.ggInitMap=function() {\n\t\t\tme._map.ggMapNotLoaded = false;\n\t\t\tvar mapDetails = player.getMapDetails(me._map.ggMapId);\n\t\t\tme._map.style.backgroundColor = mapDetails['bgcolor'];\n\t\t\tif (mapDetails.hasOwnProperty('transparent') && mapDetails['transparent']) {\n\t\t\t\tme._map.ggPermeableMap = true;\n\t\t\t} else {\n\t\t\t\tme._map.ggPermeableMap = false;\n\t\t\t}\n\t\t\tme._map.ggCalculateFloorplanSize(mapDetails);\n\t\t\tme._map.ggShowSimpleFloorplan(mapDetails);\n\t\t\tme._map.ggFloorplanNorth = mapDetails['floorplannorth'];\n\t\t}\n\t\tme._map.ggClearMap=function() {\n\t\t\tme._map.ggClearMapMarkers();\n\t\t\tme._map.ggMapNotLoaded = true;\n\t\t}\n\t\tme._map.ggChangeMap=function(mapId) {\n\t\t\tvar newMapType = player.getMapType(mapId)\n\t\t\tif (newMapType == 'web') {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tme._map.ggMapId = mapId;\n\t\t\tme._map.ggClearMap();\n\t\t\tme._map.ggInitMap();\n\t\t\tme._map.ggInitMapMarkers();\n\t\t}\n\t\tme._map.ggPlaceMarkersOnSimpleFloorplan=function() {\n\t\t\tvar markers=me._map.ggSimpleFloorplanMarkerArray;\n\t\t\tfor (id in markers) {\n\t\t\t\tif (markers.hasOwnProperty(id)) {\n\t\t\t\t\tmarker=markers[id];\n\t\t\t\t\tvar coords = player.getNodeMapCoordsInPercent(id, me._map.ggMapId);\n\t\t\t\t\tvar xPos = (me._map.ggFloorplanWidth * coords[0]) / 100.0;\n\t\t\t\t\tvar yPos = (me._map.ggFloorplanHeight * coords[1]) / 100.0;\n\t\t\t\t\tmarker.radarXPos = xPos;\n\t\t\t\t\tmarker.radarYPos = yPos;\n\t\t\t\t\txPos -= me._map.ggHMarkerAnchorOffset;\n\t\t\t\t\tyPos -= me._map.ggVMarkerAnchorOffset;\n\t\t\t\t\tmarker.style['position'] = 'absolute';\n\t\t\t\t\tmarker.style['left'] = xPos + 'px';\n\t\t\t\t\tmarker.style['top'] = yPos + 'px';\n\t\t\t\t\tmarker.style['z-index'] = me._map.style['z-index'] + 2;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map.ggInitMapMarkers=function() {\n\t\t\tme._map.ggClearMapMarkers();\n\t\t\tvar ids=player.getNodeIds();\n\t\t\tme._map.ggFilteredIds = [];\n\t\t\tif (me._map.ggFilter != '') {\n\t\t\t\tvar filter = me._map.ggFilter.split(',');\n\t\t\t\tfor (i=0; i < ids.length; i++) {\n\t\t\t\t\tvar nodeId = ids[i];\n\t\t\t\t\tvar nodeData = player.getNodeUserdata(nodeId);\n\t\t\t\t\tfor (var j=0; j < filter.length; j++) {\n\t\t\t\t\t\tif (nodeData['tags'].indexOf(filter[j].trim()) != -1) me._map.ggFilteredIds.push(nodeId);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (me._map.ggFilteredIds.length > 0) ids = me._map.ggFilteredIds;\n\t\t\t}\n\t\t\tfor(var i=0; i < ids.length; i++) {\n\t\t\t\tvar id = ids[i];\n\t\t\t\tvar coords = player.getNodeMapCoordsInPercent(id, me._map.ggMapId);\n\t\t\t\tif (coords.length>=2) {\n\t\t\t\t\tme._map.ggHMarkerAnchorOffset = 12;\n\t\t\t\t\tme._map.ggVMarkerAnchorOffset = 41;\n\t\t\t\t\tvar markerParent = new Object();\n\t\t\t\t\tmarkerParent.ggElementNodeId=function() { return id };\n\t\t\t\t\tvar markerClass = new SkinElement_map_pin_Class(me, markerParent);\n\t\t\t\t\tme._map.ggMarkerInstances.push(markerClass);\n\t\t\t\t\tvar marker = markerClass._map_pin;\n\t\t\t\t\tme._map.ggSimpleFloorplanMarkerArray[id] = marker;\n\t\t\t\t\tme._map__mapdiv.appendChild(marker);\n\t\t\t\t}\n\t\t\t}\n\t\t\tme._map.ggPlaceMarkersOnSimpleFloorplan();\n\t\t\tskin.updateSize(me._map);\n\t\tme._map.callChildLogicBlocksHotspot_map_pin_changenode();\n\t\tme._map.callChildLogicBlocksHotspot_map_pin_configloaded();\n\t\tme._map.callChildLogicBlocksHotspot_map_pin_mouseover();\n\t\tme._map.callChildLogicBlocksHotspot_map_pin_mouseover();\n\t\tme._map.callChildLogicBlocksHotspot_map_pin_active();\n\t\tme._map.callChildLogicBlocksHotspot_map_pin_hastouch();\n\t\tme._map.callChildLogicBlocksHotspot_map_pin_activehotspotchanged();\n\t\t}\n\t\tme._map.ggClearMapMarkers=function() {\n\t\t\tfor (id in me._map.ggSimpleFloorplanMarkerArray) {\n\t\t\t\tif (me._map.ggSimpleFloorplanMarkerArray.hasOwnProperty(id)) {\n\t\t\t\t\tme._map__mapdiv.removeChild(me._map.ggSimpleFloorplanMarkerArray[id]);\n\t\t\t\t}\n\t\t\t}\n\t\t\tme._map.ggMarkerInstances=[];\n\t\t\tme._map.ggSimpleFloorplanMarkerArray=[];\n\t\t}\n\t\tplayer.addListener('sizechanged', function() {\n\t\t\tme.updateSize(me.divSkin);\n\t\t});\n\t\tplayer.addListener('configloaded', function() {\n\t\t\tme._category_cloner.ggUpdate();\n\t\t\tif (me._map.ggMapNotLoaded == false) {\n\t\t\t\tme._map.ggClearMap();\n\t\t\t\tme._map.ggInitMap(false);\n\t\t\t\tme._map.ggInitMapMarkers(true);\n\t\t\t}\n\t\t});\n\t\tplayer.addListener('imagesready', function() {\n\t\t\tme._category_scroller.ggUpdatePosition();\n\t\t});\n\t};\n\tthis.hotspotProxyClick=function(id, url) {\n\t}\n\tthis.hotspotProxyDoubleClick=function(id, url) {\n\t}\n\tme.hotspotProxyOver=function(id, url) {\n\t}\n\tme.hotspotProxyOut=function(id, url) {\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_sizechanged = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_node.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_node.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_changenode = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_node.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_node.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_node_visited0 && hotspotTemplates['ht_node'][i]._ht_node_visited0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_node_visited0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_node_image0 && hotspotTemplates['ht_node'][i]._ht_node_image0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_node_image0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._hotspot_preview0 && hotspotTemplates['ht_node'][i]._hotspot_preview0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._hotspot_preview0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._tt_ht_node0 && hotspotTemplates['ht_node'][i]._tt_ht_node0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._tt_ht_node0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_node_customimage0 && hotspotTemplates['ht_node'][i]._ht_node_customimage0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_node_customimage0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_tooltip0 && hotspotTemplates['ht_node'][i]._ht_tooltip0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_tooltip0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_configloaded = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._hotspot_preview0 && hotspotTemplates['ht_node'][i]._hotspot_preview0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._hotspot_preview0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._tt_ht_node0 && hotspotTemplates['ht_node'][i]._tt_ht_node0.logicBlock_position) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._tt_ht_node0.logicBlock_position();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._tt_ht_node0 && hotspotTemplates['ht_node'][i]._tt_ht_node0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._tt_ht_node0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_mouseover = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._hotspot_preview0 && hotspotTemplates['ht_node'][i]._hotspot_preview0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._hotspot_preview0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._tt_ht_node0 && hotspotTemplates['ht_node'][i]._tt_ht_node0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._tt_ht_node0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_active = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_checkmark_tick0 && hotspotTemplates['ht_node'][i]._ht_checkmark_tick0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_checkmark_tick0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_changevisitednodes = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_node_visited0 && hotspotTemplates['ht_node'][i]._ht_node_visited0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_node_visited0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_node_image0 && hotspotTemplates['ht_node'][i]._ht_node_image0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_node_image0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_checkmark_tick0 && hotspotTemplates['ht_node'][i]._ht_checkmark_tick0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_checkmark_tick0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_hastouch = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._tt_ht_node0 && hotspotTemplates['ht_node'][i]._tt_ht_node0.logicBlock_position) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._tt_ht_node0.logicBlock_position();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_activehotspotchanged = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_node_visited0 && hotspotTemplates['ht_node'][i]._ht_node_visited0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_node_visited0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_node_image0 && hotspotTemplates['ht_node'][i]._ht_node_image0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_node_image0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._tt_ht_node0 && hotspotTemplates['ht_node'][i]._tt_ht_node0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._tt_ht_node0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_node_customimage0 && hotspotTemplates['ht_node'][i]._ht_node_customimage0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_node_customimage0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._ht_tooltip0 && hotspotTemplates['ht_node'][i]._ht_tooltip0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._ht_tooltip0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_ht_node_varchanged_opt_hotspot_preview = function(){\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._hotspot_preview0 && hotspotTemplates['ht_node'][i]._hotspot_preview0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._hotspot_preview0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['ht_node'][i]._tt_ht_node0 && hotspotTemplates['ht_node'][i]._tt_ht_node0.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['ht_node'][i]._tt_ht_node0.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_door_sizechanged = function(){\n\t\tif(hotspotTemplates['door']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['door'].length; i++) {\n\t\t\t\tif (hotspotTemplates['door'][i]._door.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._door.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_door_changenode = function(){\n\t\tif(hotspotTemplates['door']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['door'].length; i++) {\n\t\t\t\tif (hotspotTemplates['door'][i]._door.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._door.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._ht_node_visited && hotspotTemplates['door'][i]._ht_node_visited.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._ht_node_visited.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._ht_node_image && hotspotTemplates['door'][i]._ht_node_image.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._ht_node_image.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._hotspot_preview && hotspotTemplates['door'][i]._hotspot_preview.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._hotspot_preview.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._tt_ht_node && hotspotTemplates['door'][i]._tt_ht_node.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._tt_ht_node.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._ht_node_customimage && hotspotTemplates['door'][i]._ht_node_customimage.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._ht_node_customimage.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._ht_tooltip && hotspotTemplates['door'][i]._ht_tooltip.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._ht_tooltip.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_door_configloaded = function(){\n\t\tif(hotspotTemplates['door']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['door'].length; i++) {\n\t\t\t\tif (hotspotTemplates['door'][i]._hotspot_preview && hotspotTemplates['door'][i]._hotspot_preview.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._hotspot_preview.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._tt_ht_node && hotspotTemplates['door'][i]._tt_ht_node.logicBlock_position) {\n\t\t\t\t\thotspotTemplates['door'][i]._tt_ht_node.logicBlock_position();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._tt_ht_node && hotspotTemplates['door'][i]._tt_ht_node.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._tt_ht_node.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_door_mouseover = function(){\n\t\tif(hotspotTemplates['door']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['door'].length; i++) {\n\t\t\t\tif (hotspotTemplates['door'][i]._hotspot_preview && hotspotTemplates['door'][i]._hotspot_preview.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._hotspot_preview.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._tt_ht_node && hotspotTemplates['door'][i]._tt_ht_node.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._tt_ht_node.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_door_active = function(){\n\t\tif(hotspotTemplates['door']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['door'].length; i++) {\n\t\t\t\tif (hotspotTemplates['door'][i]._ht_checkmark_tick && hotspotTemplates['door'][i]._ht_checkmark_tick.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._ht_checkmark_tick.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_door_changevisitednodes = function(){\n\t\tif(hotspotTemplates['door']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['door'].length; i++) {\n\t\t\t\tif (hotspotTemplates['door'][i]._ht_node_visited && hotspotTemplates['door'][i]._ht_node_visited.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._ht_node_visited.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._ht_node_image && hotspotTemplates['door'][i]._ht_node_image.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._ht_node_image.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._ht_checkmark_tick && hotspotTemplates['door'][i]._ht_checkmark_tick.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._ht_checkmark_tick.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_door_hastouch = function(){\n\t\tif(hotspotTemplates['door']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['door'].length; i++) {\n\t\t\t\tif (hotspotTemplates['door'][i]._tt_ht_node && hotspotTemplates['door'][i]._tt_ht_node.logicBlock_position) {\n\t\t\t\t\thotspotTemplates['door'][i]._tt_ht_node.logicBlock_position();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_door_activehotspotchanged = function(){\n\t\tif(hotspotTemplates['door']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['door'].length; i++) {\n\t\t\t\tif (hotspotTemplates['door'][i]._ht_node_visited && hotspotTemplates['door'][i]._ht_node_visited.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._ht_node_visited.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._ht_node_image && hotspotTemplates['door'][i]._ht_node_image.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._ht_node_image.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._tt_ht_node && hotspotTemplates['door'][i]._tt_ht_node.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._tt_ht_node.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._ht_node_customimage && hotspotTemplates['door'][i]._ht_node_customimage.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._ht_node_customimage.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._ht_tooltip && hotspotTemplates['door'][i]._ht_tooltip.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._ht_tooltip.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tme.callChildLogicBlocksHotspot_door_varchanged_opt_hotspot_preview_1 = function(){\n\t\tif(hotspotTemplates['door']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['door'].length; i++) {\n\t\t\t\tif (hotspotTemplates['door'][i]._hotspot_preview && hotspotTemplates['door'][i]._hotspot_preview.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._hotspot_preview.logicBlock_visible();\n\t\t\t\t}\n\t\t\t\tif (hotspotTemplates['door'][i]._tt_ht_node && hotspotTemplates['door'][i]._tt_ht_node.logicBlock_visible) {\n\t\t\t\t\thotspotTemplates['door'][i]._tt_ht_node.logicBlock_visible();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tplayer.addListener('changenode', function() {\n\t\tme.ggUserdata=player.userdata;\n\t});\n\tme.skinTimerEvent=function() {\n\t\tme.ggCurrentTime=new Date().getTime();\n\t};\n\tplayer.addListener('timer', me.skinTimerEvent);\n\tfunction SkinHotspotClass_ht_node(parentScope,hotspot) {\n\t\tvar me=this;\n\t\tvar flag=false;\n\t\tvar hs='';\n\t\tme.parentScope=parentScope;\n\t\tme.hotspot=hotspot;\n\t\tvar nodeId=String(hotspot.url);\n\t\tnodeId=(nodeId.charAt(0)=='{')?nodeId.substr(1, nodeId.length - 2):''; // }\n\t\tme.ggUserdata=skin.player.getNodeUserdata(nodeId);\n\t\tme.elementMouseDown=[];\n\t\tme.elementMouseOver=[];\n\t\tme.findElements=function(id,regex) {\n\t\t\treturn skin.findElements(id,regex);\n\t\t}\n\t\tel=me._ht_node=document.createElement('div');\n\t\tel.ggId=\"ht_node\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_hotspot \";\n\t\tel.ggType='hotspot';\n\t\ths ='';\n\t\ths+='height : 0px;';\n\t\ths+='left : 75px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 130px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 0px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_node.ggIsActive=function() {\n\t\t\treturn player.getCurrentNode()==this.ggElementNodeId();\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif (me.hotspot.url!='' && me.hotspot.url.charAt(0)=='{') { // }\n\t\t\t\treturn me.hotspot.url.substr(1, me.hotspot.url.length - 2);\n\t\t\t} else {\n\t\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t\t} else {\n\t\t\t\t\treturn player.getCurrentNode();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_node.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('vis_userdata') == true)) || \n\t\t\t\t((player.getVariableValue('vis_image_popup') == true)) || \n\t\t\t\t((player.getVariableValue('vis_info_popup') == true)) || \n\t\t\t\t((player.getVariableValue('vis_video_popup_file') == true)) || \n\t\t\t\t((player.getVariableValue('vis_video_popup_url') == true)) || \n\t\t\t\t((player.getVariableValue('vis_video_popup_vimeo') == true)) || \n\t\t\t\t((player.getVariableValue('vis_video_popup_youtube') == true)) || \n\t\t\t\t((player.getVariableValue('vis_website') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_node.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_node.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_node.style[domTransition]='';\n\t\t\t\tif (me._ht_node.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_node.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_node.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_node.style.visibility=(Number(me._ht_node.style.opacity)>0||!me._ht_node.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_node.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_node.onclick=function (e) {\n\t\t\tplayer.openNext(me.hotspot.url,me.hotspot.target);\n\t\t\tskin.hotspotProxyClick(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_node.ondblclick=function (e) {\n\t\t\tskin.hotspotProxyDoubleClick(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_node.onmouseover=function (e) {\n\t\t\tplayer.setActiveHotspot(me.hotspot);\n\t\t\tme.elementMouseOver['ht_node']=true;\n\t\t\tme._hotspot_preview0.logicBlock_visible();\n\t\t\tme._tt_ht_node0.logicBlock_visible();\n\t\t\tskin.hotspotProxyOver(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_node.onmouseout=function (e) {\n\t\t\tplayer.setActiveHotspot(null);\n\t\t\tme.elementMouseOver['ht_node']=false;\n\t\t\tme._hotspot_preview0.logicBlock_visible();\n\t\t\tme._tt_ht_node0.logicBlock_visible();\n\t\t\tskin.hotspotProxyOut(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._ht_node.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['ht_node']=false;\n\t\t\tme._hotspot_preview0.logicBlock_visible();\n\t\t\tme._tt_ht_node0.logicBlock_visible();\n\t\t}\n\t\tme._ht_node.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._ht_node_visited0=document.createElement('div');\n\t\tels=me._ht_node_visited0__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_ht_node_visited0';\n\t\ths=basePath + 'images/ht_node_visited0.png';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_button';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"ht_node_visited\";\n\t\tel.ggDx=0;\n\t\tel.ggDy=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_button \";\n\t\tel.ggType='button';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 30px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 30px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_node_visited0.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_node_visited0.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.nodeVisited(me._ht_node_visited0.ggElementNodeId()) == true)) && \n\t\t\t\t((me.hotspot.customimage == \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_node_visited0.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_node_visited0.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_node_visited0.style[domTransition]='';\n\t\t\t\tif (me._ht_node_visited0.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_node_visited0.style.visibility=(Number(me._ht_node_visited0.style.opacity)>0||!me._ht_node_visited0.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_node_visited0.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_node_visited0.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_node_visited0.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_node_visited0.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=(this.ggDy + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._ht_node.appendChild(me._ht_node_visited0);\n\t\tel=me._ht_node_image0=document.createElement('div');\n\t\tels=me._ht_node_image0__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_ht_node_image0';\n\t\ths=basePath + 'images/ht_node_image0.png';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_button';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"ht_node_image\";\n\t\tel.ggDx=0;\n\t\tel.ggDy=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_button \";\n\t\tel.ggType='button';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 30px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 30px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_node_image0.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_node_image0.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.nodeVisited(me._ht_node_image0.ggElementNodeId()) == true)) || \n\t\t\t\t((me.hotspot.customimage != \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_node_image0.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_node_image0.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_node_image0.style[domTransition]='';\n\t\t\t\tif (me._ht_node_image0.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_node_image0.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_node_image0.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_node_image0.style.visibility=(Number(me._ht_node_image0.style.opacity)>0||!me._ht_node_image0.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_node_image0.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_node_image0.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=(this.ggDy + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._ht_node.appendChild(me._ht_node_image0);\n\t\tel=me._hotspot_preview0=document.createElement('div');\n\t\tel.ggId=\"hotspot_preview\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='z-index: 100;';\n\t\ths+='height : 100px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -130px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 150px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._hotspot_preview0.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._hotspot_preview0.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['ht_node'] == true)) && \n\t\t\t\t((player.getVariableValue('opt_hotspot_preview') == true)) && \n\t\t\t\t((player.getIsTour() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._hotspot_preview0.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._hotspot_preview0.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._hotspot_preview0.style[domTransition]='';\n\t\t\t\tif (me._hotspot_preview0.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._hotspot_preview0.style.visibility=(Number(me._hotspot_preview0.style.opacity)>0||!me._hotspot_preview0.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._hotspot_preview0.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._hotspot_preview0.style.visibility=\"hidden\";\n\t\t\t\t\tme._hotspot_preview0.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._hotspot_preview0.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._ht_preview_picture_frame_0=document.createElement('div');\n\t\tel.ggId=\"ht_preview_picture_frame \";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_rectangle \";\n\t\tel.ggType='rectangle';\n\t\ths ='';\n\t\ths+='background : rgba(0,0,0,0.666667);';\n\t\ths+='border : 0px solid #000000;';\n\t\ths+='cursor : default;';\n\t\ths+='height : 100px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 150px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_preview_picture_frame_0.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_preview_picture_frame_0.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._hotspot_preview0.appendChild(me._ht_preview_picture_frame_0);\n\t\tel=me._ht_preview_nodeimage0=document.createElement('div');\n\t\tels=me._ht_preview_nodeimage0__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_nodeimage';\n\t\tels.setAttribute('src',basePath + \"images/ht_preview_nodeimage_\" + nodeId + \".jpg\");\n\t\tel.ggNodeId=nodeId;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_nodeimage';\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"ht_preview_nodeImage\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_nodeimage \";\n\t\tel.ggType='nodeimage';\n\t\ths ='';\n\t\ths+='height : 90px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 5px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 140px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='0% 0%';\n\t\tme._ht_preview_nodeimage0.ggIsActive=function() {\n\t\t\treturn player.getCurrentNode()==this.ggElementNodeId();\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn this.ggNodeId;\n\t\t}\n\t\tme._ht_preview_nodeimage0.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._hotspot_preview0.appendChild(me._ht_preview_nodeimage0);\n\t\tel=me._ht_tooltip0=document.createElement('div');\n\t\tels=me._ht_tooltip0__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"ht_tooltip\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='bottom : 5px;';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 140px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='bottom: 0px;';\n\t\ths+='width: 140px;';\n\t\ths+='height: auto;';\n\t\ths+='pointer-events: none;';\n\t\ths+='background: #000000;';\n\t\ths+='background: rgba(0,0,0,0.392157);';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: pre-wrap;';\n\t\ths+='padding: 2px 3px 2px 3px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=me.hotspot.title;\n\t\tel.appendChild(els);\n\t\tme._ht_tooltip0.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_tooltip0.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.hotspot.title == \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_tooltip0.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_tooltip0.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_tooltip0.style[domTransition]='';\n\t\t\t\tif (me._ht_tooltip0.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_tooltip0.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_tooltip0.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_tooltip0.style.visibility=(Number(me._ht_tooltip0.style.opacity)>0||!me._ht_tooltip0.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_tooltip0.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_tooltip0.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._hotspot_preview0.appendChild(me._ht_tooltip0);\n\t\tel=me._ht_checkmark_tick0=document.createElement('div');\n\t\tels=me._ht_checkmark_tick0__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHZlcnNpb249IjEuMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSItMjQwIDMzMiAxMzAgMTMwIiB4PSIwcHgiIHk9IjBweCIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAtMjQwIDMzMiAxMzAgMTMwOyIgaWQ9IkxheWVyXzEiIHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3Ln'+\n\t\t\t'czLm9yZy8xOTk5L3hsaW5rIj4KIDxzdHlsZSB0eXBlPSJ0ZXh0L2NzcyI+JiN4ZDsKCS5zdDB7ZmlsbDojMDAwMDAwO30mI3hkOwoJLnN0MXtmaWxsOiNGRkZGRkY7fSYjeGQ7Cjwvc3R5bGU+CiA8ZyBpZD0iTGF5ZXJfMV8xXyIvPgogPGcgaWQ9IkxheWVyXzIiPgogIDxwYXRoIGNsYXNzPSJzdDAiIGQ9Ik0tMTIyLjEsMzQxLjVoLTEwNS44Yy0xLjQsMC0yLjYsMS4xLTIuNiwyLjZ2MTA1LjhjMCwxLjQsMS4xLDIuNiwyLjYsMi42aDEwNS44YzEuNCwwLDIuNi0xLjEsMi42LTIuNlYzNDQuMSYjeGQ7JiN4YTsmI3g5OyYjeDk7Qy0xMTkuNiwzNDIuNy0xMjAuNywzNDEuNS0xMjIuMSwzNDEuNXog'+\n\t\t\t'TS0xMzIuOCwzODEuN2wtNTAuOCw1MC44Yy0wLjMsMC4zLTAuOCwwLjUtMS4yLDAuNWMtMC41LDAtMC45LTAuMS0xLjMtMC41bC0zMS43LTMxLjgmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC43LTAuNy0wLjctMS43LDAtMi40bDEyLjUtMTIuNWMwLjctMC43LDEuNy0wLjcsMi40LDBsMTgsMThsMzcuMS0zNy4xYzAuNy0wLjcsMS43LTAuNywyLjQsMGwxMi41LDEyLjUmI3hkOyYjeGE7JiN4OTsmI3g5O0MtMTMyLjEsMzc5LjktMTMyLjEsMzgxLTEzMi44LDM4MS43eiIvPgogIDxwYXRoIGNsYXNzPSJzdDEiIGQ9Ik0tMTQ3LjcsMzY2LjhsLTM3LjEsMzcuMWwtMTgtMThjLTAuNy0wLjctMS43LTAuNy'+\n\t\t\t'0yLjQsMGwtMTIuNSwxMi41Yy0wLjcsMC43LTAuNywxLjcsMCwyLjRsMzEuNywzMS44JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4zLDAuMywwLjgsMC41LDEuMywwLjVjMC40LDAsMC45LTAuMiwxLjItMC41bDUwLjgtNTAuOWMwLjctMC43LDAuNy0xLjcsMC0yLjRsLTEyLjUtMTIuNUMtMTQ1LjksMzY2LjEtMTQ3LDM2Ni4xLTE0Ny43LDM2Ni44eiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._ht_checkmark_tick0__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"ht_checkmark_tick\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='height : 20px;';\n\t\ths+='position : absolute;';\n\t\ths+='right : 7px;';\n\t\ths+='top : 7px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 20px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_checkmark_tick0.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_checkmark_tick0.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.nodeVisited(me._ht_checkmark_tick0.ggElementNodeId()) == true)) || \n\t\t\t\t((me._ht_checkmark_tick0.ggIsActive() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_checkmark_tick0.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_checkmark_tick0.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_checkmark_tick0.style[domTransition]='';\n\t\t\t\tif (me._ht_checkmark_tick0.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_checkmark_tick0.style.visibility=(Number(me._ht_checkmark_tick0.style.opacity)>0||!me._ht_checkmark_tick0.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_checkmark_tick0.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_checkmark_tick0.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_checkmark_tick0.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_checkmark_tick0.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._hotspot_preview0.appendChild(me._ht_checkmark_tick0);\n\t\tme._ht_node.appendChild(me._hotspot_preview0);\n\t\tel=me._tt_ht_node0=document.createElement('div');\n\t\tels=me._tt_ht_node0__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"tt_ht_node\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='z-index: 100;';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 24px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 100px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: auto;';\n\t\ths+='height: auto;';\n\t\ths+='pointer-events: none;';\n\t\ths+='background: #000000;';\n\t\ths+='background: rgba(0,0,0,0.666667);';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: nowrap;';\n\t\ths+='padding: 2px 3px 2px 3px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=me.hotspot.title;\n\t\tel.appendChild(els);\n\t\tme._tt_ht_node0.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._tt_ht_node0.logicBlock_position = function() {\n\t\t\tvar newLogicStatePosition;\n\t\t\tif (\n\t\t\t\t((player.getHasTouch() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStatePosition = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStatePosition = -1;\n\t\t\t}\n\t\t\tif (me._tt_ht_node0.ggCurrentLogicStatePosition != newLogicStatePosition) {\n\t\t\t\tme._tt_ht_node0.ggCurrentLogicStatePosition = newLogicStatePosition;\n\t\t\t\tme._tt_ht_node0.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_ht_node0.ggCurrentLogicStatePosition == 0) {\n\t\t\t\t\tthis.ggDx = 0;\n\t\t\t\t\tme._tt_ht_node0.style.top='-47px';\n\t\t\t\t\tme._tt_ht_node0.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_ht_node0.ggDx=0;\n\t\t\t\t\tme._tt_ht_node0.style.top='24px';\n\t\t\t\t\tme._tt_ht_node0.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_ht_node0.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['ht_node'] == true)) && \n\t\t\t\t((me.hotspot.title != \"\")) && \n\t\t\t\t((player.getIsTour() == false)) && \n\t\t\t\t((player.getVariableValue('opt_hotspot_preview') == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((me.elementMouseOver['ht_node'] == true)) && \n\t\t\t\t((me.hotspot.title != \"\")) && \n\t\t\t\t((player.getIsTour() == true)) && \n\t\t\t\t((player.getVariableValue('opt_hotspot_preview') == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 1;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((me.elementMouseOver['ht_node'] == true)) && \n\t\t\t\t((me.hotspot.title != \"\")) && \n\t\t\t\t((player.getIsTour() == false)) && \n\t\t\t\t((player.getVariableValue('opt_hotspot_preview') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 2;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._tt_ht_node0.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._tt_ht_node0.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._tt_ht_node0.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_ht_node0.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._tt_ht_node0.style.visibility=(Number(me._tt_ht_node0.style.opacity)>0||!me._tt_ht_node0.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._tt_ht_node0.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse if (me._tt_ht_node0.ggCurrentLogicStateVisible == 1) {\n\t\t\t\t\tme._tt_ht_node0.style.visibility=(Number(me._tt_ht_node0.style.opacity)>0||!me._tt_ht_node0.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._tt_ht_node0.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse if (me._tt_ht_node0.ggCurrentLogicStateVisible == 2) {\n\t\t\t\t\tme._tt_ht_node0.style.visibility=(Number(me._tt_ht_node0.style.opacity)>0||!me._tt_ht_node0.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._tt_ht_node0.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_ht_node0.style.visibility=\"hidden\";\n\t\t\t\t\tme._tt_ht_node0.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_ht_node0.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t\tthis.style[domTransition]='left 0';\n\t\t\tthis.ggTextDiv.style.left=((98-this.ggTextDiv.offsetWidth)/2) + 'px';\n\t\t}\n\t\tme._ht_node.appendChild(me._tt_ht_node0);\n\t\tel=me._ht_node_customimage0=document.createElement('div');\n\t\tels=me._ht_node_customimage0__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_external';\n\t\tels.setAttribute('style','position: absolute;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.onload=function() {me._ht_node_customimage0.ggUpdatePosition();}\n\t\tif ((hotspot) && (hotspot.customimage)) {\n\t\t\tel.ggText=hotspot.customimage;\n\t\t\tels.setAttribute('src', hotspot.customimage);\n\t\t\tels.style.width=hotspot.customimagewidth + 'px';\n\t\t\tels.style.height=hotspot.customimageheight + 'px';\n\t\t\tme.ggUse3d = hotspot.use3D;\n\t\t\tme.gg3dDistance = hotspot.distance3D;\n\t\t}\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\ths ='';\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"ht_node_CustomImage\";\n\t\tel.ggDx=0;\n\t\tel.ggDy=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_external \";\n\t\tel.ggType='external';\n\t\ths ='';\n\t\ths+='border : 0px solid #000000;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 50px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 50px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_node_customimage0.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_node_customimage0.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.hotspot.customimage == \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_node_customimage0.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_node_customimage0.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_node_customimage0.style[domTransition]='';\n\t\t\t\tif (me._ht_node_customimage0.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_node_customimage0.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_node_customimage0__img.src = '';\n\t\t\t\t\tme._ht_node_customimage0.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_node_customimage0.style.visibility=(Number(me._ht_node_customimage0.style.opacity)>0||!me._ht_node_customimage0.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_node_customimage0.ggSubElement.src=me._ht_node_customimage0.ggText;\n\t\t\t\t\tme._ht_node_customimage0.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_node_customimage0.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=(this.ggDy + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t\tvar parentWidth = me._ht_node_customimage0.clientWidth;\n\t\t\tvar parentHeight = me._ht_node_customimage0.clientHeight;\n\t\t\tvar img = me._ht_node_customimage0__img;\n\t\t\tvar aspectRatioDiv = me._ht_node_customimage0.clientWidth / me._ht_node_customimage0.clientHeight;\n\t\t\tvar aspectRatioImg = img.naturalWidth / img.naturalHeight;\n\t\t\tif (img.naturalWidth < parentWidth) parentWidth = img.naturalWidth;\n\t\t\tif (img.naturalHeight < parentHeight) parentHeight = img.naturalHeight;\n\t\t\tvar currentWidth,currentHeight;\n\t\t\tif ((hotspot) && (hotspot.customimage)) {\n\t\t\t\tcurrentWidth = hotspot.customimagewidth;\n\t\t\t\tcurrentHeight = hotspot.customimageheight;\n\t\t\t}\n\t\t\timg.style.left='50%';\n\t\t\timg.style.marginLeft='-' + currentWidth/2 + 'px';\n\t\t\timg.style.top='50%';\n\t\t\timg.style.marginTop='-' + currentHeight/2 + 'px';\n\t\t}\n\t\tme._ht_node.appendChild(me._ht_node_customimage0);\n\t\tif ((hotspot) && (hotspot.customimage)) {\n\t\t\tel.style.width=hotspot.customimagewidth + 'px';\n\t\t\tel.style.height=hotspot.customimageheight + 'px';\n\t\t}\n\t\tme.__div = me._ht_node;\n\t};\n\tfunction SkinHotspotClass_door(parentScope,hotspot) {\n\t\tvar me=this;\n\t\tvar flag=false;\n\t\tvar hs='';\n\t\tme.parentScope=parentScope;\n\t\tme.hotspot=hotspot;\n\t\tvar nodeId=String(hotspot.url);\n\t\tnodeId=(nodeId.charAt(0)=='{')?nodeId.substr(1, nodeId.length - 2):''; // }\n\t\tme.ggUserdata=skin.player.getNodeUserdata(nodeId);\n\t\tme.elementMouseDown=[];\n\t\tme.elementMouseOver=[];\n\t\tme.findElements=function(id,regex) {\n\t\t\treturn skin.findElements(id,regex);\n\t\t}\n\t\tel=me._door=document.createElement('div');\n\t\tel.ggId=\"door\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_hotspot \";\n\t\tel.ggType='hotspot';\n\t\ths ='';\n\t\ths+='height : 0px;';\n\t\ths+='left : 75px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 130px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 0px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._door.ggIsActive=function() {\n\t\t\treturn player.getCurrentNode()==this.ggElementNodeId();\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif (me.hotspot.url!='' && me.hotspot.url.charAt(0)=='{') { // }\n\t\t\t\treturn me.hotspot.url.substr(1, me.hotspot.url.length - 2);\n\t\t\t} else {\n\t\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t\t} else {\n\t\t\t\t\treturn player.getCurrentNode();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._door.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.getVariableValue('vis_userdata') == true)) || \n\t\t\t\t((player.getVariableValue('vis_image_popup') == true)) || \n\t\t\t\t((player.getVariableValue('vis_info_popup') == true)) || \n\t\t\t\t((player.getVariableValue('vis_video_popup_file') == true)) || \n\t\t\t\t((player.getVariableValue('vis_video_popup_url') == true)) || \n\t\t\t\t((player.getVariableValue('vis_video_popup_vimeo') == true)) || \n\t\t\t\t((player.getVariableValue('vis_video_popup_youtube') == true)) || \n\t\t\t\t((player.getVariableValue('vis_website') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._door.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._door.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._door.style[domTransition]='';\n\t\t\t\tif (me._door.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._door.style.visibility=\"hidden\";\n\t\t\t\t\tme._door.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._door.style.visibility=(Number(me._door.style.opacity)>0||!me._door.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._door.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._door.onclick=function (e) {\n\t\t\tplayer.openNext(me.hotspot.url,me.hotspot.target);\n\t\t\tskin.hotspotProxyClick(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._door.ondblclick=function (e) {\n\t\t\tskin.hotspotProxyDoubleClick(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._door.onmouseover=function (e) {\n\t\t\tplayer.setActiveHotspot(me.hotspot);\n\t\t\tme.elementMouseOver['door']=true;\n\t\t\tme._hotspot_preview.logicBlock_visible();\n\t\t\tme._tt_ht_node.logicBlock_visible();\n\t\t\tskin.hotspotProxyOver(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._door.onmouseout=function (e) {\n\t\t\tplayer.setActiveHotspot(null);\n\t\t\tme.elementMouseOver['door']=false;\n\t\t\tme._hotspot_preview.logicBlock_visible();\n\t\t\tme._tt_ht_node.logicBlock_visible();\n\t\t\tskin.hotspotProxyOut(me.hotspot.id, me.hotspot.url);\n\t\t}\n\t\tme._door.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['door']=false;\n\t\t\tme._hotspot_preview.logicBlock_visible();\n\t\t\tme._tt_ht_node.logicBlock_visible();\n\t\t}\n\t\tme._door.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._ht_node_visited=document.createElement('div');\n\t\tels=me._ht_node_visited__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_ht_node_visited';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAYAAACtWK6eAAAgAElEQVR4nO2dfXQUVZr/n1vV3XkjIW8SXpIAIhAQFFgCi+EXRInjCg5rnAMyZM9ZZgQ5646wc1R0ZtEZdebMcdD5qeNvHHc9iMCMM4IuKCyLiAgygLxkQB0EXEHeQ3hJQl77pe7vj/RNbt++t6q6u7qruvt+zrmnKpXuqqeq61vPc+997i0AiUQikUgkEolEIpFIJBKJRCKRSCQSiUQikUgkEolEIpFIJBKJRGIPyG4D4oCZc8LR7hxjjAAgBwByASADANoB4DpCqCPafUqcSzIKJBE2Y4xxGQBMBYBRADAyWIZAtzAUznf8ANAEAF8DwLFg+RIAdiGEriXAZkkccLpAzNoXy3lgAIDz589nlZSUzEIIzUAI3QEAw2LYJ40GAH8FgO0A8N8AsAMhpF'+\n\t\t\t'm0b0kaggyKwilqNOX22293dXV1Tdc0bSXGuBknhjMY419hjEcn6oJKkp9IBEHf5K5gcXOKh1PcAOD+8Y9/nNXR0bFA07SvEiQKEdsxxnck6BpLkhAzomAFwRNABlUygyWLKZl33XVXTmtr68Oapp20WRgsezDG30nQNZdEgF11ENFxEWfJ2wbQW1Fmt3P3f/z48cobb7zx/6qqekvk5iaM/wKAJQih03YbIrEHI4/BegraQxBPkA3dzax9oLtFKS9Y+gZLPgAUkPLTn/50cGtr61sYY81uN2GSNozxMoyxmpifRKJHIj0I71h6XoEIR09UrKehPQ7s2LFj3NSpU/9DVdVy604jYewAgO8jhC7YbUg6kwiBxCIMoyW73rPPkydPPjh48OCfIITcVp5MgrkEAHUIoQ/tNiRdibdA2P3rCYO++XnrquD/ISIZOHCg6/Dh'+\n\t\t\t'w78sLi6ujccJ2YAGAI8ghF6125B0JJ4C0ROHmb4NtiVL9L8egYwdOzbzk08+ebGgoGBa/E7LNp5FCD1ltxHpRjwEYsZrsOGRSi3pyroi2BZWJk2alLN169ZX+vbte2sczskpvAYA/4IQijqXTBIZVgvErNcQeQgzPeD05xAAqKWlpZ76+voXiouLJ1h8Pk5kBULoMbuNSBesFIiRONh6Ba9pV4He3nGVWrLrPaLKyMhQjx8//lR5efn/sfBcnM5jCKEVdhuRDlglED1x0CEVHSKxPeR06ghbhCKpr69/aNy4cfdadB7JAobuJuC37TYk1XFZsA+eONj6Bi+U4onCLfib/lyPuF5//fWqNBQHQPc1/Q+McT1C6JjdxqQysXoQkTiMEg1ZD0GE4IFwobAiUQFAnT179oB33nnnObfbnRXjOSQzRwBgMkKo025DUhUrBW'+\n\t\t\t'Im4ZAOmUjSIZuASG/jCiQ7O9v9zTff/HtJScngGO1PBX6HEPoXu41IVXgj48zCEwdZZ8XBegs6E5fOvhVl4oaUlStX3iPF0cNijPEUu41IVaL1ILzMWVFIxYZTxEvQy5DxGkwJqahPmjSpcNeuXU96PJ6MKG1PRf4KABMRQgG7DUk1ovEgeuJgK+Qiz8GO3aBLFoR7lJ7xHr///e/vl+IIYxwAPGy3EalILCEWge0R1xMHb2ATTxyZzGczACBjzpw5Q8eNGzfWAptTkeUY42y7jUg1IhWIUaWciIQdDmvGc9DCoAXSE4ItW7ZseqQnmEYUA8Biu41INSIRiCi0ogViJA49L0JvY8XhrqmpGTB+/PhREZ9hevEoxliGnxYSaysWbzSgSCBEHKIQKhN0Kus/+clPpiCUyPFdSckAAKiz24hUwqxAeKEVL7eKJw438L0D'+\n\t\t\t'KxRaHHR/iKuwsDBzypQp0nuY45/tNiCViLYOwtY/9Kbh4YVWGcx21mvQHYPKkiVLRmZkZHiiOsP0owpjPNRuI1IFMwLRSyfhpaizrVb0khaKKJwKS1Ksra0dE+0JpiEIAP7JbiNShUgr6Xp5VqJJ3ETCYAVCi6JntGD//v0zR48enYyTLthJqgw3th2jbF7RhAu80IrOrzIrDDbXKkQcAIDmzp1bpiiKY2rnGGPc2dnZ5fV6vT6fz+9yuZTMIHbbRnELxrgIIXTFbkOSHbPp7pEkIrKtV6xgeHUNrjgAAE2fPr0sxnOMGk3T8OnTpy8dPHjwzN69ey8cOnToyr59+5ra2tp8ABCgij8/Px9Pnz49b9q0af0qKyvLRo0aVVFQUDDQJtMRAEwHgHU2HT9l0Hsyi1queK1VdF2Dl3jItlhx86wgXIjo22+//X55efkNsZ'+\n\t\t\t'+qeU6fPt34/vvvH33ppZeOnThxoj24GTMlAN0zjgSg+9UHfgDwAYA3WDpra2vzH3nkkUmTJk26IysrqziR5wAyy9cSzAiEHvxkNPshm41LC4QOtYhA6KG2YZPEZWdnq9evX384USHW0aNHz77wwgufvfHGG2cEHzESCS2QrmDpzMrK6lq1atXke+65Z15OTk6iPOI+hNDfJ+hYKUsk/SBmQyxRRi63hYraH3sMmDx5ct9EiOPy5cvNjzzyyH+NHj16nY44gGOjXh9Qz3l3dHSoc+bM2TVw4MCFO3fufDEQCLTG83yCjEzAMVIekUCMKud0BT1ScfCm7wkTBwDA+PHjC2I5OTNs2rTp0LBhw9585ZVXvoFub0CKaGodvZY8ujWPvR6elpYWNG3atPfnzZv3wLVr1/4Sx9MCAMjHGPeL8zFSHiMPIuo1Z6ff0RtTbiQO'+\n\t\t\t'ViA9jBo1Kj/G8xPS2dnZtWzZsvdmzZq1raWlxQu9oiBLdp2Hmf6gsOU777zTVFJSsuTEiROv6OzbCqQXiZFoetJFWbu8pyYvpGJbq2jo+F4rKSmJS/p2a2tr2wMPPLD6+eefPwqhrVGkTkF7EZ5wgLKdd030vKsLAFw+n08ZMWLEf/7lL3/5N4yxLx7nCQD947TftMFsTzrrRXgTvRlN2aMy++B6DaBEkpOTY/nE0y0tLS0zZ858Y8OGDWehu1Ltg95WKD+Ei4WtmLNPfNH14c3aEnadqqqqtn766acPxUkkuXHYZ1rBE4go34oXe+uJg+1EpIWlKwzoFYil+VednZ0ddXV1b+zcufMCdLc0+UAsEtI6xQoFwFgoZq5PzzWqrq7edeTIkR9x9hkrUiAxEmmqSSTThXJTR8Cc99AAIJCdnW2ZB8EYa8uWLXvj/fffPw'+\n\t\t\t'3dza9eakkKTzCsUPQq8PS50deGV4EPuV7jxo3bcuHChV9Zdb5B8izeX9phpic9kiZe4QyIECoSnjDIsucmdLvdVgwJBgCATZs2bXz55Ze/gPCQiLWRLLXgElO2Y9AXOEHkaUVFAQBl2LBhr37++edf5+TkuDweT8Dj8QRUVcUulwsjhLCidF8ORVHMeprPTX5OIsBsLpYozmZFwHb8iTwHgQ1ZyNM5AACaVbOYX7hw4Xhtbe27wT+NWuTYokGowFnBmGkSZx8SvL+Vjo4OdNNNN30Avd6MDvXYEE+SAEQCMVP/ED0deaGFyHMAhIqD3AwaAASsEAjGOPD000+/5vP52jnnwNrsYpZkXcvPz894+OGHh1dXVw8dMmRIv4KCgly32+3q6uryNTY2thw7dqxh8+bNJ996663Tfr+ftlt07Xh/s5/VqH1IUdgAe8PyPAYd'+\n\t\t\t'O5PUEjalJJtZZkFoagn5Pq95lxUHSdsInDhxYsFNN910Uywn+MUXX3wwduzY3wnOixVHWEtTRUVF39/85jd3Tp8+fVJGRoZhxu61a9ea//znP+979NFH97e2tnYFz4XUdzqDpSNY2ql18r8uCK0H8eo+UiwJwmwzL1myYRbvZmO3c3vJgaqMQ6gwehL/EEIaxICmaf6f//znb0HoDcjepKK/u15++eVb6uvrl919993VZsQBAFBQUND3oYceuuubb75ZXFdXNwjMdTSynkP0P/q3kCQAM3UQo2ZeNuQi20XCAOCHVWECiaAyyuXMmTNb1q1bdwbCby6VWrIexKWqqnv37t3fnzx58l3RHvuGG24oWrVq1YMTJ058d+nSpXtA3DSst9QjWpFI7xMBegJBzLqRWHjrZirlrDhIeOFVFCUmD7Jly5b10B3e0OfDq0e5gs'+\n\t\t\t'd2AYDr8OHDi26++eaoxUFQFEVdsmTJ92pqaioCgYBXVdWAoiiay+UKqKoaUFU1QNZdLpcW3KapqqopiqIpioIVRcEIIVLIruN+k1s0g4wGAFegexb6TQih81bsNJFE0swLIA6vROGUWe/BjqeIWSBdXV3fLl68+ICJ81ChVxz+HTt2zLNCHPRxR48eLWeDBAhgjNcDwDKE0Cm7jTGLqA7Cc/WiuoieR4lGHD1jKWIRSENDwzYIDdnIMWgvFSLIJ554YlB1dfUPoz2mRBcVAOYAwBGM8T/abYxZjFJNeP/T8xRsCxWNac8RLDEJ5OjRo3upY/LqO2HHf/TRR/8VIWR2GLIkOnIBYB3G+D67DTGD2VYsXiuKnjiiqZj7gEkBiaGSrv3yl788aPCZkHrQiy++OLyoqEi+ZyMxqADwVjLM3xVpLha9JOuiJki2cs72lNPi'+\n\t\t\t'oPOgekQSrQfxer0Xdu7c2Qn8Hn9u+FdbWzsrmmNJoqYPAPzabiOMoAUiCql4fxu1z+u1XLEhDl0XIEIhHiQqgbS3t58C/gAu4fRCJSUlU6M5liQm7sMYO3rOM7MeRFRZ11sSTPV5QLhIvNGmmrS2tjZC+BuseFMPuQDANWHChD6ZmZmOd/cpiAIAjn5LcSQV0khEwqJRS3YWELZlqUck0dZBOjo6uqA7zYW2iewrbBDUd7/73TId2yXxZZzdBugRaT8Iu10PdgQeL7xiW7BCBi7F4EG80C0QXkdl2FDavLy8vtEcR2IJCZ3zLFKMetL16iDsNnadFYheMyvbN+GHGLJ5McYkkZI+B16TrwYAuLm52bJxJ5KI6bLbAD2iafMXeQ69ijl7U7IdeHQnHj3sNSpcLlcumBeIVl9f387bjyQh/K/dBugRa6eYmbidl3fF8y'+\n\t\t\t'DsePCoB0x5PJ6+EIFANm3a1O7z+drdbrd8CWbi2WG3AXpYHVpgZp0tIQOiIFQovOl3oqKwsHAghI9Z4ZVMAMgKBAIZZ8+e/Sra40mi5gwAfGS3EXrEI/bmzf6hMUVPHEaTtRlSUFDQH/Qn0Q57J/v27dsPRXs8SdT8DCEUdSidCOJZOWV7z0UC4U3YFlOau9vtzpg1a1Y58F8UyhXIk08++XlHR8f1WI4riYgPAGCl3UYYYaVAeE98XohlpsTkQQAA7r333pEQ/tIe3kt9MgEgo7GxUVm3bt2HsRxTYppPAGCeVZNyxJN4exACO5Unb66psPmmMMZRd95Nnjx5BIS+vId9JXXYu9sffPDB/WfOnDkd7TElhvgBYAUA3IUQSsQM9zETj0q6mcJOEM0Lr2Lq2R4zZszwoUOH5oLxxNo9gvF6va65c+f+ubW1NSl+vCTi'+\n\t\t\t'JAC8BACjEUKPIYS8Rl9wCokY+2DkSdgORUtQVVVdunTpmCVLlvyVY4+w7Nmzp62urm7N2rVr/yknJycnVjvOnj17fvHixe+2tbX5o9yFZdclOIwWByfDwIqiaAghv6IoAVVVfaS43W6vx+Pp8ng8XZmZmd6srKyu7Ozsrtzc3K4+ffr48vPzvbm5ub6CggJ/Tk6OlpubG8jKytKys7Ox2+3GHo8HAwB4PB4/AFxGCCVt3U5vxCCdJk6/85yd7oee6oe8SYo8rcncTqRz0As6s4hA6GRpqLm5+c28vLyo35LU0NBwtbS0dKXf33Nv8jow6Z7+nv9VVVUVvP322/eXlpZGPUP6wYMH/zZz5syNDQ0Ndj4xeU3v9LAD7uvjIPR3ov+mp2sVTU1EX+ekJt4pFuwF4l040WdipqSkpPDxxx8fCeGDukQzsfSs7969u7miom'+\n\t\t\t'LV2rVrd3R1dUV0gzc1NbU888wz702cOPG9hoaGABhPPSp6b4oVRe9YejaIJv5Lq6TOeHsQBL1PLPKEYp9MZEk/kTBY4EEAABoaGq4NGzZsdVtbG5m+EzjLEO/Bfmbw4MGZy5cvv3XGjBmjy8vL+yPOlB9+vz9w/Pjxbzdu3PjFc88997fg8ZyGGQ9C3q1I/z6sFyGfozMgUtKDpLxAAADefPPN3QsWLNhHbdILtdj/hXxn0KBBGbfffnvxkCFDcnNyctytra2+Y8eONW/btq2xubk52npGotDLi6MFQouhHUJ/MyIgL0iBWCoQP1BvfoUE1EEIPp/PP3PmzDUffvjhleAmkTBEQkkk8TgeK3Te4DWRQHizUqZNHSTerVi8AVWiiR1E6zHjdrtdq1atunfMmDGrr169SuoTRk3RAPwfmN0Wja3cG2fGjBnFa9eunauq'+\n\t\t\t'qhrFPsPYsGHD/h/+8IdkVkdyXFLYnDheyo9eJ27S3/xmiJdA9DyT0dRBcWHAgAFFW7Zsufu2227b4Pf76dcJRCMSEXr26+5n6NChWX/84x8fKC4uLo7geLoUFxd7oHdmSWKDKMSix+TQdRO99zfyrldKEY9WLD1vwZsqKGGtJJWVlRWbN2++A8QDtdi3TXlNFN4kdGzhfa6nlJSU4I8//ni+leIAAFBVNUAdpwtC6w9650OHT0bvbaRJOaFY7UGMpgbiTVXKm8+3+4txyNWpqamp3Lp1q//uu+/epGka74lIp7ywsXskQ49J/YtHz/by8vKMnTt3Lhg8ePAQ82dhjqBAOqlj0oX2IAEQiBc443RA7EW455jMxLMfRM9b0G3wohnh40ZNTc2U/fv339+3b98AhDYc0A0GbMW0i1rST2LRew7Z9S62TJ06NWv//v3/On'+\n\t\t\t'jw4JjegSLC7Xb7gP8ekg7gN9+y58Z6EzNeJKWwUiB6T1I6hGJfXGP2TVSWMmHChPHHjx//0cyZM/OA/+4QnkBokZgJv2gBhUyr+tRTT920devWJ/v161cWr3N0uVx+CBUHKxaeUNgwjB0KbXnmtZOxKsQS1TVoAYb1VkOoSNj3Asadfv36lb733ntPbty4cV1dXd2HnZ2d9NMRqKXo/NhtNGyIhQEADx06NONPf/rTvMrKyhmc71iKx+MhHoQcHyA8nORN5MfOdukDfmU95Svq8Q6xyJL2Iuyrotl3AtIiijtutzvz/vvvrzt37tzPn3/++RGgH3LoVdDZJy39ty8nJ0dbs2ZN1ZdffvnrysrKGkiAlwwKpB0A2qgl7Ul43oTu62DPixaJnihSRijxasXiiYP1GmHvA2T+r8QyHiRSCgsLhzz22GNPXbly5Vdr1qyZ'+\n\t\t\t'VFJSQiq4IlHwbpqwsfWjR4/O2LBhw10XL158Yf78+Q9lZWXlJ+qcKIF0MEuRMHgPBPZc2XnFUtZ7AMS3o5ANszCEh1TsvLkuCHXhCaewsHDE/Pnzn5w7d27ryZMnP9m3b9+BV1999cjevXvbILSuRFq1yHn1PBSqq6sLFi5ceMuUKVP+bsiQIRNUVXXbcS7BdPMOEKfR6M0VQIueN8CNbfFLSRIhEHLjqNB9MfXE4QbqR0ikB2FxuVx9hg8fPnP48OEz58+fj9va2s42NTWdvXTp0tmmpqbW1tbWzvb2dq/b7fbk5ubmFhYWFtxwww0DiouLy3Nyciztz4gWyoMQeD3qvN5ytpdd1KPO7pddT3ri3ZPOVl7pdwJqECoKUtzQK5A4mRcZCCHUp0+fsj59+pSVlpbabY5pgh6kk9rEE4ieUHiiSIvQimClQHitOAQSkg'+\n\t\t\t'D0XlSSBBkAxnMEC7bTg6QCHo+H9PMQ2N+ArPM6SkWi0Jh90aScWBLhQdi+DRJqES/S4zEg9EfBmqbJOXNjwOVykVQTAH4YxApFJBa6iZj9PrvPlCIeAtFLxyCehPR1EJFw0xekB4kNt9tNxuEQwvplmO16CZu8z/P2m1LEKxeLrLNFg25xAPDj35AfR3qQ2FBVleRaEYySC80IIm3EAZCYWU3YnnW6DsK6cqCWIAUSGy6XixUIi1nB8D4r2pZSJHLAFCk8N899WkmBxEYwG5rXnyS6sc16h5QXBiFRHoRdJ56EHJ99ciEAQJqmyTpIDARfYRdJh6uZGz9txAGQWA+iUOv0RVZBcNGlB4mNoAex4oZOK1HQJHLILbsuuvl7wjEpkISStiLQI96pJuzftEfh/SAhrV5SILFBphq1245kJhF1EIAovYisg0jsJlEC4UFX'+\n\t\t\t'2NntCAAQxlh6EImtJNqDiIbT0uniPakpsiddYjeJ9CCiMIuGHm4rBSKxHTtCLL0WLjIISXoQiSOwuw5CC4JubVFACkTiAOwSCK+5N6xZWApEYjd2ehACEQHrTWT7vcR2nNSMKkqVl0hsw0kCAWB6250yJl2SvjghxOIhPYfEETjNg0gkjkIKRCLRQQpEItFBCkQi0cGplXRH0tbW1rlt27ajmzZt+vazzz67du3aNd+gQYMyq6qqimbNmjWsqqpquMvlsuQFnBJnIAViAowxbNiwoX7hwoV7L1++TM8zBadPn+7cs2dP04oVK/731ltv3bNy5crbx48fP9QuWyXWIkMsAzRNw8uXL99y33337WLFwXL48OHrEyZM2Lh+/foDibJPEl+kQAx45ZVXdv7iF784Hsl3vve97+3atWvX3+JlkyRxSIHo8NVXX51bunTp4W'+\n\t\t\t'i+O2fOnI9aW1vbjT8pcTJSIDqsWLHis2i/e/HiRe/69esPWmmPJPFIgQhobW3tWLly5elY9vHaa699ZZU9EnuQAhHw9ddfN2habG+B27t3b5MMs5IbKRABV65caQuuxpRS3Nzc3GqBORKbkAIRoCgKgPh9GJHsR17jJMbJP56tg0EGDBiQB/ovjTHE5XKhoqKiPEsNkyQUJwvEVm688cb++fn5wom1zTB79uwSj8fjsdAsSYJxqkAwQM/csrbg8Xjcjz/++AjaHohQLIsWLRprrVWSRONUgQA4YOKGRYsWTSksLIzKi1RXVxfceeedUiBJjpMFYjtFRUV933333TuDf5oWSVFRkXv16tUzVVWVmb1JjhMFEnPLkZVMmzbt5i1bttzhdrtNxXtlZWUZu3fvvq+8vLwk3rZJ4o8TBeI4vvOd79xaWVlJWqN0hfuDH/xg'+\n\t\t\t'6MiRIwclwCxJAnCqQBzhPSQSpwoEwJkicaJNkjjiZIHY2swrkQA4XCAOQ3qPNEQKRCLRwakCwQAAPp8vYLchSU6X3QYkO04VCAIA6Ojo8NptSJLTYrcByY5TBQIAAG1tbU4SSDK2GFy324Bkx9ECaW9vd4xAPB6PqWtl9nMJQgokRpz0Y7KgS5cuOWa46sSJEwvBhBepqKgoSoA5ZrlotwHJjlMFggAAjh49etVuQwjz5s272egzeXl56h133DHC6HMJ5JjdBiQ7ThUIAAAcOnTIMQKZMGHCjcuXLx8JOl5k7dq1U/Pz8/sk0Cw9mhBCl+w2ItmxSiAYYhyeStFzA+7bt69Fi3VqEQv52c9+dtfrr7/+d9nZ2SFp7OXl5ZkfffTRjFmzZt1ql20cpPewAPbFmWSJAEClijtYMgAgEwCyqJITXGZT2zIAwBMsrmBRgv'+\n\t\t\t'tVwDiWJ2LTTp8+XVdWVtYvlpO0muvXr3ccOXLkTHNzc2f//v1zx4wZU+bxeJw2Efj/Qwg9bLcRyU40P6qRd7AyJQPV19efcZpAcnNzs6qqqpxU1+Cx3W4DUgG9EIs35JUXQpkJq6IRDQIA2L59e0yzG6YpGAA+ttuIVMBMHUQ0NjyeyXs9Idjbb799zkn1kCThMELIMQ0cyUwklXQ9r2G0jBbU0NDg/fLLL7+NcT/pxnq7DUgVzArErDjYwvtcpKD169cfjfK76QgGgDV2G5Eq0AIxE0YZiYH9TsziAAB46aWXTnR1dTkm7cTh7EIInbLbiFQhmhCLFYDIa+iJIyLBNDU1BXbv3i3b9c3xpt0GpBKRVNJ5AqCLBvreRG8bj5C+kmeeeWY/xliO6tPnHACstduIVIInEKMnPy0EvaJR3+GFYmZBAACffPLJtf3790f0'+\n\t\t\t'rsA05NcIIRmKWojIgxj1d4iEolHFyuZhBADw7LPP7o3iu+nCJQB43W4jUo1I+0HIjU8veaIQiSgaelJgPvjgg8Y9e/bIt8fyeQYh1GG3EamGUU86va4XSrGCMSMSM4JB7HLhwoU7Ojs75VjrUA4CwO/sNiIVYSdXZhMW6aIEC0lgdFFLXiGfU5jC7j8ScGNjo6+0tNQ3ceLEGyP8bqqiAUAtQuis3YakImZDLLJkwyvaawSCxSjsovdplhDhLlmy5NCpU6cuRLiPVOVVhFDUr6uW6MMKRHTjisKqAISLgycUM52KRvR4Ha/Xi+bOnbuxo6OjM4LvpyL1APCY3UakMrz3V7BjRNgQiw6z6OISbCffoceCsEUP2nv0COrcuXNdPp/vSk1NzShzp5pyXAeAGQihRrsNSWX0BEKW7M1N3/QicYjqIOyAKXYZEbt37746fv'+\n\t\t\t'x4V0VFRbq9bgADQB1C6FO7DUl1oulJp0MnEk75g4X+mxd2iVq1jEItYeNBbW3tzr1796ZbMuNShNA6u41IByLNxWLFQd/8bKFFI+pAjLQOQpY9RdM0ZcaMGf+TRinxv0IIvWy3EemCUaqJUd8HKwa20N6ErcDzUlKM4Iqkra1Nmz59+sbjx4+ndFMnxvhVhNCTdtuRTkQSYtHNuvQNTwtBJBJWGLQ3Ac5SD1okPZX+xsZGf2Vl5bsHDhz42sQ+kg6M8dOKovzIbjvSjUin/aFvbF445aOKkVBi6SNhW9oUAEAtLS3abbfd9sG2bds+j/C8nEwgEAgsVhTlWbsNSUdErynmtSrxetaNmn/ZXnRRcy/vuGaaf8OapDVNQ6tXrz6Zl5fXUVlZWa4oiqMnxzPggtfr/UePx0OG0Mp0/wSj9x5vo7QTPaGwomE/p9cXEmnT'+\n\t\t\t'L7c/ZevWrQ0HDx48WVNTU5aTk5Npcl+OAWO87dy5c/9QWFj4pd22pDORjEkXNfWydRAfAHghPNwShV1suBVLBnCI6DZv3nx57Nixb2/evPlIEg22uu71eh9dvHjxPWVlZQ0gvYatmPEg9LoZryIKp0SeA3H2r7ceEW1tbYE//OEPp+rr6y6r5v4AAATiSURBVE9Nnjz5hoKCAqfMnRuGz+dbd/jw4dqysrJtBw8eZKc6kkKxgUjSPGgh0PUMD3RPS+qB7ilH6elJMznFA+HTkpKed1pYeuKJClVV0dNPP12xaNGiypKSkvxY92cVPp9v98WLF58rLy/fAb2tg7HkrUkswqxAyDov7d0N3Tc4LRAiElKyqG30vL1kzl86PUVPJGZsNkRVVfTEE08MX7x4cWVpaalt7/Po7Oz8+MSJE7++5ZZbPoXekJMNMwlSIDZg5m'+\n\t\t\t'bT8yIK9HoA2pMQIfA8CBEQLRDRGBIzlfmYmDNnzoAFCxZUVFdXj8jOzs6wYp96+Hy+s1euXFm/Y8eOP82bN+8Y6NfHCFIcNhGJQMg6W8+gwyQ21KK9RiazznoRMyIBiI9QcHZ2trpo0aLBNTU15ePHjy8bMGBAoQX7BYxx4Pr1639rbGzce/jw4e3z58/fGxwRSRow6P4h6T0cRiRNqfSSvnnZUYV0HUMkENqLEJHw6iNsE7GeUCI5J/aGC+vRHzVqVPbs2bMH3nzzzQVDhw4tLC0tLSwuLu6bmZmZoapqWOOG3+/3+ny+9ubm5vNXr149c/ny5VMnT5488dvf/vbAgQMHrkH3K5mJMLwQ3oEqvYcDiVQgZJ2+adlQi3gEIhCeUHgC0au081rCQGdpBlGaCy+1JiQpMzc3Fw8cOFApKiqCS5cutZ0/f76lvb29A3pF'+\n\t\t\t'0Emtk+KF0OZvPXFEO/JSYjGR3FBGoRbtSWiRiEIuWkC8UEsv3GLHtkd6LgDGk1Lw0vpJfw/dx+OFXgGwotAThx9CW6yk93Agev0gLEa93XpPc1E4xLsZ2G2ipEbek9ZM5yL7PXYMPU8QbCcoXVhxsOtEGHohFX2O7PWQ2EgkAgEw15Fn9knOu6mNUuwj+bxeyMQLoURjW3gegycO3tIopIplfIwkAUT6CjYMvQLgPekBum8AALHXIJ8XhTJk6Q4u6T4SDYyTHvWOSx+bXjcSC+1B/NB747Ni0BMH25yrV9+QQnEIVrx4ktxYSnBp5ubkiYO+Kd3U0gW9QjEzEQSAfkgnEgcG/ihJNsSiPYkPelum2CUrDrMzvUgcRLQv8UTMOisSve8aVYLZG5OusPNat2ihAJj3IHQJAF8gbHKlKNTyMUs2OVM0aIwnDCkWBxGtB+'+\n\t\t\t'GJBEAsDl44YRTOuCFUILRI6J583mwpepNyExvYG5WdZILOUqYzklkPwmYui4QhEocMrRxMLCEWrz6CwNiDAISnt/NuTlYcvE5Esq4XarHHNhPiieoerBDoOomR15DiSEKsqIMQeCJhbwBSXBAqDjascYFYIAq1FPW2G3kQMwLheRDesGJeJZzu45DiSGJiFQjtRcjfAL0iUSA8ddtMC5ZIILwhvUbpKKxtZlqu2Dm+WHHozd7CekP2eLQt7LrEYVjVisW7EQFCK+5mBELEwat38GZs1GvRIpBGBGCWRh2ErDhEf7MeQ2+UJHt9JA7HkpRxwb7YJlfR2HXRHL8uzjajSSHMeBCNWtIVdFFdiOdRRKKg00bM5FZJsTgcq+sg7A1JP7016m9eoZ/kJDSjEyFFnoOEWHrJjMQesuSFWAEQexJR4X2X3j97XPZ6SRyOlR5E'+\n\t\t\t'tE9eqjwvI5jODOa1VPHEwfMedH8Ii5EweR6B15DAC8/YTkcpjBTg/wNRysarsEt+xAAAAABJRU5ErkJggg==';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_button';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"ht_node_visited\";\n\t\tel.ggDx=0;\n\t\tel.ggDy=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_button \";\n\t\tel.ggType='button';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 45px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 45px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_node_visited.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_node_visited.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.nodeVisited(me._ht_node_visited.ggElementNodeId()) == true)) && \n\t\t\t\t((me.hotspot.customimage == \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_node_visited.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_node_visited.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_node_visited.style[domTransition]='';\n\t\t\t\tif (me._ht_node_visited.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_node_visited.style.visibility=(Number(me._ht_node_visited.style.opacity)>0||!me._ht_node_visited.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_node_visited.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_node_visited.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_node_visited.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_node_visited.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=(this.ggDy + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._door.appendChild(me._ht_node_visited);\n\t\tel=me._ht_node_image=document.createElement('div');\n\t\tels=me._ht_node_image__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_ht_node_image';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAYAAACtWK6eAAAgAElEQVR4nO2dfXQUVZr/n1vV3XkjIW8SXpIAIhAQFFgCi+EXRInjCg5rnAMyZM9ZZgQ5646wc1R0ZtEZdebMcdD5qeNvHHc9iMCMM4IuKCyLiAgygLxkQB0EXEHeQ3hJQl77pe7vj/RNbt++t6q6u7qruvt+zrmnKpXuqqeq61vPc+997i0AiUQikUgkEolEIpFIJBKJRCKRSCQSiUQikUgkEolEIpFIJBKJRGIPyG4D4oCZc8LR7hxjjAAgBwByASADANoB4DpCqCPafUqcSzIKJBE2Y4xxGQBMBYBRADAyWIZAtzAUznf8ANAEAF8DwLFg+RIAdiGEriXAZkkccLpAzNoXy3lgAIDz589nlZSUzEIIzUAI3QEAw2LYJ40GAH8FgO0A8N8AsAMhpF'+\n\t\t\t'm0b0kaggyKwilqNOX22293dXV1Tdc0bSXGuBknhjMY419hjEcn6oJKkp9IBEHf5K5gcXOKh1PcAOD+8Y9/nNXR0bFA07SvEiQKEdsxxnck6BpLkhAzomAFwRNABlUygyWLKZl33XVXTmtr68Oapp20WRgsezDG30nQNZdEgF11ENFxEWfJ2wbQW1Fmt3P3f/z48cobb7zx/6qqekvk5iaM/wKAJQih03YbIrEHI4/BegraQxBPkA3dzax9oLtFKS9Y+gZLPgAUkPLTn/50cGtr61sYY81uN2GSNozxMoyxmpifRKJHIj0I71h6XoEIR09UrKehPQ7s2LFj3NSpU/9DVdVy604jYewAgO8jhC7YbUg6kwiBxCIMoyW73rPPkydPPjh48OCfIITcVp5MgrkEAHUIoQ/tNiRdibdA2P3rCYO++XnrquD/ISIZOHCg6/Dh'+\n\t\t\t'w78sLi6ujccJ2YAGAI8ghF6125B0JJ4C0ROHmb4NtiVL9L8egYwdOzbzk08+ebGgoGBa/E7LNp5FCD1ltxHpRjwEYsZrsOGRSi3pyroi2BZWJk2alLN169ZX+vbte2sczskpvAYA/4IQijqXTBIZVgvErNcQeQgzPeD05xAAqKWlpZ76+voXiouLJ1h8Pk5kBULoMbuNSBesFIiRONh6Ba9pV4He3nGVWrLrPaLKyMhQjx8//lR5efn/sfBcnM5jCKEVdhuRDlglED1x0CEVHSKxPeR06ghbhCKpr69/aNy4cfdadB7JAobuJuC37TYk1XFZsA+eONj6Bi+U4onCLfib/lyPuF5//fWqNBQHQPc1/Q+McT1C6JjdxqQysXoQkTiMEg1ZD0GE4IFwobAiUQFAnT179oB33nnnObfbnRXjOSQzRwBgMkKo025DUhUrBW'+\n\t\t\t'Im4ZAOmUjSIZuASG/jCiQ7O9v9zTff/HtJScngGO1PBX6HEPoXu41IVXgj48zCEwdZZ8XBegs6E5fOvhVl4oaUlStX3iPF0cNijPEUu41IVaL1ILzMWVFIxYZTxEvQy5DxGkwJqahPmjSpcNeuXU96PJ6MKG1PRf4KABMRQgG7DUk1ovEgeuJgK+Qiz8GO3aBLFoR7lJ7xHr///e/vl+IIYxwAPGy3EalILCEWge0R1xMHb2ATTxyZzGczACBjzpw5Q8eNGzfWAptTkeUY42y7jUg1IhWIUaWciIQdDmvGc9DCoAXSE4ItW7ZseqQnmEYUA8Biu41INSIRiCi0ogViJA49L0JvY8XhrqmpGTB+/PhREZ9hevEoxliGnxYSaysWbzSgSCBEHKIQKhN0Kus/+clPpiCUyPFdSckAAKiz24hUwqxAeKEVL7eKJw438L0D'+\n\t\t\t'KxRaHHR/iKuwsDBzypQp0nuY45/tNiCViLYOwtY/9Kbh4YVWGcx21mvQHYPKkiVLRmZkZHiiOsP0owpjPNRuI1IFMwLRSyfhpaizrVb0khaKKJwKS1Ksra0dE+0JpiEIAP7JbiNShUgr6Xp5VqJJ3ETCYAVCi6JntGD//v0zR48enYyTLthJqgw3th2jbF7RhAu80IrOrzIrDDbXKkQcAIDmzp1bpiiKY2rnGGPc2dnZ5fV6vT6fz+9yuZTMIHbbRnELxrgIIXTFbkOSHbPp7pEkIrKtV6xgeHUNrjgAAE2fPr0sxnOMGk3T8OnTpy8dPHjwzN69ey8cOnToyr59+5ra2tp8ABCgij8/Px9Pnz49b9q0af0qKyvLRo0aVVFQUDDQJtMRAEwHgHU2HT9l0Hsyi1queK1VdF2Dl3jItlhx86wgXIjo22+//X55efkNsZ'+\n\t\t\t'+qeU6fPt34/vvvH33ppZeOnThxoj24GTMlAN0zjgSg+9UHfgDwAYA3WDpra2vzH3nkkUmTJk26IysrqziR5wAyy9cSzAiEHvxkNPshm41LC4QOtYhA6KG2YZPEZWdnq9evX384USHW0aNHz77wwgufvfHGG2cEHzESCS2QrmDpzMrK6lq1atXke+65Z15OTk6iPOI+hNDfJ+hYKUsk/SBmQyxRRi63hYraH3sMmDx5ct9EiOPy5cvNjzzyyH+NHj16nY44gGOjXh9Qz3l3dHSoc+bM2TVw4MCFO3fufDEQCLTG83yCjEzAMVIekUCMKud0BT1ScfCm7wkTBwDA+PHjC2I5OTNs2rTp0LBhw9585ZVXvoFub0CKaGodvZY8ujWPvR6elpYWNG3atPfnzZv3wLVr1/4Sx9MCAMjHGPeL8zFSHiMPIuo1Z6ff0RtTbiQO'+\n\t\t\t'ViA9jBo1Kj/G8xPS2dnZtWzZsvdmzZq1raWlxQu9oiBLdp2Hmf6gsOU777zTVFJSsuTEiROv6OzbCqQXiZFoetJFWbu8pyYvpGJbq2jo+F4rKSmJS/p2a2tr2wMPPLD6+eefPwqhrVGkTkF7EZ5wgLKdd030vKsLAFw+n08ZMWLEf/7lL3/5N4yxLx7nCQD947TftMFsTzrrRXgTvRlN2aMy++B6DaBEkpOTY/nE0y0tLS0zZ858Y8OGDWehu1Ltg95WKD+Ei4WtmLNPfNH14c3aEnadqqqqtn766acPxUkkuXHYZ1rBE4go34oXe+uJg+1EpIWlKwzoFYil+VednZ0ddXV1b+zcufMCdLc0+UAsEtI6xQoFwFgoZq5PzzWqrq7edeTIkR9x9hkrUiAxEmmqSSTThXJTR8Cc99AAIJCdnW2ZB8EYa8uWLXvj/fffPw'+\n\t\t\t'3dza9eakkKTzCsUPQq8PS50deGV4EPuV7jxo3bcuHChV9Zdb5B8izeX9phpic9kiZe4QyIECoSnjDIsucmdLvdVgwJBgCATZs2bXz55Ze/gPCQiLWRLLXgElO2Y9AXOEHkaUVFAQBl2LBhr37++edf5+TkuDweT8Dj8QRUVcUulwsjhLCidF8ORVHMeprPTX5OIsBsLpYozmZFwHb8iTwHgQ1ZyNM5AACaVbOYX7hw4Xhtbe27wT+NWuTYokGowFnBmGkSZx8SvL+Vjo4OdNNNN30Avd6MDvXYEE+SAEQCMVP/ED0deaGFyHMAhIqD3AwaAASsEAjGOPD000+/5vP52jnnwNrsYpZkXcvPz894+OGHh1dXVw8dMmRIv4KCgly32+3q6uryNTY2thw7dqxh8+bNJ996663Tfr+ftlt07Xh/s5/VqH1IUdgAe8PyPAYd'+\n\t\t\t'O5PUEjalJJtZZkFoagn5Pq95lxUHSdsInDhxYsFNN910Uywn+MUXX3wwduzY3wnOixVHWEtTRUVF39/85jd3Tp8+fVJGRoZhxu61a9ea//znP+979NFH97e2tnYFz4XUdzqDpSNY2ql18r8uCK0H8eo+UiwJwmwzL1myYRbvZmO3c3vJgaqMQ6gwehL/EEIaxICmaf6f//znb0HoDcjepKK/u15++eVb6uvrl919993VZsQBAFBQUND3oYceuuubb75ZXFdXNwjMdTSynkP0P/q3kCQAM3UQo2ZeNuQi20XCAOCHVWECiaAyyuXMmTNb1q1bdwbCby6VWrIexKWqqnv37t3fnzx58l3RHvuGG24oWrVq1YMTJ058d+nSpXtA3DSst9QjWpFI7xMBegJBzLqRWHjrZirlrDhIeOFVFCUmD7Jly5b10B3e0OfDq0e5gs'+\n\t\t\t'd2AYDr8OHDi26++eaoxUFQFEVdsmTJ92pqaioCgYBXVdWAoiiay+UKqKoaUFU1QNZdLpcW3KapqqopiqIpioIVRcEIIVLIruN+k1s0g4wGAFegexb6TQih81bsNJFE0swLIA6vROGUWe/BjqeIWSBdXV3fLl68+ICJ81ChVxz+HTt2zLNCHPRxR48eLWeDBAhgjNcDwDKE0Cm7jTGLqA7Cc/WiuoieR4lGHD1jKWIRSENDwzYIDdnIMWgvFSLIJ554YlB1dfUPoz2mRBcVAOYAwBGM8T/abYxZjFJNeP/T8xRsCxWNac8RLDEJ5OjRo3upY/LqO2HHf/TRR/8VIWR2GLIkOnIBYB3G+D67DTGD2VYsXiuKnjiiqZj7gEkBiaGSrv3yl788aPCZkHrQiy++OLyoqEi+ZyMxqADwVjLM3xVpLha9JOuiJki2cs72lNPi'+\n\t\t\t'oPOgekQSrQfxer0Xdu7c2Qn8Hn9u+FdbWzsrmmNJoqYPAPzabiOMoAUiCql4fxu1z+u1XLEhDl0XIEIhHiQqgbS3t58C/gAu4fRCJSUlU6M5liQm7sMYO3rOM7MeRFRZ11sSTPV5QLhIvNGmmrS2tjZC+BuseFMPuQDANWHChD6ZmZmOd/cpiAIAjn5LcSQV0khEwqJRS3YWELZlqUck0dZBOjo6uqA7zYW2iewrbBDUd7/73TId2yXxZZzdBugRaT8Iu10PdgQeL7xiW7BCBi7F4EG80C0QXkdl2FDavLy8vtEcR2IJCZ3zLFKMetL16iDsNnadFYheMyvbN+GHGLJ5McYkkZI+B16TrwYAuLm52bJxJ5KI6bLbAD2iafMXeQ69ijl7U7IdeHQnHj3sNSpcLlcumBeIVl9f387bjyQh/K/dBugRa6eYmbidl3fF8y'+\n\t\t\t'DsePCoB0x5PJ6+EIFANm3a1O7z+drdbrd8CWbi2WG3AXpYHVpgZp0tIQOiIFQovOl3oqKwsHAghI9Z4ZVMAMgKBAIZZ8+e/Sra40mi5gwAfGS3EXrEI/bmzf6hMUVPHEaTtRlSUFDQH/Qn0Q57J/v27dsPRXs8SdT8DCEUdSidCOJZOWV7z0UC4U3YFlOau9vtzpg1a1Y58F8UyhXIk08++XlHR8f1WI4riYgPAGCl3UYYYaVAeE98XohlpsTkQQAA7r333pEQ/tIe3kt9MgEgo7GxUVm3bt2HsRxTYppPAGCeVZNyxJN4exACO5Unb66psPmmMMZRd95Nnjx5BIS+vId9JXXYu9sffPDB/WfOnDkd7TElhvgBYAUA3IUQSsQM9zETj0q6mcJOEM0Lr2Lq2R4zZszwoUOH5oLxxNo9gvF6va65c+f+ubW1NSl+vCTi'+\n\t\t\t'JAC8BACjEUKPIYS8Rl9wCokY+2DkSdgORUtQVVVdunTpmCVLlvyVY4+w7Nmzp62urm7N2rVr/yknJycnVjvOnj17fvHixe+2tbX5o9yFZdclOIwWByfDwIqiaAghv6IoAVVVfaS43W6vx+Pp8ng8XZmZmd6srKyu7Ozsrtzc3K4+ffr48vPzvbm5ub6CggJ/Tk6OlpubG8jKytKys7Ox2+3GHo8HAwB4PB4/AFxGCCVt3U5vxCCdJk6/85yd7oee6oe8SYo8rcncTqRz0As6s4hA6GRpqLm5+c28vLyo35LU0NBwtbS0dKXf33Nv8jow6Z7+nv9VVVUVvP322/eXlpZGPUP6wYMH/zZz5syNDQ0Ndj4xeU3v9LAD7uvjIPR3ov+mp2sVTU1EX+ekJt4pFuwF4l040WdipqSkpPDxxx8fCeGDukQzsfSs7969u7miom'+\n\t\t\t'LV2rVrd3R1dUV0gzc1NbU888wz702cOPG9hoaGABhPPSp6b4oVRe9YejaIJv5Lq6TOeHsQBL1PLPKEYp9MZEk/kTBY4EEAABoaGq4NGzZsdVtbG5m+EzjLEO/Bfmbw4MGZy5cvv3XGjBmjy8vL+yPOlB9+vz9w/Pjxbzdu3PjFc88997fg8ZyGGQ9C3q1I/z6sFyGfozMgUtKDpLxAAADefPPN3QsWLNhHbdILtdj/hXxn0KBBGbfffnvxkCFDcnNyctytra2+Y8eONW/btq2xubk52npGotDLi6MFQouhHUJ/MyIgL0iBWCoQP1BvfoUE1EEIPp/PP3PmzDUffvjhleAmkTBEQkkk8TgeK3Te4DWRQHizUqZNHSTerVi8AVWiiR1E6zHjdrtdq1atunfMmDGrr169SuoTRk3RAPwfmN0Wja3cG2fGjBnFa9eunauq'+\n\t\t\t'qhrFPsPYsGHD/h/+8IdkVkdyXFLYnDheyo9eJ27S3/xmiJdA9DyT0dRBcWHAgAFFW7Zsufu2227b4Pf76dcJRCMSEXr26+5n6NChWX/84x8fKC4uLo7geLoUFxd7oHdmSWKDKMSix+TQdRO99zfyrldKEY9WLD1vwZsqKGGtJJWVlRWbN2++A8QDtdi3TXlNFN4kdGzhfa6nlJSU4I8//ni+leIAAFBVNUAdpwtC6w9650OHT0bvbaRJOaFY7UGMpgbiTVXKm8+3+4txyNWpqamp3Lp1q//uu+/epGka74lIp7ywsXskQ49J/YtHz/by8vKMnTt3Lhg8ePAQ82dhjqBAOqlj0oX2IAEQiBc443RA7EW455jMxLMfRM9b0G3wohnh40ZNTc2U/fv339+3b98AhDYc0A0GbMW0i1rST2LRew7Z9S62TJ06NWv//v3/On'+\n\t\t\t'jw4JjegSLC7Xb7gP8ekg7gN9+y58Z6EzNeJKWwUiB6T1I6hGJfXGP2TVSWMmHChPHHjx//0cyZM/OA/+4QnkBokZgJv2gBhUyr+tRTT920devWJ/v161cWr3N0uVx+CBUHKxaeUNgwjB0KbXnmtZOxKsQS1TVoAYb1VkOoSNj3Asadfv36lb733ntPbty4cV1dXd2HnZ2d9NMRqKXo/NhtNGyIhQEADx06NONPf/rTvMrKyhmc71iKx+MhHoQcHyA8nORN5MfOdukDfmU95Svq8Q6xyJL2Iuyrotl3AtIiijtutzvz/vvvrzt37tzPn3/++RGgH3LoVdDZJy39ty8nJ0dbs2ZN1ZdffvnrysrKGkiAlwwKpB0A2qgl7Ul43oTu62DPixaJnihSRijxasXiiYP1GmHvA2T+r8QyHiRSCgsLhzz22GNPXbly5Vdr1qyZ'+\n\t\t\t'VFJSQiq4IlHwbpqwsfWjR4/O2LBhw10XL158Yf78+Q9lZWXlJ+qcKIF0MEuRMHgPBPZc2XnFUtZ7AMS3o5ANszCEh1TsvLkuCHXhCaewsHDE/Pnzn5w7d27ryZMnP9m3b9+BV1999cjevXvbILSuRFq1yHn1PBSqq6sLFi5ceMuUKVP+bsiQIRNUVXXbcS7BdPMOEKfR6M0VQIueN8CNbfFLSRIhEHLjqNB9MfXE4QbqR0ikB2FxuVx9hg8fPnP48OEz58+fj9va2s42NTWdvXTp0tmmpqbW1tbWzvb2dq/b7fbk5ubmFhYWFtxwww0DiouLy3Nyciztz4gWyoMQeD3qvN5ytpdd1KPO7pddT3ri3ZPOVl7pdwJqECoKUtzQK5A4mRcZCCHUp0+fsj59+pSVlpbabY5pgh6kk9rEE4ieUHiiSIvQimClQHitOAQSkg'+\n\t\t\t'D0XlSSBBkAxnMEC7bTg6QCHo+H9PMQ2N+ArPM6SkWi0Jh90aScWBLhQdi+DRJqES/S4zEg9EfBmqbJOXNjwOVykVQTAH4YxApFJBa6iZj9PrvPlCIeAtFLxyCehPR1EJFw0xekB4kNt9tNxuEQwvplmO16CZu8z/P2m1LEKxeLrLNFg25xAPDj35AfR3qQ2FBVleRaEYySC80IIm3EAZCYWU3YnnW6DsK6cqCWIAUSGy6XixUIi1nB8D4r2pZSJHLAFCk8N899WkmBxEYwG5rXnyS6sc16h5QXBiFRHoRdJ56EHJ99ciEAQJqmyTpIDARfYRdJh6uZGz9txAGQWA+iUOv0RVZBcNGlB4mNoAex4oZOK1HQJHLILbsuuvl7wjEpkISStiLQI96pJuzftEfh/SAhrV5SILFBphq1245kJhF1EIAovYisg0jsJlEC4UFX'+\n\t\t\t'2NntCAAQxlh6EImtJNqDiIbT0uniPakpsiddYjeJ9CCiMIuGHm4rBSKxHTtCLL0WLjIISXoQiSOwuw5CC4JubVFACkTiAOwSCK+5N6xZWApEYjd2ehACEQHrTWT7vcR2nNSMKkqVl0hsw0kCAWB6250yJl2SvjghxOIhPYfEETjNg0gkjkIKRCLRQQpEItFBCkQi0cGplXRH0tbW1rlt27ajmzZt+vazzz67du3aNd+gQYMyq6qqimbNmjWsqqpquMvlsuQFnBJnIAViAowxbNiwoX7hwoV7L1++TM8zBadPn+7cs2dP04oVK/731ltv3bNy5crbx48fP9QuWyXWIkMsAzRNw8uXL99y33337WLFwXL48OHrEyZM2Lh+/foDibJPEl+kQAx45ZVXdv7iF784Hsl3vve97+3atWvX3+JlkyRxSIHo8NVXX51bunTp4W'+\n\t\t\t'i+O2fOnI9aW1vbjT8pcTJSIDqsWLHis2i/e/HiRe/69esPWmmPJPFIgQhobW3tWLly5elY9vHaa699ZZU9EnuQAhHw9ddfN2habG+B27t3b5MMs5IbKRABV65caQuuxpRS3Nzc3GqBORKbkAIRoCgKgPh9GJHsR17jJMbJP56tg0EGDBiQB/ovjTHE5XKhoqKiPEsNkyQUJwvEVm688cb++fn5wom1zTB79uwSj8fjsdAsSYJxqkAwQM/csrbg8Xjcjz/++AjaHohQLIsWLRprrVWSRONUgQA4YOKGRYsWTSksLIzKi1RXVxfceeedUiBJjpMFYjtFRUV933333TuDf5oWSVFRkXv16tUzVVWVmb1JjhMFEnPLkZVMmzbt5i1bttzhdrtNxXtlZWUZu3fvvq+8vLwk3rZJ4o8TBeI4vvOd79xaWVlJWqN0hfuDH/xg'+\n\t\t\t'6MiRIwclwCxJAnCqQBzhPSQSpwoEwJkicaJNkjjiZIHY2swrkQA4XCAOQ3qPNEQKRCLRwakCwQAAPp8vYLchSU6X3QYkO04VCAIA6Ojo8NptSJLTYrcByY5TBQIAAG1tbU4SSDK2GFy324Bkx9ECaW9vd4xAPB6PqWtl9nMJQgokRpz0Y7KgS5cuOWa46sSJEwvBhBepqKgoSoA5ZrlotwHJjlMFggAAjh49etVuQwjz5s272egzeXl56h133DHC6HMJ5JjdBiQ7ThUIAAAcOnTIMQKZMGHCjcuXLx8JOl5k7dq1U/Pz8/sk0Cw9mhBCl+w2ItmxSiAYYhyeStFzA+7bt69Fi3VqEQv52c9+dtfrr7/+d9nZ2SFp7OXl5ZkfffTRjFmzZt1ql20cpPewAPbFmWSJAEClijtYMgAgEwCyqJITXGZT2zIAwBMsrmBRgv'+\n\t\t\t'tVwDiWJ2LTTp8+XVdWVtYvlpO0muvXr3ccOXLkTHNzc2f//v1zx4wZU+bxeJw2Efj/Qwg9bLcRyU40P6qRd7AyJQPV19efcZpAcnNzs6qqqpxU1+Cx3W4DUgG9EIs35JUXQpkJq6IRDQIA2L59e0yzG6YpGAA+ttuIVMBMHUQ0NjyeyXs9Idjbb799zkn1kCThMELIMQ0cyUwklXQ9r2G0jBbU0NDg/fLLL7+NcT/pxnq7DUgVzArErDjYwvtcpKD169cfjfK76QgGgDV2G5Eq0AIxE0YZiYH9TsziAAB46aWXTnR1dTkm7cTh7EIInbLbiFQhmhCLFYDIa+iJIyLBNDU1BXbv3i3b9c3xpt0GpBKRVNJ5AqCLBvreRG8bj5C+kmeeeWY/xliO6tPnHACstduIVIInEKMnPy0EvaJR3+GFYmZBAACffPLJtf3790f0'+\n\t\t\t'rsA05NcIIRmKWojIgxj1d4iEolHFyuZhBADw7LPP7o3iu+nCJQB43W4jUo1I+0HIjU8veaIQiSgaelJgPvjgg8Y9e/bIt8fyeQYh1GG3EamGUU86va4XSrGCMSMSM4JB7HLhwoU7Ojs75VjrUA4CwO/sNiIVYSdXZhMW6aIEC0lgdFFLXiGfU5jC7j8ScGNjo6+0tNQ3ceLEGyP8bqqiAUAtQuis3YakImZDLLJkwyvaawSCxSjsovdplhDhLlmy5NCpU6cuRLiPVOVVhFDUr6uW6MMKRHTjisKqAISLgycUM52KRvR4Ha/Xi+bOnbuxo6OjM4LvpyL1APCY3UakMrz3V7BjRNgQiw6z6OISbCffoceCsEUP2nv0COrcuXNdPp/vSk1NzShzp5pyXAeAGQihRrsNSWX0BEKW7M1N3/QicYjqIOyAKXYZEbt37746fv'+\n\t\t\t'x4V0VFRbq9bgADQB1C6FO7DUl1oulJp0MnEk75g4X+mxd2iVq1jEItYeNBbW3tzr1796ZbMuNShNA6u41IByLNxWLFQd/8bKFFI+pAjLQOQpY9RdM0ZcaMGf+TRinxv0IIvWy3EemCUaqJUd8HKwa20N6ErcDzUlKM4Iqkra1Nmz59+sbjx4+ndFMnxvhVhNCTdtuRTkQSYtHNuvQNTwtBJBJWGLQ3Ac5SD1okPZX+xsZGf2Vl5bsHDhz42sQ+kg6M8dOKovzIbjvSjUin/aFvbF445aOKkVBi6SNhW9oUAEAtLS3abbfd9sG2bds+j/C8nEwgEAgsVhTlWbsNSUdErynmtSrxetaNmn/ZXnRRcy/vuGaaf8OapDVNQ6tXrz6Zl5fXUVlZWa4oiqMnxzPggtfr/UePx0OG0Mp0/wSj9x5vo7QTPaGwomE/p9cXEmnT'+\n\t\t\t'L7c/ZevWrQ0HDx48WVNTU5aTk5Npcl+OAWO87dy5c/9QWFj4pd22pDORjEkXNfWydRAfAHghPNwShV1suBVLBnCI6DZv3nx57Nixb2/evPlIEg22uu71eh9dvHjxPWVlZQ0gvYatmPEg9LoZryIKp0SeA3H2r7ceEW1tbYE//OEPp+rr6y6r5v4AAATiSURBVE9Nnjz5hoKCAqfMnRuGz+dbd/jw4dqysrJtBw8eZKc6kkKxgUjSPGgh0PUMD3RPS+qB7ilH6elJMznFA+HTkpKed1pYeuKJClVV0dNPP12xaNGiypKSkvxY92cVPp9v98WLF58rLy/fAb2tg7HkrUkswqxAyDov7d0N3Tc4LRAiElKyqG30vL1kzl86PUVPJGZsNkRVVfTEE08MX7x4cWVpaalt7/Po7Oz8+MSJE7++5ZZbPoXekJMNMwlSIDZg5m'+\n\t\t\t'bT8yIK9HoA2pMQIfA8CBEQLRDRGBIzlfmYmDNnzoAFCxZUVFdXj8jOzs6wYp96+Hy+s1euXFm/Y8eOP82bN+8Y6NfHCFIcNhGJQMg6W8+gwyQ21KK9RiazznoRMyIBiI9QcHZ2trpo0aLBNTU15ePHjy8bMGBAoQX7BYxx4Pr1639rbGzce/jw4e3z58/fGxwRSRow6P4h6T0cRiRNqfSSvnnZUYV0HUMkENqLEJHw6iNsE7GeUCI5J/aGC+vRHzVqVPbs2bMH3nzzzQVDhw4tLC0tLSwuLu6bmZmZoapqWOOG3+/3+ny+9ubm5vNXr149c/ny5VMnT5488dvf/vbAgQMHrkH3K5mJMLwQ3oEqvYcDiVQgZJ2+adlQi3gEIhCeUHgC0au081rCQGdpBlGaCy+1JiQpMzc3Fw8cOFApKiqCS5cutZ0/f76lvb29A3pF'+\n\t\t\t'0Emtk+KF0OZvPXFEO/JSYjGR3FBGoRbtSWiRiEIuWkC8UEsv3GLHtkd6LgDGk1Lw0vpJfw/dx+OFXgGwotAThx9CW6yk93Agev0gLEa93XpPc1E4xLsZ2G2ipEbek9ZM5yL7PXYMPU8QbCcoXVhxsOtEGHohFX2O7PWQ2EgkAgEw15Fn9knOu6mNUuwj+bxeyMQLoURjW3gegycO3tIopIplfIwkAUT6CjYMvQLgPekBum8AALHXIJ8XhTJk6Q4u6T4SDYyTHvWOSx+bXjcSC+1B/NB747Ni0BMH25yrV9+QQnEIVrx4ktxYSnBp5ubkiYO+Kd3U0gW9QjEzEQSAfkgnEgcG/ihJNsSiPYkPelum2CUrDrMzvUgcRLQv8UTMOisSve8aVYLZG5OusPNat2ihAJj3IHQJAF8gbHKlKNTyMUs2OVM0aIwnDCkWBxGtB+'+\n\t\t\t'GJBEAsDl44YRTOuCFUILRI6J583mwpepNyExvYG5WdZILOUqYzklkPwmYui4QhEocMrRxMLCEWrz6CwNiDAISnt/NuTlYcvE5Esq4XarHHNhPiieoerBDoOomR15DiSEKsqIMQeCJhbwBSXBAqDjascYFYIAq1FPW2G3kQMwLheRDesGJeJZzu45DiSGJiFQjtRcjfAL0iUSA8ddtMC5ZIILwhvUbpKKxtZlqu2Dm+WHHozd7CekP2eLQt7LrEYVjVisW7EQFCK+5mBELEwat38GZs1GvRIpBGBGCWRh2ErDhEf7MeQ2+UJHt9JA7HkpRxwb7YJlfR2HXRHL8uzjajSSHMeBCNWtIVdFFdiOdRRKKg00bM5FZJsTgcq+sg7A1JP7016m9eoZ/kJDSjEyFFnoOEWHrJjMQesuSFWAEQexJR4X2X3j97XPZ6SRyOlR5E'+\n\t\t\t'tE9eqjwvI5jODOa1VPHEwfMedH8Ii5EweR6B15DAC8/YTkcpjBTg/wNRysarsEt+xAAAAABJRU5ErkJggg==';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_button';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"ht_node_image\";\n\t\tel.ggDx=0;\n\t\tel.ggDy=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_button \";\n\t\tel.ggType='button';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 45px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 45px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_node_image.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_node_image.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.nodeVisited(me._ht_node_image.ggElementNodeId()) == true)) || \n\t\t\t\t((me.hotspot.customimage != \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_node_image.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_node_image.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_node_image.style[domTransition]='';\n\t\t\t\tif (me._ht_node_image.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_node_image.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_node_image.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_node_image.style.visibility=(Number(me._ht_node_image.style.opacity)>0||!me._ht_node_image.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_node_image.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_node_image.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=(this.ggDy + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._door.appendChild(me._ht_node_image);\n\t\tel=me._hotspot_preview=document.createElement('div');\n\t\tel.ggId=\"hotspot_preview\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='z-index: 100;';\n\t\ths+='height : 100px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -130px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 150px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._hotspot_preview.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._hotspot_preview.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['door'] == true)) && \n\t\t\t\t((player.getVariableValue('opt_hotspot_preview_1') == true)) && \n\t\t\t\t((player.getIsTour() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._hotspot_preview.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._hotspot_preview.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._hotspot_preview.style[domTransition]='';\n\t\t\t\tif (me._hotspot_preview.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._hotspot_preview.style.visibility=(Number(me._hotspot_preview.style.opacity)>0||!me._hotspot_preview.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._hotspot_preview.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._hotspot_preview.style.visibility=\"hidden\";\n\t\t\t\t\tme._hotspot_preview.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._hotspot_preview.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tel=me._ht_preview_picture_frame_=document.createElement('div');\n\t\tel.ggId=\"ht_preview_picture_frame \";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_rectangle \";\n\t\tel.ggType='rectangle';\n\t\ths ='';\n\t\ths+='background : rgba(0,0,0,0.666667);';\n\t\ths+='border : 0px solid #000000;';\n\t\ths+='cursor : default;';\n\t\ths+='height : 100px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 150px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_preview_picture_frame_.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_preview_picture_frame_.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._hotspot_preview.appendChild(me._ht_preview_picture_frame_);\n\t\tel=me._ht_preview_nodeimage=document.createElement('div');\n\t\tels=me._ht_preview_nodeimage__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_nodeimage';\n\t\tels.setAttribute('src',basePath + \"images/ht_preview_nodeimage_\" + nodeId + \".jpg\");\n\t\tel.ggNodeId=nodeId;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_nodeimage';\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"ht_preview_nodeImage\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_nodeimage \";\n\t\tel.ggType='nodeimage';\n\t\ths ='';\n\t\ths+='height : 90px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 5px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 140px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='0% 0%';\n\t\tme._ht_preview_nodeimage.ggIsActive=function() {\n\t\t\treturn player.getCurrentNode()==this.ggElementNodeId();\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn this.ggNodeId;\n\t\t}\n\t\tme._ht_preview_nodeimage.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._hotspot_preview.appendChild(me._ht_preview_nodeimage);\n\t\tel=me._ht_tooltip=document.createElement('div');\n\t\tels=me._ht_tooltip__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"ht_tooltip\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='bottom : 5px;';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 140px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='bottom: 0px;';\n\t\ths+='width: 140px;';\n\t\ths+='height: auto;';\n\t\ths+='pointer-events: none;';\n\t\ths+='background: #000000;';\n\t\ths+='background: rgba(0,0,0,0.392157);';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: pre-wrap;';\n\t\ths+='padding: 2px 3px 2px 3px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=me.hotspot.title;\n\t\tel.appendChild(els);\n\t\tme._ht_tooltip.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_tooltip.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.hotspot.title == \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_tooltip.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_tooltip.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_tooltip.style[domTransition]='';\n\t\t\t\tif (me._ht_tooltip.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_tooltip.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_tooltip.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_tooltip.style.visibility=(Number(me._ht_tooltip.style.opacity)>0||!me._ht_tooltip.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_tooltip.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_tooltip.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._hotspot_preview.appendChild(me._ht_tooltip);\n\t\tel=me._ht_checkmark_tick=document.createElement('div');\n\t\tels=me._ht_checkmark_tick__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_svg';\n\t\ths='data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTgnPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHZlcnNpb249IjEuMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSItMjQwIDMzMiAxMzAgMTMwIiB4PSIwcHgiIHk9IjBweCIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAtMjQwIDMzMiAxMzAgMTMwOyIgaWQ9IkxheWVyXzEiIHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3Ln'+\n\t\t\t'czLm9yZy8xOTk5L3hsaW5rIj4KIDxzdHlsZSB0eXBlPSJ0ZXh0L2NzcyI+JiN4ZDsKCS5zdDB7ZmlsbDojMDAwMDAwO30mI3hkOwoJLnN0MXtmaWxsOiNGRkZGRkY7fSYjeGQ7Cjwvc3R5bGU+CiA8ZyBpZD0iTGF5ZXJfMV8xXyIvPgogPGcgaWQ9IkxheWVyXzIiPgogIDxwYXRoIGNsYXNzPSJzdDAiIGQ9Ik0tMTIyLjEsMzQxLjVoLTEwNS44Yy0xLjQsMC0yLjYsMS4xLTIuNiwyLjZ2MTA1LjhjMCwxLjQsMS4xLDIuNiwyLjYsMi42aDEwNS44YzEuNCwwLDIuNi0xLjEsMi42LTIuNlYzNDQuMSYjeGQ7JiN4YTsmI3g5OyYjeDk7Qy0xMTkuNiwzNDIuNy0xMjAuNywzNDEuNS0xMjIuMSwzNDEuNXog'+\n\t\t\t'TS0xMzIuOCwzODEuN2wtNTAuOCw1MC44Yy0wLjMsMC4zLTAuOCwwLjUtMS4yLDAuNWMtMC41LDAtMC45LTAuMS0xLjMtMC41bC0zMS43LTMxLjgmI3hkOyYjeGE7JiN4OTsmI3g5O2MtMC43LTAuNy0wLjctMS43LDAtMi40bDEyLjUtMTIuNWMwLjctMC43LDEuNy0wLjcsMi40LDBsMTgsMThsMzcuMS0zNy4xYzAuNy0wLjcsMS43LTAuNywyLjQsMGwxMi41LDEyLjUmI3hkOyYjeGE7JiN4OTsmI3g5O0MtMTMyLjEsMzc5LjktMTMyLjEsMzgxLTEzMi44LDM4MS43eiIvPgogIDxwYXRoIGNsYXNzPSJzdDEiIGQ9Ik0tMTQ3LjcsMzY2LjhsLTM3LjEsMzcuMWwtMTgtMThjLTAuNy0wLjctMS43LTAuNy'+\n\t\t\t'0yLjQsMGwtMTIuNSwxMi41Yy0wLjcsMC43LTAuNywxLjcsMCwyLjRsMzEuNywzMS44JiN4ZDsmI3hhOyYjeDk7JiN4OTtjMC4zLDAuMywwLjgsMC41LDEuMywwLjVjMC40LDAsMC45LTAuMiwxLjItMC41bDUwLjgtNTAuOWMwLjctMC43LDAuNy0xLjcsMC0yLjRsLTEyLjUtMTIuNUMtMTQ1LjksMzY2LjEtMTQ3LDM2Ni4xLTE0Ny43LDM2Ni44eiIvPgogPC9nPgo8L3N2Zz4K';\n\t\tme._ht_checkmark_tick__img.setAttribute('src',hs);\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"ht_checkmark_tick\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_svg \";\n\t\tel.ggType='svg';\n\t\ths ='';\n\t\ths+='height : 20px;';\n\t\ths+='position : absolute;';\n\t\ths+='right : 7px;';\n\t\ths+='top : 7px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 20px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_checkmark_tick.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_checkmark_tick.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((player.nodeVisited(me._ht_checkmark_tick.ggElementNodeId()) == true)) || \n\t\t\t\t((me._ht_checkmark_tick.ggIsActive() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_checkmark_tick.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_checkmark_tick.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_checkmark_tick.style[domTransition]='';\n\t\t\t\tif (me._ht_checkmark_tick.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_checkmark_tick.style.visibility=(Number(me._ht_checkmark_tick.style.opacity)>0||!me._ht_checkmark_tick.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_checkmark_tick.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_checkmark_tick.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_checkmark_tick.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_checkmark_tick.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._hotspot_preview.appendChild(me._ht_checkmark_tick);\n\t\tme._door.appendChild(me._hotspot_preview);\n\t\tel=me._tt_ht_node=document.createElement('div');\n\t\tels=me._tt_ht_node__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"tt_ht_node\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='z-index: 100;';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 24px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 100px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: auto;';\n\t\ths+='height: auto;';\n\t\ths+='pointer-events: none;';\n\t\ths+='background: #000000;';\n\t\ths+='background: rgba(0,0,0,0.666667);';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: nowrap;';\n\t\ths+='padding: 2px 3px 2px 3px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=me.hotspot.title;\n\t\tel.appendChild(els);\n\t\tme._tt_ht_node.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._tt_ht_node.logicBlock_position = function() {\n\t\t\tvar newLogicStatePosition;\n\t\t\tif (\n\t\t\t\t((player.getHasTouch() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStatePosition = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStatePosition = -1;\n\t\t\t}\n\t\t\tif (me._tt_ht_node.ggCurrentLogicStatePosition != newLogicStatePosition) {\n\t\t\t\tme._tt_ht_node.ggCurrentLogicStatePosition = newLogicStatePosition;\n\t\t\t\tme._tt_ht_node.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_ht_node.ggCurrentLogicStatePosition == 0) {\n\t\t\t\t\tthis.ggDx = 0;\n\t\t\t\t\tme._tt_ht_node.style.top='-47px';\n\t\t\t\t\tme._tt_ht_node.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_ht_node.ggDx=0;\n\t\t\t\t\tme._tt_ht_node.style.top='24px';\n\t\t\t\t\tme._tt_ht_node.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_ht_node.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['door'] == true)) && \n\t\t\t\t((me.hotspot.title != \"\")) && \n\t\t\t\t((player.getIsTour() == false)) && \n\t\t\t\t((player.getVariableValue('opt_hotspot_preview_1') == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((me.elementMouseOver['door'] == true)) && \n\t\t\t\t((me.hotspot.title != \"\")) && \n\t\t\t\t((player.getIsTour() == true)) && \n\t\t\t\t((player.getVariableValue('opt_hotspot_preview_1') == false))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 1;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((me.elementMouseOver['door'] == true)) && \n\t\t\t\t((me.hotspot.title != \"\")) && \n\t\t\t\t((player.getIsTour() == false)) && \n\t\t\t\t((player.getVariableValue('opt_hotspot_preview_1') == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 2;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._tt_ht_node.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._tt_ht_node.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._tt_ht_node.style[domTransition]='left 0s, top 0s';\n\t\t\t\tif (me._tt_ht_node.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._tt_ht_node.style.visibility=(Number(me._tt_ht_node.style.opacity)>0||!me._tt_ht_node.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._tt_ht_node.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse if (me._tt_ht_node.ggCurrentLogicStateVisible == 1) {\n\t\t\t\t\tme._tt_ht_node.style.visibility=(Number(me._tt_ht_node.style.opacity)>0||!me._tt_ht_node.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._tt_ht_node.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse if (me._tt_ht_node.ggCurrentLogicStateVisible == 2) {\n\t\t\t\t\tme._tt_ht_node.style.visibility=(Number(me._tt_ht_node.style.opacity)>0||!me._tt_ht_node.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._tt_ht_node.ggVisible=true;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._tt_ht_node.style.visibility=\"hidden\";\n\t\t\t\t\tme._tt_ht_node.ggVisible=false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._tt_ht_node.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t\tthis.style[domTransition]='left 0';\n\t\t\tthis.ggTextDiv.style.left=((98-this.ggTextDiv.offsetWidth)/2) + 'px';\n\t\t}\n\t\tme._door.appendChild(me._tt_ht_node);\n\t\tel=me._ht_node_customimage=document.createElement('div');\n\t\tels=me._ht_node_customimage__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_external';\n\t\tels.setAttribute('style','position: absolute;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.onload=function() {me._ht_node_customimage.ggUpdatePosition();}\n\t\tif ((hotspot) && (hotspot.customimage)) {\n\t\t\tel.ggText=hotspot.customimage;\n\t\t\tels.setAttribute('src', hotspot.customimage);\n\t\t\tels.style.width=hotspot.customimagewidth + 'px';\n\t\t\tels.style.height=hotspot.customimageheight + 'px';\n\t\t\tme.ggUse3d = hotspot.use3D;\n\t\t\tme.gg3dDistance = hotspot.distance3D;\n\t\t}\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\ths ='';\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"ht_node_CustomImage\";\n\t\tel.ggDx=0;\n\t\tel.ggDy=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_external \";\n\t\tel.ggType='external';\n\t\ths ='';\n\t\ths+='border : 0px solid #000000;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 50px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 50px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._ht_node_customimage.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._ht_node_customimage.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.hotspot.customimage == \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._ht_node_customimage.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._ht_node_customimage.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._ht_node_customimage.style[domTransition]='';\n\t\t\t\tif (me._ht_node_customimage.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._ht_node_customimage.style.visibility=\"hidden\";\n\t\t\t\t\tme._ht_node_customimage__img.src = '';\n\t\t\t\t\tme._ht_node_customimage.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._ht_node_customimage.style.visibility=(Number(me._ht_node_customimage.style.opacity)>0||!me._ht_node_customimage.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._ht_node_customimage.ggSubElement.src=me._ht_node_customimage.ggText;\n\t\t\t\t\tme._ht_node_customimage.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._ht_node_customimage.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=(this.ggDy + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t\tvar parentWidth = me._ht_node_customimage.clientWidth;\n\t\t\tvar parentHeight = me._ht_node_customimage.clientHeight;\n\t\t\tvar img = me._ht_node_customimage__img;\n\t\t\tvar aspectRatioDiv = me._ht_node_customimage.clientWidth / me._ht_node_customimage.clientHeight;\n\t\t\tvar aspectRatioImg = img.naturalWidth / img.naturalHeight;\n\t\t\tif (img.naturalWidth < parentWidth) parentWidth = img.naturalWidth;\n\t\t\tif (img.naturalHeight < parentHeight) parentHeight = img.naturalHeight;\n\t\t\tvar currentWidth,currentHeight;\n\t\t\tif ((hotspot) && (hotspot.customimage)) {\n\t\t\t\tcurrentWidth = hotspot.customimagewidth;\n\t\t\t\tcurrentHeight = hotspot.customimageheight;\n\t\t\t}\n\t\t\timg.style.left='50%';\n\t\t\timg.style.marginLeft='-' + currentWidth/2 + 'px';\n\t\t\timg.style.top='50%';\n\t\t\timg.style.marginTop='-' + currentHeight/2 + 'px';\n\t\t}\n\t\tme._door.appendChild(me._ht_node_customimage);\n\t\tif ((hotspot) && (hotspot.customimage)) {\n\t\t\tel.style.width=hotspot.customimagewidth + 'px';\n\t\t\tel.style.height=hotspot.customimageheight + 'px';\n\t\t}\n\t\tme.__div = me._door;\n\t};\n\tme.addSkinHotspot=function(hotspot) {\n\t\tvar hsinst = null;\n\t\tif (hotspot.skinid=='ht_node') {\n\t\t\thotspot.skinid = 'ht_node';\n\t\t\thsinst = new SkinHotspotClass_ht_node(me, hotspot);\n\t\t\tif (!hotspotTemplates.hasOwnProperty(hotspot.skinid)) {\n\t\t\t\thotspotTemplates[hotspot.skinid] = [];\n\t\t\t}\n\t\t\thotspotTemplates[hotspot.skinid].push(hsinst);\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_sizechanged();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_changenode();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_configloaded();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_mouseover();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_active();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_changevisitednodes();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_hastouch();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_activehotspotchanged();;\n\t\t\tme.callChildLogicBlocksHotspot_ht_node_varchanged_opt_hotspot_preview();;\n\t\t} else\n\t\t{\n\t\t\thotspot.skinid = 'door';\n\t\t\thsinst = new SkinHotspotClass_door(me, hotspot);\n\t\t\tif (!hotspotTemplates.hasOwnProperty(hotspot.skinid)) {\n\t\t\t\thotspotTemplates[hotspot.skinid] = [];\n\t\t\t}\n\t\t\thotspotTemplates[hotspot.skinid].push(hsinst);\n\t\t\tme.callChildLogicBlocksHotspot_door_sizechanged();;\n\t\t\tme.callChildLogicBlocksHotspot_door_changenode();;\n\t\t\tme.callChildLogicBlocksHotspot_door_configloaded();;\n\t\t\tme.callChildLogicBlocksHotspot_door_mouseover();;\n\t\t\tme.callChildLogicBlocksHotspot_door_active();;\n\t\t\tme.callChildLogicBlocksHotspot_door_changevisitednodes();;\n\t\t\tme.callChildLogicBlocksHotspot_door_hastouch();;\n\t\t\tme.callChildLogicBlocksHotspot_door_activehotspotchanged();;\n\t\t\tme.callChildLogicBlocksHotspot_door_varchanged_opt_hotspot_preview_1();;\n\t\t}\n\t\treturn hsinst;\n\t}\n\tme.removeSkinHotspots=function() {\n\t\tif(hotspotTemplates['ht_node']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['ht_node'].length; i++) {\n\t\t\t\thotspotTemplates['ht_node'][i] = null;\n\t\t\t}\n\t\t}\n\t\tif(hotspotTemplates['door']) {\n\t\t\tvar i;\n\t\t\tfor(i = 0; i < hotspotTemplates['door'].length; i++) {\n\t\t\t\thotspotTemplates['door'][i] = null;\n\t\t\t}\n\t\t}\n\t\thotspotTemplates = [];\n\t}\n\tfunction SkinElement_map_pin_Class(parentScope,ggParent) {\n\t\tvar me=this;\n\t\tvar flag=false;\n\t\tme.parentScope=parentScope;\n\t\tme.ggParent=ggParent;\n\t\tvar nodeId=ggParent.ggElementNodeId();\n\t\tme.ggNodeId=nodeId;\n\t\tme.ggUserdata=skin.player.getNodeUserdata(nodeId);\n\t\tme.elementMouseDown=[];\n\t\tme.elementMouseOver=[];\n\t\t\n\t\tme.findElements=function(id,regex) {\n\t\t\treturn skin.findElements(id,regex);\n\t\t}\n\t\t\n\t\tel=me._map_pin=document.createElement('div');\n\t\tel.ggId=\"map_pin\";\n\t\tel.ggDx=-191;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_container \";\n\t\tel.ggType='container';\n\t\ths ='';\n\t\ths+='bottom : 380px;';\n\t\ths+='height : 41px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 24px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._map_pin.ggIsActive=function() {\n\t\t\treturn player.getCurrentNode()==this.ggElementNodeId();\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._map_pin.onclick=function (e) {\n\t\t\tif (\n\t\t\t\t(\n\t\t\t\t\t((me._map_pin.ggIsActive() == false))\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tplayer.openNext(\"{\"+me.ggNodeId+\"}\",\"\");\n\t\t\t}\n\t\t\tif (\n\t\t\t\t(\n\t\t\t\t\t((player.getVariableValue('vis_map_close_desktop') == true)) && \n\t\t\t\t\t((player.getHasTouch() == false))\n\t\t\t\t)\n\t\t\t||\n\t\t\t\t(\n\t\t\t\t\t((player.getVariableValue('vis_map_close_mobile') == true)) && \n\t\t\t\t\t((player.getHasTouch() == true))\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tplayer.setVariableValue('vis_map', false);\n\t\t\t}\n\t\t}\n\t\tme._map_pin.onmouseover=function (e) {\n\t\t\tme.elementMouseOver['map_pin']=true;\n\t\t\tme._map_pin_tt.logicBlock_alpha();\n\t\t}\n\t\tme._map_pin.onmouseout=function (e) {\n\t\t\tme.elementMouseOver['map_pin']=false;\n\t\t\tme._map_pin_tt.logicBlock_alpha();\n\t\t}\n\t\tme._map_pin.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['map_pin']=false;\n\t\t\tme._map_pin_tt.logicBlock_alpha();\n\t\t}\n\t\tme._map_pin.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._map_pin_normal=document.createElement('div');\n\t\tels=me._map_pin_normal__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_map_pin_normal';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAABSCAYAAAAWy4frAAAP30lEQVR4nN2bfYzlV1nHP+f8Xu/bzOy87U53ZrdtcFugFiwhrRKhDcY/uhL5x0b5xxDDHyZq1Eg0DUEgQqRGXpoK0WBM1ShgAikRTa0KVAi02KYYaLsF2i47szs7L3dm7vvv5ZzHP87vzu7s7tw7L3dq4rM5yeTe3z3n+Z7vc56381v1S7/5e/x/EH/UE16auGfeC0sntR/OCzKPyAJoDyWvKtSizdNFk3aXSpWtSxNLL5hRrTsSICuz992tPP9XgAcCpRbcp4ICUAoQ+p9pP0D7AbmM1VfnTn7ZWPP52F/+2mFBqYOa1qWJe+b9Uu13gQcULOycVRF4Hn4QEAZur9IsJ88yMmNAhGuer4vYL0uePzS7+vWXXhMgy9U3VSiN/6H2gj/QSpf6n5dKJW'+\n\t\t\t'qVMrValcDXA+fIjdBqd2i3OzRbre3PrdiuUvozSbv+sfnGM/UjA3Jp/J73+uXahxG7ABAGIccmxqnVqvje9cqLCLb4WwNKqeueMSK0Wh3W1+ukWdr/3ary/I8G6sIjezW5PZ2R82NviMqVm/7Ct/Y3sAalPWanp5gYr+1QOjNCkluMFXIrmGtMyCuARL4m8jSBr9DAWLXMWLXM5laTlbV1EDODyT+VyOwvLlfDB060vtcepuNQRhbH3jIZxtUvKeW9A2BsbJzZmSk87ZQyVuhm1gG41vb3IJGnqUbejvnW1utsbm4CYK35H5slZ+c2v7M4aJ6Bxrwyc++ZMB77Lqh3iFiOz85y/Pg0SiusQCsxrLUz2qkht4II+x693LLWztjq5hgrKK2YmZlibm4OAKXUnV5UfnZl9r67DwTk0sQ982j9TZBblfY4tXCKscKU0lRY'+\n\t\t\t'a6e0UoPASEY3t6x3MjqJOxLVapmF+Xm0F4DYGbT+2sXqXXfsC8hy9U0VHURfReyM9gJuOX2KOI5AoNnN2Uwy7P6taKhYgVZqaHQMCMRxxM2n5omCEKwp+eXxxxbH3jK5ZyCE1b/XYu/0EeZvmsP3fYwV6u2MTmoRy5GObmaotzOMFXzf58TcTSilUTa/NYyrX9o8+XpvKJDlmbd/RCn1bivC9PE5oih0IDoZqbHIa/QvNZZ6x4EJQ5+5uTmsCGLMO9J0+s8GAlmZufeMsvZBgMnpWSrVKlag0cvJzf4Ps6eVc7W+xtNq37/PjbDVzbHiAu7k9CwAYuV3VmbuPXO17jviiDXZx5VSXhxFTE46U+ykhm5m2YtoBZXQudJAa/S1fAtkuZCJpZPuzV33covq5YzFPpOTk3RaLXq9jidKPgmcvY6Rldn77kZ4t1jh2NSMWz'+\n\t\t\t'QTmj2zJ7cTac1UOaQceESeRhe5Ypam9Hrpdt4Y+Ipy4DFZDoh9vae5u6mLUwhMzcwgVpAsv3/5+H2/0Nd/mxHJep8CKJVrlMrOpJqJuS6/u1aUgmrkUwrcnmRZytbGBr0kIU26GJO757RHHEXEcZnK2BhRVKIW+YTa0kjyoes0e4agrImiEqXqGN3WJsraPwfetM3Iyux9dwvcAzA9ewKAJLP0jMXCrkMpmCwF2yCaW1ucf/VlNjbW6HaaO0CINXS7HTY21lg8/zL1+joiEAWa6UqI76mBa6VGtk18enrGbX6e3tkPlD6AFXNWRCiXKwRBiAg0knzwFuGY0FphTc7ypYt02g0ATk/XOPvmBd6wMM0dC1MEnuaFpTrPL23wn99f5Lnza9RXL9FtbDFz0zxBEFILfda72cD1WklO7IcEQUipVKbTaWOSzq8CT3ln3vqz'+\n\t\t\t'NLyZzyqlpmvHpimVyiTG0E0HH/DY96hGzp0vL52n026CUrznbWf4+Ht+jre+7gTzU1VC38P3NCcmKvz0qSne9ZZbqJUCvvvKOmnao91qMj4+ged5gJDlu68r4s6YrzVWhE6rgVhzrJZefERfrN51h9LebQDVag1rhV5uEVG7DoBKrLFW2Nqq02m3UFrzyHvfzu+ffTNRcF282hal4D1vO8Pnf+ud1OKAPEtZX13FWqHse2i1+7oiil5u3bPlqptPe7ddrN51h0bkLCJEUYznBQB0E8HK7qMceGhRGJOxvnIJRPj1nz/DPT91YiCLV8vNs2O8/10/AyJsbaySJi5Tr4X+wLW7ifMKnhcQRXE/6JzVyg9PAHhRGYDcuh8MkqAIEJvrq4gx3DxT433v3DWf21Xuv+sW7r3dga+vrADge9cXX1eLFSEtEr0odjoL3KKV59'+\n\t\t\t'8sYomL2tra4RG3v1jS6yBiefdbbx1oToPk197+ekQs3Z5jRCsK89p9/X7Z6fs+IhZgQdu05xoHngOS2cGH3NMKrVymmvS6ANxxavpAIABuu8llEGINed5zCg7Zk20dC52V0sc1yEmsJfB8rEC/ybF7/uRA5GkbKeLE60/eMLPek1TjgPnJClhLt9vFijPdQToY43QIPN+ZEHJSi7UVB8u5NCMgIrsOjXsuz1wBVAnUgc2qLxPlCACbZVgRtBqsgxF3VlDurIq1Fa08/6KIkOWug+GpwalPn9aoVEJEaPVyXl1pHBiECJy7tIWIEBQOp5fbgTpozx32LE8REZTnX9RizY8VgkkdkGEHrR+wRPmEYYhCeH5x/cBAzq82yNIEhRDFjplsSMngiWPCpCkKQaz5sQYuWCtkeYa1MKS35s5HLlgLQVTBWuGpc0sHBvLNF5ew'+\n\t\t\t'VgjCCCM+1rpUf5BoRfFchnWu+IJW8AoIaeI8kC7aMoN2JDVuodLYOCD88zMv88zLl/cNYqne4q/+7TlAKI85h7GXAq7v/p3OgoJXdN7rfBsgaW1hcueFAn+webVSd9BLlWOUx45hreWP/+FJkmzvfWgR+NDn/4tmJyGKS1QnXGBsJ3bg2oFfbLQVktYWAKbXfU6PndDfUlo3wQU4gMgb7IWyXGgXSeWx2dNoz2ep3uZ9n/nXPR38eqvH+x/9Ov/9I8fi1NzNKK1Ic6EzZDPiIsh0O83+lnRsRX/du/O218mmTNytlLpda01cGQcUnXTwhGkuRL7G15qwFNNpbLCy2eKfvv0Sge9xemaMUrizI9vqZTzx3Cv89uf+gxcvrALCsePzxJVjiMBaO0OGpEfjsY8CWvVl0l4LkCdOdZ7/Wx8gqEw8lnebv9xpbTJx/DS+dh'+\n\t\t\t'SmAw6diLDVy5gqB0SlCY7f/EY2l1+m12nx8Fee4uGvPMX89Bi3z89QiXx+cH6FH1/e3FbUCyIm524lLtcQYDNxncZBEvouqxCg03Jzic2/Cv1SV/EEgMkSep0mYalGyfNIssHFVZIJ9W7OROzjBTFTC2+gWV+iub6MWMPiWoPFtZ2mppSiOjHL+Mw8ojysuHPRSYY3OMqhyz7SbhOTJQAE1WNfYbMAMrf5ncXF6I3/Itbe39y8zFSpRhho6DG0lu4mll6aMhH7xKGmNnmS2uRJTNYj6XXIu02sGOJSlSCqbmfZgvNQG13XahomSkFUeKutjWUQi4g81m9uX2k+5OZhtLq/t7WGmTmN5weUIk2nN3ynRGCjm1MzPuXYdVC8IKYcxFC7Pg+zAp2epZkOL6f7UoucqibPSBsuACvhs/3vt4HUTqh/byyb88DpTmOFyrGT'+\n\t\t\t'lLRHW/bW0wJX5zcS0Bpiz8PXirBwl5kVslxIrSE/wG1h5LsbgHb9ImINoM6dMuce73+/Hccnll4wUiBsrju36PvKxRT21H7aHsZCOzNsJTmr7YzVdsZmN6edGbK9tcl2jChUrslhhdamK8BQPHw10B0JiS/qb4DEZl16rfp2WTsoE30tRsX3XJnbvIzNUwQaYRw/uiuQk3JuBcUXAZr1SyCOUq2GpMRHOHxPuZREoF2/XJDB3117HXddiqhEHgHI2ptkRf5VDrz/KxxU+yV42iLvtQCsUvpT1+p9HZAF88OngWcBOlsXHZBQo3De5rUcnlbEoXMWm+suwxZ4YiF/8UdDgQCI4pMA3Y3L26xUo5G/7TFUxqIirU+6V1wu6mM3evaGQMaPe/8I6gewkxWv/zbGazAC74rrbqy96hQT9Y1T5tyTewbiLunlg+BYMVnBSu'+\n\t\t\t'gPrRVGNfpnI+m2yVobFHR88Eb67goE4JR56UsUZ6VZX8SKEIcKT8NRX7uFgSIMXIOhXX/FkQGP78bGQCBuA/SDAGljlayoVWrR0bNSLroySbtJ3nFJp1X80SBdBwJZMC8+DnwLoLP5EwDHirf/aL/XEfqKOHBno7v1k2JH9WO35C89d2AgxSwPAmStjW1WxiP/yA553ztexYb14/IHhmk5FMgpc+5JgccBOhvnMQJB4KLtqONGWOR2RqBTnA3gCze1nv3+oYG4h5wHy9qb5EWtPB6PPq7UijmT5gbGXTNYpfSunmqnjnuQBfPDp1H6MXB2K9blQIGnRpYYxoHC1wqxkGxdcAuLevRGUfzAQAAKO7V5p0Hadn59fITRvl84pe1tNhKlbxzFbyR7BlLY6Rfgyo4FgSL0B3fO9zKiQG833Xob5/tLfm6vbOwLCEBhr9Yk'+\n\t\t\t'bdL2BtYW+dAhD/lY6HKq7tYK1mURSVCb/NP96LYvIAv5iz9C1KNwZed8T1EK9zXNDimFGs9TWISsWfSQRT0y7I25a2XfGgRjxz5IUUXm3Q1EHCsHMSlw50wEsuYqNush0PCEh/ar176BFDv1OXCsCIKnFeVo/6yUQo3WCkFIiyiu4NMn5dzKfuc6kE14Vn2EgpWstYogVIPB18rXDiiYREgay4jJEGjoSu266u/IgJyUcyuIciVx4wJi3d2ia1Tszaxi31WdYiEvzoaCT+/3xeVDAQHQ1erHBBo2T0lbywhQjTxu8I7ydaIUjMU+Au63JgNYCUuljx9Yn4P+cL7xTF3Bp+HKjvqe2hMr5cBDa7AmJ2+4mCTCJ/byovLIgQAUO7giJiNrLQPDWemzAZA1LxddQ1aicumRw+hyKCAnWt9ri/AJgLxxAWtytFJUwt1ZqY'+\n\t\t\t'SuaLImx3ZcPwClPnwYNg4NBKDYyRWxhqzpGmj915+ujeBXf5c1L/XZOC9l768Pq8ehgZxofa+NUh8G3A5LwUp0/fVdLfaKrmWO7ThTRKmHTjeeTw6rx6GBABQ7et6xcgkrQi0qXtDsL6SgErq3JpLNC9tsjB3XfzkKHUYC5HTj+QSlHgKwnWVMnqGuYaUSeSilMHmGdJ0JiuIDo/p/ViMBAuB2Vp0Ta7CtpR0HG9h2ALbVf7lAnXONwNHIyIBMLL1gRMmfAEj3MtYFOWqxRy3ue6orbIA8OMr/9TYyILCz1drf+UroXXG522zwbNEAHJmMFMjVrVbpXkby3nabR/LeVWzw0VGuCyMGAjtbrbZ95WWbq/4eORtwBEDgSquV3ho262CzDvTWdn43YjkSIFe3WqW9iLSLqlXUN4rvRi5HAsSJa7WSbrgBA68FDitHBuTq'+\n\t\t\t'Visw9FrgsHKEjFxptV7791HIkV4MLpgfPv0T//bHABbyF58+yrWO/IbTYD901GsA/C9GVYNNoq0j2AAAAABJRU5ErkJggg==';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"map_pin_normal\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='bottom : 0px;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 25px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 15px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 100%';\n\t\tme._map_pin_normal.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._map_pin_normal.logicBlock_scaling = function() {\n\t\t\tvar newLogicStateScaling;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['map_pin_normal'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateScaling = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateScaling = -1;\n\t\t\t}\n\t\t\tif (me._map_pin_normal.ggCurrentLogicStateScaling != newLogicStateScaling) {\n\t\t\t\tme._map_pin_normal.ggCurrentLogicStateScaling = newLogicStateScaling;\n\t\t\t\tme._map_pin_normal.style[domTransition]='' + cssPrefix + 'transform 200ms ease 0ms, opacity 500ms ease 0ms';\n\t\t\t\tif (me._map_pin_normal.ggCurrentLogicStateScaling == 0) {\n\t\t\t\t\tme._map_pin_normal.ggParameter.sx = 1.1;\n\t\t\t\t\tme._map_pin_normal.ggParameter.sy = 1.1;\n\t\t\t\t\tme._map_pin_normal.style[domTransform]=parameterToTransform(me._map_pin_normal.ggParameter);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._map_pin_normal.ggParameter.sx = 1;\n\t\t\t\t\tme._map_pin_normal.ggParameter.sy = 1;\n\t\t\t\t\tme._map_pin_normal.style[domTransform]=parameterToTransform(me._map_pin_normal.ggParameter);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map_pin_normal.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((me._map_pin_normal.ggIsActive() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._map_pin_normal.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._map_pin_normal.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._map_pin_normal.style[domTransition]='' + cssPrefix + 'transform 200ms ease 0ms, opacity 500ms ease 0ms';\n\t\t\t\tif (me._map_pin_normal.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tsetTimeout(function() { if (me._map_pin_normal.style.opacity == 0.0) { me._map_pin_normal.style.visibility=\"hidden\"; } }, 505);\n\t\t\t\t\tme._map_pin_normal.style.opacity=0;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._map_pin_normal.style.visibility=me._map_pin_normal.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._map_pin_normal.style.opacity=1;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map_pin_normal.onmouseover=function (e) {\n\t\t\tme.elementMouseOver['map_pin_normal']=true;\n\t\t\tme._map_pin_normal.logicBlock_scaling();\n\t\t}\n\t\tme._map_pin_normal.onmouseout=function (e) {\n\t\t\tme.elementMouseOver['map_pin_normal']=false;\n\t\t\tme._map_pin_normal.logicBlock_scaling();\n\t\t}\n\t\tme._map_pin_normal.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['map_pin_normal']=false;\n\t\t\tme._map_pin_normal.logicBlock_scaling();\n\t\t}\n\t\tme._map_pin_normal.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._map_pin.appendChild(me._map_pin_normal);\n\t\tel=me._map_pin_tt=document.createElement('div');\n\t\tels=me._map_pin_tt__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"map_pin_tt\";\n\t\tel.ggDx=0;\n\t\tel.ggDy=38;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=false;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='opacity : 0;';\n\t\ths+='position : absolute;';\n\t\ths+='top : -10000px;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 100px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='cursor: default;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: auto;';\n\t\ths+='height: auto;';\n\t\ths+='pointer-events: none;';\n\t\ths+='background: #ffffff;';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: #000000;';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: nowrap;';\n\t\ths+='padding: 0px 3px 0px 3px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=me.ggUserdata.title;\n\t\tel.appendChild(els);\n\t\tme._map_pin_tt.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._map_pin_tt.logicBlock_position = function() {\n\t\t\tvar newLogicStatePosition;\n\t\t\tif (\n\t\t\t\t((player.getHasTouch() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStatePosition = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStatePosition = -1;\n\t\t\t}\n\t\t\tif (me._map_pin_tt.ggCurrentLogicStatePosition != newLogicStatePosition) {\n\t\t\t\tme._map_pin_tt.ggCurrentLogicStatePosition = newLogicStatePosition;\n\t\t\t\tme._map_pin_tt.style[domTransition]='left 0s, top 0s, opacity 500ms ease 0ms';\n\t\t\t\tif (me._map_pin_tt.ggCurrentLogicStatePosition == 0) {\n\t\t\t\t\tthis.ggDx = 0;\n\t\t\t\t\tthis.ggDy = -38;\n\t\t\t\t\tme._map_pin_tt.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._map_pin_tt.ggDx=0;\n\t\t\t\t\tme._map_pin_tt.ggDy=38;\n\t\t\t\t\tme._map_pin_tt.ggUpdatePosition(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map_pin_tt.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['map_pin'] == true)) && \n\t\t\t\t((me.ggUserdata.title != \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._map_pin_tt.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._map_pin_tt.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._map_pin_tt.style[domTransition]='left 0s, top 0s, opacity 500ms ease 0ms';\n\t\t\t\tif (me._map_pin_tt.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tme._map_pin_tt.style.visibility=me._map_pin_tt.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._map_pin_tt.style.opacity=1;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tsetTimeout(function() { if (me._map_pin_tt.style.opacity == 0.0) { me._map_pin_tt.style.visibility=\"hidden\"; } }, 505);\n\t\t\t\t\tme._map_pin_tt.style.opacity=0;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map_pin_tt.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t\tvar ph=this.parentNode.clientHeight;\n\t\t\t\tvar h=this.offsetHeight;\n\t\t\t\t\tthis.style.top=(this.ggDy + ph/2 - h/2) + 'px';\n\t\t\t}\n\t\t\tthis.style[domTransition]='left 0';\n\t\t\tthis.ggTextDiv.style.left=((98-this.ggTextDiv.offsetWidth)/2) + 'px';\n\t\t}\n\t\tme._map_pin.appendChild(me._map_pin_tt);\n\t\tel=me._map_pin_active=document.createElement('div');\n\t\tels=me._map_pin_active__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_map_pin_active';\n\t\ths='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAABSCAYAAAAWy4frAAATIUlEQVR4nMWba3Bcx3Xnf6e77wxmQFLiA5Yl0SQlK5JsQpJtWCJVVhKwnCwp26mkolBVydbWVqKqPKryIZ9clVQSM0pixS57vYmTKEqZ5Yo363VZeViJYlMVe4lNLJESRclLgqHEOLT4BgmAIDDPe293n3y4M8AIJEGAguSDupiZO7cf/z6nz/n36R7hOuTrO7EAjz5NAFAwz2299wNC/EiEB1DuBt1kRNYqCICARtVJkDcQXjPwkmKe377/0PcE4pXqXYrIUh5WMCPDw2bbyIgH2HP/+zeLMf9VhZ8xIu/rdxYAr5DHSFB9U3krQmIMrtNqwwei6lFRvqEx/u8dB/7tCMDe4WE3PDISuwCXFchTQ0PJrxw8mAP80wODHzaG3xL4mZXOSY6ShqgxBO'+\n\t\t\t'+9F9UgghgRI7MtKKhGVTSKWHXOqbHWla2RBKHmvSp8I0Y+/fGXRl+e3+ZyAJG9w8N228iI/8ehO9clSemzVuQXK9bQjEoIIc/z1AjG9q9YwapVN7ByxQoq5RIll4B0mlAl8zmtNKNWrzMzM02jXkeJIUnK0VqbVI3QCpGg+uU8zz75UwePTewdHnbbRkZCMRTXCWQXmE+BCuieLff8NKK7Vzq7thFUYww+S1NX6e+Xd990E+9as5ZV/VVKzmGMKfp+lcZijGTeM9NocuHiJGPnz9NqNrRUKntjrOu3IjUfJlF5bMeLh59RkN8D2bWAqV0ViILp2uhzWwY/3efMb3oFr5qlabtUqVTZ9J4N3DKwjkq53OmgoqrowoOHIIgIxhTNt9KUs+MTvHHyJK12k3K5L3MiJSfQ9vGJ7S+O/tb8Pi0KSG+BPVvu+eoNifn5magh'+\n\t\t\t'hojPU7thw0beu3491b4+YoyEWNQtsiTfgXacgTUGYwzNdpv/OH2akydP4JJyMNawyoidzuP/2fHi4V9YCMxlLWth1QqwZ+vg39zg7CMzIWbe50niEnn/nXdx89q1RJTYBbA053c5IOYACcK5yUn+7djr5D5X55J8lTWlaR/+dsf+0Z+b38eumPmVPr2zuPfc1sEv3eDsI7WoaZ7npWp1hTxw333csm4tPgRiiMjsSOhburr1hBDxwXPLurU8cN99VKsrJM/zUi1qeoOzjzy3dfBLvX3sFdv74eWhoeQnv33O73lw82+scu43a0HzPM9KK/r7uX/zIP2VCrn3GOkC6PGtl32Wea+93zPvOTqACt36EKiUy7xrzRomLl2i1W47LyZf6eyHd966bvqnnxvf9/LQUPKX587NmthszR035/c8uPkBi3kxAsF77euryP2Dg1'+\n\t\t\t'TLZXwIS54H1yuqirOWZppyYHSUdrul1jkxQCBu2bHvyEvdPkPHtBSkewOV3YkRVNWLEbnvrruolsvkwXdCwlszo0Wbm0AePNVymXvvuhMREVX1iRFQ2Q2wbWTEdymQAfjLoSEHsGfr5k+ucnYwjWRZlrq7b7+D1StWFOaELKkvqoU77r10iXgMgveeNStWcvd77yDLUpdGslXODu7ZuvmTvX2XXWB2QXz2oXtWO6//nhiztpmm8V3rBsyH7ryT2JmMizeJwgtZMTgz5w5A8VEJGjtxZAl1UoB65dgxLkyMx2q5bPIYJ72TH/nEdw9P7QJjfnx42AA4r7+20tm1PmpurTF3rF+PEYGoix7BGBUnQtk6fIycrTc5MT3DiekZztab+BgpW4cTIS6hXqJiRLhj/XqsNcZHzVc6u9Z5/TWAHx8eLkLrNx++o2ymyq+VrdtU'+\n\t\t\t'b7fCe25Zb+/ZtAkfw6JjRFSl7BxT7TYjp87yT8dPsPvYDwoVAYjw2J238fHbNzL8nltY3ddH6n0xWIvSiuKM5fAbb3Dq7Omwoq9i0+DfiKvTuz/2re+nDsBcrOyoOtnUitEbY9yt69YVJtLrHRdqRJWytXzvwgS//p3v8vz45Ox3a2zh8i+GyO7Xj7P79eN8ZGAtf/rRh/jAwFrSRXrCbn9uXbeOM2NnbRajr1q7qXmxsgN4phNY9GetMeR5zpobV7OqUiHEUGDo1nCVK8ZI2VqePzPGB7/2DM+PT3J3f4UBZymJMB0i0yFSEmHAWe7ur/D8+GTx7JkxytYWDOEa7QgQYmBVpcKaG1eT5znWGEB/FsC88OCDFYThrKDkZuDGNThjCh50rTmhSp+1fH9qmof+7psAbCyXeK3RYtwHclUiBTHKVRn3gdcaLTaWSwjw0N'+\n\t\t\t'99k3+fmqbPWuIi2lNVnDEM3LiGEILJooIw/MKDD1ZMLdbfb0Q2pCFQShJZ3V9d1AihigFSH/iTVw8DcFtfiRNp9qb43nvRsdQTacamvhIAX3z1MKkPnYB27TZjjKzur1JKEklDwIhs6GDgnqo1xBh9pVKRSqmEql6TQ0WNlIzhtYtTfPHIMW4rl/hBO8P0dPqKtk4RvH7QzritXOKLR47x2sUpSsYQNS7YplBopVIqUalUJMboq9Ygwj0mwvuMCCFGqn0VEmvRK7nG3p50w6kqr1yYeFNHF7PInv/MKxcmZufBZe313lPQqCTWUu2rEGLEiBDhfU7RDcXDqtVSaRb1ZY5kXuVCkWA4OjkFgNeF9HBl6ZY5OjlFHmOPFVwBTLcbWiwbqqUS3QWNohucwE2hmEhSTkpznmpR8UNJvZ99v3QpyqTed+bAYooUmisnJVRV'+\n\t\t\t'QmEdNzlFk+4zZna5sshKL+/T9ZdZLJBO33oDqaKJE5lXXAtyJ3L1WrvfWAwDlT5g6cvc3jIDlb6CINJdcS4AQ7v/eupR1KHiu6VDjJ34odekilEV64R7160FILkOIN0y965bixUhCwWnWlAxWiQ4QoxziEWCQ2XMCIiIplk6mxCYj3o+riLSRj44sAaAsSwjEcHrtXIoRVknwliWAfDBgTWE7mSf5WYUqr/CAlNVSbMUEdFOIua8QfS4UNhcM02JehVdzHPHAmQhsL6/ypd/bAsNhburfbNtLwRCKZ5tKHz5x7awvr9KFsKby+m81573qkoryxApKK0ox40gR6MqxlhppG1y72dd8GL4jw+RR27fyGN3bOJwo8W9/RVKC5hZSYR7+yscbrR47I5NPHL7Rnzo0cYi2ETuPY20jRhrYmEBR11UPVz3ASPi2mmqrSyTUq'+\n\t\t\t'XSddgLiiD4GKlayxNbPwQou79/AgfcXk6I82zMCJxMcw41Wjx2x0ae2PohqtaSdQLbtdyWdrxVO89pp6laEdvwgWjiqNM17ddlqu8HJWtum8kzrbVasrpS6WTSrzWBixHKQmBNucT//MgDPPTum/jF5w9wPL1K7lmEL3/kfn7uvRupOEtW8KXL5+RVkAhQa7XIvdcV5bKkMZ6xDXfMfexb30/3bB08UBJzmzEmTjXqZv3q1XNDsAgxImQhUjaG/37Xe/mJ9TdzaOIiR6YuMZMWE3pVucTm1Tdy77o13NpfxcdIFuLiQfSAmWo2EJFYMsZkGl7efuhQw3W+/WdFH7XGcqlRJ81zStZxbf8zV7kBgirBe26uVli/cT3bN9w66wVFBCtC0A4bEJljvIuUgm17LtXrOGu1cNTm2wAOIDGyt+6Dd8a4ZprqdKspN61chY9L'+\n\t\t\t'Szx0n81DIFO9LEh2773JzS5SlCKlWm+3aaZtdc4lNR8QY0YAjIJ89IXR/wD291kDQhiv1eYC47UdyWUXHWJ3ucsu7l1Pnd2F3kS9RtAY+4xB0Ve3v3BoFIqtNAsgyjMWsMYyWa/RznNEpGNeP9xLUQxC6nPGazMk1sVEBFGehSJLasYHRrQwi/BMrWNerTTVqWazZ9XW+9p9r/Pam/95Md/pFeqb307xagSmWy0a7ZYaMUk9BBD7DYDxgQEVKHamdkHcs3Xzt/ud++h0mvl3rbrB3XfresLVIv07KN21+pGxc5yemgyrSmXbjOHlh/eN3t99xkCR4AIQ+F8COFuYVz1NsXTt84dzqRZEspXnTNRrJMZFJyCRr0GxYToLZLjYbKTqzD/Ucj+RGOPy4OOFWq0zQRcym7f7KubHRL1OK0ujNZLUfGgHG/4G4NzBg2EWiI'+\n\t\t\t'DuHR52P/rdw1Mi8nSfMSTWhbGZaTKfFwnsHxKS7n7JuZlprLGxYg0K3/r4C0dPfH0ndlcnBTC78zM+MFBMepXdjRCwYlwtbTHZbBZrhB+CVlQVK8J0q8WlVgNnrQRVUPkSwMD48Oz0nc+cjUDcs3Xw//Zbu20mz/2aar/74C23LjV+LYsoYI0wen6MszNTYWVSsu0Qj27fP7p5wT3Ekc6kNyJPKsWO0WSzwaVWC9vVyjukjkIbUE9TxjuTPClyCrsFtDvJrwikO+mT8tq/b4ZwrGzEKTGcmZmhw/vfOYcFgHCuViPzPjpjknoeLjn4a5ib5FcE0kW6bWTEC+YvEhFKxsUL9RlqaYoV5rQyXzvLqa0OCW3nOWO1aRJrQ6XYgf3qT7w4en7v8LDbNS/Pd9k27y8fPOgBVOJf1byfcMYkeQzxXG0G0R7+xLz2539ehkl+'+\n\t\t\t'vl6jlWdqjElqPpCb8CRAl40sCKSrlR37jlxU4UsVI5SsC2P1GZp5NqeVtzkAZt5ztjaDM9b3W4PA33/ihaOjX9+5017pPNdlQDpaKYKMlz+fyUPDiiRtn8cztZmetfXyaeDNV2FWFxoNamlbjYhNY0Sj+QLAwPj4FRnTFYEIxL3Dw277gdFTCF+pWkPJuHC2Nk0rzzu5p7cHSTehcbo2jTEmVK01edSRHS8d+tddMHvobVFAAIZHRiKAWvPHNR+CMZKkPtdzjXpxXOJt0Ep3bky0mkynLZwx4lVB9DMwxwmXBKSrlYefP/Q68JV+a3DG+dMz0zTzgrYst1YE8DFyauYSRoyvGGPTGF/ase/IHu091LAUIDDnHaLq52o+RGskaflcz9Zr2CL5tayT3Iow2WwyVWijA5DPA3QXgAsM/MIyd0Zl8Csrrf1vNR9yKya5/6'+\n\t\t\t'abi41MfXN2cynSLdNb9tXxMS5laVjhrG2F+P937B/9wGLqWlAj0OOzTfxMzQc1hQfTs406QkFbuia21L/ZMh2Xe6HV5GLaIjFGO2cmnugO5rX6uahBnNXKlsHdKxP7SzUfciOS3D9wM2U3p5W3Kq9MnKeWpb7fWdcK8cCO/aMP9PRTFyp7TY3AnFbUmc/WfAhGJEmD1zONWk9uSudee9/3zgXm3WOOHF5oNbiUtjqn6AAtPFVHGwuC6CJdlHTP4O7ZOvjkSmd/teZDLpB8eODdVK0r1vbXeZZLVXll8gK1POvOjZd27B/dolc48nc1WZRGAFbffrCIK7jP1HxoW5EkiyGertfmRuN6PBVwvtXkUtbueCoQ4ffh2p7quoA8+jThqaGh5OH933tD0Cer1pAYG862GtTybC5JsYS4YYAsBk42ZnCduNHy8V+27xt9dtcC'+\n\t\t\t'UfwtAYG5NYAPfHbGh5oTSXwMerLRq5XFXV1tjDWbxUAYI0EVY8zjsHAUf8tAdkF8amgo+fiBI2Oi+oWKNZSM9YVpLD51pJ3MSDt4TjVrOLG+aoxNY/jWf9l36Dtf34ldijaWDATmtGJ963/UfDjvjEmCajzZqMFi3XBHG2eaTZo+VyfYNEai2sfhzUmFxcqSgeyC+PLQUPKTB49PK/qZPiOUjA0X0haTaRtDseOrC1xGhIbPOd2qkxjrq85Krvq1j714aH/vydG3FQjAUGcVWavxZzN5OF4ykggSTjRrhKjI/MX3PLMShVPNBmkomELdhxjgcbjy6u9tA9JdRT565EhmRB93IjgxejFLmUi7GZfu03P9UgWLUPMZZ9tNEmN8vzUg8uQn9o8e3Ts87K7n1zzXDQSg8wMV2b7/yF81Qnilz4ozRsKJVmPugMz8id5xWS'+\n\t\t\t'ebDXyM6kSSmg91nP9DgP/XWQO9o0AA9nb3VoRPATgxTOcZ59utnoxLIarFIYFLWcb5tEXJmOKsFXxux78ePffy0FCyawk/RVpWINtGRvwuMNv3jT7bCvHbVWOsM8afbDVIQ+gcei60IRSn30606iiExEgy4/3ZUp9+HuDZeXmqdxQIzAUuNfK7aYxYMI3gOdsuNoq6nsoijGcpE3lKSUwsGQPI728bOVJ/6i1qA5aHfffQ/Hu+uiIxP1/3ITeQDK1aQ58xs87r1doUtRhCvzG2FePhh/eP3rsc7cMyaATmXKYYHq93aX6MerrdRBSswFja4lLIcVIcJxeV34HFLZoWI8sCpEsot+87/Brok/3WkBjjz2YtGsGTx8gbaZNEjK8aY1shfGfHi4ef2bVEYriQLAsQmKMu5cAfzhFKjafTFqfSFu0Y1DBLRX4b4P07dy7b'+\n\t\t\t'9uSyAdnVIZTbDhwZAz5fEEoTxvKUU2mLkhjf76wE1b/uUpFHn376LXmqXlk2IDCXADdN87m6D2ecSCLFYWwFkroPWR7kU3D9VORqsqxABPTloaFk+6FDDVV9onOSIgr4lc4C+oVPHDh8/KmhoeR6qcjVZFmBwByhnNlw5C9mvD+WiDgRkhkfLpT7kj+CyzdplkOWHcgsoXyaICp/YI3QZwwon9428r1LyxH83mkRgD1bBl/bs3Xw1Pz7yy3LrpGuzBFKfQKV3+3cW1SO6nrkPwHZ1w2h+2jlNgAAAABJRU5ErkJggg==';\n\t\tels.setAttribute('src',hs);\n\t\tels.ggNormalSrc=hs;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_image';\n\t\tels['ondragstart']=function() { return false; };\n\t\tplayer.checkLoaded.push(els);\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"map_pin_active\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_image \";\n\t\tel.ggType='image';\n\t\ths ='';\n\t\ths+='bottom : 0px;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 31px;';\n\t\ths+='left : -10000px;';\n\t\ths+='opacity : 0;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : hidden;';\n\t\ths+='width : 18px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 100%';\n\t\tme._map_pin_active.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tme._map_pin_active.logicBlock_scaling = function() {\n\t\t\tvar newLogicStateScaling;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['map_pin_active'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateScaling = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateScaling = -1;\n\t\t\t}\n\t\t\tif (me._map_pin_active.ggCurrentLogicStateScaling != newLogicStateScaling) {\n\t\t\t\tme._map_pin_active.ggCurrentLogicStateScaling = newLogicStateScaling;\n\t\t\t\tme._map_pin_active.style[domTransition]='' + cssPrefix + 'transform 200ms ease 0ms, opacity 500ms ease 0ms';\n\t\t\t\tif (me._map_pin_active.ggCurrentLogicStateScaling == 0) {\n\t\t\t\t\tme._map_pin_active.ggParameter.sx = 1.1;\n\t\t\t\t\tme._map_pin_active.ggParameter.sy = 1.1;\n\t\t\t\t\tme._map_pin_active.style[domTransform]=parameterToTransform(me._map_pin_active.ggParameter);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._map_pin_active.ggParameter.sx = 1;\n\t\t\t\t\tme._map_pin_active.ggParameter.sy = 1;\n\t\t\t\t\tme._map_pin_active.style[domTransform]=parameterToTransform(me._map_pin_active.ggParameter);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map_pin_active.logicBlock_alpha = function() {\n\t\t\tvar newLogicStateAlpha;\n\t\t\tif (\n\t\t\t\t((me._map_pin_active.ggIsActive() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateAlpha = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateAlpha = -1;\n\t\t\t}\n\t\t\tif (me._map_pin_active.ggCurrentLogicStateAlpha != newLogicStateAlpha) {\n\t\t\t\tme._map_pin_active.ggCurrentLogicStateAlpha = newLogicStateAlpha;\n\t\t\t\tme._map_pin_active.style[domTransition]='' + cssPrefix + 'transform 200ms ease 0ms, opacity 500ms ease 0ms';\n\t\t\t\tif (me._map_pin_active.ggCurrentLogicStateAlpha == 0) {\n\t\t\t\t\tme._map_pin_active.style.visibility=me._map_pin_active.ggVisible?'inherit':'hidden';\n\t\t\t\t\tme._map_pin_active.style.opacity=1;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tsetTimeout(function() { if (me._map_pin_active.style.opacity == 0.0) { me._map_pin_active.style.visibility=\"hidden\"; } }, 505);\n\t\t\t\t\tme._map_pin_active.style.opacity=0;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._map_pin_active.onmouseover=function (e) {\n\t\t\tme.elementMouseOver['map_pin_active']=true;\n\t\t\tme._map_pin_active.logicBlock_scaling();\n\t\t}\n\t\tme._map_pin_active.onmouseout=function (e) {\n\t\t\tme.elementMouseOver['map_pin_active']=false;\n\t\t\tme._map_pin_active.logicBlock_scaling();\n\t\t}\n\t\tme._map_pin_active.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['map_pin_active']=false;\n\t\t\tme._map_pin_active.logicBlock_scaling();\n\t\t}\n\t\tme._map_pin_active.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._map_pin.appendChild(me._map_pin_active);\n\t};\n\tfunction SkinCloner_category_cloner_Class(item, parentScope,ggParent,parameter) {\n\t\tvar me=this;\n\t\tvar hs='';\n\t\tme.parentScope=parentScope;\n\t\tme.ggParent=ggParent;\n\t\tme.findElements=skin.findElements;\n\t\tme.ggIndex=parameter.index;\n\t\tme.ggTag = item['tag'];\n\t\tme.ggTitle = item['title'];\n\t\tme.ggNodeCount = item['nodecount'];\n\t\tme.ggNodeId=item['firstnode'];\n\t\tme.ggUserdata=skin.player.getNodeUserdata(me.ggNodeId);\n\t\tme.elementMouseDown={};\n\t\tme.elementMouseOver={};\n\t\tme.__div=document.createElement('div');\n\t\tme.__div.setAttribute('style','position: absolute;width: 150px; height: 128px; visibility: inherit; overflow: visible;');\n\t\tme.__div.style.left=parameter.left;\n\t\tme.__div.style.top=parameter.top;\n\t\tme.__div.style.width=parameter.width;\n\t\tme.__div.style.height=parameter.height;\n\t\tme.__div.ggIsActive = function() {\n\t\t\tvar tags = player.userdata.tags;\n\t\t\tif (tags.indexOf(me.ggTag) == -1) return false;\n\t\t\tfor(var i=0;i<me.ggParent.ggCurrentFilter.length;i++) {\n\t\t\t\tif (tags.indexOf(me.ggParent.ggCurrentFilter[i])==-1) return false;\n\t\t\t}\n\t\t\treturn true;\n\t\t}\n\t\tme.__div.ggElementNodeId=function() {\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tel=me._node_cloner=document.createElement('div');\n\t\tel.ggNumRepeat = 1;\n\t\tel.ggNumRows = 0;\n\t\tel.ggNumCols = 0;\n\t\tel.ggWidth = 141;\n\t\tel.ggHeight = 100;\n\t\tel.ggUpdating = false;\n\t\tel.ggFilter = [];\n\t\tel.ggInstances = [];\n\t\tme._node_cloner.callChildLogicBlocks_changenode = function(){\n\t\t\tif(me._node_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._node_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._node_cloner.ggInstances[i]._node_title && me._node_cloner.ggInstances[i]._node_title.logicBlock_visible) {\n\t\t\t\t\t\tme._node_cloner.ggInstances[i]._node_title.logicBlock_visible();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._node_cloner.callChildLogicBlocks_mouseover = function(){\n\t\t\tif(me._node_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._node_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._node_cloner.ggInstances[i]._node_visited && me._node_cloner.ggInstances[i]._node_visited.logicBlock_bordercolor) {\n\t\t\t\t\t\tme._node_cloner.ggInstances[i]._node_visited.logicBlock_bordercolor();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._node_cloner.callChildLogicBlocks_active = function(){\n\t\t\tif(me._node_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._node_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._node_cloner.ggInstances[i]._node_visited && me._node_cloner.ggInstances[i]._node_visited.logicBlock_bordercolor) {\n\t\t\t\t\t\tme._node_cloner.ggInstances[i]._node_visited.logicBlock_bordercolor();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._node_cloner.callChildLogicBlocks_changevisitednodes = function(){\n\t\t\tif(me._node_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._node_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._node_cloner.ggInstances[i]._node_visited && me._node_cloner.ggInstances[i]._node_visited.logicBlock_bordercolor) {\n\t\t\t\t\t\tme._node_cloner.ggInstances[i]._node_visited.logicBlock_bordercolor();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._node_cloner.callChildLogicBlocks_activehotspotchanged = function(){\n\t\t\tif(me._node_cloner.ggInstances) {\n\t\t\t\tvar i;\n\t\t\t\tfor(i = 0; i < me._node_cloner.ggInstances.length; i++) {\n\t\t\t\t\tif (me._node_cloner.ggInstances[i]._node_title && me._node_cloner.ggInstances[i]._node_title.logicBlock_visible) {\n\t\t\t\t\t\tme._node_cloner.ggInstances[i]._node_title.logicBlock_visible();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tel.ggUpdate = function(filter) {\n\t\t\tif(me._node_cloner.ggUpdating == true) return;\n\t\t\tme._node_cloner.ggUpdating = true;\n\t\t\tvar el=me._node_cloner;\n\t\t\tvar curNumCols = 0;\n\t\t\tcurNumCols = me._node_cloner.ggNumRepeat;\n\t\t\tif (curNumCols < 1) curNumCols = 1;\n\t\t\tif (typeof filter=='object') {\n\t\t\t\tel.ggFilter = filter;\n\t\t\t} else {\n\t\t\t\tfilter = el.ggFilter;\n\t\t\t};\n\t\t\tfilter=filter.sort();\n\t\t\tif ((el.ggNumCols == curNumCols) && (el.ggInstances.length > 0) && (filter.length === el.ggCurrentFilter.length) && (filter.every(function(value, index) { return value === el.ggCurrentFilter[index] }) )) {\n\t\t\t\tme._node_cloner.ggUpdating = false;\n\t\t\t\treturn;\n\t\t\t} else {\n\t\t\t\tel.ggNumRows = 1;\n\t\t\t\tel.ggNumCols = curNumCols;\n\t\t\t}\n\t\t\tel.ggCurrentFilter = filter;\n\t\t\tel.ggInstances = [];\n\t\t\tif (el.hasChildNodes() == true) {\n\t\t\t\twhile (el.firstChild) {\n\t\t\t\t\tel.removeChild(el.firstChild);\n\t\t\t\t}\n\t\t\t}\n\t\t\tvar tourNodes = player.getNodeIds();\n\t\t\tvar row = 0;\n\t\t\tvar column = 0;\n\t\t\tvar currentIndex = 0;\n\t\t\tfor (var i=0; i < tourNodes.length; i++) {\n\t\t\t\tvar nodeId = tourNodes[i];\n\t\t\t\tvar passed = true;\n\t\t\t\tvar nodeData = player.getNodeUserdata(nodeId);\n\t\t\t\tif (filter.length > 0) {\n\t\t\t\t\tfor (var j=0; j < filter.length; j++) {\n\t\t\t\t\t\tif (nodeData['tags'].indexOf(filter[j]) == -1) passed = false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (passed) {\n\t\t\t\tvar parameter={};\n\t\t\t\tparameter.top=(row * me._node_cloner.ggHeight) + 'px';\n\t\t\t\tparameter.left=(column * me._node_cloner.ggWidth) + 'px';\n\t\t\t\tparameter.width=me._node_cloner.ggWidth + 'px';\n\t\t\t\tparameter.height=me._node_cloner.ggHeight + 'px';\n\t\t\t\tparameter.index=currentIndex;\n\t\t\t\tparameter.title=nodeData['title'];\n\t\t\t\tvar inst = new SkinCloner_node_cloner_Class(nodeId, me, el, parameter);\n\t\t\t\tcurrentIndex++;\n\t\t\t\tel.ggInstances.push(inst);\n\t\t\t\tel.appendChild(inst.__div);\n\t\t\t\tinst.__div.ggObj=inst;\n\t\t\t\tskin.updateSize(inst.__div);\n\t\t\t\tcolumn++;\n\t\t\t\tif (column >= el.ggNumCols) {\n\t\t\t\t\tcolumn = 0;\n\t\t\t\t\trow++;\n\t\t\t\t\tel.ggNumRows++;\n\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tme._node_cloner.callChildLogicBlocks_changenode();\n\t\t\tme._node_cloner.callChildLogicBlocks_mouseover();\n\t\t\tme._node_cloner.callChildLogicBlocks_active();\n\t\t\tme._node_cloner.callChildLogicBlocks_changevisitednodes();\n\t\t\tme._node_cloner.callChildLogicBlocks_activehotspotchanged();\n\t\t\tme._node_cloner.ggUpdating = false;\n\t\t\tplayer.triggerEvent('clonerchanged');\n\t\t\tif (me._node_cloner.parentNode.classList.contains('ggskin_subelement') && me._node_cloner.parentNode.parentNode.classList.contains('ggskin_scrollarea')) me._node_cloner.parentNode.parentNode.ggUpdatePosition();\n\t\t}\n\t\tel.ggFilter = [];\n\t\tel.ggFilter[0] = \"_nop_\";\n\t\tel.ggId=\"node_cloner\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_cloner \";\n\t\tel.ggType='cloner';\n\t\ths ='';\n\t\ths+='height : 100px;';\n\t\ths+='left : -10000px;';\n\t\ths+='overflow : visible;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 35px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 141px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._node_cloner.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._node_cloner.ggUpdateConditionNodeChange=function () {\n\t\t\tvar cnode=player.getCurrentNode();\n\t\t\tfor(var i=0; i<me._node_cloner.childNodes.length; i++) {\n\t\t\t\tvar child=me._node_cloner.childNodes[i];\n\t\t\t\tif (child.ggObj && child.ggObj.ggNodeId==cnode) {\n\t\t\t var childOffX = child.offsetLeft;\n\t\t\t var childOffY = child.offsetTop;\n\t\t\t\t\tvar p = child.parentElement;\n\t\t\t while (p != null && p!==this.divSkin) {\n\t\t\t\t\t\tif (p.ggType && p.ggType == 'scrollarea') {\n\t\t\t\t\t\t\tp.ggScrollIntoView(childOffX, childOffY, child.clientWidth, child.clientHeight);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tchildOffX += p.offsetLeft;\n\t\t\t\t\t\tchildOffY += p.offsetTop;\n\t\t\t\t\t\tp = p.parentElement;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._node_cloner.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.ggWidth;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t\t\tme._node_cloner.ggUpdate();\n\t\t}\n\t\tme._node_cloner.ggNodeChange=function () {\n\t\t\tme._node_cloner.ggUpdateConditionNodeChange();\n\t\t}\n\t\tme.__div.appendChild(me._node_cloner);\n\t\tel=me._category=document.createElement('div');\n\t\tels=me._category__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"category\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 27px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 4px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 141px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='left: 0px;';\n\t\ths+='top: 0px;';\n\t\ths+='width: 141px;';\n\t\ths+='height: auto;';\n\t\ths+='background: #a1a1a1;';\n\t\ths+='border: 0px solid #ffffff;';\n\t\ths+='color: rgba(0,0,0,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: pre-wrap;';\n\t\ths+='padding: 2px 1px 2px 1px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=me.ggTitle;\n\t\tel.appendChild(els);\n\t\tme._category.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._category.logicBlock_backgroundcolor = function() {\n\t\t\tvar newLogicStateBackgroundColor;\n\t\t\tif (\n\t\t\t\t((me.elementMouseOver['category'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateBackgroundColor = 0;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((player.getVariableValue('open_tag') == me.ggTag))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateBackgroundColor = 1;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateBackgroundColor = -1;\n\t\t\t}\n\t\t\tif (me._category.ggCurrentLogicStateBackgroundColor != newLogicStateBackgroundColor) {\n\t\t\t\tme._category.ggCurrentLogicStateBackgroundColor = newLogicStateBackgroundColor;\n\t\t\t\tme._category__text.style[domTransition]='background-color 0s';\n\t\t\t\tif (me._category.ggCurrentLogicStateBackgroundColor == 0) {\n\t\t\t\t\tme._category__text.style.backgroundColor=\"rgba(255,255,255,1)\";\n\t\t\t\t}\n\t\t\t\telse if (me._category.ggCurrentLogicStateBackgroundColor == 1) {\n\t\t\t\t\tme._category__text.style.backgroundColor=\"rgba(255,255,255,1)\";\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._category__text.style.backgroundColor=\"rgba(161,161,161,1)\";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._category.onclick=function (e) {\n\t\t\tif (\n\t\t\t\t(\n\t\t\t\t\t((player.getVariableValue('open_tag') == me.ggTag))\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tplayer.setVariableValue('close_nodes', true);\n\t\t\t}\n\t\t\tif (\n\t\t\t\t(\n\t\t\t\t\t((player.getVariableValue('open_tag') != me.ggTag))\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tplayer.setVariableValue('close_nodes', false);\n\t\t\t}\n\t\t\tif (\n\t\t\t\t(\n\t\t\t\t\t((player.getVariableValue('open_tag') != me.ggTag))\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tplayer.setVariableValue('open_tag', me.ggTag);\n\t\t\t}\n\t\t\tif (\n\t\t\t\t(\n\t\t\t\t\t((player.getVariableValue('close_nodes') == true))\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tplayer.setVariableValue('open_tag', \"_nop_\");\n\t\t\t}\n\t\t}\n\t\tme._category.onmouseover=function (e) {\n\t\t\tme.elementMouseOver['category']=true;\n\t\t\tme._category.logicBlock_backgroundcolor();\n\t\t}\n\t\tme._category.onmouseout=function (e) {\n\t\t\tif (e && e.toElement) {\n\t\t\t\tvar current = e.toElement;\n\t\t\t\twhile (current = current.parentNode) {\n\t\t\t\tif (current == me._category__text)\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t\tme.elementMouseOver['category']=false;\n\t\t\tme._category.logicBlock_backgroundcolor();\n\t\t}\n\t\tme._category.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['category']=false;\n\t\t\tme._category.logicBlock_backgroundcolor();\n\t\t}\n\t\tme._category.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._category.ggNodeChange=function () {\n\t\t\tif (\n\t\t\t\t(\n\t\t\t\t\t((me._category.ggIsActive() == true)) && \n\t\t\t\t\t((player.getVariableValue('category_follow') == true))\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tplayer.setVariableValue('open_tag', me.ggTag);\n\t\t\t}\n\t\t}\n\t\tme.__div.appendChild(me._category);\n\t\tme._node_cloner.style['display']='none';\n\t\tvar p = me._node_cloner.parentElement;\n\t\twhile (p != null && p!==this.divSkin) {\n\t\t\tif (p.ggType && p.ggType == 'cloner') {\n\t\t\t\tif (p.ggAutoPosition) {\n\t\t\t\t\tp.ggAutoPosition(false);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (p.ggType && p.ggType == 'scrollarea') {\n\t\t\t\tif (p.ggUpdatePosition) {\n\t\t\t\t\tp.ggUpdatePosition();\n\t\t\t\t}\n\t\t\t}\n\t\t\tp = p.parentElement;\n\t\t}\n\t\tskin.updateSize(me._node_cloner);\n\t\tme.event_varchanged_open_tag=function() {if (\n\t\t\t(\n\t\t\t\t((player.getVariableValue('open_tag') != me.ggTag))\n\t\t\t)\n\t\t) {\n\t\t\tme._node_cloner.ggText=\"_nop_\";\n\t\t\tif (me._node_cloner.ggText=='') {\n\t\t\t\tme._node_cloner.ggUpdate([]);\n\t\t\t} else {\n\t\t\t\tme._node_cloner.ggUpdate(me._node_cloner.ggText.split(','));\n\t\t\t}\n\t\t\tskin.updateSize(skin.divSkin);\n\t\t}\n\t\tif (\n\t\t\t(\n\t\t\t\t((player.getVariableValue('open_tag') != me.ggTag))\n\t\t\t)\n\t\t) {\n\t\t\tme._node_cloner.style['display']='none';\n\t\t\tvar p = me._node_cloner.parentElement;\n\t\t\twhile (p != null && p!==this.divSkin) {\n\t\t\t\tif (p.ggType && p.ggType == 'cloner') {\n\t\t\t\t\tif (p.ggAutoPosition) {\n\t\t\t\t\t\tp.ggAutoPosition(false);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (p.ggType && p.ggType == 'scrollarea') {\n\t\t\t\t\tif (p.ggUpdatePosition) {\n\t\t\t\t\t\tp.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tp = p.parentElement;\n\t\t\t}\n\t\t\tskin.updateSize(me._node_cloner);\n\t\t}\n\t\tif (\n\t\t\t(\n\t\t\t\t((player.getVariableValue('open_tag') == me.ggTag))\n\t\t\t)\n\t\t) {\n\t\t\tme._node_cloner.ggText=me.ggTag;\n\t\t\tif (me._node_cloner.ggText=='') {\n\t\t\t\tme._node_cloner.ggUpdate([]);\n\t\t\t} else {\n\t\t\t\tme._node_cloner.ggUpdate(me._node_cloner.ggText.split(','));\n\t\t\t}\n\t\t\tskin.updateSize(skin.divSkin);\n\t\t}\n\t\tif (\n\t\t\t(\n\t\t\t\t((player.getVariableValue('open_tag') == me.ggTag))\n\t\t\t)\n\t\t) {\n\t\t\tme._node_cloner.style['display']='inline';\n\t\t\tvar p = me._node_cloner.parentElement;\n\t\t\twhile (p != null && p!==this.divSkin) {\n\t\t\t\tif (p.ggType && p.ggType == 'cloner') {\n\t\t\t\t\tif (p.ggAutoPosition) {\n\t\t\t\t\t\tp.ggAutoPosition(false);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (p.ggType && p.ggType == 'scrollarea') {\n\t\t\t\t\tif (p.ggUpdatePosition) {\n\t\t\t\t\t\tp.ggUpdatePosition();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tp = p.parentElement;\n\t\t\t}\n\t\t\tskin.updateSize(me._node_cloner);\n\t\t}};\n\t};\n\tfunction SkinCloner_node_cloner_Class(nodeId, parentScope,ggParent,parameter) {\n\t\tvar me=this;\n\t\tvar hs='';\n\t\tme.parentScope=parentScope;\n\t\tme.ggParent=ggParent;\n\t\tme.findElements=skin.findElements;\n\t\tme.ggIndex=parameter.index;\n\t\tme.ggNodeId=nodeId;\n\t\tme.ggTitle=parameter.title;\n\t\tme.ggUserdata=skin.player.getNodeUserdata(me.ggNodeId);\n\t\tme.elementMouseDown={};\n\t\tme.elementMouseOver={};\n\t\tme.__div=document.createElement('div');\n\t\tme.__div.setAttribute('style','position: absolute;width: 141px; height: 100px; visibility: inherit; overflow: visible;');\n\t\tme.__div.style.left=parameter.left;\n\t\tme.__div.style.top=parameter.top;\n\t\tme.__div.style.width=parameter.width;\n\t\tme.__div.style.height=parameter.height;\n\t\tme.__div.ggIsActive = function() {\n\t\t\treturn player.getCurrentNode()==me.ggNodeId;\n\t\t}\n\t\tme.__div.ggElementNodeId=function() {\n\t\t\treturn me.ggNodeId;\n\t\t}\n\t\tel=me._node_image=document.createElement('div');\n\t\tels=me._node_image__img=document.createElement('img');\n\t\tels.className='ggskin ggskin_nodeimage';\n\t\tels.setAttribute('src',basePath + \"images/node_image_\" + nodeId + \".jpg\");\n\t\tel.ggNodeId=nodeId;\n\t\tels.setAttribute('style','position: absolute;top: 0px;left: 0px;width: 100%;height: 100%;-webkit-user-drag:none;pointer-events:none;;');\n\t\tels.className='ggskin ggskin_nodeimage';\n\t\tels['ondragstart']=function() { return false; };\n\t\tel.appendChild(els);\n\t\tel.ggSubElement = els;\n\t\tel.ggId=\"node_image\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_nodeimage \";\n\t\tel.ggType='nodeimage';\n\t\ths ='';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 90px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 141px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._node_image.ggIsActive=function() {\n\t\t\treturn player.getCurrentNode()==this.ggElementNodeId();\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\treturn this.ggNodeId;\n\t\t}\n\t\tme._node_image.onclick=function (e) {\n\t\t\tif (\n\t\t\t\t(\n\t\t\t\t\t((me._node_image.ggIsActive() == false))\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\tplayer.openNext(\"{\"+me.ggNodeId+\"}\",player.hotspot.target);\n\t\t\t}\n\t\t}\n\t\tme._node_image.onmouseover=function (e) {\n\t\t\tme.elementMouseOver['node_image']=true;\n\t\t\tme._node_visited.logicBlock_bordercolor();\n\t\t}\n\t\tme._node_image.onmouseout=function (e) {\n\t\t\tme.elementMouseOver['node_image']=false;\n\t\t\tme._node_visited.logicBlock_bordercolor();\n\t\t}\n\t\tme._node_image.ontouchend=function (e) {\n\t\t\tme.elementMouseOver['node_image']=false;\n\t\t\tme._node_visited.logicBlock_bordercolor();\n\t\t}\n\t\tme._node_image.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tel=me._node_title=document.createElement('div');\n\t\tels=me._node_title__text=document.createElement('div');\n\t\tel.className='ggskin ggskin_textdiv';\n\t\tel.ggTextDiv=els;\n\t\tel.ggId=\"node_title\";\n\t\tel.ggDx=0;\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_text \";\n\t\tel.ggType='text';\n\t\ths ='';\n\t\ths+='bottom : 0px;';\n\t\ths+='cursor : pointer;';\n\t\ths+='height : 20px;';\n\t\ths+='left : -10000px;';\n\t\ths+='position : absolute;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 136px;';\n\t\ths+='pointer-events:auto;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 100%';\n\t\ths ='position:absolute;';\n\t\ths += 'box-sizing: border-box;';\n\t\ths+='left: 0px;';\n\t\ths+='bottom: 0px;';\n\t\ths+='width: 136px;';\n\t\ths+='height: auto;';\n\t\ths+='background: #000000;';\n\t\ths+='background: rgba(0,0,0,0.392157);';\n\t\ths+='border: 0px solid #000000;';\n\t\ths+='color: rgba(255,255,255,1);';\n\t\ths+='text-align: center;';\n\t\ths+='white-space: pre-wrap;';\n\t\ths+='padding: 2px 1px 2px 1px;';\n\t\ths+='overflow: hidden;';\n\t\tels.setAttribute('style',hs);\n\t\tels.innerHTML=me.ggUserdata.title;\n\t\tel.appendChild(els);\n\t\tme._node_title.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._node_title.logicBlock_visible = function() {\n\t\t\tvar newLogicStateVisible;\n\t\t\tif (\n\t\t\t\t((me.ggUserdata.title == \"\"))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateVisible = 0;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateVisible = -1;\n\t\t\t}\n\t\t\tif (me._node_title.ggCurrentLogicStateVisible != newLogicStateVisible) {\n\t\t\t\tme._node_title.ggCurrentLogicStateVisible = newLogicStateVisible;\n\t\t\t\tme._node_title.style[domTransition]='';\n\t\t\t\tif (me._node_title.ggCurrentLogicStateVisible == 0) {\n\t\t\t\t\tme._node_title.style.visibility=\"hidden\";\n\t\t\t\t\tme._node_title.ggVisible=false;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._node_title.style.visibility=(Number(me._node_title.style.opacity)>0||!me._node_title.style.opacity)?'inherit':'hidden';\n\t\t\t\t\tme._node_title.ggVisible=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._node_title.ggUpdatePosition=function (useTransition) {\n\t\t\tif (useTransition==='undefined') {\n\t\t\t\tuseTransition = false;\n\t\t\t}\n\t\t\tif (!useTransition) {\n\t\t\t\tthis.style[domTransition]='none';\n\t\t\t}\n\t\t\tif (this.parentNode) {\n\t\t\t\tvar pw=this.parentNode.clientWidth;\n\t\t\t\tvar w=this.offsetWidth + 0;\n\t\t\t\t\tthis.style.left=(this.ggDx + pw/2 - w/2) + 'px';\n\t\t\t}\n\t\t}\n\t\tme._node_image.appendChild(me._node_title);\n\t\tel=me._node_visited=document.createElement('div');\n\t\tel.ggId=\"node_visited\";\n\t\tel.ggParameter={ rx:0,ry:0,a:0,sx:1,sy:1 };\n\t\tel.ggVisible=true;\n\t\tel.className=\"ggskin ggskin_rectangle \";\n\t\tel.ggType='rectangle';\n\t\ths ='';\n\t\ths+='border : 3px solid #a1a1a1;';\n\t\ths+='cursor : default;';\n\t\ths+='height : 87px;';\n\t\ths+='left : 0px;';\n\t\ths+='position : absolute;';\n\t\ths+='top : 0px;';\n\t\ths+='visibility : inherit;';\n\t\ths+='width : 135px;';\n\t\ths+='pointer-events:none;';\n\t\tel.setAttribute('style',hs);\n\t\tel.style[domTransform + 'Origin']='50% 50%';\n\t\tme._node_visited.ggIsActive=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggIsActive)) {\n\t\t\t\treturn this.parentNode.ggIsActive();\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\tel.ggElementNodeId=function() {\n\t\t\tif ((this.parentNode) && (this.parentNode.ggElementNodeId)) {\n\t\t\t\treturn this.parentNode.ggElementNodeId();\n\t\t\t}\n\t\t\treturn player.getCurrentNode();\n\t\t}\n\t\tme._node_visited.logicBlock_bordercolor = function() {\n\t\t\tvar newLogicStateBorderColor;\n\t\t\tif (\n\t\t\t\t((me._node_visited.ggIsActive() == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateBorderColor = 0;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((me.elementMouseOver['node_image'] == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateBorderColor = 1;\n\t\t\t}\n\t\t\telse if (\n\t\t\t\t((player.nodeVisited(me._node_visited.ggElementNodeId()) == true))\n\t\t\t)\n\t\t\t{\n\t\t\t\tnewLogicStateBorderColor = 2;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tnewLogicStateBorderColor = -1;\n\t\t\t}\n\t\t\tif (me._node_visited.ggCurrentLogicStateBorderColor != newLogicStateBorderColor) {\n\t\t\t\tme._node_visited.ggCurrentLogicStateBorderColor = newLogicStateBorderColor;\n\t\t\t\tme._node_visited.style[domTransition]='border-color 0s';\n\t\t\t\tif (me._node_visited.ggCurrentLogicStateBorderColor == 0) {\n\t\t\t\t\tme._node_visited.style.borderColor=\"rgba(255,255,255,1)\";\n\t\t\t\t}\n\t\t\t\telse if (me._node_visited.ggCurrentLogicStateBorderColor == 1) {\n\t\t\t\t\tme._node_visited.style.borderColor=\"rgba(255,255,255,1)\";\n\t\t\t\t}\n\t\t\t\telse if (me._node_visited.ggCurrentLogicStateBorderColor == 2) {\n\t\t\t\t\tme._node_visited.style.borderColor=\"rgba(209,209,209,1)\";\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tme._node_visited.style.borderColor=\"rgba(161,161,161,1)\";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tme._node_visited.ggUpdatePosition=function (useTransition) {\n\t\t}\n\t\tme._node_image.appendChild(me._node_visited);\n\t\tme.__div.appendChild(me._node_image);\n\t};\n\tplayer.addListener('varchanged_open_tag', function() {\n\t\tvar inst_j=skin;\n\t\tfor(var i = 0; i < inst_j._category_cloner.ggInstances.length; i++) {\n\t\t\tvar inst_i=inst_j._category_cloner.ggInstances[i];\n\t\t\tinst_i.event_varchanged_open_tag();\n\t\t}\n\t});\n\tme.addSkin();\n\tvar style = document.createElement('style');\n\tstyle.type = 'text/css';\n\tstyle.appendChild(document.createTextNode('.ggskin { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 14px;}'));\n\tdocument.head.appendChild(style);\n\tme._menu_background.logicBlock_alpha();\n\tme._menu_open.logicBlock_position();\n\tme._menu_open.logicBlock_alpha();\n\tme._tt_togglemap.logicBlock_text();\n\tme._button_close_map.logicBlock_visible();\n\tme._map_container.logicBlock_visible();\n\tme._map.logicBlock_visible();\n\tme._tt_togglemap.logicBlock_position();\n\tplayer.addListener('changenode', function(args) { me._menu_background.logicBlock_alpha();me._menu_open.logicBlock_position();me._menu_open.logicBlock_alpha();me._tt_togglemap.logicBlock_text();me._button_close_map.logicBlock_visible();me._map_container.logicBlock_visible();me._map.logicBlock_visible(); });\n\tplayer.addListener('configloaded', function(args) { me._tt_togglemap.logicBlock_position(); });\n\tplayer.addListener('hastouch', function(args) { me._tt_togglemap.logicBlock_position(); });\n\tplayer.addListener('varchanged_category_visible', function(args) { me._menu_background.logicBlock_alpha();me._menu_open.logicBlock_position();me._menu_open.logicBlock_alpha(); });\n\tplayer.addListener('varchanged_vis_map', function(args) { me._tt_togglemap.logicBlock_text();me._button_close_map.logicBlock_visible();me._map_container.logicBlock_visible();me._map.logicBlock_visible(); });\n\tplayer.addListener('changenode', function(args) { me._category_cloner.callChildLogicBlocks_changenode(); });\n\tplayer.addListener('mouseover', function(args) { me._category_cloner.callChildLogicBlocks_mouseover(); });\n\tplayer.addListener('mouseover', function(args) { me._category_cloner.callChildLogicBlocks_mouseover(); });\n\tplayer.addListener('changenode', function(args) { me._category_cloner.callChildLogicBlocks_active(); });\n\tplayer.addListener('changevisitednodes', function(args) { me._category_cloner.callChildLogicBlocks_changevisitednodes(); });\n\tplayer.addListener('activehotspotchanged', function(args) { me._category_cloner.callChildLogicBlocks_activehotspotchanged(); });\n\tplayer.addListener('varchanged_open_tag', function(args) { me._category_cloner.callChildLogicBlocks_varchanged_open_tag(); });\n\tplayer.addListener('changenode', function(args) { me._map.callChildLogicBlocksHotspot_map_pin_changenode(); });\n\tplayer.addListener('configloaded', function(args) { me._map.callChildLogicBlocksHotspot_map_pin_configloaded(); });\n\tplayer.addListener('mouseover', function(args) { me._map.callChildLogicBlocksHotspot_map_pin_mouseover(); });\n\tplayer.addListener('mouseover', function(args) { me._map.callChildLogicBlocksHotspot_map_pin_mouseover(); });\n\tplayer.addListener('changenode', function(args) { me._map.callChildLogicBlocksHotspot_map_pin_active(); });\n\tplayer.addListener('hastouch', function(args) { me._map.callChildLogicBlocksHotspot_map_pin_hastouch(); });\n\tplayer.addListener('activehotspotchanged', function(args) { me._map.callChildLogicBlocksHotspot_map_pin_activehotspotchanged(); });\n\tplayer.addListener('sizechanged', function(args) { me.callChildLogicBlocksHotspot_ht_node_sizechanged();me.callChildLogicBlocksHotspot_door_sizechanged(); });\n\tplayer.addListener('changenode', function(args) { me.callChildLogicBlocksHotspot_ht_node_changenode();me.callChildLogicBlocksHotspot_door_changenode(); });\n\tplayer.addListener('configloaded', function(args) { me.callChildLogicBlocksHotspot_ht_node_configloaded();me.callChildLogicBlocksHotspot_door_configloaded(); });\n\tplayer.addListener('mouseover', function(args) { me.callChildLogicBlocksHotspot_ht_node_mouseover();me.callChildLogicBlocksHotspot_door_mouseover(); });\n\tplayer.addListener('changenode', function(args) { me.callChildLogicBlocksHotspot_ht_node_active();me.callChildLogicBlocksHotspot_door_active(); });\n\tplayer.addListener('changevisitednodes', function(args) { me.callChildLogicBlocksHotspot_ht_node_changevisitednodes();me.callChildLogicBlocksHotspot_door_changevisitednodes(); });\n\tplayer.addListener('hastouch', function(args) { me.callChildLogicBlocksHotspot_ht_node_hastouch();me.callChildLogicBlocksHotspot_door_hastouch(); });\n\tplayer.addListener('activehotspotchanged', function(args) { me.callChildLogicBlocksHotspot_ht_node_activehotspotchanged();me.callChildLogicBlocksHotspot_door_activehotspotchanged(); });\n\tplayer.addListener('varchanged_opt_hotspot_preview', function(args) { me.callChildLogicBlocksHotspot_ht_node_varchanged_opt_hotspot_preview(); });\n\tplayer.addListener('varchanged_opt_hotspot_preview_1', function(args) { me.callChildLogicBlocksHotspot_door_varchanged_opt_hotspot_preview_1(); });\n\tplayer.addListener('hotspotsremoved', function(args) { me.removeSkinHotspots(); });\n\tme.skinTimerEvent();\n}", "function initThemeNavigation() {\n\n //initialise the wp thumbs event to assign theme and display selected background and sprites\n $(\"#theme-menu .nav, .custom-menu .nav\").on(\"mousedown touchstart\", function(event) {\n event.stopPropagation();\n event.preventDefault();\n \n $(\"#col1, #col2\").addClass(\"loading\");\n\n currentTheme = $(this).attr(\"alt\");\n currentItem = currentTheme;\n\n imgLayer.getChildren().hide();\n imgLayer.draw();\n\n //show the theme as text on the image\n var posX = $(\"#container\").width() / 2;\n var posY = 100;\n var size = 100;\n var message = currentTheme;\n drawText(posX, posY, size, message);\n\n $(\"#container, #col1, #col2, #back\").show();\n $(\"#showTextMsg\").hide();\n $(\"#theme-menu, #home, #act-home\").hide();\n\n //if this is the first time selected, create the item backgrounds\n if ($(\"#image-div\").children(\".\" + currentTheme).length === 0) {\n createItemBackgrounds();\n }\n\n //for custom show page with the sets and navigation to each set\n if (currentTheme === \"custom\") {\n showCustomPage();\n $(\"#act-home\").show();\n } else {\n //show background and item images \n $(\"#\" + currentTheme + \"_bg\").show();\n displayThemeSpriteImages();\n }\n });\n}", "function preload() {\r\n theme = loadSound('music/Forget.mp3')\r\n font = loadFont('music/vanilla-extract.regular.ttf')\r\n crasyPer = loadImage('music/crazy-faceejfnaiugjkarngow2.png')\r\n crasyPer2 = loadImage('music/crazy-facefejrgniuagoiw3.png')\r\n crasyPer3 = loadImage('music/crazy-facegjnsurgaegsuiehg4.png')\r\n crasyPer4 = loadImage('music/crazy-facejnsfjhw1.png')\r\n perPer1 = loadImage('music/crybabe.png')\r\n perPer4 = loadImage('music/iogueig.png')\r\n perPer2 = loadImage('music/sifjoefu.png')\r\n perPer3 = loadImage('music/softbayru.png')\r\n perPer5 = loadImage('music/krjgoeg.png')\r\n perPer6 = loadImage('music/oerguhg.png')\r\n perPer7 = loadImage('music/oiewjgiugb.png')\r\n dreamPer3 = loadImage('music/iurjgu.png')\r\n dreamPer1 = loadImage('music/pojihg.png')\r\n dreamPer2 = loadImage('music/rugjo.png')\r\n}" ]
[ "0.6463573", "0.6402625", "0.6202073", "0.61521894", "0.6147096", "0.61431485", "0.609275", "0.60239124", "0.5984506", "0.5949651", "0.59165335", "0.5888293", "0.5884749", "0.5867574", "0.58556545", "0.5855622", "0.5847735", "0.5842615", "0.58410823", "0.5840166", "0.5832086", "0.5831529", "0.5830075", "0.58246744", "0.58114105", "0.580546", "0.5793653", "0.5791933", "0.5782064", "0.57816005", "0.5781471", "0.5778943", "0.5770385", "0.57558906", "0.57548875", "0.57541627", "0.5753357", "0.5750842", "0.5732259", "0.5731342", "0.5724606", "0.57219934", "0.5718016", "0.57170916", "0.5704575", "0.5693276", "0.5693276", "0.5692539", "0.56912166", "0.5679852", "0.56792635", "0.56719255", "0.5661986", "0.5651085", "0.5648429", "0.56439126", "0.5640461", "0.5636252", "0.56346136", "0.5623457", "0.5617929", "0.5616267", "0.5615657", "0.5613811", "0.5610797", "0.5606686", "0.5602296", "0.5597102", "0.558667", "0.5583614", "0.5583158", "0.558115", "0.55729204", "0.55711174", "0.55673766", "0.5567121", "0.555701", "0.55556226", "0.5543482", "0.5541857", "0.5536274", "0.5528684", "0.552624", "0.5524817", "0.55244654", "0.55242896", "0.55241394", "0.55217004", "0.55183923", "0.5513303", "0.5511193", "0.5502411", "0.5500243", "0.5495924", "0.5489146", "0.5486876", "0.54792166", "0.5477383", "0.54766726", "0.5474859" ]
0.63592213
2
name ="Salman"; // assigning a value alert(name); var message = "Wlecome "; var name = "Salman"; alert(message + name);// concatinate the two variable
function imgEvent(){ alert('This is Void Link'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function greet(message){\n let name=\"Harendra\"\n alert(message + \" \" + name)\n alert(`${message} ${name}`)\n console.log(`2+2= ${2+2} \"Hello\" , 'Hello'`)\n}", "function\talertName()\t{\n\talert('Hello ' + name); \t\n}", "function showMessage_v2() {\n userName = \"Poster\"\n let alertMess= \"Hello, world \" + userName; // Hello, world Póter\n console.log(alertMess); // Hello, world Póter\n}", "function welcomeNewUser () {//--------------------------------------check it out\n let firstName = 'Merhawit';\n let lastName = 'Gubsa';\n let message = ' Hey there, ';\n let fullMessage = message + firstName + ' '+ lastName;\n\n // Alert to render the concat name with welcome\n alert (fullMessage);\n\n }", "function greet(){\r\n var firstname = prompt(\"Enter first name\")\r\n var lastname = prompt(\"Enter last name\")\r\n var fullname = firstname + \" \" + lastname\r\n alert(\"Good Morning\"+ \" \" + fullname)\r\n}", "function showMessage() {\n let username = \"john\";\n alert(\"hello\" + username);\n}", "function JavaScriptAlert6() {\r\n\r\n Username = 'azam_mustafa';\r\n myname = 'Muhammad Azam Mustafa';\r\n age = '17 year old';\r\n qualification = 'Java Script Developer';\r\n\r\n\r\n alert(Username);\r\n alert(myname);\r\n alert(age);\r\n alert(qualification);\r\n}", "function showMessage(firstname, lastname) {\n alert(\"Hello\" + ' ' + firstname + lastname);\n}", "function name (nameInput) {\n alert('The name you entered is: ' + nameInput);\n}", "function greeting(yourName) {\n var result = 'Hello'+' '+ yourName; // String Concatenation\n console.log(result);\n}", "function custom(){\n\tvar name = prompt(\"Enter your Name : \");\n\talert(\"Hope you are liking JavaScript \"+name+\" !\");\n}", "function greeting() {\r\n var name = prompt(\"What is your name?\");\r\n var result = \"Hello\" + ' ' + name; // String concatenation\r\n console.log(result);\r\n}", "function showName(name1,name2)\r\n{\r\n return name1 + \" \" + name2;\r\n}", "function aName(nameOne) {\n\treturn alert(nameOne)\n}", "function Name(first, second)//parameters\n {\n alert(first + \" \" + \"is a son of \" + second);\n }", "function greeting() {\r\n // var name = prompt('What is your name?');\r\n // var result = 'Hello ' + name;\r\n var result = 'Hello' + ' ' + name; // String Concatenation\r\n console.log(result);\r\n}", "function sayName() {\n var firstName = \"Scott\";\n var lastName = \"Hurt\";\n console.log (\"My name is \"+ firstName + \" \" + lastName);\n\n}", "function promptName()\n{\n \tvar sName = prompt(\"Enter your name.\\nThis prompt should show up when \" +\n \"the \\nClick Me button is clicked.\", \"Your name\");\n\n\talert(\"Hi there \" + sName + \". Alert boxes are a quick way to check the \\nstate of your variables when you are developing code.\");\n\n\toutputMessage = document.getElementById(\"mymessage\");\n\toutputMessage.textContent=\"Your output: \" + sName;\n}", "function alertName(yourName){\n return alert(yourName);\n}", "function myname() {\n var fname = 'Dev';\n var lname = 'D';\n\n console.log(fname + lname)\n}", "function return_name(){\n var name = prompt('what is your name :');\n document.write('hello'+\" \" +name);\n}", "function JavaScriptAlert17() {\r\n var [name, age, bloodgroup] =\r\n [\"Azam Mustafa\", \"17\", \"O+\"];\r\n\r\n b = \"My name is \" + name + \". & My Age \" + age + \" Year Old\" + \". & My blood Group is \" + bloodgroup;\r\n document.getElementById(\"sal1\").innerHTML = b;\r\n}", "function greeting(yourName) {\n var result = 'Hello ' + name; // String Concatenation\n console.log(result);\n}", "function greeting(yourName) {\r\n var result = 'Hello' + ' ' + yourName; // string Concatenation\r\n console.log(result);\r\n}", "function nameAge (word1,word2){\n let details = 'stef' + '31'\n console.log(details)\n}", "function name() {\n var x = prompt(\"Please enter a name\")\n alert(\"You have entered: \" + x);\n}", "function pies1(){\n\n var apple = 50;//apple pies on hand\n var cherry = 32;//cherry pies on hand\n var blueberry = 12;//blueberry pies on hand\n var peach = 12;//peach pies on hand\n\n var piesOnhand = apple + cherry + blueberry + peach;\n\n alert(\"You have \" + piesOnhand + \" pies on hand.\");\n\n }", "function myName() {\n var firstname = \"Fernando\";\n secondName = \"Gomez\";\n console.log(firstname + ' ' + secondName);\n}", "function playerOne() {\n var name = prompt(\"What is your name\");\n alert ('Welcome ' + name + '.' + ' You go first!' );\n}", "function greeting(yourName) {\n var result = 'Hello' + ' ' + yourName; // String Concatenation\n console.log(result);\n}", "function JavaScriptAlert13() {\r\n var txt;\r\n var age = \"21\";\r\n var a = (\"I am \" + 17 + \" year old\");\r\n alert(a);\r\n}", "function naming(firstName) {\n var fullName = firstName + ' Lost';// Creating a space is a cushion between the name\n console.log(fullName);\n}", "function greeting(yourName) {\n var result = 'Hello'+ ' ' + yourName + ' ' + ', Hope you having a good day.'; //String Concatenation\n console.log(result);\n}", "function hello(name){\n alert(\"Hey \"+name+\"! how are you?\");\n }", "function showName() {\n var name;\n name = \"Ford\";\n console.log(\"Last Name: \" + name);\n}", "function hello(firstName, lastName) {\nlet myName = firstName + ' ' + lastName;\nconsole.log(myName);\n}", "function myName(){\n var Sophia = \"Hi, my name is Sophia Sangervasi\";\n console.log(Sophia);\n }", "function askName(){\nvar UserName = prompt('Hi there! What\\'s your name?');{\n alert('It\\'s to meet you, ' + UserName + ' I hope we can be friends! But first, I must ask ye these questions many to see if I can call you buddy.');\n}\n}", "function fortune_teller()\n{\n\tn = 4;\n\tname = \"Stewie\" ; \n\tplace = \"Hawaii\";\n\tjob = \"secretary\" ; \n\talert(\"You will be a \" + job + \" in \" + place + \" , and married to \" + name + \" with \"+ n+ \" kids.\");\n}", "function return_value(name){\n document.write(\"hello\"+\" \"+name);\n}", "function showName(name) {\r\n name= prompt(\"Enter you name\");\r\n return \"Hello, \" +name\r\n}", "function formal(name=\"Leah\", title='Miss') {\r\n return title+\" \"+name //this save the variable so you can assign it later\r\n}", "function get_name(){\r\n name = prompt(\"Hello! Please enter your name.\"); // added new prompt for users to add their name.\r\n alert(name + \", welcome to Battleship game.\"); // added new alert greeting.\r\n return name;\r\n}", "function sayName(){\n var name = \"Mr X\";\n console.name(name);\n}", "function helloPopUp(){\n alert('Hello' + person);\n}", "function combineName(firstName, lastName){\r\n var fullName = firstName + \" \" + lastName;\r\n document.getElementById(\"fullName\").innerHTML = fullName;\r\n }", "function salute2(myName){\n\treturn \"Hola \" + myName;\n}", "function fullName() {\n \"use strict\";\n var firstName, lastName;\n firstName = window.prompt(\"Hang on - what's your given name?\");\n lastName = window.prompt(\"And your family name?\");\n window.alert(\"So your full name is \" + firstName.concat(lastName) + \"? Interesting.\");\n}", "function hello(fname) {\n\tlname = \"kjhwef\";\n\tconsole.log(fname + lname);\n}", "function greet(Name){\n var Name= \"Name!\"\n}", "function name(name){\n return \"hi, my name is \" + name + \".\";\n}", "function fullName(fName,lName) {\n let myFullName = fName + ' ' + lName\n //let myFullName = `${fName} ${myFullName}`;\n\n console.log(`Hello my name is ${myFullName}`);\n\n}", "function userName(firstName,lastName) {\n var result= firstName + \" \" + lastName;\n return result;\n}", "function promt() {\n let name = prompt(\"what is ur name\");\n let lengthName = name.lengthName\n let nameadd = name.slice(1, lengthName);\n let nameSlice = name.slice(0,1);\n let nameToUpper = nameSlice.toUpperCase();\n alert(\"hello\" + \" \" + nameToUpper + nameadd)\n}", "function storeMyName(){\n\tvar newName = \"Sidney\";\n\tvar newHobby = \"Scoring goals\";\n\tvar newMessage = newName +\" likes \" + newHobby;\n\t\n\t// The return gives back the work that your function is doing... You can see it in the console.\n\treturn newMessage;\n}", "function makeFullName () {\n\t\tvar private = nameIntro;\n alert(nameIntro + firstName + \" \" + lastName);\n\t}", "function react() {\r\n var name = prompt(\"please enter your name\");\r\n var result = \"hello\" + name;\r\n console.log(result);\r\n}", "function yourName(){\n\tdocument.write(\"<hr>\");\n\tdocument.write(\"Declaration and initilization at the same time or line.\");\n\tdocument.write(\"<br>\");\n\tvar yourname=\"Ravi\"; //It is good practice.\n\tdocument.write(yourname);\n}", "function myName() {\n var person = prompt(\"Please enter your name\");\n if (person !== \"\" && person !== null) {\n document.getElementById(\"person\").innerHTML = 'Yes <span class=\"name\">' + person + '</span>, you are with me !';\n } else {\n alert('Hummm! you need to put your name !');\n }\n}", "function greeting(){\r\n var name=prompt(\"what is your name\");\r\n var res=\"hello \"+name;\r\n console.log(res) \r\n}", "function myName(firstName, lastName) {\n\n document.write(\"<br/>\" + \" Hello \" + firstName +\" \" + lastName);\n \n}", "function helloPopup() {\n alert(\"hej\" + person);\n\n}", "function greetMe(yourName) {\n alert('Hello ' + yourName);\n }", "function sample(){\n var x=\"hello\";\n var y=\"Nitish\";\n return x+\" \"+y;\n}", "function playerTwo() {\n var name = prompt(\"What is your name\");\n alert ('Welcome ' + name + '.' + ' Player One goes first.' );\n}", "function popup2() {\nalert(\"Sukhdeep Singh is a young Bio-Informatician with Masters in Bio-Informatics from University of Leicester,UK. His main interests are developing web-interfaces and data handling for almost all kinds of experiments that are being conducted on daily basis all around the globe. Contact : [email protected]\")\n}", "function sayHello3(name, age){\n // `(백틱)으로 String을 입력하고 필요한 변수를 ${변수명}을 통해 넣어준다.\n console.log(`Hello ${name} you are ${age} years old.`);\n}", "function displayName(fname,mname=\"\",lname)\n {\n $('#current_employee_name').text(fname+\" \"+mname+\" \"+lname);\n }", "function myName2(name){\n\treturn \"Hello \" + name + \". \";\n}", "function display(){\n console.log(\"1\", name)\n\n //name = \"othername\" // delcaring a variable in addres in the memory \n //var info =\"newname\"\n\n // console.log(\"2\", info)\n console.log(\"3\", name)\n \n}", "function pegarNomeContato() {\n var valor = \"\";\n\n valor = document.getElementById('nome').value;\n alert (`${valor}`+' sua mensagem foi enviada com sucesso')\n}", "function greeting(yourName) {\r\n var result = 'Hello' + ' ' + yourName;\r\n console.log(result);\r\n}", "function changeValue(name) {\n name = \"Thang\";\n // var name = \"TEST\";\n console.log(\"name: \", name);\n // var number = 1;\n}", "function sayYourName(name) {\n\tconsole.log('May name is ' + name)\n}", "function tellName(name) {\n console.log('You have entered: ' + name);\n}", "function greeting(firstname,lastname) \r\n{\r\n\r\n document.write(firstname+ \" \" +lastname)\r\n}", "function introduce(name, age, address, hobby) {\n return '\"Nama saya ' + name + \", umur saya \" + age + \" tahun, alamat saya di \" + address + \", dan saya punya hobby yaitu \" + hobby + '!\"';\n}", "function showNames(firstName, lastname) {\n alert('Buenas tardes ' + firstName.charAt(0).toUpperCase() + firstName.slice(1) \n + ' ' \n + lastname.charAt(0).toUpperCase() + lastname.slice(1))\n \n console.log(firstName + ' ' + lastname)\n}", "function greetMe(yourName) {\n alert('Hello ' + yourName);\n }", "function name(firstName, lastName) {\n var userName = firstName + \" \" + lastName;\n return userName;\n}", "function greet(str) {\n // prompt('Enter your name');\n // var userName = prompt('Enter your name');\n var message = 'Hello, ' + str + '!';\n // alert(message);\n return message;\n }", "function test2(name) {\nalert(\"Welcome back \" + name + \".\");\n\n}", "function showMessage() {\n userName='petty' //we can modify the outer variable here too\n let message = 'Hello, ' + userName; //userName is an outor variable and we can access it too\n \n console.log(message);\n}", "function printName(f, l) {\n var greeting1 = \"Hi there, \";\n console.log(greeting1 + f + \" \" + l);\n var greeting1 = \"Hello there, \";\n console.log(greeting1 + f + \" \" + l);\n var greeting = \"Hi there, \";\n console.log(greeting + f + \" \" + l);\n greeting = \"Hello there, \";\n console.log(greeting + f + \" \" + l);\n}", "function addString(a,b){\n\tconst fullName = a +\" \"+ b;\n\n\treturn fullName;\n}", "function printName() {\n var name = \"Luke Mason\" // hint.. add a parameter on this line :)\n console.log(name)\n}", "function myName(name){\n\treturn \"Hello \" + name + \". \";\n}", "function testVariable() {\r\n var strText = document.getElementById(\"textOne\").value; \r\n var strText1 = document.getElementById(\"textTwo\").value;\r\n var result = strText + ' ' + strText1;\r\n document.getElementById('spanResult').textContent = result;\r\n \r\n }", "function greeting(name){\n\treturn \"sup fam \" + name\n}", "function yourName(firstName = \"Please enter your first name.\", lastName = \"Please enter your last name.\"){\n return firstName + \" \" + lastName;\n }", "function printName(value){ //the variable \"lastName\" is function scoped, only avaiale\n var lastName = \"dennis\"; //inside of the function. The globally scoped \"name\" variable\n console.log(name + \" \" + lastName);}", "function showMessage(name){\n console.log(\"Hello\" + name);\n}", "function sayHi2(who) {\n alert('Hello ' + who + '! (4)');\n}", "function nameGenerator() {\n// Random # from 0-5\n var anyNum1 = Math.floor(Math.random() * 5);\n var anyNum2 = Math.floor(Math.random() * 5);\n var firstNames = [\n 'Steve',\n 'Bucky',\n 'Natasha',\n 'Rocket',\n 'Groot'\n ];\n var lastNames = [\n 'Her',\n 'Yang',\n 'Vang',\n 'Lor',\n 'Xiong'\n ];\n var fullName = firstNames[anyNum1] + '' + lastNames[anyNum2]; //<-- Concatenation(CONCAT)\n alert(fullName);\n}", "function greet(fname, lname) //parameters of 'greet' function\n{\n\n console.log('Hello ' + fname + \" \" + lname + \" !!\"); //concatenation of 2 strings\n\n}", "function favoriteThings()\n{\n var message = \"My name is Cate.\";\n console.log(message);\n message = \"My favorite movie is Say Anything.\";\n console.log(message);\n message = \"My favorite band is Coheed and Cambria.\";\n console.log(message);\n}", "function pegarNomeCadastro() {\n var valor = \"\";\n\n valor = document.getElementById('nome').value;\n alert (`${valor}`+' seu cadastro foi realizado com sucesso')\n}", "function greet(name,lastname){\n console.log('hello ' + name + ' ' + lastname );\n\n}", "function userName() {\r\n var name = prompt('What is your name?');\r\n\r\n alert('Hello ' + name + '! Welcome to my bio! How about a quiz?'); //returns greeting to user\r\n console.log('Your name is ' + name + '.');\r\n //beginning of the score keeping tally to be calculated at the end of the ?s\r\n var finalScore = 0;\r\n return name;\r\n}", "function thank(name){\r\n\tdocument.write(\"<p>thank you, \" + name + \" </p>\"); //can use HTML style rules inside\"\" in javascript\r\n}", "function introduce(name, age, address, hobby) {\n return (\"Nama saya \" + name + \", umur saya \" + \" age tahun,\" + \" alamat saya di \" + address + \", dan saya punya hobby yaitu \" + hobby)\n}" ]
[ "0.73478764", "0.71034443", "0.7068263", "0.6941338", "0.6908971", "0.6898502", "0.685678", "0.6751887", "0.6719597", "0.66759884", "0.66648537", "0.6615329", "0.661254", "0.6582621", "0.65777504", "0.6574689", "0.6571808", "0.65597373", "0.65440905", "0.652369", "0.6519997", "0.6476421", "0.6458256", "0.6410748", "0.6397578", "0.63345987", "0.63323796", "0.6315074", "0.63150525", "0.63088304", "0.630651", "0.62919235", "0.62898797", "0.6285067", "0.6275739", "0.62552404", "0.6249552", "0.6232241", "0.6214595", "0.62041426", "0.6194309", "0.6189275", "0.61842954", "0.61796856", "0.6165055", "0.61625785", "0.61556536", "0.61547005", "0.61386293", "0.6137355", "0.6116756", "0.6113727", "0.6112931", "0.6110264", "0.61096823", "0.61088246", "0.609793", "0.6096086", "0.60939264", "0.6091811", "0.60819674", "0.6078503", "0.60745776", "0.6043817", "0.6041671", "0.60405004", "0.6032252", "0.60250574", "0.6023963", "0.6018111", "0.6014795", "0.60139155", "0.6013307", "0.60031426", "0.59959847", "0.5994369", "0.59842044", "0.5983619", "0.59788185", "0.5972012", "0.59543157", "0.595416", "0.59512526", "0.59455806", "0.5942529", "0.5927207", "0.59245837", "0.5918721", "0.5918023", "0.59173006", "0.591154", "0.590751", "0.5906674", "0.59066147", "0.5900685", "0.58886313", "0.58879006", "0.5884255", "0.5873484", "0.5865415", "0.58601046" ]
0.0
-1
loop through the list of partialList and call loading
function loadingPartial(id){ if(id){ console.log("loadingPartial with id: %s", id); renderPartialPostHandler(id); } else{ console.log("loading all partial"); for(var i in partialList){ if(!partialList[i].isRendered) renderPartialPostHandler(i); } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function loadLists() {\n\tloadEquipmentSlots();\n\tloadNpcList();\n}", "prepLoadList (list, callback) {\n\n // store here for when loadList gets called.\n this._list = list;\n\n // only want a single instance of this function.\n this._bulkLoadCompleteFn = callback;\n }", "function loadList() {\n return loadListFunctionality();\n }", "function loadLists() {\r\n\t\tlistItems();\r\n\t\taddCheckButtonEvents();\r\n\t\taddDeleteButtonEvents();\r\n\t}", "function loadAll() {\n var items = '';\n $.ajax({\n type: 'POST',\n url: UrlAll,\n dataType: 'json',\n contentType: 'application/json; charset=utf-8',\n }).done(function (resp) {\n if (resp.length > 0) {\n $.each(resp, function (idx, val) {\n items += '<li draggable=\"true\" id=' + val.BlockId + '>' + val.BlockName + '</li>';\n });\n $(listId).html(items);\n setListEvents();\n }\n else {\n $(listId).html('<p > Список пустий </p>');\n }\n loadSelected();\n }).error(function (err) {\n alert('Error! ' + err.status);\n });\n }", "function GetAccountsListPartial() {\n $(\"#dataListPartialWrapper\").html('<div class=\"\" id=\"ajax-Accounts-loader1\" style=\"text-align: center;\"><div class=\"\" style=\"display: inline-block;\"><i class=\"fa fa-spinner fa-spin fa-3x fa-fw\"></i></div></div>');\n $(\"#dataListPartialWrapper\").load(\"/Saver/GetAccountsListPartial\");\n}", "function loadList (array){\n array.forEach(function(item){\n addItem(item.name, item.id, item.done, item.trash);\n });\n }", "function GetActiveBudgetsPartial() {\n $(\"#dataListPartialWrapper\").html('<div class=\"\" id=\"ajax-Accounts-loader1\" style=\"text-align: center;\"><div class=\"\" style=\"display: inline-block;\"><i class=\"fa fa-spinner fa-spin fa-3x fa-fw\"></i></div></div>');\n $(\"#dataListPartialWrapper\").load(\"/Saver/DisplayActiveBudgets\");\n}", "function GetInactiveAccountsListPartial() {\n $(\"#dataListPartialWrapper\").html('<div class=\"\" id=\"ajax-Accounts-loader1\" style=\"text-align: center;\"><div class=\"\" style=\"display: inline-block;\"><i class=\"fa fa-spinner fa-spin fa-3x fa-fw\"></i></div></div>');\n $(\"#dataListPartialWrapper\").load(\"/Saver/GetInactiveAccountsListPartial\");\n}", "function loadPartials() {\n\t\t$allPost.load( \"partials/all.html\" );\n\t}", "function loadAll(data) {\n data.users[0].todos.forEach(data => loadSplitHelper(data, \".todo-content\"));\n data.users[0].goals.forEach(data => loadSplitHelper(data, \".goal-content\"));\n }", "function loadLookUps() {\n var baseFilter = {\n filter: 'active'\n };\n\n\n function getTaskTypeData(data, params) {\n var result = dataAPIService.applyFilters(data, params);\n $scope.all_task_type = _.keyBy(result, 'id');\n return result;\n }\n\n var loadTables = [\n {\n name: 'subbie',\n params: {\n filter: [\n 'active'\n ]\n },\n callback: dataAPIService.applyFilters,\n scope: 'subcontractors'\n },\n {\n name: 'code_task_type',\n params: baseFilter,\n callback: getTaskTypeData,\n scope: 'task_types'\n },\n {\n name: 'client',\n params: baseFilter,\n callback: dataAPIService.applyFilters,\n scope: 'clients'\n }\n ];\n models = _.map(loadTables, 'name');\n models.push('job', 'tasks');\n dataCacheService.processLoadTables(loadTables, $scope, 'query');\n }", "function loadAndRenderItems() {\n pageData().then(render)\n }", "handleLoadList(listId) {\n // UNLOAD THE CURRENT LIST AND INSTEAD LOAD THE CURRENT LIST\n this.model.loadList(listId);\n }", "loadChildrenOf(item, callback) {\n let loaded = false;\n let preventiveAnimationFinished = false;\n let barFinihsed = false;\n let finishBar = () => {\n bar.animate({\n width: '100%'\n }, 50, null, () => {\n barFinihsed = true;\n bar.fadeOut();\n });\n };\n // Clear items off list\n this.listView.items.clear();\n // Show load bar\n let bar = $(this.loadBar);\n let started = latte.DateTime.now;\n bar.addClass('visible');\n bar.show();\n bar.css('width', '1px');\n bar.animate({\n width: '90%'\n }, this.nextLoadTimePrediction, null, () => {\n preventiveAnimationFinished = true;\n if (loaded) {\n finishBar();\n }\n });\n item.loadChildren(() => {\n // Data has been loaded\n loaded = true;\n // Register the loading time\n this.addLoadingTime(latte.DateTime.now.subtractDate(started));\n // If preventive animation finished\n if (preventiveAnimationFinished) {\n finishBar();\n }\n callback();\n });\n }", "function loadList() {\r\n\t$('#tml-list').append('<h3 class=\"tml-list-h3\">Template singoli</h3>')\r\n\t// carico i template singoli\r\n\tfor (var i = 1; i < numTemplatesS+1; i++) {\r\n\t\t// creo list item ancora\r\n\t\tvar listItem = \"<li class='tml-list-item' ><div class='tml-list-item-div'><a class='tml-list-item-a' onclick='selectTml(this)' href='javascript:void(0)' id='tml\"+i+\"'></a></div></li>\";\r\n\t\t// appendo l'elemento alla lista\r\n\t\t$('#tml-list').append(listItem);\r\n\t\t// creo l'oggetto ractive col template relativo\r\n\t\t// type 0: template singoli tml'x'.html, 1: template composti ctml'x'.html\r\n\t\tloadTemplates( i , 0);\r\n\t}\r\n\r\n\t$('#tml-list').append('<h3 class=\"tml-list-h3\">Template composti</h3>')\r\n\t// carico i template singoli\r\n\tfor (var i = 1; i < numTemplatesC+1; i++) {\r\n\t\t// creo list item ancora\r\n\t\tvar listItem = \"<li class='tml-list-item' ><div class='tml-list-item-div'><a class='tml-list-item-a' onclick='selectTml(this)' href='javascript:void(0)' id='ctml\"+i+\"'></a></div></li>\";\r\n\t\t// appendo l'elemento alla lista\r\n\t\t$('#tml-list').append(listItem);\r\n\t\t// creo l'oggetto ractive col template relativo\r\n\t\t// type 0: template singoli tml'x'.html, 1: template composti ctml'x'.html\r\n\t\tloadTemplates( i , 1);\r\n\t}\r\n\r\n}", "loadList(listId) {\n this.moveListToFront(listId);\n this.view.refreshLists(this.toDoLists);\n let listIndex = -1;\n for (let i = 0; (i < this.toDoLists.length) && (listIndex < 0); i++) {\n if (this.toDoLists[i].id === listId)\n listIndex = i;\n }\n if (listIndex >= 0) {\n let listToLoad = this.toDoLists[listIndex];\n this.currentList = listToLoad;\n this.view.viewList(this.currentList);\n if(this.toDoLists[listIndex].items.length > 0){\n this.enableItemControls();\n }\n }\n this.tps.clearAllTransactions();\n this.view.disableAddListButton();\n this.view.disableRedoAndUndoButton();\n }", "function loadList(array){\n array.forEach(function(item){\n addToDo(item.name, item.id, item.done, item.trash)\n });\n}", "function loadList(array) {\n array.forEach(function(item) {\n addToDo(item.name, item.id, item.done, item.trash);\n });\n}", "function load(index){return loadInternal(getLView(),index);}", "function loadList(array) {\n array.forEach(function (item) {\n addToDo(item.name, item.id, item.done, item.trash);\n });\n}", "function loadList(array) {\n array.forEach(function (item) {\n addToDo(item.name, item.id, item.done, item.trash);\n });\n}", "function LoadPart_ThingListLookupDiv() {\n var loadingpart = LoadDivLoading();\n $(\"#divThingsLookupList\").html(loadingpart);\n $.ajax({\n url: getRootURL() + '/Things/LookupListPV?searchfor=' + $(txtThingLookupSearch).val() + '&recordsperpage=0',\n //page=\" + $(\"#DynConfigCurrentPage\").html,\n type: \"GET\",\n })\n .success(function (partialViewResult) {\n $(\"#divThingsLookupList\").html(partialViewResult);\n });\n return false;\n}", "function loadListPageData() {\n $('#list > ul').html(setListPageSensors());\n}", "function loadList(array) {\n array.forEach(function(item) {\n addToDo(item.name, item.date, item.priority, item.id, item.done, item.trash);\n });\n }", "function loadData() {\n\tvar camlQuery = new SP.CamlQuery();\n\t\n\tvar query = '<View><Query><OrderBy><FieldRef Name=\"Created\" Ascending=\"False\"></FieldRef></OrderBy></Query>'+\n\t\t\t\t'<ViewFields><FieldRef Name=\"SprintProgress\"/></ViewFields><RowLimit>'+ sprintHistoryLimit +'</RowLimit></view>';\n\tcamlQuery.set_viewXml(query);\n\tcollListItem = listReference.getItems(camlQuery);\n\n\tclientContext.load(collListItem);\n\tclientContext.executeQueryAsync(\n\tFunction.createDelegate(this, this.pageInit),\n\tFunction.createDelegate(this, this.showDataError));\n}", "function loadList(array) {\n array.forEach(function (item) {\n addTask(item.name, item.id, item.done, item.trash);\n });\n}", "function loadList() {\n var begin = ((currentPage - 1) * numberPerPage);\n var end = begin + numberPerPage;\n\n pageList = filteredData.slice(begin, end);\n console.log(pageList);\n renderTable(pageList);\n numberOfPages = getNumberOfPages(filteredData)\n check();\n}", "init() {\n for (let i = 0; i < this._airportListToLoad.length; i++) {\n const airport = this._airportListToLoad[i];\n\n this.airport_load(airport);\n }\n }", "function loadAjaxFiles( filesList, lastCb )\n {\n var completionCount = 0;\n var loadedFiles = [];\n var loadedFilesById = {};\n\n filesList.forEach( function( fileItem, ix ) {\n\n var xml = new XMLHttpRequest();\n\t\t\ttry{ \n\t\t\t\txml.open( 'GET', fileItem.link, true ); \n\t\t\t\txml.send( null );\n\t\t\t xml.onreadystatechange = processIfGood;\n\t\t\t}catch ( e ) {\t//\tTODM\n\t\t\t\t//Give up.\n completionCount++;\n checkCompletion( fileItem );\n\t\t\t}\n function processIfGood()\n {\n\t\t\t\tif ( xml.readyState === 4 ) \n\t\t\t\t{\n\t\t\t\t\tif( xml.status === 200 )\n\t\t\t\t\t{\n\t\t\t\t\t\tfileOnLoad();\n\t\t\t\t\t} else {\n //Give up.\n completionCount++;\n checkCompletion( fileItem );\n //onerror && onerror( 'Ajax problems with URL ' +\n // ajaxURL );\n\t\t\t\t\t}\n\t\t\t\t}\n }\n\n function fileOnLoad()\n {\n var loadedItem = { text:xml.responseText, fileItem:fileItem };\n //ccc( 'success: ', loadedItem );\n loadedFiles.push( loadedItem );\n if( fileItem.id ) {\n loadedFilesById[ fileItem.id ] = loadedItem;\n }\n completionCount++;\n //ccc( completionCount + ' loaded ' + fileItem.src );\n fileItem.cb && fileItem.cb( loadedItem );\n checkCompletion( fileItem );\n }\n });\n return; //rrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr\n\n function checkCompletion( fileItem )\n {\n if( completionCount === filesList.length ) {\n lastCb && lastCb( loadedFilesById, loadedFiles );\n }\n }\n }", "function loadPlayerList() {\n playerArray.forEach(addPlayerToUIList);\n }", "function loadNextList()\n{\n\t\t\t\t//First collect the basic list information\n\t\t\t\tvar containerDiv = $('#scrolltarget').parents('.continous-scroll').first();\n\t\t\t\tvar url = containerDiv.data('url')? containerDiv.data('url'): (containerDiv.data('type')? getBaseURL()+'lists/load/t/'+containerDiv.data('type'): '');\n\t\t\t\t\n\t\t\t\tvar page = containerDiv.data('page')? containerDiv.data('page'): 1;\n\t\t\t\tvar noPerPage = containerDiv.data('noperpage')? containerDiv.data('noperpage'): 10;\n\t\t\t\t// Add these to the URL\n\t\t\t\turl += (url != ''? '/p/'+(page+1)+'/n/'+noPerPage: '');\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t// Also collect any other information in the other fields if provided\n\t\t\t\tif(containerDiv.data('fields')){\n\t\t\t\t\tvar fields = containerDiv.data('fields').split('|');\n\t\t\t\t\t$.each(fields, function(index, value){\n\t\t\t\t\t\tvar fieldKeyParts = value.split('=');\n\t\t\t\t\t\turl += ($('#'+fieldKeyParts[0]).length && $('#'+fieldKeyParts[0]).val() != ''? '/'+fieldKeyParts[1]+'/'+replaceBadChars($('#'+fieldKeyParts[0]).val()): '');\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t//remove the row if it is made for just this button as it will be recreated on next load\n\t\t\t\tif($('#scrolltarget').parents('td').first().hasClass('load-next-row')){\n\t\t\t\t\t$('#scrolltarget').parents('tr').first().remove();\n\t\t\t\t}\n\t\t\t\telse $('#scrolltarget').remove();\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t// Load the next data\n\t\t\t\t$.when( $.ajax(url) ).then(function( data, textStatus, jqXHR ) {\n\t\t\t\t\tvar containerId = containerDiv.attr('id');\n\t\t\t\t\t// Remove loading image if present\n\t\t\t\t\tif($('.loading-image').length) $('.loading-image').remove();\n\t\t\t\t\t\n\t\t\t\t\tif($('#'+containerId+' > table:not(.msg)').length) {\n\t\t\t\t\t\tcontainerDiv.children('table').first().find('tbody').first().append(data);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tcontainerDiv.append(data);\n\t\t\t\t\t\t\n\t\t\t\t\t\t//Update the item width if store items have been loaded\n\t\t\t\t\t\tif($('.store-item').length){\n\t\t\t\t\t\t\tvar width = containerDiv.find('.store-item').first().width();\n\t\t\t\t\t\t\tcontainerDiv.find('.store-item').each(function(){\n\t\t\t\t\t\t\t\t$(this).css('max-width', width+'px');\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Check if the order by has been selected already\n\t\t\t\t\t\t\tif($('#sort__searchsortoptions__hidden').length){\n\t\t\t\t\t\t\t\tvar orderBy = $('#sort__searchsortoptions__hidden').val().toLowerCase();\n\t\t\t\t\t\t\t\treorderStoreItems(orderBy);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Reposition the msg table\n\t\t\t\t\tif(containerDiv.find('.msg').length > 0) { \n\t\t\t\t\t\tvar msg = containerDiv.find('.msg').first();\n\t\t\t\t\t\tvar msgHtml = msg.get(0).outerHTML;\n\t\t\t\t\t\tmsg.remove();\n\t\t\t\t\t\tcontainerDiv.append(msgHtml);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t//Increment to load the next page\n\t\t\t\t\tcontainerDiv.data('page', (page+1));\n\t\t\t\t});\n}", "loadData(state, lists) {\n state.lists = lists;\n }", "_handleLoadReasonList() {\n this._loading(true);\n\n api.loadReasonList({}, (success, result, msg) => {\n this._loading(false);\n \n if (success) {\n let options = [];\n\n result.map((item)=>{\n const oneOptions = {\n label : item.Name,\n value : item.ID\n };\n options.push(oneOptions)\n });\n\n this.setState({\n ...this.state,\n dataAPI: {\n ...this.state.dataAPI,\n apiReasonList: options,\n },\n loadingVisible: false\n });\n\n } else {\n this._error(msg);\n }\n });\n }", "function loadItens()\r\n{\r\n\tfor (let i = 0; i < todo.length; i++) \r\n\t{\r\n\t\taddItemToDOM(todo[i]);\r\n\t}\r\n\tfor (var i = 0; i < completed.length; i++) {\r\n\t\taddItemToDOM(completed[i],true);\r\n\t}\r\n\r\n}", "function loader(items, thingToDo, allDone) {\n if (!items) {\n // nothing to do.\n return;\n }\n\n if (\"undefined\" === items.length) {\n // convert single item to array.\n items = [items];\n }\n\n var count = items.length;\n\n // this callback counts down the things to do.\n var thingToDoCompleted = function (items, i) {\n count--;\n if (0 == count) {\n allDone(items);\n }\n };\n\n for (var i = 0; i < items.length; i++) {\n // 'do' each thing, and await callback.\n thingToDo(items, i, thingToDoCompleted);\n }\n}", "function loadList() {\n\t\t// Display an error message if error code is not 410 or 200 (okay)\n\t\tif (this.status != 200 && this.status != 410) {\n\t\t\tdisplayError();\n\t\t}\n\t\tvar list = document.getElementById(\"allnames\");\n\t\tvar lines = this.responseText.split(\"\\n\");\n\t\t// Add each name into select box\n\t\tfor (var i = 0; i < lines.length; i++) {\n\t\t\taddName(lines[i]);\n\t\t}\n\t\tlist.disabled = false;\n\t\tdocument.getElementById(\"loadingnames\").style.display = \"none\";\n\t}", "function loadAll(){\n\tchangeSeason()\n\tgetAnimeData()\n\tgetCharacterData()\n\tgetEpisodeData()\n\tgetImageData()\n\tgetVideoData()\n}", "initList() {\n this.loadedMinTime = true;\n this.postLoadState = STATE_OK;\n this.timeoutId = setTimeout(this.connectionTimedOut, TIME_TIMEOUT);\n this.props.communication.requestInstances(this);\n }", "function populateLoad() {\n\t$.ajax({\n\t\ttype: 'GET',\n\t\t//data: JSON.stringify(itemData),\n\t\tcontentType: 'application/json',\n\t\turl: '/monster-list',\n\t\tsuccess: function(data){\n\t\t\t//console.log(data);\n\t\t\tvar monsters = JSON.parse(data);\n\t\t\t//console.log(items[0].id);\n\n\t\t\tfor (var i = 0; i < monsters.length; i++) {\n\t\t\t\t$(\".load-window\").append(\"<p class='v-small'>\"+monsters[i].id+\"</p>\");\n\t\t\t}\n\n\t\t\t$(\".load-window .v-small\").each(function() {\n\t\t\t\t$(this).click(function() {\n\t\t\t\t\tgrabItem($(this));\n\t\t\t\t});\n\t\t\t});\n\t\t}\n\t});\n}", "function loadViewListTemplatePost() {\n $(\"#loadingViewTemplatePost\").show();\n\n $.ajax({\n type: \"POST\",\n url: thisPathReloadListPost,\n success: function (response) {\n $(\"#loadingViewTemplatePost\").hide();\n $(\"#listNameTemplate\").html(response);\n loadViewTemplatePost();\n }\n });\n }", "function loadList() {\n showLoadingMessage('Loading Pokemon list, please wait...');\n return fetch(apiUrl)\n .then(function(response) {\n return response.json();\n })\n .then(function(json) {\n hideLoadingMessage();\n json.results.forEach(function(item) {\n var pokemon = {\n name: item.name,\n detailsUrl: item.url\n };\n add(pokemon);\n });\n })\n .catch(function(e) {\n /* eslint-disable no-console */\n console.error(e);\n /* eslint-enable no-console */\n });\n }", "function load_model(index){\n if(index >= self.models.length){\n loaded.resolve();\n }else{\n var model = self.models[index];\n self.pos_widget.loading_message(_t('Loading')+' '+(model.label || model.model || ''), progress);\n var fields = typeof model.fields === 'function' ? model.fields(self,tmp) : model.fields;\n var domain = typeof model.domain === 'function' ? model.domain(self,tmp) : model.domain;\n var context = typeof model.context === 'function' ? model.context(self,tmp) : model.context;\n var ids = typeof model.ids === 'function' ? model.ids(self,tmp) : model.ids;\n progress += progress_step;\n\n if( model.model ){\n if (model.ids) {\n var records = new instance.web.Model(model.model).call('read',[ids,fields],context);\n } else {\n var records = new instance.web.Model(model.model).query(fields).filter(domain).context(context).all()\n }\n records.then(function(result){\n try{ // catching exceptions in model.loaded(...)\n\n result_filtered = []\n if(model.model == \"product.product\")\n {\n for(var i = 0; i < result.length; i++)\n {\n //Filtrando los productos que tengan stock >0, que no tengan una compañia\n //o que tengan una compañia asignada y coincida con la que tiene configurada el\n //punto de venta\n if(result[i].stock_qty > 0 && (result[i].company_id == false || (result[i].company_id != false && result[i].company_id[0] == self.config.company_id[0])))\n {\n result_filtered.push(result[i]);\n }\n }\n result = result_filtered;\n }\n\n $.when(model.loaded(self,result,tmp))\n .then(function(){ load_model(index + 1); },\n function(err){ loaded.reject(err); });\n }catch(err){\n loaded.reject(err);\n }\n },function(err){\n loaded.reject(err);\n });\n }else if( model.loaded ){\n try{ // catching exceptions in model.loaded(...)\n $.when(model.loaded(self,tmp))\n .then( function(){ load_model(index +1); },\n function(err){ loaded.reject(err); });\n }catch(err){\n loaded.reject(err);\n }\n }else{\n load_model(index + 1);\n }\n }\n }", "function loadList() {\n return $.ajax(apiUrl, {\n method: 'GET',\n dataType: 'json'\n }).then(function(item) {\n //console.log(item.results); //array of objects for JS generated */\n $.each(item.results, (function(index, result) {\n //console.log(item);\n const pokemon = {\n name: result.name,\n detailsUrl: result.url\n };\n add(pokemon);\n }));\n }).catch(function(e) {\n console.error(e);\n });\n }", "loadPage() {\n\t\tif (!this.onBeforeLoadPage()) {return;}\n\t\tthis.showPageLoadingIndicator();\n\t\tdxRequestInternal(\n\t\t\tgetComponentControllerPath(this),\n\t\t\tthis.getLoadFunctionParameters(),\n\t\t\tfunction(data_obj) {\n\t\t\t\tdata_obj.Page.forEach(function(item) {\n\t\t\t\t\tthis.addRow(item);\n\t\t\t\t}.bind(this));\n\t\t\t\tthis.total_items = data_obj.TotalCount;\n\t\t\t\tgetComponentElementById(this,\"DataListMoreButton\").show();\n\t\t\t\tif (this.total_items <= (this.current_list_offset+this.list_offset_increment)) {\n\t\t\t\t\tgetComponentElementById(this,\"DataListMoreButton\").hide();\n\t\t\t\t}\n\t\t\t\tif (this.current_page_array.length > 0) {\n\t\t\t\t\tgetComponentElementById(this,\"DataListLoading\").hide();\n\t\t\t\t} else {\n\t\t\t\t\tgetComponentElementById(this,\"DataListLoading\").html(\"No results\").show();\n\t\t\t\t\tgetComponentElementById(this,\"DataListMoreButton\").hide();\n\t\t\t\t}\n\t\t\t\tthis.onAfterLoadPage(data_obj);\n\t\t\t}.bind(this),\n\t\t\tfunction(data_obj) {\n\t\t\t\tgetComponentElementById(this,\"DataList\").hide();\n\t\t\t\tthis.handleComponentError('Could not retrieve data: '+data_obj.Message);\n\t\t\t}.bind(this),false,false);\n\t}", "loadAll (context) {\n const list = [\n {\n name: 'Ingame Events',\n source: '/cached/gameevents.json'\n },\n {\n name: 'Ingame Content Configures',\n source: '/cached/config.json'\n },\n {\n name: 'FullDatabase CN',\n source: '/cached/master.json',\n database: {\n name: 'master',\n singletable: false\n }\n },\n {\n name: 'unit_promotion JP',\n source: '/cached/ng_master/unit_promotion.json',\n database: {\n name: 'ng',\n singletable: true,\n table: 'unit_promotion'\n }\n }\n ].map(x => {\n const loader = new FileLoader(x.source)\n return loader.loadAsync().then(resp => {\n if (x.database) {\n if (x.database.singletable) {\n context.commit('updateDatabase', { key: x.database.table, value: resp, database: x.database.name })\n } else {\n context.commit('updateDatabase', { key: x.database.name, value: resp })\n }\n } else {\n switch (x.name) {\n case 'Ingame Events':\n context.commit('updateState', { key: 'events', value: resp })\n break\n case 'Ingame Content Configures':\n for (const [key, val] of Object.entries(resp)) {\n context.commit('updateState', { key: key, value: val })\n }\n break\n default:\n break\n }\n }\n })\n })\n Promise.all(list).then(() => {\n context.commit('updateState', { key: 'loaded', value: true })\n })\n }", "async loadFeatureList(list) {\n await import(\"./subcomp/facility.js\")\n .then(() => {\n // API call for get Facilities List\n list.forEach(\n (item) =>\n (this._qs(\".features\").innerHTML += `\n <facility-comp \n key=\"${item.featureId}\" \n name=\"${item.feature}\" \n measurable=\"${item.quantity == \"null\" ? \"false\" : \"1\"}\" \n checked=\"true\" \n quantity=\"${item.quantity}\"\n ></facility-comp>\n `)\n );\n })\n .catch((err) => this.popup(err, \"error\"));\n }", "async renderList() {\n console.log('Render List Pokemons');\n if(this.ListPokemons.length == 0) {\n await this.servicePokemons();\n }\n let self = this;\n let listUl = document.getElementById('list-pokemons');\n listUl.innerHTML = '';\n Promise.all(\n self.ListPokemons.map((pokemon) => {\n if(self.pokemonSelected._id == pokemon._id) {\n self.pokemonSelected = pokemon;\n }else {\n self.addItem(listUl, pokemon);\n }\n })\n ).then(() => {\n /** Render pokemon selected. */\n self.renderInformationAdditional();\n }); \n }", "function load() {\n\n initialize();\n allowDragNDrop();\n\n $.ajax({\n type: \"get\",\n url: 'http://localhost:3000/api/retrieve',\n contentType: 'application/json',\n success: function (items) {\n if (items == null) {\n return false;\n }\n $.each(items, function (index, value) {\n renderToDo(value.toDoText, value.doneCheck);\n });\n console.log(\"Get: \", items);\n }\n })\n updateStatsUI();\n}", "function loadItems(){\n $.ajax({\n url: \"/items\",\n method: \"GET\",\n dataType: \"json\",\n success: function(items) {\n renderItems(items);\n }\n })\n}", "function loadItens() {\r\n // for loop\r\n for (let i = 0; i < todos.length; i = i + 1) {\r\n // adds 'todos' to the to-do list\r\n addItemToDOM(todos[i]);\r\n }\r\n //adds 'completed' to the completed list\r\n for (let i = 0; i < completed.length; i = i + 1) {\r\n addItemToDOM(completed[i], true);\r\n }\r\n}", "function loadList() {\n\t$.ajax({\n\t\tmethod : \"GET\",\n\t\turl : \"./php/loaders/loadList.php\",\n\t\tsuccess : function(result) {\n\t\t\t\tfor ( i = 0; i < result['authors'].length; i++) {\n\t\t\t\tloadedAuthors[i] = {\n\t\t\t\t\t\"name\" : result['authors'][i]['name'],\n\t\t\t\t\t\"url\" : result['authors'][i]['url']\n\t\t\t\t};\n\t\t\t}\n\n\t\t},\n\t\terror : function() {\n\t\t\t//alert(\"Errore caricamento lista!\");\n\t\t}\n\t});\n}", "function loadPlayerList() {\n Player_v.all({order: 'id'}, function(err, results) {\n var players = [];\n var player = {};\n player.player_name = 'Not Selected';\n player.id = \"\";\n players[0] = player;\n\n if(results.length > 0) {\n for (var i = 0; i < results.length; i++) {\n // create a brand new instance of player object for every record. One cannot reuse the same player variable.\n var player = { player_name: results[i].first_name + \" \" + results[i].last_name + \"-\" + results[i].city + \"/\" + results[i].state_or_province,\n id: results[i].id};\n players.push(player);\n }\n } // end of if.\n\n this.player_list = players;\n\n next(); // process the next tick.\n }.bind(this));\n}", "function loadLPOData(id) {\n spWeb = context.get_web();\n item = spWeb.get_lists().getByTitle(lpoList).getItemById(id);\n\n context.load(item);\n context.executeQueryAsync(onGetLPODataSuccess, onGetLPODataFail);\n}", "function loadAllJSON(list, func) {\n\tconst promises = [];\n\tlist.forEach(data => promises.push(loadJSON(data, func)));\n\treturn Promise.all(promises);\n}", "function loadList () {\n return fetch(apiUrl).then(function (response) {\n return response.json();\n }).then(function (json) {\n json.results.forEach(function (item) {\n let pokemon = {\n name: item.name,\n detailsUrl: item.url\n };\n add(pokemon);\n });\n }).catch(function (e) {\n window.alert(e);\n })\n }", "function loadList() {\n\t\t\treturn fetch(apiUrl)\n\t\t\t\t.then(function (response) {\n\t\t\t\treturn response.json();\n\t\t\t})\n\t\t\t\t.then(function (json) {\n\t\t\t\tjson.results.forEach(function (item) {\n\t\t\t\t\tlet pokemon = {\n\t\t\t\t\tname: item.name,\n\t\t\t\t\tdetailsUrl: item.url\n\t\t\t\t\t};\n\t\t\t\t\tadd(pokemon);\n\t\t\t\t});\n\t\t\t})\n\t\t\t\t.catch(function (e) {\n\t\t\tconsole.error(e);\n\t\t\t});\n\t\t}", "function loadListFunctionality() {\n return fetch(API_URL)\n .then(function (response) {\n return response.json();\n })\n .then(function (json) {\n json.results.forEach(function (item) {\n let pokemon = {\n name: item.name,\n detailsUrl: item.url,\n };\n pokemonRepository.add(pokemon);\n });\n })\n .catch(function (e) {\n console.error(e);\n });\n}", "loadingData() {}", "loadingData() {}", "function loadDivision(displayStatus,commaSeparatedList){\n\tvar divList = new Array();\n\tdivList = commaSeparatedList.split(\",\");\n\tfor(var i=0;i<divList.length;i++){\n\t\tvar divName = trimText(divList[i]);\n\t\tif(displayStatus.toLowerCase() == \"load\"){\n\t\t\tdocument.getElementById(divName).style.visibility = \"visible\";\n\t \t}else{\n\t \t\tdocument.getElementById(divName).style.visibility = \"hidden\";\n\t\t}\n\t}\n}", "function loadToDoList() {\r\n $.ajax({\r\n type: \"GET\",\r\n url: \"api/todos\",\r\n async: false\r\n }).done(function (result) {\r\n // Loading the records in tasklist array to display in UI\r\n self.tasklist(replaceID(result.data));\r\n //Hide the loading indicator\r\n self.isLoading(false);\r\n }).fail(function (err) {\r\n });\r\n}", "function loadList() {\n return fetch(apiUrl).then(function (response) {\n return response.json();\n }).then(function (json) {\n json.results.forEach(function (item) {\n let pokemon = {\n name: item.name,\n detailsUrl: item.url\n };\n add(pokemon);\n });\n }).catch(function (e) {\n console.error(e);\n });\n }", "lazyLoad() {\n if(!this.state.loading && this.state.next) {\n const offset = this.state.offset + this.state.limit;\n this.getAlbums(offset);\n }\n }", "function loadCourseList(){\n\tget(\"searchlist/load_list/\", function(){\n\t\tcourseList = arguments[0].split(\",\");\n\t});\n}", "static fetchAll(callBack){\n getProductsFromFile(callBack);\n }", "function loadData() {\n $.get(\"/api/games\")\n .done(function (data) {\n updateList(data);\n })\n .fail(function (jqXHR, textStatus) {\n alert(\"Failed: \" + textStatus);\n });\n }", "function loadList() {\n return fetch(apiUrl).then(function (response) {\n return response.json();\n }).then(function (json) {\n json.results.forEach(function (item) {\n var pokemon = {\n name: item.name,\n detailsUrl: item.url\n };\n add(pokemon);\n });\n }).catch(function (e) {\n console.error(e);\n })\n }", "function loadList(array){\n array.forEach(function(item){\n addSearchHistory(item.city, item.id, item.temp, item.weather_el, item.weather_icon);\n });\n}", "function loadParts() {\n SRPurchaseService.RetrieveSRParts().then(function (result) {\n $scope.SRParts = result.data.DataList;\n });\n }", "function Data() {\n var context = SP.ClientContext.get_current();\n var web = context.get_web();\n var lists = web.get_lists();\n //var list = context.get_web().get_lists().getByTitle('RajeshPracticeList');\n //var camlquery = new SP.CamlQuery();\n //camlquery.set_viewXml('<View><RowLimit>100</RowLimit></View>');\n\n //this.collListItem = list.getItems(camlquery);\n\n context.load(web, \"Title\", \"Description\");\n context.load(lists, \"Include(Title,Fields.Include(Title))\");\n //context.load(collListItem, 'Include(Id,DisplayName)');\n context.executeQueryAsync(success, fail);\n\n function success() {\n var info = jQuery(\"#message1\");\n info.append(web.get_title());\n\n var listEnumerator = lists.getEnumerator();\n while (listEnumerator.moveNext()) {\n var listinfo = listEnumerator.get_current();\n info.append(\"<br />\");\n info.append(listinfo.get_title());\n\n //var listFields = lists.get_fields();\n //clientContext.load(listFields);\n\n var listfiledinfo = listinfo.get_fields().getEnumerator();\n\n while (listfiledinfo.moveNext()) {\n var field = listfiledinfo.get_current();\n info.append(\"<br />&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp\");\n info.append(field.get_title());\n\n\n }\n }\n }\n function fail(sender, args) {\n alert(\"Error Occured\" + args.get_message());\n\n }\n\n\n }", "function loadThings(data) {\n \n data.forEach(function(e, i, a) {\n _things[e._id] = e;\n });\n}", "function loadList() {\n return fetch(apiUrl).then(function(response) {\n return response.json();\n }).then(function(json) {\n json.results.forEach(function(item) {\n let pokemon = {\n name: item.name,\n detailsUrl: item.url\n };\n add(pokemon);\n });\n }).catch(function(e) {\n console.error(e);\n })\n}", "function loadList() {\n return fetch(apiUrl)\n .then(function (response) {\n return response.json();\n })\n .then(function (json) {\n json.results.forEach(function (item) {\n let pokemon = {\n name: item.name,\n detailsUrl: item.url,\n };\n add(pokemon);\n });\n })\n .catch(function (e) {\n console.error(e);\n });\n }", "function loadList() {\n return fetch(apiUrl)\n .then(function (response) {\n return response.json();\n })\n .then(function (json) {\n json.results.forEach(function (item) {\n let pokemon = {\n name: item.name,\n detailsUrl: item.url,\n };\n add(pokemon);\n });\n })\n .catch(function (e) {\n console.error(e);\n });\n }", "function load() {\n loadJSONfromServer()\n .then(function (result) {\n console.log('Laden erfolgreich!', result);\n myJSON = JSON.parse(result);\n for (let i = 0; i < myJSON.length; i++) {\n docsList[i] = myJSON[i];\n }\n displayDocsImages();\n Profiles();\n })\n .catch(function (error) {\n console.error('Fehler beim laden!', error);\n });\n}", "function loadData() {\n return dataService.getList()\n .then(function (res) {\n vm.fullList = athleteService.transformList(res);\n })\n .catch(exception.catcher('Failed to retrieve data'));\n }", "function WithListLoading(Component) {\r\n return function WithLoadingComponent({ isLoading, ...props }) {\r\n if (!isLoading) return <Component {...props} />;\r\n const Id = \"\";\r\n return (\r\n <>\r\n {[1,2,3].map(\r\n num => (\r\n (Id = num),\r\n (\r\n <Col size={{ xs: 6, md: 6, lg: 4, xl: 4 }} key={Id}>\r\n <Div\r\n m={{ b: { xs: \"1rem\", lg: \"0\" } }}\r\n className=\"store-card--loading\"\r\n >\r\n <Div\r\n d=\"flex\"\r\n flexDir=\"column\"\r\n h=\"100%\"\r\n p={{\r\n xs: \"0.75rem\",\r\n md: \"0.75rem\",\r\n lg: \"1.5rem\",\r\n xl: \"1.5rem\"\r\n }}\r\n bg=\"white\"\r\n border=\"1px solid\"\r\n borderColor=\"gray200\"\r\n shadow=\"3\"\r\n hoverShadow=\"4\"\r\n rounded=\"sm\"\r\n m={{ b: { xs: \"1.3rem\", lg: \"1.3rem\" } }}\r\n className=\"store-card--loading__wrapper\"\r\n >\r\n <Div flexGrow=\"1\">\r\n <Div\r\n d=\"flex\"\r\n justify=\"center\"\r\n align=\"center\"\r\n m={{ t: \"auto\", r: \"auto\", b: \"1rem\", l: \"auto\" }}\r\n />\r\n <Skeleton\r\n duration={3}\r\n style={{\r\n width: \"160px\",\r\n height: \"1.8rem\",\r\n marginBottom: \"0.5rem\"\r\n }}\r\n />\r\n <Skeleton\r\n style={{ height: \"0.9rem\", marginBottom: \"0.5rem\" }}\r\n count={2}\r\n duration={3}\r\n />\r\n <Skeleton\r\n style={{\r\n width: \"120px\",\r\n height: \"1.8rem\",\r\n marginBottom: \"0.5rem\",\r\n borderRadius: \"1000rem\"\r\n }}\r\n duration={3}\r\n />\r\n <Skeleton\r\n style={{\r\n display: \"block\",\r\n width: \"140px\",\r\n height: \"0.9rem\",\r\n marginBottom: \"0.5rem\"\r\n }}\r\n duration={3}\r\n />\r\n <Skeleton\r\n style={{\r\n width: \"140px\",\r\n height: \"2.5rem\",\r\n marginBottom: \"0.5rem\",\r\n borderRadius: \"0.35rem\"\r\n }}\r\n duration={3}\r\n />\r\n </Div>\r\n </Div>\r\n </Div>\r\n </Col>\r\n )\r\n )\r\n )}\r\n </>\r\n );\r\n };\r\n}", "function loadList() {\n return fetch(apiURL).then(function(response){\n return response.json();\n }).then (function(json){\n json.results.forEach(function(item){\n let pokemon = {\n name: item.name,\n detailsUrl: item.url,\n \n };\n add(pokemon);\n });\n }).catch(function(e){\n console.error(e);\n });\n}", "function loadTemplateData(){\r\n\t\r\n\tfor(var i = 0; i < Object.keys(templates).length; i++){\r\n\t\tvar groupName = Object.keys(templates)[i];\r\n\t\tvar group = templates[groupName];\r\n\t\tvar templateNames = [];\r\n\t\tfor(var j = 0; j < Object.keys(group).length; j++){\r\n\t\t\tvar templateName = Object.keys(group)[j];\r\n\t\t\ttemplateNames.push(templateName);\r\n\t\t}\r\n\t\tloadShelfData(groupName, $(\"#right_shelf\"), templateNames, true);\r\n\t}\t\r\n}", "function loadResults(){\n //console.log(\"loadQuantity\");\n var $results = $('.' + _results);\n for(var i = 0; i < $results.length; i++){\n var $result = $($results[i]);\n var datas = $result.data();\n if (!datas[_resController]\n || !datas[_resTempHeader]\n || !datas[_resTempHeaderId]\n || !datas[_resTempItem]\n || !datas[_resTempItemId]\n || !datas[_resTempPagination]\n || !datas[_resTempPaginationId]) {\n throw Error(\"Resuts \" + _results + \" do not define datas correctly\");\n }\n\n var ctxt = {\n \"_resTempHeaderId\": _resTempHeaderId,\n \"_resTempItemId\": _resTempItemId,\n \"_resTempPaginationId\": _resTempPaginationId\n };\n var jCookie = getJCookie(_cookieName);\n var jResources = jCookie[_jResources];\n if (jResources) {\n var ids = Object.keys(jResources).join(\"|\");\n ctxt[\"ids\"] = ids;\n $.get(datas[_resController], ctxt)\n .done(function(data){\n $('#' + ctxt[_resTempHeaderId]).empty().append(data);\n $('#' + ctxt[_resTempItemId]).append(data);\n $('#' + ctxt[_resTempPaginationId]).empty().append(data);\n })\n .fail(function(err){\n console.error(\"loading resources\", ctxt, err);\n })\n }\n }\n }", "componentDidMount() {\n // loading the list for the first time\n this.loadList();\n }", "function loaded(err, result) {\n if (errors.length) return;\n\n if (err) {\n errors.push({\n msg: err.responseText,\n details: [ t('save.status_code', { code: err.status }) ]\n });\n showErrors();\n\n } else {\n var loadMore = [];\n _.each(result.data, function(entity) {\n remoteGraph.replace(entity);\n toLoad = _.without(toLoad, entity.id);\n\n // Because loadMultiple doesn't download /full like loadEntity,\n // need to also load children that aren't already being checked..\n if (!entity.visible) return;\n if (entity.type === 'way') {\n loadMore.push.apply(loadMore,\n _.difference(entity.nodes, toCheck, toLoad, loadMore));\n } else if (entity.type === 'relation' && entity.isMultipolygon()) {\n loadMore.push.apply(loadMore,\n _.difference(_.map(entity.members, 'id'), toCheck, toLoad, loadMore));\n }\n });\n\n if (loadMore.length) {\n toLoad.push.apply(toLoad, loadMore);\n context.connection().loadMultiple(loadMore, loaded);\n }\n\n if (!toLoad.length) {\n checkConflicts();\n }\n }\n }", "function loadList() {\n return fetch(apiUrl)\n .then(function (response) {\n return response.json();\n })\n .then(function (json) {\n json.results.forEach(function (item) {\n let pokemon = {\n name: item.name,\n detailsUrl: item.url\n };\n add(pokemon);\n });\n })\n .catch(function (e) {\n console.error(e);\n });\n }", "function loadPosts(){\n $.ajax({\n type: \"GET\",\n url: \"/election/getVotablePosts\",\n cache: false,\n success: function(response){\n allPosts = response;\n response.forEach(loadThisPost);\n }\n });\n}", "function loaded()\n{\n\t$.ajax({\n\t\ttype: \"POST\",\n\t\tdatatype: \"json\",\n\t\turl: 'http://divie.herokuapp.com/requestFinalDiv',\n\t\tasync: false,\n\t\tsuccess: function(data){ \n\t\t\t$.each(data, function(k, v){\n\t\t\t\tResultList.push(\n\t\t\t\t\tnew Result(\n\t\t\t\t\t\tv.item_id, \n\t\t\t\t\t\tv.item_name, \n\t\t\t\t\t\tv.img_url\n\t\t\t\t\t)\n\t\t\t\t);\n\t\t\t});\n\t\t},\n\t\terror: function(){\n\t\t\talert(\"failed to load final result.\")\n\t\t}\n\t})\n}", "function loadList() {\n return fetch(apiUrl).then(function(response) {\n return response.json();\n }).then(function (json) {\n json.results.forEach(function(item) {\n let pokemon = {\n name: item.name,\n detailsUrl: item.url\n };\n addpoke(pokemon);\n });\n }).catch(function(e) {\n /* eslint-disable no-console */\n console.error(e);\n /* eslint-enable no-console */\n });\n }", "function loadPromotedProfiles( totalItems ){\r\n\r\n\r\n // Get profile data from the service\r\n\r\n $.get(\"/Ad\",function(data,status){\r\n\r\n var ads = data.Ad;\r\n\r\n for(i = 0; i < ads.length && i < totalItems; i++){\r\n\r\n var ad = ads[i];\r\n\r\n // Construct the div\r\n\r\n var div =\r\n \"<li>\"+\r\n \"\t<a href=\\\"/ad.jsp/?id=\"+ ad.id +\"\\\">\"+\r\n \" <img src=\\\"/image/?ad=\" + ad.id+\"&size=2\\\" height=\\\"50\\\" alt=\\\"\\\"></a>\" +\r\n \" \t\t<span class=\\\"searching\\\">\"+ad.category+\"</span>\"+\r\n \"\t\t\t<span class=\\\"title\\\">\"+ ad.title+\"</span>\"+\r\n \"\t</a>\"+\r\n \"</li>\";\r\n\r\n $(\"#promotedProfiles\").append(div);\r\n\r\n }\r\n\r\n });\r\n\r\n}", "function loaded(err, result) {\n\t if (errors.length) return;\n\n\t if (err) {\n\t errors.push({\n\t msg: err.responseText,\n\t details: [ t('save.status_code', { code: err.status }) ]\n\t });\n\t showErrors();\n\n\t } else {\n\t var loadMore = [];\n\t _.each(result.data, function(entity) {\n\t remoteGraph.replace(entity);\n\t toLoad = _.without(toLoad, entity.id);\n\n\t // Because loadMultiple doesn't download /full like loadEntity,\n\t // need to also load children that aren't already being checked..\n\t if (!entity.visible) return;\n\t if (entity.type === 'way') {\n\t loadMore.push.apply(loadMore,\n\t _.difference(entity.nodes, toCheck, toLoad, loadMore));\n\t } else if (entity.type === 'relation' && entity.isMultipolygon()) {\n\t loadMore.push.apply(loadMore,\n\t _.difference(_.map(entity.members, 'id'), toCheck, toLoad, loadMore));\n\t }\n\t });\n\n\t if (loadMore.length) {\n\t toLoad.push.apply(toLoad, loadMore);\n\t context.connection().loadMultiple(loadMore, loaded);\n\t }\n\n\t if (!toLoad.length) {\n\t checkConflicts();\n\t }\n\t }\n\t }", "function loadExternalData() {\n var loadFileParam = $location.search().loadfile;\n if (loadFileParam) {\n // block gui for long calls\n blockGui(true);\n Rest.callOther(\"loadableServerDataFiles\", \"loadFromFile\" + \"/\" + loadFileParam, initFromResponse);\n }\n }", "function loadUni()\r\n{\r\n \r\n httd = new XMLHttpRequest();\r\n httd.open(\"GET\",\"Education/getUniversity/\",true);\r\n httd.onload= lists;\r\n httd.send();\r\n}", "loadResources(callback) {\n\t\tthis.manager = new RC.LoadingManager();\n\t\tthis.objLoader = new RC.ObjLoader(this.manager);\n\t\tthis.imageLoader = new RC.ImageLoader(this.manager);\n\n\t\tlet urls = [];\n\t\t/*for(var x = 1; x <= 14; x++) {\n\t\t\turls.push(\"data/models/mitos/mito_\"+x+\"_out.obj\");\n\t\t}*/\n\t\t// Mitochondrias\n\t\tfor(var x = 1; x <= 15; x++) {\n\t\t\turls.push(\"data/models/mito_new/structure_id_\"+x+\".obj\");\n\t\t}\n\t\t// Endolysosomes\n\t\tvar end = 'structure_id_405.obj,structure_id_334.obj,structure_id_336.obj,structure_id_333.obj,structure_id_535.obj,structure_id_395.obj,structure_id_502.obj,structure_id_375.obj,structure_id_390.obj,structure_id_660.obj,structure_id_703.obj,structure_id_623.obj,structure_id_359.obj,structure_id_608.obj,structure_id_618.obj,structure_id_595.obj,structure_id_552.obj'\n\t\tfor (var s of end.split(\",\")) {\n\t\t\turls.push(\"data/models/endolysosomes_new/\"+s)\n\t\t}\n\t\t// Fusiform Vesicles\n\t\tvar fv = 'structure_id_816.obj,structure_id_815.obj,structure_id_818.obj,structure_id_822.obj,structure_id_820.obj,structure_id_821.obj'\n\t\tfor (var s of fv.split(\",\")) {\n\t\t\turls.push(\"data/models/fusiform_vesicles_new/\"+s)\n\t\t}\n\n\t\tconst makeRepeated = (arr, repeats) =>\n\t\t\t[].concat(...Array.from({ length: repeats }, () => arr));\n\n\t\tlet augmented_dataset = makeRepeated(urls, 5)\n\n\t\tfunction shuffleArray(array) {\n\t\t\tfor (var i = array.length - 1; i > 0; i--) {\n\t\t\t\tvar j = Math.floor(Math.random() * (i + 1));\n\t\t\t\tvar temp = array[i];\n\t\t\t\tarray[i] = array[j];\n\t\t\t\tarray[j] = temp;\n\t\t\t}\n\t\t}\n\t\tshuffleArray(urls)\n\t\tshuffleArray(augmented_dataset)\n\n\t\tthis.augmented_three_d_model_count = augmented_dataset.length;\n\t\tthis.three_d_model_count = urls.length;\n\t\tthis.resources = [];\n\n\t\t/*for (let i = 0; i < urls.length; ++i) {\n\t\t\tthis.resources[i] = false;\n\t\t\tthis.objLoader.load(urls[i], (obj) => {\n\t\t\t\tthis.resources[i] = obj;\n\n\t\t\t});\n\t\t}*/\n\n\t\tfor (let i = 0; i < augmented_dataset.length; ++i) {\n\t\t\tthis.resources[i] = false;\n\t\t\tthis.objLoader.load(augmented_dataset[i], (obj) => {\n\t\t\t\tthis.resources[i] = obj;\n\n\t\t\t});\n\t\t}\n\n\t\tlet wait = (function() {\n\t\t\tif (this.resources.every((el) => { return el !== false; })) {\n\t\t\t\tthis.setupObjectsInHemiSphere();\n\t\t\t\tcallback();\n\t\t\t} else {\n\t\t\t\tsetTimeout(wait, 500);\n\t\t\t}\n\t\t}).bind(this);\n\t\twait();\n\t}", "function loadData() {\n ul.innerHTML = \"\";\n taskList.loadFromJson(JSON.parse(localStorage.getItem(\"tasks\")) || []);\n taskList.getAllTasks().forEach(task => loadTask(task));\n}", "function populateFtn(list, getElementsObj, onDone) {\n if(!getElementsObj) {\n $log.info('get elements obj empty: ' + JSON.stringify(getElementsObj));\n onDone({\n nbrElems: 0,\n totalElems: 0\n });\n return;\n }\n\n objInst.state = 'pulling';\n getElementsObj.get()\n .then(function(batch) {\n $log.info('batch in populate: ' + JSON.stringify(getElementsObj.params));\n $log.info('batch total: ' + batch.total);\n $log.info('total no. of objects: ' + getElementsObj.params.total);\n $log.info('size of batch: ' + batch.data.length);\n var i = list.length;\n angular.forEach(batch.data, function(value) { \n this.push(iface.config.makeListElementFtn({\n \tapi: objInst.api,\n \telement: value,\n \tindex: parseInt(i)\n }));\n i++;\n }, list);\n\n $log.info('size of list: ' + JSON.stringify(list.length));\n //$log.info('elements : ' + JSON.stringify(list));\n\n objInst.state = 'done';\n if(onDone) {\n onDone({\n nbrElems: list.length,\n totalElems: batch.total,\n elems: list\n });\n }\n })\n .catch(function(err) {\n $log.info('error getting elements: ' + err);\n }); \t\t\n \t}", "function populateFtn(list, getElementsObj, onDone) {\n if(!getElementsObj) {\n $log.info('get elements obj empty: ' + JSON.stringify(getElementsObj));\n onDone({\n nbrElems: 0,\n totalElems: 0\n });\n return;\n }\n\n objInst.state = 'pulling';\n getElementsObj.get()\n .then(function(batch) {\n $log.info('batch in populate: ' + JSON.stringify(getElementsObj.params));\n $log.info('batch total: ' + batch.total);\n $log.info('total no. of objects: ' + getElementsObj.params.total);\n $log.info('size of batch: ' + batch.data.length);\n var i = list.length;\n angular.forEach(batch.data, function(value) { \n this.push(iface.config.makeListElementFtn({\n \tapi: objInst.api,\n \telement: value,\n \tindex: parseInt(i)\n }));\n i++;\n }, list);\n\n $log.info('size of list: ' + JSON.stringify(list.length));\n //$log.info('elements : ' + JSON.stringify(list));\n\n objInst.state = 'done';\n if(onDone) {\n onDone({\n nbrElems: list.length,\n totalElems: batch.total,\n elems: list\n });\n }\n })\n .catch(function(err) {\n $log.info('error getting elements: ' + err);\n }); \t\t\n \t}", "function launchAjax(listObj,reqData) {\n if (reqData != undefined) {\n $.each(reqData, function (key, value) {\n listObj.setRequestData(key,value);\n });\n }\n listObj.display();\n}", "function loadModels() { \n loadingManager.onLoad = function() {\n // console.log('Loading complete!');\n document.querySelector('#loadingScreen').classList.add( 'fade-out' );\n \n document.querySelector('#arrowsDiv').hidden = false;\n\n gameState.modelsLoaded = true;\n main();\n };\n\n \n const gltfLoader = new GLTFLoader(loadingManager);\n loadModelsList.forEach( model => {\n gltfLoader.load(model.url, (gltf) => {\n gltf.scene.traverse( function ( child ) {\n if ( child.isMesh ) {\n child.castShadow = true;\n child.receiveShadow = true;\n if ( child.material ) {\n child.material.metalness = 0;\n child.material.shininess = 0;\n }\n }\n } );\n model.gltf = gltf;\n });\n });\n}", "function loadItems() {\n\n //request all items\n $.get(\"/item\", function(data) {\n\n var items, numOfItems, id, status, content ;\n if (data['status'] === 1) {\n\n console.log(\"Failed to receive all items. Reason: \" + data['msg']);\n $(\"#errorMsg\").text(\"Failed to load items: \" + data['msg']);\n return;\n }\n\n $(\"#errorMsg\").html(\"&nbsp;\");\n $(\"#change_all_statuses_checkbox\").append(\"<input id='change_all_statuses' type='checkbox'>\" +\n \"<label for='change_all_statuses'>Mark all as complete</label>\");\n\n items = data['msg']['list'];\n\n nextId = data['msg']['nextId']; //If we now loaded n tasks from server, we want id assign to start with n+1\n numOfItems = items.length;\n\n for (var i = 0 ; i < numOfItems; ++i) {\n\n id = items[i]['id'];\n status = items[i]['status'];\n content = decodeURIComponent(items[i]['content']);\n\n appendNewItem(id, parseInt(status), content);\n }\n\n if (completedItems > 0) {\n $(\"#clear_completed\").html(\"Clear completed.\");\n $(\"#clear_completed\").show();\n }\n\n // display 'change all' button\n $('#change_all_statuses').prop('checked',false);\n\n if (numOfItems === 0 ) {\n $(\"#change_all_statuses\").hide();\n }\n else if (completedItems > 0 && completedItems === numOfItems) {\n $('#change_all_statuses').prop('checked',true);\n }\n });\n}", "function ontilesloaded() {\n\t//console.log('tiles loaded...so begin the loading of the weborb objects');\n\n\t//invoke weborb server\n\tinvokeServer(true);\n\n\n\t// mim data requests\n\t// TODO: enable these two function when we stop using the weborb web server. for now they are being handled by weborb\n\t//getMimLocations();\n\t//getMimPolylines();\n\n\t// transcom data requests\n\tgetTranscomLocations();\n\tgetTranscomPolylines();\n\n\t// wifi data requests\n\tgetWifiLocations();\n\tgetWifiPolylines();\n}", "_list() {\n this._listPromise().then((json) => {\n this._alerts = json;\n this._render();\n this._openOnLoad();\n }).catch(errorMessage);\n }" ]
[ "0.70509964", "0.6913766", "0.6645327", "0.6344031", "0.6333306", "0.6214303", "0.61855173", "0.6167771", "0.61478615", "0.6129641", "0.60915375", "0.60780466", "0.60684747", "0.60531116", "0.59800476", "0.5979282", "0.5971382", "0.597012", "0.59423804", "0.593376", "0.5926261", "0.5926261", "0.5873203", "0.5860178", "0.5835489", "0.5797146", "0.5787078", "0.5782932", "0.57781434", "0.57695764", "0.5751656", "0.57426727", "0.5739895", "0.5705411", "0.5704213", "0.5701464", "0.56959826", "0.56937355", "0.5679401", "0.56554884", "0.5654566", "0.56522405", "0.5649599", "0.5644431", "0.5628741", "0.5625774", "0.56149817", "0.5609619", "0.5601225", "0.55960345", "0.558295", "0.55758846", "0.5563212", "0.5547838", "0.5544544", "0.5543801", "0.55294645", "0.5527087", "0.55189717", "0.55189717", "0.55160004", "0.5512992", "0.5511339", "0.5500812", "0.5500017", "0.5496686", "0.5492958", "0.5489244", "0.54800737", "0.5473508", "0.5471251", "0.54691994", "0.5464974", "0.54614127", "0.54614127", "0.5459261", "0.5458998", "0.5451646", "0.54513276", "0.5441554", "0.54413694", "0.5440755", "0.5437528", "0.54265785", "0.5425326", "0.54045814", "0.5401584", "0.53999513", "0.5399492", "0.539835", "0.53972006", "0.53966826", "0.5391214", "0.53878343", "0.53878343", "0.5381805", "0.53812945", "0.5379817", "0.5370798", "0.5366281" ]
0.6631401
3
========================private functions ============================ this function called after main body loaded, or when partialView reloaded;
function renderPartialPostHandler(id){ console.log("renderPartialPostHandler | id: %s",id); var partial = partialList[id]; partial.setLoading(); viewRender(partial.route,null,function(content){ // console.log("renderPartialPostHandler callback: %s", content); console.log("renderPartialPostHandler | callback id: %s", id); partial.setLoaded(content); if(partial.refreshTime) { console.log("call autoRefresh for Id: %s", id); partial.autoRefresh(); } }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "afterRender() { }", "afterRender() { }", "function cb_contentLoaded(cb) {}", "onAfterRendering() {}", "function pageFullyLoaded () {}", "function partialLoaded(parentVM) {\n\t\t\tvm.super = vm;\n\t\t}", "function postRender(formmated){\r\n console.log(\"postRender\");\r\n var jObj = $(this);\r\n // adding handler for forms\r\n jObj.find(\"form\").bind(\"submit\",formSubmitHandler);\r\n\r\n // adding handler for partial view\r\n var id= jObj.attr(\"id\");\r\n console.log(\"postRender, id: %s\", id);\r\n if(id == defaultOptions.container){\r\n loadingPartial();\r\n }\r\n else if(id in partialList){\r\n loadingPartial(id);\r\n }\r\n\r\n }", "afterRenderContent() {\n this.logger.debug('After render content');\n\n if (this.model.getConfig('preferences').expandable) {\n this.view.contentExpander();\n }\n\n /**\n * Get page\n * @type {Page}\n */\n const page = this.controller.getContainment();\n\n page.observer.publish(page.eventManager.eventList.updateLoadedContent, this);\n }", "function _triggerAfterRender() {\n _trigger(docma.Event.Render, [docma.currentRoute]);\n if (_initialLoad) {\n _trigger(docma.Event.Ready);\n _initialLoad = false;\n }\n }", "function refreshRenderAddContent(){\n _model.render(function(htmlContent){\n window.frames[_iframe.attr(\"id\")].jQuery('body').empty().append(htmlContent).ready(function(){\n _layoutFunctions.afterRender(function(){\n if(reactivateInspectionToolCallback)\n {\n reactivateInspectionToolCallback();\n }\n });\n\n // If splittedRegionContent array is available - iterate over the array and replace the sample content with actual content\n if (splittedRegionContent.length > 0) {\n assignWidgetContent();\n }\n });\n });\n }", "ready() {\n super.ready();\n\n afterNextRender(this, function() {});\n }", "ready() {\n super.ready();\n\n afterNextRender(this, function() {});\n }", "ready() {\n super.ready();\n\n afterNextRender(this, function() {});\n }", "postRender()\n {\n super.postRender();\n }", "_afterRender () {\n this.adjust();\n }", "function onViewLoaded() {\n try {\n\n // Remove the event handler once the function is excuted.\n $evt.removeEventHandler($display, \"start\", onViewLoaded);\n // Get the page object\n var page = $display.getItem();\n // Insert the Edit button besides the page template dropdown\n $JQ(\"<div id='AlchemyPluginsEditTemplatesFromPagePageEditButton' class='editTemplateFromPagePluginButton editButton pageTemplate' title='Edit'><span class='text'>&nbsp;</span></div>\").insertAfter('#PageTemplate')\n // Function to be execte on the Edit Button click\n $JQ(\"#AlchemyPluginsEditTemplatesFromPagePageEditButton\").click(function () {\n // Execute the open command\n var pageTemplateId = page.getPageTemplateId();\n var s = new Tridion.Cme.Selection();\n s.addItem(pageTemplateId);\n $commands.executeCommand(\"Open\", s);\n });\n\n }\n catch (error) {\n $messages.registerError(\"Alchemy Plugin Error | EditTemplatesFromPage: \", error);\n }\n }", "function mainLoaded() {\n if (typeof(executeOnContentLoad) == \"function\") {\n if (contentLoadDestination && location.hash != contentLoadDestination) return;//wait til we are on the correct page\n var fn = executeOnContentLoad;\n executeOnContentLoad = null;\n contentLoadDestination = null;\n fn();\n }\n }", "onAfterLoadPage(data_obj) {\n\t\t//TODO: Override this as needed;\n\t}", "onAfterLoadPage(data_obj) {\n\t\t//TODO: Override this as needed;\n\t}", "function lateRender() {\n\t\tsetTimeout( function() { // IE7 needs this so dimensions are calculated correctly\n\t\t\t\t\tif (!currentView.start && bodyVisible()) { // !currentView.start makes sure this never happens more than once\n\t\t\t\t\t\trenderView();\n\t\t\t\t\t}\n\t\t\t\t}, 0);\n\t}", "function onBeforeInit() {\n \t\tvar i,\n item,\n objects = [kendoLayouts, kendoViews],\n htmlBuffer = [];\n\n \t\tfor (i=0; i<objects.length; i++) {\n \t\t\tfor (item in objects[i]) {\n \t\t\t\tif (objects[i].hasOwnProperty(item) && objects[i][item].hasOwnProperty('html')) {\n \t\t\t\t\thtmlBuffer.push(objects[i][item].html);\n \t\t\t\t}\n \t\t\t}\n \t\t}\n\n \t\t$(document.body).prepend(htmlBuffer.join(''));\n \t}", "function lateRender() {\n\t\tsetTimeout(function() { // IE7 needs this so dimensions are calculated correctly\n\t\t\tif (!currentView.start && bodyVisible()) { // !currentView.start makes sure this never happens more than once\n\t\t\t\trenderView();\n\t\t\t}\n\t\t},0);\n\t}", "function lateRender() {\n\t\tsetTimeout(function() { // IE7 needs this so dimensions are calculated correctly\n\t\t\tif (!currentView.start && bodyVisible()) { // !currentView.start makes sure this never happens more than once\n\t\t\t\trenderView();\n\t\t\t}\n\t\t},0);\n\t}", "function lateRender() {\n\t\tsetTimeout(function() { // IE7 needs this so dimensions are calculated correctly\n\t\t\tif (!currentView.start && bodyVisible()) { // !currentView.start makes sure this never happens more than once\n\t\t\t\trenderView();\n\t\t\t}\n\t\t},0);\n\t}", "function lateRender() {\n\t\tsetTimeout(function() { // IE7 needs this so dimensions are calculated correctly\n\t\t\tif (!currentView.start && bodyVisible()) { // !currentView.start makes sure this never happens more than once\n\t\t\t\trenderView();\n\t\t\t}\n\t\t},0);\n\t}", "function lateRender() {\n\t\tsetTimeout(function() { // IE7 needs this so dimensions are calculated correctly\n\t\t\tif (!currentView.start && bodyVisible()) { // !currentView.start makes sure this never happens more than once\n\t\t\t\trenderView();\n\t\t\t}\n\t\t},0);\n\t}", "_triggerLoaded() {\n\t if (this._alreadyLoaded) {\n\t // Do not trigger event twice\n\t this._triggerUpdated();\n\t return;\n\t }\n\t this._alreadyLoaded = true;\n\t const registry = storage.getRegistry(this._instance);\n\t const events = registry.events;\n\t events.fire('view-loaded', this);\n\t // Trigger onLoad event for child view\n\t if (this.onLoad !== null) {\n\t const onLoad = this.onLoad;\n\t this.onLoad = null;\n\t onLoad();\n\t }\n\t }", "function edgtfOnDocumentReady() {\n edgtfHeaderBehaviour();\n edgtfSideArea();\n edgtfSideAreaScroll();\n edgtfFullscreenMenu();\n edgtfInitMobileNavigation();\n edgtfMobileHeaderBehavior();\n edgtfSetDropDownMenuPosition();\n edgtfDropDownMenu(); \n edgtfSearch();\n }", "function _onPageLoadOuter() {\n // Back-forward navigation can add nodes: create a clean slate.\n removeAddedNodes(); // defined by application.\n onPageLoad(); // defined by application.\n}", "function onPageLoaded() {\n}", "function eltdfOnDocumentReady() {\n eltdfHeaderBehaviour();\n eltdfSideArea();\n eltdfSideAreaScroll();\n eltdfFullscreenMenu();\n eltdfInitDividedHeaderMenu();\n eltdfInitMobileNavigation();\n eltdfMobileHeaderBehavior();\n eltdfSetDropDownMenuPosition();\n eltdfDropDownMenu();\n eltdfSearch();\n eltdfVerticalMenu().init();\n }", "function eltdfOnWindowLoad() {\n\t eltdfWooCommerceStickySidebar().init();\n\t eltdfInitButtonLoading();\n eltdfInitProductListMasonryShortcode();\n }", "postRenderSetup() {\n this.el.querySelectorAll('a.addBoxerLink').forEach((link) => {\n link.onclick = () => {\n this.callbacks.closeSidebar();\n this.callbacks.createNewFighter(link.id);\n }\n });\n\n this.el.querySelector('#directoryReport').onclick = () => {\n this.callbacks.closeSidebar();\n this.callbacks.directoryReport();\n };\n\n this.el.querySelector('#assessmentReport').onclick = () => {\n this.callbacks.closeSidebar();\n this.callbacks.assessmentReport();\n }\n }", "function afterLoading(){\n\t\t\tupdatePageInfo();\n\t\t}", "function viewRenderComplete() {\n $container.trigger(topologyConstants.events.viewRenderComplete, {}); // Private Event\n }", "postPageLoadActions() {\n\t\tmenu_manager.renderAllMenus();\n\t\tinitFeedbackCapture();\n\t\tloadCurrentUserProfilePicture();\n\t\trenderAppLogo();\n\t\ttoggleUserRoleVisibility();\n\t\tdoAfterPageLoadActions();\n\t}", "function viewDidUpdate() {\n // stub\n }", "function init() {\n if ($('.detail-page').length > 0) {\n renderLoader();\n setArticleParams();\n getArticle();\n bindEvents();\n }\n }", "function afterLoadedInit(){\r\n\tSTATE = STATE_VIEW;\r\n\t//add input and findButton for search by id\r\n\tvar input = createInput( idActorInput, 'id' );\r\n\tvar button = createButton( labelActorsGetButton, idActorsGetButton, 'id' );\r\n\t$( idActorInputDom ).html( input + button );\r\n\t//Make empty table with headers\r\n\t$( idActorsListDom )\t\t\t\t\t\t\t\t.html('<table></table>');\r\n\t$( idActorsListDom ).find('table')\t\t\t\t\t.attr('id',idTableActors);\r\n\t$( hashSelector(idTableActors) )\t\t\t\t\t.append('<thead></thead><tbody></tbody>');\r\n\t$( hashSelector(idTableActors) + ' thead' )\t\t\t.append('<tr></tr>');\r\n\t$( hashSelector(idTableActors) + ' thead tr' )\t\t.append('<th>'+firstColumnName+'</th><th>'+secondColumnName+'</th>');\r\n\t//add Delete Edit Btns\r\n\t$( hashSelector(idTableActors) +' tr th:last' ).after(\r\n\t\t\t '<th>'\t\t+ createButton(labelDeleteActorButton, \tidDeleteActorButton, \t'id') +\t'</th>' +\r\n\t\t\t '<th>'\t\t+ createButton(labelEditActorButton, \tidEditActorButton, \t\t'id') +\t'</th>'\r\n\t\t);\r\n}", "async afterLoad () {\n }", "_changed() {\n reload_articles_on_drawer_close();\n }", "function handleRender() {\n\t view._isRendered = true;\n\t triggerDOMRefresh();\n\t }", "function doAfterPageLoadActions() {\n\t//TODO: Override this\n}", "function afterRenderActions() {\n var section = $(SECTION_ACTIVE_SEL);\n\n section.addClass(COMPLETELY);\n\n lazyLoad(section);\n playMedia(section);\n\n if (options.scrollOverflow) {\n options.scrollOverflowHandler.afterLoad();\n }\n\n if (isDestinyTheStartingSection()) {\n $.isFunction(options.afterLoad) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\n }\n\n $.isFunction(options.afterRender) && options.afterRender.call(container);\n }", "function initPage() {\n $.get('/api/headlines?saved=true').done((data) => {\n articleContainer.empty();\n\n if (data && data.length > 0) {\n renderArticles(data);\n\n // Activate tooltips for the action buttons.\n $('[data-toggle=\"tooltip\"]').tooltip();\n } else {\n renderEmpty();\n }\n });\n }", "function afterRenderActions(){\r\n var section = $(SECTION_ACTIVE_SEL);\r\n\r\n section.addClass(COMPLETELY);\r\n\r\n lazyLoad(section);\r\n playMedia(section);\r\n\r\n if(options.scrollOverflow){\r\n options.scrollOverflowHandler.afterLoad();\r\n }\r\n\r\n if(isDestinyTheStartingSection()){\r\n $.isFunction( options.afterLoad ) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\r\n }\r\n\r\n $.isFunction( options.afterRender ) && options.afterRender.call(container);\r\n }", "function eltdfOnWindowLoad() {\n eltdfDropDownMenu();\n eltdfSetDropDownMenuPosition();\n eltdfInitDividedHeaderMenu();\n }", "onBeforeRendering() {}", "function qodeOnWindowLoad() {\n qodeInitElementorCoverBoxes();\n }", "function initPage() {\n $.get('/api/headlines?saved=false').done((data) => {\n articleContainer.empty();\n if (data && data.length > 0) {\n renderArticles(data);\n\n // Activate tooltips for the action buttons.\n $('[data-toggle=\"tooltip\"]').tooltip();\n } else {\n renderEmpty();\n }\n });\n }", "function afterRenderActions(){\r\n var section = $(SECTION_ACTIVE_SEL)[0];\r\n\r\n addClass(section, COMPLETELY);\r\n\r\n lazyLoad(section);\r\n lazyLoadOthers();\r\n playMedia(section);\r\n\r\n if(options.scrollOverflow){\r\n options.scrollOverflowHandler.afterLoad();\r\n }\r\n\r\n if(isDestinyTheStartingSection() && isFunction(options.afterLoad) ){\r\n fireCallback('afterLoad', {\r\n activeSection: section,\r\n element: section,\r\n direction: null,\r\n\r\n //for backwards compatibility callback (to be removed in a future!)\r\n anchorLink: section.getAttribute('data-anchor'),\r\n sectionIndex: index(section, SECTION_SEL)\r\n });\r\n }\r\n\r\n if(isFunction(options.afterRender)){\r\n fireCallback('afterRender');\r\n }\r\n }", "_firstRendered() { }", "onContentLoading() {\r\n // Stub\r\n }", "function afterRenderActions(){\r\n var section = $(SECTION_ACTIVE_SEL)[0];\r\n\r\n addClass(section, COMPLETELY);\r\n\r\n lazyLoad(section);\r\n playMedia(section);\r\n\r\n if(options.scrollOverflow){\r\n options.scrollOverflowHandler.afterLoad();\r\n }\r\n\r\n if(isDestinyTheStartingSection() && isFunction(options.afterLoad) ){\r\n fireCallback('afterLoad', {\r\n activeSection: null,\r\n element: section,\r\n direction: null,\r\n\r\n //for backwards compatibility callback (to be removed in a future!)\r\n anchorLink: section.getAttribute('data-anchor'),\r\n sectionIndex: index(section, SECTION_SEL)\r\n });\r\n }\r\n\r\n if(isFunction(options.afterRender)){\r\n fireCallback('afterRender');\r\n }\r\n }", "function on_dom_content_loaded () {\n //remove this handler\n document.removeEventListener(\"DOMContentLoaded\", on_dom_content_loaded, false);\n\n //call the onLoad function\n Survana.Workflow.OnPageLoad();\n }", "function afterRenderActions() {\n var section = $(SECTION_ACTIVE_SEL)[0];\n addClass(section, COMPLETELY);\n lazyLoad(section);\n lazyLoadOthers();\n playMedia(section);\n\n if (options.scrollOverflow) {\n options.scrollOverflowHandler.afterLoad();\n }\n\n if (isDestinyTheStartingSection() && isFunction(options.afterLoad)) {\n fireCallback('afterLoad', {\n activeSection: section,\n element: section,\n direction: null,\n //for backwards compatibility callback (to be removed in a future!)\n anchorLink: section.getAttribute('data-anchor'),\n sectionIndex: index(section, SECTION_SEL)\n });\n }\n\n if (isFunction(options.afterRender)) {\n fireCallback('afterRender');\n }\n }", "function afterRenderActions(){\r\n var section = $(SECTION_ACTIVE_SEL);\r\n\r\n section.addClass(COMPLETELY);\r\n\r\n if(options.scrollOverflowHandler.afterRender){\r\n options.scrollOverflowHandler.afterRender(section);\r\n }\r\n lazyLoad(section);\r\n playMedia(section);\r\n options.scrollOverflowHandler.afterLoad();\r\n \r\n if(isDestinyTheStartingSection()){\r\n $.isFunction( options.afterLoad ) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\r\n }\r\n\r\n $.isFunction( options.afterRender ) && options.afterRender.call(container);\r\n }", "function afterRenderActions(){\r\n var section = $(SECTION_ACTIVE_SEL);\r\n\r\n section.addClass(COMPLETELY);\r\n\r\n if(options.scrollOverflowHandler.afterRender){\r\n options.scrollOverflowHandler.afterRender(section);\r\n }\r\n lazyLoad(section);\r\n playMedia(section);\r\n options.scrollOverflowHandler.afterLoad();\r\n \r\n if(isDestinyTheStartingSection()){\r\n $.isFunction( options.afterLoad ) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\r\n }\r\n\r\n $.isFunction( options.afterRender ) && options.afterRender.call(container);\r\n }", "render() {\n this.notify('initial-load', {});\n /**\n * Used to load context menu\n */\n this.trigger('load');\n this.notify('initial-end', {});\n this.renderElements();\n this.renderComplete();\n }", "render() {\n this.notify('initial-load', {});\n /**\n * Used to load context menu\n */\n this.trigger('load');\n this.notify('initial-end', {});\n this.renderElements();\n this.renderComplete();\n }", "render() {\n this.notify('initial-load', {});\n /**\n * Used to load context menu\n */\n this.trigger('load');\n this.notify('initial-end', {});\n this.renderElements();\n this.renderComplete();\n }", "beforeRender() { }", "function afterRenderActions(){\n var section = $(SECTION_ACTIVE_SEL)[0];\n\n addClass(section, COMPLETELY);\n\n lazyLoad(section);\n lazyLoadOthers();\n playMedia(section);\n\n if(options.scrollOverflow){\n options.scrollOverflowHandler.afterLoad();\n }\n\n if(isDestinyTheStartingSection() && isFunction(options.afterLoad) ){\n fireCallback('afterLoad', {\n activeSection: section,\n element: section,\n direction: null,\n\n //for backwards compatibility callback (to be removed in a future!)\n anchorLink: section.getAttribute('data-anchor'),\n sectionIndex: index(section, SECTION_SEL)\n });\n }\n\n if(isFunction(options.afterRender)){\n fireCallback('afterRender');\n }\n }", "function afterRenderActions(){\n var section = $(SECTION_ACTIVE_SEL)[0];\n\n addClass(section, COMPLETELY);\n\n lazyLoad(section);\n lazyLoadOthers();\n playMedia(section);\n\n if(options.scrollOverflow){\n options.scrollOverflowHandler.afterLoad();\n }\n\n if(isDestinyTheStartingSection() && isFunction(options.afterLoad) ){\n fireCallback('afterLoad', {\n activeSection: section,\n element: section,\n direction: null,\n\n //for backwards compatibility callback (to be removed in a future!)\n anchorLink: section.getAttribute('data-anchor'),\n sectionIndex: index(section, SECTION_SEL)\n });\n }\n\n if(isFunction(options.afterRender)){\n fireCallback('afterRender');\n }\n }", "function afterRenderActions(){\n var section = $(SECTION_ACTIVE_SEL)[0];\n\n addClass(section, COMPLETELY);\n\n lazyLoad(section);\n lazyLoadOthers();\n playMedia(section);\n\n if(options.scrollOverflow){\n options.scrollOverflowHandler.afterLoad();\n }\n\n if(isDestinyTheStartingSection() && isFunction(options.afterLoad) ){\n fireCallback('afterLoad', {\n activeSection: section,\n element: section,\n direction: null,\n\n //for backwards compatibility callback (to be removed in a future!)\n anchorLink: section.getAttribute('data-anchor'),\n sectionIndex: index(section, SECTION_SEL)\n });\n }\n\n if(isFunction(options.afterRender)){\n fireCallback('afterRender');\n }\n }", "[$onContentLoad](e) {\n this.activeScene = undefined;\n this.activeEntity = undefined;\n this.activeRenderer = undefined;\n this.needsReload = false;\n }", "function doSomethingAfterRendering(){\n displayLoading() // 로딩화면 보여주기\n fetchServer(); // 서버에서 데이터 가져오기\n }", "function onInitialFrameLoad(){\n if(contentEditCriteria.assetType == \"shared\")\n {\n // show the warning message for shared asset\n var warning = 'This is a shared Asset. Your edits will take effect on all pages that use this Asset.';\n var $topPlaceHolder = $contentFrameElem(\"#perc-content-edit-content-top-placeholder\");\n $topPlaceHolder.addClass(\"perc_shared_asset_edit_warning perc-asset-edit-info-line\");\n $topPlaceHolder.html(warning);\n $topPlaceHolder.show();\n \n // add the folder path for an existing asset\n if (assetId != undefined && assetId != '')\n {\n var pathField = '<label for=\"perc-content-edit-meta-data-item_folder_path\" >Folder path:</label> <br/>' + \n '<div id=\"perc-content-edit-meta-data-item_folder_path\" class=\"datadisplay\">' +\n contentEditCriteria.folderPath + '</div> <br/>';\n\n $contentFrameElem(\"#perc-content-edit-meta-data-top-placeholder\").html(pathField);\n $contentFrameElem(\"#perc-content-edit-metadata-panel\").show();\n //Render site impact for the asset.\n $contentFrameElem(\"#perc-site-impact-panel\").show();\n $.PercSiteImpactView.renderSiteImpact(assetId, $.PercSiteImpactView.ITEM_TYPE_ASSET, $contentFrameElem(\"#perc-site-impact-panel\"));\n }\n }\n }", "function eltdOnWindowLoadHeaderBehaviour() {\n }", "requestView(){\t\t\n\t\tthis.trigger('requestView');\n\t}", "function postInit()\n\t{\n\n\t\tproblem = app.problemList.at(app.curProbIndex);\n\n\t\t// Set some global variables (messy)\n\t\tview.showingSolution = false;\n\n\t\t// Attach to the result handler (this can't happen earlier, since it is defined after the view)\n\t\tview.initResultHandler(problem);\n\n\t\t// Layout init\n\t\tview.initLayout(problem);\n\n\t\t// Set the problem status appropriately\n\t\thandleLockouts();\n\n\t\t// Init any modules that require it\n\t\tview.initFocusManager();\n\t\tview.stepModuleInit(problem);\n\t\tview.initHelp(problem);\t\n\t\n\t\t// Open steps if required -- move to an answerType-based plugin system!\n\t\tmodeSpecific();\n\n\t\tif (app.FunctionalTestMode) {\n\t\t\tapp.globalReadyForFunctionalTest();\n\t\t}\n\n\t\tapp.clearLoadingBox();\n\t}", "function handleRender() {\n view._isRendered = true;\n triggerDOMRefresh();\n }", "function handleRender() {\n view._isRendered = true;\n triggerDOMRefresh();\n }", "function loadPartials() {\n\t\t$allPost.load( \"partials/all.html\" );\n\t}", "function initContent() {\n var msHide = document.querySelectorAll('.ms-hide');\n\n /**\n * Place the Yellow ribbon after the header.\n */\n $('#s4-workspace').prepend($('#DeltaPageStatusBar'));\n\n if (msHide.length > 0) {\n /**\n * Hide all right section web parts that are marked as \"hidden\".\n */\n if ($('.ms-hide').closest('.right-section')) {\n $('.right-section .ms-hide').parent().hide();\n }\n checkContentTypes();\n checkOrgChartZone();\n checkGatewayPage();\n }\n\n adjustArticleImageBlock();\n adjustWireStories();\n collapsibleList();\n customCheckboxes();\n howDoI();\n articleComments();\n startMyVMSNet();\n startUserControls();\n\n /**\n * Window Load Events.\n */\n window.addEventListener('load', function () {\n introText();\n wireStories();\n wireCatagory();\n updateMoreSearchText();\n });\n }", "function onLoaded()\n\t{\n\t\twindow.initExhibitorsList();\n\t\twindow.initFloorPlans();\n\t\twindow.initConciege();\n\t\twindow.initAmenities();\n\t\twindow.initVisas();\n\t}", "function initialize(){\n replaceContent(baseContent, homeContainer);\n}", "function afterRenderActions(){\n var section = $(SECTION_ACTIVE_SEL);\n\n section.addClass(COMPLETELY);\n\n if(options.scrollOverflowHandler.afterRender){\n options.scrollOverflowHandler.afterRender(section);\n }\n lazyLoad(section);\n playMedia(section);\n options.scrollOverflowHandler.afterLoad();\n \n if(isDestinyTheStartingSection()){\n $.isFunction( options.afterLoad ) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\n }\n\n $.isFunction( options.afterRender ) && options.afterRender.call(container);\n }", "function afterRenderActions(){\n var section = $(SECTION_ACTIVE_SEL);\n\n section.addClass(COMPLETELY);\n\n if(options.scrollOverflowHandler.afterRender){\n options.scrollOverflowHandler.afterRender(section);\n }\n lazyLoad(section);\n playMedia(section);\n options.scrollOverflowHandler.afterLoad();\n \n if(isDestinyTheStartingSection()){\n $.isFunction( options.afterLoad ) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\n }\n\n $.isFunction( options.afterRender ) && options.afterRender.call(container);\n }", "_didLoad () {\n // Clear the height cache\n this._lastHeight = 0\n \n // Post-process content\n this._unescapeImageURLs()\n \n // Setup event listeners\n this._addHeightListener('details', 'toggle')\n this._addHeightListener('img, svg', 'load')\n }", "ready() {\n const that = this;\n\n super.ready();\n\n that._isParentPositionStatic = window.getComputedStyle(that.parentElement || document.querySelector('body')).position === 'static';\n that._handleSelector(that.selector);\n\n if (that.visible) {\n that._applyPosition();\n }\n\n that._handleEventListeners();\n that._handleResize();\n\n that.value = that.$.content.innerHTML = that.value ? that.value : that.innerHTML;\n that._handleTemplate();\n }", "onViewParsed() {\n\n }", "onPageReady () {}", "function init()\n {\n $(document).on(\"loaded:everything\", runAll);\n }", "function eltdfOnDocumentReady() {\n eltdfInitQuantityButtons();\n eltdfInitSelect2();\n\t eltdfInitPaginationFunctionality();\n\t eltdfReinitWooStickySidebarOnTabClick();\n eltdfInitSingleProductLightbox();\n\t eltdfInitSingleProductImageSwitchLogic();\n eltdfInitProductListCarousel();\n }", "function loadMainView() {\n let body = document.getElementsByTagName('body')[0];\n let root = webComponents.getComponentByName('adminui-root', 'root');\n let components = webComponents.components;\n webComponents.loadGroup(components.sidebar, root.sidebarTarget, context);\n webComponents.loadGroup(components.topbar, root.topbarTarget, context);\n webComponents.loadGroup(components.dashboard_page, root.contentTarget, context);\n webComponents.loadGroup(components.logout_modal, body, context);\n }", "function loadMainView() {\n let body = document.getElementsByTagName('body')[0];\n let root = webComponents.getComponentByName('adminui-root', 'root');\n let components = webComponents.components;\n webComponents.loadGroup(components.sidebar, root.sidebarTarget, context);\n webComponents.loadGroup(components.topbar, root.topbarTarget, context);\n webComponents.loadGroup(components.dashboard_page, root.contentTarget, context);\n webComponents.loadGroup(components.logout_modal, body, context);\n }", "onEnterCompleted() {\n //console.log('enterCompleted',this.id);\n // Custom code should be added before super.\n\n this.menu = new Menu();\n\n if(window.AUI && Liferay) {\n this.liferayUI = new LiferayUI();\n }\n\n\n\n if($('.tabs').length) {\n this.tabs = new Tabs(this.view);\n }\n if($('#map').length) {\n this.contactMap = new Map(this.view);\n }\n\n // FAKE SELECT\n if($('[data-fake-select]').length) {\n const fakeselect = this.view.querySelectorAll('[data-fake-select]');\n this.fakeselect = [];\n for (let i = 0; i < fakeselect.length; i++) {\n let $el = fakeselect[i];\n this.fakeselect[i] = new FakeSelect('FakeSelect-' + i, $el);\n }\n // this.fakeselect = new fakeSelect(\n // this.view.querySelector('[data-fake-select]'),\n // //this.mobileSelectChange.bind(this),\n // ).init();\n }\n\n // DROPDOWN\n if ($('.js-dropdown').length) {\n const dropdowns = this.view.querySelectorAll('.js-dropdown');\n this.dropdowns = [];\n for (let i = 0; i < dropdowns.length; i++) {\n let $el = dropdowns[i];\n this.dropdowns[i] = new Dropdown('dropdown-' + i, $el);\n }\n }\n\n // OWLGALLERY\n //if($('.owl-gallery')) this.carousel = new owlCarousel();\n\n\n\n this.resize();\n\n //$('header .breadcrumbs').html($(this.view).find('.breadcrumbs__mobile ul').html());\n //$('html title').html($('.barba-container').attr('data-title')+'');\n if($('body .wysiwyg iframe').length) $('body .wysiwyg iframe').height(($('body .wysiwyg iframe').width()*9)/16);\n }", "function ViewController(){}//Extends Controller (at bottom of page).", "function afterRenderActions(){\n var section = $(SECTION_ACTIVE_SEL);\n\n section.addClass(COMPLETELY);\n\n if(options.scrollOverflowHandler.afterRender){\n options.scrollOverflowHandler.afterRender(section);\n }\n lazyLoad(section);\n playMedia(section);\n\n $.isFunction( options.afterLoad ) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\n $.isFunction( options.afterRender ) && options.afterRender.call(container);\n }", "function afterRenderActions(){\n var section = $(SECTION_ACTIVE_SEL);\n\n section.addClass(COMPLETELY);\n\n if(options.scrollOverflowHandler.afterRender){\n options.scrollOverflowHandler.afterRender(section);\n }\n lazyLoad(section);\n playMedia(section);\n\n $.isFunction( options.afterLoad ) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\n $.isFunction( options.afterRender ) && options.afterRender.call(container);\n }", "function onPageReady() {\n $scope.showRequiredFields = 'false';\n $scope.free = \"true\";\n $scope.page = \"details\";\n\n // Set initial values for form\n window.scrollTo(0, 0);\n }", "function init(){\n recipeView.addhandlerRender(controlRecipes);\n searchView.addhandlerRender(controlSearchResults);\n paginationView.addhandlerRender(controlPagination);\n recipeView.addhandlerUpdateServings(controlServings);\n recipeView.addhandlerBookmark(controlBookmarks);\n bookMarksView.addhandlerRender(loadBookmarks);\n addRecipeView.addhandlerupload(addrecipe)\n console.log('hello');\n}", "render() {\r\n document.body.insertBefore(this.element, document.querySelector('script'));\r\n\r\n this.append(this.PageContent.element, [this.NewsList, this.Footer]);\r\n this.append(this.Sidebar.element, [this.SidebarTitle, this.SourcesList]);\r\n this.append(this.element, [this.Spinner, this.PageContent, this.Sidebar, this.ToggleBtn]);\r\n }", "function eltdOnDocumentReadyHeader() {\n eltdInitMobileNavigation();\n eltdSetDropDownMenuPosition();\n eltdDropDownMenu();\n eltdVerticalMenu().init();\n }", "function ajax_Load() {\n //$(\".consoleLogOutput\").append('<div class=\"consoleLog_helm\">ajax_Load() event starting.</div>');\n \n if (helm.alreadyInitialized && helm.RefreshHelmDataAfterUpdatePanelPostBack) {\n helm.jQueryBindEvents();\n helm.Initialize(true); //true -> because this is after ajax request\n } else {\n //reset the refresh overrides\n helm.alreadyInitialized = true;\n helm.RefreshHelmDataAfterUpdatePanelPostBack = true;\n }\n \n }", "renderPreloadView() {\n const containerElements = document.getElementsByClassName(`${PRELOAD_CONTAINER_PREFIX}`);\n if (containerElements && containerElements.length) {\n this.angularUtilService.createAngularComponentAppendToDom(this._preloadComponent, containerElements[0], true);\n }\n }", "ready() {\r\n\t\t// Override this\r\n\t\tthis.updateTitle();\r\n\t}", "function page_loaded() {\n post_load_setup();\n}", "afterShowLeafPage() {\n\t}" ]
[ "0.6653066", "0.6653066", "0.6539719", "0.6529072", "0.64586747", "0.64420825", "0.63821435", "0.63804346", "0.637268", "0.6357889", "0.6352046", "0.6352046", "0.6352046", "0.63189566", "0.6303454", "0.6281305", "0.6254545", "0.62267", "0.62267", "0.6222498", "0.6221601", "0.6214088", "0.6214088", "0.6214088", "0.6214088", "0.6214088", "0.6174793", "0.6158698", "0.61468446", "0.61358845", "0.6124699", "0.6118196", "0.6083679", "0.60819143", "0.60488963", "0.6015271", "0.59922916", "0.5959446", "0.5946065", "0.59404814", "0.5926602", "0.5900079", "0.58998036", "0.5898548", "0.5891921", "0.58867437", "0.58806276", "0.5874867", "0.5872214", "0.5867726", "0.5862554", "0.586099", "0.58564603", "0.5843581", "0.5841735", "0.5841516", "0.58399194", "0.58399194", "0.583616", "0.583616", "0.583616", "0.5834732", "0.5833937", "0.5833937", "0.5833937", "0.5826747", "0.58235097", "0.5819987", "0.58197916", "0.5817075", "0.5804213", "0.5803381", "0.5803381", "0.5803187", "0.5802667", "0.5801611", "0.5795971", "0.57904905", "0.57904905", "0.57843775", "0.5779815", "0.5777997", "0.57663333", "0.57632804", "0.5761616", "0.5738535", "0.5738535", "0.5732325", "0.57312226", "0.5721637", "0.5721637", "0.5721316", "0.5720724", "0.57191515", "0.5718105", "0.5717529", "0.5716229", "0.571608", "0.57116693", "0.5710647" ]
0.6131216
30
handle custom form submission
function formSubmitHandler(event){ console.log("formSubmitHandler"); event.preventDefault(); var form = event.target || event.srcElement; var route = getFormRoute(form); var method = form.method.toLowerCase(); switch(method){ case "get": location.hash = getHashPath(route); break; case "post": case "put": // set cancelHashChange to skip the renderView on hashChange and // then proccess it manually. cancelHashChange = true; location.hash = getHashPath(route); sessionStorage["currentPostParams"] = JSON.stringify(route.postParams); setTimeout(function(){ viewRender(route); cancelHashChange = false; },0); case "path": case "delete": case "option": default: break; } return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function submitCustom(form) {\n let data = {};\n data[\"title\"] = form.customTitle.value;\n data[\"ldap\"] = form.customLdap.value;\n data[\"description\"] = form.customDescription.value;\n data[\"reason\"] = form.customReason.value;\n\n // Check for empty title or ldap\n let hasError = false;\n if (data[\"title\"] === \"\") {\n form.customTitle.parentElement.parentElement.classList.add(\"has-error\");\n hasError = true;\n } else {\n form.customTitle.parentElement.parentElement.classList.remove(\"has-error\");\n }\n if (data[\"ldap\"] === \"\") {\n form.customLdap.parentElement.parentElement.classList.add(\"has-error\");\n hasError = true;\n } else {\n form.customLdap.parentElement.parentElement.classList.remove(\"has-error\");\n }\n\n if (hasError) {\n presentAlert(\"alert-danger\", \"Please fill in the fields highlighted in red.\");\n } else {\n setVisible(\"customLoading\");\n $.post(\"api/create\", data, validateCustom);\n }\n\n return false;\n}", "function formSubmitted(e) {\n\n var action = e.target.getAttribute('action');\n\n if (action[0] === '#') {\n e.preventDefault();\n trigger('POST', action, e, serialize(e.target));\n }\n }", "formSubmit() {\n if(this.get('disableSubmit')) { return; }\n \n this.sendAction('submitUserContact', {\n contactType: this.get('selectedContactType'),\n name: this.get('nameValue'),\n fromEmail: this.get('emailValue'),\n content: this.get('commentValue')\n });\n\n if(this.attrs.onContactSubmit) {\n this.attrs.onContactSubmit();\n }\n }", "function handleFormSubmission(event) {\n //this preventDefault tells the DOM\n // when you click on a button on a form or div that click propogates up each element has a default action\n // prevent default prevents the default action of the element\n // event.stopPropagation - prevents the event from going up the chain\n event.preventDefault();\n // console.log(event.target.elements);\n const {elements} = event.target;\n const class_name = elements[\"name\"].value;\n const date_started = elements[\"date_started\"].value;\n const date_ended = elements[\"date_ended\"].value;\n onSubmit({class_name, date_started, date_ended});\n}", "handleSubmit(event){\r\n event.preventDefault(); // stop the form from submitting\r\n const fields = event.detail.fields;\r\n name = event.target.name;\r\n\r\n //select the account fields from the record page.\r\n if( name == \"saveAccount\"){\r\n this.template.querySelector('.accnt').submit(fields);\r\n }\r\n //select the contact fields from the record page.\r\n else if(name == \"saveContact\"){\r\n this.template.querySelector('.cont').submit(fields);\r\n }\r\n //select the opportunity fields from the record page.\r\n else if(name == \"saveOppty\"){\r\n this.template.querySelector('.oppty').submit(fields); \r\n }\r\n }", "handleSubmit() {\n this.submitForm();\n }", "function form_handler(form) {\n\n form.submit(function(e) {\n\n e.preventDefault();\n\n var email = form.find(\"input[name=email]\").val();\n var confirmation = $(form.data('on-submit-show'));\n var salesforce_source = \"website\";\n\n analytics.identify(email, _.reduce(form.find(\"input,textarea\"), function(acc, el) {\n\n acc[$(el).attr(\"name\")] = $(el).val();\n return acc;\n\n }, {\n\n \"LeadSource\": salesforce_source,\n \"path\": window.location.toString()\n\n }), {\n\n 'Salesforce': true\n\n });\n\n form.addClass(\"hide\");\n confirmation.removeClass(\"hide\");\n\n modal_resize();\n\n return false;\n\n });\n\n }", "function handleFormSubmit(event) {\r\n debugger;\r\n event.preventDefault();\r\n debugger;\r\n console.log(\"!!!!!!!!!!! category \" + formObject.category + \" itemName \" + formObject.itemName)\r\n if (formObject.category && formObject.itemName) {\r\n API.saveMenu({\r\n category: formObject.category,\r\n itemName: formObject.itemName,\r\n ingredientsUrl: formObject.ingredientsUrl\r\n })\r\n .then(res => loadMenus())\r\n .catch(err => console.log(err));\r\n } else {\r\n alert('Please fill in values for category and item name')\r\n }\r\n }", "async handleSubmit(evt) {}", "function formSubmitHandler(event) {\n event.preventDefault();\n buttonSubmitHandler(deck);\n }", "function formPOST(){\n\n\tthis.submit();\n\n}", "function submit() {\n\t\tvar $form = $(this).closest('form');\n\t\tif (validate($form)) {\n\t\t\tif(true){\n\t\t\t\tsend($form);\n\t\t\t} else {\n\t\t\t\tshakeButton(this);\n\t\t\t}\n\t\t}\n\t}", "function form_submit()\n {\n /* Get reply form */\n var form = submit_btn.form;\n\n /* The fields we need when do a post */\n var fields = [\"followup\", \"rootid\", \"subject\", \"upfilerename\",\n \"username\", \"passwd\", \"star\", \"totalusetable\", \"content\",\n \"expression\", \"signflag\"];\n\n /* The fields we need to encode when post */\n var encode_fields = [ \"content\" ];\n\n /* Do ajax post */\n ajax_post(form, fields, encode_fields, {\"onreadystatechange\": post_callback});\n }", "submitForm(){\n\t\tlet instance = this;\n\t\tconst\tdata = JSON.stringify({\n\t\t\tinterest: instance.dropdownData.interest,\n\t\t\tloan: instance.calculatorData,\n\t\t\tnumberOfMonths: instance.dropdownData.months,\n\t\t\ttotalDebt: instance.debt\n\t\t});\n\t\t\n\t\t\n\t\tfetch(instance.endpoint, {\n\t\t\tmethod: \"POST\",\n\t\t\theaders: {\n\t\t\t\t'Accept': 'application/json, text/plain, */*',\n\t\t\t\t'Content-Type': 'application/json'\n\t\t\t},\n\t\t\tbody: data\n\t\t}).then(resp => resp.json())\n\t\t\t.then(({status}) => instance.showFormMessage(status))\n\t\t\t.catch(err => instance.showFormMessage(`something wrong. Please contact the administrator.`, true))\n\t}", "onFormSubmit(evt) {\n\t\tevt.preventDefault()\n\t\t//send an axios request to post it to the databse\n\t\taxios({method: 'post',url:`/api/posts/${this.state.fields.location}`, data:{\n\t\t\t...this.state.fields\n\t\t}})\n\t\t//then redirect them to their new post!\n\t\t.then((post)=>{\n\t\t\tif (post.data.success){\n\t\t\t\tthis.props.history.push(`/posts/${post.data.post.location}/${post.data.post._id}`)\n\t\t\t}\n\t\t\telse{\n\t\t\t\talert('Whoops! Something went wrong!')\n\t\t\t}\n\t\t})\n\t}", "function handleFormOnsubmit(evt) {\n evt.preventDefault()\n httpAdmin.signUp({\n name: values.name,\n phone: values.phone,\n city: values.city,\n state: values.state,\n email: values.email,\n password: values.password,\n image: values.image,\n checked: values.checked\n }).then(admin => {\n console.log(\"admin\", admin)\n if (admin) {\n window.location.replace(\"/admin-12152011\")\n this.props.onSignUpSuccess(admin)\n this.props.history.push('/')\n }\n $('#errorMsg').attr(\"style\", \"color:red\")\n $('#errorMsg').text(\"An error occured please review your entries\");\n return\n }).catch(err => console.log('err', err));\n \n }", "function handleFormSubmit(event){\n event.preventDefault(); //não fazer o padrão\n }", "submitForm() {\n this._executeSubmitAction()\n .then(\n () => this.onSubmitSuccessResponse(this.formSuccessMessage)\n )\n .catch(\n () => this.onSubmitFailureResponse(this.formFailedMessage)\n );\n }", "function handle_form(form_name, submit_name, result_tgt) {\n var submit_action = function(e) {\n e.preventDefault();\n $.ajax({\n url: $(form_name).attr('action'),\n method: $(form_name).attr('method'),\n data: $(form_name).serialize(),\n beforeSend: spinner(result_tgt),\n }).done(function(data){$(result_tgt).empty().html(data);});\n };\n $(form_name).submit(submit_action);\n $(submit_name).click(submit_action);\n}", "@api\n handleSubmit() {\n this.template.querySelector(\"lightning-record-edit-form\").submit();\n }", "function submitForm() {\r\n var args = {};\r\n args.Email = session.forms.emarsyssignup.emailAddress.value;\r\n args.EmarsysSignupPage = true;\r\n args.SubscriptionType = \"footer\";\r\n args.SubscribeToEmails = true;\r\n args.Map = EmarsysNewsletter.MapFieldsSignup(); // map the form fields\r\n // send form to processing\r\n processor(args);\r\n}", "function handleSubmit(event) {\n event.preventDefault(); // stop page from reloading\n const form = event.currentTarget;\n if (form.checkValidity() === false) {\n event.preventDefault();\n event.stopPropagation();\n }\n // get the form data so we can access it\n const formData = new FormData(event.target),\n formDataObj = Object.fromEntries(formData.entries());\n setValidated(true);\n // request an analysis from the API. \n // provide the setter and the appropriate file\n requestFromApi(setResp, formDataObj)\n\n }", "function handleFormSubmit(event) {\n event.preventDefault();\n // Wont submit the post if we are missing a body, title, or workout\n if (!sequenceInput.val().trim() || !exerciseInput.val().trim() || !setsInput.val().trim() || !weightInput.val().trim() || !repsInput.val().trim() || !tempoInput.val().trim() || !restInput.val().trim() || !workoutselect.val()) {\n return;\n }\n // Constructing a newPost object to hand to the database\n var newPost = {\n section: sectionInput\n .val()\n .trim(),\n sequence: sequenceInput\n .val()\n .trim(),\n exercise: exerciseInput\n .val()\n .trim(),\n sets: setsInput\n .val()\n .trim(),\n weight: weightInput\n .val()\n .trim(),\n reps: repsInput\n .val()\n .trim(),\n tempo: tempoInput\n .val()\n .trim(),\n rest: restInput\n .val()\n .trim(),\n workoutId: workoutselect.val()\n };\n\n // If we're updating a post run updatePost to update a post\n // Otherwise run submitPost to create a whole new post\n if (updating) {\n newPost.id = postId;\n updatePost(newPost);\n } else {\n submitPost(newPost);\n }\n }", "function submitForm () {\n\n\t\t\t// Add submitting state\n\t\t\tform.setAttribute('data-submitting', true);\n\n\t\t\t// Send the data to the MailChimp API\n\t\t\tsendData(serializeForm(form));\n\n\t\t}", "function handleSubmit(e) {\n e.preventDefault();\n\n // initialized to false in the beginning to handle the edge case when a user submits with a blank field(s)\n // and fillls the field(s) and submits again\n // if we don't set this false initially, for the above case, an error alert in the field(s) will persist\n setTitleError(false);\n setDetailsError(false);\n\n if (!title.length) {\n setTitleError(true);\n }\n\n if (!details.length) {\n setDetailsError(true);\n }\n\n if (title.length && details.length) {\n fetch(\"https://smart-notes-backend.herokuapp.com/notes\", {\n method: \"POST\",\n headers: {\n Authorization: \"Bearer \" + localStorage.getItem(\"token\"),\n \"Content-type\": \"application/json\",\n },\n body: JSON.stringify({\n title,\n details,\n category,\n }),\n })\n .then((res) => res.json())\n .then((data) => {\n if (data.status === \"ok\") {\n history.push(\"/notes\");\n } else {\n notifyError(data.message);\n }\n });\n }\n }", "function afterSubmit(data) {\r\n\t var form = data.form;\r\n\t var wrap = form.closest('div.w-form');\r\n\t var redirect = data.redirect;\r\n\t var success = data.success;\r\n\r\n\t // Redirect to a success url if defined\r\n\t if (success && redirect) {\r\n\t Webflow.location(redirect);\r\n\t return;\r\n\t }\r\n\r\n\t // Show or hide status divs\r\n\t data.done.toggle(success);\r\n\t data.fail.toggle(!success);\r\n\r\n\t // Hide form on success\r\n\t form.toggle(!success);\r\n\r\n\t // Reset data and enable submit button\r\n\t reset(data);\r\n\t }", "function subform_submit(e)\n {\n var submit = e || window.event;\n \tsubmit.preventDefault();\n\t\t\tsubmit.stopPropagation();\n\n\t\tvar $subform = $(submit.target).closest('.subform'),\n\t\t\t$fields = $subform.find('.field');\n\n $subform.find('.error').remove();\n\n\t\tvar classes = $('form', $subform).attr('class').split(' '),\n\t\t\tpost_type;\n\t\tfor ( var i = 0; i < classes.length; i++ )\n\t\t{\n\t\t\tvar parts = classes[i].split(\"_\");\n\t\t\tif ( 'form-em' === parts[0] ) {\n\t\t\t\tpost_type = classes[i].replace('form-', '');\n\t\t\t}\n\t\t}\n\n var data = {\n \t'action': 'process_subforms',\n \t'post_type': post_type,\n \t'post_title': '',\n \t'fields': {},\n };\n\n\t\t$fields.each(function(){\n\t\t\tvar $field = $(this),\n\t\t\t\tkey = $field.data('field_key'),\n\t\t\t\t$input = $('.acf-input-wrap :first-child', this),\n\t\t\t\tvalue = $input.val();\n\n\t\t\tif ( undefined != key )\n\t\t\t{\n\t\t\t\tif ( key.indexOf(\"title\") > -1 )\n\t\t\t\t{\n\t\t\t\t\tdata.post_title = value;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tdata.fields[key] = value;\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\t$.ajax({\n\t\t\turl : eman.ajaxurl,\n\t\t\ttype : 'post',\n\t\t\tasync : true,\n\t\t\tcache : false,\n\t\t\tdataType : 'json',\n\t\t\tdata : data,\n\t\t\tsuccess: function( response )\n\t\t\t{\n\t\t\t\t// console.log(response);\n $('.modal .btn-primary').each(function() { clearButtonMask(this); });\n\n\t\t\t\tif ( response.error )\n\t\t\t\t{\n\t\t\t\t\t// $('.sewn_notifications').trigger('sewn/notifications/add', [response.error, {fade : true, error : true}]);\n var errMsg = document.createElement('div');\n errMsg.className = 'error';\n errMsg.appendChild(document.createElement('p')).appendChild(document.createTextNode(response.error));\n $('.modal .modal-content').prepend(errMsg);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$('.sewn_notifications').trigger('sewn/notifications/add', [\"Successfully updated\", {fade : true}]);\n\t\t\t\t\t$('form', $subform)[0].reset();\n\t\t\t\t\t$('.modal').modal('hide');\n\t\t\t\t}\n\n\t\t\t\t$subform.closest('.field').find('select').append( $('<option />', {'value': response.id, 'text': response.title}) );\n\t\t\t},\n\t\t\terror: function( xhr )\n\t\t\t{\n\t\t\t\tconsole.log(xhr.responseText);\n\t\t\t}\n\t\t});\n }", "function submitHandler(e) {\n e.preventDefault();\n const validations = [];\n const formValues = {};\n for (const [idName, idRef] of Object.entries(references)) {\n validations.push(validateCore(idName, idRef.current.value));\n formValues[idName] = idRef.current.value;\n }\n startLoading();\n Promise.all(validations).then((vResolved) => {\n const formIsValid = !vResolved.includes(false);\n if (formIsValid) {\n // the contribution object to be added to users list\n const contObj = {\n stamp: Date.now(),\n amount: parseInt(formValues.amount),\n };\n const body = {\n userName: formValues.userName,\n contObject: contObj,\n };\n // console.log(\"form is submitting...\");\n sendRequest({\n method: \"POST\",\n route: server.routes.newContribution,\n body: body,\n }).then((resObj) => {\n if (resObj.status === 200) {\n dispatchGlobal(\n addContributionThnuk(\n formValues.userName,\n contObj,\n resObj.payload.recentString\n )\n );\n // here we have to reset the form\n clearFields(references);\n dispatchValidator(vActions.RESETALL());\n setTimeout(() => {\n resetStatus();\n }, 3000);\n }\n });\n } else {\n // console.log(\"form is not valid\");\n resetStatus();\n }\n });\n }", "function handleFormSubmit(event){\n if (event.target.id == \"garden-submit\"){\n \tlet gardenInput = gFormDiv.querySelectorAll('input#garden')\n\n \tlet newGardenObj = {\n \t\ttitle: gardenInput[0].value,\n \t\tgardenType: gardenInput[1].value\n \t}\n \tApi.newGarden(newGardenObj)\n \tlocation.reload()\n }\n}", "handleSubmit(event){\n event.preventDefault(); // stop the form from submitting\n const fields = event.detail.fields;\n\n //Update RecordId, ObjectAPIName based on URL in case URL has changed in console\n //There is no way to track URL changes as there is no API and component doesn't re-render in Utility Bar\n //Update page data (object, record ID, URL) with latest info (if it was in console) and submit form\n this.updateRecordInfoFromUrl();\n\n //Use namespace in fields\n fields.issuebox__Reported_Object__c = this.objectApiName;\n fields.issuebox__Reported_Record__c = this.recordId;\n fields.issuebox__URL__c = this.pageUrlPath;\n \n this.template.querySelector('lightning-record-edit-form').submit(fields);\n }", "function handleSubmit(e) {\n e.preventDefault();\n\n // stateovi za errore\n // validacija\n }", "function afterSubmit(data) {\n var form = data.form;\n var wrap = form.closest('div.w-form');\n var redirect = data.redirect;\n var success = data.success;\n\n // Redirect to a success url if defined\n if (success && redirect) {\n Webflow.location(redirect);\n return;\n }\n\n // Show or hide status divs\n data.done.toggle(success);\n data.fail.toggle(!success);\n\n // Hide form on success\n form.toggle(!success);\n\n // Reset data and enable submit button\n reset(data);\n }", "function handleSubmit(e) {\n e.preventDefault();\n if(!isValid)\n {\n return\n }\n return history.replace(\"/ColleagueWelcome\", value);\n }", "function doFormSubmission(returnUrl) {\n\t\t/*kenyaui.openLoadingDialog({ message: 'Submitting form...' });*/\n\n\t\tvar form = $('#htmlform');\n\n\t\tjQuery.post(form.attr('action'), form.serialize(), function(result) {\n\t\t\tif (result.success) {\n\t\t\t\tui.disableConfirmBeforeNavigating();\n\n\t\t\t\tif (returnUrl) {\n\t\t\t\t\tui.navigate(returnUrl);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tui.reloadPage();\n\t\t\t\t}\n\t\t\t}\n\t\t\telse {\n\t\t\t\t// Show errors on form\n\t\t\t\tfor (key in result.errors) {\n\t\t\t\t\tshowError(key, result.errors[key]);\n\t\t\t\t}\n\n\t\t\t\t// Keep user on form page to fix errors\n\t\t\t\t/*kenyaui.notifyError('Please fix all errors and resubmit');\n\t\t\t\tkenyaui.closeDialog();*/\n\t\t\t\tsubmitting = false;\n\t\t\t}\n\t\t}, 'json')\n\t\t.error(function(jqXHR, textStatus, errorThrown) {\n\t\t\twindow.alert('Unexpected error, please contact your System Administrator: ' + textStatus);\n\t\t\tconsole.log(errorThrown);\n\t\t});\n\t}", "submit() {}", "function handleFormSubmit(event) {\n event.preventDefault();\n if (formObject.title && formObject.author) {\n API.saveLessontoMain({\n title: formObject.title,\n author: formObject.author,\n synopsis: formObject.synopsis\n })\n .then(res => loadLessonsMain())\n .catch(err => console.log(err));\n }\n }", "handleSubmit(e) {\r\n // Prevent legacy form post\r\n e.preventDefault();\r\n\r\n // Validate\r\n if (FormValidator.validateForm(e)) {\r\n // TODO place ajax POST / PUT stuff here...\r\n let isSuccess = true;\r\n\r\n if (typeof this.props.onSubmit === 'function') {\r\n this.props.onSubmit(this.state.data, isSuccess);\r\n }\r\n }\r\n }", "handleEditFormSubmission() {\n\t\tthis.getPortfolioItemData();\n\t}", "function handleFormSubmit(event) {\n event.preventDefault();\n // Wont submit the report if we are missing a body, title, or member\n if (!titleInput.val().trim() || !bodyInput.val().trim() || !memberSelect.val()) {\n return;\n }\n // Constructing a newReport object to hand to the database\n var newReport = {\n title: titleInput\n .val()\n .trim(),\n body: bodyInput\n .val()\n .trim(),\n MemberId: memberSelect.val()\n };\n\n // If we're updating a report run updateReport to update a report\n // Otherwise run submitReport to create a whole new report\n if (updating) {\n newReport.id = reportId;\n updateReport(newReport);\n }\n else {\n submitReport(newReport);\n }\n }", "handleSubmit(event) {\n this.showLoadingSpinner = true;\n // prevending default type sumbit of record edit form\n event.preventDefault();\n // querying the record edit form and submiting fields to form\n this.template\n .querySelector(\"lightning-record-edit-form\")\n .submit(event.detail.fields);\n this.showLoadingSpinner = false;\n \n }", "async submitForm(event) {\n // Set up\n var { formValues, history, submitWorkflow } = this.props;\n event.preventDefault();\n\n // Check if we even have to do an update (aka did the user even make any changes?)\n var madeNoChanges = this.compareForms(this.state.originalForm, this.props.formValues.values);\n if (madeNoChanges) {\n toast(\"You made no changes yet!\");\n return;\n }\n\n var successfullySubmission = await submitWorkflow(formValues.values, history);\n if (successfullySubmission) {\n toast(\"You have updated your profile!\");\n }\n }", "submitForm(e) {\n e.preventDefault();\n window.M.updateTextFields();\n let data = Util.getDataElementsForm(e.target, false);\n\n MakeRequest({\n method: 'post',\n url: 'actividad/post',\n data : data\n }).then(response => {\n if (response.error) {\n return Util.getMsnDialog('danger', Util.getModelErrorMessages(response.message));\n }\n\n this.getActivitiesByCategory();\n return Util.getMsnDialog('success', 'Created');\n });\n }", "function handleFormSubmit(e) {\n e.preventDefault();\n\n // This checks if the request form has blank values\n // for text fields and buttons\n checkIfFormUnfilled(formObject, \"radio\");\n\n function checkIfFormUnfilled(obj, buttonType) {\n let formFilledOutRight = true;\n // Check buttons\n var inputs = document.getElementsByTagName(\"input\");\n // buttonsBoolean is for selection validation\n // buttonSelected is for tip value validation\n let buttonsBoolean = [];\n let buttonSelected = [];\n for (var i = 0; i < inputs.length; i++) {\n if (inputs[i].type.toLowerCase() === buttonType) {\n buttonsBoolean.push(inputs[i].checked);\n if (inputs[i].checked === true) {\n buttonSelected.push(inputs[i]);\n }\n }\n }\n\n // if none are clicked, show modal\n if (!buttonsBoolean.includes(true)) {\n document.getElementById(\"warning-radio-button-button\").click();\n formFilledOutRight = false;\n }\n \n // checks tip value against minimum of selected button\n if (buttonSelected[0].id === \"generalRequest\") {\n if (formObject.tip < event.generalRequestTipMin) {\n document.getElementById(\"warning-minimum-tip-button\").click();\n formFilledOutRight = false;\n }\n } else {\n if (formObject.tip < event.playNowTipMin) {\n document.getElementById(\"warning-minimum-tip-button\").click();\n formFilledOutRight = false;\n }\n }\n \n // Check form fields\n for (var key in obj) {\n // if one is blank, show modal\n if (obj[key] === null || obj[key] === \"\") {\n document.getElementById(\"warning-form-button\").click();\n formFilledOutRight = false;\n }\n }\n\n // To album cover function\n if (formFilledOutRight) {\n getAlbumCover(formObject.title, formObject.artist);\n }\n }\n }", "function handleSubmit(URL) {\n let submissionData = {}\n if (URL === \"purchase-orders\") {\n submissionData = {\n lst_price: manualFormData.manualData.price_unit,\n name: manualFormData.manualData.name,\n id: manualFormData.manualData.product_id,\n default_code: manualFormData.manualData.default_code,\n product_qty: manualFormData.manualData.product_qty,\n product_uom: manualFormData.manualData.product_uom,\n date_planned: manualFormData.manualData.date_planned\n };\n } else if (URL === \"automatic\") {\n submissionData = {}\n } else {\n submissionData = {}\n return;\n }\n dashBoardService.submitForm(URL, submissionData)\n .then(response => {\n notifySuccess(\"Submitted\", \"Submitted Form\")\n setShowProductsModal({ state: false, action: '' })\n })\n .catch(error => {\n notifyError(\"Failed\", \"Couldn't submit the form\")\n console.log(error)\n setShowProductsModal({ state: false, action: '' })\n })\n }", "handleFormSubmit(event){\n event.preventDefault();\n var element = event.target,\n formElements;\n if(element.nodeName === 'BUTTON'){\n formElements = element.parentNode.childNodes;\n if(formElements[0].value !== '' && formElements[1].value !== '')\n this.props.callbackFromWrapper({subject : formElements[0].value,\n question : formElements[1].value,\n responses : []});\n\n formElements[0].value = '';\n formElements[1].value = '';\n }\n }", "function handleFormRequest() {\n var $inputs = $('.demo-form :input');\n var values = captureFormData($inputs);\n var url;\n // submitRequest(values, url);\n}", "function submitForm(){\n console.log(\"entered submit function\");\n// e.preventDefault();\n\n // Get values\n var type=\"cc\"\n var name = \"ram\";\n var age = \"\";\n var email = getInputVal('mail');\n var phone = \"num\";\n\n // Save message\n saveMessage(type,name,age,email, phone);\n}", "function handleSubmitForm(e) {\n e.preventDefault();\n loggingDispatch({ type: 'usernameOrEmailImmediately', value: state.usernameOrEmail.value });\n loggingDispatch({ type: 'passwordImmediately', value: state.password.value });\n\n loggingDispatch({ type: 'submitForm' });\n }", "function handleFormSubmit() {\r\n\tif(window.event) window.event.preventDefault(); \r\n\tvar inputUsername = document.getElementById(\"input-username\").value;\r\n\tvar inputCaption = document.getElementById(\"input-caption\").value;\r\n\tvar inputPicture = document.getElementById(\"input-picture\").value;\r\n addNewPost(inputUsername, fileLocations[inputPicture], inputCaption);\r\n}", "function processForm(evt) {\n}", "function handleFormSubmit(event) {\n event.preventDefault();\n // Wont submit the post if we are missing a body, title, or author\n if (!nameInput.val().trim() || !emailInput.val().trim()) {\n return;\n }\n // Constructing a newPost object to hand to the database\n var newPost = {\n email: emailInput\n .val()\n .trim(),\n name: nameInput\n .val()\n .trim(),\n //AuthorId: authorSelect.val()\n };\nconsole.log('4');\n // If we're updating a post run updatePost to update a post\n // Otherwise run submitPost to create a whole new post\n if (updating) {\n newCustomer.id = customerId;\n updateCustomer(newCustomer);\n }\n else {\n submitCustomer(newCustomer);\n }\n }", "handleSubmitModal(event) {\n this.template.querySelector(\"c-create-record-from-fieldset\").handleSubmit();\n }", "function afterSubmit(data) {\n var form = data.form;\n var redirect = data.redirect;\n var success = data.success;\n\n // Redirect to a success url if defined\n if (success && redirect) {\n Webflow.location(redirect);\n return;\n }\n\n // Show or hide status divs\n data.done.toggle(success);\n data.fail.toggle(!success);\n\n // Hide form on success\n form.toggle(!success);\n\n // Reset data and enable submit button\n reset(data);\n }", "onSubmit() {\n this._submit.classList.add('button--disabled');\n location.reload();\n if (this.isValid())\n this.props.submit ? this.props.submit(this.form) : null;\n }", "function handleSubmit(event){\n event.preventDefault()\n \n //this is where I am calling the function above to submit the username/password\n registration()\n //setUserName(\"\")\n //setPassword(\"\")\n }", "function handleSubmit(event) {\n event.preventDefault();\n\n if (!checkForm()) {\n return false;\n }\n\n AuthService.register({\n lastName: lastnameInput.current.value,\n firstName: firstnameInput.current.value,\n email: emailInput.current.value,\n password: passwordInput.current.value,\n birthDate: birthdateInput.current.value,\n username: usernameInput.current.value,\n description: descInput.current.value,\n country: countryInput.current.value,\n }).then(response => {\n if (response.ok) {\n UIkit.modal(\"#signup\").hide();\n }\n return response.json().then(data => {\n UIkit.notification({\n message: data.message,\n status: (response.ok) ? 'success' : 'danger',\n pos: 'top-right',\n timeout: 5000\n });\n return true;\n });\n });\n }", "function handleFormSubmit() {\n // Wont submit the post if we are missing a body, title, or author\n if (!nameSelect.val() || !dateSelect.val().trim() || !categorySelect.val() || !taskSelect.val() || !timeSelect.val() || !programId.val().trim()) {\n return;\n }\n // Constructing a newPost object to hand to the database\n var newEntry = {\n employee_id: userName,\n name: nameSelect.val(),\n\n // may need to reformat date information for mySQL?\n date: dateSelect.val(),\n category: categorySelect.val(),\n task: taskSelect.val(),\n timespent: timeSelect.val(),\n program: programId.val().trim(),\n ecr: inputEcr.val(),\n notes: inputNotes.val(),\n };\n submitTableRow(newEntry);\n }", "submit(e) {\n e.preventDefault();\n this.currentStep++;\n this.updateForm();\n this.$form.querySelector(\"form\").submit();\n }", "function handleSubmit() {\n const {\n fandomName,\n level,\n type,\n } = values;\n\n // Request to join Fandom\n fetch(joinFandomURL, {\n method: 'post',\n mode: 'cors',\n headers: {\n 'Content-Type': 'application/json',\n Accept: 'application/json',\n },\n body: JSON.stringify({\n level,\n type,\n fandomName,\n username: loggedInUser,\n }),\n }).then((response) => {\n switch (response.status) {\n case 200:\n handleTrigger(true);\n return response.json();\n case 404:\n throw new Error('Fandom not found.');\n case 409:\n throw new Error('User already joined fandom.');\n case 400:\n throw new Error('Invalid type or level.');\n default:\n throw new Error('Something went wrong joining a fandom.');\n }\n }).catch((err) => {\n alert(err);\n });\n }", "function handleReviewerFormSubmit(event) {\n event.preventDefault();\n // Don't do anything if the name fields hasn't been filled out\n if (\n !nameInput \n .val()\n .trim()\n .trim()\n ) {\n return;\n }\n // Calling the upsertReviewer function and passing in the value of the name input\n upsertReviewer({\n name: nameInput.val().trim()\n });\n }", "function handleFormSubmit(event) {\n event.preventDefault();\n\n API.createExpense({\n title: formObject.title,\n date: formObject.date,\n category: formObject.category,\n clienttocharge: formObject.clienttocharge,\n amount: formObject.amount,\n notes: formObject.notes,\n creator: userId\n })\n .then(() =>\n setFormObject({\n title: \"\",\n date: \"\",\n category: \"\",\n clienttocharge: \"\",\n amount: \"\",\n notes: \"\"\n })\n )\n .then(() => {\n history.push(\"/allclaims\");\n })\n .catch(err => console.log(err));\n }", "function handleFormSubmit(event) {\r\n event.preventDefault();\r\n console.log(titleInput.val());\r\n console.log(listInput.val());\r\n console.log(emailInput.val());\r\n console.log(categoryInput.val());\r\n\r\n // Wont submit the post if we are missing a body, title, or author\r\n if (!titleInput.val().trim() || !listInput.val().trim() || !emailInput.val()) {\r\n return;\r\n }\r\n // Constructing a newPost object to hand to the database\r\n var userList = {\r\n title: titleInput\r\n .val()\r\n .trim(),\r\n list: listInput\r\n .val()\r\n .trim(),\r\n emails: emailInput\r\n .val()\r\n .trim(),\r\n category: categoryInput\r\n\r\n .val()\r\n .trim(),\r\n };\r\n\r\n submitPost(userList);\r\n // submitList(userList.list);\r\n // console.log(\"working\");\r\n }", "function processForm (e) {\n\n var curMenuItem = document.querySelector('.explore-form-menu-item.active'),\n eventType = e.type;\n\n switch (e.type) {\n case 'change':\n case 'keydown':\n case 'keyup':\n case 'focus':\n case 'blur':\n case 'reset':\n if (curMenuItem.classList.contains(eventType)) {\n displayEventObject(e, false);\n }\n break;\n case 'submit':\n if (curMenuItem.classList.contains(eventType)) {\n displayEventObject(e, true);\n } else {\n e.preventDefault();\n }\n break;\n }\n}", "handleSubmit(e){\n\t\t// prevents the page reload, default for form submission\n\t\te.preventDefault();\n\n\t\t// show the spinner\n\t\t$(this.refs.spinner).show();\n\t\t\n\t\t// prepares the data to be sent, from refs on the form inputs\n\t\tvar sendData = {\n\t\t\tContactChanell: \"contact page\",\n\t\t\temail: this.refs.email.value,\n\t\t\tphoneNumber: this.refs.phoneNumber.value,\n\t\t\tcompanyName: this.refs.companyName.value,\n\t\t\tcontactName: this.refs.contactName.value,\n\t\t\tcountryCode: this.state.countryCode\n\t\t}\n\n\t\t// makes the ajax call on the jquery object\n\t\t$.ajax({\n\t\t\turl: \"some.com\",\n\t\t \ttype: 'POST',\n\t\t \tdata: sendData,\n\t\t \t// called when the request is successfull\n\t\t \tsuccess: function(response) {\n\t\t \t\t// shows the success message\n\t\t \t\t$(this.refs.success_message).show();\n\t\t \t\t// hides the form\n\t\t \t\t$(this.refs.form).hide();\n\t\t \t\t// hide the spinner\n\t\t \t$(this.refs.spinner).hide();\n\t\t \t}.bind(this),\n\t\t \t// called when the request fails\n\t\t \terror:function (e){\n\t\t \t\t// shows the failure message\n\t\t\t $(this.refs.failure_message).show();\n\t\t\t // hides the spinner\n\t\t\t $(this.refs.spinner).hide();\n\t\t\t // hides the form\n\t\t\t $(this.refs.form).hide();\n\t\t\t}.bind(this)\n\t\t});\t\n\t}", "submit(e) {\n e.preventDefault();\n let form = e.target;\n this.errors = this.checkForErrors(form);\n if (!this.errors.length) {\n // if form contents are valid then move to next step\n this.triggerEnablePayment();\n\n // store shipment details in store\n const formData = new FormData(form);\n const email = formData.get('email');\n const name = formData.get('name');\n const address = formData.get('address');\n store.dispatch(addShipmentInCheckout({ name, email, address }));\n }\n }", "function submitForm(e)\n{\n // Dit is de opdracht die de browser verteld niet de standaard actie uit te voeren\n e.preventDefault();\n\n // Hieronder, en nu pas, gaan we zelf bepalen wat er wel moet gebeuren na de submit\n // We roepen daarvoor een asynchrone functie aan om de api te benaderen met de formulier\n // gegevens.\n callAPI();\n}", "function _formHandler(ev) {\r\n ev.preventDefault();\r\n var contact = new Contact(el.form.serializeObject());\r\n contact.save(_renderThanks, _renderError);\r\n }", "function formSubmit(event) {\n\t// Prevent the form from reverting back to the default setting\n\tevent.preventDefault()\n\tvar passName = addName()\n\n\t// If all fields have been filled in correctly\n\tif (addName() == true && addUsername() == true && addEmail() == true) {\n\t\t// Call the gallery.html page! Success!\n\t\twindow.location.href = \"gallery.html\" + passName;\n\t};\n\n}", "submit() {\n }", "function handleFormSubmit(event) {\n event.preventDefault();\n if (formObject.title && formObject.username && formObject.photo) {\n API.savePost({\n title: formObject.title,\n username: formObject.username,\n content: formObject.content,\n photo: formObject.photo,\n date: formObject.date,\n })\n .then(res => loadPosts())\n .catch(err => console.log(err));\n }\n }", "function registerSubmitHandler() {\n var handler = function(e) {\n e.preventDefault();\n\n var $step = getCurrentStep();\n var valid = allFieldsValid($step);\n\n if (!valid || processing) return;\n\n if ($fields.email.val() !== emailUsed) {\n // Email has been modified since the last clearbit fetch\n return populateClearbitFields(function() {\n handler(e);\n });\n }\n\n processing = true;\n\n if ($fields.company.val()) {\n // Had a clearbit match, or finished company step\n showTimeSelection();\n } else {\n // No clearbit match\n showCompanyStep();\n }\n };\n\n $form.on('submit', handler);\n }", "function handleFormSubmit(event) {\n // 2. prevent default\n event.preventDefault();\n\n // Find input fields within form\n // const nameInput = document.getElementById('name-input');\n const newPokemon = getPokemonInfoFromForm(event);\n\n // 3. update backend - add new pokemon to db\n persistNewPokemon(newPokemon);\n\n // 4. update frontend - render our new pokemon\n // optimistic render\n // const pokemonContainer = document.getElementsByClassName('pokemon-container')[0];\n // pokemonContainer.innerHTML += renderSinglePokemon(newPokemon);\n}", "function handleSubmit(event){\n props.onSubmit(noteState);\n setNoteState({\n title: \"\",\n body: \"\"\n })\n setExpand(false);\n event.preventDefault();\n }", "function submit() {\n saveForm(applicant)\n}", "onSubmit() {\n console.log(\"submit form\");\n }", "function handleFormSubmit(event) {\n event.preventDefault();\n // Wont submit the pet if we are missing a body, title, or owner\n if (\n !titleUpdate.val().trim() ||\n !bodyUpdate.val().trim() ||\n !driverSelect.val()\n ) {\n return;\n }\n // Constructing a newPet object to hand to the database\n var newPet = {\n title: titleUpdate.val().trim(),\n email: emailUpdate.val().trim(),\n body: bodyUpdate.val().trim(),\n driverId: driverSelect.val()\n };\n\n // If we're updating a pet run updatePet to update a pet\n // Otherwise run submitPet to create a whole new pet\n if (updating) {\n newPet.id = petId;\n updatePet(newPet);\n } else {\n submitPet(newPet);\n }\n }", "function initiateFormSubmission(e) {\n e.preventDefault();\n uploadSongDispatch({\n type: 'usernameImmediately',\n value: state.username.value,\n keepError: true,\n });\n uploadSongDispatch({ type: 'songTitleImmediately', value: state.songTitle.value });\n uploadSongDispatch({ type: 'songTitleAfterDelay', value: state.songTitle.value });\n uploadSongDispatch({ type: 'audioImmediately', value: state.audio.value });\n uploadSongDispatch({ type: 'submitForm' });\n }", "function handleSubmit(e) {\n e.preventDefault();\n\n confirmationAlert(\n \"Atenção!\",\n \"Deseja realmente SALVAR esse cadastro?\",\n \"createPerson\"\n );\n }", "fallback() {\n this.form.submit();\n }", "fallback() {\n this.form.submit();\n }", "function formSubmissionHandler(e){\n e.preventDefault();\n \n if( !isValidServerNameRegex() || !doesHostnameHasAvailableClass() || !isValidEmailRegex() ){\n e.stopPropagation();\n console.error(\"STOPPING THE FORM FROM SUBMITTING!\");\n\n // showInvalidEmailWarning();\n \n return false;\n }else{\n console.log(\"CONTINUING WITH THE FORM FROM SUBMITTING!\");\n \n $$.submissionForm.unbind(); //unbind the submission listener\n\n enableAllFormElements();\n\n $$.submissionForm.submit();\n }\n \n }", "function addSubmitEventListener(handler) {\n $(\"#welcome-modal-form\").submit(handler);\n }", "function handleFormSubmit() {\n API.saveReviews(formObject)\n .then((data) => {\n console.log(data);\n console.log(\"I hit the route\");\n })\n .catch((err) => console.log(err));\n }", "function handleSubmit(event) {\n event.preventDefault()\n\n if(formData.password === formData.confirm_password) {\n console.log(\"Successfuly sugned up!\")\n } else {\n console.log(\"Pasword do not match!\")\n return\n }\n /* 4. Also when submitting the form, if the person checked\n * the \"newsletter\" checkbox, log \"Thanks for signing\n * up for our newsletter!\" to the console.\n */\n if(form.joinedNewsletter) {\n console.log(\"Thanks for signing up for our newsletter!\")\n }\n\n }", "function handleSubmit(evt) {\n evt.preventDefault();\n storeItem(newItem);\n alert(\"Menu item added!\")\n\n // redirect with history.push and the path\n // after the email form is submitted it redirects to the root\n // can also go back and forward unlike redirect\n history.push(`/${item}`);\n }", "function handleFormSubmit(event) {\n event.preventDefault();\n // Wont submit the post if we are missing a comment\n if (!comInput.val().trim()) {\n return;\n }\n // Constructing a newCom object to hand to the database\n let newCom = {\n comment: comInput.val().trim(),\n QuoteId: comInput.attr(\"data-id\"),\n };\n\n postComment(newCom);\n }", "handleAddFormSubmit(e) {\n console.log('handleFormSubmit');\n e.preventDefault();\n const formData = this.getFormData(e);\n this.doSomethingWithFormData(formData);\n this.hideAddListItemPopup();\n }", "function handleFormSubmit(event) {\n event.preventDefault();\n if (formObject.title) {\n API.savePattern({\n id: sequence?.sequenceConfigList?.length,\n title: formObject.title,\n noteCount: formObject.noteCount,\n trackList: sequence.selectedSequence.trackList,\n })\n .then(() =>\n setFormObject({\n title: \"\",\n })\n )\n .then(() => loadSequences())\n .catch((err) => console.log(err));\n }\n }", "function handleFormSubmit(event) {\n event.preventDefault();\n if (formObject.name && formObject.location) {\n transaction.saveTransaction({\n name: formObject.name,\n location: formObject.location,\n price: formObject.price\n })\n .then(res => loadTransactions())\n .catch(err => console.log(err));\n }\n }", "function handleSubmit(e) {\n // function to create a new contact and then close the model\n e.preventDefault();\n createContact(idRef.current.value,nameRef.current.value);\n closeModal();\n\n // create contact\n }", "function form_handler(form_name, custom_validation, success_message, error_message, success_function, error_function) {\n $(form_name).find('input[type=\"submit\"]').on('click', function(e) { // if submit button is clicked\n\n window.onbeforeunload = null; // cancels the alert message for unsaved changes (if such function exists)\n\n $(form_name).find('.form-group .error-msg').remove();\n var submitButton = this;\n submitButton.disabled = true; // Disables the submit buttton until the rows pass validation or we get a response from the server.\n\n var form = $(form_name)[0];\n // The custom validation function must return true or false.\n if (custom_validation != null) {\n if (!custom_validation(form, getFormData(form))) {\n submitButton.disabled = false;\n return false;\n }\n }\n e.preventDefault(); //STOP default action\n });\n $(document).click(function(e) { // Whenever the user clicks inside the form, the error messages will be removed.\n if ($(e.target).closest(form_name).length) {\n $(form_name).find('.form-group').removeClass('has-error');\n setTimeout(function() {\n $(form_name).find('.form-group .error-msg').remove();\n }, 300);\n } else {\n return\n }\n });\n}", "async function handleSubmit(e) {\n\t\te.preventDefault();\n\t\t// Clear any past errors\n\t\tsetErrors(null);\n\t\tsetIsLoading(true);\n\t\t/** Format data based on if user is signing up or logging in\n\t\t * and store response\n\t\t */\n\t\tlet data;\n\t\tlet resp;\n\n\t\tif (activeView === 'signup') {\n\t\t\tdata = {\n\t\t\t\tusername: formData.username,\n\t\t\t\tpassword: formData.password,\n\t\t\t\tfirst_name: formData.first_name || undefined,\n\t\t\t\tlast_name: formData.last_name || undefined,\n\t\t\t\temail: formData.email || undefined,\n\t\t\t};\n\n\t\t\tresp = await signup(data);\n\t\t} else {\n\t\t\tdata = {\n\t\t\t\tusername: formData.username,\n\t\t\t\tpassword: formData.password,\n\t\t\t};\n\n\t\t\tresp = await login(data);\n\t\t}\n\t\tsetIsLoading(false);\n\t\tconsole.log(resp);\n\t\t/** Direct user to '/companies' after successful sign in */\n\t\tif (resp.success) {\n\t\t\thistory.push('/companies');\n\t\t} else {\n\t\t\t/** if registering new user returns errors,\n\t\t\t * append to 'errors' state */\n\t\t\tsetErrors(resp.errors);\n\t\t}\n\t}", "function successfulSubmit() {\n console.log(\"Successful submit\");\n\n // Publish a \"form submitted\" event\n $.publish(\"successfulSubmit\");\n\n // Hide the form and show the thanks\n $('#form').slideToggle();\n $('#thanks').slideToggle();\n\n if($('#address-search-prompt').is(\":hidden\")) {\n $('#address-search-prompt').slideToggle();\n }\n if($('#address-search').is(\":visible\")) {\n $('#address-search').slideToggle();\n }\n\n // Reset the form for the next submission.\n resetForm();\n }", "async function handleSubmit(e)\n {\n e.preventDefault();\n //check if empty\n if(ifEmpty(\"titel\", titel) && ifEmpty(\"inter\", inter) && ifEmpty(\"tech\", tech) /**&& ifEmpty(\"tech2\", tech2)*/ ){\n //add job to db\n const result = await addJobdb4params(titel, inter, tech, email)\n if(result === true){\n //get all jobs from db\n var jobs = await getJobs(email)\n //set all jobs in db\n props.updateUser(jobs)\n //redirect to /profile\n history.push(\"/profile\");\n }\n } \n }", "function handleSubmit(e) {\n e.preventDefault();\n if (image) {\n imageUpload();\n } else {\n collectFields();\n }\n }", "handleAddSubmit() {}", "function processForm(){\n\t\tvar name = formHandle.name;\n\t\tvar email = formHandle.email;\n\t\tvar comment = formHandle.comment;\n\t\tvar thanksMsgDiv = document.getElementById(\"section-div2\");\n\t\t//Validation\n\t\tif(name.value===\"\")\n\t\t{\n\t\t\tname.style.background=\"red\";\n\t\t\tname.focus();\t\t\t\n\t\t\treturn false;\n\t\t}\n\t\tif(email.value===\"\")\n\t\t{\n\t\t\temail.style.background=\"red\";\n\t\t\temail.focus();\n\t\t\treturn false;\n\t\t}\n\t\tif(comment.value===\"\")\n\t\t{\n\t\t\tcomment.style.background=\"red\";\n\t\t\tcomment.focus();\n\t\t\treturn false;\n\t\t}\n\t\tformHandle.classList.add(\"section-div2\");\n\t\tthanksMsgDiv.innerHTML=\"<p>Thank you!! \" + name.value +\" </p>\" + \"<span>Your message has been sent.</span> \"\n\t\t\n\t}", "function handleSubmit(event) {\n // handle form validation\n /** if the form is not valid then do nothing. */\n if (!formIsValid()) return;\n\n // to handle event on client, call prevent default post to server\n event.preventDefault();\n\n // call authorActions (instead of directly calling the api)\n authorActions\n // pass the author held in state\n .saveAuthor(author)\n /** all the api functions return a promise so we could\n * declare .then() to specify what should happen after\n * the saveAuthor is completed.\n */\n .then(() => {\n // redirect back to AuthorsPage\n props.history.push(\"/authors\");\n /** since Add Author was loaded via\n * React Router's Route we have access to\n * React Router's history object on props.\n * So we can programmatically redirect the\n * user after the save is completed. */\n\n // display notification after success save\n toast.success(\"Author saved.\");\n });\n }", "submitExtra() {\n }", "function handleSubmit(e) {\n e.preventDefault();\n\n postMessage({\n message: value,\n projectID: e.target.name\n })\n }" ]
[ "0.7398674", "0.71746373", "0.70603627", "0.69652617", "0.6928645", "0.6925527", "0.6900938", "0.6865389", "0.68645173", "0.68574566", "0.6832717", "0.67941743", "0.67672765", "0.67378545", "0.6727598", "0.66854167", "0.66817355", "0.6678787", "0.6666687", "0.66645914", "0.6663511", "0.6662974", "0.664828", "0.66414356", "0.66377044", "0.66223043", "0.6618395", "0.6613219", "0.6608634", "0.6598827", "0.65917104", "0.6590026", "0.6587941", "0.65865123", "0.65821713", "0.6578579", "0.6574644", "0.6570422", "0.6569045", "0.6566994", "0.6566656", "0.6563517", "0.6561798", "0.6560068", "0.6558332", "0.6547861", "0.65429384", "0.6527649", "0.6524998", "0.65209335", "0.6505996", "0.64912915", "0.64829165", "0.6480971", "0.64785165", "0.6476322", "0.64758617", "0.64664376", "0.64574766", "0.6448692", "0.6439976", "0.6430868", "0.64300525", "0.64296305", "0.64054376", "0.6394723", "0.6394373", "0.6391863", "0.63881314", "0.63857305", "0.63839555", "0.63810205", "0.6380022", "0.6379139", "0.6371439", "0.6371035", "0.6370188", "0.6365979", "0.6352446", "0.6352446", "0.63493615", "0.6346053", "0.634508", "0.6345012", "0.6332409", "0.63289315", "0.6327795", "0.632725", "0.6326717", "0.63190365", "0.6318632", "0.6318389", "0.63171905", "0.6311044", "0.6309366", "0.6308956", "0.6308849", "0.630485", "0.63030046", "0.6301237" ]
0.6935953
4
parsing the form to get parameters for get and post
function getFormRoute(form){ var hash = getHashFromUrl(form.action); console.log("getFormRoute | hash: %s", hash); var route = getRoute(hash); var params = {}; for(var i=0;i<form.elements.length;i++){ var e = form.elements[i]; var key = e.name; var type = e.type.toLowerCase(); if(!key || ((type=="radio" || type=="checkbox") && !e.checked)) continue; var value = e.value; updateParamItem(params,key,value,false); } console.log("params: %s", JSON.stringify(params)); $.extend(route.params,params); if(form.method.toLowerCase() == "get"){ $.extend(route.getParams,params); } else{ // create post params route.postParams = params; } console.log("updated route: %s", JSON.stringify(route)); return route; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function parse_get_parameters() {\n if (location.search.length < 1) {\n return null;\n }\n else {\n var parameters = [];\n location.search\n .substr(1)\n .split(\"&\")\n .forEach(function (item) {\n let temp = item.split(\"=\");\n parameters.push(\n {\n parameter_name: temp[0],\n parameter_value: temp[1]\n }\n )\n });\n\n return parameters;\n }\n}", "function getRequiredParamsNames() {\n return [\n \"Submission Form URL\", // The url to POST to\n \"Username field\", \n \"Password field\", \n \"First get URI with leading slash, without trailing slash\" // Example: /test/get1.php\n ];\n}", "function _processRequestGET(req, res){\n\t\tres.writePage(_buildInboundForm(req));\n\t}", "function getPostArgs(t) {\n var ts = t.parentNode.parentNode.parentNode.getElementsByTagName(\"input\")\n var o = {}\n\n for (var i = 0; i < ts.length; i++)\n if (ts[i].type === \"hidden\") o[ts[i].name] = ts[i].value\n\n o[\"sd\"] = '1'\n\n return o\n}", "function getFormParams(formX){\n\tvar returnString = \"\";\t\n\tfor(var i = 0; i < formX.elements.length; i++){\n\t\tvar element = formX.elements[i];\n\t\tif(element.type == \"text\" || element.type == 'password'){\n\t\t\treturnString += \"&\"\t + element.name + \"=\" + element.value;\n\t\t}else if(element.type == \"file\"){\t\t\t\n\t\t}\n\t}\n\treturn returnString;\n}", "function getFormValuesAndDisplayResults() {\n}", "function parseURL() {\n\tlet match,\n\t\tpl = /\\+/g, // Regex for replacing addition symbol with a space\n\t\tsearch = /([^&=]+)=?([^&]*)/g,\n\t\tdecode = function (s) { return decodeURIComponent(s.replace(pl, ' ')); },\n\t\tquery = window.location.search.substring(1);\n\n\tlet urlParams = {};\n\twhile (match = search.exec(query))\n\t\turlParams[decode(match[1])] = decode(match[2]);\n\n\tirc.auther.fillFormFromURI(urlParams);\n}", "function populateGet() {\r\n\tvar obj = {}, params = location.search.slice(1).split('&');\r\n\tfor(var i=0,len=params.length;i<len;i++) {\r\n\t\tvar keyVal = params[i].split('=');\r\n\t\tobj[decodeURIComponent(keyVal[0])] = decodeURIComponent(keyVal[1]);\r\n\t}\r\n\treturn obj;\r\n}", "function _parseGetParams( parseStr ) {\r\n//console.log(parseStr);\r\n//console.log(window.location);\r\n\r\n\t\t\tif( !parseStr ){\r\n\t\t\t\tvar parse_url = window.location.search.substring(1).split(\"&\");\r\n\t\t\t} else {\r\n\t\t\t\tp = parseStr.split(\"?\");\r\n\t\t\t//console.log(p);\r\n\t\t\t\tparseStr = p[\"1\"];\r\n\t\t\t\tvar parse_url = parseStr.split(\"&\");\r\n\t\t\t}\r\n\r\n\t\t\tvar $_GET = {};\r\n\t\t\tfor(var n = 0; n < parse_url.length; n++) {\r\n\t\t\tvar getVar = parse_url[n].split(\"=\");\r\n\t\t\t\t//$_GET[ getVar[0] ] = typeof(getVar[1])==\"undefined\" ? \"\" : getVar[1];\r\n\t\t\t\tif( typeof(getVar[1])==\"undefined\" ){\r\n\t\t\t\t\t$_GET[ getVar[0] ] = \"\";\r\n\t\t\t\t} else {\r\n\t\t\t\t $_GET[ getVar[0] ] = getVar[1];\r\n\t\t\t\t}\r\n\t\t\t}//next\r\n\t\t\treturn $_GET;\r\n\t\t}//end _parseGetParams()", "function parseParameters() {\n var searchParams = new URLSearchParams(location.search);\n\n if (searchParams.has(\"question\")) {\n state.question = searchParams.get(\"question\")\n }\n}", "function urlQueryValues() {}", "function handleFormRequest() {\n var $inputs = $('.demo-form :input');\n var values = captureFormData($inputs);\n var url;\n // submitRequest(values, url);\n}", "function obtainGETparameters() {\n\tvar oGetParameters = new Array();\n\n\tvar sLocation = location.search.split(\"?\");\t\n\tif(sLocation.length > 1) {\n\t\tvar sParameterList =sLocation[1].split(\"&\"); \n\n\t\tfor(var i=0; i < sParameterList.length; i++) { \n\t\t\tsParameterList[i] = sParameterList[i].split(\"+\").join(\" \");\n\t\t\tvar aValues = sParameterList[i].split(\"=\");\n\t\t\tvar sId = aValues[0];\n\t\t\tvar sValue = aValues[1];\n\t\t\toGetParameters[sId]=sValue;\n\t\t}\t\t\t\t\n\t}\n\treturn oGetParameters;\n}", "function parseInputs()\n{\n var output = {};\n var query = window.location.search.substring(0);\n console.log(query);\n\n output.job = gup(\"job\", query);\n output.discipline = gup(\"discipline\", query);\n output.gender = gup(\"gender\", query);\n output.religion = gup(\"religion\", query);\n output.ideology = gup(\"ideology\", query);\n output.firstname = gup(\"firstname\", query);\n output.lastname = gup(\"lastname\", query);\n\n console.log(output);\n\n return output;\n}", "function parseURLVars() {\n //First grab the url\n let url = window.location.href;\n //Check if we have a GET value in there, if not return empty\n if (url.indexOf(\"?\") < 0) return \"\";\n //Now only read the get part\n let get = url.split('?')[1];\n //Split the get part into pairs, each is a key value pair\n let pairs = get.split(\"&\");\n //Iterate over the pairs, and only once you see keyword we return the value\n var returnValue = \"\";\n pairs.forEach(function (pair) {\n if (pair.split(\"=\")[0].toLowerCase() == \"keyword\") {\n returnValue = pair.split(\"=\")[1];\n }\n let parts = pair.split('=');\n GET[decodeURI(parts[0])] = decodeURI(parts[1]);\n });\n}", "function get_form_data() {\n var data = {};\n data[\"out\"] = $(\"#outcome-resp\").val();\n data[\"int\"] = $(\"#intervention-resp\").val();\n data[\"cmp\"] = $(\"#comparator-resp\").val();\n data[\"ans\"] = getCheckBoxSelection();\n data[\"res\"] = $(\"#reasoning-resp\").val();\n data[\"xml\"] = $(\"#reasoning-resp\").attr('xml_offsets');\n return data;\n}", "function grabLinkParams() {\n var url = new URL(window.location.href);\n var fulfillRequestTo = url.searchParams.get(\"fulfillRequestTo\");\n $(\"#destinationWalletOrEmail\").val(fulfillRequestTo);\n var fulfillRequestAmount = url.searchParams.get(\"fulfillRequestAmount\");\n $(\"#transactionAmount\").val(fulfillRequestAmount);\n }", "function parseArgs() {\n var args = {};\n var query = document.location.search.substring(1);\n var pairs = query.split('&');\n for (var i = 0; i < pairs.length; i++) {\n pos = pairs[i].indexOf('=');\n if (pos == -1) continue;\n var argname = pairs[i].substring(0, pos);\n var value = pairs[i].substring(pos+1);\n args[argname] = value;\n }\n return args;\n }", "function getURLparams() {\n var paramsArray = getURLSearch().split('&');\n var returnArray = [];\n\n paramsArray.forEach(function(param) {\n \n splitedParams = param.split('=');\n\n returnArray.push({\n name: splitedParams[0],\n value: splitedParams[1]\n });\n\n });\n\n return returnArray;\n}", "function getParams(qs) {\n\t qs = qs.split(\"+\").join(\" \");\n\t var params = {},\n\t tokens,\n\t re = /[?&]?([^=]+)=([^&]*)/g;\n\t while (tokens = re.exec(qs)) {\n\t \tparams[decodeURIComponent(tokens[1])]\n\t \t= decodeURIComponent(tokens[2]);\n\t }\n\t return params;\n}", "toGetParameters(data) {\n let parameters = \"\";\n let index = 0;\n for(let field in data) {\n if(index++ === 0) {\n parameters += \"?\";\n } else {\n parameters += \"&\";\n }\n parameters += encodeURIComponent(field) + \"=\" + encodeURIComponent(data[field]);\n }\n return parameters;\n }", "function setFormFields () {\n let query = qs.parse(window.location.search.substr(1));\n\n setCheckbox(form.allow.json, query[\"allow-json\"]);\n setCheckbox(form.allow.yaml, query[\"allow-yaml\"]);\n setCheckbox(form.allow.text, query[\"allow-text\"]);\n setCheckbox(form.allow.empty, query[\"allow-empty\"]);\n setCheckbox(form.allow.unknown, query[\"allow-unknown\"]);\n setCheckbox(form.refs.external, query[\"refs-external\"]);\n setCheckbox(form.refs.circular, query[\"refs-circular\"]);\n setCheckbox(form.validate.schema, query[\"validate-schema\"]);\n setCheckbox(form.validate.spec, query[\"validate-spec\"]);\n\n // If a custom URL is specified, then show the \"Your API\" tab\n if (query.url) {\n form.url.val(query.url);\n }\n\n // If a method is specified, then change the \"Validate!\" button\n if (query.method) {\n query.method = query.method.toLowerCase();\n if ([\"parse\", \"resolve\", \"bundle\", \"dereference\", \"validate\"].indexOf(query.method) !== -1) {\n form.method.button.val(query.method);\n }\n }\n}", "function parseGET(url)\n{ \n if(!url || url == '') url = document.location.search;\n if(url.indexOf('?') < 0) return Array();\n \n url = url.split('?');\n url = url[1];\n \n var GET = [];\n var params = [];\n var keyval = [];\n \n if(url.indexOf('#')!=-1) \n { \n anchor = url.substr(url.indexOf('#')+1);\n url = url.substr(0,url.indexOf('#'));\n }\n \n if(url.indexOf('&') > -1) params = url.split('&');\n else params[0] = url;\n \n for (i=0; i<params.length; i++)\n {\n if(params[i].indexOf('=') > -1) keyval = params[i].split('=');\n else { keyval[0] = params[i]; keyval[1] = true; }\n GET[keyval[0]]=keyval[1];\n }\n \n return (GET);\n}", "function parseURLParameters() {\n\tqueryString = window.location.search;\n\tif(typeof queryString !== 'undefined' && queryString && queryString.length > 2) {\n\t\tqueries = queryString.substring(1).split(\"&\");\n\t\tfor ( i = 0, l = queries.length; i < l; i++ ) {\n\t\t\tvar parts = queries[i].split('='), name = parts[0], val = decodeURIComponent(parts[1]);\n\t\t\t// console.log(\"Name=\"+name+\"Val=\"+val);\n\t\t\tswitch(name) {\n\t\t\tcase \"pv\":\n\t\t\t\tviewerVars.pvs.push(val); viewerVars.pvData[val] = {}; break;\n\t\t\tcase \"from\":\n\t\t\t\tviewerVars.start = new Date(val); break;\n\t\t\tcase \"to\":\n\t\t\t\tviewerVars.end = new Date(val); break;\n\t\t\tdefault:\n\t\t\t\tconsole.log(\"Unsupported parameter; adding it to the viewerVars anyways\" + name);\n\t\t\tviewerVars.name = val;\n\t\t\t}\n\t\t}\n\t}\n\t// QueryStart and QueryEnd are what we actually send to the server....\n\tviewerVars.queryStart = viewerVars.start;\n\tviewerVars.queryEnd = viewerVars.end;\n}", "function parseParams() {\n var md = view.getLocation().match(/^(.*?)#(.*)$/);\n var result = {};\n if(md) {\n var hash = md[2];\n hash.split('&').forEach(function(param) {\n var kv = param.split('=');\n if(kv[1]) {\n result[kv[0]] = decodeURIComponent(kv[1]);\n }\n });\n if(Object.keys(result).length > 0) {\n view.setLocation(md[1] + '#');\n }\n }\n return result; \n }", "function readParameters(req){\n var request_parameters = {};\n\n var page_formats = [\"Letter\", \"Legal\", \"Tabloid\",\"Ledger\",\"A0\",\"A1\",\"A2\",\"A3\",\"A4\",\"A5\",\"A6\"];\n\n if (req.query.url && \"\" != req.query.url) {\n request_parameters.url = req.query.url;\n }\n\n if (req.query.username && null != req.query.username) {\n request_parameters.username = req.query.username;\n }\n\n if (req.query.password && null != req.query.password) {\n request_parameters.password = req.query.password;\n }\n\n if (req.query.scale && !isNaN(parseFloat(req.query.scale))) {\n request_parameters.scale = parseFloat(req.query.scale);\n }\n\n if (req.query.printBackground && 1 === parseInt(req.query.printBackground)) {\n request_parameters.printBackground = true;\n }\n\n if (req.query.landscape && 1 == parseInt(req.query.landscape)) {\n request_parameters.landscape = true;\n }\n\n if (req.query.format && page_formats.indexOf(req.query.format) > -1) {\n request_parameters.format = req.query.format;\n }\n\n if (req.query.delay && parseInt(req.query.delay) > 0) {\n request_parameters.delay = parseInt(req.query.delay);\n }\n\n if (req.query.pageRanges && \"\" != req.query.pageRanges) {\n request_parameters.pageRanges = req.query.pageRanges;\n }\n\n if (req.query.headerTemplate && \"\" != req.query.headerTemplate) {\n request_parameters.headerTemplate = req.query.headerTemplate;\n }\n\n if (req.query.footerTemplate && \"\" != req.query.footerTemplate) {\n request_parameters.footerTemplate = req.query.footerTemplate;\n }\n\n if (request_parameters.headerTemplate || request_parameters.footerTemplate) {\n request_parameters.displayHeaderFooter = true;\n }\n\n if (req.query.margin) {\n request_parameters.margin = {}\n\n if (req.query.margin[\"top\"]) {\n request_parameters.margin.top = req.query.margin[\"top\"]\n }\n\n if (req.query.margin[\"bottom\"]) {\n request_parameters.margin.bottom = req.query.margin[\"bottom\"]\n }\n\n if (req.query.margin[\"left\"]) {\n request_parameters.margin.left = req.query.margin[\"left\"]\n }\n\n if (req.query.margin[\"right\"]) {\n request_parameters.margin.right = req.query.margin[\"right\"]\n }\n }\n\n return Object.assign({}, default_parameters, request_parameters);\n}", "function FormBodyParser() {\n\t}", "function getSearchParameters() {\n var prmstr = window.location.search.substr(1);\n return prmstr != null && prmstr != \"\" ? transformToAssocArray(prmstr) : {};\n}", "function getParameters() {\n let filtersParameter = filters.val() === '' ? '' : 'filters=' + filters.val();\n\n // let parameters = '?' + filtersParameter;\n return parameters= '?' + filtersParameter;\n }", "function Params() {\n const { params } = useParams(); // params&age={int}&weather={str}\n var params_array = params.split(\"&\");\n params_array.shift();\n var params2 = params_array.map(item => {\n var param_end_idx = item.indexOf(\"{\")\n var param = item.slice(0, param_end_idx);\n var type = item.slice(param_end_idx + 1, -1);\n return [param, type];\n }\n );\n\n var MappingItems = params2.map(([param, type]) =>\n <div>\n <Form className='params'>\n <Form.Group as={Row}>\n <Form.Label column sm=\"4\">{param}</Form.Label>\n <Col>\n <Form.Control id={param}\n onChange={event => {\n // parse the parameteres according to the input type //\n parameters[param] = parser(param, type, event.target.value);\n }}\n type=\"text\" placeholder=\"\" />\n </Col>\n </Form.Group>\n </Form>\n </div>\n );\n return MappingItems;\n}", "function getSearchParameters() {\r\n var prmstr = window.location.search.substr(1);\r\n return prmstr != null && prmstr != \"\" ? transformToAssocArray(prmstr) : {};\r\n }", "function parsePOSTRequest(req) { // returns the request's body as a JSON\n const bodyIndex = r.indexOf(\"\\n\\r\");\n const reqBody = r.substring(bodyIndex+3, r.length);\n let keyIndex = 0;\n let equalIndex = 0;\n let ampersandIndex = 0;\n let isDone = false;\n let parsedRespJSON = {};\n while(!isDone) {\n equalIndex = reqBody.indexOf('=', equalIndex+1);\n ampersandIndex = reqBody.indexOf('&', ampersandIndex+1);\n let key = reqBody.substring(keyIndex, equalIndex);\n let value;\n if (ampersandIndex == -1) {\n // take from last '=' character till end of string if last one, do not use ampersand index\n value = reqBody.substring(equalIndex+1, req.length)\n isDone = true; // exit the loop since we are done parsing\n }\n else {\n key = reqBody.substring(keyIndex, equalIndex) // bet. prev ampersand and equal we have the key\n keyIndex = ampersandIndex + 1;\n value = reqBody.substring(equalIndex+1, ampersandIndex) // bet. equal and ampersand we have value\n }\n parsedRespJSON[key] = value;\n }\n return parsedRespJSON;\n}", "function getUrlArgs() {\n\tvar qs = (location.search.length > 0 ? location.search.substring(1) : \"\")\n\tvar args = {};\n\tvar items = qs.split(\"&\");\n\tvar item = null;\n\tname = null;\n\tvalue = null;\n\tfor (var i = 0; i < items.length; i++) {\n\t\titem = items[i].split(\"=\");\n\t\tname = decodeURIComponent(item[0]);\n\t\tvalue = decodeURIComponent(item[1]);\n\t\targs[name] = value;\n\t}\n\treturn args;\n}", "function parseQueryString()\n{\n\tif(document.location.href.indexOf(\"?\") == -1){\n\t\tqueries = new Array(10);\n\t\treturn;\n\t}\n\tvar x = document.location.href.split(\"?\")[1].split(\"&\");\n\tvar xx;\n\tvar result = new Array(x.length);\n\t\n\tfor(i=0; i < x.length; i++)\n\t{\n\t\txx = x[i].split(\"=\");\n\t\tresult[i] = new Object();\n\t\tresult[i].name = xx[0];\n\t\tresult[i].value = xx[1];\n\t}\n\tqueries = result;\n\tcount = queries.length;\n}", "function getFormValues (myForm){\r\n var myParms = \"\";\r\n for (var i = 0, d, v; i < myForm.elements.length; i++) {\r\n d = myForm.elements[i];\r\n if (d.name && d.value) {\r\n v = (d.type == \"checkbox\" || d.type == \"radio\" ? (d.checked ? d.value : '') : d.value);\r\n if (v) myParms += d.name + \"=\" + escape(v) + \"&\";\r\n }\r\n }\r\n myParms = myParms.substr(0,myParms.length-1);\r\n // alert(\"myParms = \" + myParms);\r\n return myParms;\r\n}", "function getSearchParameters() {\n var prmstr = window.location.search.substr(1);\n return prmstr != null && prmstr != \"\" ? transformToAssocArray(prmstr) : {};\n }", "function getFormValues() {\n\tname = document.getElementById(\"name\").value;\n\temail = document.getElementById(\"email\").value;\n\tsubject = document.getElementById(\"subject\").value;\n\tmessage = document.getElementById(\"message\").value;\n}", "function getInput() {\n \tvar data = {},\n \t form = pageElements.input,\n \t tagString;\n\n\n \tdata.id = form.id.value;\n \tdata.title = form.title.value;\n \tdata.url = form.url.value\n \tdata.author = form.author.value;\n \tdata.tags = \"\";\n \tdata.comments = form.comments.value;\n\n \ttagString = form.tags.value;\n \tif(tagString.length) {\n \t\tdata.tags = tagString.toLowerCase().replace(/\\s*/g, \"\").split(\",\");\n \t}\n\n \treturn data;\n }", "function getURLArgs() {\n var query_string = {};\n let query = window.location.search.substring(1);\n let vars = query.split(\"&\");\n \n for (let i=0;i<vars.length;i++) {\n let pair = vars[i].split(\"=\");\n //if is the first entry with that name\n if (typeof query_string[pair[0]] === \"undefined\") {\n query_string[pair[0]] = decodeURIComponent(pair[1]);\n //if is the second entry with that name\n } else if (typeof query_string[pair[0]] === \"string\") {\n let arr = [ query_string[pair[0]],decodeURIComponent(pair[1]) ];\n query_string[pair[0]] = arr;\n //if is the third or more entry with that name\n } else {\n query_string[pair[0]].push(decodeURIComponent(pair[1]));\n }\n } \n return query_string;\n }", "function retrieveURL(url,nameOfFormToPost) {\r\n\r\n //get the (form based) params to push up as part of the get request\r\n url=url+getFormAsString(nameOfFormToPost);\r\n\r\n //Do the Ajax call\r\n if (window.XMLHttpRequest) { // Non-IE browsers\r\n req = new XMLHttpRequest();\r\n req.onreadystatechange = processStateChange;\r\n try {\r\n \treq.open(\"GET\", url, true); //was get\r\n } catch (e) {\r\n alert(\"Problem Communicating with Server\\n\"+e);\r\n }\r\n req.send(null);\r\n } else if (window.ActiveXObject) { // IE\r\n\r\n req = new ActiveXObject(\"Microsoft.XMLHTTP\");\r\n if (req) {\r\n req.onreadystatechange = processStateChange;\r\n req.open(\"GET\", url, true);\r\n req.send();\r\n }\r\n }\r\n }", "function getAllFormFieldsAsQueryString(paramsArray) {\r\n \tvar params = '[{';\r\n\r\n \tparams = params + '\"teste\":\"1\"';\r\n \t\r\n \tif (paramsArray) {\r\n \t\tfor (key in paramsArray) {\r\n \t\t\tparams = params + ',\"' + key + '\":\"' + paramsArray[key] + '\"';\r\n \t\t}\r\n \t\t\r\n \t}\r\n \t\r\n \tvar forms = document.forms;\r\n \tvar elementName;\r\n \tvar elementValue;\r\n\r\n \tfor (k=0; k < forms.length; k++) {\r\n \t\tfor (i=0; i < forms[k].elements.length; i++) {\r\n \t\t\tvar element = forms[k].elements[i];\r\n \t\t\t\t\t\r\n \t\t\tif (isFormElement(element)) {\t\t\t\t\r\n \t\t\t\t// nao envia o parametro referente ao formulario a ser validado\r\n \t\t\t\t// para enviar o parametro 'validationKey' referente ao \r\n \t\t\t\tif (element.name == 'validationKey') {\r\n \t\t\t\t\tcontinue;\r\n \t\t\t\t}\r\n \t\t\t\t\r\n \t\t\t\telementName = element.name;\r\n \t\t\t\telementValue = replaceAll(element.value, \"\\\"\", \"'\");\r\n \t\t\t\t \t\t\t\t\r\n \t\t\t\tif (element.type == 'select-multiple' || element.type == 'select-one') {\r\n \t\t\t\t\tvar options = element.options;\r\n \t\t\t\t\tfor (j = 0;j < options.length;j++) {\r\n \t\t\t\t\t\tif (options[j].selected) {\r\n \t\t\t\t\t\t\tparams = params + ',\"' + element.name + '\":' + '\"' + options[j].value + '\"';\t\r\n \t\t\t\t\t\t}\r\n \t\t\t\t\t}\r\n \t\t\t\t} else {\t\t\t\t\r\n \t\t\t\t\tif ((element.type == 'radio' || element.type == 'checkbox') && element.checked) {\r\n \t\t\t\t\t\tparams = params + ',\"' + element.name + '\":' + '\"' + elementValue + '\"';\t\r\n \t\t\t\t\t} else if (element.type != 'radio' && element.type != 'checkbox' && element.tagName != 'textarea') {\r\n \t\t\t\t\t\tvar elValue = elementValue;\r\n \t\t\t\t\t\t\r\n \t\t\t\t\t\tif (elValue.indexOf('&') != -1) {\r\n \t\t\t\t\t\t\telValue = elValue.replace(/&/g,'%26');\r\n \t\t\t\t\t\t}\r\n \t\t\t\t\t\t\r\n \t\t\t\t\t\tif (elValue.indexOf('\\n') != -1)\r\n \t\t\t\t\t\t\tcontinue;\r\n \t\t\t\t\t\t\r\n \t\t\t\t\t\tparams = params + ',\"' + element.name + '\":' + '\"' + elValue + '\"';\t\r\n \t\t\t\t\t}\r\n \t\t\t\t}\r\n \t\t\t}\r\n \t\t}\r\n \t}\r\n \tparams += '}]';\r\n\r\n \treturn eval(params)[0];\r\n }", "function getSearchParameters() {\n var prmstr = decodeURIComponent(window.location.search.slice(1));\n return prmstr != null && prmstr != \"\" ? transformToAssocArray(prmstr) : {};\n}", "function ReadQueryParams() {\n const urlParams = new URLSearchParams(location.search)\n\n inputBoxWidth.value = +urlParams.get(paramBoxWidth) || defaultBoxWidth\n inputBoxHeight.value = +urlParams.get(paramBoxHeight) || defaultBoxHeight\n inputBoxRadius.value = +urlParams.get(paramBoxRadius) || defaultBoxRadius\n inputBoxMargin.value = +urlParams.get(paramBoxMargin) || defaultBoxMargin\n inputBoxColor.value = urlParams.get(paramBoxColor) || defaultBoxColor\n inputBgColor.value = urlParams.get(paramBgColor) || defaultBgColor\n inputBoxShadowColor.value = urlParams.get(paramBoxShadowColor) || defaultBoxShadowColor\n inputBoxShadowX.value = +urlParams.get(paramBoxShadowX) || defaultBoxShadowX\n inputBoxShadowY.value = +urlParams.get(paramBoxShadowY) || defaultBoxShadowY\n inputBlurRadius.value = +urlParams.get(paramBlurRadius) || defaultBlurRadius\n inputSpreadRadius.value = +urlParams.get(paramSpreadRadius) || defaultSpreadRadius\n}", "function getQueryParameters() {\n var parameters = {};\n parameters.select = $('input[name=radio-choice-1]:checked').val();\n console.log(\"Selected : \" + parameters.select);\n parameters.query = $('input[name=search]').val();\n console.log(\"Query : \" + parameters.query);\n parameters.true = true;\n return parameters;\n }", "function getParams() {\n return qs.parse(window.location.search);\n}", "getFormData(form) {\n const type = form['query_type'].value || 1\n \n let content = form['query_content'].value\n const values = {\n query: content,\n name: form['query_name'].value,\n uri: form['query_endpoint'].value.trim(),\n params: {\n type: type,\n period: [ content.includes(\"$beginYear\") ? +form['from_year'].value : '', \n content.includes(\"$endYear\") ? +form['to_year'].value : '' ],\n lab: [ content.includes(\"$lab1\") ? form['query_lab1'].value : '', \n content.includes(\"$lab2\") ? form['query_lab2'].value : '' ],\n country: content.includes(\"$country\") ? form['query_country'].value : '',\n list_authors: form['query_list_authors'].value.split(',').map(d => `\"${d.trim()}\"`)\n }\n };\n\n this.getVariables(values.params)\n\n values.params.prefixes = this.getPrefixes()\n \n return values;\n }", "loadQueryParams() {\n queryParamsToFormStore(\n this.args.queryParams,\n this.formStore,\n this.sourceNode\n );\n }", "function get_url_params() {\n var $_GET = {};\n\n document.location.search.replace(/\\??(?:([^=]+)=([^&]*)&?)/g, function () {\n function decode(s) {\n return decodeURIComponent(s.split(\"+\").join(\" \"));\n }\n\n $_GET[decode(arguments[1])] = decode(arguments[2]);\n });\n return $_GET;\n}", "function getRequestParam(request){\n return querystring.parse( url.parse(request.url).query );\n}", "function parseCurrentUrlParams () {\n\t\tme.urlParams = me.paramsToObject(window.location.search.substr(1));\n\t}", "function getParams()\n{\n var idx = document.URL.indexOf('?');\n var params = [];\n if (idx != -1) {\n var pairs = document.URL.substring(idx+1, document.URL.length).split('&');\n for (var i=0; i<pairs.length; i++)\n {\n nameVal = pairs[i].split('=');\n params[nameVal[0]] = nameVal[1];\n }\n }\n return params;\n}", "function initGetVars() {\r\n var parts = window.location.search.substr(1).split(\"&\");\r\n GET = {};\r\n GET['nArgs'] = parts.length;\r\n GET['array'] = new Array();\r\n\r\n for (var i = 0; i < parts.length; i++) {\r\n var temp = parts[i].split(\"=\");\r\n GET[decodeURIComponent(temp[0])] = decodeURIComponent(temp[1]);\r\n GET['array'].push(parts[i]);\r\n }\r\n LMT.GET = GET;\r\n}", "function getParametersFromUrl() {\n let queryDict = {}\n location.search.substr(1).split(\"&\").forEach(function(item) {queryDict[item.split(\"=\")[0]] = item.split(\"=\")[1]})\n return queryDict\n}", "function getFormVariables() {\n return [$(\"#art_name\").val(),\n $(\"#id_field\").val(),\n $(\"#birthyear\").val(),\n $(\"#img_url\").val()\n ]\n}", "function Common_parseUrlParam(){\n\turl = decodeURI(window.location.href);\n\tlet returnParams = {};\n\tparamPos = url.indexOf('?');\n\tif(paramPos<0)\n\t\treturn {};\n\turl = url.substring(paramPos+1);//don't need the '?' any more\n\tfor(;;){\n\t\tparamPos = url.indexOf('=');\n\t\tvalPos = url.indexOf('&');\n\t\tif(paramPos>0 && valPos>0){\n\t\t\treturnParams[url.substring(0,paramPos)] = url.substring(paramPos+1,valPos);\n\t\t\turl = url.substring(valPos+1);\n\t\t}\n\t\telse if(paramPos>0 && valPos<0){\n\t\t\treturnParams[url.substring(0,paramPos)] = url.substring(paramPos+1);\n\t\t\turl='';\n\t\t}\n\t\telse if(paramPos<0){\n\t\t\tbreak;\n\t\t}\n\t\t\n\t}\n\t\n\treturn returnParams;\n\t\n}", "function parseQuery() {\n\tvar query = { };\n\tif(window.location.search.length == 0) {\n\t\t// we don't have a query string\n\t\treturn query;\n\t}\n\t// strip off the leading '?' and split into name=value assignments\t\n\tvar assignments = window.location.search.substring(1).split('&');\n\tfor(var index = 0; index < assignments.length; index++) {\n\t\tvar tokens = assignments[index].split('=');\n\t\tif(tokens.length == 2) {\n\t\t\tquery[tokens[0]] = tokens[1];\n\t\t}\n\t}\n\treturn query;\n}", "function getParams() {\n var res = {}\n var params = location.search.substr(1).split('&')\n\n for (var value; value = params.pop();) {\n var tmp = value.split('=')\n res[tmp[0]] = decodeURIComponent(tmp[1])\n }\n\n return res\n}", "function form_contents() {\n var form = $$('form').first();\n \n var form_els = form.getElements().reject(function(el) {\n return $w(\"_method authenticity_token\").include(el.name);\n });\n var url_encoded = form_els.collect(function(el) {\n return(el.name + \"=\" + el.value);\n });\n \n return url_encoded.join(\"&\");\n}", "function parseQuery() {\n var queryString = window.location.search.substr(1);\n // set all parameters to their default values\n param1 = default1;\n if (queryString.length > 0) {\n // if there's a query string, check for each param within it\n var val1 = queryString.match(/.*param1=([^&]+).*/i);\n if (val1) {\n param1 = val1[1];\n }\n }\n}", "function bodyRequest(body){\n\t/* Process Request Modified from CS 290 Lecture \n\t http://eecs.oregonstate.edu/ecampus-video/CS290/core-content/hello-node/express-forms.html */\n\tvar qParams = [];\n\tfor (var p in body){ /* Loop through request body */\n\t\tqParams.push({'name':p,'value':body[p]})\n\t}\n\treturn qParams; /* Add requrest to context object */\n}", "function getRequest(){\n\tvar params = window.location.search.replace('?','').split('&').reduce(\n\t\tfunction(prev, curr){\n\t\t\tvar temp = curr.split('=');\n\t\t\tprev[decodeURIComponent(temp[0])] = decodeURIComponent(temp[1]);\n\t\t\treturn prev;\n\t\t},{}\n\t);\n\treturn params;\n}", "function getURLParams() {\n\tvar query = window.location.search.substring(1);\n\tvar vars = query.split(\"&\");\n\tvar query_string = {};\n\tfor (var i = 0; i < vars.length; i++) {\n\t\tvar pair = vars[i].split(\"=\");\n\t\tvar key = decodeURIComponent(pair[0]);\n\t\tvar value = decodeURIComponent(pair[1]);\n\t\t// If first entry with this name\n\t\tif (typeof query_string[key] === \"undefined\") {\n\t\t\tquery_string[key] = decodeURIComponent(value);\n\t\t\t// If second entry with this name\n\t\t} \n\t\telse if (typeof query_string[key] === \"string\") {\n\t\t\tvar arr = [query_string[key], decodeURIComponent(value)];\n\t\t\tquery_string[key] = arr;\n\t\t\t// If third or later entry with this name\n\t\t} \n\t\telse {\n\t\t\tquery_string[key].push(decodeURIComponent(value));\n\t\t}\n\t}\n\treturn query_string;\n}", "function parse_post(req, callback) {\n // Pushing things into an array and joining them in the end is faster then concatenating strings.\n var data = [];\n\n req.addListener('data', function(chunk) {\n data.push(chunk);\n });\n\n req.addListener('end', function() {\n callback(querystring.parse(data.join('')));\n });\n}", "getParams() {\n const params = {};\n // Get the values for each parameter\n for (let param of this.operation.params) {\n let id = param.id\n params[id] = document.getElementById(id).value;\n }\n return params;\n }", "function getToObj(){\n var url=window.location.href;\n var info=url.split(\"?\");\n var nameValuePairs=info[1].split(\"&\");\n var len=nameValuePairs.length;\n var obj=new Object();\n obj['len']=len-1;//1st is hidden input as placeholder; <2 means no additional data\n for(var i=1;i<len;i++){//start at 1 because of one hidden input\n var map=nameValuePairs[i].split(\"=\");\n var name =map[0];\n var value=map[1];\n obj[name]=value;\n }\n return obj;\n}", "_resolveQueryData( data ) {\n let obj = {}, pairs = [];\n this._ctype = 'application/x-www-form-urlencode; charset=UTF-8';\n\n // assume JSON string\n if ( data && typeof data === 'string' ) {\n try { obj = JSON.parse( data ); } catch ( e ) { }\n return this._resolveQueryData( obj );\n }\n // FormData object\n if ( data instanceof FormData ) {\n data.forEach( ( value, key ) => { obj[ key ] = value; } );\n return this._resolveQueryData( obj );\n }\n // form element object\n if ( data instanceof HTMLFormElement ) {\n for ( let i = 0; i < data.elements.length; i++ ) {\n let elm = data.elements[ i ];\n let value = elm.value || '';\n\n if ( !elm.name || elm.type === 'file' ) continue;\n if ( elm.type === 'checkbox' ) value = elm.checked ? 1 : 0;\n obj[ elm.name ] = value;\n }\n return this._resolveQueryData( obj );\n }\n // JS object\n if ( data instanceof Object ) {\n for ( let key in data ) {\n if ( !data.hasOwnProperty( key ) || /^\\d+$/.test( key ) ) continue;\n if ( /^(function|object)$/.test( typeof data[ key ] ) ) continue;\n pairs.push( encodeURIComponent( key ) + '=' + encodeURIComponent( data[ key ] ) );\n }\n return pairs.join( '&' );\n }\n // all else\n return '';\n }", "function parseParameters() {\n var pageURL = window.location.href;\n var message = url(\"?message\", pageURL);\n\n if (message == \"submitted\") {\n $(\"#modal-message-submitted\").openModal();\n }\n}", "function get_params() {\n return get_cookie(\"params\");\n}", "getParams() {\n let validator = new Validator();\n let param = {};\n let msg = '';\n\n //email\n let email = this.state.email;\n if (validator.isEmpty(email) && validator.isValidEmail(email)) {\n param['email'] = email;\n }\n else {\n msg = msg + '\\n- ' + AlertConstants.MESSAGE.VALIDATION_ERROR_EMAIL;\n }\n\n //Password\n let password = this.state.password;\n if (validator.isEmpty(password)) {\n param['password'] = password;\n }\n else {\n msg = msg + '\\n- ' + AlertConstants.MESSAGE.VALIDATION_ERROR_PASSWORD;\n }\n\n if (msg.length > 0) {\n //show error\n AlertUtils.showOkAlert(AlertConstants.TITLE.VALIDATION_ERROR, msg);\n return null;\n }\n\n return param;\n }", "function getValues(form) {\n processCheckbox(form);\n processSelect(form);\n processInput(form);\n processTextarea(form);\n setDateTime(helpData);\n if (helpData.kind === 'need') {\n getTime(form)\n }\n helpData.userName = $(\"#username\").val();\n return helpData;\n}", "function parseUrlParams() {\n var search = window.location.search;\n search = search.charAt(0) === \"?\" ? search.substring(1) : search;\n return search.split(\"&\")\n .map(function(pair){ return pair.split(\"=\").map(decodeURIComponent) })\n .reduce( function(obj, pair) { obj[pair[0]] = pair[1]; return obj }, {});\n}", "_getParams(route) {\n var matches = route.match(/:\\w+/g)\n return (matches || []).map(match => {\n return match.substring(1, match.length)\n })\n }", "validate(form_data, form) {\n\n let method = form.method;\n\n //check if data attribute is set. This is for put and delete request\n if (typeof form.dataset.method !== 'undefined') {\n method = form.dataset.method;\n }\n\n return form_data[method](form.action);\n }", "function s(t){var a=e.isFunction(t.url)?t.url():t.url,n=t.type?t.type.toUpperCase():\"GET\",r=e(\"<form>\",{method:\"GET\"===n?\"GET\":\"POST\",action:a,style:\"display:none\"});\"GET\"!==n&&\"POST\"!==n&&r.append(e(\"<input>\",{type:\"hidden\",name:\"_method\",value:n.toLowerCase()}));var f=t.data;if(\"string\"==typeof f)e.each(f.split(\"&\"),function(t,a){var n=a.split(\"=\");r.append(e(\"<input>\",{type:\"hidden\",name:n[0],value:n[1]}))});else if(e.isArray(f))e.each(f,function(t,a){r.append(e(\"<input>\",{type:\"hidden\",name:a.name,value:a.value}))});else if(\"object\"==typeof f){var o;for(o in f)r.append(e(\"<input>\",{type:\"hidden\",name:o,value:f[o]}))}e(document.body).append(r),r.submit()}", "function parseSearchParameters(keys) {\n var parameters = {}, params;\n params = location.search.substr(1).split('&').sort();\n\n $.each(keys, function(i,k){\n var values = [];\n for (var i = 0; i < params.length; i++) {\n if (k == params[i].substr(0, k.length)) {\n values.push(params[i].split('=').pop());\n }\n }\n parameters[k] = values;\n });\n\n /**\n * Get value for k location search parameter.\n *\n * @param k\n */\n function getParams(k) {\n\n // returns all parameters.\n if (typeof k == 'undefined') {\n return JSON.parse(JSON.stringify(parameters));\n }\n\n return typeof parameters[k] != 'undefined' ? parameters[k].slice(0) : [];\n }\n\n return getParams;\n }", "function getParameters() {\n\t\t\t var searchString = window.location.search.substring(1)\n\t\t\t\t, params = searchString.split(\"&\")\n\t\t\t\t, hash = {}\n\t\t\t\t;\n\n\t\t\t for (var i = 0; i < params.length; i++) {\n\t\t\t\tvar val = params[i].split(\"=\");\n\t\t\t\thash[unescape(val[0])] = unescape(val[1]);\n\t\t\t }\n\t\t\t return hash;\n\t\t\t}", "function parseQueryString() {\n var query = {};\n var args = document.location.search.substring(1).split('&');\n for (var arg in args) {\n var m = args[arg].split('=');\n query[decodeURIComponent(m[0])] = decodeURIComponent(m[1]);\n }\n\n return query;\n}", "function Main_ParseUrlParameters()\n{\n\t//create an url object\n\tvar url = {};\n\n\t//get the url string\n\tvar strURL = location.href;\n\t//search for first query\n\tvar nAmp = strURL.indexOf(\"?\");\n\tif (nAmp != -1)\n\t{\n\t\t//correct url\n\t\tstrURL = strURL.substr(nAmp + 1);\n\t\t//split into pairs\n\t\tstrURL = strURL.split(\"&\");\n\t\t//loop through them\n\t\tfor (var i = 0, c = strURL.length; i < c; i++)\n\t\t{\n\t\t\t//split this into the name/value pair\n\t\t\tvar pair = strURL[i].split(\"=\");\n\t\t\tif (pair.length == 2)\n\t\t\t{\n\t\t\t\t//add this\n\t\t\t\turl[pair[0].toLowerCase()] = pair[1];\n\t\t\t}\n\t\t}\n\t\t//we have a root?\n\t\tif (url.startid)\n\t\t{\n\t\t\t//add root\n\t\t\turl.StartStateId = url.startid;\n\t\t\t//has extension?\n\t\t\tif (url.StartStateId.indexOf(__NEMESIS_EXTENSION) != -1)\n\t\t\t{\n\t\t\t\t//remove it\n\t\t\t\turl.StartStateId.replace(__NEMESIS_EXTENSION, \"\");\n\t\t\t}\n\t\t}\n\t}\n\t//return it\n\treturn url;\n}", "function getFormData(){\n var result = {};\n var fields = document.querySelectorAll('[name=linkform] [name]');\n\n for(var i in fields){\n var name = fields[i].name;\n // Excludes useless fields.\n if(['save_edit', 'cancel_edit', 'delete_link', 'token', 'returnurl'].indexOf(name) < 0){\n if(typeof name === 'string' && name.length > 0){\n if(fields[i].type === 'checkbox'){\n result[name] = fields[i].checked;\n } else if(fields[i].type === 'radio'){\n if(fields[i].checked){\n result[name] = fields[i].value;\n }\n } else{\n result[name] = fields[i].value;\n }\n }\n\n if(result[name]){\n result[name] = result[name];\n }\n }\n }\n\n return result;\n}", "function queryRequest(query){\n\t/* Process Request Modified from CS 290 Lecture \n\t http://eecs.oregonstate.edu/ecampus-video/CS290/core-content/hello-node/express-forms.html */\n\tvar qParams = [];\n\tfor (var p in query){ /* Loop through request query */\n\t\tqParams.push({'name':p,'value':query[p]})\n\t}\n\treturn qParams; /* Add requrest to context object */\n\t//return context;\n}", "function getFormValues(){\r\n\tvar values=\"\",eType,element;\r\n\tvar elements=hatsForm.elements;\r\n\tfor (var i=0,iL=elements.length; i<iL; ++i){\r\n\t\tvar elementVal = \"\";\r\n\t\telement=elements[i];\r\n\t\teType=element.type;\r\n\t\tvar computeValue = true;\r\n\t\tif ((eType == \"radio\") ||(eType == \"checkbox\"))\r\n\t\t\tcomputeValue = element.checked;\r\n\t\tif(computeValue){\r\n\t\t\tif (appletInitialized && document.HATSApplet){\r\n\t\t\t\telementVal = document.HATSApplet.encode(element.value,document.charset);\r\n\t\t\t}else if(window.encodeURIComponent){\r\n\t\t\t\telementVal = encodeURIComponent(element.value);\r\n\t\t\t}else if (window.escape){\r\n\t\t\t\telementVal = escape(element.value);\r\n\t\t\t}\r\n\t\t\tvalues += \"&\" + element.name + \"=\" + elementVal;\r\n\t\t}\r\n\t}\r\n\treturn values;\r\n}", "function getFormValues(){\n var form = document.getElementById (\"the_form\");\n var todo = form.elements.task.value;\n return {task: todo}; \n}", "function fetchformdata() {\nlet form = document.forms[0];\nlet day, month, year, gender;\n\ngender = form.gender.value;\n\nday = parseInt(form.day.value);\nmonth = parseInt(form.month.value);\nyear = parseInt(form.year.value);\n\nreturn [gender, day, month, year];\n\n}", "function getHiddenFields(){\r\n\t\tvar str;\r\n\t\tvar secondaryphone = 'SecondaryPhone='+getSecondaryPhone();\r\n\t\tvar mobilephone = 'MobilePhone='+getSecondaryPhone();\r\n\t\tvar residencetime = getResidenceTime();\r\n\t\tvar employmenttime = getEmploymentTime();\r\n\t\tvar age = getAge();\r\n\t\tvar birthday = 'DateOfBirthMonth='+jQuery('#DateOfBirth').val().substr(0,2)+'&DateOfBirthDay='+jQuery('#DateOfBirth').val().substr(3,2)+'&DateOfBirthYear='+jQuery('#DateOfBirth').val().substr(6,4);\r\n\t\tvar appType2 = getAppType2();\r\n\t\tvar loanamountpl = checkLoanAmountPL();\r\n\t\t\r\n\t\treturn secondaryphone+'&'+mobilephone+'&'+residencetime+'&'+employmenttime+'&'+age+'&'+birthday+'&'+appType2+'&'+loanamountpl;\r\n\t}", "function getFormValues(){\n\nsignupInfo.email = document.getElementById('email').value;\nsignupInfo.username = document.getElementById('username').value;\nsignupInfo.password = document.getElementById('password').value;\nsignupInfo.firstName = document.getElementById('firstName').value;\nsignupInfo.lastName = document.getElementById('lastName').value;\n\nsendToApi ();\n}", "function getUrlParams(){\r\n var url = decodeURIComponent(location.href);\r\n var query = url.split('?')[1];\r\n var params = {};\r\n if (query !== ''){\r\n var arr = query.split('&');\r\n for (var i of arr) {\r\n var entry = i.split('=');\r\n var key = entry[0];\r\n var value = entry[1];\r\n params[key] = value;\r\n }\r\n }\r\n return params;\r\n}", "function ekGetSearchParams() {\n var result = {};\n var searchParams = window.location.href.split('?');\n if (searchParams && searchParams.length > 1) {\n var vals = searchParams[1].split('&');\n for (var i = 0; i < vals.length; i++) {\n var next = vals[i].split('=');\n var key = next[0];\n var val = decodeURIComponent(next[1].replace(/\\+/g,' '));\n result[key] = val;\n }\n }\n return result;\n }", "function getUrlParams() {\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for (var i = 0; i < hashes.length; i++) {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n }", "getParameter (\n\t\trequest // command to parse\n\t) {\n\t\t// return all string (parameter) after # character (# isn't include)\n\t\treturn request.substring(request.lastIndexOf(\"#\") + 1); \n\t}", "function getParamsForTimeFrame(){\n\t\tfromTimeVal = $('#timeRangeFromValue').val();\n\t\ttoTimeVal = $('#timeRangeToValue').val();\n\t\tsearchEntity = $('#searchEntity').val();\n\t}", "function GetCgiParameters() {\n let url = window.location.search.substring(1);\n let output = {};\n let settings = url.split('&');\n for (let i=0; i<settings.length; i++) {\n let pair = settings[i].split('=');\n pair[0] = decodeURIComponent(pair[0]);\n pair[1] = decodeURIComponent(pair[1]);\n if (typeof output[pair[0]] === 'undefined') {\n output[pair[0]] = pair[1];\n } else if (typeof output[pair[0]] === 'string') {\n let arr = [ output[pair[0]], pair[1] ];\n output[pair[0]] = arr;\n } else {\n output[pair[0]].push(pair[1]);\n }\n }\n return output;\n}", "function getUrlParameters() {\n\tvar vars = [], hash;\n\tvar hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n\tfor (var i = 0; i < hashes.length; i++) {\n\t\thash = hashes[i].split('=');\n\t\tvars.push(hash[0]);\n\t\tvars[hash[0]] = hash[1];\n\t}\n\treturn vars;\n}", "function getQueryStrings(){\n var queryString = window.location.search || '';\n var keyValPairs = [];\n var params = {};\n queryString = queryString.substr(1);\n\n if (queryString.length){\n keyValPairs = queryString.split('&');\n for (pairNum in keyValPairs){\n var key = keyValPairs[pairNum].split('=')[0];\n if (!key.length) continue;\n if (typeof params[key] === 'undefined')\n params[key] = [];\n params[key].push(keyValPairs[pairNum].split('=')[1]);\n }\n }\n return params;\n}", "function readquerystring() {\n if ($location.search() && $location.search().code != null && $location.search().code != '') {\n tools_service.showPreloader($scope, 'show');\n $scope.selectprogramforedit($location.search().code, function (program) {\n //$scope.programs[program];\n $scope.currentaction = 'editprogram';\n $scope.showcategoryselector = true; \n var tab = $scope.tab.get('whattodo'); //lets go to the editor...\n tab.next();\n tools_service.showPreloader($scope, 'hide');\n });\n }\n }", "function ParsedQueryString() {}", "function ParsedQueryString() {}", "function getURLParams (req) {\n\tvar urlParts = url.parse(req.url, true);\n\treturn urlParts.query;\n}", "function urlencoded_parse(input, isindex) {\n\t\t\t\t\tvar sequences = input.split('&');\n\t\t\t\t\tif (isindex && sequences[0].indexOf('=') === -1)\n\t\t\t\t\t\tsequences[0] = '=' + sequences[0];\n\t\t\t\t\tvar pairs = [];\n\t\t\t\t\tsequences.forEach(function (bytes) {\n\t\t\t\t\t\tif (bytes.length === 0) return;\n\t\t\t\t\t\tvar index = bytes.indexOf('=');\n\t\t\t\t\t\tif (index !== -1) {\n\t\t\t\t\t\t\tvar name = bytes.substring(0, index);\n\t\t\t\t\t\t\tvar value = bytes.substring(index + 1);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tname = bytes;\n\t\t\t\t\t\t\tvalue = '';\n\t\t\t\t\t\t}\n\t\t\t\t\t\tname = name.replace(/\\+/g, ' ');\n\t\t\t\t\t\tvalue = value.replace(/\\+/g, ' ');\n\t\t\t\t\t\tpairs.push({ name: name, value: value });\n\t\t\t\t\t});\n\t\t\t\t\tvar output = [];\n\t\t\t\t\tpairs.forEach(function (pair) {\n\t\t\t\t\t\toutput.push({\n\t\t\t\t\t\t\tname: decodeURIComponent(pair.name),\n\t\t\t\t\t\t\tvalue: decodeURIComponent(pair.value)\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t\treturn output;\n\t\t\t\t}", "submit() {\n const namedFieldNode = this.$['form-fields'].assignedNodes()\n .filter(node => node.hasAttribute && node.hasAttribute(\"name\"));\n\n const allValid = this.novalidate || namedFieldNode.every(node => node.validate ? node.validate() : true);\n\n if (allValid) {\n const reqData = namedFieldNode.reduce((result, node) => {\n const key = node.getAttribute('name');\n const value = node.value;\n result[key] = value;\n return result;\n }, {});\n const method = (this.method || '').toUpperCase();\n if(method === 'GET') {\n this._get(reqData);\n } else if(method === 'POST') {\n this._post(reqData);\n } else {\n throw new TypeError(`Unsupported method: ${this.method}`);\n }\n }\n }", "function GetCgiParameters() {\n var url = window.location.search.substring(1);\n var output = {};\n var settings = url.split('&');\n for (var i=0; i<settings.length; i++) {\n var pair = settings[i].split('=');\n pair[0] = decodeURIComponent(pair[0]);\n pair[1] = decodeURIComponent(pair[1]);\n if (typeof output[pair[0]] === 'undefined') {\n output[pair[0]] = pair[1];\n } else if (typeof output[pair[0]] === 'string') {\n var arr = [ output[pair[0]], pair[1] ];\n output[pair[0]] = arr;\n } else {\n output[pair[0]].push(pair[1]);\n }\n }\n return output;\n}" ]
[ "0.64322215", "0.6404169", "0.63484", "0.62563497", "0.62064284", "0.61928874", "0.6158871", "0.6123546", "0.6111088", "0.60739666", "0.6024206", "0.6011635", "0.5980322", "0.59562236", "0.59357077", "0.5934784", "0.588576", "0.5860076", "0.5853899", "0.5852038", "0.584296", "0.5837881", "0.5802806", "0.57943344", "0.5786388", "0.57796264", "0.57730687", "0.5769847", "0.57637405", "0.57579356", "0.5755097", "0.5737591", "0.5734733", "0.5722341", "0.57188445", "0.569894", "0.5693772", "0.5685959", "0.5678215", "0.56739694", "0.56656724", "0.5657439", "0.5654424", "0.5643331", "0.5637431", "0.563696", "0.56094384", "0.5608573", "0.5606242", "0.56042355", "0.5599275", "0.5597831", "0.55792874", "0.55732787", "0.55721897", "0.5563613", "0.55597556", "0.5554641", "0.5553683", "0.55527806", "0.5532484", "0.55153316", "0.5505077", "0.5502819", "0.54946756", "0.54883903", "0.54852134", "0.5482965", "0.54747397", "0.5456538", "0.54481995", "0.54467463", "0.5445769", "0.54444903", "0.5443662", "0.5443536", "0.54295975", "0.54281414", "0.54024535", "0.5396611", "0.53963315", "0.53860503", "0.53851885", "0.53842354", "0.5382642", "0.5381531", "0.53751355", "0.53751296", "0.5370752", "0.53633916", "0.536314", "0.53468657", "0.5345885", "0.5343033", "0.5342916", "0.5342916", "0.53399366", "0.53392977", "0.53361535", "0.53327996" ]
0.5986725
12
parsing arguments for calling action with predefined params
function parseArguments(args){ var data,success,dataType; if(typeof(args[1])=="object"){ data = args[1]; if(typeof(args[2])=="function"){ success = args[2]; if(typeof(args[3])=="string"){ dataType = args[3]; } } }else if(typeof(args[1])=="function"){ success = args[1]; if(typeof(args[2])=="string"){ dataType = args[2]; } } else if(typeof(args[1])=="string"){ dataType = args[1]; } return { url:args[0], data: data, success: success, dataType: dataType } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function main(args) {\n // propagate errors\n if (args.error) return args\n // unescape params: { action, state, foo, params: { bar } } becomes { action, state, params: { foo, bar } }\n const action = args.action\n const state = args.state\n const params = args.params\n delete args.action\n delete args.state\n delete args.params\n return { action, state, params: Object.assign(args, params) }\n}", "parsePerformActionsParams(params) {\n return Parser.Input.parsePerformActionsParams(params);\n }", "parseInput(args) {\n let validArgs = {\n a: 'add',\n add: 'add',\n l: 'list',\n list: 'list',\n d: 'delete',\n delete: 'delete',\n u: 'update',\n update: 'update',\n };\n\n let allCommands = Object.keys(args);\n let command = allCommands.filter(arg => validArgs[arg])[0];\n\n return {\n action: validArgs[command],\n payload: typeof args[command] === 'string' ? args[command] : undefined,\n category: args.category,\n text: args.text,\n };\n }", "function receiveArguments()\n{\n if (arguments[0] && arguments[0].designTimeObj)\n {\n DS_DESIGN_TIME_ARG = arguments[0].designTimeObj;\n if (arguments[0].insertObj)\n {\n INSERT_OPTIONS_ARG = arguments[0].insertObj;\n }\n }\n}", "__buildActionCodeUri(action)\n {\n var $this = this;\n var uri = action.uri;\n\n if (!action.args) {\n return uri;\n }\n\n // Traduzir params names\n Arr.each(action.args, (arg_name, arg_info) => {\n if ((arg_info != null) && (arg_info.type && (arg_info.type == 'param'))) {\n uri = Str.replaceAll('{' + arg_name + '}', $this.defs.strVar(arg_name), uri);\n }\n });\n\n return uri;\n }", "function Params() {\n if (currentToken() == \"(\") {\n nextToken();\n ArgList();\n if (currentToken() == \")\") {\n nextToken();\n return;\n } else {\n let errorMessage = \"Não foi encontrado o fechamento da lista de parâmetros da função\";\n handleError(errorMessage);\n nextToken();\n }\n } else {\n return;\n }\n }", "getAdditionalArgs(action, currentNode) {\n switch(action) {\n case this.count:\n return [];\n case this.list:\n return [currentNode.value];\n default:\n console.log(`Error determining additional args for the action ${action}`);\n }\n }", "parseAbilityArguments(policyOrAction, args) {\n const tokens = policyOrAction.split('.');\n const usingCustomAuthorizer = args.length && args[0] instanceof ActionsAuthorizer;\n let output = {\n action: policyOrAction,\n authorizer: this,\n args: args,\n };\n if (usingCustomAuthorizer) {\n output.authorizer = args.shift();\n output.args = args;\n }\n if (tokens.length > 1) {\n output.policy = tokens.shift();\n output.action = tokens.join('.');\n }\n return output;\n }", "function UserInputs(action, input) {\n switch (action) {\n case \"concert-this\":\n runBandsInTown(input);\n fixString(input)\n break;\n case \"spotify-this-song\":\n runSpotify(input);\n fixString(input)\n break;\n case \"movie-this\":\n runOmdb(input);\n fixString(input)\n break;\n case \"do-what-it-says\":\n runRandom(input);\n break;\n default:\n console.log(\"\\n--------------------------------------------------------\");\n console.log(\n \"Please enter a valid argument, such as:\\n\\nnode liri.js movie-this [MOVIE TITLE]\\n\\nnode liri.js spotify-this-song [SONG TITLE]\\n\\nnode liri.js concert-this [ARTIST NAME]\\n\\nnode liri.js do-what-it-says\"\n );\n console.log(\n \"--------------------------------------------------------\\n\\n\"\n );\n }\n}", "action(params) {\n this.beforeAction();\n this.setParams(params);\n Dispatcher.action(this, params);\n }", "function checkArgs(req, res) {\n for (rid in req.query) {\n for (id in parmlist) {\n if (id == rid) parmlist[id](req.params[0], req.query[rid]);\n }\n }\n}", "function main(params) {\n var name = params.name || params.payload || 'stranger';\n var place = params.place || 'somewhere';\n return {payload: 'Hello, ' + name + ' from ' + place + ' !'};\n}", "parseArgs () {\n for (; this.argsIterator.hasNext(); this.argsIterator.next()) {\n const prefix = this.argsIterator.current()\n if (prefix.charAt(0) == '-') {\n this.parseArgParamter(prefix.substring(1))\n } else {\n throw new Error(`Error Args Prefix:${prefix}`)\n }\n }\n }", "function triggerParamsActions () {\r\n if ( checkURLParam('autoplay') || checkURLParam('isAutoPlay') ) playWrap();\r\n if ( checkURLParam('agenda') ) sectionsScreen();\r\n if ( checkURLParam('hidebuttons') || checkURLParam('isHideButtons') ) hideGUIForever();\r\n }", "arguments(desc) {\n return this.parseExpectedArgs(desc.split(/ +/));\n }", "function exampleActionCreator(...params) {\n return {\n type: 'EXAMPLE_ACTION',\n payload: params,\n };\n}", "function parseArguments(url,data,success,dataType){if($.isFunction(data))dataType=success,success=data,data=undefined;if(!$.isFunction(success))dataType=success,success=undefined;return{url:url,data:data,success:success,dataType:dataType};}", "function testParams(arg1, arg2) {\n var params = [];\n for (var _i = 2; _i < arguments.length; _i++) {\n params[_i - 2] = arguments[_i];\n }\n if (params.length > 0) {\n console.log(\"--------------------Rest Params---------------------\");\n for (var index = 0; index < params.length; index++) {\n console.log(\"Params \" + index + \" = \" + params[index]);\n }\n console.log(\"--------------------Rest Params---------------------\");\n console.log(\"--------------------argument variable---------------------\");\n for (var index = 0; index < arguments.length; index++) {\n console.log(\"Arguments \" + index + \" = \" + arguments[index]);\n }\n console.log(\"--------------------argument variable---------------------\");\n console.log(\"--------------------normal param---------------------\");\n console.log(\"arg1 = \" + arg1);\n console.log(\"arg2 = \" + arg2);\n console.log(\"--------------------normal param---------------------\");\n }\n}", "function args() {\n\n}", "function parseGoTo(params, callback) {\n const coordinates = params.split(',');\n if (coordinates.length === 2) {\n const xVal = coordinates[0];\n const yVal = coordinates[1];\n\n if (!isNaN(yVal) && !isNaN(xVal)) {\n //send goTo request with koordinates\n sendMsg('app_goto_target', [parseInt(xVal), parseInt(yVal)]);\n callback();\n } else adapter.log.error('GoTo need two koordinates with type number');\n adapter.log.info('xVAL: ' + xVal + ' yVal: ' + yVal);\n\n } else {\n adapter.log.error('GoTo only work with two arguments seperated by ', '');\n }\n}", "function normalizeArguments(caller, args) {\n let mut = args.slice();\n\n if (isCallingWithCall(caller)) {\n // Whenever the action was called .call we want to remove the context parameter\n mut.shift();\n } else if (isCallingWithApply(caller)) {\n // Whenever the action was called with .apply we want to get the arguments with which the function\n // would actually get called\n mut = mut[1].elements.slice();\n }\n\n // scheduleOnce takes in the queue name as the first parameter so we have to remove it have a similar\n // structure as \"once\"\n if (cleanCaller(caller).indexOf(SCHEDULE_ONCE) > -1) {\n mut.shift();\n }\n\n return mut;\n}", "arguments(desc) {\n return this._parseExpectedArgs(desc.split(/ +/));\n }", "arguments(desc) {\n return this._parseExpectedArgs(desc.split(/ +/));\n }", "arguments(desc) {\n return this._parseExpectedArgs(desc.split(/ +/));\n }", "arguments(desc) {\n return this._parseExpectedArgs(desc.split(/ +/));\n }", "function parseInput(input) {\n\tvar trimmed = input.trim();\n\tvar inputs = trimmed.split(\" \");\n\tcommand = inputs[0];\n\tinputs.shift();\n\targuments = inputs;\n\tvar known = false;\n\tvar availActions = actions;\n\t//new scope code - change which functions we're looking at depending on the scope\n\tif(scope === 'shop') {\n\t\tavailActions = shopActions\n\t}\n\t//\n\tfor(i = 0; i < (arguments.length + 1) && !known; i++) {\n\t\tfor(j = 0; j < availActions.length; j++) {\n\t\t\tif(command.toUpperCase() === availActions[j].toUpperCase()) {\n\t\t\t\tknown = true;\n\t\t\t}\n\t\t}\n\t\tif(!known) {\n\t\t\tcommand = command + \" \" + arguments[0];\n\t\t\targuments.shift();\n\t\t}\n\t}\n\treturn arguments.join(\" \");\n}", "function UsingParams(pRequired, pDefault, pOptional) {\n if (pDefault === void 0) { pDefault = \"DBS-ID\"; }\n var pRest = [];\n for (var _i = 3; _i < arguments.length; _i++) {\n pRest[_i - 3] = arguments[_i];\n }\n console.log(pRequired);\n console.log(pDefault);\n console.log(pOptional);\n console.log(pRest);\n}", "dispatch(invocation) {\n const finish = function finish(err) {\n for (var _len = arguments.length, results = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n results[_key - 1] = arguments[_key];\n }\n\n const serialized = [err != null ? { message: err.message } : null];\n\n if (results && results.length) {\n serialized.push.apply(serialized, results);\n }\n\n invocation.callback(invocation, JSON.stringify(serialized));\n };\n\n const parameters = JSON.parse(invocation.args);\n\n // console.log(invocation.name + '(' + JSON.stringify(parameters) + ')');\n\n if (invocation.name === 'httpRequest') {\n return this.httpRequest(...parameters, finish);\n } else if (invocation.name === 'log') {\n this.log(...parameters);\n return finish(null);\n } else if (invocation.name === 'error') {\n this.error(...parameters);\n return finish(null);\n }\n\n return finish(null);\n }", "function handleAction(action, argument) {\n \n switch (action) {\n //concert this\n case \"concert-this\":\n //Grabs the artistName arguement\n var artistName = argument;\n //If artistName is not provided defaults to Avatar\n if (artistName === \"\") {\n lookupAvatar();\n } else {\n //Gets the event info for artist name\n getEventInfo(artistName);\n }\n break;\n //Gathers song information from spotify API\n case \"spotify-this-song\":\n //Grabs the songTitle argument\n var songTitle = argument;\n //if no songTitle is provided then defaults to \"All the small things\"\n if (songTitle === \"\") {\n lookupSpecificSong();\n } else {\n //Gets the song info for the specified song\n getSongInfo(songTitle);\n }\n break;\n //Gets Movie information\n case \"movie-this\":\n //Grabs the movieTitle argument\n var movieTitle = argument;\n //If no movieTitle is provided then defaults to \"Mr. Nobody\"\n if (movieTitle === \"\") {\n lookupSpecificMovie();\n } else {\n //Gets the movie info for the specific movie\n getMovieInfo(movieTitle);\n }\n break;\n //do what it says\n case \"do-what-it-says\":\n //Performs the action indicated in the random.txt file\n doWhatItSays();\n break;\n }\n}", "function action(...args) {\n return (type) => createAction(type, ...args);\n}", "function args() {\n\t\tvar params = slice.call(arguments);\n\t\tparams.isArgs = true;\n\t\treturn params;\n\t}", "function foo() {\n var url = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'www.wikipedia.com';\n var message = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'Welcome to wikipedia';\n console.log(\"Argument with Default Parameter Url =\" + url);\n console.log(\"Argument with Default Parameter message =\" + message);\n}", "function parseArgument(lexer$$1) {\n var start = lexer$$1.token;\n return {\n kind: kinds.ARGUMENT,\n name: parseName(lexer$$1),\n value: (expect(lexer$$1, lexer.TokenKind.COLON), parseValueLiteral(lexer$$1, false)),\n loc: loc(lexer$$1, start)\n };\n}", "function doAction(action) {\n // action.apply(human, ['My firstname is:']);\n // action.call(human, 'My firstname is:');\n action('My firstname is:');\n}", "function handle_args_list(args_list){\n arguments_list = args_list.split(', ');\n}", "function SimpleArgs() {\r\n}", "function doSomething(action, argument) {\n\n\tif (!argument) argument = getThirdArgument();\n\n\tswitch (action) {\n\n\t\t// Gets list of tweets.\n\n\t\tcase \"my-tweets\":\n\n\t\t\tgetMyTweetFeeds();\n\n\t\t\tbreak;\n\n\t\t\t// Gets song information.\n\n\t\tcase \"spotify-this-song\":\n\n\t\t\t// First gets song title argument.\n\n\t\t\tvar songTitle = argument;\n\n\t\t\t// If no song title provided, defaults to specific song.\n\n\t\t\tif (songTitle === \"\") {\n\n\t\t\t\tlookupSpecificSong();\n\n\t\t\t\t// Else looks up song based on song title.\n\n\t\t\t} else {\n\n\t\t\t\t// Get song information from Spotify.\n\n\t\t\t\tgetSongInfo(songTitle);\n\n\t\t\t}\n\n\t\t\tbreak;\n\n\t\t\t// Gets movie information.\n\n\t\tcase \"movie-this\":\n\n\t\t\t// First gets movie title argument.\n\n\t\t\tvar movieTitle = argument;\n\n\t\t\t// If no movie title provided, defaults to specific movie.\n\n\t\t\tif (movieTitle == \"\") {\n\n\t\t\t\tgetMovieInfo(\"MR. NOBODY\");\n\n\t\t\t\t// Else looks up song based on movie title.\n\n\t\t\t} else {\n\n\t\t\t\tgetMovieInfo(movieTitle);\n\n\t\t\t}\n\n\t\t\tbreak;\n\n\t\t\t// Gets text inside file, and uses it to do something.\n\n\t\tcase \"do-what-it-says\":\n\n\t\t\tdoWhatItSays();\n\n\t\t\tbreak;\n\n\t}\n\n}", "function parseArgs() {\n var args = {};\n var query = document.location.search.substring(1);\n var pairs = query.split('&');\n for (var i = 0; i < pairs.length; i++) {\n pos = pairs[i].indexOf('=');\n if (pos == -1) continue;\n var argname = pairs[i].substring(0, pos);\n var value = pairs[i].substring(pos+1);\n args[argname] = value;\n }\n return args;\n }", "function importRunArgs(arg0, arg1, arg2) {\n var opts = {options: {}};\n if (utils.isFunction(arg1)) {\n opts.callback = arg1;\n } else if (utils.isFunction(arg2)) {\n opts.callback = arg2;\n // identify legacy input format (used by some tests)\n opts.legacy = arg1 && guessInputContentType(arg1) != null;\n opts.input = arg1;\n } else {\n // if no callback, create a promise and a callback for resolving the promise\n opts.promise = new Promise(function(resolve, reject) {\n opts.callback = function(err, data) {\n if (err) reject(err);\n else resolve(data);\n };\n });\n }\n if (!opts.legacy && utils.isObject(arg1)) {\n if (arg1.xl) {\n // options for runCommandsXL()\n opts.options = arg1;\n } else {\n // input data for runCommands() and applyCommands()\n opts.input = arg1;\n }\n }\n return opts;\n }", "doExecute(action, ...args) {\n if(!Reflect.has(this.service, action)){\n throw Error(`service ${this.name} hasnt action ${action}`)\n }\n return this.service[action](...args)\n }", "executeAction(actionMetadata, action, interceptorFns) {\n // compute all parameters\n const paramsPromises = actionMetadata.params\n .sort((param1, param2) => param1.index - param2.index)\n .map((param) => this.parameterHandler.handle(action, param));\n const controllerInstance = actionMetadata.controllerMetadata.instance;\n const Dto = Reflect.getMetadata('design:returntype', controllerInstance, actionMetadata.method);\n // after all parameters are computed\n return Promise.all(paramsPromises).then(async (params) => {\n let body = {};\n let response;\n // execute action and handle result\n const allParams = actionMetadata.appendParams ? (actionMetadata.appendParams(action).concat(params)) : params;\n if (actionMetadata.methodOverride) {\n response = actionMetadata.methodOverride(actionMetadata, action, allParams);\n }\n else {\n response = await controllerInstance[actionMetadata.method].apply(controllerInstance, params);\n }\n if (response &&\n response._base &&\n response._base() === execption_1.PYIThrows) {\n const execption = new Proxy(new response(), {\n get: (t, p) => {\n if (t[p]) {\n return t[p];\n }\n else {\n return controllerInstance[p];\n }\n },\n set: (t, p, value) => {\n t[p] = value;\n return true;\n }\n });\n if (Dto &&\n Dto._base &&\n Dto._base() === dto_1.PYIDto) {\n try {\n const data = await execption.throws();\n body = (new Dto(data));\n }\n catch (error) {\n body = (new Dto(body)).throws(error);\n }\n }\n else {\n body = await execption.throws();\n }\n }\n else {\n body = await response;\n }\n return await this.handleCallMethodResult(body, actionMetadata, action, interceptorFns);\n }).catch(async (error) => {\n if (Dto &&\n Dto._base &&\n Dto._base() === dto_1.PYIDto) {\n const body = (new Dto({})).throws(error);\n return await this.handleCallMethodResult(body, actionMetadata, action, interceptorFns);\n }\n else {\n return this.driver.handleError(error, actionMetadata, action);\n }\n // otherwise simply handle error without action execution\n // return this.driver.handleError(error, actionMetadata, action);\n });\n }", "function parseArguments(url, data, success, dataType) {\n\t if ($.isFunction(data)) dataType = success, success = data, data = undefined;\n\t if (!$.isFunction(success)) dataType = success, success = undefined;\n\t return {\n\t url: url,\n\t data: data,\n\t success: success,\n\t dataType: dataType\n\t };\n\t }", "function validateArgs() {\n if (!getAction(args)) {\n errorHandler(new Error('there is no the following required argument: --action'));\n }\n if (!getShift(args)) {\n errorHandler(new Error('there is no the following required argument: --shift'));\n }\n const fs = require('fs');\n let file = getInputFile(args);\n if (file) {\n fs.access(file, fs.constants.R_OK, err => errorHandler(err));\n }\n file = getOutputFile(args);\n if (file) {\n fs.access(file, fs.constants.W_OK, err => errorHandler(err));\n }\n}", "function doSomething(action, argument) {\n /* Controls optional third argument.\n Defines specific data relating to the action.\n For example, when requesting song information,\n you can pass in a song title. */\n argument = getThirdArgument();\n\n switch (action) {\n\n // Get list of tweets\n case \"my-tweets\":\n getMyTweets();\n break;\n\n // Gets song information\n case \"spotify-this-song\":\n\n // First gets song title argument\n var songTitle = argument;\n\n // If no song title provided, defaults to specific song\n if (songTitle === \"\") {\n lookupSpecificSong();\n \n // Else looks up song based on song title\n } else {\n // Get song information from Spotify\n getSongInfo(songTitle);\n }\n break;\n\n // Gets movie information\n case \"movie-this\":\n\n // First gets movie title argument\n var movieTitle = argument;\n\n // If no movie title provided, defaults to specific movie\n if (movieTitle === \"\") {\n getMovieInfo(\"Mr. Nobody\");\n \n // Else looks up song based on movie title\n } else {\n getMovieInfo(movieTitle);\n }\n break;\n\n // Gets text inside file, and uses it to do something\n case \"do-what-it-says\":\n doWhatItSays();\n break;\n }\n}", "function parseArgument(lexer) {\n\t var start = lexer.token;\n\t return {\n\t kind: _kinds.ARGUMENT,\n\t name: parseName(lexer),\n\t value: (expect(lexer, _lexer.TokenKind.COLON), parseValueLiteral(lexer, false)),\n\t loc: loc(lexer, start)\n\t };\n\t}", "function parseArgument(lexer) {\n\t var start = lexer.token;\n\t return {\n\t kind: _kinds.ARGUMENT,\n\t name: parseName(lexer),\n\t value: (expect(lexer, _lexer.TokenKind.COLON), parseValueLiteral(lexer, false)),\n\t loc: loc(lexer, start)\n\t };\n\t}", "function parseArguments( url, data, success, dataType ) {\n if ( $.isFunction( data ) ) dataType = success, success = data, data = undefined\n if ( !$.isFunction( success ) ) dataType = success, success = undefined\n return {\n url : url,\n data : data,\n success : success,\n dataType: dataType\n }\n }", "function callAction(action, activator, sourceInterface, targetInterface, transitionInterface) {\r\n var nodeId = swui_piece(activator.id,idSeparator,1,2).replace('id','');\r\n var url = \"\";\r\n var params = \"\";\r\n if (action.match(\"swui:submitForm\") != null) {\r\n // Submits a form\r\n url = action.replace(\"swui:submitForm(\",\"\");\r\n url = url.replace(\")\",\"\")\r\n var form = findForm(activator);\r\n params = buildPars(form);\r\n if (targetInterface != '') { params = params + \"swuiInterface=\" + targetInterface + \"&\"; }\r\n } else {\r\n // Calls an action\r\n url = action; \r\n }\r\n if (nodeId != '') { url = url.replace(\":id\",nodeId); } // id - target object id \r\n sendQuery(url, params, sourceInterface, targetInterface, transitionInterface); \r\n}", "function parseArguments(url, data, success, dataType) {\r\n if ($.isFunction(data)) dataType = success, success = data, data = undefined\r\n if (!$.isFunction(success)) dataType = success, success = undefined\r\n return {\r\n url: url\r\n , data: data\r\n , success: success\r\n , dataType: dataType\r\n }\r\n }", "function parseArguments(url, data, success, dataType) {\r\n if ($.isFunction(data)) dataType = success, success = data, data = undefined\r\n if (!$.isFunction(success)) dataType = success, success = undefined\r\n return {\r\n url: url\r\n , data: data\r\n , success: success\r\n , dataType: dataType\r\n }\r\n }", "function parseArgument(lexer) {\n var start = lexer.token;\n return {\n kind: _kinds__WEBPACK_IMPORTED_MODULE_4__[\"Kind\"].ARGUMENT,\n name: parseName(lexer),\n value: (expect(lexer, _lexer__WEBPACK_IMPORTED_MODULE_3__[\"TokenKind\"].COLON), parseValueLiteral(lexer, false)),\n loc: loc(lexer, start)\n };\n}", "function parseArguments(url, data, success, dataType) {\r\n if ($.isFunction(data)) dataType = success, success = data, data = undefined\r\n if (!$.isFunction(success)) dataType = success, success = undefined\r\n return {\r\n url: url\r\n , data: data\r\n , success: success\r\n , dataType: dataType\r\n }\r\n }", "runAction(_actionName, _actionData) {\n return new Promise((resolve, reject) => {\n if (!_actionData)\n reject(\"null parameters\");\n var _cmd = `from ${_actionName}.${_actionName} import ${_actionData.entry_point};`; // add corresponding import\n _cmd += _actionData.entry_point;\n _cmd += \"(\";\n for (let _i = 0; _i < _actionData.params.length; _i++) {\n switch (_actionData.params[_i].type) {\n case \"string\":\n _cmd += `${_actionData.params[_i].name} = '${_actionData.params[_i].default}'`;\n break;\n case \"int\":\n _cmd += `${_actionData.params[_i].name} = ${_actionData.params[_i].default}`;\n break;\n default:\n _cmd += `${_actionData.params[_i].name} = '${_actionData.params[_i].default}'`;\n break;\n }\n if (_i + 1 < _actionData.params.length)\n _cmd += ',';\n }\n _cmd += \")\"; // close method call\n this.newRequest(_actionData.port, this.mainConfig.socketInterpreterSettings.host).then((client) => {\n client.write(_cmd);\n client.on('data', (data) => {\n client.destroy();\n });\n });\n resolve(_cmd); // return command\n });\n }", "function perform_action(address, payload, type, httpMethod, config, projectConfig, projectName, debug){\n\tif (debug == undefined) debug = false;\n\tinputAndParameters = matched_input(projectConfig.inputs, address, type, httpMethod, projectName, debug);\n\tif(debug) console.log('received input: ' + payload + ' at address: ' + address);\n\tif(debug) console.log(inputAndParameters);\n\tif(inputAndParameters != undefined) \n\t\tperform_transformations(inputAndParameters, payload, config, projectConfig, debug);\t\n}", "function ActionData(\n\t/* data */\n) {\n\tvar cArgs = arguments.length;\n\tvar record = Session.Installer.CreateRecord( cArgs );\n\tvar i;\n\tfor ( i = 0; i < cArgs; i++ ) {\n\t\tswitch( typeof arguments[i] ) { \n\t\t\tcase 'integer':\n\t\t\t\trecord.IntegerData( i+1 ) = arguments[i];\n\t\t\t\tbreak;\n\t\t\tcase 'string':\n\t\t\t\trecord.StringData( i+1 ) = arguments[i];\n\t\t\t\tbreak;\n\t\t\tcase 'object':\n\t\t\tdefault:\n\t\t\t\trecord.StringData( i+1 ) = JSON.stringify( arguments[i] );\n\t\t\t\tbreak;\n\t\t};\n\t};\n\tSession.Message( MsgKind.ActionData, record );\n}", "function parseArgument(lexer) {\n var start = lexer.token;\n return {\n kind: _kinds.Kind.ARGUMENT,\n name: parseName(lexer),\n value: (expect(lexer, _lexer.TokenKind.COLON), parseValueLiteral(lexer, false)),\n loc: loc(lexer, start)\n };\n}", "function parseArgument(lexer) {\n var start = lexer.token;\n return {\n kind: _kinds.Kind.ARGUMENT,\n name: parseName(lexer),\n value: (expect(lexer, _lexer.TokenKind.COLON), parseValueLiteral(lexer, false)),\n loc: loc(lexer, start)\n };\n}", "function parseArgument(lexer) {\n var start = lexer.token;\n return {\n kind: _kinds.Kind.ARGUMENT,\n name: parseName(lexer),\n value: (expect(lexer, _lexer.TokenKind.COLON), parseValueLiteral(lexer, false)),\n loc: loc(lexer, start)\n };\n}", "function parseArgument(lexer) {\n var start = lexer.token;\n return {\n kind: _kinds.Kind.ARGUMENT,\n name: parseName(lexer),\n value: (expect(lexer, _lexer.TokenKind.COLON), parseValueLiteral(lexer, false)),\n loc: loc(lexer, start)\n };\n}", "function parseArgument(lexer) {\n var start = lexer.token;\n return {\n kind: _kinds.Kind.ARGUMENT,\n name: parseName(lexer),\n value: (expect(lexer, _lexer.TokenKind.COLON), parseValueLiteral(lexer, false)),\n loc: loc(lexer, start)\n };\n}", "function passingValueToParamDemo(a,b,c) {\n\treturn \"This got passed to me A \" + a + \" B \" + b + \" C \" + c;\n}", "function parseArgument(lexer) {\n var start = lexer.token;\n return {\n kind: _kinds.ARGUMENT,\n name: parseName(lexer),\n value: (expect(lexer, _lexer.TokenKind.COLON), parseValueLiteral(lexer, false)),\n loc: loc(lexer, start)\n };\n}", "function parseArgument(lexer) {\n var start = lexer.token;\n return {\n kind: _kinds.ARGUMENT,\n name: parseName(lexer),\n value: (expect(lexer, _lexer.TokenKind.COLON), parseValueLiteral(lexer, false)),\n loc: loc(lexer, start)\n };\n}", "function parseArgument(lexer) {\n var start = lexer.token;\n return {\n kind: _kinds.ARGUMENT,\n name: parseName(lexer),\n value: (expect(lexer, _lexer.TokenKind.COLON), parseValueLiteral(lexer, false)),\n loc: loc(lexer, start)\n };\n}", "function parseArgument(lexer) {\n var start = lexer.token;\n return {\n kind: _kinds.ARGUMENT,\n name: parseName(lexer),\n value: (expect(lexer, _lexer.TokenKind.COLON), parseValueLiteral(lexer, false)),\n loc: loc(lexer, start)\n };\n}", "function parseArgument(lexer) {\n var start = lexer.token;\n return {\n kind: _kinds.ARGUMENT,\n name: parseName(lexer),\n value: (expect(lexer, _lexer.TokenKind.COLON), parseValueLiteral(lexer, false)),\n loc: loc(lexer, start)\n };\n}", "function parseArgument(lexer) {\n var start = lexer.token;\n return {\n kind: _kinds.ARGUMENT,\n name: parseName(lexer),\n value: (expect(lexer, _lexer.TokenKind.COLON), parseValueLiteral(lexer, false)),\n loc: loc(lexer, start)\n };\n}", "function argument(arg) \n\t{\n\t if (arg instanceof Array) \n\t {\n\t\tarray(arg,argument);\n\t\treturn;\n\t }\n\n\t if (typeof arg === 'object')\n\t {\n\t\tvar out = {};\n\t\tvar first = true;\n\t\t\n\t\tgenerated.push('dictionary(');\n\n\t\tfor (var k in arg) \n\t\t{\n\t\t if (first) first = false;\n\t\t else comma();\n\t\t \n\t\t string(k);\n\t\t comma();\n\t\t argument(arg[k]);\n\t\t}\n\n\t\tgenerated.push(')');\n\n\t\treturn;\n\t }\n\n\t if (arg.charAt(0) === ':') \n\t {\n\t\tvar key = arg.substring(1);\n\t\t\n\t\tfor (var i = 0; i < args.length; ++i) \n\t\t if (args[i] === key) \n\t\t\treturn generated.push('getArgument(',i,')');\n\n\t\tthrow (\"Unknown argument \" + arg + \" in \" + path + \".\" + name)\n\t }\n\n\t if (arg.charAt(0) === '@') \n\t {\n\t\tvar key = arg.substring(1);\n\n\t\tif (key === '') \n\t\t{\n\t\t generated.push('identity');\n\t\t return;\n\t\t}\n\n\t\tfor (var i = 0; i < model.fields.length; ++i) \n\t\t{\n\t\t if (model.fields[i] === key) \n\t\t {\t\n\t\t\tgenerated.push('getMember(');\n\t\t\tstring(key);\n\t\t\tgenerated.push(')');\n\t\t\treturn;\n\t\t }\n\t\t}\n\n\t\tthrow (\"Unknown field \" + arg + \" in \" + path + \".\" + name)\n\t }\n\n\t return string(arg);\t \n\t}", "arg([path]) {\n let { parts: [head, ...rest] } = path;\n this.opcode(['get', [`@${head}`, rest]], path);\n }", "function parseArguments(url, data, success, dataType) {\n if ($.isFunction(data)) dataType = success, success = data, data = undefined\n if (!$.isFunction(success)) dataType = success, success = undefined\n return {\n url: url,\n data: data,\n success: success,\n dataType: dataType\n }\n }", "function get_arg_2() { return arguments[2]; }", "proxyUpcomingExecute(serviceName, action, ...args) {\n let grantedItem\n\n if(!this.requireDict[serviceName]){\n throw Error(`Unknown service ${serviceName} called`)\n }\n if(!this.requireDict[serviceName][action]){\n throw Error(`Unknown action ${action} at service ${serviceName} called`)\n }\n grantedItem = this.requireDict[serviceName][action]\n return grantedItem.layer.executeAction(grantedItem.ticket, serviceName, action, ...args)\n }", "function main() {\n return argumentsAsString(...arguments)\n }", "function test_param(name, age, gender) {\n console.log(name);\n console.log(age);\n console.log(gender);\n}", "function readArguments() {\n //system.args[0] is for file name which is being executed\n\t\n if (system.args.length < 4 || system.args.length > 5) {\n console.log(constants.invalidArgumentsError);\n phantom.exit();\n }\n\n yelpObject.account['username'] = system.args[1];\n yelpObject.account['password'] = system.args[2];\n reviewsObject.business_id = system.args[3];\n\n //Check for user-agent, if yes then set to the page settings\n if (system.args[4]) {\n yelpObject.userAgent = system.args[4];\n page.settings.userAgent = yelpObject.userAgent;\n }\n}", "static parseArgs(args, kwargs, special) {\n const argDef = SPECIALS[special].args;\n const parsedArgs = Object.assign({ $args: [], $kwargs: {} }, ((argDef) ? argDef.defaults : {}));\n args.forEach((arg, index) => {\n if (argDef.argsPosition !== null && argDef.argsPosition <= index) {\n parsedArgs.$args.push(arg);\n }\n else if (argDef.lookup[index] !== undefined) {\n parsedArgs[argDef.lookup[index].name] = arg;\n }\n else {\n throw new UnexpectedPositionalArgument(index, special);\n }\n });\n Object.keys(kwargs).forEach(key => {\n if (argDef.lookup[key] !== undefined) {\n parsedArgs[key] = kwargs[key];\n }\n else if (argDef.kwargsPosition !== null) {\n parsedArgs.$kwargs[key] = kwargs[key];\n }\n else {\n throw new UnepectedKeywordArgument(key, special);\n }\n });\n return parsedArgs;\n }", "function parseArguments(url, data, success, dataType) {\n if ($.isFunction(data)) dataType = success, success = data, data = undefined\n if (!$.isFunction(success)) dataType = success, success = undefined\n return {\n url: url\n , data: data\n , success: success\n , dataType: dataType\n }\n }", "function parseArguments(url, data, success, dataType) {\n if ($.isFunction(data)) dataType = success, success = data, data = undefined\n if (!$.isFunction(success)) dataType = success, success = undefined\n return {\n url: url\n , data: data\n , success: success\n , dataType: dataType\n }\n }", "function parseArguments(url, data, success, dataType) {\n if ($.isFunction(data)) dataType = success, success = data, data = undefined\n if (!$.isFunction(success)) dataType = success, success = undefined\n return {\n url: url\n , data: data\n , success: success\n , dataType: dataType\n }\n }", "function parseArguments(url, data, success, dataType) {\n if ($.isFunction(data)) dataType = success, success = data, data = undefined\n if (!$.isFunction(success)) dataType = success, success = undefined\n return {\n url: url\n , data: data\n , success: success\n , dataType: dataType\n }\n }", "function parseArguments(url, data, success, dataType) {\n if ($.isFunction(data)) dataType = success, success = data, data = undefined\n if (!$.isFunction(success)) dataType = success, success = undefined\n return {\n url: url\n , data: data\n , success: success\n , dataType: dataType\n }\n }", "function parseArguments(url, data, success, dataType) {\n if ($.isFunction(data)) dataType = success, success = data, data = undefined\n if (!$.isFunction(success)) dataType = success, success = undefined\n return {\n url: url\n , data: data\n , success: success\n , dataType: dataType\n }\n }", "function parseArguments(url, data, success, dataType) {\n if ($.isFunction(data)) dataType = success, success = data, data = undefined\n if (!$.isFunction(success)) dataType = success, success = undefined\n return {\n url: url\n , data: data\n , success: success\n , dataType: dataType\n }\n }", "function parseArguments(url, data, success, dataType) {\n if ($.isFunction(data)) dataType = success, success = data, data = undefined\n if (!$.isFunction(success)) dataType = success, success = undefined\n return {\n url: url\n , data: data\n , success: success\n , dataType: dataType\n }\n }", "function parseArguments(url, data, success, dataType) {\n if ($.isFunction(data)) dataType = success, success = data, data = undefined\n if (!$.isFunction(success)) dataType = success, success = undefined\n return {\n url: url\n , data: data\n , success: success\n , dataType: dataType\n }\n }", "async function validateArguments(args, serviceManifest) {\n let error = new Error();\n let body = undefined;\n\n error.name = 'ArgumentError';\n if (!serviceManifest) {\n let verbs = [\"add\", \"clone\", \"delete\", \"export\", \"get\", \"import\", \"list\", \"publish\", \"query\", \"set\", \"suggest\", \"train\", \"update\"];\n if (verbs.indexOf(args._[0]) < 0)\n error.message = `'${args._[0]}' is not a valid action`;\n else if (args._.length >= 2)\n error.message = `'${args._[1]}' is not a valid resource`;\n else\n error.message = `missing resource\\n`;\n throw error;\n }\n const { operation } = serviceManifest;\n\n const entitySpecified = typeof args.in === 'string';\n const entityRequired = !!operation.entityName;\n\n if (entityRequired) {\n if (entitySpecified) {\n body = await getFileInput(args);\n }\n else {\n // make up a request body from command line args\n switch (serviceManifest.operation.target[0]) {\n case \"version\":\n switch (serviceManifest.operation.methodAlias) {\n case \"publish\":\n body = {\n versionId: args.versionId,\n isStaging: args.staging === true,\n region: args.region\n };\n break;\n }\n break;\n default:\n error.message = `The --in requires an input of type: ${operation.entityType}`;\n throw error;\n }\n }\n }\n return body;\n // Note that the ServiceBase will validate params that may be required.\n}", "function takeRest(...params) {\n console.log(...params);\n}", "static parse(parts, extras) {\n let [time, target, action, ...params] = parts,\n [namespace, ...idParts] = target.split('_'),\n id = idParts.join('_');\n\n return Object.assign({\n action: action,\n id: id,\n latency: Date.now() - time,\n from: namespace,\n params: params\n }, extras);\n }", "function abc(a,b) {\n var c = 6;\n return arguments[0] + b + c;\n}", "function parseArgument(lexer) {\n var start = lexer.token;\n var name = parseName(lexer);\n expectToken(lexer, _tokenKind__WEBPACK_IMPORTED_MODULE_4__[\"TokenKind\"].COLON);\n return {\n kind: _kinds__WEBPACK_IMPORTED_MODULE_6__[\"Kind\"].ARGUMENT,\n name: name,\n value: parseValueLiteral(lexer, false),\n loc: loc(lexer, start)\n };\n}", "function parseOperatorParameters(spec, ctx) {\n if (spec.params) {\n var op = ctx.get(spec.id);\n if (!op) error('Invalid operator id: ' + spec.id);\n ctx.dataflow.connect(op, op.parameters(\n parseParameters$1(spec.params, ctx),\n spec.react,\n spec.initonly\n ));\n }\n }", "function receiveArguments(page, width, height, operation) {\n\t\n\tMM.BC.FOCUS_BEFORE_COMMAND_OPEN = dw.getFocus();\n\t\n\tglobals.editorPage = page;\n\tif (operation == \"edit\") {\n\t\tglobals.editMode = true;\n\t}\n\tif (width && height && width != \"\" && height != \"\") {\n\t\tglobals.width = width;\n\t\tglobals.height = height;\n\t}\n}", "function get_arg() { return arguments; }", "function multiPurposeFunction(action) {\n if (action) {\n console.log(action('John', 'Smith'));\n console.log(action('', 'Bond'));\n }\n}", "function hzSpawnMethodArgs(spawnExp) {\n\t\tconst args = spawnExp.arguments[0].arguments;\n\t\tspawnExp = hzSpawnMethod(spawnExp);\n\t\tspawnExp.argument.arguments.push(t.arrayExpression(args));\n\t\tspawnExp.argument.callee.property.name = \"spawnMethodArgs\";\n\t\treturn spawnExp;\n\t}", "function methodName (arguments) {\n\t\n}", "_parse(method, params) {\n if (!params) params = {};\n\n const queryParts = [];\n const pathParts = [];\n\n // ?Part\n const queryPart = method.url.split('?')[1];\n if (queryPart) {\n const queryParams = queryPart.split('&');\n for (let i in queryParams) {\n const name = queryParams[i].split('=')[0];\n (params[name] || params[name] === 0) && queryParts.push(`${name}=${encodeURIComponent(params[name])}`);\n }\n }\n\n // /part\n const pathPart = method.url.split('?')[0];\n const pathParams = pathPart.split('/');\n for (let k in pathParams) {\n if (pathParams[k][0] != ':') {\n pathParts.push(pathParams[k]);\n } else {\n const param = params[pathParams[k].substr(1)];\n if (param || param === 0) {\n pathParts.push(param);\n } else {\n // check for missing required params\n if (method.optional && method.optional.indexOf(pathParams[k].substr(1)) === -1) throw Error(`Missing mandatory parameter: ${pathParams[k].substr(1)}`);\n }\n }\n }\n\n // Filters\n const filters = ['query', 'years', 'genres', 'languages', 'countries', 'runtimes', 'ratings', 'certifications', 'networks', 'status'];\n for (let p in params) {\n filters.indexOf(p) !== -1 && queryParts.indexOf(`${p}=${encodeURIComponent(params[p])}`) === -1 && queryParts.push(`${p}=${encodeURIComponent(params[p])}`);\n }\n\n // Pagination\n if (method.opts['pagination']) {\n params['page'] && queryParts.push(`page=${params['page']}`);\n params['limit'] && queryParts.push(`limit=${params['limit']}`);\n }\n\n // Extended\n if (method.opts['extended'] && params['extended']) { \n queryParts.push(`extended=${params['extended']}`);\n }\n\n return [\n this._settings.endpoint,\n pathParts.join('/'),\n queryParts.length ? `?${queryParts.join('&')}` : ''\n ].join('');\n }", "buildArgs() {\n let args = {};\n\n // Skip any url parameters (e.g. items that begin with $)\n for (let key in this.givenArgs) {\n if (key.substring(0, 1) !== '$') {\n args[key] = this.givenArgs[key];\n }\n }\n\n let apiType = u.thisOrThat(this.contextOptions.api_type,\n this._userConfig.apiType);\n\n if (apiType) {\n args.api_type = apiType;\n }\n\n return args;\n }", "function parseOperatorParameters(spec, ctx) {\n if (spec.params) {\n var op = ctx.get(spec.id);\n if (!op) vegaUtil.error('Invalid operator id: ' + spec.id);\n ctx.dataflow.connect(op, op.parameters(\n parseParameters(spec.params, ctx),\n spec.react,\n spec.initonly\n ));\n }\n }", "function identifyBehaviorArguments(fnCallStr){\n var argArray, retVal = \"\";\n\n argArray = extractArgs(fnCallStr);\n if (argArray.length == 4) retVal = \"objId,other,other\";\n return retVal;\n}" ]
[ "0.662924", "0.61538094", "0.60469383", "0.5933523", "0.589596", "0.58123964", "0.5743006", "0.5722535", "0.5717835", "0.5683364", "0.56329304", "0.56009483", "0.5572511", "0.55389535", "0.55096483", "0.5475489", "0.5474218", "0.5430921", "0.5428628", "0.5419558", "0.5391436", "0.53850263", "0.53850263", "0.53850263", "0.53850263", "0.53784615", "0.53645897", "0.5364329", "0.53603935", "0.53270054", "0.5324477", "0.531107", "0.5308895", "0.52923477", "0.5288696", "0.52576166", "0.5253585", "0.52482754", "0.52209264", "0.5203669", "0.5196508", "0.51961696", "0.5195966", "0.5191281", "0.51842535", "0.51842535", "0.51813585", "0.516355", "0.5162067", "0.5162067", "0.5161189", "0.5136627", "0.51331526", "0.5132034", "0.512623", "0.5123626", "0.5123626", "0.5123626", "0.5123626", "0.5123626", "0.5123434", "0.51209927", "0.51209927", "0.51209927", "0.51209927", "0.51209927", "0.51209927", "0.5118335", "0.51123834", "0.51114553", "0.51096886", "0.51068044", "0.5105212", "0.51030624", "0.5101013", "0.5096696", "0.5094376", "0.5094376", "0.5094376", "0.5094376", "0.5094376", "0.5094376", "0.5094376", "0.5094376", "0.5094376", "0.5091772", "0.50886667", "0.50793314", "0.50745714", "0.5071563", "0.50703275", "0.50694996", "0.506722", "0.5065509", "0.5060176", "0.50566334", "0.50549966", "0.50513256", "0.50481886", "0.50468034" ]
0.5786146
6
This is the key function or entry point to render a view route, model, callback
function viewRender(route, model, callback){ console.log("viewRender: %s", JSON.stringify(route)); var template = getTemplate(route); loadController(route.controller, function(){ var ret = model; if(!ret){ var handler = controllers[route.controller][route.action] || controllers[route.controller]["_defaultAction"] || defaultOptions.actionHandler; var args = getParamNames(handler); var vals = []; for(var i=0; i<args.length; i++){ var val = route.params[args[i]]; vals.push(val) } ret = handler.apply($.jf,vals); } processAction(ret,template,route,callback); }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "view() {\n // console.log('Render called');\n return this._view.renderView();\n }", "render(){}", "render(){}", "function render() {\n var currentAction = $route.current.action || 'list';\n \n switch(currentAction) {\n case 'add': {\n publicMethods.create();\n } break;\n case 'view': {\n publicMethods.view($routeParams.entityId);\n } break\n default: {\n publicMethods.list();\n } break;\n }\n }", "_render() {}", "render() {}", "render() {}", "render() {}", "view(viewName, data = {}) {\r\n if (!this.baseView) {\r\n throw new Error('Please set the base view path first');\r\n }\r\n\r\n return render(this.baseView + '/' + viewName, data, this);\r\n }", "render(){\r\n\r\n\t}", "render() {\n\n\t}", "render() {\n\n\t}", "function render() {\n\n\t\t\t}", "render() {\n\n }", "async show({ params, request, response, view }) {}", "render(){if(this.renderer){this.renderer.call(this.owner,this.content,this.owner,this.model)}}", "function render() {\n\t\t\t}", "requestView(){\t\t\n\t\tthis.trigger('requestView');\n\t}", "_render(model) {\n\t\tthis._coordinator.newEvent({\n\t\t\tsource: this.constructor.name,\n\t\t\ttype: 'render',\n\t\t\tdata: {\n\t\t\t\toriginX: this._originX,\n\t\t\t\toriginY: this._originY,\n\t\t\t\twidth: this._width,\n\t\t\t\theight: this._height\n\t\t\t}\n\t\t});\n\t}", "render() {\n }", "render() {\n\n }", "render() {\n\n }", "render() {\n\n }", "function View(){}", "function render() {\n\t\t\n\t}", "function render() {\n\t}", "render() { }", "async show({ params, request, response, view }) {\n }", "function View() {\n }", "render() {\n }", "render() {\n }", "render() {\n // Subclasses should override\n }", "async index({ request, response, view }) {\n }", "function View() {\n // FIXME\n // Store base view elements\n\n // Store resuable view templates (result card, expanded profile cards, forms)\n\n // Render base view elements\n\n // Render\n}", "async show ({ params, request, response, view }) {\n }", "async show ({ params, request, response, view }) {\n }", "async show ({ params, request, response, view }) {\n }", "async show ({ params, request, response, view }) {\n }", "async show ({ params, request, response, view }) {\n }", "async show ({ params, request, response, view }) {\n }", "async show ({ params, request, response, view }) {\n }", "function render() {\n //zarejdame si templeitite i im zakachame event\n ctx.partial('./templates/welcome.hbs')\n .then(attachEvents);\n }", "static rendered () {}", "static rendered () {}", "function render(viewPath) {\n return function (req, res) {\n return res.render(viewPath, {\n model: res.locals.model,\n isAuthenticated: !!req.session.authenticated,\n currentUserId: req.session.userId,\n currentDisplayName: req.session.displayName,\n });\n };\n}", "function renderContactListView() {\n app.router.load('list');\n }", "async index ({ request, response, view }) {\n }", "async index ({ request, response, view }) {\n }", "async index ({ request, response, view }) {\n }", "async index ({ request, response, view }) {\n }", "function handler(req, res) {\n // for now we just do render statics\n // this.content will define either json or a db index to query\n console.log(\"Path Context: \" + req.path);\n console.log(this.view);\n console.log(this.content);\n // res.render(this.view, {content: this.content, template: config.template, title: config.siteTitle, nav: this.global_navigation, path: this.optional_path || this.path});\n res.render(this.view, {content: this.content, template: config.template, title: config.siteTitle, nav: this.global_navigation, path: this.path, optionalPath: this.optional_path});\n}", "renderView() {\n super.renderView();\n\n this.parent.className = 'detail';\n\n const tag = this.getTagFromLocation();\n\n this.db.fetchRestaurantByTag(tag).then(restaurant => {\n if (restaurant) {\n this.bc.reset();\n this.bc.addCrumb(restaurant.name, '');\n this.bc.render();\n\n // Add map marker\n this.map.addMarker(restaurant.name, restaurant.latlng, DBHelper.urlForRestaurant(restaurant));\n this.map.resetView();\n\n this.appendRestaurantDetails(restaurant);\n\n this.appendReviews(restaurant.id, restaurant.tag);\n }\n else {\n this.renderError();\n }\n });\n }", "function View() {}", "function View() {}", "function View() {}", "function View() {}", "onViewParsed() {\n\n }", "render() {\n if (this.renderer) {\n this.renderer.call(this.owner, this.content, this.owner, this.model);\n }\n }", "function render() {\r\n\r\n}", "function render() {\r\n\r\n}", "get View() {}", "function renderView() {\n return require([contentViewUrl, topBarViewUrl, collectionUrl], function (contentView, topBarView, contentCollection) {\n var collection;\n\n App.filtersObject.filter = filter;\n\n collection = new contentCollection({\n viewType : 'list',\n page : page,\n reset : true,\n count : count,\n filter : filter,\n parrentContentId: parrentContentId,\n contentType : contentType,\n showMore : false\n });\n\n collection.bind('reset', _.bind(createViews, self));\n\n custom.setCurrentVT('list');\n\n function createViews() {\n var topbarView;\n var contentview;\n\n collection.unbind('reset');\n\n topbarView = new topBarView({\n actionType: 'Content',\n collection: collection\n });\n\n contentview = new contentView({\n collection: collection,\n startTime : startTime,\n filter : filter\n });\n\n eventsBinder.subscribeTopBarEvents(topbarView, contentview);\n eventsBinder.subscribeCollectionEvents(collection, contentview);\n\n collection.trigger('fetchFinished', {\n totalRecords: collection.totalRecords,\n currentPage : collection.currentPage,\n pageSize : collection.pageSize\n });\n\n context.changeView(contentview);\n context.changeTopBarView(topbarView);\n }\n });\n }", "render( ) {\n return null;\n }", "function render() {\r\n //does nothing if there is not a current error\r\n renderError();\r\n\r\n let html = '';\r\n\r\n//view state changes if user has chosen to add a new bookmark\r\n if (store.adding === true) {\r\n html = addBookmark()\r\n }\r\n //if the value of error has changed state from its initial value of null displayError will inject the msg into the html\r\n else if (store.error != null) {\r\n html = displayError()\r\n }\r\n \r\n //finally, if no errors are present the initial view of the app will render\r\n else { html = generateInitialView(generateBookmarkString) }\r\n $('main').html(html)\r\n store.filter = 0\r\n}", "function tryRender(view,options,callback){try{view.render(options,callback);}catch(err){callback(err);}}", "renderPage() {}", "function handleRender() {\n\t view._isRendered = true;\n\t triggerDOMRefresh();\n\t }", "render() {\n const restaurantId = +getUrlParameter('id');\n\n if (!restaurantId) {\n console.error('The restaurant ID could not be located');\n return;\n }\n\n DBHelper.fetchRestaurant(restaurantId)\n .then(restaurant => {\n this.restaurant = restaurant;\n document.title += ` | ${this.restaurant.name}`;\n\n this.fillBreadcrumb();\n this.renderRestaurant();\n this.loadMap();\n })\n .catch(console.error);\n }", "index(request, response) {\n \n // display confirmation message in log\n logger.info('about rendering');\n \n // create view data object (contains data to be sent to the view e.g. page title)\n const viewData = {\n title: 'Your shelf',\n shelves: shelfStore.getAllShelves(),\n };\n \n // render the about view and pass through the data\n response.render('shelf', viewData);\n }", "static create (route) {\n var Self = this\n return function (state, emit) {\n const view = state.cache(Self, Self.id(state))\n\n let children\n try {\n if (state.error) throw state.error\n children = view.render(state, emit)\n const next = view.meta(state)\n next['og:title'] = next.title\n if (next.title !== DEFAULT_TITLE) {\n next.title = `${next.title} | ${DEFAULT_TITLE}`\n }\n emit('meta', next)\n } catch (err) {\n err.status = err.status || 500\n children = error(err)\n emit('DOMTitleChange', error.title(err))\n }\n\n if (route !== state.routeName) emit('routeNameChange', route)\n\n return html`\n <body class=\"View\">\n <div class=\"View-full\">\n ${state.cache(Header, Header.id()).render()}\n </div>\n ${children}\n <div class=\"View-full\">\n ${state.cache(Footer, Footer.id()).render(state.meta)}\n </div>\n </body>\n `\n }\n }", "onRender()/*: void*/ {\n this.render();\n }", "function render() {\n let bigString;\n console.log('render fxn ran')\n if (store.view === 'landing') {\n bigString = generateTitleTemplate(store);\n\n }\n else if (store.view === 'question') {\n bigString = generateQuestionTemplate(store);\n\n }\n else if (store.view === 'feedback') {\n bigString = generateFeedbackTemplate(store)\n\n }\n else if (store.view === 'results') {\n bigString = generateResultsTemplate(store);\n\n }\n $('main').html(bigString);\n\n //attach event listeners\n\n\n}", "willRender() {\n console.log('willRender ejecutado!');\n }", "function render(ui, view) {\n clearFilters(ui);\n updateTitle(view);\n updateNav(view);\n\n switch(view) {\n case 'Contacts':\n ui.view(document.getElementById('view'), '0ROu0hKqSFCodgZTExaZmA');\n\n break;\n case 'Summary':\n renderDefault(ui);\n\n break;\n case 'Facebook':\n case 'Twitter':\n var data = {};\n data.value = view;\n\n drillIntoDataPoint(ui, data);\n\n break;\n case 'History':\n ui.view(document.getElementById('view'), 'XQgyVfUVSWO13NR6w-v3_A');\n\n break;\n default:\n renderDefault(ui);\n }\n}", "render() {\n return this.renderContent()\n }", "function cb () {\n var ref;\n if (typeof viewMethod === \"function\") {\n ref = viewMethod;\n } else {\n ref = self.view.get(viewMethod);\n }\n\n ref.apply(self.view, arguments);\n }", "function render() {\n res.render('socList', {\n title: 'Sentinel Project: SOC Manager',\n socs: socs,\n datapoints: resultsDatapoints\n });\n }", "function render() {\n\t// remove existing movies from view\n\t$moviesList.empty();\n\t// pass `allMovies` into the template function\n\tvar moviesHtml = template({ movies: allMovies });\n\t// append html to the view\n\t$moviesList.append(moviesHtml);\n}", "index(request, response) {\n const loggedInUser = accounts.getCurrentUser(request); \n logger.info('about rendering');\n if (loggedInUser) {\n \n const viewData = {\n title: 'About the Horselist App',\n developers: developerStore.getAllDevelopers(),\n fullname: loggedInUser.firstName + ' ' + loggedInUser.lastName,\n picture: loggedInUser.picture,\n messages: messageStore.getAllMessages(),\n };\n response.render('about', viewData);\n }\n else response.redirect('/'); \n }", "onRender () {\n\n }", "function render(view, info){\n return `VIEW NAME: ${view} \\nADDITIONAL INFO: ${info}`;\n}", "function __express(filename, options, callback) {\n\t// options for rendering the main view\n\tvar lvOpts = {\n\t\tfile: filename,\n\t\tbindings: options.bindings || viewhandler.defaultBindings(),\n\t\tdomain: this.name,\n\t\tcacheFlag: options.cache,\n\t}\n\tvar output\n\n\t// get the main view render function\n\tviewloader.getMainView(lvOpts, mainViewResult)\n\n\tfunction mainViewResult(err, renderFunction) {\n\t\tif (!err) {\n\n\t\t\t// inject data into main view html\n\t\t\toutput = renderFunction(options)\n\t\t\tif (!options.layout) callback(null, output)\n\t\t\telse {\n\n\t\t\t\t// get layout render function\n\t\t\t\tvar layout = getLayoutName(options.layout)\n\t\t\t\tif (layout instanceof Error) callback(layout)\n\t\t\t\telse {\n\t\t\t\t\tlvOpts.file = layout\n\t\t\t\t\tlvOpts.bindings = viewhandler.layoutBindings\n\t\t\t\t\tviewloader.getMainView(lvOpts, layoutResult)\n\t\t\t\t}\n\t\t\t}\n\t\t} else callback(err)\n\t}\n\n\tfunction layoutResult(err, layoutFunction) {\n\t\tif (!err) {\n\n\t\t\t// inject data into layout view\n\t\t\toptions.body = output\n\t\t\tcallback(null, layoutFunction(options))\n\t\t} else callback(err)\n\t}\n\n\t// name is options.layout\n\tfunction getLayoutName(name) {\n\t\tif (!name || typeof name.valueOf() != 'string') name = 'layout'\n\t\tif (!path.extname(name)) name += '.' + options.settings['view engine']\n\t\tname = path.resolve(options.settings.views, name)\n\t\tif (fs.existsSync(name)) return name\n\t\treturn Error('Layout file not found:' + name)\n\t}\n}", "function LView(){}", "function handleRender() {\n view._isRendered = true;\n triggerDOMRefresh();\n }", "function handleRender() {\n view._isRendered = true;\n triggerDOMRefresh();\n }", "function index(req, res, next) {\n\t// parameters for res.render(par1, par2)\n\t// par1 : a view in the views folder\n\t// par2 : data to be used when rendering the view\n // console.log(ALOmodel);\n // console.log(autopop);\n res.render(\n \t'program',\n \t{ title: 'Add Program',\n program: programModel,\n accreditor: accreditorModel,\n department: departmentModel,\n classes: autopop,\n ALO: ALOmodel,\n }\n );\n // console.log(programModel);\n}", "function TView(){}", "render() {\n const self = this;\n const data = self.get('data');\n if (!data) {\n throw new Error('data must be defined first');\n }\n self.clear();\n self.emit('beforerender');\n self.refreshLayout(this.get('fitView'));\n self.emit('afterrender');\n }", "render() {\n return this.renderContent();\n }", "render(data, option_, callback_) {\n\t let option = option_;\n\t let callback = callback_;\n\t let html = '';\n\t const fn = this.fn;\n\t const config = this.config;\n\t if (typeof option === 'function') {\n\t callback = option;\n\t option = null;\n\t }\n\t option = option || {};\n\t if (!callback) {\n\t callback = (error_, ret) => {\n\t let error = error_;\n\t if (error) {\n\t if (!(error instanceof Error)) {\n\t error = new Error(error);\n\t }\n\t throw error;\n\t }\n\t html = ret;\n\t };\n\t }\n\t let name = this.config.name;\n\t if (!name && fn && fn.TPL_NAME) {\n\t name = fn.TPL_NAME;\n\t }\n\t let scope;\n\t if (data instanceof Scope) {\n\t scope = data;\n\t } else {\n\t scope = new Scope(data);\n\t }\n\t const buffer = new LinkedBuffer(callback, config).head;\n\t const tpl = new TplWrap(name, {\n\t commands: option.commands\n\t }, this, scope, buffer, name, fn);\n\t buffer.tpl = tpl;\n\t if (!fn) {\n\t config.loader.load(tpl, (err, fn2) => {\n\t if (fn2) {\n\t tpl.fn = this.fn = fn2;\n\t renderTpl(tpl);\n\t } else if (err) {\n\t buffer.error(err);\n\t }\n\t });\n\t return html;\n\t }\n\t renderTpl(tpl);\n\t return html;\n\t }", "didRender() {\n console.log('didRender ejecutado!');\n }", "render() { this.screen.render() }", "function render() {\n //empty existing posts from view\n $nationalparks.empty();\n\n //pass 'allParks' into template function\n var parksHtml = getAllNationalparksHtml(allParks);\n\n //append html to view\n $nationalparks.append(parksHtml);\n}", "function handleRender(view){\r\n view._isRendered = true;\r\n triggerDOMRefresh(view);\r\n }", "render(renderedTemplate) {\n super.render()\n\n // render the template\n render(renderedTemplate, this, {\n eventContext: this\n })\n }", "render() {\n\t\treturn null;\n\t}", "function general_render(obj) {\n obj.render();\n }", "function render() {\r\n let content = '';\r\n if (STORE.view === 'home') {\r\n $('main').html(welcomePage());\r\n }\r\n else if (STORE.view === 'question') {\r\n content = questionAsked();\r\n content += generateAnswers();\r\n content += questionAndScoreStanding();\r\n $('main').html(`<form>${content}</form>`);\r\n } else if (STORE.view === 'feedback') {\r\n answerFeedback();\r\n } else if (STORE.view === 'score') {\r\n finalScore();\r\n }\r\n}", "function render() {\n renderRegistry();\n renderDirectory();\n renderOverride();\n}", "render(){return renderNotImplemented;}" ]
[ "0.7086873", "0.70798975", "0.70798975", "0.68738425", "0.66272753", "0.6625312", "0.6625312", "0.6625312", "0.6560287", "0.6489538", "0.64632446", "0.64632446", "0.6427854", "0.64211416", "0.6405989", "0.63958013", "0.63621193", "0.63380516", "0.63336235", "0.6321515", "0.63115925", "0.63115925", "0.63115925", "0.6294384", "0.6288462", "0.628591", "0.62814844", "0.62619996", "0.62235796", "0.6168959", "0.6168959", "0.6147271", "0.61471015", "0.6143167", "0.6133436", "0.6133436", "0.6133436", "0.6133436", "0.6133436", "0.6133436", "0.6133436", "0.61332095", "0.6126311", "0.6126311", "0.6126132", "0.6123962", "0.6120169", "0.6120169", "0.6120169", "0.6120169", "0.61186904", "0.6059461", "0.6038962", "0.6038962", "0.6038962", "0.6038962", "0.60315746", "0.6022508", "0.6019572", "0.6019572", "0.6018549", "0.59947497", "0.59893966", "0.5948174", "0.59316856", "0.5894174", "0.5876657", "0.5863259", "0.58579767", "0.5841745", "0.5823583", "0.58035505", "0.57999855", "0.57896566", "0.57843095", "0.5783705", "0.57832927", "0.57787883", "0.57751733", "0.57618296", "0.57602566", "0.57600874", "0.5757515", "0.57463235", "0.57463235", "0.57280654", "0.5711834", "0.56905854", "0.56869566", "0.56835073", "0.56712544", "0.56696844", "0.56607217", "0.5648629", "0.5639353", "0.56369185", "0.56203777", "0.5619468", "0.5614109", "0.5611918" ]
0.77995634
0
handler call after each view loaded.
function postRender(formmated){ console.log("postRender"); var jObj = $(this); // adding handler for forms jObj.find("form").bind("submit",formSubmitHandler); // adding handler for partial view var id= jObj.attr("id"); console.log("postRender, id: %s", id); if(id == defaultOptions.container){ loadingPartial(); } else if(id in partialList){ loadingPartial(id); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "_triggerLoaded() {\n\t if (this._alreadyLoaded) {\n\t // Do not trigger event twice\n\t this._triggerUpdated();\n\t return;\n\t }\n\t this._alreadyLoaded = true;\n\t const registry = storage.getRegistry(this._instance);\n\t const events = registry.events;\n\t events.fire('view-loaded', this);\n\t // Trigger onLoad event for child view\n\t if (this.onLoad !== null) {\n\t const onLoad = this.onLoad;\n\t this.onLoad = null;\n\t onLoad();\n\t }\n\t }", "onViewParsed() {\n\n }", "function onViewLoaded() {\n try {\n\n // Remove the event handler once the function is excuted.\n $evt.removeEventHandler($display, \"start\", onViewLoaded);\n // Get the page object\n var page = $display.getItem();\n // Insert the Edit button besides the page template dropdown\n $JQ(\"<div id='AlchemyPluginsEditTemplatesFromPagePageEditButton' class='editTemplateFromPagePluginButton editButton pageTemplate' title='Edit'><span class='text'>&nbsp;</span></div>\").insertAfter('#PageTemplate')\n // Function to be execte on the Edit Button click\n $JQ(\"#AlchemyPluginsEditTemplatesFromPagePageEditButton\").click(function () {\n // Execute the open command\n var pageTemplateId = page.getPageTemplateId();\n var s = new Tridion.Cme.Selection();\n s.addItem(pageTemplateId);\n $commands.executeCommand(\"Open\", s);\n });\n\n }\n catch (error) {\n $messages.registerError(\"Alchemy Plugin Error | EditTemplatesFromPage: \", error);\n }\n }", "postPageLoadActions() {\n\t\tmenu_manager.renderAllMenus();\n\t\tinitFeedbackCapture();\n\t\tloadCurrentUserProfilePicture();\n\t\trenderAppLogo();\n\t\ttoggleUserRoleVisibility();\n\t\tdoAfterPageLoadActions();\n\t}", "function viewRenderComplete() {\n $container.trigger(topologyConstants.events.viewRenderComplete, {}); // Private Event\n }", "function doAfterPageLoadActions() {\n\t//TODO: Override this\n}", "requestView(){\t\t\n\t\tthis.trigger('requestView');\n\t}", "_lazyLoadHandler() {\n var freeList = [];\n this.ListenerQueue.forEach(listener => {\n if (!listener.el || !listener.el.parentNode) {\n freeList.push(listener);\n }\n\n var catIn = listener.checkInView();\n if (!catIn) return;\n listener.load();\n });\n freeList.forEach(item => {\n remove(this.ListenerQueue, item);\n item.$destroy();\n });\n }", "async function pageLoaded() {\n loadRegisteData();\n prepareHandles();\n}", "function afterLoading(){\n\t\t\tupdatePageInfo();\n\t\t}", "function handleDOMContentLoaded() {\n const viewName = document.getElementsByTagName('body')[0].dataset.jsViewName;\n const ViewClass = loadView(viewName);\n const view = new ViewClass();\n view.mount();\n window.currentView = view;\n}", "complete() {\n this.trigger('load_complete');\n }", "function loadViewData() {\n\t\t\tviewService.getViews().then(function(view) {\n\t\t\t\tapplyViewData(view);\n\t\t\t});\n\t\t}", "function onLoaded()\n\t{\n\t\twindow.initExhibitorsList();\n\t\twindow.initFloorPlans();\n\t\twindow.initConciege();\n\t\twindow.initAmenities();\n\t\twindow.initVisas();\n\t}", "async afterLoad () {\n }", "function mainLoaded() {\n if (typeof(executeOnContentLoad) == \"function\") {\n if (contentLoadDestination && location.hash != contentLoadDestination) return;//wait til we are on the correct page\n var fn = executeOnContentLoad;\n executeOnContentLoad = null;\n contentLoadDestination = null;\n fn();\n }\n }", "onAfterLoadPage(data_obj) {\n\t\t//TODO: Override this as needed;\n\t}", "onAfterLoadPage(data_obj) {\n\t\t//TODO: Override this as needed;\n\t}", "in_view_cb () {\n if (this.in_view_cbs.length > 0) {\n this.in_view_cbs.forEach((cb) => {\n cb.run();\n });\n } else {\n console.warn(\n 'Watch.js: No functions have been set for when this element comes in to view'\n ); /* RemoveLogging:skip */\n }\n }", "function dom_loaded_handler() {\n // function flag since we only want to execute this once\n if (dom_loaded_handler.done) { return; }\n dom_loaded_handler.done = true;\n\n DOM_LOADED = true;\n ENQUEUE_REQUESTS = false;\n\n _.each(instances, function(inst) {\n inst._dom_loaded();\n });\n }", "function pageFullyLoaded () {}", "function doSomethingAfterRendering(){\n displayLoading() // 로딩화면 보여주기\n fetchServer(); // 서버에서 데이터 가져오기\n }", "function init(){\n recipeView.addhandlerRender(controlRecipes);\n searchView.addhandlerRender(controlSearchResults);\n paginationView.addhandlerRender(controlPagination);\n recipeView.addhandlerUpdateServings(controlServings);\n recipeView.addhandlerBookmark(controlBookmarks);\n bookMarksView.addhandlerRender(loadBookmarks);\n addRecipeView.addhandlerupload(addrecipe)\n console.log('hello');\n}", "function applicationLoaded() {\n initiateController();\n }", "function _triggerAfterRender() {\n _trigger(docma.Event.Render, [docma.currentRoute]);\n if (_initialLoad) {\n _trigger(docma.Event.Ready);\n _initialLoad = false;\n }\n }", "function onAllLoaded() {\n console.log('all loaded');\n}", "function cb_contentLoaded(cb) {}", "onAfterRendering() {}", "function onPagesLoaded(e) {\n window.PDFViewerApplication.eventBus.off(\"pagesloaded\", onPagesLoaded);\n initMeta(e.pagesCount);\n }", "function oninitialized() {\n\t // focus once ready\n\t this.once(this.options.mode + ' ready', bind(this.focusInput, this));\n\t\n\t // resolve view\n\t if ('signin' === this.options.mode) {\n\t // if user in AD ip range\n\t if (this.$ssoData && this.$ssoData.connection) {\n\t return this._kerberosPanel(this.options, callback);\n\t }\n\t\n\t // if user logged in show logged in experience\n\t if (this.options._shouldShowLastLogin()) {\n\t return this._loggedinPanel(this.options, callback);\n\t }\n\t\n\t // otherwise, just show signin\n\t this._signinPanel();\n\t }\n\t\n\t if ('signup' === this.options.mode) {\n\t this._signupPanel();\n\t }\n\t\n\t if ('reset' === this.options.mode) {\n\t this._resetPanel(this.options, callback);\n\t }\n\t\n\t }", "function graphsLoadCompleteHandler(){\n $engine.log('DASHBOARD > LOADER: '+objloadedArr.length + ' / ' + loadCount)\n if(objloadedArr.length == loadCount){\n $engine.toggleViewLoader(false);\n $('.drilldown-button').show();\n loadCount=0;\n objloadedArr.length = null;\n }\n }", "function loadViews() {\r\n var $viewHolders = $(\"[data-role='view']\");\r\n $viewHolders.each(function () {\r\n var holder = $(this);\r\n var $src = holder.attr(\"data-src\");\r\n $.ajax({url: $src, async: false}).then(function (data) {\r\n holder.replaceWith(data);\r\n });\r\n });\r\n }", "function register_event_handlers()\n {\n\n var navMan = new ViewManager('#firstPage');\n\n\n }", "function contentLoaded (){\n\t\t//_story.buildSlides()\n\t\t/// send story to be managed by navigator\n\n\t\t_navigator = new Navigator( _story );\n\t\t_navigator.setButtons(_back, _next);\n\t\t\n\t\t$.storyStage.add(_navigator.init() );\n\t\t\n\t\t$.storyViewer.removeEventListener('android:back', pageBack);\n\n\n\t}", "out_view_cb () {\n if (this.out_view_cbs.length > 0) {\n this.out_view_cbs.forEach((cb) => {\n cb.run();\n });\n } else {\n console.warn(\n 'Watch.js: No functions have been set for when this element goes out of view'\n ); /* RemoveLogging:skip */\n }\n }", "function SetupAfterAllLoaded() {\n /**\n * CHECK IMAGE LOADED -> IF LOADED COMPLETE THEN EXECUTE 'SLIDE-END'\n */\n slData.nImage = slData.nImage + 1;\n if (slData.nImage == slData.imageLen\n && (!slData.isVideoback || (slData.isVideoback && slData.isVideobackLoaded))) {\n setTimeout(function () {\n VariableModule(that);\n (slData['id'] == 'home') ? M.Module('LAYER').LoadHomeEnd()\n : that.LOAD.SlideEnd($slCur);\n }, 10);\n }\n }", "_didLoad () {\n // Clear the height cache\n this._lastHeight = 0\n \n // Post-process content\n this._unescapeImageURLs()\n \n // Setup event listeners\n this._addHeightListener('details', 'toggle')\n this._addHeightListener('img, svg', 'load')\n }", "function loadDataUploadView() {\n}", "function page_loaded() {\n post_load_setup();\n}", "function _onPageLoadOuter() {\n // Back-forward navigation can add nodes: create a clean slate.\n removeAddedNodes(); // defined by application.\n onPageLoad(); // defined by application.\n}", "function onloadHandler(){\n console.info(\"Nick Cage is ready!\");\n // where the magic happens\n replaceAllElements();\n }", "function handleRender(view){\r\n view._isRendered = true;\r\n triggerDOMRefresh(view);\r\n }", "function loaded() {\n\taddElements();\n\tosScroll();\n\t// initiate tabs\n\t$('#tabs').tab();\n\t// set event listeners\n\tsetOneTimeEventListeners();\n\t//updateChecked();\n}", "function afterRenderActions() {\n var section = $(SECTION_ACTIVE_SEL);\n\n section.addClass(COMPLETELY);\n\n lazyLoad(section);\n playMedia(section);\n\n if (options.scrollOverflow) {\n options.scrollOverflowHandler.afterLoad();\n }\n\n if (isDestinyTheStartingSection()) {\n $.isFunction(options.afterLoad) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\n }\n\n $.isFunction(options.afterRender) && options.afterRender.call(container);\n }", "onPageLoaded() {\n window.clearTimeout(this.animationTimeout_);\n window.clearTimeout(this.loadingTimeout_);\n this.setUIStep(AssistantLoadingUIState.LOADED);\n }", "function handleLoadAsync() {\n\t\t\t\t\tlogWithPhase( \"handleLoad - Async\" );\n\t\t\t\t\t$scope.$apply(\n\t\t\t\t\t\tfunction() {\n\t\t\t\t\t\t\thandleLoadSync();\n\t\t\t\t\t\t}\n\t\t\t\t\t);\n\t\t\t\t}", "function init()\n {\n $(document).on(\"loaded:everything\", runAll);\n }", "function handleRender() {\n\t view._isRendered = true;\n\t triggerDOMRefresh();\n\t }", "function afterRenderActions() {\n var section = $(SECTION_ACTIVE_SEL)[0];\n addClass(section, COMPLETELY);\n lazyLoad(section);\n lazyLoadOthers();\n playMedia(section);\n\n if (options.scrollOverflow) {\n options.scrollOverflowHandler.afterLoad();\n }\n\n if (isDestinyTheStartingSection() && isFunction(options.afterLoad)) {\n fireCallback('afterLoad', {\n activeSection: section,\n element: section,\n direction: null,\n //for backwards compatibility callback (to be removed in a future!)\n anchorLink: section.getAttribute('data-anchor'),\n sectionIndex: index(section, SECTION_SEL)\n });\n }\n\n if (isFunction(options.afterRender)) {\n fireCallback('afterRender');\n }\n }", "function attach() {\n\t\t\t$(\"[data-role='page'][data-controller]\").live('pagebeforeshow', function (event, ui) {\n\t\t\t\tvar page, controller, view, model;\n\t\t\t\tpage = $(this);\n\t\t\t\tcontroller = page.data(\"controller\");\n\t\t\t\tview = page.data(\"view\");\n\t\t\t\tmodel = {\n\t\t\t\t\tapp: app.environ,\n\t\t\t\t\tparams: $.url.parse(ui.url).params\n\t\t\t\t};\n\t\t\t\tmvc.run(model, view, controller, output);\n\n\t\t\t\tfunction output(source) {\n\t\t\t\t\tpage\n\t\t\t\t\t\t.html(source)\n\t\t\t\t\t\t.parent()\n\t\t\t\t\t\t.page()\n\t\t\t\t\t\t.page(\"refresh\");\n\t\t\t\t}\n\t\t\t});\n\t\t}", "function on_dom_content_loaded () {\n //remove this handler\n document.removeEventListener(\"DOMContentLoaded\", on_dom_content_loaded, false);\n\n //call the onLoad function\n Survana.Workflow.OnPageLoad();\n }", "function initViews() {\n\n for(var view in window.map.views) {\n self.views[view] = setTransition(view);\n }\n }", "function handleRender(view) {\n view._isRendered = true;\n triggerDOMRefresh(view);\n }", "function afterSectionLoads(v) {\n continuousVerticalFixSectionOrder(v); //callback (afterLoad) if the site is not just resizing and readjusting the slides\n\n if (isFunction(options.afterLoad) && !v.localIsResizing) {\n fireCallback('afterLoad', v);\n }\n\n if (options.scrollOverflow) {\n options.scrollOverflowHandler.afterLoad();\n }\n\n if (!v.localIsResizing) {\n playMedia(v.element);\n }\n\n addClass(v.element, COMPLETELY);\n removeClass(siblings(v.element), COMPLETELY);\n lazyLoadOthers();\n canScroll = true;\n\n if (isFunction(v.callback)) {\n v.callback();\n }\n }", "function afterRenderActions(){\n var section = $(SECTION_ACTIVE_SEL);\n\n section.addClass(COMPLETELY);\n\n if(options.scrollOverflowHandler.afterRender){\n options.scrollOverflowHandler.afterRender(section);\n }\n lazyLoad(section);\n playMedia(section);\n\n $.isFunction( options.afterLoad ) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\n $.isFunction( options.afterRender ) && options.afterRender.call(container);\n }", "function afterRenderActions(){\n var section = $(SECTION_ACTIVE_SEL);\n\n section.addClass(COMPLETELY);\n\n if(options.scrollOverflowHandler.afterRender){\n options.scrollOverflowHandler.afterRender(section);\n }\n lazyLoad(section);\n playMedia(section);\n\n $.isFunction( options.afterLoad ) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\n $.isFunction( options.afterRender ) && options.afterRender.call(container);\n }", "function afterRenderActions(){\r\n var section = $(SECTION_ACTIVE_SEL);\r\n\r\n section.addClass(COMPLETELY);\r\n\r\n lazyLoad(section);\r\n playMedia(section);\r\n\r\n if(options.scrollOverflow){\r\n options.scrollOverflowHandler.afterLoad();\r\n }\r\n\r\n if(isDestinyTheStartingSection()){\r\n $.isFunction( options.afterLoad ) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\r\n }\r\n\r\n $.isFunction( options.afterRender ) && options.afterRender.call(container);\r\n }", "function afterSectionLoads (v){\n continuousVerticalFixSectionOrder(v);\n\n //callback (afterLoad) if the site is not just resizing and readjusting the slides\n if(isFunction(options.afterLoad) && !v.localIsResizing){\n fireCallback('afterLoad', v);\n }\n\n if(options.scrollOverflow){\n options.scrollOverflowHandler.afterLoad();\n }\n\n if(!v.localIsResizing){\n playMedia(v.element);\n }\n\n addClass(v.element, COMPLETELY);\n removeClass(siblings(v.element), COMPLETELY);\n lazyLoadOthers();\n\n canScroll = true;\n\n if(isFunction(v.callback)){\n v.callback();\n }\n }", "function afterSectionLoads (v){\n continuousVerticalFixSectionOrder(v);\n\n //callback (afterLoad) if the site is not just resizing and readjusting the slides\n if(isFunction(options.afterLoad) && !v.localIsResizing){\n fireCallback('afterLoad', v);\n }\n\n if(options.scrollOverflow){\n options.scrollOverflowHandler.afterLoad();\n }\n\n if(!v.localIsResizing){\n playMedia(v.element);\n }\n\n addClass(v.element, COMPLETELY);\n removeClass(siblings(v.element), COMPLETELY);\n lazyLoadOthers();\n\n canScroll = true;\n\n if(isFunction(v.callback)){\n v.callback();\n }\n }", "function afterSectionLoads (v){\n continuousVerticalFixSectionOrder(v);\n\n //callback (afterLoad) if the site is not just resizing and readjusting the slides\n if(isFunction(options.afterLoad) && !v.localIsResizing){\n fireCallback('afterLoad', v);\n }\n\n if(options.scrollOverflow){\n options.scrollOverflowHandler.afterLoad();\n }\n\n if(!v.localIsResizing){\n playMedia(v.element);\n }\n\n addClass(v.element, COMPLETELY);\n removeClass(siblings(v.element), COMPLETELY);\n lazyLoadOthers();\n\n canScroll = true;\n\n if(isFunction(v.callback)){\n v.callback();\n }\n }", "function afterRenderActions(){\n var section = $(SECTION_ACTIVE_SEL)[0];\n\n addClass(section, COMPLETELY);\n\n lazyLoad(section);\n lazyLoadOthers();\n playMedia(section);\n\n if(options.scrollOverflow){\n options.scrollOverflowHandler.afterLoad();\n }\n\n if(isDestinyTheStartingSection() && isFunction(options.afterLoad) ){\n fireCallback('afterLoad', {\n activeSection: section,\n element: section,\n direction: null,\n\n //for backwards compatibility callback (to be removed in a future!)\n anchorLink: section.getAttribute('data-anchor'),\n sectionIndex: index(section, SECTION_SEL)\n });\n }\n\n if(isFunction(options.afterRender)){\n fireCallback('afterRender');\n }\n }", "function afterRenderActions(){\n var section = $(SECTION_ACTIVE_SEL)[0];\n\n addClass(section, COMPLETELY);\n\n lazyLoad(section);\n lazyLoadOthers();\n playMedia(section);\n\n if(options.scrollOverflow){\n options.scrollOverflowHandler.afterLoad();\n }\n\n if(isDestinyTheStartingSection() && isFunction(options.afterLoad) ){\n fireCallback('afterLoad', {\n activeSection: section,\n element: section,\n direction: null,\n\n //for backwards compatibility callback (to be removed in a future!)\n anchorLink: section.getAttribute('data-anchor'),\n sectionIndex: index(section, SECTION_SEL)\n });\n }\n\n if(isFunction(options.afterRender)){\n fireCallback('afterRender');\n }\n }", "function afterRenderActions(){\n var section = $(SECTION_ACTIVE_SEL)[0];\n\n addClass(section, COMPLETELY);\n\n lazyLoad(section);\n lazyLoadOthers();\n playMedia(section);\n\n if(options.scrollOverflow){\n options.scrollOverflowHandler.afterLoad();\n }\n\n if(isDestinyTheStartingSection() && isFunction(options.afterLoad) ){\n fireCallback('afterLoad', {\n activeSection: section,\n element: section,\n direction: null,\n\n //for backwards compatibility callback (to be removed in a future!)\n anchorLink: section.getAttribute('data-anchor'),\n sectionIndex: index(section, SECTION_SEL)\n });\n }\n\n if(isFunction(options.afterRender)){\n fireCallback('afterRender');\n }\n }", "function handleRender() {\n view._isRendered = true;\n triggerDOMRefresh();\n }", "function handleRender() {\n view._isRendered = true;\n triggerDOMRefresh();\n }", "postRenderSetup() {\n this.el.querySelectorAll('a.addBoxerLink').forEach((link) => {\n link.onclick = () => {\n this.callbacks.closeSidebar();\n this.callbacks.createNewFighter(link.id);\n }\n });\n\n this.el.querySelector('#directoryReport').onclick = () => {\n this.callbacks.closeSidebar();\n this.callbacks.directoryReport();\n };\n\n this.el.querySelector('#assessmentReport').onclick = () => {\n this.callbacks.closeSidebar();\n this.callbacks.assessmentReport();\n }\n }", "function afterSectionLoads (v){\r\n continuousVerticalFixSectionOrder(v);\r\n\r\n //callback (afterLoad) if the site is not just resizing and readjusting the slides\r\n if(isFunction(options.afterLoad) && !v.localIsResizing){\r\n fireCallback('afterLoad', v);\r\n }\r\n\r\n if(options.scrollOverflow){\r\n options.scrollOverflowHandler.afterLoad();\r\n }\r\n\r\n if(!v.localIsResizing){\r\n playMedia(v.element);\r\n }\r\n\r\n addClass(v.element, COMPLETELY);\r\n removeClass(siblings(v.element), COMPLETELY);\r\n lazyLoadOthers();\r\n\r\n canScroll = true;\r\n\r\n if(isFunction(v.callback)){\r\n v.callback();\r\n }\r\n }", "function afterRenderActions(){\r\n var section = $(SECTION_ACTIVE_SEL)[0];\r\n\r\n addClass(section, COMPLETELY);\r\n\r\n lazyLoad(section);\r\n lazyLoadOthers();\r\n playMedia(section);\r\n\r\n if(options.scrollOverflow){\r\n options.scrollOverflowHandler.afterLoad();\r\n }\r\n\r\n if(isDestinyTheStartingSection() && isFunction(options.afterLoad) ){\r\n fireCallback('afterLoad', {\r\n activeSection: section,\r\n element: section,\r\n direction: null,\r\n\r\n //for backwards compatibility callback (to be removed in a future!)\r\n anchorLink: section.getAttribute('data-anchor'),\r\n sectionIndex: index(section, SECTION_SEL)\r\n });\r\n }\r\n\r\n if(isFunction(options.afterRender)){\r\n fireCallback('afterRender');\r\n }\r\n }", "initialise_view(user) {\n this.refresh_view(user);\n }", "function postInit()\n\t{\n\n\t\tproblem = app.problemList.at(app.curProbIndex);\n\n\t\t// Set some global variables (messy)\n\t\tview.showingSolution = false;\n\n\t\t// Attach to the result handler (this can't happen earlier, since it is defined after the view)\n\t\tview.initResultHandler(problem);\n\n\t\t// Layout init\n\t\tview.initLayout(problem);\n\n\t\t// Set the problem status appropriately\n\t\thandleLockouts();\n\n\t\t// Init any modules that require it\n\t\tview.initFocusManager();\n\t\tview.stepModuleInit(problem);\n\t\tview.initHelp(problem);\t\n\t\n\t\t// Open steps if required -- move to an answerType-based plugin system!\n\t\tmodeSpecific();\n\n\t\tif (app.FunctionalTestMode) {\n\t\t\tapp.globalReadyForFunctionalTest();\n\t\t}\n\n\t\tapp.clearLoadingBox();\n\t}", "function initViews() {\n \n for(var view in window.map.views) {\n self.views[view] = setTransition(view);\n }\n }", "function onPageLoaded() {\n}", "onCreatedHandler() {\n this.fetchData();\n }", "afterRender() { }", "afterRender() { }", "ready() {\n super.ready();\n\n afterNextRender(this, function() {});\n }", "ready() {\n super.ready();\n\n afterNextRender(this, function() {});\n }", "ready() {\n super.ready();\n\n afterNextRender(this, function() {});\n }", "function complete(){\r\n callbackCount++;\r\n if(callbackCount >= 3){\t\t\t\t//CHANGE IF FUNCTIONS BEING CALLED CHANGES!!\r\n res.render('search_topic', context);\r\n }\r\n\r\n }", "function afterRenderActions(){\r\n var section = $(SECTION_ACTIVE_SEL)[0];\r\n\r\n addClass(section, COMPLETELY);\r\n\r\n lazyLoad(section);\r\n playMedia(section);\r\n\r\n if(options.scrollOverflow){\r\n options.scrollOverflowHandler.afterLoad();\r\n }\r\n\r\n if(isDestinyTheStartingSection() && isFunction(options.afterLoad) ){\r\n fireCallback('afterLoad', {\r\n activeSection: null,\r\n element: section,\r\n direction: null,\r\n\r\n //for backwards compatibility callback (to be removed in a future!)\r\n anchorLink: section.getAttribute('data-anchor'),\r\n sectionIndex: index(section, SECTION_SEL)\r\n });\r\n }\r\n\r\n if(isFunction(options.afterRender)){\r\n fireCallback('afterRender');\r\n }\r\n }", "function afterRenderActions(){\n var section = $(SECTION_ACTIVE_SEL);\n\n section.addClass(COMPLETELY);\n\n if(options.scrollOverflowHandler.afterRender){\n options.scrollOverflowHandler.afterRender(section);\n }\n lazyLoad(section);\n playMedia(section);\n options.scrollOverflowHandler.afterLoad();\n \n if(isDestinyTheStartingSection()){\n $.isFunction( options.afterLoad ) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\n }\n\n $.isFunction( options.afterRender ) && options.afterRender.call(container);\n }", "function afterRenderActions(){\n var section = $(SECTION_ACTIVE_SEL);\n\n section.addClass(COMPLETELY);\n\n if(options.scrollOverflowHandler.afterRender){\n options.scrollOverflowHandler.afterRender(section);\n }\n lazyLoad(section);\n playMedia(section);\n options.scrollOverflowHandler.afterLoad();\n \n if(isDestinyTheStartingSection()){\n $.isFunction( options.afterLoad ) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\n }\n\n $.isFunction( options.afterRender ) && options.afterRender.call(container);\n }", "function updateViews(){\r\n\treloadBall();\r\n\treloadCalendar();\r\n\treloadWordle();\r\n}", "function setupViewEventHandlers(self) {\n _view.resetButtonEventBus.onEvent(newWordLogic.bind(self));\n _view.alphabetButtonEventBus.onEvent(letterPressedLogic.bind(self));\n }", "_initializeViews()\n {\n this._layoutViewMaster = new LayoutViewMaster();\n }", "afterRenderContent() {\n this.logger.debug('After render content');\n\n if (this.model.getConfig('preferences').expandable) {\n this.view.contentExpander();\n }\n\n /**\n * Get page\n * @type {Page}\n */\n const page = this.controller.getContainment();\n\n page.observer.publish(page.eventManager.eventList.updateLoadedContent, this);\n }", "onPageReady () {}", "function onInit() {\n loadData();\n manageBag();\n}", "function afterSectionLoads (v){\r\n continuousVerticalFixSectionOrder(v);\r\n\r\n //callback (afterLoad) if the site is not just resizing and readjusting the slides\r\n if(isFunction(options.afterLoad) && !v.localIsResizing){\r\n fireCallback('afterLoad', v);\r\n }\r\n\r\n if(options.scrollOverflow){\r\n options.scrollOverflowHandler.afterLoad();\r\n }\r\n\r\n if(!v.localIsResizing){\r\n playMedia(v.element);\r\n }\r\n\r\n addClass(v.element, COMPLETELY);\r\n removeClass(siblings(v.element), COMPLETELY);\r\n\r\n canScroll = true;\r\n\r\n if(isFunction(v.callback)){\r\n v.callback();\r\n }\r\n }", "function loadView() {\n\t\tvar srv1 = comc.requestLiteList('HCONLTTIPO', $scope.cntx);\n\t\tvar srv2 = comc.requestLiteList('ANUALIDAD', $scope.cntx);\n\t\tvar srv3 = comc.requestLiteList('MES', $scope.cntx); \n\t\tvar srv4 = comc.request('cate/list', $scope.cntx);\n\t\tvar srv5 = comc.request('conc/full', $scope.cntx);\n\t\t\n\t\t$q.all([srv.stResp(true, srv1,srv2,srv3,srv4,srv5)]).then(function() {\n\t\t\tview();\n\t\t});\n\t}", "function afterRenderActions(){\r\n var section = $(SECTION_ACTIVE_SEL);\r\n\r\n section.addClass(COMPLETELY);\r\n\r\n if(options.scrollOverflowHandler.afterRender){\r\n options.scrollOverflowHandler.afterRender(section);\r\n }\r\n lazyLoad(section);\r\n playMedia(section);\r\n options.scrollOverflowHandler.afterLoad();\r\n \r\n if(isDestinyTheStartingSection()){\r\n $.isFunction( options.afterLoad ) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\r\n }\r\n\r\n $.isFunction( options.afterRender ) && options.afterRender.call(container);\r\n }", "function afterRenderActions(){\r\n var section = $(SECTION_ACTIVE_SEL);\r\n\r\n section.addClass(COMPLETELY);\r\n\r\n if(options.scrollOverflowHandler.afterRender){\r\n options.scrollOverflowHandler.afterRender(section);\r\n }\r\n lazyLoad(section);\r\n playMedia(section);\r\n options.scrollOverflowHandler.afterLoad();\r\n \r\n if(isDestinyTheStartingSection()){\r\n $.isFunction( options.afterLoad ) && options.afterLoad.call(section, section.data('anchor'), (section.index(SECTION_SEL) + 1));\r\n }\r\n\r\n $.isFunction( options.afterRender ) && options.afterRender.call(container);\r\n }", "function loadView() {\n\t\tvar srv1 = comc.request('cuen/list', $scope.cntx);\n\t\t\n\t\t$q.all([srv.stResp(true, srv1)]).then(function() {\n\t\t\tview();\n\t\t});\n\t}", "function gbViewDidAppear ()\n{\n\tif ( pluginDidDisappear )\n\t\trefresh ();\n}", "onContentLoading() {\r\n // Stub\r\n }", "function OnLoaded(){\n const sections=document.getElementsByTagName(\"section\");\n buildNavigationBar(sections);\n buildSectionArray(sections)\n createScrollToTopView();\n}", "function onPageLoad() {\n $('button[data-button-cerca]').click(ricercaConciliazione.bind(undefined, false));\n $(\"#buttonNuovaConciliazione\").click(apriCollapseNuovaConciliazione);\n $('#inserimento_buttonSalva').click(gestisciConciliazione.bind(undefined, 'inserimento', 'gestioneConciliazionePerTitolo_inserisci.do'));\n $('#aggiornamento_buttonSalva').click(gestisciConciliazione.bind(undefined, 'aggiornamento', 'gestioneConciliazionePerTitolo_aggiornamento.do'));\n\n definisciRadioEntrataSpesa();\n definisciCaricamentoSelectViaAjax();\n definisciPulsantiAnnullamento();\n definisciRicercaGuidataConto();\n\n $(document).on('contoCaricato', gestioneContoCaricato);\n }", "function lateRender() {\n\t\tsetTimeout( function() { // IE7 needs this so dimensions are calculated correctly\n\t\t\t\t\tif (!currentView.start && bodyVisible()) { // !currentView.start makes sure this never happens more than once\n\t\t\t\t\t\trenderView();\n\t\t\t\t\t}\n\t\t\t\t}, 0);\n\t}", "function queueViewHooks(def,tView,i){if(def.afterViewInit){(tView.viewHooks||(tView.viewHooks=[])).push(i,def.afterViewInit);}if(def.afterViewChecked){(tView.viewHooks||(tView.viewHooks=[])).push(i,def.afterViewChecked);(tView.viewCheckHooks||(tView.viewCheckHooks=[])).push(i,def.afterViewChecked);}}", "function onHtmlLoaded(){\n \n // move article if header height changes during browser resize\n\t$(window).resize(positionArticle);\n\t\n\t//Create top menu (buttons and username)\n addTopMenu();\n \n //initial positioning of articles based on header size \n positionArticle();\n \n currentArticleId = getUrlParam(\"id\"); //Get selected article ID\n \n var article = new Article(); //Create new article object \n article.getArticleById(currentArticleId).done(displayArticle); //Request article by id and display it\n \n}//END onHtmlLoaded function", "function _pageLoaded() {\n window.removeEventListener( 'load', _pageLoaded );\n refresh();\n }" ]
[ "0.711159", "0.6745946", "0.67163956", "0.6515156", "0.64583033", "0.642292", "0.64223933", "0.63748217", "0.6357358", "0.6349494", "0.63411504", "0.6320601", "0.629923", "0.6216456", "0.62116194", "0.61990196", "0.6172037", "0.6172037", "0.610932", "0.6107479", "0.6105994", "0.6065635", "0.6055234", "0.60444015", "0.6043808", "0.6026824", "0.6019145", "0.60055375", "0.60038006", "0.5970629", "0.59704876", "0.5963149", "0.5961257", "0.5960542", "0.5939135", "0.5938746", "0.5923388", "0.5919916", "0.59147197", "0.59146696", "0.59094274", "0.590167", "0.5894656", "0.58926415", "0.58891654", "0.58630544", "0.58619726", "0.5855732", "0.58428115", "0.5833029", "0.58193064", "0.5819158", "0.58153784", "0.5815227", "0.5811101", "0.5811101", "0.58070767", "0.5803918", "0.5803918", "0.5803918", "0.5793144", "0.5793144", "0.5793144", "0.579291", "0.579291", "0.5785226", "0.57806545", "0.57628417", "0.57621044", "0.574855", "0.574417", "0.574268", "0.5741604", "0.572438", "0.572438", "0.57209617", "0.57209617", "0.57209617", "0.57184374", "0.5718047", "0.57053536", "0.57053536", "0.5701735", "0.5700382", "0.5694864", "0.5687162", "0.5683507", "0.5683321", "0.56780195", "0.5672361", "0.56720406", "0.56720406", "0.5667318", "0.5648577", "0.5635818", "0.56336606", "0.56327426", "0.5629931", "0.5629332", "0.5629095", "0.56282115" ]
0.0
-1
this will set the params equal getParams it should only be use to create link for anchor or form.
function getRouteHelper(obj){ var tmpRoute; if(typeof(obj)=="string"){ tmpRoute = {action: obj, controller: currentControllerName}; } else{ tmpRoute = obj; } tmpRoute.getParams = $.extend({},tmpRoute.params); return $.extend({}, defaultRoute, tmpRoute); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function setArticleParams() {\n var articleId;\n var versionNumber;\n var runId;\n var url = window.location.pathname;\n if (config.ISPP) {\n // for use in the PP\n url = window.location.search;\n url = url.replace('?', '/');\n }\n\n url = url.split('/');\n url = _.compact(url);\n articleId = (!_.isEmpty(url[1])) ? url[1] : null;\n versionNumber = (!_.isEmpty(url[2])) ? url[2] : null;\n runId = (!_.isEmpty(url[3])) ? url[3] : null;\n\n /* If you have come through the PP nav we need to force some id's */\n if (config.ISPP && url[0] !== 'article') {\n articleId = '00353';\n versionNumber = '1';\n runId = 'c03211f7-6e1e-492d-9312-e0a80857873c';\n }\n\n detail.queryParams = {\n articleId: articleId,\n versionNumber: versionNumber,\n runId: runId,\n };\n }", "setParams() {\n helpers.setURLParams('?tool='+toolParam)\n }", "setParams() {\n helpers.setURLParams('?tool='+toolParam)\n }", "setParams() {\n helpers.setURLParams('?tool='+toolParam)\n }", "function replaceParams() {\n var href = $(this).attr(\"href\") || $(this).serialize()\n href = PlaceGuide.cleanParamString(href)\n var state = href.match(/[\\?\\&]/) ? $.deparam.querystring(href) : {}\n $.bbq.pushState(state, PlaceGuide.REPLACE_EXISTING)\n return false\n }", "updateParams(){\n\n\t\tconsole.log('params');\n\n\t\tvar self = this;\n\n\t\t\tfor (var key in this.attributes.filters) {\n\n\t\t\t\tif(self.attributes.filters[key]['active']==true){\n\t\t\t\t\tself.attributes.params[key] = self.attributes.filters[key]['value'];\n\t\t\t\t}\n\t\t\t}\n\n\t\tthis.sendParams();\n\n\t}", "function setURLParameters(paramobjs) {\n let nurl = new URL(window.location.href);\n let first = true;\n for (let key in paramobjs) {\n if (first) {\n nurl.searchParams.set(paramobjs[key].paramname, paramobjs[key].paramvalue);\n first = false;\n } else {\n nurl.searchParams.append(paramobjs[key].paramname, paramobjs[key].paramvalue);\n }\n }\n history.pushState('', document.title, nurl.toString());\n}", "function setDataUrlParams(params)\n\t{\n\t\tobjThis.selectorElt.tagSuggest().setDataUrlParams(params);\n\t}", "function setRouteParameters(params, saveHistory = false) {\r\n let url = UU5.Common.Url.parse(window.location.href.replace(/#.*/, \"\"))\r\n .set({ parameters: params })\r\n .toString();\r\n if (saveHistory) {\r\n history.pushState({}, document.title, url);\r\n } else {\r\n history.replaceState({}, document.title, url);\r\n }\r\n}", "function setParams()\n {\n //get advanced links width\n var width = $('#oc-link-advanced-player').outerWidth();\n Opencast.embedControlHide.setWidth(width);\n \n //get controll bars height\n var height = 0;\n \n for (var id in _elements) {\n if ($(_elements[id]).css('display') !== 'none') {\n height += $(_elements[id]).outerHeight();\n }\n }\n Opencast.embedControlHide.setHeight(height);\n }", "pushParams() {\n const entities = this.getEntities(),\n targetKeyword = this.isCategory() ? 'category' : 'files';\n\n if (window.history && window.history.replaceState) {\n window.history.replaceState({}, document.title,\n `?${$.param(this.getParams())}&${targetKeyword}=${entities.join('|')}`\n );\n }\n\n $('.permalink').prop('href', `?${$.param(this.getPermaLink())}&${targetKeyword}=${entities.join('%7C')}`);\n }", "function setParams(pageNumber) {\n\t\tvar params = {};\n\t\tparams.data = { \n\t\t\ttype : $scope.formData.type.map(function(a) {return a.value;}),\n\t\t\tregion : $scope.formData.region.map(function(a) {return a.value;}),\n\t\t\toxidation : $scope.formData.oxidation.map(function(a) {return a.value;}),\n\t\t\tleaf : $scope.formData.leaf.map(function(a) {return a.value;}),\n\t\t\tlabel : $scope.formData.label.map(function(a) {return a.value;}),\n\t\t\tprice: $scope.formData.price\n\t\t};\n\t\tparams.pageNumber = pageNumber;\n\t\tparams.pageItemsCount = $scope.itemsPerPage;\n\t\treturn params;\n\t}", "function grabLinkParams() {\n var url = new URL(window.location.href);\n var fulfillRequestTo = url.searchParams.get(\"fulfillRequestTo\");\n $(\"#destinationWalletOrEmail\").val(fulfillRequestTo);\n var fulfillRequestAmount = url.searchParams.get(\"fulfillRequestAmount\");\n $(\"#transactionAmount\").val(fulfillRequestAmount);\n }", "function setParams(state) {\r\n var selector = state.activeFilter.selector;\r\n var newParam = \"?filter=\" + selector.replace(/^\\./g, \"\");\r\n\r\n if (selector === targetSelector && getSelectorFromParam()) {\r\n // Equivalent to filter \"all\", remove the hash\r\n history.pushState(null, document.title, window.location.pathname);\r\n // or history.replaceState()\r\n } else if (\r\n newParam !== getSelectorFromParam() &&\r\n selector !== targetSelector\r\n ) {\r\n // Change the hash\r\n history.pushState(\r\n null,\r\n document.title,\r\n window.location.pathname + newParam\r\n ); // or history.replaceState()\r\n }\r\n }", "function createLink(actionContext, params) {\n var params_to_copy,\n mergedParams,\n k;\n if (actionContext.params.hasOwnProperty('merge')) {\n params_to_copy = actionContext.params.merged();\n } else {\n params_to_copy = actionContext.params.getFromMerged();\n }\n mergedParams = Y.mojito.util.copy(params_to_copy);\n for (k in params) {\n if (params.hasOwnProperty(k)) {\n mergedParams[k] = params[k];\n }\n }\n return actionContext.url.make('frame', 'index', Y.QueryString.stringify(mergedParams));\n }", "function addParamsToURL(){\n\t\t\n\t\tif (!$(\"#tsvDownload\").attr('baseDownloadLink')){\n\t\t\t$(\"#tsvDownload\").attr('baseDownloadLink', $(\"#tsvDownload\").attr('href'));\n\t\t}\n\n\t\tif (!$(\"#xlsDownload\").attr('baseDownloadLink')){\n\t\t\t$(\"#xlsDownload\").attr('baseDownloadLink', $(\"#xlsDownload\").attr('href'));\n\t\t}\n\t\t\n\t\tvar link = $(\"#tsvDownload\").attr('baseDownloadLink');\n\t\tlink += selectedFilters;\n\t\t$(\"#tsvDownload\").attr('href', link);\n\n\t\tlink = $(\"#xlsDownload\").attr('baseDownloadLink');\n\t\tlink += selectedFilters;\n\t\t$(\"#xlsDownload\").attr('href', link);\n\t}", "queryParams(params) {\n this.table = $('#searchtable');\n var options = this.table.bootstrapTable('getOptions');\n console.log('table opts', options);\n console.log('parmas', params);\n\n // this is necessary to ensure the backend has the validated API parameters it needs\n // the table pipeline extension renames some of the query parameters\n if (options.usePipeline) {\n params.order = params.sortOrder;\n params.sort = params.sortName;\n }\n return params;\n }", "function htmldb_Get_addParam(name,val){\n if ( this.params == '' )\n this.params = name + '='+ ( val != null ? this.escape(val) : '' );\n else\n //this.params = this.params + '&'+ name + '='+ ( val != null ? val : '' );\n this.params = this.params + '&'+ name + '='+ ( val != null ? this.escape(val) : '' );\n return;\n}", "updateUrl(action, params) {\n\n let url_params = {\n profile: params.profile,\n 'test-name': params.testName,\n 'data-provider': params.dataProvider,\n version: params.version,\n level: params.level\n };\n\n switch (action.isById) {\n case true:\n this.url = `${this.initUrl}${action.url}/${params.id}`\n break;\n\n case false:\n let queryParams = this.$httpParamSerializer(\n _.transform(url_params, (res, v, k) => {\n if (v) res[k] = v;\n }));\n this.url = `${this.initUrl}${action.url}?${queryParams}`;\n break;\n\n case 'irrelevant':\n url_params[id] = params.id;\n let queryParam = this.$httpParamSerializer(\n _.transform(url_params, (res, v, k) => {\n if (v) res[k] = v;\n }));\n this.url = `${this.initUrl}${action.url}?${queryParam}`;\n break;\n }\n }", "setParams(params){\n var state_manager = this,\n url, house, params;\n if (state_manager.update_in_progress) return false;\n state_manager.update_in_progress = true;\n\n params = Object.assign({}, state_manager.state, params);\n if (params.house_id){\n house = state_manager.houses.find((h)=>{ return h.data.id == params.house_id; });\n } else {\n house = state_manager.state.house || state_manager.houses[0];\n params.house_id = house.data.id;\n }\n\n house.verifyMonthState(params);\n if (params.dataset === 'irradiance'){\n params.date_interval = house.verifyPowerRange(params.date_interval || [], params);\n url = `/irradiance/${params.month}/${params.year}/${params.view}?${query_string.stringify({dates: params.date_interval})}`;\n } else if (params.dataset === 'energy'){\n url = `/houses/${params.house_id}/energy/${params.year}/${params.graph_attr}/${params.view}`;\n } else {\n params.date_interval = house.verifyPowerRange(params.date_interval || [], params);\n url = `/houses/${params.house_id}/power/${params.month}/${params.year}/${params.view}?${query_string.stringify({dates: params.date_interval})}`;\n }\n\n state_manager.history.push(url);\n }", "function setParams(a) {\n var prefix,\n s = [],\n add = function( key, valueOrFunction ) {\n\n // If value is a function, invoke it and use its return value\n var value = typeof obj === \"function\" && typeof obj.nodeType !== \"number\" ?\n valueOrFunction() :\n valueOrFunction;\n\n s[ s.length ] = encodeURIComponent( key ) + \"=\" +\n encodeURIComponent( value == null ? \"\" : value );\n };\n\n // encode each item\n for ( prefix in a ) {\n add( prefix, a[ prefix ] );\n }\n\n // Return the resulting serialization\n return s.join( \"&\" );\n }", "newParams() {\n return new _angular_common_http__WEBPACK_IMPORTED_MODULE_0__[\"HttpParams\"]({\n encoder: PARAMETER_CODEC\n });\n }", "function updateParamsToUrl(paramKey, paramValue) {\n\n paramValue = window.btoa(JSON.stringify(paramValue));\n\n var nextUrl = window.location.origin + window.location.pathname;\n\n var params = getUrlVars(); //Get all the query params as an ARRAY\n\n var size = Object.keys(params).length;\n var i = 0;\n if (size == 0) {\n window.location.href = window.location.href + \"?\" + paramKey + \"=\" + paramValue;\n } else {\n\n nextUrl += '?'; // ? for started to attach the query string to url\n\n params[paramKey] = paramValue;\n\n // This is for search,selection by any one of ways => BRAND or SEARCH Keyword\n if (paramKey == 'search' && params['brand'] != undefined) {\n params['brand'] = '';\n }\n if (paramKey == 'brand' && params['search'] != undefined) {\n params['search'] = '';\n }\n\n if (paramKey == 'brand') {\n params['width'] = '';\n params['diameter'] = '';\n }\n\n // Attach the query params to the nextURL \n $.each(params, function(key, value) {\n if (value != '') {\n if (i == size) {\n nextUrl += key + '=' + value;\n } else {\n nextUrl += key + '=' + value + '&';\n }\n }\n\n i++;\n });\n\n\n window.location.href = nextUrl;\n }\n}", "function updateParamsByUrl(){\n\t\t\n\t\tvar emptyCnt=resetAllTxtFields(\"paramKeyTxtName[]\");\n\t\tvar fullUrl = $('#OData').find('[name=\"oDataURL\"]').val();\n\t\t\n\t\tif(fullUrl!=null)\tfullUrl = fullUrl.trim();\n\t\t\n\t\tvar urlArr = fullUrl.split(\"?\");\n\t\tvar paramArr = \"\";\n\t\t//var paramStr = urlArr[1]; \n\t\tif( urlArr[1]!=null ){\n\t\t\tparamArr = urlArr[1].split(\"&\");\t\n\t\t}\n\t\t\n\t\tvar keyvalArr;\n\t\t\n\t\tif(paramArr!=null && paramArr.length>0){\n\t\t\tvar paramId, paramVal;\n\t\t\tfor(var idx=0; idx< paramArr.length; idx++){\n\t\t\t\tkeyvalArr = paramArr[idx].split(\"=\");\n\t\t\t\tparamId = keyvalArr[0];\n\t\t\t\tparamVal = keyvalArr[1];\n\t\t\t\tif(paramId === undefined) \tparamId=\"\";\n\t\t\t\tif(paramVal === undefined) \tparamVal=\"\";\n\t\t\t\tif(paramId!=\"\"){\n\t\t\t\t\taddParamRow(paramId,paramVal);\t\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tfor(var empCnt=0; empCnt<emptyCnt ; empCnt++){\n\t\t\t\taddParamRow(\"\",\"\");\n\t\t\t}\t\t\t\n\t\t}else{//Add a empty row if no parameter field\n\t\t\taddParamRow(\"\",\"\");\n\t\t}\n\t\t\n\t\t$(\"#oDataURL\").removeClass(\"txtFocusClass\");\n\t\t$(\"#oDataURL\").addClass(\"defaultTxtClass\");\n\t}", "function relay_parameters () {\n\n parameters = getURLParameters();\n\n $('a[href]:not(a[href^=\"javascript\"]):not(a[href^=\"mailto\"])').each( function () {\n\n for (var name in parameters) {\n var hash = $(this).attr('href').split('#')[1] ? ( '#' + $(this).attr('href').split('#')[1] ) : '';\n $(this).attr('href', updateURLParameter( $(this).attr('href').split('#')[0], name, parameters[name] ) + hash );\n\n }\n });\n\n}", "function linkParamsAndHash(env, scope, morph, path, params, hash) {\n if (morph.linkedParams) {\n params = morph.linkedParams.params;\n hash = morph.linkedParams.hash;\n } else {\n params = params && _expressionVisitor.acceptParams(params, env, scope);\n hash = hash && _expressionVisitor.acceptHash(hash, env, scope);\n }\n\n _htmlbarsUtilMorphUtils.linkParams(env, scope, morph, path, params, hash);\n return [params, hash];\n }", "function linkParamsAndHash(env, scope, morph, path, params, hash) {\n if (morph.linkedParams) {\n params = morph.linkedParams.params;\n hash = morph.linkedParams.hash;\n } else {\n params = params && _expressionVisitor.acceptParams(params, env, scope);\n hash = hash && _expressionVisitor.acceptHash(hash, env, scope);\n }\n\n _htmlbarsUtilMorphUtils.linkParams(env, scope, morph, path, params, hash);\n return [params, hash];\n }", "function linkParamsAndHash(env, scope, morph, path, params, hash) {\n if (morph.linkedParams) {\n params = morph.linkedParams.params;\n hash = morph.linkedParams.hash;\n } else {\n params = params && _expressionVisitor.acceptParams(params, env, scope);\n hash = hash && _expressionVisitor.acceptHash(hash, env, scope);\n }\n\n _htmlbarsUtilMorphUtils.linkParams(env, scope, morph, path, params, hash);\n return [params, hash];\n }", "setParams(){\r\n params = {};\r\n params[\"method\"] = this.sendMethod;\r\n params[\"headers\"] = this.sendHeaders;\r\n if (this.sendMethod !== \"GET\") {\r\n if (typeof params.headers['Content-Type'] == \"undefined\") {\r\n params.headers['Content-Type'] = 'application/x-www-form-urlencoded';\r\n }\r\n params[\"body\"] = this.sendData;\r\n }\r\n return params;\r\n }", "function setUrl(params) {\n\t\tvar key,\n querystring = \"?\";\n\n\t\tparams = QUnit.extend(QUnit.extend({}, QUnit.urlParams), params);\n\n\t\tfor (key in params) {\n\t\t\tif (params.hasOwnProperty(key)) {\n\t\t\t\tif (hasOwn.call(params, key)) {\n\t\t\t\t\tif (params[key] === undefined) {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tquerystring += encodeURIComponent(key);\n\t\t\t\t\tif (params[key] !== true) {\n\t\t\t\t\t\tquerystring += \"=\" + encodeURIComponent(params[key]);\n\t\t\t\t\t}\n\t\t\t\t\tquerystring += \"&\";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn location.protocol + \"//\" + location.host +\n location.pathname + querystring.slice(0, -1);\n\t}", "update() {\n\tlet usp = new search.URLSearchParams(location.hash)\n\tfor (let node of this.anchors) {\n\t let params = new search.URLSearchParams(node.hash)\n\t usp.set('m', params.get('m'))\n\t node.href = '#?' + usp.toString()\n\t}\n }", "function updateParam(name, value) {\n var newUrlHash = biomart.url.jsonify(location.href);\n if (value) biomart.params[name] = value;\n else delete biomart.params[name];\n _urlHash.query = $.param(biomart.params);\n newUrlHash.fragment = biomart.url.stringify(_urlHash);\n location = biomart.url.stringify(newUrlHash);\n }", "function linkParamsAndHash(env, scope, morph, path, params, hash) {\n if (morph.linkedParams) {\n params = morph.linkedParams.params;\n hash = morph.linkedParams.hash;\n } else {\n params = params && _expressionVisitor.acceptParams(params, env, scope);\n hash = hash && _expressionVisitor.acceptHash(hash, env, scope);\n }\n\n _htmlbarsUtilMorphUtils.linkParams(env, scope, morph, path, params, hash);\n return [params, hash];\n}", "function setupMakeTestParams(baseParams) {\n return function makeTestParams(name, url) {\n var params = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};\n\n return {\n name: name,\n requestParams: url,\n params: (0, _xtend2.default)(baseParams, params)\n };\n };\n}", "function createParam() {\n var singledovParams = {};\n var mattId = self.isGlobal ? self.docModel.matterid : self.matterId;\n mattId = parseInt(mattId);\n singledovParams.documentname = self.docModel.documentname;\n singledovParams.categoryid = self.docModel.category.doc_category_id;\n singledovParams.needs_review = self.docModel.needs_review ? 1 : 0;\n singledovParams.review_user = utils.isNotEmptyVal(self.reviewUser) ? self.reviewUser.toString() : ''; // assign reviewer user\n singledovParams.uploadtype = 'fresh';\n singledovParams.intake_id = mattId;\n singledovParams.associated_party_id = angular.isUndefined(self.docModel.associated_party_id) ? 0 : self.docModel.associated_party_id;\n singledovParams.party_role = self.docModel.party_role ? self.docModel.party_role : 0;\n singledovParams.tags = _.pluck(self.docAddTags, 'name');\n angular.isDefined(self.memo) ? singledovParams.memo = self.memo : singledovParams.memo = '';\n singledovParams.date_filed_date = utils.isNotEmptyVal(self.docModel.date_filed_date) ? moment.utc(self.docModel.date_filed_date).unix() : '';\n return singledovParams;\n }", "_prepareParams (params) {\n if (params == null) {\n params = {}\n }\n if (params.auth == null) {\n params.auth = {}\n }\n if (params.auth.key == null) {\n params.auth.key = this._authKey\n }\n if (params.auth.expires == null) {\n params.auth.expires = this._getExpiresDate()\n }\n\n return JSON.stringify(params)\n }", "function updateUrlParam() {\n // Update url parameter\n window.history.replaceState(\n null,\n null,\n `?page=${page}&limit=${perPage}&past-events=${pastEvents}`\n ); // -> set url param\n}", "function setParameters(e) {\n setModalTitle($(e.currentTarget));\n var articleId = ($(e.currentTarget).attr('data-article-id')) ? $(e.currentTarget).attr('data-article-id') : false;\n var articleScheduled = ($(e.currentTarget).attr('data-scheduled')) ? $(e.currentTarget).attr('data-scheduled') : false;\n schedule.articleId = articleId;\n schedule.articleScheduled = articleScheduled;\n schedule.scheduleActionType = $(e.currentTarget).attr('data-action-type');\n\n var data = {actionType: 'schedule', includeArticleId: false};\n if (schedule.scheduleActionType === 'schedule-cancel') {\n data.actionType = 'cancel';\n } else if (schedule.scheduleActionType === 'schedule-amend' || schedule.scheduleActionType === 'schedule' || schedule.scheduleActionType === 'future-schedule') {\n data.actionType = 'schedule';\n }\n\n if (schedule.scheduleActionType === 'future-schedule') {\n data.showArticleIdField = true;\n }\n\n $('#schedule-modal .modal-body').html(schedule.template.modalBody(data));\n $('#schedule-modal .modal-footer').html(schedule.template.modalFooter(data));\n\n }", "setParams() {\n this.from = this.params.from;\n this.to = this.params.to;\n this.start = this.params.start;\n this.end = this.params.end;\n\n this.airports = this.params.airports;\n\n // Get Airports if we don't have from the state params\n if (!this.airports) {\n this.airportsService.getAirports().then(res => {\n this.airports = {\n from: res.airports[this.from],\n to: res.airports[this.to]\n }\n });\n }\n }", "function updateURL () {\n var newSearch = \"?\" + Object.keys(parameters).filter(function (key) {\n return Boolean(parameters[key])\n }).map(function (key) {\n return encodeURIComponent(key) + \"=\" + encodeURIComponent(parameters[key])\n }).join(\"&\");\n history.replaceState(null, null, newSearch)\n }", "function parseCurrentUrlParams () {\n\t\tme.urlParams = me.paramsToObject(window.location.search.substr(1));\n\t}", "function getParams() {\n return util.copyObject(currentState.params);\n }", "makeParams(value){\n let params = {};\n params[this.attr('attr')] = {};\n params[this.attr('attr')][this.attr('ltKey')] = value || this.attr('value');\n params[this.attr('limitKey')] = 1;\n params.$sort = {};\n params.$sort[this.attr('attr')] = -1;\n // Merge in all attributes that start with 'param'\n Object.keys(this.attr()).forEach(key => {\n if (key.startsWith('param')) {\n let newKey = key.slice(5);\n newKey = newKey[0].toLowerCase() + newKey.slice(1);\n params[newKey] = this.attr(key);\n }\n });\n return params;\n }", "function setPara(model, parameters){\n var obj = {};\n model.forEach(function(prop) {obj[prop] = parameters[prop];});\n return obj;\n}", "function encodeParams () {\n\n }", "function updateParams() {\n let params = [];\n params.push(getPlayerParams());\n params.push(getPilesParams());\n document.getElementById('new_parameters').value = JSON.stringify(params);\n all_params = params;\n}", "function update_params () {\n\t\tvar config = Jupyter.notebook.config;\n\t\tfor (var key in params) {\n\t\t\tif (config.data.hasOwnProperty(key)) {\n\t\t\t\tparams[key] = config.data[key];\n\t\t\t}\n\t\t}\n\t}", "function addParams2TabsUrl(tabset , paramNames, paramValues){\r\n\tvar _paramNames = paramNames.split(\",\");\r\n\tvar _paramValues = paramValues.split(\",\");\r\n\tfor(var i=0; i<tabset.cells.length; i++){\r\n\t\tif(typeof(tabset.cells[i].targetUrl)!=\"undefined\"&&tabset.cells[i].targetUrl!=\"\"){\r\n\t\t\tfor(var j = 0;j<_paramNames.length;j++){\r\n\t\t\t\tif(j==0){\r\n\t\t\t\t\ttabset.cells[i].targetUrl = tabset.cells[i].targetUrl + \"?\" + _paramNames[j] + \"=\" + _paramValues[j];\r\n\t\t\t\t}else{\r\n\t\t\t\t\ttabset.cells[i].targetUrl = tabset.cells[i].targetUrl + \"&\" + _paramNames[j] + \"=\" + _paramValues[j];\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n}", "function toCrossroadsParams(state, abyssaParams) {\n var params = {},\n allQueryParams = state.allQueryParams();\n\n for (var key in abyssaParams) {\n if (allQueryParams[key]) {\n params.query = params.query || {};\n params.query[key] = abyssaParams[key];\n }\n else {\n params[key] = abyssaParams[key];\n }\n }\n\n return params;\n }", "async function getChangingParams() {\n let algod = await initAlgod()\n\n let params = await algod.getTransactionParams().do()\n params.fee = 1000\n params.flatFee = true\n // params.genesisHash = params.genHash\n return params\n}", "function setUrlSearchParams(data) {\n let urlSearchParams = new URLSearchParams();\n for (let name in data) {\n urlSearchParams.append(name, data[name]);\n }\n return urlSearchParams;\n}", "function setUrlSearchParams(data) {\n let urlSearchParams = new URLSearchParams();\n for (let name in data) {\n urlSearchParams.append(name, data[name]);\n }\n return urlSearchParams;\n}", "setearParams(kv, ma, md, fltr, anod) {\n\n //console.log(\"seteo nuevos parametros\");\n this.kilovolt = kv;\n this.miliamperios = ma;\n this.modo = md;\n this.filtro = fltr;\n this.anodo = anod;\n }", "link(outlet, params = {}) {\n const { _outletMap, _currentParams, _currentQueryParams } = this;\n let route = _outletMap[outlet];\n if (route === undefined) {\n return;\n }\n let linkPath = route.fullPath;\n if (route.fullQueryParams.length > 0) {\n let queryString = route.fullQueryParams.reduce((queryParamString, param, index) => {\n if (index > 0) {\n return `${queryParamString}&${param}={${param}}`;\n }\n return `?${param}={${param}}`;\n }, '');\n linkPath = `${linkPath}${queryString}`;\n }\n params = Object.assign({}, route.defaultParams, _currentQueryParams, _currentParams, params);\n if (Object.keys(params).length === 0 && route.fullParams.length > 0) {\n return undefined;\n }\n const fullParams = [...route.fullParams, ...route.fullQueryParams];\n for (let i = 0; i < fullParams.length; i++) {\n const param = fullParams[i];\n if (params[param]) {\n linkPath = linkPath.replace(`{${param}}`, params[param]);\n }\n else {\n return undefined;\n }\n }\n return this._history.prefix(linkPath);\n }", "function set_url_params(query, init_query) {\n var base_url = script_vars.current_url;\n var base_url_depaged = script_vars.current_url_depaged;\n var url = '';\n\n Object.keys(query).forEach(function(key) {\n console.log(query[key])\n // Go through each query key and set/delete url param\n if (typeof query[key] != 'undefined') {\n if(url) {\n url += '&';\n }\n url+= key + '=' + query[key];\n }\n })\n\n if(url) {\n url = '?' + url;\n }\n\n // If query has changed navigate to depaged base url (reset the page)\n if (query !== init_query) {\n // TODO - determine whether we need to detect page has not changed\n base_url = base_url_depaged;\n }\n\n window.location = base_url + url;\n }", "function clickParams()\n{\n\tvar model_id = getModelId();\n //changeStartTime();\n\n\tif ((model_id == null) || (model_id < 0))\n\t\treturn;\n\tif ((tab1.modelId == null) || (tab1.modelId != model_id)) {\n\t tab1.modelId = model_id;\n\t tab1.enabled = false;\n\t tab2.enabled = false;\n\t\t tab3.enabled = true;\n\t tab4.enabled = false;\n\t tab5.enabled = false;\n\t tab6.enabled = false;\n tab7.enabled = false;\n tab8.enabled = false;\n\t\t\n\t\tonTabClick(\"btn3\");\n\n\t\tshowModelName();\n\t\tclearModelParams();\n\t\tloadModelParams('false');\n\t} else {\n\t\ttab2.enabled = false;\n\t\ttab3.enabled = true;\n\t\tonTabClick(\"btn3\");\n\t}\n}", "setParam(param) {\n if (IsObject(param, ['internal_name', 'name'])) {\n PopLog.info(this.name, `Params set for ${param.internal_name}`, param);\n this.asset.param.set(param.internal_name, param);\n }\n }", "_appendParamsToUrl (url, params) {\n const sigData = this.calcSignature(params)\n const { signature } = sigData\n let jsonParams = sigData.params\n\n if (url.indexOf('?') === -1) {\n url += `?signature=${signature}`\n } else {\n url += `&signature=${signature}`\n }\n\n jsonParams = encodeURIComponent(jsonParams)\n url += `&params=${jsonParams}`\n\n return url\n }", "static prepareUrlParams(params) {\n return Object.keys(params)\n .filter(k => isTruthy(params[k]))\n .map(k => `${encodeURIComponent(k)}=${encodeURIComponent(params[k])}`)\n .join('&');\n }", "addParamToURL(urlParam) {\n if (this.props.showArticleFinder) { return; }\n window.history.pushState({}, '', `?showArticle=${urlParam}`);\n }", "createFormState(props) {\n const { node } = props;\n // console.log({ node });\n if (node) {\n const { config = {} } = this.context;\n const {\n input: { id, parameters: inputParameters },\n _links: { self: { href } },\n } = node;\n const parameters = {};\n inputParameters.map((parameter, index) => {\n parameters[index] = parameter;\n return parameter;\n });\n this.setState({ parameters, id, href: `${config._rootURL}${href}` });\n }\n }", "function PassParameters(el){\n\n\tvar source = getParameterByName('utm_source');\n\tvar medium = getParameterByName('utm_medium');\n\tvar campaign = getParameterByName('utm_campaign');\n\tvar content = getParameterByName('utm_content');\n\tvar term = getParameterByName('utm_term');\n\tvar newURL = \"https://donate.starlight.org.au/what-would-you-do//?\";\n\n\tif (source != \"\"){\n\t\tnewURL += \"utm_source=\" + source;\n\t}\n\tif (medium != \"\"){\n\t\tnewURL += \"&utm_medium=\" + medium;\n\t}\n\n\tif (campaign != \"\") {\n\t\tnewURL += \"&utm_campaign=\" + campaign;\n\t}\n\n\tif (term != \"\") {\n\t\tnewURL += \"&utm_term=\" + term;\n\t}\n\n\tif (content != \"\"){\n\t\tnewURL += \"&utm_content=\" + content;\n\t}\n\n\n\t$(el).attr('href', newURL); \n\n}", "function queryParams(params) {\n // params.advFilter = \"projectID\";\n params.hostID = id;\n params.sortName='levelRisk';\n params.sortOrder='desc';\n return(params);\n // return {advFilter: 'projectID', advFilterValue: id};\n}", "function getParams() {\n if (!window.frameElement.hasAttribute('data-params')) {\n return;\n }\n params = JSON.parse(decodeURIComponent(window.frameElement.getAttribute('data-params')));\n }", "function setPageURL(pagename, urlparams = undefined) {\n cleanURL().then(function () {\n switch (pagename) {\n case 'course_professormenu':\n case 'course_studentmenu':\n case 'panel-left':\n case 'desktopmainmenu':\n break;\n case 'coursehome':\n location.hash = pagename;\n setTimeout(function () {\n setURLParameters([{\n paramname: 'id',\n paramvalue: currentcourse.courseid\n }]);\n }, 300);\n break;\n default:\n location.hash = pagename;\n if (typeof urlparams !== 'undefined') {\n setTimeout(function () {\n setURLParameters(urlparams);\n }, 300);\n }\n }\n });\n}", "function getRssAndHtmlParams(type)\n{\n $.get(createLink('block', 'set', 'index=' + v.index + '&type=' + type), function(data)\n {\n $('#blockParam').html(data);\n $.setAjaxForm('#ajaxForm', function(){parent.location.href=config.webRoot + config.appName;});\n });\n}", "function redirectWithNewParam(a,b) {\r\n\t\tvar c,d;\r\n\t\tc=window.location.href;\r\n\t\tc=c.split(\"#\");\r\n\t\td=c.length==2?\"#\"+c[1]:\"\";\r\n\t\tc=c[0];\r\n\t\tvar e=c.match(/[\\?&]\\w+=[^&#]*/g), f={};\r\n\t\tif(e) for(var g=0;g<e.length;++g){\r\n\t\t\te[g]=e[g].split(\"=\");\r\n\t\t\tf[e[g][0].substring(1)]=decodeURIComponent(e[g][1].replace(/\\+/g,\"%20\"))\r\n\t\t}\r\n\t\tf[b]=a;\r\n\t\tf[\"persist_\"+b]=\"1\";\r\n\t\tc=c.split(\"?\");\r\n\t\tc=c[0];\r\n\t\toj(c,f,d);\r\n\t}", "storeParams(payloadData) {\n this.params = _.merge(this.params, payloadData)\n }", "function setLocationHashParams(params) {\n const out = [];\n for (const key in params) {\n if (params.hasOwnProperty(key)) {\n out.push(key + '=' + encodeURIComponent(params[key]));\n }\n }\n window.location.hash = out.join('&');\n}", "function setContentInstanceParams(instance, params) {\n Object.assign(instance, params);\n}", "function updateURLWithParams(paramsToUpdate, doReplace) {\n const url = new URL(window.location);\n for (const [param, val] of Object.entries(paramsToUpdate)) {\n if (val != undefined && (!val.trim || val.trim() !== \"\")) {\n url.searchParams.set(param, val);\n }\n else {\n url.searchParams.delete(param);\n }\n }\n updateURLTo(url, doReplace);\n}", "function generateLinkForPage(linkBase, qryParams, newPageNumber) {\n \tqryParams.page = newPageNumber;\n \tvar theLink = linkBase + \"?\" + toQueryString(qryParams);\n \treturn theLink;\n }", "_setParamIfEmpty(param){\r\n\t\t\r\n\t\tif(param == null) param = {};\r\n\t\t\r\n\t\tif(param['ajax_url'] == null) param['ajax_url'] = 'dummy';\r\n\t\t\r\n\t\treturn param;\r\n\t}", "function createParams(routePattern, fragment, queryString) {\n\t var params = routePattern.exec(fragment).slice(1);\n\t\n\t for (var i = 0; i < params.length; i++) {\n\t var current = params[i];\n\t params[i] = current ? decodeURIComponent(current) : null;\n\t }\n\t\n\t var queryParams = router.parseQueryString(queryString);\n\t if (queryParams) {\n\t params.push(queryParams);\n\t }\n\t\n\t return {\n\t params:params,\n\t queryParams:queryParams\n\t };\n\t }", "function setUrlParams(){\n (window.onpopstate = function () {\n var match,\n pl = /\\+/g, // Regex for replacing addition symbol with a space\n search = /([^&=]+)=?([^&]*)/g,\n decode = function (s) { return decodeURIComponent(s.replace(pl, \" \")); },\n query = window.location.search.substring(1);\n\n urlParams = new setUrlParamDefaults();\n while (match = search.exec(query))\n urlParams[decode(match[1])] = decode(match[2]);\n })();\n}", "setListParams() {\n var parameters = {\n CATEGORY_ID: \"\",\n SUBCATEGORY_ID: \"%\" + this.state.SUBCATEGORY_ID + \"%\",\n SUBCATEGORY_NAME: \"\",\n }\n return parameters\n }", "function setParamsOfChildNode() {\n if (inputFields) {\n // specific case for body type query/procedure variable with query params\n if (inputFields[param.name] && _.isObject(inputFields[param.name])) {\n paramValueInfo = inputFields[param.name];\n }\n else {\n paramValueInfo = inputFields;\n }\n params = _.get(operationInfo, ['definitions', param.type]);\n }\n else {\n // For Api Designer\n paramValueInfo = paramValue || {};\n params = param.children;\n }\n }", "processURL() {\n\t\t\tlet urlParams = {};\n\t\t\t// Get URL params - split em up - loop over them - fill urlParams object\n\t\t\twindow.location.search\n\t\t\t\t.replace('?', '')\n\t\t\t\t.split('&')\n\t\t\t\t.forEach(chunks => {\n\t\t\t\t\tlet kv = chunks.split('=');\n\t\t\t\t\turlParams[kv[0]] = kv[1];\n\t\t\t\t});\n\t\t\t// If a command URL is present.\n\t\t\tif (urlParams.hasOwnProperty('note')) {\n\t\t\t\tmethods.add('note', urlParams);\n\t\t\t\t// Clear the state.\n\t\t\t\twindow.history.pushState({}, document.title, '/');\n\t\t\t}\n\t\t}", "function HttpParamsOptions() {}", "function HttpParamsOptions() {}", "function params() {\n return (modal.params || {});\n }", "function setParameters(){\n var params = {};\n src = $('[src*=\"contrast.js\"').attr('src');\n if (src.substring(0, 4) != 'http') src = protocol + '//' + hostname + src;\n src.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) { params[key] = value; });\n css = params['css'];\n append = params['append'];\n if (append == null) append = 'body';\n }", "function _loadFromParams(ev, urlParams) {\n _safeChangeFilters(function () {\n var $filterGroup = $('.filter-group');\n _.each(urlParams.f, function (val, key) {\n\n var $e = $('#filter-' + key, $filterGroup);\n if ($e.length === 0) {\n return ;\n }\n\n if (val !== \"\") {\n $e.val(val);\n } else {\n $e.val(key === \"name\" ? \"\" : \"null\");\n }\n });\n });\n _runFilters();\n }", "function setParam (params) {\n content = $('.' + currentClass).html();\n $.each(params,function(key,value){\n var search = new RegExp('{{' + key + '}}','g');\n content = content.replace(search,value);\n });\n return content;\n }", "function HttpParamsOptions() { }", "function HttpParamsOptions() { }", "function HttpParamsOptions() { }", "_routeChange(e) {\n var details = e.detail;\n if (typeof details.queryParams.assignment !== typeof undefined) {\n this.set(\"queryParams.assignment\", details.queryParams.assignment);\n this.notifyPath(\"queryParams.assignment\");\n }\n if (typeof details.queryParams.project !== typeof undefined) {\n this.set(\"queryParams.project\", details.queryParams.project);\n this.notifyPath(\"queryParams.project\");\n }\n if (typeof details.queryParams.author !== typeof undefined) {\n this.set(\"queryParams.author\", details.queryParams.author);\n this.notifyPath(\"queryParams.author\");\n }\n if (typeof details.data.page !== typeof undefined) {\n this.set(\"data.page\", details.data.page);\n this.notifyPath(\"data.path\");\n }\n }", "function setParams(templateCode, params) {\n var resetParams = {};\n switch (templateCode) {\n case \"F1153_10\":\n case \"F1153_9\":\n resetParams = {\n template_code: templateCode,\n intake_id: parseInt(params.intakeId),\n time_zone: moment.tz.guess(),\n template_type: params.templatetype,\n plaintiff_id: angular.isDefined(params.plaintiff) ? [parseInt(params.plaintiff.intakePlaintiffId)] : [0],\n contact_id: utils.isNotEmptyVal(vm.referredById) ? [parseInt(vm.referredById.contactId)] : [0],\n contact_type: ['Local'],\n RETAINER_AGREEMENT_DATE: angular.isDefined(params.custom_date) ? moment.unix(params.custom_date).utc().format('MMMM D, YYYY') : '{RETAINER_AGREEMENT_DATE}'\n }\n break;\n case \"F1143_133\":\n // Dates Calculation\n var employmentStartDate = angular.isDefined(params.date_Employed_From1) ? moment.unix(params.date_Employed_From1).utc().format('MMMM DD, YYYY') : ''\n var employmentEndDate = angular.isDefined(params.date_Employed_To1) ? moment.unix(params.date_Employed_To1).utc().format('MMMM DD, YYYY') : ''\n var employmentStartDate2 = angular.isDefined(params.date_Employed_From2) ? moment.unix(params.date_Employed_From2).utc().format('MMMM DD, YYYY') : ''\n var employmentEndDate2 = angular.isDefined(params.date_Employed_To2) ? moment.unix(params.date_Employed_To2).utc().format('MMMM DD, YYYY') : ''\n var employmentStartDate3 = angular.isDefined(params.date_Employed_From3) ? moment.unix(params.date_Employed_From3).utc().format('MMMM DD, YYYY') : ''\n var employmentEndDate3 = angular.isDefined(params.date_Employed_To3) ? moment.unix(params.date_Employed_To3).utc().format('MMMM DD, YYYY') : ''\n\n var employmentDate1 = employmentStartDate + \" \" + employmentEndDate;\n var employmentDate2 = employmentStartDate2 + \" \" + employmentEndDate2;\n var employmentDate3 = employmentStartDate3 + \" \" + employmentEndDate3;\n\n //Employer Selection\n var employerIds = [];\n employerIds[0] = angular.isDefined(params.plaintiffEmployerIds) ? parseInt(params.plaintiffEmployerIds.intakeEmployerId) : 0;\n employerIds[1] = angular.isDefined(params.plaintiffEmployerIds_sec) ? parseInt(params.plaintiffEmployerIds_sec.intakeEmployerId) : 0;\n employerIds[2] = angular.isDefined(params.plaintiffEmployerIds_ter) ? parseInt(params.plaintiffEmployerIds_ter.intakeEmployerId) : 0;\n\n //Witness Selection\n var witnessIds = [];\n witnessIds[0] = angular.isDefined(params.witnessId) ? parseInt(params.witnessId.contact.contactId) : 0;\n witnessIds[1] = angular.isDefined(params.witnessId1) ? parseInt(params.witnessId1.contact.contactId) : 0;\n\n //Medical Provider and Physican selection\n var medicalproviderIds = [];\n medicalproviderIds[0] = (angular.isDefined(params.medicalproviderId) && params.medicalproviderId.medProvider.contactId) ? parseInt(params.medicalproviderId.medProvider.contactId) : 0;\n medicalproviderIds[1] = (angular.isDefined(params.medicalproviderId2) && params.medicalproviderId2.medProvider.contactId) ? parseInt(params.medicalproviderId2.medProvider.contactId) : 0;\n medicalproviderIds[2] = (angular.isDefined(params.medicalproviderId3) && params.medicalproviderId3.medProvider.contactId) ? parseInt(params.medicalproviderId3.medProvider.contactId) : 0;\n\n var medicalTreatmentIds = [];\n medicalTreatmentIds[0] = (angular.isDefined(params.medicalproviderId) && params.medicalproviderId.treatmentId) ? parseInt(params.medicalproviderId.treatmentId) : 0;\n medicalTreatmentIds[1] = (angular.isDefined(params.medicalproviderId2) && params.medicalproviderId2.treatmentId) ? parseInt(params.medicalproviderId2.treatmentId) : 0;\n medicalTreatmentIds[2] = (angular.isDefined(params.medicalproviderId3) && params.medicalproviderId3.treatmentId) ? parseInt(params.medicalproviderId3.treatmentId) : 0;\n\n resetParams = {\n template_code: templateCode,\n intake_id: parseInt(params.intakeId),\n time_zone: moment.tz.guess(),\n template_type: params.templatetype,\n plaintiff_id: angular.isDefined(params.plaintiff) ? [parseInt(params.plaintiff.intakePlaintiffId)] : [0],\n plaintiffEmployer_id: utils.isNotEmptyVal(employerIds) ? employerIds : [0],\n plaintiffEmployer_type: ['Local', 'Local', 'Local'],\n medicalprovider_id: utils.isNotEmptyVal(medicalproviderIds) ? medicalproviderIds : [0],\n medicalprovider_type: ['Local', 'Local', 'Local'],\n medicalTreatment_id: utils.isNotEmptyVal(medicalTreatmentIds) ? medicalTreatmentIds : [0],\n witness_id: utils.isNotEmptyVal(witnessIds) ? witnessIds : [0],\n user_id: angular.isDefined(params.assign_user) ? [parseInt(params.assign_user.userId)] : [0],\n insurance_id: angular.isDefined(params.onlyInsuranceId) ? [parseInt(params.onlyInsuranceId.intakeInsuranceId)] : [0],\n EMERGENCY_CONTACT_NUMBER: angular.isDefined(params.textBoxOne) ? params.textBoxOne : '{EMERGENCY_CONTACT_NUMBER}',\n ACCIDENT_DESCRIPTION: angular.isDefined(params.textBoxTwo) ? params.textBoxTwo : '{ACCIDENT_DESCRIPTION}',\n TIME_RESTRICTED_TO_BED_TEXT: angular.isDefined(params.textBoxThree) ? params.textBoxThree : '{TIME_RESTRICTED_TO_BED_TEXT}',\n TIME_RESTRICTED_TO_HOUSE_TEXT: angular.isDefined(params.textBoxFour) ? params.textBoxFour : '{TIME_RESTRICTED_TO_HOUSE_TEXT}',\n LOSS_OF_SERVICES_DESCRIPTION_TEXT: angular.isDefined(params.textBoxFive) ? params.textBoxFive : '{LOSS_OF_SERVICES_DESCRIPTION_TEXT}',\n POLICE_OFFICER_ACCIDENT_REPORT_INFORMATION_TEXT: angular.isDefined(params.textBoxSix) ? params.textBoxSix : '{POLICE_OFFICER_ACCIDENT_REPORT_INFORMATION_TEXT}',\n PRIOR_ACCIDENTS_OR_INJURIES_TEXT: angular.isDefined(params.textBoxSeven) ? params.textBoxSeven : '{PRIOR_ACCIDENTS_OR_INJURIES_TEXT}',\n SUBSEQUENT_ACCIDENTS_OR_INJURIES_TEXT: angular.isDefined(params.textBoxEight) ? params.textBoxEight : '{SUBSEQUENT_ACCIDENTS_OR_INJURIES_TEXT}',\n PRIOR_RELATED_MEDICAL_CONDITIONS_TEXT: angular.isDefined(params.textBoxNine) ? params.textBoxNine : '{PRIOR_RELATED_MEDICAL_CONDITIONS_TEXT}',\n MEANS_OF_CALCULATION_TEXT: angular.isDefined(params.textBoxTen) ? params.textBoxTen : '{MEANS_OF_CALCULATION_TEXT}',\n LIABILITY_BASIS_TEXT: angular.isDefined(params.userValueOne) ? params.userValueOne : '{LIABILITY_BASIS_TEXT}',\n SOCIAL_SECURITY_DISABILITY_INFORMATION_TEXT: angular.isDefined(params.userValueTwo) ? params.userValueTwo : '{SOCIAL_SECURITY_DISABILITY_INFORMATION_TEXT}',\n USER_ADDRESS: angular.isDefined(params.userValueThree) ? params.userValueThree : '{USER_ADDRESS}',\n USER_RESIDENCE_STATE: angular.isDefined(params.userValueFour) ? params.userValueFour : '{USER_RESIDENCE_STATE}',\n USER_RESIDENCE_COUNTY: angular.isDefined(params.userValueFive) ? params.userValueFive : '{USER_RESIDENCE_COUNTY}',\n PLAINTIFF_SPOUSE_SSN: angular.isDefined(params.userValueSix) ? params.userValueSix : '{PLAINTIFF_SPOUSE_SSN}',\n AMOUNT_OF_LOST_INCOME_TEXT: utils.isNotEmptyVal(params.amountInNumbers1) ? params.amountInNumbers1 : '{AMOUNT_OF_LOST_INCOME_TEXT}',\n BILLED_AMOUNT_1: utils.isNotEmptyVal(params.amountInNumbers2) ? params.amountInNumbers2 : '{BILLED_AMOUNT_1}',\n BILLED_AMOUNT_2: utils.isNotEmptyVal(params.amountInNumbers3) ? params.amountInNumbers3 : '{BILLED_AMOUNT_2}',\n BILLED_AMOUNT_3: utils.isNotEmptyVal(params.amountInNumbers4) ? params.amountInNumbers4 : '{BILLED_AMOUNT_3}',\n PLAINTIFF_GROSS_PAY_1: utils.isNotEmptyVal(params.amountInNumbers5) ? params.amountInNumbers5 : '{PLAINTIFF_GROSS_PAY_1}',\n PLAINTIFF_GROSS_PAY_2: utils.isNotEmptyVal(params.amountInNumbers6) ? params.amountInNumbers6 : '{PLAINTIFF_GROSS_PAY_2}',\n PLAINTIFF_GROSS_PAY_3: utils.isNotEmptyVal(params.amountInNumbers7) ? params.amountInNumbers7 : '{PLAINTIFF_GROSS_PAY_3}',\n DATE_OF_FILING: angular.isDefined(params.filling_date) ? moment.unix(params.filling_date).utc().format('MMMM D, YYYY') : '{DATE_OF_FILING}',\n PLAINTIFF_DATE_OF_MARRIAGE: angular.isDefined(params.marriage_date) ? moment.unix(params.marriage_date).utc().format('MMMM D, YYYY') : '{PLAINTIFF_DATE_OF_MARRIAGE}',\n PLAINTIFF_DATES_EMPLOYED_1: utils.isNotEmptyVal(employmentDate1) ? employmentDate1 : '{PLAINTIFF_DATES_EMPLOYED_1}',\n PLAINTIFF_DATES_EMPLOYED_2: utils.isNotEmptyVal(employmentDate2) ? employmentDate2 : '{PLAINTIFF_DATES_EMPLOYED_2}',\n PLAINTIFF_DATES_EMPLOYED_3: utils.isNotEmptyVal(employmentDate3) ? employmentDate3 : '{PLAINTIFF_DATES_EMPLOYED_3}'\n }\n break;\n\n case \"F1563_11\":\n resetParams = {\n template_code: templateCode,\n intake_id: parseInt(params.intakeId),\n time_zone: moment.tz.guess(),\n template_type: params.templatetype,\n plaintiff_id: angular.isDefined(params.plaintiff) ? [parseInt(params.plaintiff.intakePlaintiffId)] : [0],\n plaintiffEmployer_id: angular.isDefined(params.plaintiffEmployerIdsNew) ? [params.plaintiffEmployerIdsNew.intakeEmployerId] : [0],\n plaintiffEmployer_type: ['Local'],\n medicalTreatment_id: angular.isDefined(params.medicalProviderPhysicians) ? [params.medicalProviderPhysicians.contactId] : [0],\n medicalprovider_id: angular.isDefined(params.medicalServiceProvider) ? [params.medicalServiceProvider.contactId] : [0],\n medicalprovider_type: ['Local'],\n insurance_id: angular.isDefined(params.insuredParty) ? [params.insuredParty.intakeInsuranceId] : [0],\n ACCIDENT_TIME: angular.isDefined(params.accidentTime) ? params.accidentTime : '{ACCIDENT_TIME}',\n ACCIDENT_DESCRIPTION: angular.isDefined(params.textBoxTwo) ? params.textBoxTwo : '{ACCIDENT_DESCRIPTION}',\n VEHICLE_INFORMATION: angular.isDefined(params.vehicleInformation) ? params.vehicleInformation : '{VEHICLE_INFORMATION}'\n }\n break;\n\n case \"F1563_13\":\n resetParams = {\n template_code: templateCode,\n intake_id: parseInt(params.intakeId),\n time_zone: moment.tz.guess(),\n template_type: params.templatetype,\n plaintiff_id: angular.isDefined(params.plaintiff) ? [parseInt(params.plaintiff.intakePlaintiffId)] : [0],\n DATE_OF_SERVICE: angular.isDefined(params.serviceDates) ? params.serviceDates.startEndDate : '{DATE_OF_SERVICE}',\n medicalprovider_id: angular.isDefined(params.medicalServiceProvider) ? [params.medicalServiceProvider.contactId] : [0],\n medicalprovider_type: ['Local'],\n }\n break;\n }\n return resetParams;\n }", "function flushParams() {\n\n s.events = \"\";\n s.campaign = \"\";\n s.linkTrackVars = \"\";\n s.linkTrackEvents = \"\";\n s.Media.trackVars = \"\";\n s.Media.trackEvents = \"\";\n\n s.eVar1 = \"\";\n s.eVar2 = \"\";\n s.eVar3 = \"\";\n s.eVar4 = \"\";\n s.eVar5 = \"\";\n s.eVar6 = \"\";\n s.eVar7 = \"\";\n s.eVar8 = \"\";\n s.eVar9 = \"\";\n s.eVar10 = \"\";\n s.eVar11 = \"\";\n s.eVar12 = \"\";\n s.eVar13 = \"\";\n s.eVar14 = \"\";\n s.eVar15 = \"\";\n s.eVar16 = \"\";\n s.eVar17 = \"\";\n s.eVar18 = \"\";\n s.eVar19 = \"\";\n s.eVar20 = \"\";\n s.eVar21 = \"\";\n s.eVar22 = \"\";\n s.eVar23 = \"\";\n\n s.hier1 = \"\";\n s.hier3 = \"\";\n\n s.prop1 = \"\";\n s.prop2 = \"\";\n s.prop3 = \"\";\n s.prop4 = \"\";\n s.prop5 = \"\";\n s.prop6 = \"\";\n s.prop7 = \"\";\n s.prop8 = \"\";\n s.prop9 = \"\";\n s.prop10 = \"\";\n s.prop11 = \"\";\n s.prop12 = \"\";\n s.prop13 = \"\";\n s.prop14 = \"\";\n s.prop15 = \"\";\n s.prop16 = \"\";\n s.prop17 = \"\";\n s.prop18 = \"\";\n s.prop19 = \"\";\n s.prop20 = \"\";\n }", "function setQueryParameter(name, val) {\n\tfunction updateURLParameter(url, param, paramVal){\n\t\tvar newAdditionalURL = \"\";\n\t\tvar tempArray = url.split(\"?\");\n\t\tvar baseURL = tempArray[0];\n\t\tvar additionalURL = tempArray[1];\n\t\tvar temp = \"\";\n\t\tif (additionalURL) {\n\t\t\ttempArray = additionalURL.split(\"&\");\n\t\t\tfor (var i=0; i<tempArray.length; i++){\n\t\t\t\tif(tempArray[i].split('=')[0] !== param){\n\t\t\t\t\tnewAdditionalURL += temp + tempArray[i];\n\t\t\t\t\ttemp = \"&\";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tvar rows_txt = temp + \"\" + param + \"=\" + paramVal;\n\t\treturn baseURL + \"?\" + newAdditionalURL + rows_txt;\n\t}\n\n\twindow.history.replaceState('', '', updateURLParameter(window.location.href, name, val.toString()));\n}", "function makeParams(div$) {\n var el = div$[0]\n var params = defaultParams()\n\n var convertAttrs = function(str, lowercase) {\n var out\n str = $.trim(str)\n if (lowercase == false) {\n out = str\n }\n else if (str.toLowerCase() === \"false\") {\n out = false\n }\n else if (str.toLowerCase() === \"true\") {\n out = true\n }\n else {\n out = str.toLowerCase()\n }\n return out\n }\n\n for (var i=0;i<el.attributes.length;i++){\n var key = convertAttrs(el.attributes[i].nodeName, true)\n if (key.indexOf(\"data-\") === 0) {\n var key = key.replace(\"data-\", \"\")\n\n var defaultVal = params[key]\n\n var val\n if (key == \"on-finish\") {\n val = convertAttrs(el.attributes[i].nodeValue, false)\n }\n else {\n val = convertAttrs(el.attributes[i].nodeValue, true)\n }\n params[key] = val\n }\n }\n\n return params\n }", "setListParams() {\n var parameters = {\n CATEGORY_ID: \"\",\n SUBCATEGORY_ID: \"\",\n SUBCATEGORY_NAME: \"\",\n\n }\n\n return parameters\n }", "saveUrlParams () {\n throw new Error('You have to implement the method saveUrlParams!')\n }", "function setGoToData(){\n\t\t\t//set links array\n\t\t\t$scope.goToData.links.push({type: 'user id', namePath: 'id', sref: 'spa.user.userEdit', paramKey: 'userId', paramPath: 'id'});\n\t\t\tif(hasAccountsPermissions) $scope.goToData.links.push({type: 'account', namePath: 'accountName', sref: 'spa.account.accountEdit', paramKey: 'accountId', paramPath: 'accountId'});\n\t\t\t//$scope.goToData.links.push({type: 'permissions', namePath: 'id', sref: 'spa.user.userPermissions', paramKey: 'userId', paramPath: 'id'});\n\n\t\t\t//due to the fact that HISTORY action was already added by entityLayout.js, needs to reorder the actions and add HISTORY to be last\n\t\t\t//set actions array\n\t\t\t$scope.goToData.actions.splice(0, 0, {name: 'New User', func: addNewUser});\n\t\t\t$scope.goToData.actions.splice(1, 0, {name: 'Delete', func: deleteEntity});\n\t\t}", "function serialize_params(newparams){\n let params = new URLSearchParams(window.location.search);\n const validCategories = [\"a\",\"n\",\"q\"] //list of params that should be encoded\n //encodes params, deleting any that are empty\n for (const key in newparams){\n if (validCategories.includes(key)) {\n //if there's any content left in the param, update it. If not, delete it.\n newparams[key].length ? params.set(key, Base64.encodeURI(JSON.stringify(newparams[key]))) : params.delete(key);\n }\n }\n //if there are any params that shouldn't be encoded, deal with them here\n const utilParams = [\"t\"];\n //sets changes to threshold value---removes if value is at default number of if it's not a number\n if (typeof newparams[\"t\"] === \"number\"){\n if (newparams[\"t\"] === 0.4){\n params.delete(\"t\");\n } else {\n params.set(\"t\", newparams[\"t\"]);\n }\n } else {\n params.delete(\"t\");\n }\n //deletes any params that aren't approved\n params.forEach(function(value, key){\n if (!validCategories.includes(key) && !utilParams.includes(key)){\n params.delete(key);\n }\n });\n window.location.search = params;\n}", "function updateLinks(url, obj) {\n var pathArray = url.split( '/'),\n // pathArray = window.location.href.split( '/'),\n protocol = pathArray[0],\n host = pathArray[2],\n baseUrl = protocol + '//' + host,\n theUrl = url.split('?')[0],\n params = '',\n counter = 0,\n // url = window.location.href.split('?')[0],\n // params = obj,\n // params = window.location.href.split('?')[1],\n noParams = true,\n links = $(\"a[href^='\"+baseUrl+\"'], a[href^='/'], a[href^='./'], a[href^='../'], a[href^='#']\");\n $.each( obj, function( key, value ) {\n if (counter == 0) {\n params = '?' + key + '=' + value;\n counter = counter + 1;\n }\n else {\n params = params + '&' + key + '=' + value;\n counter = counter + 1;\n }\n });\n // if (url != params) {\n if (theUrl != params) {\n noParams = false;\n links.each(function(){\n console.log('updating the links:');\n var hrefTemp = $(this).attr(\"href\");\n hrefTemp = hrefTemp.split('?')[0];\n console.log(hrefTemp);\n console.log(params);\n $(this).attr(\"href\", hrefTemp + params);\n });\n }\n }", "function addParams(name, jsonParams) {\n var newString;\n var newParams = \"\";\n for (var prop in jsonParams) {\n newString = `${name}[${prop}]=${jsonParams[prop]}&`;\n //console.log(newString);\n newParams = newParams.concat(newString);\n }\n //console.log(\"new\", newParams);\n newParams = newParams.slice(0,-1);\n return newParams;\n}", "function setQueryParams(params) {\n const queryItems = Object.keys(params)\n .map(key => `${encodeURIComponent(key)}=${encodeURIComponent(params[key])}`)\n return queryItems.join('&');\n}", "function setParams() {\r\n \r\n for(Entry<String,Double> e : body.metabolicParameters.get(body.bodyState.state).get(BodyOrgan.BRAIN.value).entrySet()) {\r\n switch (e.getKey()) {\r\n case \"glucoseOxidized_\" : { glucoseOxidized_ = e.getValue(); break; }\r\n case \"glucoseToAlanine_\" : { glucoseToAlanine_ = e.getValue(); break; }\r\n case \"bAAToGlutamine_\" : { bAAToGlutamine_ = e.getValue(); break; }\r\n }\r\n }\r\n //System.out.println(\"glucoseOxidized: \" + glucoseOxidized_);\r\n }", "function processURLParameters() {\r\n originalURL = decodeURIComponent(window.location.href);\r\n var params = {};\r\n // look for the params\r\n if (originalURL.indexOf(\"#\") != -1) {\r\n var qString = originalURL.split('#')[1];\r\n var args = qString.split(',');\r\n originalURL = originalURL.split('#')[0];\r\n ac.loadCategoryItem(args[0], args[1]);\r\n return;\r\n \t} else if (originalURL.indexOf(\"?\") != -1) {\r\n var qString = originalURL.split('?')[1];\r\n // get rid of any bookmarking stuff\r\n if (qString.indexOf(\"#\") != -1) {\r\n qString = qString.split('#')[0];\r\n originalURL = originalURL.split('#')[0];\r\n window.location.href = originalURL;\r\n }\r\n ps = qString.split('&');\r\n // now go through and create the params map as an object literal\r\n for (var i in ps) {\r\n var t = ps[i].split('=');\r\n params[t[0]] = t[1];\r\n }\r\n // first check for the item in product \r\n if (typeof params.itemId != 'undefined' && typeof params.pid != 'undefined') {\r\n ac.loadCategoryItem(params.pid, params.itemId);\r\n \t// next if there is a catid definition then do it\r\n } else if (typeof params.catid != 'undefined') {\r\n ac.showCategory(params.catid);\r\n }\r\n } else {\r\n // nothing is selected\r\n ac.showFirstCategory();\r\n }\r\n }" ]
[ "0.64227766", "0.61190534", "0.61190534", "0.61190534", "0.5958614", "0.5878475", "0.5807637", "0.57913107", "0.57556915", "0.5747033", "0.5643816", "0.5635349", "0.5610925", "0.5591237", "0.55659074", "0.553835", "0.5536452", "0.5535456", "0.55133504", "0.5488656", "0.5484229", "0.5476831", "0.54664475", "0.54639995", "0.54628485", "0.5456447", "0.5456447", "0.5456447", "0.54516083", "0.54361326", "0.5427742", "0.5423951", "0.53610724", "0.53514767", "0.532626", "0.52820355", "0.5273528", "0.52732944", "0.52511233", "0.5222749", "0.52138793", "0.519878", "0.5179517", "0.517707", "0.51678574", "0.51557326", "0.5153177", "0.51518035", "0.51493794", "0.5137831", "0.51294523", "0.51294523", "0.5128538", "0.5126589", "0.51221895", "0.5113962", "0.51115656", "0.51078886", "0.5101381", "0.50958896", "0.5090254", "0.5082386", "0.5072531", "0.5068286", "0.50679356", "0.5066324", "0.5065416", "0.50504285", "0.50309235", "0.5017053", "0.5015834", "0.50117743", "0.50093514", "0.5006141", "0.50016576", "0.4999676", "0.4991146", "0.4987601", "0.49859536", "0.49859536", "0.49691388", "0.49628997", "0.49627084", "0.49619606", "0.4957155", "0.4957155", "0.4957155", "0.49430728", "0.49418792", "0.49406645", "0.49379897", "0.4933691", "0.4922315", "0.4918617", "0.4914673", "0.4913532", "0.4912612", "0.48935723", "0.48899907", "0.4883628", "0.4875247" ]
0.0
-1
get argument names of a callback function.
function getParamNames(func) { var fnStr = func.toString().replace(STRIP_COMMENTS, '') var result = fnStr.slice(fnStr.indexOf('(')+1, fnStr.indexOf(')')).match(ARGUMENT_NAMES) if(result === null) result = [] return result }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function argumentNames(fn) {\n\t var names = fn.toString().match(/^[\\s\\(]*function[^(]*\\(([^)]*)\\)/)[1]\n\t .replace(/\\/\\/.*?[\\r\\n]|\\/\\*(?:.|[\\r\\n])*?\\*\\//g, '')\n\t .replace(/\\s+/g, '').split(',');\n\t return names.length == 1 && !names[0] ? [] : names;\n\t}", "function argumentNames(f) {\n var paramsString = /^function\\s*.*?\\((.*?)\\)/.exec(f.toString())[1];\n var argumentNames = !!paramsString ? paramsString.split(/\\s*,\\s*/) : [];\n return Iterable_1.list(argumentNames);\n}", "function _getParamNames(func) {\n var funStr = func.toString();\n return funStr.slice(funStr.indexOf('(')+1, funStr.indexOf(')')).match(/([^\\s,]+)/g);\n}", "function getArgumentNames(method) {\n var names = method.toString().match(/^[\\s\\(]*function[^(]*\\(([^)]*)\\)/)[1]\n .replace(/\\/\\/.*?[\\r\\n]|\\/\\*(?:.|[\\r\\n])*?\\*\\//g, '')\n .replace(/\\s+/g, '').split(',');\n return names.length == 1 && !names[0] ? [] : names;\n }", "function getParamNames(func) {\n const fnStr = func.toString().replace(STRIP_COMMENTS, '');\n let result = fnStr\n .slice(fnStr.indexOf('(') + 1, fnStr.indexOf(')'))\n .split(',')\n .map(content => {\n return content.trim().replace(/\\s?=.*$/, '');\n });\n if (result.length === 1 && result[0] === '') {\n result = [];\n }\n return result;\n}", "function getArgAndCb(arg, callback, def) {\n\t return typeof arg === 'function' ? [def, arg] : [arg, callback];\n\t}", "function getRuleArgNames(rule) {\n var args = [language.silence];\n\n if (rule.hasBoolParams) {\n args.push(language.boolParams);\n }\n\n for (let name in rule.passedParams) {\n let type = rule.passedParams[name].type;\n if (type === undefined || type === 'boolean') {\n continue;\n } else if (type === 'reference') {\n args.push(language.refParamArgDeclarator(name));\n } else {\n args.push(language.paramArgName(name));\n }\n }\n return args;\n }", "function guess_callback(argsi, array) {\n var callback = argsi[0], args = slice.call(argsi, 1), scope = array, attr;\n\n if (typeof(callback) === 'string') {\n attr = callback;\n if (array.length !== 0 && typeof(array[0][attr]) === 'function') {\n callback = function(object) { return object[attr].apply(object, args); };\n } else {\n callback = function(object) { return object[attr]; };\n }\n } else {\n scope = args[0];\n }\n\n return [callback, scope];\n}", "static performCallbacks(callbacks) {\n // This is my method of getting all the arguments except for the list of callbacks\n const args = Array.prototype.slice.call(arguments, 1);\n callbacks.forEach((callback) => {\n // To use the arguments I have to use the apply method of the function\n callback(...args);\n });\n }", "function getCallbackFromArgs( argumentList ) {\n var callbackObject = [];\n\n if ( argumentList && argumentList.length ) {\n for ( var i in argumentList ) {\n switch( typeof argumentList[i] ) {\n case \"function\":\n throw new Error()\n case \"object\": \n case \"number\":\n case \"array\":\n default:\n // this does not check for other functions within objects...\n callbackObject.push(JSON.parse(JSON.stringify(argumentList[i])));\n break;\n }\n }\n \n }\n return callbackObject;\n }", "function nums(){\n\tconst bindArgs = Array.from(arguments).slice(1);\n\tconst callArgs = Array.from(arguments);\n\tconsole.log(`bindArgs: ${bindArgs}`);\n\tconsole.log(`callArgs: ${callArgs}`);\n}", "function myfunctionarg(a,b){\r\n return arguments.length;\r\n}", "function inspectArgs() {\n for (let i = 0; i < arguments.length; i++) {\n console.log(arguments[i]);\n }\n}", "function get_arg() { return arguments; }", "function getCallBackParams(d, elem, prop) {\n var cbParams = { datum: d\n , elem: elem\n , prop: prop // NB - untyped assignment - only use in mkCallback fns\n , timestamp: d3.event.timeStamp\n , meta: d3.event.metaKey\n , shift: d3.event.shiftKey\n , ctrl: d3.event.ctrlKey\n , alt: d3.event.altKey };\n return cbParams;\n}", "parameterNames() {\n\t\tconst params = [];\n\t\tif (this.parameterMetadata) {\n\t\t\tfor (const param of this.parameterMetadata.paramDefs) {\n\t\t\t\tparams.push(param.name);\n\t\t\t}\n\t\t}\n\t\treturn params;\n\t}", "function g() {\n return g.arguments;\n}", "function getArgs() {\n var result = [];\n var i;\n for (i = 0; i < args.length; i++) result.push(args[i]);\n return result;\n }", "function getParams(func) {\n // String representaation of the function code\n var str = func.toString();\n\n // Remove comments of the form /* ... */\n // Removing comments of the form //\n // Remove body of the function { ... }\n // removing '=>' if func is arrow function\n str = str\n .replace(/\\/\\*[\\s\\S]*?\\*\\//g, \"\")\n .replace(/\\/\\/(.)*/g, \"\")\n .replace(/{[\\s\\S]*}/, \"\")\n .replace(/=>/g, \"\")\n .trim();\n\n // Start parameter names after first '('\n var start = str.indexOf(\"(\") + 1;\n\n // End parameter names is just before last ')'\n var end = str.length - 1;\n\n var result = str.substring(start, end).split(\", \");\n\n var params = [];\n\n result.forEach((element) => {\n // Removing any default value\n element = element.replace(/=[\\s\\S]*/g, \"\").trim();\n\n if (element.length > 0) params.push(element);\n });\n\n return params;\n}", "function myCallback(callbackName) {\n console.log(\"this is my name \" + callbackName);\n}", "function myFunction(){\n console.log(arguments);\n}", "public function keys()\n {\n return array_keys($this->parameters);\n }", "function howManyArgs() {\n console.log(arguments[0]);\n console.log(arguments.length);\n}", "function myFunc() {\n console.log(arguments)\n }", "function myFunction(a, b) {\n console.log(arguments);\n}", "function argList(s) {\n return s.match(/^\\w+\\((.*)\\)$/)[1].match(/(\\w+)/g);\n}", "getArgs(ctx) {\n const args = [ctx.bufArg(), ctx.offArg()];\n if (this.ref.signature === 'value') {\n args.push(ctx.matchVar());\n }\n return args;\n }", "function countArguments(func) {\n console.log(func.length);\n}", "listGlobalFuncNames() {\n const stack = this.lib.getOrAllocCallStack();\n const outSizeOffset = stack.allocPtrArray(2);\n const outSizePtr = stack.ptrFromOffset(outSizeOffset);\n const outArrayPtr = stack.ptrFromOffset(outSizeOffset + this.lib.sizeofPtr());\n this.lib.checkCall(this.exports.TVMFuncListGlobalNames(outSizePtr, outArrayPtr));\n const size = this.memory.loadI32(outSizePtr);\n const array = this.memory.loadPointer(outArrayPtr);\n const names = [];\n for (let i = 0; i < size; ++i) {\n names.push(this.memory.loadCString(this.memory.loadPointer(array + this.lib.sizeofPtr() * i)));\n }\n this.lib.recycleCallStack(stack);\n return names;\n }", "getParams(func) {\n var fnStr = func.toString().replace(/((\\/\\/.*$)|(\\/\\*[\\s\\S]*?\\*\\/))/mg, '');\n return fnStr.slice(fnStr.indexOf('(') + 1, fnStr.indexOf(')')).match(/([^\\s,]+)/g) || [];\n }", "function callback(arg){\n console.log(arg)\n}", "keys( cb ){\n\t\tlet _keys = Object.keys( this.data );\n\t\tif (cb != null) { cb( null, _keys ); }\n\t\treturn _keys;\n\t}", "function arg_len() { return arguments.length; }", "function argsFor() {\n\n}", "function UniqueArgumentNames(context) {\n\t var knownArgNames = _Object$create(null);\n\t return {\n\t Field: function Field() {\n\t knownArgNames = _Object$create(null);\n\t },\n\t Directive: function Directive() {\n\t knownArgNames = _Object$create(null);\n\t },\n\t Argument: function Argument(node) {\n\t var argName = node.name.value;\n\t if (knownArgNames[argName]) {\n\t context.reportError(new _error.GraphQLError(duplicateArgMessage(argName), [knownArgNames[argName], node.name]));\n\t } else {\n\t knownArgNames[argName] = node.name;\n\t }\n\t return false;\n\t }\n\t };\n\t}", "function getArguments() {\n return arguments;\n}", "function func1(str1, str2) {\n console.log(arguments[3]);\n console.log(arguments.length);\n}", "function foo(a) {\n alert(arguments.length);\n}", "function getHookArgumentsLength(fn){if(isUndef(fn)){return false;}var invokerFns=fn.fns;if(isDef(invokerFns)){// invoker\nreturn getHookArgumentsLength(Array.isArray(invokerFns)?invokerFns[0]:invokerFns);}else{return(fn._length||fn.length)>1;}}", "function getHookArgumentsLength(fn){if(isUndef(fn)){return false;}var invokerFns=fn.fns;if(isDef(invokerFns)){// invoker\nreturn getHookArgumentsLength(Array.isArray(invokerFns)?invokerFns[0]:invokerFns);}else{return(fn._length||fn.length)>1;}}", "function UniqueArgumentNames(context) {\n var knownArgNames = _Object$create(null);\n return {\n Field: function Field() {\n knownArgNames = _Object$create(null);\n },\n Directive: function Directive() {\n knownArgNames = _Object$create(null);\n },\n Argument: function Argument(node) {\n var argName = node.name.value;\n if (knownArgNames[argName]) {\n context.reportError(new _error.GraphQLError(duplicateArgMessage(argName), [knownArgNames[argName], node.name]));\n } else {\n knownArgNames[argName] = node.name;\n }\n return false;\n }\n };\n}", "function f() {\n console.log(arguments);\n}", "function parseArgumentDefs(lexer) {\n\t if (!peek(lexer, _lexer.TokenKind.PAREN_L)) {\n\t return [];\n\t }\n\t return many(lexer, _lexer.TokenKind.PAREN_L, parseInputValueDef, _lexer.TokenKind.PAREN_R);\n\t}", "function parseArgumentDefs(lexer) {\n\t if (!peek(lexer, _lexer.TokenKind.PAREN_L)) {\n\t return [];\n\t }\n\t return many(lexer, _lexer.TokenKind.PAREN_L, parseInputValueDef, _lexer.TokenKind.PAREN_R);\n\t}", "function callbackParams(callback) {\n callback();\n}", "getParameters() {\n\t\treturn this.paramDefs.map((param) => param.name);\n\t}", "function UniqueArgumentNames(context) {\n var knownArgNames = Object.create(null);\n return {\n Field: function Field() {\n knownArgNames = Object.create(null);\n },\n Directive: function Directive() {\n knownArgNames = Object.create(null);\n },\n Argument: function Argument(node) {\n var argName = node.name.value;\n if (knownArgNames[argName]) {\n context.reportError(new _error.GraphQLError(duplicateArgMessage(argName), [knownArgNames[argName], node.name]));\n } else {\n knownArgNames[argName] = node.name;\n }\n return false;\n }\n };\n}", "function fun2() {\n console.log(arguments);\n}", "function f_arg (arguments)\n{\n return arguments;\n}", "function test() {\n console.log(arguments);\n}", "function args() {\n return Array.prototype.slice.call(arguments[0]);\n }", "function identifyBehaviorArguments(fnCallStr){\n var argArray, retVal = \"\";\n\n argArray = extractArgs(fnCallStr);\n if (argArray.length == 4) retVal = \"objId,other,other\";\n return retVal;\n}", "function getArguments(...args) {\n return args;\n}", "function get_args(args) {\n return args.map(function (arg) {\n return [arg.TYPE, arg.name];\n });\n }", "function parseArgumentDefs(lexer) {\n if (!peek(lexer, _lexer.TokenKind.PAREN_L)) {\n return [];\n }\n return many(lexer, _lexer.TokenKind.PAREN_L, parseInputValueDef, _lexer.TokenKind.PAREN_R);\n}", "function parseArgumentDefs(lexer) {\n if (!peek(lexer, _lexer.TokenKind.PAREN_L)) {\n return [];\n }\n return many(lexer, _lexer.TokenKind.PAREN_L, parseInputValueDef, _lexer.TokenKind.PAREN_R);\n}", "function parseArgumentDefs(lexer) {\n if (!peek(lexer, _lexer.TokenKind.PAREN_L)) {\n return [];\n }\n return many(lexer, _lexer.TokenKind.PAREN_L, parseInputValueDef, _lexer.TokenKind.PAREN_R);\n}", "function parseArgumentDefs(lexer) {\n if (!peek(lexer, _lexer.TokenKind.PAREN_L)) {\n return [];\n }\n return many(lexer, _lexer.TokenKind.PAREN_L, parseInputValueDef, _lexer.TokenKind.PAREN_R);\n}", "function parseArgumentDefs(lexer) {\n if (!peek(lexer, _lexer.TokenKind.PAREN_L)) {\n return [];\n }\n return many(lexer, _lexer.TokenKind.PAREN_L, parseInputValueDef, _lexer.TokenKind.PAREN_R);\n}", "function parseArgumentDefs(lexer) {\n if (!peek(lexer, _lexer.TokenKind.PAREN_L)) {\n return [];\n }\n return many(lexer, _lexer.TokenKind.PAREN_L, parseInputValueDef, _lexer.TokenKind.PAREN_R);\n}", "function parseArgumentDefs(lexer) {\n if (!peek(lexer, _lexer.TokenKind.PAREN_L)) {\n return [];\n }\n return many(lexer, _lexer.TokenKind.PAREN_L, parseInputValueDef, _lexer.TokenKind.PAREN_R);\n}", "function parseArgumentDefs(lexer) {\n if (!peek(lexer, _lexer.TokenKind.PAREN_L)) {\n return [];\n }\n return many(lexer, _lexer.TokenKind.PAREN_L, parseInputValueDef, _lexer.TokenKind.PAREN_R);\n}", "function parseArgumentDefs(lexer) {\n if (!peek(lexer, _lexer.TokenKind.PAREN_L)) {\n return [];\n }\n return many(lexer, _lexer.TokenKind.PAREN_L, parseInputValueDef, _lexer.TokenKind.PAREN_R);\n}", "function parseArgumentDefs(lexer) {\n if (!peek(lexer, _lexer.TokenKind.PAREN_L)) {\n return [];\n }\n return many(lexer, _lexer.TokenKind.PAREN_L, parseInputValueDef, _lexer.TokenKind.PAREN_R);\n}", "function parseArgumentDefs(lexer) {\n if (!peek(lexer, TokenKind.PAREN_L)) {\n return [];\n }\n\n return many(lexer, TokenKind.PAREN_L, parseInputValueDef, TokenKind.PAREN_R);\n}", "function KnownArgumentNames(context) {\n return {\n Argument: function Argument(node, key, parent, path, ancestors) {\n var argumentOf = ancestors[ancestors.length - 1];\n if (argumentOf.kind === Kind.FIELD) {\n var fieldDef = context.getFieldDef();\n if (fieldDef) {\n var fieldArgDef = (0, _find2.default)(fieldDef.args, function (arg) {\n return arg.name === node.name.value;\n });\n if (!fieldArgDef) {\n var parentType = context.getParentType();\n !parentType ? (0, _invariant2.default)(0) : void 0;\n context.reportError(new _error.GraphQLError(unknownArgMessage(node.name.value, fieldDef.name, parentType.name, (0, _suggestionList2.default)(node.name.value, fieldDef.args.map(function (arg) {\n return arg.name;\n }))), [node]));\n }\n }\n } else if (argumentOf.kind === Kind.DIRECTIVE) {\n var directive = context.getDirective();\n if (directive) {\n var directiveArgDef = (0, _find2.default)(directive.args, function (arg) {\n return arg.name === node.name.value;\n });\n if (!directiveArgDef) {\n context.reportError(new _error.GraphQLError(unknownDirectiveArgMessage(node.name.value, directive.name, (0, _suggestionList2.default)(node.name.value, directive.args.map(function (arg) {\n return arg.name;\n }))), [node]));\n }\n }\n }\n }\n };\n}", "function parseArgumentDefs(lexer) {\n if (!peek(lexer, _lexer.TokenKind.PAREN_L)) {\n return [];\n }\n\n return many(lexer, _lexer.TokenKind.PAREN_L, parseInputValueDef, _lexer.TokenKind.PAREN_R);\n}", "function checkUnamedArguments(){\n\t\tvar arg = arguments; \n\t\tdebugger;\n\t}", "function KnownArgumentNames(context) {\n\t return {\n\t Argument: function Argument(node, key, parent, path, ancestors) {\n\t var argumentOf = ancestors[ancestors.length - 1];\n\t if (argumentOf.kind === _languageKinds.FIELD) {\n\t var fieldDef = context.getFieldDef();\n\t if (fieldDef) {\n\t var fieldArgDef = (0, _jsutilsFind2['default'])(fieldDef.args, function (arg) {\n\t return arg.name === node.name.value;\n\t });\n\t if (!fieldArgDef) {\n\t var parentType = context.getParentType();\n\t (0, _jsutilsInvariant2['default'])(parentType);\n\t context.reportError(new _error.GraphQLError(unknownArgMessage(node.name.value, fieldDef.name, parentType.name), [node]));\n\t }\n\t }\n\t } else if (argumentOf.kind === _languageKinds.DIRECTIVE) {\n\t var directive = context.getDirective();\n\t if (directive) {\n\t var directiveArgDef = (0, _jsutilsFind2['default'])(directive.args, function (arg) {\n\t return arg.name === node.name.value;\n\t });\n\t if (!directiveArgDef) {\n\t context.reportError(new _error.GraphQLError(unknownDirectiveArgMessage(node.name.value, directive.name), [node]));\n\t }\n\t }\n\t }\n\t }\n\t };\n\t}", "function UniqueArgumentNames(context) {\n var knownArgNames = Object.create(null);\n return {\n Field: function Field() {\n knownArgNames = Object.create(null);\n },\n Directive: function Directive() {\n knownArgNames = Object.create(null);\n },\n Argument: function Argument(node) {\n var argName = node.name.value;\n\n if (knownArgNames[argName]) {\n context.reportError(new _error_GraphQLError__WEBPACK_IMPORTED_MODULE_0__[\"GraphQLError\"](duplicateArgMessage(argName), [knownArgNames[argName], node.name]));\n } else {\n knownArgNames[argName] = node.name;\n }\n\n return false;\n }\n };\n}", "_argsWithNames (func: string, args: Array = []): Object {\n let r = null\n for (const i in this._json.abi) {\n if (this._json.abi.hasOwnProperty(i) && this._json.abi[i].name === func) {\n const inputs = this._json.abi[i].inputs\n if (!r) {\n r = {}\n }\n for (const j in inputs) {\n if (inputs.hasOwnProperty(j)) {\n if (!args.hasOwnProperty(j)) {\n throw new Error(`invalid argument ${j}`)\n }\n r[inputs[j].name] = args[j]\n }\n }\n break\n }\n }\n if (!r) {\n throw new Error('argsWithNames should not be null')\n }\n return r\n }", "function KnownArgumentNames(context) {\n return {\n Argument: function Argument(node, key, parent, path, ancestors) {\n var argumentOf = ancestors[ancestors.length - 1];\n if (argumentOf.kind === _languageKinds.FIELD) {\n var fieldDef = context.getFieldDef();\n if (fieldDef) {\n var fieldArgDef = (0, _jsutilsFind2['default'])(fieldDef.args, function (arg) {\n return arg.name === node.name.value;\n });\n if (!fieldArgDef) {\n var parentType = context.getParentType();\n (0, _jsutilsInvariant2['default'])(parentType);\n context.reportError(new _error.GraphQLError(unknownArgMessage(node.name.value, fieldDef.name, parentType.name), [node]));\n }\n }\n } else if (argumentOf.kind === _languageKinds.DIRECTIVE) {\n var directive = context.getDirective();\n if (directive) {\n var directiveArgDef = (0, _jsutilsFind2['default'])(directive.args, function (arg) {\n return arg.name === node.name.value;\n });\n if (!directiveArgDef) {\n context.reportError(new _error.GraphQLError(unknownDirectiveArgMessage(node.name.value, directive.name), [node]));\n }\n }\n }\n }\n };\n}", "function example3() {\n\n function hi() {\n for (var _len = arguments.length, fullName = Array(_len), _key = 0; _key < _len; _key++) {\n fullName[_key] = arguments[_key];\n }\n\n console.log(fullName.join(' '));\n }\n\n hi('vlad', 'argentum');\n}", "function namedParamsKeys() {\n const allNamedParamsKeys = namedParamsWithIndex();\n\n return allNamedParamsKeys.reduce((values, paramKey) => {\n values.push(paramKey.value);\n return values;\n }, []);\n }", "function aa() {\n console.log(arguments)\n let [a, b] = arguments\n console.log(a, b)\n}", "function eventArgs(event) {\n var _a;\n return (_a = event) === null || _a === void 0 ? void 0 : _a.args;\n}", "getARGs() {\n let args = [];\n for (let instruction of this.instructions) {\n if (instruction instanceof arg_1.Arg) {\n args.push(instruction);\n }\n }\n return args;\n }", "function namedParamsKeys() {\n const allNamedParamsKeys = namedParamsWithIndex();\n\n return allNamedParamsKeys.reduce((values, paramKey) => {\n values.push(paramKey.value);\n return values;\n }, []);\n }", "function countarg(a, b) {\n return arguments.length;\n}", "function getEventHandlerNames(tmplData) { // 195\n return _.filter(Object.keys(tmplData), function (opt) { // 196\n return opt.indexOf('_on') === 0 && // Include if '_on...' // 197\n _.isFunction(tmplData[opt]); // and handler is indeed a function // 198\n }); // 199\n}", "function parseArgumentDefs(lexer) {\n if (!peek(lexer, _tokenKind__WEBPACK_IMPORTED_MODULE_4__[\"TokenKind\"].PAREN_L)) {\n return [];\n }\n\n return many(lexer, _tokenKind__WEBPACK_IMPORTED_MODULE_4__[\"TokenKind\"].PAREN_L, parseInputValueDef, _tokenKind__WEBPACK_IMPORTED_MODULE_4__[\"TokenKind\"].PAREN_R);\n}", "function callbackAnimais(event){\n console.log(event.target)\n}", "function getStartArgs(ruleName) {\n var rule = asts.findRule(ast, ruleName);\n var argNames = getRuleArgNames(rule);\n var args = [];\n\n for (let i = 0; i < argNames.length; i++) {\n let argName = argNames[i];\n if (argName === language.silence) {\n args.push('false');\n } else if (argName === language.boolParams) {\n args.push('0');\n } else {\n let paramName = language.paramNameFromArg(argName);\n let type = rule.passedParams[paramName].type;\n if (type === 'integer') {\n args.push('0');\n } else if (type === 'boolean') {\n args.push('false');\n } else if (type === 'string') {\n args.push('\"\"');\n } else if (type === 'reference') {\n args.push(language.newRef('null'));\n } else {\n throw new Error('Unknown param type: ' + type);\n }\n }\n }\n return args;\n }", "function getArg(func) {\n //const arg = map.get(func);\n const arg = Object.values(map).find(value => value.func === func).arg;\n return arg;\n}", "function imprimeArguemntos(){\n console.log(arguments);\n}", "function parseArgumentDefs(lexer$$1) {\n if (!peek(lexer$$1, lexer.TokenKind.PAREN_L)) {\n return [];\n }\n return many(lexer$$1, lexer.TokenKind.PAREN_L, parseInputValueDef, lexer.TokenKind.PAREN_R);\n}", "function getHookArgumentsLength (fn) {\n\t if (isUndef(fn)) {\n\t return false\n\t }\n\t var invokerFns = fn.fns;\n\t if (isDef(invokerFns)) {\n\t // invoker\n\t return getHookArgumentsLength(\n\t Array.isArray(invokerFns)\n\t ? invokerFns[0]\n\t : invokerFns\n\t )\n\t } else {\n\t return (fn._length || fn.length) > 1\n\t }\n\t}", "function getHookArgumentsLength (fn) {\n\t if (isUndef(fn)) {\n\t return false\n\t }\n\t var invokerFns = fn.fns;\n\t if (isDef(invokerFns)) {\n\t // invoker\n\t return getHookArgumentsLength(\n\t Array.isArray(invokerFns)\n\t ? invokerFns[0]\n\t : invokerFns\n\t )\n\t } else {\n\t return (fn._length || fn.length) > 1\n\t }\n\t}", "function parseArgumentDefs(parser) {\n\t if (!peek(parser, _lexer.TokenKind.PAREN_L)) {\n\t return [];\n\t }\n\t return many(parser, _lexer.TokenKind.PAREN_L, parseInputValueDef, _lexer.TokenKind.PAREN_R);\n\t}", "function saludarArgumentos(referencia){\n console.log(arguments);\n}", "function getHookArgumentsLength (fn) {\r\n if (isUndef(fn)) {\r\n return false\r\n }\r\n var invokerFns = fn.fns;\r\n if (isDef(invokerFns)) {\r\n // invoker\r\n return getHookArgumentsLength(\r\n Array.isArray(invokerFns)\r\n ? invokerFns[0]\r\n : invokerFns\r\n )\r\n } else {\r\n return (fn._length || fn.length) > 1\r\n }\r\n}", "function test () {\n return arguments\n}", "function getHookArgumentsLength(fn) {\n\t if (isUndef(fn)) {\n\t return false;\n\t }\n\t var invokerFns = fn.fns;\n\t if (isDef(invokerFns)) {\n\t // invoker\n\t return getHookArgumentsLength(Array.isArray(invokerFns) ? invokerFns[0] : invokerFns);\n\t } else {\n\t return (fn._length || fn.length) > 1;\n\t }\n\t}", "function getHookArgumentsLength(fn) {\n\t if (isUndef(fn)) {\n\t return false;\n\t }\n\t var invokerFns = fn.fns;\n\t if (isDef(invokerFns)) {\n\t // invoker\n\t return getHookArgumentsLength(Array.isArray(invokerFns) ? invokerFns[0] : invokerFns);\n\t } else {\n\t return (fn._length || fn.length) > 1;\n\t }\n\t}", "function getHookArgumentsLength (fn) {\n if (isUndef(fn)) {\n return false\n }\n var invokerFns = fn.fns;\n if (isDef(invokerFns)) {\n // invoker\n return getHookArgumentsLength(\n Array.isArray(invokerFns)\n ? invokerFns[0]\n : invokerFns\n )\n } else {\n return (fn._length || fn.length) > 1\n }\n }", "function getHookArgumentsLength (fn) {\n if (isUndef(fn)) {\n return false\n }\n var invokerFns = fn.fns;\n if (isDef(invokerFns)) {\n // invoker\n return getHookArgumentsLength(\n Array.isArray(invokerFns)\n ? invokerFns[0]\n : invokerFns\n )\n } else {\n return (fn._length || fn.length) > 1\n }\n }", "function getHookArgumentsLength (fn) {\n if (isUndef(fn)) {\n return false\n }\n var invokerFns = fn.fns;\n if (isDef(invokerFns)) {\n // invoker\n return getHookArgumentsLength(\n Array.isArray(invokerFns)\n ? invokerFns[0]\n : invokerFns\n )\n } else {\n return (fn._length || fn.length) > 1\n }\n }", "function getHookArgumentsLength (fn) {\n if (isUndef(fn)) {\n return false\n }\n var invokerFns = fn.fns;\n if (isDef(invokerFns)) {\n // invoker\n return getHookArgumentsLength(\n Array.isArray(invokerFns)\n ? invokerFns[0]\n : invokerFns\n )\n } else {\n return (fn._length || fn.length) > 1\n }\n }", "function parseArgumentDefs(lexer) {\n if (!peek(lexer, _lexer__WEBPACK_IMPORTED_MODULE_3__[\"TokenKind\"].PAREN_L)) {\n return [];\n }\n\n return many(lexer, _lexer__WEBPACK_IMPORTED_MODULE_3__[\"TokenKind\"].PAREN_L, parseInputValueDef, _lexer__WEBPACK_IMPORTED_MODULE_3__[\"TokenKind\"].PAREN_R);\n}", "function parseArgumentDefs(lexer) {\n if (!peek(lexer, _lexer__WEBPACK_IMPORTED_MODULE_4__[\"TokenKind\"].PAREN_L)) {\n return [];\n }\n\n return many(lexer, _lexer__WEBPACK_IMPORTED_MODULE_4__[\"TokenKind\"].PAREN_L, parseInputValueDef, _lexer__WEBPACK_IMPORTED_MODULE_4__[\"TokenKind\"].PAREN_R);\n}" ]
[ "0.75850946", "0.6928508", "0.6827934", "0.6582613", "0.63940877", "0.6366113", "0.6350676", "0.60110426", "0.59533465", "0.58827436", "0.5869651", "0.58469486", "0.58403456", "0.58285767", "0.5812033", "0.57768273", "0.57695436", "0.5761976", "0.5671639", "0.5669627", "0.5653774", "0.56350845", "0.563388", "0.56291133", "0.55998397", "0.55971926", "0.5569691", "0.55590624", "0.55565774", "0.55507284", "0.5484138", "0.54720557", "0.54691595", "0.54528767", "0.5427098", "0.54245585", "0.5392148", "0.5383425", "0.53341043", "0.53341043", "0.5329463", "0.53184426", "0.53062785", "0.53062785", "0.53015983", "0.53010935", "0.5290986", "0.528926", "0.5286433", "0.5277462", "0.5268819", "0.52673215", "0.525911", "0.52435535", "0.521701", "0.521701", "0.521701", "0.521701", "0.521701", "0.521701", "0.521701", "0.521701", "0.521701", "0.521701", "0.5209043", "0.52001274", "0.5192323", "0.5185542", "0.5176561", "0.5163884", "0.5156161", "0.5135736", "0.5129979", "0.510594", "0.5096103", "0.5094332", "0.5093889", "0.5079293", "0.5078956", "0.5074427", "0.5057716", "0.50495565", "0.5048117", "0.50433326", "0.50375986", "0.50263596", "0.5025212", "0.5025212", "0.50178444", "0.5016066", "0.5011178", "0.50111705", "0.50076777", "0.50076777", "0.50060916", "0.50060916", "0.50060916", "0.50060916", "0.49992263", "0.4997731" ]
0.6949597
1
fetch the remote controller and keep track of it so it will not be loaded twice.
function loadController(controllerName, callback){ currentControllerName = controllerName; if(controllers[controllerName]!=undefined) { // console.log("controller already loaded"); callback(); return; } controllers[controllerName] = null; var filePath = defaultRoute.baseUrl + "/controllers/" + controllerName + ".js"; var script = document.createElement("script"); script.type="text/javascript"; script.src = filePath; script.onload = function(){ registerController(controllerName); callback(); } document.head.appendChild(script); // var script = $('<script type="text/javascript" src="'+ filePath // +'"></script>'); // script.get(0).load = callback; // $(document.body).append(script); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async retrieveController() {\n this.contr = await Controller.createController();\n }", "function getController() {\n return controller;\n}", "get controller()\n {\n return this._controller;\n }", "get controller()\n {\n return this._controller;\n }", "function load_controller(url, callback) {\n\t\tvar controller_done, interface_source;\n\t\t\n\t\t// When both the interface_data and the controller are loaded, then combine them and render\n\t\t// the interface.\n\t\tfunction check_done() {\n\t\t\tif (!controller_done || interface_source === undefined) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tcallback(interface_source);\n\t\t}\n\n\t\t// Check to see if we need to load the remote interface or not.\n\t\tif (loaded_urls[url] === undefined) {\n\t\t\tloaded_urls[url] = true;\n\n\t\t\t// Load the controller from the server\n\t\t\t$.ajax({\n\t\t\t\ttype: \"GET\",\n\t\t\t\turl: url,\n\t\t\t\tsuccess: function () {\n\t\t\t\t\tcontroller_done = true;\n\t\t\t\t\tcheck_done();\n\t\t\t\t},\n\t\t\t\tdataType: \"script\",\n\t\t\t\tcache : false\n\t\t\t});\n\n\t\t\t// Load the interface and parse it\n\t\t\t$.ajax({\n\t\t\t\ttype: \"GET\",\n\t\t\t\turl: url.replace(/\\.js$/, '.tci'),\n\t\t\t\tsuccess: function (data) {\n\t\t\t\t\tinterface_source_cache[url] = data;\n\t\t\t\t\tinterface_source = data;\n\t\t\t\t\tcheck_done();\n\t\t\t\t},\n\t\t\t\tdataType: \"text\",\n\t\t\t\tcache: false\n\t\t\t});\n\t\t} else {\n\t\t\tinterface_source = interface_source_cache[url];\n\t\t\tcontroller_done = true;\n\t\t\tcheck_done();\n\t\t}\n\t}", "get controller() {\r\n return this._CONTROLLER;\r\n }", "function getOrCreateController(tag) {\n if (!Api.cache[tag]) {\n Api.cache[tag] = new ProxyController(tag)\n }\n\n return Api.cache[tag]\n}", "addController(controller) {\n var _a2, _b2;\n ((_a2 = this.__controllers) !== null && _a2 !== void 0 ? _a2 : this.__controllers = []).push(controller);\n if (this.renderRoot !== void 0 && this.isConnected) {\n (_b2 = controller.hostConnected) === null || _b2 === void 0 ? void 0 : _b2.call(controller);\n }\n }", "get loadingController() {\n return getOrCreateController('ion-loading-controller')\n }", "async function injectController() {\n await chrome.scripting.executeScript({\n target : {tabId : await getTabId(), allFrames : false},\n files : [ \"src/injection/initializer.js\" ],\n })\n console.log(\"Controller injected!\");\n}", "setupController(controller) {\n this._super(...arguments);\n controller.fetchMembers.perform();\n if (!controller._hasLoadedLabels) {\n this.store.query('label', {limit: 'all'}).then(() => {\n controller._hasLoadedLabels = true;\n });\n }\n }", "function initiateController() {\n window.extensions.KJSLINT.Panels.Command.Controller.init();\n }", "setController(initController) {\n this.controller = initController;\n }", "setController(initController) {\n this.controller = initController;\n }", "function _loadController() {\n // pageService.getPagData(contactPageId).then(\n // _getPageDataSuccessResult, _getPageDataErrorResult);\n pageService.getAllSelect(columnIds).then(_getAllSelectSuccessResult, _getAllSelectErrorResult)\n function _getAllSelectSuccessResult(result) {\n\n $scope.dropDownLists = result;\n\n $scope.entity.Current = param.Current;\n if (param.Current != undefined) {\n if (!param.Current.IsSameAsPermanent) {\n $scope.entity.Permanent = param.Permanent;\n }\n }\n\n }\n function _getAllSelectErrorResult(err) {\n\n }\n }", "init() {\n if(config.disableRemoteControl || this.initialized\n || !APP.conference.isDesktopSharingEnabled) {\n return;\n }\n logger.log(\"Initializing remote control.\");\n this.initialized = true;\n APP.API.init({\n forceEnable: true,\n });\n this.controller.enable(true);\n if(this.enabled) { // supported message came before init.\n this._onRemoteControlSupported();\n }\n }", "function processControllerStateChange() {\n addEvent(\"controllers\", e[\"controller_id\"], point, entities);\n }", "get(url) {\n url = url.trimAll(\"/\");\n // Fast Access Controller (full match)\n let fast_acs_controller = this.router[url];\n if (fast_acs_controller != null)\n return this.app.createComponent(fast_acs_controller, Object.assign({}, this.app.config, {\"request\": {}}));\n\n // Searching for best option:\n var best_controller = null;\n var best_controller_request = {};\n var best_controller_placeholders = 1000;\n for (var routePattern in this.router) {\n if (this.isMatch(url, routePattern)) {\n var phCount = routePattern.match(/<(.+?)>/g).length;\n if (phCount < best_controller_placeholders) {\n best_controller = this.router[routePattern];\n best_controller_request = this.extractParameters(url, routePattern);\n best_controller_placeholders = phCount;\n // Match found with minimum amount of placeholders - no need to keep looking...\n if (phCount == 1) break;\n }\n }\n };\n if (best_controller) {\n return this.app.createComponent(best_controller, Object.assign({}, this.app.config, {\"request\": best_controller_request}));\n }\n throw new Error(\"404 NotFound\")\n }", "loadCurrentRoute() {\n switch (this.currentRoute()) {\n case '/':\n import(/*webpackChunkName: \"home\" */ './IndexController').then(IndexController => {\n IndexController.default.init();\n });\n\n break;\n case '/restaurant':\n import(/*webpackChunkName: \"restaurant\" */ './RestaurantController').then(\n RestaurantController => {\n RestaurantController.default.init();\n }\n );\n\n break;\n }\n }", "function activeController() {\n FoodService.get({ id: $stateParams.foodId }).$promise\n .then(food => {\n vm.food = food;\n })\n .catch(err => {\n vm.message = `Something error: ${err.data}`;\n });\n }", "handleRemotePlayerLoaded(player) {\n console.log(`REMOTE DATA LOADED : ${player.id}`);\n\n // Remove player from initialisingPlayers ...\n game.initialisingPlayers = game.initialisingPlayers.filter(p => p.id !== player.id);\n // ... and add it to remotePlayers\n game.remotePlayers.push(player);\n\n player.action = player.initialAction;\n game.scene.add(player.object);\n }", "get modalController() {\n return getOrCreateDelegatedController('ion-modal-controller')\n }", "function instantiateController() {\n return new PaneController(\n mockScope,\n mockAgentService,\n mockWindow,\n mockLocation,\n mockAttrs\n );\n }", "function getOrCreateDelegatedController(tag) {\n if (!Api.cache[tag]) {\n Api.cache[tag] = new ProxyDelegateController(tag, _Delegate)\n }\n\n return Api.cache[tag]\n}", "function loadRemoteBanners(context, $scope) {\n var $regions = $('[data-emthemesmodez-remote-banner]', $scope);\n\n if ($regions.length > 0) {\n var update = function update(resp) {\n var $resp = $(resp);\n\n if ($resp.length > 0) {\n $regions.each(function (i, region) {\n var $region = $(region);\n var regionName = $(region).data('emthemesmodezRemoteBanner');\n\n if (regionName) {\n $region.after($resp.find(\"[id='\" + regionName + \"'], .\" + regionName).clone());\n }\n });\n }\n\n $regions.remove();\n };\n\n if (remoteBannerCache) {\n update(remoteBannerCache.content);\n } else {\n _bigcommerce_stencil_utils__WEBPACK_IMPORTED_MODULE_0__[\"default\"].api.getPage(context.urls.search + \"?search_query=&section=content\", {\n template: 'papa-supermarket/banners/remote'\n }, function (err, resp) {\n if (err) {\n return;\n }\n\n remoteBannerCache = {\n content: resp\n };\n update(remoteBannerCache.content);\n });\n }\n }\n}", "getDispatcher() {\n return this.remoteDispatcher;\n }", "connectedCallback() {\n var _a2;\n if (this.renderRoot === void 0) {\n this.renderRoot = this.createRenderRoot();\n }\n this.enableUpdating(true);\n (_a2 = this.__controllers) === null || _a2 === void 0 ? void 0 : _a2.forEach((c) => {\n var _a3;\n return (_a3 = c.hostConnected) === null || _a3 === void 0 ? void 0 : _a3.call(c);\n });\n }", "constructor() {\n this.controller = new Controller();\n this._initialized = false;\n }", "function getController() {\n ctrlFactory.get.call(this, '/rest/account/collection');\n var ctrl = this;\n\n ctrl.controllerAction = function() {\n\n // if not allowed to spoof the user request creation, force the user parameter\n\n var spoofed_user = ctrl.req.query.user;\n var forced_params = null;\n\n if (!spoofed_user || !ctrl.req.user.canSpoofUser(spoofed_user)) {\n forced_params = { user: ctrl.req.user._id };\n }\n\n ctrl.jsonService(ctrl.service('account/collection/get', forced_params));\n };\n}", "function getController(room) {\n return room.controller;\n}", "function getCurrentFrontend() {\n return shim_1.getCurrentClient();\n}", "function initializeController() {\n }", "function initializeController() {\n }", "initRemote() {\n let me = this,\n remote = me.remote,\n className = me.className,\n currentWorker = Neo.currentWorker,\n listenerId;\n\n if (!me.singleton) {\n throw new Error('Remote method access is only functional for Singleton classes ' + className);\n }\n\n if (!Neo.config.unitTestMode && Neo.isObject(remote)) {\n if (Neo.workerId !== 'main' && currentWorker.isSharedWorker && !currentWorker.isConnected) {\n listenerId = currentWorker.on('connected', () => {\n currentWorker.un('connected', listenerId);\n Base.sendRemotes(className, remote);\n });\n } else {\n Base.sendRemotes(className, remote);\n }\n }\n }", "initRemote() {\n let me = this,\n remote = me.remote,\n className = me.className,\n currentWorker = Neo.currentWorker,\n listenerId;\n\n if (!me.singleton) {\n throw new Error('Remote method access is only functional for Singleton classes ' + className);\n }\n\n if (!Neo.config.unitTestMode && Neo.isObject(remote)) {\n if (Neo.workerId !== 'main' && currentWorker.isSharedWorker && !currentWorker.isConnected) {\n listenerId = currentWorker.on('connected', () => {\n currentWorker.un('connected', listenerId);\n Base.sendRemotes(className, remote);\n });\n } else {\n Base.sendRemotes(className, remote);\n }\n }\n }", "function initController() {\n }", "setupController(controller , model ){ \n controller.set('webapidata4',model.resultO);\n }", "_initializeControllers()\n {\n this._controllerContextMenu = new ControllerContextMenu();\n this._controllerModal = new ControllerModal();\n this._controllerProject = new ControllerProject();\n this._controllerResource = new ControllerResource();\n this._controllerRunJob = new ControllerRunJob();\n this._controllerWorkflow = new ControllerWorkflow();\n this._controllerWorkflowBuilder = new ControllerWorkflowBuilder();\n this._controllerWorkflowRun = new ControllerWorkflowRun();\n\n }", "function getOrCreateMenuController(tag) {\n if (!Api.cache[tag]) {\n Api.cache[tag] = new ProxyMenuController(tag)\n }\n\n return Api.cache[tag]\n}", "function RepositoryBrowserControllerProxy() {\r\n\r\n // This function is called after the Save dialog has been used\r\n this.remoteSave = function( myFilename, mySolution, myPath, myType, myOverwrite ) {\r\n\t\t//console.log(\"save state:\" + myFilename);\r\n\t\tthis.pluginSave({\r\n \tfullpath :mySolution+myPath+'/'+myFilename,\r\n \t\"filename\":myFilename,\r\n \tsolution :mySolution,\r\n \tpath :myPath,\r\n \ttype :myType,\r\n \toverwrite:myOverwrite\r\n });\r\n } //end remoteSave\r\n}", "function registerController(ctrlCallback) {\n if(view_model.idb == null) {\n _establishIndexedDB(function() {\n view_model.observerCallbacks.push(ctrlCallback);\n if(!view_model.initialSync) return;\n view_model.newSyncThree(function(response) {\n ctrlCallback(response);\n });\n });\n } else {\n view_model.observerCallbacks.push(ctrlCallback);\n if(!view_model.initialSync) return;\n view_model.newSyncThree(function(response) {\n ctrlCallback(response);\n });\n }\n }", "function Controller(){\r\n\t\tvar scope = this;\r\n\t\tvar view = new View({controller: this});\t\t\r\n\t\tvar currentContentController = undefined;\t\r\n\t\tvar pageRootPath = ''; // is set to page's root path (form where it is served)\r\n\t\t\r\n\t\t// new content must register controller here, type: BaseContentController\r\n\t\tvar contentRegister = {\r\n\t\t\t'simulations' : 'contents/simulations/SimulationsContentController',\r\n\t\t\t'complexes': 'contents/complexes/ComplexesContentController'\r\n\t\t};\t\t\r\n\t\t\r\n\t\tfunction init(){\r\n\t\t\tasync.series([\r\n\t\t\t webSocketController.init.bind(null, {}),\r\n\t\t\t utils.asTask(initRouter)\r\n\t\t\t ], function(err){\r\n\t\t\t\terr && handleError(err);\r\n\t\t\t});\t\t\t\t\t\r\n\t\t}\t\t\r\n\t\t\r\n\t\tfunction initRouter(){\r\n\t\t\tvar Router = Backbone.Router.extend({\r\n\t\t\t\t routes: {\r\n\t\t\t\t\t '*path': showContent, // matches all path and splits query-part\t \r\n\t\t\t\t\t }});\r\n\t\t\trouter = new Router();\r\n\t\t\tBackbone.history.start({pushState: true});\r\n\t\t}\r\n\t\t\r\n\t\t/**\r\n\t\t * Based on the given parameters requires for the corresponding controller,\r\n\t\t * initiates and triggers page-transition on pageView.\r\n\t\t * @param path : url-path\r\n\t\t * @param query : query-params, the 'content' is used to extract view, the rest is given the content-controller as argument\r\n\t\t */\r\n\t\tfunction showContent(path, query){\r\n\t\t\tpageRootPath = pageRootPath || path; // first time-set\r\n\t\t\tvar urlState = jQuery.parseQuery(query);\r\n\t\t\turlState.content = urlState.content || 'simulations';\r\n\t\t\tvar controllerUri = contentRegister[urlState.content];\t\t\t\r\n\t\t\tif(!controllerUri){\r\n\t\t\t\tthrow new Error('This content-name is not registered, '+urlState.content);\r\n\t\t\t}\r\n\t\t\trequire([controllerUri], function(Controller){\t\t\r\n\t\t\t\tvar formerContentController = currentContentController;\r\n\t\t\t\tcurrentContentController = new Controller(urlState);\r\n\t\t\t\tcurrentContentController\r\n\t\t\t\t .on(BaseContentController.READY, function(){\r\n\t\t\t\t \tasync.series([view.createHideContentTask(formerContentController),\r\n\t\t\t\t \t view.createShowContentTask(currentContentController)]);\t\t\t\t\t\r\n\t\t\t\t\t })\r\n\t\t\t\t\t.init();\r\n\t\t\t});\r\n\t\t}\t\r\n\t\t\r\n\t\t/**\r\n\t\t * @param navTarget : via name as registered in 'contentRegister'\r\n\t\t */\r\n\t\tthis.handleMenuItemClicked = function(navTarget){\r\n\t\t\trouter.navigate(pageRootPath+'?'+jQuery.param({content:navTarget}), {trigger: true});\r\n\t\t};\r\n\t\t\r\n\t\tinit();\r\n\t}", "RegisterController(controller){\n this.RegisteredControllersObj[controller.ControllerNameStr] = controller;\n this.ControllerNameArr.push(controller.ControllerNameStr);\n controller.SetRegistrationOnController(this.ControllerNameArr, this.Request, this.Resp);\n }", "function loadRemoteData() {\n // The friendService returns a promise.\n siteFetcher.getEvent(\"1\")\n .then(\n function( response ) {\n $scope.event = response;\n }\n );\n }", "function loadRemoteData() {\n // The friendService returns a promise.\n siteFetcher.getEvent(\"1\")\n .then(\n function( response ) {\n $scope.event = response;\n }\n );\n }", "function fetchRemoteNode(path, isDeleted) {\n logger.info(\"fetch remote\", path);\n return remoteAdapter.get(path);\n }", "async fetch() {\r\n const remote = await spawnGit([\"config\", \"--get\", \"remote.origin.url\"]);\r\n if (!remote.length) return this.sendMessage({ type: \"remoteNotConfigured\" });\r\n\r\n await spawnGit([\"fetch\", remote[0]]);\r\n }", "get componentControllerClass(){\n if(this.getComponentController()){\n return this.getComponentController().constructor;\n }else {\n return this._componentControllerClass;\n }\n }", "function controllers() {\n\t\t\treturn {\n\t\t\t\thome: new Controller(\"home\", function(model, view, callback) {\n\t\t\t\t\tcallback(view.render(model));\n\t\t\t\t}),\n\t\t\t\tvehicleList: new Controller(\"vehicleList\", function(model, view, callback) {\n\t\t\t\t\tmodel.vehicles = vehicles;\n\t\t\t\t\tcallback(view.render(model));\n\t\t\t\t}),\n\t\t\t\tvehicleDetail: new Controller(\"vehicleDetail\", function(model, view, callback) {\n\t\t\t\t\t// Obtain the vehicle by filtering with the id\n\t\t\t\t\tvar vehicle = _(vehicles).detect(function(item) {\n\t\t\t\t\t\t// In this case model.params.id is comming from the\n\t\t\t\t\t\t// url used in the querystring\n\t\t\t\t\t\treturn item.id === model.params.id;\n\t\t\t\t\t});\n\t\t\t\t\tmodel.vehicle = vehicle;\n\t\t\t\t\tcallback(view.render(model));\n\t\t\t\t}),\n\t\t\t\tgithubRepos: new Controller(\"githubRepos\", function (model, view, callback) {\n\t\t\t\t\tvar data = {},\n\t\t\t\t\t\treq = $.ajax({\n\t\t\t\t\t\tasync: false,\n\t\t\t\t\t\turl: \"http://github.com/api/v2/json/repos/show/masyl\",\n\t\t\t\t\t\tdataType: \"jsonp\",\n\t\t\t\t\t\tsuccess: function(data) {\n\t\t\t\t\t\t\tmodel.repositories = data.repositories;\n\t\t\t\t\t\t\tcallback(view.render(model));\n\t\t\t\t\t\t}\n\t\t\t\t\t})\n\t\t\t\t})\n\t\t\t};\n\t\t}", "function loadRemoteData() {\n\n\t\t// The comment service returns a promise.\n\t\tUserservice.getEditedComments().then(function(EditedComments) {\n\n\t\t\tapplyRemoteData(EditedComments);\n\n\t\t});\n\n\t}", "function controller_by_user(){\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\t\r\n\t\t} catch(e){\r\n\t\t\tconsole.log(\"%cerror: %cPage: `hsn_code` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\r\n\t\t\tconsole.dir(e);\r\n\t\t}\r\n\t}", "init (controller) {\n this.controller = controller\n this.originalRunTreeFunction = controller.runTree\n\n if (this.storeMutations) {\n this.initialModelString = JSON.stringify(controller.model.get())\n }\n\n window.addEventListener('cerebral2.debugger.changeModel', (event) => {\n controller.model.set(event.detail.path, event.detail.value)\n controller.flush()\n })\n window.addEventListener('cerebral2.debugger.remember', (event) => {\n if (!this.storeMutations) {\n console.warn('Cerebral Devtools - You tried to time travel, but you have turned of storing of mutations')\n }\n this.remember(event.detail)\n })\n window.addEventListener('cerebral2.debugger.reset', (event) => {\n this.reset()\n })\n // When debugger responds a client ping\n window.addEventListener('cerebral2.debugger.pong', this.sendInitial)\n // When debugger pings the client\n window.addEventListener('cerebral2.debugger.ping', this.sendInitial)\n\n const event = new window.CustomEvent('cerebral2.client.message', {\n detail: JSON.stringify({type: 'ping'})\n })\n window.dispatchEvent(event)\n\n this.watchExecution()\n }", "function controller_by_user(){\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\t\r\n\t\t} catch(e){\r\n\t\t\tconsole.log(\"%cerror: %cPage: `index` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\r\n\t\t\tconsole.dir(e);\r\n\t\t}\r\n\t}", "function controller_by_user(){\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\t\r\n\t\t} catch(e){\r\n\t\t\tconsole.log(\"%cerror: %cPage: `index` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\r\n\t\t\tconsole.dir(e);\r\n\t\t}\r\n\t}", "function initController() {\r\n loadProjects();\r\n }", "remote(state){\n return API.get(Urls.hrMe());\n }", "_findRemoteSideOn(model, ifUnloaded=false) {\n // Determine the class of the remote side.\n // XXX: Ugly child-class awareness.\n const HostClass = this instanceof OneSideRelationProxy ?\n ManySideRelationProxy : OneSideRelationProxy;\n\n // Resolve the remote side.\n const remoteSide = HostClass.findOnModel(\n model, this.host.constructor, this.sourceAttribute\n );\n // Ensure we found a remote relation proxy in an appropriate load\n // state.\n if (!remoteSide || (!remoteSide.loaded && !ifUnloaded)) return null;\n\n return remoteSide;\n }", "function Simulator_UpdateController(bReachedEnd)\n{\n\t//Controller\n\tif (__CONTROLLER)\n\t{\n\t\t//Before updating ask the interpreter if we have loading iframes\n\t\tif (__WAIT_MANAGER.IsWaiting())\n\t\t{\n\t\t\t//come back when the wait is over\n\t\t\t__EVENTS_QUEUE.AddEvent(\"__SIMULATOR.UpdateController(\" + bReachedEnd + \");\", 0);\n\t\t}\n\t\telse\n\t\t{\n\t\t\t//get current state\n\t\t\tvar wi4State = this.StateManager.CurrentState;\n\t\t\t//disabled\n\t\t\tvar disabled = __CONTROLLER.States.Disabled;\n\t\t\t//visible\n\t\t\tvar visible = __CONTROLLER.States.Visible;\n\t\t\t//hidden\n\t\t\tvar hidden = __CONTROLLER.States.Hidden;\n\t\t\t//create a state\n\t\t\tvar newState = __CONTROLLER.createState();\n\t\t\t// Update basic info\n\t\t\tnewState.SimId = wi4State.SimId;\n\t\t\tnewState.SimStateUID = wi4State.SimStateId;\n\t\t\tnewState.TutId = wi4State.TutId;\n\t\t\tnewState.ListOfBlocks = wi4State.ListOfBlocks && wi4State.ListOfBlocks.length > 0 ? wi4State.ListOfBlocks : null;\n\t\t\t//update the progress bar data\n\t\t\tnewState.ProgressBarCurrent = this.History.CurrentStateIndex - 1; //minus one, zero based controller\n\t\t\tnewState.ProgressBarMax = this.History.MaxStateIndex - 1; //minus one, zero based controller\n\t\t\t//update the caption\n\t\t\tnewState.TaskBarCaptions = this.Interpreter.GetTopLevelCaptions(true);\n\t\t\t//set focused id\n\t\t\tnewState.TaskBarFocusedId = Form_GetFocusedForm().InterpreterObject.DataObject.Id;\n\t\t\t//get keyboard commands\n\t\t\tnewState.KeyboardShortCuts = wi4State.aKeyboardShortcuts;\n\t\t\t//activate mouse button only in tablet mode\n\t\t\tnewState.MouseButton = __BROWSER_IS_TOUCH_ENABLED ? visible : hidden;\n\t\t\t//activate keyboard button only in tablet mode with keyboard shortcuts\n\t\t\tnewState.KeyboardButton = __BROWSER_IS_TOUCH_ENABLED && newState.KeyboardShortCuts.length > 0 ? visible : hidden;\n\n\t\t\t//parameters\n\t\t\tvar parameters = wi4State.ControlSettings;\n\t\t\t//show message button only if we have a message\n\t\t\tnewState.MessageButton = wi4State.DisplayMessageIds.length > 0 ? visible : disabled;\n\t\t\t//hints is per parameters\n\t\t\tnewState.HintsButton = Get_Bool(parameters[__NEMESIS_ParamName_HintsButtonShow], false) ? bReachedEnd || !Get_Bool(parameters[__NEMESIS_ParamName_HintsButtonEnabled], true) ? disabled : visible : hidden;\n\t\t\t//so is camera\n\t\t\tnewState.CameraButton = Get_Bool(parameters[__NEMESIS_ParamName_PlaybackButtonShow], false) ? bReachedEnd || !Get_Bool(parameters[__NEMESIS_ParamName_PlaybackButtonEnabled], true) ? disabled : visible : hidden;\n\t\t\t//and the play pause button\n\t\t\tnewState.CameraPauseButton = Get_Bool(parameters[__NEMESIS_ParamName_CameraPlayPauseButtonShow], false) ? bReachedEnd || !Get_Bool(parameters[__NEMESIS_ParamName_CameraPlayPauseButtonEnabled], true) ? disabled : visible : hidden;\n\t\t\t//statement is visible if we want it but disabled if there isnt a statement\n\t\t\tnewState.StatementButton = Get_Bool(parameters[__NEMESIS_ParamName_StatementButtonShow], false) ? wi4State.StatementMessageId && Get_Bool(parameters[__NEMESIS_ParamName_StatementButtonEnabled], true) ? visible : disabled : hidden;\n\n\t\t\t// Used only for simulation tutorial\n\t\t\tif (newState.NavigationMode)\n\t\t\t{\n\t\t\t\t//navigation modes enum\n\t\t\t\tvar NavigationModes = __CONTROLLER.NavigationModes;\n\n\t\t\t\t// Force free navigation ?\n\t\t\t\tif (this._forceFreeNavigation)\n\t\t\t\t{\n\t\t\t\t\t//set the navigation mode\n\t\t\t\t\tnewState.NavigationMode = NavigationModes.FreeNavigation;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t//reached the end ?\n\t\t\t\t\tif (bReachedEnd)\n\t\t\t\t\t{\n\t\t\t\t\t\t//allow navigation on end ?\n\t\t\t\t\t\tnewState.NavigationMode = Get_Bool(parameters[__NEMESIS_ParamName_AllowNavigationOnEnd], false) ? NavigationModes.FreeNavigation : NavigationModes.NoNavigation;\n\t\t\t\t\t\t//if we are allowing the free navigation\n\t\t\t\t\t\tif (newState.NavigationMode == NavigationModes.FreeNavigation)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t// Force free navigation on all screens from now on\n\t\t\t\t\t\t\tthis._forceFreeNavigation = true;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t//get current navigation mode\n\t\t\t\t\t\tvar navigationModeString = Get_String(parameters[__NEMESIS_ParamName_NavigationMode], \"\");\n\n\t\t\t\t\t\t//get the enum value from the string\n\t\t\t\t\t\tnewState.NavigationMode = (function ()\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfor (var mode in NavigationModes)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (mode.toLowerCase() == navigationModeString.toLowerCase())\n\t\t\t\t\t\t\t\t\treturn NavigationModes[mode];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\treturn newState.NavigationMode;\n\t\t\t\t\t\t})();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t//always memorise the current navigation type\n\t\t\t\tthis._NavigationModeFreeNavigation = newState.NavigationMode == NavigationModes.FreeNavigation;\n\n\t\t\t\t//back/forward buttons shown ?\n\t\t\t\tif (Get_Bool(parameters[__NEMESIS_ParamName_ShowBackNextButtons], true))\n\t\t\t\t{\n\t\t\t\t\tif (newState.NavigationMode == NavigationModes.NoNavigation)\n\t\t\t\t\t{\n\t\t\t\t\t\tnewState.PreviousButton = newState.NextButton = disabled;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t//set to visible if we can go back, disabled otherwise\n\t\t\t\t\t\tnewState.PreviousButton = this.History.CurrentStateIndex > 1 ? visible : disabled;\n\n\t\t\t\t\t\tvar testMaxState = newState.NavigationMode == NavigationModes.FreeNavigation ? this.History.MaxStateIndex : this.History.States.length;\n\t\t\t\t\t\t//set to visible if we can go forward, disabled otherwise\n\t\t\t\t\t\tnewState.NextButton = this.History.CurrentStateIndex < testMaxState ? visible : disabled;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tnewState.PreviousButton = newState.NextButton = hidden;\n\t\t\t\t}\n\n\t\t\t\t//show slider\n\t\t\t\tnewState.ShowSlider = Get_Bool(parameters[__NEMESIS_ParamName_ShowSlider], true);\n\t\t\t}\n\n\t\t\t// Movie mode\n\t\t\tnewState.IsMovieMode = Get_Bool(parameters[__NEMESIS_ParamName_LessonAutoPlayCamera], false);\n\n\t\t\t//Check if we are blockng user interaction\n\t\t\tnewState.BlockControl = Get_Bool(parameters[__NEMESIS_ParamName_LessonBlockControl], false) || newState.IsMovieMode;\n\t\t\t//get trigger data\n\t\t\tnewState.TriggersData = wi4State.TriggersData;\n\t\t\t//and the information button\n\t\t\tnewState.InformationButton = Get_Bool(parameters[__NEMESIS_ParamName_InformationButtonShow], false) ? visible : hidden;\n\t\t\t//and whether we are in sandbox or not\n\t\t\tnewState.IsSandboxBehavior = Get_Bool(parameters[__NEMESIS_ParamName_SandboxBehavior], false);\n\n\t\t\t//loop through our messages\n\t\t\tfor (var i = 0, messages = wi4State.DisplayMessageIds, c = messages.length; i < c; i++)\n\t\t\t{\n\t\t\t\t//get the message\n\t\t\t\tvar wi4Msg = wi4State.GetMessage(messages[i]);\n\t\t\t\t//this a basic message?\n\t\t\t\tif (wi4Msg.Type == __NEMESIS_MessageType_Basic)\n\t\t\t\t{\n\t\t\t\t\t//reached the end?//is the basic message not customised? generated?\n\t\t\t\t\tif (bReachedEnd && !wi4Msg.Amended)\n\t\t\t\t\t{\n\t\t\t\t\t\t//try to get the end of lesson message\n\t\t\t\t\t\tvar endOfLessonMsg = wi4State.EndOfLessonMessageId ? wi4State.GetMessage(wi4State.EndOfLessonMessageId) : null;\n\t\t\t\t\t\t//valid?\n\t\t\t\t\t\tif (endOfLessonMsg)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t//replace default message with the end of lesson message\n\t\t\t\t\t\t\twi4Msg = endOfLessonMsg;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t//non basic message in screenshots or qa?\n\t\t\t\telse if (__SCREENSHOTS_ON || __QA_ON)\n\t\t\t\t{\n\t\t\t\t\t//ignore this one in screenshots\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t//create a message\n\t\t\t\tvar newMessage = Tut_ConvertMsgToControllerMsg(wi4Msg, __CONTROLLER, parameters, true);\n\t\t\t\t//if we reached the end? basic message?\n\t\t\t\tif (bReachedEnd && (wi4Msg.Type == __NEMESIS_MessageType_Basic || wi4Msg.Type == __NEMESIS_MessageType_Unknown))\n\t\t\t\t{\n\t\t\t\t\t//forcebly remove all timers\n\t\t\t\t\tnewMessage.TimeToDisplay = 0;\n\t\t\t\t}\n\t\t\t\t//add to array\n\t\t\t\tnewState.ScreenMessages.push(newMessage);\n\t\t\t}\n\t\t\t//has statement message?\n\t\t\tif (wi4State.StatementMessageId)\n\t\t\t{\n\t\t\t\t//create a message\n\t\t\t\tvar newStatementMessage = Tut_ConvertMsgToControllerMsg(wi4State.GetMessage(wi4State.StatementMessageId), __CONTROLLER, parameters, false);\n\t\t\t\t//valid\n\t\t\t\tif (newStatementMessage)\n\t\t\t\t{\n\t\t\t\t\t//force type\n\t\t\t\t\tnewStatementMessage.Type = __CONTROLLER.MessageTypes.Statement;\n\t\t\t\t\t//add to state\n\t\t\t\t\tnewState.StatementMessage = newStatementMessage;\n\t\t\t\t\t//remember this in vars\n\t\t\t\t\t__VARS_MANAGER.Statement = newStatementMessage.HTMLText;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t//update our tutorial data (only scores for now)\n\t\t\tthis.Scores.TriggerHints = Get_Number(parameters[__NEMESIS_ParamName_LessonTriggerHintsAfter], 2);\n\t\t\tthis.Scores.TriggerCamera = Get_Number(parameters[__NEMESIS_ParamName_LessonTriggerPlaybackAfter], 3);\n\n\t\t\t//update controller\n\t\t\t__CONTROLLER.setState(newState);\n\t\t}\n\t}\n}", "setupController() {\n // eslint-disable-next-line ember/no-controller-access-in-routes\n this.controllerFor('application').set('isEmberApplication', true);\n this.port.one('general:reset', this, this.reset);\n }", "function retrieveTasksServer() {\n $.ajax(\"task\", {\n \"type\": \"get\",\n\t\t\tdataType: \"json\"\n }).done(displayTasksServer.bind()); // need reference to the tasksController object\n }", "initBrowseView() {\n\n let microServiceEndpoints = [\n // 0) JSON Static, we used it for defining the data interface of a generic record for updating\n \"jsonprototypes/address-book-record-prototype.json\",\n\n // 1) JSON Static, we used it for defining the data interface of a new record for adding\n \"jsonprototypes/address-book-new-record-prototype.json\",\n\n // 2) A PHP implementation of JSON service\n \"services/address-book-record-get.php?activity=\",\n\n // 3) A Java JSP implementation of JSON service\n \"http://\" + JAVA_TOMCAT_HOST + \"/Esame/1_showActivities.jsp\"\n ];\n\n let selectedMicroServiceEndpoint = microServiceEndpoints[3];\n\n let controller = this;\n\n /* Call the microservice and evaluate data and result status */\n $.getJSON(selectedMicroServiceEndpoint, function (data) {\n controller.renderGUI(data);\n }).done(function () {\n controller.showMessageStatus(\"green\", \"All done\");\n }).fail(function () {\n controller.showMessageStatus(\"red\", \"Error while requesting service: \" + controller.serviceEndPoint);\n });\n\n this.showMessageStatus(\"black\", \"Requesting data from service: \" + this.serviceEndPoint);\n }", "function onLoad(){\n getRequest(\"/display-current\", displayData);\n}", "function controller_by_user(){\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\t\r\n\t\t} catch(e){\r\n\t\t\tconsole.log(\"%cerror: %cPage: `sp2hp` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\r\n\t\t\tconsole.dir(e);\r\n\t\t}\r\n\t}", "function controller_by_user(){\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\t\r\n\t\t} catch(e){\r\n\t\t\tconsole.log(\"%cerror: %cPage: `ptdh` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\r\n\t\t\tconsole.dir(e);\r\n\t\t}\r\n\t}", "function Controller(){} //Extends Class (at bottom of page).", "function controller_by_user(){\n\t\ttry {\n\t\t\t\n\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `index` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "function controller_by_user(){\n\t\ttry {\n\t\t\t\n\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `index` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "get instanceID() {\n return this.controller.model.instanceID\n }", "fetch () {\n return PS.get();\n }", "function getControllers(renderer,onSelectStart,onSelectEnd) {\n const controllerOne = renderer.xr.getController(0);\n \n controllerOne.addEventListener('connected',function(event){\n this.add(buildController(event.data))\n });\n\n controllerOne.addEventListener('disconnected',function() {\n this.remove(this.children[0]);\n });\n\n controllerOne.addEventListener('selectstart',onSelectStart);\n\n controllerOne.addEventListener('selectend',onSelectEnd);\n\n return controllerOne;\n\n}", "function load(controllerName, query) {\n\t\trequire(['js/' + controllerName + 'Controller'], function(controller) {\n\t\t\tcontroller.init(query);\n\t\t});\n\t\t//history.pushState(null, null, document.URL);\n\t\t/*history.pushState(null, null, \"#\");\n\t\twindow.addEventListener(\"popstate\",function(e) { \n\t\t //history.pushState(null, null, document.URL);\n\t\t\thistory.pushState(null, null, \"#\");\n\t\t}, false);*/\n\t}", "function REMOTE_CONTROL_HTML$static_(){RemoteControlHandlerRegistryImpl.REMOTE_CONTROL_HTML=( net.jangaroo.net.URIUtils.parse(\"remoteControl.html\"));}", "function loadRemoteData() {\n\n\t\t// The comment service returns a promise.\n\t\tUserservice.getComments().then(function(Comments) {\n\n\t\t\tapplyRemoteData(Comments);\n\n\t\t});\n\n\t}", "function calculationController(localAvailable, remoteAvailable) {\n if ( typeof calculationController.instance === 'object' ){\n\t return calculationController.instance;\n };\n\n // TODO: Don't hard-code these\n this.methods = [\n {\n name: 'remoteDefault',\n displayName: 'Remote Default',\n help: 'Remote Default Method',\n repos: 'remote'\n },\n {\n name: 'localDefault',\n displayName: 'Local Default',\n help: 'Local Default Method',\n repos: 'KStest'\n },\n {\n name: 'localWilcoxon',\n displayName: 'Local Wilcoxon',\n help: 'Local Wilcoxon Method',\n repos: 'wilcoxon',\n },\n /*{\n name: 'localTtest',\n displayName: 'Local Ttest',\n help: 'Local T-test Method',\n repos: 't_test',\n }*/\n ];\n\n this.localWorker;\n calculationController.instance = this;\n return this;\n}", "function detectControllers() {\n var initialRun = true\n\n if (navigator.getVRDisplays && navigator.getGamepads) {\n console.log('WebVR API and Gamepad API supported.')\n reportDisplays()\n } else {\n console.log('WebVR API and/or Gamepad API not supported by this browser.')\n }\n\n function reportDisplays() {\n navigator.getVRDisplays().then(function(displays) {\n console.log(displays.length + ' displays')\n for (var i = 0; i < displays.length; i++) {\n console.log('displays[i].displayName', displays[i].displayName)\n }\n\n setTimeout(reportGamepads, 1000)\n // For VR, controllers will only be active after their corresponding headset is active\n })\n }\n\n function reportGamepads() {\n var gamepads = navigator.getGamepads()\n console.log(gamepads.length + ' controllers')\n for (var i = 0; i < gamepads.length; ++i) {\n var gp = gamepads[i]\n if (gp) {\n console.log('gp.id', gp.id)\n updateControllerHelpText(gp.id)\n }\n }\n initialRun = false\n }\n\n function updateControllerHelpText(id) {\n const grabButton = {\n left: 'Grip',\n right: 'Grip',\n }\n const teleportButton = {\n left: '',\n right: '',\n }\n switch (id) {\n // Vive Wand Controllers\n case 'OpenVR Gamepad':\n teleportButton.left = 'Trackpad'\n teleportButton.right = 'Trackpad'\n break\n // This doesn't seem to be working\n case 'Oculus Touch (Left)':\n teleportButton.left = 'X'\n break\n // This doesn't seem to be working\n case 'Oculus Touch (Right)':\n teleportButton.right = 'A'\n break\n // will use the Oculus Touch controllers\n // as the default case for now\n default:\n teleportButton.left = 'X'\n teleportButton.right = 'A'\n }\n\n const helpText = {\n left: `\\n${grabButton.left}: Grab object\\n${teleportButton.left}: Teleport`,\n right: `\\n${grabButton.right}: Grab object\\n${teleportButton.right}: Teleport`,\n }\n\n d3.select('#ctlLText').remove()\n d3.select('#ctlL')\n .append('a-text')\n .attr('value', helpText.left)\n .attr('id', 'ctlRtext')\n .attr('position', '0 0.05 0')\n .attr('rotation', '-90 0 0')\n .attr('scale', '0.1 0.1 0.1')\n .attr('align', 'center')\n .attr('color', '#FFFFFF')\n\n d3.select('#ctlRText').remove()\n d3.select('#ctlR')\n .append('a-text')\n .attr('value', helpText.right)\n .attr('id', 'ctlRtext')\n .attr('position', '0 0.05 0')\n .attr('rotation', '-90 0 0')\n .attr('scale', '0.1 0.1 0.1')\n .attr('align', 'center')\n .attr('color', '#FFFFFF')\n }\n}", "function retrieveTasksServer() {\n\t\tshowLoader();\n\t\t$.ajax(\"TaskServlet\", {\n\t\t\t\"type\": \"get\",\n\t\t\tdataType: \"json\"\n\t\t}).done(displayTasksServer.bind()) //need reference to the tasksController object\n\t\t\t.fail(function () {\n\t\t\t\thideLoader();\n\t\t\t})\n\t}", "_setup() {\n this._controller.setup();\n }", "function loadRemoteData() {\n\n\t\t// The comment service returns a promise.\n\t\tUserservice.getCorrelationData().then(function(correlationData) {\n\n\t\t\tapplyRemoteData(correlationData);\n\n\t\t});\n\n\t}", "function getController() {\n var gamepads = navigator.getGamepads && navigator.getGamepads();\n if(gamepads.length) {\n var gamepad = gamepads[0];\n return gamepad;\n }\n return false;\n}", "function controller_by_user(){\n\t\ttry {\n\t\t\t\n\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `lotes` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "_evaluateControllers() {\n this._page === 1\n ? this._prevController.classList.add('controller--hidden')\n : this._prevController.classList.remove('controller--hidden');\n\n this.isLastPage\n ? this._nextController.classList.add('controller--hidden')\n : this._nextController.classList.remove('controller--hidden');\n }", "initControllers() {\n\t\tnew BlockController(this.app);\n\t}", "function latestController(req, res) {\n var result = retrieveHistoryPromise();\n result.then(function(terms) {\n res.json(terms);\n });\n}", "async getRemote() {\r\n const remote = await spawnGit([\"config\", \"--get\", \"remote.origin.url\"]);\r\n\r\n if (!remote.length) this.sendMessage({ type: \"remoteNotConfigured\" });\r\n\r\n this.sendMessage({ type: \"remote\", remote: remote[0] });\r\n }", "function controller_by_user(){\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\t\r\n\t\t} catch(e){\r\n\t\t\tconsole.log(\"%cerror: %cPage: `opsi` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\r\n\t\t\tconsole.dir(e);\r\n\t\t}\r\n\t}", "fetch () {\n this._makeRequest('GET', resources);\n }", "removeController(controller) {\n var _a2;\n (_a2 = this.__controllers) === null || _a2 === void 0 ? void 0 : _a2.splice(this.__controllers.indexOf(controller) >>> 0, 1);\n }", "function controller_by_user(){\n\t\ttry {\n\t\t\t\n\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `publicar` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "function controller_by_user(){\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\t\r\n\t\t} catch(e){\r\n\t\t\tconsole.log(\"%cerror: %cPage: `bookmark` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\r\n\t\t\tconsole.dir(e);\r\n\t\t}\r\n\t}", "function generateController(owner, controllerName) {\n generateControllerFactory(owner, controllerName);\n\n var fullName = 'controller:' + controllerName;\n var instance = owner.lookup(fullName);\n\n if (true) {\n if ((0, _emberMetal.get)(instance, 'namespace.LOG_ACTIVE_GENERATION')) {\n (0, _emberDebug.info)('generated -> ' + fullName, { fullName: fullName });\n }\n }\n\n return instance;\n }", "function generateController(owner, controllerName) {\n generateControllerFactory(owner, controllerName);\n\n var fullName = 'controller:' + controllerName;\n var instance = owner.lookup(fullName);\n\n if (true) {\n if ((0, _emberMetal.get)(instance, 'namespace.LOG_ACTIVE_GENERATION')) {\n (0, _emberDebug.info)('generated -> ' + fullName, { fullName: fullName });\n }\n }\n\n return instance;\n }", "function generateController(owner, controllerName) {\n generateControllerFactory(owner, controllerName);\n\n var fullName = 'controller:' + controllerName;\n var instance = owner.lookup(fullName);\n\n if (true) {\n if ((0, _emberMetal.get)(instance, 'namespace.LOG_ACTIVE_GENERATION')) {\n (0, _emberDebug.info)('generated -> ' + fullName, { fullName: fullName });\n }\n }\n\n return instance;\n }", "static getInstance(controller) {\n\t\tif (!this._instance) this._instance = new ActionsWinEdit({ controller: controller });\n\t\tthis._instance.controller = controller;\n\t\treturn this._instance;\n\t}", "function controller_by_user(){\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\t\r\n\t\t} catch(e){\r\n\t\t\tconsole.log(\"%cerror: %cPage: `utama` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\r\n\t\t\tconsole.dir(e);\r\n\t\t}\r\n\t}", "function loadTracker() {\n // setup tracker\n ctracker = new clm.tracker();\n ctracker.init(pModel);\n ctracker.start(videoInput.elt);\n}", "setupController(controller, model) {\n this._super(controller, model);\n controller.set('document', this.modelFor('documents.show'));\n }", "function showRemote() {\n $(\"#remote\").centerInClient();\n $(\"#remote\").css(\"display\", \"block\");\n documentReady();\n}", "function ctrl() {\r\n\t// Subscribe to routeChanging which is published by user\r\n\t// when accessing a new route (after app init)\r\n\tpubSub.subscribe('routeChanging', () => {\r\n\t\t// Show loader and start animation\r\n\t\tloader.start();\r\n\t});\r\n\r\n\t// Subscribe to routeChanged which is published whenever\r\n\t// template of target route has been rendered\r\n\tpubSub.subscribe('routeChanged', () => {\r\n\t\t// Stop animation and hide loader\r\n\t\tloader.stop();\r\n\t});\r\n}", "function controller_by_user(){\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\t\r\n\t\t} catch(e){\r\n\t\t\tconsole.log(\"%cerror: %cPage: `sac_code` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\r\n\t\t\tconsole.dir(e);\r\n\t\t}\r\n\t}", "function initilizeController(){\n }" ]
[ "0.6947303", "0.64765906", "0.622677", "0.622677", "0.6164597", "0.6033011", "0.570248", "0.56610477", "0.56163496", "0.54773855", "0.5402852", "0.5303666", "0.5218258", "0.5218258", "0.5175834", "0.5172983", "0.5159715", "0.51589084", "0.5098989", "0.5034112", "0.5019513", "0.50188553", "0.5006338", "0.50062495", "0.5001513", "0.499171", "0.49886146", "0.49800584", "0.49787328", "0.49762043", "0.4970092", "0.4936777", "0.4936777", "0.49347973", "0.49347973", "0.49283895", "0.49269825", "0.49260768", "0.49233848", "0.49219844", "0.48688328", "0.48609537", "0.48469424", "0.48432094", "0.48432094", "0.48380098", "0.4801652", "0.4799711", "0.47957182", "0.47878176", "0.47862378", "0.47743624", "0.4773614", "0.4773614", "0.47718224", "0.4766334", "0.4761902", "0.47580883", "0.47572902", "0.4753211", "0.47437778", "0.47425997", "0.47410384", "0.4738374", "0.47357652", "0.47306237", "0.47306237", "0.47286478", "0.47250193", "0.4711103", "0.47097114", "0.46998528", "0.4696677", "0.46963292", "0.4694667", "0.46801087", "0.4679404", "0.46744952", "0.467423", "0.46738145", "0.46673644", "0.4660713", "0.46606138", "0.46504548", "0.4649903", "0.46312538", "0.46302843", "0.4627374", "0.46259636", "0.4623376", "0.4623376", "0.4623376", "0.4613561", "0.46095717", "0.46080858", "0.46014184", "0.46007973", "0.46000314", "0.45965785", "0.45963702" ]
0.50508654
19
when controller script loaded, $.jf.ctrl will be set some value; this function will read the value, set to the controllers, then reset the temporary $.jf.ctrl;
function registerController(name){ controllers[name] = $.jf.ctrl.actions; $.jf.ctrl = { filters: [], actionFilters: {}, actions:{} } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function refreshGui() {\n gui.__controllers.forEach(controller => controller.setValue(controller.initialValue));\n }", "setController(initController) {\n this.controller = initController;\n }", "setController(initController) {\n this.controller = initController;\n }", "function initilizeController(){\n }", "function initiateController() {\n window.extensions.KJSLINT.Panels.Command.Controller.init();\n }", "function initController() {\n }", "'refresh_internal'() {\n // When values are set in the constructor, using fields, do they get set using data values, like they would otherwise?\n\n var key = this.key;\n var value = this.value;\n // May be better to have a String control for the key.\n // That way it will be easier to make it editable (using the control overrides).\n var content = this.content;\n var key_content = ctrl_key.span;\n //this.set('ctrl_string_key', ctrl_string_key);\n //var key_content = ctrl_key.content.get(1);\n if (key) {\n //console.log('key ' + key);\n //var key_value = key.value();\n //console.log('key_value ' + key_value);\n key_content.add(key);\n var vcon = ctrl_value.content;\n //vcon.set(1, 'hello');\n vcon.clear();\n var ctrl_viewer = this.factory(value, this.context);\n //console.log('ctrl_viewer', ctrl_viewer);\n //console.log('tof ctrl_viewer', tof(ctrl_viewer));\n\n vcon.push(ctrl_viewer);\n }\n }", "function resetCtrl() {\n if (_animationController) {\n _animationController.remove();\n _animationController = undefined;\n _animationControllerResize = undefined;\n }\n }", "function resetCtrl() {\n if (_animationController) {\n _animationController.remove();\n _animationController = undefined;\n _animationControllerResize = undefined;\n }\n }", "function coreInitDynamicLoading() {\n\n //Load a user control\n $.pageController.loadUserControl = function (page, ctrl, ctrlId, userControlName) {\n\n //Set controlId and control\n ctrl.attr(\"controlId\", ctrlId);\n ctrl.attr(\"control\", page.controlName + \".\" + userControlName);\n\n //Create the user control and add to page\n page.controls[ctrlId] = ctrl[userControlName]();\n\n //Return the control\n return $(ctrl)[userControlName]();\n }\n\n\n //Unload a user control that is loaded\n $.pageController.unLoadUserControl = function (page, userControlId) {\n\n //Verify userControl Id exists\n if (typeof page.controls[userControlId] !== \"undefined\") {\n\n //Find its unique Id\n var sel = page.controls[userControlId].selectedObject;\n var str = [];\n while ($(sel)[0].tagName != \"BODY\") {\n var parentControlName = $(sel).attr(\"control\").split(\".\")[0];\n\n var parentControl = $(sel).closest(\"[control$='.\" + parentControlName + \"']\");\n str.push($(parentControl).attr(\"controlId\"));\n sel = parentControl;\n }\n var uniqueId = str.reverse().join(\"_\") + \"_\" + page.controls[userControlId].selectedObject.attr(\"controlId\");\n\n //Delete userControls and all child controls of it\n for (var prop in WEBUI.UICONTROLS) {\n if (prop.startsWith(uniqueId))\n delete WEBUI.UICONTROLS[prop];\n }\n\n //Clear html,control and controlId\n $(page.controls[userControlId].selectedObject).html(\"\");\n $(page.controls[userControlId].selectedObject).removeAttr(\"controlId\");\n $(page.controls[userControlId].selectedObject).removeAttr(\"control\");\n\n //Delete the reference in parent control\n delete page.controls[userControlId];\n\n\n }\n\n }\n }", "init_pre() {\n prop.airport = airport;\n\n this.airlineController = new AirlineController();\n this.aircraftController = new AircraftController();\n\n window.airlineController = this.airlineController;\n window.aircraftController = this.aircraftController;\n }", "function initializeController() {\n }", "function initializeController() {\n }", "function settingController($scope, $state, $window, commonApi, constants, localize) {\n // Init data when initialize welcome screen\n function initialize() {\n }\n\n //initialize welcome screen\n initialize();\n }", "function InitController()\n {\n trc.schema.controller._init();\n }", "function init () {\n ctrl.selectedIndex = ctrl.selectedIndex || 0;\n compileTemplate();\n configureWatchers();\n bindEvents();\n $mdTheming($element);\n $mdUtil.nextTick(function () {\n updateHeightFromContent();\n adjustOffset();\n updateInkBarStyles();\n ctrl.tabs[ ctrl.selectedIndex ] && ctrl.tabs[ ctrl.selectedIndex ].scope.select();\n loaded = true;\n updatePagination();\n });\n }", "function init () {\n ctrl.selectedIndex = ctrl.selectedIndex || 0;\n compileTemplate();\n configureWatchers();\n bindEvents();\n $mdTheming($element);\n $mdUtil.nextTick(function () {\n updateHeightFromContent();\n adjustOffset();\n updateInkBarStyles();\n ctrl.tabs[ ctrl.selectedIndex ] && ctrl.tabs[ ctrl.selectedIndex ].scope.select();\n loaded = true;\n updatePagination();\n });\n }", "setupController(controller , model ){ \n controller.set('webapidata4',model.resultO);\n }", "function setupTabsController () {\n ctrl.selectedIndex = ctrl.selectedIndex || 0;\n compileTemplate();\n configureWatchers();\n bindEvents();\n $mdTheming($element);\n $mdUtil.nextTick(function () {\n updateHeightFromContent();\n adjustOffset();\n updateInkBarStyles();\n ctrl.tabs[ ctrl.selectedIndex ] && ctrl.tabs[ ctrl.selectedIndex ].scope.select();\n loaded = true;\n updatePagination();\n });\n }", "_initializeControllers()\n {\n this._controllerContextMenu = new ControllerContextMenu();\n this._controllerModal = new ControllerModal();\n this._controllerProject = new ControllerProject();\n this._controllerResource = new ControllerResource();\n this._controllerRunJob = new ControllerRunJob();\n this._controllerWorkflow = new ControllerWorkflow();\n this._controllerWorkflowBuilder = new ControllerWorkflowBuilder();\n this._controllerWorkflowRun = new ControllerWorkflowRun();\n\n }", "_setup() {\n this._controller.setup();\n }", "resetController (controller /*, isExiting, transition */) {\n this.setProperties({\n isOrgAdmin: false,\n hasOpenDataAdmin: false,\n isAuthenticated: false,\n isInDCProdOrg: false\n });\n controller.set('model', null);\n }", "function initModal(){\n setModalControllerData('languages', $scope.languages);\n setModalControllerData('services', $scope.services);\n setModalControllerData('softwares', $scope.softwares);\n setModalControllerData('engineeringCategories', $scope.engineeringCategories);\n }", "function init(vew) {\n\n // the view this controller is controlling\n view = vew;\n\n // put the view in an initial state\n view.init();\n }", "constructor() {\n this.controller = new Controller();\n this._initialized = false;\n }", "function initModal(){\n setModalControllerData('languages', $scope.languages);\n setModalControllerData('services', $scope.services);\n setModalControllerData('softwares', $scope.softwares);\n }", "after_init_control(){\n\n if(!this.properties.visible)\n this.hide();\n\n if(!this.properties.enabled)\n this.disable();\n\n if(this.properties.style)\n this.jquery().attr('style', this.properties.style);\n\n if(this.properties.field_style)\n this.jquery_place().attr('style', this.properties.field_style);\n\n if(this.properties.css)\n this.set_css(this.properties.css);\n\n if(this.properties.field_css)\n this.set_field_css(this.properties.field_css);\n\n if(this.properties.help)\n this.init_help();\n }", "resetController(controller, isExiting) {\n if (isExiting) {\n // isExiting would be false if only the route's model was changing\n controller.set('geo_group', null);\n controller.set('geo_value', null);\n controller.set('geo_level', null);\n controller.set('target_id', null);\n }\n }", "function Simulator_UpdateController(bReachedEnd)\n{\n\t//Controller\n\tif (__CONTROLLER)\n\t{\n\t\t//Before updating ask the interpreter if we have loading iframes\n\t\tif (__WAIT_MANAGER.IsWaiting())\n\t\t{\n\t\t\t//come back when the wait is over\n\t\t\t__EVENTS_QUEUE.AddEvent(\"__SIMULATOR.UpdateController(\" + bReachedEnd + \");\", 0);\n\t\t}\n\t\telse\n\t\t{\n\t\t\t//get current state\n\t\t\tvar wi4State = this.StateManager.CurrentState;\n\t\t\t//disabled\n\t\t\tvar disabled = __CONTROLLER.States.Disabled;\n\t\t\t//visible\n\t\t\tvar visible = __CONTROLLER.States.Visible;\n\t\t\t//hidden\n\t\t\tvar hidden = __CONTROLLER.States.Hidden;\n\t\t\t//create a state\n\t\t\tvar newState = __CONTROLLER.createState();\n\t\t\t// Update basic info\n\t\t\tnewState.SimId = wi4State.SimId;\n\t\t\tnewState.SimStateUID = wi4State.SimStateId;\n\t\t\tnewState.TutId = wi4State.TutId;\n\t\t\tnewState.ListOfBlocks = wi4State.ListOfBlocks && wi4State.ListOfBlocks.length > 0 ? wi4State.ListOfBlocks : null;\n\t\t\t//update the progress bar data\n\t\t\tnewState.ProgressBarCurrent = this.History.CurrentStateIndex - 1; //minus one, zero based controller\n\t\t\tnewState.ProgressBarMax = this.History.MaxStateIndex - 1; //minus one, zero based controller\n\t\t\t//update the caption\n\t\t\tnewState.TaskBarCaptions = this.Interpreter.GetTopLevelCaptions(true);\n\t\t\t//set focused id\n\t\t\tnewState.TaskBarFocusedId = Form_GetFocusedForm().InterpreterObject.DataObject.Id;\n\t\t\t//get keyboard commands\n\t\t\tnewState.KeyboardShortCuts = wi4State.aKeyboardShortcuts;\n\t\t\t//activate mouse button only in tablet mode\n\t\t\tnewState.MouseButton = __BROWSER_IS_TOUCH_ENABLED ? visible : hidden;\n\t\t\t//activate keyboard button only in tablet mode with keyboard shortcuts\n\t\t\tnewState.KeyboardButton = __BROWSER_IS_TOUCH_ENABLED && newState.KeyboardShortCuts.length > 0 ? visible : hidden;\n\n\t\t\t//parameters\n\t\t\tvar parameters = wi4State.ControlSettings;\n\t\t\t//show message button only if we have a message\n\t\t\tnewState.MessageButton = wi4State.DisplayMessageIds.length > 0 ? visible : disabled;\n\t\t\t//hints is per parameters\n\t\t\tnewState.HintsButton = Get_Bool(parameters[__NEMESIS_ParamName_HintsButtonShow], false) ? bReachedEnd || !Get_Bool(parameters[__NEMESIS_ParamName_HintsButtonEnabled], true) ? disabled : visible : hidden;\n\t\t\t//so is camera\n\t\t\tnewState.CameraButton = Get_Bool(parameters[__NEMESIS_ParamName_PlaybackButtonShow], false) ? bReachedEnd || !Get_Bool(parameters[__NEMESIS_ParamName_PlaybackButtonEnabled], true) ? disabled : visible : hidden;\n\t\t\t//and the play pause button\n\t\t\tnewState.CameraPauseButton = Get_Bool(parameters[__NEMESIS_ParamName_CameraPlayPauseButtonShow], false) ? bReachedEnd || !Get_Bool(parameters[__NEMESIS_ParamName_CameraPlayPauseButtonEnabled], true) ? disabled : visible : hidden;\n\t\t\t//statement is visible if we want it but disabled if there isnt a statement\n\t\t\tnewState.StatementButton = Get_Bool(parameters[__NEMESIS_ParamName_StatementButtonShow], false) ? wi4State.StatementMessageId && Get_Bool(parameters[__NEMESIS_ParamName_StatementButtonEnabled], true) ? visible : disabled : hidden;\n\n\t\t\t// Used only for simulation tutorial\n\t\t\tif (newState.NavigationMode)\n\t\t\t{\n\t\t\t\t//navigation modes enum\n\t\t\t\tvar NavigationModes = __CONTROLLER.NavigationModes;\n\n\t\t\t\t// Force free navigation ?\n\t\t\t\tif (this._forceFreeNavigation)\n\t\t\t\t{\n\t\t\t\t\t//set the navigation mode\n\t\t\t\t\tnewState.NavigationMode = NavigationModes.FreeNavigation;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t//reached the end ?\n\t\t\t\t\tif (bReachedEnd)\n\t\t\t\t\t{\n\t\t\t\t\t\t//allow navigation on end ?\n\t\t\t\t\t\tnewState.NavigationMode = Get_Bool(parameters[__NEMESIS_ParamName_AllowNavigationOnEnd], false) ? NavigationModes.FreeNavigation : NavigationModes.NoNavigation;\n\t\t\t\t\t\t//if we are allowing the free navigation\n\t\t\t\t\t\tif (newState.NavigationMode == NavigationModes.FreeNavigation)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t// Force free navigation on all screens from now on\n\t\t\t\t\t\t\tthis._forceFreeNavigation = true;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t//get current navigation mode\n\t\t\t\t\t\tvar navigationModeString = Get_String(parameters[__NEMESIS_ParamName_NavigationMode], \"\");\n\n\t\t\t\t\t\t//get the enum value from the string\n\t\t\t\t\t\tnewState.NavigationMode = (function ()\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfor (var mode in NavigationModes)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (mode.toLowerCase() == navigationModeString.toLowerCase())\n\t\t\t\t\t\t\t\t\treturn NavigationModes[mode];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\treturn newState.NavigationMode;\n\t\t\t\t\t\t})();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t//always memorise the current navigation type\n\t\t\t\tthis._NavigationModeFreeNavigation = newState.NavigationMode == NavigationModes.FreeNavigation;\n\n\t\t\t\t//back/forward buttons shown ?\n\t\t\t\tif (Get_Bool(parameters[__NEMESIS_ParamName_ShowBackNextButtons], true))\n\t\t\t\t{\n\t\t\t\t\tif (newState.NavigationMode == NavigationModes.NoNavigation)\n\t\t\t\t\t{\n\t\t\t\t\t\tnewState.PreviousButton = newState.NextButton = disabled;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t//set to visible if we can go back, disabled otherwise\n\t\t\t\t\t\tnewState.PreviousButton = this.History.CurrentStateIndex > 1 ? visible : disabled;\n\n\t\t\t\t\t\tvar testMaxState = newState.NavigationMode == NavigationModes.FreeNavigation ? this.History.MaxStateIndex : this.History.States.length;\n\t\t\t\t\t\t//set to visible if we can go forward, disabled otherwise\n\t\t\t\t\t\tnewState.NextButton = this.History.CurrentStateIndex < testMaxState ? visible : disabled;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tnewState.PreviousButton = newState.NextButton = hidden;\n\t\t\t\t}\n\n\t\t\t\t//show slider\n\t\t\t\tnewState.ShowSlider = Get_Bool(parameters[__NEMESIS_ParamName_ShowSlider], true);\n\t\t\t}\n\n\t\t\t// Movie mode\n\t\t\tnewState.IsMovieMode = Get_Bool(parameters[__NEMESIS_ParamName_LessonAutoPlayCamera], false);\n\n\t\t\t//Check if we are blockng user interaction\n\t\t\tnewState.BlockControl = Get_Bool(parameters[__NEMESIS_ParamName_LessonBlockControl], false) || newState.IsMovieMode;\n\t\t\t//get trigger data\n\t\t\tnewState.TriggersData = wi4State.TriggersData;\n\t\t\t//and the information button\n\t\t\tnewState.InformationButton = Get_Bool(parameters[__NEMESIS_ParamName_InformationButtonShow], false) ? visible : hidden;\n\t\t\t//and whether we are in sandbox or not\n\t\t\tnewState.IsSandboxBehavior = Get_Bool(parameters[__NEMESIS_ParamName_SandboxBehavior], false);\n\n\t\t\t//loop through our messages\n\t\t\tfor (var i = 0, messages = wi4State.DisplayMessageIds, c = messages.length; i < c; i++)\n\t\t\t{\n\t\t\t\t//get the message\n\t\t\t\tvar wi4Msg = wi4State.GetMessage(messages[i]);\n\t\t\t\t//this a basic message?\n\t\t\t\tif (wi4Msg.Type == __NEMESIS_MessageType_Basic)\n\t\t\t\t{\n\t\t\t\t\t//reached the end?//is the basic message not customised? generated?\n\t\t\t\t\tif (bReachedEnd && !wi4Msg.Amended)\n\t\t\t\t\t{\n\t\t\t\t\t\t//try to get the end of lesson message\n\t\t\t\t\t\tvar endOfLessonMsg = wi4State.EndOfLessonMessageId ? wi4State.GetMessage(wi4State.EndOfLessonMessageId) : null;\n\t\t\t\t\t\t//valid?\n\t\t\t\t\t\tif (endOfLessonMsg)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t//replace default message with the end of lesson message\n\t\t\t\t\t\t\twi4Msg = endOfLessonMsg;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t//non basic message in screenshots or qa?\n\t\t\t\telse if (__SCREENSHOTS_ON || __QA_ON)\n\t\t\t\t{\n\t\t\t\t\t//ignore this one in screenshots\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t//create a message\n\t\t\t\tvar newMessage = Tut_ConvertMsgToControllerMsg(wi4Msg, __CONTROLLER, parameters, true);\n\t\t\t\t//if we reached the end? basic message?\n\t\t\t\tif (bReachedEnd && (wi4Msg.Type == __NEMESIS_MessageType_Basic || wi4Msg.Type == __NEMESIS_MessageType_Unknown))\n\t\t\t\t{\n\t\t\t\t\t//forcebly remove all timers\n\t\t\t\t\tnewMessage.TimeToDisplay = 0;\n\t\t\t\t}\n\t\t\t\t//add to array\n\t\t\t\tnewState.ScreenMessages.push(newMessage);\n\t\t\t}\n\t\t\t//has statement message?\n\t\t\tif (wi4State.StatementMessageId)\n\t\t\t{\n\t\t\t\t//create a message\n\t\t\t\tvar newStatementMessage = Tut_ConvertMsgToControllerMsg(wi4State.GetMessage(wi4State.StatementMessageId), __CONTROLLER, parameters, false);\n\t\t\t\t//valid\n\t\t\t\tif (newStatementMessage)\n\t\t\t\t{\n\t\t\t\t\t//force type\n\t\t\t\t\tnewStatementMessage.Type = __CONTROLLER.MessageTypes.Statement;\n\t\t\t\t\t//add to state\n\t\t\t\t\tnewState.StatementMessage = newStatementMessage;\n\t\t\t\t\t//remember this in vars\n\t\t\t\t\t__VARS_MANAGER.Statement = newStatementMessage.HTMLText;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t//update our tutorial data (only scores for now)\n\t\t\tthis.Scores.TriggerHints = Get_Number(parameters[__NEMESIS_ParamName_LessonTriggerHintsAfter], 2);\n\t\t\tthis.Scores.TriggerCamera = Get_Number(parameters[__NEMESIS_ParamName_LessonTriggerPlaybackAfter], 3);\n\n\t\t\t//update controller\n\t\t\t__CONTROLLER.setState(newState);\n\t\t}\n\t}\n}", "function init () {\n ctrl.selectedIndex = ctrl.selectedIndex || 0;\n compileTemplate();\n configureWatchers();\n bindEvents();\n $mdTheming($element);\n $mdUtil.nextTick(function () {\n // Note that the element references need to be updated, because certain \"browsers\"\n // (IE/Edge) lose them and start throwing \"Invalid calling object\" errors, when we\n // compile the element contents down in `compileElement`.\n elements = getElements();\n updateHeightFromContent();\n adjustOffset();\n updateInkBarStyles();\n ctrl.tabs[ ctrl.selectedIndex ] && ctrl.tabs[ ctrl.selectedIndex ].scope.select();\n loaded = true;\n updatePagination();\n });\n }", "loadValueProposition() {\n $(jqId(VALUE_PROPOSITION_PANEL)).load(\"valueproposition/instance.html\");\n }", "function initController(){\n var home=document.querySelector(\".home\");\n controller=Controller(home);\n controller.init();\n controller.setOnButtonClickedListener(onButtonClicked);\n }", "function $onInit() {\n // Angular will try to bind any 'bindings' properties after its instantiate the controller.\n // Therefore, I seal the controller after its ready / $onInit.\n\n Object.seal(ctrl);\n }", "function init() {\r\n // Set up the items that are needed for the controller to run\r\n }", "function initialize(value){\n ngModelCtrl.$setViewValue(value);\n scope.getView = getView();\n unregister();\n }", "function initialize(value){\n ngModelCtrl.$setViewValue(value);\n scope.getView = getView();\n unregister();\n }", "function ControllerChange(idx : int ){\n\tchrAnimator.runtimeAnimatorController = chrAnimatorController[idx];\n\tPlayClip(\"Appear\");\n}", "function initController() {\r\n loadProjects();\r\n }", "setupController(controller , model ){ \n controller.set('webapidataf2',model.resultA); \n }", "function init(){ // función que se llama así misma para indicar que sea lo primero que se ejecute\n carreraCtrl.carreras = carreraService.getCarreras();\n }", "restart(){\n this.initialize_values();\n }", "function setDefaultControlState() {\n defCtrlState = {};\n defCtrlState.hashFunct = 0;\n defCtrlState.collision = 0;\n defCtrlState.tableSize = 0;\n defCtrlState.keyrange = 0;\n defCtrlState.m = '';\n\n // Update the default control state based on the query parameters\n var params = JSAV.utils.getQueryParameter();\n\n // Set hash function\n if (params.hashFunct) {\n if (params.hashFunct > 0 && params.hashFunct <= 5) {\n defCtrlState.hashFunct = params.hashFunct;\n\n // Disable so user can't change the value set by parameter\n $('#function').attr('disabled', 'disabled');\n } else {\n console.error(\"Invalid URL parameter method: \" + params.hashFunct);\n }\n }\n\n // Set collision resolution policy\n if (params.collision) {\n if (params.collision > 0 && params.collision <= 7) {\n defCtrlState.collision = params.collision;\n\n // Disable so user can't change the value set by parameter\n $('#collision').attr('disabled', 'disabled');\n } else {\n console.error(\"Invalid URL parameter collision: \" + params.collision);\n }\n }\n\n // Set table size\n if (params.tableSize) {\n if (params.tableSize > 0 && params.tableSize <= 16) {\n defCtrlState.tableSize = params.tableSize;\n\n // Disable so user can't change the value set by parameter\n $('#tablesize').attr('disabled', 'disabled');\n } else {\n console.error(\"Invalid URL parameter tableSize: \" + params.tableSize);\n }\n }\n\n // Set keyrange\n if (params.keyrange) {\n if (params.keyrange > 0 && params.keyrange <= 2) {\n defCtrlState.keyrange = params.keyrange;\n\n // Disable so user can't change the value set by parameter\n $('#keyrange').attr('disabled', 'disabled');\n } else {\n console.error(\"Invalid URL parameter keyrange: \" + params.keyrange);\n }\n }\n\n // Set M-value\n if (params.m) {\n if (params.m > 0) {\n defCtrlState.m = params.m;\n\n // Disable so user can't change the value set by parameter\n $('#M').attr('disabled', 'disabled');\n } else {\n console.error(\"Invalid URL parameter m: \" + params.m);\n }\n }\n }", "function InitValues_Framework_L2(){\n if(ggbApplet.exists(\"btnResetAll\") != true) {\n ggbApplet.evalCommand('btnResetAll = Button(\"Reset All\")');\n }\n if(ggbApplet.exists(\"btnResetStatus\") != true) {\n ggbApplet.evalCommand('btnResetStatus = Button(\"Reset Status\")');\n }\n if(ggbApplet.exists(\"checkSettings\") != true) {\n ggbApplet.evalCommand('checkSettings = Checkbox(\"Settings\")');\n }\n if(ggbApplet.exists(\"checkHints\") != true) {\n ggbApplet.evalCommand('checkHints = Checkbox(\"Hints\")');\n }\n ggbApplet.setFixed(\"btnResetAll\" , false, true);\n ggbApplet.setFixed(\"btnResetStatus\", false, true);\n ggbApplet.setFixed(\"checkSettings\" , false, true);\n ggbApplet.setFixed(\"checkHints\" , false, true);\n ggbApplet.setCoords(\"btnResetAll\" , 15, 15);\n ggbApplet.setCoords(\"btnResetStatus\", 15, 15+DEFAULT_OFFSET_Y);\n ggbApplet.setCoords(\"checkSettings\" , 15, 15+DEFAULT_OFFSET_Y*2);\n ggbApplet.setCoords(\"checkHints\" , 15, 15+DEFAULT_OFFSET_Y*3);\n ggbApplet.setFixed(\"btnResetAll\" , true, true);\n ggbApplet.setFixed(\"btnResetStatus\", true, true);\n ggbApplet.setFixed(\"checkSettings\" , true, true);\n ggbApplet.setFixed(\"checkHints\" , true, true);\n \n ggbApplet.evalCommand(\"checkSettings = true\");\n ggbApplet.evalCommand(\"checkHints = true\");\n}", "function InitValues_Framework_L2(){\n if(ggbApplet.exists(\"btnResetAll\") != true) {\n ggbApplet.evalCommand('btnResetAll = Button(\"Reset All\")');\n }\n if(ggbApplet.exists(\"btnResetStatus\") != true) {\n ggbApplet.evalCommand('btnResetStatus = Button(\"Reset Status\")');\n }\n if(ggbApplet.exists(\"checkSettings\") != true) {\n ggbApplet.evalCommand('checkSettings = Checkbox(\"Settings\")');\n }\n if(ggbApplet.exists(\"checkHints\") != true) {\n ggbApplet.evalCommand('checkHints = Checkbox(\"Hints\")');\n }\n ggbApplet.setFixed(\"btnResetAll\" , false, true);\n ggbApplet.setFixed(\"btnResetStatus\", false, true);\n ggbApplet.setFixed(\"checkSettings\" , false, true);\n ggbApplet.setFixed(\"checkHints\" , false, true);\n ggbApplet.setCoords(\"btnResetAll\" , 15, 15);\n ggbApplet.setCoords(\"btnResetStatus\", 15, 15+DEFAULT_OFFSET_Y);\n ggbApplet.setCoords(\"checkSettings\" , 15, 15+DEFAULT_OFFSET_Y*2);\n ggbApplet.setCoords(\"checkHints\" , 15, 15+DEFAULT_OFFSET_Y*3);\n ggbApplet.setFixed(\"btnResetAll\" , true, true);\n ggbApplet.setFixed(\"btnResetStatus\", true, true);\n ggbApplet.setFixed(\"checkSettings\" , true, true);\n ggbApplet.setFixed(\"checkHints\" , true, true);\n \n ggbApplet.evalCommand(\"checkSettings = true\");\n ggbApplet.evalCommand(\"checkHints = true\");\n}", "function _init() {\n vm.loading = true;\n vm.success = false;\n vm.errmsg = null;\n _loadHome();\n }", "function initController(){\n loadCountries();\n }", "function refreshIndex(){ctrl.selectedIndex=getNearestSafeIndex(ctrl.selectedIndex);ctrl.focusIndex=getNearestSafeIndex(ctrl.focusIndex);}", "function usePlayerControl(curr) {\n var funcname = dojo.attr(curr, config.attrs.ctrl_func);\n var resetToDefault = dojo.attr(curr, config.attrs.ctrl_reset_to_default);\n eval(\"playermenu.\" + funcname + \"(curr)\");\n console.log(resetToDefault);\n if (eval(resetToDefault))\n {\n selectFirstChoiceInMenu(dojo.byId(config.IDs.player.ctrl_div));\n //selectDefaultPlayerControl();\n }\n}", "function getController() {\n return controller;\n}", "function loadLocalStorage() {\n currReplacement = localStorage['currReplacement'];\n excludeWord.value = localStorage['excText'];\n percentReplSlider.value = localStorage['percentReplacement'];\n //Convert strings to boolean\n chkPronouns.checked = ( localStorage['excludePronouns'] == 'true');\n chkHyphens.checked = ( localStorage['excludeHyphenated'] == 'true' );\n chkConjunctions.checked = ( localStorage['excludeConjunctions'] == 'true' );\n chkNoRepeat.checked = ( localStorage['chkNoRepeat'] == 'true' );\n chkMultiWord.checked = ( localStorage['chkMultiWord'] == 'true');\n text_area.value = localStorage['mainText'];\n text_area.value = '123';\n let controllerElement = document.querySelector('section');\n let controllerScope = angular.element(controllerElement).scope();\n //controllerScope.inputText.text = text_area.value;\n controllerScope.$apply();\n}", "loadValueProposition() {\n $(jqId(VALUE_PROPOSITION_PANEL)).load(\"valueproposition/dynamic_routing_gateway.html\");\n }", "restart_values() {\n this.initialize_values();\n this.model.restart();\n this.view.restart();\n this.client.restart();\n this.deselectCurrentPiece();\n this.view.marker.indicatorFlag = true;\n this.scene.reset = false;\n }", "function initController(){\n\n vm.writeReply= false;\n\n vm.workData ={};\n vm.workData = ProfileCourseService.GetWorkData();\n vm.userData = ProfileCourseService.GetProfileData();\n\n console.log(vm.workData);\n\n getComments();\n processComments();\n\n }", "async function init() {\n // re use value from last time it was set\n let { value } = browser.local.storage.get('value');\n // if first time then value is set to 0\n if (!value) {\n value = 0;\n }\n input.value = value;\n // once we get it from storage now adjust value\n setValue(value);\n}", "resetController(controller, isExiting, transition) {\n // Check if the user is leaving the page\n if (isExiting) {\n // Reset the page\n controller.set('page', 1);\n\n // Reset the search\n controller.set('search', undefined);\n\n // Reset the sort\n controller.set('sort', undefined);\n\n // Reset aggregations\n this.set('selectedAggs', {});\n this.set('currentAggregation', null);\n }\n }", "function setInitalClimateVariable() {\n $('.climate-variables :selected').val('rh_wt');\n $(\"select\").material_select(); \n }", "startObserving() {\r\n this.counter = 0;\r\n document.getElementById(\"log-panel\").value = \"\";\r\n document.getElementById(\"text\").value = \"Reload!\" + \"\\n\";\r\n document.getElementById(\"help-panel\").value = \"Initializing...\";\r\n }", "init() {\n this.reset();\n this.load();\n }", "function init() {\n\t\t\tctrl.competencematrixAll = [];\n\t\t\tctrl.competencematrix = {};\n\t\t\tctrl.idSelected = null;\n\t\t\tcompetencematrixConnectorFactory.getCompetenceMatrixAll().then(setCompetenceMatrixAll, null);\n\t\t}", "setAsReady() {\n this.logger.debug('Page is ready to use');\n this.controller.store();\n }", "function initController(){\n\n vm.userData = ProfileCourseService.GetProfileData();\n\n console.log(vm.userData);\n\n\n if (vm.userData.TipoRepositorioArchivos == \"0\"){\n\n vm.userData.TipoRepositorioArchivos = \"Google Drive\"\n }\n if (vm.userData.TipoRepositorioArchivos == \"1\"){\n\n vm.userData.TipoRepositorioArchivos = \"Dropbox\"\n }\n\n vm.courseAverageWidth = {'width': vm.userData.PromedioCursos+'%'}; \n vm.projectAverageWidth = {'width': vm.userData.PromedioProyectos+'%'}; \n\n vm.photo = \"data:image/jpg;base64,\" + $localStorage.Foto;\n\n vm.toggleEnable;\n if (vm.userData.Active == \"0\"){\n vm.toggleEnable = false;\n }\n if(vm.userData.Active == \"1\"){\n vm.toggleEnable = true;\n }\n loadStats();\n }", "function invenioDynamicSelectController($scope, $controller) {\n $controller('dynamicSelectController', {$scope: $scope});\n // If it is ui-select inside an array...\n if ($scope.modelArray) {\n $scope.$watchCollection('modelArray', function(newValue) {\n // If this is not the initial setting of the element...\n if (!angular.equals($scope.select_model, {})) {\n // Get the element's correct value from the array model\n var value = $scope.modelArray[$scope.arrayIndex][$scope.form.key.slice(-1)[0]];\n // Set ui-select's model to the correct value if needed\n if ($scope.insideModel !== value) {\n $scope.insideModel = value;\n var query = $scope.$eval(\n $scope.form.options.processQuery || 'query',\n { query: value }\n );\n $scope.populateTitleMap($scope.form, query);\n $scope.select_model.selected = $scope.find_in_titleMap(value);\n }\n }\n });\n }\n}", "function InitValues_Framework_L1(){\n // You must make textarea, slidbar and more.\n}", "function InitValues_Framework_L1(){\n // You must make textarea, slidbar and more.\n}", "function init(){ctrl.selectedIndex=ctrl.selectedIndex||0;compileTemplate();configureWatchers();bindEvents();$mdTheming($element);$mdUtil.nextTick(function(){// Note that the element references need to be updated, because certain \"browsers\"\n\t// (IE/Edge) lose them and start throwing \"Invalid calling object\" errors, when we\n\t// compile the element contents down in `compileElement`.\n\telements=getElements();updateHeightFromContent();adjustOffset();updateInkBarStyles();ctrl.tabs[ctrl.selectedIndex]&&ctrl.tabs[ctrl.selectedIndex].scope.select();loaded=true;updatePagination();});}", "function _init() {\r\n // set page <title>\r\n Metadata.set(home.title);\r\n\r\n // activate controller\r\n _activate();\r\n }", "function parentController2()\n {\n var vm = this;\n vm.value = 1;\n }", "function start () {\n gmCtrl.setObj();\n uiCtrl.setUi();\n }", "setFaustInterfaceControles() {\n // //this.moduleView.fTitle.textContent = this.moduleFaust.fName;\n // var moduleFaustInterface = new FaustInterfaceControler(\n // (faustInterface) => { this.interfaceSliderCallback(faustInterface) },\n // (adress, value) => { this.setParamValue(adress, value) }\n // );\n // //let ui_json = JSON.parse(this.moduleFaust.fDSP.getJSON())\n // //this.moduleControles = moduleFaustInterface.parseFaustJsonUI(ui_json).ui, this);\n }", "function InitObjectProperty_Framework_L2(){\n ggbApplet.setCoordSystem(DEFAULT_VIEW1_WIDTH_MIN,\n DEFAULT_VIEW1_WIDTH_MAX,\n DEFAULT_VIEW1_HEIGHT_MIN, \n DEFAULT_VIEW1_HEIGHT_MAX);\n \n ggbApplet.setVisible(\"btnResetAll\" , true);\n ggbApplet.setVisible(\"btnResetStatus\", true);\n ggbApplet.setVisible(\"checkSettings\" , true);\n ggbApplet.setVisible(\"checkHints\" , true);\n}", "function InitObjectProperty_Framework_L2(){\n ggbApplet.setCoordSystem(DEFAULT_VIEW1_WIDTH_MIN,\n DEFAULT_VIEW1_WIDTH_MAX,\n DEFAULT_VIEW1_HEIGHT_MIN, \n DEFAULT_VIEW1_HEIGHT_MAX);\n \n ggbApplet.setVisible(\"btnResetAll\" , true);\n ggbApplet.setVisible(\"btnResetStatus\", true);\n ggbApplet.setVisible(\"checkSettings\" , true);\n ggbApplet.setVisible(\"checkHints\" , true);\n}", "function init() {\n\t\"use strict\";\n\tconsole.log(\"init() called\");\n\n\tDemoScriptsController.checkDemoScripts();\n\n\t$('#bottomPanel').bottomPanel('init');\n\t$(\"#topBarIcons\").topBarIconsPlugin('init');\n\n\t$('#properties').library(\"init\");\n\t$('#properties').library('setAlphabetVisible', false);\n\n\t$(\"#libraryButton\").click(function() {\n\t\tPropertiesController.initializeLibrary();\n\t});\n\n\t$('#loadConfigButton').on('click', function() {\n\t\tScriptController.loadScript();\n\t});\n\n\t$('#saveConfigButton').on('click', function() {\n\t\tScriptController.saveScript();\n\t});\n\n\t$('#runConfigButton').on('click', function() {\n\t\tScriptController.runScript();\n\t});\n\n\t$('#clearConsoleBtn').on('click', function() {\n\t\t$('#ambConsole').empty();\n\t});\n\n\t//Simulator init\n\tSimulator.ambConsole = $('#ambConsole');\n\n\t// editor init - not used due to TIVI-2181\n\t// editor = ace.edit(\"textArea\");\n\t// editor.setTheme(\"ace/theme/ambiance\");\n\t// editor.getSession().setMode(\"ace/mode/javascript\");\n\n\t// vehicle init\n\tvehicle = new Vehicle(PropertiesController.wsStart, PropertiesController.wsError, \"ws://localhost:23001\");\n}", "function initclient() {\n\tvar model=new RemoteModel();\n\tvar view=new UserView();\n\tvar controller=new Controller(model,view);\n\tmodel.init();\n\tgeid('userinterface').innerHTML=\"client initialized\";\n\tgeid('title').innerHTML=\"IOktopus v0.35 growing...\";\n}", "function _init() {\r\n $sc['_name'] = CONTROLLER_NAME;\r\n\r\n //Set page title\r\n $hs.$scope.setTitle([\r\n characterInfo['serverName'],\r\n '->',\r\n characterInfo['characterName']\r\n ].join(' '));\r\n\r\n //Set up character and server names and stats\r\n $sc['serverName'] = characterInfo['serverName'];\r\n $sc['character'] = characterInfo;\r\n\r\n //Set up chart\r\n $sc['chart'] = _setUpChart(characterInfo);\r\n\r\n //Set up pagination\r\n $sc['pagination'] = _setUpPagination(characterInfo['status'], 10);\r\n\r\n //Search...\r\n $sc['search'] = _search;\r\n }", "function _loadController() {\n // pageService.getPagData(contactPageId).then(\n // _getPageDataSuccessResult, _getPageDataErrorResult);\n pageService.getAllSelect(columnIds).then(_getAllSelectSuccessResult, _getAllSelectErrorResult)\n function _getAllSelectSuccessResult(result) {\n\n $scope.dropDownLists = result;\n\n $scope.entity.Current = param.Current;\n if (param.Current != undefined) {\n if (!param.Current.IsSameAsPermanent) {\n $scope.entity.Permanent = param.Permanent;\n }\n }\n\n }\n function _getAllSelectErrorResult(err) {\n\n }\n }", "function changeVPSAuto(index) {\n logMessage('Control :' + vpsPerFrameControlList[index].controlName);\n var control = document.getElementById(vpsPerFrameControlList[index].control);\n var autoControl = document.getElementById(vpsPerFrameControlList[index].autoControl);\n if (index === 0) {\n frameControllers[lstFrames.selectedIndex].exposureControl.auto = autoControl.checked;\n var label = document.getElementById('lblExposure');\n if (autoControl.checked) {\n label.value = \"Exposure: Auto\";\n } else {\n control = document.getElementById(vpsPerFrameControlList[0].control);\n label.value = \"Exposure:\" + control.value;\n }\n } else {\n frameControllers[lstFrames.selectedIndex].isoSpeedControl.auto = autoControl.checked;\n var isoLabel = document.getElementById('lblIsoSpeed');\n if (autoControl.checked) {\n isoLabel.value = \"IsoSpeed: Auto\";\n } else {\n control = document.getElementById(vpsPerFrameControlList[1].control);\n isoLabel.value = \"IsoSpeed:\" + control.value;\n }\n }\n control.disabled = autoControl.checked;\n\n\n}", "[$onContentLoad](e) {\n this.activeScene = undefined;\n this.activeEntity = undefined;\n this.activeRenderer = undefined;\n this.needsReload = false;\n }", "function init() {\n\t\t\tctrl.competenceprofileAll = [];\n\t\t\tctrl.competenceprofile = {};\n\t\t\tctrl.idSelected = null;\n\t\t\tcompetenceprofileConnectorFactory.getCompetenceProfileAll().then(setCompetenceProfileAll, null);\n\t\t}", "function newload() {\n $.mobile.loading(\"show\");\n\n //Create object which will store device data\n window.controller = {};\n update_device(\n function(){\n if (window.controller.settings.en == \"1\") $(\"#en\").prop(\"checked\",true);\n if (window.controller.settings.mm == \"1\") $(\"#mm,#mmm\").prop(\"checked\",true);\n update_weather();\n changePage(\"#sprinklers\");\n },\n function(){\n $.mobile.loading(\"hide\");\n if (Object.keys(getsites()).length) {\n show_sites(false);\n } else {\n changePage(\"#start\");\n }\n }\n );\n}", "function ctrl1(){\r\n this.var1= \"From Ctrl1\";\r\n}", "get controller()\n {\n return this._controller;\n }", "get controller()\n {\n return this._controller;\n }", "function init() {\n MetaTaxonomyService.getMetaTaxonomyForTargets(ctrl.tabs).then(function (metaTaxonomies) {\n ctrl.metaTaxonomies = metaTaxonomies;\n });\n }", "init_control(){\n if(this.properties.error) this.jquery_place().addClass('error'); else this.jquery_place().removeClass('error');\n }", "function saveInitialValues() {\n\t//Iterate through all inputs, selects and textareas\n\t$$('#'+standardPrefix+'FormContents input,#'+standardPrefix+'FormContents select,#'+standardPrefix+'FormContents textarea').each(function(el) {\n\t\t//Check that change tracking is not disabled for this element\n\t\tif(!el.hasClass('noChangeTrack'))\n\t\t\tel.store('initialValue',el.value);\n\t});\t\n}", "function Awake ()\n{\n\n\t// get a reference to the target script (PlayerController)\n\tPControllerScript = PControllerObj.GetComponent (PlayerController);\n\t\n\t// get a reference to the target script (TrainController)\n\tTControllerScript = TControllerObj.GetComponent (TrainController);\n\n\t// get and set DELOREAN\n\ttheDeLorean = GameObject.FindWithTag(\"DeLorean\");\n\n\t// get and set CEMENT TRUCK\n\ttheCTruck = GameObject.FindWithTag(\"Cement\");\n\n\t// get and set MANURE TRUCK\n\ttheMTruck = GameObject.FindWithTag(\"Manure\");\n\n}", "function init() {\r\n alertify.parent(document.body);\r\n console.log(\"init()s'est executée\");\r\n\r\n doAjax(ajaxTarget + \"?level=\" + level + \"&red=\"+ red +\"&blue=\"+blue,ajaxCallback, 0, 0);\r\n\r\n alerteTemp();\r\n\r\n //désatvier le controller\r\n $(\".autoside\").removeClass(\"disableSide\").addClass(\"disableSide\");\r\n $(\".manuside\").removeClass(\"disableSide\").addClass(\"disableSide\");\r\n $(\".barre\").removeClass(\"disableSide\").addClass(\"disableSide\");\r\n $(\".mode\").removeClass(\"disableSide\").addClass(\"disableSide\");\r\n\r\n document.getElementById('automatiqueMode').disabled = true;\r\n document.getElementById('manualMode').disabled = true;\r\n\r\n }", "function applicationLoaded() {\n initiateController();\n }", "function init()\n{\n //initalize the application\n meDominance='';\n reset();\n //setFrameUrl('header','header.htm');\n //setFrameUrl('left','selectdomleft.htm');\n //setFrameUrl('right','selectdomright.htm');\n\n blnInitCalled=true;\n}", "setupController(controller, model) {\n this._super(controller, model);\n controller.set('document', this.modelFor('documents.show'));\n }", "loadValueProposition() {\n $(jqId(VALUE_PROPOSITION_PANEL)).load(\"valueproposition/vm_cluster.html\");\n }", "setFaustInterfaceControles() {\n this.moduleView.fTitle.textContent = this.moduleFaust.fName;\n var moduleFaustInterface = new FaustInterfaceControler((faustInterface) => { this.interfaceSliderCallback(faustInterface); }, (adress, value) => { this.moduleFaust.fDSP.setParamValue(adress, value); });\n this.moduleControles = moduleFaustInterface.parseFaustJsonUI(JSON.parse(this.moduleFaust.fDSP.getJSON()).ui, this);\n }", "function initialize() {\n $scope.isBrowser = true; //util.isBrowser();\n loadAllAppFiles();\n\n var div = document.getElementById('cc.base1');\n var ccBase = new LoadingCtrl(div);\n ccBase.initialize();\n ccBase.invalid();\n\n var divPartical = document.getElementById('cc.base2');\n var ccPartical = new ParticalCtrl(divPartical);\n ccPartical.initialize();\n ccPartical.invalid();\n\n var I18nRes = {\n \"HELLO\": 'HELLO',\n \"template.WELCOME\": {\n Key: 'template.WELCOME',\n Params: { name: $scope.Eugene.name },\n },\n };\n\n $scope.I18nRes = Object.keys(I18nRes).map(function(key) {\n return I18nRes[key];\n });\n\n testOOP();\n }", "function initPage(sMode) {\n \n bindConfigurationTemplate();\n setFocusToField(\"lkpDepotCode\");\n hideDiv(\"lnkReset\");\n hideDiv(\"divDetail\");\n}", "function initController() {\n UserService.GetAll().then(function (user) {\n $scope.allUsers = user;\n $scope.userLength = Object.size(user);\n }).finally(function() {\n\t\t\t\t$scope.loading = false;\n\t\t\t});\n }", "function cntrlMessInit(){\n\t\tvar cntrlMess = getCookie('hasUsedControls');\n\t\tif(cntrlMess == undefined || cntrlMess == null || cntrlMess == ''){\n\t\t\t$('#controls .control-info').fadeIn();\n\t\t}\n\t}", "resetVars() {\r\n this._current = undefined;\r\n this._nextRevisionNr = exports.INITIAL_REVISION_NEXT_NR;\r\n }", "function IndexController() {\n initHbbtv();\n setRedButtonTimeout();\n window.onkeydown = redButtonCreateAppEventHandler;\n}", "function initUI() {\n\tlogMessage(REP_ITEM_NOTE, \"bc_configure_edit\", \"calling initUI --- \" + globals.editorPage);\n\t// get panel color//\n\tvar col = dw.getPanelColor();\n\tvar backgroundColor = MM.BC.UTILS.RGB2HTML(col[0], col[1], col[2]);\n\tvar loadingDiv = document.getElementById(\"loadingDiv\");\n\t\n\tvar cancel_btn = document.getElementById(\"cancelBtn\");\n\tvar cancel_btn_container = document.getElementById(\"cancelBtnContainer\");\n\tcancel_btn_container.style.width = cancel_btn.style.width;\n\t\n\tloadLoadingPage();\t \n\t\n\tloadingDiv.style.width = globals.width + \"px\";\n\tloadingDiv.style.height = globals.height + \"px\";\n\t\n\tloadingDiv.style.backgroundColor = \"#\" + backgroundColor;\n\t\n\t// Setup the browser control.\n\tglobals.browser = document.getElementById(\"bc_priority_browser\");\t\n\tglobals.browser.setAutomaticallyPromptForCredentials(false);\n\tglobals.browser.style.top = \"0px\";\n\tglobals.browser.style.left = \"0px\";\n\tglobals.browser.style.width = window.innerWidth + \"px\";\n\tglobals.browser.style.height = (window.innerHeight - 55) + \"px\";\n\t// add general listeners on browser control//\n\tif (globals.browser && globals.browser.addEventListener) {\n\t\tglobals.browser.addEventListener(\"BrowserControlBeforeNavigation\", function (e) { onBeforeNavigation(e); }, false);\n\t\tglobals.browser.addEventListener(\"BrowserControlBeforeRefresh\", function(e) { e.preventDefault(); }, false);\n\t}\n\t\n\tglobals.initedUI = true;\n\n\t// get the module code//\n\tvar dom = dw.getDocumentDOM();\n\tvar sel = dom.getSelection();\n\tif (globals.editMode) {\n\t\tglobals.moduleCode = dom.documentElement.outerHTML.substring(sel[0], sel[1]);\n\t}\n\tglobals.targetURL = globals.editorPage;\n\t// show loading state//\n\tshowLoadingState();\n\t// if we have a site token//\n\tif (MM.BC.TOKENS.getSiteToken(MM.BC.SITE.getSiteID())) {\n\t\t// if we don't have a site token, start api calls//\n\t\tbrowseTo(MM.BC.CONSTANTS.BC_LOCAL_PAGE, true, function() {\n\t\t\t// load module editor page//\n\t\t\tloadModuleEditorPage();\t\t\n\t\t}, true);\n\t} else {\n\t\t// if we don't have a site token, start api calls//\n\t\tbrowseTo(MM.BC.CONSTANTS.BC_LOCAL_PAGE, true, function() {\n\t\t\tstartAPIProcesses(MM.BC.TOKENS.getGenericToken(), MM.BC.SITE.getSiteID());\n\t\t}, true);\n\t}\n}", "function resetControls() {\n $(\"#function\").val(defCtrlState.hashFunct);\n $(\"#collision\").val(defCtrlState.collision);\n $(\"#tablesize\").val(defCtrlState.tableSize);\n $(\"#keyrange\").val(defCtrlState.keyrange);\n $(\"#M\").val(defCtrlState.m);\n if (defCtrlState.m === '') {\n $('#mValue').hide();\n }\n setFunction();\n\n // Clear input textbox and disable next button\n $(\"#input\").val(\"\");\n $('#next').attr(\"disabled\", \"disabled\");\n }", "function SettingsPresenter() {\r\n\r\n var MyInstance=this;\r\n \r\n /// <summary>\r\n /// LoadAllPairedDevices\r\n /// </summary>\r\n /// <param name=\"$scope\">Current scope</param>\r\n /// <param name=\"xlatService\">xlatService for globalization</param>\r\n this. PageLoad = function ($scope, xlatService) {\r\n try {\r\n\r\n OneViewConsole.Debug(\"PageLoad Start\", \"SettingsPresenter.PageLoad\");\r\n // Make the probe list to null (empty)\r\n $scope.probes = {};\r\n $scope.LogVariableList = {};\r\n $scope.ShiftsData = {}; \r\n // Show the settings page to visible\r\n // Bydefault this page will visible\r\n $scope.settingvisible = true;\r\n $scope.BackVisible = false;\r\n $scope.NewProbes = {};\r\n\r\n var _DOM = new DOM();\r\n var TemperatureAutoMaualBadgetxt = 'Auto';\r\n var _oSettingsBO = new SettingsBO();\r\n _oSettingsBO.UpdateManualPinValidityStatus();\r\n\r\n if (IsGlobalAutoTemperatureManualAllowed == true){\r\n TemperatureAutoMaualBadgetxt = 'Manual';\r\n if (document.getElementById('lblTempReading') != null)\r\n document.getElementById('lblTempReading').innerHTML = \"Manual\";\r\n\r\n if (document.getElementById('lblBlueThermStatus') != null) {\r\n document.getElementById('lblBlueThermStatus').className = \"assertive\";\r\n document.getElementById('lblBlueThermStatus').innerHTML = xlatService.xlat('Manual');\r\n }\r\n } \r\n else {\r\n TemperatureAutoMaualBadgetxt = 'Auto';\r\n if (document.getElementById('lblTempReading') != null)\r\n document.getElementById('lblTempReading').innerHTML = \"Auto\";\r\n\r\n if (document.getElementById('lblBlueThermStatus') != null) {\r\n document.getElementById('lblBlueThermStatus').className = \"balanced\";\r\n document.getElementById('lblBlueThermStatus').innerHTML = xlatService.xlat('Auto'); \r\n }\r\n }\r\n \r\n\r\n var oOneViewAppInfoPlugin = new OneViewAppInfoPlugin();\r\n var LocalAppInfo = oOneViewAppInfoPlugin.GetLocalAppInfo();\r\n\r\n var CleaningProfiledownloadViewConfiguration = \"Disabled\";\r\n if (document.getElementById('lblMyDownLoadView') != null) {\r\n document.getElementById('lblMyDownLoadView').innerHTML = \"Disabled\";\r\n }\r\n if (IsGlobalCleaningProfiledownloadView == true) {\r\n CleaningProfiledownloadViewConfiguration = \"Enabled\";\r\n if (document.getElementById('lblMyDownLoadView') != null) {\r\n document.getElementById('lblMyDownLoadView').innerHTML = \"Enabled\";\r\n }\r\n }\r\n else {\r\n CleaningProfiledownloadViewConfiguration = \"Disabled\";\r\n if (document.getElementById('lblMyDownLoadView') != null) {\r\n document.getElementById('lblMyDownLoadView').innerHTML = \"Disabled\";\r\n }\r\n }\r\n\r\n var ConflictResolveModeConfiguration = \"Use Mine\";\r\n if (document.getElementById('lblResolveMode') != null)\r\n document.getElementById('lblResolveMode').innerHTML = \"Use Mine\";\r\n if (OneViewGlobalConflictResolveMode == 2) {\r\n ConflictResolveModeConfiguration = \"Use Server\";\r\n if (document.getElementById('lblResolveMode') != null)\r\n document.getElementById('lblResolveMode').innerHTML = \"Use Server\";\r\n } \r\n else {\r\n ConflictResolveModeConfiguration = \"Use Mine\";\r\n if (document.getElementById('lblResolveMode') != null)\r\n document.getElementById('lblResolveMode').innerHTML = \"Use Mine\";\r\n }\r\n \r\n var GlobalOVGuidChecking = \"Disabled\";\r\n if (document.getElementById('lblGlobalOVGuidChecking') != null) {\r\n document.getElementById('lblGlobalOVGuidChecking').innerHTML = \"Disabled\";\r\n }\r\n if (IsGlobalOVGuidCheckingEnabled == true) {\r\n GlobalOVGuidChecking = \"Enabled\";\r\n if (document.getElementById('lblGlobalOVGuidChecking') != null) {\r\n document.getElementById('lblGlobalOVGuidChecking').innerHTML = \"Enabled\";\r\n }\r\n }\r\n else {\r\n GlobalOVGuidChecking = \"Disabled\";\r\n if (document.getElementById('lblGlobalOVGuidChecking') != null) {\r\n document.getElementById('lblGlobalOVGuidChecking').innerHTML = \"Disabled\";\r\n }\r\n }\r\n\r\n //State Mangement : New Dc\r\n // alert('IsGlobal_NewDc_StateManagementEnabled kkkk ' + IsGlobal_NewDc_StateManagementEnabled);\r\n if (IsGlobal_NewDc_StateManagementEnabled == true) {\r\n _DOM.AddInnerHtml('lblNewDcState', \"Enable\");\r\n }\r\n else {\r\n _DOM.AddInnerHtml('lblNewDcState', \"Disable\");\r\n }\r\n\r\n\r\n //Probe Indicator : Hide and Show \r\n //alert('IsGlobalBlueThermLiveTemperatureIndicatorEnabled : ' + IsGlobalBlueThermLiveTemperatureIndicatorEnabled);\r\n if (IsGlobalBlueThermLiveTemperatureIndicatorEnabled == true) {\r\n if (document.getElementById('lblTempIndicator') != null) {\r\n document.getElementById('lblTempIndicator').innerHTML = \"Enabled\";\r\n }\r\n }\r\n\r\n else {\r\n if (document.getElementById('lblTempIndicator') != null) {\r\n document.getElementById('lblTempIndicator').innerHTML = \"Disabled\";\r\n }\r\n }\r\n\r\n\r\n\r\n if (IsNewDcPageDcStartDateSelectionEnabled == true) {\r\n _DOM.AddInnerHtml('lblNewDcStartDateSelection', \"Enable\"); \r\n }\r\n\r\n else {\r\n _DOM.AddInnerHtml('lblNewDcStartDateSelection', \"Disable\");\r\n }\r\n \r\n if (OneViewLocalStorage.Get(\"IsAutoUploadEnabled\") == null || OneViewLocalStorage.Get(\"IsAutoUploadEnabled\") == \"false\") {\r\n _DOM.AddInnerHtml('lblAutoUpload', \"Disable\");\r\n \r\n }\r\n else {\r\n _DOM.AddInnerHtml('lblAutoUpload', \"Enable\");\r\n }\r\n\r\n if (OneViewLocalStorage.Get(\"IsAutoActionFollowupDownloadEnabled\") == null || OneViewLocalStorage.Get(\"IsAutoActionFollowupDownloadEnabled\") == \"false\") {\r\n _DOM.AddInnerHtml('lblAutoActionFollowupDownload', \"Disable\");\r\n\r\n }\r\n else {\r\n _DOM.AddInnerHtml('lblAutoActionFollowupDownload', \"Enable\");\r\n }\r\n\r\n if (OneViewLocalStorage.Get(\"IsAutoSyncEnabled\") == 'true') {\r\n _DOM.AddInnerHtml('lblAutoSync', xlatService.xlat('Enable'));\r\n }\r\n else {\r\n _DOM.AddInnerHtml('lblAutoSync', xlatService.xlat('Disable'));\r\n }\r\n\r\n if (OneViewLocalStorage.Get(\"IsAutoMetadataDownload\") == 'true') {\r\n _DOM.AddInnerHtml('lblAutoMetadataDownload', xlatService.xlat('Enable'));\r\n }\r\n else {\r\n _DOM.AddInnerHtml('lblAutoMetadataDownload', xlatService.xlat('Disable'));\r\n }\r\n\r\n if (OneViewLocalStorage.Get(\"IsGlobalGeoLocationValidationEnabled\") == null) {\r\n _DOM.AddInnerHtml('lblEnableGeoLocationValidation', \"Disable\");\r\n }\r\n else {\r\n if (OneViewLocalStorage.Get(\"IsGlobalGeoLocationValidationEnabled\") == \"true\") {\r\n _DOM.AddInnerHtml('lblEnableGeoLocationValidation', \"Enable\");\r\n if (OneViewLocalStorage.Get(\"LocalStorageDistanceSpan\") != null) {\r\n _DOM.AddInnerHtml('lblDistanceSpan', OneViewLocalStorage.Get(\"LocalStorageDistanceSpan\") + \"(m)&nbsp;&nbsp;&nbsp;\");\r\n }\r\n }\r\n else {\r\n _DOM.AddInnerHtml('lblEnableGeoLocationValidation', \"Disable\");\r\n } \r\n }\r\n\r\n if (OneViewLocalStorage.Get(\"IsGlobalLandingpagedailysyncEnabled\") == null) {\r\n _DOM.AddInnerHtml('lblLandingpagedailysync', \"Disable\");\r\n }\r\n else {\r\n if (OneViewLocalStorage.Get(\"IsGlobalLandingpagedailysyncEnabled\") == \"true\") {\r\n _DOM.AddInnerHtml('lblLandingpagedailysync', \"Enable\");\r\n }\r\n else {\r\n _DOM.AddInnerHtml('lblLandingpagedailysync', \"Disable\");\r\n }\r\n }\r\n\r\n // Show all settings\r\n //$scope.settings = [\r\n // { title: \"Probe Configuration\", newpage: true, enabled: true, icon: \"ion-thermometer\" },\r\n // { title: \"Auto/Manual Temperature Configuration\", enabled: true, badge: true, badgetxt: TemperatureAutoMaualBadgetxt, icon: \"ion-edit\" },\r\n // { title: \"My Downloads : Cleaning View\", enabled: true, badge: true, badgetxt: CleaningProfiledownloadViewConfiguration, icon: \"ion-edit\" },\r\n // { title: \"Conflict Resolve Mode\", enabled: true, badge: true, badgetxt: ConflictResolveModeConfiguration, icon: \"ion-edit\" },\r\n // { title: \"Copy DB\", enabled: true, icon: \"ion-gear-a\" },\r\n // { title: \"Upload DB\", enabled: true, icon: \"ion-gear-a\" },\r\n // { title: \"Upload Logs\", enabled: true, icon: \"ion-gear-a\" },\r\n // { title: \"Restore DB\", enabled: true, icon: \"ion-gear-a\" },\r\n // { title: \"ClearAll DC And Actions\", enabled: true, icon: \"ion-gear-a\" },\r\n // { title: \"Clean DB\", enabled: true, icon: \"ion-gear-a\" },\r\n // { title: \"Enable Logs\", newpage: true, enabled: true, icon: \"ion-gear-a\" },\r\n // { title: \"Check For Updates\", newpage: true, enabled: true, icon: \"ion-gear-a\" },\r\n // { title: \"Refresh Page Globalization\", newpage: true, enabled: true, icon: \"ion-gear-a\" },\r\n // { title: \"Refresh\", newpage: true, enabled: true, icon: \"ion-gear-a\" },\r\n // { title: \"Version : OneView \" + LocalAppInfo.VersionName, enabled: true, icon: \"ion-gear-a\" },\r\n // { title: \"Reset Password\", enabled: true, icon: \"ion-gear-a\" }\r\n //];\r\n\r\n $scope.settings = [\r\n { Id: \"Setting_ProbeConfiguration_ProbeSynchronize\", title: \"Probe Configuration\", newpage: true, enabled: true, icon: \"ion-thermometer\" },\r\n { Id: 'Setting_ProbeConfiguration_TemperatureReading', title: \"Auto/Manual Temperature Configuration\", enabled: true, badge: true, badgetxt: TemperatureAutoMaualBadgetxt, icon: \"ion-edit\" },\r\n { Id: \"Setting_Download_CleaningView\", title: \"My Downloads : Cleaning View\", enabled: true, badge: true, badgetxt: CleaningProfiledownloadViewConfiguration, icon: \"ion-edit\" },\r\n { Id: \"Setting_Application_ConflictResolveMode\", title: \"Conflict Resolve Mode\", enabled: true, badge: true, badgetxt: ConflictResolveModeConfiguration, icon: \"ion-edit\" },\r\n { Id: \"Setting_Application_GlobalOVGuidChecking\", title: \"OneView Version Conflict\", enabled: true, badge: true, badgetxt: GlobalOVGuidChecking, icon: \"ion-edit\" },\r\n { Id: \"Setting_Log_EnableLogs\", title: \"Enable Logs\", newpage: true, enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_Log_UploadLogs\", title: \"Upload Logs\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_DB_CopyDB\", title: \"Copy DB\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_DB_UploadDB\", title: \"Upload DB\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_DB_RestoreDB\", title: \"Restore DB\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_DB_CleanDB\", title: \"Clean DB\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_DB_CleanDCActions\", title: \"ClearAll DC And Actions\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_Application_CheckUpdates\", title: \"Check For Updates\", newpage: true, enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_Application_RefreshGlobalization\", title: \"Refresh Page Globalization\", newpage: true, enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_Application_Refresh\", title: \"Refresh\", newpage: true, enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_Version_VersionName\", title: \"Version : OneView \" + LocalAppInfo.VersionName, enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_Profile_ChangePassword\", title: \"Reset Password\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_StateManagement_NewDc\", title: \"New Dc State Enable\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_ProbeConfiguration_TempIndicator\", title: \"Live Temperature Indicator Enable\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_NewDcDateSelectionEnable_DcStartDate\", title: \"New Dc Page Dc Start Date Selection Enable\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_ShiftSelection\", title: \"Shift Selection\", newpage: true, enabled: true, icon: \"ion-thermometer\" },\r\n { Id: \"Setting_DB_UploadImagesAndDbAcrossService\", title: \"Upload Across Service Image and Database\", enabled: true, icon: \"ion-gear-a\" },\r\n\r\n { Id: \"Setting_AutoSync_StartSync\", title: \"Sync\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_AutoMetadataDownload\", title: \"Auto Master Data Download\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_AutoMasterMetadataDownload\", title: \"Auto Download\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_Application_GlobalOVGuidChecking\", title: \"OneView Version Conflict\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_Application_GeoLocationValidation\", title: \"GeoLocation Validation in landing page\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_Application_Landingpagedailysync\", title: \"Landing page daily sync\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_MobileAutoSync_Sync\", title: \"Sync\", enabled: true, icon: \"ion-gear-a\" },\r\n { Id: \"Setting_MobileAutoSync_Refresh\", title: \"Refresh Mobile Auto Sync Metadata\", enabled: true, icon: \"ion-gear-a\" },\r\n ];\r\n\r\n //var SettingMetadata = {\r\n // \"ServiceId\": 1, \r\n // \"UserId\": -1,\r\n // \"OperationTagList\": [\r\n // {\r\n // \"OperationTag\": \"Setting_ProbeConfiguration_TemperatureReading\", Hide: false,\r\n\r\n // }\r\n // ]\r\n //}\r\n //for (var Key in SettingMetadata) {\r\n \r\n // if (Key == \"OperationTagList\") {\r\n // if (SettingMetadata[Key].length > 0) {\r\n \r\n // var _OperationTag = SettingMetadata[Key];\r\n // for (var i = 0; i < _OperationTag.length; i++) {\r\n // $scope[_OperationTag[i][\"OperationTag\"] ]= _OperationTag[i][\"Hide\"];\r\n // }\r\n // }\r\n // }\r\n //}\r\n var EventArgs = { GroupId: 'Setting', oScope: $scope };\r\n var _ACLEnableHandler = new ACLEnableHandler();\r\n _ACLEnableHandler.handleACLEnableJob(EventArgs);\r\n\r\n \r\n\r\n if (document.getElementById('lblVersion') != null)\r\n document.getElementById('lblVersion').innerHTML = \"OneView \" + LocalAppInfo.VersionName;\r\n \r\n MyInstance.SetupForOS($scope);\r\n \r\n OneViewConsole.Debug(\"PageLoad End\", \"SettingsPresenter.PageLoad\");\r\n }\r\n\r\n catch (Excep) { \r\n throw oOneViewExceptionHandler.Create(\"Presenter\", \"SettingsPresenter.PageLoad\", Excep);\r\n }\r\n finally {\r\n TemperatureAutoMaualBadgetxt = null;\r\n oOneViewAppInfoPlugin = null;\r\n LocalAppInfo = null;\r\n }\r\n }\r\n \r\n this.SetupForOS=function($scope)\r\n {\r\n if(OSType == OSTypeEnum.IOS)\r\n {\r\n $scope.Setting_ProbeConfiguration=true;\r\n $scope.Setting_Log=true;\r\n $scope.Setting_DB_CopyDB=true;\r\n $scope.Setting_DB_RestoreDB=true;\r\n $scope.Setting_Application_CheckForUpdates=true;\r\n }\r\n }\r\n\r\n /// <summary>\r\n /// LoadAllPairedDevices\r\n /// </summary>\r\n /// <param name=\"$scope\">Current scope</param>\r\n /// <param name=\"DeviceLst\">List of paired devices</param>\r\n /// <param name=SettingsObj>selected settings object</param> \r\n this.ShowPairedDevices = function ($scope, DeviceLst, SettingsObj) {\r\n try {\r\n OneViewConsole.Debug(\"ShowPairedDevices Start\", \"SettingsPresenter.ShowPairedDevices\");\r\n // Updating the model with available devices\r\n for (var i = 0; i < DeviceLst.length; i++) {\r\n\r\n if (ConnectedProbe[0] != undefined) {\r\n if (DeviceLst[i].DeviceName == ConnectedProbe[0].Name) {\r\n\r\n var oBluetoothTemperatureLoggerBO = new BluetoothTemperatureLoggerBO()\r\n var IsConnectionAlive = oBluetoothTemperatureLoggerBO.IsConnectionAlive(ConnectedProbe[0].Name);\r\n\r\n if (IsConnectionAlive)\r\n $scope.probes[i + 1] = { \"Index\": i + 1, \"Id\": DeviceLst[i].DeviceName, \"Name\": DeviceLst[i].DeviceName, \"selected\": 'selected' };\r\n else {\r\n ConnectedProbe[0] = undefined;\r\n $scope.probes[i + 1] = { \"Index\": i + 1, \"Id\": DeviceLst[i].DeviceName, \"Name\": DeviceLst[i].DeviceName };\r\n }\r\n }\r\n else {\r\n $scope.probes[i + 1] = { \"Index\": i + 1, \"Id\": DeviceLst[i].DeviceName, \"Name\": DeviceLst[i].DeviceName };\r\n } \r\n }\r\n else {\r\n $scope.probes[i + 1] = { \"Index\": i + 1, \"Id\": DeviceLst[i].DeviceName, \"Name\": DeviceLst[i].DeviceName }; \r\n }\r\n }\r\n\r\n // Show the new page with available devices\r\n if (SettingsObj.newpage) {\r\n $scope.settingvisible = false;\r\n $scope.probevisible = true;\r\n $scope.BackVisible = true;\r\n $scope.UpdatePassword = false;\r\n\r\n $scope.Settings = false;\r\n $scope.ChangePassword = false;\r\n $scope.SettingsToolBar = true;\r\n $scope.ProbeList = true;\r\n\r\n $scope.ShiftsVisible = false;\r\n }\r\n OneViewConsole.Debug(\"ShowPairedDevices End\", \"SettingsPresenter.ShowPairedDevices\");\r\n }\r\n catch (Excep) {\r\n throw oOneViewExceptionHandler.Create(\"Presenter\", \"SettingsPresenter.ShowPairedDevices\", Excep);\r\n }\r\n }\r\n\r\n this.ShowNewPairedProbeDevices = function ($scope, DeviceLst, SettingsObj) {\r\n try {\r\n OneViewConsole.Debug(\"ShowPairedDevices Start\", \"SettingsPresenter.ShowPairedDevices\");\r\n \r\n $scope.probes = {};\r\n for (var i = 0; i < DeviceLst.length; i++) {\r\n \r\n if (ConnectedProbe[0] != undefined) {\r\n if (DeviceLst[i].DeviceName == ConnectedProbe[0].Name) {\r\n\r\n var oBluetoothTemperatureLoggerBO = new BluetoothTemperatureLoggerBO()\r\n var IsConnectionAlive = oBluetoothTemperatureLoggerBO.IsConnectionAlive(ConnectedProbe[0].Name,true);\r\n\r\n if (IsConnectionAlive)\r\n $scope.probes[i + 1] = { \"Index\": i + 1, \"Id\": DeviceLst[i].DeviceName, \"Name\": DeviceLst[i].DeviceName, \"selected\": 'selected' };\r\n else {\r\n ConnectedProbe[0] = undefined;\r\n $scope.probes[i + 1] = { \"Index\": i + 1, \"Id\": DeviceLst[i].DeviceName, \"Name\": DeviceLst[i].DeviceName };\r\n }\r\n }\r\n else {\r\n $scope.probes[i + 1] = { \"Index\": i + 1, \"Id\": DeviceLst[i].DeviceName, \"Name\": DeviceLst[i].DeviceName };\r\n }\r\n }\r\n else {\r\n\r\n $scope.probes[i + 1] = { \"Index\": i + 1, \"Id\": DeviceLst[i].DeviceName, \"Name\": DeviceLst[i].DeviceName, \"selected\": '' };\r\n $scope.probes[i + 1].selected = '';\r\n \r\n }\r\n }\r\n\r\n // Show the new page with available devices\r\n if (SettingsObj.newpage) {\r\n $scope.settingvisible = false;\r\n $scope.NewProbevisible = true;\r\n $scope.probevisible = false;\r\n $scope.BackVisible = true;\r\n $scope.UpdatePassword = false;\r\n\r\n $scope.Settings = false;\r\n $scope.ChangePassword = false;\r\n $scope.SettingsToolBar = true;\r\n $scope.ProbeList = true;\r\n\r\n $scope.ShiftsVisible = false;\r\n }\r\n OneViewConsole.Debug(\"ShowPairedDevices End\", \"SettingsPresenter.ShowPairedDevices\");\r\n }\r\n catch (Excep) {\r\n throw oOneViewExceptionHandler.Create(\"Presenter\", \"SettingsPresenter.ShowPairedDevices\", Excep);\r\n }\r\n }\r\n\r\n\r\n /// <summary>\r\n /// SaveSelectedDevice\r\n /// </summary>\r\n /// <param name=\"probeObj\">Probe info</param> \r\n this.SaveSelectedDevice = function (probeObj) {\r\n try {\r\n OneViewConsole.Debug(\"SaveSelectedDevice Start\", \"SettingsPresenter.SaveSelectedDevice\");\r\n //Selected probe information\r\n ConnectedProbe[0] = { \"Index\": probeObj.Index, \"Id\": probeObj.Name, \"Name\": probeObj.Name };\r\n\r\n OneViewConsole.Debug(\"SaveSelectedDevice End\", \"SettingsPresenter.SaveSelectedDevice\");\r\n }\r\n catch (Excep) {\r\n throw oOneViewExceptionHandler.Create(\"Presenter\", \"SettingsPresenter.SaveSelectedDevice\", Excep);\r\n }\r\n }\r\n\r\n /// <summary>\r\n /// UpdateProbeDisconnectStatus\r\n /// </summary>\r\n /// <param name=\"$scope\">Current scope</param> \r\n /// <param name=\"probeObj\">Probe info</param> \r\n this.UpdateProbeDisconnectStatus = function ($scope, probeObj) {\r\n try {\r\n OneViewConsole.Debug(\"UpdateProbeDisconnectStatus Start\", \"SettingsPresenter.UpdateProbeDisconnectStatus\");\r\n\r\n $scope.probes[probeObj.Index].selected = '';\r\n\r\n OneViewConsole.Debug(\"UpdateProbeDisconnectStatus End\", \"SettingsPresenter.UpdateProbeDisconnectStatus\");\r\n }\r\n catch (Excep) {\r\n throw oOneViewExceptionHandler.Create(\"Presenter\", \"SettingsPresenter.UpdateProbeDisconnectStatus\", Excep);\r\n }\r\n }\r\n\r\n /// <summary>\r\n /// UpdateProbeDisconnectStatus\r\n /// </summary>\r\n /// <param name=\"$scope\">Current scope</param> \r\n /// <param name=\"probeObj\">Probe info</param> \r\n this.UpdateNewProbeDisconnectStatus = function ($scope, probeObj) {\r\n try {\r\n OneViewConsole.Debug(\"UpdateNewProbeDisconnectStatus Start\", \"SettingsPresenter.UpdateNewProbeDisconnectStatus\");\r\n\r\n $scope.probes[probeObj.Index].selected = '';\r\n\r\n OneViewConsole.Debug(\"UpdateNewProbeDisconnectStatus End\", \"SettingsPresenter.UpdateNewProbeDisconnectStatus\");\r\n }\r\n catch (Excep) {\r\n throw oOneViewExceptionHandler.Create(\"Presenter\", \"SettingsPresenter.UpdateNewProbeDisconnectStatus\", Excep);\r\n }\r\n }\r\n\r\n /// <summary>\r\n /// UpdateProbeSelectedStatus\r\n /// </summary>\r\n /// <param name=\"$scope\">Current scope</param> \r\n /// <param name=\"probeObj\">Probe info</param> \r\n this.UpdateProbeSelectedStatus = function ($scope, probeObj) {\r\n try {\r\n OneViewConsole.Debug(\"UpdateProbeSelectedStatus Start\", \"SettingsPresenter.UpdateProbeSelectedStatus\");\r\n\r\n $scope.probes[probeObj.Index].selected = 'selected';\r\n\r\n OneViewConsole.Debug(\"UpdateProbeSelectedStatus End\", \"SettingsPresenter.UpdateProbeSelectedStatus\");\r\n \r\n }\r\n catch (Excep) {\r\n throw oOneViewExceptionHandler.Create(\"Presenter\", \"SettingsPresenter.UpdateProbeSelectedStatus\", Excep);\r\n }\r\n }\r\n\r\n\r\n\r\n this.ShowAllValidShifts = function ($scope, ShiftsList, SettingsObj) {\r\n try {\r\n OneViewConsole.Debug(\"ShowAllValidShifts Start\", \"SettingsPresenter.ShowAllValidShifts\");\r\n //alert('ShiftsList : ' + JSON.stringify(ShiftsList));\r\n // Updating the model with available data\r\n //for (var i = 0; i < ShiftsList.length; i++) {\r\n // $scope.ShiftsData[ShiftsList[i].ServerId] = { \"Index\": ShiftsList[i].ServerId, \"Id\": ShiftsList[i].ServerId, \"Name\": ShiftsList[i].Name };\r\n //}\r\n\r\n var Data = OneViewLocalStorage.Get(\"SelectedShiftData\");\r\n //alert(Data + \",\" + JSON.stringify(Data));\r\n if (Data != \"\" && Data != null && Data != undefined) {\r\n SelectedShiftData = JSON.parse(Data);\r\n }\r\n //alert(SelectedShiftData + 'SelectedShiftData : ' + JSON.stringify(SelectedShiftData));\r\n for (var i = 0; i < ShiftsList.length; i++) {\r\n if (SelectedShiftData != undefined) {\r\n if (ShiftsList[i].Name == SelectedShiftData.Name) {\r\n $scope.ShiftsData[ShiftsList[i].ServerId] = { \"Index\": ShiftsList[i].ServerId, \"Id\": ShiftsList[i].ServerId, \"Name\": ShiftsList[i].Name, \"selected\": 'selected' };\r\n\r\n }\r\n else {\r\n $scope.ShiftsData[ShiftsList[i].ServerId] = { \"Index\": ShiftsList[i].ServerId, \"Id\": ShiftsList[i].ServerId, \"Name\": ShiftsList[i].Name };\r\n }\r\n }\r\n else {\r\n $scope.ShiftsData[ShiftsList[i].ServerId] = { \"Index\": ShiftsList[i].ServerId, \"Id\": ShiftsList[i].ServerId, \"Name\": ShiftsList[i].Name };\r\n }\r\n }\r\n\r\n // Show the new page with available devices\r\n if (SettingsObj.newpage) {\r\n $scope.settingvisible = false;\r\n $scope.probevisible = false;\r\n $scope.NewProbevisible = false;\r\n $scope.BackVisible = true;\r\n $scope.UpdatePassword = false;\r\n\r\n $scope.Settings = false;\r\n $scope.ChangePassword = false;\r\n $scope.SettingsToolBar = true;\r\n $scope.ProbeList = true;\r\n\r\n $scope.ShiftsVisible = true;\r\n }\r\n OneViewConsole.Debug(\"ShowAllValidShifts End\", \"SettingsPresenter.ShowAllValidShifts\");\r\n }\r\n catch (Excep) {\r\n throw oOneViewExceptionHandler.Create(\"Presenter\", \"SettingsPresenter.ShowAllValidShifts\", Excep);\r\n }\r\n }\r\n \r\n\r\n /// <summary>\r\n /// SaveSelectedShift\r\n /// </summary>\r\n /// <param name=\"shiftObj\">Shift info</param> \r\n this.SaveSelectedShift = function (shiftObj) {\r\n try {\r\n OneViewConsole.Debug(\"SaveSelectedShift Start\", \"SettingsPresenter.SaveSelectedShift\");\r\n //alert('shiftObj :' + JSON.stringify(shiftObj));\r\n //Selected shift information\r\n\r\n if (shiftObj.selected == true) {\r\n SelectedShiftData = { \"Index\": shiftObj.Index, \"Id\": shiftObj.Id, \"Name\": shiftObj.Name };\r\n }\r\n else {\r\n SelectedShiftData = {};\r\n }\r\n //alert('SelectedShiftData' + JSON.stringify(SelectedShiftData));\r\n OneViewLocalStorage.Save(\"SelectedShiftData\", JSON.stringify(SelectedShiftData));\r\n\r\n OneViewConsole.Debug(\"SaveSelectedShift End\", \"SettingsPresenter.SaveSelectedShift\");\r\n }\r\n catch (Excep) {\r\n throw oOneViewExceptionHandler.Create(\"Presenter\", \"SettingsPresenter.SaveSelectedShift\", Excep);\r\n }\r\n }\r\n\r\n}" ]
[ "0.67322004", "0.65495676", "0.65495676", "0.61538666", "0.6131448", "0.60840964", "0.58426356", "0.57253", "0.57253", "0.57248455", "0.5697311", "0.56924", "0.56924", "0.56093794", "0.56092507", "0.5594043", "0.5594043", "0.5572633", "0.5535082", "0.553315", "0.5495676", "0.5492341", "0.54832155", "0.54790145", "0.54670197", "0.5464645", "0.5464134", "0.54474926", "0.54382074", "0.5437679", "0.54230064", "0.5421553", "0.54178137", "0.54133946", "0.5388496", "0.5388496", "0.5388044", "0.5373167", "0.5370041", "0.53557193", "0.53413916", "0.5310443", "0.5259888", "0.5259888", "0.52594405", "0.52543277", "0.52517515", "0.52438325", "0.5227818", "0.52237463", "0.5221548", "0.52111125", "0.5209587", "0.5202715", "0.5187901", "0.5186028", "0.51814955", "0.5174141", "0.5164313", "0.515658", "0.5138744", "0.51316005", "0.5118361", "0.5118361", "0.51159805", "0.5100839", "0.5096792", "0.50900483", "0.5088303", "0.5084689", "0.5084689", "0.5080277", "0.5075648", "0.5073298", "0.5071414", "0.50605756", "0.50582856", "0.5051616", "0.5042267", "0.5035806", "0.50351584", "0.50351584", "0.5034988", "0.50344974", "0.50288075", "0.50264823", "0.50239515", "0.5023368", "0.50210595", "0.50203556", "0.5016003", "0.501384", "0.50032055", "0.49983788", "0.49940923", "0.49895304", "0.4987314", "0.49840713", "0.49834493", "0.49822026", "0.4981406" ]
0.0
-1
return route object base on current url it should answer what is the controller, and the view. format for the hash controller/action?param1=value1&param2=value2
function getRoute(hash){ var hash = hash || window.location.hash.substring(1); if(!hash) { console.log("hash is not defined use defaultRoute: %s", JSON.stringify(defaultRoute)); return defaultRoute; } var i = hash.indexOf("?"); var path = paramStr = ""; var route = $.extend({},defaultRoute); if(i!=-1){ path = hash.substr(0,i); paramStr = hash.substr(i+1); }else{ path = hash; } var pathArr = path.split('/'); console.log("path: %s", path); if(pathArr.length==1){ route.controller = currentControllerName; route.action = pathArr[0] || route.action; }else{ route.controller = pathArr[0] || route.controller; route.action = pathArr[1] || route.action; } route.params = getParams(paramStr); console.log("route: %s", JSON.stringify(route)); return route; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getRouteHelper(obj){\r\n var tmpRoute;\r\n if(typeof(obj)==\"string\"){\r\n tmpRoute = {action: obj, controller: currentControllerName};\r\n }\r\n else{\r\n tmpRoute = obj;\r\n }\r\n tmpRoute.getParams = $.extend({},tmpRoute.params);\r\n return $.extend({}, defaultRoute, tmpRoute);\r\n }", "function currentRoute() {\n const path = $window.location.pathname;\n const pathSegments = path.slice(1).split('/');\n const params = queryString.parse($window.location.search);\n\n let route;\n switch (pathSegments[0]) {\n case 'a':\n route = 'annotation';\n params.id = pathSegments[1] || '';\n break;\n case 'stream':\n route = 'stream';\n break;\n default:\n route = 'sidebar';\n break;\n }\n\n return { route, params };\n }", "function getRoute() {\n\t\treturn hasher.getHash();\n\t}", "getRouteFromHash() {\n\t const prefixLength = exports.ROUTE_PREFIX.length;\n\t const hash = window.location.hash;\n\t // Do not try to parse route if prefix doesn't match.\n\t if (hash.substring(0, prefixLength) !== exports.ROUTE_PREFIX)\n\t return '';\n\t return hash.split('?')[0].substring(prefixLength);\n\t }", "getCurrentRoute () {\n return location.href.split('#')[1];\n }", "function route() {\n\t\tvar o = status(); //get current hash object.\n\t\tif (o) {\n\t\t\t_callControllerFromObj(o.id, o.params);\n\t\t\treturn true;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t}", "function route() {\n this.method = this.req.method.toLowerCase();\n var n = w.map[this.method];\n if (!n) {\n this.reply4xx(404, \"no route for method: \"+this.req.method);\n this.end();\n return\n } else {\n this.url = w.dep.url.parse(this.req.url, true);\n this.query = this.url.query || {};\n this.context = {};\n for (var e in this.query) { this.context[e] = this.query[e] }\n this.context._work = this;\n this.context._js = [];\n this.context._css = [];\n \n var p = this.url.pathname.split('/');\n console.log(this.req.url, \"route to ===============> \" + this.req.method.toUpperCase(), p);\n \n for (var i = 1; i < p.length; ++i) {\n var segment = p[i];\n if (n.branches[segment]) { n = n.branches[segment]; continue };\n if (n.branches[':']) { //varname\n this.context[n.varname] = segment;\n console.log(\"//varname: \" + n.varname + \" = \" + this.context[n.varname]);\n n = n.branches[':'];\n continue\n };\n if (n.branches['*']) { //wildcard\n this.context['_location'] = p.slice(i).join('/');\n console.log(\"//wildcard: \" + this.context['_location']);\n n = n.branches['*'];\n break\n };\n this.reply4xx(404, \"no route to: \"+this.req.method+' '+this.req.url);\n this.end();\n return\n };\n };\n \n if (n.handler) {\n this.mapnode = n;\n n.handler.call(this);\n this.end();\n return\n }\n\n this.reply5xx(500, \"no handler found for: \"+this.req.method+' '+this.req.url);\n this.end();\n return\n}", "function getRouteParams(route,params){var routeParams={};if(!route.path)return routeParams;var paramNames=(0,_PatternUtils.getParamNames)(route.path);for(var p in params){if(Object.prototype.hasOwnProperty.call(params,p)&&paramNames.indexOf(p)!==-1){routeParams[p]=params[p];}}return routeParams;}", "function getRouteParams(route,params){var routeParams={};if(!route.path)return routeParams;var paramNames=(0,_PatternUtils.getParamNames)(route.path);for(var p in params){if(Object.prototype.hasOwnProperty.call(params,p)&&paramNames.indexOf(p)!==-1){routeParams[p]=params[p];}}return routeParams;}", "function getRouteParams(route,params){var routeParams={};if(!route.path)return routeParams;var paramNames=(0,_PatternUtils.getParamNames)(route.path);for(var p in params){if(Object.prototype.hasOwnProperty.call(params,p)&&paramNames.indexOf(p)!==-1){routeParams[p]=params[p];}}return routeParams;}", "match(route) {\n //match route against dictionary of defined paths to their relevant attributes\n for (let [path, {pathRoute, handler, params}] of this.routes) {\n const match = pathRoute.exec(route);\n //each route will be associated with a handler\n //this handler will handle all of the rendering associated with a new change\n if (match !== null) {\n //remove the first / from the route\n //loop through values and add each value with its associated parameter\n const routeParams = match.slice(1).\n reduce((allParams, value, index) => {\n allParams[params[index]] = value;\n return allParams;\n }, {});\n //split parameters using the ?varName=varVal \n this.currentPath = path;\n //check if we have any query parameters to parse\n if (window.location.search) {\n this.getQueryParameters(window.location.search, routeParams);\n }\n handler(route, routeParams);\n //we don't want to execute more than route once we've matched one\n //if it can match multiple ones so we break\n break;\n }\n\n }\n }", "function getFormRoute(form){\r\n var hash = getHashFromUrl(form.action);\r\n console.log(\"getFormRoute | hash: %s\", hash);\r\n var route = getRoute(hash);\r\n var params = {};\r\n for(var i=0;i<form.elements.length;i++){\r\n var e = form.elements[i];\r\n var key = e.name;\r\n var type = e.type.toLowerCase();\r\n if(!key || ((type==\"radio\" || type==\"checkbox\") && !e.checked)) continue;\r\n var value = e.value;\r\n updateParamItem(params,key,value,false);\r\n }\r\n console.log(\"params: %s\", JSON.stringify(params));\r\n $.extend(route.params,params);\r\n if(form.method.toLowerCase() == \"get\"){\r\n $.extend(route.getParams,params);\r\n }\r\n else{\r\n // create post params\r\n route.postParams = params;\r\n }\r\n console.log(\"updated route: %s\", JSON.stringify(route));\r\n return route;\r\n }", "parseParams(location){\n let route = this; \n var keys=[],params={};\n var tokens = this.getMatch(location.pathname);\n if (tokens && tokens.keys.length!=0){\n var i = 1;\n var keys = tokens.keys;\n keys.forEach((e) => params[e.name] = tokens.token[i++] );\n }\n this.params = params;\n return params;\n }", "match(route) {\n //match route against dictionary of defined paths to their relevant attributes\n for (let [path, {pathRoute, handler, params}] of this.routes) {\n const match = pathRoute.exec(route);\n //each route will be associated with a handler\n //this handler will handle all of the rendering associated with a new change\n if (match !== null) {\n //remove the first / from the route\n //loop through values and add each value with its associated parameter\n const routeParams = match.slice(1).\n reduce((allParams, value, index) => {\n allParams[params[index]] = value;\n return allParams;\n }, {});\n this.currentPath = path;\n //check if we have any query parameters to parse\n if (window.location.search) {\n this.getQueryParameters(window.location.search, routeParams);\n }\n handler(route, routeParams);\n //we don't want to execute more than route once we've matched one\n //if it can match multiple ones so we break\n break;\n }\n\n }\n }", "getSubRoute(){\n var app = \"\"\n var doc = \"\"\n var url = window.location.href.split(\"#\")\n if (url.length > 1) {\n var parts = url[1].split(\"/\")\n app = parts[1]\n doc = parts[2]\n }\n return [app,doc]\n }", "function dispatch () {\n\t\teach(routes, function (route, uri) {\n\t\t\tvar callback = route[0];\n\t\t\tvar pattern = route[1];\n\t\t\tvar params = route[2];\n\t\t\tvar match = location.match(pattern);\n\n\t\t\t// we have a match\n\t\t\tif (match != null) {\n\t\t\t\t// create params object to pass to callback\n\t\t\t\t// i.e {user: 'simple', id: '1234'}\n\t\t\t\tvar data = match.slice(1, match.length);\n\n\t\t\t\tvar args = data.reduce(function (previousValue, currentValue, index) {\n\t\t\t\t\t\t// if this is the first value, create variables store\n\t\t\t\t\t\tif (previousValue == null) {\n\t\t\t\t\t\t\tpreviousValue = {};\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// name: value\n\t\t\t\t\t\t// i.e user: 'simple'\n\t\t\t\t\t\t// `vars` contains the keys for the variables\n\t\t\t\t\t\tpreviousValue[params[index]] = currentValue;\n\n\t\t\t\t\t\treturn previousValue;\n\n\t\t\t\t\t\t// null --> first value\n\t\t\t\t\t}, null); \n\n\t\t\t\tcallback(args, uri);\n\t\t\t}\n\t\t});\n\t}", "navigateToCurrentHash() {\n\t const hashRoute = this.getRouteFromHash();\n\t const newRoute = hashRoute in this.routes ? hashRoute : this.defaultRoute;\n\t this.dispatch(actions.Actions.navigate({ route: newRoute }));\n\t // TODO(dproy): Handle case when new route has a permalink.\n\t }", "function doRoute(req, context) {\n var uri = url_parse(req.url);\n var path = uri.pathname;\n for (var routeName in routes) {\n var route = routes[routeName];\n if (req.method === route.method) {\n var match = path.match(route.pattern);\n if (match && match[0].length > 0) {\n // TODO named properties params in response como query string\n context.response.matches = match;\n return route;\n }\n }\n }\n \n return false;\n }", "function dispatch() {\n var query,\n path,\n arg,\n finalRoute = 0,\n finalMatchLength = -1,\n finalRegStr = \"\",\n finalFirstCaptureGroupIndex = -1,\n finalCallback = 0,\n finalRouteName = \"\",\n pathUri = new S.Uri(getFragment()),\n finalParam = 0;\n\n path = pathUri.clone();\n path.query.reset();\n path = path.toString();\n\n // user input : /xx/yy/zz\n each(allRoutes, function (route) {\n var routeRegs = route[ROUTER_MAP],\n // match exactly\n exactlyMatch = 0;\n each(routeRegs, function (desc) {\n var reg = desc.reg,\n regStr = desc.regStr,\n paramNames = desc.paramNames,\n firstCaptureGroupIndex = -1,\n m,\n name = desc.name,\n callback = desc.callback;\n if (m = path.match(reg)) {\n // match all result item shift out\n m.shift();\n\n function genParam() {\n if (paramNames) {\n var params = {};\n each(m, function (sm, i) {\n params[paramNames[i]] = sm;\n });\n return params;\n } else {\n // if user gave directly reg\n // then call callback with match result array\n return [].concat(m);\n }\n }\n\n function upToFinal() {\n finalRegStr = regStr;\n finalFirstCaptureGroupIndex = firstCaptureGroupIndex;\n finalCallback = callback;\n finalParam = genParam();\n finalRoute = route;\n finalRouteName = name;\n finalMatchLength = m.length;\n }\n\n // route: /xx/yy/zz\n if (!m.length) {\n upToFinal();\n exactlyMatch = 1;\n return false;\n }\n else if (regStr) {\n\n firstCaptureGroupIndex = findFirstCaptureGroupIndex(regStr);\n\n // final route : /*\n // now route : /xx/*\n if (firstCaptureGroupIndex > finalFirstCaptureGroupIndex) {\n upToFinal();\n }\n\n else if (\n firstCaptureGroupIndex == finalFirstCaptureGroupIndex &&\n finalMatchLength >= m.length\n ) {\n // final route : /xx/:id/:id\n // now route : /xx/:id/zz\n if (m.length < finalMatchLength) {\n upToFinal()\n } else if (regStr.length > finalRegStr.length) {\n upToFinal();\n }\n }\n\n // first route has priority\n else if (!finalRoute) {\n upToFinal();\n }\n }\n // if exists user-given reg router rule then update value directly\n // first route has priority\n // 用户设置的正则表达式具备高优先级\n else {\n upToFinal();\n exactlyMatch = 1;\n return false;\n }\n }\n }\n );\n\n if (exactlyMatch) {\n return false;\n }\n });\n\n\n if (finalParam) {\n query = pathUri.query.get();\n finalCallback.apply(finalRoute, [finalParam, query, {\n path: path,\n url: location.href\n }]);\n arg = {\n name: finalRouteName,\n \"paths\": finalParam,\n path: path,\n url: location.href,\n query: query\n };\n finalRoute.fire('route:' + finalRouteName, arg);\n finalRoute.fire('route', arg);\n }\n }", "function getActiveRoutes(params) {\n var activeRoutes = {},\n availableRoutes =\n { 'index': 'GET /'\n , 'create': 'POST /'\n , 'new': 'GET /new'\n , 'edit': 'GET /:id/edit'\n , 'destroy': 'DELETE /:id'\n , 'update': 'PUT /:id'\n , 'show': 'GET /:id'\n },\n availableRoutesSingleton = \n { 'show': 'GET /'\n , 'create': 'POST /'\n , 'new': 'GET /new'\n , 'edit': 'GET /edit'\n , 'destroy': 'DELETE /'\n , 'update': 'PUT /'\n };\n\n if (params.singleton) {\n availableRoutes = availableRoutesSingleton;\n }\n\n var action;\n // 1. only\n if (params.only) {\n if (typeof params.only == 'string') {\n params.only = [params.only];\n }\n for (action in availableRoutes) {\n if (params.only.indexOf(action) !== -1) {\n activeRoutes[action] = availableRoutes[action];\n }\n }\n }\n // 2. except\n else if (params.except) {\n if (typeof params.except == 'string') {\n params.except = [params.except];\n }\n for (action in availableRoutes) {\n if (params.except.indexOf(action) == -1) {\n activeRoutes[action] = availableRoutes[action];\n }\n }\n }\n // 3. all\n else {\n for (action in availableRoutes) {\n activeRoutes[action] = availableRoutes[action];\n }\n }\n return activeRoutes;\n }", "_handleRoute(e) {\n this.log.logApi('_handleRoute', e);\n var _hash = location.hash.replace(/^#\\/|\\/$/gi, '/');\n var parser = document.createElement('a');\n parser.href = _hash;\n var _routeObj = null;\n var res = {};\n var req = {\n hostname: parser.hostname,\n host: parser.host,\n port: parser.port,\n protocol: parser.protocol,\n pathname: parser.pathname,\n hash: parser.hash,\n url: parser.href,\n query: parser.search,\n params: {}, //needs to be routes named params keys and value the values\n data: {} //Needs to be any other data sent along\n };\n\n req.query = this._getUrlQuery(parser.href);\n\n //Loop each regex route and match against hash, if match, invoke route handler function.\n for (var i = 0; i < this.routesRegex.length; i++) {\n _routeObj = this.routesRegex[i];\n\n //Test if route matches registered route\n if (_routeObj.regexp.test(_hash)) {\n _routeObj.current = _hash;\n\n _routeObj = this._setRouteParams(_routeObj);\n\n //setup request params / and data\n req.params = _routeObj.params;\n\n //Log\n this.log.logApi(_hash, _routeObj);\n /*\n PubSub.emit('route:success', {\n _routeObj, req, res\n });\n PubSub.emit('route:change', {\n _routeObj, req, res\n });\n */\n //Execute route handler\n this.execute(_routeObj.success, [req, res], _hash);\n } else {\n\n this.execute(_routeObj.error, [req, res], _hash);\n }\n }\n }", "parseParametedRoute(url) {\n var nBread = url.split('/');\n var matched = {};\n for (var i = 0; i < this.routes.length; i++) {\n var route = this.routes[i];\n var routePath = route.path;\n var rBread = routePath.split('/');\n if (rBread.length !== nBread.length)\n continue;\n var routeParams = {};\n matched[`${route.path}`] = true;\n for (var j = 0; j < rBread.length; j++) {\n var el = rBread[j];\n if (nBread[j] === '' && j !== 0) {\n matched[`${route.path}`] = false;\n continue;\n }\n if (el === nBread[j])\n continue;\n else {\n if (el[0] === ':') {\n routeParams[el.replace(':', '')] = nBread[j];\n continue;\n }\n else {\n matched[`${route.path}`] = false;\n }\n }\n }\n }\n let keys = Object.keys(matched).filter((key) => matched[key] === true);\n if (!keys.length)\n throw Error(\"Couldn't find matching path\");\n else {\n let idx = this.routes.findIndex((r) => r.path === keys[0]);\n this.currentRoute['params'] = routeParams;\n return idx;\n }\n }", "get(url) {\n url = url.trimAll(\"/\");\n // Fast Access Controller (full match)\n let fast_acs_controller = this.router[url];\n if (fast_acs_controller != null)\n return this.app.createComponent(fast_acs_controller, Object.assign({}, this.app.config, {\"request\": {}}));\n\n // Searching for best option:\n var best_controller = null;\n var best_controller_request = {};\n var best_controller_placeholders = 1000;\n for (var routePattern in this.router) {\n if (this.isMatch(url, routePattern)) {\n var phCount = routePattern.match(/<(.+?)>/g).length;\n if (phCount < best_controller_placeholders) {\n best_controller = this.router[routePattern];\n best_controller_request = this.extractParameters(url, routePattern);\n best_controller_placeholders = phCount;\n // Match found with minimum amount of placeholders - no need to keep looking...\n if (phCount == 1) break;\n }\n }\n };\n if (best_controller) {\n return this.app.createComponent(best_controller, Object.assign({}, this.app.config, {\"request\": best_controller_request}));\n }\n throw new Error(\"404 NotFound\")\n }", "function dinamicRoutes() {\n var otherRoutes = routes.filter(function (item) { return item.path.includes(':'); });\n var getRouteCurrent = location.pathname.split('/');\n var request = {};\n otherRoutes.map(function (route) { return request = getRouteCurrent[1] == (route.path.split('/'))[1] ? { 'status': true, 'route': route } : { 'status': false }; });\n return request;\n}", "function dinamicRoutes() {\n var otherRoutes = routes.filter(function (item) { return item.path.includes(':'); });\n var getRouteCurrent = location.pathname.split('/');\n var request = {};\n otherRoutes.map(function (route) { return request = getRouteCurrent[1] == (route.path.split('/'))[1] ? { 'status': true, 'route': route } : { 'status': false }; });\n return request;\n}", "function initPath(req){\n let path = url.parse(req.url).pathname;\n let reg = /(\\/\\w+?){2,}/;\n if(reg.test(path)){\n let pathParam = path.split('/');\n let controller = pathParam[1] || 'index';\n let action = pathParam[2] || 'index';\n let param = pathParam.slice(3);\n\n return {controller, action, param}\n }else{\n //todo error: the path not correct\n } \n}", "url(action,i18n,payload,params,hash){\n if (this.data.url){\n return this.data.url.call(this, action, i18n,payload,params);\n } else {\n let route_path = i18n.t(this.key);\n return `/${i18n.language}/${route_path}`;\n }\n }", "function getRouteParams(route, params) { // 11\n var routeParams = {}; // 12\n // 13\n if (!route.path) return routeParams; // 14\n // 15\n var paramNames = _PatternUtils.getParamNames(route.path); // 16\n // 17\n for (var p in params) { // 18\n if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n }return routeParams; // 20\n} // 21", "get routes(){\n\t\treturn {\n\t\t\t'get /': [actionFilter, 'index'],\n\t\t\t'get /home/about': 'about'\n\t\t}\n\t}", "function getRouteValuesFromUrl(e) {\n\n //Prevent from running twice\n if (e.routeMatched != undefined) return e.routeMatched;\n\n //Ensure values is initialized\n e.values = (e.values || {});\n\n //Locals\n var url = go.trimChars(e.url, \"/\"),\n routes = _config.routes,\n length = routes.length;\n\n //Query string\n if (/\\?/.test(url)) {\n\n //Split string from path\n var parts = url.split(\"?\");\n params = parts[1].split(\"&\");\n\n //Reassign URL path\n url = go.trimChars(parts[0], \"/\");\n\n //Add params to e.values\n for (var i = 0; i < params.length; i++) {\n var pair = params[i].split(\"=\");\n e.values[decodeURIComponent(pair[0])] = decodeURIComponent(pair[1]);\n }\n\n }\n\n //Convert empty path to default \"/\"\n url = url || \"/\"\n\n //Exit on empty arguments\n if (!url || !routes) return;\n\n //Check each route, take first match\n for (var i = 0; i < length; i++) {\n\n //Locals\n var routeObj = routes[i],\n route = go.trimChars(routeObj.route, \"/\") || \"/\",\n require = routeObj.require,\n defaults = routeObj.defaults,\n paramRegex = /{[\\w\\d_]+}/ig,\n routeRegex = new RegExp(\"^\" + route.replace(paramRegex, \"([^\\\\/]+)\") + \"$\", \"i\"),\n vals = e.values;\n\n //Check URL with regex\n if (routeRegex.test(url)) {\n\n //Add require to event only if it doesn't exist\n if (!e.require && require) e.require = require;\n\n //Merge values with defaults\n vals = extend(vals, defaults);\n\n //Get param names\n var paramNames = route.match(paramRegex);\n\n //Route might not contain any params\n if (paramNames) {\n\n //Remove curly brackets from names\n go.trimChars(paramNames, \"{}\");\n\n //Get param values\n //Skip first item in array, Only take param matches\n var paramValues = url.match(routeRegex).slice(1);\n for (var i = 0; i < paramNames.length; i++) {\n vals[paramNames[i]] = paramValues[i];\n }\n\n }\n\n //Success, Route has been matched\n //Return true only if controller and action found\n if (vals.controller && vals.action) {\n e.routeMatched = true;\n e.route = route;\n return true;\n }\n }\n }\n\n //No matching route found\n e.routeMatched = false;\n return false;\n }", "get_view() {\n var path = window.location.pathname.split(\"/\").pop();\n if (path.indexOf(\".\") > -1) {\n return path.split(\".\").slice(0, -1).join(\".\");\n } else if (path == \"\") {\n return \"index\";\n } else {\n return path;\n }\n }", "findRoute(ctx) {\n const url = ctx.request.url();\n const method = ctx.request.method();\n const hostname = ctx.request.hostname();\n /*\n * Profiling `route.match` method\n */\n const matchRoute = ctx.profiler.profile('http:route:match');\n const route = this.router.match(url, method, hostname || undefined);\n matchRoute.end();\n /*\n * Raise error when route is missing\n */\n if (!route) {\n throw new utils_1.Exception(`Cannot ${method}:${url}`, 404, 'E_ROUTE_NOT_FOUND');\n }\n /*\n * Attach `params`, `subdomains` and `route` when route is found. This\n * information only exists on a given route\n */\n ctx.params = route.params;\n ctx.subdomains = route.subdomains;\n ctx.route = route.route;\n ctx.routeKey = route.routeKey;\n }", "function getURL(route, paramArray){\n\tif(route === myApp.route) {\n\t\tconsole.log(\"== page already routed '\"+ route +\"' ==\");\n\t\treturn false;\n\t}\n\n // client-side routing handled using page.js\n\tvar path = '/'+route;\n\tif(paramArray && paramArray.length>0) {\n\t\tfor(var i=0; i<paramArray.length; i++) {\n\t\t\tpath = path + '/' + paramArray[i]; // eg. '/editor/1'\n\t\t}\n\t}\n\n\tconsole.log(\"=> getURL route: \" + route);\n\tpage(path);\n}", "function getRouteParams(route, params) {\r\n\t var routeParams = {};\r\n\t\r\n\t if (!route.path) return routeParams;\r\n\t\r\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\r\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\r\n\t routeParams[p] = params[p];\r\n\t }\r\n\t });\r\n\t\r\n\t return routeParams;\r\n\t}", "_getParams(route) {\n var matches = route.match(/:\\w+/g)\n return (matches || []).map(match => {\n return match.substring(1, match.length)\n })\n }", "function url(platform, controller, action)\n{\n return location.protocol + '//' + location.host + location.pathname + '?p=' + platform + '&c=' + controller + '&a=' + action;\n}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t var paramNames = (0, _URLUtils.getParamNames)(route.path);\n\n\t for (var p in params) if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n\n\t return routeParams;\n\t}", "stringifyRoute(route) {\n return Router.objectToRouteString(route)\n }", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t var paramNames = _PatternUtils.getParamNames(route.path);\n\t\n\t for (var p in params) {\n\t if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n\t }return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t var paramNames = _PatternUtils.getParamNames(route.path);\n\t\n\t for (var p in params) {\n\t if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n\t }return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t var paramNames = _PatternUtils.getParamNames(route.path);\n\t\n\t for (var p in params) {\n\t if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n\t }return routeParams;\n\t}", "function path (route) {\n const model = getIn(route, ['model', 'coll'])\n const tags = route.tags || [model]\n const summary = route.summary\n return compact({\n tags,\n summary,\n 'x-model': model,\n 'x-handler': route.handler.name,\n parameters: parameters(route),\n requestBody: requestBody(route.requestSchema),\n responses: responses(route)\n })\n}", "function getRouteInfo() {\n var result = {\n isIndexPage: false,\n isCountryPage: false,\n isCountryDetailsPage: false,\n countryCode: null\n };\n\n var parts = url.parse(window.location.href, true);\n if (_.isObject(parts)) {\n result.isIndexPage = (parts.pathname == '/index.html') ||\n (parts.pathname == '/') || (parts.pathname == '');\n result.isCountryPage = parts.pathname == '/country.html';\n result.isCountryDetailsPage = parts.pathname == '/country-details.html';\n\n if (_.isObject(parts.query)) {\n result.countryCode = parts.query.country || null;\n }\n }\n\n return result;\n}", "function resolveRoute(context) {\n if (isFunction(context.route.action)) {\n return context.route.action(context);\n }\n return undefined;\n}", "function resolveRoute(context) {\n if (isFunction(context.route.action)) {\n return context.route.action(context);\n }\n return undefined;\n}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t var paramNames = (0, _PatternUtils.getParamNames)(route.path);\n\t\n\t for (var p in params) {\n\t if (Object.prototype.hasOwnProperty.call(params, p) && paramNames.indexOf(p) !== -1) {\n\t routeParams[p] = params[p];\n\t }\n\t }\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\t\n\t if (!route.path) return routeParams;\n\t\n\t var paramNames = (0, _PatternUtils.getParamNames)(route.path);\n\t\n\t for (var p in params) {\n\t if (Object.prototype.hasOwnProperty.call(params, p) && paramNames.indexOf(p) !== -1) {\n\t routeParams[p] = params[p];\n\t }\n\t }\n\t\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t (0, _PatternUtils.getParamNames)(route.path).forEach(function (p) {\n\t if (Object.prototype.hasOwnProperty.call(params, p)) {\n\t routeParams[p] = params[p];\n\t }\n\t });\n\n\t return routeParams;\n\t}", "function descriptor(route) {\n\t return {\n\t name: route.name,\n\t path: route.path,\n\t params: (0, _dash.pick)(params, _path2['default'].extractParamNames(route.path)),\n\t options: (0, _dash.clone)(route.options)\n\t };\n\t }", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t var paramNames = _PatternUtils.getParamNames(route.path);\n\n\t for (var p in params) {\n\t if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n\t }return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t var paramNames = _PatternUtils.getParamNames(route.path);\n\n\t for (var p in params) {\n\t if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n\t }return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t var paramNames = _PatternUtils.getParamNames(route.path);\n\n\t for (var p in params) {\n\t if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n\t }return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t var paramNames = _PatternUtils.getParamNames(route.path);\n\n\t for (var p in params) {\n\t if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n\t }return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t var paramNames = _PatternUtils.getParamNames(route.path);\n\n\t for (var p in params) {\n\t if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n\t }return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t var paramNames = _PatternUtils.getParamNames(route.path);\n\n\t for (var p in params) {\n\t if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n\t }return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t var paramNames = _PatternUtils.getParamNames(route.path);\n\n\t for (var p in params) {\n\t if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n\t }return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t var paramNames = (0, _PatternUtils.getParamNames)(route.path);\n\n\t for (var p in params) {\n\t if (Object.prototype.hasOwnProperty.call(params, p) && paramNames.indexOf(p) !== -1) {\n\t routeParams[p] = params[p];\n\t }\n\t }\n\n\t return routeParams;\n\t}", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t var paramNames = (0, _PatternUtils.getParamNames)(route.path);\n\n\t for (var p in params) {\n\t if (Object.prototype.hasOwnProperty.call(params, p) && paramNames.indexOf(p) !== -1) {\n\t routeParams[p] = params[p];\n\t }\n\t }\n\n\t return routeParams;\n\t}", "route(key, defaultValue = null) {\n return this.request.params[key] || defaultValue;\n }", "function getRouteParams(route, params) {\n\t var routeParams = {};\n\n\t if (!route.path) return routeParams;\n\n\t var paramNames = _PatternUtils.getParamNames(route.path);\n\n\t for (var p in params) {\n\t if (Object.prototype.hasOwnProperty.call(params, p) && paramNames.indexOf(p) !== -1) {\n\t routeParams[p] = params[p];\n\t }\n\t }\n\n\t return routeParams;\n\t}", "function Router() {\n return {\n /**\n * navigateToCart - navigate to cart in checkout\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n navigateToCart : function(info) {\n info = _.extend({\n route : 'cart'\n }, info);\n return handleAppRoute(info);\n },\n\n /**\n * navigateToCustomer - navigate to customer views\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n navigateToCustomer : function(info) {\n info = _.extend({\n route : 'customer'\n }, info);\n return handleAppRoute(info);\n },\n\n /**\n * navigateToCustomerSearchResult - navigate to customer search results\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n navigateToCustomerSearchResult : function(info) {\n info = _.extend({\n route : 'customer_search_result'\n }, info);\n return handleAppRoute(info);\n },\n\n /**\n * customerLogout - log out a customer\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n customerLogout : function(info) {\n info = _.extend({\n route : 'customer_logout'\n }, info);\n return handleAppRoute(info);\n },\n\n /**\n * presentChangeStorePasswordDrawer - change the store password\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n presentChangeStorePasswordDrawer : function(info) {\n info = _.extend({\n route : 'change_store_password'\n }, info);\n return handleAppRoute(info);\n },\n\n /**\n * navigateToHome - navigate to Home\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n navigateToHome : function(info) {\n info = _.extend({\n route : 'home'\n }, info);\n\n return handleAppRoute(info);\n },\n\n /**\n * navigateToCategory - navigate to category\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n navigateToCategory : function(info) {\n info = _.extend({\n route : 'product_search_result',\n query : ''\n }, info);\n\n return handleAppRoute(info);\n },\n\n /**\n * navigateToProduct - navigate to a product (PDP)\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n navigateToProduct : function(info) {\n info = _.extend({\n route : 'product_detail'\n }, info);\n\n return handleAppRoute(info);\n },\n\n /**\n * navigateToProductSearch - navigate to product search results\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n navigateToProductSearch : function(info) {\n info = _.extend({\n route : 'product_search_result'\n }, info);\n\n return handleAppRoute(info);\n },\n\n /**\n * navigateToOrderSearchResult - navigate to order search results\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n navigateToOrderSearchResult : function(info) {\n info = _.extend({\n route : 'order_search_result'\n }, info);\n\n return handleAppRoute(info);\n },\n\n /**\n * presentAssociateLogin - present associate login\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n presentAssociateLogin : function(info) {\n info = _.extend({\n route : 'associate_login'\n }, info);\n return handleAppRoute(info);\n },\n\n /**\n * presentCustomerSearchDrawer - present customer search dialog\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n presentCustomerSearchDrawer : function(info) {\n info = _.extend({\n route : 'customer_search'\n }, info);\n return handleAppRoute(info);\n },\n\n /**\n * presentOrderSearchDrawer - present order search dialog\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n presentOrderSearchDrawer : function(info) {\n info = _.extend({\n route : 'order_search'\n }, info);\n return handleAppRoute(info);\n },\n\n /**\n * presentProductSearchDrawer - present product search dialog\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n presentProductSearchDrawer : function(info) {\n info = _.extend({\n route : 'product_search'\n }, info);\n return handleAppRoute(info);\n },\n\n /**\n * presentPrinterChooserDrawer - present printer chooser dialog\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n presentPrinterChooserDrawer : function(info) {\n info = _.extend({\n route : 'printer_chooser'\n }, info);\n return handleAppRoute(info);\n },\n\n /**\n * associateLogout - perform associate logout\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n associateLogout : function(info) {\n info = _.extend({\n route : 'associate_logout'\n }, info);\n return handleAppRoute(info);\n },\n\n /**\n * presentCreateAccountDrawer - present create account dialog\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n presentCreateAccountDrawer : function(info) {\n info = _.extend({\n route : 'create_account'\n }, info);\n return handleAppRoute(info);\n },\n\n /**\n * checkPaymentDevice - check status of payment device\n *\n * @param {Boolean} verified - if verified\n * @return {Deferred} promise\n * @api public\n */\n checkPaymentDevice : function(verified) {\n return checkPaymentDevice(verified);\n },\n\n /**\n * paymentDeviceConnectionChecked - update device status\n *\n * @param {Boolean} connected - if connected\n * @api public\n */\n paymentDeviceConnectionChecked : function(connected) {\n if (connected != paymentDeviceConnected) {\n paymentDeviceConnected = connected;\n $.header.updateDeviceStatus(false, connected);\n if ($.no_payment_terminal) {\n $.no_payment_terminal.updateDeviceStatus(connected);\n }\n }\n },\n\n /**\n * startup - restart the application\n *\n * @api public\n */\n startup : function() {\n Alloy.eventDispatcher.trigger('app:startup', {\n login : true\n });\n },\n\n /**\n * showActivityIndicator - shows activity indicator until deferred is complete\n *\n * @param {Deferred} deferred\n * @api public\n */\n showActivityIndicator : function(deferred) {\n showActivityIndicator(deferred);\n },\n\n /**\n * showHideHamburgerMenu - show the hamburger menu popover\n *\n * @api public\n */\n showHideHamburgerMenu : function() {\n $.hamburger_menu.showHideHamburgerMenu();\n },\n\n /**\n * hideHamburgerMenu - hide the hamburger menu popover\n *\n * @api public\n */\n hideHamburgerMenu : function() {\n $.hamburger_menu.hideHamburgerMenu();\n },\n\n /**\n * navigate - dynamic routing based on info passed in\n *\n * @param {Object} info - optional info\n * @return {Deferred} promise\n * @api public\n */\n navigate : function(info) {\n // for dynamic routing\n return handleAppRoute(info);\n }\n };\n}", "function updateRoute() {\n\tlet route = window.location.hash.substr(1);\n\tSTORE.dispatch({ type: \"routing\", route });\n}", "function AboutRoute(db) {\n //var ctrl = new AboutCtrl(db);\n \n return [\n {\n method: 'GET',\n path: '/',\n handler: (request, h) => {\n \n return 'Hello, world!';\n }\n },\n {\n method: 'GET',\n path: '/{name}',\n handler: (request, h) => {\n \n return 'Hello, ' + encodeURIComponent(request.params.name) + '!';\n }\n }\n ];\n}", "parseHash() {\n if (window.location.hash.indexOf('#') === -1) {\n this.push('/');\n }\n let hash = window.location.hash.replace('#', '');\n var routeArray = hash.split('?');\n var routeInfo;\n var routeInfo = {\n fullPath: routeArray[0],\n route: routeArray[0].split('/'),\n query: {}\n };\n if (routeArray[1]) {\n var routeQuery = routeArray[1].split('&');\n routeQuery.forEach((param) => {\n let keyValue = param.split('=');\n routeInfo.query[keyValue[0]] = keyValue[1];\n });\n }\n var fromPath;\n if (this.currentRoute)\n fromPath = this.currentRoute;\n else\n fromPath = null;\n if (this.transition !== null) {\n this.transitionOut();\n }\n setTimeout(function () {\n this.beforeEachRoute(this.beforeEach, routeInfo, fromPath).then(function (r) {\n this.currentRoute = routeInfo;\n this.compareRoutes();\n if (this.afterEach)\n this.afterEach(routeInfo, fromPath);\n if (this.transition !== null) {\n this.transitionIn();\n }\n }.bind(this));\n }.bind(this), this.transitionDuration.leavingDuration + 10);\n }", "function createRouteString( modelName )\n{\n return BASE_URL + modelName;\n}", "function resolveRoute(context) {\n if (isFunction$1(context.route.action)) {\n return context.route.action(context);\n }\n return undefined;\n }", "function use_route(r_name, params2) {\n if (dr[r_name]) {\n const data = {}, path = dr[r_name].path, params1 = dr[r_name].params;\n params1.forEach(param => data[param] = db[path][param]);\n params2.forEach(param => data[param] = db[path][param]);\n return data\n }\n else return undefined\n }", "function getRoute(start,target) {\n\tapi({ data: \"cmd=getroute&start=\"+start+\"&target=\"+target, type: \"block\" },selectRoute);\n}", "init(){\n this.routes.forEach((route)=>{\n this._proccessRegExp(route);\n }, this);\n\n let found = false;\n let routerObj = {\n pathFor: (name, parameter)=>{\n return this._pathFor(name, parameter);\n },\n\n goTo: (url, data, title)=>{\n return this._goTo(url, data, title);\n },\n\n historyMode: this._historyMode\n };\n this.routes.some((route)=>{\n if(this._requestPath().match(route.regExp)) {\n route.current = true;\n found = true;\n\n let request = {};\n request.param = this._processRequestParameters(route);\n request.query = this.query;\n request.uri = window.location.pathname;\n\n return route.callback.call(route.thisArg, request, routerObj);\n }\n },this)\n\n if(!found){\n if(!this._notFoundFunction) return;\n let request = {};\n request.uri = window.location.pathname;\n return this._notFoundFunction(request, routerObj);\n }\n }", "function getRouteParams(route, params) {\n var routeParams = {};\n\n if (!route.path) return routeParams;\n\n var paramNames = _PatternUtils.getParamNames(route.path);\n\n for (var p in params) {\n if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n }return routeParams;\n}", "function getRouteParams(route, params) {\n var routeParams = {};\n\n if (!route.path) return routeParams;\n\n var paramNames = _PatternUtils.getParamNames(route.path);\n\n for (var p in params) {\n if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n }return routeParams;\n}", "function getRouteParams(route, params) {\n var routeParams = {};\n\n if (!route.path) return routeParams;\n\n var paramNames = _PatternUtils.getParamNames(route.path);\n\n for (var p in params) {\n if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n }return routeParams;\n}", "function getRouteParams(route, params) {\n var routeParams = {};\n\n if (!route.path) return routeParams;\n\n var paramNames = _PatternUtils.getParamNames(route.path);\n\n for (var p in params) {\n if (params.hasOwnProperty(p) && paramNames.indexOf(p) !== -1) routeParams[p] = params[p];\n }return routeParams;\n}" ]
[ "0.69673014", "0.65067947", "0.6253531", "0.6098924", "0.6054433", "0.5961769", "0.5955426", "0.59383893", "0.59383893", "0.59383893", "0.5920788", "0.5877686", "0.5872621", "0.5826042", "0.5781528", "0.5694709", "0.5683778", "0.56832606", "0.5681354", "0.56583095", "0.56404155", "0.5638172", "0.5623233", "0.5615085", "0.5615085", "0.56007177", "0.5594657", "0.5589498", "0.556135", "0.5534653", "0.5489114", "0.5488511", "0.54712313", "0.5457294", "0.5430623", "0.54259694", "0.5410805", "0.5410805", "0.5410805", "0.5410805", "0.5410805", "0.5410805", "0.5410805", "0.5410805", "0.5410805", "0.5410805", "0.5410805", "0.5410805", "0.5410805", "0.5410805", "0.53981656", "0.5388772", "0.5379532", "0.5379532", "0.5379532", "0.5377928", "0.5367803", "0.5362237", "0.5362237", "0.53549844", "0.53549844", "0.53371143", "0.53371143", "0.53371143", "0.53371143", "0.53371143", "0.53371143", "0.53371143", "0.53371143", "0.53371143", "0.53371143", "0.53371143", "0.53371143", "0.53371143", "0.53371143", "0.53297216", "0.5318656", "0.5318656", "0.5318656", "0.5318656", "0.5318656", "0.5318656", "0.5318656", "0.52897257", "0.52897257", "0.5281663", "0.5279795", "0.52720284", "0.5269898", "0.5266623", "0.52664983", "0.5265521", "0.52596736", "0.52581894", "0.5256981", "0.5249044", "0.5243937", "0.5243937", "0.5243937", "0.5243937" ]
0.6940775
1
helper function to format string
function format() { var format = arguments[0] || ""; var match = format.match(/%s|%d|%j/g); if (!match) return format; if (match.length != arguments.length - 1) throw { name: "Argument Error", message: "Number of arguments mismatch" }; for (var i = 1; i < arguments.length; i++) { var matchIndex = i - 1; var value = (match[matchIndex] == "%j") ? JSON.stringify(arguments[i]) : arguments[i]; format = format.replace(match[matchIndex], value); } return format; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function Format() {}", "function Format() {}", "function formatString(arg) {\n var response = arg;\n response = response.replace(/\\//g, \"_\");\n response = response.replace(/\\+/g, \"-\");\n response = response.replace(/=+$/, '');;\n return response;\n}", "format (formatString = '%s%y%j%p%n') {\n let str = formatString\n\n str = str.replace(/%s/g, this.sign)\n str = str.replace(/%c/g, this.currency)\n str = str.replace(/%y/g, this.symbol)\n\n str = str.replace(/%\\+/g, this.signIfPositive)\n str = str.replace(/%-/g, this.signIfNegative)\n\n str = str.replace(/%r/g, this.raw)\n str = str.replace(/%a/g, this.amount)\n\n str = str.replace(/%j/g, this.major)\n str = str.replace(/%n/g, this.minor)\n str = str.replace(/%p/g, this.separator)\n\n return str\n }", "function formatString(format) {\n var ars = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n ars[_i - 1] = arguments[_i];\n }\n var s = format;\n for (var i = 0; i < ars.length; i++) {\n s = s.replace(new RegExp(\"\\\\{\" + i + \"\\\\}\", \"gm\"), ars[i]);\n }\n return s;\n }", "function format() {\n // The string containing the format items (e.g. \"{0}\")\n // will and always has to be the first argument.\n var string = arguments[0];\n // Start with the second argument (i = 1)\n for (var i = 1; i < arguments.length; i++) {\n // \"gm\" = RegEx options for Global search (more than one instance)\n // and for Multiline search.\n var regEx = new RegExp(\"\\\\{\" + (i - 1) + \"\\\\}\", \"gm\");\n string = string.replace(regEx, arguments[i]);\n }\n\n return string;\n }", "function format() {\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments[_i];\n }\n var a = args[0];\n var b = [];\n for (var c = 1, len = args.length; c < len; c += 1) {\n b.push(args[c]);\n }\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n return a;\n }", "function _fmt(str, formats) {\n // first, replace any ORDERED replacements.\n var idx = 0; // the current index for non-numerical replacements\n\n return str.replace(/%@([0-9]+)?/g, function (_s, argIndex) {\n var i = argIndex ? parseInt(argIndex, 10) - 1 : idx++;\n var r = i < formats.length ? formats[i] : undefined;\n return typeof r === 'string' ? r : r === null ? '(null)' : r === undefined ? '' : String(r);\n });\n }", "function format(a, b, c) {\n// the result string must give: \"Their names were: a, b and c.\"\n const template = `Their names were: ${a}, ${b} and ${c}.` //This is using backticks NOT single quotes.\n return template\n }", "function formatstr(str) {\n y = str.substr(0, 4);\n m = str.substr(4, 2);\n d = str.substr(6, 2);\n return d + '-' + m + '-' + y;\n}", "function stringFormat(str){\n var selfArguments = arguments,\n i,\n j;\n outputStr = selfArguments[0];\n if (selfArguments.length > 1) {\n for (var i = 1; i < selfArguments.length; i += 1) {\n for (var j = 0; j < outputStr.length; j+=1) {\n outputStr = outputStr.replace('{' + (i - 1) + '}', selfArguments[i]);\n }\n }\n }\n return outputStr;\n }", "function format(text) {\n var args = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n args[_i - 1] = arguments[_i];\n }\n return text.replace(/\\{+-?[0-9]+(:[^}]+)?\\}+/g, function (tag) {\n var match = tag.match(/(\\{+)(-?[0-9]+)(:([^\\}]+))?(\\}+)/), index = parseInt(match[2], 10), value = args[index];\n if (match[1].length > 1 && match[5].length > 1) {\n return \"{\" + index + (match[3] || \"\") + \"}\";\n }\n if (typeof value === \"undefined\") {\n value = \"\";\n }\n if (match[3]) {\n switch (match[4]) {\n case \"U\":\n return value.toString().toUpperCase();\n case \"u\":\n return value.toString().toLowerCase();\n default:\n if (window.Globalize) {\n return Globalize.format(value, match[4]);\n }\n break;\n }\n }\n return value;\n });\n }", "static format(format, ...args) {\n args.forEach(arg => {\n format = format.replace('##', arg);\n });\n return format;\n }", "function makeFMT(name) {\n return name + \" \" + name + \".\";\n }", "static format (stringDefinition = '') {\n // Test to \n\n let combinatorLiteralFormat = /(\\|\\||\\||&&|\\[|\\]|,(?=[^{}]*(?:{|$))|\\/|<[^>]*>)/g\n let multiplyerFormat = /\\s*(\\*|\\+|\\?|\\{[^\\}]*\\}|\\#|\\!)/g;\n return stringDefinition.replace(combinatorLiteralFormat, ' $1 ')\n .replace(multiplyerFormat, '$1 ').replace(/\\s+/g, ' ').trim();\n }", "function format() {\n\t for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n\t args[_key] = arguments[_key];\n\t }\n\n\t var a = args[0];\n\t var b = [];\n\t var c;\n\n\t for (c = 1; c < args.length; c += 1) {\n\t b.push(args[c]);\n\t }\n\n\t b.forEach(function (d) {\n\t a = a.replace(/%[a-z]/, d);\n\t });\n\t return a;\n\t}", "function StringFormat()\r\n {\r\n var args = Array.prototype.slice.call(arguments, 0),\r\n string = args.shift();\r\n\r\n for(var i=0; i<args.length; i++)\r\n {\r\n string = string.replace( new RegExp('\\\\{'+i+'\\\\}','g'), args[i]);\r\n }\r\n\r\n return string;\r\n }", "function format(fmt) {\n var fn = formatter(fmt);\n var str = fn.apply(null, Array.prototype.slice.call(arguments, 1));\n return str;\n }", "function formatstring(str){\n\treturn str.replace(/ /g,\"_\");\n}", "function doSprintf() {\n\t var fstring = formatting.toString();\n\n\t var pad = function(str,ch,len) { var ps='';\n\t for(var i=0; i<Math.abs(len); i++) {\n\t\t\t ps+=ch;\n\t\t }\n\t return len>0?str+ps:ps+str;\n\t };\n\t var processFlags = function(flags,width,rs,arg) { \n\t var pn = function(flags,arg,rs) {\n\t if(arg>=0) { \n\t if(flags.indexOf(' ')>=0) {\n\t\t\t\t\t rs = ' ' + rs;\n\t\t\t\t } else if(flags.indexOf('+')>=0) {\n\t\t\t\t\t rs = '+' + rs;\n\t\t\t\t }\n\t } else {\n\t rs = '-' + rs;\n\t\t\t }\n\t return rs;\n\t };\n\t var iWidth = parseInt(width,10);\n\t if(width.charAt(0) == '0') {\n\t var ec=0;\n\t if(flags.indexOf(' ')>=0 || flags.indexOf('+')>=0) {\n\t\t\t\t ec++;\n\t\t\t }\n\t if(rs.length<(iWidth-ec)) {\n\t\t\t\t rs = pad(rs,'0',rs.length-(iWidth-ec));\n\t\t\t }\n\t return pn(flags,arg,rs);\n\t }\n\t rs = pn(flags,arg,rs);\n\t if(rs.length<iWidth) {\n\t if(flags.indexOf('-')<0) {\n\t\t\t\t rs = pad(rs,' ',rs.length-iWidth);\n\t\t\t } else {\n\t\t\t\t rs = pad(rs,' ',iWidth - rs.length);\n\t\t\t }\n\t } \n\t return rs;\n\t };\n\t var converters = [];\n\t converters.c = function(flags,width,precision,arg) { \n\t if (typeof(arg) == 'number') {\n\t\t\t return String.fromCharCode(arg);\n\t\t } else if (typeof(arg) == 'string') {\n\t\t\t return arg.charAt(0);\n\t\t } else {\n\t\t\t return '';\n\t\t }\n\t };\n\t converters.d = function(flags,width,precision,arg) { \n\t return converters.i(flags,width,precision,arg); \n\t };\n\t converters.u = function(flags,width,precision,arg) { \n\t return converters.i(flags,width,precision,Math.abs(arg)); \n\t };\n\t converters.i = function(flags,width,precision,arg) {\n\t var iPrecision=parseInt(precision, 10);\n\t var rs = ((Math.abs(arg)).toString().split('.'))[0];\n\t if(rs.length<iPrecision) {\n\t\t\t rs=pad(rs,' ',iPrecision - rs.length);\n\t\t }\n\t return processFlags(flags,width,rs,arg); \n\t };\n\t converters.E = function(flags,width,precision,arg) {\n\t return (converters.e(flags,width,precision,arg)).toUpperCase();\n\t };\n\t converters.e = function(flags,width,precision,arg) {\n\t iPrecision = parseInt(precision, 10);\n\t if(isNaN(iPrecision)) {\n\t\t\t iPrecision = 6;\n\t\t }\n\t rs = (Math.abs(arg)).toExponential(iPrecision);\n\t if(rs.indexOf('.')<0 && flags.indexOf('#')>=0) {\n\t\t\t rs = rs.replace(/^(.*)(e.*)$/,'$1.$2');\n\t\t }\n\t return processFlags(flags,width,rs,arg); \n\t };\n\t converters.f = function(flags,width,precision,arg) { \n\t iPrecision = parseInt(precision, 10);\n\t if(isNaN(iPrecision)) {\n\t\t\t iPrecision = 6;\n\t\t }\n\t rs = (Math.abs(arg)).toFixed(iPrecision);\n\t if(rs.indexOf('.')<0 && flags.indexOf('#')>=0) {\n\t\t\t rs = rs + '.';\n\t\t }\n\t return processFlags(flags,width,rs,arg);\n\t };\n\t converters.G = function(flags,width,precision,arg) { \n\t return (converters.g(flags,width,precision,arg)).toUpperCase();\n\t };\n\t converters.g = function(flags,width,precision,arg) {\n\t iPrecision = parseInt(precision, 10);\n\t absArg = Math.abs(arg);\n\t rse = absArg.toExponential();\n\t rsf = absArg.toFixed(6);\n\t if(!isNaN(iPrecision)) { \n\t rsep = absArg.toExponential(iPrecision);\n\t rse = rsep.length < rse.length ? rsep : rse;\n\t rsfp = absArg.toFixed(iPrecision);\n\t rsf = rsfp.length < rsf.length ? rsfp : rsf;\n\t }\n\t if(rse.indexOf('.')<0 && flags.indexOf('#')>=0) {\n\t\t\t rse = rse.replace(/^(.*)(e.*)$/,'$1.$2');\n\t\t }\n\t if(rsf.indexOf('.')<0 && flags.indexOf('#')>=0) {\n\t\t\t rsf = rsf + '.';\n\t\t }\n\t rs = rse.length<rsf.length ? rse : rsf;\n\t return processFlags(flags,width,rs,arg); \n\t }; \n\t converters.o = function(flags,width,precision,arg) { \n\t var iPrecision=parseInt(precision, 10);\n\t var rs = Math.round(Math.abs(arg)).toString(8);\n\t if(rs.length<iPrecision) {\n\t\t\t rs=pad(rs,' ',iPrecision - rs.length);\n\t\t }\n\t if(flags.indexOf('#')>=0) {\n\t\t\t rs='0'+rs;\n\t\t }\n\t return processFlags(flags,width,rs,arg); \n\t };\n\t converters.X = function(flags,width,precision,arg) { \n\t return (converters.x(flags,width,precision,arg)).toUpperCase();\n\t };\n\t converters.x = function(flags,width,precision,arg) { \n\t var iPrecision=parseInt(precision, 10);\n\t arg = Math.abs(arg);\n\t var rs = Math.round(arg).toString(16);\n\t if(rs.length<iPrecision) {\n\t\t\t rs=pad(rs,' ',iPrecision - rs.length);\n\t\t }\n\t if(flags.indexOf('#')>=0) {\n\t\t\t rs='0x'+rs;\n\t\t }\n\t return processFlags(flags,width,rs,arg); \n\t };\n\t converters.s = function(flags,width,precision,arg) { \n\t var iPrecision=parseInt(precision, 10);\n\t var rs = arg;\n\t if(rs.length > iPrecision) {\n\t\t\t rs = rs.substring(0,iPrecision);\n\t\t }\n\t return processFlags(flags,width,rs,0);\n\t };\n\n\t farr = fstring.split('%');\n\t retstr = farr[0];\n\t fpRE = /^([-+ #]*)(?:(\\d*)\\$|)(\\d*)\\.?(\\d*)([cdieEfFgGosuxX])(.*)$/;\n\t for(var i = 1; i<farr.length; i++) { \n\t fps=fpRE.exec(farr[i]);\n\t if(!fps) {\n\t\t\t continue;\n\t\t }\n\t\t var my_i = fps[2] ? fps[2] : i;\n\t if(arguments[my_i-1]!= \"undefined\") {\n\t retstr+=converters[fps[5]](fps[1],fps[3],fps[4],arguments[my_i-1]);\n\t }\n\t retstr += fps[6];\n\t }\n\t return retstr;\n\t}", "function format() {\n for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n var a = args[0];\n var b = [];\n var c = void 0;\n\n for (c = 1; c < args.length; c += 1) {\n b.push(args[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n var a = args[0];\n var b = [];\n var c = void 0;\n\n for (c = 1; c < args.length; c += 1) {\n b.push(args[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n var a = args[0];\n var b = [];\n var c = void 0;\n\n for (c = 1; c < args.length; c += 1) {\n b.push(args[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n var a = args[0];\n var b = [];\n var c = void 0;\n\n for (c = 1; c < args.length; c += 1) {\n b.push(args[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n var a = args[0];\n var b = [];\n var c;\n\n for (c = 1; c < args.length; c += 1) {\n b.push(args[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n return a;\n}", "function formatString(text)\r\n{\r\n\tvar result = text;\r\n\tfor (var i = 1; i < arguments.length; i++)\r\n\t{\r\n\t\tvar pattern = \"{\" + (i - 1) + \"}\";\r\n\t\twhile (result.indexOf(pattern) >= 0)\r\n\t\t{\r\n\t\t\tresult = result.replace(pattern, arguments[i]);\r\n\t\t}\r\n\t}\r\n\treturn result;\r\n}", "function format() {\n for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n var a = args[0];\n var b = [];\n var c = void 0;\n\n for (c = 1; c < args.length; c += 1) {\n b.push(args[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n return a;\n}", "function formatString(str) {\n let l = str.length;\n let ns = '';\n if (l > 3) {\n ns = `\\$${str.substring(0, l - 3)}.${str.substring(l - 3, l + 1)}`;\n }\n if (l <= 3) {\n return `\\$${str}`\n }\n return ns;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(c < 0 || arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(c < 0 || arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(c < 0 || arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(c < 0 || arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n return a;\n}", "function sformat(format) {\n var args = arguments;\n var i = 0;\n return format.replace(/{(\\d*)}/g, function sformatReplace(match, number) {\n i += 1;\n if (typeof args[number] !== 'undefined') {\n return args[number];\n }\n if (typeof args[i] !== 'undefined') {\n return args[i];\n }\n return match;\n });\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n var a = arguments.length <= 0 ? undefined : arguments[0];\n var b = [];\n\n for (var c = 1, len = arguments.length; c < len; c += 1) {\n b.push(arguments.length <= c ? undefined : arguments[c]);\n }\n\n b.forEach(function (d) {\n a = a.replace(/%[a-z]/, d);\n });\n\n return a;\n}", "function format() {\n return Array.prototype.slice.call(arguments).join(\" \");\n }", "function formatString(s,args) { \r\n\tif (arguments.length>0) { \r\n\t\tvar result = s; \r\n\t\tif (arguments.length == 2 && typeof (args) == \"object\") { \r\n\t\t\tfor (var key in args) { \r\n\t\t\t\tvar reg=new RegExp (\"({\"+key+\"})\",\"g\"); \r\n\t\t\t\tresult = result.replace(reg, args[key]); \r\n\t\t\t} \r\n\t\t}else { \r\n\t\t\tfor (var i = 1; i < arguments.length; i++) { \r\n\t\t\t\tif(arguments[i]==undefined) { \r\n\t\t\t\t\treturn \"\"; \r\n\t\t\t\t} else \t{ \r\n\t\t\t\t\tvar reg=new RegExp(\"({[\"+(i-1)+\"]})\",\"g\"); \r\n\t\t\t\t\tresult = result.replace(reg, arguments[i]); \r\n\t\t\t\t} \r\n\t\t\t} \r\n\t\t} \r\n\t\treturn result; \r\n\t} else { \r\n\t\treturn s; \r\n\t} \r\n}", "function format(value){if(typeof value=='number')return value;var str=String(value);var ary=str.split('\\n').map(function(e){return JSON.stringify(e);});if(ary.length>1){// If the string has newlines, start it off on its own line so that\n// it's easier to compare against another string with newlines.\nreturn'\\n'+ary.join('\\n');}else{return ary.join('\\n');}}", "function formatWithPadding(num, string, num2) {\n\n}", "function stringFormat(str, args) {\n var content = str;\n for (var i=0; i < args.length; i++) {\n var replacement = '{' + i + '}';\n content = content.replace(replacement, args[i]);\n }\n return content;\n }", "function sformat(format) {\n var args = arguments;\n var i = 0;\n return format.replace(/{(\\d*)}/g, function sformatReplace(match, number) {\n i += 1;\n if (typeof args[number] !== 'undefined') {\n return args[number];\n }\n if (typeof args[i] !== 'undefined') {\n return args[i];\n }\n return match;\n });\n}", "function format(entry) {\n var val = entry.value;\n switch (entry.type) {\n case 'Method':\n case 'InterfaceMethod':\n case 'Field':\n return \"#\" + val.class_ref.value + \".#\" + val.sig.value;\n case 'NameAndType':\n return \"#\" + val.meth_ref.value + \":#\" + val.type_ref.value;\n case 'float':\n return format_decimal(val, 'f');\n case 'double':\n return format_decimal(val, 'd');\n case 'long':\n return val + \"l\";\n default:\n return util.escape_whitespace((entry.deref != null ? '#' : '') + val).replace(/\"/g, '\\\\\"');\n }\n}", "function format(string) {\n var args = arguments;\n var pattern = new RegExp(\"%([1-\" + arguments.length + \"])\", \"g\");\n console.log(pattern);\n return String(string).replace(pattern, function(match, index) {\n \tif(Number.isInteger(args[index])){\n \t\treturn args[index];\n \t} else {\n \t\treturn '\"'+args[index]+'\"';\n \t}\n });\n}", "function format(s) {\n\t return formatArr(s, slice.call(arguments, 1))\n\t}", "formatString(stringInfo) {\n if (stringInfo) {\n return stringInfo;\n } else {\n return 'Unknown';\n }\n }", "function formatString(string) {\r\n var args = arguments;\r\n var pattern = RegExp(\"%([1-\" + (arguments.length - 1) + \"])\", \"g\");\r\n return string.replace(pattern, function (match, index) {\r\n return args[index];\r\n });\r\n }", "function reformatSSN (SSN)\r\n{ return (reformat (SSN, \"\", 3, \"-\", 2, \"-\", 4))\r\n}", "function reformatSSN (SSN)\r\n{ return (reformat (SSN, \"\", 3, \"-\", 2, \"-\", 4))\r\n}", "function dpFormat(format){\r\n \treturn format.replace(/[HhMmYySsD]/g, 'd');\r\n }", "function format(value) {\n if (value === undefined || value === null)\n return '';\n return String(value);\n}", "function format(str, swaps) {\n // First replace the %S strings\n var index = 0;\n str = str.replace(/%S/g, function() {\n return swaps[index++];\n });\n // Then %n$S style strings\n str = str.replace(/%([0-9])\\$S/g, function(match, idx) {\n return swaps[idx - 1];\n });\n return str;\n}", "function format(str) {\n var formatArgs = [];\n for (var _i = 0; _i < (arguments.length - 1); _i++) {\n formatArgs[_i] = arguments[_i + 1];\n }\n if(typeof formatArgs[0] === 'object') {\n var a = formatArgs[0];\n return str.replace(objectCurlyRegex, function (m, n) {\n if(m == '{{') {\n return '{';\n }\n if(m == '}}') {\n return '}';\n }\n return a && a[n] || '';\n });\n }\n return str.replace(numberCurlyRegex, function (m, n) {\n if(m == '{{') {\n return '{';\n }\n if(m == '}}') {\n return '}';\n }\n return formatArgs[n] || '';\n });\n }", "function format(...args) {\n let a = args[0]\n const b = []\n let c\n\n for (c = 1; c < args.length; c += 1) {\n b.push(args[c])\n }\n\n b.forEach(d => {\n a = a.replace(/%[a-z]/, d)\n })\n\n return a\n}", "function format() {\n // String+ -> String\n // Takes a variable number of arguments. The first argument is the format\n // string. Placeholders in the format string are marked with `\"%s\"`.\n // Example:\n // lively.lang.string.format(\"Hello %s!\", \"Lively User\"); // => \"Hello Lively User!\"\n return formatFromArray(Array.prototype.slice.call(arguments));\n}", "function format(msg) \n{\n if (msg.length == 16) return msg;\n \n if (msg.length > 16) {return (msg.substring(0,16));} // return only the first 16 characters if longer.\n \n if (msg.length < 16) {\n return ((msg + \"000000000000000\").substring(0,16));\n }\n}", "function formatString(x) {\n return x.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, \",\");\n }", "function reformat (s)\r\n\r\n{ var arg;\r\n var sPos = 0;\r\n var resultString = \"\";\r\n\r\n for (var i = 1; i < reformat.arguments.length; i++) {\r\n arg = reformat.arguments[i];\r\n if (i % 2 == 1) resultString += arg;\r\n else {\r\n resultString += s.substring(sPos, sPos + arg);\r\n sPos += arg;\r\n }\r\n }\r\n return resultString;\r\n}", "function reformat (s)\r\n\r\n{ var arg;\r\n var sPos = 0;\r\n var resultString = \"\";\r\n\r\n for (var i = 1; i < reformat.arguments.length; i++) {\r\n arg = reformat.arguments[i];\r\n if (i % 2 == 1) resultString += arg;\r\n else {\r\n resultString += s.substring(sPos, sPos + arg);\r\n sPos += arg;\r\n }\r\n }\r\n return resultString;\r\n}", "function formatStringNoRegex(input) {\n var i, len, \n args, \n index,\n currentChar, \n output = '';\n \n input = input || '';\n args = [].slice.apply(arguments);\n \n for (i = 0, len = input.length; i < len; i += 1) {\n currentChar = input[i];\n if (currentChar !== '{') {\n output += currentChar; \n } else {\n index = Number(input[i + 1]) + 1; //in out args array at first position we have the input string => args start from first position\n output += (typeof args[index] != 'undefined' ? args[index] : ('{' + (index - 1) + '}'));\n i += 2;\n }\n }\n \n return output;\n}", "function format(s) {\n s = s.replace(/\\[\\[(.+)\\]\\]/g, (_, s) => `<em>${s}</em> `);\n s = s.replace(/^[^:]{1,18}: /, s => `<strong>${s}</strong>`);\n return s;\n}", "function formatString(string){\n var args, index;\n\n args = [].slice.apply(arguments);\n\n string = string.replace(/{(\\d+)}/g, function (match, number) {\n index = Number(number) + 1; \n return typeof args[index] != 'undefined'\n ? args[index]\n : match;\n });\n\n return string;\n}", "function formatted_price( $currency_symbol, $price, price_format ){\n return price_format.replace( '%1$s', $currency_symbol ).replace( '%2$s', $price ).replace( '&nbsp;', ' ' );\n }", "function formatAddress(address) {\n\treturn address;\n}", "function formatMessage(txt) {\n return txt\n}", "function format(str, ctx) {\n var splitter = '{',\n isInside = false,\n segment,\n valueAndFormat,\n path,\n i,\n len,\n ret = [],\n val,\n index;\n\n while ((index = str.indexOf(splitter)) !== -1) {\n\n segment = str.slice(0, index);\n if (isInside) { // we're on the closing bracket looking back\n\n valueAndFormat = segment.split(':');\n path = valueAndFormat.shift().split('.'); // get first and leave format\n len = path.length;\n val = ctx;\n\n // Assign deeper paths\n for (i = 0; i < len; i++) {\n val = val[path[i]];\n }\n\n // Format the replacement\n if (valueAndFormat.length) {\n val = formatSingle(valueAndFormat.join(':'), val);\n }\n\n // Push the result and advance the cursor\n ret.push(val);\n\n } else {\n ret.push(segment);\n\n }\n str = str.slice(index + 1); // the rest\n isInside = !isInside; // toggle\n splitter = isInside ? '}' : '{'; // now look for next matching bracket\n }\n ret.push(str);\n return ret.join('');\n }", "function format(str, ctx) {\n var splitter = '{',\n isInside = false,\n segment,\n valueAndFormat,\n path,\n i,\n len,\n ret = [],\n val,\n index;\n\n while ((index = str.indexOf(splitter)) !== -1) {\n\n segment = str.slice(0, index);\n if (isInside) { // we're on the closing bracket looking back\n\n valueAndFormat = segment.split(':');\n path = valueAndFormat.shift().split('.'); // get first and leave format\n len = path.length;\n val = ctx;\n\n // Assign deeper paths\n for (i = 0; i < len; i++) {\n val = val[path[i]];\n }\n\n // Format the replacement\n if (valueAndFormat.length) {\n val = formatSingle(valueAndFormat.join(':'), val);\n }\n\n // Push the result and advance the cursor\n ret.push(val);\n\n } else {\n ret.push(segment);\n\n }\n str = str.slice(index + 1); // the rest\n isInside = !isInside; // toggle\n splitter = isInside ? '}' : '{'; // now look for next matching bracket\n }\n ret.push(str);\n return ret.join('');\n }", "function format(str, ctx) {\n var splitter = '{',\n isInside = false,\n segment,\n valueAndFormat,\n path,\n i,\n len,\n ret = [],\n val,\n index;\n \n while ((index = str.indexOf(splitter)) !== -1) {\n \n segment = str.slice(0, index);\n if (isInside) { // we're on the closing bracket looking back\n \n valueAndFormat = segment.split(':');\n path = valueAndFormat.shift().split('.'); // get first and leave format\n len = path.length;\n val = ctx;\n \n // Assign deeper paths\n for (i = 0; i < len; i++) {\n val = val[path[i]];\n }\n \n // Format the replacement\n if (valueAndFormat.length) {\n val = formatSingle(valueAndFormat.join(':'), val);\n }\n \n // Push the result and advance the cursor\n ret.push(val);\n \n } else {\n ret.push(segment);\n \n }\n str = str.slice(index + 1); // the rest\n isInside = !isInside; // toggle\n splitter = isInside ? '}' : '{'; // now look for next matching bracket\n }\n ret.push(str);\n return ret.join('');\n }", "function formatter(fmt) {\n var codeRxp = /%([',+0]*)([1-9]?)((?:\\.[1-9])?)([sdifxX%])/g;\n var literals = [],\n formatCodes = [],\n startIdx = 0,\n prefix = \"\",\n matches = codeRxp.exec(fmt),\n literal;\n\n while (matches) {\n literal = fmt.substring(startIdx, codeRxp.lastIndex - matches[0].length);\n if (matches[0] == '%%') {\n prefix += literal + '%';\n } else {\n literals.push(prefix + literal);\n prefix = '';\n formatCodes.push(matches);\n }\n startIdx = codeRxp.lastIndex;\n matches = codeRxp.exec(fmt);\n }\n literals.push(prefix + fmt.substr(startIdx));\n\n return function() {\n var str = literals[0],\n n = arguments.length;\n if (n != formatCodes.length) {\n error(\"[format()] Data does not match format string; format:\", fmt, \"data:\", arguments);\n }\n for (var i=0; i<n; i++) {\n str += formatValue(arguments[i], formatCodes[i]) + literals[i+1];\n }\n return str;\n };\n }", "formatter(params) { return params.name; }", "function solve() {\n String.format = function() {\n var result = arguments[0];\n\n for (var i = 0; i < arguments.length - 1; i++) {\n var matchExpression = new RegExp('\\\\{' + i + '\\\\}', 'gm');\n result = result.replace(matchExpression, arguments[i + 1]);\n }\n\n return result;\n };\n\n var frmt = '{0}, {1}, {0} text {2}';\n var text = String.format(frmt, 1, 'Pesho', 'Gosho');\n\n console.log(text);\n}", "function buildFakeFormatString(chunks){var parts=[];var i;var chunk;for(i=0;i<chunks.length;i++){chunk=chunks[i];if(typeof chunk==='string'){parts.push('['+chunk+']');}else if(chunk.token){if(chunk.token in specialTokens){parts.push(SPECIAL_TOKEN_MARKER+// useful during post-processing\n'['+chunk.token+']'// preserve as literal text\n);}else{parts.push(chunk.token);// unprotected text implies a format string\n}}else if(chunk.maybe){parts.push(MAYBE_MARKER+// useful during post-processing\nbuildFakeFormatString(chunk.maybe)+MAYBE_MARKER);}}return parts.join(PART_SEPARATOR);}", "formatstring(){\n // Split date stamp received from json object to set date\n this.date = this.json.formatted.split(\" \")[0]\n let datesplit = this.date.split(\"-\")\n this.year = datesplit[0]\n this.month = datesplit[1]\n this.day = datesplit[2]\n this.displaydate = this.month + \"-\" + this.day + \"-\" + this.year\n \n // Split date stamp received from json object to set time\n let mTime = this.json.formatted.split(\" \")[1]\n let mTimeSplit = mTime.split(\":\")\n\n // Set the minutes\n this.minute = mTimeSplit[1]\n\n // Convert 24 hour time to 12 hour time\n this.hour = mTimeSplit[0]\n if (this.hour > 12) {\n this.hour = this.hour - 12\n this.suffix = \"PM\"\n }\n\n //Produce the display sting\n this.displaytime = this.hour + \":\" + this.minute + \" \" + this.suffix\n }", "formatNumber (format: string, number: number): string {\n return numeral(number).format(format)\n }", "function format(item) {\n if (item < 10) {\n return (item = `0${item}`);\n }\n return item;\n }", "function fv_format( str, variant ) {\n\n variant = ( variant == null || variant != \"b\" && variant != \"i\" && variant != \"bi\" ) ? \"r\" : variant;\n var out = \"\";\n for ( var index = 0; index < str.length; index++ ) {\n out += !( str.charAt( index ) in chars ) ? str.charAt( index ) : chars[ str.charAt( index ) ][ variant ];\n }\n return out;\n}", "function really_format(content) {\n\treturn content.replace(FORMAT_RE, apply_format);\n}", "function format(string, length) {\n for (var i = 0; i < length - string.length; i++) {\n string += \" \";\n }\n return string;\n }", "function renderFakeFormatString(fakeFormatString,date){return processMaybeMarkers(renderFakeFormatStringParts(fakeFormatString,date).join(''));}", "function jstrprintf() {\r\n\t\t//get length of arguments in function\r\n\t\tlen = arguments.length;\r\n\t\tif (len == 0) { return; } //return if len of arguments == zero\r\n\t\tif (len == 1) { return arguments[0]; } //return a zero dimension array if argumrnts are equal to one\r\n\t\t\r\n\t\t//declare some variables\r\n\t\tvar result;\r\n\t\tvar regexstr;\r\n\t\tvar replstr;\r\n\t\tvar formatstr;\r\n\t\tvar re;\r\n\t\t\r\n\t\t//Declare variables\r\n\t\tresult = \"\";\r\n\t\tregexstr = \"\";\r\n\t\treplstr = \"\";\r\n\t\tformatstr = arguments[0];\r\n\t\t\r\n\t\tfor (var i=1; i<arguments.length; i++) {\r\n\t\t\treplstr += String(i+100) + arguments[i] + String(i + 100);\r\n\t\t\tregexstr += String(i+100) + \"(.*)\" + String(i+100);\r\n\t\t}\r\n\t\tre = new RegExp(regexstr);\r\n\t\tvar result;\r\n\t\tresult = replstr.replace(re, formatstr);\r\n\t\t//console.log(result);\r\n\t\treturn result;\r\n\t}", "function getFormat(options) {\n return '<% if (date) { %>' + $.gray('${date}') + '<% } %>' +\n options.name + ' ' +\n '<% if (padding) { %>' + $.gray('${padding}') + '<% } %>' +\n (options.message || '${message}') +\n '<% if (debug) { %>' + $.gray('${debug}') + '<% } %>';\n}", "function user_format_convert(param){\n var formatted ='';\n//console.log('user_format_param: '+ param);\n if(param){\n var raw_number = param;\n formatted = raw_number.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, \",\");\n //console.log(\"user_format_formatted: \"+formatted);\n return formatted; \n }\n\n}", "formatTime(n) {\n if ((n + '').length > 2) {\n\treturn n;\n }\n const padding = new Array(2).join('0');\n return (padding + n).slice(-2);\n }", "function format(str, ctx) {\n\t\tvar splitter = '{',\n\t\t\tisInside = false,\n\t\t\tsegment,\n\t\t\tvalueAndFormat,\n\t\t\tpath,\n\t\t\ti,\n\t\t\tlen,\n\t\t\tret = [],\n\t\t\tval,\n\t\t\tindex;\n\t\t\n\t\twhile ((index = str.indexOf(splitter)) !== -1) {\n\t\t\t\n\t\t\tsegment = str.slice(0, index);\n\t\t\tif (isInside) { // we're on the closing bracket looking back\n\t\t\t\t\n\t\t\t\tvalueAndFormat = segment.split(':');\n\t\t\t\tpath = valueAndFormat.shift().split('.'); // get first and leave format\n\t\t\t\tlen = path.length;\n\t\t\t\tval = ctx;\n\n\t\t\t\t// Assign deeper paths\n\t\t\t\tfor (i = 0; i < len; i++) {\n\t\t\t\t\tval = val[path[i]];\n\t\t\t\t}\n\n\t\t\t\t// Format the replacement\n\t\t\t\tif (valueAndFormat.length) {\n\t\t\t\t\tval = formatSingle(valueAndFormat.join(':'), val);\n\t\t\t\t}\n\n\t\t\t\t// Push the result and advance the cursor\n\t\t\t\tret.push(val);\n\t\t\t\t\n\t\t\t} else {\n\t\t\t\tret.push(segment);\n\t\t\t\t\n\t\t\t}\n\t\t\tstr = str.slice(index + 1); // the rest\n\t\t\tisInside = !isInside; // toggle\n\t\t\tsplitter = isInside ? '}' : '{'; // now look for next matching bracket\n\t\t}\n\t\tret.push(str);\n\t\treturn ret.join('');\n\t}", "function format(str, ctx) {\n\t\tvar splitter = '{',\n\t\t\tisInside = false,\n\t\t\tsegment,\n\t\t\tvalueAndFormat,\n\t\t\tpath,\n\t\t\ti,\n\t\t\tlen,\n\t\t\tret = [],\n\t\t\tval,\n\t\t\tindex;\n\t\t\n\t\twhile ((index = str.indexOf(splitter)) !== -1) {\n\t\t\t\n\t\t\tsegment = str.slice(0, index);\n\t\t\tif (isInside) { // we're on the closing bracket looking back\n\t\t\t\t\n\t\t\t\tvalueAndFormat = segment.split(':');\n\t\t\t\tpath = valueAndFormat.shift().split('.'); // get first and leave format\n\t\t\t\tlen = path.length;\n\t\t\t\tval = ctx;\n\n\t\t\t\t// Assign deeper paths\n\t\t\t\tfor (i = 0; i < len; i++) {\n\t\t\t\t\tval = val[path[i]];\n\t\t\t\t}\n\n\t\t\t\t// Format the replacement\n\t\t\t\tif (valueAndFormat.length) {\n\t\t\t\t\tval = formatSingle(valueAndFormat.join(':'), val);\n\t\t\t\t}\n\n\t\t\t\t// Push the result and advance the cursor\n\t\t\t\tret.push(val);\n\t\t\t\t\n\t\t\t} else {\n\t\t\t\tret.push(segment);\n\t\t\t\t\n\t\t\t}\n\t\t\tstr = str.slice(index + 1); // the rest\n\t\t\tisInside = !isInside; // toggle\n\t\t\tsplitter = isInside ? '}' : '{'; // now look for next matching bracket\n\t\t}\n\t\tret.push(str);\n\t\treturn ret.join('');\n\t}", "function format(value, length) {\n var ret = \"\";\n // pad with zeros if it's too short\n while ((ret+value).length < length) {\n ret += \"0\";\n }\n // chop off trailing characters if it's too long\n while ((ret+value).length > length) {\n value = (\"\"+value).substr(0,(\"\"+value).length-1);\n }\n return ret+value;\n}" ]
[ "0.77428436", "0.77428436", "0.7315509", "0.72914624", "0.7254038", "0.7215152", "0.711854", "0.7112623", "0.70984256", "0.70468247", "0.7030428", "0.6989819", "0.69894737", "0.69861245", "0.6975022", "0.6886742", "0.6884545", "0.68305856", "0.6771086", "0.67595685", "0.6743668", "0.6743668", "0.6743668", "0.6743668", "0.6740121", "0.6739528", "0.67354244", "0.67080104", "0.669922", "0.669922", "0.669922", "0.669922", "0.6680295", "0.664968", "0.6647172", "0.6647172", "0.6647172", "0.6647172", "0.6647172", "0.6647172", "0.6647172", "0.6647172", "0.6647172", "0.6647172", "0.6647172", "0.6647172", "0.6647172", "0.6647172", "0.6647172", "0.6647172", "0.6622291", "0.6606381", "0.65878564", "0.65829897", "0.658108", "0.6580792", "0.65603966", "0.65273315", "0.65048546", "0.64810544", "0.6474688", "0.64591986", "0.64591986", "0.64536744", "0.64393437", "0.6436371", "0.6435048", "0.64259547", "0.6411172", "0.6397712", "0.639698", "0.6396635", "0.6396635", "0.63950455", "0.63846874", "0.63811433", "0.63655716", "0.6354696", "0.6353787", "0.6350271", "0.6350271", "0.63065", "0.6291425", "0.6286728", "0.6285589", "0.6256663", "0.62496144", "0.624015", "0.62394035", "0.62385994", "0.62336445", "0.62332284", "0.6230132", "0.62215626", "0.6214636", "0.6213047", "0.6204667", "0.620129", "0.620129", "0.62008065" ]
0.6902527
15
Function called when clicking the Login/Logout button. [START buttoncallback]
function toggleSignIn() { if (!firebase.auth().currentUser) { var provider = new firebase.auth.GoogleAuthProvider(); // [START signin] firebase.auth().signInWithPopup(provider).then(function(result) { // User is authenticated. var user = result.user; // The signed-in user info // Store user uid, displayName, and email sessionStorage.setItem("uid", user.uid); sessionStorage.setItem("displayName", user.displayName); sessionStorage.setItem("email", user.email); // Store in session the graduation status of the user; if not a student/alumni, show error message. gradStatus = returnGradStatus(user.email, user.emailVerified) // Determine if account can enter app. if (gradStatus !== 'error') { sessionStorage.setItem("gradStatus", gradStatus); // Go to app main page. window.location.href = "main.html"; } else { // Signout user. firebase.auth().signOut(); // Re-enable button. document.getElementById('quickstart-sign-in').disabled = false; // Error message (user is not verified, or not a student or alumni) sweetAlert("Oops!", "Please use a Notre Dame e-mail account.", "error"); } }).catch(function(error) { // Handle Errors here. var errorCode = error.code; var errorMessage = error.message; var email = error.email; // The email of the user's account used. var credential = error.credential; // The firebase.auth.AuthCredential type that was used. if (errorCode === 'auth/account-exists-with-different-credential') { alert('You have already signed up with a different auth provider for that email.'); // If you are using multiple auth providers on your app you should handle linking // the user's accounts here. } else { console.error(error); } }); // [END signin] } else { // [START signout] // Confirm logout sweetAlert. swal({ title: "Are you sure?", text: "Do you want to logout?", type: "warning", showCancelButton: true, closeOnConfirm: false, confirmButtonText: "Yes, logout!", confirmButtonColor: "#ec6c62" }, function(isConfirm){ if (isConfirm) { // Logout confirmed. firebase.auth().signOut(); console.log("logging out"); window.location.href = "index.html"; } else { // Logout canceled. } }); // [END signout] } $('#quickstart-sign-in').disabled = true; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function handleLoginBtnClick() {\n console.log(\"login clicked\", email, password);\n\n }", "function loggedIn(){\n var $login = $('.login');\n switchTheme($login, 'b');\n $('.ui-btn-text', $login).text($login.data('text-logout'));\n $login.attr('onclick', 'window.location.href = \"https://www.google.com/accounts/Logout?continue=https://appengine.google.com/_ah/logout?continue=\" + window.location.href;');\n\n notice.remove('requires-login');\n }", "loginLogoutClick() {\n this.checkLoginState();\n }", "function loggedOut(){\n var $login = $('.login');\n switchTheme($login, 'c');\n $('.ui-btn-text', $login).text($login.data('text-login'));\n $login.attr('onclick', 'auth.login(true)');\n }", "function onLogin() {}", "function btnLoginClicked() {\n\tif ($.txtUserName.value.length != 0 && $.txtPassword.value.length != 0) {\n\t\t$.activityIndicator.show();\n\t\tvar hostIP = $.txtHostIP.value,\n\t\t username = $.txtUserName.value,\n\t\t password = $.txtPassword.value;\n\n\t\tif ($.swcKeepMeSignedIn.value == true) {\n\t\t\tLoginGlobal.saveLoginInformationToProperties(username, hostIP);\n\t\t}\n\t\tLoginGlobal.login(hostIP, username, password);\n\t} else {\n\t\talert(\"Please enter a username and password.\");\n\t}\n}", "function changeLoginButton(){\n\tif($('#button-login').button( \"option\", \"label\" )==\"LOGIN\")\n\t{\n\t\t$('#button-login').button( \"option\", \"label\", \"LOGOUT\" )\n\t\t\t$('#button-login').button().on(\"click.logout\",\n\t\t\tfunction(){\n\t\t\t\t$.get(\"PHP/endsession.php\",function(data){\n\t\t\t\t\t$('#login_info').text(\"You are currently not logged in.\");\n\t\t\t\t\tchangeLoginButton();\t\n\t\t\t\t\twindow.location=\"index.php\";\n\t\t\t\t});\n\t\t\t});\n\t\t$('#button-login').button().off(\"click.login\");\t\t\n\t}\n\telse\n\t{\n\t\t$('#button-login').button( \"option\", \"label\", \"LOGIN\" )\n\t\t$('#button-login').button().off(\"click.logout\");\t\n\t\t$('#button-login').button().on(\"click.login\",\n\t\tfunction(){\n\t\t\t$('#login').dialog(\"open\");\n\t\t});\t\n\t}\n}", "get btnLogin () { return $('#back-to-login') }", "function loginButton()\r\n{\r\n\tif(appWindow.scrollViews()[0].buttons()[\"Login\"].isValid())\r\n\t{\r\n\t\tappWindow.scrollViews()[0].buttons()[\"Login\"].tap();\r\n\t\tUIALogger.logPass(\"Login button exists and user has tapped on login button\");\r\n\t}\r\n\telse\r\n\t{\r\n\t\tUIALogger.logFail(\"User is unable to click on Login button\");\r\n\t}\r\n}", "function logInClick() {\n\tif (!logInBtn) return;\n\n\tlogInBtn.onclick = function() {\n\t\twindow.location.href='protected/admin.php';\n\t}\n}", "function signIn(e){\r\n\tCloud.Users.login({\r\n\t\tlogin:$.login.value,\r\n\t\tpassword:$.password.value\r\n\t}, function(e){\r\n\t\tif(e.success){\r\n\t\t\tvar tochange=Alloy.createController(\"index\");\r\n\t\t\ttochange.signInButton.title=\"Sign Out\";\r\n\t\t\t$.signWin.close();\r\n\t\t}\r\n\t\telse{\r\n\t\t\t$.signWin.close();\r\n\t\t\talert(\"Sign in Failed\");\r\n\t\t}\r\n\t});\r\n\t\r\n\t\r\n}", "function loginClick() {\n\t username = $(\"#userName\").val();\n\t password = $(\"#password\").val();\n\t getRememberMestatus();\n\t var params = {\"username\":username,\"password\":password};\n\t var callerId = \"login\";\n\t var url = \"/logon\";\n\t reqManager.sendPost(callerId, url, params, loginSuccessHandler, loginErrorHandler, null);\n\t}", "function OnLogIn()\n {\n //If the selection window is closed, clear the timer first, then \n //retrieve the returned record \n if (loginwin.closed)\n {\n //Clear the timer\n clearInterval(timer);\n \n //Unhide the logout menu button\n var logout = document.getElementById(\"logout\");\n //\n //Update the value of the Logout menu to show the username\n logout.value = \"Logout \" + dbname;\n //\n //Remove the hidden attribute\n logout.removeAttribute(\"hidden\");\n }\n }", "function loginCompleted() {\n }", "function onReady(){\n $('#bLogin').click( bLogin_action );\n}//End of ready function", "function listenLoginButton() {\n $(\"#loginButton\").click(()=>{\n var password = $(\"#passwordInput\").val();\n login(password);\n });\n}", "function Log_In() {\n var self = this;\n\n this.init = function () {\n self.GoTo_Home();\n self.GoTo_SignUp();\n //self.GoTo_ForgotPassword();\n //self.ChangeForm();\n }\n\n //---------------------------------------\n //LogIn Get\n //---------------------------------------\n this.GoTo_Home = function () {\n\n //$(\".LogInButton\").click(function (event) {\n // // Ir al Home si el login es exitoso\n // window.location.href = \"../ASPX/HomePage.aspx\";\n // return false;\n //});\n }\n\n //---------------------------------------\n //SignUp Button Handler\n //---------------------------------------\n this.GoTo_SignUp = function () {\n\n // Click Function\n $(\".toggle\").click(function (event) {\n // Ir al Home si el login es exitoso\n window.location.href = \"../ASPX/SignUp.aspx\";\n return false;\n //console.log(\"Pasando a la siguiente pagina\");\n });\n }\n} // End of Script", "function loginUserCallback() {\n loginUser();\n }", "function handleLoginButton() {\n // select main area class div with inputs and on click and look for nav-login link run e\n $(\".main-area\").on(\"click\", \".nav-login\", function(e) {\n console.log(\"Login button clicked\");\n // stop page from submitting\n e.preventDefault();\n // excute display login function\n displayLoginPage();\n });\n}", "function UpdateAuthenticationInfo( e )\r\n{\r\n if( e.auth_done )\r\n {\r\n // If the Logout button is not visible, we were offline and now we must switch to online because the auth:done event is fired\r\n if( !$.btnLogout.visible )\r\n {\r\n $.btnLogout.visible = true ;\r\n current_logged_username = Alloy.Globals.CurrentAuthenticationInfoTitle() ;\r\n // Set welcome label text\r\n $.lblWelcome.setText( current_logged_username ) ;\r\n\r\n RebuildTable() ;\r\n }\r\n }\r\n else\r\n {\r\n Alloy.Globals.ResetSession() ;\r\n\r\n $.btnLogout.visible = false ;\r\n current_logged_username = L( 'generic_welcome_offline_text_msg' ) ;\r\n // Set welcome label text\r\n $.lblWelcome.setText( current_logged_username ) ;\r\n }\r\n}", "function handleSignInButtonClick() {\n if (!loggedIn) {\n setHasError(true);\n setErrorMessage('Please log in to continue');\n setShowLogin(!showLogin);\n } else {\n setLoggedIn(true);\n }\n }", "clickLoginButton() {\n this.loginButton.click();\n }", "function onLogin(loginResponse){\n // Send headers to your server and validate user by calling Digits’ API\n var oAuthHeaders = loginResponse.oauth_echo_headers;\n var verifyData = {\n authHeader: oAuthHeaders['X-Verify-Credentials-Authorization'],\n apiUrl: oAuthHeaders['X-Auth-Service-Provider']\n };\n\n console.log('logged in!');\n console.log(verifyData);\n\n $('.digits-widget').hide();\n alert('You are now logged in!');\n\n }", "function handleClick() {\n setLogin(!login)\n }", "function initializePage_login()\r\n{\r\n page_login.initializeForm(page_userLogin);\r\n page_login.initializeButton(showPage_createAccount);\r\n}", "function onLogout(){\r\n\t$('#id_dropdown_logout').stop().slideUp();\r\n\tbIsLoggedIn = false;\r\n\t$('#id_login_button').text('LOGIN');\r\n\tclearStickies();\r\n}", "function setupButtons() {\n\t$('#btnLogin').click(login);\n\t$('#btnLogout').click(logout);\n}", "function loginBackButtonPressed() {\n}", "function loginButtonClicked() {\n loginButtonEl.addEventListener(\"click\", function () {\n let usernameInput = document.getElementById(\"username-id\").value;\n let passwordInput = document.getElementById(\"password-id\").value;\n // Check if the entered username is equal to a valid username/password\n let adminAccount = JSON.parse(window.localStorage.getItem(\"adminAccount\"));\n let userAccount = JSON.parse(window.localStorage.getItem(\"user\")) || \"\";\n if ((adminAccount.password === passwordInput) && (adminAccount.username === usernameInput)) {\n alert(\"Logging in as Admin...\");\n loginPageEl.style.display = \"none\";\n homePageEl.style.display = \"block\";\n accountCreationModalEl.style.display = \"none\";\n } else if ((userAccount.username === usernameInput) && (userAccount.password === passwordInput)) {\n alert(`Logging in as ${userAccount.username}...`);\n loginPageEl.style.display = \"none\";\n homePageEl.style.display = \"block\";\n accountCreationModalEl.style.display = \"none\";\n } else {\n alert(\"Please enter a valid account login.\");\n passwordInput.value = \"\";\n }\n });\n }", "function signinCallback(authResult) {\n if (authResult['access_token']) {\n // Successfully authorized\n // Hide the sign-in button now that the user is authorized:\n document.getElementById('signinButton')\n .setAttribute('style', 'display: none');\n // One of the async actions have happened\n unitsReady++;\n checkAllUnitsLoaded();\n } else if (authResult['error']) {\n // There was an error.\n // Possible error codes:\n // \"access_denied\" - User denied access to your app\n // \"immediate_failed\" - Could not automatically log in the user\n console.log('There was an error: ' + authResult['error']);\n\n document.getElementById('signinButton')\n .setAttribute('style', 'display: visible');\n document.getElementById('loggedInUI')\n .setAttribute('style', 'display: none');\n }\n}", "clickLoginButton() {\n this.loginButton.waitForVisible();\n this.loginButton.click();\n }", "function loginModalCallback(){\n\t\tvar screenName;\n\t\t\n\t\tif(ScreenManager.getCurrentScreen().getDisplayName != null){\n\t\t\tscreenName = ScreenManager.getCurrentScreen().getDisplayName();\n\t\t}else{\n\t\t\tscreenName = ScreenManager.getCurrentScreen().displayName;\n\t\t}\n\t\t\n\t\tif(screenName == WelcomeScreen.displayName){\n\t\t\tModalManager.hideModal();\n\t\t\tScreenManager.changeScreen(new UserIdentityScreen())\n\t\t}else{\n\t\t\tModalManager.hideModal();\n\t\t\tScreenManager.replaceScreen(ScreenManager.getCurrentScreen());\n\t\t}\n\t}", "function onLoginButtonClick(event) {\n console.log('Digits login started.');\n Digits.logIn().done(onLogin).fail(onFailure);\n return false;\n }", "function logIn() {\r\n let userr = $('#username').val()\r\n let passw = $('#passwrd').val()\r\n //if they do we get our entire menu back with extra options\r\n if (userr == usernameadmin && passw == passwordadmin) {\r\n $('#disp').css('display', 'block')\r\n deletingchildelem()\r\n $(\".overlay-content\").show(500);\r\n $(\".overlay-content\").css(\"display\", \"block\");\r\n $('.overlay-content').append('<button type=\"button\" class=\"btn btn-primary\" onclick=\"logOut()\" id=\"logger\">Log Out</button>')\r\n $('#loggs').css('display', 'none')\r\n }\r\n //if not we get notification\r\n else {\r\n alert('Incorrect username or password!')\r\n }\r\n}", "function displayLogin() {\n hide(\"logout\");\n display(\"login\");\n circle.setColor(\"rgb(212, 29, 140)\");\n}", "function handleLoginClick(event) {\n login.handleLoginClick(startCMISSession);\n}", "function logoutFunc() {\n\tvar dialog = Ti.UI.createAlertDialog({\n\t\tcancel : 1,\n\t\tbuttonNames : [L('yes_txt'), L('no_txt')],\n\t\tmessage : L('logout_confirmation_txt'),\n\t\ttitle : L('app_name'),\n\t});\n\tdialog.addEventListener('click', function(e) {\n\t\tif (e.index === 0) {\n\t\t\tvar login = Alloy.createController(\"LoginScreen\").getView();\n\t\t\tif (OS_ANDROID) {\n\t\t\t\tlogin.open();\n\t\t\t} else {\n\t\t\t\tlogin.open({\n\t\t\t\t\ttransition : Titanium.UI.iOS.AnimationStyle.CROSS_DISSOLVE\n\t\t\t\t});\n\t\t\t}\n\t\t\t$.navWin.close();\n\t\t\tTi.App.Properties.setString(\"access_token\", null);\n\t\t\tTi.App.Properties.setBool(\"isAutoLogin\", false);\n\t\t\tTi.App.Properties.setObject(\"userData\", null);\n\t\t}\n\t});\n\tdialog.show();\n\n}", "function signinCallback(authResult) {\n\n if (authResult['status']['signed_in']) {\n\n // Successfully authorized\n// document.getElementById('customBtn').setAttribute('style', 'display: none');\n apiClientLoad();\n\n } else if (authResult['error']) {\n\n // There was an error.\n // Possible error codes:\n // \"access_denied\" - User denied access to your app\n // \"immediate_failed\" - Could not automatially log in the user\n //console.log('There was an error: ' + authResult['error']);\n gpLoggedInFailure(authResult['error']);\n }\n}", "function NewLoginForm() {\n //$(\"#loginButton\").click(this.logIn);\n $(\"#loginButton\").click(this.testAlert);\n }", "function signinLink(loginStatus){\n\n\t// remove the login/logout content if it exists.\n\t$('.mystar .anonymous').remove();\n\n // do not render Sign In / Sign out if disabled\n\n if (!$('body').hasClass('shellpage')){\n\n var displayHtml = '';\n displayHtml += '<ul class=\"anonymous float-clear\">';\n\n // check the cookie to see if the user is logged in (user_id), and build the right display html\n\n if ( loginStatus ){\n displayHtml += '<li class=\"logout\" id=\"logoutlink\"><span>Sign out</span></li>';\n $('.digitalAccessBottom p.signIn span').removeClass('login').addClass('logout').html('Sign Out');\n } else {\n displayHtml += '<li class=\"logout\" id=\"loginlink\"><span>Sign in</span></li>';\n $('.digitalAccessBottom p.signIn span').removeClass('logout').addClass('login').html('Sign In');\n }\n\n displayHtml += '</ul>';\n\n\n // render the link\n $('.mystar').prepend(displayHtml);\n\n\n $('#loginlink').on('click', function(e){\n // location of the mystar dialog.\n var loginlocation = mystarsecurelocation + '/users/signin'\n createLoginModal(loginlocation);\n });\n\n $('.digitalAccessBottom p.signIn span.login').on('click', function(e){\n // location of the mystar dialog.\n var loginlocation = mystarsecurelocation + '/users/signin'\n createLoginModal(loginlocation);\n });\n\n\n $('#logoutlink').on('click', function(){\n //this will log out the user from commenting Echo's Backplane server\n Backplane.resetCookieChannel();\n window.location = mystarlocation + '/users/signout';\n });\n\n $('.digitalAccessBottom p.signIn span.logout').on('click', function(){\n //this will log out the user from commenting Echo's Backplane server\n Backplane.resetCookieChannel();\n window.location = mystarlocation + '/users/signout';\n });\n }\n}", "function logoutButton(){\n ajax_All(199)\n}", "function switchToLogin(){\n\t\tturnService.closeWaitingAlert();\n\t\t$userLoginArea.show();\t\t\n\t\t$pageWrapper.hide();\n\t}", "function modalLogIn() {\n $(\"#logIn\").find(\".btn-primary\").click(logIn);\n}", "function callback() {\n deleteUsuarioLogado();\n onChangeView(VIEW_LOGIN_KEY);\n }", "onLoginSuccess() {\n\t\tApp.navigatePrevious();\n\t}", "function goLogIn() {\n \n body.innerHTML = renderLoginDiv(email2, pass2, message2);\n assignListener('login2');\n }", "function handleLoginSwitchButton(evt) {\n document.forms['auth'].action = '/login';\n document.getElementById('submit').innerText = 'LOGIN';\n document.getElementById('register-switch').classList.remove('button-focused');\n evt.target.classList.add('button-focused');\n}", "function login() {}", "function doLogout()\n{\n getSelectedItem();\n // here's the workaround - login functions are with token\n var selected_token = selected_slot.getToken();\n try {\n selected_token.logoutAndDropAuthenticatedResources();\n var tok_status = document.getElementById(\"tok_status\");\n if (selected_token.isLoggedIn()) {\n tok_status.setAttribute(\"label\", \n bundle.GetStringFromName(\"devinfo_stat_loggedin\"));\n } else {\n tok_status.setAttribute(\"label\",\n bundle.GetStringFromName(\"devinfo_stat_notloggedin\"));\n }\n } catch (e) {\n }\n enableButtons();\n}", "onLogoutClicked() {\n AuthActions.logoutUser();\n }", "function handleClick(event){\n console.log(\"Signing in\")\n}", "function login() {\n\n}", "function displayLogIn(){\n\t\t\t//change button oplogin's appearance to Log In\n\t\t\tvar openlogin = document.getElementById(\"openlogin\");\n\t\t\topenlogin.innerHTML = \"Log In\";\n\t\t}", "function handleGoogleLoginBtnClick() {\n console.log(\"google login clicked\");\n }", "function loggedOut() {\n $(\"input\").val(\"\");\n $(\"#content .business\").hide();\n $('.intro').fadeIn(300);\n $(\"header .picture\").empty();\n var l = $(\"header .login\").removeClass('clickable');\n l.html('<img src=\"i/persona_sign_in_blue.png\" alt=\"Sign in\">')\n .show().one('click', function() {\n $(\"header .login\").css('opacity', '0.5');\n navigator.id.get(gotVerifiedEmail, browseridArguments);\n }).addClass(\"clickable\").css('opacity','1.0');\n}", "function logout() {\n token = false;\n showLogin();\n}", "function logOut() {\n $.post('core/action-design.php', {\n 'act': 'logout'\n })\n .success(function(data) {\n login = false;\n info('<label style=\"color:green\">Success for Logout</label>');\n });\n }", "function bindHeaderEvents(){\n //when the login button is pressed\n $(\"#login-button\").click(function(){\n $(\"#login-modal\").modal('show');\n });\n //when the logout button is pressed\n $(\"#logout-button\").off().click(function(){\n logoutUser();\n });\n\n}", "function onChangeLogin() {}", "function signIn(){\n var dataEntered = getLoginData();\n loginUser(dataEntered);\n}", "function generateLoggedInButton(){\n\n var loggedInUser = getUserInfo();\n var loggedInAs = loggedInUser[0].userName;\n\n\n if(loggedInAs!=null && typeof(loggedInAs)!='undefined'){\n alert('loggedIn');\n //document.getElementById('loggedInUserLabel').innerHTML = 'Logged as : '+loggedInAs; \n var header = document.getElementsByTagName('header')[0];\n\n var logOutbutton = document.createElement('button');\n logOutbutton.setAttribute(\"id\",\"logout\");\n logOutbutton.setAttribute(\"class\" ,\"navitems\");\n logOutbutton.addEventListener(\"click\", userLogOut);\n var logOutbuttonText = document.createTextNode('Logged In: '+loggedInAs);\n logOutbutton.appendChild(logOutbuttonText);\n\n header.appendChild(logOutbutton);\n}\n}", "function logOut() {\n setCookie(-100);\n $(\"#signUp\").css(\"display\", \"inherit\");\n $(\"#signOff\").css(\"display\", \"none\");\n hideButtons(); //Ocultamos los botones privados\n initPopulate();\n}", "function login() {\n\n clearInterval(timerId);\n outlet.innerHTML = loginTemplate;\n const loginPage = document.getElementById(\"login\");\n loginPage.addEventListener(\"click\", animationPage);\n history.pushState(\"logout\", \"title 1\", \"?page =login\");\n // \n }", "function postLogout() {\n $(\".postlogin-content, .login-show, #successAlert\").fadeOut( function() { \n $(\".prelogin-content, #landingpagebutton, .logout-show\").fadeIn();\n $(\"#queryResetButton\").click();\n });\n}", "function myrunwayLogin(){\r\n $(\"#signin\").on(\"click\", function(){\r\n $('#login').click();\r\n\r\n if (!$(\"#username\").val()) {\r\n sap.messageBox.showMsg(sapLang.getText(\"110001\"));\r\n $(\"#username\").focus();\r\n } else if (!$(\"#password\").val()) {\r\n sap.messageBox.showMsg(sapLang.getText(\"110002\"));\r\n $(\"#password\").focus();\r\n } else {\r\n var signInObj = {};\r\n signInObj.snsProvider = \"DEFAULT\";\r\n signInObj.snsAccount = $(\"#username\").val();\r\n signInObj.password = $(\"#password\").val();\r\n signInObj.isMyRunwayLogin = \"true\";\r\n var reqData = JSON.stringify({SignInVO: signInObj});\r\n signinMyRunway(reqData);\r\n $(\"#share\").hide(); \r\n }\r\n \r\n return false;\r\n });\r\n \r\n $(document).on('keypress', function(e) {\r\n if(e.keyCode == 13 && !$(\"#login\").hasClass(\"hidden\")) {\r\n $(\"#signin\").click();\r\n }\r\n });\r\n }", "function authLogin() {\n\t\tpopup(tools.urlLogin, 'BOM - Login', 302, 320);\n\t\teventer(messageEvent, authLoginSuccess, false);\n\t}", "function TakeLoginAction(e) {\n\n var enterkeyPressed = IsEnterKeyPressed(e);\n\n if (enterkeyPressed) {\n\n if (window.event) {\n event.returnValue = false;\n event.cancel = true;\n }\n else {\n e.returnValue = false;\n e.cancel = true;\n }\n\n var actionButton = GetActionButton(\"logonButton\");\n\n if (actionButton != null) {\n actionButton.click();\n }\n }\n}", "function drawLogout() {\n console.log('logged in')\n document.getElementById('auth').innerHTML = `<button onclick=\"app.controllers.authController.logout()\">logout</button>`\n\n}", "renderLogIn()\n {\n return (\n <div id=\"login\">\n <Login\n callback={this.loginCallback}\n />\n <p>no account? <button onClick={this.registerButtonHandler}>register here</button></p>\n </div>\n );\n }", "handleClick(e) {\n this.userLogin(this.state.username, this.state.password);\n }", "function loadLogin() {\n console.log(\"User is now logged out.\");\n}", "function loginout(){\n let lIn = document.getElementById(\"loginBtn\");\n let lOut = document.getElementById(\"logoutBtn\");\n if ((sessionStorage.getItem(\"token\") === null) || (sessionStorage.getItem(\"token\") === \"\")) {\n lIn.style.display = \"block\";\n lOut.style.display = \"none\";\n } else {\n lIn.style.display = \"none\";\n lOut.style.display = \"block\";\n }\n}", "function userIsLoggedIn() {\n _localStorage('save', 'pihole_success', 1);\n $('#header_guest').hide();\n $('#header_loggedin').show();\n\n $('#logout').click(function (event) {\n event.preventDefault();\n _localStorage('remove', 'pihole_success');\n _localStorage('remove', 'pihole_host');\n _localStorage('remove', 'pihole_token');\n userIsGuest();\n pageAppSettings();\n });\n}", "function logOut(){\n clearCurrentUser();\n showLoggedOutView();\n}", "function navLoginClick (evt) {\n\tconsole.debug('navLoginClick', evt);\n\thidePageComponents();\n\t$loginForm.show();\n\t$signupForm.show();\n}", "function login() {\r\n hideall();\r\n $(\"sidebar\").hide();\r\n var id = $(\"#lemail\").val();\r\n var p1 = $(\"#lpass\").val();\r\n // Login\r\n\r\n // Parse the input\r\n\r\n var lambda = new AWS.Lambda({\r\n region: 'ca-central-1',\r\n apiVersion: '2018-02-25'\r\n });\r\n var params = {\r\n FunctionName: \"OurUTMUserAccounts\",\r\n InvocationType: \"RequestResponse\",\r\n LogType: \"None\",\r\n Payload: JSON.stringify({\r\n \"function\": \"login\",\r\n \"parameters\": {\r\n \"email\": id,\r\n \"password\": p1,\r\n }\r\n }),\r\n };\r\n\r\n var pullResults;\r\n let page = \"#login\";\r\n\r\n lambda.invoke(params, function(error, data) {\r\n if (error) {\r\n prompt(\"error\" + error);\r\n } else {\r\n pullResults = JSON.parse(data.Payload);\r\n if (pullResults['msg'] === \"login: successful\") {\r\n loadHome();\r\n setUser(id);\r\n } else {\r\n $(\"#lpass\").val(\"\")\r\n $(page).show();\r\n }\r\n }\r\n });\r\n $(\"#navbar\").show();\r\n\r\n}", "Logout() {\n alert(\"You will Loging Out\");\n }", "function logoutUser(){\n updateViewToLoggedOut();\n}", "function onLogin(){\r\n\t$('#id_dropdown_login').stop().slideUp();\r\n\tbIsLoggedIn = true;\r\n\t//Update the text to state 'Logged in'\r\n\t$('#id_login_button').text('LOGGED IN (' + tUsers[iCurrentUser].user_name + ')');\r\n\t//Greeting to the user\r\n\t$('#id_greeting_user').text('Hi ' + tUsers[iCurrentUser].user_name + '!');\r\n\t\r\n\t//Retrieve the user's stickies from the userData-table\r\n\tretrieveUserStickies(tUsers[iCurrentUser].user_username);\r\n\t\r\n\t//add the stickies that were created before the user logged in to his userData\r\n\tconst tCurrentUserData = tUserData[\"user_\" + tUsers[iCurrentUser].user_username];\r\n\tfor (i=0; i<tStickies.length; i++){\r\n\t\tif (!isStickyLoadedInTable(tCurrentUserData,tStickies[i])){\r\n\t\t\tconsole.log(\"Not loaded, so adding it to tUserData!\");\r\n\t\t\ttCurrentUserData.push(tStickies[i]);\r\n\t\t\t//because class instances/objects work via pointers in js, we don't need special handling to ensure that data changed in\r\n\t\t\t//tStickeis is also changed in tUserData!\r\n\t\t}\r\n\t}\r\n\t\r\n\t//Sort the stickies and update the screen (and log the result)\r\n\tsortStickies();\r\n}", "function logOut() {\n FB.logout();\n buttonView('logOut')\n }", "function navLoginClick(evt) {\n console.debug(\"navLoginClick\", evt);\n hidePageComponents();\n $loginForm.show();\n $signupForm.show();\n}", "function navLoginClick(evt) {\n console.debug(\"navLoginClick\", evt);\n hidePageComponents();\n $loginForm.show();\n $signupForm.show();\n}", "function navLoginClick(evt) {\n console.debug(\"navLoginClick\", evt);\n hidePageComponents();\n $loginForm.show();\n $signupForm.show();\n}", "function navLoginClick(evt) {\n console.debug(\"navLoginClick\", evt);\n hidePageComponents();\n $loginForm.show();\n $signupForm.show();\n}", "function doModalLogin_() {\n\tcustomModalBox.htmlBox('yt-LoginContent_Popup', '', 'Log in'); \n\tloginClose_();\n}", "function navLoginClick(evt) {\n\tconsole.debug('navLoginClick', evt);\n\thidePageComponents();\n\t$loginForm.show();\n\t$signupForm.show();\n}", "switchToLogin() {\n document.getElementById(\"login-form-container\").classList.remove('right-panel-active');\n this.clearFeedback();\n updatePageTitle(\"Logg inn\");\n }", "logOut() {\n _elements.logOutLink.click();\n return this.checkLoginLinkPresent();\n }", "function loginButton(){\n\tfunction getUser(userData) {\n \t$.get(\"/api/\", userData, function(data){\n \t\tconsole.log(data);\n \t\t//ensure all the retreived data is saved in the session\n \t\tsessionStorage.setItem('userId', data[0].id);\n \t\tsessionStorage.setItem('userfName', data[0].fName);\n\t\t\tsessionStorage.setItem('userlName', data[0].lName);\n\t\t\tsessionStorage.setItem('userCompany', data[0].company);\n\t\t\tsessionStorage.setItem('userEmail', data[0].email);\n\t\t\tsessionStorage.setItem('userPassword', data[0].password);\n \t})\n \t.then(changeURL);\n \t \n \t}\n \t//verify user information is entered correctly\n \tif($('#userEmail').val() == \"\" || $('#userPassword').val() == \"\"){\n \t\talert('Some information is missing from the form. Please make sure all information is filled out fully.');\n \t}else{\n\t\tgetUser({\n\t\t\taction: 'login',\n\t\t\temail: $('#userEmail').val(),\n\t\t\tpassword: $('#userPassword').val()\n\t\t});\n\t}\n}", "function onSignOut() {\n console.log('>onSignOut');\n //showSignedOutUserControls();\n}", "function navLoginClick(evt) {\n console.debug(\"navLoginClick\");\n hidePageComponents();\n $loginForm.show();\n $signupForm.show();\n}", "get loginBtn () { return $('#btnLogin') }", "function onClickLogin(evt) {\n evt.preventDefault();\n var command = $(\"#login\").text();\n if (command === \"Login to See your Stats\") {\n\n // Store CSRF token and current location as cookie\n var csrfToken = uuidGen();\n $.cookie(csrfTokenName, csrfToken);\n $.cookie(hashTokenName, window.location.hash);\n\n // No OAuth token, request one from the OAuth authentication endpoint\n window.location = \"https://login.eveonline.com/oauth/authorize/\" +\n \"?response_type=token\" +\n \"&client_id=\" + clientId +\n \"&scope=\" + scopes +\n \"&redirect_uri=\" + redirectUri +\n \"&state=\" + csrfToken;\n\n } else {\n ajaxSetup(false);\n loginSetup(false);\n }\n }", "onLoginClick(event) {\n this.props.signinUser(this.state.userName, this.state.password, this.props.history);\n }", "function toggle_register_login_logout() {\n if(trying_to_logout) {\n $(\"#logout_btn\")\n .attr(\"id\",\"register_login_btn\")\n .removeClass(\"btn-danger\")\n .addClass(\"btn-success\")\n .attr(\"value\",\"Login?\");\n $(\"#login_form\").attr(\"hidden\",false);\n $(\"#login_message\").text(\"\");\n\n window.location.hash = \"\";\n\n is_logged_in = false;\n trying_to_logout = false;\n }\n if(trying_to_login) {\n $(\"#register_login_btn\").attr(\"value\",\"Login?\");\n $(\"#login_register\").html(\"Register : \");\n $(\"#login\").attr(\"value\",\"Register!\");\n $(\"#username_div\").attr(\"hidden\",false);\n trying_to_login = false;\n } else {\n $(\"#register_login_btn\").attr(\"value\",\"Register?\");\n $(\"#login_register\").html(\"Login : \");\n $(\"#login\").attr(\"value\",\"Login!\");\n $(\"#username_div\").attr(\"hidden\",true);\n $(\"#username\").val(\"\");\n\n trying_to_login = true;\n }\n game_restart(); // if user played, logs out then logs back in, need to reload game\n $(\"#login_message\")\n .val(\"\")\n .attr(\"hidden\",true);\n $(\"#email\").val(\"\");\n $(\"#password\").val(\"\");\n\n\n}", "function isAuth() {\n\t\tglobal.bom.settings.btnLogin.innerHTML = global.bom.settings.textLogout;\n\t\tglobal.bom.settings.btnLogin.addEventListener(clickEvent, authentication.logout);\n\t}", "function navLoginClick(evt) {\n console.debug('navLoginClick', evt)\n hidePageComponents()\n $loginForm.show()\n $signupForm.show()\n}", "function navLoginClick(evt) {\n hidePageComponents();\n $loginForm.show();\n $signupForm.show();\n console.debug(\"navLoginClick\", evt);\n}", "function getLogin() {\r\n\r\n var url = \"api/get_login_servlet\";\r\n\r\n $.post(url, null, function (dataFromServer) {\r\n console.log(\"Finished calling servlet.\");\r\n console.log(dataFromServer);\r\n // Update the HTML with our result\r\n if(dataFromServer.indexOf(\"Not logged in.\") == -1)\r\n {\r\n $('#getLoginText').html(dataFromServer);\r\n $('#loginInfo').html(\"Get login info\");\r\n $('#mainTitle').html(\"Welcome!\");\r\n $('#loginID').hide();\r\n $('#loggedInText').html(dataFromServer.substring(dataFromServer.indexOf(\"You are logged in as\")));\r\n $('#logOutDiv').show();\r\n button = $('#login');\r\n button.on(\"click\", getLogin);\r\n }\r\n else\r\n {\r\n $('#getLoginText').html(\"\");\r\n $('#loginInfo').html(\"Login\");\r\n $('#mainTitle').html(\"Login\");\r\n $('#loginID').show();\r\n $('#loggedInText').html(\"\");\r\n $('#logOutDiv').hide();\r\n button = $('#login');\r\n button.off(\"click\", getLogin);\r\n }\r\n });\r\n}", "function handleAuthClick(event) {\r\n\t console.log(\"Authorized button clicked\");\r\n\tgapi.auth2.getAuthInstance().signIn();\r\n }", "function doLogin()\n{\n getSelectedItem();\n // here's the workaround - login functions are with token\n var selected_token = selected_slot.getToken();\n try {\n selected_token.login(false);\n var tok_status = document.getElementById(\"tok_status\");\n if (selected_token.isLoggedIn()) {\n tok_status.setAttribute(\"label\", \n bundle.GetStringFromName(\"devinfo_stat_loggedin\"));\n } else {\n tok_status.setAttribute(\"label\",\n bundle.GetStringFromName(\"devinfo_stat_notloggedin\"));\n }\n } catch (e) {\n doPrompt(bundle.GetStringFromName(\"login_failed\"));\n }\n enableButtons();\n}" ]
[ "0.75020313", "0.745738", "0.74435467", "0.7432854", "0.73764944", "0.7121758", "0.7024859", "0.7013445", "0.69564337", "0.6953437", "0.68890643", "0.6881376", "0.68652344", "0.6841569", "0.68296957", "0.6821401", "0.6796377", "0.6774338", "0.6769635", "0.6756239", "0.6744398", "0.6743955", "0.6743392", "0.67404103", "0.67390776", "0.6715682", "0.6705407", "0.6693873", "0.66741514", "0.66643846", "0.66623706", "0.6655753", "0.66536653", "0.66045773", "0.6590068", "0.65883476", "0.65822285", "0.65810406", "0.65803", "0.6579346", "0.65605474", "0.6554461", "0.654773", "0.652798", "0.6520988", "0.6516945", "0.6515536", "0.6511351", "0.6511292", "0.65093726", "0.6501861", "0.6492157", "0.64868665", "0.6486846", "0.64845043", "0.64836156", "0.64835715", "0.6477919", "0.64695114", "0.644871", "0.6440182", "0.64390093", "0.6438298", "0.6430507", "0.64115673", "0.6408803", "0.63988364", "0.6393329", "0.6392365", "0.63839656", "0.6382419", "0.6382008", "0.6381279", "0.6380242", "0.63785785", "0.63783216", "0.63761854", "0.63730764", "0.6360779", "0.636064", "0.6357373", "0.6357373", "0.6357373", "0.6357373", "0.6354204", "0.6353923", "0.6342629", "0.6341685", "0.63385713", "0.6335805", "0.6330829", "0.6330322", "0.63279396", "0.6327506", "0.632538", "0.6322831", "0.6311436", "0.6309227", "0.63084775", "0.63019043", "0.6291311" ]
0.0
-1
[END buttoncallback] Function used to return current user graduation status based on their user.email.
function returnGradStatus (email, emailVerified) { if (emailVerified) { // Email is verified. // Get domain of email (note: if email is 'abc@abc'@example.com, then this next line won't work properly) var domain = email.replace(/.*@/, ""); // Replaces everything up to and including the @ symbol if (domain === 'alumni.nd.edu') { // true if the address ends with alumni.nd.edu return 'alumni'; } else if (domain === 'nd.edu') { // true if the address ends with nd.edu return 'student'; } else { // address is not of student or alumni return 'error'; } } else { // Email is not verified. return 'error'; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function CheckStatus(){\n \n fire.auth().onAuthStateChanged(\n (user)=>{\n if (user) {\n setUserInfo(user.email)\n }\n }\n )\n }", "function checkUserState() {\n var user = firebaseData.getUser();\n if (user) {\n // logged in - hide this\n document.getElementById('not_logged_in').style.display = 'none';\n document.getElementById('submit_access_reminder').style.display = 'none';\n document.getElementById('not_reader').style.display = null;\n document.getElementById('login_explanation').style.display = null;\n firebaseData.getUserData(user,\n function(firebaseUserData) {\n // got the data\n if (firebaseData.isUserReader(firebaseUserData)) {\n // we are a reader\n document.getElementById('not_reader').style.display = 'none';\n document.getElementById('login_explanation').style.display = 'none';\n }\n else {\n // not a reader\n document.getElementById('not_reader').style.display = null;\n populateRegistrationForm(firebaseUserData);\n }\n if (firebaseUserData['isRequestPending']) {\n // let them send their reminder as the request is pending\n document.getElementById('submit_access_reminder').style.display = null;\n }\n }),\n function(error) {\n // failed\n console.log('failed to get the user data to see if a reader', error);\n document.getElementById('not_reader').style.display = null;\n }\n }\n else {\n // not logged in, show this\n document.getElementById('not_logged_in').style.display = null;\n document.getElementById('not_reader').style.display = 'none';\n document.getElementById('submit_access_reminder').style.display = 'none';\n }\n}", "function userVisitStatus(){\n dataservice.postData(USER_VISIT_API, {}, config).then(function(data, status) {\n if (data) {\n if (data.status) {\n }\n }\n\n }, function() {});\n }", "checkInComplete() {\n if (GoogleSignin.currentUser() != null) {\n StorageController.getCheckinNotifPreference().then((value) => {\n if (value) {\n console.log('Notifying...');\n PushNotification.localNotification({\n title:'Checked In',\n message: 'Just checked you into this event. Have fun!'\n });\n }\n });\n }\n }", "function getEmailStatus() {//here we changed 'gender,emailConfirmation,status' from on to 'male/female/others,Yes/no,Active/Inactive'\n gender = document.querySelectorAll(\"input[name='gender']\");\n gender.forEach(function (elements) {\n if (elements[\"checked\"]) {\n gender = elements.previousSibling.previousSibling.innerText;\n }\n });\n emailConfirmation = document.querySelectorAll(\"input[name='emailConfirmation']\");\n emailConfirmation.forEach(function (elements) {\n if (elements[\"checked\"]) {\n emailConfirmation = elements.previousSibling.previousSibling.innerText;\n }\n });\n status = document.querySelectorAll(\"input[name='status']\");\n status.forEach(function (elements) {\n if (elements[\"checked\"]) {\n status = elements.previousSibling.previousSibling.innerHTML;\n }\n });\n }", "function profileCallback(){\r\n\t\t// Constants from the HTML page\r\n\t\tconst profile_name = document.querySelector('#profile_name');\r\n\t\tconst profile_firstname = document.querySelector('#profile_firstname');\r\n\t\tconst profile_email = document.querySelector('#profile_email');\r\n\t\tconst profile_submit = document.querySelector('#profile_submit');\r\n\t\t\r\n\t\t// Get the user information\r\n\t\tdb.collection('users').doc(user.uid).get().then((doc) => {\r\n\t\t\tprofile_name.value = doc.data().name;\r\n\t\t\tprofile_firstname.value = doc.data().firstName;\r\n\t\t\tprofile_email.value = user.email;\r\n\t\t\tdiv.style.display = \"none\";\r\n\t\t});\r\n\r\n\t\t// Update the email address\r\n\t\tprofile_submit.addEventListener('click', (e) => {\r\n\t\t\te.preventDefault();\r\n\t\t\t// Request user password\r\n\t\t\tvar password = prompt(\"Please enter your password:\", \"\");\r\n\t\t\tif (password == null || password == \"\") {\r\n\t\t\t\talert(\"Your email was not updated\");\r\n\t\t\t} else {\r\n\t\t\t\t// Update email address\r\n\t\t\t\tauth.signInWithEmailAndPassword(user.email, password)\r\n\t\t\t\t .then((userCredential) => {\r\n\t\t\t\t // Signed in\r\n\t\t\t\t var user = userCredential.user;\r\n\r\n\t\t\t\t user.updateEmail(profile_email.value).then(() => {\r\n\t\t\t\t\t \talert(\"Email was modified with success\");\r\n\t\t\t\t\t });\r\n\t\t\t\t\t })\r\n\t\t\t\t\t\t.catch((error) => {\r\n\t\t\t\t\t\t\t// Error\r\n\t\t\t\t\t\t\talert(\"An error has occured, please try again.\");\r\n\t\t\t\t });\r\n\t\t\t}\r\n\t\t});\r\n\t}", "function updateOnlineStatusOfClients(all_occupants_details){\n //first every user's status label to offline\n $(\".online_status\").text(' (Offline) ').css('color', '#C0C0C0');\n\n //then update the online status based on logged in clients.\n for(var i=0; i<all_occupants_details.length; i++){\n var userEmail = all_occupants_details[i].email;\n $('#online_status_'+convertEmailToID(userEmail)).text(' (Online) ').css('color', '#0f0');\n }\n}", "function updateOnlineStatusOfClients(all_occupants_details){\n //first every user's status label to offline\n $(\".online_status\").text(' (Offline) ').css('color', '#C0C0C0');\n\n //then update the online status based on logged in clients.\n for(var i=0; i<all_occupants_details.length; i++){\n var userEmail = all_occupants_details[i].email;\n $('#online_status_'+convertEmailToID(userEmail)).text(' (Online) ').css('color', '#0f0');\n }\n}", "function user_status(status){\n\tif(status == \"VISIBLE\"){\n \tajax_call(status)\n\t}\n\telse{\n\n\t\tvar result=confirm(\"Your 10 point will be deducted.Are you sure to Continue? if credit is not present then buy for inactivating your account.\");\n\t\tif (result==true)\n\t\t {\n\t\t ajax_call(status) \n\t\t }\n\t\telse\n\t\t {\n\t\t jQuery(\"#visibility_status\").val(\"VISIBLE\");\n\t\t }\n\n\t}\n}", "function getStatusUserByStatus(statusID) {\n\n}", "function checkNewUserStatus(e){\n var newUserStatus = localStorage.getItem(\"newUserStatus\");\n //console.log(something);\n if (newUserStatus){\n //show intro div\n alert(something);\n } else if (!newUserStatus){\n //show direction div\n alert(\"Oops something went wrong\");\n }\n \n return userStatus;\n}", "function addUserStatusToDb(email) {\n db.collection(\"users\")\n .get()\n .then((snapshot) =>\n snapshot.docs.forEach((doc) => {\n if (email === doc.data().email) {\n let id = doc.id;\n db.collection(\"users\").doc(id).update({ signedIn: true });\n let email = doc.data().email;\n let first = doc.data().firstname;\n let last = doc.data().lastname;\n let status = true;\n //Add message to user on login\n let para = document.createElement(\"p\");\n let node = document.createTextNode(`Welcome ${first} ${last}!`);\n para.appendChild(node);\n let element = document.getElementById(\"div1\");\n element.appendChild(para);\n addUserToState(first, last, email, status);\n }\n })\n );\n}", "function CheckUserStatus () { // check if he is a premium user or not\n var userStatus = JSON.parse(localStorage.getItem('userStatus'));\n if (userStatus.indexOf(\"premium\") != -1) {\n document.getElementById(\"downgrade\").style.display = \"block\";\n document.getElementById(\"upgrade\").style.display = \"none\";\n } else {\n document.getElementById(\"upgrade\").style.display = \"block\";\n document.getElementById(\"downgrade\").style.display = \"none\";\n }\n}", "function master(userName, userEmail, total) {\r\n if (isValidName(userName) === false) {\r\n nameSpan.style.display = '';\r\n nameSpan.style.color = 'red';\r\n }\r\n if (isValidEmail(userEmail) === false) {\r\n emailSpan.style.display = '';\r\n emailSpan.style.color = 'red';\r\n } \r\n if (isActivityValid(total) === false) {\r\n activitySpan.style.display = '';\r\n activitySpan.style.color = 'red';\r\n } \r\n if (isValidName(userName) === true && isValidEmail(userEmail) === true && isActivityValid(total) === true) {\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n}", "function checkStatus() {\n\n var users = getUsers();\n // variable count is used to monitor how many users are loged in, if more than\n // one then it sets the loged in status of all users to false\n var count = 0;\n\n for(var k = 0; k < users.length; k++) {\n if(users[k].loggedIn == true) {\n loggedIn = [true, k];\n count += 1;\n }\n }\n //if user is logged in changes the login tab to user information tab\n if(loggedIn[0] && count == 1) {\n if(document.getElementById(\"LoggedInAs\") != null && document.getElementById(\"playersHighscore\") != null) {\n document.getElementById(\"LoggedInAs\").innerHTML = \"Logged in as: \" + users[loggedIn[1]].name;\n document.getElementById(\"playersHighscore\").innerHTML = \"Highest score: \" + users[loggedIn[1]].score;\n selectTab(event, 'logedIn');\n } else {\n //sets the login / sign up value inside the navigation bar to a users username\n document.getElementById(\"user\").innerHTML = users[loggedIn[1]].name;\n }\n } else {\n for(var l = 0; l < users.length; l++) {\n users[l].loggedIn = false;\n }\n }\n }", "function listenMembersStatus(chatID) {\n unsubscribeMembersStatus = db.collection(\"users\").onSnapshot(function (snapshot) {\n snapshot.docChanges().forEach(function (change) {\n if (change.type == \"modified\") {\n var changedUserData = change.doc.data();\n db.collection(\"chatMembers\").doc(chatID).get().then(function (chatMembers) {\n if (document.getElementById(changedUserData.email)) {\n // Determine current and old status of the user with changed data \n var currentStatus = changedUserData.loggedIn ? \"logged-in\" : \"logged-out\";\n var oldStatus;\n if (!document.getElementById(changedUserData.email).parentElement.classList.contains(currentStatus)) {\n oldStatus = currentStatus == \"logged-in\" ? \"logged-out\" : \"logged-in\";\n }\n // Determine if user is a user of the active chat and compare to see if current and old status are the same, if not then need to update the button on front end \n if (chatMembers.data()[changedUserData.email] && currentStatus != oldStatus) {\n document.getElementById(changedUserData.email).parentElement.classList.replace(oldStatus, currentStatus);\n }\n }\n })\n }\n })\n })\n}", "function onNewUserCreationCallBack(data) {\n\t\tvar create_status = data.status;\n\t\tif (create_status == 0) {\n \tprependInfoDiv($(\"#user_reg\"), \"user_reg_status_info\", \"We send out a verification email to \" + data.email);\n\t\t}\n\t\telse if (create_status == 1) {\n\t\t\tprependInfoDiv($(\"#user_reg\"), \"user_reg_status_info\", \"This email has already been used.\");\t\n\t\t}\n\t\telse if (create_status == 2) {\n\t\t\tprependInfoDiv($(\"#user_reg\"), \"user_reg_status_info\", \"This email is waiting for verification.\");\n\t\t}\n\t\telse if (create_status == 9) {\n\t\t\tprependInfoDiv($(\"#user_reg\"), \"user_reg_status_info\", \"Database Error\");\n\t\t}\n\t\telse {}\n\t}", "function authStateObserver(user) {\r\n if (user) { // User is signed in!\r\n //alert(\"Logged In\");\r\n $('#signin').hide();\r\n $('#checkPage').removeClass('hide');\r\n\r\n $('#msg').text(\"Please click the green button below to detect fake news!\");\r\n\r\n\r\n\r\n // We save the Firebase Messaging Device token and enable notifications.\r\n //saveMessagingDeviceToken();\r\n } else { // User is signed out!\r\n // Hide user's profile and sign-out button.\r\n //alert(\"Please login!\");\r\n $('#msg').text(\"Please login to detect fake news!\");\r\n }\r\n}", "function updateCurrentStatus(user) {\n $(\"#current-status\").empty().append(\n `<h4>` + user[\"family_name\"] + \", \" + user[\"given_name\"] + `</h4>\n <h4>UIN: ` + user[\"uin\"] + `</h4>\n <p>Current Entry Status = ` + user[\"status\"] + `</p>`\n ).show();\n}", "updateSigninStatus(isSignedIn) {\n this.setState({isSignedIn, checkedSignIn: true})\n if (isSignedIn) {\n const googleUser = window.gapi.auth2.getAuthInstance().currentUser.get().getBasicProfile();\n\n const profile = {\n name: googleUser.getName(),\n email: googleUser.getEmail(),\n imageUrl: googleUser.getImageUrl()\n }\n\n this.setState({profile})\n\n this.getLabels();\n this.getEmails('me', '', this.state.selectedLabel, this.getEmailMetaData)\n }\n }", "function googleSignInComplete(googleUser) {\n\n let userEmail = googleUser.getBasicProfile().getEmail();\n authuserID = googleUser.getAuthResponse().session_state.extraQueryParams.authuser;\n\n // Add the user email address to the signed in button.\n document.getElementById('signedInAs').innerHTML =\n '<span class=\"gmailSignedInText\">as <u>' +\n userEmail + '</u></span>' +\n '<img class=\"gmailImage\" src=\"' + googleUser.getBasicProfile().getImageUrl() + '\" alt=\"\"/>';\n\n // Change the please click sign in paragraph.\n document.getElementById(\"pleaseClickSignInParagraph\").innerText =\n 'You are currently signed in to a Google account. If this is not your primary Google account, logout of the account and change into your primary Google account now.';\n\n isSignedIn = true;\n survey.setValue('isSignedIn', 'true');\n\n survey.setValue('SSOEmailAddress', userEmail);\n\n // Setup the sign-in state change listener.\n gapi.load('auth2', function() {\n // Retrieve the singleton for the GoogleAuth library and set up the client.\n let auth2 = gapi.auth2.init({\n client_id: '353069496362-4a8fuq2fs5crocmm1eaqqnm0bgn9m4mq.apps.googleusercontent.com'\n });\n\n // Listen for sign-in state changes.\n auth2.isSignedIn.listen(afterSignIn);\n });\n}", "function statusChangeCallback(response) {\n\t // The response object is returned with a status field that lets the\n\t // app know the current login status of the person.\n\t // Full docs on the response object can be found in the documentation\n\t // for FB.getLoginStatus().\n\t if (response.status === 'connected') {\n\t \t// Logged into your app and Facebook.\n\t \tconsole.log('Welcome! Fetching your information.... ');\n\t\t\tvar url = '/me?fields=first_name,last_name,email';\n\t\t\tFB.api(url, function (response) {\n\t\t\t\tresponse['type'] = 'Facebook';\n\t\t\t\tuserObj = response;\n\t\t\t\tif(response.email === undefined) {\n\t\t\t\t\t$.ajax({url:'/user-manager/getBySocialId?id='+response.id,type:'get',success:function(docRes) {\n\t\t\t\t\t\tif(docRes.success) {\n\t\t\t\t\t\t\tif(docRes.data[0]._email === null || docRes.data[0]._email === undefined) {\n\t\t\t\t\t\t\t\t$('#userEmailAddress').modal({backdrop: 'static',keyboard: false});\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tuserObj['email_exception'] = true;\n\t\t\t\t\t\t\t\tsendLoginInfo(userObj);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$('#userEmailAddress').modal({backdrop: 'static',keyboard: false});\n\t\t\t\t\t\t}\n\t\t\t\t\t}});\n\t\t\t\t} else {\n\t\t\t\t\tuserObj['email_exception'] = false;\n\t\t\t\t\tsendLoginInfo(userObj);\n\t\t\t\t}\n\t\t },{scope: 'public_profile,email'});\n\t } else {\n\t \tconsole.log('user closed dialog')\n\t \t$('.fa-spin').remove();\n\t // The person is not logged into your app or we are unable to tell.\n\t //document.getElementById('status').innerHTML = 'Please log ' +\n\t //'into this app.';\n\t }\n\t}", "function getUserOnlineStatus(selUser) {\n var connectStatus = \"\";\n var connectedUser = connectedUserList.find(function(oneUser) {\n return oneUser.email === selUser.email;\n });\n if(connectedUser) {\n connectStatus = \"online\";\n }\n else {\n connectStatus = \"offline\";\n }\n\n var contactUser = contactList.find(function (oneUser) {\n return oneUser.email === selUser.email;\n });\n\n var state = \"\";\n if(contactUser) {\n switch (contactUser.state) {\n case 'CONTACTED':\n state = \"status contacted-\";\n break;\n case 'ADDED':\n state = \"status added-\";\n break;\n case 'INVITED':\n state = \"status invited-\";\n break;\n case 'REMOVED':\n state = \"status away-\";\n break;\n case 'DECLINED':\n state = \"status declined-\";\n break;\n }\n }\n else {\n state = \"status away-\";\n }\n\n return state + connectStatus;\n}", "function onSignIn(googleUser) {\n console.log('User signed in!');\n var profile = googleUser.getBasicProfile();\n //change userName text, img source, & email text based on profile\n $(\"h1\").text(\"Welcome, \" + profile.getName());\n // $(\"img\").attr(\"src\", profile.getImageUrl());\n // $(\".email\").text(profile.getEmail());\n}", "checkForUserEmail(results) {\n // check if user email is in dbs\n // TO DO function calls based on what emerges\n apiCalls.checkUserByEmail(results.email).then(results => {\n if (results.data.data === \"new user\") {\n console.log(\"build new user\");\n } else {\n console.log(\"update old user\");\n }\n });\n }", "async function extract_ready_status_from_user(user_email_str, database)\n {\n let collection_str =\n await user_exists_in_this_collection(user_email_str, database);\n\n // IF USER COULD NOT BE FOUND IN DATABASE \n if(!collection_str)\n return -1234;\n \n // AT THIS POINT, WE CAN ASSUME THAT THE USER EXISTS IN THE DATABASE\n let database_results_array =\n await database.collection(collection_str).find( {email : user_email_str} ).toArray();\n \n return database_results_array[0].ready_status;\n }", "function authStateObserver(user) {\n if (user) { // User is signed in!\n // Get the signed-in user's profile pic and name.\n var profilePicUrl = getProfilePicUrl();\n var userName = getUserName();\n\n // Display add buttons if user logged in\n if (addResourceBtn) addResourceBtn.style.display = \"block\";\n if (addSpaceBtn) addSpaceBtn.style.display = \"block\";\n if (addCollectionBtn) addCollectionBtn.style.display = \"block\";\n\n // Set the user's profile pic and name.\n userPicElement.style.backgroundImage = 'url(' + addSizeToGoogleProfilePic(profilePicUrl) + ')';\n userNameElement.textContent = userName;\n\n // Show user's profile and sign-out button.\n userNameElement.removeAttribute('hidden');\n userPicElement.removeAttribute('hidden');\n signOutButtonElement.removeAttribute('hidden');\n\n // Hide sign-in button.\n signInButtonElement.setAttribute('hidden', 'true');\n\n if (window.location.href.indexOf(\"space\") > -1) {\n // on a space page so therefore messaging functonality\n // We save the Firebase Messaging Device token and enable notifications.\n saveMessagingDeviceToken();\n\n } else {\n // on a resource page so therefore commenting functionality\n // We save the Firebase Commenting Device token and enable notifications.\n saveCommentingDeviceToken();\n }\n\n } else { // User is signed out!\n if (userNameElement) {\n // Hide user's profile and sign-out button.\n userNameElement.setAttribute('hidden', 'true');\n userPicElement.setAttribute('hidden', 'true');\n signOutButtonElement.setAttribute('hidden', 'true');\n\n // Show sign-in button.\n signInButtonElement.removeAttribute('hidden');\n }\n }\n}", "function onSignIn(googleUser) {\n console.log('User signed in!');\n var profile = googleUser.getBasicProfile();\n //change userName text, img source, & email text based on profile\n $(\".userName\").text(profile.getName());\n $(\"img\").attr(\"src\", profile.getImageUrl());\n $(\".email\").text(profile.getEmail());\n}", "graduate() {\n if (this.grade > 70) {\n this.isGraduated = true;\n console.log(`${this.name} has enough points to graduate!`);\n } else {\n console.log(`${this.name} does not have enough points to graduate.`);\n }\n }", "function toggleSignIn() {\n if (!firebase.auth().currentUser) {\n var provider = new firebase.auth.GoogleAuthProvider();\n // [START signin]\n firebase.auth().signInWithPopup(provider).then(function(result) {\n // User is authenticated.\n var user = result.user; // The signed-in user info\n\n // Store user uid, displayName, and email\n sessionStorage.setItem(\"uid\", user.uid);\n sessionStorage.setItem(\"displayName\", user.displayName);\n sessionStorage.setItem(\"email\", user.email);\n\n // Store in session the graduation status of the user; if not a student/alumni, show error message.\n gradStatus = returnGradStatus(user.email, user.emailVerified)\n\n // Determine if account can enter app.\n if (gradStatus !== 'error') {\n sessionStorage.setItem(\"gradStatus\", gradStatus);\n // Go to app main page.\n window.location.href = \"main.html\";\n } else {\n // Signout user.\n firebase.auth().signOut();\n // Re-enable button.\n document.getElementById('quickstart-sign-in').disabled = false;\n // Error message (user is not verified, or not a student or alumni)\n sweetAlert(\"Oops!\", \"Please use a Notre Dame e-mail account.\", \"error\");\n }\n }).catch(function(error) {\n // Handle Errors here.\n var errorCode = error.code;\n var errorMessage = error.message;\n\n var email = error.email; // The email of the user's account used.\n var credential = error.credential; // The firebase.auth.AuthCredential type that was used.\n\n if (errorCode === 'auth/account-exists-with-different-credential') {\n alert('You have already signed up with a different auth provider for that email.');\n // If you are using multiple auth providers on your app you should handle linking\n // the user's accounts here.\n } else {\n console.error(error);\n }\n });\n // [END signin]\n } else {\n // [START signout]\n // Confirm logout sweetAlert.\n swal({\n title: \"Are you sure?\",\n text: \"Do you want to logout?\",\n type: \"warning\",\n showCancelButton: true,\n closeOnConfirm: false,\n confirmButtonText: \"Yes, logout!\",\n confirmButtonColor: \"#ec6c62\"\n },\n function(isConfirm){\n if (isConfirm) {\n // Logout confirmed.\n firebase.auth().signOut();\n console.log(\"logging out\");\n window.location.href = \"index.html\";\n } else {\n // Logout canceled.\n }\n });\n // [END signout]\n }\n $('#quickstart-sign-in').disabled = true;\n}", "function onAuthStateChanged(user) {\n if (user) {\n user.reload();\n if (user.emailVerified ) {\n\n functions().httpsCallable('verifyEmail')({uid:auth().currentUser.uid}).then((result) => {\n if (result) {\n console.log('verify email result', result)\n }\n }).catch((error) => {\n console.log('verify email error', error)\n\n });\n }\n\n }\n\n\n\n\n }", "function onAuthStateChange(user) {\n if (user) {\n\n // in caz ca este logat\n\n var email = user.email;\n var userId = user.uid;\n user_uid = userId;\n\n // vom face apel la baza de date pentru a prelua datele despre acesta\n\n firebase.database().ref('/users/' + userId).once('value').then(function (snapshot) {\n document.getElementById('username').innerText = snapshot.val().first_name + ' ' + snapshot.val().last_name;\n renderDbValuesToHtml(snapshot.val());\n user_stats = snapshot.val().stats;\n\n });\n }\n else\n {\n // in cazul in care iese din aplicatie, va fi redirectionat la pagina de start\n\n window.location = '../Start.html';\n }\n}", "function get_status_towards_this_user(user_email_str, candidates_array)\n {\n let status_int = -1;\n \n // GO THROUGH ALL CANDIDATES\n for(let i = 0; i < candidates_array.length; ++i)\n {\n if(candidates_array[i].email === user_email_str)\n {\n status_int = candidates_array[i].status;\n break;\n }\n }\n \n return status_int;\n }", "function getStatusUpdate(callback) {\n var queryParamString = \"type=getStatus\";\n queryParamString += \"&username=\" + AccountServices.username;\n\n var uri = REQUEST_URL + \"?\" + queryParamString;\n\n if (DEBUG) {\n console.log(\"getStatusUpdate: \" + uri);\n }\n\n request({\n uri: uri\n }, function (error, response) {\n if (error || !response || response.status !== \"success\") {\n console.error(\"Error with getStatus: \" + JSON.stringify(response));\n } else if (response.data.userStatus.toLowerCase() !== \"offline\") {\n currentStatus = response.data.userStatus;\n editStatusOverlays();\n }\n \n callback();\n });\n }", "function getEmail(){\n// Load the oauth2 libraries to enable the userinfo methods.\n gapi.client.load('oauth2', 'v2', function() {\n var request = gapi.client.oauth2.userinfo.get();\n request.execute(getEmailCallback);\n });\n}", "async function checkFuelStatus (userUrl, authHeadersActual, event) {\n const fuelState = await axios.get(`https://${userUrl}/api/states/sensor.dmb8668_fuel_level`, {\n headers: authHeadersActual\n })\n web.chat.postMessage({\n channel: event.channel,\n text: `Your fuel percentage remaining is *${fuelState.data.state}%*.`\n })\n}", "updateUserStatus(state) {\n state.userSignUpStatus = \"Sign up Successful!\"\n console.log(state.userSignUpStatus)\n }", "function updateSigninStatus() {\n if (window.gapi.auth2.getAuthInstance().isSignedIn.get()) {\n // authorizeButton.style.display = 'none';\n // signoutButton.style.display = 'block';\n listUpcomingEvents();\n } else {\n // authorizeButton.style.display = 'block';\n // signoutButton.style.display = 'none';\n }\n }", "function checkuserstatus() {\n //资料等待提交\n $(\"#datadsubmit\").hide();\n// divhide('datadsubmit');\n //资料正在审核中\n $(\"#dataaudit\").hide();\n// divhide('dataaudit');\n //资料审核通过\n $(\"#datathrough\").hide();\n// divhide('datathrough');\n //资料被打回\n $(\"#databackto\").hide();\n// divhide('databackto');\n //资料已被拒绝\n $(\"#datarefused\").hide();\n// divhide('datarefused');\n if (localStorage.int32_apply_status != null) {\n switch (localStorage.int32_apply_status) {\n case \"0\":\n //资料等待提交\n divshow('datadsubmit');\n break;\n case \"1\":\n /*Data are waiting for the audit*/\n case \"2\":\n //资料正在审核中\n divshow('dataaudit');\n break;\n case \"3\":\n //资料审核通过\n// localStorage.int32_limit_amount\n $(\"#liamount\").html(500);\n divshow('datathrough');\n break;\n case \"4\":\n //资料被打回\n divshow('databackto');\n break;\n case \"5\":\n //资料已被拒绝\n divshow('datarefused');\n divshow('li_moreloan');\n break;\n }\n }\n}", "function checkNotification (user, admin, callback) {\n\tgetLastCheckIn(user, admin, function (err, previous) {\n\t\tif (previous === undefined) {\n\t\t\tconsole.log(\"No Checkins for user\");\n\t\t\treturn callback(null);\n\t\t}\n\t\tvar checkInInterval = admin.requiredCheckIn;\n\t\tvar reminderTime = admin.reminderTime;\n\t\tvar notifyEmergencyContact = admin.emergencyTime;\n\t\tvar overdueTime = admin.overdueTime;\n\t\tif (previous.type === 'Check In' || previous.type === 'Start') {\n\t\t\tvar timeNow = moment();\n\t\t\tvar previousTime = moment(previous.timestamp, 'ddd, MMM Do YYYY, h:mm:ss a Z', 'en');\n\t\t\tvar timeDiff = timeNow.diff(previousTime, 'minutes'); // get time difference in mins\n\t\t\tconsole.log(previous.name + \" last check in was \" + timeDiff + \" minutes ago\");\n\t\t\tif (timeDiff >= (checkInInterval - reminderTime)) {\n\t\t\t\tconsole.log(\"In Reminder/Overdue\");\n\t\t\t\tvar tech = previous.username;\n\t\t\t\tvar dontSend = false;\n\t\t\t\t// Stop sending messages if it's been too long\n\t\t\t\tif (timeDiff < (checkInInterval + notifyEmergencyContact)) {\n\t\t\t\t\tconsole.log(\"Checking if: \" + timeDiff + \" is less than \" + (checkInInterval + notifyEmergencyContact));\n\t\t\t\t\tvar overdueAlert = timeDiff >= (checkInInterval + overdueTime);\n\t\t\t\t\tconsole.log(\"Reminders are: \" + (user.reminders ? 'ON' : 'OFF'));\n\t\t\t\t\tconsole.log(\"Notifications are: \" + (user.notifications ? 'ON' : 'OFF'));\n\t\t\t\t\tconsole.log(\"Checking if: \" + timeDiff + \" > \" + checkInInterval);\n\t\t\t\t\tif (timeDiff > checkInInterval && user.reminders) {\n\t\t\t\t\t\tconsole.log(\"OVERDUE REMINDER\");\n\t\t\t\t\t\tvar message = \"You are \" + (-(checkInInterval - timeDiff)) + \" minutes overdue for Check In!\";\n\t\t\t\t\t\tvar subject = \"OVERDUE WARNING\";\n\t\t\t\t\t}\n\t\t\t\t\telse if (timeDiff < checkInInterval && user.notifications) {\n\t\t\t\t\t\tconsole.log(\"NORMAL REMINDER\");\n\t\t\t\t\t\tvar message = \"You are due for a Check In in \" + (checkInInterval - timeDiff) + \" minutes\";\n\t\t\t\t\t\tvar subject = \"REMINDER NOTIFICATION\"\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\tconsole.log(\"Setting dontSend to: true\");\n\t\t\t\t\t\tdontSend = true;\n\t\t\t\t\t}\n\t\t\t\t\tif (!dontSend) {\n\t\t\t\t\t\tconsole.log(\"Sending REMINDER/OVERDUE Notification\");\n\t\t\t\t\t\tvar emailObj = {\n\t\t\t\t\t\t\tto: user.email,\n\t\t\t\t\t\t\ttext: message,\n\t\t\t\t\t\t\tsubject: subject\n\t\t\t\t\t\t}\n\t\t\t\t\t\tsendEmail(emailObj, function (err) {\n\t\t\t\t\t\t\tif (err) { \n\t\t\t\t\t\t\t\tvar emailError = {\n\t\t\t\t\t\t\t\t\tto: process.env.ERROR_EMAIL,\n\t\t\t\t\t\t\t\t\tsubject: \"Error sending email to \" + user.email,\n\t\t\t\t\t\t\t\t\ttext: err\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tsendEmail(emailError);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t\tconsole.log(\"OVERDUE ALERT (ADMIN/VIEW USERS): \" + overdueAlert);\n\t\t\t\t\tif (overdueAlert) {\n\t\t\t\t\t\tvar massEmail = {\n\t\t\t\t\t\t\ttext: user.firstName + \" \" + user.lastName + \" (\" + user.username + \") is \" \n\t\t\t\t\t\t\t\t+ (-(checkInInterval - timeDiff)) + \" minutes overdue for check in!\",\n\t\t\t\t\t\t\tsubject: subject\n\t\t\t\t\t\t}\n\t\t\t\t\t\tconsole.log(\"Admin notifications are \" + (admin.overdueNotifications ? 'ON' : 'OFF'));\n\t\t\t\t\t\tif (admin.overdueNotifications) {\n\t\t\t\t\t\t\tmassEmail.to = admin.email;\n\t\t\t\t\t\t\tsendEmail(massEmail);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tgetViewUsers(admin, function (err, viewUsers) {\n\t\t\t\t\t\t\tif (err) {\n\t\t\t\t\t\t\t\tvar emailError = {\n\t\t\t\t\t\t\t\t\tto: process.env.ERROR_EMAIL,\n\t\t\t\t\t\t\t\t\tsubject: \"Error getting view users for \" + admin.username,\n\t\t\t\t\t\t\t\t\ttext: err\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tsendEmail(emailError);\n\t\t\t\t\t\t\t\tthrow err;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif (viewUsers.length !== 0) {\n\t\t\t\t\t\t\t\tviewUsers.forEach(function (viewUser) {\n\t\t\t\t\t\t\t\t\tif (viewUser !== undefined) {\n\t\t\t\t\t\t\t\t\t\tconsole.log(viewUser.username + \" has notifications \" + (viewUser.notifications ? 'ON' : 'OFF'));\n\t\t\t\t\t\t\t\t\t\tif (viewUser.notifications) {\n\t\t\t\t\t\t\t\t\t\t\tmassEmail.to = viewUser.email;\n\t\t\t\t\t\t\t\t\t\t\tsendEmail(massEmail);\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tcallback(null);\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\tcallback(null);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t// Ensure they are only sent a message once\n\t\t\t\t\tconsole.log(\"Checking if: \" + timeDiff + \" is less than \" + (checkInInterval + notifyEmergencyContact + runInterval));\n\t\t\t\t\tif (timeDiff < (checkInInterval + notifyEmergencyContact + runInterval)) {\n\t\t\t\t\t\tconsole.log(\"In Emergency Noticications\");\n\t\t\t\t\t\tif (user.emergencyContact.email !== '') {\n\t\t\t\t\t\t\tconsole.log(\"Sending EMERG msg to \" + user.emergencyContact.email);\n\t\t\t\t\t\t\tvar mailOpts = {\n\t\t\t\t\t\t\t\tto: user.emergencyContact.email,\n\t\t\t\t\t\t\t\tsubject: user.firstName + \" \" + user.lastName + ' is overdue for Check In',\n\t\t\t\t\t\t\t\thtml : '<p>' + user.firstName + \" \" + user.lastName + ' (' + user.username + ')'\n\t\t\t\t\t\t\t\t\t+ ' is overdue by ' + (timeDiff - checkInInterval) + ' minutes! Please ' \n\t\t\t\t\t\t\t\t\t+ 'ensure they are safe.</p><p><strong>You will only receive this email' \n\t\t\t\t\t\t\t\t\t+ ' once</strong></p>'\n\t\t\t\t\t\t\t};\n\t\t\t\t\t\t\tsendEmail(mailOpts);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (user.emergencyContact.phone !== '') {\n\t\t\t\t\t\t\tconsole.log(\"Sending EMERG text to \" + user.emergencyContact.phone);\n\t\t\t\t\t\t\tvar phoneOpts = {\n\t\t\t\t\t\t\t\tphone: user.emergencyContact.phone,\n\t\t\t\t\t\t\t\tbody: user.firstName + \" \" + user.lastName + \" is overdue by \" + (timeDiff - checkInInterval) \n\t\t\t\t\t\t\t\t\t+ \" minutes. Please ensure they are safe. You will only get this message once.\"\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tsendText(phoneOpts);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\tconsole.log(\"Emergency contact already notified.\");\n\t\t\t\t\t}\n\t\t\t\t\tcallback(null);\n\t\t\t\t}\n\t\t\t}\n\t\t\telse {\n\t\t\t\tconsole.log(timeDiff + \" not >= \" + (checkInInterval - reminderTime));\n\t\t\t\tconsole.log(\"NO ACTION TAKEN\");\n\t\t\t\tcallback(null);\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\tconsole.log('Last checkin was END');\n\t\t\tcallback(null);\n\t\t}\n\t});\n}", "function status () {\n return request({\n url: '/memberProfile/webget?expand=memberType',\n method: 'get'\n })\n}", "function authStateObserver(user) {\n if (user) { // User is signed in!\n // Get the signed-in user's profile pic and name.\n document.getElementById(\"userID\").innerHTML = getUserName();\n } else { // User is signed out!\n location.href=\"/index.html\";\n }\n}", "function checkForUserProfile() {\n \n dataservice.getData(LENDER_INFO_API, {}, config).then(function(data, status) {\n if (data) {\n if (data.status) {\n if(data.data.ifsc!=\"\" && data.data.ifsc!=undefined){\n $rootRouter.navigate(['Payment']);\n }\n else{\n $('#lenderInfoModal').modal({\n backdrop: 'static',\n keyboard: false\n });\n }\n\n }\n }\n }, function() {\n $('#lenderInfoModal').modal({\n backdrop: 'static',\n keyboard: false\n });\n });\n\n }", "function getStatus() {\n // var getAccountButton = document.getElementById('getAccount');\n // getAccountButton.onclick = getAccountFeed;\n \n //var getDataButton = document.getElementById('getData');\n //getDataButton.onclick = getDataFeed;\n\n var gaPanel = document.getElementById('_ga_panel');\n var loginButton = document.getElementById('_ga_authButton');\n \n if (!google.accounts.user.checkLogin(scope)) {\n gaPanel.style.display = 'none'; // hide control div\n loginButton.innerHTML = 'Access Google Analytics';\n } else {\n gaPanel.style.display = 'block'; // hide control div\n loginButton.innerHTML = 'Logout from Google Analytics account';\n \n if (document.getElementById('tableId').innerHTML) {\n \tgetDataFeed();\n };\n \n }\n}", "function gpSignInCallback() {\n\tvar profile = googleUser.getBasicProfile();\n\tvar id_token = googleUser.getAuthResponse().id_token;\n\t$('#fg_token').val(id_token);\n\t$('#fg_id').val(profile.getId());\n\t$('#fgl_id').val(profile.getId());\n\t$('#fgl_token').val(id_token);\n\t$('#fgl_type').val('Google');\n\t$('#fg_type').val('Google');\n\tif(!is_social_signin) {\n\t\tisAlreadySignedUP(function() {\n\t\t\t$('#fgl_form').submit();\n\t\t}, function() {\n\t\t\t$('#fg_name').val(profile.getName());\n\t\t\t$('#fg_email').val(profile.getEmail());\n\t\t\tsecondStageSocialSignUp();\n\t\t}, null);\n\t\t$('#otp_container').hide('slow');\n\t} else {\n\t\tisAlreadySignedUP(function() {\n\t\t\t$('#fgl_form').submit();\n\t\t}, function() {\n\t\t\t$('#s_login_error').show('slow');\n\t\t\t$('#s_login_error').html('You have to SignUp using Google');\n\t\t}, null);\n\t}\n}", "function onSignIn(googleUser) {\n\n var profile = googleUser.getBasicProfile();\n var userID = profile.getId();\n var userName = profile.getName();\n var userPicture = profile.getImageUrl();\n var userEmail = profile.getEmail();\n var userToken = googleUser.getAuthResponse().id_token;\n\n\n if (userEmail !== '') {\n var dados = {\n userID: userID,\n userName: userName,\n userPicture: userPicture,\n userEmail: userEmail\n };\n $.post('valida.php', dados, function (retorna) {\n if (retorna === '\"erro\"') {\n // var msg = \"Usuário no encontrado com esse e-mail\";\n mensage = \"Usuario Gmail no registrado en Korpovibro\";\n shakeModalVerificar(mensage);\n\n //\tdocument.getElementById('msg').innerHTML = msg;\n } else {\n \n //window.location.href = retorna;\n var n = 3;\n var l = document.getElementById(\"number\");\n window.setInterval(function () {\n l.innerHTML = n;\n n--;\n }, 700);\n\n setTimeout(function () {\n\n window.location.href = retorna;\n\n }, 2000);\n mensage = \"Usuario Gmail validado en Korpovibro\";\n shakeModalVerificarG(mensage);\n }\n\n });\n } else {\n var msg = \"Usuário no encontrado!\";\n //document.getElementById('msg').innerHTML = msg;\n\n }\n}", "function authStateObserver(user) {\n if (user) { // User is signed in!\n // Get the signed-in user's profile pic and name.\n firebase.firestore().collection('gamelist').doc(sessionStorage.gameID).get().then(function(doc){\n if (doc.data().status==\"ready\"){\n alert(\"아직 게임이 시작되지 않아 사용할 수 없습니다.\");\n location.href=\"../index.html\";\n }\n if (doc.data().status==\"on\")\n updateGameInfo();\n else\n finalGameInfo();\n var url = getProfilePicUrl();\n\n document.getElementById(\"userpic\").setAttribute(\"src\", url);\n document.getElementById(\"userID\").innerHTML = getUserName();\n document.getElementById(\"userID2\").innerHTML = getUserName();\n });\n //because it is not reveal day, removed user name and pic in guess columns.\n } else { // User is signed out!\n location.href=\"../index.html\";\n }\n}", "async function fetchUserStatus() {\n await AsyncStorage.getItem(\"userToken\")\n .then(async (token) => {\n await apiGetUserStatus(token)\n .then((res) => {\n //all is well\n })\n .catch((error) => {\n //user access denied\n signOut();\n });\n })\n .catch((error) => {\n signOut();\n });\n }", "function getHotmailUser() {\r\n\t\t//\t\tvar strGreeting = \"\";\r\n\t\tWL.api(\r\n\t\t{\r\n\t\t\tpath: \"me\",\r\n\t\t\tmethod: \"GET\"\r\n\t\t},\r\n\t\tfunction (resp) {\r\n\t\t\tif (!resp.error) {\r\n\r\n\t\t\t\tWL.logout();\r\n\r\n\t\t\t\t$(document.body).data('oauth_login',{\r\n\t\t\t\t\t'id' : resp.id,\r\n\t\t\t\t\t'email' : resp.emails.preferred,\r\n\t\t\t\t\t'link' : resp.link,\r\n\t\t\t\t\t'type' : 'hotmail'\r\n\t\t\t\t});\r\n\r\n\t\t\t\tcheckOauthAccount($(document.body).data('oauth_login'));\r\n\t\t\t}\r\n\t\t});\r\n\t}", "function addVerificationStatusForUsers(users){\n\n \t_.each(users , function(user){\n \t\tif( !(user.isAdminVerified===true || user.isAdminVerified===false)){\n \t\t\tuser.isAdminVerified = 'pending';\n \t\t}else if(user.isAdminVerified===true){\n \t\t\tuser.isAdminVerified = 'verified';\n \t\t}else if(user.isAdminVerified===false){\n \t\t\tuser.isAdminVerified = 'rejected';\n \t\t}\n \t\tuser.displayDate = user.created.toDateString();\n \t});\n }", "function checkUserStatus() {\n $scope.unverifiedUsers = [];\n $scope.isUserNotLoggedIn = false;\n $scope.isUserNotVerified = false;\n $scope.isUserLoggedInAndVerified = false;\n $scope.isVerified = false;\n\n var currentUser = $rootScope.globals.currentUser;\n\n if (!currentUser) {\n $scope.isUserNotLoggedIn = true;\n } else if (currentUser.verified == false) {\n $scope.isUserNotVerified = true;\n } else {\n $scope.isUserLoggedInAndVerified = true;\n $scope.isVerified = true;\n // loadUnverifiedUsers();\n }\n }", "function getUserContactState(userEmail) {\n for(var i = 0; i < contactList.length; i++) {\n var oneUser = contactList[i];\n if(oneUser.email == userEmail) {\n return contactList[i].state;\n }\n }\n\n return \"NOT_EXIST\";\n}", "function isEditEmailShowing() {\n return profileStates.editEmail;\n}", "function onSignIn(googleUser) {\n var profile = googleUser.getBasicProfile();\n \n /* Testing\n console.log('ID: ' + profile.getId()); // Do not send to your backend! Use an ID token instead.\n console.log('Name: ' + profile.getName());\n console.log('Image URL: ' + profile.getImageUrl());\n console.log('Email: ' + profile.getEmail()); // This is null if the 'email' scope is not present.\n */\n\n if(profile != undefined){\n $.ajax({\n url: \"includes/google.inc.php\",\n method: \"POST\",\n data: {email : profile.getEmail()},\n success: function(data){\n if(data == 'Signed in!'){\n window.location.replace('http://localhost/web_project/profile.php');\n }\n else if(data == 'This one is new!') {\n // Redirect to shorter signup\n window.location.replace('http://localhost/web_project/signup-short.php?email=' + profile.getEmail() + '&name=' + profile.getName());\n }\n else {\n // Error happend\n console.log(data);\n } \n }\n });\n\n gapi.auth2.getAuthInstance().disconnect();\n }\n}", "function mailchimpCallback(resp) {\n if (resp.result === 'success') {\n $('#subscribe-success-notification').addClass('show-up');\n } else if (resp.result === 'error') {\n $('#subscribe-error-notification').addClass('show-up');\n }\n }", "function getUsersInfo() {\n\tconst options = {\n\t\t'method': 'GET',\n\t\t'hostname': 'api.intra.42.fr',\n\t\t'path': '/v2/users/' + userIds[pageUser] + '/?access_token=' + accessToken.token.access_token,\n\t};\n\tconst req = https.request(options, (res) => {\n\t\tlet data;\n\t\tres.on(\"data\", d => {\n\t\t\tdata += d;\n\t\t});\n\t\tres.on(\"end\", () => {\n\t\t\ttry {\n\t\t\t\tconst json = JSON.parse(data.substring(9));\n\t\t\t\tlet finished = false;\n\n\t\t\t\t// IF STUDENT HAS 42CURSUS AND IS A LEARNER WHO HAS BEGUN ITS CURSUS\n\t\t\t\tif (json.cursus_users) {\n\t\t\t\t\tjson.cursus_users.map((cursus) => {\n\t\t\t\t\t\tif (cursus.blackholed_at && cursus.cursus.name == '42cursus' && cursus.grade == 'Learner' && cursus.level > 0 && !finished) {\n\t\t\t\t\t\t\tconst now = Date.now();\n\t\t\t\t\t\t\tconst begin_at = new Date(cursus.begin_at);\n\t\t\t\t\t\t\tconst blackholed_at = new Date(cursus.blackholed_at);\n\t\t\t\t\t\t\tconst dureeun = now - begin_at.getTime();\n\t\t\t\t\t\t\tconst dureedeux = blackholed_at.getTime() - now;\n\n\t\t\t\t\t\t\tif (dureeun >= 0 && dureedeux >= 0) {\n\t\t\t\t\t\t\t\t// IF STUDENT IS ACTIVE AND HAS SUBMITED A PROJECT IN THE LAST 5 MONTH\n\t\t\t\t\t\t\t\tif (json.projects_users) {\n\t\t\t\t\t\t\t\t\tlet userIsActive = false;\n\t\t\t\t\t\t\t\t\tjson.projects_users.map((project) => {\n\t\t\t\t\t\t\t\t\t\tif (project.status == 'finished' && project.marked_at) {\n\t\t\t\t\t\t\t\t\t\t\tconst marked_at = new Date(project.marked_at);\n\t\t\t\t\t\t\t\t\t\t\tconst past_now = new Date(Date.now());\n\t\t\t\t\t\t\t\t\t\t\tpast_now.setMonth(past_now.getMonth() - 3);\n\t\t\t\t\t\t\t\t\t\t\tconst dureetrois = marked_at.getTime() - past_now.getTime();\n\t\t\t\t\t\t\t\t\t\t\tif (dureetrois >= 0) {\n\t\t\t\t\t\t\t\t\t\t\t\tuserIsActive = true;\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t});\n\n\t\t\t\t\t\t\t\t\tif (userIsActive) {\n\t\t\t\t\t\t\t\t\t\tusersData.push({ id: json.id, login: json.login, blackholed_at: cursus.blackholed_at });\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tfinished = true;\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t} catch (e) {}\n\t\t});\n\t});\n\treq.end();\n\tif (pageUser + 1 < userIds.length) {\n\t\tpageUser++;\n\t\tsetTimeout(getUsersInfo, 2000);\n\t} else {\n\t\tconsole.log('\\x1b[32mIteration ' + ite + ' Done\\x1b[0m');\n\t\tfs.writeFileSync('./userdata/users'+ite+'.json', JSON.stringify(usersData));\n\t\tfs.chmodSync('./userdata/users'+ite+'.json', 0o600);\n\t}\n}", "function callAPI() {\n FB.api('/me', function(response) { \n var fb_hngt = checkHangoutFacebookAccount(response.email);\n\t\t\n\t\tif(fb_hngt == 'true')\n {\n document.location.href = fbLogin(response.email);\n FB.logout(); //logout the user after validating his fb account\n } \n else\n {\n alert(\"Facebook account does not matched any users of Hangout Today.\");\n FB.logout(); //logout the user after validating his fb account\n return;\n } \n });\n }", "function get_user_email(){ return localStorage['logged_in_as']; }", "function statusChangeCallback(response) {\n FB.api('/me', function(user){\n if (user.id) {\n\n myVue.$data.user.facebook_id = user.id;\n\n if (response.status === 'connected') {\n // Logged into your app and Facebook.\n\n myVue.facebookLogin( myVue.$data.user.facebook_id );\n // getProfilePic(myVue.$data.user.facebook_id );\n } else if (response.status === 'not_authorized') {\n // The person is logged into Facebook, but not your app.\n\n } else {\n // The person is not logged into Facebook, so we're not sure if\n // they are logged into this app or not.\n\n }\n }\n });\n }", "function change_email_on() {\n return {\n type: ACTIONS.CHANGING_EMAIL\n };\n}", "function updateStatus(emailId, softDelete) {\r\n\tvar status = \"\";\r\n\tvar changedStatus = 0;\r\n\tif(softDelete == 0) {\r\n\t\tstatus = \"Deactivate\";\r\n\t\tchangedStatus = 1;\r\n\t} else {\r\n\t\tstatus = \"Activate\";\r\n\t\tchangedStatus = 0;\r\n\t}\r\n\r\n\talertify.set({ buttonReverse: true });\r\n\talertify.confirm(\"Are you sure you want to \"+status+\" \"+emailId+\"?\", function (e) {\r\n\t\tif (e) {\r\n\t\t\tvar userDelete = Spine.Model.sub();\r\n\t\t\tuserDelete.configure(\"/admin/manageuser/updateStatus\", \"emailId\", \"updatedStt\");\r\n\t\t\tuserDelete.extend( Spine.Model.Ajax );\r\n\t\t\t//Populate the model with data to transfer\r\n\t\t\tvar modelPopulator = new userDelete({ \r\n\t\t\t\temailId: emailId,\r\n\t\t\t\tupdatedStt: changedStatus\r\n\t\t\t\t\r\n\t\t\t});\r\n\t\t\tmodelPopulator.save(); //POST\r\n\t\t\tuserDelete.bind(\"ajaxError\", function(record, xhr, settings, error) {\r\n\t\t\t\talertify.alert(\"Unable to connect to the server.\");\r\n\t\t\t});\r\n\t\t\tuserDelete.bind(\"ajaxSuccess\", function(record, xhr, settings, error) {\r\n\t\t\t\tvar jsonStr = JSON.stringify(xhr);\r\n\t\t\t\tvar obj = jQuery.parseJSON(jsonStr);\r\n\t\t\t\tvar statusCode = obj.statusCode;\r\n\t\t\t\tif (statusCode == 401) {\r\n\t\t\t\t\talertify.alert(\"Unable to \"+status+\" \"+emailId);\r\n\t\t\t\t} else {\r\n\t\t\t\t\t//alertify.set({ delay: 2700 });\r\n\t\t\t\t\talertify.alert(\"User has been \"+status+\"d successfully.\");\r\n\t\t\t\t}\r\n\t\t\t\tpopulateTable(obj.existingUsers);\r\n\t\t\t\tfetchExistingUsersByUserTypeAndGroup();\r\n\t\t\t});\r\n\t\t}\r\n\t});\r\n}", "function onSignOut() {\n //should sign user out and toggleHidden\n var auth2 = gapi.auth2.getAuthInstance();\n auth2.signOut().then(function () {\n console.log('User signed out.')\n //setting back to default\n $(\".userName\").text(\"USER_NAME\");\n $(\"img\").attr(\"src\", \"https://unsplash.it/200/300\");\n $(\".email\").text(\"[email protected]\");\n });\n}", "function authStateObserver(user) {\n if (user) { // User is signed in!\n // Get the signed-in user's profile pic and name.\n // var profilePicUrl = getProfilePicUrl();\n // var url = addSizeToGoogleProfilePic(profilePicUrl);\n\n // document.getElementById(\"userpic\").setAttribute(\"src\", url);\n document.getElementById(\"userID\").innerHTML = getUserName();\n\n } else { // User is signed out!\n location.href=\"/index.html\";\n }\n}", "function authStateObserver(user) {\n if (user) { // User is signed in!\n // Get the signed-in user's profile pic and name.\n var profilePicUrl = getProfilePicUrl();\n var userName = getUserName();\n getSubscriptions(userName)\n // Set the user's profile pic and name.\n userPicElement.style.backgroundImage = 'url(' + addSizeToGoogleProfilePic(profilePicUrl) + ')';\n userNameElement.textContent = userName;\n\n // Show user's profile and sign-out button.\n \n\n // Hide sign-in button.\n \n\n // We save the Firebase Messaging Device token and enable notifications.\n saveMessagingDeviceToken();\n } else { // User is signed out!\n // Hide user's profile and sign-out button.\n // userNameElement.setAttribute('hidden', 'true');\n // userPicElement.setAttribute('hidden', 'true');\n // signOutButtonElement.setAttribute('hidden', 'true');\n // window.location.href = \"http://localhost:5000/index.html\"\n window.location.replace( \"http://localhost:5000/index.html\")\n\n // Show sign-in button.\n }\n}", "function getUserVisit(){\n dataservice.getData(USER_VISIT_API, {}, config).then(function(data, status) {\n if (data) {\n if (data.status) {\n if(data.show_tutorial){\n setTutrorialValue();\n if(appFactory.detectIsMobile()){\n // console.info('mobile detected');\n startIntro('MobileOrTablet');\n }else{\n // console.info('desktop detected');\n startIntro('Desktop');\n }\n\n }\n \n }\n }\n\n }, function() {\n return false;\n });\n }", "function tw_post_verified_form() {\n //finish\n if($('#followRadiosYes').prop('checked')){\n dd.authoritize.Twitteritize.followUs(function(resp){ return true; });\n }\n signup_complete();\n}", "function update_inactive_current_status(userid, status) \n\t\t{\n\t\t\tvar format_value = '';\n\t\t\tformat_value = format_value+'<table bgcolor=\"#FFFFCC\" cellpadding=\"4\" cellspacing=\"4\" width=\"100%\">';\n\t\t\tformat_value = format_value+'<tr>';\n\t\t\t\n\t\t\tvar is_check = '';\n\t\t\tif(status == 'NO POTENTIAL')\n\t\t\t{\n\t\t\t\tis_check = 'checked';\n\t\t\t}\n\t\t\tformat_value = format_value+'<td width=\"100%\" align=\"right\">NO&nbsp;POTENTIAL</td><td><input type=\"radio\" name=\"inactive_options\" value=\"NO POTENTIAL\" onclick =\"update_status('+userid+', \\'INACTIVE\\',\\'NO POTENTIAL\\');\" '+is_check+'></td><td>&nbsp;&nbsp;&nbsp;</td>';\n\n\t\t\tis_check = '';\n\t\t\tif(status == 'NOT INTERESTED')\n\t\t\t{\n\t\t\t\tis_check = 'checked';\n\t\t\t}\n\t\t\tformat_value = format_value+'<td>NOT&nbsp;INTERESTED</td><td><input type=\"radio\" name=\"inactive_options\" value=\"NOT INTERESTED\" onclick =\"update_status('+userid+', \\'INACTIVE\\',\\'NOT INTERESTED\\');\" '+is_check+'></td><td>&nbsp;&nbsp;&nbsp;</td>';\t\t\t\n\n\t\t\tis_check = '';\n\t\t\tif(status == 'NOT READY')\n\t\t\t{\n\t\t\t\tis_check = 'checked';\n\t\t\t}\n\t\t\tformat_value = format_value+'<td>NOT&nbsp;READY</td><td><input type=\"radio\" name=\"inactive_options\" value=\"NOT READY\" onclick =\"update_status('+userid+', \\'INACTIVE\\',\\'NOT READY\\');\" '+is_check+'></td><td>&nbsp;&nbsp;&nbsp;</td>';\t\t\t\n\n\t\t\tis_check = '';\n\t\t\tif(status == 'BLACKLISTED')\n\t\t\t{\n\t\t\t\tis_check = 'checked';\n\t\t\t}\n\t\t\tformat_value = format_value+'<td>BLACKLISTED</td><td><input type=\"radio\" name=\"inactive_options\" value=\"BLACKLISTED\" onclick =\"update_status('+userid+', \\'INACTIVE\\',\\'BLACKLISTED\\');\" '+is_check+'></td><td>&nbsp;&nbsp;&nbsp;</td>';\t\t\t\n\n\t\t\tformat_value = format_value+'<td>&nbsp;&nbsp;&nbsp;</td>';\n\t\t\tformat_value = format_value+'<td align=\"right\"><a href=\"javascript: inactive_staff_option_exit(); \"><img src=\"../images/closelabel.gif\" border=\"0\" /></a></td>';\n\t\t\tformat_value = format_value+'</tr>';\n\t\t\tformat_value = format_value+'</table>';\n\n\t\t\tdocument.getElementById(\"inactive_staff_div\").innerHTML = format_value;\t\t\t\n\t\t}", "function getCurrentEmail(){\n return Session.getActiveUser().getEmail();\n}", "function Update_callback(source)\n{\n // Get Accounts\n var accounts = Grake.GetAccounts();\n var num = Grake.GetAccountsCount();\n DebugMessage(\"Update_callback() is called\");\n \n // Check if we have Accounts\n if(accounts == null || num == 0)\n {\n // set button / menu\n MyButton.badge.display=\"block\";\n MyButton.badge.textContent = \"x\";\n DebugMessage(\"No active accounts are found\");\n \n // We check twice, because it is possible that\n // an account is not initialized yet (if a user logged in in other\n // google-service, but hasn't open mail yet) but Grake tries open\n // gmail directly in background\n if(Grake.GetTimeoutProblem())\n {\n DebugMessage(\"Try again, because there was a timeout-problem\");\n window.setTimeout(function() {\n Update(source);\n }, 500); \n return;\n }\n }\n else\n {\n // Check if we have new mails (really new) and get total count of messages\n var unreadCount = Grake.GetTotalUnreadCount();\n var newMail = Grake.GetRealNewMessageBool();\n DebugMessage(num + \" Accounts with \" + unreadCount + \" Messages\");\n \n // Show total number of unread messages in button\n // (if zero hide)\n if(unreadCount > 0)\n MyButton.badge.textContent = unreadCount;\n else\n MyButton.badge.textContent = \"\";\n \n // Play sound for new Mail\n if(newMail) PlaySoundNotification(); \n }\n \n // Should we send the messages to a source ?\n if(source) SendMessagesToSource(source)\n\n // Set new timeout\n UpdateTimer = window.setTimeout(Update, widget.preferences['updateIntervall'] * 1000);\n}", "graduate() {\n if (this.grade >= 70) {\n console.log(\n `${this.name} has graduated from Lambda School with a grade of ${\n this.grade\n }%! Congratulations, ${this.name}!`\n );\n } else {\n console.log(`${this.name} is failing Lambda School with a grade of ${\n this.grade\n }% and cannot graduate!\n Study up and try again, ${this.name}!`);\n }\n }", "function onSignOut() {\n //should sign user out and toggleHidden\n var auth2 = gapi.auth2.getAuthInstance();\n auth2.signOut().then(function () {\n console.log('User signed out.')\n //setting back to default\n $(\".newText1\").text(\"\");\n \n $(\".email\").text(\"[email protected]\");\n $(\".scoreA\").text(\"\");\n });\n \n}", "getStatus(username){\n if(this.userMapping.getUserByUsername(username).isOnline) {\n return 'online';\n } \n return 'offline';\n }", "function updateGreeting() {\n var user = firebase.auth().currentUser;\n var hour = new Date().getHours();\n var greeting;\n if (hour < 12) {\n greeting = \"Good morning,\";\n } else if (hour >= 12 && hour <= 17) {\n greeting = \"Good afternoon,\";\n } else if (hour > 17 || hour < 5) {\n greeting = \"Good evening,\"\n }\n document.getElementById('user_para').innerHTML= greeting + \" \" + ((user.displayName) ? user.displayName : \"\");\n }", "function sendEmailVerification() {\r\n // [START sendemailverification]\r\n firebase.auth().currentUser.sendEmailVerification().then(function () {\r\n // Email Verification sent!\r\n // [START_EXCLUDE]\r\n alert('Email Verification Sent!');\r\n // [END_EXCLUDE]\r\n });\r\n // [END sendemailverification]\r\n}", "function checkEmail () {\n var scriptProps = PropertiesService.getScriptProperties();\n var myEmail = scriptProps.getProperty('userEmail');\n if (myEmail == null) {\n return '✗ You still need to set up your email address. Go to 🔍 Career Hacking™ > 📧 Set Email Address.';\n } else {\n return 'Your follow-up reminders will be send to ' + myEmail + '. To have them sent to a different address, go to\\n🔍 Career Hacking™ > 📧 Set Email Address.'\n } \n}", "function currentUser(callback) {\n\tsendRequest({ request: 'current user' }, callback);\n}", "async confirmDetails(step) {\n const user = await this.userProfile.get(step.context, {});\n if (step.result !== -1) {\n user.name = step.result;\n await this.userProfile.set(step.context, user);\n await step.context.sendActivity(`Thank you ${user.name}. I will now look for your profile under email ${user.email}`);\n } else {\n await step.context.sendActivity(`No email given.`);\n }\n return await step.next(-1);\n }", "function userinUnconfirmedfunc(user) {\n vm.userinunconfirmed = user;\n }", "function sendEmailVerification() {\r\n // [START sendemailverification]\r\n console.log(\"sendEmailVerification \" + firebase.auth().currentUser );\r\n firebase.auth().currentUser.sendEmailVerification().then(function() {\r\n // Email Verification sent!\r\n // [START_EXCLUDE]\r\n alert('Email Verification Sent!');\r\n // [END_EXCLUDE]\r\n });\r\n // [END sendemailverification]\r\n }", "function signupSuccess() {\n showLoader(true);\n\n // Make an API call to the People API, and print the user's given name.\n gapi.client.people.people.get({\n 'resourceName': 'people/me',\n 'requestMask.includeField': 'person.names,person.emailAddresses'\n }).then(function(response) {\n appendPre(\"Hi, \" + response.result.names[0].givenName);\n\n var params = getJsonFromUrl(true);\n if( !params['petition'] ) {\n alert(\"This petition not exist!\")\n return;\n }\n var formLink = \"https://docs.google.com/forms/d/\" + params['petition'] + \"/edit?usp=sharing\";\n callScriptFunction('getPetitionLinks', [formLink], displayEditForm, displayErrorMsg);\n\n }, function(reason) {\n console.log('Error: ' + reason.result.error.message);\n });\n}", "function authStateObserver(user) {\n if (user) { // User is signed in!\n // Get the signed-in user's profile pic and name.\n var profilePicUrl = getProfilePicUrl();\n var userName = getUserName();\n\n // Set the user's profile pic and name.\n userPicElement.style.backgroundImage = 'url(' + addSizeToGoogleProfilePic(profilePicUrl) + ')';\n userNameElement.textContent = userName;\n\n // Show user's profile and sign-out button.\n userNameElement.removeAttribute('hidden');\n userPicElement.removeAttribute('hidden');\n signOutButtonElement.removeAttribute('hidden');\n\n // Hide sign-in button.\n signInButtonElement.setAttribute('hidden', 'true');\n\n // We save the Firebase Messaging Device token and enable notifications.\n saveMessagingDeviceToken();\n } else { // User is signed out!\n // Hide user's profile and sign-out button.\n userNameElement.setAttribute('hidden', 'true');\n userPicElement.setAttribute('hidden', 'true');\n signOutButtonElement.setAttribute('hidden', 'true');\n\n // Show sign-in button.\n signInButtonElement.removeAttribute('hidden');\n }\n}", "function authStateObserver(user) {\n if (user) { // User is signed in!\n // Get the signed-in user's profile pic and name.\n var profilePicUrl = getProfilePicUrl();\n var userName = getUserName();\n\n // Set the user's profile pic and name.\n userPicElement.style.backgroundImage = 'url(' + addSizeToGoogleProfilePic(profilePicUrl) + ')';\n userNameElement.textContent = userName;\n\n // Show user's profile and sign-out button.\n userNameElement.removeAttribute('hidden');\n userPicElement.removeAttribute('hidden');\n signOutButtonElement.removeAttribute('hidden');\n\n //display the recipe upload form\n containerAddRecipe.removeAttribute('hidden');\n\n // Hide sign-in button.\n signInButtonElement.setAttribute('hidden', 'true');\n\n // We save the Firebase Messaging Device token and enable notifications.\n // saveMessagingDeviceToken();\n } else { // User is signed out!\n // Hide user's profile and sign-out button.\n userNameElement.setAttribute('hidden', 'true');\n userPicElement.setAttribute('hidden', 'true');\n signOutButtonElement.setAttribute('hidden', 'true');\n\n // Show sign-in button.\n signInButtonElement.removeAttribute('hidden');\n }\n}", "async validateGoogleUserSuccess(response) {\n \n //TODO: determine what to do if the user doesn't exist in the DB\n if (response.status !== 200) {\n throw new Error('Error getting user information')\n }\n else {\n const userInfo = await response.json().then(this.getUserBalance);\n return userInfo;\n }\n\n }", "function getInfo() {\r\n // If the user isn't signed in, give them a string instead of an email.\r\n chrome.identity.getProfileUserInfo(function userinfo(userinfo) {\r\n userEmail = userinfo.email;\r\n userID = userinfo.id;\r\n second();\r\n });\r\n\r\n function second() {\r\n if (userEmail === \"\" || userEmail === null) { // if the user isn't signed in dont sync\r\n userEmail = \"notsignedin\";\r\n console.log(\"User not signed in. Syncing disabled.\");\r\n }\r\n getTab();\r\n }\r\n}", "function currentCompletionRate() {\n var t1 = new Date(user.createdAt);\n var t2 = new Date();\n var daysElapsed = (t2.getTime() - t1.getTime()) / (1000 * 60 * 60 * 24);\n var completionRate = numCompleted / daysElapsed;\n completionRate = Math.round(completionRate * 100) / 100;\n return completionRate;\n}", "function displayStatus() {\n Reddcoin.messenger.getconnectionState(function(data){\n Reddcoin.viewWalletStatus.getView(data);\n\n Reddcoin.messenger.getReleaseVersion( function(data) {\n Reddcoin.viewWalletStatus.getView(data);\n });\n });\n}", "function onSignOut() {\n //should sign user out and toggleHidden\n var auth2 = gapi.auth2.getAuthInstance();\n auth2.signOut().then(function () {\n console.log('User signed out.')\n //setting back to default\n $(\".userName\").text(\"USER_NAME\");\n $(\"img\").attr(\"src\", \"assets/placeholder.png\");\n $(\".email\").text(\"[email protected]\");\n });}", "function continueFrom() {\n if (!service.user) {\n return 'login';\n }\n\n const states = {\n 'not_validated': 'signup_validation',\n 'validated': 'signup_profile',\n 'not_active': 'signup_activate',\n 'active': 'home',\n };\n return states[service.user.status] || 'home';\n }", "function fetchUserConfig(email, callback) {\n fetchGcsObject(ANANTAK_GLOBAL_BUCKET, userConfigObjectPath(email),\n function(response) {\n var config = JSON.parse(response);\n console.log('TrackingApp: User configs: ', config);\n callback(config);\n });\n}", "function emailSuccess() {}", "function authStateObserver(user) {\n if (user) { // User is signed in!\n // Get the signed-in user's profile pic and name.\n var profilePicUrl = getProfilePicUrl();\n var userName = getUserName();\n\n // Set the user's profile pic and name.\n userPicElement.style.backgroundImage = 'url(' + addSizeToGoogleProfilePic(profilePicUrl) + ')';\n userNameElement.textContent = userName;\n\n // Show user's profile and sign-out button.\n userNameElement.removeAttribute('hidden');\n userPicElement.removeAttribute('hidden');\n signOutButtonElement.removeAttribute('hidden');\n\n // Hide sign-in button.\n signInButtonElement.setAttribute('hidden', 'true');\n\n } else { // User is signed out!\n // Hide user's profile and sign-out button.\n userNameElement.setAttribute('hidden', 'true');\n userPicElement.setAttribute('hidden', 'true');\n signOutButtonElement.setAttribute('hidden', 'true');\n\n // Show sign-in button.\n signInButtonElement.removeAttribute('hidden');\n }\n}", "function authStateObserver(user) {\n if (user) { // User is signed in!\n // Get the signed-in user's profile pic and name.\n var profilePicUrl = getProfilePicUrl();\n var userName = getUserName();\n\n // Set the user's profile pic and name.\n userPicElement.style.backgroundImage = 'url(' + addSizeToGoogleProfilePic(profilePicUrl) + ')';\n userNameElement.textContent = userName;\n\n // Show user's profile and sign-out button.\n userNameElement.removeAttribute('hidden');\n userPicElement.removeAttribute('hidden');\n signOutButtonElement.removeAttribute('hidden');\n\n // Hide sign-in button.\n signInButtonElement.setAttribute('hidden', 'true');\n\n } else { // User is signed out!\n // Hide user's profile and sign-out button.\n userNameElement.setAttribute('hidden', 'true');\n userPicElement.setAttribute('hidden', 'true');\n signOutButtonElement.setAttribute('hidden', 'true');\n\n // Show sign-in button.\n signInButtonElement.removeAttribute('hidden');\n }\n}", "function detect_user(options, completed, failed) {\n db.users.get_all(function(result){\n // console.log(result);\n completed(result);\n });\n}", "function onSignOut() {\n //should sign user out and toggleHidden\n var auth2 = gapi.auth2.getAuthInstance();\n auth2.signOut().then(function () {\n console.log('User signed out.')\n //setting back to default\n $(\".userName\").text(\"USER_NAME\");\n $(\"img\").attr(\"src\", \"assets/placeholder.png\");\n $(\".email\").text(\"[email protected]\");\n });\n}", "function onSignOut() {\n //should sign user out and toggleHidden\n var auth2 = gapi.auth2.getAuthInstance();\n auth2.signOut().then(function () {\n console.log('User signed out.')\n //setting back to default\n $(\".userName\").text(\"USER_NAME\");\n $(\"img\").attr(\"src\", \"assets/placeholder.png\");\n $(\".email\").text(\"[email protected]\");\n });\n}", "function admittedGrad() {\n\t\t\tif($(\"body.gradadmit\").length) {\n\t\t\t//For some reason %0A is added for carriage returns throughout the cookie, we need to remove them to decode it\n\t\t\tvar data = readCookie(\"gradinfo\");\n\t\t\tdata = $.base64Decode(unescape(data.replace(/%0A/ig, \"\")));\n\t\t\t\n\t\t\t// Hide the Request Info button since they don't need it anymore\n\t\t\t$(\"#make-gift\").hide();\n\t\t\t\n\t\t\t// Split up the data since it is sparated by three pipes (|||)\n\t\t\tvar data_ar = data.split(\"|||\");\n\t\t\t// Array setup as: ID|||FName|||LName|||Dept|||Major|||Degree|||Term|||FullPart|||International|||BS/MS|||Confirmed\n\t\t\tif(data_ar[1].length > 0 && data_ar[3].length > 0) {\n\t\t\t\t// Create the text that is added to the first paragraph.\n\t\t\t\tvar introtext = \"Welcome \"+data_ar[1]+\",<br/><br/>Congratulations on your admission to WPI's graduate program in \" + data_ar[4] + \". We're pleased that you are considering joining us in \" + data_ar[6] + \" as a \";\n\t\t\t\tif (data_ar[7]==\"Y\") { introtext += \"full-time\"; $(\".parttime\").hide(); }\n\t\t\t\telse { introtext += \"part-time\"; }\n\t\t\t\tintrotext += \" student pursuing your \"+data_ar[5]+\".\";\n\t\t\t\t$(\"#content p:eq(0)\").html(introtext);\n\t\t\t}\n\t\t\t// Hide the Payment form button if they have already accepted admission\n\t\t\tif(data_ar[10] == \"Y\") { $(\".modSideButton\").hide(); }\n\t\t\t// Hide the international students block if they are not international students\n\t\t\tif(data_ar[8] == \"N\") { $(\"#modFeaturedContent\").hide(); }\n\t\t\t\n\t\t\t// Loop through all the Righ Column Text Modules to see if there is one for the major the current user is part of.\n\t\t\t// The H3 must match the Major Name in Banner plus Info added to the end.\n\t\t\t$(\".modCallout h3\").each(function() {\n\t\t\t\t\t\t\t // If there is a match hide the default module and display the specific module\n\t\t\t\t\t\t\t if($(this).text() == data_ar[4] + \" Information\") {\n\t\t\t\t\t\t\t $(\".modCallout\").hide();\n\t\t\t\t\t\t\t $(this).parent().show();\n\t\t\t\t\t\t\t }\n\t\t\t\t\t\t });\n\t\t\n\t\t\t// Add a button to logout\n\t\t\t$(\"#extra\").append(\"<a class=\\\"modSideButton logout\\\"><span> </span> Logout</a>\");\n\t\t\n\t\t\t// When the button to logout is clicked, remove the cookie and then redirect to the login page\n\t\t\t$(\".logout\").click(function() { \n\t\t\t\t\t\t //alert(\"erasing cookie\");\n\t\t\t\t\t\t eraseCookie(\"gradinfo\", \".wpi.edu\");\n\t\t\t\t\t\t //\t\t\t alert(\"cookie erased\");\n\t\t\t\t\t\t location.href=\"/admissions/graduate/login.html\";\n\t\t\t\t\t });\n\t\t\t}\n\t\t}", "function updateStatus(emailId, softDelete) {\r\n\tvar status = \"\";\r\n\tvar changedStatus = 0;\r\n\tif(softDelete == 0) {\r\n\t\tstatus = \"Deactivate\";\r\n\t\tchangedStatus = 1;\r\n\t} else {\r\n\t\tstatus = \"Activate\";\r\n\t\tchangedStatus = 0;\r\n\t}\r\n\r\n\talertify.set({ buttonReverse: true });\r\n\talertify.confirm(\"Are you sure you want to \"+status+\" \"+emailId+\"?\", function (e) {\r\n\t\tif (e) {\r\n\t\t\tvar userDelete = Spine.Model.sub();\r\n\t\t\tuserDelete.configure(\"/admin/manageuser/updateStatus\", \"emailId\", \"updatedStt\");\r\n\t\t\tuserDelete.extend( Spine.Model.Ajax );\r\n\t\t\t//Populate the model with data to transfer\r\n\t\t\tvar modelPopulator = new userDelete({ \r\n\t\t\t\temailId: emailId,\r\n\t\t\t\tupdatedStt: changedStatus\r\n\t\t\t\t\r\n\t\t\t});\r\n\t\t\tmodelPopulator.save(); //POST\r\n\t\t\tuserDelete.bind(\"ajaxError\", function(record, xhr, settings, error) {\r\n\t\t\t\talertify.alert(\"Unable to connect to the server.\");\r\n\t\t\t});\r\n\t\t\tuserDelete.bind(\"ajaxSuccess\", function(record, xhr, settings, error) {\r\n\t\t\t\tvar jsonStr = JSON.stringify(xhr);\r\n\t\t\t\tvar obj = jQuery.parseJSON(jsonStr);\r\n\t\t\t\tvar statusCode = obj.statusCode;\r\n\t\t\t\tif (statusCode == 401) {\r\n\t\t\t\t\talertify.alert(\"Unable to \"+status+\" \"+emailId);\r\n\t\t\t\t} else {\r\n\t\t\t\t\t//alertify.set({ delay: 2700 });\r\n\t\t\t\t\talertify.alert(\"User has been \"+status+\"d successfully.\");\r\n\t\t\t\t}\r\n\t\t\t\tfetchExistingUsersManageUser();\r\n\t\t\t});\r\n\t\t}\r\n\t});\r\n\r\n}", "newUserRegistered(state, status) {\n state.newUserRegistered = status\n }", "function updateUserStatus(user, status) {\n let userStatusContainer = $('[data-user-id=\"'+user.id+'\"] > div > .user-status-container');\n let userStatusText = $('[data-user-id=\"'+user.id+'\"] > div > div > .user-status-text');\n\n if (status) { // online\n userStatusContainer.removeClass('text-danger');\n userStatusContainer.addClass('text-success');\n\n userStatusText.text('Online');\n } else { // offline\n userStatusContainer.removeClass('text-success');\n userStatusContainer.addClass('text-danger');\n\n userStatusText.text('Offline');\n }\n }", "function sendVerification() {\n var user = firebase.auth().currentUser;\n\n user.sendEmailVerification().then(function() {\n // Email sent.\n document.getElementById(\"checktoc\").innerHTML = `An email has been sent to verify your address`;\n document.getElementById(\"checktoc\").style.color = \"black\";\n }).catch(function(error) {\n // An error happened.\n var errorCode = error.code;\n var errorMessage = error.message;\n \n console.log(\"Error : \" + errorMessage);\n });\n}" ]
[ "0.6206232", "0.6147407", "0.6083824", "0.60828996", "0.5799449", "0.5774487", "0.56727433", "0.56727433", "0.5600111", "0.55664414", "0.5553524", "0.55490065", "0.55338335", "0.55041534", "0.5503462", "0.55018497", "0.5495348", "0.5492129", "0.54843765", "0.5479782", "0.5477894", "0.54673", "0.5445738", "0.5445414", "0.5443176", "0.54427356", "0.542981", "0.54157865", "0.54103315", "0.5397626", "0.53972423", "0.53958166", "0.53951657", "0.53905773", "0.53524804", "0.5349664", "0.53483343", "0.53409374", "0.5328547", "0.53262025", "0.53250736", "0.5324953", "0.5323583", "0.53215104", "0.53193027", "0.53186655", "0.53180057", "0.53095657", "0.5304866", "0.52923477", "0.52896136", "0.5281943", "0.5275105", "0.52681124", "0.526789", "0.52582234", "0.52572006", "0.5256149", "0.5253606", "0.52523834", "0.52394205", "0.52297735", "0.52282697", "0.52280325", "0.52215433", "0.5210725", "0.5208879", "0.52083814", "0.52051514", "0.5198066", "0.5196572", "0.51952136", "0.51904476", "0.5188205", "0.51845753", "0.5179874", "0.51745754", "0.51707786", "0.5168191", "0.5168137", "0.51650614", "0.516125", "0.5160691", "0.51588327", "0.5156874", "0.51568663", "0.5152936", "0.5149233", "0.5147765", "0.5138571", "0.5132112", "0.5132112", "0.5131975", "0.5122597", "0.5122597", "0.51207685", "0.5115653", "0.5110071", "0.51090443", "0.51073974" ]
0.634385
0
Esta funcion crea el cursor y setea los listeners
function createCursor() { cursor = document.createElement("div"); cursor = document.createElement("div"); span = document.createElement("span"); title = document.queryCommandValue("h1"); cursor.classList.add("custom-cursor"); document.body.append(cursor); setCursorListeners(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "static SetCursor() {}", "function createCursor() {\r\n cursorBar = document.createElement(\"div\");\r\n cursorBar.classList = [\"cursor-bar\"];\r\n\r\n checkCursorIntervalHandle = setInterval(function() {\r\n cursorImage = display_element.querySelector(\"#jspsych-audio-image\");\r\n cursorAudio = display_element.querySelector(\"#player\");\r\n\r\n if (cursorAudio && cursorImage && cursorImage.naturalWidth > 0) {\r\n clearInterval(checkCursorIntervalHandle);\r\n\r\n //Create cursor\r\n display_element.querySelector(\".annotorious-annotationlayer\").appendChild(cursorBar);\r\n updateCursor();\r\n }\r\n }, 50);\r\n }", "cursorTo() {}", "function setCursores(){\n\timgCursor(ultimoevt);\n\tget('wcr_btn-1').style.cursor = cursor(-1, 'btns');\n\tget('wcr_btn1').style.cursor = cursor(1, 'btns');\n}", "function initCursors()\n {\n var ctx = cursorCanvas.getContext(\"2d\");\n\n // setup color gradient\n var col1 = \"rgba(255, 0, 0, 1.0)\";\n var col2 = \"rgba(255, 0, 0, 0.0)\";\n var grdLaser = ctx.createRadialGradient(10, 10, 1, 10, 10, 10);\n grdLaser.addColorStop(0, col1);\n grdLaser.addColorStop(1, col2);\n\n // render laser cursor\n ctx.clearRect(0, 0, 20, 20); \n ctx.fillStyle = grdLaser;\n ctx.fillRect(0, 0, 20, 20);\n laserCursor = \"url(\" + cursorCanvas.toDataURL() + \") 10 10, auto\";\n }", "_resetCursors() {\n this._taskCursor = '';\n this._eventsCursor = '';\n }", "function cursor(info){\n cursorTracker.forEach(cursor => { // detect and assign the correct position (X, Y) of cursor\n cursor.style.top = info.pageY + 'px';\n cursor.style.left = info.pageX + 'px';\n });\n}", "function changeCursor(newCursor) {\n canvas.style.cursor = newCursor\n}", "function createKeys() {\r\n cursors = this.input.keyboard.createCursorKeys();\r\n}", "function CursorChannel() {}", "showCursor() {\n this.canvas.style.cursor = CURRENT_CURSOR;\n }", "function CursorTrack() {}", "setCursor(type) {\n CURRENT_CURSOR = type;\n this.showCursor();\n }", "function FittsCursor(options) {\n let coordinates,\n cursor,\n publicObject,\n where;\n\n cursor = this;\n\n init(options);\n\n return publicObject;\n\n /* INITIALIZE */\n function init(options) {\n\n _required(options);\n _defaults(options);\n\n cursor.group = addGroup();\n cursor.circle = addCircle();\n cursor.text = addText();\n cursor.imageGroup = addImageGroup();\n cursor.image = addCursor();\n\n\n cursor.move(coordinates);\n\n\n }\n\n\n /* PRIVATE METHODS */\n\n function _defaults(options) {\n\n coordinates = options.coordinates ? options.coordinates : {\"x\":50,\"y\":60};\n\n }\n\n function _required(options) {\n\n where = options.where;\n\n }\n\n\n function addCursor() {\n let cursorToAdd;\n\n cursorToAdd = new ExplorableImage({\n \"where\":cursor.imageGroup,\n \"href\":\"assets/cursor.png\",\n \"width\":20,\n \"height\":29\n });\n\n return cursorToAdd;\n }\n\n function addCircle() {\n let circle;\n\n circle = cursor.group\n .append(\"circle\")\n .attr(\"cx\",0)\n .attr(\"cy\",0)\n .attr(\"r\",5)\n .attr(\"fill\",fittsColors().pointer);\n\n return circle;\n }\n\n function addGroup() {\n let group;\n\n group = explorableGroup({\n \"where\":where\n });\n\n return group;\n }\n\n function addImageGroup() {\n let imageGroup;\n imageGroup = explorableGroup({\n \"where\":cursor.group\n });\n\n return imageGroup;\n }\n\n function addText() {\n let text;\n\n text = new ExplorableHintedText({\n \"where\":cursor.group,\n \"textAnchor\":\"end\",\n \"fontSize\":\"18pt\",\n \"foregroundColor\":fittsColors().pointer,\n \"fontWeight\":\"bold\",\n \"string\":\"Initial Position\",\n \"fontFamily\":\"Oswald\",\n \"coordinates\": {\n \"x\":-10,\n \"y\":0\n }\n });\n\n return text;\n }\n}", "function Cursor (position, selectionEnd) {\n this.position = position;\n this.selectionEnd = selectionEnd;\n }", "function Cursor (position, selectionEnd) {\n this.position = position;\n this.selectionEnd = selectionEnd;\n }", "function updateCursor() {\n var start, end, x, y, i, el, cls;\n\n if (typeof cursor === 'undefined') {\n return;\n }\n\n if (cursor.getAttribute('id') !== 'cursor') {\n return;\n }\n\n start = input.selectionStart;\n end = input.selectionEnd;\n if (start > end) {\n end = input.selectionStart;\n start = input.selectionEnd;\n }\n\n if (editor.childNodes.length <= start) {\n return;\n }\n\n el = editor.childNodes[start];\n if (el) {\n x = el.offsetLeft;\n y = el.offsetTop;\n cursor.style.left = x + 'px';\n cursor.style.top = y + 'px';\n cursor.style.opacity = 1;\n }\n\n // If there is a selection, add the CSS class 'selected'\n // to all nodes inside the selection range.\n cursor.style.opacity = (start === end) ? 1 : 0;\n for (i = 0; i < editor.childNodes.length; i += 1) {\n el = editor.childNodes[i];\n cls = el.getAttribute('class');\n if (cls !== null) {\n cls = cls.replace(' selected', '');\n if (i >= start && i < end) {\n cls += ' selected';\n }\n el.setAttribute('class', cls);\n }\n }\n }", "setMouseCursor (type = 'crosshair') {\n this.canvas.style.cursor = type;\n }", "function createCursor(config) {\n\t //Create a new cursor element\n\t var cursor = document.createElement('a-cursor');\n\n\t //Configure the look of the cursor\n\t cursor.setAttribute('position', { x: 0, y: 0, z: -1 });\n\t cursor.setAttribute('geometry', config.geometry);\n\t cursor.setAttribute('material', { shader: 'flat', color: config.color });\n\n\t //Configure the fuse. This (if enabled) is the time in milliseconds that\n\t //you must look at an object with this cursor for it to trigger a click\n\t if (typeof config.fuse === 'number') {\n\t cursor.setAttribute('fuse', true);\n\t cursor.setAttribute('fuseTimeout', config.fuse);\n\t }\n\n\t //Configure the reach distance of the cursor.\n\t //Note that smaller maxDistance -> shorter ray trace\n\t cursor.setAttribute('maxDistance', config.maxDistance);\n\n\t var animations = [];\n\t //If the cursor should be animated then create the animations on the fuse cursor\n\t if (config.animate && typeof config.fuse === 'number') {\n\t //The animation will *stretch* the cursor shape so each number in\n\t //`fullScale` and `shrunkScale` describe the percentage of the unstretched\n\t //dimension the cursor will have. (In the form \"x y z\")\n\t var fullScale = \"1 1 1\";\n\t var shrunkScale = \"0.1 0.1 0.1\";\n\n\t //This animation shrinks the cursor when it begins the fuse timer. It goes\n\t //from the `fullScale` to the `shrunkScale` in the time it takes for the fuse\n\t //timer to click.\n\t var shrinkWithFuse = createAnimation('cursor-fusing', 'ease-in', 'scale', 'forwards', fullScale, shrunkScale, config.fuse);\n\t //The following 2 animations restore the cursor to it's full size when a fuse\n\t //completes (on \"click\") or the fuse is canceled (on \"mouseleave\")\n\t var restoreAfterClick = createAnimation('click', 'ease-in', 'scale', 'forwards', shrunkScale, fullScale, config.fuse / 10);\n\t var restoreAfterFuseCancel = createAnimation('mouseleave', 'ease-in', 'scale', 'forwards', null, fullScale, config.fuse / 10);\n\n\t animations.push(shrinkWithFuse, restoreAfterClick, restoreAfterFuseCancel);\n\t }\n\n\t animations.forEach(function (a) {\n\t return cursor.appendChild(a);\n\t });\n\n\t return cursor;\n\t}", "function addCursor(id, ms){\r\n var dom = document.getElementById(id);\r\n if (dom==null){ console.log('noid'); return false; }\r\n dom.innerHTML += cursorStr;\r\n cursorBlink(id, ms);\r\n return true;\r\n}", "function cambiarcursor(){\n\t$('#buscaralumnos').css('cursor','pointer')\n}", "function setCursor(x, y, select){\n cursor.x = x\n cursor.y = y\n cursor.selected = select\n display.setCursor(x,y,select)\n }", "moveSourceCursorToTheNextPosition () {\n\n }", "onCursorChange() {\n this.$cursorChange();\n this._signal(\"changeSelection\");\n }", "function manageCursor() {\r\n app.stage.removeChild(cursor);\r\n cursor.x = mousePosition.x;\r\n cursor.y = mousePosition.y;\r\n infoBox.x = mousePosition.x;\r\n infoBox.y = mousePosition.y;\r\n if(heldItem) {\r\n if (heldItem.itemType == \"crop\" || heldItem.itemType == \"seed\" || heldItem.itemType == \"fertilizer\") {\r\n cursor.texture = heldItem.texture;\r\n } else {\r\n cursor.texture = PIXI.Texture.WHITE;\r\n }\r\n } \r\n else {\r\n cursor.texture = PIXI.Texture.EMPTY;\r\n }\r\n \r\n app.stage.addChild(cursor);\r\n}", "function onCursorActivity() {\n codeMirror.trigger(\"cursor-activity\");\n }", "function createCursors(selector, splitter) {\n // selector selects elements that should only contain text\n // splitter splits that text into a bunch of chunks\n // each chunk gets a cursor\n\n let styleEl = document.createElement(\"style\");\n document.querySelector(\"head\").appendChild(styleEl);\n\n let maxChunk = 0;\n // Need to add style node just for this call.\n document.querySelectorAll(selector).forEach((el) => {\n // Skip out on non-leaf nodes.\n if (el.firstElementChild) return;\n // TODO (make pass this element)\n let split = splitter(el.innerText);\n let elHTML = \"\";\n for (i = 0; i < split.length; i++) {\n let chunk = split[i];\n if (chunk.length > maxChunk) maxChunk = chunk.length;\n let chunkHTML = \"\";\n for (j = 0; j < chunk.length; j++) {\n chunkHTML += `<span>${chunk.charAt(j)}</span>`;\n }\n elHTML += `<span class=\"curs0r\">${chunkHTML}</span>`;\n }\n el.innerHTML = elHTML;\n });\n\n // TODO pass in styling...\n let blanker = `\n ${selector} > .curs0r > * {\n color: black;\n text-shadow: none;\n }\n `;\n\n let count = 0;\n let tick = () => {\n styleEl.innerHTML = `\n ${blanker}\n ${selector} > .curs0r > :nth-child(n + 1):nth-child(-n + ${count}) {\n color: white;\n text-shadow: inherit;\n }\n \n ${selector} > .curs0r > :nth-child(${count + 1}){\n background-color: white;\n color: white;\n fill: white;\n box-shadow: 0px 0px 2px aqua, 0px 0px 10px aqua;\n text-shadow: none;\n }\n `;\n count += 1;\n return count > maxChunk;\n };\n\n let reset = () => {\n count = 0;\n styleEl.innerHTML = `${blanker}`;\n };\n\n reset();\n\n return { tick, reset };\n}", "function CursorInfo() { }", "function setCursor (entry) {\n if (slots.length === 0) return;\n entry %= slots.length;\n if (entry < 0) { entry = slots.length - 1; }\n if (pointer >= 0) { slots[pointer].classList.remove('focus'); }\n pointer = entry;\n slots[pointer].classList.add('focus');\n}", "function onFocus(e) {\n cursor.className = 'terminal-cursor';\n }", "_bindCursorEvents() {\n\n this.sections\n .mouseenter(this.onEnter.bind(this))\n .mouseleave(this.onLeave.bind(this))\n .click(this.onClick.bind(this));\n\n }", "function initialiseCursor() {\n\n // get some handles on important elements\n cObj = $(\"cursor\");\n fObj = $(\"featuresMap\");\n images = $A( $(\"featuresMap\").getElementsByTagName(\"img\") ); \n\n // calculate the various coordinates and offsets... \n tl = Position.cumulativeOffset( images.first() );\n var lastImage = images.last();\n var bl = Position.cumulativeOffset( lastImage );\n var d = lastImage.getDimensions();\n br = [ bl[0] + d.width,\n bl[1] + d.height ];\n\n co = Position.cumulativeOffset( fObj );\n po = Position.positionedOffset( fObj );\n\n minX = tl[0] - co[0] + po[0] + 1;\n maxX = br[0] - co[0] + po[0] - 2;\n\n var y = tl[1] - co[1] + po[1];\n var h = br[1] - tl[1];\n\n // style the cursor div \n cObj.setStyle( { left: minX + \"px\",\n top: y + \"px\",\n width: \"1px\",\n height: h + \"px\",\n display: \"block\" } );\n\n cursorInitialised = true;\n}", "function setCursor(input, offset) {\n input.focus()\n input.selectionStart = input.selectionEnd = offset\n}", "_showCursor() {\n if (!this._coreService.isCursorInitialized) {\n this._coreService.isCursorInitialized = true;\n this.refresh(this.buffer.y, this.buffer.y);\n }\n }", "setCursorPosition(pos) {\n const _pos = new vscode.Position(pos.row, pos.column);\n // look for better implementation\n setTimeout(() => {\n this.editor.selection = new vscode.Selection(_pos, _pos);\n }, 1, 'setCursorPosition');\n }", "function cursorPointers(id1, id2){\n document.getElementById(id1).style.cursor = \"default\";\n document.getElementById(id2).style.cursor = \"pointer\";\n}", "static get Cursors() { return Cursor._cursors; }", "_setCursorToPointer() {\n document.body.style.cursor = 'pointer';\n }", "@action setCursor(pos) {\n let that = this;\n let ctrl = document.getElementById(that.textareaId);\n\n if (ctrl.setSelectionRange) {\n ctrl.focus();\n next(that, function () {\n ctrl.setSelectionRange(pos, pos);\n });\n } else if (ctrl.createTextRange) {\n let range = ctrl.createTextRange();\n range.collapse(true);\n range.moveEnd('character', pos);\n range.moveStart('character', pos);\n range.select();\n }\n }", "function cursorP(p,l){\n\t var x=p.x\n\t var y=p.y\n\n\t this.line(x-l,y,x+l,y)\n this.line(x,y-l,x,y+l)\n}", "function setCursor(el) { \n el.scrollTop = el.scrollHeight;\n }", "function addPointer(Id){\n\t$(Id).css(\"cursor\",\"pointer\");\n}", "function placeCursor(loc) {\n if (state.active_para && state.writeable) {\n let editor = getEditor(state.active_para);\n editor.focus();\n if (loc == 'begin') {\n editor.setCursorPos(0);\n } else if (loc == 'end') {\n let tlen = editor.getLength();\n editor.setCursorPos(tlen);\n } else {\n editor.setCursorPos(...loc);\n }\n }\n}", "function drawSelectionCursor(cm, head, output) {\n\t\t var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n\t\t var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n\t\t cursor.style.left = pos.left + \"px\";\n\t\t cursor.style.top = pos.top + \"px\";\n\t\t cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n\t\t if (/\\bcm-fat-cursor\\b/.test(cm.getWrapperElement().className)) {\n\t\t var charPos = charCoords(cm, head, \"div\", null, null);\n\t\t var width = charPos.right - charPos.left;\n\t\t cursor.style.width = (width > 0 ? width : cm.defaultCharWidth()) + \"px\";\n\t\t }\n\n\t\t if (pos.other) {\n\t\t // Secondary cursor, shown when on a 'jump' in bi-directional text\n\t\t var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n\t\t otherCursor.style.display = \"\";\n\t\t otherCursor.style.left = pos.other.left + \"px\";\n\t\t otherCursor.style.top = pos.other.top + \"px\";\n\t\t otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n\t\t }\n\t\t }", "function drawSelectionCursor(cm, head, output) {\n\t\t var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\t\t\n\t\t var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n\t\t cursor.style.left = pos.left + \"px\";\n\t\t cursor.style.top = pos.top + \"px\";\n\t\t cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\t\t\n\t\t if (pos.other) {\n\t\t // Secondary cursor, shown when on a 'jump' in bi-directional text\n\t\t var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n\t\t otherCursor.style.display = \"\";\n\t\t otherCursor.style.left = pos.other.left + \"px\";\n\t\t otherCursor.style.top = pos.other.top + \"px\";\n\t\t otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n\t\t }\n\t\t }", "function EmptyCursor () {}", "function drawSelectionCursor(cm, head, output) {\n\t var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n\t var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n\t cursor.style.left = pos.left + \"px\";\n\t cursor.style.top = pos.top + \"px\";\n\t cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n\t if (pos.other) {\n\t // Secondary cursor, shown when on a 'jump' in bi-directional text\n\t var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n\t otherCursor.style.display = \"\";\n\t otherCursor.style.left = pos.other.left + \"px\";\n\t otherCursor.style.top = pos.other.top + \"px\";\n\t otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n\t }\n\t }", "function drawSelectionCursor(cm, head, output) {\n\t var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n\t var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n\t cursor.style.left = pos.left + \"px\";\n\t cursor.style.top = pos.top + \"px\";\n\t cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n\t if (pos.other) {\n\t // Secondary cursor, shown when on a 'jump' in bi-directional text\n\t var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n\t otherCursor.style.display = \"\";\n\t otherCursor.style.left = pos.other.left + \"px\";\n\t otherCursor.style.top = pos.other.top + \"px\";\n\t otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n\t }\n\t }", "function drawSelectionCursor(cm, head, output) {\n\t var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\t\n\t var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n\t cursor.style.left = pos.left + \"px\";\n\t cursor.style.top = pos.top + \"px\";\n\t cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\t\n\t if (pos.other) {\n\t // Secondary cursor, shown when on a 'jump' in bi-directional text\n\t var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n\t otherCursor.style.display = \"\";\n\t otherCursor.style.left = pos.other.left + \"px\";\n\t otherCursor.style.top = pos.other.top + \"px\";\n\t otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n\t }\n\t }", "function drawCursor() {\n cursorContext.clearRect(0, 0, cursorCanvas.width, cursorCanvas.height);\n\n cursorContext.beginPath();\n cursorContext.arc(mouseX, mouseY, mouseWidth, 0, 2 * Math.PI, true);\n cursorContext.fillStyle = '#FF6A6A'\n cursorContext.fill();\n cursorContext.lineWidth = 1;\n cursorContext.strokeStyle = \"black\"\n cursorContext.stroke();\n }", "onMouseMove(e) {\n this.setCursor(this.cursor);\n }", "function showCursor(cur)\n {\n if (cur != undefined) selectCursor(cur);\n container.style.cursor = currentCursor;\n\t}", "function updateCursor(cursor){\r\n\tif(typeof hatsForm.notRefreshSafe != \"undefined\"){\r\n\t\treturn;\r\n\t}\r\n\thatsForm.CURSORPOSITION.value = cursor;\r\n\tresetCursor();\r\n}", "addToCursor(state, n){\n state.cursor += n\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "activate()\n\t{\n\t\tconsole.log(\"LineTool.activate\")\n\t\teditor.view.container.dom.style.cursor=\"crosshair\"\n\t\tthis.mouseIp=new InputPoint()\n\t\tthis.firstIp= new InputPoint();\n\t}", "function ksfCanvas_setCursor(cursor)\n{\n\t$(GRAPH_ID).css( 'cursor', cursor );\n}", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (/\\bcm-fat-cursor\\b/.test(cm.getWrapperElement().className)) {\n var charPos = charCoords(cm, head, \"div\", null, null);\n var width = charPos.right - charPos.left;\n cursor.style.width = (width > 0 ? width : cm.defaultCharWidth()) + \"px\";\n }\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (/\\bcm-fat-cursor\\b/.test(cm.getWrapperElement().className)) {\n var charPos = charCoords(cm, head, \"div\", null, null);\n var width = charPos.right - charPos.left;\n cursor.style.width = (width > 0 ? width : cm.defaultCharWidth()) + \"px\";\n }\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n }", "update_cursor() {\n let color = this.get_annotation_color(null, true);\n let thr_width = this.get_line_size()*this.state[\"zoom_val\"]\n let width = Math.max(Math.min(thr_width, 64), 6);\n let cursor_svg = `<svg version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" width=\"${width}px\" height=\"${width}px\" viewBox=\"0 0 ${width} ${width}\">\n <circle cx=\"${width/2}\" cy=\"${width/2}\" r=\"${width/2}\" opacity=\"0.8\" stroke=\"white\" fill=\"${color}\" />\n </svg>`;\n\n let bk_width = Math.max(Math.min(thr_width, 32), 6);\n let bk_cursor_svg = `<svg version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" width=\"${bk_width}px\" height=\"${bk_width}px\" viewBox=\"0 0 ${bk_width} ${bk_width}\">\n <circle cx=\"${bk_width/2}\" cy=\"${bk_width/2}\" r=\"${bk_width/2}\" opacity=\"0.8\" stroke=\"${color}\" fill=\"${color}\" />\n </svg>`;\n \n let cursor_b64 = btoa(cursor_svg);\n let bk_cursor_b64 = btoa(bk_cursor_svg);\n jquery_default()(\"#\"+this.config[\"annbox_id\"]).css(\n \"cursor\",\n `url(data:image/svg+xml;base64,${cursor_b64}) ${width/2} ${width/2}, url(data:image/svg+xml;base64,${bk_cursor_b64}) ${bk_width/2} ${bk_width/2}, auto`\n );\n }", "function cursorWait() {\n document.body.style.cursor = 'wait';\n }", "function getCursor() {\r\n\treturn [cursorLine,cursorColumn];\r\n}", "function onSelectionChangeCursor(e) {\n\n // find node that cursor points to\n var cursorPos = aceEditor.getCursorPosition();\n var astNodes = PARSED && PARSED.stylesheet && PARSED.stylesheet.rules || [];\n \n var cursorAstNode = _findAstNodeForCursorPosition(astNodes, cursorPos);\n\n fileEditor.hDev.publish(CURSOR_POSITION_CHANGE, {\n f: fileEditor.filepath,\n mode: MIME_TYPE,\n p: cursorPos,\n astNode: cursorAstNode ? _pickCssAstData(cursorAstNode) : {},\n });\n }", "async start() {\n await this._wait(this.startDelay)\n\n for (let line of this.lines) {\n const type = line.getAttribute(this.pfx)\n const delay = line.getAttribute(`${this.pfx}-delay`) || this.lineDelay\n\n if (type == \"input\") {\n line.setAttribute(`${this.pfx}-cursor`, this.cursor)\n await this.type(line)\n await this._wait(delay)\n } else if (type == \"progress\") {\n await this.progress(line)\n await this._wait(delay)\n } else {\n this.container.appendChild(line)\n await this._wait(delay)\n }\n\n line.removeAttribute(`${this.pfx}-cursor`)\n }\n }", "fillCursor(cursor) {\n\t\t\tconst line = this.getLine(cursor.line);\n\t\t\tconst colIndex = cursor.column.valueOf() - 1;\n\n\t\t\t// Amount of spaces to insert\n\t\t\tlet count = 0;\n\n\t\t\t// Calculate how many we need to insert\n\t\t\tlet i = colIndex - 1;\n\t\t\twhile (i >= 0 && (line.columns[i] === undefined || line.columns[i] === \"\")) {\n\t\t\t\ti--;\n\t\t\t\tcount++;\n\t\t\t}\n\n\t\t\t// Insert spaces\n\t\t\tfor (const char of this.getSpaces(count)) {\n\t\t\t\ti++;\n\t\t\t\tline.columns[i] = char;\n\t\t\t}\n\t\t}", "function decorateCursor(cursor) {\n cursor.eachAsync = function(fn, opts, callback) {\n if (typeof opts === 'function') {\n callback = opts;\n opts = {};\n }\n opts = opts || {};\n\n return eachAsync(function(cb) { return cursor.next(cb); }, fn, opts, callback);\n };\n}", "function animatedCursor() {\n\n if ($(\".aimated-cursor\").length) {\n\n var e = {x: 0, y: 0}, t = {x: 0, y: 0}, n = .25, o = !1, a = document.getElementsByClassName(\"cursor\"),\n i = document.getElementsByClassName(\"cursor-loader\");\n TweenLite.set(a, {xPercent: -50, yPercent: -50}), document.addEventListener(\"mousemove\", function (t) {\n var n = window.pageYOffset || document.documentElement.scrollTop;\n e.x = t.pageX, e.y = t.pageY - n\n }), TweenLite.ticker.addEventListener(\"tick\", function () {\n o || (t.x += (e.x - t.x) * n, t.y += (e.y - t.y) * n , TweenLite.set(a, {x: t.x, y: t.y}))\n }),\n $(\".animated-wrap\").mouseenter(function (e) {\n TweenMax.to(this, .3, {scale: 2}), TweenMax.to(a, .3, {\n scale: 1.5,\n borderWidth: \"1px\",\n opacity: .2\n }), TweenMax.to(i, .3, {\n scale: 1.5,\n borderWidth: \"1px\",\n top: 1,\n left: 1\n }), TweenMax.to($(this).children(), .3, {scale: .5}), o = !0\n }),\n $(\".animated-wrap\").mouseleave(function (e) {\n TweenMax.to(this, .3, {scale: 1}), TweenMax.to(a, .3, {\n scale: 1,\n borderWidth: \"2px\",\n opacity: 1\n }), TweenMax.to(i, .3, {\n scale: 1,\n borderWidth: \"2px\",\n top: 0,\n left: 0\n }), TweenMax.to($(this).children(), .3, {scale: 1, x: 0, y: 0}), o = !1\n }),\n $(\".animated-wrap\").mousemove(function (e) {\n var n, o, i, l, r, d, c, s, p, h, x, u, w, f, m;\n n = e, o = 2, i = this.getBoundingClientRect(), l = n.pageX - i.left, r = n.pageY - i.top, d = window.pageYOffset || document.documentElement.scrollTop, t.x = i.left + i.width / 2 + (l - i.width / 2) / o, t.y = i.top + i.height / 2 + (r - i.height / 2 - d) / o, TweenMax.to(a, .3, {\n x: t.x,\n y: t.y\n }), s = e, p = c = this, h = c.querySelector(\".animated-element\"), x = 20, u = p.getBoundingClientRect(), w = s.pageX - u.left, f = s.pageY - u.top, m = window.pageYOffset || document.documentElement.scrollTop, TweenMax.to(h, .3, {\n x: (w - u.width / 2) / u.width * x,\n y: (f - u.height / 2 - m) / u.height * x,\n ease: Power2.easeOut\n })\n }),\n $(\".hide-cursor,.btn,.tp-bullets\").mouseenter(function (e) {\n TweenMax.to(\".cursor\", .2, {borderWidth: \"1px\", scale: 2, opacity: 0})\n }), $(\".hide-cursor,.btn,.tp-bullets\").mouseleave(function (e) {\n TweenMax.to(\".cursor\", .3, {borderWidth: \"2px\", scale: 1, opacity: 1})\n }), $(\".link\").mouseenter(function (e) {\n TweenMax.to(\".cursor\", .2, {\n borderWidth: \"0px\",\n scale: 3,\n backgroundColor: \"rgba(5,5,5,0.27)\",\n opacity: .15\n })\n }), $(\".link\").mouseleave(function (e) {\n TweenMax.to(\".cursor\", .3, {\n borderWidth: \"2px\",\n scale: 1,\n backgroundColor: \"rgba(255,255,255,0)\",\n opacity: 1\n })\n })\n\n }\n\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine)\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"))\n cursor.style.left = pos.left + \"px\"\n cursor.style.top = pos.top + \"px\"\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\"\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"))\n otherCursor.style.display = \"\"\n otherCursor.style.left = pos.other.left + \"px\"\n otherCursor.style.top = pos.other.top + \"px\"\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\"\n }\n}", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine)\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"))\n cursor.style.left = pos.left + \"px\"\n cursor.style.top = pos.top + \"px\"\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\"\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"))\n otherCursor.style.display = \"\"\n otherCursor.style.left = pos.other.left + \"px\"\n otherCursor.style.top = pos.other.top + \"px\"\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\"\n }\n}", "function putCursor (color) {\r\n return \"<font color='\" + color + \"'>\" + this.cursor + \"</font>\";\r\n}", "function createCursor(tagName, attributes, children) {\n return [new AnchorToken(attributes), new FocusToken(attributes)];\n}", "_setCursor(x, y) {\n this._dirtyRowService.markDirty(this._bufferService.buffer.y);\n if (this._coreService.decPrivateModes.origin) {\n this._bufferService.buffer.x = x;\n this._bufferService.buffer.y = this._bufferService.buffer.scrollTop + y;\n }\n else {\n this._bufferService.buffer.x = x;\n this._bufferService.buffer.y = y;\n }\n this._restrictCursor();\n this._dirtyRowService.markDirty(this._bufferService.buffer.y);\n }", "function Cursor(type) {\n var maxArgs = 1;\n var delegate = arguments.length > maxArgs ?\n arguments[maxArgs] \n : arguments.length === 1 ? new javaClass(B.boxAsJava(type))\n : new javaClass();\n\n Object.defineProperty(this, \"unwrap\", {\n configurable: true,\n value: function() {\n return delegate;\n }\n });\n if(Cursor.superclass)\n Cursor.superclass.constructor.apply(this, arguments);\n delegate.setPublished(this);\n }", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n}", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n}", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n}", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n}", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n}", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n}", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n}", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n}", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n}", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n}", "function drawSelectionCursor(cm, head, output) {\n var pos = cursorCoords(cm, head, \"div\", null, null, !cm.options.singleCursorHeightPerLine);\n\n var cursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor\"));\n cursor.style.left = pos.left + \"px\";\n cursor.style.top = pos.top + \"px\";\n cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + \"px\";\n\n if (pos.other) {\n // Secondary cursor, shown when on a 'jump' in bi-directional text\n var otherCursor = output.appendChild(elt(\"div\", \"\\u00a0\", \"CodeMirror-cursor CodeMirror-secondarycursor\"));\n otherCursor.style.display = \"\";\n otherCursor.style.left = pos.other.left + \"px\";\n otherCursor.style.top = pos.other.top + \"px\";\n otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + \"px\";\n }\n}", "constructor() {\n super();\n this.name = 'cursor';\n this.SELECTION_TOLERANCE = 3;\n this.CURSOR_DEFAULT = 'cursors/default.png';\n this.CURSOR_SCALE_TOP_RIGHT_BOTTOM_LEFT = 'cursors/scale-top-right-bottom-left.png';\n this.CURSOR_SCALE_TOP_LEFT_BOTTOM_RIGHT = 'cursors/scale-top-left-bottom-right.png';\n this.CURSOR_SCALE_VERTICAL = 'cursors/scale-vertical.png';\n this.CURSOR_SCALE_HORIZONTAL = 'cursors/scale-horizontal.png';\n this.CURSOR_ROTATE_TOP = 'cursors/rotate-top-right.png';\n this.CURSOR_ROTATE_RIGHT = 'cursors/rotate-bottom-right.png';\n this.CURSOR_ROTATE_BOTTOM = 'cursors/rotate-bottom-left.png';\n this.CURSOR_ROTATE_LEFT = 'cursors/rotate-top-left.png';\n this.CURSOR_ROTATE_TOP_RIGHT = 'cursors/rotate-top-right.png';\n this.CURSOR_ROTATE_TOP_LEFT = 'cursors/rotate-top-left.png';\n this.CURSOR_ROTATE_BOTTOM_RIGHT = 'cursors/rotate-bottom-right.png';\n this.CURSOR_ROTATE_BOTTOM_LEFT = 'cursors/rotate-bottom-left.png';\n this.CURSOR_MOVE = 'cursors/move.png';\n this.CURSOR_SEGMENT = 'cursors/segment.png';\n this.CURSOR_CURVE = 'cursors/curve.png';\n this.HOVER_PREVIEW_SEGMENT_STROKE_COLOR = 'rgba(100,150,255,1.0)';\n this.HOVER_PREVIEW_SEGMENT_STROKE_WIDTH = 1.5;\n this.HOVER_PREVIEW_SEGMENT_FILL_COLOR = '#ffffff';\n this.HOVER_PREVIEW_SEGMENT_RADIUS = 5;\n this.HOVER_PREVIEW_CURVE_STROKE_WIDTH = 2;\n this.HOVER_PREVIEW_CURVE_STROKE_COLOR = this.HOVER_PREVIEW_SEGMENT_STROKE_COLOR;\n this.hitResult = new this.paper.HitResult();\n this.selectionBox = new this.paper.SelectionBox(paper);\n this.draggingCurve = new this.paper.Curve();\n this.draggingSegment = new this.paper.Segment();\n this.hoverPreview = new this.paper.Item({\n insert: false\n });\n this.selectedItems = [];\n this.currentCursorIcon = '';\n }" ]
[ "0.7385312", "0.6627222", "0.66079", "0.6439811", "0.63694715", "0.631824", "0.6286023", "0.6217564", "0.6203469", "0.6197986", "0.61702645", "0.6104216", "0.60769176", "0.604556", "0.6027897", "0.6027897", "0.6000636", "0.59923834", "0.59831095", "0.5976143", "0.5970618", "0.59676224", "0.5953087", "0.594606", "0.5926326", "0.5908495", "0.5888543", "0.58619684", "0.5852967", "0.58486927", "0.58322245", "0.5793345", "0.57798535", "0.5766921", "0.5744207", "0.56965554", "0.5682952", "0.5664967", "0.5656178", "0.5635883", "0.56160766", "0.5601828", "0.55855656", "0.5584632", "0.55794936", "0.5575392", "0.55696124", "0.55696124", "0.55670774", "0.55408794", "0.5539206", "0.553203", "0.55270076", "0.552573", "0.55140024", "0.55140024", "0.55140024", "0.55140024", "0.55140024", "0.55140024", "0.55140024", "0.55140024", "0.55140024", "0.55140024", "0.55140024", "0.55140024", "0.55140024", "0.55140024", "0.55140024", "0.55140024", "0.55123425", "0.55101967", "0.5499373", "0.5499373", "0.549381", "0.5492021", "0.54883116", "0.5484625", "0.54786956", "0.5477409", "0.54655945", "0.54601055", "0.54551595", "0.54551595", "0.5439107", "0.5436151", "0.5422919", "0.54190093", "0.54161686", "0.54161686", "0.54161686", "0.54161686", "0.54161686", "0.54161686", "0.54161686", "0.54161686", "0.54161686", "0.54161686", "0.54161686", "0.541373" ]
0.699894
1
let [x, y, z] = [0, 0, 0]; const meshX = new THREE.Vector3(1, 0, 0); scene.add(new THREE.AxisHelper( 200 )); mesh.rotation.z = Math.PI / 2; const arrowHelper = new THREE.ArrowHelper(meshX, new THREE.Vector3(), 300, 0xffffff); scene.add(arrowHelper);
function start() { document.body.appendChild( renderer.domElement ); mesh.rotation.set(-Math.PI/2, 0, 0); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function addHelpArrow() {\r\n\tlet dir = new THREE.Vector3(1, 2, 0);\r\n\tdir.normalize();\r\n\tlet origin = new THREE.Vector3(0, 0, 0);\r\n\tlet length = 1;\r\n\tlet hex = 0xffff00;\r\n\tlet arrowHelper = new THREE.ArrowHelper(dir, origin, length, hex);\r\n\tscene.add(arrowHelper);\r\n}", "drawGeometry(scene){\n var triangleGeometry = new THREE.Geometry();\n\n triangleGeometry.vertices.push(new THREE.Vector3(0,17,0));\n triangleGeometry.vertices.push(new THREE.Vector3(3,0,0));\n triangleGeometry.vertices.push(new THREE.Vector3(-3,0,0));\n\n triangleGeometry.faces.push( new THREE.Face3(0,1,2));\n\n var basicMaterial = new THREE.MeshBasicMaterial({\n color: 0x2685AA,\n side: THREE.DoubleSide\n });\n\n var triangleMesh = new THREE.Mesh(triangleGeometry, basicMaterial);\n scene.add(triangleMesh);\n }", "function createTriangle(geometry,topPoint,rightPoint,leftPoint,currentIndex) {\n\n\tif (facingCamera){//Regra da mao direita a comecar em cima\n\t\tgeometry.vertices.push(topPoint);\n\t\tgeometry.vertices.push(leftPoint);\n\t\tgeometry.vertices.push(rightPoint);\n\t}\n\telse{\n\t\tgeometry.vertices.push(topPoint);\n\t\tgeometry.vertices.push(rightPoint);\n\t\tgeometry.vertices.push(leftPoint);\n\t}\n\t\n\t\n\tvar color = new THREE.Color( 0x000000 );\n\t\n\tvar face = new THREE.Face3( currentIndex, currentIndex+1,currentIndex+2, color);\n\n\tgeometry.faces.push( face );\n\n\tgeometry.computeFaceNormals();\n\tgeometry.computeVertexNormals();\n}", "setupArrow() {\n const arrow = new Arrow(this, this.ball.mesh.position);\n this.add(arrow);\n this.arrow = arrow;\n }", "function constructArrowHelper(source, target) {\n\t\t\t\t// Instantiate origin and target in Vector3 format\n\t\t\t\tvar origin = new THREE.Vector3(10, 10, 10);\n\t\t\t\tvar terminus = new THREE.Vector3(0, 0, 0);\n\t\t\t\t\n\t\t\t\t// Calculate terminus vectors\n\t\t\t\tvar direction = new THREE.Vector3().subVectors(terminus, origin).normalize();\n\t\t\t\tvar distance = origin.distanceTo(terminus);\n\t\t\t\tvar arrow = new THREE.ArrowHelper(direction, origin, distance, 0x000000);\n\n\t\t\t\t// Set node data associated with the arrow\n\t\t\t\tarrow.userData = {\n\t\t\t\t\ttarget : nodes[nodelinks[i].target.name].name,\n\t\t\t\t\tsource : nodes[nodelinks[i].source.name].name\n\t\t\t\t};\n\t\t\t\tscene.add(arrow);\n\t\t\t}", "function renderer() {\n // if(left){\n // // camera.look.x +=0.1;\n // lookx +=0.1;\n // camera.lookAt({x:lookx,y:0,z:0});\n // if(Math.abs(lookx - 5)<0.00001){\n // left = false;\n // }\n // }\n // else{\n // lookx -=0.1;\n // if(Math.abs(lookx + 5) < 0.00001){\n // left = true;\n // }\n // }\n vth +=1\n camerax = Math.sin(vth*Math.PI/180)\n cameraz = Math.cos(vth*Math.PI/180)\n\n console.log(\"camerax %f j\",camerax)\n camera.lookAt(new THREE.Vector3(camerax, 0,10 - cameraz));\n // mesh.rotation.y += 0.1;\n render.render(scene,camera);\n window.requestAnimationFrame(renderer);\n}", "function OnDrawGizmos(){\t\n\ttransform.position = Vector3(transform.position.x,-3,transform.position.z);\n}", "function initArrow(s, tsize = 0.05, hsize = 0.5){\n VertexPositionBuffer = gl.createBuffer();\n gl.bindBuffer(gl.ARRAY_BUFFER, VertexPositionBuffer);\n vertices = [\n 0.5*hsize, s, 0.0,\n 0.0, s+hsize, 0.0,\n -0.5*hsize, s, 0.0,\n\n -1.*tsize, s, 0.0,\n tsize, s, 0.0,\n -1.*tsize, 0.0, 0.0,\n\n tsize, 0.0, 0.0,\n tsize, s, 0.0,\n -1.*tsize, 0.0, 0.0,\n\n ];\n\n gl.bufferData(gl.ARRAY_BUFFER, new Float32Array(vertices), gl.STATIC_DRAW);\n VertexPositionBuffer.itemSize = 3;\n VertexPositionBuffer.numItems = 9;\n gl.vertexAttribPointer(shaderProgram.vertexPositionAttribute, VertexPositionBuffer.itemSize, gl.FLOAT, false, 0, 0);\n gl.enableVertexAttribArray(0);\n\n}", "function addAxis(axis) {\n // set the color of the axis\n var color = new THREE.Color();\n color.setRGB(axis.x, axis.y, axis.z);\n var material = new THREE.MeshBasicMaterial({\n color : color.getHex()\n });\n\n // setup the rotation information\n var rotAxis = new THREE.Vector3();\n rotAxis.crossVectors(axis, new THREE.Vector3(0, -1, 0));\n var rot = new THREE.Quaternion();\n rot.setFromAxisAngle(rotAxis, 0.5 * Math.PI);\n\n // create the arrow\n var arrow = new THREE.Mesh(that.headGeom, material);\n arrow.position.copy(axis);\n arrow.position.multiplyScalar(0.95);\n arrow.quaternion.copy(rot);\n arrow.updateMatrix();\n that.add(arrow);\n\n // create the line\n var line;\n if (lineType === 'dashed') {\n var l = lineDashLength;\n for (var i = 0; (l / 2 + 3 * l * i + l / 2) <= 1; ++i) {\n var geom = new THREE.CylinderGeometry(shaftRadius, shaftRadius, l);\n line = new THREE.Mesh(geom, material);\n line.position.copy(axis);\n // Make spacing between dashes equal to 1.5 times the dash length.\n line.position.multiplyScalar(l / 2 + 3 * l * i);\n line.quaternion.copy(rot);\n line.updateMatrix();\n that.add(line);\n }\n } else if (lineType === 'full') {\n line = new THREE.Mesh(that.lineGeom, material);\n line.position.copy(axis);\n line.position.multiplyScalar(0.45);\n line.quaternion.copy(rot);\n line.updateMatrix();\n that.add(line);\n } else {\n console.warn('[ROS3D.Axes]: Unsupported line type. Not drawing any axes.');\n }\n }", "function crearMundo(){\n\tvar geometria = new THREE.PlaneGeometry(250,500);\n\tvar material = new THREE.MeshLambertMaterial({color: 0xB18904, side:THREE.DoubleSide});\n\n\tplano = new THREE.Mesh(geometria, material);\n\tplano.receiveShadow = true;\n\tplano.rotation.z = -.5 * Math.PI;\n\tplano.rotation.x = -.5 * Math.PI;\n\tvar axisHelper = new THREE.AxisHelper(100);\n \tescena.add(axisHelper);\n\tescena.add(plano);\n}", "constructor( dir = new Vector3( 0, 0, 1 ), origin = new Vector3( 0, 0, 0 ), length = 1, color = 0xffff00, headLength = length * 0.2, headWidth = headLength * 0.2 ) {\n\n\t\tsuper();\n\n\t\tthis.type = 'ArrowHelper';\n\n\t\tif ( _lineGeometry === undefined ) {\n\n\t\t\t_lineGeometry = new BufferGeometry();\n\t\t\t_lineGeometry.setAttribute( 'position', new Float32BufferAttribute( [ 0, 0, 0, 0, 1, 0 ], 3 ) );\n\n\t\t\t_coneGeometry = new CylinderGeometry( 0, 0.5, 1, 5, 1 );\n\t\t\t_coneGeometry.translate( 0, - 0.5, 0 );\n\n\t\t}\n\n\t\tthis.position.copy( origin );\n\n\t\tthis.line = new Line( _lineGeometry, new LineBasicMaterial( { color: color, toneMapped: false } ) );\n\t\tthis.line.matrixAutoUpdate = false;\n\t\tthis.add( this.line );\n\n\t\tthis.cone = new Mesh( _coneGeometry, new MeshBasicMaterial( { color: color, toneMapped: false } ) );\n\t\tthis.cone.matrixAutoUpdate = false;\n\t\tthis.add( this.cone );\n\n\t\tthis.setDirection( dir );\n\t\tthis.setLength( length, headLength, headWidth );\n\n\t}", "function createScene() {\r\n scene = new THREE.Scene();\r\n aspect = window.innerWidth / window.innerHeight;\r\n fov = 60;\r\n nearVal = 1;\r\n farVal = 950;\r\n\r\n scene.fog = new THREE.Fog(0xff5566, 120, 800);\r\n camera = new THREE.PerspectiveCamera(fov,aspect,nearVal,farVal);\r\n camera.position.x = 0;\r\n camera.position.z = 500;\r\n camera.position.y = 100;\r\n\r\n renderer = new THREE.WebGLRenderer({alpha: true,antialias: true});\r\n renderer.setSize(window.innerWidth, window.innerHeight);\r\n renderer.shadowMap.enabled = true;\r\n\r\n\r\n\r\n container = document.getElementById('bg');\r\n container.appendChild(renderer.domElement);\r\n\r\n controls = new THREE.DeviceOrientationControls( camera );// <------------ //for the phone (also a variable in)\r\n\r\n pivPoint = new THREE.Object3D();\r\n\r\n}", "function Three() {\n\n // const props = {ray:{direction:{new THREE.Vector3(1, 2, 3)}}};\n \n return (\n <Canvas camera={{ position: [0, 0, 0], fov:45}} >\n <Scene />\n <Controls />\n </Canvas>\n );\n}", "function addRoad() {\n var geometry = new THREE.PlaneGeometry( 300, 8000, 32 );\n var material = new THREE.MeshPhongMaterial( {color: 0x000000, side: THREE.DoubleSide} );\n var road = new THREE.Mesh( geometry, material );\n road.position.set(0, 75, -1000);\n road.rotation.x = (Math.PI / 180) * 90;\n scene.add( road );\n}", "function drawFloor(){\n var floorMaterial = new THREE.MeshBasicMaterial({color: 0x444444, side: THREE.DoubleSide});\n var floorGeometry = new THREE.PlaneGeometry(1000, 1000, 10, 10);\n var floor = new THREE.Mesh(floorGeometry, floorMaterial);\n floor.position.y = -0.5;\n floor.rotation.x = Math.PI/2;\n scene.add(floor);\n}", "function v(x,y,z){ \n\t return new THREE.Vertex(new THREE.Vector3(x,y,z)); \n\t }", "function init() {\n scene = new THREE.Scene();\n\n gridHelper = new THREE.GridHelper(10, 10);\n scene.add(gridHelper);\n\n axisHelper = new THREE.AxisHelper(10);\n scene.add(axisHelper);\n\n camera = new THREE.PerspectiveCamera(VIEW_ANGLE, ASPECT, NEAR, FAR);\n camera.position.set(15, 10, 15);\n // camera.lookAt(origin);\n\n // geometry = new THREE.BoxGeometry(50, 50, 50);\n // material = new THREE.MeshLambertMaterial({ color: 0x888888 });\n // mesh = new THREE.Mesh(geometry, material);\n // scene.add(mesh);\n\n // ambientLight = new THREE.AmbientLight(0xffffff, 0.1);\n // scene.add(ambientLight);\n\n pointLight = new THREE.PointLight(0xffffff, 1, 500);\n pointLight.position.set(10, 10, 10);\n scene.add(pointLight);\n\n const texture = new THREE.Texture();\n const textureLoader = new THREE.ImageLoader();\n textureLoader.load('../../assets/textures/misc/uv_grid_sm.jpg', (image) => {\n texture.image = image;\n texture.needsUpdate = true;\n });\n\n const loader = new THREE.OBJLoader();\n loader.load('../../assets/objects/minecraft-tree.obj', (object) => {\n // object.traverse((child) => {\n // if (child instanceof THREE.Mesh) {\n // child.material.map = texture;\n // }\n // });\n object.position.set(0, 4, 0);\n object.scale.set(0.01, 0.01, 0.01);\n scene.add(object);\n camera.lookAt(object.position);\n });\n\n renderer = new THREE.WebGLRenderer();\n renderer.setSize(window.innerWidth, window.innerHeight);\n\n controls = new THREE.OrbitControls(camera, renderer.domElement);\n\n THREEx.WindowResize(renderer, camera);\n\n document.body.appendChild(renderer.domElement);\n}", "function cubeAndArrow(x,y,z,color,color1,innerArr1 = true,innerArr2 = true,innerArr3 = true,innerArr4 = true,innerArr5 = true,innerArr6 = true){\r\n\r\n Cubes = []\r\n cube = new Cube(x,y,z,0.5,0.5,0.5);\r\n Cubes.push(cube.gObject(color1, white , 0.8));\r\n\r\n if (innerArr1){\r\n if (x>0){\r\n arr1 = new Line([[x-0.5,y+0.2,z],[x-1,y+0.2,z]]);\r\n arr11 = new Line([[x+0.5,y+0.2,z],[x-1,y+0.2,z]]);\r\n Cubes.push(arr1.gObject(color, 3));\r\n Cubes.push(arr11.arrowHead(color,3));\r\n }else{\r\n arr1 = new Line([[x-0.5,y,z],[x-1,y,z]]);\r\n arr11 = new Line([[x+0.5,y,z],[x-1,y,z]]);\r\n Cubes.push(arr1.gObject(color, 3));\r\n Cubes.push(arr11.arrowHead(color,3));\r\n }\r\n }else{\r\n arr1 = new Line([[0,0,0],[0,0,0]]);\r\n arr11 = new Line([[0,0,0],[0,0,0]]);\r\n Cubes.push(arr1.gObject(color, 0));\r\n Cubes.push(arr11.arrowHead(color,0));\r\n }\r\n\r\n if (innerArr2){\r\n if (x<0){\r\n arr2 = new Line([[x+0.5,y+0.2,z],[x+1,y+0.2,z]]);\r\n arr22 = new Line([[x-0.5,y+0.2,z],[x+1,y+0.2,z]]);\r\n Cubes.push(arr2.gObject(color, 3));\r\n Cubes.push(arr22.arrowHead(color,3));\r\n }else{\r\n arr2 = new Line([[x+0.5,y,z],[x+1,y,z]]);\r\n arr22 = new Line([[x-0.5,y,z],[x+1,y,z]]);\r\n Cubes.push(arr2.gObject(color, 3));\r\n Cubes.push(arr22.arrowHead(color,3));\r\n }\r\n }else{\r\n arr2 = new Line([[0,0,0],[0,0,0]]);\r\n arr22 = new Line([[0,0,0],[0,0,0]]);\r\n Cubes.push(arr2.gObject(color, 0));\r\n Cubes.push(arr22.arrowHead(color,0));\r\n }\r\n\r\n if (innerArr3){\r\n if (y>0){\r\n arr3 = new Line([[x,y-0.5,z+0.2],[x,y-1,z+0.2]]);\r\n arr33 = new Line([[x,y+0.5,z+0.2],[x,y-1,z+0.2]]);\r\n Cubes.push(arr3.gObject(color, 3));\r\n Cubes.push(arr33.arrowHead(color,3));\r\n }else{\r\n arr3 = new Line([[x,y-0.5,z],[x,y-1,z]]);\r\n arr33 = new Line([[x,y+0.5,z],[x,y-1,z]]);\r\n Cubes.push(arr3.gObject(color, 3));\r\n Cubes.push(arr33.arrowHead(color,3));\r\n }\r\n }else{\r\n arr3 = new Line([[0,0,0],[0,0,0]]);\r\n arr33 = new Line([[0,0,0],[0,0,0]]);\r\n Cubes.push(arr3.gObject(color, 0));\r\n Cubes.push(arr33.arrowHead(color,0));\r\n }\r\n\r\n if (innerArr4){\r\n if (y<0){\r\n arr4 = new Line([[x,y+0.5,z+0.2],[x,y+1,z+0.2]]);\r\n arr44 = new Line([[x,y-0.5,z+0.2],[x,y+1,z+0.2]]);\r\n Cubes.push(arr4.gObject(color, 3));\r\n Cubes.push(arr44.arrowHead(color,3));\r\n }else{\r\n arr4 = new Line([[x,y+0.5,z],[x,y+1,z]]);\r\n arr44 = new Line([[x,y-0.5,z],[x,y+1,z]]);\r\n Cubes.push(arr4.gObject(color, 3));\r\n Cubes.push(arr44.arrowHead(color,3));\r\n }\r\n }else{\r\n arr4 = new Line([[0,0,0],[0,0,0]]);\r\n arr44 = new Line([[0,0,0],[0,0,0]]);\r\n Cubes.push(arr4.gObject(color, 0));\r\n Cubes.push(arr44.arrowHead(color,0));\r\n }\r\n\r\n if (innerArr5){\r\n if (z>0){\r\n arr5 = new Line([[x+0.2,y,z-0.5],[x+0.2,y,z-1]]);\r\n arr55 = new Line([[x+0.2,y,z+0.5],[x+0.2,y,z-1]]);\r\n Cubes.push(arr5.gObject(color, 3));\r\n Cubes.push(arr55.arrowHead(color,3));\r\n }else{\r\n arr5 = new Line([[x,y,z-0.5],[x,y,z-1]]);\r\n arr55 = new Line([[x,y,z+0.5],[x,y,z-1]]);\r\n Cubes.push(arr5.gObject(color, 3));\r\n Cubes.push(arr55.arrowHead(color,3));\r\n }\r\n }else{\r\n arr5 = new Line([[0,0,0],[0,0,0]]);\r\n arr55 = new Line([[0,0,0],[0,0,0]]);\r\n Cubes.push(arr5.gObject(color, 0));\r\n Cubes.push(arr55.arrowHead(color,0));\r\n }\r\n\r\n\r\n if (innerArr6){\r\n if (z<0){\r\n arr6 = new Line([[x+0.2,y,z+0.5],[x+0.2,y,z+1]]);\r\n arr66 = new Line([[x+0.2,y,z-0.5],[x+0.2,y,z+1]]);\r\n Cubes.push(arr6.gObject(color, 3));\r\n Cubes.push(arr66.arrowHead(color,3));\r\n }else{\r\n arr6 = new Line([[x,y,z+0.5],[x,y,z+1]]);\r\n arr66 = new Line([[x,y,z-0.5],[x,y,z+1]]);\r\n Cubes.push(arr6.gObject(color, 3));\r\n Cubes.push(arr66.arrowHead(color,3));\r\n }\r\n }else{\r\n arr6 = new Line([[0,0,0],[0,0,0]]);\r\n arr66 = new Line([[0,0,0],[0,0,0]]);\r\n Cubes.push(arr6.gObject(color, 0));\r\n Cubes.push(arr66.arrowHead(color,0));\r\n }\r\n\r\n return Cubes;\r\n\r\n}", "function createScene() {\r\n // geometry\r\n var geometry = new THREE.Geometry(2,2,2);\r\n\r\n// Make the simplest shape possible: a triangle.\r\ngeometry.vertices.push(\r\n new THREE.Vector3(-10, 10, 0),\r\n new THREE.Vector3(-10, -10, 0),\r\n new THREE.Vector3( 10, -10, 0)\r\n);\r\n\r\n// Note that I'm assigning the face to a variable\r\n// I'm not just shoving it into the geometry.\r\nvar face = new THREE.Face4(0, 1, 2,3);\r\n\r\n// Assign the colors to the vertices of the face.\r\nface.vertexColors[0] = new THREE.Color(0xff0000); // red\r\nface.vertexColors[1] = new THREE.Color(0x00ff00); // green\r\nface.vertexColors[2] = new THREE.Color(0x0000ff); // blue\r\nface.vertexColors[3]= new THREE.Color(0x0000ff);\r\n// Now the face gets added to the geometry.\r\ngeometry.faces.push(face);\r\n\r\n// Using this material is important.\r\nvar material = new THREE.MeshBasicMaterial({vertexColors: THREE.VertexColors});\r\n\r\nvar mesh = new THREE.Mesh(geometry, material);\r\n scene.add(mesh);\r\n}", "function addAxis(axis) {\n // set the color of the axis\n var color = new THREE$1.Color();\n color.setRGB(axis.x, axis.y, axis.z);\n var material = new THREE$1.MeshBasicMaterial({\n color : color.getHex()\n });\n\n // setup the rotation information\n var rotAxis = new THREE$1.Vector3();\n rotAxis.crossVectors(axis, new THREE$1.Vector3(0, -1, 0));\n var rot = new THREE$1.Quaternion();\n rot.setFromAxisAngle(rotAxis, 0.5 * Math.PI);\n\n // create the arrow\n var arrow = new THREE$1.Mesh(that.headGeom, material);\n arrow.position.copy(axis);\n arrow.position.multiplyScalar(0.95);\n arrow.quaternion.copy(rot);\n arrow.updateMatrix();\n that.add(arrow);\n\n // create the line\n var line;\n if (lineType === 'dashed') {\n var l = lineDashLength;\n for (var i = 0; (l / 2 + 3 * l * i + l / 2) <= 1; ++i) {\n var geom = new THREE$1.CylinderGeometry(shaftRadius, shaftRadius, l);\n line = new THREE$1.Mesh(geom, material);\n line.position.copy(axis);\n // Make spacing between dashes equal to 1.5 times the dash length.\n line.position.multiplyScalar(l / 2 + 3 * l * i);\n line.quaternion.copy(rot);\n line.updateMatrix();\n that.add(line);\n }\n } else if (lineType === 'full') {\n line = new THREE$1.Mesh(that.lineGeom, material);\n line.position.copy(axis);\n line.position.multiplyScalar(0.45);\n line.quaternion.copy(rot);\n line.updateMatrix();\n that.add(line);\n } else {\n console.warn('[Axes]: Unsupported line type. Not drawing any axes.');\n }\n }", "function createPlane() {\n plane = new AirPlane();\n plane.mesh.position.y = 100;\n plane.mesh.scale.set(0.25, 0.25, 0.25);\n scene.add(plane.mesh);\n}", "function figureMeshAndContolDevice() {\n figureMaterial();\n Figure();\n\n oneSideMesh = new THREE.Mesh(geometry, material);\n\n scene = new THREE.Scene();\n scene.background = new THREE.Color(0x000000);\n scene.add(oneSideMesh);\n\n controls = new THREE.DeviceOrientationControls(oneSideMesh);\n}", "constructor() {\n\n //CREATE SCENE AND CAMERA\n this.scene = new THREE.Scene(); //everithing in Three library is preceed by three\n this.camera = new THREE.PerspectiveCamera(75, window.innerWidth / window.innerHeight, 0.1, 1000); //With perspective camera objects in the distance will appear smaller than objects in the foreground\n //THREE.PerspectiveCamera(angle, aspect ratio, nearest point to render from camera, farthest.....) \n\n //CREATE RENDERER\n this.renderer = new THREE.WebGLRenderer();\n this.renderer.setSize(window.innerWidth, window.innerHeight);\n document.body.appendChild(this.renderer.domElement); //apend canvas to document body\n\n //CREATE LIGHT\n const light = new THREE.DirectionalLight(\"rgb(255, 255, 255)\");\n light.position.set(0, 20, 10); //x,y,z\n const ambient = new THREE.AmbientLight(\"rgba(0, 112, 112, 0.44)\"); // soft white light\n\n //CREATE GEOMETRY AND MATERIAL\n const geometry = new THREE.BoxGeometry(1, 1, 1); //x,y,z\n const material = new THREE.MeshPhongMaterial({ color: \"rgb(0,170,255)\" });\n\n //CREATE MESH\n this.cube = new THREE.Mesh(geometry, material);\n\n //ADD ELEMENTS TO SCENE\n this.scene.add(this.cube);\n this.scene.add(light);\n this.scene.add(ambient);\n\n this.camera.position.z = 3;\n\n this.animate();\n }", "function init() {\t\r\n\tcontainer = document.createElement( 'div' );\r\n\tdocument.body.appendChild( container );\r\n\t\r\n\tscene = new THREE.Scene();\r\n\tstats = new Stats();\r\n\tstats.domElement.id='stats_monitor';\r\n\tstats.domElement.style.position = 'absolute';\r\n\tstats.domElement.style.top='5px';\r\n\tstats.domElement.style.left='4px';\t\r\n\tdocument.body.insertBefore(stats.domElement,document.getElementById('axis_legend'));\r\n\tcamera = new THREE.PerspectiveCamera( 90, window.innerWidth / window.innerHeight, 1, 1200 );\r\n\tcamera.position.y = 150;\r\n\tcamera.position.z = 400;\r\n\tscene.add( camera );\r\n\r\n\t// Cube\r\n\tmaterial = new THREE.MeshBasicMaterial( {color: 0xffffff, wireframe: true, transparent: false, opacity: 0 } ) ;\r\n\tmaterial.transparent=true ; \r\n\tcube = new THREE.Mesh( new THREE.CubeGeometry( 300, 300, 300), material );\r\n\tcube.position.y = 175 ;\r\n\tvar planes = CreateCube(300,300,300,\"0\",\"0\",\"0\") ;\r\n\t\r\n\t// Add cube to the scene\r\n\t\r\n\tvar i, j ;\r\n\tvar pln, lln ;\r\n\tpln = planes.length ;\r\n\tfor(i = 0; i < pln ; i++){\r\n\t\tlln = planes[i].length ;\r\n \tfor(j = 0; j < lln; j++){\r\n\t\t\tcube.add(planes[i][j]) ;\r\n\t\t}\r\n\t}\t\r\n\t\r\n\t// Add cube to the scene\r\n\tscene.add( cube );\r\n\t\r\n\t// Plane\r\n\tplane = new THREE.Mesh( new THREE.PlaneGeometry( 300, 300), new THREE.MeshBasicMaterial( { color: 0xe8e8e8 } ) );\r\n\tplane.rotation.x = -90 * ( Math.PI / 180 );\r\n\tscene.add( plane ) ;\r\n\trenderer = new THREE.WebGLRenderer();\r\n\trenderer.setSize( window.innerWidth, window.innerHeight);\r\n\twindow.addEventListener( 'resize', onWindowResize, false );\r\n\tcontainer.appendChild( renderer.domElement );\r\n\r\n}", "function createAxesHelper() {\r\n const axesHelper = new THREE.AxesHelper(100);\r\n return axesHelper;\r\n}", "function onCreate() {\n /***************************** SETUP SCENE *****************************/\n // Create the scene\n scene = new THREE.Scene();\n // scene.fog = new THREE.FogExp2( 0xffffff, 0.015 )\n\n /***************************** SETUP CAMERA *****************************/\n\n camera = new THREE.PerspectiveCamera(45, window.innerWidth / window.innerHeight, 0.00001, 1000);\n camera.lat = Math.random();\n camera.lng = Math.random();\n camera.position.set(0,0,0);\n camera.lookAt(new THREE.Vector3(0,0,1));\n // camera.lookAt(new THREE.Vector3(0,2,0));\n // camera.lookAt(new THREE.Vector3(0,0,1));\n // console.log(camera.position)\n scene.add(camera);\n\n /**************************** SETUP PLANE ****************************/\n // var positions = [{x:0, y:0, z:100},\n // {x:100, y:0, z:100},\n // {x:-100, y:0, z:100},\n //\n // {x:0, y:0, z:0},\n // {x:100, y:0, z:0},\n // {x:-100, y:0, z:0},\n //\n // {x:0, y:0, z:-100},\n // {x:100, y:0, z:-100},\n // {x:-100, y:0, z:-100}];\n //\n // for (var i = 0; i < 9; i++) {\n // var aPlane = new THREE.Mesh(new THREE.PlaneGeometry( 100, 100 ),\n // new THREE.MeshBasicMaterial(\n // {color: colors[i],\n // side: THREE.DoubleSide} )\n // );\n // aPlane.position.set(\n // positions[i].x,\n // positions[i].y,\n // positions[i].z\n // );\n // aPlane.rotation.x = Math.PI/2; //angles[i];\n // scene.add( aPlane );\n // }\n\n /***************************** SETUP IMAGE(S) *****************************/\n // material\n THREE.ImageUtils.crossOrigin = \"anonymous\";\n\n graffitiArray.forEach(function(graffiti) {\n var pos = {\n x: (loc.coords.longitude - parseFloat(graffiti.lng)),\n y: 0,\n z: (loc.coords.latitude - parseFloat(graffiti.lat))};\n var theta = Math.random();\n console.log(pos, theta);\n var name = './pics/' + graffiti.id + \".jpg\"\n\n var material = new THREE.MeshBasicMaterial({\n map: THREE.ImageUtils.loadTexture(name),\n side: THREE.DoubleSide});\n\n // image\n var img = new THREE.Mesh(new THREE.PlaneGeometry(0.0001, 0.0001), material);\n // img.overdraw = true;\n img.needsUpdate = true;\n img.position.x = pos.x;\n img.position.y = pos.y;\n img.position.z = pos.z;\n img.rotation.y = theta;\n\n img.graffiti = { lat: graffiti.lat, lng: graffiti.lng }\n images.push(img);\n\n })\n\n images.forEach(function(img) {\n scene.add(img);\n })\n\n\n /***************************** SETUP PointLight *****************************/\n var pointLight = new THREE.PointLight( 0xFFFFFF );\n\n // set its position\n pointLight.position.x = 0;\n pointLight.position.y = 100;\n pointLight.position.z = 0;\n scene.add(pointLight);\n\n /***************************** SETUP RENDERER *****************************/\n // Check whether the browser supports WebGL\n\n // if(Detector.webgl){\n // renderer = new THREE.WebGLRenderer({antialias:true});\n // // alert(\"In WebGL mode!!\");\n // // If its not supported, instantiate the canvas renderer to support all non WebGL browsers\n // } else {\n // renderer = new THREE.CanvasRenderer();\n // // alert(\"In Canvas mode!!\");\n // }\n renderer = new THREE.CanvasRenderer();\n\n // Set the background color of the renderer to black, with full opacity\n renderer.setClearColor(0x000000, 1);\n\n // start the renderer\n renderer.setSize(window.innerWidth, window.innerHeight);\n\n // get the DOM element to attach to - assume we've got jQuery to handle this\n var container = $('#container');\n\n // attach the render-supplied DOM element\n window.addEventListener('keydown', checkKey, false);\n window.addEventListener( 'resize', onWindowResize, false );\n\n container.append(renderer.domElement);\n\n $(window).load(renderScene);\n\n onFrame();\n}", "function drawArrow(base, vec, myColor) {\n\tpush();\n\tstroke(myColor);\n\tstrokeWeight(3);\n\tfill(myColor);\n\ttranslate(base.x, base.y);\n\tline(0, 0, vec.x, vec.y);\n\trotate(vec.heading());\n\tvar arrowSize = 7;\n\ttranslate(vec.mag() - arrowSize, 0);\n\ttriangle(0, arrowSize / 2, 0, -arrowSize / 2, arrowSize, 0);\n\tpop();\n}", "function addRoadLiner() {\n var geometry = new THREE.BoxGeometry( 5, 6000, 1 );\n var material = new THREE.MeshBasicMaterial( {color: 0x8B008B} );\n var cube = new THREE.Mesh( geometry, material );\n cube.position.set(-150, 77, -2000);\n cube.rotation.x = Math.PI/180 * 90;\n scene.add( cube );\n\n geometry = new THREE.BoxGeometry( 5, 6000, 1 );\n material = new THREE.MeshBasicMaterial( {color: 0x8B008B} );\n cube = new THREE.Mesh( geometry, material );\n cube.position.set(150, 77, -2000);\n cube.rotation.x = Math.PI/180 * 90;\n scene.add( cube );\n}", "function drawArrow(x, y, angle, legLength = 10) {\n push();\n translate(x, y);\n rotate(radians(90));\n rotate(radians(angle));\n push();\n rotate(radians(45));\n line(0, 0, legLength, 0);\n pop();\n push();\n rotate(radians(135));\n line(0, 0, legLength, 0);\n pop();\n pop();\n}", "createGizmo (center, euler, size, radius, color, range, axis) {\n\n var material = new GizmoMaterial({\n color: color\n })\n\n var subMaterial = new GizmoMaterial({\n color: color\n })\n\n var torusGizmo = new THREE.Mesh(\n new THREE.TorusGeometry(\n radius, size, 64, 64, range),\n material)\n\n var subTorus = new THREE.Mesh(\n new THREE.TorusGeometry(\n radius, size, 64, 64, 2 * Math.PI),\n subMaterial)\n\n subTorus.material.highlight(true)\n\n var transform = new THREE.Matrix4()\n\n var q = new THREE.Quaternion()\n\n q.setFromEuler(euler)\n\n var s = new THREE.Vector3(1, 1, 1)\n\n transform.compose(center, q, s)\n\n torusGizmo.applyMatrix(transform)\n\n subTorus.applyMatrix(transform)\n\n var plane = this.createBox(\n this.size * 100,\n this.size * 100,\n 0.01)\n\n plane.applyMatrix(transform)\n\n subTorus.visible = false\n\n this.viewer.impl.addOverlay(\n this.overlayScene, torusGizmo)\n\n this.viewer.impl.addOverlay(\n this.overlayScene, subTorus)\n\n torusGizmo.subGizmo = subTorus\n torusGizmo.plane = plane\n torusGizmo.axis = axis\n\n return torusGizmo\n }", "function rotateZ() {\n console.log('rotate about z triggered');\n var cosA = Math.cos(0.05);\n var sinA = Math.sin(0.05);\n var m = new THREE.Matrix4();\n m.set( cosA, sinA, 0, 0,\n -sinA, cosA, 0, 0,\n 0, 0, 1, 0,\n 0, 0, 0, 1 );\n geometry.applyMatrix(m);\n // render\n render();\n}", "renderArrow_() {\n const steps = [];\n // Find the relative coordinates of the center of the bubble.\n const relBubbleX = this.width_ / 2;\n const relBubbleY = this.height_ / 2;\n // Find the relative coordinates of the center of the anchor.\n let relAnchorX = -this.relativeLeft_;\n let relAnchorY = -this.relativeTop_;\n if (relBubbleX === relAnchorX && relBubbleY === relAnchorY) {\n // Null case. Bubble is directly on top of the anchor.\n // Short circuit this rather than wade through divide by zeros.\n steps.push('M ' + relBubbleX + ',' + relBubbleY);\n } else {\n // Compute the angle of the arrow's line.\n const rise = relAnchorY - relBubbleY;\n let run = relAnchorX - relBubbleX;\n if (this.workspace_.RTL) {\n run *= -1;\n }\n const hypotenuse = Math.sqrt(rise * rise + run * run);\n let angle = Math.acos(run / hypotenuse);\n if (rise < 0) {\n angle = 2 * Math.PI - angle;\n }\n // Compute a line perpendicular to the arrow.\n let rightAngle = angle + Math.PI / 2;\n if (rightAngle > Math.PI * 2) {\n rightAngle -= Math.PI * 2;\n }\n const rightRise = Math.sin(rightAngle);\n const rightRun = Math.cos(rightAngle);\n\n // Calculate the thickness of the base of the arrow.\n const bubbleSize = this.getBubbleSize();\n let thickness =\n (bubbleSize.width + bubbleSize.height) / Bubble.ARROW_THICKNESS;\n thickness = Math.min(thickness, bubbleSize.width, bubbleSize.height) / 4;\n\n // Back the tip of the arrow off of the anchor.\n const backoffRatio = 1 - Bubble.ANCHOR_RADIUS / hypotenuse;\n relAnchorX = relBubbleX + backoffRatio * run;\n relAnchorY = relBubbleY + backoffRatio * rise;\n\n // Coordinates for the base of the arrow.\n const baseX1 = relBubbleX + thickness * rightRun;\n const baseY1 = relBubbleY + thickness * rightRise;\n const baseX2 = relBubbleX - thickness * rightRun;\n const baseY2 = relBubbleY - thickness * rightRise;\n\n // Distortion to curve the arrow.\n let swirlAngle = angle + this.arrow_radians_;\n if (swirlAngle > Math.PI * 2) {\n swirlAngle -= Math.PI * 2;\n }\n const swirlRise = Math.sin(swirlAngle) * hypotenuse / Bubble.ARROW_BEND;\n const swirlRun = Math.cos(swirlAngle) * hypotenuse / Bubble.ARROW_BEND;\n\n steps.push('M' + baseX1 + ',' + baseY1);\n steps.push(\n 'C' + (baseX1 + swirlRun) + ',' + (baseY1 + swirlRise) + ' ' +\n relAnchorX + ',' + relAnchorY + ' ' + relAnchorX + ',' + relAnchorY);\n steps.push(\n 'C' + relAnchorX + ',' + relAnchorY + ' ' + (baseX2 + swirlRun) +\n ',' + (baseY2 + swirlRise) + ' ' + baseX2 + ',' + baseY2);\n }\n steps.push('z');\n this.bubbleArrow_.setAttribute('d', steps.join(' '));\n }", "function figureMaterial() {\n material = new THREE.MeshNormalMaterial({side: 3, wireframe: true})\n}", "function initThree(){ \n scene = new THREE.Scene();\n camera = new THREE.PerspectiveCamera(75, window.innerWidth / window.innerHeight, 0.1, 1000000000);\n renderer = new THREE.WebGLRenderer({ antialias: false, alpha: true });\n var bgTexture = THREE.ImageUtils.loadTexture(\"textures/stars-mw-map.jpg\");\n scene.background = bgTexture;\n renderer.setSize(window.innerWidth, window.innerHeight);\n renderer.setClearColor(0x000000, 0);\n camera.position.z = 1000;\n document.body.appendChild(renderer.domElement);\n controls = new THREE.OrbitControls(camera); \n controls.objectToFollow = new THREE.Object3D();\n}", "function add_environment(){\n var geometry = new THREE.PlaneGeometry( 200, 100, 32 );\n\t//var material = new THREE.MeshBasicMaterial( {color: 0x666666, side: THREE.DoubleSide} );\n\tvar material = new THREE.MeshLambertMaterial({color: 0x889988});\n\tvar plane = new THREE.Mesh( geometry, material );\n\tplane.rotation.x = -Math.PI / 2;\n\t//plane.castShadow = true;\n\tplane.receiveShadow = true;\n scene.add( plane );\n}", "function v(x,y,z){\n return new THREE.Vector3(x,y,z); \n }", "function makePlane() {\n\tvar body = new THREE.Shape();\n\tbody.moveTo(5,4); // start point of first curve (plane head)\n\tbody.bezierCurveTo(-2,4, -2,0, 5,0);\n\tbody.bezierCurveTo(7,0, 13,0, 13,4);\n\tbody.bezierCurveTo(12,2, 6,4, 5,4);\n\n\tvar wing = new THREE.Shape();\n\twing.moveTo(0,0);\n\twing.bezierCurveTo(0,5, 5,5, 5,0);\n\n\tvar bodyMat = new THREE.MeshPhongMaterial( {color: 0xC0C0C0, // light grey\n\t \t\t\t\t\t\t\t\t\t\t\tambient: 0xC0C0C0, \n\t specular: 0xC0C0C0,\n\t shininess: 5,\n\t transparent: true,\n\t opacity: 0.8} );\n\n\tvar wingMat = new THREE.MeshPhongMaterial( {color: 0xCC0000, // red\n\t \t\t\t\t\t\t\t\t\t\t\tambient: 0xCC0000, \n\t specular: 0xCC0000,\n\t shininess: 5,\n\t \ttransparent: true,\n\t opacity: 0.8} );\n\n\tvar options = {\n\t\tamount: 5,\n\t\tbevelThickness: 1,\n\t\tbevelSize: 0,\n\t\tbevelSegments: 3,\n\t\tbevelEnabled: true,\n\t\tcurveSegments: 12,\n\t\tsteps: 1\n\t};\n\n\tvar bodyMesh = new THREE.Mesh(new THREE.ExtrudeGeometry(body, options), bodyMat);\n\tbodyMesh.scale.set(16, 16, 4); // enlarges airplane body\n\n\t// helper function to create wing meshes\n\tfunction makeWingMesh(side) {\n\t\tvar wingMesh = new THREE.Mesh(new THREE.ExtrudeGeometry(wing, options), wingMat);\n\t\twingMesh.scale.set(16, 20, 2);\n\t\twingMesh.position.set(40, 20, 0);\n\t\twingMesh.rotation.x = side*Math.PI/1.5;\n\t\treturn wingMesh;\n\t}\n\n\tvar wing1 = makeWingMesh(1);\n\tvar wing2 = makeWingMesh(-1);\n\twing1.position.set(40, 30, 20);\n\n\t// helper function to create a window mesh\n\tfunction makeWindow() {\n\t\tvar windowGeom = new THREE.SphereGeometry(9,20,20);\n\t\tvar windowMat = new THREE.MeshPhongMaterial( {color: 0xA0A0A0, // grey\n\t \t\t\t\t\t\t\t\t\t\t\tambient: 0xA0A0A0, \n\t specular: 0xA0A0A0,\n\t shininess: 5,\n\t \ttransparent: true,\n\t opacity: 0.7} );\n\t\tvar windowMesh = new THREE.Mesh(windowGeom, windowMat);\n\t\twindowMesh.scale.y = 2;\n\t\twindowMesh.rotation.x = Math.PI/2;\n\t\twindowMesh.position.set(40, 45, 10);\n\t\treturn windowMesh;\n\t}\n\n\tvar windowSpace = 35; // space between the windows\n\n\t// makes three sets of windows (appearing on both sides of plane)\n\tvar window1 = makeWindow();\n\tvar window2 = makeWindow();\n\twindow2.position.x += windowSpace;\n\tvar window3 = makeWindow();\n\twindow3.position.x += windowSpace*2;\n\n\tvar plane = new THREE.Object3D();\n\tplane.add(bodyMesh);\n\tplane.add(wing1);\n\tplane.add(wing2);\n\tplane.add(window1);\n\tplane.add(window2);\n\tplane.add(window3);\n\tplane.scale.set(.5,.5,.5);\n\n\treturn plane;\n}", "function buildLeftBorder(geometry,currentIndex){\n\tif(facingCamera){/*Serve para construir face que pode ser vista de fora*/\n\n\t\tgeometry.vertices.push(new THREE.Vector3(0,0.25,0));//PONTO A\n\t\tgeometry.vertices.push(new THREE.Vector3(0,0.25,-0.10));// PONTO B\n\t\tgeometry.vertices.push(new THREE.Vector3(-0.25,-0.25,0));// PONTO C\n\t\t\n\t\tvar color = new THREE.Color( 0x000000 );\n\t\tvar face = new THREE.Face3(currentIndex,currentIndex+1,currentIndex+2,color);\n\t\tcurrentIndex += 3;\n\t\tgeometry.faces.push(face)\n\n\t\tgeometry.vertices.push(new THREE.Vector3(-0.25,-0.25,0));\n\t\tgeometry.vertices.push(new THREE.Vector3(0,0.25,-0.10));\n\t\tgeometry.vertices.push(new THREE.Vector3(-0.25,-0.25,-0.10));\n\t\tface = new THREE.Face3(currentIndex,currentIndex+1,currentIndex+2,color);\n\t\tcurrentIndex += 3;\n\t\tgeometry.faces.push(face)\n\n\t}\n\telse{/*Serve para construir face que pode ser vista de dentro*/\n\t\tgeometry.vertices.push(new THREE.Vector3(0,0.25,0));//PONTO A\n\t\tgeometry.vertices.push(new THREE.Vector3(-0.25,-0.25,0));// PONTO C A DIFERENCA ESTA NA ORDEM\n\t\tgeometry.vertices.push(new THREE.Vector3(0,0.25,-0.10));// PONTO B DESTAS DUAS LINHAS QUE ESTAO TROCADAS\n\t\t\t\n\t\tvar color = new THREE.Color( 0x000000 );\n\t\tvar face = new THREE.Face3(currentIndex,currentIndex+1,currentIndex+2,color);\n\t\tcurrentIndex += 3;\n\t\tgeometry.faces.push(face)\n\n\t\tgeometry.vertices.push(new THREE.Vector3(-0.25,-0.25,0));\n\t\tgeometry.vertices.push(new THREE.Vector3(-0.25,-0.25,-0.10));\n\t\tgeometry.vertices.push(new THREE.Vector3(0,0.25,-0.10));\n\t\tface = new THREE.Face3(currentIndex,currentIndex+1,currentIndex+2,color);\n\t\tcurrentIndex += 3;\n\t\tgeometry.faces.push(face)\n\n\n\t}\n}", "function initCore() {\n // Create renderer\n renderer = new THREE.WebGLRenderer();\n renderer.setClearColor(BACKGROUND_COLOR, 1.0);\n renderer.setSize(window.innerWidth, window.innerHeight);\n document.body.appendChild(renderer.domElement);\n\n // Create scene\n scene = new THREE.Scene();\n scene.add(new THREE.AxisHelper(100));\n\n // Create camera\n camera = new THREE.PerspectiveCamera(65, window.innerWidth / window.innerHeight, 0.1, 1000);\n camera.position.set(0, 10, 0);\n camera.lookAt(scene.position);\n\n // Create main light\n //var light = new THREE.DirectionalLight('white', 1.0);\n var light = new THREE.DirectionalLight('white', 0.5);\n light.position.set(50, 100, 50);\n scene.add(light);\n scene.add(new THREE.AmbientLight(0x888888));\n}", "function createBase(){\n\nvar curve = new THREE.CatmullRomCurve3( [\n new THREE.Vector3( 30, 0, 0),\n new THREE.Vector3( -30, 0, 0 ),\n new THREE.Vector3( 0, 0, 30 ),\n new THREE.Vector3( 30, 0, 0)\n] );\n\nvar geometry = new THREE.TubeGeometry( curve, sceneParams.tubularSegments, sceneParams.baseRadius, sceneParams.radiusSegments, false );\nvar material = new THREE.MeshBasicMaterial( { color: sceneParams.woodColor } );\nvar mesh = new THREE.Mesh( geometry, material );\n\ncounter.add(mesh);\n}", "function Arrow(x, y, dx, dy, color) {\r\n\treturn {\r\n\t\ttype: \"arrow\",\r\n\t\tx: x,\r\n\t\ty: y,\r\n\t\tdx: dx,\r\n\t\tdy: dy,\r\n\t\tcolor: color,\r\n\t\ttranslate: function(dx, dy) {\r\n\t\t\twith (this) {\r\n\t\t\t\tx += dx;\r\n\t\t\t\tx += dx;\r\n\t\t\t}\r\n\t\t},\r\n\t\tdraw: function (ctx) {\r\n \t\twith (this) {\r\n \t\t\tLine([x,y,x+dx,y+dy], color, color).draw(ctx);\r\n\r\n // arrows are hard, adapted from here:\r\n // http://www.dbp-consulting.com/tutorials/canvas/CanvasArrow.html\r\n // x1 = x, y1 = y, x2 = x+dx, y2 = y+dy\r\n var angle = Math.PI/8; // angle arrowhead makes with line\r\n var d = 20; // length of arrowhead hypotenuses\r\n\r\n // calculate the angle of the line\r\n var theta=Math.atan2(dy,dx);\r\n // h is the line length of a side of the arrow head\r\n var h=Math.abs(d/Math.cos(angle));\r\n // angle of top hypotenuse with +X axis\r\n var angle1=theta+Math.PI+angle;\r\n // x, y coordinates of top corner\r\n var topx=x+dx+Math.cos(angle1)*h;\r\n var topy=y+dy+Math.sin(angle1)*h;\r\n // same calculations, but for bottom hypotenuse and corner\r\n var angle2=theta+Math.PI-angle;\r\n var botx=x+dx+Math.cos(angle2)*h;\r\n var boty=y+dy+Math.sin(angle2)*h;\r\n\r\n \t\t\tTriangle(x+dx, y+dy, topx, topy, botx, boty, color, color).draw(ctx);\r\n \t\t}\r\n \t}\r\n }\r\n}", "function createTriangle() {\n\n var testTriangle_geom = new THREE.Geometry();\n\n var tv0 = new THREE.Vector3(0,0,-100);\n var tv1 = new THREE.Vector3(100,0,0);\n var tv2 = new THREE.Vector3(0,0,100);\n var tv3 = new THREE.Vector3(0,100,0);\n testTriangle_geom.vertices.push(tv0,tv1,tv2,tv3);\n\n var tf0 = new THREE.Face3(0,1,2);\n var tf1 = new THREE.Face3(2,3,0);\n var tf2 = new THREE.Face3(3,1,0);\n var tf3 = new THREE.Face3(2,1,3);\n\n var c1 = new THREE.Color(0xFF0000);//顶点1颜色——红色\n var c2 = new THREE.Color(0x00FF00);//顶点2颜色——绿色\n var c3 = new THREE.Color(0x0000FF);//顶点3颜色——蓝色\n\n // 设置各个顶点颜色\n testTriangle_geom.colors.push(c1,c2,c3,c1);\n\n // tf0.vertexColors.push(c1, c2, c3);//定义三角面三个顶点的颜色\n // tf1.vertexColors.push(c1, c2, c3);//定义三角面三个顶点的颜色\n // tf2.vertexColors.push(c1, c2, c3);//定义三角面三个顶点的颜色\n // tf3.vertexColors.push(c1, c2, c3);//定义三角面三个顶点的颜色\n\n testTriangle_geom.faces.push(tf0,tf1,tf2,tf3);\n\n var random_material=new THREE.MeshLambertMaterial({\n vertexColors: THREE.VertexColors,//以顶点颜色为准\n side: THREE.DoubleSide,//两面可见\n opacity: 1.0\n });//材质对象\n\n // var testTriangle = new THREE.Mesh(testTriangle_geom,random_material);\n // scene_3D_S.add(testTriangle);\n\n\n // ShaderMaterial测试\n var attributes = {\n color_r: {\n type: 'f', // a float\n value: [] // an empty array\n },\n color_g: {\n type: 'f', // a float\n value: [] // an empty array\n },\n color_b:{\n type: 'f', // a float\n value: [] // an empty array\n }\n };\n // now populate the array of attributes\n var verts = testTriangle_geom.vertices;\n var color_r = attributes.color_r.value;\n var color_g = attributes.color_g.value;\n var color_b = attributes.color_b.value;\n for (var v = 0; v < verts.length; v++) {\n color_r.push(Math.random());\n color_g.push(Math.random());\n color_b.push(Math.random());\n }\n console.log(color_r);\n\n var shaderMaterial_test;\n // // load shader\n $.get('http://localhost:3000/../shaders/my.vs', function(vShader){\n $.get('http://localhost:3000/../shaders/my.fs', function(fShader){\n // console.log(vShader); // test success\n // console.log(fShader); // test success\n shaderMaterial_test = new THREE.ShaderMaterial({\n vertexShader: vShader,\n fragmentShader: fShader,\n attributes: attributes\n });\n // create triangle and add it to scene[这两步必须放到材质生成之后,jQuery中]\n var triangle_test = new THREE.Mesh(testTriangle_geom, shaderMaterial_test);//网格模型对象\n scene_3D_S.add(triangle_test); //模型添加到场景中\n });\n });\n}", "function v(x,y,z){\n return new THREE.Vertex(new THREE.Vector3(x,y,z));\n }", "function createObjV1(x, y, z) {\n 'use strict';\n\n objV1 = new THREE.Object3D();\n objV1.userData = {\n rotClockwise: false, \n rotAntiClockwise: false, \n movingL: false, \n movingR: false, \n movingU: false, \n movingD: false\n };\n\n materialObjV1 = new THREE.MeshBasicMaterial({ color: 0x0099db, wireframe: true});\n material = materialObjV1;\n\n addVerticalCylinder(objV1, 0, 35.65, 0, 2);\n\n addHorizontalCylinder(objV1, -10, 42, 0, 2);\n\taddVerticalCylinder(objV1, -20, 38, 0, 0.9);\n\taddHorizontalCylinder(objV1, -20, 34, 0, 1);\n\taddFlatParallelepiped(objV1, -22 - 6, 34, 0, 2);\n\taddFlatDiamond(objV1, -5 - 6, 34, 0, 2);\n\n\taddHorizontalCylinder(objV1, 5, 34, 0, 1);\n\taddFlatCylinder(objV1, 10 + 6, 34, 0, 2);\n\n\taddObjV2(objV1, 0, 0, 0);\n\n\tobjV1.position.set(x, y, z);\n\tscene.add(objV1);\n \n}", "function createButton(x, y, z, callback) {\n var buttonGeo = new THREE.BoxBufferGeometry(.2, .2, .2)\n var buttonMesh = new THREE.Mesh(buttonGeo, mRed)\n buttonMesh.position.x = x\n buttonMesh.position.y = y\n buttonMesh.position.z = z\n buttonMesh.callback = callback;\n buttonMesh.flavor = \"button\"\n return buttonMesh;\n}", "function base() {\n\t\tvar geo = new THREE.CubeGeometry( 11, 0.5, 11 );\n\t\tvar mat = new THREE.MeshBasicMaterial(\n\t\t\t\t\t\t{ \tcolor: 0x000000, \n\t\t\t\t\t\t\tside: THREE.FrontSide } );\n\t\tvar base = new THREE.Mesh( geo, mat );\n\t\tbase.position.y -= 0.26;\n\t\n\t\treturn base;\n\t}", "function init(){\n \n //camera\n camera = new THREE.PerspectiveCamera(45, window.innerWidth / window.innerHeight, 1, 1000);\n camera.position.z = 5; \n //scene\n scene = new THREE.Scene();\n \n //renderer\n renderer = new THREE.WebGLRenderer();\n //set the size of the renderer\n renderer.setSize( window.innerWidth, window.innerHeight );\n \n //add the renderer to the html document body\n document.body.appendChild( renderer.domElement );\n}", "function figureMaterial() {\n material = new THREE.MeshNormalMaterial({side: 2, wireframe: false})\n}", "function init() {\n\n // Scene\n scene = new THREE.Scene();\n var WIDTH = window.innerWidth,\n HEIGHT = window.innerHeight;\n\n // Renderer\n renderer = new THREE.WebGLRenderer({antialias:true});\n renderer.setSize(WIDTH, HEIGHT);\n document.body.appendChild(renderer.domElement);\n\n // Camera\n camera = new THREE.PerspectiveCamera(45, WIDTH / HEIGHT, 0.1, 20000);\n camera.position.set(0,0,10);\n scene.add(camera);\n\n // Resize renderer with browser window\n window.addEventListener('resize', function() {\n var WIDTH = window.innerWidth,\n HEIGHT = window.innerHeight;\n renderer.setSize(WIDTH, HEIGHT);\n camera.aspect = WIDTH / HEIGHT;\n camera.updateProjectionMatrix();\n });\n\n // Background and light\n renderer.setClearColorHex(0x333F47, 1);\n var frontLight = new THREE.DirectionalLight('white', 0.75);\n frontLight.position.set(0.5, 0.5, 2);\n scene.add( frontLight );\n\n // OrbitControls\n controls = new THREE.OrbitControls(camera, renderer.domElement);\n\n\n // Robot Dude\n var headMaterial = new THREE.MeshPhongMaterial();\n var faceMaterial = new THREE.MeshPhongMaterial( { color: 0x000000 } );\n\n var head = new THREE.Mesh(\n new THREE.CylinderGeometry( 0.5, 0.1, 1, 50), headMaterial);\n scene.add( head );\n\n var nose = new THREE.Mesh(\n new THREE.CylinderGeometry( 0.05, 0.05, 0.05, 6), faceMaterial);\n nose.rotation.x = 90;\n nose.position.z = 0.4;\n nose.position.y = 0.125;\n scene.add( nose );\n\n var leftEye = new THREE.Mesh(\n new THREE.CylinderGeometry( 0.07, 0.07, 0.05, 6), faceMaterial);\n leftEye.rotation.x = 90;\n leftEye.position.z = 0.4;\n leftEye.position.y = 0.3;\n leftEye.position.x = 0.125;\n scene.add( leftEye );\n\n var rightEye = new THREE.Mesh(\n new THREE.CylinderGeometry( 0.07, 0.07, 0.05, 6), faceMaterial);\n rightEye.rotation.x = 90;\n rightEye.position.z = 0.4;\n rightEye.position.y = 0.3;\n rightEye.position.x = -0.125;\n scene.add( rightEye );\n\n var body = new THREE.Mesh(\n new THREE.CylinderGeometry( 0.5, 0.2, 2, 50), headMaterial);\n body.scale.x = 2;\n body.scale.z = 1.2;\n body.position.y = -1.2;\n scene.add(body);\n\n var firstBall = new THREE.Mesh(\n new THREE.SphereGeometry(0.15), headMaterial);\n firstBall.scale.x = 2;\n firstBall.scale.y = 1.5;\n firstBall.position.y = -2.2;\n scene.add(firstBall); \n}", "function buildRightBorder(geometry,currentIndex){\n\tif (facingCamera){/*Serve para construir face que pode ser vista de fora*/\n\t\tgeometry.vertices.push(new THREE.Vector3(0,0.25,0));//PONTO A\n\t\tgeometry.vertices.push(new THREE.Vector3(0.25,-0.25,0));// PONTO B\n\t\tgeometry.vertices.push(new THREE.Vector3(0,0.25,-0.10));// PONTO C\n\n\t\tvar color = new THREE.Color( 0x0000000 );\n\t\tvar face = new THREE.Face3(currentIndex,currentIndex+1,currentIndex+2,color);//Constroi um triangulo\n\t\tcurrentIndex += 3; // com os ultimos 3 vertices pushed\n\t\tgeometry.faces.push(face);\n\n\t\tgeometry.vertices.push(new THREE.Vector3(0.25,-0.25,0));\n\t\tgeometry.vertices.push(new THREE.Vector3(0.25,-0.25,-0.10));\n\t\tgeometry.vertices.push(new THREE.Vector3(0,0.25,-0.10));\n\n\t\tface = new THREE.Face3(currentIndex,currentIndex+1,currentIndex+2,color);//Constroi um triangulo\n\t\tcurrentIndex += 3; // com os ultimos 3 vertices pushed\n\t\tgeometry.faces.push(face);\n\n\t}\n\n\telse{/*Serve para construir face que pode ser vista de dentro*/\n\t\tgeometry.vertices.push(new THREE.Vector3(0,0.25,0));\n\t\tgeometry.vertices.push(new THREE.Vector3(0,0.25,-0.10)); //A DIFERENCA ESTA NA ORDEM\n\t\tgeometry.vertices.push(new THREE.Vector3(0.25,-0.25,0)); // DESTAS DUAS LINHAS QUE ESTAO TROCADAS\n\n\t\tvar color = new THREE.Color( 0x000000 );\n\t\tvar face = new THREE.Face3(currentIndex,currentIndex+1,currentIndex+2,color);\n\t\tcurrentIndex += 3;\n\t\tgeometry.faces.push(face);\n\n\t\tgeometry.vertices.push(new THREE.Vector3(0.25,-0.25,0));\n\t\tgeometry.vertices.push(new THREE.Vector3(0,0.25,-0.10));\n\t\tgeometry.vertices.push(new THREE.Vector3(0.25,-0.25,-0.10));\n\n\t\tface = new THREE.Face3(currentIndex,currentIndex+1,currentIndex+2,color);\n\t\tcurrentIndex += 3;\n\t\tgeometry.faces.push(face);\n\n\t}\n}", "constructor() {\n // create geometry\n const geometry = new T.BoxGeometry()\n\n // build mesh\n const mesh = new T.Mesh(geometry, material().ref)\n\n // add mesh shadows\n mesh.castShadow = false\n mesh.receiveShadow = true\n\n // store mesh\n this.mesh = mesh\n }", "function spawnArrow(direciton)\n\t\t\t{\n\t\t\t\tvar options = {\n\t\t\t\t\t\"width\": this.itemWidth,\n\t\t\t\t\t\"height\": this.itemHeight,\n\t\t\t\t\t\"text\": \"ShootingGallery\",\n\t\t\t\t\t\"fontSize\": 5,\n\t\t\t\t\t\"color\": \"rgba(255,255,255,1.0)\",\n\t\t\t\t\t\"background\": \"rgba(0,0,0,1.0)\",\n\t\t\t\t\t\"backgroundImageElem\": this.arrowImageElem\n\t\t\t\t};\n\n\t\t\t\tvar scale = 2.0;\n\n\t\t\t\tvar scoreCanvas = document.createElement('canvas');\n\t\t\t\tscoreCanvas.width = options.width * scale;\n\t\t\t\tscoreCanvas.height = options.height * scale;\n\n\t\t\t\tvar scoreContext = scoreCanvas.getContext('2d');\n\t\t\t\tscoreContext.drawImage(options.backgroundImageElem, 0, 0, scoreCanvas.width, scoreCanvas.height);\n\t\t\t\t/*\n\t\t\t\tscoreContext.textAlign = \"center\";\n\t\t\t\tscoreContext.textBaseline = \"middle\";\n\t\t\t\tscoreContext.font = \"Bold \" + options.fontSize * scale + \"px Arial\";\n\t\t\t\tscoreContext.fillStyle = options.color;\n\t\t\t \tscoreContext.fillText(options.text, scoreCanvas.width / 2.0, scoreCanvas.height / 2.0);\n\t\t\t \t*/\n\n\t\t\t\tvar scoreTexture = new THREE.Texture(scoreCanvas); \n\t\t\t\tscoreTexture.needsUpdate = true;\n\n\t\t\t\tvar material = new THREE.MeshBasicMaterial({map: scoreTexture, visible: true});\n\n\t\t\t\t//var geometry = //new THREE.BoxGeometry(options.width, options.height, 0);\n\t\t\t\tvar geometry = new THREE.Geometry();\n\t\t\t\t/*\n\t\t\t\tgeometry.vertices.push(new THREE.Vector3(0, 2, 0).multiplyScalar(scale));\n \t\t\tgeometry.vertices.push(new THREE.Vector3(-2, 0, 0).multiplyScalar(scale));\n \t\t\t\tgeometry.vertices.push(new THREE.Vector3(2, 0, 0).multiplyScalar(scale));\n \t\t\t\t*/\n \t\t\t\tgeometry.vertices.push(new THREE.Vector3(0, options.height, 0));\n \t\t\tgeometry.vertices.push(new THREE.Vector3(-options.width / 2.0, -options.height * 1.5, 0));\n \t\t\t\tgeometry.vertices.push(new THREE.Vector3(options.width / 2.0, -options.height * 1.5, 0));\n\t\t\t\tgeometry.faces.push(new THREE.Face3(0, 1, 2));\n\t\t\t\tgeometry.computeFaceNormals();\n\n\t\t\t\tgeometry.faceVertexUvs[ 0 ].push([\n\t\t\t\t\tnew THREE.Vector2(0.5, 1),\n\t\t\t\t\tnew THREE.Vector2(0, 0),\n\t\t\t\t\tnew THREE.Vector2(1, 0)\n\t\t\t\t]);\n\n\t\t\t\tgeometry.uvsNeedUpdate = true;\n\n\t\t\t\tvar plane = new THREE.Mesh(geometry, material);\n\t\t\t\tplane.scale.y *= 0.3;\n\n\t\t\t\tif( direciton === \"down\" )\n\t\t\t\t\tplane.rotateZ(Math.PI);\n\n\t\t\t\tthis.container.add(plane);\n\n\t\t\t\treturn plane;\n\t\t\t}", "function rotateX() {\n console.log('rotate about x triggered');\n var cosA = Math.cos(0.05);\n var sinA = Math.sin(0.05);\n var m = new THREE.Matrix4();\n m.set( 1, 0, 0, 0,\n 0, cosA, sinA, 0,\n 0, -sinA, cosA, 0,\n 0, 0, 0, 1 );\n geometry.applyMatrix(m);\n // render\n render();\n}", "function init(){\n \n renderer = new THREE.WebGLRenderer({antialias: true});\n renderer.setClearColor(0xffffff, 1);\n renderer.setPixelRatio(window.devicePixelRatio);\n\n canvasWidth = window.innerWidth;\n canvasHeight = window.innerHeight;\n\n renderer.setSize(canvasWidth, canvasHeight);\n document.getElementById(\"WebGLCanvas\").appendChild(renderer.domElement);\n window.addEventListener('resize', onWindowResize, false);\n\n scene = new THREE.Scene();\n\n viewLength = 500;\n aspRat = canvasWidth/canvasHeight;\n\n document.addEventListener(\"keydown\", onKeyDown, false);\n document.addEventListener(\"keyup\", onKeyUp, false);\n\n raycaster = new THREE.Raycaster(new THREE.Vector3(), new THREE.Vector3(0, -1, 0), 0, 10);\n\n camera = setPerspective();\n\n controls = new THREE.PointerLockControls(camera);\n if(controls == null){\n console.log(\"oops\");\n }\n scene.add(controls.getObject());\n draw();\n}//end init()", "_addWall(_position={x: 0, y: 0, z: 0}, _size={w:1,h:1, d:1}, _groupMesh, _rotationY=0, _scale={x: 1, y: 1, z: 1}) {\r\n let tWall = new THREE.TextureLoader().load('./assets/textur es/OpenGameArt/Planks/test_128x128_6.png')\r\n tWall.wrapS = THREE.RepeatWrapping;\r\n tWall.wrapT = THREE.RepeatWrapping;\r\n tWall.repeat.y = 2\r\n tWall.repeat.x = 20\r\n let wallMaterial = new THREE.MeshPhongMaterial( {side: THREE.DoubleSide, map: tWall} );\r\n let wallGeometry = new THREE.BoxBufferGeometry( _size.w, _size.h, _size.d, 1, 1);\r\n\r\n let tempMesh = new THREE.Mesh(wallGeometry, wallMaterial)\r\n tempMesh.position.set(_position.x, _position.y, _position.z)\r\n tempMesh.rotation.y = _rotationY\r\n\r\n tempMesh.scale.set(_scale.x,_scale.y,_scale.z);\r\n tempMesh.receiveShadow = true;\r\n tempMesh.castShadow = true;\r\n _groupMesh.add(tempMesh);\r\n\r\n let ammoWallShape = new Ammo.btBoxShape(new Ammo.btVector3(_size.w/2, _size.h/2, _size.d/2));\r\n let shapeWallTrans = new Ammo.btTransform();\r\n shapeWallTrans.setIdentity();\r\n shapeWallTrans.setOrigin(new Ammo.btVector3(tempMesh.position.x,tempMesh.position.y,tempMesh.position.z));\r\n let shapeWallQuat = tempMesh.quaternion;\r\n shapeWallTrans.setRotation( new Ammo.btQuaternion(shapeWallQuat.x, shapeWallQuat.y, shapeWallQuat.z, shapeWallQuat.w) );\r\n this.compoundShape.addChildShape(shapeWallTrans, ammoWallShape);\r\n }", "function addTPlane(x,y,z,w,h,texture){ //transparent allowant plane\n\tvar _g = new THREE.PlaneGeometry(w,h);\n\t _g.applyMatrix(new THREE.Matrix4().makeRotationX(-Math.PI/2));\n\tvar _m = new THREE.MeshLambertMaterial({map:texture});\n\t _m.transparent=true;\n\tvar _p = new THREE.Mesh(_g,_m);\n\t _p.position.set(x,y,z);\n\tscene.add(_p);\n} //end function", "function createArrowButton(x, name, direction) {\n let scaling = 0.5;\n let normal = new createjs.Bitmap(queue.getResult(\"orangeBtn\")).set({\n scaleX: scaling, scaleY: scaling\n });\n let imgHeight = normal.image.height * scaling;\n let hover = new createjs.Bitmap(queue.getResult(\"yellowBtn\")).set({\n scaleX: scaling, scaleY: scaling\n });\n if (\"right\" === direction) {\n normal.rotation = 180;\n normal.y += imgHeight;\n hover.rotation = 180;\n hover.y += imgHeight;\n }\n let button = new createjs.Container().set({\n x: x,\n y: CANVAS_HEIGHT - imgHeight - 10,\n name: name\n });\n button.addChild(normal);\n button.cursor = 'pointer';\n button.mouseChildren = false;\n button.mouseEnabled = true;\n\n button.on('mouseover', e => {\n button.removeAllChildren();\n button.addChild(hover);\n });\n button.on('mouseout', e => {\n button.removeAllChildren();\n button.addChild(normal);\n });\n button.disable = () => {\n button.alpha = 0.5;\n button.mouseEnabled = false;\n };\n button.enable = () => {\n button.alpha = 1.0;\n button.mouseEnabled = true;\n }\n return button;\n}", "function _drawArrow(pStart, pEnd, arrowSize, color) {\n var p = new Primitive();\n p.color = toColor(color);\n\n p.vertices.push(pStart);\n p.vertices.push(pEnd);\n\n var dir = new THREE.Vector3();\n dir.subVectors(pEnd, pStart);\n dir.normalize();\n\n var right = new THREE.Vector3();\n var dot = dir.dot(UNIT_Y);\n if (dot > 0.99 || dot < -0.99) {\n right.crossVectors(dir, UNIT_X);\n } else {\n right.crossVectors(dir, UNIT_Y);\n }\n\n var top = new THREE.Vector3();\n top.crossVectors(right, dir);\n\n dir.multiplyScalar(arrowSize);\n right.multiplyScalar(arrowSize);\n top.multiplyScalar(arrowSize);\n\n // Right slant.\n var tmp = new THREE.Vector3();\n p.vertices.push(pEnd);\n p.vertices.push(tmp.addVectors(pEnd, right).sub(dir));\n\n // Left slant.\n tmp = new THREE.Vector3();\n p.vertices.push(pEnd);\n p.vertices.push(tmp.subVectors(pEnd, right).sub(dir));\n\n // Top slant.\n tmp = new THREE.Vector3();\n p.vertices.push(pEnd);\n p.vertices.push(tmp.addVectors(pEnd, top).sub(dir));\n\n // Bottom slant.\n tmp = new THREE.Vector3();\n p.vertices.push(pEnd);\n p.vertices.push(tmp.subVectors(pEnd, top).sub(dir));\n\n renderer.addPrimitive(p);\n }", "function setup(){\n entorno = new Environment();\n camara = new THREE.PerspectiveCamera();\n camara.position.z = 30;\n \n entorno.add( new Pared(1,7,0) );\n entorno.add( new Pared(1,-7,0) );\n entorno.add( new Pared(1,7,1) );\n entorno.add( new Pared(1,-7,1) );\n entorno.add( new Pared(1,7,-1) );\n entorno.add( new Pared(1,-7,-1));\n entorno.add( new Pelota(0.5) );\n entorno.add(camara);\n \n \n renderer = new THREE.WebGLRenderer();\n renderer.setSize(window.innerHeight*.95, window.innerHeight*.95);\n document.body.appendChild ( renderer.domElement );\n }", "function makeBG() {\n var mesh = new THREE.Mesh(new THREE.PlaneGeometry(100,50), new THREE.MeshStandardMaterial({color:0x111111}));\n scene.add(mesh);\n mesh.position.z = -12;\n mesh.position.y = 0;\n return mesh;\n}", "function drawArrow(v,loc){\n push();\n stroke(0);\n var normalizeV = [0.0, 0.0];\n var vMag = Math.sqrt(v[0]*v[0]+v[1]*v[1]);\n if (vMag>0){\n normalizeV[0] = 5 * v[0]/vMag;\n normalizeV[1] = 5 * v[1]/vMag;\n }\n line(loc[0]-normalizeV[0],loc[1]-normalizeV[1],loc[0]+normalizeV[0],loc[1]+normalizeV[1]);\n fill(0);\n triangle(loc[0]+normalizeV[0],loc[1]+normalizeV[1],loc[0]+0.8*normalizeV[0]-0.2*normalizeV[1],loc[1]+0.8*normalizeV[1]+0.2*normalizeV[0],loc[0]+0.8*normalizeV[0]+0.2*normalizeV[1],loc[1]+0.8*normalizeV[1]-0.2*normalizeV[0]);\n \n pop();\n}", "draw() {\n while (scene.children.length > 0) {\n scene.remove(scene.children[0]);\n }\n var from = new THREE.Vector3(0, (this.height / -2), (this.length / 2));\n var to = new THREE.Vector3(0, (this.height / -2), (this.length / 2) + 1000);\n var direction = to.clone().sub(from);\n var length = direction.length();\n var arrowHelper = new THREE.ArrowHelper(direction.normalize(), from, length, \"red\");\n scene.add(arrowHelper);\n var gridHelper = new THREE.GridHelper(1.5 * this.length, 15);\n gridHelper.position.set(0, (this.height / -2), 0);\n scene.add(gridHelper);\n runtimeManager.currentGridUUID = gridHelper.uuid;\n super.draw(null, { type: \"bordered\" });\n for (var index in this.goods) {\n var g = this.goods[index];\n g.draw({ h: this.height, w: this.width, l: this.length }, { type: \"filled\" });\n }\n }", "function arrowHelper() {\n $('<a>&larr; portfolio</a>').appendTo('#pa');\n $('<a>&larr; about me</a>').appendTo('#aa');\n $('#footer').fadeIn('slow');\n }", "function FieldPath (name, yPoints, zPoints) {\n this.name = name;\n this.xPoints = []; // anterior-posterior\n this.yPoints = yPoints; // superior-inferior\n this.zPoints = zPoints; //lateral-medial\n\n this.side = \"right\";\n // Need to assert yPoints.length = zPoints.length\n this.numPoints = yPoints.length\n this.switchSide = switchSide;\n this.renderPath = renderPath;\n this.material = new THREE.LineBasicMaterial({\n linewidth: 3,\n linecap: \"round\",\n linejoin: \"round\",\n });\n this.changeToDash = changeToDash;\n\n // Initialise xPoints with integers from 0 to numLength\n for (var i=0; i<this.numPoints; i++) {\n this.xPoints.push(2*i);\n }\n\n function switchSide() {\n this.zPoints = this.zPoints.map(n => n * (-1));\n switch(this.side) {\n case \"right\":\n this.side = \"left\";\n break;\n case \"left\":\n this.side = \"right\";\n break;\n }\n }\n\n function renderPath(parent, color, zOffset) {\n // zOffset to show all lines without superimposition\n this.material.color.set(color)\n var zPointsOffset = this.zPoints.map(n => n + zOffset);\n var geometry = new THREE.Geometry();\n for (var i=0; i<this.numPoints; i++) {\n var xc = this.xPoints[i];\n var yc = this.yPoints[i];\n var zc = zPointsOffset[i];\n geometry.vertices.push(new THREE.Vector3(xc, yc, zc));\n }\n geometry.computeLineDistances();\n var line = new THREE.Line(geometry, this.material);\n parent.add(line);\n }\n\n function changeToDash() {\n this.material = new THREE.LineDashedMaterial({\n linewidth: 2,\n linecap: \"round\",\n linejoin: \"round\",\n dashSize: 0.2,\n gapSize: 0.05,\n })\n }\n\n}", "function drawBox(){\n\tvar geometry = new THREE.BoxBufferGeometry( params.size, params.size, params.size);\n\n\tvar edges = new THREE.EdgesGeometry( geometry );\n\tvar material = new THREE.LineBasicMaterial( {color: 0x000000} )\n\tvar line = new THREE.LineSegments( edges, material);\n\tline.position.set(params.size/2, params.size/2., params.size/2.);\n\tparams.scene.add( line );\n\n\t//The X axis is red. The Y axis is green. The Z axis is blue.\n\tvar cubeAxis = new THREE.AxesHelper(1.5*params.size);\n\tcubeAxis.position.set(0,0,0);\n\tparams.scene.add( cubeAxis );\n}", "function drawAxes(scene) {\n // x-axis\n const xGeo = new THREE.Geometry();\n xGeo.vertices.push(new THREE.Vector3(0, 0, 0));\n xGeo.vertices.push(new THREE.Vector3(3, 0, 0));\n const xMat = new THREE.LineBasicMaterial({\n color: 0xff0000\n });\n const xAxis = new THREE.Line(xGeo, xMat);\n scene.add(xAxis);\n\n // y-axis\n const yGeo = new THREE.Geometry();\n yGeo.vertices.push(new THREE.Vector3(0, 0, 0));\n yGeo.vertices.push(new THREE.Vector3(0, 3, 0));\n const yMat = new THREE.LineBasicMaterial({\n color: 0x00ff00\n });\n const yAxis = new THREE.Line(yGeo, yMat);\n scene.add(yAxis);\n\n // z-axis\n const zGeo = new THREE.Geometry();\n zGeo.vertices.push(new THREE.Vector3(0, 0, 0));\n zGeo.vertices.push(new THREE.Vector3(0, 0, 3));\n const zMat = new THREE.LineBasicMaterial({\n color: 0x00ccff\n });\n const zAxis = new THREE.Line(zGeo, zMat);\n scene.add(zAxis);\n}", "init() {\n this.center = new THREE.Vector3();\n\n // Create our new Box3\n const box = new THREE.Box3();\n this.box = box;\n\n // Create a helper to help visualize the box.\n const helper = this.helper = new THREE.Box3Helper(box, 0xFF851B);\n this.el.sceneEl.object3D.add(helper);\n }", "function initPlane(){\n // Creating the plane\n const ter_mat_props = { \n map : texture\n }\n\n // Setting the plane to update vertices\n plane_geo.verticesNeedUpdate = true;\n\n // Creating the plane with the given texture\n const ter_mat = new THREE.MeshBasicMaterial(ter_mat_props); \n plane = new THREE.Mesh(plane_geo, ter_mat);\n \n // Rotating the plane to face us\n plane.rotation.x -= Math.PI / 2;\n\n scene.add(plane);\n}", "__init() {this.potentialArrowAt = -1}", "function addLampBase(obj, x, y, z){\n 'use strict';\n\n geometry = new THREE.ConeGeometry(3.5, 2, 32);\n material = new THREE.MeshBasicMaterial({color: 0x42e2f4, wireframe: true});\n mesh = new THREE.Mesh(geometry, material);\n mesh.position.set(x, y, z);\n obj.add(mesh);\n}", "function rotateLocal(obj3D,axis,degree){\n\n var rotateMatrix = new THREE.Matrix4();\n\n rotateMatrix.makeRotationAxis(axis.normalize(),degree*Math.PI/180);\n\n obj3D.matrix.multiply(rotateMatrix);\n\n obj3D.rotation.setFromRotationMatrix(obj3D.matrix);\n\n\n}", "function init() {\n scene = new THREE.Scene();\n\n camera = new THREE.PerspectiveCamera(\n 75, // FOV IN DEGREES\n window.innerWidth / window.innerHeight, // ASPECT OF VIEW\n 0.1, // NEAR PLANE\n 1000); // FAR PLANE\n\n renderer = new THREE.WebGLRenderer({antialias: true});\n\n renderer.setSize(window.innerWidth, window.innerHeight);\n\n document.body.appendChild(renderer.domElement);\n\n camera.position.z = 5; \n}", "function createPipe(startVector, endVector, label) {\n var lineGeo = new THREE.Geometry();\n lineGeo.vertices.push(startVector);\n lineGeo.vertices.push(endVector);\n var lineMaterial = new THREE.LineBasicMaterial({\n\t\t\tcolor: 0xff0000,\n\t\t\tlinewidth: 10 \n\t\t });\n var lineMesh = new THREE.Line(lineGeo, lineMaterial); \n\t\n var labelMesh = new THREE.Mesh(new THREE.TextGeometry(label,\n\t\t\t\t\t\t\t{size: 12,\n\t\t\t\t\t\t\t height: 4,\n\t\t\t\t\t\t\t curveSegments: 0\n\t\t\t\t\t\t\t}), new THREE.LineBasicMaterial({\n\t\t\t\t \t\t\tcolor: 0xff0000,\n\t\t\t\t \t\t\tlinewidth: 20 \n\t\t\t\t \t\t }));\n//new THREE.MeshNormalMaterial());\n labelMesh.lookAt(camera.position);\n labelMesh.position.x = Math.abs(endVector.x + startVector.x) / 2;\n labelMesh.position.y = Math.abs(endVector.y + startVector.y) / 2 + 25;\n labelMesh.position.z = Math.abs(endVector.z + startVector.z) / 2;\n if(labelMesh.position.x == 0) {\n\tlabelMesh.position.x = endVector.x;\n }\n if(labelMesh.position.y == 25) {\n\tlabelMesh.position.y = endVector.y + 25;\n }\n if(labelMesh.position.z == 0) {\n\tlabelMesh.position.z = endVector.z;\n }\n return [lineMesh, labelMesh];\n}", "createCube(color, side, position) {\n\n let geometry = new THREE.CubeGeometry( 200, 600, 50 )\n let material = new THREE.MeshStandardMaterial({ color: color })\n let mesh = new THREE.Mesh( geometry, material )\n\n mesh.position.x = side === 'right' ? 300 : -300\n mesh.position.z = position\n mesh.position.y = -200\n\n mesh.shading = THREE.FlatShading\n mesh.castShadow = true\n mesh.receiveShadow = true\n \n this.scene.add( mesh )\n this.buildings.push( mesh )\n }", "constructor(scene, x, y) {\n super(scene, x, y);\n this.scene = scene;\n this.sprite = this.scene.add.sprite(x+30, y, 'arrow');\n this.sprite.name = 'arrow';\n this.sprite.setOrigin(.5, -.5);\n this.scene.add.existing(this);\n\n }", "function arrowRot (x1, y1, z1, x2, y2, z2) {\n var xx1 = x1*cosAlpha-z1*sinAlpha; // x-Koordinate des Anfangspunkts nach der Drehung\n var zz1 = x1*sinAlpha+z1*cosAlpha; // z-Koordinate des Anfangspunkts nach der Drehung\n var xx2 = x2*cosAlpha-z2*sinAlpha; // x-Koordinate des Endpunkts nach der Drehung\n var zz2 = x2*sinAlpha+z2*cosAlpha; // z-Koordinate des Endpunkts nach der Drehung\n var u1 = screenU(xx1,y1), v1 = screenV(xx1,y1,zz1); // Bildschirmkoordinaten des Anfangspunkts\n var u2 = screenU(xx2,y2), v2 = screenV(xx2,y2,zz2); // Bildschirmkoordinaten des Endpunkts\n arrow(u1,v1,u2,v2,THICK); // Pfeil zeichnen\n }", "function Arrow(x,y,cnv) {\n\tActor.call(this,x,y,\"arrow.png\",cnv,0,110,200);\n\tthis.debugColor = \"#DD4400\";\n\tthis.state = \"follow path\";\n\tthis.path = new Path([[10,10],[300,50],[-100,500], [300,250],[-225,240],[-450,280]],true);\n\tthis.nextPoint = null;\n\tthis.slowRadius = 115;\n}", "function createAxis(p1, p2, color){\n var line, lineGeometry = new THREE.Geometry(),\n lineMat = new THREE.LineBasicMaterial({color: color, lineWidth: 1});\n lineGeometry.vertices.push(p1, p2);\n line = new THREE.Line(lineGeometry, lineMat);\n\n scene.add(line);\n }", "function initializeThreeJsEnvironment() {\n camera = new THREE.PerspectiveCamera(70, window.innerWidth / window.innerHeight, 0.01, 10);\n //camera = new THREE.PerspectiveCamera(70, viewportAspect, 0.01, 10);\n camera.position.z = 1.4;\n\n scene = new THREE.Scene();\n\n renderer = new THREE.WebGLRenderer({ antialias: true });\n renderer.setSize(window.innerWidth, window.innerHeight);\n\n let c = document.getElementById('canvas3d');\n c.appendChild(renderer.domElement);\n\n controls = new THREE.TrackballControls(camera);\n controls.addEventListener('change', render);\n}", "function OnDrawGizmos(){\n \nGizmos.color = Color.red;\nfor(var i : int = 0; i< waypoints.Length;i++)\n{\nvar pos : Vector3 = waypoints[i].position;\nif(i>0)\n{\nvar prev : Vector3 = waypoints[i-1].position;\n \n}\n}\n}", "function render() {\n requestAnimationFrame(render);\n\n // Rotate our shape\n cube.rotation.x += 0.02;\n cube.rotation.y += 0.02;\n line.rotation.x += 0.02;\n line.rotation.y += 0.02;\n //camera.rotation.z += .1;\n //torus.rotation.x += 0.01;\n \n\n renderer.render(scene, camera);\n}", "function createSideBoard(x,y,z,rx,ry,rz) {\n\tmaterialBoard = new THREE.MeshPhongMaterial( { color: BOARD_COLOR } );\n\tgeometryBoard = new THREE.ExtrudeGeometry( createShape(), extrudeSettings );\n\tsideMesh = new THREE.Mesh( geometryBoard, materialBoard );\t\n\n\tsideMesh.position.set( x, y, z );\n\tsideMesh.rotation.set( rx, ry, rz );\n\treturn sideMesh;\n}", "init3dScene () {\n // Scene\n this.scene = new THREE.Scene()\n\n // Renderer\n this.renderer = new THREE.WebGLRenderer({\n antialias: true\n })\n this.renderer.setClearColor(0xCCCCCC, 1)\n this.renderer.setSize(this.width, this.height)\n document.body.appendChild(this.renderer.domElement)\n\n // Camera\n this.camera = new THREE.PerspectiveCamera(60, this.width / this.height, 0.01, 10000)\n this.camera.position.z = 50\n this.camera.position.y = 20\n\n // Camera controls\n this.controls = new OrbitControls(this.camera, document.body)\n\n // Boundaries\n const boxSize = 30\n const box = new THREE.Mesh(\n new THREE.BoxGeometry(boxSize, boxSize, boxSize),\n new THREE.MeshBasicMaterial({wireframe: true, color: '#FFFFFF', transparent: true, opacity: 0.5})\n )\n this.scene.add(box)\n\n // Create vehicle\n this.vehicle = new Vehicle(this.scene, new THREE.Vector2(), 0.3, 0.005, boxSize)\n\n // 3d grid\n this.grid = new THREE.Mesh(\n new THREE.PlaneBufferGeometry(40, 40, 10, 10),\n new THREE.MeshBasicMaterial({wireframe: true, color: '#69aedb', transparent: false, opacity: 0.2})\n )\n this.grid.rotation.x = 90 * Math.PI / 180\n this.scene.add(this.grid)\n }", "function init() {\n\n // Three setup\n scene = new THREE.Scene();\n scene.background = new THREE.Color( 0xcccccc );\n\n renderer = new THREE.WebGLRenderer( { antialias: true } );\n renderer.setPixelRatio( window.devicePixelRatio );\n renderer.setSize( window.innerWidth, window.innerHeight );\n document.body.appendChild( renderer.domElement );\n\n camera = new THREE.PerspectiveCamera( 60, window.innerWidth / window.innerHeight, 1, 4000 );\n camera.position.set(0,12,10);\n camera.lookAt(0,10,0);\n\n // controls\n controls = new OrbitControls( camera, renderer.domElement );\n \n //controls.addEventListener( 'change', render ); // call this only in static scenes (i.e., if there is no animation loop)\n controls.enableDamping = true; // an animation loop is required when either damping or auto-rotation are enabled\n controls.dampingFactor = 0.05;\n controls.screenSpacePanning = false;\n controls.minDistance = 10;\n controls.maxDistance = 1000;\n controls.maxPolarAngle = Math.PI / 2;\n \n // Load Model(s)\n var elf;\n var loadingManager = new THREE.LoadingManager( function () {\n scene.add( elf ); \n } );\n var loader = new ColladaLoader( loadingManager );\n loader.load( './model/elf.dae', function ( collada ) {\n elf = collada.scene;\n } );\n\n // lights\n var light = new THREE.AmbientLight( 0x404040 );\n scene.add( light );\n var light = new THREE.HemisphereLight( 0xffffbb, 0x080820, 1 );\n scene.add( light );\n\n //\n window.addEventListener( 'resize', onWindowResize, false );\n\n}", "function onKeyDown(e){\n 'use strict';\n\n switch (e.keyCode){\n case 37: //left\n Rot = - 1;\n //angle = -Math.PI/30; //sentido contrario ao dos ponteiros\n break;\n case 38: //up\n acc = -1;\n break;\n case 39: //right\n Rot = 1;\n //angle = Math.PT/30; //sentido dos ponteiros\n break;\n case 40: //down\n acc = 1;\n break;\n case 49: //1\n createCamera(50, 50, 50);\n break;\n case 50: //2\n createCamera(0, 100 ,0);\n break;\n case 51: //3\n createCamera(0, 50, 50);\n break;\n case 65: //A\n case 97: //a\n scene.traverse(function (node) {\n if (node instanceof THREE.Mesh) {\n node.material.wireframe = !node.material.wireframe;\n }\n });\n break;\n case 83: //S\n case 115: //s\n case 69: //E\n case 101: //e\n scene.traverse(function (node) {\n if (node instanceof THREE.AxisHelper) {\n node.visible = !node.visible;\n }\n });\n break;\n }\n}", "function init() {\n scene = new THREE.Scene();\n camera = new THREE.PerspectiveCamera(60, window.innerWidth / window.innerHeight, 0.001, 1e6);\n\n renderer = new THREE.WebGLRenderer({\n antialias: true\n });\n renderer.setPixelRatio(window.devicePixelRatio);\n renderer.setSize(window.innerWidth, window.innerHeight);\n renderer.setClearColor(0xffffff, 1.0);\n\n document.body.appendChild(renderer.domElement);\n\n\n var ambientLight = new THREE.AmbientLight(0xeeeeee);\n scene.add(ambientLight);\n\n var lights = [];\n lights[0] = new THREE.PointLight(0xffffff, 0.5, 0);\n lights[1] = new THREE.PointLight(0xffffff, 0.5, 0);\n lights[2] = new THREE.PointLight(0xffffff, 0.5, 0);\n\n lights[0].position.set(100, 100, 100);\n lights[1].position.set(-100, 100, 100);\n lights[2].position.set(0, 100, -100);\n\n scene.add(lights[0]);\n scene.add(lights[1]);\n scene.add(lights[2]);\n}", "initCamera() {\n this.camera = new THREE.PerspectiveCamera(45, window.innerWidth / window.innerHeight, 10, 1000);\n this.camera.position.y = 400;\n this.camera.position.z = 400;\n this.camera.rotation.x = .70;\n }", "function buildGround(){\n \n var geom = new THREE.PlaneGeometry(600,600); \n\t plane = new THREE.Mesh( geom, matGroundGreen);\n\t plane.rotation.x = Math.PI/2;\n\t scene.add( plane );\n \n}", "function init() {\n\n // Rhino models are z-up, so set this as the default\n THREE.Object3D.DefaultUp = new THREE.Vector3( 0, 0, 1 );\n\n // create a scene and a camera\n scene = new THREE.Scene()\n scene.background = new THREE.Color(1, 1, 1)\n camera = new THREE.PerspectiveCamera(45, window.innerWidth / window.innerHeight, 1, 1000)\n camera.position.set(1, -1, 1) // like perspective view\n\n // very light grey for background, like rhino\n scene.background = new THREE.Color('whitesmoke')\n\n // create the renderer and add it to the html\n renderer = new THREE.WebGLRenderer({ antialias: true })\n renderer.setPixelRatio( window.devicePixelRatio )\n renderer.setSize(window.innerWidth, window.innerHeight)\n document.body.appendChild(renderer.domElement)\n\n // add some controls to orbit the camera\n controls = new OrbitControls(camera, renderer.domElement)\n\n // add a directional light\n const directionalLight = new THREE.DirectionalLight( 0xffffff )\n directionalLight.intensity = 2\n scene.add( directionalLight )\n\n const ambientLight = new THREE.AmbientLight()\n scene.add( ambientLight )\n\n // handle changes in the window size\n window.addEventListener( 'resize', onWindowResize, false )\n\n animate()\n}", "function addStaticMeshToTower(newMesh){\n\tnewMesh.position.x=TOWER_X;\n\tnewMesh.position.y=currentTowerHeight; // Pivot in centre of object\n\tnewMesh.position.z=TOWER_Z;\n\t\n\tmainScene.add(newMesh);\n}", "function draw_arrow(x1, y1, x2, y2)\n{\n\tctx.fillStyle = ctx.strokeStyle = 'yellow';\n\tctx.beginPath(); ctx.moveTo(x1, y1);\n\tctx.lineTo(x2, y2); // Main line\n\tvar arrowtip = Vector.create(x2, y2);\n\tvar direction = Vector.mult(Vector.normalise(Vector.create(x2-x1, y2-y1)), 15);\n\tvar rightedge = Vector.add(arrowtip, Vector.rotate(direction, 0.8*Math.PI));\n\tvar leftedge = Vector.add(arrowtip, Vector.rotate(direction, -0.8*Math.PI));\n\tctx.lineTo(rightedge.x, rightedge.y);\n\tctx.lineTo(leftedge.x, leftedge.y);\n\tctx.lineTo(x2, y2);\n\tctx.stroke();\n\tctx.fill();\n}", "function initThree() {\n\n // Create the scene and set the scene size.\n scene = new THREE.Scene();\n\n // Create a renderer and add it to the DOM.\n renderer = new THREE.WebGLRenderer({canvas: document.getElementById(\"mainCanvas\"), antialias:true});\n renderer.setSize(WIDTH, HEIGHT);\n renderer.setPixelRatio(window.devicePixelRatio);\n renderer.shadowMap.enabled = true;\n renderer.shadowMap.type = THREE.PCFShadowMap;\n // document.body.appendChild(renderer.domElement);\n // Set the background color of the scene.\n renderer.setClearColor(0x333F47, 1);\n\n // Cameras\n camera = new THREE.PerspectiveCamera(45, WIDTH / HEIGHT, 0.1, 5000);\n camera.position.set( 0, 0, 25);\n // camera.rotation.x = Math.PI /2\n scene.add(camera);\n\n //Helpers\n // var axes = new THREE.AxisHelper(5);\n // var grid = new THREE.GridHelper(50, 1);\n // scene.add(axes);\n // grid.setColors(0x0000ff, 0x808080);\n // grid.rotation.x = Math.PI /2;\n // scene.add(grid);\n\n // Lights\n // var ambientLight = new THREE.AmbientLight(0xffffff, 0.001);\n // scene.add(ambientLight);\n\n var light = new THREE.HemisphereLight( 0xffffbb, 0x080820, 0.4 );\n light.rotation.x = Math.PI /2 ;\n // var hemHelper = new THREE.HemisphereLightHelper(light, 15);\n // scene.add(hemHelper);\n scene.add( light );\n\n\n var diceLight = new THREE.SpotLight( 0xffffff, 0.7);\n diceLight.position.set( 10, -10, 50 );\n // var spotLightHelper = new THREE.SpotLightHelper( spotLight );\n // scene.add( spotLightHelper );\n // spotLight.target = cube;\n diceLight.castShadow = true;\n diceLight.shadow.bias = 0.001;\n diceLight.shadow.mapSize.width = 2048*2;\n diceLight.shadow.mapSize.height = 2048*2;\n diceLight.shadow.camera.near = 5;\n diceLight.shadow.camera.far = 100;\n scene.add( diceLight );\n\n var playerSelectorLight = new THREE.SpotLight( 0xffffff, 0.7);\n playerSelectorLight.position.set( -10, 10, 30 );\n // playerSelectorLight.target\n playerSelectorLight.castShadow = true;\n playerSelectorLight.shadow.bias = 0.001;\n playerSelectorLight.shadow.mapSize.width = 2048*2;\n playerSelectorLight.shadow.mapSize.height = 2048*2;\n playerSelectorLight.shadow.camera.near = 5;\n playerSelectorLight.shadow.camera.far = 100;\n scene.add( playerSelectorLight );\n\n\n //Elements\n var cubeGeometry = new THREE.BoxGeometry(1, 1, 1 );\n // var modifier = new THREE.SubdivisionModifier( 4 ); //attempt to smooth cube\n // modifier.modify( cubeGeometry );\n // var cubeMaterial = new THREE.MeshLambertMaterial( {color: 0x00ff00} );\n var faceMaterial = []; //apply texture to each face\n for (var i=1; i < 7; i++) {\n faceMaterial.push( new THREE.MeshPhongMaterial({\n color: 0xffffff,\n map: new THREE.TextureLoader().load(\"images/dice\"+i+\".PNG\") }) );\n }\n cube = new THREE.Mesh( cubeGeometry, new THREE.MeshFaceMaterial(faceMaterial) );\n cube.castShadow = true;\n scene.add( cube );\n\n cube2 = new THREE.Mesh(cubeGeometry, new THREE.MeshFaceMaterial(faceMaterial));\n cube2.castShadow = true;\n scene.add(cube2);\n\n var planeGeometry = new THREE.PlaneGeometry( 50, 50, 1, 1 );\n var planeMaterial = new THREE.MeshPhongMaterial( { map: new THREE.TextureLoader().load(\"images/woodGrain.jpg\") });\n plane = new THREE.Mesh( planeGeometry, planeMaterial );\n plane.material.side = THREE.DoubleSide;\n plane.receiveShadow = true;\n scene.add( plane );\n\n selectorBackground = new THREE.Mesh( planeGeometry, planeMaterial );\n selectorBackground.recieveShadow = true;\n selectorBackground.rotation.y = Math.PI/2;\n selectorBackground.position.set(25, 0, 25);\n scene.add(selectorBackground);\n\n playerSelectors = new THREE.Group();\n //create city selectors\n var cityGeometry = createCityGeometry(1);\n var spacing = 4;\n whiteCity = new THREE.Mesh(cityGeometry, new THREE.MeshLambertMaterial());\n whiteCity.name = \"White\";\n whiteCity.castShadow = true;\n whiteCity.position.set(-(5/2) * spacing,0,0);\n playerSelectors.add(whiteCity);\n\n redCity = new THREE.Mesh(cityGeometry, new THREE.MeshLambertMaterial({color: 0xff0000}));\n redCity.name = \"Red\";\n redCity.castShadow = true;\n redCity.position.set(-(3/2) * spacing,0,0);\n playerSelectors.add(redCity);\n\n blueCity = new THREE.Mesh(cityGeometry, new THREE.MeshLambertMaterial({color: 0x0000ff}));\n blueCity.name = \"Blue\";\n blueCity.castShadow = true;\n blueCity.position.set(-spacing/2,0,0);\n playerSelectors.add(blueCity);\n\n orangeCity = new THREE.Mesh(cityGeometry, new THREE.MeshLambertMaterial({color: 0xffA500}));\n orangeCity.name = \"Orange\";\n orangeCity.castShadow = true;\n orangeCity.position.set(spacing/2,0,0);\n playerSelectors.add(orangeCity);\n\n greenCity = new THREE.Mesh(cityGeometry, new THREE.MeshLambertMaterial({color: 0x008000}));\n greenCity.name = \"Green\";\n greenCity.castShadow = true;\n greenCity.position.set((3/2) * spacing,0,0);\n playerSelectors.add(greenCity);\n\n brownCity = new THREE.Mesh(cityGeometry, new THREE.MeshLambertMaterial({color: 0x8B4513}));\n brownCity.name = \"Brown\";\n brownCity.castShadow = true;\n brownCity.position.set((5/2) * spacing,0,0);\n playerSelectors.add(brownCity);\n\n playerSelectors.position.set(23, 0, 25);\n playerSelectors.rotation.y = -Math.PI/2;\n scene.add(playerSelectors);\n\n playerSelectorLight.target = selectorBackground;\n camera.lookAt(playerSelectors.position);\n\n turnIndicators = new THREE.Group();\n var vHeight = visibleHeightAtZDepth(plane.position.z, camera) /2 *0.82;\n turnIndicators.position.set(0,vHeight,2);\n // playerSelectors.rotation.y = -Math.PI/2;\n scene.add(turnIndicators);\n // Add OrbitControls so that we can pan around with the mouse.\n // controls = new THREE.OrbitControls(camera, renderer.domElement);\n\n //window resize\n window.addEventListener( 'resize', onWindowResize, false );\n // window.addEventListener( \"click\", findDiceFace );\n\n raycaster = new THREE.Raycaster();\n\n}", "function Door(geometry, material, x, y, z, direction){\n\t\t\n\t\tthis.isOpen = false;\n\t\tthis.direction = direction; // North, East, South, West : \n\t\t\n\t\tthis.cube = new THREE.Mesh(geometry,material);\n\t\tthis.cube.receiveShadow = true;\n\t\tthis.cube.castShadow = true;\n\t\t\n\t\tthis.cube.position.set( x, y, z);\t\n\t\t\n\t\tthis.isDoor = true;\n\t\t\n\t\tapp.city.scene.add(this.cube);\n\t\t\n\t}", "constructor({ width = 1.0, height = 1.0, length = 1.0 }) {\n super();\n /* Points 0, 1, 2, 3 are on the left.\n * Points 4, 5, 6, 7 are on the right.\n * x = width, y = length, z = height*/\n const topLeftOut = [(width / 2), 0, (height / 2)];\n const botLeftOut = [(width / 2), 0, -(height / 2)];\n const topLeftIn = [-(width / 2), 0, (height / 2)];\n const botLeftIn = [-(width / 2), 0, -(height / 2)];\n const topRightOut = [(width / 2), length, (height / 2)];\n const botRightOut = [(width / 2), length, -(height / 2)];\n const topRightIn = [-(width / 2), length, (height / 2)];\n const botRightIn = [-(width / 2), length, -(height / 2)];\n this.vertices.push(topLeftOut);\n this.vertices.push(botLeftOut);\n this.vertices.push(topLeftIn);\n this.vertices.push(botLeftIn);\n this.vertices.push(topRightOut);\n this.vertices.push(botRightOut);\n this.vertices.push(topRightIn);\n this.vertices.push(botRightIn);\n\n // Left side face\n this.triangles.push([0, 1, 2]);\n this.triangles.push([2, 3, 1]);\n // Back side face\n this.triangles.push([2, 3, 6]);\n this.triangles.push([3, 6, 7]);\n // Right side face\n this.triangles.push([4, 5, 6]);\n this.triangles.push([5, 6, 7]);\n // Bottom face\n this.triangles.push([3, 5, 1]);\n this.triangles.push([5, 6, 3]);\n // Front side face\n this.triangles.push([1, 5, 4]);\n this.triangles.push([0, 1, 4]);\n // Top face\n this.triangles.push([0, 2, 4]);\n this.triangles.push([2, 4, 6]);\n }", "function createScene(){\n 'use strict';\n\n scene = new THREE.Scene();\n\n scene.add(new THREE.AxisHelper(10));\n\n createTable(0, 0, 0);\n createLamp(40, 0, -20);\n createChair(0, 0, 30);\n}", "getThreeFace(){return this.faceMesh;}", "function createArrowElement(arrow) {\n var arrowElement = div();\n\n if (arrow === true) {\n arrowElement.className = ARROW_CLASS;\n } else {\n arrowElement.className = SVG_ARROW_CLASS;\n\n if (isElement(arrow)) {\n arrowElement.appendChild(arrow);\n } else {\n setInnerHTML(arrowElement, arrow);\n }\n }\n\n return arrowElement;\n}", "constructor( context, control_box ) // The scene begins by requesting the camera, shapes, and materials it will need.\r\n { super( context, control_box ); // First, include a couple other helpful components, including one that moves you around:\r\n if( !context.globals.has_controls ) \r\n context.register_scene_component( new Movement_Controls( context, control_box.parentElement.insertCell() ) ); \r\n\r\n // Define the global camera and projection matrices, which are stored in a scratchpad for globals. The projection is special \r\n // because it determines how depth is treated when projecting 3D points onto a plane. The function perspective() makes one.\r\n // Its input arguments are field of view, aspect ratio, and distances to the near plane and far plane.\r\n context.globals.graphics_state. camera_transform = Mat4.translation([ 0,0,-30 ]); // Locate the camera here (inverted matrix).\r\n context.globals.graphics_state.projection_transform = Mat4.perspective( Math.PI/4, context.width/context.height, .1, 1000 );\r\n \r\n const shapes = { 'triangle' : new Triangle(), // At the beginning of our program, load one of each of these shape \r\n 'strip' : new Square(), // definitions onto the GPU. NOTE: Only do this ONCE per shape\r\n 'bad_tetrahedron' : new Tetrahedron( false ), // design. Once you've told the GPU what the design of a cube is,\r\n 'tetrahedron' : new Tetrahedron( true ), // it would be redundant to tell it again. You should just re-use\r\n 'windmill' : new Windmill( 10 ), // the one called \"box\" more than once in display() to draw\r\n 'box' : new Cube(), // multiple cubes. Don't define more than one blueprint for the\r\n 'ball' : new Subdivision_Sphere( 4 ) }; // same thing here.\r\n this.submit_shapes( context, shapes );\r\n \r\n [ this.hover, this.t ] = [ false, 0 ]; // Define a couple of data members called \"hover\" and \"t\".\r\n \r\n // *** Materials: *** Define more data members here, returned from the material() function of our shader. Material objects contain\r\n // shader configurations. They are used to light and color each shape. Declare new materials as temps when\r\n // needed; they're just cheap wrappers for some numbers. 1st parameter: Color (4 floats in RGBA format).\r\n this.clay = context.get_instance( Phong_Shader ).material( Color.of( .9,.5,.9, 1 ), { ambient: .4, diffusivity: .4 } );\r\n this.plastic = this.clay.override({ specularity: .6 });\r\n this.glass = context.get_instance( Phong_Shader ).material( Color.of( .5,.5, 1,.2 ), { ambient: .4, specularity: .4 } );\r\n this.fire = context.get_instance( Funny_Shader ).material();\r\n this.stars = this.plastic.override({ texture: context.get_instance( \"assets/stars.png\" ) });\r\n\r\n // *** Lights: *** Values of vector or point lights. They'll be consulted by the shader when coloring shapes. Two different lights \r\n // *per shape* are supported by in the example shader; more requires changing a number in it or other tricks.\r\n // Arguments to construct a Light(): Light source position or vector (homogeneous coordinates), color, and intensity.\r\n this.lights = [ new Light( Vec.of( 30, 30, 34, 1 ), Color.of( 0, .4, 0, 1 ), 100000 ),\r\n new Light( Vec.of( -10, -20, -14, 0 ), Color.of( 1, 1, .3, 1 ), 100 ) ];\r\n }", "function buildBottomBorders(geometry,currentIndex){\n\n\n\tif(facingCamera){\n\t\t\n\t\tgeometry.vertices.push(new THREE.Vector3(-0.25,-0.25,0));\n\t\tgeometry.vertices.push(new THREE.Vector3(-0.25,-0.25,-0.10));\n\t\tgeometry.vertices.push(new THREE.Vector3(0.25,-0.25,-0.10));\n\t\t\n\n\t\tvar color = new THREE.Color( 0x000000 );\n\t\tvar face = new THREE.Face3(currentIndex,currentIndex+1,currentIndex+2,color);\n\t\tcurrentIndex += 3;\n\t\tgeometry.faces.push(face);\n\n\t\tgeometry.vertices.push(new THREE.Vector3(0.25,-0.25,0));\n\t\tgeometry.vertices.push(new THREE.Vector3(-0.25,-0.25,0));\n\t\tgeometry.vertices.push(new THREE.Vector3(0.25,-0.25,-0.10));\n\n\t\tface = new THREE.Face3(currentIndex,currentIndex+1,currentIndex+2,color);\n\t\tcurrentIndex += 3;\n\t\tgeometry.faces.push(face);\n\t}\n\telse{\n\t\tgeometry.vertices.push(new THREE.Vector3(-0.25,-0.25,0));\n\t\tgeometry.vertices.push(new THREE.Vector3(0.25,-0.25,-0.10));\n\t\tgeometry.vertices.push(new THREE.Vector3(-0.25,-0.25,-0.10));\n\t\t\n\t\tvar color = new THREE.Color( 0x000000 );\n\t\tvar face = new THREE.Face3(currentIndex,currentIndex+1,currentIndex+2,color);\n\t\tcurrentIndex += 3;\n\t\tgeometry.faces.push(face);\n\n\t\t\n\t\tgeometry.vertices.push(new THREE.Vector3(0.25,-0.25,0));\n\t\tgeometry.vertices.push(new THREE.Vector3(0.25,-0.25,-0.10));\n\t\tgeometry.vertices.push(new THREE.Vector3(-0.25,-0.25,0));\n\n\t\tface = new THREE.Face3(currentIndex,currentIndex+1,currentIndex+2,color);\n\t\tcurrentIndex += 3;\n\t\tgeometry.faces.push(face);\n\t}\n\n}", "function setup() {\n \n createCanvas(400,1200); \n \n background(255);\n colorMode(HSB,360,100,100);\n\n \n \tv = createVector(100,250);\n // v2 = createVector(v.x+150,v.y-75)\n tx = 107;\n ty=0;\n strokeWeight(2.0);\n v2 = createVector(v.x+170,v.y-75);\n \tanchorPoint = v2.copy();\n}" ]
[ "0.76643014", "0.6565999", "0.65508", "0.65248364", "0.64694476", "0.6308553", "0.6268231", "0.62507004", "0.62262636", "0.61648804", "0.61637837", "0.6149577", "0.61450136", "0.6138427", "0.61242926", "0.6100362", "0.6027", "0.6025186", "0.6014909", "0.6014772", "0.5984306", "0.59818876", "0.59473133", "0.59375465", "0.5920502", "0.59187454", "0.5916233", "0.5913155", "0.588999", "0.5881309", "0.5876174", "0.58740646", "0.58660537", "0.58501816", "0.5849851", "0.58399636", "0.5839797", "0.58387035", "0.5835891", "0.583144", "0.58263797", "0.58227336", "0.5807582", "0.57878894", "0.5785476", "0.57665586", "0.57570446", "0.5754009", "0.5752238", "0.57517517", "0.57445836", "0.5734882", "0.5732187", "0.5710029", "0.5707346", "0.5703228", "0.57020223", "0.56960976", "0.5693576", "0.56933475", "0.56915087", "0.5680458", "0.5674605", "0.56720483", "0.56719035", "0.56603914", "0.5655164", "0.5641381", "0.5634073", "0.5630816", "0.56288314", "0.5620451", "0.5616487", "0.5610776", "0.560959", "0.560891", "0.5608475", "0.5606705", "0.5602958", "0.5600231", "0.55971026", "0.55960405", "0.5595615", "0.5591165", "0.55859387", "0.5574928", "0.5569511", "0.5567038", "0.5563061", "0.5562284", "0.5560758", "0.556064", "0.5549783", "0.5547034", "0.5545386", "0.55440074", "0.5543989", "0.55424595", "0.55413836", "0.55394614" ]
0.6466647
5
Converts each image used by the extension into the base64 encoding, placing that encoding into an outputted JSON file for later use by the extension.
function encodeFile(path) { const file = fs.readFileSync(path); return new Buffer(file).toString('base64'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "serializeImagesRelations(images, writer) {\n if (images.length > 0) {\n let imagePath = '';\n let base64ImageString;\n let keys = images.keys;\n for (let i = 0; i < keys.length; i++) {\n let mImage = images.get(keys[i]);\n base64ImageString = mImage.imageString;\n if (isNullOrUndefined(base64ImageString)) {\n imagePath = this.imagePath + '/0.jpeg';\n this.serializeRelationShip(writer, keys[i], this.imageRelType, imagePath.replace('word/', ''));\n }\n else {\n let imageInfo = HelperMethods.formatClippedString(base64ImageString);\n let extension = imageInfo.extension;\n let formatClippedString = imageInfo.formatClippedString;\n imagePath = this.imagePath + keys[i] + extension;\n this.serializeRelationShip(writer, keys[i], this.imageRelType, imagePath.replace('word/', ''));\n //if (m_archive.Find(imagePath.Replace('\\\\', '/')) === -1)\n // {\n let imageBlob = new Blob([this.encodedString(formatClippedString)]);\n let zipArchiveItem = new ZipArchiveItem(imageBlob, imagePath);\n // let TestArchive = new ZipArchive();\n this.mArchive.addItem(zipArchiveItem);\n // TestArchive.save('image.zip').then(function (): void {\n // TestArchive.destroy();\n // });\n // }\n }\n }\n }\n }", "function convertImagesToBase64(protoObject) {\n if (protoObject.primitives) {\n const prims = protoObject.primitives;\n for (const stream of Object.keys(prims)) {\n if (prims[stream].images) {\n prims[stream].images.forEach(entry => {\n convertImageToBase64(entry);\n });\n }\n }\n } else if (protoObject.images) {\n protoObject.images.forEach(entry => {\n convertImageToBase64(entry);\n });\n } else if (protoObject.data && protoObject.width_px) {\n convertImageToBase64(protoObject);\n }\n}", "function imgToBase64(){\r\n $('img').each(function(){\r\n var src = $(this).attr('src');\r\n var img = $(this);\r\n if (src.includes(\"latex.codecogs.com\")) {\r\n toDataURL(\r\n 'https://cors-anywhere.herokuapp.com/' + src,\r\n function (dataUrl) {\r\n img.attr('src', dataUrl);\r\n });\r\n }\r\n });\r\n}", "static images() {\n let zip = new JSZip();\n\n let mainfs = zip.folder(\"mainfs\");\n let mainfsDirCount = PP64.fs.mainfs.getDirectoryCount();\n for (let d = 0; d < mainfsDirCount; d++) {\n let dirFolder = mainfs.folder(d.toString());\n let dirFileCount = PP64.fs.mainfs.getFileCount(d);\n for (let f = 0; f < dirFileCount; f++) {\n try {\n let fileBuffer = PP64.fs.mainfs.get(d, f);\n if (PP64.utils.FORM.isForm(fileBuffer)) {\n let formUnpacked = PP64.utils.FORM.unpack(fileBuffer);\n if (formUnpacked.BMP1.length) {\n formUnpacked.BMP1.forEach((bmpEntry, idx) => {\n let dataUri = PP64.utils.arrays.arrayBufferToDataURL(bmpEntry.parsed.src, bmpEntry.parsed.width, bmpEntry.parsed.height);\n dirFolder.file(`${f}.${idx}.png`, dataUri.substr(dataUri.indexOf(',') + 1), { base64: true });\n });\n }\n }\n else {\n // Maybe an ImgPack?\n let imgs = _readImgsFromMainFS(d, f);\n imgs.forEach((imgInfo, idx) => {\n let dataUri = PP64.utils.arrays.arrayBufferToDataURL(imgInfo.src, imgInfo.width, imgInfo.height);\n dirFolder.file(`${f}.${idx}.png`, dataUri.substr(dataUri.indexOf(',') + 1), { base64: true });\n });\n if (imgs.length > 1) {\n let tilesBuf = PP64.utils.img.tiler.fromTiles(_readPackedFromMainFS(d, f), imgs.length, 1, imgs[0].width * 4, imgs[0].height);\n let tilesUrl = PP64.utils.arrays.arrayBufferToDataURL(tilesBuf, imgs[0].width * imgs.length, imgs[0].height);\n dirFolder.file(`${f}.all.png`, tilesUrl.substr(tilesUrl.indexOf(',') + 1), { base64: true });\n }\n }\n }\n catch (e) {}\n }\n }\n\n zip.generateAsync({type: \"blob\"}).then((blob) => {\n saveAs(blob, `mp${PP64.romhandler.getGameVersion()}-images.zip`);\n });\n\n function _readPackedFromMainFS(dir, file) {\n let imgPackBuffer = PP64.fs.mainfs.get(dir, file);\n let imgArr = PP64.utils.img.ImgPack.fromPack(imgPackBuffer);\n if (!imgArr || !imgArr.length)\n return;\n\n let dataViews = imgArr.map(imgInfo => {\n return new DataView(imgInfo.src);\n });\n\n return dataViews;\n }\n\n function _readImgsFromMainFS(dir, file) {\n let imgPackBuffer = PP64.fs.mainfs.get(dir, file);\n let imgArr = PP64.utils.img.ImgPack.fromPack(imgPackBuffer);\n if (!imgArr || !imgArr.length)\n return;\n\n return imgArr;\n }\n }", "function writeJson() { //写json\n\n\tvar crock,\n\t\timages = exportImageData,\n\t\tidx = images.length - 1,\n\t\tjsOut,\n\t\thdr = exportHeader;\n\n\tjsOut = new File(hdr.outDir + '/' + hdr.prefix + '.js');\n\tjsOut.open('w');\n\tjsOut.writeln('/* exported json for ' + hdr.psdName + ' */');\n\tjsOut.writeln('\\n');\n\tjsOut.writeln('var imgInput = function () {');\n\tjsOut.writeln('\\n');\n\tjsOut.writeln(' var input = {');\n\tjsOut.writeln(' \"container\" : {');\n\tjsOut.writeln(' \"width\" : ' + hdr.psdWidth + ',');\n\tjsOut.writeln(' \"height\" : ' + hdr.psdHeight);\n\tjsOut.writeln(' },');\n\n\tjsOut.writeln(' \"images\" : [');\n\n\t// Photoshop extracts top first; put em in the JSON bottom first\n\tfor (idx; idx >= 0; idx -= 1) {\n\n\t\tjsOut.writeln(' {');\n\t\tjsOut.writeln(' \"name\" : \"' + images[idx].name + '\",');\n\t\tjsOut.writeln(' \"extension\": \"' + hdr.extension + '\",');\n\t\tjsOut.writeln(' \"left\" : ' + images[idx].left + ',');\n\t\tjsOut.writeln(' \"top\" : ' + images[idx].top + ',');\n\t\tjsOut.writeln(' \"width\" : ' + images[idx].width + ',');\n\t\tjsOut.writeln(' \"height\" : ' + images[idx].height);\n\n\t\tcrock = idx > 0 ? jsOut.writeln(' },') : jsOut.writeln(' }');\n\t}\n\tjsOut.writeln(' ]');\n\tjsOut.writeln(' };');\n\tjsOut.writeln('\\n');\n\tjsOut.writeln(' return JSON.stringify(input);');\n\tjsOut.writeln('}');\n\n\tjsOut.close();\n}", "function doit(files){\n// console.log(pattern);\n var element={};\n var img={};\n var obj=[];\n var images=[];\n var err='';\n var codice='';\n for (var i=0; i<files.length; i++) { \n if (i==0){\n codice=files[i];\n codice=codice.replace('./img/items/','');\n codice=codice.substring(0,14);\n // console.log(codice);\n }\n img={\"thumbnails\":files[i]};\n images[i]=img;\n }\n \n element.id = codice;\n element.images = images;\n obj=element;\n console.log(obj);\n \n \n// console.log(obj);\n // If the `nonull` option is set, and nothing\n // was found, then files is [\"**/*.js\"] \n // er is an error object or null.\n// console.log(files);\nvar jsonString = JSON.stringify(obj);\nfs.stat('test_dir.json', function(err, stat) {\nif(err == null) {\n fs.appendFile(\"./data/img.json\", \",\"+jsonString+\"\\n\", function(err) {\n if(err) {\n return console.log(err);\n }\n });\n\n } else if(err.code == 'ENOENT') {\n fs.writeFile(\"./data/img.json\", jsonString, function(err) {\n if(err) {\n return console.log(err);\n }\n });\n } else {\n console.log('Some other error: ', err.code);\n }\n});\n\n\n}", "function getBase64ProductImages(validImage) {\n var imageObj = {};\n //set of 4 images tobe uploaded.\n for (var i = 0; i <= 3; i++) {\n if (validImage[i]) {\n var item = {},\n imageData = validImage[i].siblings().children().find('img').attr('src');\n imageObj[\"image\" + i] = imageData;\n } else {\n var item = {};\n imageObj[\"image\" + i] = \"empty\";\n }\n }\n return imageObj;\n }", "function base64_encode(img) {\n // read binary data\n let png = fs.readFileSync(img);\n // convert binary data to base64 encoded string\n return new Buffer.from(png).toString('base64');\n}", "function preprocess(images) {\n return images.map((image) => {\n const next = Object.assign({}, image);\n next.writePath = `images/${image.name}`;\n return next;\n });\n }", "function base64_encode(img) {\n // read binary data\n let png = fs.readFileSync(img);\n // convert binary data to base64 encoded string\n return new Buffer.from(png).toString('base64');\n}", "function getBase64StringMulti(resized) {\n\n var stringDataTypeFull = resized.split(';')[0];\n var stringDataType = stringDataTypeFull.split(':')[1]; // get data type for blob conversion\n var stringBase64 = resized.split(',')[1]; // get base64 string for blob conversion - iVBORw0KGgoAAAA...\n var blob = b64toBlob(stringBase64, stringDataType); // encode base64 string as blob for preview & file ops\n var blobUrl = URL.createObjectURL(blob); // create Object URL for image preview of resized image\n\n img = document.createElement(\"img\"); // use resized image (blobUrl) for image preview\n img.src = blobUrl;\n document.getElementById(fileName).src = blobUrl;\n\n resizedImages.push({filename: fileName, data: resized}); // push photo filename & data to array\n }", "function pngToBase64(pngs, callback) {\n\t// convert png images to base64\n\tvar base64Imgs = [];\n\tvar imageCount = pngs.length;\n\tpngs.map(function(url, index) {\n\t\tconvertImg(url, function(base64Img){\n\t\t\t// Base64DataURL\n\t\t\tbase64Imgs[index] = base64Img.substring(22);\n\n\t\t\t// TODO: Is this how to waterfall these async processes?\n\t\t\timageCount--;\n\t\t\tif (imageCount <= 0) {\n\t\t\t\tcallback(base64Imgs);\n\t\t\t}\n\t\t});\n\t});\n}", "static formImages() {\n let mainfsDirCount = PP64.fs.mainfs.getDirectoryCount();\n for (let d = 0; d < mainfsDirCount; d++) {\n let dirFileCount = PP64.fs.mainfs.getFileCount(d);\n for (let f = 0; f < dirFileCount; f++) {\n let fileBuffer = PP64.fs.mainfs.get(d, f);\n if (!PP64.utils.FORM.isForm(fileBuffer))\n continue;\n\n try {\n let formUnpacked = PP64.utils.FORM.unpack(fileBuffer);\n if (formUnpacked.BMP1.length) {\n formUnpacked.BMP1.forEach(bmpEntry => {\n let dataUri = PP64.utils.arrays.arrayBufferToDataURL(bmpEntry.parsed.src, bmpEntry.parsed.width, bmpEntry.parsed.height);\n console.log(`${d}/${f}:`);\n console.log(dataUri);\n });\n }\n }\n catch (e) {}\n }\n }\n }", "async function imgTob64 (image_source){\n\n}", "function internalizeImages($html, callback) {\n var $images = $html.filter('img');\n $images.each(function(index) {\n var $image = $(this);\n var imageSource = $image.attr('src');\n // add support for GIFs\n var filetype = imageSource.split('.').pop();\n convertImgToBase64(imageSource, filetype, function(dataURL) {\n $image.attr('src', dataURL); // replaced with Base64\n // when finish iterating images, do callback\n if (index === $images.length-1) callback($html);\n });\n });\n}", "transform(image) {\n image = image.toJSON()\n return {\n id: image.id,\n size: image.size,\n original_name: image.original_name,\n extension: image.extension,\n url: image.url\n }\n }", "apply_blob(blob) { return Base64.encode(blob) }", "saveAsjpg() {\n return Object(tslib__WEBPACK_IMPORTED_MODULE_0__[\"__awaiter\"])(this, void 0, void 0, function* () {\n // base64 image\n var img = this.canvas.toDataURL(\"image/jpg\");\n var base64data = img.split(\",\")[1];\n img = \"\";\n var newbase64Img = base64data.replace(/\\//g, \"SLASH\");\n this.apiresult = yield this.apiService.getApiResult(newbase64Img).toPromise();\n console.log(\"flask response \" + this.apiresult);\n // Emmiting response to parent component\n this.childevent.emit(this.apiresult);\n });\n }", "function imageEncode (arrayBuffer) {\n let u8 = new Uint8Array(arrayBuffer)\n let b64encoded = btoa([].reduce.call(new Uint8Array(arrayBuffer),function(p,c){return p+String.fromCharCode(c)},''))\n let mimetype=\"image/jpeg\"\n return \"data:\"+mimetype+\";base64,\"+b64encoded\n}", "function convertImage(type, data) {\n return \"\\\"data:image/\" + type + \";base64,\" + (new Buffer(data).toString('base64')) + \"\\\"\";\n }", "async processImages(o) {\n let re = /(?:!\\[(.*?)\\]\\((.*?)\\))/g\n let matches = o.content.matchAll(re)\n for(let m of matches) {\n let url = m[2]\n let match = /assets\\/(.+)$/.exec(url)\n if (match && match.length > 0) {\n let b = await this.fs.promises.readFile(`${this.config.settings.SRC}/assets/${match[1]}`)\n await this.fs.promises.writeFile(`${this.config.settings.DEST}/assets/${match[1]}`, b)\n }\n }\n }", "function convertImageToBase64(image) {\n if (Array.isArray(image.data)) {\n image.data = base64js.fromByteArray(Uint8Array.from(image.data));\n }\n}", "function encoderBase64() {\n return {\n write: encodeBase64Write,\n end: encodeBase64End,\n\n prevStr: '',\n };\n}", "parseIconFiles() {\n this.iconFiles.forEach(iconFile => {\n const name = path.basename(iconFile, '.svg').substring(2);\n const svgMarkup = fs.readFileSync(path.resolve(this.distIconsFolder, iconFile), 'utf8');\n const content = Parser.getContent(svgMarkup);\n const iconObject = {\n name,\n content,\n };\n\n this.output.icons.push(iconObject);\n });\n }", "function buildFile() {\n const asList = Object.keys(data).reduce((arr, tag) => {\n return [...arr, { tag, bundles: data[tag].bundles }]\n }, [])\n const stringified = JSON.stringify(asList, null, 2)\n fs.writeFileSync(`sizes-${Date.now()}.json`, stringified)\n}", "function encodeB64AnnotationBatch(token, imgAnnotations){\n\n let bodyReq = {\n 'btoken': token, // really important since every batch annotations is identified by a unique token\n 'data64': Buffer.from(JSON.stringify(imgAnnotations)).toString('base64')\n };\n\n fetch(backendStorage + 'updateBatchAnn.php', {\n method: 'POST',\n body: JSON.stringify(bodyReq),\n headers: {\n 'Content-Type': 'application/json'\n }\n })\n .then(php_response => {\n //console.log('PHP response: ');console.log(php_response);\n });\n}", "function image_result_streamization() {\r\n \r\n}", "function writeFile(callback) {\n var s = JSON.stringify(images);\n\n fs.writeFile('imageData.json', s, function (err) {\n if (err) return console.log(err);\n else\n { \n console.log(\"ERFOLG\");\n if (callback) callback.call(this, images);\n }\n });\n\n\n }", "function encodeImageToString(element) {\n\tif(element){\n\t\tvar FileSize = element.files[0].size / 1024 / 1024; // in MB\n\t\tif (FileSize > 1) {\n\t\t\tnotify(\"error\", \"Image size exceeds 1 MB. Please upload a valid image.\");\n\t\t\treturn false;\n\t\t\t// $(file).val(''); //for clearing with Jquery\n\t\t} else {\n\t\t\tif(validate()){\n\t\t\t\tif($('input[type=file]').val().replace(/C:\\\\fakepath\\\\/i, '')){\n\t\t\t\t\timage_data = {}\n\t\t\t\t\timage_data['img_name'] = $('input[type=file]').val().replace(/C:\\\\fakepath\\\\/i, '')\n\t\t\t\t\tvar file = element.files[0];\n\t\t\t\t\tvar reader = new FileReader();\n\t\t\t\t\treader.onloadend = function() {\n\t\t\t\t\t\tvar img_str = reader.result\n\t\t\t\t\t\timage_data['img_str'] =img_str.split(',')[1] \n\t\t\t\t\t\timage_data['img_format'] = $('input[type=file]').val().replace(/C:\\\\fakepath\\\\/i, '').split('.')[1];\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\treader.readAsDataURL(file);\n\t\t\t\t}\n\t\t\t}else{\n\t\t\t\timage_data = {};\n\t\t\t\t//$('.fileinput-exists').trigger('click'); \n\t\t\t}}}else{ \n\t\t\t\tnotify(\"info\", \"Image upload error.\");\n\t\t\t}\n\t\t\tconsole.log(\"@@@\",image_data)\t\t\t\n\t\t\t\n\t\t\t\n\t\t \n }", "async function decodeBase64Image(dataString) {\r\n\r\n cloudinary.config({\r\n cloud_name: process.env.CLOUD_NAME,\r\n api_key: process.env.API_KEY,\r\n api_secret: process.env.API_SECRET\r\n });\r\n\r\n const valid_extensions = ['png', 'jpg', 'jpeg'];\r\n var matches = dataString.match(/^data:([A-Za-z-+\\/]+);base64,(.+)$/)\r\n response = {};\r\n // console.log(matches);\r\n if (matches.length !== 3) {\r\n return new Error('Invalid input string');\r\n }\r\n\r\n extension = matches[1].split(\"/\")[1].toLowerCase().trim();\r\n data = Buffer.from(matches[2], 'base64');\r\n let imageName = `${Date.now()}-image.${extension}`\r\n if (valid_extensions.indexOf(extension) !== -1) {\r\n\r\n var dir = './images/'\r\n if (!fs.existsSync(dir)) {\r\n fs.mkdirSync(dir);\r\n }\r\n\r\n console.log('full dir: ', dir, 'existed: ', fs.existsSync(dir));\r\n\r\n fs.writeFile(`./images/${imageName}`, data, function(err) {\r\n if (err) {\r\n console.log('error when save image: ', err)\r\n response.status = 500;\r\n response.error = err.toString();\r\n }\r\n });\r\n\r\n // upload image to cloudinary\r\n result = await cloudinary.uploader.upload(`./images/${imageName}`);\r\n\r\n console.log(result);\r\n console.log(result.url);\r\n response.name = result.url\r\n response.status = 200;\r\n response.path = dir;\r\n response.type = matches[1];\r\n // response.name = imageName;\r\n response.extension = extension;\r\n } else {\r\n response.status = 404\r\n response.error = 'extension not supported'\r\n\r\n }\r\n\r\n return response;\r\n}", "function addArticleRepresentationImage(files, request_json) {\n for (var i = 0; i < files.length; i++) {\n request_json[\"article_representations\"].push({\n \"representation\": {\n \"representation_type_code\": REPRESENTATION_IMAGE_TYPE_CODE\n }\n });\n }\n}", "slimTransform(data, slim){\n if(slim._hasInitialImage && !slim._imageEditor)\n return true;\n \n var base64 = 0;\n var large_base64 = 0;\n if(slim._data.output.image){\n var dataurl = slim._data.output.image.toDataURL(\"image/*\") ;\n var arr = dataurl.split(','), mime = arr[0].match(/:(.*?);/)[1],\n bstr = atob(arr[1]), n = bstr.length, u8arr = new Uint8Array(n);\n while(n--){\n u8arr[n] = bstr.charCodeAt(n);\n }\n var file = new File([u8arr], slim._data.input.name, {type:mime});\n base64 = file;\n }\n // if(slim._data.input.image){\n // var inputFile = new File([slim._data.input.file], slim._data.input.name);\n // large_base64 = inputFile;\n // }\n this.onChangeAddNewUserDetails(slim._output.name, base64);\n //this.props.onChangeAddNewUserDetails(slim._output.name+'_large', large_base64);\n console.log('Transform',base64);\n \n }", "static importAllImages(r = require.context(\"./images\", false, /\\.(png|jpe?g|svg)$/)) {\n let images = {};\n r.keys().map((item) => { images[item.replace('./', '')] = r(item); });\n return images;\n }", "function postprocess(images) {\n return images.map((image) => {\n if (config.productionMode) {\n image.contents = minify(image.contents, image.extension, config.minify);\n }\n return image;\n });\n }", "function addImages() {\n var images = ['heroImage', 'legacyLogo'];\n var img = null;\n for (var i = 0; i < images.length; i++) {\n var key = companyInfo['key'];\n if (companyInfo[images[i]].length > 0) {\n var url = 'https://media.licdn.com/media' + companyInfo[images[i]];\n img = $('<img class=\"recruiting-token-image\" id=\"' + images[i] + '-' + key + '\">');\n $(img).attr('src', url);\n img.data('file', null);\n img.data('name', images[i] + '-' + key);\n img.data('saved', false);\n img.data('scraped', true);\n createThumbnail(img, 'company-image-container');\n }\n }\n}", "function saveImageData(data, name) {\n //combine all data into object\n ret = {}\n for (key in data) {\n //get images for one product\n var imagePath = data[key][name];\n var jdata = JSON.parse(imagePath);\n\n //put the images into object, key is product id(0,1,2,3,4...)\n ret[key] = jdata;\n }\n allData[name] = ret;\n}", "static generateContainersWithImageInfoAndLoadImageWithCompression(data) {\n\t\tif (data.hasOwnProperty('response')) {\n\t\t\tconst imageStatisticsContainers = AngularConstants.generateImageStatisticsConstants();\n\t\t\tconst BACKEND_KEYS = AngularConstants.generateBackendCompressionAccessibleKeys();\n\n\t\t\tlet statisticModule = null, \n\t\t\t\tbackendInformation;\n\n\t\t\timageStatisticsContainers.forEach(function(imageStatisticsContainer) {\n\t\t\t\tbackendInformation = data.response[imageStatisticsContainer.jsonKey];\n\t\t\t\tImageCompressionStatistics.createAndInitialize(imageStatisticsContainer.id, backendInformation);\n\n\t\t\t\tif (imageStatisticsContainer.jsonKey === BACKEND_KEYS.imageWithOptimizationKey) {\n\t\t\t\t\tif (backendInformation.hasOwnProperty('filePath')) {\n\t\t\t\t\t\tImageCompressionContainer.createAndInitialize(imageStatisticsContainer.id, backendInformation.filePath);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t}", "function encodeIMG() {\n if ($('#fileIMG').prop('files')[0]) {\n var imgFile = $('#fileIMG').prop('files')[0];\n if (imgFile.size >= 2000000) {\n $('.error').text(\n 'Your image is larger than 2mb! Please upload a smaller image.'\n );\n }\n var reader = new FileReader();\n reader.onloadend = function () {\n $('.file1').remove();\n $('<img>')\n .attr('src', reader.result)\n .attr('alt', 'User Image')\n .attr('id', 'preview1')\n .attr('class', 'file1')\n .appendTo($('.imgdisplay')); // displays image on site\n imgResult = reader.result; // base64 conversion result\n return imgResult;\n };\n reader.readAsDataURL(imgFile); // Takes the file and converts the data to base64\n }\n}", "async function encodeImage(url) {\n\treturn new Promise((resolve, reject) => {\n\t\trequest.get(url, function (error, response, body) {\n\t\t\tif (error) {\n\t\t\t\tconsole.log(error);\n\t\t\t\treturn resolve(null);\n\t\t\t}\n\t\t\tif (response.statusCode != 200) {\n\t\t\t\tconsole.log(\"Images not found, is the image folder route correct?\");\n\t\t\t\treturn resolve(null);\n\t\t\t}\n\t\t\tlet data = \"data:\" + response.headers[\"content-type\"].replace(\" \", \"\") + \";base64,\" + new Buffer.from(body).toString('base64');\n\t\t\treturn resolve(data);\n\t\t})\n\t});\n}", "function repositoryGen() {\n hexo.extend.filter.register(\"after_generate\", function (picture) {\n log.info(\"---- START GENERATING PICTURE FILES ----\");\n try {\n var arr = [];\n const originPath = pictureDirPath;\n const output = targetPhotoListDir;\n (function test(path) {\n const files = fs.readdirSync(path);\n if (!files.length) return;\n files.forEach(v => {\n const vPath = path + \"/\" + v;\n const stats = fs.statSync(vPath);\n if (stats.isFile()) {\n const imgSize = sizeOf(vPath);\n arr.push(imgSize.width + \".\" +\n imgSize.height + \" \" +\n vPath.replace(originPath + \"/\", \"\"));\n } else {\n test(vPath);\n }\n });\n })(originPath);\n var content = JSON.stringify(arr, null, \"\\t\");\n fs.writeFile(output, content);\n } catch (err) {\n log.info(err);\n }\n var photojslibPath = pathFn.join(__dirname, \"lib/repos.js\");\n var photoJsContent = fs.readFileSync(photojslibPath);\n photoJsContent = photoJsContent.replace(\"${thumbnailUrl}\", pictureUrl);\n photoJsContent = photoJsContent.replace(\"${pictureUrl}\", pictureUrl);\n fs.writeFile(photoPubPath, photoJsContent);\n log.info(\"---- END GENERATING PICTURE FILES ----\");\n });\n}", "exportPng(imageData) {\n return __awaiter(this, void 0, void 0, function* () {\n const base64 = imageData.replace('data:image/png;base64,', '');\n const pngFilePath = this._uri.fsPath.replace('.json', '');\n const pngFileUri = yield vscode_1.window.showSaveDialog({\n defaultUri: vscode_1.Uri.parse(pngFilePath).with({ scheme: 'file' }),\n filters: { 'PNG': ['png'] }\n });\n if (pngFileUri) {\n fs.writeFile(pngFileUri.fsPath, base64, 'base64', (error) => {\n if (error) {\n const errorMessage = `Failed to save file: ${pngFileUri.fsPath}`;\n this._logger.logMessage(logger_1.LogLevel.Error, 'exportPng():', errorMessage);\n vscode_1.window.showErrorMessage(errorMessage);\n }\n });\n }\n this.webview.postMessage({ command: 'showMessage', message: '' });\n });\n }", "function parseImageUrls(params){\n\t\tif(opts.verbose !== 0 || !opts.hideErrors){\n\t\t\tconsole.info('[Embedding data URIs to] -> %s', params.path);\n\t\t}\n\t\tvar fileAbsPath = sysPath.resolve(sysPath.dirname(params.path));\n\t\tvar data = params.data;\n\t\tvar result = data.match(pattern); \n\t\tvar base64Data = data;\n\n\t\tresult.forEach(function(item){\n\t\t\t// Assuming image path is system path, not \"http/https path\"\n\t\t\tvar raw_path = item.replace(/url(?:\\s*)\\((?:\\s*)[\\'\\\"]?([^\\)\\'\\\"]*)[\\'\\\"]?(?:\\s*)\\)/, '$1');\n\t\t\tvar path = clean_url_value(raw_path); // '../assets/images/clock.svg'\n\t\t\tvar ext = sysPath.extname(path);\n\t\t\t// Don't convert when path is already a data-uri \n\t\t\tif(/^data:image/.test(path) || (imgsExtns.indexOf(ext) == -1)){\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif(/^(http|https):\\/\\//.test(path)){\n\t\t\t\tif(opts.verbose == 2 || opts.verbose == MAX_VERBOSE_VAL){\n\t\t\t\t\tconsole.info('Skipped data-uri as path has http/https %s', path);\n\t\t\t\t} \n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// Find absolute path in relation to the \"*.less\" file path \n\t\t\tvar absPath = sysPath.resolve(fileAbsPath, path); \n\n\t\t\tif(!fs.existsSync(absPath)){\n\t\t\t\tvar newpath = sysPath.resolve(opts.altImageDir, path);\n\t\t\t\tif(fs.existsSync(newpath)){\n\t\t\t\t\tabsPath = newpath;\n\t\t\t\t}else{\n\t\t\t\t\tif(!opts.hideErrors){\n\t\t\t\t\t\tconsole.info('[Warn] Skipped, the file is missing at: %s',absPath);\n\t\t\t\t\t}\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif(typeof imagesDataMap[absPath] === 'undefined'){\n\t\t\t\tvar mimeType = mime.lookup(path);\n\n\t\t\t\timagesDataMap[absPath] = {};\n\t\t\t\timagesDataMap[absPath].path = path;\n\t\t\t\timagesDataMap[absPath].absPath = absPath;\n\t\t\t\timagesDataMap[absPath].mimeType = mimeType;\n\t\t\t\timagesDataMap[absPath].toSkipped = false; // Also upadted in getDataUri()\n\t\t\t\timagesDataMap[absPath].dataUri = getDataUri(mimeType, absPath);\n\t\t\t}\n\t\t\t// Don't replace url with base64 when it is marked to skipped.\n\t\t\tif(!imagesDataMap[absPath].toSkipped){\n\t\t\t\tvar quote = ('image/svg+xml' === imagesDataMap[absPath].mimeType || opts.urlQuotes) ? '\\\"' : '';\n\t\t\t\tbase64Data = base64Data.replace(item, \"url(\"+ quote + imagesDataMap[absPath].dataUri + quote + \")\");\n\t\t\t\tif(opts.verbose == 3) {\n\t\t\t\t\tconsole.info('Successfully converted %s', absPath);\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\treturn base64Data;\n\t}", "function base64_encode (file, callback) {\n // read binary data\n var bitmap = fs.readFileSync(file, {encoding: 'base64'});\n // convert binary data to base64 encoded string\n // var base64 = new Buffer(bitmap, 'binary').toString('base64');\n // var base64 = bitmap.toString('base64');\n\n // bitmap = bitmap.replace(/_/g, '/');\n // bitmap = bitmap.replace(/-/g, '+');\n callback(bitmap);\n}", "runConverter(){\n return this.getFiles().forEach((file) =>{\n file.convert();\n file.getScreenshots();\n });\n }", "base64(pathFile) {\n const fs = require('fs');\n let base64data = null;\n try {\n let buff = fs.readFileSync(pathFile);\n base64data = buff.toString('base64');\n } catch (error) {\n console.log('Image not converted to base 64 :\\n\\n' + error);\n }\n //console.log('Image converted to base 64 is:\\n\\n' + base64data);\n return base64data;\n }", "function imageToPngBase64(imgsrc) {\n var img = document.createElement(\"IMG\");\n img.src = imgsrc;\n var c = document.createElement(\"CANVAS\");\n c.id = \"myCanvas\";\n c.width = img.width;\n c.height = img.height;\n var ctx = c.getContext(\"2d\");\n ctx.drawImage(img, 0, 0);\n return c.toDataURL();\n}", "async function base64IconConversion() {\t\n\t\t\tlet iconsConverted = 0\n\t\t\tlet iconsNotConverted = 0\n\t\t\tlet iconsBase64 = 0\n\t\t iziToast.show({\n\t\t id: 'base64',\n\t\t\t\ttheme: iziTheme,\n\t\t\t\ttimeout: false,\n\t\t\t\tprogressBar: false,\n\t\t\t\toverlay: true,\n\t\t\t\toverlayClose: true,\n\t\t\t\tanimateInside: true,\n\t\t\t\tcloseOnEscape: true,\n\t\t\t\tclose: false,\n\t\t backgroundColor: bgColor, \n\t\t position: 'center',\n\t\t title: jsonLanguage.settings.dialog_convertIconTitle,\n\t\t titleSize: '22',\n\t\t titleLineHeight: '30',\n\t\t titleColor: '#008200',\n\t\t message: jsonLanguage.settings.dialog_convertIconMsg,\n\t\t\t\tmessageSize: '18',\n\t\t\t\tmessageColor: 'white',\t\t\n\t\t\t\tmessageLineHeight: '20',\n\t\t displayMode: 2,\n\t\t\t\ttransitionIn: 'fadeIn',\n\t\t\t\ttransitionOut: 'fadeOutDown',\n\t\t\t\tlayout: 9,\n\t\t\t\tbuttons: [\n\t\t\t\t\t['<button style=\"background-color: #a70e0e;\">'+jsonLanguage.settings.dialog_Cancel+'</button>', function (instance, toast) {\n\t\t\t\t\t\tinstance.hide({ }, toast)\n\t\t\t\t\t}],\n\t\t\t\t\t['<button style=\"background-color: #38A12A;\"><b>'+jsonLanguage.settings.dialog_Ok+'</b></button>', async function (instance, toast) {\n\t\t\t\t\t\tinstance.hide({ }, toast)\n\t\t\t\t\t\ttoggleOverlay(true)\n\t\t\t\t\t\tlet count = document.getElementById(\"spinner-count\")\n\t\t\t\t\t\tlet jsonData\t\n\t\t\t\t\t\ttry {\n\t\t \t\t\tlet result = await chrome.storage.local.get(\"upStartData\")\n\t\t\t\t\t\t\tjsonData = JSON.parse(result.upStartData)\t\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\tfor (i = 0; i < jsonData['items'].length; i++) {\n\t\t\t\t\t\t\t\tcount.innerHTML = jsonLanguage.settings.dialog_countMsg+'<BR><span class=\"highlight-text\">'+jsonData.items[i].label+'</span>'\n\t\t\t\t\t\t\t\tlet itemIcon = jsonData.items[i].icon\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t//verify url\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif ( (itemIcon == \"\") || (itemIcon == 'undefined') ) {\n\t\t\t\t\t\t\t\t\titemIcon = 'icon/default.svg'\n\t\t\t\t\t\t\t\t}\n\n\n\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\tif (itemIcon.toLowerCase().match(/^data:image\\/.*/)) { \n\t\t\t\t\t\t\t\t\t\ticonsBase64++\n\t\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t\tlet base64ImageData = await getBase64Image(itemIcon, 128, 128)\n\t\t\t\t\t\t\t\t\t\tjsonData.items[i].icon = base64ImageData\n\t\t\t\t\t\t\t\t\t\ticonsConverted++\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tcatch (error) {\t\t\n\t\t\t\t\t\t\t\t\tconsole.log(error)\t\t\t\n\t\t\t\t\t\t\t\t\ticonsNotConverted++\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\t\t\t\t\t\n\t\t\t\t\t\t\ttoggleOverlay(false)\n\t\t\t\t\t\t\n\n\t\t\t\t\t\t\tif (iconsConverted != 0) {\n\t\t\t\t\t\t\t\t//message\n\t\t\t\t\t\t\t\tiziToast.show({\n\t\t\t\t\t\t\t\t\ttheme: iziTheme,\n\t\t\t\t\t\t\t\t\ttimeout: false,\n\t\t\t\t\t\t\t\t\tprogressBar: false,\n\t\t\t\t\t\t\t\t\toverlay: true,\n\t\t\t\t\t\t\t\t\tcloseOnEscape: true,\n\t\t\t\t\t\t\t\t\tclose: false,\n\t\t\t\t\t\t\t\t\tbackgroundColor: bgColor, \n\t\t\t\t\t\t\t\t\tposition: 'center',\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\ttitle: jsonLanguage.settings.dialog_convertIconComplete,\n\t\t\t\t\t\t\t\t\ttitleSize: '22',\n\t\t\t\t\t\t\t\t\ttitleLineHeight: '30',\n\t\t\t\t\t\t\t\t\ttitleColor: '#008200',\n\t\t\t\t\t\t\t\t\tmessage: '<BR><span class=\"highlight-text\">'+iconsConverted+'</span> '+jsonLanguage.settings.dialog_convertIconConverted+\n\t\t\t\t\t\t\t\t\t'<BR><span class=\"highlight-text\">'+iconsNotConverted+'</span> '+jsonLanguage.settings.dialog_convertIconNotConverted+\n\t\t\t\t\t\t\t\t\t'<BR><span class=\"highlight-text\">'+iconsBase64+'</span> '+jsonLanguage.settings.dialog_convertIconAlready64,\n\t\t\t\t\t\t\t\t\tmessageSize: '18',\n\t\t\t\t\t\t\t\t\tmessageColor: 'white',\t\t\n\t\t\t\t\t\t\t\t\tmessageLineHeight: '20',\n\t\t\t\t\t\t\t\t\ttransitionIn: 'fadeIn',\n\t\t\t\t\t\t\t\t\ttransitionOut: 'fadeOutDown',\n\t\t\t\t\t\t\t\t\tdisplayMode: 2,\n\t\t\t\t\t\t\t\t\tlayout: 2,\n\t\t\t\t\t\t\t\t\tbuttons: [\n\t\t\t\t\t\t\t\t\t\t['<button style=\"background-color: #a70e0e;\">'+jsonLanguage.settings.dialog_Cancel+'</button>', function (instance, toast) {\n\t\t\t\t\t\t\t\t\t\t\tinstance.hide({ }, toast)\n\t\t\t\t\t\t\t\t\t\t}],\n\t\t\t\t\t\t\t\t\t\t['<button style=\"background-color: #38A12A;\"><b>'+jsonLanguage.settings.dialog_Apply+'</b></button>', async function (instance, toast) {\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\tawait chrome.storage.local.set({\"upStartData\": JSON.stringify(jsonData)})\n\t\t\t\t\t\t\t\t\t\t\tinstance.hide({ }, toast)\n\t\t\t\t\t\t\t\t\t\t\tsuccessMessage(jsonLanguage.settings.message_dataSaved)\n\t\t\t\t\t\t\t\t\t\t},true]\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t]\n\t\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t//message\n\t\t\t\t\t\t\t\tiziToast.show({\n\t\t\t\t\t\t\t\t\ttheme: iziTheme,\n\t\t\t\t\t\t\t\t\ttimeout: false,\n\t\t\t\t\t\t\t\t\tprogressBar: false,\n\t\t\t\t\t\t\t\t\toverlay: true,\n\t\t\t\t\t\t\t\t\tcloseOnEscape: true,\n\t\t\t\t\t\t\t\t\tclose: false,\n\t\t\t\t\t\t\t\t\tbackgroundColor: bgColor, \n\t\t\t\t\t\t\t\t\tposition: 'center',\n\t\t\t\t\t\t\t\t\ttitle: jsonLanguage.settings.dialog_noIconsConverted, \n\t\t\t\t\t\t\t\t\ttitleSize: '22',\n\t\t\t\t\t\t\t\t\ttitleLineHeight: '30',\n\t\t\t\t\t\t\t\t\ttitleColor: '#008200',\n\t\t\t\t\t\t\t\t\tdisplayMode: 2,\n\t\t\t\t\t\t\t\t\ttransitionIn: 'fadeIn',\n\t\t\t\t\t\t\t\t\ttransitionOut: 'fadeOutDown',\n\t\t\t\t\t\t\t\t\tlayout: 2,\n\t\t\t\t\t\t\t\t\tbuttons: [\n\t\t\t\t\t\t\t\t\t\t['<button style=\"background-color: #38A12A;\">'+jsonLanguage.settings.dialog_Ok+'</button>', function (instance, toast) {\n\t\t\t\t\t\t\t\t\t\t\tinstance.hide({}, toast)\n\t\t\t\t\t\t\t\t\t\t},true]\n\t\t\t\t\t\t\t\t\t]\n\t\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcatch (error) {\n\t\t\t\t\t\t\tconsole.log(error)\n\t\t\t\t\t\t}\t\t\t\t\n\t\t\t\t\t},true]\t\t\t\t\t\n\t\t\t\t]\n\t\t\t})\n\t\t}", "function base64_encode(file) {\r\n // read binary data\r\n let bitmap = fs.readFileSync(file);\r\n // convert binary data to base64 encoded string\r\n return new Buffer(bitmap).toString('base64');\r\n}", "slimTransformMulti(data, slim){\n \n \n var base64 = 0;\n var large_base64 = 0;\n if(slim._data.output.image){\n var dataurl = slim._data.output.image.toDataURL(\"image/*\") ;\n var arr = dataurl.split(','), mime = arr[0].match(/:(.*?);/)[1],\n bstr = atob(arr[1]), n = bstr.length, u8arr = new Uint8Array(n);\n while(n--){\n u8arr[n] = bstr.charCodeAt(n);\n }\n var file = new File([u8arr], slim._data.input.name, {type:mime});\n base64 = file;\n }\n if(slim._data.input.image){\n var inputFile = new File([slim._data.input.file], slim._data.input.name);\n large_base64 = inputFile;\n }\n this.onChangeAddNewUserDetails(slim._output.name, base64);\n //this.props.onChangeAddNewUserDetails(slim._output.name+'_large', large_base64);\n console.log('Transform');\n }", "function drawImages() {\n if (counter < project.renderImages.length) {\n var imageForm = new FormData();\n ctx.clearRect(0, 0, canvasRender.width, canvasRender.height);\n var image = project.renderImages[counter];\n var posX = parseInt((res.width / 2) - (image.originalWidth / 2));\n var posY = parseInt((res.height / 2) - (image.originalHeight / 2));\n ctx.putImageData(image, posX, posY);\n var imgData = canvasRender.toDataURL(\"image/jpeg\", 1.0);\n // convert base64 string to blob\n var blobBin = atob(imgData.split(',')[1]);\n var array = [];\n for (var j = 0; j < blobBin.length; j++) {\n array.push(blobBin.charCodeAt(j));\n }\n var file = new Blob([new Uint8Array(array)], {\n type: 'image/jpeg'\n });\n\n var fieldname = filename = \"image\" + counter;\n console.log(\"making\", filename);\n imageForm.append('projectID', project.getProjectID());\n imageForm.append('currImageNum', counter + 1);\n imageForm.append(fieldname, file, filename + \".jpg\");\n\n var request = new XMLHttpRequest();\n request.open(\"POST\", \"/render\");\n request.send(imageForm);\n request.onreadystatechange = function() {\n if (request.readyState == 4) {\n if (request.status === 200) {\n drawImages();\n } else {\n swal(\"Error\", \"There was a problem with the image upload. Try again\", \"error\");\n }\n }\n }\n counter += 1;\n } else {\n done = true;\n formData.append('currImageNum', counter);\n }\n }", "function postImage() {\t\n\t// encodes image to base64\n\tvar filesSelected = document.getElementById(\"userphoto\").files;\n\tif (filesSelected.length > 0) {\n\t\tvar fileToLoad = filesSelected[0];\n\t\tvar fileReader = new FileReader();\n \n\t\tfileReader.onload = function(fileLoadedEvent) {\n\t\t \tvar srcData = fileLoadedEvent.target.result;\n \n\t\t \tvar newImage = document.createElement('img');\n\t\t \tnewImage.src = srcData;\n \n\t\t \tdocument.getElementById(\"imgTest\").innerHTML = newImage.outerHTML; // adds image to website\n \n\t\t\tlet encodedImage = document.getElementById(\"imgTest\").innerHTML; // gets base64 string from image\n\t\t \n\t\t \tremoveElement('imgTest'); // removes image from website\n\n\t\t\t// let betterEncodedImage = encodedImage.slice(encodedImage.indexOf(\"base64\")+7, -2); // just the base64 code\n\t\t\tlet betterEncodedImage = encodedImage.slice(10, -2); // doesn't remove image type\n\n\t\t\t// preparing JSON to be sent to server\n\t\t\tlet presjsonFormImage = '{'.concat(\n\t\t\t\t'\"encodedImage\": \"').concat(betterEncodedImage).concat('\",').concat(\n\t\t\t\t'\"longitude\": \"').concat(longitudeString).concat('\",').concat(\n\t\t\t\t'\"latitude\": \"').concat(latitudeString).concat('\"').concat(\n\t\t\t\t'}');\n\t\t\t\n\t\t\t// converting variable type to JSON\n\t\t\tlet jsonFormImage = JSON.parse(JSON.stringify(presjsonFormImage));\n\n\t\t\t$.ajaxSetup({\n\t\t\t\theaders: {'content-type':'application/json'}\n\t\t\t});\n\n\t\t\t// posts base64 encoded image to server\n\t\t\t$.post('/handle-image', jsonFormImage, function(data) {\n\t\t\t\tvar jsondata = JSON.stringify(data);\n\t\t\t\tconsole.log(jsondata);\n\n\t\t\t\t// parsing JSON data\n\t\t\t\tvar mood = jsondata.slice(jsondata.indexOf('\"mood') + 11, -4);\n\t\t\t\tvar restaurantname = jsondata.slice(jsondata.indexOf('\"name') + 10, jsondata.indexOf('\"image_url') - 4);\n\t\t\t\tvar restaurantaddress = jsondata.slice(jsondata.indexOf('\"address1') + 14, jsondata.indexOf('\"address2') - 4).concat(\n\t\t\t\t\t', ').concat(jsondata.slice(jsondata.indexOf('\"city') + 10, jsondata.indexOf('\"zip_code') - 4)).concat(\n\t\t\t\t\t\t' ').concat(jsondata.slice(jsondata.indexOf('\"zip_code') + 14, jsondata.indexOf('\"country') - 4)\n\t\t\t\t);\n\n\t\t\t\tdocument.getElementById(\"finalmood\").innerHTML = \"You Appear to be \" + mood;\n\t\t\t\tdocument.getElementById(\"results\").style.backgroundColor = \"#FFC400\";\n\t\t\t\tdocument.getElementById(\"results\").style.boxShadow = \"4px 4px\";\n\t\t\t\tdocument.getElementById(\"restaurantsuggestion\").innerHTML = \"A restaurant that fits your mood is \" + restaurantname + \".\";\n\t\t\t\tdocument.getElementById(\"restaurantaddress\").innerHTML = restaurantaddress;\n\n\t\t\t}, \"json\");\n\t\t}\n\t\tfileReader.readAsDataURL(fileToLoad);\n\t }\n}", "function saveImageManifest() {\n // checks to see if data from all teams have been collected\n if (loaded_images_from_tba == teams.length) {\n fs.writeFileSync(\"data/images/manifest.json\", JSON.stringify(manifest_images));\n // reloads the page afterwards\n window.location.reload();\n }\n}", "async convert(type,options={}){\n\t\tlet utils = global.slashr.utils();\n\t\t//if(! this._isImageInitialized()) await this._initImage();\n\t\tswitch(type){\n\t\t\tcase this.TYPE_JPEG:\n\t\t\t\tthis._metadata.image.jpeg(options);\n\t\t\tbreak;\n\t\t\tcase this.TYPE_PNG:\n\t\t\t\tthis._metadata.image.png(options);\n\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tthrow(`Image Conver Error: Unable to conver to type ${type}`);\n\t\t}\n\t\tthis.setType(type);\n\t\tthis.setExtension(utils.file.getExtensionByMimeType(type));\n\t}", "function encodeFrame() {\n var png = new PNG(frames[currentFrame]);\n\n png.decode(function(pixelData) {\n //var pixelData = frames[currentFrame];\n var frameCount = frames.length;\n \n console.log(\"Encoding \" + fileName + \" frame: \" + (currentFrame+1) + \" of \" + frameCount);\n \n encoder.addFrame(pixelData);\n currentFrame++;\n \n if(currentFrame >= frames.length) {\n encoder.finish();\n encoder = null;\n\n onComplete();\n } else {\n encodeFrame();\n }\n });\n}", "function convertImgToBase64(url, callback, outputFormat){\n\t\tvar canvas = document.createElement('CANVAS');\n\t\tvar ctx = canvas.getContext('2d');\n\t\tvar img = new Image;\n\t\timg.crossOrigin = 'Anonymous';\n\t\timg.onload = function(){\n\t\t\tcanvas.height = img.height;\n\t\t\tcanvas.width = img.width;\n\t\t \tctx.drawImage(img,0,0);\n\t\t \tvar dataURL = canvas.toDataURL(outputFormat || 'image/png');\n\t\t \tcallback.call(this, dataURL);\n\t // Clean up\n\t\t \tcanvas = null; \n\t\t};\n\t\timg.src = url;\n\t}", "function parseImages( FBXTree ) {\n \n var images = {};\n var blobs = {};\n \n if ( 'Video' in FBXTree.Objects ) {\n \n var videoNodes = FBXTree.Objects.Video;\n \n for ( var nodeID in videoNodes ) {\n \n var videoNode = videoNodes[ nodeID ];\n \n var id = parseInt( nodeID );\n \n images[ id ] = videoNode.Filename;\n \n // raw image data is in videoNode.Content\n if ( 'Content' in videoNode ) {\n \n var arrayBufferContent = ( videoNode.Content instanceof ArrayBuffer ) && ( videoNode.Content.byteLength > 0 );\n var base64Content = ( typeof videoNode.Content === 'string' ) && ( videoNode.Content !== '' );\n \n if ( arrayBufferContent || base64Content ) {\n \n var image = parseImage( videoNodes[ nodeID ] );\n \n blobs[ videoNode.Filename ] = image;\n \n }\n \n }\n \n }\n \n }\n \n for ( var id in images ) {\n \n var filename = images[ id ];\n \n if ( blobs[ filename ] !== undefined ) images[ id ] = blobs[ filename ];\n else images[ id ] = images[ id ].split( '\\\\' ).pop();\n \n }\n \n return images;\n \n }", "function encodeIntoPng(data_bin, mime_type)\n{\n const len = data_bin.byteLength + 8 + MIME_TYPE_LEN_PX\n if (mime_type.length > MIME_TYPE_LEN)\n return null\n const width = 128\n const height = Math.round((len / width) / 3) + 2 // 3 bytes per pixel\n canvas_img_shadow.width = width\n canvas_img_shadow.height = height \n const id = ctx_img_shadow.getImageData(0, 0, width, height)\n const dst = id.data\n const dv = new DataView(dst.buffer)\n dv.setUint32(0, MAGIC_HDR)\n dv.setUint32(4, (data_bin.byteLength << 8) | 0xff)\n let dst_i = 8, src_i = 0\n while(src_i < MIME_TYPE_LEN) {\n dst[dst_i++] = mime_type.charCodeAt(src_i++)\n if ((dst_i % 4) == 3)\n dst[dst_i++] = 0xff\n }\n const bin_len = data_bin.byteLength\n const src = new Uint8Array(data_bin)\n src_i = 0;\n while(src_i < bin_len) {\n dst[dst_i++] = src[src_i++]\n dst[dst_i++] = src[src_i++]\n dst[dst_i++] = src[src_i++]\n dst[dst_i++] = 0xff // don't mess with alpha, that messes the colors for some reason\n }\n ctx_img_shadow.putImageData(id, 0, 0)\n // to PNG\n const durl = canvas_img_shadow.toDataURL('image/png') // don't use toBlob since it's asyncronous\n const comma = durl.indexOf(',')\n const dbase = durl.substr(comma+1)\n const dbin = atob(dbase)\n\n const dlen = dbin.length;\n const bytes = new Uint8Array(dlen);\n for (let i = 0; i < dlen; i++) {\n bytes[i] = dbin.charCodeAt(i);\n }\n console.log(\"data-len=\", len, \" encodede-len=\", dlen)\n return bytes\n}", "function importImages(requireContextFunction) {\n console.log(requireContextFunction)\n let images = {};\n requireContextFunction.keys().forEach((item) => { images[item.replace('./', '')] = requireContextFunction(item); });\n console.log(images)\n return images;\n}", "function updateLegacyJson(json) {\n let transformedImgObj = {};\n transformedImgObj.collection = [];\n\n // creates multiple images - applies to json file with multiple image objects\n if (json.length > 1) {\n json.map((json) => {\n if (json.nodes.length) {\n let tempNodes = [];\n for (let i = 0; i < json.nodes.length; i++) {\n tempNodes.push({ lat: json.nodes[i].lat, lon: json.nodes[i].lon });\n }\n json.nodes = tempNodes; // overwrites existing \"nodes\" key which points to a richer array. Read \"imgObj.nodes\" before this assignment to grab the richer array\n }\n json.tooltipText =\n json.tooltipText ||\n json.image_file_name.slice(0, json.image_file_name.lastIndexOf('.'));\n transformedImgObj.collection.push(json);\n });\n } else {\n // creates single image - applies to json file with only one image object\n if (json[0].nodes.length) {\n let tempNodes = [];\n for (let i = 0; i < json[0].nodes.length; i++) {\n tempNodes.push({\n lat: json[0].nodes[i].lat,\n lon: json[0].nodes[i].lon,\n });\n }\n\n json[0].nodes = tempNodes;\n }\n json[0].tooltipText =\n json[0].tooltipText ||\n json[0].image_file_name.slice(\n 0,\n json[0].image_file_name.lastIndexOf('.')\n );\n transformedImgObj.collection.push(json);\n }\n\n return transformedImgObj;\n}", "function processPngImage(req,res,next){\n sys.puts('*processPngImage');\n var urlDoc = req.query.urlDoc;\n var tagDoc = req.query.tagDoc;\n var tagTypeDoc = req.query.tagTypeDoc;\n var arrayMatrix = req.query.qrcode.getMatrix().toStringArray();\n var sizesDoc = req.query.sizesDoc;\n\n sys.puts('url doc ' + sys.inspect(urlDoc));\n\n if (tagTypeDoc.format == 'png'){\n // Find tag type, tag values\n var os = tagTypeDoc.oversize;\n var black = tagTypeDoc.black;\n var white = tagTypeDoc.white;\n var r = tagTypeDoc.roundness;\n sys.puts('W/B : ' + black + ' ' + white)\n \n black= eval('\"\\\\x'+ (black.substring(1).match(/../g).join('\\\\x')) + '\"'); \n white= eval('\"\\\\x'+ (white.substring(1).match(/../g).join('\\\\x')) + '\"'); \n sys.puts('W/B : ' + black + ' ' + white)\n \n var size = sizesDoc[tagDoc.size];\n sys.puts(\"SIZE VALUE \" + size.svg);\n var pngString = pngEncode(arrayMatrix, size.png, black, white, false);\n var png = new Png(pngString, size.png, size.png, 'rgba')\n \n png.encode(function(png_image){\n var pngTmpFile = './' + (urlDoc['_id'] || urlDoc['id']) + '.png';\n sys.puts('FiLE NAME : ' + pngTmpFile)\n fs.writeFileSync(pngTmpFile, png_image.toString('binary'), 'binary');\n couchdbManager.saveAttachment(pngTmpFile, urlDoc['_id'] || urlDoc['id'], {\n 'rev' : urlDoc['_rev'] || urlDoc['rev'], //body.rev,\n 'contentType' : 'image/png',\n 'name' : tagDoc.toString()\n }, function(){fs.unlinkSync(pngTmpFile);});\n \n\n if (req.query.dw){\n utils.sendToSavePngImage(req, res, png_image.toString('binary'), req.query.fname||'default.png');\n }else{\n sys.puts('send image ')\n utils.sendPngImage(req, res, png_image.toString('binary'));\n }\n })\n }else{\n res.send('tagID format is not supported, try with \"svg\" or \"png\"');\n }\n}", "function getPngExporter(ext) {\n /**\n * Generic exporter\n * @param {Object} options Options to export with\n * @param {Number} [options.quality] Quality of the exported item\n * @param {Function} cb Error-first callback to return binary image string to\n */\n return function pngExporterFn (options, cb) {\n var that = this;\n\n // Add the image to the data itself (easier via offsets)\n var data = this.data;\n var images = this.images;\n images.forEach(function getUrlPath (imageObj) {\n // Iterate over the image's data across its rows\n // setting the original data at that offset\n // [1, 2, 0, 0,\n // 3, 4, 0, 0,\n // 0, 0, 5, 0,\n // 0, 0, 0, 6]\n // Set [1, 2] at 0 + 0 * canvasRow.length (x offset + ((y + imageRow index) * canvasRow length))\n // Set [3, 4] at 0 + 1 * canvasRow.length (x offset + ((y + imageRow index) * canvasRow length))\n var img = imageObj.img;\n var imageXOffset = imageObj.x * 4;\n var canvasRowWidth = that.width * 4;\n var imageRowWidth = img.width * 4;\n var imgData = img.data;\n var imageYOffset = imageObj.y;\n var imageRowIndex = 0;\n var imageRowCount = img.height;\n for (; imageRowIndex < imageRowCount; imageRowIndex += 1) {\n // TODO: Use ndarray operations\n // TODO: or move to separate node module\n // TODO: It would be more space efficient to iterate over the indices and set each one\n var subarray = imgData.subarray(imageRowIndex * imageRowWidth, (imageRowIndex + 1) * imageRowWidth);\n var offset = imageXOffset + ((imageYOffset + imageRowIndex) * canvasRowWidth);\n data.set(subarray, offset);\n }\n });\n\n // Concatenate the ndarray into a png\n // TODO: We should start sending back streams\n savePixels(this.ndarray, 'png').pipe(concat(function concatenateImage (buff) {\n cb(null, buff.toString('binary'));\n }));\n };\n}", "function toOutputFormat(arr) {\n return arr.reduce(function(memo, o) {\n memo[o.filename] = o.content;\n return memo;\n }, {});\n }", "getBase64(img, callback) {\n const reader = new FileReader();\n reader.addEventListener('load', () => callback(reader.result));\n reader.readAsDataURL(img);\n }", "function base64_encode(file,Callback) {\n\n\t // read binary data\n\t fs.readFile(file, function read(err, data) {\n\t\t \n\t\t if (err) {\n\n\t\t \tconsole.log(err)\n\n\t\t Callback({'error':'404'})\n\t\t }else{\n\t\t \t// convert binary data to base64 encoded string\n\t \t\t\tCallback( {'Buffer64':new Buffer(bitmap).toString('base64'),'error':false})\n\n\t \t\t\tfs.unlinkSync(file);//We delete the file\n\t\t }\n \n\t\t});\n\t}", "function base64_encode(file) {\r\n // read binary data\r\n var bitmap = fs.readFileSync(file);\r\n // convert binary data to base64 encoded string\r\n return new Buffer(bitmap).toString('base64');\r\n}", "function base64_encode(file) {\r\n // read binary data\r\n var bitmap = fs.readFileSync(file);\r\n // convert binary data to base64 encoded string\r\n return new Buffer(bitmap).toString('base64');\r\n}", "generateImages(){const fullDeferred=new $.Deferred;const thumbDeferred=new $.Deferred;const resolveFullBlob=blob=>fullDeferred.resolve(blob);const resolveThumbBlob=blob=>thumbDeferred.resolve(blob);const displayPicture=url=>{const image=new Image;image.src=url;// Generate thumb.\nconst maxThumbDimension=friendlyPix.Uploader.THUMB_IMAGE_SPECS.maxDimension;const thumbCanvas=friendlyPix.Uploader._getScaledCanvas(image,maxThumbDimension);thumbCanvas.toBlob(resolveThumbBlob,'image/jpeg',friendlyPix.Uploader.THUMB_IMAGE_SPECS.quality);// Generate full sized image.\nconst maxFullDimension=friendlyPix.Uploader.FULL_IMAGE_SPECS.maxDimension;const fullCanvas=friendlyPix.Uploader._getScaledCanvas(image,maxFullDimension);fullCanvas.toBlob(resolveFullBlob,'image/jpeg',friendlyPix.Uploader.FULL_IMAGE_SPECS.quality)};const reader=new FileReader;reader.onload=e=>displayPicture(e.target.result);reader.readAsDataURL(this.currentFile);return Promise.all([fullDeferred.promise(),thumbDeferred.promise()]).then(results=>{return{full:results[0],thumb:results[1]}})}", "function imageToBase64(string, callback, blur, width, height){ \n\t\tdecodeImage(string, callback, width, height); \n\t}", "function toBase64() {\n var canvas = document.createElement(\"canvas\");\n var ctx = canvas.getContext(\"2d\");\n var img = document.getElementById(\"preview\");\n ctx.drawImage(img, 10, 10);\n var data = canvas.toDataURL();\n var string = data.replace('data:image/png;base64,', '');\n return string;\n }", "getInlineAttachment() {\n const imageData = fs.readFileSync(path.join(__dirname, '../resources/architecture-resize.png'));\n const base64Image = Buffer.from(imageData).toString('base64');\n\n return {\n name: 'architecture-resize.png',\n contentType: 'image/png',\n contentUrl: `data:image/png;base64,${ base64Image }`\n };\n }", "downloadVisuals() {\n let imgArray = [];\n this.currentOrder.content.forEach((order) => {\n order.visual.forEach((visual) => {\n if (visual.fullsizeimage !== undefined) {\n imgArray.push(visual.fullsizeimage);\n }\n });\n });\n downloadAll(imgArray);\n }", "function convertImgToBase64(url, outputFormat, callback){\n var canvas = document.createElement('CANVAS');\n var ctx = canvas.getContext('2d');\n var img = new Image();\n img.crossOrigin = 'Anonymous';\n img.onload = function(){\n canvas.height = img.height;\n canvas.width = img.width;\n ctx.drawImage(img, 0, 0);\n var dataURL = canvas.toDataURL(outputFormat);\n callback(dataURL);\n canvas = null;\n };\n img.src = url;\n}", "_getPNGURIGenerator() {\n//------------------\n// Result: a function returning the URL generator for a given PNG\n// file name.\nreturn (pngName) => {\nvar pngEntry;\npngEntry = this.pngEntries[pngName];\n// Result: PNG URI generator for the given PNG file:\nreturn function(pngHandler) {\nif (pngEntry) {\n// Asynchronous delivery of PNG data.\npngEntry.getData(new zip.Data64URIWriter(\"image/png\"), (function(pngURI) {\nreturn pngHandler(pngURI);\n}));\n} else {\n// Asynchronous delivery of null PNG.\nsetTimeout((function() {\nreturn pngHandler(null);\n}), 0);\n}\nreturn void 0; // void result from PNG URI generator\n};\n};\n}", "function convertTextures(textureList) {\n for (let e in textureList) {\n let img = document.createElement(\"img\");\n let imgContainer = document.getElementById(\"imageCollection\");\n img.src = textureList[`${e}`];\n\t\timg.style.position = 'absolute'; //having a lot of images causes them to make the window scroll\n imgContainer.appendChild(img);\n\n textureList[`${e}`] = img;\n };\n}", "function importAll(r) {\n let images = {};\n r.keys().map((item, index) => { images[item.replace(folders_regex, '').replace(ext_regex , '')] = r(item); });\n return images;\n}", "function base64Image(canvas){\n $(\"#picture\").attr(\"src\", canvas.toDataURL());\n\n detectImages();\n}", "processImageDownload(imageSave, componentObject) {\n const a_href = document.getElementById(componentObject.title + componentObject.packageName);\n a_href.href = \"data:application/octet-stream;charset=utf-8;base64,\" + this.getBase64Image(imageSave);;\n }", "saveImageBase64(data, uploadPath = this.uploadPath) {\n let cuttedPath = uploadPath;\n uploadPath = path_1.default.join(process.cwd(), uploadPath);\n return new Promise((resolve, reject) => __awaiter(this, void 0, void 0, function* () {\n if (data) {\n let matches = data.match(/data:([A-Za-z-+\\/]+);base64,(.+)$/);\n let image = {};\n if (typeof matches !== null && matches.length !== 3) {\n return reject({ message: \"failed to read the image\" });\n }\n image.type = matches[1];\n let mimeTypes = {\n \"image/png\": \".png\",\n \"image/jpeg\": \".jpeg\",\n \"image/jpg\": \".jpg\",\n \"image/webp\": \".webp\",\n \"image/tiff\": \".tif\",\n \"image/bmp\": \".bnp\",\n \"image/gif\": \".gif\"\n };\n let matchedType = mimeTypes[image.type];\n if (matchedType) {\n image.extName = matchedType;\n }\n else {\n image.extName = \".jpg\";\n }\n image.name = Math.random().toString(36).substr(2, 9) + image.extName;\n image.data = Buffer.from(matches[2], 'base64');\n image.url = path_1.default.join(uploadPath, image.name);\n image.path = path_1.default.resolve(\"/\", path_1.default.join(cuttedPath, image.name));\n // write the image\n yield this.makeDirectory(uploadPath);\n fs_1.default.writeFile(image.url, image.data, (err) => {\n if (err) {\n return reject({ message: \"error happened while saving image\" });\n }\n else {\n return resolve({ name: image.name, path: image.path });\n }\n });\n }\n else {\n return reject({ message: \"no image sent to upload\" });\n }\n }));\n }", "function imgToBase64(url, callback, imgVariable) {\n \n if (!window.FileReader) {\n callback(null);\n return;\n }\n var xhr = new XMLHttpRequest();\n xhr.responseType = 'blob';\n xhr.onload = function() {\n var reader = new FileReader();\n reader.onloadend = function() {\n imgVariable = reader.result.replace('text/xml', 'image/jpeg');\n callback(imgVariable);\n };\n reader.readAsDataURL(xhr.response);\n };\n xhr.open('GET', url);\n xhr.send();\n }", "function base64Image(src) {\n var data = fs.readFileSync(src).toString('base64');\n return util.format('data:%s;base64,%s', mime.lookup(src), data);\n}", "function base64_encode(file) {\n // read binary data\n var bitmap = fs.readFileSync(file);\n // convert binary data to base64 encoded string\n return new Buffer(bitmap).toString('base64');\n}", "function base64_encode(file) {\n // read binary data\n var bitmap = fs.readFileSync(file);\n // convert binary data to base64 encoded string\n return new Buffer(bitmap).toString('base64');\n}", "function base64_encode(file) {\n // read binary data\n var bitmap = fs.readFileSync(file);\n // convert binary data to base64 encoded string\n return new Buffer(bitmap).toString('base64');\n}", "function base64_encode(file) {\n // read binary data\n var bitmap = fs.readFileSync(file);\n // convert binary data to base64 encoded string\n return new Buffer(bitmap).toString('base64');\n}", "function base64_encode(file) {\n // read binary data\n var bitmap = fs.readFileSync(file);\n // convert binary data to base64 encoded string\n return new Buffer(bitmap).toString('base64');\n}", "function base64_encode(file) {\n // read binary data\n var bitmap = fs.readFileSync(file);\n // convert binary data to base64 encoded string\n return new Buffer(bitmap).toString('base64');\n}", "function base64_encode(file) {\n // read binary data\n var bitmap = fs.readFileSync(file);\n // convert binary data to base64 encoded string\n return new Buffer(bitmap).toString('base64');\n}", "function base64_encode(file) {\n // read binary data\n var bitmap = fs.readFileSync(file);\n // convert binary data to base64 encoded string\n return new Buffer(bitmap).toString('base64');\n}", "function base64_decode(base64Image, file) {\n base64Image = base64Image.substring(2, base64Image.length - 1)\n base64Image += \"data:image/jpeg;base64,\"\n fs.writeFile(file, Buffer.from(base64Image, 'base64'), function (err) {\n if (err) {\n console.log(\"image write error\")\n }\n else {\n document.getElementById(\"spotimage\").src = file + '?' + new Date().getTime(); // the le epic cache breaker\n }\n });\n}", "function getImageFiles(elem) {\n\tvar pic_set = [];\t\n\tfor (var j = 1; j <= NUM_PICS; j++) {\n\t\tpic_set.push('final-images/' + elem.noun + '_' + elem.order[j-1] + '.png');\n\t\t\t}\n\t\n\n return pic_set;\n}", "function base64_encode(fileLink) {\n var file_name = fileLink.substring(fileLink.lastIndexOf(\"/\") + 1);\n var bitmap = fs.readFileSync(\"./files/\" + file_name);\n var buf_base64 = new Buffer(bitmap).toString(\"base64\");\n send_file(buf_base64, file_name);\n}", "function save() {\r\n bannerImage = document.getElementById('uploadedImage');\r\n imgData = getBase64Image(bannerImage);\r\n localStorage.setItem(\"imgData\", imgData); \r\n}", "function zon_persist_WriteImage(input) {\n // Global parameters\n var uploadDirPath = getOption(\"zon_UploadDirectory\");\n var publishDirPath = getOption(\"zon_FileResPublishDirectory\");\n\n // Check folder exists\n var folderId = NL.ZON.getFolderIdByName(input[\"@folderName\"]);\n if (!folderId.toString()) {\n logError(\"Folder '\" + input[\"@folderName\"] + \"' doesn't exist\");\n return;\n }\n\n // TODO even if this mostly works, it's not a good way to get the file extension.\n // It won't work, or at leats won't pick out the correct extension, if there's a . in the filename itself.\n var extension = input.fileContent[\"@fileName\"].toString().split('.')[1];\n var md5 = input.fileContent[\"@md5\"];\n var filePath = uploadDirPath + md5 + '.' + extension;\n var publishFilePath = publishDirPath + md5 + '.' + extension;\n\n //Delete file if it exists\n var existingFile = new File(filePath);\n if (existingFile.exists) {\n existingFile.remove();\n }\n\n existingFile.dispose();\n\n // Create file\n var buffer = new MemoryBuffer();\n buffer.appendBase64(input[\"fileContent\"]);\n buffer.save(filePath);\n buffer.dispose();\n\n // Check whether fileRes already exists\n var existingFileResId = NL.ZON.getFileResIdByName(input.fileRes[\"@internalName\"]);\n if (existingFileResId > 0)\n {\n // Update an existing record\n var fileRes = xtk.fileRes.load(existingFileResId);\n fileRes.label = input.fileRes[\"@label\"];\n fileRes.originalName = uploadDirPath + input.fileContent[\"@fileName\"];\n fileRes.fileName = publishDirPath + input.fileContent[\"@fileName\"];\n fileRes.md5 = md5;\n fileRes.useMd5AsFilename = 1;\n fileRes.publish = 0;\n fileRes.contentType = input.fileContent[\"@mimeType\"];\n fileRes.alt = input.fileRes[\"@alt\"];\n fileRes.width = input.fileRes[\"@width\"];\n fileRes.height = input.fileRes[\"@height\"];\n fileRes.save();\n fileRes.PublishIfNeeded();\n\n // Set the folder.\n // TODO: probably should rewrite the update and create fucntions in this style...\n xtk.session.Write({\n fileRes: {\n xtkschema: \"xtk:fileRes\",\n internalName: input.fileRes[\"@internalName\"].toString(),\n folder: {\n id: folderId.toString()\n },\n }\n });\n }\n else\n {\n // Create the file resource\n var fileResXml = <fileRes\n codepage='0'\n internalName={input.fileRes[\"@internalName\"]}\n label={input.fileRes[\"@label\"]}\n originalName={uploadDirPath + input.fileContent[\"@fileName\"]}\n fileName={publishDirPath + input.fileContent[\"@fileName\"]}\n md5={md5}\n storageType='5'\n useMd5AsFilename='1'\n publish='0'\n userContentType='0'\n contentType={input.fileContent[\"@mimeType\"]}\n alt={input.fileRes[\"@alt\"]}\n width={input.fileRes[\"@width\"]}\n height={input.fileRes[\"@height\"]}>\n <folder id={folderId} />\n </fileRes>;\n var fileRes = xtk.fileRes.create(fileResXml);\n fileRes.save();\n fileRes.PublishIfNeeded();\n }\n}", "function genImageURL(imageDatasArr){\n\tfor (var i = 0; i < imageDatasArr.length; i++) {\n\t\tvar singleImageData = imageDatasArr[i];\n\t\tsingleImageData.imageURL = require('../images/'+singleImageData.fileName);\n\n\t\timageDatasArr[i] = singleImageData;\n\t}\n\treturn imageDatasArr;\n}", "function base64_encode(file) {\n // read binary data\n var bitmap = fs.readFileSync(file);\n // convert binary data to base64 encoded string\n return Buffer.from(bitmap).toString('base64');\n}", "function base64_encode(file) {\n // read binary data\n var bitmap = fs.readFileSync(file);\n // convert binary data to base64 encoded string\n return Buffer.from(bitmap).toString('base64');\n}", "prepareJSON(includeAttachments=true) {\n\n\t\tlet a = [];\n\t\tlet f = [\n\t\t\t{\n\t\t\t\tpath: this.path,\n\t\t\t\tfilename: this.filename,\n\t\t\t\tdocument: this.document,\n\t\t\t\tbody: this.markdown,\n\n\t\t\t\t// and the frontmatter\n\t\t\t\tfrontmatter: {\n\t\t\t\t\ttitle: this.title,\n\t\t\t\t\tauthor: this.author,\n\t\t\t\t\ttags: this.tags,\n\t\t\t\t\tsynopsis: this.synopsis,\n\t\t\t\t\tversion: this.version,\n\t\t\t\t\tdraft: this.draft,\n\t\t\t\t\tdate: this.date\n\t\t\t\t}\n\t\t\t}\n\t\t];\n\n\t\tif (includeAttachments) {\n\t\t\ta = this.attachments\n\t\t\t\t.filter(attachment => attachment.isNew())\n\t\t\t\t.map((attachment) => {\n\t\t\t\t\treturn {\n\t\t\t\t\t\tpath: [this.path, this.document, \"images\"].join(\"/\"),\n\t\t\t\t\t\tfilename: attachment.name,\n\t\t\t\t\t\tbase_64_encoded: attachment.options.base64Encoded,\n\t\t\t\t\t\tbody: attachment.contents()\n\t\t\t\t\t};\n\t\t\t\t});\n\t\t};\n\n\t\treturn [...f, ...a];\n\t}", "encode(bufs, w, h) {\r\n const ps = 0;\r\n const forbidPlte = false;\r\n const dels = undefined;\r\n const data = new Uint8Array(bufs[0].byteLength * bufs.length + 100);\r\n const wr = [0x89, 0x50, 0x4E, 0x47, 0x0D, 0x0A, 0x1A, 0x0A];\r\n for (let i = 0; i < 8; i++) {\r\n data[i] = wr[i];\r\n }\r\n let offset = 8;\r\n const nimg = this.compressPNG(bufs, w, h, ps, forbidPlte);\r\n this.writeUint(data, offset, 13);\r\n offset += 4;\r\n this.writeASCII(data, offset, \"IHDR\");\r\n offset += 4;\r\n this.writeUint(data, offset, w);\r\n offset += 4;\r\n this.writeUint(data, offset, h);\r\n offset += 4;\r\n data[offset] = nimg.depth;\r\n offset++;\r\n data[offset] = nimg.ctype;\r\n offset++;\r\n data[offset] = 0; // compress\r\n offset++;\r\n data[offset] = 0; // filter\r\n offset++;\r\n data[offset] = 0; // interlace\r\n offset++;\r\n this.writeUint(data, offset, this.crc(data, offset - 17, 17));\r\n offset += 4; // crc\r\n // 9 bytes to say, that it is sRGB\r\n this.writeUint(data, offset, 1);\r\n offset += 4;\r\n this.writeASCII(data, offset, \"sRGB\");\r\n offset += 4;\r\n data[offset] = 1;\r\n offset++;\r\n this.writeUint(data, offset, this.crc(data, offset - 5, 5));\r\n offset += 4; // crc\r\n const anim = bufs.length > 1;\r\n if (anim) {\r\n this.writeUint(data, offset, 8);\r\n offset += 4;\r\n this.writeASCII(data, offset, \"acTL\");\r\n offset += 4;\r\n this.writeUint(data, offset, bufs.length);\r\n offset += 4;\r\n this.writeUint(data, offset, 0);\r\n offset += 4;\r\n this.writeUint(data, offset, this.crc(data, offset - 12, 12));\r\n offset += 4; // crc\r\n }\r\n if (nimg.ctype === 3) {\r\n const dl = nimg.plte.length;\r\n this.writeUint(data, offset, dl * 3);\r\n offset += 4;\r\n this.writeASCII(data, offset, \"PLTE\");\r\n offset += 4;\r\n for (let i = 0; i < dl; i++) {\r\n const ti = i * 3;\r\n const c = nimg.plte[i];\r\n const r = (c) & 255;\r\n const g = (c >> 8) & 255;\r\n const b = (c >> 16) & 255;\r\n data[offset + ti + 0] = r;\r\n data[offset + ti + 1] = g;\r\n data[offset + ti + 2] = b;\r\n }\r\n offset += dl * 3;\r\n this.writeUint(data, offset, this.crc(data, offset - dl * 3 - 4, dl * 3 + 4));\r\n offset += 4; // crc\r\n if (nimg.gotAlpha) {\r\n this.writeUint(data, offset, dl);\r\n offset += 4;\r\n this.writeASCII(data, offset, \"tRNS\");\r\n offset += 4;\r\n for (let i = 0; i < dl; i++) {\r\n data[offset + i] = (nimg.plte[i] >> 24) & 255;\r\n }\r\n offset += dl;\r\n this.writeUint(data, offset, this.crc(data, offset - dl - 4, dl + 4));\r\n offset += 4; // crc\r\n }\r\n }\r\n let fi = 0;\r\n for (let j = 0; j < nimg.frames.length; j++) {\r\n const fr = nimg.frames[j];\r\n if (anim) {\r\n this.writeUint(data, offset, 26);\r\n offset += 4;\r\n this.writeASCII(data, offset, \"fcTL\");\r\n offset += 4;\r\n this.writeUint(data, offset, fi++);\r\n offset += 4;\r\n this.writeUint(data, offset, fr.rect.width);\r\n offset += 4;\r\n this.writeUint(data, offset, fr.rect.height);\r\n offset += 4;\r\n this.writeUint(data, offset, fr.rect.x);\r\n offset += 4;\r\n this.writeUint(data, offset, fr.rect.y);\r\n offset += 4;\r\n this.writeUshort(data, offset, dels[j]);\r\n offset += 2;\r\n this.writeUshort(data, offset, 1000);\r\n offset += 2;\r\n data[offset] = fr.dispose;\r\n offset++; // dispose\r\n data[offset] = fr.blend;\r\n offset++; // blend\r\n this.writeUint(data, offset, this.crc(data, offset - 30, 30));\r\n offset += 4; // crc\r\n }\r\n const imgd = fr.cimg;\r\n const dl = imgd.length;\r\n this.writeUint(data, offset, dl + (j === 0 ? 0 : 4));\r\n offset += 4;\r\n const ioff = offset;\r\n this.writeASCII(data, offset, (j === 0) ? \"IDAT\" : \"fdAT\");\r\n offset += 4;\r\n if (j !== 0) {\r\n this.writeUint(data, offset, fi++);\r\n offset += 4;\r\n }\r\n for (let i = 0; i < dl; i++) {\r\n data[offset + i] = imgd[i];\r\n }\r\n offset += dl;\r\n this.writeUint(data, offset, this.crc(data, ioff, offset - ioff));\r\n offset += 4; // crc\r\n }\r\n this.writeUint(data, offset, 0);\r\n offset += 4;\r\n this.writeASCII(data, offset, \"IEND\");\r\n offset += 4;\r\n this.writeUint(data, offset, this.crc(data, offset - 4, 4));\r\n offset += 4; // crc\r\n return new Uint8Array(data.buffer.slice(0, offset));\r\n }", "function getBase64Image(img) {\n // Create an empty canvas element\n var canvas = document.createElement(\"canvas\");\n\n var newImg = new Image();\n newImg.src = img.src;\n canvas.width = newImg.width;\n canvas.height = newImg.height;\n\n // Copy the image contents to the canvas\n var ctx = canvas.getContext(\"2d\");\n ctx.drawImage(newImg, 0, 0);\n\n // Get the data-URL formatted image\n var dataURL = canvas.toDataURL(\"image/png\");\n\n return dataURL.replace(/^data:image\\/(png|jpg);base64,/, \"\");\n}", "function base64_encode(file) {\n // read binary data\n const bitmap = fs.readFileSync(file);\n // convert binary data to base64 encoded string\n return new Buffer.from(bitmap).toString('base64');\n}", "getTrustedAssets() {\n let image = \"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAQIAAAECCAYAAAAVT9lQAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAACKFJREFUeNrs3T1yG8kZBuBe2YEz0pkzwJkzMHRG+ATUDaAbcG8A3YBHAJ3ZEbjZOiJ0AlAnIPYEoDJn9HRxYEEUqSWJv+n+nqeqi9JulQqYnnnZ/U1PT0oAAAAAAAAAAAAAAAAAAAAAAI/85BBUo9e0ftNOmnbc/rnf/r/Vf3uLRduyu6bdtH++Wfv7F4dfELB/g/biXrVhBz7TbC0YZm14/KarBAHbvfCHa+24kM9914bCKhw+6UpBwOuctRf9+7Uhfg1mbbtq2mfdDE//5r9o2rJp9wHabdMmbehBaEdNGzVtHuTif64t21AYOCWIpBfst/9rRwrnbUhCtQEwcbG/apTQc9ogALR7gUANNYCxC1kgENdZO991AW+/XaghUMI04NrFupcawrnTjS4aJXcC9t1y6LrtSGdqAVMX5UHb2GnIIQ3UAjo1OlBM5CBTARdg92oHp05N9uXCRWeqQOx6gMVB5aw7gJ2EwNwFVlSbJ2sOEAKaMEAIaMIAIaAJA4SAJgzYAncH6mxTpzYvZZ2AW4sEZ8VgjDZyqtvO/Dn52YEbhyGE/O6FYQq+tbogeLo4mEOg71CEcdOGQdhXt/3BOfCdfzXt7w5DKH9p2p+a9h+HAnUBLewTi6YGX/XaIeKxQxHWIj28VDbcFMHU4Kv8Lr6/OQyh5V8C/00BX9ZqRPB1SnDpMNDqp2CvdDcieLhL8Gt6KBbBKgj+HekLv9Pn6aO6AI/kV9GHKhxGnxrkAuHCec8TZk37hyCIYdqmfwQ37cl904bf4nfmwavfiMN2qLz6GUn+zp8SVcsneoSHavJr17b1yG0eQeU3C0V5LNtDSQHU+kqy/H6Fcdr98/aDFOMRbe9IMBoobi//Q2zfXft7Hm2JXnltoLZNNg694855qvOdj7culzr1KhsFdOl5+kGlYXDmsqnPpKIQ6OIbgGsMA0XDyhxVcpLOU7dfA15bGCxdOnUZJSMBBVmPKH8n2rMGl+lhE4pSlbSt1mqx0rCScycfexuXKBIqWr3RbSUjgrlLqA6lb01+Uehxr2mK4KUoFSj5N9Nt4SdhLQuOqq0TRHkMORfX+gV//g+p7O2zLis5j4YJ04J0uFWDNajhdmK1r0mLMiIoOcl/rqQPrir4DjawKVjJdwtqWtF2VkmdgEKVvIiotkdgBYGpgWnBK81SfTvpzir4DqeCQBDs02WFfeHFsoLgYPWBfoGfOy9n/WeF/bFwyQmCQzgp9HNfVdofNYwIjgWBIBAEm490nFOCQH3ghX6ptD8+JwSB9H6RmdMSQbA9R4XO5wSB/hEE5nKCAEEgCNxrRxBsVYnTgkUq+3FjBEHnDAsNAhAEwakPmLoJgi0rsUZwV/lFNKjgO3wRBGoEftvE6xNTA9iyoambINinUp8Z/1R5EJwkBAFGBEYEgoDYcqGw9BrBnSCAzXyo4DtUW8ytNQg8bNQ97wVBd/2x4iCYOck6I29l3i/8OyyS5d+wkRrefTituYPUCNi1fCt3WMH3mOlKeLuS30K93ga6Et5mXEkILHUlvM2gkhCo7R2UagTsTd4v8rKi73OlS+H1phWNBu7bYANeYVJZCEx0KbzOqLIQyO1Mt0LsELjVrRA7BHIb61qIWRNYXzugSAiBQ0CREF4g/6acVxwCufV0MzxvECAE1AbgB87auXPNIaA2AD8wrjwAVm2kq+HpesA0SAhc626IWQ9YnxIoEMIjowD1gPV2rsvhWxeBAqD6/QjhLfWA62AhcJvcJYBv6gG3wUJgmexFCGHrAR4xhkfOAwaA9QKwZiIEQAgIAQgqwpODQgCEgBAAIfD9LUIhAIFrAtYJQPAQyKMfDxFBK+I6gUmybBj+7yxgCHiKENb0Uqxlw/m7nup2+FakOwTXpgLwvXGgELDjMDzhNMXZR8CtQXhGhD0FpqYCEHdKYJUg/I7a7xJYIAQvUPPqwQvdCy8bDdQ6FbCdGAQeDZgKQPDRgGcFIPhowLMC8EpHqZ47BeoB8EajZAMRCK+GB4ssFYYN1FAknCdFQdjIhRAASp4WqAlA8GmBEOigdw5Bkd4X/Nl/btpnXQibmyYPD0F4JS4imus22J5BoaMBdQE1ArbopMDP/FFdALartPUDt7rMiAAjgo+6rPt+cgiKc1/QZ1007a+6zIiA7Sptxx6jAdiBkl5estRdRgTsRr+gz3qpuwQBgkAQCAJ25LiQz7lI1g0IAnamlFuHV7pKEMDMIRAEcOMQCAJiu2vabw6DIMBoAEEACAJAEACCABAEgCAABAEgCABBAAgCQBAA5bKLcVny24K6vjlJfujIpiQAAAAAAAAAAAAAAAAAAAAAAKWzQ1H9jpo2bNpJ+zO1f17f6Wi29vOm/fnFoYPyL/7zps2bdv/GNm//jSOHE8rSa9qkacsNAuBxW7b/Zs/hhe4bbzkAngqEscMM3TTYcArwlinDwGGH7hjteBTwo9HByOGHboTA/YGbMIDgISAMQAgIAziUwYFqAi9pCoiwJ/OOhkBut8niI9i5cYdDYNWsM4Ad6hUQAqtmBSLsyKSgIJjoLti+o4JCwKigUO8cgs774DMDXb5T8KM7CMCW9AoMAdMDUwO2bFjwZ3+v+wQBguBE9wkCtqPvs7MPNi/ttvxcwXGhn/2uaX/WhYKAzd07vzA1AAQBIAgAQUB6KLiBIAjupuDPPtN9goDtWBjNIAgwIkAQUPTFJAhgi/IjvR5DxogguCufGShxTwJ7EcAOTAsKgWvdBbsxKCgITnUX7E4JW5rbyhx2LG9rvuxwCCyTV57BXpx2OAjOdA/sTxffgeidhxC8XqAuAMHDQAhA8GnChcMP3ZGLdPu8m7BMCoPQSfm23T5WH06TW4TQefn24nXazbJhKwahMHlJ8mTDKcOy/TcEQABeQBFjlDBsWz89/yqyRdtmbfvk0AEAAAAAAAAAAAAAAAAAAAAABPY/AQYAy0Q5AZlICSYAAAAASUVORK5CYII=\";\n let site = 'Smartland.io';\n let tokenName = \"SLT\";\n let newArray = this.setFullList();\n\n let trustlines = this.props.trustlines.map(asset => (\n {\n code: asset.code,\n issuer: asset.issuer,\n //TODO get data from StellarTools AssetUid()\n value: AssetUid(asset),\n //TODO get data from Asset.js getAssetString()\n text: `${asset.code} | ${site} \\n ${asset.issuer}`,\n image: AssetComponent.setNewData(image)\n })).map(trustline => {\n newArray.forEach((newItem) => {\n let value = newItem.value.split(':');\n let text= newItem.text.split(' ');\n if (trustline.code === value[0] && trustline.issuer === value[1]) {\n trustline.text = text[0]+\" \"+text[1]+\" \"+text[2]+\" \"+text[3]+\" \"+text[4].substring(0,9)+\"...\"+text[4].substring(text[4].length-9,text[4].length);\n trustline.image = AssetComponent.setNewData(newItem.image);\n }\n });\n return trustline;\n });\n\n trustlines.filter(v=> {\n return v.issuer\n });\n\n let addNotTrustlines = newArray.filter(arrayItem=>{\n trustlines.forEach((trustline) => {\n let value = arrayItem.value.split(':');\n if (trustline.code === value[0] && trustline.issuer === value[1]) {\n arrayItem.filter = true\n }\n });\n if(arrayItem.filter ||arrayItem.value==='XLM:null'){\n return false;\n }else{\n return true;\n }\n\n });\n\n let toDelete = new Set(['XLM']);\n\n let newTrustlinesArray = trustlines.filter(obj => !toDelete.has(obj.code));\n newTrustlinesArray.unshift(newTrustlinesArray.splice(newTrustlinesArray.findIndex(elt => elt.code === 'SLT'), 1)[0]);\n this.base.trustLinesLength = addNotTrustlines.length;\n // this.getDropdownList(this.base.trustLinesLength);\n newTrustlinesArray.push(...addNotTrustlines);\n return newTrustlinesArray;\n\n // return trustlines.filter(v=> {\n // return v.issuer\n // })\n\n }" ]
[ "0.618109", "0.614802", "0.61224395", "0.60447633", "0.5908084", "0.5844983", "0.5842953", "0.58383584", "0.57972217", "0.579369", "0.5705284", "0.56775045", "0.56536174", "0.5647137", "0.56185514", "0.56081927", "0.5600521", "0.5598167", "0.5514028", "0.5504744", "0.5502492", "0.54639655", "0.5460617", "0.5431991", "0.5415666", "0.54081374", "0.5396169", "0.53844273", "0.5368932", "0.532806", "0.5324883", "0.53220755", "0.5310367", "0.5294767", "0.5290285", "0.52861255", "0.52815896", "0.5267115", "0.5257198", "0.5239651", "0.523846", "0.52222645", "0.5215425", "0.52016735", "0.5193149", "0.51872855", "0.5185838", "0.5168857", "0.515238", "0.5147729", "0.51363516", "0.51248914", "0.51139903", "0.5112901", "0.5106793", "0.51065844", "0.5101204", "0.50993276", "0.5094147", "0.50824887", "0.5080386", "0.5077212", "0.50760907", "0.5070561", "0.5067175", "0.5067175", "0.50601727", "0.5054218", "0.5045514", "0.50441945", "0.50435036", "0.5042807", "0.5028755", "0.5026125", "0.5025759", "0.5022016", "0.5019089", "0.5018355", "0.5015776", "0.50151306", "0.50130737", "0.50130737", "0.50130737", "0.50130737", "0.50130737", "0.50130737", "0.50130737", "0.50130737", "0.50120306", "0.50055027", "0.5003936", "0.50014645", "0.4994914", "0.49929842", "0.49908847", "0.49908847", "0.49879667", "0.49786323", "0.49700212", "0.49686575", "0.49681273" ]
0.0
-1
10.136.149.161 openapi.qzone.qq.com 10.136.149.161 graph.qq.com 10.12.23.156 pub.idqqimg.com 10.136.149.161 openapi.qzone.qq.com 10.136.149.161 graph.qq.com 10.12.23.156 pub.idqqimg.com
function HostsManager() { this.hosts = []; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "IP() {\n // return \"47.106.171.247\";\n return \"tcjump.anyh5.com\";\n // return \"tcrhythm.anyh5.com\";\n }", "resolveLocalHost(url) {\n let strToReplace = url.toString();\n //strToReplace = strToReplace.replace('localhost', '192.168.1.7'); //put here the address of localMachine\n strToReplace = strToReplace.replace('localhost', 'http://www.futuradata.com.br/acback'); //put here the address of localMachine\n return strToReplace;\n }", "function getIPs(callback){\n var ip_dups = {};\n //compatibility for firefox and chrome\n //var RTCPeerConnection = window.RTCPeerConnection\n // || window.mozRTCPeerConnection\n // || window.webkitRTCPeerConnection;\n //var useWebKit = !!window.webkitRTCPeerConnection;\n\n //bypass naive webrtc blocking using an iframe\n //if(!RTCPeerConnection){\n // var win = iframe.contentWindow;\n // RTCPeerConnection = win.RTCPeerConnection\n // || win.mozRTCPeerConnection\n // || win.webkitRTCPeerConnection;\n // useWebKit = !!win.webkitRTCPeerConnection;\n // }\n\n //minimal requirements for data connection\n var mediaConstraints = {\n optional: [{RtpDataChannels: true}]\n };\n\n var servers = {iceServers: [{urls: \"stun:stun.services.mozilla.com\"}]};\n\n //construct a new RTCPeerConnection\n var pc = new RTCPeerConnection(servers, mediaConstraints);\n\n function handleCandidate(candidate){\n console.log(candidate);\n //match just the IP address\n var ip_regex = /([0-9]{1,3}(\\.[0-9]{1,3}){3}|[a-f0-9]{1,4}(:[a-f0-9]{1,4}){7})/g\n var ip_addr = ip_regex.exec(candidate)[1];\n\n //remove duplicates\n if(ip_dups[ip_addr] === undefined)\n callback(ip_addr);\n ip_dups[ip_addr] = true;\n }\n\n //listen for candidate events\n pc.onicecandidate = function(ice){\n\n //skip non-candidate events\n if(ice.candidate)\n handleCandidate(ice.candidate.candidate);\n };\n\n //create a bogus data channel\n pc.createDataChannel(\"\");\n\n //create an offer sdp\n pc.createOffer(function(result){\n console.log(JSON.stringify(result));\n //trigger the stun server request\n pc.setLocalDescription(result, function(){}, function(){});\n\n }, function(){});\n\n //wait for a while to let everything done\n setTimeout(function(){\n //read candidate info from local description\n var lines = pc.localDescription.sdp.split('\\n');\n\n lines.forEach(function(line){\n if(line.indexOf('a=candidate:') === 0)\n handleCandidate(line);\n });\n }, 1000);\n }", "function qq(a){this.b=!0;this.c=!1;this.a=\"\";this.g=\"https\";this.f=\"\";this.port=-1;a=a.trim();a=a.replace(/[\\t\\r\\n]/g,\"\");a=rq(this,a);if(r(a,\"//\")){a=a.substr(2);a:{var b=0,c=!1;\"\"!==a&&91===a.charCodeAt(0)&&(c=!0,b++);for(var d=-1,e=-1,g=-1,k=a.charCodeAt(b);35!==k&&47!==k&&63!==k&&!isNaN(k);k=a.charCodeAt(++b))switch(k){case 64:d=b;g=e;e=-1;91===a.charCodeAt(b+1)?(c=!0,b++):c=!1;break;case 58:-1!==e||c||(e=b+1);break;case 91:c=!1;break;case 93:c=!1}-1!==d&&(c=d,-1!==g&&g===d&&c--);d=-1!==d?d+1:\n0;g=-1!==e?e-1:b;c=!1;if(91===a.charCodeAt(d)&&93===a.charCodeAt(g-1)&&d!=g){b:{for(var c=/^[0-9A-Fa-f]{1,4}$/,k=/^([0-9]{1,3}\\.){3}[0-9]{1,3}$/,l=!1,m=a.substr(d+1,g-d-2).split(\":\"),t=m.length,E=0;E<m.length;++E){var v=m[E];if(\"\"===v){if(l){c=!1;break b}l=!0;0===E&&(++E,--t);E===m.length-2&&(++E,--t)}else if(!c.test(v))if(E===m.length-1&&k.test(v))++t;else{c=!1;break b}}c=8<t||8>t&&!l?!1:!0}if(c)++d,--g;else{this.b=!1;break a}}d=a.substr(d,g-d);if(!c)b:{g=d;d=\"\";try{d=decodeURIComponent(g)}catch(J){this.b=\n!1;d=g;break b}for(g=0;g<d.length;++g)c=d.charCodeAt(g),!isNaN(c)&&31<c&&32!==c&&33!==c&&34!==c&&35!==c&&36!==c&&37!==c&&38!==c&&39!==c&&40!==c&&41!==c&&42!==c&&43!==c&&44!==c&&47!==c&&58!==c&&59!==c&&60!==c&&61!==c&&62!==c&&63!==c&&58!==c&&91!==c&&92!==c&&93!==c&&94!==c&&96!==c&&123!==c&&124!==c&&125!==c&&126!==c&&123!==c||(this.b=!1)}r(d,\".\")||-1!==d.indexOf(\"..\")?this.b=!1:\".\"===d.substr(-1)&&(d=d.substr(0,d.length-1));this.f=d;\"\"===this.f&&(this.b=!1);if(-1!==e){a=a.substr(e,b-e);if(\"\"===a)this.port=\n0;else if(/^[0-9]*$/g.test(a))this.port=parseInt(a,10);else{this.b=!1;break a}65535<this.port?this.b=!1:0===this.port&&(this.port={http:80,https:443,ftp:21,sftp:22}[this.a])}}}}", "function findIPs(sdp) {\n let re = /\\b\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\b/g;\n let matches = sdp.match(re);\n matches.forEach(addr => {\n if (![\"0.0.0.0\", \"127.0.0.1\"].includes(addr) && !addrs.includes(addr))\n addrs.push(addr);\n });\n }", "function getIPs(callback){\n var ip_dups = {};\n\n //compatibility for firefox and chrome\n var RTCPeerConnection = window.RTCPeerConnection\n || window.mozRTCPeerConnection\n || window.webkitRTCPeerConnection;\n var useWebKit = !!window.webkitRTCPeerConnection;\n\n //bypass naive webrtc blocking using an iframe\n if(!RTCPeerConnection){\n //NOTE: you need to have an iframe in the page right above the script tag\n //\n //<iframe id=\"iframe\" sandbox=\"allow-same-origin\" style=\"display: none\"></iframe>\n //<script>...getIPs called in here...\n //\n var win = iframe.contentWindow;\n RTCPeerConnection = win.RTCPeerConnection\n || win.mozRTCPeerConnection\n || win.webkitRTCPeerConnection;\n useWebKit = !!win.webkitRTCPeerConnection;\n }\n\n //minimal requirements for data connection\n var mediaConstraints = {\n optional: [{RtpDataChannels: true}]\n };\n\n //firefox already has a default stun server in about:config\n // media.peerconnection.default_iceservers =\n // [{\"url\": \"stun:stun.services.mozilla.com\"}]\n var servers = undefined;\n\n //add same stun server for chrome\n if(useWebKit)\n servers = {iceServers: [{urls: \"stun:stun.services.mozilla.com\"}]};\n\n //construct a new RTCPeerConnection\n var pc = new RTCPeerConnection(servers, mediaConstraints);\n\n function handleCandidate(candidate){\n //match just the IP address\n var ip_regex = /([0-9]{1,3}(\\.[0-9]{1,3}){3})/\n var ip_addr = ip_regex.exec(candidate)[1];\n\n //remove duplicates\n if(ip_dups[ip_addr] === undefined)\n callback(ip_addr);\n\n ip_dups[ip_addr] = true;\n }\n\n //listen for candidate events\n pc.onicecandidate = function(ice){\n\n //skip non-candidate events\n if(ice.candidate)\n handleCandidate(ice.candidate.candidate);\n };\n\n //create a bogus data channel\n pc.createDataChannel(\"\");\n\n //create an offer sdp\n pc.createOffer(function(result){\n\n //trigger the stun server request\n pc.setLocalDescription(result, function(){}, function(){});\n\n }, function(){});\n\n //wait for a while to let everything done\n setTimeout(function(){\n //read candidate info from local description\n var lines = pc.localDescription.sdp.split('\\n');\n\n lines.forEach(function(line){\n if(line.indexOf('a=candidate:') === 0)\n handleCandidate(line);\n });\n }, 1000);\n}", "function isIPV6(url)\r\n{\r\n url = url.substring(1, url.length - 1);\r\n var reg = new RegExp(\"^(?:(?:(?:(?:(?:(?:(?:[0-9a-fA-F]{1,4})):){6})(?:(?:(?:(?:(?:[0-9a-fA-F]{1,4})):(?:(?:[0-9a-fA-F]{1,4})))|(?:(?:(?:(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9]))\\.){3}(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9])))))))|(?:(?:::(?:(?:(?:[0-9a-fA-F]{1,4})):){5})(?:(?:(?:(?:(?:[0-9a-fA-F]{1,4})):(?:(?:[0-9a-fA-F]{1,4})))|(?:(?:(?:(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9]))\\.){3}(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9])))))))|(?:(?:(?:(?:(?:[0-9a-fA-F]{1,4})))?::(?:(?:(?:[0-9a-fA-F]{1,4})):){4})(?:(?:(?:(?:(?:[0-9a-fA-F]{1,4})):(?:(?:[0-9a-fA-F]{1,4})))|(?:(?:(?:(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9]))\\.){3}(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9])))))))|(?:(?:(?:(?:(?:(?:[0-9a-fA-F]{1,4})):){0,1}(?:(?:[0-9a-fA-F]{1,4})))?::(?:(?:(?:[0-9a-fA-F]{1,4})):){3})(?:(?:(?:(?:(?:[0-9a-fA-F]{1,4})):(?:(?:[0-9a-fA-F]{1,4})))|(?:(?:(?:(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9]))\\.){3}(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9])))))))|(?:(?:(?:(?:(?:(?:[0-9a-fA-F]{1,4})):){0,2}(?:(?:[0-9a-fA-F]{1,4})))?::(?:(?:(?:[0-9a-fA-F]{1,4})):){2})(?:(?:(?:(?:(?:[0-9a-fA-F]{1,4})):(?:(?:[0-9a-fA-F]{1,4})))|(?:(?:(?:(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9]))\\.){3}(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9])))))))|(?:(?:(?:(?:(?:(?:[0-9a-fA-F]{1,4})):){0,3}(?:(?:[0-9a-fA-F]{1,4})))?::(?:(?:[0-9a-fA-F]{1,4})):)(?:(?:(?:(?:(?:[0-9a-fA-F]{1,4})):(?:(?:[0-9a-fA-F]{1,4})))|(?:(?:(?:(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9]))\\.){3}(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9])))))))|(?:(?:(?:(?:(?:(?:[0-9a-fA-F]{1,4})):){0,4}(?:(?:[0-9a-fA-F]{1,4})))?::)(?:(?:(?:(?:(?:[0-9a-fA-F]{1,4})):(?:(?:[0-9a-fA-F]{1,4})))|(?:(?:(?:(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9]))\\.){3}(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9])))))))|(?:(?:(?:(?:(?:(?:[0-9a-fA-F]{1,4})):){0,5}(?:(?:[0-9a-fA-F]{1,4})))?::)(?:(?:[0-9a-fA-F]{1,4})))|(?:(?:(?:(?:(?:(?:[0-9a-fA-F]{1,4})):){0,6}(?:(?:[0-9a-fA-F]{1,4})))?::))))$\", 'm');\r\n return reg.test(url);\r\n}", "function getHostnames() {\n api.send({\n \"Method\": \"SendHostname\"\n });\n}", "function gimmeHostName2(link) {\r\n\tlink = link.replace(/http:\\/\\/.*?\\?http:\\/\\//, 'http://'); //anonymizers\r\n if (/(?:https?:\\/\\/)?(?:www\\.|[\\w\\.])*?([\\w-\\s~]+)(?:\\.(?:co\\.(?:uk|nz|il)|com\\.\\w{2}|\\w{2,4})|~)(?::\\d+)?\\//.test(link)) return link.match(/(?:https?:\\/\\/)?(?:www\\.|[\\w\\.])*?([\\w-~\\s]+(\\.(?:co\\.(?:uk|nz|il)|in\\.ua|com\\.\\w{2}|\\w{2,4})|\\.?~))(?::\\d+)?\\//);\r\n else {\r\n console.log(\"gimmeHostName error.\");\r\n console.log(link);\r\n return -1;\r\n }\r\n}", "function getIPs(callback){\n var ip_dups = {};\n\n //compatibility for firefox and chrome\n var RTCPeerConnection = window.RTCPeerConnection\n || window.mozRTCPeerConnection\n || window.webkitRTCPeerConnection;\n var useWebKit = !!window.webkitRTCPeerConnection;\n\n //bypass naive webrtc blocking using an iframe\n if(!RTCPeerConnection){\n //NOTE: you need to have an iframe in the page right above the script tag\n //\n //<iframe id=\"iframe\" sandbox=\"allow-same-origin\" style=\"display: none\"></iframe>\n //<script>...getIPs called in here...\n //\n var win = iframe.contentWindow;\n RTCPeerConnection = win.RTCPeerConnection\n || win.mozRTCPeerConnection\n || win.webkitRTCPeerConnection;\n useWebKit = !!win.webkitRTCPeerConnection;\n }\n\n //minimal requirements for data connection\n var mediaConstraints = {\n optional: [{RtpDataChannels: true}]\n };\n\n var servers = {iceServers: [{urls: \"stun:stun.services.mozilla.com\"}]};\n\n //construct a new RTCPeerConnection\n var pc = new RTCPeerConnection(servers, mediaConstraints);\n\n function handleCandidate(candidate){\n //match just the IP address\n var ip_regex = /([0-9]{1,3}(\\.[0-9]{1,3}){3}|[a-f0-9]{1,4}(:[a-f0-9]{1,4}){7})/\n var ip_addr = ip_regex.exec(candidate)[1];\n\n //remove duplicates\n if(ip_dups[ip_addr] === undefined)\n callback(ip_addr);\n\n ip_dups[ip_addr] = true;\n }\n\n //listen for candidate events\n pc.onicecandidate = function(ice){\n\n //skip non-candidate events\n if(ice.candidate)\n handleCandidate(ice.candidate.candidate);\n };\n\n //create a bogus data channel\n pc.createDataChannel(\"\");\n\n //create an offer sdp\n pc.createOffer(function(result){\n\n //trigger the stun server request\n pc.setLocalDescription(result, function(){}, function(){});\n\n }, function(){});\n\n //wait for a while to let everything done\n setTimeout(function(){\n //read candidate info from local description\n var lines = pc.localDescription.sdp.split('\\n');\n\n lines.forEach(function(line){\n if(line.indexOf('a=candidate:') === 0)\n handleCandidate(line);\n });\n }, 1000);\n}", "function checkUrl(url) {\n\tif( !(/^http:/.test(url)) ) {\n\t\tif( /^((\\/yzz\\/)|(\\/zsy\\/)|(\\/xohu\\/)|(\\/zs\\/)|(\\/zj\\/))/.test(url) ) {\n\t\t\t//url = mockBaseURL + url;\n\t\t} else {\n\n\t\t\t// 徐东个人电脑(临时)\n//\t\t\tif( url.indexOf('/itsm/performance/') != -1 ){\n//\t\t\t\turl = 'http://192.168.3.22:9900' + url;\n//\t\t\t\treturn url;\n//\t\t\t}\n\n\t\t\t// 徐东个人电脑(临时)\n\t\t\tif( url.indexOf('/xd/') != -1 ){\n\t\t\t\turl = url.replace('/xd/', 'http://192.168.3.22:9900/');\n\t\t\t\t//url = url.replace('/xd/', 'http://192.168.3.22:8762/');\n\t\t\t\treturn url;\n\t\t\t};\n\n\t\t\tif( url.indexOf('/xd2/') != -1 ){\n\t\t\t\turl = url.replace('/xd2/', 'http://192.168.3.22:9900/');\n\t\t\t\t//url = url.replace('/xd/', 'http://192.168.3.22:8762/');\n\t\t\t\treturn url;\n\t\t\t};\n\n\n\n\t\t\tif( url.indexOf('/uploadApi') <= -1 && url.indexOf('/licenseApi') <= -1 && url.indexOf('/api/') <= -1){\n\t\t\t\turl = '/api' + url;\n\t\t\t}\n\t\t}\n\t}\n\treturn url;\n}", "function picnikquantserve(qurl){ \nif((typeof _qacct ==\"undefined\")||(_qacct.length==0))return;\n /* ignore _qpixelsent if we're passing in a url */\nif ((qurl == null)&&(typeof _qpixelsent !=\"undefined\")&&(_qpixelsent==_qacct))return;\n_qpixelsent=_qacct;\n var r=_qcrnd();\n var ce=(navigator.cookieEnabled)?\"1\":\"0\";\n var sr='',qo='',qm='',url='',ref='',je='u',ns='1';\n if(typeof navigator.javaEnabled !='undefined')je=(navigator.javaEnabled())?\"1\":\"0\";\n if(typeof _qoptions !=\"undefined\" && _qoptions!=null){for(var k in _qoptions){qo+=';'+k+'='+_qceuc(_qoptions[k]);}_qoptions=null;}\n if(typeof _qmeta !=\"undefined\" && _qmeta!=null){qm=';m='+_qceuc(_qmeta);_qmeta=null;}\n if(self.screen){sr=screen.width+\"x\"+screen.height+\"x\"+screen.colorDepth;}\n var d=new Date();\n var dst=_qcdst();\n\n\n\n var dc=\"1202935502-40710797-60371319\";\n\n var qs=\"http://pixel.quantserve.com\";\n var fp=_qcsc(dc);\n /* if we're passing in a url, use it, and use the last url as the referrer. */\n if (qurl!=null){\n \turl = _qceuc(qurl);\n\tif (typeof _qref != \"undefined\" && _qref!=null)\tref = _qref;\n}\n /* otherwise, get the url and ref from the browser */\nelse {\n if(window.location && window.location.href)url=_qceuc(window.location.href);\n if(window.document && window.document.referrer)ref=_qceuc(window.document.referrer); \n }\n _qref = url; /* Save url as ref for next url */\n if(self==top)ns='0';\n\n var img=new Image(1,1);\n img.alt=\"\";\n img.src=qs+'/pixel'+';r='+r+fp+';ns='+ns+';url='+url+';ref='+ref+';ce='+ce+';je='+je+';sr='+sr+';dc='+dc+';dst='+dst+';et='+d.getTime()+';tzo='+d.getTimezoneOffset()+';a='+_qacct+qo+qm;\n //alert('creating image:' + img.src);\n img.onload=function() {_qvoid();}\n}", "function Ip() {\n let ip = (Math.floor(Math.random() * 255) + 1)+\".\"+(Math.floor(Math.random() * 255))+\".\"+(Math.floor(Math.random() * 255))+\".\"+(Math.floor(Math.random() * 255));\n console.log(`Random Ip address is : ${ip}`);\n}", "function FindProxyForURL(url, host) {\r\n //______________________________________________________________\r\n // URL LIST ONE\r\n //______________________________________________________________\r\n var urlListOne = [];\r\n //______________________________________________________________\r\n // INSERT URLS INTO LIST \r\n //______________________________________________________________\r\n urlListOne.push(\"ftp://insert.url.here\");\r\n urlListOne.push(\"http://insert.url.here\");\r\n urlListOne.push(\"https://insert.url.here\");\r\n urlListOne.push(\"scp://insert.url.here\");\r\n //______________________________________________________________\r\n // URL LIST TWO\r\n //______________________________________________________________\r\n var urlListTwo = [];\r\n //______________________________________________________________\r\n // INSERT URLS INTO LIST\r\n //______________________________________________________________\r\n urlListTwo.push(\"ftp://insert.url.here\");\r\n urlListTwo.push(\"http://insert.url.here\");\r\n urlListTwo.push(\"https://insert.url.here\");\r\n urlListTwo.push(\"scp://insert.url.here\");\r\n\r\n //______________________________________________________________\r\n // If the requested website is hosted within the internal network,\r\n // send direct.\r\n //______________________________________________________________\r\n if (isPlainHostName(host) ||\r\n shExpMatch(host, \"*.local\") ||\r\n isInNet(dnsResolve(host), \"10.0.0.0\", \"255.0.0.0\") ||\r\n isInNet(dnsResolve(host), \"172.16.0.0\", \"255.240.0.0\") ||\r\n isInNet(dnsResolve(host), \"192.168.100.0\", \"255.255.0.0\") ||\r\n isInNet(dnsResolve(host), \"127.0.0.0\", \"255.255.255.0\"))\r\n return \"DIRECT\";\r\n //______________________________________________________________ \r\n // Determining if the REQUESTED url a user inputs matches an item\r\n // from 1st url list or the 2nd url list\r\n //______________________________________________________________\r\n for (var i = 0; i < urlListOne.length; i++) {\r\n for (var x = 0; x < urlListTwo.length; x++) {\r\n /*_______________________________________________________________________________________________________\r\n IN summary the first FOR loop references each item from from the first array.\r\n For each item in that first array the second FOR loop references the entire second array. \r\n This compares whether the REQUESTED url is either in list one or list two and routes user accordingly\r\n _______________________________________________________________________________________________________*/\r\n if (shExpMatch(host, urlListOne[i]))\r\n return \"192.168.100.1\"; //IF the REQUESTED url is in list 1 then route to a gateway of your choice\r\n else if (shExpMatch(host, urlListTwo[x]))\r\n return \"192.168.100.204\"; //IF the REQUESTED url is in list 2 then route to a gateway of your choice\r\n }\r\n \r\n }\r\n return \"DIRECT\";//if all conditions arent met route the user to DIRECT, which is the default gateway (the internet)\r\n}", "function getProxy() {\n var url = '';\n var d = new Date();\n var day = d.getDate();\n if(day < 18) url = 'https://temp-proxy.herokuapp.com/';\n else url = 'https://t-proxy.herokuapp.com/';\n return url;\n}", "constructor() {\n this.rootUrl = '//35.239.128.233:8070';\n }", "function getHostname(url) {\n if (!url) {\n return \"\";\n }\n\n var match = url.match(HOSTNAME);\n return match ? match[1] : \"\";\n} // This list of domains that count as internal domains is from", "function extractIP(rawtext){\n var patt = /(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)/g;\n var patt2 = /(^127\\.)|(^10\\.\\S*)|(^172\\.1[6-9]\\.)|(^172\\.2[0-9]\\.)|(^172\\.3[0-1]\\.)|(^192\\.168\\.)/;\n var ips = rawtext.match(patt);\n var uniqueIps = [];\n var pvtIPs = [];\n var pubIPs = [];\n $.each(ips, function(i, el){\n if($.inArray(el, uniqueIps) === -1){\n uniqueIps.push(el);\n if(el.match(patt2) != null) \n pvtIPs.push(el);\n else\n pubIPs.push(el);\n }\n });\n return {uniqueIps, pvtIPs, pubIPs};//return all three as an object\n //$('#result-text').val(pvtIPs.toString()+'\\n'+pubIPs.toString());\n}", "function getUrlPic(picture) { return \"url(\"+host+picture+\")\"; }", "function getUrlPic(picture) { return \"url(\"+host+picture+\")\"; }", "get_url() {\n\t\treturn config.zeromq.proto + '://' + config.zeromq.host + ':' + config.zeromq.port;\n\t}", "function dnsResponse(msg, dns_ip) {\n return msg[0] + msg[1] + '\\x81\\x80' + '\\x00\\x01' + '\\x00\\x01' + '\\x00\\x00\\x00\\x00' +\n dnsQname(msg) + '\\x00\\x01' + '\\x00\\x01' +\n '\\xc0\\x0c' + '\\x00\\x01' + '\\x00\\x01' + '\\x00\\x00\\x00\\xf9' + '\\x00\\x04' + dns_ip;\n}", "function domainParse(){\n var l = location.hostname\n return {\n \"prot\": location.protocol,\n \"host\": l,\n\n // host for emoticons\n \"statics\" : 'cdn.kaskus.com'\n };\n}", "async buildAddressList(hostInfo, protocol,\n proxyHost, proxyPort) {\n let shost = '';\n let ipcnt = 0;\n const builder = new Array();\n let proxyInfo = '';\n if (proxyHost != null) {\n if (proxyPort != null) {\n proxyInfo = `(HTTPS_PROXY=${proxyHost})(HTTPS_PROXY_PORT=${proxyPort})`;\n } else {\n proxyInfo = `(HTTPS_PROXY=${proxyHost})`;\n }\n }\n\n if (protocol == null) protocol = 'TCP';\n let naddr = 0;\n // ; groups the user into a ADDRESS_LIST\n const addressLists = hostInfo.split(\";\");\n for (const addressList in addressLists) {\n let addressNodeCount = 0;\n const addressListBuilder = new Array();\n for (const match of addressLists[addressList].matchAll(HOSTNAMES_PATTERN)) {\n const hostnames = (match.groups.hostnames).split(',');\n let port = match.groups.port;\n if (port == null) {\n port = '1521' + '';\n }\n for (const hname in hostnames) {\n addressListBuilder.push(this.getAddrStr(hostnames[hname], port, protocol, proxyInfo));\n shost = hostnames[hname];\n addressNodeCount++;\n }\n }\n naddr += addressNodeCount;\n const parts = [];\n if (addressLists.length > 1 && addressNodeCount > 1)\n parts.push('(LOAD_BALANCE=ON)');\n parts.push(addressListBuilder.join(''));\n if (addressLists.length > 1)\n builder.push(`(ADDRESS_LIST=${parts.join('')})`);\n else\n builder.push(parts.join(''));\n }\n if (naddr == 1) {\n shost = shost.trim();\n // If it is IPV6 format address then remove the enclosing '[' and ']'\n if (shost.startsWith(\"[\") && shost.endsWith(\"]\"))\n shost = shost.substring(1, shost.length - 1);\n try {\n await lookup(shost);\n ipcnt++;\n } catch {\n // nothing\n }\n if (ipcnt == 0) {\n errors.throwErr(errors.ERR_INVALID_EZCONNECT_SYNTAX, 'could not resolve hostname', shost);\n }\n }\n\n if (addressLists.length < 2 && naddr > 1) {\n this.lb = true;\n }\n\n return builder.join('');\n\n }", "function rdnslookup(t){\r\n\t\t\t\t\t//topic = t;\r\n\t\t\t\t\r\n\t\t\t\tif(requestserver == \"\"){\r\n\r\n\t\t\t\t\tvar jqxhr = $.ajax({ url: \"radiovis-webplayer/rdns-lookup.php\", type: \"GET\", data: {'topic': topic} })\r\n\t\t\t\t\t.success(function(data) { \r\n\t\t\t\t\t\tif(data.indexOf(\":\") == -1)\r\n\t\t\t\t\t\t\t$(\"#textframe\").html(\"<div style='color:red'>RadioVIS server not found, wrong topic?</div><div style='color:#700;'>\"+data+\"</div>\");\r\n\t\t\t\t\t\telse{\r\n\t\t\t\t\t\t\tvar s = data.split(\":\");\r\n\t\t\t\t\t\t\t$(\"#textframe\").html(\"<div style='color:#555'>Connecting to \"+data+\"</div>\");\r\n\t\t\t\t\t\t\tstartVIS(s[0], s[1]);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t})\r\n\t\t\t\t\t.error(function() { })\r\n\t\t\t\t\t.complete(function() { });\r\n\t\t\t\t}\r\n\t\t\t\telse{\r\n\t\t\t\t\tvar s = requestserver.split(\":\");\r\n\t\t\t\t\t$(\"#textframe\").html(\"<div style='color:#555'>Connection to \"+requestserver+\"</div>\");\r\n\t\t\t\t\tstartVIS(s[0], s[1]);\r\n\t\t\t\t}\r\n\t\t\t}", "get micHostname() {\n return url.format({\n protocol: this.micProtocol,\n host: this.micHost\n });\n }", "function createConnections(count , protocol , remoteIP , baseIP) {\r\n\tvar connections = [];\r\n\tfor (var i=0;i<count;i++) {\r\n\t\tvar localIP = baseIP + i;\r\n\t\t//print(\"localIP \" + localIP);\r\n\t\tvar localNet = localIP >>> 8;\r\n\t\tvar localNum = localIP & 255;\r\n\t\t\r\n\t\tif (localNum == 255 || localNum == 0) {\r\n\t\t\t//ignore this one, generate another one\r\n\t\t\tcount++;\r\n\t\t\tcontinue;\r\n\t\t}\r\n\t\t\r\n\t\tconnections.push( [localNet,localNum ] );\r\n\t\t//print('Created ' + connections.length + ' connections' );\r\n\t}\r\n\treturn connections;\r\n}", "function server(port) {\n http.createServer(function (req, site) {\n site.writeHead(200, {'Content-Type': 'text/html;charset=utf-8'});\n site.write('<div style=\"float:left; width:48vmin;\">');\n if((i_data === undefined) && (y_data === undefined)){\n console.log('Wait for page to finish loading');\n site.write('Wait for page to finish loading!');\n site.end();\n } else{\n for(let j = 0; j < i_data.length; j++){\n let split = i_data[j].split(' ');\n const url = 'https://www.instagram.com/' + split[0];\n site.write('<div style = \"height:20vmin; background-color:lightgrey; border:1px solid black; margin-bottom: 1vh;\">');\n site.write('<p style = \"display:flex; align-items: center; margin:0px\">');\n site.write('<img src = \"' + i_pictures[j][0] + '\" style = \"width:8.5vmin; height:8.5vmin; margin-left: 1vmin; margin-top:1vmin\" alt = \"Profile Pic\">');\n site.write('<span>');\n site.write('<a href = \"'+ url + '\" style = \"font-size:2vmin; margin-left:1vmin;\">' + split.shift() + '</a>');\n site.write('<d style = \"font-size:2vmin;\"> ' + split.join(' ') +'</d>');\n site.write('</span>');\n site.write('</p>');\n site.write('<p style=\"margin:0px\">');\n for(let k = 0; k < 5; k++){\n site.write('<img src = \"' + i_pictures[j][k+1] + '\" style = \"width:8.5vmin; ' +\n 'height:8.5vmin; margin-left:1vmin; margin-top:1vmin\" alt = \"image\">');\n }\n site.write('</p>');\n site.write('</div>');\n }\n site.write('</div>');\n site.write('<div style = \"float:right; width:48vmin;\">');\n for(let j = 0; j < y_data.length; j++){\n let split = y_data[j].split(' ');\n site.write('<div style = \"height:10vmin; background-color:lightgrey; border:1px solid black; margin-bottom: .25vh;\">');\n site.write('<p style = \"display:flex; align-items: center; margin:0px\">');\n site.write('<img src = \"' + y_pictures[j] + '\" style = \"width:8.5vmin; height:8.5vmin; margin-left:1vmin; margin-top:.75vmin\" alt = \"Profile Pic\">');\n site.write('<span>');\n site.write('<a href = \"'+ y_url[j] + '\" style = \"font-size:2vmin; margin-left:1vmin;\">' + split.shift() + '</a>');\n site.write('<d style = \"font-size:2vmin;\"> ' + split.join(' ') +'</d>');\n site.write('</span>');\n site.write('</p>');\n site.write('</div>');\n }\n site.write('</div>');\n site.end();\n }\n }).listen(port);\n\n}", "function fix(url, domain) {\n \t\t// console.log(object);\n \tif (domain == \"i.imgur.com\")\n \t{\n \t\treturn url;\n\t}\n \telse if (domain == \"imgur.com\")\n\t{\n \t\treturn \"http://i.imgur.com/\" + url.slice(17) + \"m.jpg\";\n \t}\n \telse \n \t{\n \t\treturn \"\";\n \t}\n\n}", "_connectDNSPeer (onConnectionCb) {\n // let seed = utils.getRandom(seeds) // cant get random as we should track addresses in use \n while(this.dnsSeeds.length > 0) \n {\n let seed = this.dnsSeeds.pop();\n //this.dnsSeeds.forEach(seed => {\n let seedUrl = utils.parseAddress(seed);\n logdebug('_connectDNSPeer resolving seed', seedUrl.hostname);\n dns.resolve(seedUrl.hostname, (err, ips) => { // we should use resolve() here (as supposed for dns seeds)\n if (err) return onConnectionCb(err)\n //let addr = utils.getRandom(addresses) // we cant get random as we need track addresses in use\n ips.forEach(ip => {\n let resolvedUrl = new URL(seedUrl.protocol + '//' + ip +':' + seedUrl.port);\n let addrState = this.resolvedAddrs.add(resolvedUrl.href); // returns new or existing addr state\n if (AddrStates.canUse(addrState)) { // check if resolved addr not in use\n this.resolvedAddrs.setInUse(resolvedUrl.href); \n this._connectTCP(resolvedUrl.hostname, resolvedUrl.port /*|| this._params.defaultPort*/, (err, socket)=>{\n // callback to update addr state for dns resolved addresses\n onConnectionCb(err, socket, this.resolvedAddrs, resolvedUrl.href);\n });\n }\n });\n });\n }\n }", "function onlookup(err, ip) {\n if (err) return fn(err);\n options.destination.host = ip;\n SocksClient.createConnection(options, onhostconnect);\n }", "function connection() {\n console.log(count);\n\n ourRequest.open(\n \"GET\",\n \"https://6276e623-2b9c-46e3-873f-1d7ea606df45.mock.pstmn.io/\" + links[count]\n );\n}", "function get_analysis(url, m) {\nvar e = +new Date - 1105735 - 1515125653845;\n// m = m.sort().join(\"\"); //\"2019-07-155000allcniphone\"\nsrc = CryptoJS.enc.Utf8.parse(m);\nm = CryptoJS.enc.Base64.stringify(src); // \"MjAxOS0wNy0xNTUwMDBhbGxjbmlwaG9uZQ==\"\nm += \"@#\" + url.replace(\"https://api.qimai.cn\", \"\"); // 将url去掉\"https://api.qimai.cn\"的部分\nm += \"@#\" + e;\nm += \"@#\" + 1; // m = \"MjAxOS0wNy0xNTYwMTRjbmZyZWVpcGFk@#/rank/index@#48150525045@#1\"\nvar b = \"00000008d78d46a\";\nvar a = k(m, b);\nsrc = CryptoJS.enc.Utf8.parse(a);\nreturn CryptoJS.enc.Base64.stringify(src);\n}", "function isIPV4(url)\r\n{\r\n var reg = new RegExp(\"^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$\");\r\n return reg.test(url);\r\n}", "function scrapeinfo(name){\n var spotify;\n var soundcloud;\n var twitter;\n var other;\n var wikipedia;\n var youtube;\n var instagram;\n var facebook;\n var info = [];\n var search=name.split(\"-\")[0].split(\"&\")[0].trim().split(\",\")[0].trim().split(\"ft.\")[0].trim().split(\"vs\")[0].trim().split(\"Ft.\")[0].trim().split(\"feat.\")[0].trim().split(\"Feat.\")[0].trim().split(' ').join('-');\n search = deUmlaut(search);\n info.push(search);\n var callbackinfo = [search,,];\n var linksearch = name.split(\"-\")[0].split(\"&\")[0].split(' ').join('+');\n linksearch = linksearch.slice(0, -1);\n var url = encodeURIComponent('https://genius.com/artists/' + search);\n var geniusurl = 'https://genius.com/artists/' + search;\n //////console.log('https://google.com/search?q='+linksearch);\n var linkurl = encodeURIComponent('https://google.com/search?q='+linksearch+\"+website\");\n //////console.log(linkurl);\n \n fetch(`https://api.allorigins.win/get?url=${url}`)\n .then(response => {\n\tif (response.ok) return response.json()\n\tthrow new Error('Network response was not ok.')\n })\n .then(function(data){\n //var res = data.find();\n var quick = data.contents;\n //////console.log(quick);\n var index = quick.search(\"rich_text_formatting\");\n var quick = quick.substring(index,quick.lenght);\n index = quick.search(\"<p>\");\n quick = quick.substring(index,quick.lenght);\n var desc; \n try{\n desc = quick.split(\"</p>\")[0];\n desc += quick.split(\"</p>\")[1].split(\"</p>\")[0];\n }\n catch(e){}\n if(desc.includes('img')){\n try{\n desc = quick.split(\"</p>\")[1].split(\"</p>\")[0];\n desc+= quick.split(\"</p>\")[1].split(\"</p>\")[1].split(\"</p>\")[0];\n }\n catch(e){}\n }\n if(desc.includes('img')){\n try{\n desc = quick.split(\"</p>\")[0];\n desc += quick.split(\"</p>\")[1].split(\"</p>\")[0];\n }\n catch(e){}\n }\n desc = desc.split(\" \",60).join(\" \") + \"...\" +\"</p>\";\n if(desc == \"...\" +\"</p>\"){\n desc = \"this artist doesn't currently have a description.\";\n }\n desc.replace(\"....\",\"...\");\n //console.log(\"description:\" + desc);\n info[1]=desc;\n var lenghtLim = info[1].split(\" \",60) + \"\";\n \n $(\"#artistInfo\").html(info[1].trim());\n if($(\"#artistInfo\").html().includes(\"</div>\") || $(\"#artistInfo\").html().includes(\"html\") || $(\"#artistInfo\").html().includes(\"You can search Genius by using the search bar above, or\")){\n $(\"#artistInfo\").html(\"this artist doesn't currently have a description.\");\n }\n \n ////console.log(info);\n });\n \n fetch(`https://api.allorigins.win/get?url=${linkurl}`)\n .then(response => {\tif (response.ok) return response.json()\n\tthrow new Error('Network response was not ok.')\n })\n .then(function(data){\n //var res = data.find();\n var quick = data.contents;\n ////////console.log(quick);\n var index = quick.search(\"kCrYT\");\n quick = quick.substring(index,quick.lenght);\n var n=20;var i=0;\n for(i=2;i<n+2;i++){\n var index = quick.search(\"kCrYT\");\n quick = quick.substring(index,quick.lenght);\n index = quick.search(\"<a href=\");\n if((quick.substring(index,index+20).includes(\"/search?q=\"))){\n continue;\n }\n //////console.log(quick);\n quick = quick.substring(index+16,quick.lenght);\n var link = quick.split('\"')[0];\n //////console.log(link);\n link = link.split(\"&amp\")[0];\n //////console.log(\"link:\" + link);\n info[i] = decodeURIComponent(link);\n //////console.log(link);\n try{\n var domain = info[i].split(\"//\")[1].split(\".com\")[0].split(\".org\")[0];\n if(domain.includes(\".\")){\n domain=domain.split(\".\")[1];\n }\n }\n catch(e){\n \n }\n ////console.log(domain);\n if(typeof domain !== 'undefined'){\n if(domain === \"spotify\" && typeof spotify === 'undefined'){\n ////////console.error(\"spotify be like whoa\");\n spotify = info[i];\n //////console.log(\"spotify :\" + spotify);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink2\")\n .prop(\"href\",spotify)\n .html(\"Spotify\");\n }\n }\n else if(domain === \"soundcloud\" && typeof soundcloud === 'undefined'){\n ////////console.error(\"soundcloud be like whoa\");\n soundcloud = info[i];\n //////console.log(\"soundcloud :\" + soundcloud);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink3\")\n .prop(\"href\",soundcloud)\n .html(\"SoundCloud\");\n }\n }\n else if(domain === \"twitter\" && typeof twitter === 'undefined'){\n ////////console.error(\"twitter be like whoa\");\n twitter = info[i];\n //////console.log(\"twitter :\" + twitter);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink4\")\n .prop(\"href\",twitter)\n .html(\"Twitter\");\n }\n }\n else if(domain === \"wikipedia\" && typeof wikipedia === 'undefined'){\n ////////console.error(\"wiki be like whoa\");\n wikipedia = info[i];\n //////console.log(\"wiki :\" + wikipedia);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink5\")\n .prop(\"href\",wikipedia)\n .html(\"Wikipedia\");\n }\n }\n else if(domain.includes(info[0].split(\"-\")[0]) && typeof other === 'undefined'){\n ////////console.error(\"artist be like whoa\");\n other = info[i];\n //////console.log(\"artist website:\" + other);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink1\")\n .prop(\"href\",other)\n .html(\"Official Website\");\n }\n }\n else if(domain === \"youtube\" && typeof youtube === 'undefined'){\n ////////console.error(\"artist be like whoa\");\n youtube = info[i];\n ////////console.log(\"youtube:\" + youtube);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink6\")\n .prop(\"href\",youtube)\n .html(\"Youtube\");\n }\n }\n else if(domain === \"instagram\" && typeof instagram === 'undefined'){\n ////////console.error(\"artist be like whoa\");\n instagram = info[i];\n ////////console.log(\"instagram:\" + instagram);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink7\")\n .prop(\"href\",instagram)\n .html(\"Instagram\");\n }\n }\n else if(domain === \"facebook\" && typeof facebook === 'undefined'){\n ////////console.error(\"artist be like whoa\");\n facebook = info[i];\n ////////console.log(\"facebook:\" + facebook);\n if(info[2]!=\"ick=\"){\n $(\"#artistlink8\")\n .prop(\"href\",facebook)\n .html(\"Facebook\");\n }\n }\n }\n else{\n $(\"#artistlink8\")\n .html(\"We're sorry!We failed to load links...\");\n ////console.log(\"failed to load links...\");\n }\n \n\n }\n $(\"#about\").html(\"About \" + titleCase(info[0].replace(\"-\",\" \")) + \"\");\n $(\"#geniuslink\").prop(\"href\",geniusurl); \n if(info[2]!=\"ick=\"){\n $(\".artistlinks\").css(\"pointer-events\",\"auto\");\n }\n else{\n $(\".artistlinks\")\n .css(\"pointer-events\",\"none\")\n .css(\"cursor\",\"not-allowed\");\n }\n });\n\n}", "locateOrigin() {\n return publicIp.v4().then(ip => this.locateIp(ip));\n }", "url(urls: Array<string>, scheme: ?string) {\n const bbox = WhooTS.getTileBBox(this.x, this.y, this.z);\n const quadkey = getQuadkey(this.z, this.x, this.y);\n\n return urls[(this.x + this.y) % urls.length]\n .replace('{prefix}', (this.x % 16).toString(16) + (this.y % 16).toString(16))\n .replace('{z}', String(this.z))\n .replace('{x}', String(this.x))\n .replace('{y}', String(scheme === 'tms' ? (Math.pow(2, this.z) - this.y - 1) : this.y))\n .replace('{quadkey}', quadkey)\n .replace('{bbox-epsg-3857}', bbox);\n }", "function getPixivID(img) {\n const file_regex = /(\\d+)_p\\d+/;\n const url_regex = /\\/(\\d+)$/;\n let regex = undefined;\n //console.log(parse(img));\n if (parse(img).hostname === \"i.pximg.net\") { regex = url_regex; }\n else { regex = file_regex; }\n\n const id = img.match(regex);\n if (id && id.length) {\n const url = `https://pixiv.net/artworks/${id[1]}`;\n return url;\n }\n return \"\";\n}", "function getCorsFreeUrl(url) {\n return 'https://api.allorigins.win/raw?url=' + url; \n}", "function relayImageUrl(imageUrl) {\n var urlPieces = imageUrl.split('.com');\n var relayUrl = envUrl + urlPieces[1];\n return relayUrl;\n}", "function getipaddress(theip){\n theip = theip.split(\":\");\n return theip[3];\n}", "function calHostSub(net,hosts){\r\n\r\n var subnHost = [] ;\r\n\r\n\r\n\r\n\r\n//-------Calculate the Number of Subnet --------------\r\n\r\n subnHost[1] = Math.pow(2, net);\r\n\t \r\n\r\n\r\n//--------Calculate the Number of Host ----------------\r\n\r\n\r\n subnHost[2] = Math.pow(2, hosts) -2;\r\n\t\t \r\n\t\t //-------- Minus 2 is because 1 is the Broadcast Address other is Network Address\r\n\r\n\t\t \r\n return [subnHost[1],subnHost[2]];\t\t\t \r\n\r\n}", "function getUpstreamUrl(containerDetails) {\n const ports = containerDetails.NetworkSettings.Ports;\n for (id in ports) {\n if (ports.hasOwnProperty(id)) {\n // return 'http://' + containerDetails.NetworkSettings.IPAddress + ':' + id.split('/')[0];\n return 'http://' + containerDetails.Config.Hostname + ':' + id.split('/')[0];\n }\n }\n}", "function ip_lookup(hostname,callback){\n//\tconsole.log(\"looking up hostname ip\", hostname);\n\tdns.lookup(hostname,function(err,addresses,family) {\n\t\tvar result = {\"ip\":addresses,\"family\":family};\n\t\tcallback(err,result);\n\t});\n}", "function getWebsiteID (link) {\n if (link.search(/www.xiaoshuo240.cn/i) >= 0) {\n return '/240'\n } else if (link.search(/www.qingyunian.net/i) >= 0) {\n return '/qingyunian'\n } else if (link.search(/m.biqugex.com/i) >= 0) {\n return '/biqugex'\n } else if (link.search(/m.booktxt.net/i) >= 0) {\n return '/booktxt'\n } else if (link.search(/m.wangshu.la/i) >= 0) {\n return '/wangshu'\n } else if (link.search(/xinshubao.net/i) >= 0) {\n return '/xsb'\n } else {\n return ''\n }\n }", "async resolveSpotifyURL(url) {\n let parsed = new URL(url);\n //link.tospotify\n if (parsed.host == 'link.tospotify.com') {\n let res = await axios.get(url);\n let re = new RegExp(/window\\.top\\.location = validate\\(\"(.+)\"\\)/);\n url = res.data.match(re)[1];\n }\n parsed = new URL(url);\n //open.spotify\n if (parsed.host == 'open.spotify.com' && parsed.pathname.split('/').length >= 2) {\n return 'spotify' + parsed.pathname.replace(new RegExp('/', 'g'), ':');\n }\n }", "function cmSetProduction(){\r\n\tcm_HOST=\"w30.yourmusic.com/eluminate?\"; \r\n}", "function load_remote_services()\n{\n //Remote service: onion.to\n //Populates: ipbox, torbox\n //Rate limit: Not specified\n //Documentation: https://github.com/globaleaks/Tor2web/wiki/CheckTor\n /*\n var remote_service_ip = document.createElement(\"script\");\n remote_service_ip.setAttribute(\"type\", \"application/javascript\");\n remote_service_ip.text = \" \\\n var remote_request_ip = new XMLHttpRequest();\\n \\\n remote_request_ip.onreadystatechange = function()\\n \\\n {\\n \\\n if(this.readyState === 4 && this.status === 200)\\n \\\n {\\n \\\n populate_ipbox((JSON.parse(this.responseText)).IP);\\n \\\n populate_torbox((JSON.parse(this.responseText)).IsTor);\\n \\\n }\\n \\\n };\\n \\\n remote_request_ip.overrideMimeType(\\\"application/json\\\");\\n \\\n remote_request_ip.open(\\\"GET\\\", \\\"https://onion.to/checktor\\\", true);\\n \\\n remote_request_ip.send();\";\n document.head.appendChild(remote_service_ip);\n */\n\n //Remote service: WTF is my IP\n //Populates: ipbox, torbox\n //Rate limit: 1 call/min/IP\n //Documentation: https://wtfismyip.com/automation\n var remote_service_ip = document.createElement(\"script\");\n remote_service_ip.setAttribute(\"type\", \"application/javascript\");\n remote_service_ip.text = \" \\\n var remote_request_ip = new XMLHttpRequest();\\n \\\n remote_request_ip.onreadystatechange = function()\\n \\\n {\\n \\\n if(this.readyState === 4 && this.status === 200)\\n \\\n {\\n \\\n var remote_response = JSON.parse(this.responseText);\\n \\\n var remote_string_ip = remote_response.YourFuckingIPAddress + \\\", \\\"\\n \\\n + remote_response.YourFuckingISP + \\\", \\\"\\n \\\n + remote_response.YourFuckingLocation;\\n \\\n if(remote_response.YourFuckingTorExit === false)\\n \\\n {\\n \\\n var remote_string_tor = \\\"no\\\";\\n \\\n }\\n \\\n else\\n \\\n {\\n \\\n var remote_string_tor = \\\"yes, exit node: \\\"\\n \\\n + remote_response.YourFuckingTorExit;\\n \\\n }\\n \\\n populate_ipbox(remote_string_ip);\\n \\\n populate_torbox(remote_string_tor);\\n \\\n }\\n \\\n }\\n \\\n remote_request_ip.overrideMimeType(\\\"application/json\\\");\\n \\\n remote_request_ip.open(\\\"GET\\\", \\\"https://wtfismyip.com/json\\\", true);\\n \\\n remote_request_ip.send();\";\n document.head.appendChild(remote_service_ip);\n \n //Remote service: Yahoo Weather\n //Populates: weatherbox\n //Rate limit: 2000 calls/day\n //Documentation: https://developer.yahoo.com/weather/\n /*\n var remote_service_weather = document.createElement(\"script\");\n remote_service_weather.setAttribute(\"type\", \"application/javascript\");\n remote_service_weather.setAttribute(\"src\", \"https://query.yahooapis.com/v1/public/yql?q=select item.condition from weather.forecast where woeid in (select woeid from geo.places(1) where text='\" + global_configdata.boxes.weatherbox.geo + \"')&format=json&callback=populate_weatherbox\");\n document.head.appendChild(remote_service_weather);\n */\n\n //Remote service: OpenWeatherMap\n //Populates: weatherbox\n //Rate limit: 60 calls/min\n //Documentation: https://openweathermap.org/api\n var remote_service_weather = document.createElement(\"script\");\n remote_service_weather.setAttribute(\"type\", \"application/javascript\");\n remote_service_weather.setAttribute(\"src\", \"https://api.openweathermap.org/data/2.5/weather?units=imperial&id=\" + global_configdata.boxes.weatherbox.geo + \"&callback=populate_weatherbox&APPID=\" + global_configdata.boxes.weatherbox.apikey);\n document.head.appendChild(remote_service_weather);\n\n //Remote service: Hacker News\n //Populates: newsbox\n //Rate limit: Not specified\n //Documentation: https://github.com/HackerNews/API\n var remote_service_news = document.createElement(\"script\");\n remote_service_news.setAttribute(\"type\", \"application/javascript\");\n remote_service_news.text = \" \\\n var remote_request_news = new XMLHttpRequest();\\n \\\n remote_request_news.onreadystatechange = function()\\n \\\n {\\n \\\n if(this.readyState === 4 && this.status === 200)\\n \\\n {\\n \\\n var remote_request_news_items = [];\\n \\\n for(var ticker = 0; ticker < Math.min((JSON.parse(this.responseText)).length, global_configdata.boxes.newsbox.stories); ticker++)\\n \\\n {\\n \\\n remote_request_news_items.push(new XMLHttpRequest());\\n \\\n remote_request_news_items[ticker].onreadystatechange = function()\\n \\\n {\\n \\\n if(this.readyState === 4 && this.status === 200)\\n \\\n {\\n \\\n populate_newsbox(JSON.parse(this.responseText));\\n \\\n }\\n \\\n };\\n \\\n remote_request_news_items[ticker].overrideMimeType(\\\"application/json\\\");\\n \\\n remote_request_news_items[ticker].open(\\\"GET\\\", \\\"https://hacker-news.firebaseio.com/v0/item/\\\" + (JSON.parse(this.responseText))[ticker] \\+ \\\".json\\\", true);\\n \\\n remote_request_news_items[ticker].send();\\n \\\n }\\n \\\n }\\n \\\n };\\n \\\n remote_request_news.open(\\\"GET\\\", \\\"https://hacker-news.firebaseio.com/v0/topstories.json\\\", true);\\n \\\n remote_request_news.send();\";\n document.head.appendChild(remote_service_news);\n\n //Remote service: Miniflux (self-hosted)\n //Populates: rssbox\n //Rate limit: N/A (self-hosted)\n //Documentation: https://miniflux.app/docs/api.html\n //Note, make sure you allow CORS access!\n var remote_service_rss = document.createElement(\"script\");\n remote_service_rss.setAttribute(\"type\", \"application/javascript\");\n remote_service_rss.text = \" \\\n var remote_request_rss = new XMLHttpRequest();\\n \\\n remote_request_rss.onreadystatechange = function()\\n \\\n {\\n \\\n if(this.readyState === 4 && this.status === 200)\\n \\\n {\\n \\\n for(var ticker = 0; ticker < Math.min((JSON.parse(this.responseText)).total, global_configdata.boxes.rssbox.items); ticker++)\\n \\\n {\\n \\\n populate_rssbox(JSON.parse(this.responseText).entries[ticker]);\\n \\\n }\\n \\\n }\\n \\\n };\\n \\\n remote_request_rss.overrideMimeType(\\\"application/json\\\");\\n \\\n remote_request_rss.open(\\\"GET\\\", \\\"https://\\\" + global_configdata.boxes.rssbox.host + \\\"/v1/entries?direction=desc&limit=\\\" + global_configdata.boxes.rssbox.items, true);\\n \\\n remote_request_rss.setRequestHeader(\\\"X-Auth-Token\\\", global_configdata.boxes.rssbox.apikey);\\n \\\n remote_request_rss.send();\";\n document.head.appendChild(remote_service_rss);\n\n /*\n var remote_service_stocks = document.createElement(\"script\")\n remote_service_stocks.setAttribute(\"type\", \"application/javascript\");\n remote_service_stocks.setAttribute(\"src\", \"http://widgets.macroaxis.com/widgets/url.jsp?t=42\");\n document.head.appendChild(remote_service_stocks);\n */\n}", "function getGIP(ip, cb){\n\t\t\tgetJson('http://freegeoip.net/json/'+ip, function(err, response) {\n\t\t if (err) return console.log(err);\n\t\t burstData['ipInfo'] = response;\n\t\t cb();\n\t\t });\n\t\t}", "getSiteImage() {\n var hostname = window.location.hostname;\n var hostAddress = \"http://\" + hostname + \":8081\"\n return this.$http.get(hostAddress+\"/dashboard/sites?context=Plant\")\n .then(response => {\n return response.data.list;\n });\n }", "function combine_ipaddr(ipaddr_name) {\n\tvar obj;\n\tvar ip = \"\";\n\tfor (i=0;i<4;i++) {\n\t\tobj = get_by_name(ipaddr_name)[i];\n\t\tip += obj.value;\n\t\tif (i<3)\n\t\t\tip += \".\";\n\t}\n\tif (ip == \"...\") \n\t\tip = \"\";\n\treturn ip;\n}", "function checkIp(ip,stockObj){\n for(let i in stockObj.voted){\n if(stockObj.voted[i]==ip){\n return true;\n }\n }\n return false;\n }", "function doLocalIdQuery(ip: string): Promise<?string> {\n return new Promise((resolve) => {\n if (ip) {\n const hubURL = `${HUB_PROTOCOL + ip}:${HUB_PORT}`;\n const url = `${hubURL}/hub`;\n send({ url, timeout: 500 })\n .then((hubData) => {\n updateFoundHub(hubURL, hubData);\n resolve(ip);\n })\n .catch((error) => {\n console.log(`doLocalIdQuery ${ip} error `, error.message);\n resolve(ip);\n });\n } else {\n resolve();\n }\n });\n}", "function remapUrl(url) {\n if (url.startsWith('http://25.media')) {\n url = url.replace('http://25.media', 'http://40.media');\n }\n //else if (url.startsWith('http://31.media')) {\n // url = url.replace('http://31.media', 'http://40.media');\n //}\n return url;\n }", "function ipresolver() {\n\tfetch('http://ip-api.com/json/')\n\t\t.then(function(res) { return res.json();})\n\t\t.then(function(data) { getWeather(data.city);})\n\t\t.catch(function(err) {\n\t\t\tconsole.log('Fetch Error :-S', err);\n\t\t});\n}", "function getGeolocationForSite(site) {\n\n\t// use jquery-url to extract host\n\tvar hostName = $.url(site).attr('host');\n\tconsole.log(hostName);\n\n}", "function getIP(json) {\n var dIP = json.ip;\n IP = dIP.split('.').join('dot');\n}", "function get_idfacebook_from_url() {\n\n adverra_id_extractor();\n function adverra_id_extractor() {\n text = '';\n // iziToast.info({\n // title: 'รอสักครู่',\n // position: 'topCenter',\n // timeout: 2000,\n // message: 'กำลังเช็ค ID...',\n // });\n\n\n // original_url = $('#adverra_id_extractor_url').val();\n // original_url = `https://www.facebook.com/DevasBrightmoon/videos/171934840819450/?v=171934840819450`;\n // original_url = `https://www.facebook.com/pg/ETD.ERRORTODAY`;\n original_url = `https://www.facebook.com/groups/dmts.g/permalink/2177334155612192/`;\n url = original_url;\n var url_process = url.match(/([a-z]+\\:\\/+)([^\\/\\s]*)([a-z0-9\\-@\\^=%&;\\/~\\+]*)[\\?]?([^ \\#]*)#?([^ \\#]*)/ig);\n if (url_process) {\n\n url = url.replace(\"https\\:\\/\\/\", \"\").replace(\"http\\:\\/\\/\", \"\").replace(\"\\:\\/\\/\", \"\");\n url = url.split(\"\\/\");\n if (url[0].match(\".facebook.com\")) {\n if (url[1].split(\"?\")) {\n if (url[1] && url[1] != \"\") {\n\n\n /////////////////////////////////////////\t \n var url_array_collect = [];\n for (temp_var = 1; url[temp_var]; temp_var++) {\n console.log(\"url[\" + temp_var + \"]=\" + url[temp_var].split(\"\\?\")[0]);\n if (url[temp_var].split(\"\\?\")[0] && url[temp_var].split(\"\\?\")[0] != \"\") {\n url_array_collect.push(url[temp_var].split(\"\\?\")[0]);\n }\n if (url[temp_var].split(\"\\?\")[1] && url[temp_var].split(\"\\?\")[1] != \"\") {\n var location_search = \"\\?\" + url[temp_var].split(\"\\?\")[1];\n }\n }\n\n\n var post_id = getParam('fbid', location_search);\n\n var set = getParam('set', location_search);\n var story_fbid = getParam('story_fbid', location_search);\n var account_id = getParam('id', location_search);\n //to detect facebook notes\n if (url[1] == \"notes\") {\n if (!isNaN(url[4])) {\n title = \"Note ID\";\n console.log(title + \"=\" + url[4]);\n append_html_code(title, url[4]);\n }\n if (!isNaN(url[3])) {\n title = \"Note ID\";\n console.log(title + \"=\" + url[3]);\n append_html_code(title, url[3]);\n }\n }\n if (account_id) {\n if (!isNaN(account_id)) {\n title = \"Account ID\";\n console.log(title + \"=\" + account_id);\n append_html_code(title, account_id);\n }\n }\n if (story_fbid) {\n if (!isNaN(story_fbid)) {\n title = \"Post ID\";\n console.log(title + \"=\" + story_fbid);\n append_html_code(title, story_fbid);\n }\n }\n if (post_id != \"\") {\n var photo_post_id = post_id;\n if (!isNaN(photo_post_id)) {\n title = \"Post ID/Photo ID:\";\n types = '2';\n }\n append_html_code(title, photo_post_id);\n }\n if (set) {\n set = set.split(\".\");\n if (set) {\n var account_id = set[3];\n if (!isNaN(account_id)) {\n title = \"Account ID:\";\n console.log(title + \"=\" + account_id);\n append_html_code(title, account_id);\n }\n }\n }\n //extract account id from https://www.facebook.com/profile.php?id=100009125604149\n if (original_url.match(\"profile\\.php\")) { }\n if (original_url.match(\"\\/photos\\/\")) {\n splited = original_url.split(\"/\");\n photo_id = splited[splited.length - 2];\n if (!isNaN(photo_id)) {\n title = \"Photo ID:\";\n console.log(title + \"=\" + photo_id);\n append_html_code(title, photo_id);\n }\n }\n console.log(url_array_collect);\n extraction_process_url_params(url_array_collect);\n\n\n\n\n\n\n /////////////////////////\t \n\n\n\n }\n else {\n\n\n console.log('เกิดข้อผิดพลาด', 'ไม่สามารถดึง ID กรุณากรอก URL อื่น', 'error');\n\n\n }\n }\n }\n else {\n\n console.log('เกิดข้อผิดพลาด', 'URL ที่ใส่ ต้องเป็น URL ของ Facebook', 'error');\n }\n }\n else {\n\n console.log('นี่ไม่ใช่ URL ', 'กรุณากรอก URL ของ Facebook', 'error');\n\n }\n\n\n }\n\n\n\n\n\n\n\n function extract_page_id(page_id) {\n if (!isNaN(page_id)) {\n console.log(\"page id=\" + page_id);\n title = \"Page id:\";\n append_html_code(title, page_id);\n } else {\n alert(\"URL is tampered.\");\n }\n }\n function extract_post_id(post_id) {\n if (!isNaN(post_id)) {\n console.log(\"post_id=\" + post_id);\n title = \"Post id:\";\n append_html_code(title, post_id);\n } else {\n alert(\"URL is tampered.\");\n }\n }\n function event_post_id_append(post_id) {\n if (!isNaN(post_id)) {\n console.log(\"event_post_id=\" + post_id);\n title = \"Event post id:\";\n append_html_code(title, post_id);\n } else {\n alert(\"URL is tampered.\");\n }\n }\n function group_post_id_append(post_id) {\n if (!isNaN(post_id)) {\n console.log(\"group_post_id=\" + post_id);\n title = \"Group post id:\";\n append_html_code(title, post_id);\n } else {\n alert(\"URL is tampered.\");\n }\n }\n function id_extract_event(account_username) {\n if (!isNaN(account_username)) {\n console.log(\"Event id is:\" + account_username);\n title = \"Event ID:\";\n append_html_code(title, account_username);\n } else {\n alert(\"URL is tampered.\");\n }\n }\n function extract_video_id(video_id) {\n if (!isNaN(video_id)) {\n console.log(\"video id is=\" + video_id);\n title = \"Post ID/ Video id:\";\n append_html_code(title, video_id);\n }\n }\n function id_extract_group(account_username) {\n\n if (isNaN(account_username)) {\n pageurl = \"https://mbasic.facebook.com/groups/\" + account_username;\n dinesh = new XMLHttpRequest();\n dinesh.open(\"GET\", pageurl, true);\n dinesh.onreadystatechange = function () {\n console.log(`dinesh.readyState: `, dinesh.readyState);\n console.log(`dinesh.status: `, dinesh.status);\n if (dinesh.readyState == 4 && dinesh.status == 200) {\n var responsa = dinesh.responseText.match(/\\/groups\\/\\d+/g)[0];\n responsa = responsa.replace(\"\\/groups\\/\", \"\");\n title = \"Group ID:\";\n console.log(title + responsa);\n append_html_code(title, responsa);\n }\n }\n dinesh.send();\n } else {\n title = \"Group ID:\";\n console.log(title + account_username);\n append_html_code(title, account_username);\n }\n }\n\n\n\n\n\n function append_html_code(title, id) {\n title = '<b style=\"font-size:20px;font-weight:bold\">' + title;\n text = text + '<p>' + title + '<input class=\"copytext' + id + '\" type=\"text\" value=\"' + id + '\" style=\"font-size:30px; text-align:center;width:90%;\" ><a datashow=\"copytext' + id + '\" class=\"copyto btn-floating mb-1 btn-flat waves-effect waves-light pink accent-2 white-text\"> <i class=\"material-icons\">content_copy</i></a><p></b>';\n\n console.log({\n title: 'Copy ตัวเลขไปใช้ได้เลยค่ะ',\n type: 'success',\n html: text,\n })\n // iziToast.success({\n // title: 'เรียบร้อย',\n // position: 'topCenter',\n // timeout: 3000,\n // message: 'พบ ID แล้ว Copy ไปใช้ได้เลย',\n // });\n }\n\n\n\n\n\n\n function extraction_process_url_params(url_array_collect) {\n console.log(url_array_collect);\n\n\n if (url_array_collect[2]) {\n if (url_array_collect[2] == \"permalink\") {\n if (url_array_collect[0] == \"groups\") {\n id_extract_group(url_array_collect[1]);\n if (!isNaN(url_array_collect[3])) {\n group_post_id_append(url_array_collect[3]);\n }\n }\n if (url_array_collect[0] == \"events\") {\n id_extract_event(url_array_collect[1]);\n if (!isNaN(url_array_collect[3])) {\n event_post_id_append(url_array_collect[3]);\n }\n }\n }\n if (url_array_collect[1] == \"videos\") {\n extract_video_id(url_array_collect[2]);\n }\n if (url_array_collect[0] == \"pages\") {\n if (!isNaN(url_array_collect[2])) {\n extract_page_id(url_array_collect[2]);\n }\n }\n if (url_array_collect[1] == \"posts\") {\n if (url_array_collect[0]) {\n id_extract_account(url_array_collect[0]);\n }\n if (!isNaN(url_array_collect[2])) {\n extract_post_id(url_array_collect[2]);\n }\n } else {\n id_extract_account(url_array_collect[0]);\n }\n } else {\n if (url_array_collect[1]) {\n if (url_array_collect[0] == \"groups\") {\n id_extract_group(url_array_collect[1]);\n }\n if (url_array_collect[0] == \"events\") {\n id_extract_event(url_array_collect[1]);\n }\n if (url_array_collect[0] == \"pg\") {\n id_extract_account(url_array_collect[1]);\n }\n } else {\n id_extract_account(url_array_collect[0]);\n }\n }\n }\n\n\n\n\n\n\n\n\n\n function id_extract_account(account_username) {\n\n function error_msgs() {\n //toastr.error(\"Unable to retrieve account ID\");\n }\n\n if (isNaN(account_username)) {\n responsa = '';\n pageurl = \"https://m.facebook.com/\" + account_username + \"\";\n\n dinesh = new XMLHttpRequest();\n dinesh.open(\"GET\", pageurl, true);\n dinesh.onreadystatechange = function () {\n if (dinesh.readyState == 4 && dinesh.status == 200) {\n var responsa = dinesh.responseText;\n responsa = responsa.replace(/&quot;/g, '\"');\n if (responsa.match(/\"profile_id\":\\d+/g)) {\n\n var last_array = (responce_id = responsa.match(/\"profile_id\":\\d+/g).length - 1);\n\n var responce_id = responsa.match(/\"profile_id\":\\d+/g)[last_array];\n responce_id = responce_id.replace('\"profile_id\":', \"\");\n if (!isNaN(responce_id)) {\n title = \"Account ID:\";\n console.log(title + \"=\" + responce_id);\n append_html_code(title, responce_id);\n\n\n } else {\n error_msgs();\n }\n }\n\n else\n\n if (responsa.match(/page_id:\\\"\\d+/g)) {\n\n var last_array = responsa.match(/page_id:\\\"\\d+/g)[0];\n responce_id = last_array.replace('page_id:\\\"', \"\");\n if (!isNaN(responce_id)) {\n title = \"Page ID:\";\n console.log(title + responce_id);\n append_html_code(title, responce_id);\n\n\n } else {\n error_msgs();\n }\n }\n\n\n\n\n }\n }\n dinesh.send();\n } else {\n alert(\"account id is:\" + responsa.id);\n //document.getElementById(\"fst789_id_extractor_result\").innerText = account_username;\n }\n }\n\n\n\n\n\n\n\n\n\n function getParam(sname, location_search) {\n if (location_search && sname) {\n\n var params = location_search.substr(location_search.indexOf(\"?\") + 1);\n var sval = \"\";\n params = params.split(\"&\");\n // split param and value into individual pieces\n for (var i = 0; i < params.length; i++) {\n temp = params[i].split(\"=\");\n if ([temp[0]] == sname) { sval = temp[1]; }\n }\n\n return sval;\n } else {\n return '';\n }\n }\n\n}", "function getHostInfo() {\n $.ajax({\n type: 'GET',\n url: 'https://api.twitch.tv/kraken/streams/' + data.hosts[0].target_login,\n headers: {\n 'Client-ID': 'f2cmg4s30fnzmq7zbcx8rcsfxdc1san'\n },\n success: function(data) {\n console.log(data);\n if (data.stream) {\n $(\"#title\").text(\"Panda is currently hosting \" + data.stream.channel.display_name);\n $(\"#streaminfo\").text(data.stream.channel.status);\n chatSrc = \"https://www.twitch.tv/\" + data.stream.channel.name + \"/chat\";\n }\n else streamOffline();\n }\n });\n\n\n }", "function getUpstreamUrl(containerDetails) {\n var ports = containerDetails.NetworkSettings.Ports;\n for (id in ports) {\n if (ports.hasOwnProperty(id)) {\n return 'http://' + containerDetails.NetworkSettings.IPAddress + ':' + id.split('/')[0];\n }\n }\n}", "function getHostname(url) {\n let nURL = \"\";\n if (url[5] === \":\") {\n url = url.substr(8, url.length);\n } else {\n url = url.substr(7, url.length);\n }\n for (i in url) {\n if (url[i] === \"/\") {\n break;\n } else {\n nURL += url[i];\n }\n }\n return nURL;\n }", "function linkpart(url,echo){\r\n let link = url.toString();\r\n link = link.split(\"//\");\r\n if(echo != undefined || null){\r\n if(echo == \"protocol\"){\r\n return link[0]+\"//\";\r\n }\r\n else{\r\n if(link.length = 1){\r\n return false;\r\n }\r\n link = link[1].split(\"/\");\r\n if(echo == \"domain\"){\r\n return link[0];\r\n }\r\n else if(echo == \"data\"){\r\n let data = new Array;\r\n let i;\r\n for(i = 1;i<link.length;i++){\r\n data.push(link[i]);\r\n }\r\n return data;\r\n }\r\n }\r\n \r\n }\r\n else{\r\n let data = new Array;\r\n let parts = new Array;\r\n data.push(link[0]);\r\n link = link[1].split(\"/\");\r\n parts.push(link[0]);\r\n for(i = 1;i<link.length;i++){\r\n if(link[i] == \"\"){\r\n\r\n }else{\r\n parts.push(link[i]);\r\n }\r\n }\r\n data.push(parts);\r\n return data;\r\n }\r\n}", "function xmlhttp_handler() {\n\tif(this.readyState == this.DONE) {\n\t\tif(this.status == 200) \n\t\t{\n\t\t\tif (debug || 1)\n\t\t\t\tconsole.log(\"[+] headers retrieved (\" + this.containerID + \")\");\n\n\t\t\t/* contains all IP address sources as extracted \n\t\t\t\tfrom the 'received from' headers of the message */\n\t\t\tvar ip_sources = new Array();\n\n\t\t\t/* print the 'from' line of the message. \n\t\t\t\tused to easily identify a message in the console. */\n\t\t\tif (verbose || 1)\n\t\t\t\tconsole.log(this.responseText.match(new RegExp('From:[^\\n]+','gi')));\n\n\t\t\t/* extract 'received from' headers */\n\t\t\tvar rcv_from \n\t\t\t\t= this.responseText.match(new RegExp('Received: from[^)]+','gi'));\n\n\t\t\tif (rcv_from == null) {\n\t\t\t\tif (debug) {\n\t\t\t\t\tconsole.log(\"\\n--- BEGIN MESSAGE DUMP --- --- ---\\n\");\n\t\t\t\t\tconsole.log(this.responseText);\n\t\t\t\t\tconsole.log(\"\\n--- END MESSAGE DUMP --- --- ---\\n\");\n\t\t\t\t}\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t/* for each message header extract the source IP address */\n\t\t\tif (debug)\n\t\t\t\tconsole.log(\"\\n--- --- --- BEGIN MESSAGE HEADERS --- --- ---\\n\");\n\n\t\t\tfor (var i = 0; i < rcv_from.length; i++) {\n\t\t\t\tif (debug)\n\t\t\t\t\tconsole.log(rcv_from[i]);\n\n\t\t\t\t/* get the part inside the parenthesis */\n\t\t\t\tvar rcv_from_actual = rcv_from[i].split('(');\n\t\t\t\tif (rcv_from_actual == \"\") continue;\n\t\t\t\tif (rcv_from_actual.length < 2) continue;\n\t\t\t\trcv_from_actual = rcv_from_actual[1];\n\n\t\t\t\t/* get the part inside the brackets [...] */\n\t\t\t\tvar rcv_from_ipaddr \n//\t\t\t\t\t= rcv_from_actual.match(new RegExp('\\\\[[^\\\\]]+','gi'));\n\t\t\t\t// match against something that looks like an IP address and ends with a space or ] or ) - doing this to avoid matching IP-adresses-prefixed domains (e.g., 127.0.0.1-dynclient.foobar.com)\n\t\t\t\t\t= rcv_from_actual.match(\n\t\t\t\t\t\tnew RegExp('[0-9]+\\.[0-9]+\\.[0-9]+\\.[0-9]+[\\\\]\\\\) ]','gi'));\n\t\t\t\tif (rcv_from_ipaddr == null) continue;\n\t\t\t\t// get first (and should be only) match\n\t\t\t\trcv_from_ipaddr = rcv_from_ipaddr[0];\n\t\t\t\t// strip away last character (see regexp above)\n\t\t\t\trcv_from_ipaddr \n\t\t\t\t\t= rcv_from_ipaddr.substring(0,rcv_from_ipaddr.length-1);\n//\t\t\t\trcv_from_ipaddr = rcv_from_ipaddr.split('[');\n//\t\t\t\tif (rcv_from_ipaddr.length < 2) continue;\n//\t\t\t\trcv_from_ipaddr = rcv_from_ipaddr[1];\n\n\t\t\t\tif (debug)\n\t\t\t\t\tconsole.log(\"[*] '\" + rcv_from[i] + \"' produced '\" \n\t\t\t\t\t\t+ rcv_from_ipaddr +\"'\");\n\n\t\t\t\t/* push IP source in the array */\n\t\t\t\tip_sources.push(rcv_from_ipaddr);\n\t\t\t}\n\t\t\tif (debug)\n\t\t\t\tconsole.log(\"\\n--- --- --- END MESSAGE HEADERS --- --- ---\\n\");\n\n\t\t\t/* reverse the IP sources array so that the bottom \n\t\t\t\theaders extract comes first */\n\t\t\tip_sources = ip_sources.reverse();\n\n\t\t\t/* process IP sources in the array, \n\t\t\t\tdiscard any private IP addresses \n\t\t\t\tand get the first good candidate */\n\t\t\tfor (var i = 0; i < ip_sources.length; i++) \n\t\t\t{\n\t\t\t\tif (debug)\n\t\t\t\t\tconsole.log(\"[x] considering \" + ip_sources[i]);\n\t\t\t\tif (ip_sources[i].match(new RegExp('^127\\\\.0\\\\.0\\\\.1','gi'))) continue;\n\t\t\t\tif (ip_sources[i].match(new RegExp('^10\\\\.','gi'))) continue;\n\t\t\t\tif (ip_sources[i].match(new RegExp('^192\\\\.168\\\\.','gi'))) continue;\n\n\t\t\t\tif (verbose)\n\t\t\t\t\tconsole.log(\"[x] source IP address is: \" + ip_sources[i]);\n\n\t\t\t\t// Resolve IP address to a geographic location\n\t\t\t\tvar geoclient = new XMLHttpRequest();\n\t\t\t\tgeoclient.original_ip_source = ip_sources[i];\n\t\t\t\tgeoclient.containerID = this.containerID;\n\t\t\t\tgeoclient.onreadystatechange = geolookup_handler;\n\t\t\t\tgeoclient.open(\"GET\", \"http://freegeoip.net/json/\" \n\t\t\t\t\t+ geoclient.original_ip_source, true); // asynchronous\n\t\t\t\tgeoclient.send(null);\n\n\t\t\t\t/* don't process any more source IP addresses in the array. \n\t\t\t\t\tfirst match is what we are looking for. */\n\t\t\t\tbreak; \n\t\t\t}\n\t\t}\n\t}\n}", "function getUpstreamUrl(containerDetails) {\n const ports = containerDetails.NetworkSettings.Ports;\n for (id in ports) {\n if (ports.hasOwnProperty(id)) {\n return 'http://' + containerDetails.NetworkSettings.IPAddress + ':' + id.split('/')[0];\n }\n }\n}", "function FindProxyForURLByAutoProxy(url, host) {\n\nreturn \"DIRECT\";\n}", "function NetworkUtil(){}", "getSongURI(hostname){\n \n if(this.activeSong !== undefined){\n\n return hostname + this.activeSong.filepath;\n }\n else{\n console.log(hostname + encodeURIComponent(\"countdown\" + (new Date().getTime())+ \".mp3\"))\n return hostname + encodeURIComponent(\"countdown\" + (new Date().getTime())+ \".mp3\");// + (new Date().getTime()));\n }\n\n }", "function urlMaker(nameArray) {\n var urls = new Array();\n for (var i = 0; i < userArray.length; i++) {\n var name = nameArray[i];\n //API Query to return JSON status information\n urls[i] = \"https://wind-bow.gomix.me/twitch-api/streams/\" + name + \"?callback=?\";\n }\n return urls;\n }", "function host(url) {\n\t\ttx = ''+url;\n\t\tvar p = tx.indexOf('://');\n\t\tif (p!=-1) {\n\t\t\ttx = tx.substring(p+3);\n\t\t}\n\t\tif (tx.substring(0,4)=='www.') {\n\t\t\ttx = tx.substring(4);\n\t\t}\n\t\tp = tx.indexOf('/');\n\t\tif (p!=-1) {\n\t\t\ttx = tx.substring(0,p);\n\t\t}\n\t\treturn trimm(''+tx);\n\t}", "function GetDeviceIP(){\n showBackgroundImage('wait_message');\n getContent('','/cgi-bin/setup.cgi?GetDeviceIP','function:ShowGetDeviceIP');\n}", "function DataUrl() \n{ \n var url = \"json.php?bucket=m\";\n url += \"&publisher=\";\n if (params['publisher']) \n {\t\n url += params['publisher'];\n }\n url += \"&advertiser=\";\n if (params['advertiser']) \n {\t\n url += params['advertiser'];\n }\n url += \"&adunit=\";\n if (params['adunit']) \n {\t\n url += params['adunit'];\n }\n url += \"&from=\";\n url += Math.floor(lookback);\n return url; \n}", "function parseStub(url, tabId) {\r\n\textracted_blocked_ip = ''; //reset ip\r\n\tis_bad_url = true;\r\n\tif (url.indexOf('//77.37.254.90/zapret/') > -1) { //Onlime (Rostelecom)\r\n\t\tlet arr = /[?&]{1}sa=(\\d+\\.\\d+\\.\\d+\\.\\d+)/.exec(url);\r\n\t\tif (arr!=null) extracted_blocked_ip = arr[1];\r\n\t\tarr = /[?&]{1}url=([^&?]+)/.exec(url);\r\n\t\tif (arr!=null) return decode(arr[1]);\r\n\t\treturn '';\r\n\t}\r\n\tlet domain = extractHostname(url)\r\n\tif (domain == 'blackhole.beeline.ru') { //blackhole.beeline.ru/?url=rutracker.org%2F\r\n\t\tlet arr = /[?&]{1}url=([^&?]+)/.exec(url);\r\n\t\tif (arr!=null) return decode(arr[1]);\r\n\t\t//return '';\r\n\t}\r\n\tif (domain == 'warning.rt.ru' || domain == \"95.167.13.50\" || domain == \"95.167.13.51\") { \r\n\t\t//warning.rt.ru/?id=13&st=0&dt=195.82.146.214&rs=http%3A%2F%2Frutracker.org%2F\r\n\t\tlet arr = /[?&]{1}dt=(\\d+\\.\\d+\\.\\d+\\.\\d+)/.exec(url);\r\n\t\tif (arr!=null) extracted_blocked_ip = arr[1];\r\n\t\tarr = /[?&]{1}rs=([^&?]+)/.exec(url);\r\n\t\tif (arr!=null) return decode(arr[1]);\r\n\t\t//return '';\r\n\t}\r\n\tif (domain == 'blocked.mts.ru') { //http://blocked.mts.ru/info?host=rutracker.org http://blocked.mts.ru/?host=rutracker.org\r\n\t\t//blocked.mts.ru/?host=?url=http%3A%2F%2Frutracker.org%2F&ip=195.82.146.214\r\n\t\tlet arr = /&ip=(\\d+\\.\\d+\\.\\d+\\.\\d+)/.exec(url);\r\n\t\tif (arr!=null) extracted_blocked_ip = arr[1];\r\n\t\tarr = /[?&]{1}url=([^&?]+)/.exec(url);\r\n\t\tif (arr!=null) return decode(arr[1]);\r\n\t\tarr = /[?&]{1}host=([^&?]+)/.exec(url);\r\n\t\tif (arr!=null) return decode(arr[1]);\r\n\t\t//return '';\r\n\t}\r\n\t//if (domain == '') { //http://fz139.ttk.ru/?order=решение%20суда%20по%20делу%20№%203-0726/2015&org=Мосгорсуд&date=2015-12-04&id=262698\r\n\t\t//no domain info\r\n\t//}\r\n\tif (url.indexOf('/freedom-vrn.ru/support/block.html') > -1\r\n\t\t|| (domain=='milecom.ru' && url.indexOf('milecom.ru/zapret.htm') > -1)\r\n\t\t|| url.indexOf('/sovatelecom.ru/ZAPRET.html') > -1\r\n\t\t|| (domain=='tmpk.net' && url.indexOf('tmpk.net/rpn/') > -1)\r\n\t\t|| easy_provider_stub_list[domain]\r\n\t\t|| (domain && domain == localStorage.custom_provider_stub)\r\n\t\t)\r\n\t{\r\n\t\t//if info is not provided, try to remember what last domain was\r\n\t\tif (tabId && saved_last_url[tabId]) return saved_last_url[tabId]; //return old url if exists\r\n\t\treturn '';\r\n\t}\r\n\tis_bad_url = false;\r\n\treturn url;\r\n}", "function debug_ips() {\n console.log(ip_hashmap.keys());\n }", "function getProxyUri(req) {\n // var daili_url;\n // console.log((req.apiurl || req.url), qf_uris.indexOf((req.apiurl || req.url)))\n // if (qf_uris.indexOf((req.apiurl || req.url).split('?')[0]) > -1) {\n // daili_url = qf_proxy_url;\n // } else {\n // daili_url = proxy_url;\n // }\n // return daili_url;\n return proxy_url;\n}", "function ShowConnections(url, cache2)\n{\n\t//\n\t//TODO CHANGE FOR NEW REDISIGN!\n\t//\n\tlet id = url.match(/\\/(tt\\d+)\\//)[1];\n\t//console.log(id);\n\t//console.log(cache2);\n\tif ($.isEmptyObject(cache2[id][\"connects\"]))\n\t{\n\t\txmlIMDB(\"connections\", document.URL, cache2);\n\t\treturn;\n\t}\n\n\tlet contentH = \"\";\n\tlet contents = \"\";\n\n\tconst begHead = \"<div class='head'>\\\n\t<span id='hide-actress' class='hide-link' style='display: none;'> Hide & nbsp; <img src='http://ia.media-imdb.com/images/G/01/imdb/images/icons/hide-1061525577._CB522736167_.png' class='absmiddle' alt='Hide' width='18' height='16'></span>\\\n\t<span id='show-actress' class='show-link' style='display: inline;'>Show&nbsp;<img src='http://ia.media-imdb.com/images/G/01/imdb/images/icons/show-582987296._CB522736544_.png' class='absmiddle' alt='Show' width='18' height='16'></span>\";\n\tconst endHead = \"</div>\";\n\n\tconst begContent = \"<div class='filmo-category-section' style='display:block;'>\";\n\tconst endContent = \"</div>\";\n\n\tconst begContentRowOdd = \"<div class='filmo-row odd' id='self-tt1001361'>\";\n\tconst endContentRowOdd = \"</div>\";\n\n\tconst begContentRowEven = \"<div class='filmo-row even' id='self-tt1001361'>\";\n\tconst endContentRowEven = \"</div>\";\n\n\tfor (let i = 0; i < Object.keys(cache2[id][\"connects\"]).length; i++)\n\t{\n\t\tcontents = \"\";\n\t\t//console.log(Object.keys(cache[id][\"connects\"]).length);\n\t\t//SORT TODO FOLOWS FIRST AND FOLLOING BY SECCONG, AND MAkE SETTINGS BY SHOWING SPIN OFF OR NOT\n\t\tfor (let x = 0; x < (Object.keys(cache2[id][\"connects\"][i]).length - 1); x++)\n\t\t{\n\t\t\tif (x % 2)\n\t\t\t{\n\t\t\t\tcontents += begContentRowEven + \"<span class='year_column'>&nbsp;\" + cache2[id][\"connects\"][i][x][\"year\"] + \"</span>\"\n\t\t\t\t\t+ \"<b><a href='https://www.imdb.com/title/\" + cache2[id][\"connects\"][i][x][\"id\"] + \"'>\" + cache2[id][\"connects\"][i][x][\"nameMovie\"] + \"</a></b>\"\n\t\t\t\t\t+ \"<br>\" + cache2[id][\"connects\"][i][x][\"text\"] + endContentRowEven;\n\t\t\t} else\n\t\t\t{\n\t\t\t\tcontents += begContentRowOdd + \"<span class='year_column'>&nbsp;\" + cache2[id][\"connects\"][i][x][\"year\"] + \"</span>\"\n\t\t\t\t\t+ \"<b><a href='https://www.imdb.com/title/\" + cache2[id][\"connects\"][i][x][\"id\"] + \"'>\" + cache2[id][\"connects\"][i][x][\"nameMovie\"] + \"</a></b>\"\n\t\t\t\t\t+ \"<br>\" + cache2[id][\"connects\"][i][x][\"text\"] + endContentRowOdd;\n\t\t\t}\n\t\t}\n\t\tcontentH += begHead + \"<a name='actress'>\" + cache2[id][\"connects\"][i][\"name\"] + \"</a> (\" + (Object.keys(cache2[id][\"connects\"][i]).length - 1) + \")\" + endHead + begContent + contents + endContent;\n\t}\n\tconsole.log(contentH);\n\n\tconst divConnections = $(\"<div id=imdbe_divconnections class=article></div>\").html(\"<div> \\\n<span class='rightcornerlink'> \\\n<a href='https://www.imdb.com/title/\" + id + \"/movieconnections'>Learn more</a> \\\n</span>\\\n<div class=name><h1 class='h2'>Connections</h1></div>\\\n<div id='filmography'>\" + contentH + \"</div >\\\n\");\n\n\n\t$(\"section[data-testid='title-cast']\").before(divConnections);\n\n\tfor (let i = 0; i < Object.keys(cache2[id][\"connects\"]).length; i++)\n\t{\n\t\t//console.log(((cache[id][\"connects\"][i][\"name\"] !== \"Follows\") | (cache[id][\"connects\"][i][\"name\"] !== \"Followed by\") ? \"yes\" : \"no\"));\n\t\tif (cache2[id][\"connects\"][i][\"name\"] !== \"Follows\")\n\t\t{\n\t\t\tif (cache2[id][\"connects\"][i][\"name\"] !== \"Followed by\")\n\t\t\t{\n\t\t\t\t$(\"#imdbe_divconnections\").find(\".head:eq(\" + i + \")\").next(\".filmo-category-section\").toggle();\n\t\t\t\t//console.log($(\"#imdbe_divconnections\").find(\".head:eq(\" + i + \")\"));\n\t\t\t}\n\t\t}\n\t}\n\n\tconsole.log(cache2[id][\"connects\"]);\n\n\tif (Object.keys(cache2[id][\"connects\"]).length > 0 || typeof cache2[id][\"connects\"] === \"undefined\")\n\t{\n\t\t//$(\"#filmography\").append($(\"<div class=article></div>\").html(\"Connections\"));\n\t} else\n\t{\n\t\tconsole.log($(\"#filmography\"));\n\t\t$(\"#filmography\").append($(\"<div class=article></div>\").html(\"No Connections\"));\n\t}\n\n\tSetEvents(\"connections\");\n}", "async resolveToLongURLFormat(url) {\n // URL is in the following format\n // [protocol://]host1[,host13][:port1][,host2:port2][/service_name][:server][/instance_name]\n\n const urlWithoutWhiteSpaces = url.replace(/\\s/g, \"\");\n let bool = 0;\n let protocol = null, hostInfo = null, serviceName = null, serverMode = null, instanceName = null;\n for (const match of urlWithoutWhiteSpaces.matchAll(EZ_URL_PATTERN)) {\n bool = 1;\n protocol = match.groups.protocol;\n hostInfo = match.groups.hostinfo;\n serviceName = match.groups.servicename;\n serverMode = match.groups.servermode;\n instanceName = match.groups.instance;\n }\n if (!bool) {\n // No Processing required as the URL is not in ezconnect format.\n errors.throwErr(errors.ERR_INVALID_EZCONNECT_SYNTAX, 'input string not in easy connect format', urlWithoutWhiteSpaces);\n }\n\n if (protocol == null) {\n if (!(url.includes(\"//\")))\n protocol = 'TCP';\n } else if (protocol.toLowerCase() != 'tcp' && protocol.toLowerCase() != 'tcps') {\n errors.throwErr(errors.ERR_INVALID_EZCONNECT_SYNTAX, 'Unsupported protocol in thin mode', protocol);\n }\n // Try to get the proxy information from URL properties\n const proxyHost = this.urlProps.get(\"HTTPS_PROXY\");\n const proxyPort = this.urlProps.get(\"HTTPS_PROXY_PORT\");\n const addressInfo =\n await this.buildAddressList(hostInfo, protocol, proxyHost, proxyPort);\n\n const connectionIdPrefix =\n this.urlProps.get(\"CONNECTION_ID_PREFIX\");\n // Build the available information in TNS format.\n const parts = [];\n if (this.lb)\n parts.push(\"(LOAD_BALANCE=ON)\");\n parts.push(this.buildDescriptionParams());\n parts.push(addressInfo);\n parts.push(this.buildConnectData(serviceName, serverMode, instanceName,\n connectionIdPrefix));\n parts.push(this.buildSecurityInfo(protocol));\n return `(DESCRIPTION=${parts.join('')})`;\n }", "function ShowConnections()\r\n{\r\n\tvar clients = serv.GetWebSockClients();\r\n\t\r\n\tif( clients.length > 0 )\r\n\t{\r\n \t//Make a list of clients.\r\n \tvar list = \"\";\r\n \tfor( var i=0; i<clients.length; i++ )\r\n \t list += clients[i].remoteAddress + \"\\n\";\r\n \t \r\n \t//Show client list.\r\n \ttxt.SetText( list );\r\n\t}\r\n}", "function FindProxyForURL(url, host) {\n host = host.toLowerCase();\n if (\n dnsDomainIs(host, \"gnulug.org\")\n || dnsDomainIs(host, \"open-nsm.net\")\n || shExpMatch(host, \"192.17.239.*\")\n )\n return \"SOCKS 127.0.0.1:50000\"; // (IP:port)\n\n if (\n dnsDomainIs(host, \"draconyx.net\")\n )\n return \"PROXY 127.0.0.1:80\"\n\n //if (dnsDomainIs(host, \"test.com\"))\n // return \"SOCKS 127.0.0.1:1234\"; // (IP:port)\n\n return \"DIRECT\";\n}", "get liveServiceHostname() {\n return url.format({\n protocol: this.liveServiceProtocol,\n host: this.liveServiceHost\n });\n }", "function getShortURL () {\n\t//base 36 characters\n\tvar alphanumeric = ['0','1','2','3','4','5','6','7','8','9','A','B',\n\t\t\t\t\t\t'C','D','E','F','G','H','I','J','K','L','M','N',\n\t\t\t\t\t\t'O','P','Q','R','S','T','U','V','W','X','Y','Z'];\n\tvar urlString = \"http://localhost:3000/\";\n\tfor (i = 0; i < 4; i++) {\n\t\tvar num = randomNum(0,35);\n\t\turlString = urlString + alphanumeric[num];\n\t}\n\n\treturn urlString;\n}", "function getapi(){\n\tif (window.location.protocol != \"https:\"){\n\t\treturn \"http://wev.se/etc/api\";\n\t} else{\n\t\treturn \"https://wev.se/etc/api\";\n\t}\n}", "onMessageReceived(msg, msgInfo) {\n if (msgInfo.address === ip.address()) {\n // if the source address is the own ip address return\n return;\n } else {\n // else forward the message the the app\n this.mainWindow.webContents.send(\"receivedMessage\", msg.toString());\n }\n }", "function sendURL() \r\n{\r\n\tsocketSend('U' + webFilePath + nextSlideName);\r\n}", "function normalizeImageUrl(data) {\n\t return data.replace('www.dropbox.com', 'dl.dropboxusercontent.com');\n\t}", "get apiHostname() {\n return url.format({\n protocol: this.apiProtocol,\n host: this.apiHost\n });\n }", "function getkevalue() {\n //var returnval = jsaction.getkeyvalue(); //本地代码获取基础数据 地址|用户id|用户店ID|key\n //var returnval = \"http://218.6.160.126:8090|2|xlhl|http://http://218.6.160.126:8091/|http://171.211.126.122:8092/|1\";\n\n // http://171.211.126.122:8092/ --localhost:5819 -- 514|25 --- 572|26\n\n //330\n var returnval = \"\";\n //if(window.localStorage.userinfo==undefined){\n // window.localStorage.userinfo=\"http://localhost/|1|2|xlhl|http://localhost:5819/|http://171.211.126.122:8092/|1,1|http://192.168.1.253:8095/|http://192.168.1.98:8088\";\n //}\n // returnval=\"http://localhost/|1|2|xlhl|http://localhost:5819/|http://171.211.126.122:8092/|1,1|http://192.168.1.253:8095/|http://192.168.1.253:8092\";\n returnval=\"http://localhost/|1|2|xlhl|http://localhost:5819/|http://171.211.126.122:8092/|1,1|http://192.168.1.253:8095/|http://192.168.1.253:8092\";\n // returnval=\"http://localhost/|1|2|xlhl|http://localhost:5819/|http://171.211.126.122:8092/|1,1|http://192.168.1.253:8095/|https://xilai99.com\";\n // var returnval = \"http://localhost:5080/|1|2|xlhl|http://171.211.126.122:8091/|http://171.211.126.122:8092/|2,1|1|\";\n //var returnval = \"http://localhost:5080/|585|28|xlhl|http://localhost:5819/|http://171.211.126.122:8092/|3,1|3,1|192.168.1.193:8088\";\n //var returnval = \"http://localhost:5080/|606|32|xlhl|http://171.211.126.122:8091/|http://171.211.126.122:8092/|1,1|1|\"\n // var returnval = \"http://localhost:5080/|1|2|xlhl|http://localhost:5819/|http://171.211.126.122:8092/|1|1|http://localhost:8088\";\n // var returnval = \"http://localhost:5080/|1|2|xlhl|http://localhost:5819/|http://171.211.126.122:8092/|3,1|3,1|http://localhost:8088\";\n // var returnval = \"http://localhost:5080/|619|3|xlhl|http://localhost:5819/|http://171.211.126.122:8092/|1|http://171.211.126.122:8092/\";\n\n //var returnval = \"http://localhost:5080/|28|2|xlhl|http://192.168.1.253:8095|6513513|123\"\n // var returnval = \"http://211.149.163.185:8090/|28|2|xlhl|http://171.211.126.122:8091|http://171.211.126.122:8092/|1\";\n\n // var returnval = \"http://localhost:5080/|1|2|xlhl|http://192.168.1.253:8091\";//\n\n // var returnval = \"http://localhost:5080/|1|8|xlhl|http://218.6.160.126:8091/|http://218.6.160.126:8092/\";\n // var returnval = \"http://localhost:5080/|9|314|xlhl|http://192.168.1.253:8091|http://192.168.1.253:8092\";//\n\n //var returnval = window.localStorage.userinfo;\n if (returnval == \"\" || returnval == undefined) {\n\n alert(\"账号过期重新登入\");\n window.location.href= \"http://211.149.163.185:8090/Login/loginnew.aspx\";\n }\n var vararry = returnval.split(\"|\");\n var keyobj = new Object();\n keyobj.url = vararry[0];//处理服务器ip 211.\n keyobj.userid = vararry[1];\n keyobj.branchid = vararry[2];\n keyobj.key = vararry[3];\n keyobj.brinchip = vararry[4];//文件上传处理 171\n keyobj.branchshowip = vararry[5]; //文件展示ip\n keyobj.rolestate = vararry[6]; // 供应商时候标识供应商类型和权限 逗号隔开 第一个参数 1:桁架 2:灯光 3:灯光和桁架 第二个参数:1 代表管理员\n keyobj.loackshowip = vararry[7];\n keyobj.apiurl = vararry[8];//处理服务器ip 211.\n return keyobj;\n\n}", "function detectHost() {\n\t\tvar host;\n\t\thost = (location.hostname.indexOf(\"10.128\") === 0) ? \"localhost\" : location.hostname;\n\n\t\tswitch (host) {\n\t\t\tcase \"localhost\":\n\t\t\tcase \"127.0.0.1\":\n\t\t\tcase \"skynet\":\n\t\t\tcase \"skynet-1\":\n\t\t\t\thost = \"local\";\n\t\t\t\tbreak;\n\t\t\tcase \"www.csps-efpc.gc.ca\":\n\t\t\tcase \"csps-efpc.gc.ca\":\n\t\t\t\thost = \"public\";\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\thost = \"prod\";\n\t\t\t\tbreak;\n\t\t}\n\t\t//console.log(host);\n\t\treturn host;\n\n\t}", "async getTopRiskyIPAddresses(ts, te) {\n let token = localStorage.getItem(\"interset_token\");\n axios.defaults.headers.common['Authorization'] = token;\n // console.log(ts);\n let url = `${API_URL}/api/search/0/ips/topRisky?sort=maximum&markup=false&tz=UTC%2B8&count=10&keepAlive=300000`\n if((ts!==0) && (te!==0)){\n url = url + '&ts=' + ts + '&te=' + te;\n }\n // console.log(url);\n \n const response = await axios.get(url);\n return response.data;\n }", "function is_fast_packet (pgn)\n{\n switch (pgn)\n {\n case 65536 :\n case 126208 :\n case 126464 :\n case 126720 :\n case 126976 :\n case 126983 :\n case 126984 :\n case 126985 :\n case 126986 :\n case 126987 :\n case 126988 :\n case 126996 :\n case 126998 :\n case 127233 :\n case 127237 :\n case 127489 :\n case 127496 :\n case 127497 :\n case 127498 :\n case 127500 :\n case 127503 :\n case 127510 :\n case 127513 :\n case 128275 :\n case 128520 :\n case 129029 :\n case 129038 :\n case 129039 :\n case 129040 :\n case 129041 :\n case 129044 :\n case 129045 :\n case 129284 :\n case 129285 :\n case 129301 :\n case 129302 :\n case 129538 :\n case 129540 :\n case 129541 :\n case 129542 :\n case 129545 :\n case 129547 :\n case 129549 :\n case 129550 :\n case 129551 :\n case 129556 :\n case 129792 :\n case 129793 :\n case 129794 :\n case 129795 :\n case 129796 :\n case 129797 :\n case 129798 :\n case 129799 :\n case 129800 :\n case 129801 :\n case 129802 :\n case 129804 :\n case 129805 :\n case 129806 :\n case 129807 :\n case 129808 :\n case 129809 :\n case 129810 :\n case 130060 :\n case 130061 :\n case 130064 :\n case 130065 :\n case 130066 :\n case 130067 :\n case 130068 :\n case 130069 :\n case 130070 :\n case 130071 :\n case 130072 :\n case 130073 :\n case 130074 :\n case 130320 :\n case 130321 :\n case 130322 :\n case 130323 :\n case 130324 :\n case 130560 :\n case 130567 :\n case 130569 :\n case 130570 :\n case 130571 :\n case 130572 :\n case 130573 :\n case 130574 :\n case 130577 :\n case 130578 :\n case 130579 :\n case 130580 :\n case 130581 :\n case 130582 :\n case 130583 :\n case 130584 :\n case 130585 :\n case 130586 :\n case 130816 :\n case 130817 :\n case 130818 :\n case 130819 :\n case 130820 :\n case 130821 :\n case 130824 :\n case 130827 :\n case 130828 :\n case 130831 :\n case 130832 :\n case 130834 :\n case 130835 :\n case 130836 :\n case 130837 :\n case 130838 :\n case 130839 :\n case 130840 :\n case 130842 :\n case 130843 :\n case 130845 :\n case 130847 :\n case 130850 :\n case 130851 :\n case 130856 :\n case 130880 :\n case 130881 :\n case 130944 :\n {\n fast_packet = true;\n break;\n }\n default :\n {\n fast_packet = false;\n break;\n }\n }//end switch (pgn)\n}//end function is_fast_packet", "function isHostnameMatch(url) {\n // return urlWithoutProtocol(url).substring(hostReg, host.length) === host;\n return false;\n }", "function processSpotifyLink(link) {\n const match = link.match(/^([A-Z0-9]{4}) (https:\\/\\/open\\.spotify\\.com\\/track\\/|spotify:track:)(.{22})/);\n if (match) {\n return [match[1], 'spotify:track:' + match[3]];\n }\n else {\n return [null, null];\n }\n}", "function getSIGameDetailsUrl(gameID) {\n return 'http://www.si.com/pbp/liveupdate?json=1&sport=basketball%2Fnba&id=' +\n gameID + '&box=true&pbp=true&linescore=true';\n}", "function getImageUrl(imageSrc) {\n if (imageSrc) {\n imageSrc = imageSrc.replace(\"www.dropbox\", \"dl.dropboxusercontent\").split(\"?dl=\")[0];\n imageSrc = imageSrc.replace(\"dropbox.com\", \"dl.dropboxusercontent.com\").split(\"?dl=\")[0];\n imageSrc = imageSrc.replace(\"dl.dropbox.com\", \"dl.dropboxusercontent.com\");\n }\n return imageSrc;\n }", "function fallback_graphs(data) {\n for(var s = 0; s < 8; s++) {\n create_graph(data, '&host=' + data['host'] + '&srv=' + data['service'] + '&source=' + s);\n }\n}", "function rappelPing(host,session,n,tab)\n{\nif(!(verifierIp(host))){console.log(\"erreur\");return;}\nif(n==0)\n{\n//------------------------------------------->constatation err er\n\nif(tab.length!=50){\n//console.log(\"erreur,hote:\"+host+\" longueur du tableau:\"+tab.length);\n//console.log(tab);\ninterroger(host);\n}\n\n\n//----------------------------condition d'arret->transmission dans la db\nconsole.log(\"host:\"+host);\nvar chiffres=statistique(tab);\nconsole.log(chiffres);\n\nHost.find({ip:host}).exec(function(err,found){\n_.each(found,function(h){\nh.last_check=new Date();\nh.moyenne=chiffres.moyenne;\nh.statu=(chiffres.perte>45)?\"down\":\"up\";\nh.perte_paquet=chiffres.perte;\nh.min=chiffres.min;\nh.max=chiffres.max;\nh.save(function(err,s){\nHost.publishUpdate(s.id,s);\n});\n});\n\nLog_ping.create({ip:host,moyenne:chiffres.moyenne,\nperte_paquet:chiffres.perte,\nmin:chiffres.min,\nmax:chiffres.max\n}).exec(function(){\n});\n\n\n});\n\n//-------------−>reinitialisation des valeurs\n\ntab=[];\n//ev.emit(\"vita\",host);\n}\nelse\n{\n///------------------iteration de la boucle\n\n//------------------>si host---->regexp diso retour\n\nif(verifierIp(host) && session)\nsession.pingHost(host,function(error,target,sent,rcvd){\nvar reprise=false;\n\nif(error){\n//console.log(error.toString()+\"pour hote:\"+target);\n//console.log(target);\nif(error.toString()==\"Error: Socket closed\")reprise=true;\n}\n\nvar r=(error instanceof ping.RequestTimedOutError)?false:true;\ntab.push({\ntemps:(!r)?0:(rcvd-sent),\nreached:r\n});\n\n//console.log((rcvd-sent)+\" reach \"+r);\nif(reprise){\nif(verifierIp(target))\ninterroger(target);\nconsole.log(\"reprise pour:\"+target);\n}\nelse\nrappelPing(host,session,n-1,tab);\n\n});\n\n\n}\n\n}", "function extract_host(u){\n\treturn /^https?:\\/\\/[\\.\\-0-9a-z]+/i.exec(u)[0] + \"/\";\n}", "function showJsonIP(ip) {\n var output = 'IP '\n +'Src: '+ip.ipSrc\n +' Dst: '+ip.ipDst\n +'<br>'\n + showJsonTransport(ip.transport);\n return output;\n}", "function checkEtcHost() {\r\n page.onResourceRequested = function(requestData, networkRequest) {\r\n var pattern = /https?:\\/\\/(.+)\\.ey\\.sandcats\\.io/;\r\n var match = pattern.exec(requestData.url);\r\n if (match !== null && match[1]) {\r\n if (config(WILDCARD_DOMAIN_PREFIX + match[1]) === undefined) {\r\n if (fs.isFile('/etc/hosts')) {\r\n var hosts = fs.open('/etc/hosts', 'r');\r\n var current = hosts.read();\r\n hosts.close();\r\n if (current.indexOf(match[1] + \".ey.sandcats.io\") < 0) {\r\n // append\r\n var ahosts = fs.open('/etc/hosts', 'a');\r\n if (current[current.length - 1] != '\\n') {\r\n ahosts.write('\\n');\r\n }\r\n ahosts.write('10.20.124.1\\t' + match[1] + '.ey.sandcats.io' + '\\n');\r\n ahosts.close();\r\n }\r\n config(WILDCARD_DOMAIN_PREFIX + match[1], true);\r\n }\r\n }\r\n }\r\n };\r\n}", "function getHostname(url) {\n return decodeURIComponent(url).replace(/.*\\/\\//, \"\").replace(/\\/.*$/, \"\");\n}", "async function ipLookUp(ip) {\n const url = `http://ip-api.com/json/${ip}`; // 45 requests per minute\n const url_free = `http://geolocation-db.com/json/${ip}`; // free and slow (CORS errors)\n \n const response = await fetch(url_free);\n const data = await response.json()\n return data;\n}", "function getChannelNames(urls) {\n\n const chNames = []\n urls.forEach(url => {\n let splittedUrl = url.split('/')\n let idn = splittedUrl[splittedUrl.length - 2]\n\n if (idn == 'channel'){\n chNames.push(\".\" + splittedUrl[splittedUrl.length - 1])\n }else{\n chNames.push(splittedUrl[splittedUrl.length - 1])\n }\n })\n\n return chNames\n}" ]
[ "0.5768341", "0.53459907", "0.5262719", "0.51721704", "0.515178", "0.5121218", "0.50644404", "0.50459456", "0.50412184", "0.49936128", "0.49880514", "0.49574947", "0.4955964", "0.4913962", "0.48788762", "0.48631275", "0.48441955", "0.48419645", "0.48365718", "0.48365718", "0.48313007", "0.48229802", "0.48112902", "0.47912654", "0.47886246", "0.4775729", "0.47592154", "0.47546604", "0.47458115", "0.47444957", "0.47424", "0.47380272", "0.47196817", "0.47181684", "0.47132468", "0.4705826", "0.4689566", "0.4673249", "0.46728808", "0.46718642", "0.46501735", "0.4647", "0.4643577", "0.46286467", "0.46262747", "0.4620263", "0.46152562", "0.4608176", "0.45977548", "0.45972395", "0.45880127", "0.45847258", "0.4583627", "0.45775458", "0.4576043", "0.45732957", "0.4568548", "0.45676476", "0.4562263", "0.45619738", "0.45550156", "0.455462", "0.45481342", "0.45466742", "0.4539163", "0.45331734", "0.45323396", "0.45293552", "0.452825", "0.45281106", "0.45229602", "0.4520674", "0.451978", "0.45181072", "0.45170647", "0.45129514", "0.4512462", "0.4506914", "0.4505049", "0.4503866", "0.45007062", "0.44991133", "0.44924", "0.44901192", "0.4489527", "0.44872946", "0.4486354", "0.448586", "0.44826755", "0.44804752", "0.44788462", "0.4462239", "0.4461882", "0.44612348", "0.44563448", "0.4453693", "0.44514525", "0.44487494", "0.4448635", "0.44460616", "0.4442541" ]
0.0
-1
const time = new Date().getHours()
function App2(){ const [searchTerm,setSearchTerm] = useState('') const onSearchChange = (e) =>{ setSearchTerm(e.target.value) } return( < > { isLoggedIn? <Login/> : <Greeting text="Welcome to iCrowd"/> } <input type='text' placeholder = 'search staff' onChange = {onSearchChange} value = {searchTerm} /> <CardList searchStaff = {searchTerm}/> <Image/> </>) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function hourNow() {\n return (new Date).getHours();\n}", "H (date) {\n return date.getHours()\n }", "function getHours() {\r\n\tlet date = new Date();\r\n\tlet hour = date.getHours();\r\n\r\n\treturn hour;\r\n}", "function returnHour(){\n\tvar date = new Date();\n\tvar hours = date.getHours();\n\tconsole.log(\"It´s around \" + hours + \" of morning\");\n}", "HH (date) {\n return pad(date.getHours())\n }", "function get_time(){\n const today = new Date()\n let time = today.getHours() + \":\" + today.getMinutes();\n return time;\n }", "function get_hours(date) {\r\n hours = date.getHours();\r\n return hours; \r\n}", "h (date) {\n const hours = date.getHours();\n return hours === 0\n ? 12\n : (hours > 12 ? hours % 12 : hours)\n }", "get hour() {\n return this.date.getHours();\n }", "getHours() {\n return this.duration() / 3600000 //MS in an Hour\n }", "function getHours(time) {\n return time.split(\":\")[0];\n}", "function time() {\n var date = new Date();\n var hours = date.getHours();\n var minutes = date.getMinutes();\n if (minutes < 10) {\n minutes = \"0\" + minutes;\n }\n var time = hours + \":\" + minutes\n return time;\n}", "function time() {\n const date = new Date();\n const hours = date.getHours();\n let timeOfDay;\n if (hours < 12) {\n timeOfDay = \"Good morning :)\";\n } else if (hours >= 12 && hours < 17) {\n timeOfDay = \"Good afternoon :)\";\n } else {\n timeOfDay = \"Good evening :)\";\n }\n return timeOfDay;\n}", "function getTime(){\n \n hr = hour();\n mn = minute();\n sc = second();\n}", "get hour() {\n\t\treturn this.worldTime.getHours();\n\t}", "get hours() {\n return this.date.getHours();\n }", "getHours() {\r\n return this._hours;\r\n }", "function getTime() {\r\n var currentTime = new Date();\r\n var hours = currentTime.getHours();\r\n var minutes = currentTime.getMinutes();\r\n if (minutes < 10) {\r\n minutes = \"0\" + minutes;\r\n }\r\n return hours + \":\" + minutes;\r\n}", "get currentHour(){\n //returning in the format 01 - 24 \n return this._moment.format(`HH`); \n }", "function get_time() {\n return Date.now();\n}", "function getTime() {\n var date = new Date();\n var hours = date.getHours();\n var minutes = date.getMinutes();\n return \"(\" +hours + \":\" + minutes + \")\";\n}", "get time() {\n return (process.hrtime()[0] * 1e9 + process.hrtime()[1]) / 1e6;\n }", "calculateTime(){\n let today = new Date();\n let currentTime = today.getHours() + \":\" + today.getMinutes();// + \":\" + today.getSeconds();\n return currentTime;\n }", "function horas() {\n var date = new Date();\n var hours = date.getHours() < 10 ? \"0\" + date.getHours() : date.getHours();\n var minutes = date.getMinutes() < 10 ? \"0\" + date.getMinutes() : date.getMinutes();\n var seconds = date.getSeconds() < 10 ? \"0\" + date.getSeconds() : date.getSeconds();\n time = hours + \":\" + minutes + \":\" + seconds;\n return time;\n }", "function getTime(){\n const d = new Date();\n let hours = d.getHours();\n let minutes = d.getMinutes();\n let mode = 'am';\n\n if(hours > 12){\n hours -= 12 ;\n mode = \"pm\"\n }\n\n return {time: `${hours}:${JSON.stringify(minutes).padStart(2,'0')}`, mode}\n}", "function returnTime(){\n let d = new Date();\n // Get the time settings\n let min = d.getMinutes();\n let hour = d.getHours();\n let time = hour + \":\" + min;\n return time;\n}", "function myGreet(){\n const h = new Date().getHours();\n updateGreeting(h);\n}", "getTime(){\n var date = new Date();\n var heure= date.getHours().toString(); //l'heure\n var minute= date.getMinutes().toString();//a la minute\n if(heure===\"0\"){\n heure=\"00\";\n }\n if(heure.length===1 && heure!=\"0\"){\n heure=\"0\"+heure;\n }\n if(minute===\"0\"){\n minute=\"00\";\n }\n if(minute.length===1 && minute!=\"0\"){\n minute = \"0\"+minute;\n }\n\n var time = heure+\":\"+minute;\n return time;\n }", "function getTime() {\n let date = new Date(),\n min = date.getMinutes(),\n sec = date.getSeconds(),\n hour = date.getHours();\n\n return (\n \"\" +\n (hour < 10 ? \"0\" + hour : hour) +\n \":\" +\n (min < 10 ? \"0\" + min : min) +\n \":\" +\n (sec < 10 ? \"0\" + sec : sec)\n );\n}", "function getTime() {\n let minutes;\n let timeOfDay;\n const dt = new Date();\n if (dt.getHours() > 12) {\n timeOfDay = \"PM\";\n } else {\n timeOfDay = \"AM\";\n }\n if (dt.getMinutes() < 10) {\n minutes = \"0\" + dt.getMinutes();\n } else {\n minutes = dt.getMinutes();\n }\n return (dt.getHours() % 12) + \":\" + minutes + \" \" + timeOfDay;\n}", "function time() {\r\n var data = new Date();\r\n var ora = addZero( data.getHours() );\r\n var minuti = addZero( data.getMinutes() );\r\n return orario = ora + ':' + minuti;\r\n }", "function Hora(){\n var Digital=new Date();\n var hours=Digital.getHours();\n var minutes=Digital.getMinutes();\n var seconds=Digital.getSeconds();\n var dn=\"AM\";\n if (hours>12){\n dn=\"PM\";\n hours=hours-12;\n }\n if (hours==0)\n hours=12;\n if (minutes<=9)\n minutes=\"0\"+minutes;\n if (seconds<=9)\n seconds=\"0\"+seconds;\n return hours + \":\" + minutes;\n }", "function get_time() {\n return new Date().getTime();\n}", "function get_time() {\n return new Date().getTime();\n}", "getTime(){\n var date = new Date();\n return [('00'+date.getHours()).slice(-2), ('00'+date.getMinutes()).slice(-2), ('00'+date.getSeconds()).slice(-2)].join(':');\n }", "function getHours(time) {\n const unixTimestamp = time;\n\n const milliseconds = unixTimestamp * 1000;\n\n const dateObject = new Date(milliseconds);\n\n var hours =\n dateObject.getHours() > 12\n ? dateObject.getHours() - 12\n : dateObject.getHours();\n\n var am_pm = dateObject.getHours() >= 12 ? \"PM\" : \"AM\";\n\n return `${hours} ${am_pm}`;\n}", "function currentTime() {\n const today = new Date();\n let hours = today.getHours();\n let mins = today.getMinutes();\n let ampm = \"am\";\n\n if (hours >= 12) {\n ampm = \"pm\";\n }\n if (mins < 10) {\n mins = '0' + mins;\n }\n hours = hours % 12;\n let time = hours + \":\" + mins + ampm;\n return time;\n}", "function getTime() {\n let date = new Date(),\n hour = date.getHours(),\n min = date.getMinutes();\n // sec = date.getSeconds();\n\n return \"\" +\n (hour < 10 ? (\"0\" + hour) : hour) +\n \":\" +\n (min < 10 ? (\"0\" + min) : min);\n // + \":\" + (sec < 10 ? (\"0\" + sec) : sec);\n}", "hh (date) {\n return pad(this.h(date))\n }", "function getTime() {\n\n var currentTime = new Date();\n var hours = currentTime.getHours();\n var minutes = currentTime.getMinutes();\n var amOrPm = (hours > 11 ? 'PM':'AM');\n \n if( hours===0 ) hours = 12;\n else if( hours>12 ) hours = hours - 12;\n\n minutes = ( minutes < 10 ? '0' + minutes : minutes );\n\n return hours + ':' + minutes + amOrPm;\n}", "function getTime() {\n return new Date().toLocaleTimeString('en-GB', {\n hour: \"numeric\",\n minute: \"numeric\"\n });\n}", "function getTime() {\n\ttest = new Date();\n\thour = test.getHours();\n\tminutes = test.getMinutes();\n\tvar suffix = hour >= 12 ? \"pm\":\"am\";\n\thour = ((hour + 11) % 12 + 1);\n\ttime = hour + \":\" + minutes + suffix;\n\treturn time;\n}", "get time() {}", "function timeString(){\r\n var date = new Date()\r\n var current_hour = date.toLocaleString()\r\n current_hour = pad(current_hour, 23, 1, \" \")\r\n return current_hour\r\n}", "function getTimeHour(time){\n\n return moment(today + ' ' + time, \"dddd, MMMM Do YYYY hh:00 A\").format(\"MM-DD-YYYY hh:00 A\") ;\n\n}", "function getTime(date) {\n\tvar hr = date.getHours() === 0 ? 12 : date.getHours();\n\tvar min = date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes(); \n\tif (hr > 12) {\n\t\thr = hr - 12;\n\t}\n\tvar m = date.getHours() < 12 ? 'am' : 'pm';\n\t\n\treturn hr + ':' + min + m;\n}", "function date(){\n var myDate = new Date();\n var time= {\n d : myDate.toLocaleDateString(),\n h : myDate.getHours(),\n m : myDate.getMinutes(),\n s : myDate.getSeconds()\n }\n return time;\n}", "function time(){\n\tvar d = new Date();\n\tvar hours = function() {\n\t\th = d.getHours();\n\t\tif (h <= 9) {\n\t\t\th = 0 + \"\" + h;\n\t\t}\n\t\treturn h;\n\t};\n\tvar mins = function() {\n\t\tvar m = d.getMinutes();\n\t\tif (m <= 9 ) {\n\t\t\tm = 0 + \"\" + m;\n\t\t}\n\t\treturn m\n\t}\n\tt = hours() + \"\" + mins();\n\tt = parseFloat(t);\n\treturn t;\n}", "function humanHour() {\n var h = hour() % 12;\n if (h == 0) {\n h = 12;\n }\n return h;\n}", "function humanHour() {\n var h = hour() % 12;\n if (h == 0) {\n h = 12;\n }\n return h;\n}", "function time() {\n let timestamp = Math.floor(new Date().getTime() / 1000)\n return timestamp;\n }", "function getNow() {\n var now = new Date();\n return {\n hours: now.getHours() + now.getMinutes() / 60,\n minutes: now.getMinutes() * 12 / 60 + now.getSeconds() * 12 / 3600,\n seconds: now.getSeconds() * 12 / 60\n };\n }", "function checkIsItDay() {\n let time = new Date().getHours();\n // console.log(time.getHours());\n return time > 6 && time < 18;\n}", "function timeStart()\n{\n var ds = new Date();\n var hs = addZero(ds.getHours());\n var ms = addZero(ds.getMinutes());\n var ss = addZero(ds.getSeconds());\n return hs + \":\" + ms + \":\" + ss;\n}", "function getTime() {\n const date = new Date();\n const minutes = date.getMinutes();\n const hours = date.getHours();\n\n clockTitle.innerText = `${hours < 10 ? `0${hours}` : hours} : ${\n minutes < 10 ? `0${minutes}` : minutes\n }`;\n}", "function timeManagement() {\n var day = $(\"#currentDay\"); \n var date = moment().format('llll').toString();\n day.text(date);\n var ampm = date.split(\" \");\n hour = parseInt(moment().format('LT').toString());\n if (ampm[5] === \"PM\") {\n hour = hour + 12;\n return hour;\n }\n return hour;\n }", "function currentTime(){\n let now = new Date();\n\n const hh = String(now.getHours()).padStart(2, '0');\n const mm = String(now.getMinutes()).padStart(2, '0');\n\n now = hh + ':' + mm;\n\n return now; \n}", "getCurrentTime() {\n const today = new Date();\n var time = today.getHours() + \":\" + today.getMinutes();\n if (today.getMinutes() < 10) {\n time = today.getHours() + \":0\" + today.getMinutes();\n }\n return time;\n }", "hourStart(s) {\n return s.dateTimeStart.getHours();\n }", "function getDateAndTime(){\n return new Date()\n}", "function whatTime() {\n var time = new Date().getHours();\n console.log(time)\n\n if (time < 6) {\n document.getElementById(\"time\").innerHTML = \"It's night!\";\n }\n else if (time < 12) {\n document.getElementById(\"time\").innerHTML = \"It's morning!\";\n }\n else if (time < 17) {\n document.getElementById(\"time\").innerHTML = \"It's afternoon!\";\n } \n else if (time < 20) {\n document.getElementById(\"time\").innerHTML = \"It's evening!\";\n } \n else {\n document.getElementById(\"time\").innerHTML = \"It's night!\";\n }\n}", "static get_time() {\n return (new Date()).toISOString();\n }", "function currentTime () {\n return new Date().toLocaleTimeString()\n}", "function DateAndTime(){\n let today = new Date();\n let day = today.getDay();\n const week = [\"Sunday\",\"Monday\",\"Tuesday\",\"Wednesday\",\"Thrusday\",\"Friday\",\"Saturday\"];\n console.log(week[day]);\n let hour = today.getHours();\n let minute = today.getMinutes();\n let second = today.getSeconds();\n if(hour > 12){\n hour = hour - 12;\n hour = hour + \" PM\";\n }else{\n hour = hour + \" AM\";\n }\n if(minute < 10){\n minute = \"0\"+minute;\n }\n if(second < 10){\n second = \"0\"+second;\n }\n console.log(\"Current Time : \" + hour +\" : \"+ minute +\" : \"+ second);\n\n}", "getMidDay(hour) {\n return hour >= 12 ? \"PM\" : \"AM\";\n }", "isDay() {\n let hours = new Date(Date.now()).getHours()\n return hours >= 7 && hours <= 21\n }", "function getTimeString() \n{\n var current_date = new Date();\n return current_date.getHours() + \":\" + current_date.getMinutes();\n}", "function printTime(){\n var currentTime = new Date();\n var time = currentTime.getHours() + \":\" + currentTime.getMinutes() + \":\" + currentTime.getSeconds();\n return time;\n}", "function tellTime() \r\n{ \r\n var now = new Date(); \r\n var theHr = now.getHours(); \r\n var theMin = now.getMinutes(); \r\n alert(\"Current time: \"+ theHr + \":\" + theMin); \r\n}", "function getTime() {\r\n\ttime = new Date();\r\n\treturn time.getTime();\r\n}", "function getTime(time) {\n var newTime = new Date(time);\n var hours = newTime.toString();\n var departureTime = hours.substring(16, 21);\n return departureTime;\n}", "function time() {\r\n return Math.round((new Date()).getTime() / 1000); \r\n}", "function getHour(dateISO){ \n let appointmentHour = new Date(dateISO);\n return appointmentHour.toLocaleString('en-US', { hour: 'numeric', hour12: true });\n }", "function fetchTime() {\n let time = new Date();\n return time.toLocaleString(\"en-PK\", {\n hour: \"numeric\",\n minute: \"numeric\",\n hour12: true,\n });\n}", "function getCurrentHoursAndMinutes() {\n var now = convertUTCtoOttawa(new Date());\n return { hours: now.getHours(), minutes: now.getMinutes() };\n}", "getTime(){\n let hh = new Date().getHours()\n let mm = new Date().getMinutes()\n return `[${this.helper(hh)}:${this.helper(mm)}]`\n }", "function getTime() {\n return (new Date()).getTime();\n}", "function getTime() {\n return new Date().getTime();\n}", "function dateAndTime() {\nconst today = Date(); // assigns current date and time to a const\nreturn today;\n}", "function formatTime(date) {\n let now\n let h\n\n if (date) {\n now = new Date(convertLocalDateToUTCDate(date));\n h = now.getHours() + \":\" + (\"0\" + now.getMinutes()).slice(-2);\n } else {\n now = new Date();\n h = now.getHours() + \":\" + (\"0\" + now.getMinutes()).slice(-2);\n }\n return h\n }", "function fnContentVistedgetHours(pardate) {\n try {\n var hours = pardate.getHours();\n return hours < 10 ? '0' + hours : '' + hours;\n } catch (err) {\n console.log('fnContentVistedgetHours : ' + err.message);\n }\n}", "function getTimeNow () {\n\tvar x = new Date();\n\tvar h = x.getHours();\n\tvar m = x.getMinutes()/60;\n\tselectedTime = h + m;\n\treturn (h + m);\n}", "function stringifiedHour(){\r\n var date=new Date();\r\n var h = date.getHours();\t\r\n var m = date.getMinutes();\t\r\n var s = date.getSeconds();\t\r\n\r\n if(h<10)h=\"0\"+h;\r\n if(m<10)m=\"0\"+m;\r\n if(s<10)s=\"0\"+s;\r\n\r\n return h+\":\"+m+\":\"+s;\t\r\n\r\n}", "function getTime() {\n var today = new Date();\n var mon = today.getMonth() + 1;\n var d = today.getDate();\n var y = today.getFullYear();\n var h = today.getHours();\n var p = \"AM\";\n if(h === 0) {\n h = 12;\n } else if(h >= 12) {\n p = \"PM\";\n h = (h != 12) ? (h - 12) : 12;\n }\n var m = today.getMinutes();\n var s = today.getSeconds();\n // add a zero in front of numbers<10\n m = checkTime(m);\n s = checkTime(s);\n var time = mon + \"/\" + d + \"/\" + y + \" \" + h + \":\" + m + \":\" + s + \" \" + p;\n return time;\n}", "function getCurrentTime () {\n var currentHour = parseInt(moment().format(\"hh\"));\n var currentPeriod = moment().format(\"A\");\n\n if (currentPeriod == \"PM\"){\n currentHour = currentHour + 12;\n }\n return currentHour;\n}", "function getTime(){\n let date = new Date();\n\n let time = date.getHours() + ':'+ date.getMinutes()+ ':' + date.getSeconds();\n console.log(time);\n // let k = setTimeout(getTime,1000);\n\n\n \n \n}", "function time(date) {\n return date.getFullYear() +\n \"-\" + (date.getMonth() + 1) +\n \"-\" + appendZeroes(date.getDate()) +\n \" \" + appendZeroes(date.getHours()) +\n \":\" + appendZeroes(date.getMinutes()) +\n \":\" + appendZeroes(date.getSeconds())\n}", "function getLocalTime() {\n const today = new Date();\n const days = ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'];\n const day = days[today.getDay()];\n const month = today.getMonth();\n const year = today.getFullYear();\n\n const time = today.getHours() + ':' + today.getMinutes();\n\n const element = document.getElementById(\"header-text\");\n\n element.textContent = time + ' | ' + day + ' | ' + today.getDate() + '/' + month + '/' + year;\n}", "get hourStart() {\n\t\treturn this.nativeElement ? this.nativeElement.hourStart : undefined;\n\t}", "function timeNow() {\n var d = new Date(),\n h = (d.getHours()<10?'0':'') + d.getHours(),\n m = (d.getMinutes()<10?'0':'') + d.getMinutes(),\n s = (d.getSeconds()<10?'0':'') + d.getSeconds();\n return h + ':' + m + ':' + s;\n }", "function time() {\n\treturn Date.now() / 1000.0;\n}", "function current_time() {\n var hh = today.getHours()\n var mm = today.getMinutes()\n\n if (mm < 10) {\n mm = \"0\" + mm\n }\n\n if (hh >= 12) {\n hh = hh % 12\n return (hh + \":\" + mm + \"pm\")\n } else {\n return (hh + \":\" + mm + \"am\")\n }\n}", "function now(){\r\n const date = new Date()\r\n const hour = date.getHours()\r\n const minute = date.getMinutes()\r\n const day = date.getUTCDate()\r\n const month = date.getMonth()\r\n const year = date.getFullYear()\r\n return year + \"-\" + month + \"-\" + day + \" \" + hour + \":\" + minute + \":\" + date.getSeconds()\r\n}", "function AffichageHeure() {\n\n var date = new Date();\n\n var hour2 = date.toLocaleTimeString();\n document.getElementById('divHeure').innerHTML = hour2;\n}", "function dataAtual(){\r\n\tvar data = new Date();\r\n\tvar hora = data.getHours();\r\n\tvar minuto = data.getMinutes();\r\n\tvar segundo = data.getSeconds();\r\n\treturn hora + \":\" + minuto + \":\" + segundo;\r\n}", "function gettime() {\n //return Math.round(new Date().getTime() / 1000);\n return Math.round(Date.now() / 1000);\n}", "function time() {\n\t\t\treturn (new Date()).getTime();\n\t\t}", "function getTime() {\n\tvar Time = new Date();\n\treturn Time.toISOString().slice(0,10) + \" \" + Time.getHours() + \":\" + Time.getMinutes() + \":\" + Time.getSeconds();\n}", "function getTime() {\n return new Date().getTime() / 1000;\n}", "function loadTheTime() {\n const date = new Date(),\n hours = date.getHours(),\n minutes = date.getMinutes(),\n seconds = date.getSeconds();\n h1.innerText = `${hours < 10 ? `0${hours}` : hours}:${\n minutes < 10 ? `0${minutes}` : minutes\n }:${seconds < 10 ? `0${seconds}` : seconds}`;\n}", "formatTime(date) {\n let hours = date.getHours();\n let ampm = hours >= 12 ? 'PM' : 'AM';\n hours %= 12;\n hours = hours ? hours : 12; // the hour 0 should be 12\n\n return hours + ampm;\n }" ]
[ "0.88877296", "0.8814418", "0.865732", "0.8097972", "0.8007119", "0.7994984", "0.7929036", "0.76222223", "0.759132", "0.755606", "0.7416349", "0.7312028", "0.7297682", "0.72687304", "0.7256236", "0.7223416", "0.71892506", "0.71366775", "0.7118099", "0.7086186", "0.7072738", "0.70572233", "0.7045749", "0.7045127", "0.7009742", "0.6996295", "0.6987443", "0.6975085", "0.69688994", "0.6940462", "0.6916698", "0.6900165", "0.68709785", "0.68709785", "0.6863644", "0.6855167", "0.6843402", "0.68412745", "0.6829717", "0.68179226", "0.67945457", "0.67927516", "0.6787076", "0.6768485", "0.67674464", "0.67248195", "0.6718741", "0.6683576", "0.6671526", "0.6671526", "0.6663089", "0.66489416", "0.6646406", "0.6630905", "0.66272724", "0.6623558", "0.6622803", "0.6622384", "0.6602019", "0.6598139", "0.6595529", "0.65881413", "0.6584808", "0.65777874", "0.65745604", "0.6559197", "0.6552972", "0.6527213", "0.65205747", "0.65161985", "0.6515402", "0.6513703", "0.6500205", "0.6498944", "0.64974624", "0.6495324", "0.6493114", "0.6484383", "0.64804834", "0.64803046", "0.64762664", "0.647398", "0.6467548", "0.64642614", "0.6460809", "0.6448597", "0.64479554", "0.64357966", "0.6428252", "0.6422877", "0.6414264", "0.64004755", "0.6397301", "0.6393316", "0.63924676", "0.63916135", "0.63746667", "0.63667566", "0.63624203", "0.6353812", "0.63512015" ]
0.0
-1
To swap the position of two items
function init() { posHTML.setDragnDrop() //Tooltip $("a").tooltip('show') $('a').tooltip({html: true}) $("a").tooltip('hide') }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function SwapItems(itemId1: int, itemId2: int) {\n\t\n\t}", "swapItems(itemIndex1, itemIndex2) {\n const items = this.props.items.slice();\n const temp = items[itemIndex1];\n items[itemIndex1] = items[itemIndex2];\n items[itemIndex2] = temp;\n\n this.props.onChange(items);\n }", "function swap(array, posA, posB) {\n var temp = array[posA]; \n array[posA] = array[posB]; \n array[posB] = temp; \n }", "function swap(items, leftIndex, rightIndex){\n var temp = items[leftIndex];\n items[leftIndex] = items[rightIndex];\n items[rightIndex] = temp;\n}", "function swap(array, posA, posB) {\n var temp = array[posA]; \n array[posA] = array[posB]; \n array[posB] = temp; \n }", "function swap (arr, pos1, pos2) {\n var arr = arr, pos1 = pos1, pos2 = pos2, temp;\n\n temp = arr[pos1];\n arr[pos1] = arr[pos2];\n arr[pos2] = temp;\n\n return arr;\n}", "function swapItems(arr,index1,index2){\n temp=arr[index1];\n arr[index1]=arr[index2];\n arr[index2]=temp;\n return arr;\n}", "function swap( arr, posA, posB ) {\n var temp = arr[posA];\n arr[posA] = arr[posB];\n arr[posB] = temp;\n}", "function swap(currentPosition,nextPosition,array){\n\t\tvar temp = array[currentPosition];\n\t\tarray[currentPosition] = array[nextPosition];\n\t\tarray[nextPosition] = temp;\n\t}", "function swapQueueItems(msg, args) {\n let arg1 = args.split(\" \")[0], arg2 = args.split(\" \")[1];\n if(isNaN(arg1) || isNaN(arg2))\n throw \"Invalid position.\";\n if(arg1 == arg2)\n throw \"Invalid positions.\";\n let pos1 = Number(arg1);\n let pos2 = Number(arg2);\n if(pos1 % 1 != 0 || pos2 % 1 != 0)\n throw \"Invalid position\";\n let queue = globals.connections[msg.guild.id].queue;\n if(pos1 < 2 || pos2 < 2 || pos1 > queue.length || pos2 > queue.length)\n throw 'Invalid position';\n msg.channel.send(\"**Swapped** `\" + queue[pos1 - 1].name + \"` **with** `\" + queue[pos2 - 1].name + \"`** in the play queue.**\");\n // quick swap (elem2 is holder)\n var elem2 = queue[pos2 - 1];\n queue[pos2 - 1] = queue[pos1 - 1];\n queue[pos1 - 1] = elem2;\n}", "function swapIconPosition(icon1, icon2) {\n\n var tempPosX = icon1.posX;\n var tempPosY = icon1.posY;\n setIconPos(icon1, icon2.posX, icon2.posY);\n setIconPos(icon2, tempPosX, tempPosY);\n\n}", "function swap (a, b) {\n [array[a], array[b]] = [array[b], array[a]];\n }", "swap(index1, index2) {\n const s = this.store;\n [s[index1], s[index2]] = [s[index2], s[index1]];\n }", "function swap(a, i1, i2) {\n var t = a[i1];\n a[i1] = a[i2];\n a[i2] = t;\n }", "function swap(arr, idx1, idx2) {\n var temp = arr[idx1];\n arr[idx1] = arr[idx2];\n arr[idx2] = temp;\n}", "function indexSwap(itemsToSort, leftIndex, rightIndex) {\n var tempVar = itemsToSort[leftIndex];\n itemsToSort[leftIndex] = itemsToSort[rightIndex];\n itemsToSort[rightIndex] = tempVar;\n}", "_swapItems(firstItemIndex, secondItemIndex) {\n function swap(list, x, y) {\n const temp = list[y];\n\n list[y] = list[x];\n list[x] = temp;\n }\n\n const that = this,\n lesserIndex = Math.min(firstItemIndex, secondItemIndex),\n greaterIndex = Math.max(firstItemIndex, secondItemIndex),\n items = that._items;\n let expandedIndexes = that.expandedIndexes.slice();\n\n if (that._items[firstItemIndex].expanded && !that._items[secondItemIndex].expanded) {\n const indexPosition = expandedIndexes.indexOf(firstItemIndex);\n\n expandedIndexes[indexPosition] = secondItemIndex;\n that.expandedIndexes = expandedIndexes.slice();\n }\n else if (that._items[secondItemIndex].expanded && !that._items[firstItemIndex].expanded) {\n const indexPosition = expandedIndexes.indexOf(secondItemIndex);\n\n expandedIndexes[indexPosition] = firstItemIndex;\n that.expandedIndexes = expandedIndexes.slice();\n }\n\n that.selectedIndex = that.selectedIndex === firstItemIndex ? secondItemIndex : firstItemIndex;\n that.$.container.insertBefore(items[greaterIndex], items[lesserIndex]);\n swap(items, firstItemIndex, secondItemIndex);\n that._items[firstItemIndex].$.removeClass('hovered');\n\n that._reorderedIndex = secondItemIndex;\n }", "function swap_items(source, target) {\n debug.trace(\"Swap items\", source, target);\n var temp;\n if (target.is_empty()) {\n target.set_item(source.get_item());\n source.set_item(null);\n } else {\n temp = target.get_item();\n target.set_item(source.get_item());\n source.set_item(temp);\n }\n }", "function swap(arr, idx1, idx2) {\n let temp = arr[idx1];\n arr[idx1] = arr[idx2];\n arr[idx2] = temp;\n}", "function swap(idx1, idx2, arr) {\n let temp = arr[idx1];\n arr[idx1] = arr[idx2];\n arr[idx2] = temp;\n}", "function swap_2(a, b){ //cach truyen tham chieu\n return [b, a];\n}", "function swap(array, a, b) {\n\t\t\tvar temp = array[a];\n\t\t\tarray.splice(a, 1, array[b]);\n\t\t\tarray.splice(b, 1, temp);\n\t\t}", "function swap(arr, idx1, idx2) {\n let temp = arr[idx1];\n arr[idx1] = arr[idx2];\n arr[idx2] = temp;\n}", "function iter_swap(x, y) {\r\n var _a;\r\n _a = __read([y.value, x.value], 2), x.value = _a[0], y.value = _a[1];\r\n}", "function swapValues(arr, idx1, idx2) {\n\n }", "function swapItems(start, end){\r\n const itemOne = listItems[start].querySelector('.draggable');\r\n const itemTwo = listItems[end].querySelector('.draggable');\r\n\r\n listItems[start].appendChild(itemTwo);\r\n listItems[end].appendChild(itemOne);\r\n}", "function swap(array, idx1, idx2) {\n var temp = array[idx1];\n array[idx1] = array[idx2];\n array[idx2] = temp;\n}", "function swap(index1, index2) {\n tmp = arr[index1];\n arr[index1] = arr[index2];\n arr[index2] = tmp;\n }", "function swap(index1, index2) {\n tmp = arr[index1];\n arr[index1] = arr[index2];\n arr[index2] = tmp;\n }", "function swap(arr, index1, index2) {\n var temp = arr[index1]; // store value of arr[index1]\n arr[index1] = arr[index2]; // assign value of arr[index2] to arr[index1]\n arr[index2] = temp; // assign value of arr[index1] to arr[index2] from temp store\n}", "function swap(index1, index2) {\n console.log(`Swap: ${arr[index1]} e ${arr[index2]}`);\n tmp = arr[index1];\n arr[index1] = arr[index2];\n arr[index2] = tmp;\n \n }", "function swap(a, b) {\n return [...fromTo(a, b), ...fromTo(b, a)];\n}", "function swapArr(arr, idx1, idx2) {\n var temp = arr[idx1];\n arr[idx1] = arr[idx2];\n arr[idx2] = temp;\n}", "function swapArr(arr, idx1, idx2) {\n var temp = arr[idx1];\n arr[idx1] = arr[idx2];\n arr[idx2] = temp;\n}", "function swapArr(arr, idx1, idx2) {\n var temp = arr[idx1];\n arr[idx1] = arr[idx2];\n arr[idx2] = temp;\n}", "function swapItems(fromIndex, toIndex) {\n // selecting both DOM elements\n const itemOne = listItems[fromIndex].querySelector(\".draggable\");\n const itemTwo = listItems[toIndex].querySelector(\".draggable\");\n\n // swapping places\n listItems[fromIndex].appendChild(itemTwo);\n listItems[toIndex].appendChild(itemOne);\n}", "function swap(arr, i1, i2) {\n var temp = arr[i1];\n arr[i1] = arr[i2];\n arr[i2] = temp;\n }", "function swapElements(elm1, elm2)\r\n{\r\n var parent1, next1,\r\n parent2, next2;\r\n parent1 = elm1.parentNode;\r\n next1 = elm1.nextSibling;\r\n parent2 = elm2.parentNode;\r\n next2 = elm2.nextSibling;\r\n\r\n parent1.insertBefore(elm2, next1);\r\n parent2.insertBefore(elm1, next2);\r\n}", "function swap(array, index1, index2) {\n var aux = array[index1];\n array[index1] = array[index2];\n array[index2] = aux;\n}", "function swap(arr, index1, index2){\n var temp = arr[index1];\n arr[index1] = arr[index2];\n arr[index2] = temp;\n}", "function swap(arr,xp, yp)\n{\n var temp = arr[xp];\n arr[xp] = arr[yp];\n arr[yp] = temp;\n}", "function swap(arr, idx1, idx2){\n // add whatever you parameters you deem necessary, good luck!\n [arr[idx1], arr[idx2]] = [arr[idx2],arr[idx1]]\n return arr;\n}", "function swap(arr, idxA, idxB) {\n const temp = arr[idxA]\n arr[idxA] = arr[idxB]\n arr[idxB] = temp\n}", "function swap(arr, x, y) {\n var tmp = arr[x];\n arr[x] = arr[y];\n arr[y] = tmp;\n }", "function swap(arr, idx1, idx2) {\n return [arr[idx1], arr[idx2]] = [arr[idx2], arr[idx1]];\n}", "swapNodes(idx1, idx2) {\n const VALS = this.values;\n\n const temp = VALS[idx1];\n VALS[idx1] = VALS[idx2];\n VALS[idx2] = temp;\n }", "function swap(arr, i1, i2) {\n var temp = arr[i1];\n arr[i1] = arr[i2];\n arr[i2] = temp;\n}", "function swapPoints(a, b) {\n let tmp = a.style.top;\n a.style.top = b.style.top;\n b.style.top = tmp;\n}", "function swap( index1, index2, arr ) {\n const temp = arr[ index1 ];\n arr[ index1 ] = arr[ index2 ];\n arr[ index2 ] = temp;\n}", "function swapItems(fromIndex, toIndex) {\n // get the picked up item and the target position item\n const itemOne = listItems[fromIndex].querySelector(\".draggable-list__detail\");\n const itemTwo = listItems[toIndex].querySelector(\".draggable-list__detail\");\n\n // swap the elements in the listItem array\n listItems[fromIndex].appendChild(itemTwo);\n listItems[toIndex].appendChild(itemOne);\n}", "function swap(input, index_A, index_B) {\n let temp = input[index_A];\n \n input[index_A] = input[index_B];\n input[index_B] = temp\n }", "function swap_items(source, target) {\n debug.trace(\"Swap items\", source, target);\n var temp;\n if (target.is_empty()) { // target jest pusty\n if (target.set_item(source.get_item())) { // jesli target przyjal przedmiot\n source.set_item(null); // nullujemy source\n }\n } else {\n temp = target.get_item();\n if (target.set_item(source.get_item())) { // jesli target przyjal przedmiot\n if (source.set_item(temp)) { // jesli source przyjal przedmiot z targeta\n } else { // source nie przyjal, przywracamy przedmiot targeta\n target.set_item(temp);\n }\n }\n }\n }", "function swap(arr, index1, index2) {\n var temp = arr[index1]\n arr[index1] = arr[index2]\n arr[index2] = temp\n return arr\n}", "function swap (arr, i1, i2) {\n var tmp = arr[i1]\n arr[i1] = arr[i2]\n arr[i2] = tmp\n return arr\n}", "function swap(array, a, b) {\n let temp = array[b];\n array[b] = array[a]\n array[a] = temp\n}", "function swap(arr, index1, index2) {\n\tconst value1 = arr[index1],\n\t\tvalue2 = arr[index2]\n\tarr[index1] = value2\n\tarr[index2] = value1\n\t//![arr[index2], arr[index1]] = [arr[index1], arr[index2]] //! Why doesnt this work?\n}", "function swapPosition(pos1, pos2) {\n document.getElementById(\"demo-tooltip-mouse\" + (pos1 - 1)).style.top = position(pos2);\n document.getElementById(\"demo-tooltip-mouse\" + (pos2 - 1)).style.top = position(pos1);\n}", "_swap(idx1, idx2) {\n let _tempElement = this._elementHeap[idx1];\n let _tempPriority = this._priorityHeap[idx1];\n\n this._elementHeap[idx1] = this._elementHeap[idx2];\n this._priorityHeap[idx1] = this._priorityHeap[idx2];\n\n this._elementHeap[idx2] = _tempElement;\n this._priorityHeap[idx2] = _tempPriority;\n\n this._indexLookup[this._elementHeap[idx1]] = idx1;\n this._indexLookup[this._elementHeap[idx2]] = idx2;\n }", "function swap(arr, a, b) {\r\n let temp = arr[a];\r\n arr[a] = arr[b];\r\n arr[b] = temp;\r\n}", "function _swapArrayItems(array, leftIndex, rightIndex) {\n const temp = array[leftIndex];\n array[leftIndex] = array[rightIndex];\n array[rightIndex] = temp;\n }", "function swapSides() {\n var tmp;\n\n // swap symbols\n tmp = symbol2;\n symbol2 = symbol1;\n symbol1 = tmp;\n\n justDrawLinearSeparately(getPositions(2), symbol1, getPositions(1), symbol2);\n}", "function swapItems(fromIndex, toIndex) {\n const itemOne = listItems[fromIndex].querySelector('.draggable');\n const itemTwo = listItems[toIndex].querySelector('.draggable');\n\n listItems[fromIndex].appendChild(itemTwo);\n listItems[toIndex].appendChild(itemOne);\n}", "function swap(a, b){\n let temp = a;\n a = b;\n b = temp;\n // console.log(`=> a = ${a},-> b = ${b}`); //hoan vi bien a va b(trong ham swap)\n return[a, b]; //phai tra ve mang khi truyen tham tri\n}", "function swap(arr,first,second){\n if(first == second){\n return;\n }\n var temp = arr[first];\n arr[first] = arr[second];\n arr[second] = temp;\n}", "function swap(itemsToSort, temp, i) {\n let old = itemsToSort[i];\n itemsToSort[i] = itemsToSort[temp];\n itemsToSort[temp] = old;\n }", "function swap(arr, one, two) {\n const temp = arr[one];\n arr[one] = arr[two];\n arr[two] = temp;\n }", "function swap (a, b) {\n let temp = sortedArray[a]\n sortedArray[a] = sortedArray[b]\n sortedArray[b] = temp\n }", "function swap (position) \r\n{\r\n\tvar temp = gamePiece[position].style.top;\r\n\tgamePiece[position].style.top = spaceY;\r\n\tspaceY = temp;\r\n\ttemp = gamePiece[position].style.left;\r\n\tgamePiece[position].style.left = spaceX;\r\n\tspaceX = temp;\r\n\r\n}", "function swap(before, after, array)\n{\n \n //swap the element:\n let temp = array[before]; \n array[before] = array[after];\n array[after] = temp;\n}//end of swap()", "function swapGemPosition(gem1, gem2) {\n\n var tempPosX = gem1.posX;\n var tempPosY = gem1.posY;\n setGemPos(gem1, gem2.posX, gem2.posY);\n setGemPos(gem2, tempPosX, tempPosY);\n\n}", "function swap(range, x, y) {\n var tmp = range[x];\n range[x] = range[y];\n range[y] = tmp;\n}", "function swap(a, b) {\n var temp = a;\n a = b;\n b = temp;\n}", "function swapItems(fromIndex, toIndex) {\n // listItems에 들어있는 li 태그를 가져와서 그 li 태그 안에 있는 draggable을 쿼리셀렉터로 가져옴\n const itemOne = listItems[fromIndex].querySelector('.draggable');\n const itemTwo = listItems[toIndex].querySelector('.draggable');\n\n listItems[fromIndex].appendChild(itemTwo);\n listItems[toIndex].appendChild(itemOne);\n}", "function swapValues(args) {\n var temp = args[0];\n args[0] = args[1];\n args[1] = temp;\n}", "function swap(x, y) {\r\n let temp = x;\r\n x = y;\r\n y = temp;\r\n}", "function swap (position) {\n\t\t//moves the puzzle piece by switching position with an empty space\n\t\tlet temp = pieceCount[position].style.top;\n\t\tpieceCount[position].style.top = yCoordinate;\n\t\tyCoordinate = temp;\n\t\ttemp = pieceCount[position].style.left;\n\t\tpieceCount[position].style.left = xCoordinate;\n\t\txCoordinate = temp;\n\t}", "function swapPairs(idx1, idx2, arr) {\n\tvar temp = arr[idx1];\n\tarr[idx1] = arr[idx2];\n\tarr[idx2] = temp;\n\tconsole.log(\"swap is\", arr)\n\treturn arr;\n}", "function swap(arr, val1, val2)\n{\n let temp = arr[val2];\n arr[val2] = arr[val1];\n arr[val1] = temp;\n}", "function bubbleSortSwap(index1, index2, array) {\n var temp = array[index2];\n array[index2] = array[index1];\n array[index1] = temp;\n }", "function swapVal(array, a, b) {\n let temp = array[a];\n array[a] = array[b];\n array[b] = temp;\n}", "function Swapper(a, b){\n this.items = {};\n this.items[item_A] = a;\n this.items[item_B] = b;\n this.selected = item_A;\n}", "function swap(direction1, direction2) {\n var temp; // holds direction during swap process\n temp = document.getElementById(direction1).innerHTML;\n document.getElementById(direction1).innerHTML =\n document.getElementById(direction2).innerHTML;\n document.getElementById(direction2).innerHTML = temp;\n }", "swap(a, b) {\n\n let temp = this.harr[a]\n this.harr[a] = this.harr[b]\n this.harr[b] = temp\n\n }", "function swap(arr=[], a, b){\n\tlet temp = arr[a];\n\tarr[a] = arr[b];\n\tarr[b] = temp;\n\treturn;\n}", "swapQueues(index1, index2) {\n var temp = this.queues[index1];\n this.queues[index1] = this.queues[index2];\n this.queues[index2] = temp;\n }", "function swap(x1, y1, x2, y2) {\n var typeswap = level.tiles[x1][y1].type;\n \n level.tiles[x1][y1].type = level.tiles[x2][y2].type;\n \n level.tiles[x2][y2].type = typeswap;\n }", "function swap(x1, y1, x2, y2) {\n var typeswap = level.tiles[x1][y1].type;\n level.tiles[x1][y1].type = level.tiles[x2][y2].type;\n level.tiles[x2][y2].type = typeswap;\n var newswap = level.tiles[x1][y1].isNew;\n level.tiles[x1][y1].isNew = level.tiles[x2][y2].isNew;\n level.tiles[x2][y2].isNew = newswap;\n }", "function swap(array, firstElement, secondElement){\n let temp = array[firstElement];\n array[firstElement] = array[secondElement];\n array[secondElement] = temp;\n}", "moveItemUp(itemId){\n let index = -1;\n for(let i = 0; i < this.items.length; i++){\n if(this.items[i].id === Number(itemId)){\n index = i;\n break;\n }\n }\n let tempItem = this.items[index - 1];\n this.items[index - 1] = this.items[index];\n this.items[index] = tempItem;\n }", "swap(firstIndex, secondIndex) {\r\n\r\n let temp = this.heapContainer[firstIndex];\r\n this.heapContainer[firstIndex] = this.heapContainer[secondIndex];\r\n this.heapContainer[secondIndex] = temp;\r\n }", "function swap(A, indexA, indexB) {\n var temp = A[indexA];\n A[indexA] = A[indexB];\n A[indexB] = temp;\n}", "function swap(xp, yp) {\r\n\r\n let tmp = array[xp];\r\n array[xp] = array[yp];\r\n array[yp] = tmp;\r\n\r\n tmp = document.getElementById(xp).style.height;\r\n document.getElementById(xp).style.height = document.getElementById(yp).style.height;\r\n document.getElementById(yp).style.height = tmp;\r\n\r\n}", "swap(editor, path1, path2) {\n if (path1 && SelectionTransforms.isComponentElementPath(editor, path1) && path2 && SelectionTransforms.isComponentElementPath(editor, path2)) {\n if (Path.equals(path1, path2)) {\n return;\n }\n\n const [, containerPath1] = ContainerTransforms.getContainer(editor, path1);\n const [, containerPath2] = ContainerTransforms.getContainer(editor, path2);\n\n if (!containerPath1 || !containerPath2) {\n return;\n }\n\n const withinSameContainer = Path.equals(containerPath1, containerPath2);\n if (withinSameContainer) {\n\n // Moving within the same container, so we start by sorting the two paths, to ensure we always move \"down\":\n // const sorted = path1[1] < path2[1];\n const sorted = Path.isBefore(path1, path2);\n const p1 = sorted ? path1 : path2;\n const p2 = sorted ? path2 : path1;\n\n // After moving p1 to p2 DOWN* (we guarantee that, above), the node at p2 will be shifted one element UP,\n // which we need to account for.\n const newP2 = [...p2];\n newP2[newP2.length - 1]--; // compat: p2[p2.length - 1] > 0\n Editor.withoutNormalizing(editor, () => {\n Transforms.moveNodes(editor, { at: p1, to: p2, mode: \"all\", voids: true });\n Transforms.moveNodes(editor, { at: newP2, to: p1, mode: \"all\", voids: true });\n });\n\n } else {\n\n // If we are moving elements between containers, we don't have to worry about relative\n // positioning and direction of the swap. The element that was originally at path2\n // will be shifted down one position, as we've added a new element to the container.\n const newPath2 = [...path2];\n newPath2[newPath2.length - 1]++; // down by one element\n\n Editor.withoutNormalizing(editor, () => {\n Transforms.moveNodes(editor, { at: path1, to: path2, mode: \"all\", voids: true });\n Transforms.moveNodes(editor, { at: newPath2, to: path1, mode: \"all\", voids: true });\n });\n }\n }\n }", "_swap(i, j) {\n const temp = this._nodes[i];\n this._nodes[i] = this._nodes[j];\n this._nodes[j] = temp;\n }", "function swap () {\n p.parentNode.insertBefore(m, p);\n}", "function swap(arr, i, j) {\r\n let tmp = arr[i];\r\n arr[i] = arr[j]\r\n arr[j] = tmp\r\n\r\n}", "swap(color1, color2) {\r\n let colorStore = color1.color;\r\n let indexStore = color1.index;\r\n color1.update(color2.color, color2.index);\r\n color2.update(colorStore, indexStore);\r\n }", "function swap(i, j) {\n displayBuffer.push(['swap', i, j]); // Do not delete this line (for display)\n console.log(\"swap - implement me !\");\n let tmp = csvData[i];\n csvData[i] = csvData[j];\n csvData[j] = tmp;\n // [csvData[i], csvData[j]] = [csvData[j], csvData[i]]\n}", "function swapElement(array, indexA, indexB) {\n const temp = array[indexA];\n array[indexA] = array[indexB];\n array[indexB] = temp;\n }", "function swap(a, b) {\n if (a > b) {\n a ^= b;\n b ^= a;\n a ^= b;\n\n console.log('Swapped:');\n console.log('a=' + a);\n console.log('b=' + b);\n } else {\n console.log('NOT swapped');\n }\n}", "function swap(a, i, j) {\n\tlet temp = a[i];\n\ta[i] = a[j];\n\ta[j] = temp;\n}" ]
[ "0.77183545", "0.75518435", "0.7456719", "0.74516267", "0.7449057", "0.7441188", "0.7395601", "0.73703724", "0.72045845", "0.7175213", "0.7130356", "0.7096268", "0.70710194", "0.70570165", "0.705149", "0.70360345", "0.702523", "0.69908166", "0.69832885", "0.6976202", "0.69714636", "0.6967803", "0.6967596", "0.6964322", "0.6961491", "0.69555664", "0.6943627", "0.69394124", "0.69394124", "0.6929887", "0.692577", "0.6894638", "0.68938595", "0.68938595", "0.68938595", "0.6887808", "0.6886242", "0.6883965", "0.68788534", "0.6868792", "0.6858952", "0.6856103", "0.68363434", "0.6832977", "0.6830882", "0.68292546", "0.68026274", "0.6795036", "0.67779136", "0.67575437", "0.67572474", "0.67464674", "0.6739124", "0.67388976", "0.6736941", "0.6734241", "0.67338794", "0.67256653", "0.672073", "0.67189485", "0.6718298", "0.66969657", "0.6676446", "0.667298", "0.6668825", "0.6659546", "0.6658266", "0.66547674", "0.6652864", "0.6635911", "0.6633277", "0.662949", "0.66178703", "0.66132444", "0.6600367", "0.6528541", "0.6516411", "0.6513567", "0.6509983", "0.6493792", "0.64910185", "0.6483478", "0.64796144", "0.6474914", "0.647201", "0.6464195", "0.645625", "0.6455718", "0.6448937", "0.64439464", "0.6428392", "0.64194244", "0.6418238", "0.64181185", "0.641592", "0.6410988", "0.6406336", "0.63962376", "0.63882715", "0.63857573", "0.6381173" ]
0.0
-1
Return true for events we want to keep, false to ignore
function fixParsedEvent(parsedEvent, backupSiteId, serverTs, eventId, dateMap, fileDateIndex) { // Field names repairFieldNames(parsedEvent); // Check that basic info is available if (!parsedEvent.pageUrl || !parsedEvent.browserUserAgent) { // Almost never happens // console.log('No page url or new user agent'); // console.log(parsedEvent.name); return false; } // Date and index // Get the year, month and date from the server ts rather than the file, because there can be a discrepancy const date = new Date(serverTs); parsedEvent.date = { year: date.getUTCFullYear(), month: date.getUTCMonth() + 1, day: date.getUTCDate() }; const dateAsNum = getDateAsNumber(parsedEvent.date), newDateIndex = dateMap[dateAsNum]; parsedEvent.dateIndex = newDateIndex; if (typeof newDateIndex !== 'number') { if (dateAsNum === 20160131) { console.log('Event before beginning of time (Feb 1, 2016) -- throwing away: ', ++ tooOldCounter); return false; } console.log('Bad date: ' + newDateIndex + ' from ' + dateAsNum + ' / ' + JSON.stringify(parsedEvent.date)); return false; } if (newDateIndex !== fileDateIndex) { if (newDateIndex < fileDateIndex - 1 || newDateIndex > fileDateIndex + 1) { console.log('Strange date index discrepency, off by more than 1 day: ' + fileDateIndex + ' => ' + newDateIndex); } else { console.log('Date index discrepency for dateIndex = %d (%s): ', dateAsNum, newDateIndex > fileDateIndex ? '+1' : '-1', ++ dateIndexDiscrepencyCounter); } } // Event ID parsedEvent.eventId = eventId; // Site ID parsedEvent.siteId = (parsedEvent.siteId || backupSiteId).trim(); // Server time parsedEvent.serverTs = serverTs; // Window name simplification -- sometimes the names are ridiculously large if (parsedEvent.details && parsedEvent.details.windowName) { parsedEvent.details.windowName = parsedEvent.details.windowName.substr(0, 30); } // Garbage AB test check if (typeof parsedEvent.abTest === 'string') { if (parsedEvent.abTest.startsWith('moreButtonTimer.')) { delete parsedEvent.abTest; } } else if (typeof parsedEvent.abTest !== 'undefined') { delete parsedEvent.abTest; } // Event-specific fixes const eventSpecificRepairFn = eventSpecificRepair[parsedEvent.name]; if (eventSpecificRepairFn) { eventSpecificRepairFn(parsedEvent); } // Version const version = parsedEvent.scVersion, simplifiedVersionString = version && version.replace('-RELEASE', ''); parsedEvent.version = simplifiedVersionString; // Metadata parsedEvent.meta = metaData(parsedEvent); // Garbage session id fix if (parsedEvent.userId && (simplifiedVersionString === '4.2.7' || simplifiedVersionString === '4.2.8')) { // Create a session ID unique to this user and this domain const newSessionId = parsedEvent.userId + '-' + parsedEvent.meta.domain + '-' + newDateIndex; parsedEvent.sessionId = newSessionId; } // TODO Debug null session ids and page view ids! // else { // if (!parsedEvent.sessionId && parsedEvent.name !== 'page-visited' && parsedEvent.name !== 'error') { // console.log(JSON.stringify(parsedEvent)); // } // } // Keep or ignore? if (shouldKeep(parsedEvent)) { removeUnusedFields(parsedEvent); return true; } return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "ignoreEvent(event) { return true; }", "filterEvent(event) {\n return false;\n }", "has(e) {\n return !!this.events[e];\n }", "stopEvent(event) {\n return false;\n }", "function shouldEventBeIgnored(event){\n // This adds an easter egg to only play closed PRs\n if (!!ULTIMATE_DREAM_KILLER)\n return (event.type !== \"PullRequestEvent\" || event.action !== \"closed\");\n\n return false;\n}", "function excludeEvents(name) {\n const isFailing = [\n 'onresume',\n 'onfreeze',\n 'onreadystatechange',\n 'onpointerlockchange',\n 'onpointerlockerror',\n 'onselectionchange',\n 'onvisibilitychange',\n 'onsecuritypolicyviolation',\n ].includes(name);\n\n return !isFailing;\n}", "function eventsPending(events) {\n\t\treturn events.filter((event) => {\n\t\t\treturn event.accepted === undefined ? true : false;\n\t\t});\n\t}", "function shouldIgnore(event) {\n return isEditable(eventTarget(event)) || hasModifiers(event);\n}", "removeAllListeners(eventName) {\r\n if (eventName in this.events === false) return false;\r\n\r\n delete this.events[eventName];\r\n return true;\r\n }", "function recentStopFilterEnter() {\n return true;\n }", "function _dropOldEvents(){\n if(!_storage.__jstorage_meta.PubSub){\n return;\n }\n\n var retire = +new Date() - 2000;\n\n for(var i=0, len = _storage.__jstorage_meta.PubSub.length; i<len; i++){\n if(_storage.__jstorage_meta.PubSub[i][0] <= retire){\n // deleteCount is needed for IE6\n _storage.__jstorage_meta.PubSub.splice(i, _storage.__jstorage_meta.PubSub.length - i);\n break;\n }\n }\n\n if(!_storage.__jstorage_meta.PubSub.length){\n delete _storage.__jstorage_meta.PubSub;\n }\n\n }", "function removeAllEventsFromDisplay() {\n cosmo.view.cal.itemRegistry.each(removeEventFromDisplay);\n return true;\n }", "function removeEvents() {\n if (activeEvents) {\n var currentVideoTime = playbackController.getTime();\n var eventIds = Object.keys(activeEvents);\n\n for (var i = 0; i < eventIds.length; i++) {\n var eventId = eventIds[i];\n var curr = activeEvents[eventId];\n if (curr !== null && (curr.duration + curr.presentationTime) / curr.eventStream.timescale < currentVideoTime) {\n log('Remove Event ' + eventId + ' at time ' + currentVideoTime);\n curr = null;\n delete activeEvents[eventId];\n }\n }\n }\n }", "function isEvent() {\n trigger = 1;\n if (label === eventLabel) {\n eventTrigger = true;\n return true;\n } else {\n eventTrigger = false;\n return false;\n }\n}", "function eventIsClean(e) {\n\tvar targetTag = e.target.tagName;\n\tvar keyCode = e.which;\n\treturn !e.altKey && !e.ctrlKey && !e.metaKey &&\n\t targetTag != \"TEXTAREA\" && targetTag != \"INPUT\" &&\n\t (keyCode == keyCodeForPrev || keyCode == keyCodeForNext);\n}", "addEvent(event){\n if (this.events.includes(event.id)) {\n return false;\n } else {\n this.events.push(event.id);\n return true;\n }\n }", "function defaultFilter() {\n\t return !exports.event.button;\n\t}", "function defaultFilter() {\n\t return !exports.event.button;\n\t}", "function defaultFilter() {\n\t return !exports.event.button;\n\t}", "function defaultFilter() {\n\t return !exports.event.button;\n\t}", "removeAllEvents() {\n return this.each(el => el.removeAllEvents());\n }", "function hasEvent2(event,entry){\n\tfor(var i=0;i<entry[\"events\"].length;i++){\n\t\tif(entry[\"events\"][i] == event){\n\t\t\treturn true;\n\t\t}\n\t}\n\treturn false;\n}", "function defaultFilter() {\n\t return !exports.event.button;\n\t }", "function defaultFilter() {\n\t return !exports.event.button;\n\t }", "function isEventHandled(value){return value==='handled'||value===true;}", "function defaultFilter() {\n return !exports.event.button;\n }", "async function checkOtherEvent(){\n let beginDate = Math.round(new Date(datetimeBegin).getTime()/1000);\n let endDate = Math.round(new Date(datetimeEnd).getTime()/1000);\n let allEvents = await firebase.getEventData();\n\n let check = false;\n let stop = false;\n allEvents.forEach(event => {\n if( !stop ){\n if( (beginDate > event.endDateTimestamp) || (beginDate < event.beginDateTimestamp && endDate < event.beginDateTimestamp) ){\n check = true;\n }else {\n check = false;\n stop = true;\n }\n }\n })\n return check;\n }", "function Event_IsSingleEvent(event1)\n{\n\t//default: its a single event\n\tvar bRes = true;\n\t//switch according to the event\n\tswitch (event1)\n\t{\n\t\tcase __NEMESIS_EVENT_DRAGDROP:\n\t\t\t//this is a double event\n\t\t\tbRes = false;\n\t\t\tbreak;\n\t}\n\t//return the result\n\treturn bRes;\n}", "eraseUntouched() {\n let toRemove = [];\n for (var packetId in this.packetIdToData) {\n if (!this.touchedPacketsIds[packetId]) {\n toRemove.push(packetId);\n }\n }\n\n toRemove.forEach(packetId => {\n console.info(\"Packet \" + packetId + \" no longer used.\");\n\n delete this.packetIdToData[packetId];\n\n if (this.requestedPacketIds[packetId]) {\n delete this.requestedPacketIds[packetId];\n }\n });\n\n for (var packetId in this.touchedPacketsIds) {\n if (!this.packetIdToData[packetId]) {\n return false;\n }\n }\n\n return true;\n }", "function excludeEventsBySources(specificEvents, specificSources) {\n\t\t\treturn $.grep(specificEvents, function(event) {\n\t\t\t\tfor (var i = 0; i < specificSources.length; i++) {\n\t\t\t\t\tif (event.source === specificSources[i]) {\n\t\t\t\t\t\treturn false; // exclude\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn true; // keep\n\t\t\t});\n\t\t}", "function defaultFilter() {\n return !exports.event.button;\n}", "function defaultFilter() {\n return !exports.event.button;\n}", "function defaultFilter() {\n return !exports.event.button;\n}", "function defaultFilter() {\n return !exports.event.button;\n}", "function latch(event, equals = (a, b) => a === b, disposable) {\n let firstCall = true;\n let cache;\n return filter(event, value => {\n const shouldEmit = firstCall || !equals(value, cache);\n firstCall = false;\n cache = value;\n return shouldEmit;\n }, disposable);\n }", "function defaultFilter$2() {\n return !exports.event.button;\n }", "function defaultFilter$1() {\n return !exports.event.button;\n }", "supports(eventName) {\n return KeyEventsPlugin.parseEventName(eventName) != null;\n }", "supports(eventName) {\n return KeyEventsPlugin.parseEventName(eventName) != null;\n }", "supports(eventName) {\n return KeyEventsPlugin.parseEventName(eventName) != null;\n }", "supports(eventName) {\n return KeyEventsPlugin.parseEventName(eventName) != null;\n }", "supports(eventName) {\n return KeyEventsPlugin.parseEventName(eventName) != null;\n }", "function excludeEventsBySources(specificEvents, specificSources) {\n\t\treturn $.grep(specificEvents, function(event) {\n\t\t\tfor (var i = 0; i < specificSources.length; i++) {\n\t\t\t\tif (event.source === specificSources[i]) {\n\t\t\t\t\treturn false; // exclude\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn true; // keep\n\t\t});\n\t}", "function excludeEventsBySources(specificEvents, specificSources) {\n\t\treturn $.grep(specificEvents, function(event) {\n\t\t\tfor (var i = 0; i < specificSources.length; i++) {\n\t\t\t\tif (event.source === specificSources[i]) {\n\t\t\t\t\treturn false; // exclude\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn true; // keep\n\t\t});\n\t}", "function excludeEventsBySources(specificEvents, specificSources) {\n\t\treturn $.grep(specificEvents, function(event) {\n\t\t\tfor (var i = 0; i < specificSources.length; i++) {\n\t\t\t\tif (event.source === specificSources[i]) {\n\t\t\t\t\treturn false; // exclude\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn true; // keep\n\t\t});\n\t}", "function excludeEventsBySources(specificEvents, specificSources) {\n\t\treturn $.grep(specificEvents, function(event) {\n\t\t\tfor (var i = 0; i < specificSources.length; i++) {\n\t\t\t\tif (event.source === specificSources[i]) {\n\t\t\t\t\treturn false; // exclude\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn true; // keep\n\t\t});\n\t}", "function defaultFilter$2() {\n\t return !exports.event.button;\n\t}", "function defaultFilter$2() {\n\t return !exports.event.button;\n\t}", "function defaultFilter$2() {\n\t return !exports.event.button;\n\t}", "function defaultFilter$2() {\n\t return !exports.event.button;\n\t}", "function defaultFilter$2() {\n\t return !exports.event.button;\n\t }", "function defaultFilter$2() {\n\t return !exports.event.button;\n\t }", "function cleanEvent() {\n\tvar removable = ACT.Event.removable;\n\tfor (var itor = 0; itor < removable.length; itor++) {\n\t\tif (removable[itor].eventType === 'env:envRendered') continue;\n\t\tif (removable[itor].eventType === 'message') continue;\n\t\tif (removable[itor].eventType === 'screen:status') continue;\n\t\tif (removable[itor].eventType === 'collapseStart') continue;\n if (removable[itor].eventType === 'html5:message') continue;\n\t\tremovable[itor].remove();\n\t}\n\tACT.Event.removable = [];\n}", "function checkCurrent() {\n var i = 0;\n var currentTime = new Date();\n while (i < $scope.events.length) {\n var ev = $scope.events[i];\n ev.current = false;\n var evStart = new Date(ev.start.dateTime);\n var evEnd = new Date(ev.end.dateTime);\n if (currentTime >= evStart && currentTime <= evEnd) {\n ev.current = true;\n }\n i += 1;\n }\n }", "function defaultFilter() {\n return !on_event.ctrlKey && !on_event.button;\n}", "function defaultFilter() {\n return !on_event.ctrlKey && !on_event.button;\n}", "function defaultFilter$2() {\n return !exports.event.button;\n}", "function defaultFilter$2() {\n return !exports.event.button;\n}", "function defaultFilter$2() {\n return !exports.event.button;\n}", "function defaultFilter$2() {\n return !exports.event.button;\n}", "function filterByMatch(event) {\n return ;\n}", "function defaultFilter$1() {\n return !exports.event.button;\n}", "function defaultFilter$1() {\n return !exports.event.button;\n}", "function defaultFilter$1() {\n return !exports.event.button;\n}", "function defaultFilter$1() {\n return !exports.event.button;\n}", "function defaultFilter$1() {\n\t return !exports.event.button;\n\t}", "function defaultFilter$1() {\n\t return !exports.event.button;\n\t}", "function defaultFilter$1() {\n\t return !exports.event.button;\n\t}", "function defaultFilter$1() {\n\t return !exports.event.button;\n\t}", "get hasAcceptedEvents() {\n return this.hasOwnProperty('acceptedEvents');\n }", "function defaultFilter$1() {\n\t return !exports.event.button;\n\t }", "function defaultFilter$1() {\n\t return !exports.event.button;\n\t }", "supports(eventName) {\n return KeyEventsPlugin.parseEventName(eventName) != null;\n }", "function hasEvent(event, entry) {\r\n return entry.events.indexOf(event) != -1;\r\n}", "function filter(event) {\n var target = event.target || event.srcElement;\n var tagName = target.tagName;\n // Ignore these cases, the shortcut key is invalid\n\n return !(tagName === 'INPUT' || tagName === 'SELECT' || tagName === 'TEXTAREA' || target.isContentEditable);\n }", "function filter(event) {\n var target = event.target || event.srcElement;\n var tagName = target.tagName;\n var flag = true; // ignore: isContentEditable === 'true', <input> and <textarea> when readOnly state is false, <select>\n\n if (target.isContentEditable || tagName === 'TEXTAREA' || (tagName === 'INPUT' || tagName === 'TEXTAREA') && !target.readOnly) {\n flag = false;\n }\n\n return flag;\n} // 判断摁下的键是否为某个键,返回true或者false", "function defaultFilter(event) {\n return !event.ctrlKey && !event.button;\n}", "function defaultFilter(event) {\n return !event.ctrlKey && !event.button;\n}", "function defaultFilter(event) {\n return !event.ctrlKey && !event.button;\n}", "function defaultFilter(event) {\n return !event.ctrlKey && !event.button;\n}", "function defaultFilter(event) {\n return !event.ctrlKey && !event.button;\n}", "function shouldSkipDOMEvent(event) {\n // We are only interested in filtering `keypress` events for now.\n if (event.type !== 'keypress') {\n return false;\n }\n\n try {\n const target = event.target ;\n\n if (!target || !target.tagName) {\n return true;\n }\n\n // Only consider keypress events on actual input elements. This will disregard keypresses targeting body\n // e.g.tabbing through elements, hotkeys, etc.\n if (target.tagName === 'INPUT' || target.tagName === 'TEXTAREA' || target.isContentEditable) {\n return false;\n }\n } catch (e) {\n // just accessing `target` property can throw an exception in some rare circumstances\n // see: https://github.com/getsentry/sentry-javascript/issues/838\n }\n\n return true;\n }", "function filter(event) {\n var target = event.target || event.srcElement;\n var tagName = target.tagName;\n var flag = true; // ignore: isContentEditable === 'true', <input> and <textarea> when readOnly state is false, <select>\n\n if (target.isContentEditable || (tagName === 'INPUT' || tagName === 'TEXTAREA') && !target.readOnly) {\n flag = false;\n }\n\n return flag;\n} // 判断摁下的键是否为某个键,返回true或者false", "function filter(event) {\n var target = event.target || event.srcElement;\n var tagName = target.tagName;\n var flag = true; // ignore: isContentEditable === 'true', <input> and <textarea> when readOnly state is false, <select>\n\n if (target.isContentEditable || (tagName === 'INPUT' || tagName === 'TEXTAREA') && !target.readOnly) {\n flag = false;\n }\n\n return flag;\n} // 判断摁下的键是否为某个键,返回true或者false", "function defaultFilter(event) {\n return !event.ctrlKey && !event.button;\n}", "function defaultFilter(event) {\n return !event.ctrlKey && !event.button;\n}", "function filter(event) {\n var target = event.target || event.srcElement;\n var tagName = target.tagName;\n var flag = true; // ignore: isContentEditable === 'true', <input> and <textarea> when readOnly state is false, <select>\n\n if (target.isContentEditable || (tagName === 'INPUT' || tagName === 'TEXTAREA' || tagName === 'SELECT') && !target.readOnly) {\n flag = false;\n }\n\n return flag;\n} // 判断摁下的键是否为某个键,返回true或者false", "function canUse() {\n return fsevents && Object.keys(FSEventsWatchers).length < 128;\n}", "function _latch(event) {\n var firstCall = true;\n var cache;\n return _filter(event, function (value) {\n var shouldEmit = firstCall || value !== cache;\n firstCall = false;\n cache = value;\n return shouldEmit;\n });\n}", "function shouldShift(comm_arr, event){\n \n if((!inLiveHours()) && (comm_arr.length > 0)){\n var workHours = ('workHours' in comm_arr[0]) ? comm_arr[0].workHours : true //if no workHours field is set, assume it needs to be processed only in work hours\n \n if(workHours){\n console.log('shifting event');\n shiftEvents([event])\n return true\n }\n }\n \n return false\n}", "isStop() {\n return this.eventCallbackFibers.length == 1 && this.eventCallbackFibers[0].name == 'isEventManagerStop'\n }", "function ignoreDragging() {\n try {\n window.event.returnValue = false; }\n catch (e) {}\n return false; }", "function defaultFilter$1(event) {\n return !event.ctrlKey && !event.button;\n}", "function Event_IgnoreData(eClass, eEvent)\n{\n\t//by default we never compare data\n\tvar bIgnoreData = true;\n\t//check the class\n\tswitch (eClass)\n\t{\n\t\tcase __NEMESIS_CLASS_COMBO_BOX:\n\t\tcase __NEMESIS_CLASS_TAB_CONTROL:\n\t\tcase __NEMESIS_CLASS_TOOL_BAR:\n\t\tcase __NEMESIS_CLASS_TREE_VIEW:\n\t\tcase __NEMESIS_CLASS_LIST_BOX:\n\t\tcase __NEMESIS_CLASS_LIST_VIEW:\n\t\tcase __NEMESIS_CLASS_TREE_GRID:\n\t\tcase __NEMESIS_CLASS_POPUP_MENU:\n\t\tcase __NEMESIS_CLASS_NAV_BAR:\n\t\tcase __NEMESIS_CLASS_ULTRAGRID:\n\t\t\t//these ALWAYS require data check\n\t\t\tbIgnoreData = false;\n\t\t\tbreak;\n\t\tdefault:\n\t\t\t//now check the event itself\n\t\t\tswitch (eEvent)\n\t\t\t{\n\t\t\t\tcase __NEMESIS_EVENT_CHANGE:\n\t\t\t\tcase __NEMESIS_EVENT_FOCUSOUT:\n\t\t\t\tcase __NEMESIS_EVENT_KEYDOWN:\n\t\t\t\tcase __NEMESIS_EVENT_MENUSELECT:\n\t\t\t\t\t//these ALWAYS require data check\n\t\t\t\t\tbIgnoreData = false;\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t\tbreak;\n\t}\n\t//return the result\n\treturn bIgnoreData;\n}", "function isPromiEvent(value) {\n return !!value[promiEventBrand];\n}", "function hasQueuedDiscreteEvents() {\n return queuedDiscreteEvents.length > 0;\n}", "function hasQueuedDiscreteEvents() {\n return queuedDiscreteEvents.length > 0;\n}", "set silenceEvents(status) {\n eventStates.silenceEvents = status? true : false;\n }", "function shouldSkipDOMEvent(event) {\n\t // We are only interested in filtering `keypress` events for now.\n\t if (event.type !== 'keypress') {\n\t return false;\n\t }\n\n\t try {\n\t const target = event.target ;\n\n\t if (!target || !target.tagName) {\n\t return true;\n\t }\n\n\t // Only consider keypress events on actual input elements. This will disregard keypresses targeting body\n\t // e.g.tabbing through elements, hotkeys, etc.\n\t if (target.tagName === 'INPUT' || target.tagName === 'TEXTAREA' || target.isContentEditable) {\n\t return false;\n\t }\n\t } catch (e) {\n\t // just accessing `target` property can throw an exception in some rare circumstances\n\t // see: https://github.com/getsentry/sentry-javascript/issues/838\n\t }\n\n\t return true;\n\t}", "function allRelevantEventsLoaded (events) {\n return events.some(event => moment(event.Timestamp).valueOf() < startedAt)\n }", "function shouldSkipDOMEvent(event) {\n // We are only interested in filtering `keypress` events for now.\n if (event.type !== 'keypress') {\n return false;\n }\n try {\n var target = event.target;\n if (!target || !target.tagName) {\n return true;\n }\n // Only consider keypress events on actual input elements. This will disregard keypresses targeting body\n // e.g.tabbing through elements, hotkeys, etc.\n if (target.tagName === 'INPUT' || target.tagName === 'TEXTAREA' || target.isContentEditable) {\n return false;\n }\n }\n catch (e) {\n // just accessing `target` property can throw an exception in some rare circumstances\n // see: https://github.com/getsentry/sentry-javascript/issues/838\n }\n return true;\n}" ]
[ "0.7149208", "0.68852717", "0.64330953", "0.6242025", "0.6164724", "0.59778744", "0.58658725", "0.5808228", "0.58077973", "0.5753746", "0.5722709", "0.57148975", "0.56845635", "0.5684476", "0.5672289", "0.56389", "0.5618865", "0.5618865", "0.5618865", "0.5618865", "0.560033", "0.55979806", "0.55880064", "0.55880064", "0.55848426", "0.5567491", "0.5558833", "0.55519104", "0.5548243", "0.5547684", "0.550015", "0.550015", "0.550015", "0.550015", "0.54964226", "0.5482908", "0.54669046", "0.5466191", "0.5466191", "0.5466191", "0.5466191", "0.5466191", "0.5463244", "0.5463244", "0.5463244", "0.5463244", "0.5459672", "0.5459672", "0.5459672", "0.5459672", "0.54521286", "0.54521286", "0.5451956", "0.54449654", "0.5443218", "0.5443218", "0.54400367", "0.54400367", "0.54400367", "0.54400367", "0.5437092", "0.5432612", "0.5432612", "0.5432612", "0.5432612", "0.54319113", "0.54319113", "0.54319113", "0.54319113", "0.5421399", "0.5418246", "0.5418246", "0.5389646", "0.53762", "0.5369711", "0.53632194", "0.5362194", "0.5362194", "0.5362194", "0.5362194", "0.5362194", "0.53617984", "0.5350734", "0.5350734", "0.5349444", "0.5349444", "0.53458995", "0.53356457", "0.5332946", "0.53207177", "0.5318569", "0.5307006", "0.5297219", "0.5293576", "0.52924544", "0.5289066", "0.5289066", "0.52865", "0.5281872", "0.5263301", "0.52411664" ]
0.0
-1
[Config Functions] Hide Custom Panels
function customPanel_visibility(state) { let inverse = 'Auto'; let panels = { "Message": "", "Panels": [] } if (hideCustomPanels_inUSBMode.toString() == "true" ? true : false) { if (state == "Hidden") { panels.Message = 'Hide Custom UI in USB Mode is enabled, Hiding the following panel IDs: ' } else { panels.Message = 'Hide Custom UI in USB Mode is enabled, Showing the following panel IDs: ' } for (let i = 0; i < hideCustomPanels_inUSBMode_PanelIds.length; i++) { panels.Panels.push(hideCustomPanels_inUSBMode_PanelIds[i]) xapi.command('UserInterface Extensions Panel Update', { PanelId: hideCustomPanels_inUSBMode_PanelIds[i], Visibility: state }).catch(e => console.debug(e)) } console.debug(panels) } else { for (let i = 0; i < hideCustomPanels_inUSBMode_PanelIds.length; i++) { panels.Panels.push(hideCustomPanels_inUSBMode_PanelIds[i]) xapi.command('UserInterface Extensions Panel Update', { PanelId: hideCustomPanels_inUSBMode_PanelIds[i], Visibility: 'Auto' }).catch(e => console.debug(e)) } } if (hideCustomPanels_inDefaultMode.toString() == "true" ? true : false) { if (state == 'Auto') { inverse = 'Hidden'; panels.Message = 'Hide Custom UI in Default Mode is enabled, Hiding the following panel IDs: ' } else { inverse = 'Auto' panels.Message = 'Hide Custom UI in Default Mode is enabled, Showing the following panel IDs: ' } for (let i = 0; i < hideCustomPanels_inDefaultMode_PanelIds.length; i++) { panels.Panels.push(hideCustomPanels_inDefaultMode_PanelIds[i]) xapi.command('UserInterface Extensions Panel Update', { PanelId: hideCustomPanels_inDefaultMode_PanelIds[i], Visibility: inverse }).catch(e => console.debug(e)) } console.debug(panels) } else { for (let i = 0; i < hideCustomPanels_inDefaultMode_PanelIds.length; i++) { panels.Panels.push(hideCustomPanels_inDefaultMode_PanelIds[i]) xapi.command('UserInterface Extensions Panel Update', { PanelId: hideCustomPanels_inDefaultMode_PanelIds[i], Visibility: 'Auto' }).catch(e => console.debug(e)) } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function hidePanels(){\n\tvar controller = abRepmAddEditLeaseInABuilding_ctrl;\t\n\tcontroller.abRepmAddEditLeaseInABuildingLeaseInfo_form.show(false);\n\tcontroller.abRepmAddEditLeaseInABuildingDocs_grid.show(false);\n\tcontroller.abRepmAddEditLeaseInABuildingBaseRents_grid.show(false);\n}", "function hideControlPanel () {\n\n controlPanel.style.display = 'none';\n\n }", "function hidePanel(theInstance) { \n if (!document.getElementById) {\n return null;\n }\n\n document.getElementById(\"panel\" + \"_\" + theInstance).style.visibility = \"hidden\";\n \n // Start Override: if we are hiding the imageViewer and it was displayed Inline, resizePanels\n if (theInstance == \"imageViewer\" && imagePanelInline) {\n resizePanels();\n }\n}", "function hidePropMenu() {\n propBoxLabel.hide();\n ipNameLabel.hide();\n colNameLabel.hide();\n labCaptLabel.hide();\n opNameLabel.hide();\n inputIsTopBox.hide();\n inputCaptionBox.hide();\n outputCaptionBox.hide();\n outputColorBox.hide();\n labelTextBox.hide();\n clockspeedLabel.hide();\n clockspeedSlider.hide();\n}", "function handleHidePanel() {\n\tbutton.state('window', {checked: false});\n}", "function hideChatWizContainer() {\n\t\t\t\tsendPostMessage({\"lpEmbChatWiz\": \"LPNVPF\", \"CMD\" : \"CONTROL\", \"value\" : \"HIDE_CONTAINER\"});\n\t\t\t}", "function hide() {\n if (visible) {\n panel.classList.remove(SHOW_CLASS);\n setTimeout(function () {\n panel.style.display = \"none\";\n }, 300);\n\n currentPanel = NO_PANEL;\n visible = false;\n self.port.emit(\"panel-hidden\");\n setTimeout(function () {\n if (body !== undefined) {\n body.removeChild(overlay);\n body.style.overflow = \"auto\";\n while (overlay.hasChildNodes()) {\n overlay.removeChild(overlay.lastChild);\n }\n }\n }, 300);\n }\n}", "function disable() {\n\thideIcon(false);\n\thideLabel(false);\n\thideArrow(false);\n}", "function hideWinPanel(){\n let winPanel = document.getElementsByClassName(\"win-panel\")[0];\n winPanel.style.display = \"none\";\n}", "_hide() {\n this.panelElem.addClass(\"hidden\");\n }", "function hideSettings() {\n settingsContainer.classList.add('hidden');\n}", "function _hidePanelsIfRequired() {\n var panelIDs = WorkspaceManager.getAllPanelIDs();\n _previouslyOpenPanelIDs = [];\n panelIDs.forEach(function (panelID) {\n var panel = WorkspaceManager.getPanelForID(panelID);\n if (panel && panel.isVisible()) {\n panel.hide();\n _previouslyOpenPanelIDs.push(panelID);\n }\n });\n }", "function hideSelectorContainers(){\n\thideTypeSelector();\n\thidePlayerSelector();\n\thideYearSelector();\n\thideWeekSelector();\n\thideStatNameSelector();\n\thideTeamSelector();\n}", "function hideGUIForever () {\r\n $('#buttonsPanel')\r\n .add('#player-logo')\r\n .add('#presentation-info')\r\n .add('.leftButton')\r\n .add('.rightButton')\r\n .add('#menu-container')\r\n .add('#timelinebutton').removeClass('show').addClass('hidden');\r\n\r\n // Disable all GUI handlers\r\n $('html').off(\"mouseenter\", showGUI);\r\n $('html').off(\"mouseleave\", hideGUI);\r\n $('#scene').off('mousemove');\r\n }", "function update_wallpaper_option_panels_visibility()\n {\n const value = DOM.is_enabled.checked ? \"block\" : \"none\";\n DOM.panels.forEach(panel => { panel.style.display = value; });\n }", "hide() {\n\t\tthis.panelEl.classList.remove(classes.panel.open);\n\t\tthis.panelEl.classList.add(classes.panel.closed);\n\t}", "function mainPanelOff() {\n (Settings.niceView) ? mainPanel1.setAttributeNS(null, \"fill\", \"#000\") : mainPanel0.setAttributeNS(null, \"fill\", \"#000\");\n}", "function HideSlidePanel() {\r\n //set aria-hidden to true for accessibility\r\n $(\"#SlidePanel\").attr(\"aria-hidden\", \"true\");\r\n $(\"#SlidePanel\").attr(\"role\", \"menuitem\");\r\n $(\"#SlidePanel\").hide();\r\n}", "function hidePlayerControls() {\n\tif(controlsVisible) {\n\t\t$(\".playerArea\").hide(200, \"swing\");\n\t\tcontrolsVisible = false;\n\t}\n}", "Hide() {\n if (this.COLLIDER != undefined) \n this.COLLIDER.Disable();\n \n return super.Hide();\n }", "function removeConfigPane(el) {\n var panel = $(el).find('.data-grid-settings');\n $(panel).fadeOut('fast');\n // Undo forced minimum height on the container.\n $(el).css('min-height', '');\n }", "function showSettings() {\n settingsContainer.classList.remove('hidden');\n}", "static hidePopup(panelNode) {\n let panelMultiViewNode = panelNode.querySelector(\"panelmultiview\");\n if (panelMultiViewNode) {\n this.forNode(panelMultiViewNode).hidePopup();\n } else {\n panelNode.hidePopup();\n }\n }", "function ac_showConfigPanel() {\n\tac_switchTool(\"cfg\");\n}", "function hideUIOverlays() {\r\n endEdgeDrawing();\r\n deselectAllNodes();\r\n Context.hideAllMenus();\r\n Tooltip.hideAllTooltips();\r\n Canvas.update();\r\n}", "hide ()\n\t{\n\t\t//hide the elements of the view\n\t\tthis.root.style.display= 'none';\n\t}", "function mydoc_off()\n{\n\n\tcheck_advert_status();\n\tcheck_sidepanel_hieght();\n show('map');\n hide('gallery_id');\n\thide('chart_gallery_id')\n\thide('weather_gallery_id')\n\thide('uc_image');\n\n\t//for hide show details window\n\thide('more_info');\n\n}", "function panelHide(){\n\tpanelView = '';\n\t$('#panel').fadeTo(218, 0);\n\t$('#main_').animate({\n\t\t'top': panelTop\n\t}, 218);\n\t\n\t$('#button-hidepanel').css('display', 'none');\n}", "function hideSettings() {\n $(this).parent(s.projectSettingsOverlay).slideUp(600);\n }", "function hideSettings() {\n $(this).parent(s.projectSettingsOverlay).slideUp(600);\n }", "function hideInnerPanel(container){\r\n\t\t$(container).find('.combo-f').each(function(){\r\n\t\t\tvar p = $(this).combo('panel');\r\n\t\t\tif (p.is(':visible')){\r\n\t\t\t\tp.panel('close');\r\n\t\t\t}\r\n\t\t});\r\n\t}", "function hideAlgorithmSelectionPanel() {\n\n document.getElementById(\"algorithmSelectionPanel\").style.display=\"none\";\n hdxGlobals.algSelectScreen = false;\n}", "function hide() {\n\t\t\n\t\t$('.minicolors-input').each( function() {\n\t\t\t\n\t\t\tvar input = $(this),\n\t\t\t\tsettings = input.data('minicolors-settings'),\n\t\t\t\tminicolors = input.parent();\n\t\t\t\n\t\t\t// Don't hide inline controls\n\t\t\tif( settings.inline ) return;\n\t\t\t\n\t\t\tminicolors.find('.minicolors-panel').fadeOut(settings.hideSpeed, function() {\n\t\t\t\tif(minicolors.hasClass('minicolors-focus')) {\n\t\t\t\t\tif( settings.hide ) settings.hide.call(input.get(0));\n\t\t\t\t}\n\t\t\t\tminicolors.removeClass('minicolors-focus');\n\t\t\t});\t\t\t\n\t\t\t\t\t\t\n\t\t});\n\t}", "hidePane() {\n this.modalPanel.hide()\n }", "function hideAllPanels() {\n $('#AllLeads').hide();\n $('#AddLead').hide();\n $('#LeadDetails').hide();\n $('#AllOpps').hide();\n $('#OppDetails').hide();\n $('#AllSales').hide();\n $('#SaleDetails').hide();\n $('#AllLostSales').hide();\n $('#LostSaleDetails').hide();\n $('#AllReports').hide();\n $('#amountPipeline').hide();\n $('#countPipeline').hide();\n $('#chartArea').hide();\n $('#drillDown').hide();\n $('#pipelineName').hide();\n $('#conversionName').hide();\n}", "hide() {}", "function showPanels() \n{ \n\tvar strHide = \"HIDDEN\"; \n var strShow = \"SHOW\"; \n // Initial values \n var p_nav = strShow, \n p_zoom = strShow, \n p_overview = strShow, \n p_legend = strShow, \n p_download = strShow, \n p_measure = strShow, \n p_type = strShow, \n p_fullscreen = strShow; \n\t \n\t// get the panels to show \n\tif (g_panel != \"\") { \n\t\tvar panelsToShow = g_panel.spilt('+'); \n\t\tfor (var panel in panelsToShow) { \n\t\t\tif (panel == \"nav\") { \n\t\t\t\tp_nav = strShow; \n\t\t\t} \n\t\t\telse if (panel == \"zoom\") { \n\t\t\t\tp_zoom = strShow; \n\t\t\t} \n\t\t\telse if (panel == \"overview\") { \n\t\t\t\tp_overview = strShow; \n\t\t\t} \n\t\t\telse if (panel == \"legend\") { \n\t\t\t\tp_legend = strShow; \n\t\t\t} \n\t\t\telse if (panel == \"download\") { \n\t\t\t\tp_download = strShow; \n\t\t\t} \n\t\t\telse if (panel == \"measure\") { \n\t\t\t\tp_measure = strShow; \n\t\t\t} \n\t\t\telse if (panel == \"type\") { \n\t\t\t\tp_type = strShow; \n\t\t\t} \n\t\t\telse if (panel == \"fullscreen\") { \n\t\t\t\tp_fullscreen = strShow; \n\t\t\t} \n\t\t} \n\t} \n\t \n\t// get the panels to hide \n\tif (g_panel_hide != \"\") { \n\t\tvar panelsToHide = g_panel_hide.spilt('+'); \n\t\tfor (var panel in panelsToHide) { \n\t\t\tif (panel == \"nav\") { \n\t\t\t\tp_nav = strHide; \n\t\t\t} \n\t\t\telse if (panel == \"zoom\") { \n\t\t\t\tp_zoom = strHide; \n\t\t\t} \n\t\t\telse if (panel == \"overview\") { \n\t\t\t\tp_overview = strHide; \n\t\t\t} \n\t\t\telse if (panel == \"legend\") { \n\t\t\t\tp_legend = strHide; \n\t\t\t} \n\t\t\telse if (panel == \"download\") { \n\t\t\t\tp_download = strHide; \n\t\t\t} \n\t\t\telse if (panel == \"measure\") { \n\t\t\t\tp_measure = strHide; \n\t\t\t} \n\t\t\telse if (panel == \"type\") { \n\t\t\t\tp_type = strHide; \n\t\t\t} \n\t\t\telse if (panel == \"fullscreen\") { \n\t\t\t\tp_fullscreen = strHide; \n\t\t\t} \n\t\t} \n\t} \n\t \n\t// set visibility of the panels \n\tmap0.SetPanelVisibility(\"FLY\", p_nav); \n map0.SetPanelVisibility(\"ZOOM\", p_zoom); \n map0.SetPanelVisibility(\"OVERVIEW\", p_overview); \n map0.SetPanelVisibility(\"LEGEND\", p_legend); \n map0.SetPanelVisibility(\"BUY\", p_download); \n map0.SetPanelVisibility(\"MEASURE\", p_measure); \n map0.SetPanelVisibility(\"TYPE\", p_type); \n\tmap0.SetLogoVisibility(g_tflogo); \n\t \n\t//set legend \n\tif (p_legend == strShow && g_legend != \"\") { \n\t\tmap0.SetLegend(g_legend); \n\t} \n\t \n\t// set debug status \n\tif (g_debug == 0) { \n map0.ViewDebugPanel(false); \n map0.ViewTileURL(false); \n } \n if (g_debug == 1) { \n map0.ViewDebugPanel(false); \n map0.ViewTileURL(true); \n } \n if (g_debug == 2) { \n map0.ViewDebugPanel(true); \n map0.ViewTileURL(false); \n } \n if (g_debug == 3) { \n map0.ViewDebugPanel(true); \n map0.ViewTileURL(true); \n } \n}", "isHidden() {\n return false;\n }", "hideGUI( ) {\n this.fireCallback( this.events.eventHandle.onChangeVisibility, false );\n }", "hideDragButtons() {\n if (this.dragButtons) this.dragButtons.setVisible(false);\n }", "_hide_workspaces_thumbnails() {\n\t\tMain.overview._overview._controls._thumbnailsBox.hide();\n\t}", "function hide() {\r\n\t\t\r\n\t\t$('.minicolors-input').each( function() {\r\n\t\t\t\r\n\t\t\tvar input = $(this),\r\n\t\t\t\tsettings = input.data('minicolors-settings'),\r\n\t\t\t\tminicolors = input.parent();\r\n\t\t\t\r\n\t\t\t// Don't hide inline controls\r\n\t\t\tif( settings.inline ) return;\r\n\t\t\t\r\n\t\t\tminicolors.find('.minicolors-panel').fadeOut(settings.hideSpeed, function() {\r\n\t\t\t\tif(minicolors.hasClass('minicolors-focus')) {\r\n\t\t\t\t\tif( settings.hide ) settings.hide.call(input.get(0));\r\n\t\t\t\t}\r\n\t\t\t\tminicolors.removeClass('minicolors-focus');\r\n\t\t\t});\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t});\r\n\t}", "function hidePanel(theInstance) { \n if (!document.getElementById) {\n return null;\n}\n \ndocument.getElementById(\"panel\" + \"_\" + theInstance).style.visibility = \"hidden\";\n \n}", "hide() {\n\t\t\tif ( this._container ) {\n\t\t\t\tthis._container.style = 'display:none';\n\t\t\t}\n\t\t}", "hide() {\n this.container.classList.remove(\"enabled\");\n }", "function hideTooltips() {\n\t\tif (tooltips_element) {\n\t\t\ttooltips_element.style.display = 'none';\n\t\t}\n\t}", "function hideAwareness() {\n var projCont = document.getElementById(\"project-status-container\");\n projCont.style.display = \"none\";\n var chatCont = document.getElementById(\"chat-box-container\");\n chatCont.style.display = \"none\";\n}", "function hideAwareness() {\n var projCont = document.getElementById(\"project-status-container\");\n projCont.style.display = \"none\";\n var chatCont = document.getElementById(\"chat-box-container\");\n chatCont.style.display = \"none\";\n}", "function hideComponents(){\n components.forEach( (c) => c.hide());\n}", "function hideExt(state) {\n $('#toolbar-id').attr('hidden', state);\n $('#main-content-id').attr('hidden', state);\n}", "hiddenTools() {\n this.panelTool.classList.remove(\"hidden\");\n this.panelTool.classList.add(\"show\");\n }", "function hideAllInitialSections() {\n //Hideing all questions\n hideAllQuestions();\n // Hideing warning section\n hideWarningSection();\n // Hideing result section\n hideResultSection();\n // Hideing show high score section\n hideViewHighScoreSection();\n // Hideing saveToMemory section\n hideSaveToMemorySection();\n //Hideing High Score Result Section\n hideViewHighScoreResultSection()\n}", "function hideNotWorkingStuff() {\n // Top right account control buttons\n hide('#material-one-right #gb > div > div > div:not(:last-child)');\n style('#material-one-right #gb > div > div > div:last-child',\n { display: 'block', float: 'right' });\n style('#material-one-right #gb > div > div', { display: 'block', float: 'right' });\n cssRule('#material-one-right #gb {min-width: 40px !important}');\n\n // Built in mini player buttons\n hide('.player-top-right-items > paper-icon-button');\n\n // Settings options that won't work\n cssRule('#download { display: none !important }');\n cssRule('#manage-downloads { display: none !important }');\n cssRule('.subscription-gifting-card.settings-card {display: none !important}');\n\n // Hide the upload music button in settings\n cssRule('.music-sources-card.settings-card {display: none !important}');\n\n hide('.upload-dialog-bg', true);\n hide('.upload-dialog', true);\n\n cssRule('.song-menu.goog-menu.now-playing-menu > .goog-menuitem:nth-child(3) { display: none !important; }');\n}", "function hide() {\n toogle = 'hide'\n\n }", "function hideTravelNewsHelp() {\n setHelpPanels();\n\n try {\n helpPanelTravelNews.style.display = 'none';\n helpPanelTravelNewsNonMap.style.display = 'none';\n } catch (err) { }\n\n return false;\n}", "hide() {\n\t\tconsole.log('[NonVisualComponent.hide] invoked');\n\t}", "hide() {\n checkPresent(this.containerDiv, 'not present when hiding');\n // The visibility property must be a string enclosed in quotes.\n this.containerDiv.style.visibility = 'hidden';\n }", "function hidePageContainers() {\n var leftPanelScope = getLeftPanelScope();\n if (Utils.isMobile()) {\n leftPanelScope && leftPanelScope.collapse();\n WM.element(roleSelector(HEADER_CLASS_NAME) + \" \" + classSelector(SEARCH_CONTAINER_CLASS_NAME)).hide();\n $rootScope.sidebarCollapsed = true;\n }\n }", "function hideWidget() {\n widgets.forEach((widget) => {\n $(widget).css(\"z-index\", \"0\");\n $(widget).hide();\n $(widget).removeClass(\"active\");\n });\n}", "hide() {\n this.isVisible = false;\n }", "function hideSettingsPage() {\n document.getElementById('settings').classList.add('hidden');\n}", "function unhideControls() {\n\tdocument.querySelector('.hidden').style.visibility = 'visible';\n}", "hide()\n\t{\n\t\t// hide the decorations:\n\t\tsuper.hide();\n\n\t\t// hide the stimuli:\n\t\tif (typeof this._items !== \"undefined\")\n\t\t{\n\t\t\tfor (let i = 0; i < this._items.length; ++i)\n\t\t\t{\n\t\t\t\tif (this._visual.visibles[i])\n\t\t\t\t{\n\t\t\t\t\tconst textStim = this._visual.textStims[i];\n\t\t\t\t\ttextStim.hide();\n\n\t\t\t\t\tconst responseStim = this._visual.responseStims[i];\n\t\t\t\t\tif (responseStim)\n\t\t\t\t\t{\n\t\t\t\t\t\tresponseStim.hide();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// hide the scrollbar:\n\t\t\tthis._scrollbar.hide();\n\t\t}\n\t}", "function _sh_overview_hidden(){\n\tin_overview = false;\n\twrap_plane_clone.visible = false;\n\tif( paused_preserve ) pause();\n}", "function hideOrShowMenus(){\n\tresizeSidebar(\"menu\");\n}", "_hideAll() {\n this.views.directorySelection.hide();\n this.views.training.hide();\n this.views.messages.hide();\n this.views.directorySelection.css('visibility', 'hidden');\n this.views.training.css('visibility', 'hidden');\n this.views.messages.css('visibility', 'hidden');\n }", "function hideAllChildren(){\n uki.map( screens, function(screen){\n screen.visible(false);\n });\n }", "function hideGamePanel() {\n gamePanel.style.display = \"none\";\n}", "unhide() {\n document.getElementById(\"guiArea\").classList.remove(\"hideMe\");\n document.getElementById(\"guiAreaToggle\").classList.remove(\"hideMe\");\n }", "hideCommentsPanel() {\r\n document.getElementById(\"pano\").classList.add(\"hidden\");\r\n document.querySelector(\".filters\").classList.toggle(\"hidden\");\r\n document.getElementById(\"results\").classList.toggle(\"hidden\");\r\n document.getElementById(\"comments\").classList.toggle(\"hidden\");\r\n document.querySelector(\".omnibox\").classList.toggle(\"viewComments\");\r\n document.getElementById(\"commentsList\").innerHTML = \"\";\r\n document.querySelector(\".toolbar\").classList.toggle(\"hidden\");\r\n app.currentRestaurant = null;\r\n }", "function hideSlides(){\n $('.caps').hide()\n $('.headers').hide();\n}", "doHidden( root ) {\n root.style.display = 'none';\n }", "showOptionsPane() {\n if (!isNullOrUndefined(this.optionsPaneModule) && !isNullOrUndefined(this.viewer)) {\n this.optionsPaneModule.showHideOptionsPane(true);\n }\n }", "function hideWorkingMessage() {\n psc().hideLayer();\n}", "function hide_controls() {\r\n\r\n //Let the mouse movement lister know that the controls are now hidden.\r\n controls_hidden = true;\r\n\r\n //Hide the cursor on the body.\r\n $(document.body).css(\"cursor\", \"none\");\r\n\r\n //Fade out the control bar over 1500ms using opacity.\r\n $(\"#control_container\").animate({ opacity: 0 }, 1500);\r\n\r\n }", "function dhtml_hideLayer(name, displayNone) {\t\t\r\n var layer = dhtml_getLayerStyle(name);\r\n if (layer) {\r\n if (document.layers) {\r\n layer.visibility = \"hide\";\r\n } else {\r\n layer.visibility = \"hidden\";\r\n }\r\n if (displayNone) {\r\n layer.display = 'none';\r\n }\r\n }\r\n}", "function YATAShowHide(panel, child) {\n child.classList.add(\"shinyjs-show\");\n child.classList.remove(\"shinyjs-hide\"); \n \n p = document.getElementById(panel); \n childs = p.childNodes;\n\n for (var i = 0; i < childs.length; i++) {\n childs[i].classList.add(\"shinyjs-hide\");\n childs[i].classList.remove(\"shinyjs-show\"); \n }\n p.appendChild(child);\n}", "function hideWorkingPanel() {\n\t$('#workingPanel').removeClass();\n\t$('#workingPanel').addClass(\"hidden\");\n}", "function panelMetaDataClose(){\n\tpanelView = '';\n\tpanelShow({'height' : '10px'});\n\t$('panelFrame').src='index.php?n';\n}", "static toggleSettings() {\n document.getElementById('settingsContainer').hidden = !document.getElementById('settingsContainer').hidden;\n }", "function hideSettings() {\n $(this).parent(s.taskSettingsOverlay).slideUp(600);\n }", "function toggleConfShowButtons(){\n\tshowButtons = toggleConfBool('botones', showButtons);\n\tget('wcr_botones').style.display = showButtons ? '' : 'none';\n}", "function configurationForm_hideError()\n{\n\terrorPaneId = 'errorPane';\n\t\n\tif (document.getElementById) // DOM3 = IE5, NS6\n\t{\n\t\tdocument.getElementById(errorPaneId).style.display = 'none';\n\t}\n\telse\n\t{\n\t\tif (document.layers) // Netscape 4\n\t\t{\n\t\t\tdocument.errorPaneId.display = 'none';\n\t\t}\n\t\telse // IE4\n\t\t{\n\t\t\tdocument.all.errorPaneId.style.display = 'none';\n\t\t}\n\t}\n}", "function show_home_panel() {\n if (_via_current_image_loaded) {\n show_all_canvas();\n set_all_text_panel_display('none');\n } \n}", "function hidePopup () {\n editor.popups.hide('customPlugin.popup');\n }", "function hidePopup () {\n editor.popups.hide('customPlugin.popup');\n }", "function disableControls()\n {\n if( m_controlBar )\n if( This.widget.getDisplayNode().contains( m_controlBar ) )\n This.widget.getDisplayNode().removeChild( m_controlBar );\n }", "function xHide(e){return xVisibility(e,0);}", "function collapsePanel() {\n phone.mode = DisplayMode.Minimized;\n document.documentElement.style.setProperty(\"--widgetAreaWidth\", \"0px\");\n $(\".expanded\").hide();\n \n}", "function hideContainer(container) {\n jq(container).addClass('hidden');\n disableContainer(container);\n}", "function hideBoardTitleForm() {\n vm.isBoardTitleFormVisible = false;\n }", "function hideEnableEditor(hideOptions = false) {\n // hinde the block canvas\n var canvas = document.getElementsByClassName(\"gjs-pn-views-container\");\n if (canvas[0].style.display === \"none\") {\n canvas[0].style.display = \"block\";\n } else {\n canvas[0].style.display = \"none\";\n }\n\n // Hide the bar canvas\n var canvas = document.getElementsByClassName(\"gjs-pn-commands\");\n if (canvas[0].style.display === \"none\") {\n canvas[0].style.display = \"block\";\n } else {\n canvas[0].style.display = \"none\";\n }\n\n // Hide the bar canvas\n var canvas = document.getElementsByClassName(\"gjs-pn-devices-c\");\n if (canvas[0].style.display === \"none\") {\n canvas[0].style.display = \"block\";\n } else {\n canvas[0].style.display = \"none\";\n }\n\n // Hide the bar canvas\n var canvas = document.getElementsByClassName(\"gjs-pn-views\");\n if (canvas[0].style.display === \"none\") {\n canvas[0].style.display = \"block\";\n } else {\n canvas[0].style.display = \"none\";\n }\n\n // if true will hide the hole editor usable for the dragn and drop\n if (hideOptions) {\n // hide the bar canvas\n var canvas = document.getElementsByClassName(\"gjs-pn-options\");\n if (canvas[0].style.display === \"none\") {\n canvas[0].style.display = \"block\";\n } else {\n canvas[0].style.display = \"none\";\n }\n }\n\n // Rearange the editor top bar\n var canvas = document.getElementsByClassName(\"gjs-pn-options\");\n if (canvas[0].classList[4] === \"editor-bar-hide\") {\n canvas[0].classList.remove(\"editor-bar-hide\");\n } else {\n canvas[0].classList.add(\"editor-bar-hide\");\n }\n}", "function hideAllModals(event) {\n hideOverlay();\n hideMap();\n hideLogin();\n}", "hide() {\n this.visible = false;\n if (this.config.pauseGame) {\n ns.game.paused = false;\n }\n }", "function hidePopup(event) {\n props.setShowClients(false);\n }", "function hideControls() {\n\t\tif (controlsHidden) return;\n\t\tcontrolsHidden = true;\n\t\taddMouseMoveListener();\n\t\tprevDiv.animate({left: '-150'}, 350, function() {\n\t\t\tprevDiv.hide().css(\"left\", 0);\n\t\t});\n\t\tnextDiv.animate({right: '-150'}, 350, function() {\n\t\t\tnextDiv.hide().css(\"right\", 0);\n\t\t});\n\t\tcloseButton.animate({top: '-50'}, 350, function() {\n\t\t\tcloseButton.hide().css(\"top\", 0);\n\t\t});\n\t\tfullScreenButton.animate({top: '-50'}, 350, function() {\n\t\t\tfullScreenButton.hide().css(\"top\", 0);\n\t\t});\n\t\tsettingsButton.animate({top: '-50'}, 350, function() {\n\t\t\tsettingsButton.hide().css(\"top\", 0);\n\t\t});\n\t\tnewtab.animate({top: '-50'}, 350, function() {\n\t\t\tnewtab.hide().css(\"top\", 0);\n\t\t});\n\t}", "function hideTools() {\n\t\t\thideAllBtn();\n\t\t\t$('#colorelement').css('display','none');\n\t\t\t$('#fntEdit').css('display','none');\n\t\t}", "hideTools() {\n\t\tlet tools = this.querySelectorAll('.panel-nav > span.panel-nav-item');\n\t\tif (tools.length) {\n\t\t\tArray.prototype.forEach.call(tools, (el) => el.classList.remove('is-selected'));\n\t\t}\n\t\tlet tool = this.querySelector('.panel-tool');\n\t\tlet toolRect = tool.getBoundingClientRect();\n\t\tif (!tool.style.display && toolRect.width) {\n\t\t\tlet rect = this.getBoundingClientRect();\n\t\t\tthis.width = (rect.width - toolRect.width) / rect.width * this.width;\n\t\t\tthis.style.width = this.width * 100 + 'vh';\n\t\t}\n\t\ttool.style.display = 'none';\n\t}", "function hideWorkflowEditButton()\n {\n $.PercDataList.enableButtons(container);\n $(\"#perc-wf-update-editor\").hide();\n $(\"#perc-wf-name-wrapper\").hide();\n dirtyController.setDirty(false);\n }", "function showOptions() {\n document.getElementById(\"controls\").hidden = !document.getElementById(\"controls\").hidden;\n}" ]
[ "0.725464", "0.7065207", "0.6750465", "0.67105985", "0.6627959", "0.6622119", "0.6595186", "0.6553107", "0.65338504", "0.653136", "0.6496401", "0.6493388", "0.6465505", "0.64373815", "0.64037937", "0.63856566", "0.6369869", "0.63603336", "0.63507223", "0.63385075", "0.6326461", "0.6318766", "0.631263", "0.6310111", "0.6299457", "0.62987024", "0.62811685", "0.62799984", "0.62678564", "0.62678564", "0.6266788", "0.6245792", "0.62420845", "0.6207498", "0.6195861", "0.6191349", "0.61845815", "0.61820954", "0.6181314", "0.61518997", "0.61349404", "0.6127856", "0.61085916", "0.610495", "0.6081441", "0.6078447", "0.6070243", "0.6070243", "0.60447025", "0.6028886", "0.6028205", "0.60258657", "0.60173553", "0.6014527", "0.59945136", "0.5991895", "0.5989399", "0.5984582", "0.5983806", "0.5980491", "0.597967", "0.59706664", "0.59704787", "0.5970012", "0.5969191", "0.5963362", "0.5954813", "0.5951294", "0.59492135", "0.5948515", "0.5948459", "0.59482837", "0.59478384", "0.59445", "0.5940319", "0.5938188", "0.59360486", "0.5934527", "0.5924383", "0.591866", "0.59177214", "0.59164417", "0.59160054", "0.59137917", "0.59125376", "0.59125376", "0.5912323", "0.5904912", "0.59042895", "0.5893993", "0.58935905", "0.5892637", "0.5890024", "0.588714", "0.58800083", "0.5877962", "0.58774686", "0.58770674", "0.58760244", "0.5874034" ]
0.64652795
13