summaryrefslogtreecommitdiff
path: root/amiga/arexx.c
diff options
context:
space:
mode:
authorVincent Sanders <vince@kyllikki.org>2014-10-16 09:55:01 +0100
committerVincent Sanders <vince@kyllikki.org>2014-10-16 22:33:44 +0100
commit0b64df140c87c81d5046c0a97b5a655ca7af170b (patch)
tree3e0e1d5038e2b8d27f859d22c1c3f2205363d2c7 /amiga/arexx.c
parent3b4dea6241a09f745f7c4c54c302e6b4a0052680 (diff)
downloadnetsurf-0b64df140c87c81d5046c0a97b5a655ca7af170b.tar.gz
netsurf-0b64df140c87c81d5046c0a97b5a655ca7af170b.tar.bz2
Update amiga frontend for split operation table header changes
Diffstat (limited to 'amiga/arexx.c')
-rw-r--r--amiga/arexx.c50
1 files changed, 24 insertions, 26 deletions
diff --git a/amiga/arexx.c b/amiga/arexx.c
index 4130dbb6d..7a367e893 100644
--- a/amiga/arexx.c
+++ b/amiga/arexx.c
@@ -16,17 +16,6 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#include "amiga/os3support.h"
-
-#include "amiga/arexx.h"
-#include "amiga/download.h"
-#include "amiga/gui.h"
-#include "amiga/hotlist.h"
-#include "amiga/theme.h"
-#include "utils/nsoption.h"
-
-#include "desktop/browser_private.h"
-#include "desktop/version.h"
#include <string.h>
#include <math.h>
@@ -38,11 +27,20 @@
#include <gadgets/clicktab.h>
#include <reaction/reaction_macros.h>
+#include "utils/nsoption.h"
+#include "desktop/browser_private.h"
+#include "desktop/gui_window.h"
+#include "desktop/version.h"
+
+#include "amiga/os3support.h"
+#include "amiga/arexx.h"
+#include "amiga/download.h"
+#include "amiga/gui.h"
+#include "amiga/hotlist.h"
+#include "amiga/theme.h"
+
extern const char * const verarexx;
-extern const char * const netsurf_version;
extern const char * const wt_revid;
-extern const int netsurf_version_major;
-extern const int netsurf_version_minor;
enum
{
@@ -106,13 +104,13 @@ STATIC struct ARexxCmd Commands[] =
BOOL ami_arexx_init(void)
{
- if(arexx_obj = ARexxObject,
+ if((arexx_obj = ARexxObject,
AREXX_HostName,"NETSURF",
AREXX_Commands,Commands,
AREXX_NoSlot,TRUE,
AREXX_ReplyHook,NULL,
AREXX_DefExtension,"nsrx",
- End)
+ End))
{
GetAttr(AREXX_SigMask, arexx_obj, &rxsig);
return true;
@@ -147,7 +145,7 @@ void ami_arexx_cleanup(void)
if(arexx_obj) DisposeObject(arexx_obj);
}
-struct browser_window *ami_find_tab_gwin(struct gui_window_2 *gwin, int tab)
+static struct browser_window *ami_find_tab_gwin(struct gui_window_2 *gwin, int tab)
{
int tabs = 0;
struct Node *ctab;
@@ -166,12 +164,12 @@ struct browser_window *ami_find_tab_gwin(struct gui_window_2 *gwin, int tab)
TNA_UserData, &bw,
TAG_DONE);
if(tabs == tab) return bw;
- } while(ctab=ntab);
+ } while((ctab=ntab));
return NULL;
}
-int ami_find_tab_bw(struct gui_window_2 *gwin, struct browser_window *bw)
+static int ami_find_tab_bw(struct gui_window_2 *gwin, struct browser_window *bw)
{
int tabs = 0;
struct Node *ctab;
@@ -190,12 +188,12 @@ int ami_find_tab_bw(struct gui_window_2 *gwin, struct browser_window *bw)
TNA_UserData, &tbw,
TAG_DONE);
if(tbw == bw) return tabs;
- } while(ctab=ntab);
+ } while((ctab=ntab));
return 0;
}
-struct browser_window *ami_find_tab(int window, int tab)
+static struct browser_window *ami_find_tab(int window, int tab)
{
struct nsObject *node, *nnode;
@@ -215,7 +213,7 @@ struct browser_window *ami_find_tab(int window, int tab)
if(windows == window)
return ami_find_tab_gwin(node->objstruct, tab);
}
- } while(node = nnode);
+ } while((node = nnode));
}
return NULL;
}
@@ -563,8 +561,8 @@ STATIC VOID rx_windows(struct ARexxCmd *cmd, struct RexxMsg *rxm __attribute__((
} while(node = nnode);
}
- if(cmd->ac_ArgList[0]) sprintf(result, "%ld", tabs);
- else sprintf(result, "%ld", windows);
+ if(cmd->ac_ArgList[0]) sprintf(result, "%d", tabs);
+ else sprintf(result, "%d", windows);
cmd->ac_Result = result;
}
@@ -606,8 +604,8 @@ STATIC VOID rx_active(struct ARexxCmd *cmd, struct RexxMsg *rxm __attribute__((u
tab = ami_find_tab_bw(gwin, bw);
}
- if(cmd->ac_ArgList[0]) sprintf(result, "%ld", tab);
- else sprintf(result, "%ld", window);
+ if(cmd->ac_ArgList[0]) sprintf(result, "%d", tab);
+ else sprintf(result, "%d", window);
cmd->ac_Result = result;
}