7 new changesets in galaxy-central: http://bitbucket.org/galaxy/galaxy-central/changeset/4730f4406ee7/ changeset: r5392:4730f4406ee7 user: james_taylor date: 2011-04-12 02:55:39 summary: trackster: pull out a class module for the ubiquitous extend method, this should be augmented with a more complete inheritence framework affected #: 1 file (338 bytes) --- a/static/scripts/trackster.js Fri Apr 08 16:43:45 2011 -0400 +++ b/static/scripts/trackster.js Mon Apr 11 20:55:39 2011 -0400 @@ -2,6 +2,10 @@ 2010-2011: James Taylor, Kanwei Li, Jeremy Goecks */ +var class_module = function(require, exports) { + +// Module is a placeholder for a more complete inheritence approach + /** Simple extend function for inheritence */ var extend = function() { var target = arguments[0]; @@ -14,12 +18,20 @@ return target; }; +exports.extend = extend; + +// end class_module encapsulation +}; + + // Encapsulate -- anything to be availabe outside this block is added to exports -var trackster_module = function(require, exports){ +var trackster_module = function(require, exports) { -var slotting = require('slotting'), +var extend = require('class').extend, + slotting = require('slotting'), painters = require('painters'); + // ---- Canvas management and extensions ---- /** @@ -2076,7 +2088,6 @@ this.hda_ldda = hda_ldda; this.dataset_id = dataset_id; this.original_dataset_id = dataset_id; - this.zo_slots = {}; this.show_labels_scale = 0.001; this.showing_details = false; this.summary_draw_height = 30; @@ -2361,6 +2372,8 @@ // Encapsulation var slotting_module = function(require, exports) { + +var extend = require('class').extend; // HACK: LABEL_SPACING is currently duplicated between here and painters var LABEL_SPACING = 2, @@ -2526,6 +2539,8 @@ // ---- Painters ---- var painters_module = function(require, exports){ + +var extend = require('class').extend; /** * Draw a dashed line on a canvas using filled rectangles. This function is based on: @@ -3420,6 +3435,7 @@ modules[key] = exports; }; // Run all modules + run_module( 'class', class_module ); run_module( 'slotting', slotting_module ); run_module( 'painters', painters_module ); run_module( 'trackster', trackster_module ); http://bitbucket.org/galaxy/galaxy-central/changeset/f6050dc1bb64/ changeset: r5393:f6050dc1bb64 user: james_taylor date: 2011-04-12 02:55:51 summary: Automated merge with https://bitbucket.org/galaxy/galaxy-central affected #: 1 file (338 bytes) --- a/static/scripts/trackster.js Mon Apr 11 14:17:35 2011 -0400 +++ b/static/scripts/trackster.js Mon Apr 11 20:55:51 2011 -0400 @@ -2,6 +2,10 @@ 2010-2011: James Taylor, Kanwei Li, Jeremy Goecks */ +var class_module = function(require, exports) { + +// Module is a placeholder for a more complete inheritence approach + /** Simple extend function for inheritence */ var extend = function() { var target = arguments[0]; @@ -14,12 +18,20 @@ return target; }; +exports.extend = extend; + +// end class_module encapsulation +}; + + // Encapsulate -- anything to be availabe outside this block is added to exports -var trackster_module = function(require, exports){ +var trackster_module = function(require, exports) { -var slotting = require('slotting'), +var extend = require('class').extend, + slotting = require('slotting'), painters = require('painters'); + // ---- Canvas management and extensions ---- /** @@ -2093,7 +2105,6 @@ this.hda_ldda = hda_ldda; this.dataset_id = dataset_id; this.original_dataset_id = dataset_id; - this.zo_slots = {}; this.show_labels_scale = 0.001; this.showing_details = false; this.summary_draw_height = 30; @@ -2379,6 +2390,8 @@ // Encapsulation var slotting_module = function(require, exports) { + +var extend = require('class').extend; // HACK: LABEL_SPACING is currently duplicated between here and painters var LABEL_SPACING = 2, @@ -2544,6 +2557,8 @@ // ---- Painters ---- var painters_module = function(require, exports){ + +var extend = require('class').extend; /** * Draw a dashed line on a canvas using filled rectangles. This function is based on: @@ -3438,6 +3453,7 @@ modules[key] = exports; }; // Run all modules + run_module( 'class', class_module ); run_module( 'slotting', slotting_module ); run_module( 'painters', painters_module ); run_module( 'trackster', trackster_module ); http://bitbucket.org/galaxy/galaxy-central/changeset/ffbec3713bc0/ changeset: r5394:ffbec3713bc0 user: james_taylor date: 2011-04-14 20:07:22 summary: Automated merge with https://bitbucket.org/galaxy/galaxy-central affected #: 1 file (0 bytes) http://bitbucket.org/galaxy/galaxy-central/changeset/e8f720f2e0f8/ changeset: r5395:e8f720f2e0f8 user: james_taylor date: 2011-04-14 20:32:37 summary: merging affected #: 1 file (334 bytes) --- a/static/scripts/trackster.js Thu Apr 14 14:07:22 2011 -0400 +++ b/static/scripts/trackster.js Thu Apr 14 14:32:37 2011 -0400 @@ -2,6 +2,10 @@ 2010-2011: James Taylor, Kanwei Li, Jeremy Goecks */ +var class_module = function(require, exports) { + +// Module is a placeholder for a more complete inheritence approach + /** Simple extend function for inheritence */ var extend = function() { var target = arguments[0]; @@ -14,6 +18,12 @@ return target; }; +exports.extend = extend; + +// end class_module encapsulation +}; + + /** * Compute the type of overlap between two regions. They are assumed to be on the same chrom/contig. * The overlap is computed relative to the second region; hence, OVERLAP_START indicates that the first @@ -59,11 +69,13 @@ }; // Encapsulate -- anything to be availabe outside this block is added to exports -var trackster_module = function(require, exports){ +var trackster_module = function(require, exports) { -var slotting = require('slotting'), +var extend = require('class').extend, + slotting = require('slotting'), painters = require('painters'); + // ---- Canvas management and extensions ---- /** @@ -2183,7 +2195,6 @@ this.hda_ldda = hda_ldda; this.dataset_id = dataset_id; this.original_dataset_id = dataset_id; - this.zo_slots = {}; this.show_labels_scale = 0.001; this.showing_details = false; this.summary_draw_height = 30; @@ -2558,6 +2569,8 @@ // Encapsulation var slotting_module = function(require, exports) { + +var extend = require('class').extend; // HACK: LABEL_SPACING is currently duplicated between here and painters var LABEL_SPACING = 2, @@ -2724,6 +2737,8 @@ var painters_module = function(require, exports){ +var extend = require('class').extend; + /** * Draw a dashed line on a canvas using filled rectangles. This function is based on: * http://vetruvet.blogspot.com/2010/10/drawing-dashed-lines-on-html5-canvas.ht... @@ -3573,6 +3588,7 @@ modules[key] = exports; }; // Run all modules + run_module( 'class', class_module ); run_module( 'slotting', slotting_module ); run_module( 'painters', painters_module ); run_module( 'trackster', trackster_module ); http://bitbucket.org/galaxy/galaxy-central/changeset/45298d68ad5b/ changeset: r5396:45298d68ad5b user: james_taylor date: 2011-04-14 20:32:44 summary: Automated merge with https://bitbucket.org/galaxy/galaxy-central affected #: 1 file (334 bytes) --- a/static/scripts/trackster.js Thu Apr 14 14:29:32 2011 -0400 +++ b/static/scripts/trackster.js Thu Apr 14 14:32:44 2011 -0400 @@ -2,6 +2,10 @@ 2010-2011: James Taylor, Kanwei Li, Jeremy Goecks */ +var class_module = function(require, exports) { + +// Module is a placeholder for a more complete inheritence approach + /** Simple extend function for inheritence */ var extend = function() { var target = arguments[0]; @@ -14,6 +18,12 @@ return target; }; +exports.extend = extend; + +// end class_module encapsulation +}; + + /** * Compute the type of overlap between two regions. They are assumed to be on the same chrom/contig. * The overlap is computed relative to the second region; hence, OVERLAP_START indicates that the first @@ -59,11 +69,13 @@ }; // Encapsulate -- anything to be availabe outside this block is added to exports -var trackster_module = function(require, exports){ +var trackster_module = function(require, exports) { -var slotting = require('slotting'), +var extend = require('class').extend, + slotting = require('slotting'), painters = require('painters'); + // ---- Canvas management and extensions ---- /** @@ -2185,7 +2197,6 @@ this.hda_ldda = hda_ldda; this.dataset_id = dataset_id; this.original_dataset_id = dataset_id; - this.zo_slots = {}; this.show_labels_scale = 0.001; this.showing_details = false; this.summary_draw_height = 30; @@ -2557,6 +2568,8 @@ // Encapsulation var slotting_module = function(require, exports) { + +var extend = require('class').extend; // HACK: LABEL_SPACING is currently duplicated between here and painters var LABEL_SPACING = 2, @@ -2723,6 +2736,8 @@ var painters_module = function(require, exports){ +var extend = require('class').extend; + /** * Draw a dashed line on a canvas using filled rectangles. This function is based on: * http://vetruvet.blogspot.com/2010/10/drawing-dashed-lines-on-html5-canvas.ht... @@ -3572,6 +3587,7 @@ modules[key] = exports; }; // Run all modules + run_module( 'class', class_module ); run_module( 'slotting', slotting_module ); run_module( 'painters', painters_module ); run_module( 'trackster', trackster_module ); http://bitbucket.org/galaxy/galaxy-central/changeset/d4ede96517d0/ changeset: r5397:d4ede96517d0 user: james_taylor date: 2011-04-14 22:51:26 summary: trackster: fix problem with drawing bounderies of overflow bars for line tracks affected #: 1 file (5 bytes) --- a/static/scripts/trackster.js Thu Apr 14 14:32:44 2011 -0400 +++ b/static/scripts/trackster.js Thu Apr 14 16:51:26 2011 -0400 @@ -2941,19 +2941,19 @@ var overflow_min_start = -1, overflow_max_start = -1; ctx.fillStyle = this.prefs.overflow_color; + var last_x_scaled; for (var i = 0, len = data.length; i < len; i++) { y = data[i][1]; x_scaled = Math.round((data[i][0] - view_start) * w_scale); - x_minus_scaled = Math.round((data[i][0] - 1 - view_start) * w_scale); // If we are in a min/max run, check if it should be ended if ( overflow_max_start >= 0 && ( y === null || y < max_value ) ) { // Value does not exist or is in valid range, any overflow ends - ctx.fillRect( overflow_max_start, 0, x_minus_scaled - overflow_max_start + 1, 2 ); + ctx.fillRect( overflow_max_start, 0, last_x_scaled + delta_x_px - overflow_max_start, 2 ); overflow_max_start = -1; } else if ( overflow_min_start >= 0 && ( y === null || y > min_value ) ) { // Draw bottom overflow bar - ctx.fillRect( overflow_min_start, height - 2, x_minus_scaled - overflow_min_start + 1, 2 ); + ctx.fillRect( overflow_min_start, height - 2, last_x_scaled + delta_x_px - overflow_min_start, 2 ); overflow_min_start = -1; } @@ -2966,6 +2966,7 @@ // Bottom overflows and we are not already in a run overflow_min_start = x_scaled; } + last_x_scaled = x_scaled; } ctx.restore(); http://bitbucket.org/galaxy/galaxy-central/changeset/c792f5cc9efd/ changeset: r5398:c792f5cc9efd user: james_taylor date: 2011-04-14 22:51:40 summary: Automated merge with https://bitbucket.org/galaxy/galaxy-central affected #: 1 file (329 bytes) --- a/static/scripts/trackster.js Thu Apr 14 16:42:12 2011 -0400 +++ b/static/scripts/trackster.js Thu Apr 14 16:51:40 2011 -0400 @@ -2,6 +2,10 @@ 2010-2011: James Taylor, Kanwei Li, Jeremy Goecks */ +var class_module = function(require, exports) { + +// Module is a placeholder for a more complete inheritence approach + /** Simple extend function for inheritence */ var extend = function() { var target = arguments[0]; @@ -14,6 +18,12 @@ return target; }; +exports.extend = extend; + +// end class_module encapsulation +}; + + /** * Compute the type of overlap between two regions. They are assumed to be on the same chrom/contig. * The overlap is computed relative to the second region; hence, OVERLAP_START indicates that the first @@ -59,11 +69,13 @@ }; // Encapsulate -- anything to be availabe outside this block is added to exports -var trackster_module = function(require, exports){ +var trackster_module = function(require, exports) { -var slotting = require('slotting'), +var extend = require('class').extend, + slotting = require('slotting'), painters = require('painters'); + // ---- Canvas management and extensions ---- /** @@ -2194,7 +2206,6 @@ this.hda_ldda = hda_ldda; this.dataset_id = dataset_id; this.original_dataset_id = dataset_id; - this.zo_slots = {}; this.show_labels_scale = 0.001; this.showing_details = false; this.summary_draw_height = 30; @@ -2566,6 +2577,8 @@ // Encapsulation var slotting_module = function(require, exports) { + +var extend = require('class').extend; // HACK: LABEL_SPACING is currently duplicated between here and painters var LABEL_SPACING = 2, @@ -2732,6 +2745,8 @@ var painters_module = function(require, exports){ +var extend = require('class').extend; + /** * Draw a dashed line on a canvas using filled rectangles. This function is based on: * http://vetruvet.blogspot.com/2010/10/drawing-dashed-lines-on-html5-canvas.ht... @@ -2935,19 +2950,19 @@ var overflow_min_start = -1, overflow_max_start = -1; ctx.fillStyle = this.prefs.overflow_color; + var last_x_scaled; for (var i = 0, len = data.length; i < len; i++) { y = data[i][1]; x_scaled = Math.round((data[i][0] - view_start) * w_scale); - x_minus_scaled = Math.round((data[i][0] - 1 - view_start) * w_scale); // If we are in a min/max run, check if it should be ended if ( overflow_max_start >= 0 && ( y === null || y < max_value ) ) { // Value does not exist or is in valid range, any overflow ends - ctx.fillRect( overflow_max_start, 0, x_minus_scaled - overflow_max_start + 1, 2 ); + ctx.fillRect( overflow_max_start, 0, last_x_scaled + delta_x_px - overflow_max_start, 2 ); overflow_max_start = -1; } else if ( overflow_min_start >= 0 && ( y === null || y > min_value ) ) { // Draw bottom overflow bar - ctx.fillRect( overflow_min_start, height - 2, x_minus_scaled - overflow_min_start + 1, 2 ); + ctx.fillRect( overflow_min_start, height - 2, last_x_scaled + delta_x_px - overflow_min_start, 2 ); overflow_min_start = -1; } @@ -2960,6 +2975,7 @@ // Bottom overflows and we are not already in a run overflow_min_start = x_scaled; } + last_x_scaled = x_scaled; } ctx.restore(); @@ -3581,6 +3597,7 @@ modules[key] = exports; }; // Run all modules + run_module( 'class', class_module ); run_module( 'slotting', slotting_module ); run_module( 'painters', painters_module ); run_module( 'trackster', trackster_module ); Repository URL: https://bitbucket.org/galaxy/galaxy-central/ -- This is a commit notification from bitbucket.org. You are receiving this because you have the service enabled, addressing the recipient of this email.