diff --git a/package.nw/GridTracker.html b/package.nw/GridTracker.html index 96152ddb..b5dd213e 100644 --- a/package.nw/GridTracker.html +++ b/package.nw/GridTracker.html @@ -3,6 +3,7 @@ GridTracker ©2020 N0TTL + @@ -14,6 +15,7 @@ + @@ -173,8 +175,7 @@
Clear Live
-
Clear Log
+
Clear Log
@@ -262,12 +263,15 @@
-
Call Roster + Award Tracker
+
+
+
+
-
-
-
+
+
+
@@ -282,11 +286,12 @@
-
-
+
+
+
-
+
@@ -348,10 +353,10 @@
@@ -830,6 +748,46 @@
+
+
+
+ + + + + + + + + + +
Working Callsign(s)
Enable?
Callsign(s)
+
+
+ + + + + + + + + + + + +
Working Date
Enable?
+
No Date
+
+
+ +
+
+
+
+ +
+
@@ -844,7 +802,6 @@
-
@@ -870,28 +827,7 @@
-
-
- - - - - - - -
Split QSL Grids
-
-
- - - - - - - -
Grid Mouse-Over Tables
-
-
+

@@ -935,17 +871,8 @@

-
- - - - - - - -
Merge Award Overlay
-
-
+ +
@@ -977,7 +904,37 @@
Grayline Darkness
-
+ +
+ + + + + + + +
Split QSL Grids
+

+
+ + + + + + + +
Grid Mouse-Over Tables
+
+
+ + + + + + + +
Merge Award Overlay
+
@@ -997,18 +954,7 @@
-
-
- - - - - - - -
US Weather Radar
-
- +

@@ -1018,7 +964,40 @@
-

+ +
+ + + + + + + + + + +
PSK-Spot Color
PSK-Reporter Palette
+
+
+ + + + + + + +
PSK-Spots Over Grids
+
+
+ + + + + + + +
PSK-Spot Paths
+

@@ -1063,6 +1042,19 @@
+
@@ -1078,73 +1070,21 @@
- - - - -
-
- - - - - - - - - - -
Spot Color
PSK-Reporter Palette
-
- -
-
- - - - - - - -
PSK-Reporter Spot Paths
-
-
- +
- +
Spot Path WidthPSK-Spot Path Width 1.5
-
-
-
- - - - - - - -
Spots over Grids
-
-
+ + + +
@@ -1318,7 +1258,7 @@ - + @@ -1805,7 +1745,9 @@ ©2020 Stephen "Tag" Loomis / NØTTL

©2020 Henry "atouk" Forte / N2VFL
-
+

+

Contributors

+ NRØQ - "d3jake" KEØRIY - "Don" KB2YSI - K4KPW

diff --git a/package.nw/gt_update.html b/package.nw/gt_update.html index 6a99bd05..4ec7b1fd 100644 --- a/package.nw/gt_update.html +++ b/package.nw/gt_update.html @@ -1,100 +1,108 @@ - +
+
+ +This is the last release until we have documentation ready or there is a bug.

+All feature requests will be added to the backlog.

+We will prioritize them in our public #Round-Table room on our Discord server.

+Here is a link to our Discord server. Link

+ +We recommend downloading the Discord app instead of using the browser. +

-[v1.20.0821] August 21st, 2020
+GridTracker:
+  I have improved the UI/UX (User interface/User Experience) in this release
+  I have moved buttons around & items are labeled for clarity
+  Most items/buttons that you can interact with have a tooltip
+  Simply hover your mouse-pointer over an item/field/button & it will describe it
+
+Main Window:
+  Update:
+    "Call Roster + Award Tracker" Text button now a 
+      "Call Roster + Award" Icon button
+      
+    "Lookup" Icon button less creepy
+    
+  New:
+    "?" Icon button toggles the Hotkey List
+      In the next release it will open documentation
+      
+    "Timezone" Icon button toggles Timezone layer
+    
+    "Radar" Icon button toggles US Nexrad Weather layer
+
+Hotkey List:
+  Ordered by Key for clarity
+  Added Version to header
+  
+Map:  
+  Fixed:
+    "Timezone" layer very slow to react 
+  
+Settings:
+  Update:
+    Merged Spots Tab with Map Tab to make room for Logbook Tab
+      
+  Logbook:
+    New Tab!:
+      "Working Callsign(s)"
+        When enabled, filter your logbooks by callsigns
+          eg:  "N0TTL,N0OAW,KE0PEA" 
+    
+      "Working Date"
+        When enabled, filter your logbooks by anything on or after date
+    
+  Lookups:
+    Update:
+      Callsign Database now list instead of boxes
+        Making room for more callsign databases
+          NR0Q found the Canadian call-db and will be in a future release
+          
+      Downloads are now automatic and weekly when enabled
+        The US Database is only 10mb
+        
+    US Callsign Database:
+      Fixed:
+        Corrupt/Incomplete database due to program close while downloading
 
-GridTracker Main Window:
-	Update:
-		"Map View" renamed "Map View Filters"
-		"Callable Roster" renamed "Call Roster + Award Tracker"
-		Minimum width now 200 pixels (you can hide the map now)
-		
-	New:
-		"Prop" added to "Map View Filters"
-			Propagation Mode for filtering Logbook data *only* 
-				Live data view is unaffected
-			
-	Update:
-		Removed "FFMA" and "GMA" award layers and replaced with "US48" layer
-			To view your Fred Fish Memorial "FFMA" Award:
-				Select "US48" hotkey (8) then;
-					Set your Band filter to "6m"
-			
-			To view your AMSAT GridMaster "GMA" Award:
-				Select "US48" hotkey (8) then;
-					Set your Band & Mode filters to "Mixed"
-					Set your Prop filter to "Satellite"
-		
 Call Roster:
-	Update:
-		Callable Roster renamed to "Call Roster"
-		
-	Fixed:
-		Award Tracking:
-			"Wanted" box remains as it's needed
-			Fix bad filtering flags
-			
-		When enabling "Wanted" entities; right-click menu now tracks correctly 
-		
-		Issue with New/Unconfirmed callsigns not showing up at all
-		
-		Return of the "strikeout" on callsigns that have been confirmed
-			by popular demand
-			
-	Compact Mode:
-		Sorted by "Age" for now 
-			(Will add a right-click menu to select sort type later on)
-			
-		Added "DXCC" under "Callsign"
-		
-		Tooltip(mouse-over) added with decode details
-			(Will add Worked/Confirmed status by band/mode later on)
-			
-				
-PSK-Spots:
-	Fixed: 
-		Memory issue when 1500 spots in 24 hours
-			Thanks to mister "I get out" NR0Q for finding this one
-			
-Logging:
-	Local Files(s)
-		Details:
-			Filename now has a tooltip with the full file path
-		
-		
-		
-		
-		
-		
-		
-		
-		
+  Fixed:
+    Hide Controls/Show Controls getting out of sync when switching views
+
+
+
+
+
+Below is the backlog of features that have been prioritized for the next
+release *after* we get our first update to documentation in over 2 years!
+
+Output from the most recent Round-Table discussion on new features...
+
+Ordered by priority:
+
+DX Logbook, HRD Logbook , N3FJP ACLog, Log4OM..  QSL Import and  Synchronization
+
+Create Award Tracker Stats Tab
+
+Add Settings Window To Call Roster
+
+Add New Ignores in "new settings window" in Call Roster
+
+Add Callsign and DXCC right-click "Add Call/DXCC Watcher" + "Edit Watcher"
+
+Add Lighting alert volume .. and mute override and media selector
+
+Audio Alerts fix up
+
+
+
+
+
+
+
+
 
 
 Thank you for reading the entire update! 
-
-
-
-
-
-
-
-
-
-
-
-Mention "phone-sofa" in any forum I read and I'll send you a GridTracker token
-to the address associated with your callsign lookup
-
-Please don't mention this easter-egg to anyone. I want to see who reads the update
-
-To the 21 of you out of 650-ish, who downloaded and read the update in v1.20.0819: 
-	I salute you! And I'll be shipping out tokens when I get a chance! Thank you!
-
 
