Netsurf


scachi

Member
Joined
Dec 28, 2005
Messages
451
Hi,

here is a first port of netsurf for testing.
Onscreen keyboard is available in the lower-right corner (tiny keyboard image).
You have to click first in the input field where the input should appear before inserting text.
That's buggy atm as the inserted text is not visible .. but it works.
 
THANKS!!! GUY THANKS!! :D :D :D :D :D :D :D :D :D :D :D :D :D :D :D
i will try it immediately!!!!
thanks you!
ps: can you host this test on another file sharing site? i have problems with uploaded ;)
EIDT2: i tested it, so i found a lot of problems:
first: when you tap on the onscreen keyboard you don't see what you are writing;
second: it don't display the images, but i think you can't do anything, is the browser directely ;)
third: can you use too the caanoo controls like the ABYX bottons or the analogic stick? will be more easy to manage the web pages: for help i think in caanoo browser from rikku2000 will be some trick to enamble them ;) http://dl.openhandhelds.org/cgi-bin/caanoo.cgi?0,0,0,0,112,509
 
kayuz said:
THANKS!!! GUY THANKS!! :D :D :D :D :D :D :D :D :D :D :D :D :D :D :D
i will try it immediately!!!!
thanks you!
ps: can you host this test on another file sharing site? i have problems with uploaded ;)
EIDT2: i tested it, so i found a lot of problems:
first: when you tap on the onscreen keyboard you don't see what you are writing;
second: it don't display the images, but i think you can't do anything, is the browser directely ;)
third: can you use too the caanoo controls like the ABYX bottons or the analogic stick? will be more easy to manage the web pages: for help i think in caanoo browser from rikku2000 will be some trick to enamble them ;) http://dl.openhandhelds.org/cgi-bin/caanoo.cgi?0,0,0,0,112,509
Thx for testing and reporting + link.
Can you recommend another free file sharing site ?

I'll try to fix all the problems in the next few days.
 
Last edited by a moderator:
Yeah, surfing the net with the analog stick would be awesome. Well, i'm trying this browser on my arch installation (on pc) and the images are loading. This seems to be a great browser on pc, I haven't tested it yet on the caanoo.
Great idea, man!
=)
 
You can use OpenHandhelds and write in the description that is a alpha, or use megaupload or (the simplest way) you can attach the file to the post! =)
Roberto.
 
no no no, use mediafire, no wait for donwload and easy upload ;)
thanks you so much for listened my report, hope to see all fixed :D

EDIT: i add in wikipedia that Netsurf is avaible on the caanoo.
second i host your test on mediafire ;) http://www.mediafire.com/?4b5vtdnrir3bbxf
 
when the browser is 100% fixed you must upload to OpenHandeld.org (there are some time problem to upgrade a release in a new version)
at all thanx for port :)
 
Hi,

test2 is available.
Images should be working and entered text is visible now too.

No caanoo button control is supported at the moment..it will be added with my next test release.
 
NEW UPDATE! tHANKS A LOT!! :D :D :D :D
i wait spasmodly the next test ;)
thanks scachi ;)
EDIT.
so, i try it and there are my suggestions for the next version:
- add some more features.. like Favorites.. i don't know if there are already enambled in the original browser.
- is impossible to enamble flash or javascrips...(i don't want anything ;)
- and naturally the CAANOO controls

anway great work, guy ;)
 
I tested for about half hour yesterday and the browser is VERY promising! The sites show your pictures and frames correctly. Obviously needs a little work but, for you Scachi... congratulations!!! THANK YOU! :D

Keep working... the way it is is already the best browser for Caanoo. :)

Luo=-_
 
If you want and you can add it:
UT7ZdH5L1Fd3.png

q586Niy41Zmc.png

The code is not the best way but it works for me.

Code:
Code:
SDL_Joystick *joy;

/* Virtual Keyboard Init */
int virtual_keyboard_open; // If its 1 then open the Virtual Keyboard
int virtual_keyboard_shift = 0; // If its 1 then use the SHIFT keys

int virtual_keyboard_init;
int virtual_keyboard_x = 51;
int virtual_keyboard_y = 147;

const SDLKey virtual_keyboard_array1[] = {
	SDLK_q, SDLK_w, SDLK_e, SDLK_r, SDLK_t, SDLK_y, SDLK_u, SDLK_i, SDLK_o, SDLK_p,
	SDLK_a, SDLK_s, SDLK_d, SDLK_f, SDLK_g, SDLK_h, SDLK_j, SDLK_k, SDLK_l, SDLK_COMMA,
	SDLK_z, SDLK_x, SDLK_c, SDLK_v, SDLK_b, SDLK_n, SDLK_m, SDLK_PERIOD, SDLK_BACKSPACE, SDLK_RETURN
};

const SDLKey virtual_keyboard_array2[] = {
	SDLK_1, SDLK_2, SDLK_3, SDLK_4, SDLK_5, SDLK_6, SDLK_7, SDLK_8, SDLK_9, SDLK_0,
	SDLK_HASH, SDLK_SEMICOLON, SDLK_PLUS, SDLK_ASTERISK, SDLK_DOLLAR, SDLK_CARET, SDLK_EQUALS, SDLK_QUOTEDBL, SDLK_BACKSLASH, SDLK_AMPERSAND,
	SDLK_QUOTEDBL, SDLK_EXCLAIM, SDLK_QUESTION, SDLK_SLASH, SDLK_MINUS, SDLK_UNDERSCORE, SDLK_COLON, SDLK_AT, SDLK_BACKSPACE, SDLK_RETURN
};

