Skip to content

Commit

Permalink
preparing release 0.4.0, add fullscreen options to the embed
Browse files Browse the repository at this point in the history
  • Loading branch information
pofider committed Apr 12, 2015
1 parent 41bac66 commit 0023eff
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions extension/embedding/public/js/embed.js
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,7 @@ var jsreport = (function (global, jQuery, undefined) {
}

options = options || {};
options.fullScreen = options.fullScreen === true;

template = $.extend(true, {}, template);

Expand All @@ -210,10 +211,11 @@ var jsreport = (function (global, jQuery, undefined) {

$(".jsreport-backdrop").show();

this.jsreportIFrame.css("width", ($(window).width() - 200) + "px");
this.jsreportIFrame.css("height", ($(window).height() - 200) + "px");
this.jsreportIFrame.css("left", "100px");
this.jsreportIFrame.css("top", "100px");

if (options.fullScreen)
_fullScreen.bind(this)();
else
_smallScreen.bind(this)();

this.template = template;

Expand All @@ -236,6 +238,7 @@ var jsreport = (function (global, jQuery, undefined) {
}

function _fullScreen() {
console.log("full");
this.jsreportIFrame.css("left", "0px");
this.jsreportIFrame.css("top", "0px");
this.jsreportIFrame.css("right", "0px");
Expand Down

0 comments on commit 0023eff

Please sign in to comment.