+ diff --git a/package.nw/img/help.svg b/package.nw/img/help.svg new file mode 100644 index 00000000..2ea091e6 --- /dev/null +++ b/package.nw/img/help.svg @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/package.nw/img/lookup-icon.png b/package.nw/img/lookup-icon.png new file mode 100644 index 00000000..66871065 Binary files /dev/null and b/package.nw/img/lookup-icon.png differ diff --git a/package.nw/img/lookup.svg b/package.nw/img/lookup.svg new file mode 100644 index 00000000..09e5f95c --- /dev/null +++ b/package.nw/img/lookup.svg @@ -0,0 +1,12 @@ + + + + + + + + + + + + \ No newline at end of file diff --git a/package.nw/img/plus.svg b/package.nw/img/plus.svg new file mode 100644 index 00000000..18ac154f --- /dev/null +++ b/package.nw/img/plus.svg @@ -0,0 +1,12 @@ + + + + + + diff --git a/package.nw/img/radar-button.svg b/package.nw/img/radar-button.svg new file mode 100644 index 00000000..5053f530 --- /dev/null +++ b/package.nw/img/radar-button.svg @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/package.nw/img/roster-button.svg b/package.nw/img/roster-button.svg new file mode 100644 index 00000000..5224c723 --- /dev/null +++ b/package.nw/img/roster-button.svg @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/package.nw/img/roster-icon.png b/package.nw/img/roster-icon.png new file mode 100644 index 00000000..f1ebbf63 Binary files /dev/null and b/package.nw/img/roster-icon.png differ diff --git a/package.nw/img/roster.svg b/package.nw/img/roster.svg new file mode 100644 index 00000000..608fc53e --- /dev/null +++ b/package.nw/img/roster.svg @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + diff --git a/package.nw/img/timezone-button.svg b/package.nw/img/timezone-button.svg new file mode 100644 index 00000000..cb684c7a --- /dev/null +++ b/package.nw/img/timezone-button.svg @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/package.nw/lib/adif.js b/package.nw/lib/adif.js index c01daed3..ccc63b47 100644 --- a/package.nw/lib/adif.js +++ b/package.nw/lib/adif.js @@ -95,6 +95,11 @@ function onAdiLoadComplete( adiBuffer, saveAdifFile, adifFileName, newFile) var finalVucc = []; var finalDXcall = findAdiField(activeAdifArray[x], "CALL").replace("_","/"); var finalDEcall = findAdiField(activeAdifArray[x], "STATION_CALLSIGN").replace("_","/"); + + if ( finalDEcall == "" ) + finalDEcall = myDEcall; + if ( g_appSettings.workingCallsignEnable && !(finalDEcall in g_appSettings.workingCallsigns) ) + continue; var finalRSTsent = findAdiField(activeAdifArray[x], "RST_SENT"); var finalRSTrecv = findAdiField(activeAdifArray[x], "RST_RCVD"); var finalBand = findAdiField(activeAdifArray[x], "BAND").toLowerCase(); @@ -147,9 +152,7 @@ function onAdiLoadComplete( adiBuffer, saveAdifFile, adifFileName, newFile) finalDxcc = Number(callsignToDxcc( finalDXcall )); // If my callsign isn't present, it must be for me anyway - if ( finalDEcall == "" ) - finalDEcall = myDEcall; - + var finalCqZone = findAdiField(activeAdifArray[x], "CQZ"); if ( finalCqZone.length == 1 ) finalCqZone = "0" + finalCqZone; @@ -177,6 +180,10 @@ function onAdiLoadComplete( adiBuffer, saveAdifFile, adifFileName, newFile) var dateTime = new Date(Date.UTC(dateVal.substr(0,4), parseInt(dateVal.substr(4,2))-1,dateVal.substr(6,2), timeVal.substr(0,2), timeVal.substr(2,2),timeVal.substr(4,2))); var finalTime = parseInt(dateTime.getTime()/1000); + + if ( g_appSettings.workingDateEnable && finalTime < g_appSettings.workingDate ) + continue; + finalGrid = finalGrid.substr(0,6); if ( !validateGridFromString(finalGrid) ) finalGrid = ""; diff --git a/package.nw/lib/callsigns.js b/package.nw/lib/callsigns.js index b9f91d32..0db27327 100644 --- a/package.nw/lib/callsigns.js +++ b/package.nw/lib/callsigns.js @@ -12,7 +12,7 @@ var g_ulsCallsignsCount = 0; var g_ulsWhenDate = 0; var g_ulsLoadTimer = null; -var g_ulsDownloadPending = false; + var g_oqrsCallsigns = Object(); var g_oqrsFile = ""; var g_oqrsWhenDate = 0; @@ -72,27 +72,18 @@ function saveCallsignSettings() function lotwLoadCallsigns() { - if ( g_callsignLookups.lotwWeeklyEnable == true ) + + var now = timeNowSec(); + if ( now - g_callsignLookups.lotwLastUpdate > (86400 * 7) ) + g_callsignLookups.lotwLastUpdate = 0; + else { - var now = timeNowSec(); - if ( now - g_callsignLookups.lotwLastUpdate > (86400 * 7) ) - g_callsignLookups.lotwLastUpdate = 0; - else - { - var lotwWhenTimer = (86400 * 7) - (now - g_callsignLookups.lotwLastUpdate); - g_lotwWhenDate = now + lotwWhenTimer; - g_lotwLoadTimer = setTimeout(lotwDownload,(lotwWhenTimer)*1000); - } - } - else - { - if ( g_lotwLoadTimer != null ) - { - clearTimeout(g_lotwLoadTimer); - g_lotwLoadTimer = null; - g_lotwWhenTimer = 0; - } + var lotwWhenTimer = (86400 * 7) - (now - g_callsignLookups.lotwLastUpdate); + g_lotwWhenDate = now + lotwWhenTimer; + g_lotwLoadTimer = setTimeout(lotwDownload,(lotwWhenTimer)*1000); } + + if (!fs.existsSync(g_lotwFile)) { @@ -116,50 +107,32 @@ function lotwLoadCallsigns() function lotwSettingsDisplay() { lotwUseEnable.checked = g_callsignLookups.lotwUseEnable; - lotwWeeklyEnable.checked = g_callsignLookups.lotwWeeklyEnable; if ( g_callsignLookups.lotwLastUpdate == 0 ) { - lotwUpdatedTd.innerHTML = "Never"; - lotwWhenTd.innerHTML = "Never"; + lotwUpdatedTd.innerHTML = "Never"; + } else { - lotwUpdatedTd.innerHTML = ""+userTimeString(g_callsignLookups.lotwLastUpdate * 1000)+""; - lotwWhenTd.innerHTML = ""+userTimeString(g_lotwWhenDate * 1000) + ""; + lotwUpdatedTd.innerHTML = userTimeString(g_callsignLookups.lotwLastUpdate * 1000); + } - - if ( g_callsignLookups.lotwUseEnable ) + if ( !g_callsignLookups.lotwUseEnable ) { - lotwWeeklyTd.style.display = "table-cell"; - lotwNowTd.style.display = "table-cell"; - lotwCountTd.style.display = "table-cell"; - if ( lotwWeeklyEnable.checked == true ) - lotwWhenTr.style.display = "table-row"; - else - lotwWhenTr.style.display = "none"; - lotwLastTr.style.display = "table-row"; - } - else - { - lotwWeeklyTd.style.display = "none"; - lotwNowTd.style.display = "none"; - lotwCountTd.style.display = "none"; - lotwWhenTr.style.display = "none"; - lotwLastTr.style.display = "none"; + if ( g_lotwLoadTimer != null ) clearTimeout(g_lotwLoadTimer); g_lotwLoadTimer = null; g_lotwCallsigns = Object(); } - lotwCountTd.innerHTML = Object.keys(g_lotwCallsigns).length + " callsigns found"; + lotwCountTd.innerHTML = Object.keys(g_lotwCallsigns).length; } function lotwValuesChanged() { g_callsignLookups.lotwUseEnable = lotwUseEnable.checked; - g_callsignLookups.lotwWeeklyEnable = lotwWeeklyEnable.checked; saveCallsignSettings(); if ( g_callsignLookups.lotwUseEnable == true ) { @@ -185,7 +158,8 @@ function processLotwCallsigns(result, flag) { //var result = String(buffer); var lines = Array(); - lines = result.split("\n"); + lines = result.split("\n"); + delete result; var lotwCallsigns = Object(); for ( x in lines ) { @@ -196,18 +170,17 @@ function processLotwCallsigns(result, flag) lotwCallsigns[breakout[0]] = parseInt(dateTime.getTime() / 1000)/86400; } } + delete lines; g_callsignLookups.lotwLastUpdate = timeNowSec(); - if ( g_callsignLookups.lotwWeeklyEnable == true ) - { - var now = timeNowSec(); - if ( g_lotwLoadTimer != null ) - clearTimeout(g_lotwLoadTimer); - - var lotwWhenTimer = (86400 * 7) - (now - g_callsignLookups.lotwLastUpdate); - g_lotwWhenDate = now + lotwWhenTimer; - g_lotwLoadTimer = setTimeout(lotwDownload,(lotwWhenTimer)*1000); - } + var now = timeNowSec(); + if ( g_lotwLoadTimer != null ) + clearTimeout(g_lotwLoadTimer); + + var lotwWhenTimer = (86400 * 7) - (now - g_callsignLookups.lotwLastUpdate); + g_lotwWhenDate = now + lotwWhenTimer; + g_lotwLoadTimer = setTimeout(lotwDownload,(lotwWhenTimer)*1000); + if ( Object.keys(lotwCallsigns).length > 100 ) { g_lotwCallsigns = lotwCallsigns; @@ -220,26 +193,15 @@ function processLotwCallsigns(result, flag) function oqrsLoadCallsigns() { - if ( g_callsignLookups.oqrsWeeklyEnable == true ) + + var now = timeNowSec(); + if ( now - g_callsignLookups.oqrsLastUpdate > (86400 * 7) ) + g_callsignLookups.oqrsLastUpdate = 0; + else { - var now = timeNowSec(); - if ( now - g_callsignLookups.oqrsLastUpdate > (86400 * 7) ) - g_callsignLookups.oqrsLastUpdate = 0; - else - { - var oqrsWhenTimer = (86400 * 7) - (now - g_callsignLookups.oqrsLastUpdate); - g_oqrsWhenDate = now + oqrsWhenTimer; - g_oqrsLoadTimer = setTimeout(oqrsDownload,(oqrsWhenTimer)*1000); - } - } - else - { - if ( g_oqrsLoadTimer != null ) - { - clearTimeout(g_oqrsLoadTimer); - g_oqrsLoadTimer = null; - g_oqrsWhenTimer = 0; - } + var oqrsWhenTimer = (86400 * 7) - (now - g_callsignLookups.oqrsLastUpdate); + g_oqrsWhenDate = now + oqrsWhenTimer; + g_oqrsLoadTimer = setTimeout(oqrsDownload,(oqrsWhenTimer)*1000); } if (!fs.existsSync(g_oqrsFile)) @@ -260,50 +222,33 @@ function oqrsLoadCallsigns() function oqrsSettingsDisplay() { oqrsUseEnable.checked = g_callsignLookups.oqrsUseEnable; - oqrsWeeklyEnable.checked = g_callsignLookups.oqrsWeeklyEnable; + if ( g_callsignLookups.oqrsLastUpdate == 0 ) { - oqrsUpdatedTd.innerHTML = "Never"; - oqrsWhenTd.innerHTML = "Never"; + oqrsUpdatedTd.innerHTML = "Never"; + } else { - oqrsUpdatedTd.innerHTML = ""+userTimeString(g_callsignLookups.oqrsLastUpdate * 1000)+""; - oqrsWhenTd.innerHTML = ""+userTimeString(g_oqrsWhenDate * 1000) + ""; + oqrsUpdatedTd.innerHTML = userTimeString(g_callsignLookups.oqrsLastUpdate * 1000); + } - if ( g_callsignLookups.oqrsUseEnable ) + if ( !g_callsignLookups.oqrsUseEnable ) { - oqrsWeeklyTd.style.display = "table-cell"; - oqrsNowTd.style.display = "table-cell"; - oqrsCountTd.style.display = "table-cell"; - if ( oqrsWeeklyEnable.checked == true ) - oqrsWhenTr.style.display = "table-row"; - else - oqrsWhenTr.style.display = "none"; - oqrsLastTr.style.display = "table-row"; - } - else - { - oqrsWeeklyTd.style.display = "none"; - oqrsNowTd.style.display = "none"; - oqrsCountTd.style.display = "none"; - oqrsWhenTr.style.display = "none"; - oqrsLastTr.style.display = "none"; if ( g_oqrsLoadTimer != null ) clearTimeout(g_oqrsLoadTimer); g_oqrsLoadTimer = null; g_oqrsCallsigns = Object(); } - oqrsCountTd.innerHTML = Object.keys(g_oqrsCallsigns).length + " callsigns found"; + oqrsCountTd.innerHTML = Object.keys(g_oqrsCallsigns).length; } function oqrsValuesChanged() { g_callsignLookups.oqrsUseEnable = oqrsUseEnable.checked; - g_callsignLookups.oqrsWeeklyEnable = oqrsWeeklyEnable.checked; saveCallsignSettings(); if ( g_callsignLookups.oqrsUseEnable == true ) { @@ -328,16 +273,15 @@ function processoqrsCallsigns(buffer, flag) g_oqrsCallsigns = JSON.parse(buffer); g_callsignLookups.oqrsLastUpdate = timeNowSec(); - if ( g_callsignLookups.oqrsWeeklyEnable == true ) - { - var now = timeNowSec(); - if ( g_oqrsLoadTimer != null ) - clearTimeout(g_oqrsLoadTimer); - - var oqrsWhenTimer = (86400 * 7) - (now - g_callsignLookups.oqrsLastUpdate); - g_oqrsWhenDate = now + oqrsWhenTimer; - g_oqrsLoadTimer = setTimeout(oqrsDownload,(oqrsWhenTimer)*1000); - } + + var now = timeNowSec(); + if ( g_oqrsLoadTimer != null ) + clearTimeout(g_oqrsLoadTimer); + + var oqrsWhenTimer = (86400 * 7) - (now - g_callsignLookups.oqrsLastUpdate); + g_oqrsWhenDate = now + oqrsWhenTimer; + g_oqrsLoadTimer = setTimeout(oqrsDownload,(oqrsWhenTimer)*1000); + fs.writeFileSync(g_oqrsFile, JSON.stringify(g_oqrsCallsigns)); oqrsSettingsDisplay(); @@ -345,27 +289,17 @@ function processoqrsCallsigns(buffer, flag) function eqslLoadCallsigns() { - if ( g_callsignLookups.eqslWeeklyEnable == true ) + + var now = timeNowSec(); + if ( now - g_callsignLookups.eqslLastUpdate > (86400 * 7) ) + g_callsignLookups.eqslLastUpdate = 0; + else { - var now = timeNowSec(); - if ( now - g_callsignLookups.eqslLastUpdate > (86400 * 7) ) - g_callsignLookups.eqslLastUpdate = 0; - else - { - var eqslWhenTimer = (86400 * 7) - (now - g_callsignLookups.eqslLastUpdate); - g_eqslWhenDate = now + eqslWhenTimer; - g_eqslLoadTimer = setTimeout(eqslDownload,(eqslWhenTimer)*1000); - } - } - else - { - if ( g_eqslLoadTimer != null ) - { - clearTimeout(g_eqslLoadTimer); - g_eqslLoadTimer = null; - g_eqslWhenTimer = 0; - } + var eqslWhenTimer = (86400 * 7) - (now - g_callsignLookups.eqslLastUpdate); + g_eqslWhenDate = now + eqslWhenTimer; + g_eqslLoadTimer = setTimeout(eqslDownload,(eqslWhenTimer)*1000); } + if (!fs.existsSync(g_eqslFile)) { @@ -385,50 +319,32 @@ function eqslLoadCallsigns() function eqslSettingsDisplay() { eqslUseEnable.checked = g_callsignLookups.eqslUseEnable; - eqslWeeklyEnable.checked = g_callsignLookups.eqslWeeklyEnable; if ( g_callsignLookups.eqslLastUpdate == 0 ) { - eqslUpdatedTd.innerHTML = "Never"; - eqslWhenTd.innerHTML = "Never"; + eqslUpdatedTd.innerHTML = "Never"; + } else { - eqslUpdatedTd.innerHTML = ""+userTimeString(g_callsignLookups.eqslLastUpdate * 1000)+""; - eqslWhenTd.innerHTML = ""+userTimeString(g_eqslWhenDate * 1000) + ""; + eqslUpdatedTd.innerHTML = userTimeString(g_callsignLookups.eqslLastUpdate * 1000); + } - if ( g_callsignLookups.eqslUseEnable ) + if ( !g_callsignLookups.eqslUseEnable ) { - eqslWeeklyTd.style.display = "table-cell"; - eqslNowTd.style.display = "table-cell"; - eqslCountTd.style.display = "table-cell"; - if ( eqslWeeklyEnable.checked == true ) - eqslWhenTr.style.display = "table-row"; - else - eqslWhenTr.style.display = "none"; - eqslLastTr.style.display = "table-row"; - } - else - { - eqslWeeklyTd.style.display = "none"; - eqslNowTd.style.display = "none"; - eqslCountTd.style.display = "none"; - eqslWhenTr.style.display = "none"; - eqslLastTr.style.display = "none"; if ( g_eqslLoadTimer != null ) clearTimeout(g_eqslLoadTimer); g_eqslLoadTimer = null; g_eqslCallsigns = Object(); } - eqslCountTd.innerHTML = Object.keys(g_eqslCallsigns).length + " callsigns found"; + eqslCountTd.innerHTML = Object.keys(g_eqslCallsigns).length; } function eqslValuesChanged() { g_callsignLookups.eqslUseEnable = eqslUseEnable.checked; - g_callsignLookups.eqslWeeklyEnable = eqslWeeklyEnable.checked; saveCallsignSettings(); if ( g_callsignLookups.eqslUseEnable == true ) { @@ -456,21 +372,21 @@ function processeqslCallsigns(buffer, flag) g_eqslCallsigns = Object(); for ( x in lines ) { - g_eqslCallsigns[lines[x].trim()] = 1; + g_eqslCallsigns[lines[x].trim()] = true; } g_callsignLookups.eqslLastUpdate = timeNowSec(); - if ( g_callsignLookups.eqslWeeklyEnable == true ) - { - var now = timeNowSec(); - if ( g_eqslLoadTimer != null ) - clearTimeout(g_eqslLoadTimer); - - var eqslWhenTimer = (86400 * 7) - (now - g_callsignLookups.eqslLastUpdate); - g_eqslWhenDate = now + eqslWhenTimer; - g_eqslLoadTimer = setTimeout(eqslDownload,(eqslWhenTimer)*1000); - } + + var now = timeNowSec(); + if ( g_eqslLoadTimer != null ) + clearTimeout(g_eqslLoadTimer); + + var eqslWhenTimer = (86400 * 7) - (now - g_callsignLookups.eqslLastUpdate); + g_eqslWhenDate = now + eqslWhenTimer; + g_eqslLoadTimer = setTimeout(eqslDownload,(eqslWhenTimer)*1000); + + if ( Object.keys(g_eqslCallsigns).length > 10000 ) + fs.writeFileSync(g_eqslFile, JSON.stringify(g_eqslCallsigns)); - fs.writeFileSync(g_eqslFile, JSON.stringify(g_eqslCallsigns)); eqslSettingsDisplay(); } @@ -484,32 +400,61 @@ function ulsLoadCallsigns() } - if ( g_callsignLookups.ulsWeeklyEnable == true ) - { - var now = timeNowSec(); - if ( now - g_callsignLookups.ulsLastUpdate > (86400 * 7) ) - g_callsignLookups.ulsLastUpdate = 0; - else - { - var ulsWhenTimer = (86400 * 7) - (now - g_callsignLookups.ulsLastUpdate); - g_ulsWhenDate = now + ulsWhenTimer; - g_ulsLoadTimer = setTimeout(ulsDownload,(ulsWhenTimer)*1000); - } - } - - - if ( g_callsignLookups.ulsLastUpdate == 0 ) - { + var now = timeNowSec(); + if ( now - g_callsignLookups.ulsLastUpdate > (86400 * 7) ) ulsDownload(); - } - else + else { - updateCallsignCount(true); + var ulsWhenTimer = (86400 * 7) - (now - g_callsignLookups.ulsLastUpdate); + g_ulsWhenDate = now + ulsWhenTimer; + g_ulsLoadTimer = setTimeout(ulsDownload,(ulsWhenTimer)*1000); + updateCallsignCount(); } + } -function updateCallsignCount( shouldDownload = false ) +function updateQSO() +{ + if ( g_ulsCallsignsCount > 0 ) + { + for ( hash in g_QSOhash ) + { + var details = g_QSOhash[hash]; + var lookupCall = false; + + + if ( (details.cnty == null || details.state == null) && isKnownCallsignDXCC(details.dxcc)) + { + // Do County Lookup + lookupCall = true; + } + else if (details.cnty != null && isKnownCallsignUSplus(details.dxcc)) + { + if (!(details.cnty in g_cntyToCounty)) + { + if (details.cnty.indexOf(",") == -1) + { + if (!(details.state + "," + details.cnty in g_cntyToCounty)) + lookupCall = true; + } + else + lookupCall = true; + + } + } + if (lookupCall) + { + if (g_callsignLookups.ulsUseEnable) + { + lookupUsCallsign(details); + } + } + } + } +} + +function updateCallsignCount() { g_ulsDatabase.transaction(function (tx) { tx.executeSql('SELECT count(*) as cnt FROM calls', [], function (tx, results) @@ -517,51 +462,11 @@ function updateCallsignCount( shouldDownload = false ) var len = results.rows.length, i; if ( len == 1 ) { - g_ulsCallsignsCount = results.rows[0]["cnt"]; - ulsCountTd.innerHTML = g_ulsCallsignsCount + " callsigns found"; - if ( g_ulsCallsignsCount > 0 ) - { - for ( hash in g_QSOhash ) - { - var details = g_QSOhash[hash]; - var lookupCall = false; - - if ( (details.cnty == null || details.state == null) && (details.dxcc == 291 || details.dxcc == 110 || details.dxcc == 6 || details.dxcc == 202)) - { - // Do County Lookup - lookupCall = true; - } - else if (details.cnty != null && (details.dxcc == 291 || details.dxcc == 110 || details.dxcc == 6 || details.dxcc == 202)) - { - if (!(details.cnty in g_cntyToCounty)) - { - if (details.cnty.indexOf(",") == -1) - { - if (!(details.state + "," + details.cnty in g_cntyToCounty)) - lookupCall = true; - } - else - lookupCall = true; - } - } - if (lookupCall) - { - if (g_callsignLookups.ulsUseEnable) - { - lookupUsCallsign(details); - } - } - } - } - else - { - ulsDownload(); - } - } - else - { - ulsDownload(); + g_ulsCallsignsCount = results.rows[0]["cnt"]; + ulsCountTd.innerHTML = g_ulsCallsignsCount; + + updateQSO(); } }, null); @@ -572,75 +477,52 @@ function updateCallsignCount( shouldDownload = false ) function ulsSettingsDisplay() { ulsUseEnable.checked = g_callsignLookups.ulsUseEnable; - ulsWeeklyEnable.checked = g_callsignLookups.ulsWeeklyEnable; - + if ( g_callsignLookups.ulsLastUpdate == 0 ) { - ulsUpdatedTd.innerHTML = "Never"; - ulsWhenTd.innerHTML = "Never"; + ulsUpdatedTd.innerHTML = "Never"; } else { - ulsUpdatedTd.innerHTML = ""+userTimeString(g_callsignLookups.ulsLastUpdate * 1000)+""; - ulsWhenTd.innerHTML = ""+userTimeString(g_ulsWhenDate * 1000) + ""; + ulsUpdatedTd.innerHTML = userTimeString(g_callsignLookups.ulsLastUpdate * 1000); } - if ( g_callsignLookups.ulsUseEnable ) + if ( !g_callsignLookups.ulsUseEnable ) { - ulsWeeklyTd.style.display = "table-cell"; - ulsNowTd.style.display = "table-cell"; - ulsCountTd.style.display = "table-cell"; - if ( ulsWeeklyEnable.checked == true ) - ulsWhenTr.style.display = "table-row"; - else - ulsWhenTr.style.display = "none"; - ulsLastTr.style.display = "table-row"; - } - else - { - ulsWeeklyTd.style.display = "none"; - ulsNowTd.style.display = "none"; - ulsCountTd.style.display = "none"; - ulsWhenTr.style.display = "none"; - ulsLastTr.style.display = "none"; if ( g_ulsLoadTimer != null ) clearTimeout(g_ulsLoadTimer); g_ulsLoadTimer = null; g_ulsCallsignsCount = 0; + ulsCountTd.innerHTML = g_ulsCallsignsCount; } } function ulsValuesChanged() { g_callsignLookups.ulsUseEnable = ulsUseEnable.checked; - g_callsignLookups.ulsWeeklyEnable = ulsWeeklyEnable.checked; - saveCallsignSettings(); + if ( g_callsignLookups.ulsUseEnable == true ) { ulsLoadCallsigns(); } else - g_callsignToState = Object(); + { + resetULSDatabase(); + ulsCountTd.innerHTML = 0; + } + saveCallsignSettings(); + ulsSettingsDisplay(); - - goProcessRoster(); if ( g_callRosterWindowHandle ) g_callRosterWindowHandle.window.resize(); } -function ulsDownload(fromSettings) +function ulsDownload() { - if ( g_ulsDownloadPending == true ) - { - ulsUpdatedTd.innerHTML = "Download pending"; - return; - } - g_ulsDownloadPending = true; ulsUpdatedTd.innerHTML = "Downloading..."; - g_callsignLookups.ulsLastUpdate = 0; - ulsCountTd.innerHTML = ""; + ulsCountTd.innerHTML = 0; getChunkedBuffer("https://dl.dropboxusercontent.com/s/91iynrvdse7zcf5/callsigns.txt?cb="+timeNowSec(), processulsCallsigns, null, "https", 443); } @@ -669,30 +551,31 @@ function getChunkedBuffer(file_url, callback, flag, mode, port, cookie, errorHan } http.get(options, function (res) { var fsize = res.headers['content-length']; + var fread = 0; var cookies = null; if (typeof res.headers['set-cookie'] != 'undefined') cookies = res.headers['set-cookie']; res.on('data', function (data) { + var isEnd = false; + fread += data.length; + if ( fread == fsize ) + isEnd = true; if (fileBuffer == null) { - fileBuffer = callback(data, flag, cookies, true, false); + fileBuffer = callback(data, flag, cookies, true, isEnd); } else { - fileBuffer = callback(fileBuffer + data, flag, cookies, false, false); + fileBuffer = callback(fileBuffer + data, flag, cookies, false, isEnd); } }).on('end', function () { - if (typeof callback === "function") { - // Call it, since we have confirmed it is callable - callback(null, flag, cookies, false , true); - } + }).on('error', function (e) { console.error('Got error: ' + e.message); }); }); } -var g_callsignToState = Object(); var g_ulsDatabase = openDatabase('ulsDB', '1.0', 'US Callsigns', 40 * 1024 * 1024); @@ -700,13 +583,19 @@ g_ulsDatabase.transaction(function (tx) { tx.executeSql('CREATE TABLE IF NOT EXISTS calls (callsign PRIMARY KEY, zip, state)'); }); -var g_currentULSBuffer = 0; + +function resetULSDatabase() +{ + g_callsignLookups.ulsLastUpdate = 0; + g_ulsCallsignsCount = 0; +} function processulsCallsigns(data, flag, cookies, starting, finished) { var buffer = String(data); var returnBuffer = ""; + if ( buffer && buffer.length > 0 ) { var lines = null; @@ -727,49 +616,58 @@ function processulsCallsigns(data, flag, cookies, starting, finished) g_ulsDatabase.transaction(function (tx) { if ( starting == true ) { + g_ulsCallsignsCount = 0; + g_callsignLookups.ulsLastUpdate = 0; + saveCallsignSettings(); + ulsUpdatedTd.innerHTML = "Processing..."; tx.executeSql('drop table calls'); tx.executeSql('CREATE TABLE IF NOT EXISTS calls (callsign PRIMARY KEY, zip, state)'); - g_ulsCallsignsCount = 0; - g_currentLine = 0; } for (var x in lines ) { if ( lines[x].length ) { tx.executeSql( 'INSERT INTO calls (callsign, zip, state) VALUES ("'+lines[x].substr(7)+'","'+lines[x].substr(0,5)+'","'+lines[x].substr(5,2)+'")'); + ++g_ulsCallsignsCount; + if ( g_ulsCallsignsCount % 7969 == 0 ) + ulsCountTd.innerHTML = g_ulsCallsignsCount; } } delete lines; lines = null; - + }); } } if ( finished == true ) { - g_ulsDownloadPending = false; + var now = timeNowSec(); - g_callsignLookups.ulsLastUpdate = timeNowSec(); - if ( g_callsignLookups.ulsWeeklyEnable == true ) - { - var now = timeNowSec(); - if ( g_ulsLoadTimer != null ) - clearTimeout(g_ulsLoadTimer); - - var ulsWhenTimer = (86400 * 7) - (now - g_callsignLookups.ulsLastUpdate); - g_ulsWhenDate = now + ulsWhenTimer; - g_ulsLoadTimer = setTimeout(ulsDownload,(ulsWhenTimer)*1000); - } - updateCallsignCount(); - ulsValuesChanged(); + if ( g_ulsLoadTimer != null ) + clearTimeout(g_ulsLoadTimer); + + var ulsWhenTimer = 86400 * 7; + g_ulsWhenDate = ulsWhenTimer + now; + g_ulsLoadTimer = setTimeout(ulsDownload,(ulsWhenTimer)*1000); + + g_ulsDatabase.transaction(function (tx) { + tx.executeSql('SELECT count(*) as cnt FROM calls', [], function (rx, results) + { + var len = results.rows.length, i; + if ( len == 1 ) + { + g_ulsCallsignsCount = results.rows[0]["cnt"]; + ulsCountTd.innerHTML = g_ulsCallsignsCount; + g_callsignLookups.ulsLastUpdate = timeNowSec(); + saveCallsignSettings(); + ulsSettingsDisplay(); + updateQSO(); + } + }); + }); } - g_currentULSBuffer++; - if ( g_currentULSBuffer % 40 == 0 ) - { - updateCallsignCount(); - } return Buffer(returnBuffer); } @@ -781,12 +679,20 @@ function lookupUsCallsign( object , writeState = false) var qry = 'SELECT * FROM calls where callsign = "'+object.DEcall+'"'; tx.executeSql(qry, [], function (tx, results) { - var len = results.rows.length, i; if ( len == 1 ) { if ( object.state == null ) - object.state = "US-"+results.rows[0]["state"]; + { + if ( object.dxcc == 1 ) + { + object.state = "CA-"+results.rows[0]["state"]; + } + else + { + object.state = "US-"+results.rows[0]["state"]; + } + } object.zipcode = results.rows[0]["zip"]; if ( object.cnty == null ) { diff --git a/package.nw/lib/datepicker.js b/package.nw/lib/datepicker.js new file mode 100644 index 00000000..48269dbf --- /dev/null +++ b/package.nw/lib/datepicker.js @@ -0,0 +1,238 @@ +var picker = { + attach : function (opt) { + // attach() : attach datepicker to target + // opt : options (object) + // target : datepicker will populate this field + // container : datepicker will be generated in this container + // startmon : start on Monday (default false) + // disableday : array of days to disable, e.g. [2,7] to disable Tue and Sun + + // (A) Create new datepicker + var dp = document.createElement("div"); + dp.dataset.target = opt.target; + dp.dataset.fire = opt.fire; + dp.dataset.startmon = opt.startmon ? "1" : "0"; + dp.classList.add("picker"); + if (opt.disableday) { + dp.dataset.disableday = JSON.stringify(opt.disableday); + } + + // (B) Default to current month + year + // ! NOTE: UTC+0 ! + var today = new Date(), + thisMonth = today.getUTCMonth(), // Note: Jan is 0 + thisYear = today.getUTCFullYear(), + months = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", + "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"]; + + // (C) Month select + var select = document.createElement("select"), + option = null; + select.classList.add("picker-m"); + for (var mth in months) { + option = document.createElement("option"); + option.value = parseInt(mth) + 1; + option.text = months[mth]; + select.appendChild(option); + } + select.selectedIndex = thisMonth; + select.addEventListener("change", function(){ picker.draw(this); }); + dp.appendChild(select); + + // (D) Year select + var yRange = 100; // Year range to show, I.E. from thisYear-yRange to thisYear+yRange + select = document.createElement("select"); + select.classList.add("picker-y"); + for (var y = thisYear-yRange; y < thisYear+20; y++) { + option = document.createElement("option"); + option.value = y; + option.text = y; + select.appendChild(option); + } + select.selectedIndex = yRange; + select.addEventListener("change", function(){ picker.draw(this); }); + dp.appendChild(select); + + // (E) Day select + var days = document.createElement("div"); + days.classList.add("picker-d"); + dp.appendChild(days); + + // (F) Attach date picker to target container + draw the dates + picker.draw(select); + + // (F1) Popup datepicker + if (opt.container==1) { + // Mark this as a "popup" + var uniqueID = 0; + while (document.getElementById("picker-" + uniqueID) != null) { + uniqueID = Math.floor(Math.random() * (100 - 2)) + 1; + } + dp.dataset.popup = "1"; + dp.dataset.dpid = uniqueID; + + // Create wrapper + var wrapper = document.createElement("div"); + wrapper.id = "picker-" + uniqueID; + wrapper.classList.add("picker-wrap"); + wrapper.appendChild(dp); + + // Attach onclick to show/hide datepicker + var target = document.getElementById(opt.target); + target.dataset.dp = uniqueID; + target.onfocus = function () { + document.getElementById("picker-" + this.dataset.dp).classList.add("show"); + }; + wrapper.addEventListener("click", function (evt) { + if (evt.target.classList.contains("picker-wrap")) { + this.classList.remove("show"); + } + }); + + // Attach popup datepicker to document + document.documentElement.appendChild(wrapper); + } + + // (F2) Inline datepicker + else { + document.getElementById(opt.container).appendChild(dp); + } + }, + + draw : function (el) { + // draw() : draw the days in month + // el : HTML reference to either year or month selector + + // (A) Get date picker components + var parent = el.parentElement, + year = parent.getElementsByClassName("picker-y")[0].value, + month = parent.getElementsByClassName("picker-m")[0].value, + days = parent.getElementsByClassName("picker-d")[0]; + + // (B) Date range calculation + // ! NOTE: UTC+0 ! + var daysInMonth = new Date(Date.UTC(year, month, 0)).getUTCDate(), + startDay = new Date(Date.UTC(year, month-1, 1)).getUTCDay(), // Note: Sun = 0 + endDay = new Date(Date.UTC(year, month-1, daysInMonth)).getUTCDay(), + startDay = startDay==0 ? 7 : startDay, + endDay = endDay==0 ? 7 : endDay; + + // (C) Generate date squares (in array first) + var squares = [], + disableday = null; + if (parent.dataset.disableday) { + disableday = JSON.parse(parent.dataset.disableday); + } + + // (C1) Empty squares before first day of month + if (parent.dataset.startmon=="1" && startDay!=1) { + for (var i=1; i 0 ) + { + window[parent.dataset.fire](); + } + + // (D) Popup only - close the popup + if (parent.dataset.popup == "1") { + document.getElementById("picker-" + parent.dataset.dpid).classList.remove("show"); + } + } +}; \ No newline at end of file diff --git a/package.nw/lib/defaults.js b/package.nw/lib/defaults.js index 8311d6ea..b678a713 100644 --- a/package.nw/lib/defaults.js +++ b/package.nw/lib/defaults.js @@ -36,15 +36,15 @@ var def_appSettings = "rosterAlwaysOnTop": false, "centerGridsquare" : "", "chatUUID" : "", - "crScript" : 1, - "distanceUnit" : "KM", + "crScript" : 0, + "distanceUnit" : "MI", "earthImgSrc" : 0, "gridViewMode" : 3, "gridsquareDecayTime" : 300, "gtAgree" : "", - "gtBandFilter" : "auto", + "gtBandFilter" : "", "gtFlagImgSrc" : 0, - "gtModeFilter" : "auto", + "gtModeFilter" : "", "gtPropFilter" : "mixed", "gtMsgEnable" : true, "gtShareEnable" : true, @@ -85,7 +85,11 @@ var def_appSettings = "wsjtForwardUdpIp" : "127.0.0.1", "wsjtForwardUdpPort" : 2238, "wsjtIP" : "", - "wsjtUdpPort" : 2237 + "wsjtUdpPort" : 0, + "workingCallsignEnable" : false, + "workingCallsigns" : {}, + "workingDateEnable": false, + "workingDate" : 0 }; var def_mapSettings = diff --git a/package.nw/lib/dp-dark.css b/package.nw/lib/dp-dark.css new file mode 100644 index 00000000..60257f99 --- /dev/null +++ b/package.nw/lib/dp-dark.css @@ -0,0 +1,67 @@ +/* [POPUP] */ +.picker-wrap { + position: fixed; + top: 0; + left: 0; + width: 100vw; + height: 100vh; + background: rgba(0,0,0,0.5); + opacity: 0; + visibility: hidden; + transition: opacity 0.2s; +} +.picker-wrap.show { + opacity: 1; + visibility: visible; +} +.picker-wrap .picker{ + margin: 50vh auto 0 auto; + transform: translateY(-50%) +} + +/* [CONTAINER] */ +.picker { + max-width: 300px; + border: 1px solid #000; + background: #444; + padding: 10px; +} + +/* [MONTH + YEAR] */ +.picker-m, .picker-y { + width: 50%; + padding: 5px; + box-sizing: border-box; + font-size: 16px; +} + +/* [DAY] */ +.picker-d table { + color: #fff; + border-collapse: separate; + width: 100%; + margin-top: 10px; +} +.picker-d table td { + width: 14.28%; /* 7 equal columns */ + padding: 5px; + text-align: center; +} +/* Header cells */ +.picker-d-h td { + font-weight: bold; +} +/* Blank dates */ +.picker-d-b { + background: #4e4e4e; +} +/* Pickable Dates */ +.picker-d-d:hover { + cursor: pointer; + background: #a33c3c; +} +/* Unpickable Dates */ +.picker-d-dd { + color: #888; + background: #4e4e4e; +} \ No newline at end of file diff --git a/package.nw/lib/dp-light.css b/package.nw/lib/dp-light.css new file mode 100644 index 00000000..edeb6326 --- /dev/null +++ b/package.nw/lib/dp-light.css @@ -0,0 +1,68 @@ +/* [POPUP] */ +.picker-wrap { + position: fixed; + top: 0; + left: 0; + width: 100vw; + height: 100vh; + background: rgba(0,0,0,0.5); + opacity: 0; + visibility: hidden; + transition: opacity 0.2s; +} +.picker-wrap.show { + opacity: 1; + visibility: visible; +} +.picker-wrap .picker{ + margin: 50vh auto 0 auto; + transform: translateY(-50%) +} + +/* [CONTAINER] */ +.picker { + max-width: 300px; + border: 1px solid #eee; + background: #fafafa; + padding: 10px; +} + +/* [MONTH + YEAR] */ +.picker-m, .picker-y { + width: 50%; + padding: 5px; + box-sizing: border-box; + font-size: 16px; +} + +/* [DAY] */ +.picker-d table { + color: #333; + border-collapse: separate; + width: 100%; + margin-top: 10px; +} +.picker-d table td { + width: 14.28%; /* 7 equal columns */ + padding: 5px; + text-align: center; +} +/* Header */ +.picker-d-h td { + font-weight: bold; +} +/* Blank dates */ +.picker-d-b { + background: #ddd; +} +/* Pickable Dates */ +.picker-d-d:hover { + cursor: pointer; + background: #2d68c4; + color: #fff; +} +/* Unpickable Dates */ +.picker-d-dd { + color: #aaa; + background: #ddd; +} \ No newline at end of file diff --git a/package.nw/lib/gt.js b/package.nw/lib/gt.js index 105a4c29..0a2f5615 100644 --- a/package.nw/lib/gt.js +++ b/package.nw/lib/gt.js @@ -1,8 +1,8 @@ // GridTracker ©2020 N0TTL var gtComment1 = "GridTracker is not open source, you may not change, modify or 'borrow' code for your needs that is redistributed in any form without first asking and receiving permission from N0TTL *and* N2VFL"; var gtComment2 = "Third party libraries and functions used are seperated to third-party.js or their respective lib .js files, the GT close-source directive does not apply to these files of course"; -var gtVersion = 1200821; -var gtBeta = ""; +var gtVersion = 1200825; +var gtBeta = "Betamax"; var g_startVersion = 0; @@ -48,7 +48,6 @@ var g_popupWindowHandle = null; var g_callRosterWindowHandle = null; var g_conditionsWindowHandle = null; var g_chatWindowHandle = null; -var g_settingsWindowHandle = null; var g_statsWindowHandle = null; var g_lookupWindowHandle = null; var g_baWindowHandle = null; @@ -69,6 +68,26 @@ var g_callsignLookups = {}; var g_startupLogs = []; var g_mapMemory = []; +var g_callsignDatabaseDXCC = { + 291 : true, + 1 : true, + 6 : true, + 110 : true, + 202 : true +}; + +var g_callsignDatabaseUS = { + 291 : true, + 6 : true, + 110 : true +} + +var g_callsignDatabaseUSplus = { + 291 : true, + 6 : true, + 110 : true, + 202 : true +} function loadAllSettings() { @@ -264,6 +283,24 @@ function saveAndCloseApp() saveAppSettings(); saveMapSettings(); + try + { + + if ( g_callRosterWindowHandle ) + { + g_callRosterWindowHandle.window.writeRosterSettings(); + g_callRosterWindowHandle.close(true); + } + if ( g_popupWindowHandle ) g_popupWindowHandle.close(true); + if ( g_conditionsWindowHandle ) g_conditionsWindowHandle.close(true); + if ( g_chatWindowHandle ) g_chatWindowHandle.close(true); + if ( g_statsWindowHandle ) g_statsWindowHandle.close(true); + if ( g_lookupWindowHandle ) g_lookupWindowHandle.close(true); + if ( g_baWindowHandle ) g_baWindowHandle.close(true); + } + catch (e) { + console.log(e); + } nw.App.quit(); } @@ -866,6 +903,32 @@ function setState( details ) } } +function isKnownCallsignDXCC(dxcc) +{ + if ( dxcc in g_callsignDatabaseDXCC ) + return true; + return false; + +} + +function isKnownCallsignUS(dxcc) +{ + if ( dxcc in g_callsignDatabaseUS ) + return true; + return false; + +} + +function isKnownCallsignUSplus(dxcc) +{ + if ( dxcc in g_callsignDatabaseUSplus ) + return true; + return false; + +} + + + function addDeDx(finalGrid, finalDXcall, cq, cqdx, locked, finalDEcall, finalRSTsent, finalTime, ifinalMsg, mode, band, confirmed, notQso, finalRSTrecv, finalDxcc, finalState, finalCont, finalCnty, finalCqZone, finalItuZone, finalVucc = [], finalPropMode = "", finalDigital = false, finalPhone = false, finalIOTA = "", finalSatName = "") { @@ -961,11 +1024,11 @@ function addDeDx(finalGrid, finalDXcall, cq, cqdx, locked, finalDEcall, finalRST details.zone = Number(details.px.charAt(details.px.length-1)); } - if (details.state != null && finalDxcc != 291 && finalDxcc != 110 && finalDxcc != 6 && finalDxcc != 202) - details.state = null; - else if (details.state == null && (finalDxcc == 291 || finalDxcc == 110 || finalDxcc == 6 || finalDxcc == 202) && finalGrid.length > 0) { + + if (details.state == null && isKnownCallsignUSplus(finalDxcc) && finalGrid.length > 0) { var fourGrid = finalGrid.substr(0, 4); - if ((fourGrid in g_gridToState) && g_gridToState[fourGrid].length == 1) { + if ((fourGrid in g_gridToState) && g_gridToState[fourGrid].length == 1 ) + { details.state = g_gridToState[fourGrid][0]; } lookupCall = true; @@ -981,20 +1044,28 @@ function addDeDx(finalGrid, finalDXcall, cq, cqdx, locked, finalDEcall, finalRST details.cnty = finalCnty; - if (details.cnty == null && (finalDxcc == 291 || finalDxcc == 110 || finalDxcc == 6 || finalDxcc == 202)) { - // Do County Lookup - lookupCall = true; - } else if (details.cnty != null && (finalDxcc == 291 || finalDxcc == 110 || finalDxcc == 6 || finalDxcc == 202)) { - if (!(details.cnty in g_cntyToCounty)) { - if (details.cnty.indexOf(",") == -1) { - if (!(details.state + "," + details.cnty in g_cntyToCounty)) - lookupCall = true; - } else - lookupCall = true; - + if ( isKnownCallsignUSplus(finalDxcc) ) + { + if (details.cnty == null ) + { + lookupCall = true; } + else + { + if (!(details.cnty in g_cntyToCounty)) + { + if (details.cnty.indexOf(",") == -1) + { + if (!(details.state + "," + details.cnty in g_cntyToCounty)) + lookupCall = true; + } + else + lookupCall = true; + } + } } + if (lookupCall) { if (g_callsignLookups.ulsUseEnable) { lookupUsCallsign(details, true); @@ -1009,8 +1080,6 @@ function addDeDx(finalGrid, finalDXcall, cq, cqdx, locked, finalDEcall, finalRST if (finalMsg.length > 0) details.msg = finalMsg; - - g_tracker.worked.call[finalDXcall + band + mode] = true; g_tracker.worked.call[finalDXcall] = true; g_tracker.worked.call[finalDXcall + mode] = true; @@ -1292,12 +1361,12 @@ function addDeDx(finalGrid, finalDXcall, cq, cqdx, locked, finalDEcall, finalRST newCallsign.IOTA = finalIOTA; newCallsign.satName = finalSatName; - if (newCallsign.state == null && (finalDxcc == 291 || finalDxcc == 110 || finalDxcc == 6 || finalDxcc == 202) && finalGrid.length > 0) { + if (newCallsign.state == null && isKnownCallsignDXCC(finalDxcc) && finalGrid.length > 0) { if (g_callsignLookups.ulsUseEnable) { lookupUsCallsign(newCallsign); } - if (newCallsign.state == null) { + if (newCallsign.state == null && isKnownCallsignUSplus(finalDxcc) ) { var fourGrid = finalGrid.substr(0, 4); if ((fourGrid in g_gridToState) && g_gridToState[finalGrid.substr(0, 4)].length == 1) { newCallsign.state = g_gridToState[finalGrid.substr(0, 4)][0]; @@ -1912,7 +1981,8 @@ function openCallRosterWindow( show = true ) { var gui = require('nw.gui'); gui.Window.open('gt_roster.html', { "show": false, - "id": "GT-roster" + "id": "GT-roster", + "icon" : "img/roster-icon.png" }, function (new_win) { g_callRosterWindowHandle = new_win; new_win.on('loaded', function () { @@ -2945,6 +3015,24 @@ function mouseOverGtFlag(feature) myFlagtip.style.zIndex = 499; myFlagtip.style.display = "block"; + + + if (feature.size == 73 && feature != g_lasttimezone ) + { + if ( g_lasttimezone != null ) + { + g_lasttimezone.setStyle(null); + } + + var style = new ol.style.Style({ + fill: new ol.style.Fill({ + color: "#FFFF0088" + }) + }); + + feature.setStyle(style); + g_lasttimezone = feature; + } return; } @@ -4057,6 +4145,22 @@ function clearOrLoadQSOs() } } +function clearAndLoadQSOs() +{ + initQSOdata(); + g_QSOhash = {}; + g_QSLcount = 0; + g_QSOcount = 0; + setTrophyOverlay(g_currentOverlay); + redrawGrids(); + updateCountStats(); + updateLogbook(); + updateRosterWorked(); + goProcessRoster(); + updateCountStats(); + startupAdifLoadCheck(); +} + function clearQSOs() { initQSOdata(); @@ -4636,22 +4740,6 @@ function initMap() { if (features[index].geometryName_ == "tz" ) { features[index].size = 73; - if ( features[index] != g_lasttimezone ) - { - if ( g_lasttimezone != null ) - { - g_lasttimezone.setStyle(null); - } - - var style = new ol.style.Style({ - fill: new ol.style.Fill({ - color: "#FFFF0088" - }) - }); - - features[index].setStyle(style); - g_lasttimezone = features[index]; - } } if (typeof features[index].size == "undefined") continue; @@ -4667,6 +4755,13 @@ function initMap() { break; } + if (features[index].size == 1) { + mouseOverGtFlag(features[index]); + noFlag = false; + noFeature = true; + break; + } + if (features[index].size == 6) { noFeature = false; finalGridFeature = features[index]; @@ -4674,25 +4769,20 @@ function initMap() { if (features[index].size == 4 && finalGridFeature == null) { noFeature = false; finalGridFeature = features[index]; + noFlag = true; } - if (features[index].size == 73) { + if (features[index].size == 73 && finalGridFeature == null ) { mouseOverGtFlag(features[index]); noFlag = false; - finalGridFeature == null; - noFeature = true; - break; - } - if (features[index].size == 1) { - mouseOverGtFlag(features[index]); - noFlag = false; - finalGridFeature == null; - noFeature = true; - break; } + + } if (finalGridFeature) + { mouseOverDataItem(finalGridFeature, true); + } } } @@ -4860,9 +4950,7 @@ function toggleNexrad() delete g_Nexrad; g_Nexrad = null; } - - - + createNexRad(); if ( g_nexradInterval == null ) @@ -4882,17 +4970,10 @@ function toggleNexrad() g_Nexrad = null; } } - if ( g_nexradEnable ) - { - UsNexradValue.checked = true; - } - else - { - UsNexradValue.checked = false; - } + - g_mapSettings.usNexrad = UsNexradValue.checked; - saveMapSettings(); + g_mapSettings.usNexrad = (g_nexradEnable==1?true:false); + } @@ -5875,7 +5956,7 @@ function handleWsjtxDecode(newMessage) { newCallsign.cqza = Array(); newCallsign.distance = 0; newCallsign.heading = 0; - if (g_callsignLookups.ulsUseEnable == true && (newCallsign.dxcc == 291 || newCallsign.dxcc == 110 || newCallsign.dxcc == 6 || newCallsign.dxcc == 202)) { + if (g_callsignLookups.ulsUseEnable == true && isKnownCallsignDXCC(newCallsign.dxcc) ) { lookupUsCallsign(newCallsign); } @@ -7509,7 +7590,8 @@ function openLookupWindow( show = true ) { var gui = require('nw.gui'); gui.Window.open('gt_lookup.html', { "show": false, - "id": "GT-lookups" + "id": "GT-lookups", + "icon" : "img/lookup-icon.png" }, function (new_win) { g_lookupWindowHandle = new_win; new_win.on('loaded', function () { @@ -7858,7 +7940,7 @@ function renderStatsBox() else workObject(modet.Other, true, band, mode, type, didConfirm); - if (state != null && (finalDxcc == 291 || finalDxcc == 110 || finalDxcc == 6)) { + if (state != null && isKnownCallsignUS(finalDxcc) ) { if (state.substr(0, 2) != "US") state = "US-" + state; @@ -8642,7 +8724,7 @@ function redrawGrids() { var ituz = g_QSOhash[i].ituz; var cqz = g_QSOhash[i].cqz; - if (state != null && (finalDxcc == 291 || finalDxcc == 110 || finalDxcc == 6)) { + if (state != null && isKnownCallsignUS(finalDxcc) ) { if (state.substr(0, 2) != "US") state = "US-" + state; @@ -9323,8 +9405,13 @@ function updateRunningProcesses() { function updateBasedOnIni() { var which = null; + var count = 0; + if ( g_wsjtxProcessRunning ) + count++; + if ( g_jtdxProcessRunning ) + count++; // UdpPortNotSet - if (g_appSettings.wsjtUdpPort == 0) { + if (g_appSettings.wsjtUdpPort == 0 || count == 1) { if (g_wsjtxProcessRunning) which = g_wsjtxIni; else if (g_jtdxProcessRunning) @@ -9335,8 +9422,14 @@ function updateBasedOnIni() { } if (which == null) { g_appSettings.wsjtUdpPort = 2237; - g_appSettings.ip = ""; + g_appSettings.wsjtIP = ""; } + if (ipToInt(g_appSettings.wsjtIP) >= ipToInt("224.0.0.0") && ipToInt(g_appSettings.wsjtIP) < ipToInt("240.0.0.0")) + { + g_appSettings.multicast = true; + } + else + g_appSettings.multicast = false; } // Which INI do we load? if (g_appSettings.wsjtUdpPort) { @@ -9422,6 +9515,57 @@ function validateNumAndLetter( input ) return false; } +function validCallsignsKeys( value ) +{ + if (value == 44) + return true; + if ( value >= 48 && value <= 57 ) + return true; + if ( value >= 65 && value <= 90 ) + return true; + return (value >=97 && value <= 122); +} + +function ValidateCallsigns(inputText, validDiv) +{ + inputText.value = inputText.value.toUpperCase(); + var callsigns = inputText.value.split(","); + var passed = false; + for ( var call in callsigns ) + { + if (callsigns[call].length > 0) + { + if (/\d/.test(callsigns[call]) && /[A-Z]/.test(callsigns[call]) ) + { + passed = true; + } + else + { + passed = false; + break; + } + } + else + { + passed = false; + break; + } + } + + if (passed) + { + inputText.style.color = "#FF0"; + inputText.style.backgroundColor = "green"; + } + else + { + inputText.style.color = "#000"; + inputText.style.backgroundColor = "yellow"; + } + return passed; +} + + function ValidateCallsign(inputText, validDiv) { addError.innerHTML = ""; if ((inputText.value.length > 0)) { @@ -9562,7 +9706,7 @@ function ValidateMulticast(inputText) { if (inputText.value.match(ipformat)) { if (inputText.value != "0.0.0.0" && inputText.value != "255.255.255.255") { var ipInt = ipToInt(inputText.value); - if (ipInt > ipToInt("224.0.0.0") && ipInt < ipToInt("240.0.0.0")) { + if (ipInt >= ipToInt("224.0.0.0") && ipInt < ipToInt("240.0.0.0")) { if (ipInt > ipToInt("224.0.0.255")) { inputText.style.color = "black"; inputText.style.backgroundColor = "yellow"; @@ -9635,6 +9779,59 @@ function ValidatePort(inputText, checkBox, callBackCheck) { } } +function workingCallsignEnableChanged(ele) +{ + g_appSettings.workingCallsignEnable = ele.checked; + applyCallsignsAndDateDiv.style.display = ""; +} + +function workingDateEnableChanged(ele) +{ + g_appSettings.workingDateEnable = ele.checked; + applyCallsignsAndDateDiv.style.display = ""; + +} + +function workingDateChanged() +{ + var fields = workingDateValue.value.split("-"); + var date = new Date( Date.UTC(parseInt(fields[0]), parseInt(fields[1])-1, parseInt(fields[2]),0,0,0)); + g_appSettings.workingDate = Date.UTC(parseInt(fields[0]), parseInt(fields[1])-1, parseInt(fields[2]),0,0,0) / 1000; + displayWorkingDate(); + applyCallsignsAndDateDiv.style.display = ""; +} + +function displayWorkingDate() +{ + var date = new Date(g_appSettings.workingDate*1000); + workingDateString.innerHTML = dateToString( date ); +} + +var g_tempWorkingCallsigns = {}; +function workingCallsignsChanged(ele) +{ + g_tempWorkingCallsigns = {}; + var callsigns = ele.value.split(","); + for ( var call in callsigns ) + { + g_tempWorkingCallsigns[callsigns[call]] = true; + } + if ( callsigns.length > 0 ) + { + g_appSettings.workingCallsigns = Object.assign({},g_tempWorkingCallsigns); + if ( g_appSettings.workingCallsignEnable ) + applyCallsignsAndDateDiv.style.display = ""; + } + else + applyCallsignsAndDateDiv.style.display = "none"; +} + +function applyCallsignsAndDates() +{ + clearAndLoadQSOs(); + applyCallsignsAndDateDiv.style.display = "none"; +} + function selectElementContents(el) { var body = document.body, range, @@ -9671,21 +9868,22 @@ function ipLocation(buffer, flag) { function popupNewWindows() { if (typeof nw != 'undefined') { - var gui = require('nw.gui'); - var win = gui.Window.get(); win.on('new-win-policy', function (frame, url, policy) { policy.forceNewPopup(); + g_lastUrl = ""; }); } } +var g_lastUrl = ""; function lockNewWindows() { if (typeof nw != 'undefined') { - var gui = require('nw.gui'); - var win = gui.Window.get(); - win.on('new-win-policy', function (frame, url, policy) { - var gui = require('nw.gui'); - gui.Shell.openExternal(url); + win.on('new-win-policy', function (frame, url, policy) { + if ( url != g_lastUrl ) + { + nw.Shell.openExternal(url); + g_lastUrl = url; + } policy.ignore(); }); } @@ -10424,7 +10622,6 @@ function loadMapSettings() { offlineImg.src = g_mapImageArray[(g_mapSettings.offlineMode ? 0 : 1)]; - mapSelect.value = g_mapSettings.mapIndex; mapNightSelect.value = g_mapSettings.nightMapIndex; @@ -10441,7 +10638,6 @@ function loadMapSettings() { haltAllOnTxValue.checked = g_mapSettings.haltAllOnTx; strikesAlert.value = g_mapSettings.strikesAlert; - UsNexradValue.checked = g_mapSettings.usNexrad; setStrikesButton(); @@ -10874,7 +11070,18 @@ function setMsgSettingsView() { } function loadAdifSettings() { - + + workingCallsignEnable.checked = g_appSettings.workingCallsignEnable; + workingCallsignsValue.value = (Object.keys(g_appSettings.workingCallsigns).join(",")); + + if ( workingCallsignsValue.value.length == 0 ) + workingCallsignsValue.value = myDEcall; + + ValidateCallsigns(workingCallsignsValue); + + workingDateEnable.checked = g_appSettings.workingDateEnable ; + displayWorkingDate(); + if ( g_platform == "mac" ) { selectTQSLButton.style.display = "none"; @@ -10955,6 +11162,7 @@ function loadAdifSettings() { } setAdifStartup(loadAdifCheckBox); ValidateQrzApi(qrzApiKey); + } function startupVersionInit() { @@ -11033,14 +11241,7 @@ function postInit() { updateForwardListener(); addLastTraffic("GridTracker
" + gtShortVersion ); - if ( UsNexradValue.checked == true ) - { - g_nexradEnable = 0; - } - else - { - g_nexradEnable = 1; - } + g_nexradEnable = g_mapSettings.usNexrad?0:1; toggleNexrad(); updateText.innerHTML = fs.readFileSync("./gt_update.html"); @@ -11053,6 +11254,13 @@ function postInit() { } g_finishedLoading = true; //tagme + var x = document.querySelectorAll("input[type='range']"); + for (var i = 0; i < x.length; i++) { + if ( x[i].title.length > 0 ) + x[i].title += "\n"; + x[i].title += "(Use Arrow Keys For Smaller Increments)"; + } + } @@ -13198,4 +13406,17 @@ function makeScreenshots() } +window.addEventListener("load", function(){ + picker.attach({ + target: "workingDateValue", + container: "pick-inline", + fire: "workingDateChanged" + }); +}); + +process.on('uncaughtException', function (e) { + alert(e); + console.error('uncaughtException:', e); + console.error(e.stack); +}); diff --git a/package.nw/lib/gtws.js b/package.nw/lib/gtws.js index 9afcbd31..c664c34a 100644 --- a/package.nw/lib/gtws.js +++ b/package.nw/lib/gtws.js @@ -390,7 +390,7 @@ function makeGtPin( obj ) obj.pin = null; } - if (typeof obj.grid == 'undefined' || typeof obj.grid == null ) + if (typeof obj.grid == 'undefined' || obj.grid == null ) return; if ( obj.grid.length != 4 && obj.grid.length != 6 ) diff --git a/package.nw/lib/roster.js b/package.nw/lib/roster.js index bfa1ac1f..551b989b 100644 --- a/package.nw/lib/roster.js +++ b/package.nw/lib/roster.js @@ -41,6 +41,9 @@ var g_regFocus = false; var g_awards = {}; var g_awardTypes = {}; var g_awardTracker = {}; +var g_callsignDatabaseDXCC = {}; +var g_callsignDatabaseUS = {} +var g_callsignDatabaseUSplus = {}; var g_modeColors = {}; @@ -197,6 +200,30 @@ function writeRosterSettings() localStorage.rosterSettings = JSON.stringify(g_rosterSettings); } +function isKnownCallsignDXCC(dxcc) +{ + if ( dxcc in g_callsignDatabaseDXCC ) + return true; + return false; + +} + +function isKnownCallsignUS(dxcc) +{ + if ( dxcc in g_callsignDatabaseUS ) + return true; + return false; + +} + +function isKnownCallsignUSplus(dxcc) +{ + if ( dxcc in g_callsignDatabaseUSplus ) + return true; + return false; + +} + function timeNowSec() { return parseInt(Date.now() / 1000); @@ -427,6 +454,7 @@ function viewRoster() var callMode = g_rosterSettings.callsign; var onlyHits = false; var isAwardTracker = false; + if ( callMode == "hits" ) { callMode = "all"; @@ -438,6 +466,7 @@ function viewRoster() onlyHits = false; isAwardTracker = true; g_rosterSettings.huntNeed = "confirmed"; + } var canMsg = (window.opener.g_mapSettings.offlineMode == false && window.opener.g_appSettings.gtShareEnable == "true" && window.opener.g_appSettings.gtMsgEnable == "true" ); @@ -859,7 +888,6 @@ function viewRoster() } callRoster[callHash].tx = tx; - } } @@ -1067,7 +1095,7 @@ function viewRoster() if ( huntCounty.checked == true && window.opener.g_callsignLookups.ulsUseEnable == true ) { var finalDxcc = callRoster[callHash].callObj.dxcc; - if ( callRoster[callHash].callObj.cnty && ( finalDxcc == 291 || finalDxcc == 110 || finalDxcc == 6) && callRoster[callHash].callObj.cnty.length > 0 ) + if ( callRoster[callHash].callObj.cnty && ( finalDxcc == 291 || finalDxcc == 110 || finalDxcc == 6 || finalDxcc == 202) && callRoster[callHash].callObj.cnty.length > 0 ) { var hash = callRoster[callHash].callObj.cnty + workHash; @@ -2643,6 +2671,10 @@ function resize() function init() { + g_callsignDatabaseDXCC = window.opener.g_callsignDatabaseDXCC; + g_callsignDatabaseUS = window.opener.g_callsignDatabaseUS + g_callsignDatabaseUSplus = window.opener.g_callsignDatabaseUSplus; + loadAwardJson(); updateWorked(); @@ -2689,11 +2721,34 @@ function init() rosterHead.style.display = "block"; g_rosterSettings.controls = true; } + g_compactMenu.items[0].label = g_rosterSettings.controls? "Hide Controls":"Show Controls"; localStorage.rosterSettings = JSON.stringify(g_rosterSettings); resize(); } }); g_menu.append(item); + + item = new nw.MenuItem({ + type: "normal", + label: g_rosterSettings.controls? "Hide Controls":"Show Controls", + click: function() { + if ( this.label == "Hide Controls" ) + { + this.label = "Show Controls"; + rosterHead.style.display = "none"; + g_rosterSettings.controls = false; + } + else + { + this.label = "Hide Controls"; + rosterHead.style.display = "block"; + g_rosterSettings.controls = true; + } + g_menu.items[0].label = g_rosterSettings.controls? "Hide Controls":"Show Controls"; + localStorage.rosterSettings = JSON.stringify(g_rosterSettings); + resize(); + } + }); g_compactMenu.append(item); item = new nw.MenuItem({ @@ -2789,7 +2844,7 @@ function init() item = new nw.MenuItem({ type: 'separator' }); g_menu.append(item); - g_compactMenu.append(item); + item = new nw.MenuItem({ type: "checkbox", @@ -2842,7 +2897,7 @@ function init() } }); g_menu.append(g_clearIgnores); - g_compactMenu.append(g_clearIgnores); + g_clearIgnoresCall = new nw.MenuItem({ type: "normal", @@ -2896,7 +2951,7 @@ function init() } }); g_menu.append(g_clearCQIgnoreMainMenu); - g_compactMenu.append(g_clearCQIgnoreMainMenu); + g_clearCQIgnore = new nw.MenuItem({ type: "normal", @@ -2949,7 +3004,7 @@ function init() } }); g_menu.append(g_clearDxccIgnoreMainMenu); - g_compactMenu.append(g_clearDxccIgnoreMainMenu); + g_clearDxccIgnore = new nw.MenuItem({ type: "normal", @@ -2972,7 +3027,7 @@ function init() } }); g_menu.append(item); - g_compactMenu.append(item); + item = new nw.MenuItem({ @@ -3799,16 +3854,18 @@ function testApxa(award, obj, baseHash) { if ( test.rule.pxa[i].indexOf(obj.px) > -1 ) { - return false; + if ( String(obj.px)+baseHash in g_tracker[award.test.look].px ) + { + return false; + } + else + { + return true; + } } } - - if ( String(obj.px)+baseHash in g_tracker[award.test.look].px ) - { - return false; - } } - return true; + return false; } function scoreAsfx(award, obj) diff --git a/package.nw/lib/style.css b/package.nw/lib/style.css index d3ed4cca..d155e229 100644 --- a/package.nw/lib/style.css +++ b/package.nw/lib/style.css @@ -477,6 +477,19 @@ img { .buttonImg { height:32px; + padding:0; + margin:0; + +} + +.buttonImgWide +{ + width:74px; + height:36px; + padding:0; + margin-top:1px; + margin-bottom:-1px; + } .solarImg diff --git a/package.nw/lib/style_roster.css b/package.nw/lib/style_roster.css index d273ff09..0a9c146c 100644 --- a/package.nw/lib/style_roster.css +++ b/package.nw/lib/style_roster.css @@ -218,13 +218,13 @@ table.darkTable thead th:first-child { } .compactCallsign { - padding:3px; + padding:1px; overflow: hidden; white-space: nowrap; } .compactDXCC { - padding:3px; + padding:2px; max-width: 9em; overflow: hidden; white-space: nowrap; diff --git a/package.nw/package.json b/package.nw/package.json index e31cd4bc..a4d500e6 100644 --- a/package.nw/package.json +++ b/package.nw/package.json @@ -7,7 +7,7 @@ "toolbar" : false, "show" : false, "width" : 800, - "height" : 640 + "height" : 652 }, "webkit": { "plugin": true
N3FJP ACLogN3FJP Loggers