void push_key( SDLKey key ) {
	SDL_Event e;

	memset(&e.key.keysym, 0, sizeof(e.key.keysym));

	e.key.keysym.sym = key;
	e.key.keysym.unicode = key;

	e.key.state = SDL_RELEASED;

	e.type = SDL_KEYDOWN;
	SDL_PushEvent(&e);

	e.type = SDL_KEYUP;
	SDL_PushEvent(&e);
}

int o_x, o_y; // Virtual Mouse

Code:
joy = SDL_JoystickOpen(0);

	  case SDL_JOYAXISMOTION:
		  if (virtual_keyboard_open == 0)
			  if (SDL_JoystickGetAxis(joy, 1) < -16384) {
				  push_key(SDLK_UP);
			  } else if (SDL_JoystickGetAxis(joy, 0) < -16384) {
				  push_key(SDLK_LEFT);
			  } else if (SDL_JoystickGetAxis(joy, 1) >  16384) {
				  push_key(SDLK_DOWN);
			  } else if (SDL_JoystickGetAxis(joy, 0) >  16384) {
				  push_key(SDLK_RIGHT);
			  }
			  break;

	  case SDL_JOYBUTTONDOWN:
		  if(SDL_JoystickGetButton(joy, 0)) {
			  push_key(SDLK_RETURN);
		  } else if(SDL_JoystickGetButton(joy, 1)) {
		  } else if(SDL_JoystickGetButton(joy, 2)) {
		  } else if(SDL_JoystickGetButton(joy, 3)) {
			  push_key(SDLK_t);
		  } else if(SDL_JoystickGetButton(joy, 4)) {
		  } else if(SDL_JoystickGetButton(joy, 5)) {
		  } else if(SDL_JoystickGetButton(joy, 6)) {
			  if (virtual_keyboard_open == 0)
				  push_key(SDLK_ESCAPE);
		  } else if(SDL_JoystickGetButton(joy, 7)) {
		  } else if(SDL_JoystickGetButton(joy, 8)) {
			  if (virtual_keyboard_open == 0) {
				  virtual_keyboard_open = 1;
				  virtual_keyboard_shift = 0;
			  } else if (virtual_keyboard_open == 1)
				  virtual_keyboard_open = 0;
		  } else if(SDL_JoystickGetButton(joy, 9)) {
			  if (virtual_keyboard_open == 1)
				  if (virtual_keyboard_shift == 0)
					  virtual_keyboard_shift = 1;
				  else if (virtual_keyboard_shift == 1)
					  virtual_keyboard_shift = 0;
		  } else if(SDL_JoystickGetButton(joy, 10)) {
		  }
		  break;

	  case SDL_JOYBUTTONUP:
		  break;

	  case SDL_MOUSEBUTTONDOWN:
		  if (virtual_keyboard_open == 0) {
		  } else if (virtual_keyboard_open == 1) {
			  for(virtual_keyboard_init = 0; virtual_keyboard_init < 29; virtual_keyboard_init++) {
				  if (virtual_keyboard_shift == 0) {
					  if (o_x + (10) > virtual_keyboard_x && o_x < virtual_keyboard_x + (10) && o_y + (16) > virtual_keyboard_y && o_y < virtual_keyboard_y + (16))
						  push_key(virtual_keyboard_array1[virtual_keyboard_init]);
				  } else if (virtual_keyboard_shift == 1) {
					  if (o_x + (10) > virtual_keyboard_x && o_x < virtual_keyboard_x + (10) && o_y + (16) > virtual_keyboard_y && o_y < virtual_keyboard_y + (16))
						  push_key(virtual_keyboard_array2[virtual_keyboard_init]);
				  }

				  virtual_keyboard_x += 24;

				  if (virtual_keyboard_x == 291) {
					  virtual_keyboard_y += 37;
					  virtual_keyboard_x = 51;
				  }
			  }
		  }
		  break;

      case SDL_MOUSEBUTTONUP:
		  if (virtual_keyboard_open == 0) {
		  } else if (virtual_keyboard_open == 1) { // Set Virtual Keyboard default
			  virtual_keyboard_x = 51; virtual_keyboard_y = 147;
		  }
          break;

      case SDL_MOUSEMOTION:
		  if (virtual_keyboard_open == 0) {
		  } else if (virtual_keyboard_open == 1) {
			  o_x = event.motion.x;
			  o_y = event.motion.y;
		  }
          break;
 
Thank you Rikku for your example.
Netsurf has already an on screen keyboard builtin.

I am working on adding joystick input handling to netsurfs libnsfb as this seems to be the place where all other input events and frontend specific (SDL in this case) functions are located.
A missing "@" will be added to the keyboard.

If everything is done and working I can try to compile it for the wiz or someone else might give it a try then. Don't know if it would be fun to use it on its small screen.
 
thanks a lot scachi, good job! :D
i can't wait for the next version ;)
 
Back
Top