summaryrefslogtreecommitdiff
path: root/amiga
diff options
context:
space:
mode:
authorVincent Sanders <vince@kyllikki.org>2013-05-28 16:44:46 +0100
committerVincent Sanders <vince@kyllikki.org>2013-05-28 16:44:46 +0100
commita92e5930ffbcb178a2d2420ee2f6d4834ffa90e1 (patch)
treeb3284a8aaadc287ecb3397f989fc9e4d53dd4191 /amiga
parentfcc61ea37437fbfd163c5a96a7119bbcf69073e1 (diff)
downloadnetsurf-a92e5930ffbcb178a2d2420ee2f6d4834ffa90e1.tar.gz
fixup issues with new options API merge
Diffstat (limited to 'amiga')
-rw-r--r--amiga/clipboard.c4
-rwxr-xr-xamiga/font.c6
-rw-r--r--amiga/gui.c16
-rwxr-xr-xamiga/gui_options.c29
-rw-r--r--amiga/menu.c2
-rw-r--r--amiga/theme.c2
6 files changed, 31 insertions, 28 deletions
diff --git a/amiga/clipboard.c b/amiga/clipboard.c
index d0772f1b0..fd42f4d61 100644
--- a/amiga/clipboard.c
+++ b/amiga/clipboard.c
@@ -238,7 +238,7 @@ void gui_set_clipboard(const char *buffer, size_t length,
{
if(!(PushChunk(iffh, ID_FTXT, ID_FORM, IFFSIZE_UNKNOWN)))
{
- if(nsoption_bool(utf8_clipboard))
+ if(nsoption_bool(clipboard_write_utf8))
{
if(!(PushChunk(iffh, 0, ID_CSET, 32)))
{
@@ -254,7 +254,7 @@ void gui_set_clipboard(const char *buffer, size_t length,
}
if(!(PushChunk(iffh, 0, ID_CHRS, IFFSIZE_UNKNOWN))) {
- if(nsoption_bool(utf8_clipboard)) {
+ if(nsoption_bool(clipboard_write_utf8)) {
WriteChunkBytes(iffh, buffer, length);
} else {
if(utf8_to_local_encoding(buffer, length, &text) == UTF8_CONVERT_OK) {
diff --git a/amiga/font.c b/amiga/font.c
index 69001a28d..f10db53e4 100755
--- a/amiga/font.c
+++ b/amiga/font.c
@@ -881,10 +881,10 @@ void ami_font_setdevicedpi(int id)
{
DisplayInfoHandle dih;
struct DisplayInfo dinfo;
- ULONG ydpi = nsoption_int(amiga_ydpi);
- ULONG xdpi = nsoption_int(amiga_ydpi);
+ ULONG ydpi = nsoption_int(screen_ydpi);
+ ULONG xdpi = nsoption_int(screen_ydpi);
- nscss_screen_dpi = INTTOFIX(nsoption_int(amiga_ydpi));
+ nscss_screen_dpi = INTTOFIX(nsoption_int(screen_ydpi));
if(id && (nsoption_int(monitor_aspect_x) != 0) && (nsoption_int(monitor_aspect_y) != 0))
{
diff --git a/amiga/gui.c b/amiga/gui.c
index 9737ed087..4ce629b73 100644
--- a/amiga/gui.c
+++ b/amiga/gui.c
@@ -131,6 +131,8 @@
#include <math.h>
#include <string.h>
+define AMINS_SCROLLERPEN NUMDRIPENS
+
#define NSA_KBD_SCROLL_PX 10
/* Extra mouse button defines to match those in intuition/intuition.h */
@@ -668,10 +670,10 @@ void ami_openscreen(void)
if (nsoption_charp(use_pubscreen) == NULL)
{
- if((nsoption_charp(modeid)) &&
- (strncmp(nsoption_charp(modeid), "0x", 2) == 0))
+ if((nsoption_charp(screen_modeid)) &&
+ (strncmp(nsoption_charp(screen_modeid), "0x", 2) == 0))
{
- id = strtoul(nsoption_charp(modeid), NULL, 0);
+ id = strtoul(nsoption_charp(screen_modeid), NULL, 0);
}
else
{
@@ -687,8 +689,8 @@ void ami_openscreen(void)
char *modeid = malloc(20);
id = screenmodereq->sm_DisplayID;
sprintf(modeid, "0x%lx", id);
- nsoption_set_charp(modeid, modeid);
- nsoption_write(current_user_options);
+ nsoption_set_charp(screen_modeid, modeid);
+ nsoption_write(current_user_options, NULL, NULL);
}
FreeAslRequest(screenmodereq);
}
@@ -3196,7 +3198,7 @@ struct gui_window *gui_create_browser_window(struct browser_window *bw,
CLICKTAB_Labels, &g->shared->tab_list,
TAG_DONE);
- if(nsoption_bool(new_tab_active))
+ if(nsoption_bool(new_tab_is_active))
{
RefreshSetGadgetAttrs((struct Gadget *)g->shared->objects[GID_TABS],g->shared->win,NULL,
CLICKTAB_Current,g->tab,
@@ -3209,7 +3211,7 @@ struct gui_window *gui_create_browser_window(struct browser_window *bw,
g->shared->tabs++;
g->shared->next_tab++;
- if(nsoption_bool(new_tab_active)) ami_switch_tab(g->shared,false);
+ if(nsoption_bool(new_tab_is_active)) ami_switch_tab(g->shared,false);
ami_update_buttons(g->shared);
diff --git a/amiga/gui_options.c b/amiga/gui_options.c
index 102036ded..16d6fc1f5 100755
--- a/amiga/gui_options.c
+++ b/amiga/gui_options.c
@@ -435,9 +435,10 @@ void ami_gui_opts_open(void)
screennamedisabled = TRUE;
}
- if((nsoption_charp(modeid)) && (strncmp(nsoption_charp(modeid),"0x",2) == 0))
+ if((nsoption_charp(screen_modeid)) &&
+ (strncmp(nsoption_charp(screen_modeid),"0x",2) == 0))
{
- screenmodeid = strtoul(nsoption_charp(modeid),NULL,0);
+ screenmodeid = strtoul(nsoption_charp(screen_modeid),NULL,0);
}
if(nsoption_bool(http_proxy))
@@ -743,7 +744,7 @@ void ami_gui_opts_open(void)
GA_ID, GID_OPTS_PTROS,
GA_RelVerify, TRUE,
GA_Text, gadlab[GID_OPTS_PTROS],
- GA_Selected, nsoption_bool(use_os_pointers),
+ GA_Selected, nsoption_bool(os_mouse_pointers),
CheckBoxEnd,
LayoutEnd, // mouse
CHILD_WeightedHeight,0,
@@ -1163,7 +1164,7 @@ void ami_gui_opts_open(void)
GA_ID, GID_OPTS_TAB_ACTIVE,
GA_RelVerify, TRUE,
GA_Text, gadlab[GID_OPTS_TAB_ACTIVE],
- GA_Selected, !nsoption_bool(new_tab_active),
+ GA_Selected, !nsoption_bool(new_tab_is_active),
CheckBoxEnd,
LAYOUT_AddChild, gow->objects[GID_OPTS_TAB_LAST] = CheckBoxObject,
GA_ID, GID_OPTS_TAB_LAST,
@@ -1274,7 +1275,7 @@ void ami_gui_opts_open(void)
GA_ID, GID_OPTS_CLIPBOARD,
GA_RelVerify, TRUE,
GA_Text, gadlab[GID_OPTS_CLIPBOARD],
- GA_Selected, nsoption_bool(utf8_clipboard),
+ GA_Selected, nsoption_bool(clipboard_write_utf8),
CheckBoxEnd,
LayoutEnd, // clipboard
CHILD_WeightedHeight, 0,
@@ -1590,7 +1591,7 @@ void ami_gui_opts_use(bool save)
{
char *modeid = malloc(20);
sprintf(modeid,"0x%lx", id);
- nsoption_set_charp(modeid, modeid);
+ nsoption_set_charp(screen_modeid, modeid);
}
GetAttr(GA_Selected,gow->objects[GID_OPTS_WIN_SIMPLE],(ULONG *)&data);
@@ -1614,9 +1615,9 @@ void ami_gui_opts_use(bool save)
GetAttr(GA_Selected,gow->objects[GID_OPTS_PTROS],(ULONG *)&data);
if (data) {
- nsoption_set_bool(use_os_pointers, true);
+ nsoption_set_bool(os_mouse_pointers, true);
} else {
- nsoption_set_bool(use_os_pointers, false);
+ nsoption_set_bool(os_mouse_pointers, false);
}
GetAttr(CHOOSER_Selected,gow->objects[GID_OPTS_PROXY],(ULONG *)&data);
@@ -1667,7 +1668,7 @@ void ami_gui_opts_use(bool save)
nsoption_set_bool(animate_images, true);
}
- GetAttr(INTEGER_Number,gow->objects[GID_OPTS_DPI_Y],(ULONG *)&nsoption_int(amiga_ydpi));
+ GetAttr(INTEGER_Number,gow->objects[GID_OPTS_DPI_Y],(ULONG *)&nsoption_int(screen_ydpi));
ami_font_setdevicedpi(id); // id set above
GetAttr(GETFONT_TextAttr,gow->objects[GID_OPTS_FONT_SANS],(ULONG *)&data);
@@ -1740,9 +1741,9 @@ void ami_gui_opts_use(bool save)
GetAttr(GA_Selected,gow->objects[GID_OPTS_TAB_ACTIVE],(ULONG *)&data);
if (data) {
- nsoption_set_bool(new_tab_active, false);
+ nsoption_set_bool(new_tab_is_active, false);
} else {
- nsoption_set_bool(new_tab_active, true);
+ nsoption_set_bool(new_tab_is_active, true);
}
GetAttr(GA_Selected,gow->objects[GID_OPTS_TAB_LAST],(ULONG *)&data);
@@ -1784,9 +1785,9 @@ void ami_gui_opts_use(bool save)
GetAttr(GA_Selected,gow->objects[GID_OPTS_CLIPBOARD],(ULONG *)&data);
if (data) {
- nsoption_set_bool(utf8_clipboard, true);
+ nsoption_set_bool(clipboard_write_utf8, true);
} else {
- nsoption_set_bool(utf8_clipboard, false);
+ nsoption_set_bool(clipboard_write_utf8, false);
}
GetAttr(GA_Selected,gow->objects[GID_OPTS_CONTEXTMENU],(ULONG *)&data);
@@ -1868,7 +1869,7 @@ void ami_gui_opts_use(bool save)
}
if(save == true) {
- nsoption_write(current_user_options);
+ nsoption_write(current_user_options, NULL, NULL);
ami_font_savescanner(); /* just in case it has changed and been used only */
}
diff --git a/amiga/menu.c b/amiga/menu.c
index c7c3c4671..5cd7e6aa0 100644
--- a/amiga/menu.c
+++ b/amiga/menu.c
@@ -953,7 +953,7 @@ static void ami_menu_item_settings_snapshot(struct Hook *hook, APTR window, stru
static void ami_menu_item_settings_save(struct Hook *hook, APTR window, struct IntuiMessage *msg)
{
- nsoption_write(current_user_options);
+ nsoption_write(current_user_options, NULL, NULL);
}
static void ami_menu_item_arexx_execute(struct Hook *hook, APTR window, struct IntuiMessage *msg)
diff --git a/amiga/theme.c b/amiga/theme.c
index ca5e2b622..a0755b23a 100644
--- a/amiga/theme.c
+++ b/amiga/theme.c
@@ -193,7 +193,7 @@ void ami_update_pointer(struct Window *win, gui_pointer_shape shape)
{
if(drag_save_data) return;
- if(nsoption_bool(use_os_pointers))
+ if(nsoption_bool(os_mouse_pointers))
{
switch(shape)
{