prepared cext_array_* removal in libixp

This commit is contained in:
Anselm R. Garbe 2006-04-03 15:52:05 +02:00
parent 2dee3984ea
commit 41f9a57ba6
12 changed files with 21 additions and 79 deletions

View File

@ -7,8 +7,8 @@
#include <X11/Xlib.h>
#include <X11/Xutil.h>
#include "ixp.h"
#include "blitz.h"
#include <ixp.h>
#include <blitz.h>
/* WM atoms */
enum {
@ -73,8 +73,7 @@ typedef struct Area Area;
typedef struct Frame Frame;
typedef struct Client Client;
EVECTOR(AreaVector, Area *);
VECTOR(AreaVector, Area *);
struct View {
char tag[MAX_TAGS][MAX_TAGLEN];
unsigned int ntag;
@ -84,8 +83,7 @@ struct View {
unsigned int revert;
};
EVECTOR(FrameVector, Frame *);
VECTOR(FrameVector, Frame *);
struct Area {
unsigned short id;
FrameVector frame;
@ -158,20 +156,20 @@ typedef struct {
} Default;
/* global variables */
EVECTOR(ViewVector, View *);
VECTOR(ViewVector, View *);
ViewVector view;
unsigned int sel;
EVECTOR(ClientVector, Client *);
VECTOR(ClientVector, Client *);
ClientVector client;
EVECTOR(KeyVector, Key *);
VECTOR(KeyVector, Key *);
KeyVector key;
EVECTOR(LabelVector, Label *);
VECTOR(LabelVector, Label *);
LabelVector label;
EVECTOR(TagVector, char *);
VECTOR(TagVector, char *);
TagVector tag;
Display *dpy;

View File

@ -17,7 +17,8 @@
#include <X11/Xutil.h>
#include <X11/keysym.h>
#include "blitz.h"
#include <blitz.h>
#include <cext.h>
static Bool done = False;
static int ret = 0;
@ -30,7 +31,7 @@ static Window win;
static XRectangle mrect;
static int screen;
EVECTOR(ItemVector, char *);
VECTOR(ItemVector, char *);
static ItemVector allitem = {0};
static ItemVector item = {0};

View File

@ -11,7 +11,6 @@
#include <time.h>
#include <ixp.h>
#include <cext.h>
static IXPClient c = { 0 };

View File

@ -33,13 +33,13 @@ long long cext_strtonum(const char *numstr, long long minval,
unsigned int cext_tokenize(char **result, unsigned int reslen, char *str, char delim);
/* vector.c */
#define EVECTOR(name, type) \
#define VECTOR(name, type) \
typedef struct { \
unsigned int size; \
type *data; \
} name
EVECTOR(Vector, void*);
VECTOR(Vector, void*);
void cext_vattach(Vector *v, void *p);
void cext_vdetach(Vector *v, void *p);

View File

@ -10,7 +10,6 @@
#include <sys/types.h>
#include <unistd.h>
#include "cext.h"
#include "ixp.h"
int

View File

@ -4,10 +4,7 @@
*/
#include <sys/types.h>
#ifndef nil
#define nil 0
#endif
#include <cext.h>
#define IXP_VERSION "9P2000"
#define IXP_MAX_VERSION 32
@ -17,62 +14,12 @@
#define IXP_MAX_FLEN 128
#define IXP_MAX_ULEN 32
#define IXP_MAX_STAT 64
#define IXP_MAX_WELEM 16 /*MAXWELEM */
#define IXP_MAX_WELEM 16 /* MAXWELEM */
#define IXP_MAX_TFUNCS 14
#define IXP_PORT 564
#define IXP_PORT 5640
/*
size[4] Tversion tag[2] msize[4] version[s]
size[4] Rversion tag[2] msize[4] version[s]
size[4] Tauth tag[2] afid[4] uname[s] aname[s]
size[4] Rauth tag[2] aqid[13]
size[4] Rerror tag[2] ename[s]
size[4] Tflush tag[2] oldtag[2]
size[4] Rflush tag[2]
size[4] Tattach tag[2] fid[4] afid[4] uname[s] aname[s]
size[4] Rattach tag[2] qid[13]
size[4] Twalk tag[2] fid[4] newfid[4] nwname[2] nwname*(wname[s])
size[4] Rwalk tag[2] nwqid[2] nwqid*(wqid[13])
size[4] Topen tag[2] fid[4] mode[1]
size[4] Ropen tag[2] qid[13] iounit[4]
size[4] Tcreate tag[2] fid[4] name[s] perm[4] mode[1]
size[4] Rcreate tag[2] qid[13] iounit[4]
size[4] Tread tag[2] fid[4] offset[8] count[4]
size[4] Rread tag[2] count[4] data[count]
size[4] Twrite tag[2] fid[4] offset[8] count[4] data[count]
size[4] Rwrite tag[2] count[4]
size[4] Tclunk tag[2] fid[4]
size[4] Rclunk tag[2]
size[4] Tremove tag[2] fid[4]
size[4] Rremove tag[2]
size[4] Tstat tag[2] fid[4]
size[4] Rstat tag[2] stat[n]
size[4] Twstat tag[2] fid[4] stat[n]
size[4] Rwstat tag[2]
stat[n]:
size[2] total byte count of the following data
type[2] for kernel use
dev[4] for kernel use
qid.type[1] the type of the file (directory, etc.),
represented as a bit vector corresponding to the high 8
bits of the file's mode word.
qid.vers[4] version number for given path
qid.path[8] the file server's unique identification for the file
mode[4] permissions and flags
atime[4] last access time
mtime[4] last modification time
length[8] length of file in bytes
name[ s ] file name; must be / if the file is the root directory of
the server
uid[ s ] owner name
gid[ s ] group name
muid[ s ]
*/
/*9P message types */
/* 9P message types */
enum {
TVERSION = 100,
RVERSION,

View File

@ -15,7 +15,6 @@
#include <unistd.h>
#include "ixp.h"
#include "cext.h"
static unsigned char *msg[IXP_MAX_MSG];

View File

@ -15,7 +15,6 @@
#include <sys/un.h>
#include <unistd.h>
#include "cext.h"
#include "ixp.h"
static int

View File

@ -15,8 +15,6 @@
#include "ixp.h"
#include <cext.h>
unsigned int
ixp_send_message(int fd, void *msg, unsigned int msize, char **errstr)
{

View File

@ -4,7 +4,6 @@
*/
#include <X11/Xlib.h>
#include <cext.h>
#define BLITZ_FONT "fixed"
#define BLITZ_SELCOLORS "#ffffff #285577 #4c7899"

View File

@ -5,6 +5,8 @@
#include <stdio.h>
#include <string.h>
#include <cext.h>
#include "blitz.h"
XFontStruct *

View File

@ -6,6 +6,7 @@
#include <math.h>
#include <string.h>
#include <stdlib.h>
#include <cext.h>
#include "blitz.h"