pixel editor mouseup(); unhighlight line when resume after debug

This commit is contained in:
Steven Hugg 2019-04-22 13:32:34 -04:00
parent 8af1c5d3c5
commit 8f1a7c710e
6 changed files with 29 additions and 23 deletions

View File

@ -29,8 +29,6 @@ TODO:
- update Javatari version? (and others?) - update Javatari version? (and others?)
- unify versioning - unify versioning
- disassembler for uploaded ROMs - disassembler for uploaded ROMs
- verilog debugging/reloading makes it slow
- remove FPS and play controls when Verilog scope paused
- compile stuck when errors unchanged - compile stuck when errors unchanged
- sound mute? - sound mute?
- $error updates source editor - $error updates source editor
@ -46,19 +44,15 @@ TODO:
- links to external tools in ide - links to external tools in ide
- error msg when #link doesn't work - error msg when #link doesn't work
- figure out folders for projects for real - figure out folders for projects for real
- why loadState() on verilog kill perf?
- click to break on raster position - click to break on raster position
- restructure src/ folders - restructure src/ folders
- quantify verilog "graph iterations"
- debug bankswitching for funky formats - debug bankswitching for funky formats
- spaces in filename don't parse code listing (DASM, maybe more) - spaces in filename don't parse code listing (DASM, maybe more)
- 'undefined' for bitmap replacer - 'undefined' for bitmap replacer
- astrocade: run to cursor in hello world messes up emulation - astrocade: run to cursor in hello world messes up emulation
- requestInterrupt needs to be disabled after breakpoint? - requestInterrupt needs to be disabled after breakpoint?
- verilog: when paused scope doesn't work
- C/asm formatter - C/asm formatter
- fix WebAudio (https://news.ycombinator.com/item?id=18066474) - fix WebAudio (https://news.ycombinator.com/item?id=18066474)
- share playable link w/ verilog?
- allow download of JSASM output - allow download of JSASM output
- update bootstrap - update bootstrap
- $readmemb/h - $readmemb/h
@ -81,7 +75,6 @@ TODO:
- markdown, verilog: can't share - markdown, verilog: can't share
- https://www.crowdsupply.com/tinyfpga/tinyfpga-bx - https://www.crowdsupply.com/tinyfpga/tinyfpga-bx
- HTTPS warning - HTTPS warning
- Safari: scope doesn't show while CRT in use
- recording video indicator - recording video indicator
- stego shareable images (http://pico-8.wikia.com/wiki/P8PNGFileFormat) - stego shareable images (http://pico-8.wikia.com/wiki/P8PNGFileFormat)
- https://makecode.com/language? - https://makecode.com/language?
@ -107,7 +100,6 @@ TODO:
- map editor - map editor
- metasprites - metasprites
- throw errors when bad/no refs - throw errors when bad/no refs
- capture so we get mouseUp() out of frame
- per-View keyboard shortcuts - per-View keyboard shortcuts
- parse labels - parse labels
- crt0.s compiled each time? - crt0.s compiled each time?
@ -118,6 +110,18 @@ TODO:
- running profiler while replaying? grand unified replay? - running profiler while replaying? grand unified replay?
- click on profiler to step to position - click on profiler to step to position
- breakpoints stop profiler from running - breakpoints stop profiler from running
- https://remotestoragejs.readthedocs.io/en/latest/getting-started/how-to-add.html ?
- Verilog
- larger scope range, better scrolling
- remove FPS and play controls when Verilog scope paused
- when paused scope doesn't work
- Safari: scope doesn't show while CRT in use
- verilog debugging/reloading makes it slow
- why loadState() on verilog kill perf?
- quantify verilog "graph iterations"
- toolbar overlaps scope
- CPU debugging
- disassemble more code around breakpoint
WEB WORKER FORMAT WEB WORKER FORMAT

View File

@ -1,6 +1,6 @@
{ {
"name": "8bitworkshop", "name": "8bitworkshop",
"version": "3.3.1", "version": "3.4.0",
"author": "Steven Hugg", "author": "Steven Hugg",
"dependencies": {}, "dependencies": {},
"devDependencies": { "devDependencies": {

View File

@ -33,10 +33,10 @@ const int note_table_tri[64] = {
#define NOTE_TABLE note_table_49 #define NOTE_TABLE note_table_49
#define BASS_NOTE 36 #define BASS_NOTE 36
byte music_index = 0; byte music_index = 0;
byte cur_duration = 0; byte cur_duration = 0;
const byte music1[]; // music data -- see end of file const byte music1[]; // music data -- see end of file
const byte* music_ptr = music1; const byte* music_ptr = music1;

View File

@ -926,20 +926,19 @@ class PixEditor extends Viewer {
dragcol = this.getPixel(pos.x, pos.y) == this.currgba ? this.palette[0] : this.currgba; dragcol = this.getPixel(pos.x, pos.y) == this.currgba ? this.palette[0] : this.currgba;
this.setPixel(pos.x, pos.y, this.currgba); this.setPixel(pos.x, pos.y, this.currgba);
dragging = true; dragging = true;
// TODO: pixcanvas.setCapture(); $(document).mouseup( (e) => {
var pos = this.getPositionFromEvent(e);
this.setPixel(pos.x, pos.y, dragcol);
dragging = false;
this.commit();
$(document).off('mouseup');
});
}) })
.mousemove( (e) => { .mousemove( (e) => {
var pos = this.getPositionFromEvent(e); var pos = this.getPositionFromEvent(e);
if (dragging) { if (dragging) {
this.setPixel(pos.x, pos.y, dragcol); this.setPixel(pos.x, pos.y, dragcol);
} }
})
.mouseup( (e) => {
var pos = this.getPositionFromEvent(e);
this.setPixel(pos.x, pos.y, dragcol);
dragging = false;
this.commit();
// TODO: pixcanvas.releaseCapture();
}); });
/* /*
Mousetrap.bind('ctrl+shift+h', this.flipX.bind(this)); Mousetrap.bind('ctrl+shift+h', this.flipX.bind(this));

View File

@ -325,9 +325,9 @@ export class SourceEditor implements ProjectView {
} }
refreshDebugState(moveCursor:boolean) { refreshDebugState(moveCursor:boolean) {
this.clearCurrentLine();
var line = this.getActiveLine(); var line = this.getActiveLine();
if (line >= 0) { if (line >= 0) {
this.clearCurrentLine();
this.setCurrentLine(line, moveCursor); this.setCurrentLine(line, moveCursor);
// TODO: switch to disasm? // TODO: switch to disasm?
} }
@ -375,6 +375,8 @@ export class SourceEditor implements ProjectView {
/// ///
const disasmWindow = 512; // disassemble this many bytes around cursor
export class DisassemblerView implements ProjectView { export class DisassemblerView implements ProjectView {
disasmview; disasmview;
@ -455,7 +457,7 @@ export class DisassemblerView implements ProjectView {
} }
return s; return s;
} }
var text = disassemble(pc-96, pc) + disassemble(pc, pc+96); var text = disassemble(pc-disasmWindow, pc) + disassemble(pc, pc+disasmWindow);
this.disasmview.setValue(text); this.disasmview.setValue(text);
if (moveCursor) { if (moveCursor) {
this.disasmview.setCursor(selline, 0); this.disasmview.setCursor(selline, 0);
@ -1183,9 +1185,10 @@ export class AssetEditorView implements ProjectView, pixed.EditorContext {
let label = fileid; // TODO: label let label = fileid; // TODO: label
let node : pixed.PixNode = new pixed.TextDataNode(projectWindows, fileid, label, frag.start, frag.end); let node : pixed.PixNode = new pixed.TextDataNode(projectWindows, fileid, label, frag.start, frag.end);
let first = node; let first = node;
// rle-compressed? // rle-compressed? TODO
if (frag.fmt.comp == 'rletag') { if (frag.fmt.comp == 'rletag') {
node = node.addRight(new pixed.Compressor()); //node = node.addRight(new pixed.Compressor());
continue;
} }
// is this a nes nametable? // is this a nes nametable?
if (frag.fmt.map == 'nesnt') { if (frag.fmt.map == 'nesnt') {

2
tss

@ -1 +1 @@
Subproject commit 5b5ee67fc06956bc7dce51726e98812d2d897eaa Subproject commit 61a1691a1de05dca3b694bf603db49ffbaf572cf