mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-07-11 22:03:01 -06:00
CtrlCore: debug mode _DBG_Ungrab for X11
git-svn-id: svn://ultimatepp.org/upp/trunk@4963 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
5b1cbd50ec
commit
3135cd0bf8
3 changed files with 15 additions and 0 deletions
|
|
@ -37,6 +37,7 @@ void HttpRequest::Init()
|
|||
chunk = 4096;
|
||||
timeout = 120000;
|
||||
ssl = false;
|
||||
cookies = false;
|
||||
}
|
||||
|
||||
HttpRequest::HttpRequest()
|
||||
|
|
@ -658,6 +659,8 @@ void HttpRequest::Finish()
|
|||
#endif
|
||||
}
|
||||
Close();
|
||||
if(cookies)
|
||||
CopyCookies();
|
||||
if(status_code == 401 && !IsNull(username)) {
|
||||
String authenticate = header["www-authenticate"];
|
||||
if(authenticate.GetCount() && redirect_count++ < max_redirects) {
|
||||
|
|
|
|||
|
|
@ -310,6 +310,7 @@ class HttpRequest : public TcpSocket {
|
|||
String digest;
|
||||
String request_headers;
|
||||
String postdata;
|
||||
bool cookies;
|
||||
|
||||
String protocol;
|
||||
int status_code;
|
||||
|
|
@ -389,6 +390,8 @@ public:
|
|||
HttpRequest& AddHeaders(const String& h) { request_headers.Cat(h); return *this; }
|
||||
HttpRequest& Header(const char *id, const String& data);
|
||||
HttpRequest& Cookie(const String& cookie) { return Header("Cookie", cookie); }
|
||||
|
||||
HttpRequest& Cookies(bool b = true) { cookies = b; }
|
||||
|
||||
HttpRequest& StdHeaders(bool sh) { std_headers = sh; return *this; }
|
||||
HttpRequest& NoStdHeaders() { return StdHeaders(false); }
|
||||
|
|
|
|||
|
|
@ -522,6 +522,15 @@ int Ctrl::GetKbdSpeed()
|
|||
return 25;
|
||||
}
|
||||
|
||||
|
||||
#ifdef _DEBUG
|
||||
void _DBG_Ungrab(void) {
|
||||
XUngrabPointer(Xdisplay, CurrentTime);
|
||||
XUngrabKeyboard(Xdisplay, CurrentTime);
|
||||
XFlush(Xdisplay);
|
||||
}
|
||||
#endif
|
||||
|
||||
END_UPP_NAMESPACE
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue