forked from h2oai/h2o-2
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixes PP-71, PP-80, PP-82
- Loading branch information
Showing
95 changed files
with
3,407 additions
and
2,325 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
Steam.AlertDialog = (_, _title, _message, _go) -> | ||
|
||
confirm = -> _go 'confirm' | ||
cancel = -> _go 'cancel' | ||
|
||
title: _title | ||
message: _message | ||
confirm: confirm | ||
cancel: cancel | ||
template: 'alert-dialog' | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
Steam.DialogManager = (_) -> | ||
|
||
initialize = -> | ||
linkDialog _.alert, Steam.AlertDialog | ||
linkDialog _.fail, Steam.ErrorDialog | ||
linkDialog _.promptForFrame, Steam.SelectFrameDialog | ||
|
||
# --- Add additional dialogs here --- | ||
|
||
linkDialog = (edge, createDialog) -> | ||
link$ edge, (requestArgs..., go) -> | ||
throw new Error 'No continuation provided.' unless isFunction go | ||
requestArgs.unshift _ | ||
requestArgs.push (responseArgs...) -> | ||
_.unloadDialog dialog | ||
go.apply null, responseArgs | ||
_.loadDialog dialog = createDialog.apply null, requestArgs | ||
|
||
link$ _.positionDialog, (element) -> | ||
return unless element.nodeType is 1 | ||
$dialogContainer = $ element | ||
$dialog = $ $dialogContainer.children()[0] | ||
[ $dialogHeader, $dialogBody ] = map $dialog.children(), (child) -> $ child | ||
dialogWidth = parseInt $dialog.attr 'data-dialog-width' | ||
dialogHeight = parseInt $dialog.attr 'data-dialog-height' | ||
|
||
parentWidth = $dialog.parent().parent().width() | ||
|
||
unless dialogWidth > 0 | ||
dialogWidth = parentWidth * 0.75 | ||
|
||
# Set the dialog width so that the .height() measurement returns an accurate height. | ||
$dialog.width dialogWidth | ||
|
||
unless dialogHeight > 0 | ||
dialogHeight = $dialog.height() | ||
|
||
dialogLeft = -dialogWidth / 2 | ||
dialogTop = -dialogHeight / 2 | ||
dialogHeaderHeight = $dialogHeader.height() | ||
dialogBodyHeight = dialogHeight - dialogHeaderHeight | ||
|
||
$dialog.attr 'style', "position:absolute;width:#{dialogWidth}px;height:#{dialogHeight}px;left:#{dialogLeft}px;top:#{dialogTop}px" | ||
$dialogHeader.attr 'style', 'position:absolute;top:0;left:0;right:0' | ||
$dialogBody.attr 'style', "position:absolute;left:0;right:0;bottom:0;top:#{dialogHeaderHeight}px" | ||
|
||
initialize() | ||
|
||
return | ||
|
||
|
||
|
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
Steam.ErrorDialog = (_, _title, _message, error, _go) -> | ||
|
||
confirm = -> _go 'confirm' | ||
cancel = -> _go 'cancel' | ||
|
||
title: _title | ||
message: _message | ||
confirm: confirm | ||
cancel: cancel | ||
error: error | ||
template: 'error-dialog' | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,11 @@ | ||
Steam.ErrorMonitor = (_) -> | ||
window.onerror = (message, url, lineNumber) -> | ||
_.fatal message, | ||
url: url | ||
lineNumber: lineNumber | ||
|
||
|
||
|
||
|
||
if window | ||
window.onerror = (message, url, lineNumber) -> | ||
_.fatal message, | ||
url: url | ||
lineNumber: lineNumber | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.