Author: remi
Date: 2008-12-02 13:55:45 +0100 (Tue, 02 Dec 2008)
New Revision: 2984

Removed:
   
software_suite_v2/software/http_server_resources/chatter_tux/trunk/ChatterTux/Check.pas
Log:
* removed an unused file

Deleted: 
software_suite_v2/software/http_server_resources/chatter_tux/trunk/ChatterTux/Check.pas
===================================================================
--- 
software_suite_v2/software/http_server_resources/chatter_tux/trunk/ChatterTux/Check.pas
     2008-12-02 12:55:20 UTC (rev 2983)
+++ 
software_suite_v2/software/http_server_resources/chatter_tux/trunk/ChatterTux/Check.pas
     2008-12-02 12:55:45 UTC (rev 2984)
@@ -1,63 +0,0 @@
-unit Check;
-
-interface
-
-Function CheckConnection : Boolean;
-Function CheckIPConnection(Name: String; var IP: String): Boolean;
-
-implementation
-
-Uses WinINet, WinSock, SysUtils, Types;
-
-Function CheckConnection : Boolean;
-Const
- // local system uses a modem to connect to the Internet.
- INTERNET_CONNECTION_MODEM      = 1;
- // local system uses a local area network to connect to the Internet.
- INTERNET_CONNECTION_LAN        = 2;
- // local system uses a proxy server to connect to the Internet.
- INTERNET_CONNECTION_PROXY      = 4;
- // local system's modem is busy with a non-Internet connection.
- INTERNET_CONNECTION_MODEM_BUSY = 8;
-Var
- dwConnectionTypes : DWORD;
-Begin
- dwConnectionTypes := INTERNET_CONNECTION_MODEM + INTERNET_CONNECTION_LAN + 
INTERNET_CONNECTION_PROXY;
- Result := InternetGetConnectedState(@dwConnectionTypes,0);
-End;
-
-// CheckIPConnection('www.whatever.com' IP);
-Function CheckIPConnection(Name: String; var IP: String): Boolean;
-var wsdata : TWSAData;
- hostName : array [0..255] of char;
- hostEnt : PHostEnt;
- addr : PChar;
-begin
- WSAStartup ($0101, wsdata);
- try
-   gethostname (hostName, sizeof (hostName));
-   StrPCopy(hostName, Name);
-   hostEnt := gethostbyname (hostName); // Hier is de vertraging...
-   if Assigned (hostEnt) then
-     if Assigned (hostEnt^.h_addr_list) then begin
-       addr := hostEnt^.h_addr_list^;
-       if Assigned (addr) then begin
-         IP := Format ('%d.%d.%d.%d', [byte (addr [0]),
-         byte (addr [1]), byte (addr [2]), byte (addr [3])]);
-         Result := True;
-       end
-       else
-         Result := False;
-     end
-     else
-       Result := False
-   else begin
-     Result := False;
-   end;
- finally
-   WSACleanup;
- end
-end;
-
-end.
- 
\ No newline at end of file


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Tux-droid-svn mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tux-droid-svn

Reply via email to