summaryrefslogtreecommitdiff
path: root/atari/ctxmenu.c
diff options
context:
space:
mode:
authorOle Loots <ole@monochrom.net>2011-11-28 23:23:28 +0000
committerOle Loots <ole@monochrom.net>2011-11-28 23:23:28 +0000
commit999410adc818e9bc9e566580b38954720d7dad55 (patch)
tree6abf17a5a94a9835673e2b5b5a6542087f010737 /atari/ctxmenu.c
parenta7ba1b7ccd1178717e8e4a0546282270ed2fb1d6 (diff)
downloadnetsurf-999410adc818e9bc9e566580b38954720d7dad55.tar.gz
netsurf-999410adc818e9bc9e566580b38954720d7dad55.tar.bz2
I'm actually trying to simplify the frontend code, changes:
- Optimized browser window caret, uses back-buffer now. ( So no content redraw is scheduled by the frontend just for a caret move ) - Fixed a double redraw issue when the browser reformat is pending and the AES also sends an redraw request because of the resize. - Started to use netsurfs textarea instead of a custom implementation ( to reduce code size ). svn path=/trunk/netsurf/; revision=13191
Diffstat (limited to 'atari/ctxmenu.c')
-rw-r--r--atari/ctxmenu.c18
1 files changed, 13 insertions, 5 deletions
diff --git a/atari/ctxmenu.c b/atari/ctxmenu.c
index fadf69de2..06df25903 100644
--- a/atari/ctxmenu.c
+++ b/atari/ctxmenu.c
@@ -96,7 +96,7 @@ static struct s_context_info * get_context_info( struct gui_window * gw, short m
memset( &ctxinfo.ccdata, sizeof(struct contextual_content), 0 );
browser_window_get_contextual_content(
gw->browser->bw,
- mx+gw->browser->scroll.current.x,
+ mx+gw->browser->scroll.current.x,
my+gw->browser->scroll.current.y,
(struct contextual_content*)&ctxinfo.ccdata
);
@@ -149,7 +149,8 @@ void context_popup( struct gui_window * gw, short x, short y )
char * data;
FILE * fp_tmpfile;
char * tempfile;
- int err = 0;
+ int err = 0;
+ char cmdline[128];
pop = get_tree( POP_CTX );
if( pop == NULL )
@@ -251,11 +252,18 @@ void context_popup( struct gui_window * gw, short x, short y )
fp_tmpfile = fopen( tempfile, "w" );
if( fp_tmpfile ){
fwrite( data, size, 1, fp_tmpfile );
- fclose( fp_tmpfile );
- err = ShelWrite( option_atari_editor, tempfile , NULL, 1, 0);
+ fclose( fp_tmpfile );
+ // TODO: check if app is runnin, if not, use pexec or such.
+ /*sprintf((char*)&cmdline, "%s \"%s\"", option_atari_editor, tempfile );
+ system( (char*)&cmdline );
+ */
+ //err = ShelWrite( option_atari_editor, tempfile , option_atari_editor, 1, 0);
LOG(("launched: %s %s (%d)\n", option_atari_editor, tempfile, err ));
- }
+ }
+
}
+ } else {
+ LOG(("Please set option_atari_editor!"));
}
break;