Skip to content

Commit

Permalink
Increased max num of measures from 10 to 50
Browse files Browse the repository at this point in the history
  • Loading branch information
ginestra committed Apr 7, 2024
1 parent 7e95cff commit 1e602f4
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 11 deletions.
11 changes: 4 additions & 7 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -208,8 +208,7 @@

<span id="hiddenDescription">
GrooveScribe allows drummers to easily create grooves, listen, share, print sheet music, and more.
Use the GrooveScribe to create new grooves, figure out the groove to your favorite song,
or write down the groove to your latest tune.
Use the GrooveScribe to create new grooves, figure out the groove to your favorite song, or write down the groove to your latest tune.
</span>

<!-- GrooveDB output area -->
Expand All @@ -231,11 +230,9 @@
<A href="" id="showHideABC" onclick="event.preventDefault(); myGrooveWriter.ShowHideABCResults();">Show/Hide ABC Notation</a>

<div id="ABC_Results">
ABC Notation is used for rendering the music. You can see what is being generated below.
You can even edit it. <br>
NOTE: whenever the page is modified, the ABC Notation below will be overwritten automatically. <br>
For more information about ABC Notation go here: <a href="http://abcnotation.com/">http://abcnotation.com/</a>
<p></p>
<p>ABC Notation is used for rendering the music. You can see what is being generated below. You can even edit it.</p>
<p>NOTE: whenever the page is modified, the ABC Notation below will be overwritten automatically.</p>
<p>For more information about ABC Notation go here: <a href="http://abcnotation.com/">http://abcnotation.com/</a></p>
<textarea id="ABCsource" rows="10" cols="72" ></textarea>
<br>
<button type="button" onclick="myGrooveWriter.displayNewSVG();">Re-render the music</button>
Expand Down
6 changes: 3 additions & 3 deletions js/groove_utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ if (document.currentScript)
var global_midiInitialized = false;

// global constants
var constant_MAX_MEASURES = 10;
var constant_MAX_MEASURES = 50;
var constant_DEFAULT_TEMPO = 80;
var constant_ABC_STICK_R = '"R"x';
var constant_ABC_STICK_L = '"L"x';
Expand Down Expand Up @@ -1041,7 +1041,7 @@ function GrooveUtils() {
var fullURL = window.location.protocol + "//" + window.location.host + window.location.pathname;

if(!url_destination) {
// then assume it is the groove writer display. Do nothing
// then assume it is the groove writer display. Do nothing
} else if(url_destination == "display") {
// asking for the "groove_display" page
if(fullURL.includes('index.html'))
Expand All @@ -1052,7 +1052,7 @@ function GrooveUtils() {
fullURL += 'GrooveEmbed.html';
} else if(url_destination == "fullGrooveScribe") {
// asking for the full GrooveScribe link
fullURL = 'https://www.mikeslessons.com/gscribe';
fullURL = 'https://ginestra.github.io/GrooveScribe/';
}

fullURL += '?';
Expand Down
2 changes: 1 addition & 1 deletion js/groove_writer.js
Original file line number Diff line number Diff line change
Expand Up @@ -3350,7 +3350,7 @@ function GrooveWriter() {

document.addEventListener("keydown", function (e) {

// only accept the event if it not going to an INPUT field (allow for range types)
// only accept the event if it not going to an INPUT field (allow for range types)
if (e.target.type == "range" || (e.target.tagName.toUpperCase() != "INPUT" && e.target.tagName.toUpperCase() != "TEXTAREA")) {
switch (e.which) {
case 90: // ctrl-z
Expand Down

0 comments on commit 1e602f4

Please sign in to comment.