mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-05-21 06:45:39 -06:00
PGSQL: Autoreconnect improvement
git-svn-id: svn://ultimatepp.org/upp/trunk@2699 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
540202ebc3
commit
12ca84d0b6
6 changed files with 17 additions and 15 deletions
|
|
@ -91,21 +91,23 @@ of type derived from T.&]
|
||||||
element.&]
|
element.&]
|
||||||
[s3;%- &]
|
[s3;%- &]
|
||||||
[s4;%- &]
|
[s4;%- &]
|
||||||
[s5;:Array`:`:Add`(const T`&`):%- [@(0.0.255) void]_[* Add]([@(0.0.255) const]_[*@4 T][@(0.0.255) `&
|
[s5;:Array`:`:Add`(const T`&`):%- [*@4 T][@(0.0.255) `&]_[* Add]([@(0.0.255) const]_[*@4 T][@(0.0.255) `&
|
||||||
]_[*@3 x])&]
|
]_[*@3 x])&]
|
||||||
[s2; Adds a new element with specified value to the Array.&]
|
[s2; Adds a new element with specified value to the Array.&]
|
||||||
[s6; Requires T to have deep copy constructor.&]
|
[s6; Requires T to have deep copy constructor.&]
|
||||||
[s6; Invalidates iterators to the Array.&]
|
[s6; Invalidates iterators to the Array.&]
|
||||||
[s7; [*C@3 x]-|The value that is copied to newly created element.&]
|
[s7; [*C@3 x]-|The value that is copied to newly created element.&]
|
||||||
|
[s7; [*/ Return value]-|Reference to new element in Array.&]
|
||||||
[s3;%- &]
|
[s3;%- &]
|
||||||
[s4;%- &]
|
[s4;%- &]
|
||||||
[s5;:Array`:`:AddPick`(pick`_ T`&`):%- [@(0.0.255) void]_[* AddPick]([@(0.128.128) pick`_]_
|
[s5;:Array`:`:AddPick`(pick`_ T`&`):%- [*@4 T][@(0.0.255) `&]_[* AddPick]([@(0.128.128) pick`_
|
||||||
[*@4 T][@(0.0.255) `&]_[*@3 x])&]
|
]_[*@4 T][@(0.0.255) `&]_[*@3 x])&]
|
||||||
[s2; Adds new element to the Array and picks value of parameter to
|
[s2; Adds new element to the Array and picks value of parameter to
|
||||||
it. &]
|
it. &]
|
||||||
[s6; Requires T to have pick constructor.&]
|
[s6; Requires T to have pick constructor.&]
|
||||||
[s6; Invalidates iterators to the Array.&]
|
[s6; Invalidates iterators to the Array.&]
|
||||||
[s7; [*C@3 x]-|Source instance of T that is to be picked.&]
|
[s7; [*C@3 x]-|Source instance of T that is to be picked.&]
|
||||||
|
[s7; [*/ Return value]-|Reference to new element in Array.&]
|
||||||
[s3;%- &]
|
[s3;%- &]
|
||||||
[s4;%- &]
|
[s4;%- &]
|
||||||
[s5;:Array`:`:Add`(T`*`):%- [*@4 T][@(0.0.255) `&]_[* Add]([*@4 T]_`*[*@3 newt])&]
|
[s5;:Array`:`:Add`(T`*`):%- [*@4 T][@(0.0.255) `&]_[* Add]([*@4 T]_`*[*@3 newt])&]
|
||||||
|
|
|
||||||
|
|
@ -76,21 +76,23 @@ constructor.&]
|
||||||
element.&]
|
element.&]
|
||||||
[s3;%- &]
|
[s3;%- &]
|
||||||
[s4;%- &]
|
[s4;%- &]
|
||||||
[s5;:Vector`:`:Add`(const T`&`):%- [@(0.0.255) void]_[* Add]([@(0.0.255) const]_[*@4 T][@(0.0.255) `&
|
[s5;:Vector`:`:Add`(const T`&`):%- [*@4 T][@(0.0.255) `&]_[* Add]([@(0.0.255) const]_[*@4 T][@(0.0.255) `&
|
||||||
]_[*@3 x])&]
|
]_[*@3 x])&]
|
||||||
[s2; Adds new element with specified value to Vector.&]
|
[s2; Adds new element with specified value to Vector.&]
|
||||||
[s6; Requires T to have deep copy constructor.&]
|
[s6; Requires T to have deep copy constructor.&]
|
||||||
[s6; Invalidates iterators and references to Vector.&]
|
[s6; Invalidates iterators and references to Vector.&]
|
||||||
[s7; [*C@3 x]-|The value that is copied to newly created element.&]
|
[s7; [*C@3 x]-|The value that is copied to newly created element.&]
|
||||||
|
[s7; [*/ Return value]-|Reference to new element in Vector.&]
|
||||||
[s3;%- &]
|
[s3;%- &]
|
||||||
[s4;%- &]
|
[s4;%- &]
|
||||||
[s5;:Vector`:`:AddPick`(pick`_ T`&`):%- [@(0.0.255) void]_[* AddPick]([@(0.128.128) pick`_]_
|
[s5;:Vector`:`:AddPick`(pick`_ T`&`):%- [*@4 T][@(0.0.255) `&]_[* AddPick]([@(0.128.128) pick
|
||||||
[*@4 T][@(0.0.255) `&]_[*@3 x])&]
|
`_]_[*@4 T][@(0.0.255) `&]_[*@3 x])&]
|
||||||
[s2; Adds new element to Vector and picks value of parameter to it.
|
[s2; Adds new element to Vector and picks value of parameter to it.
|
||||||
&]
|
&]
|
||||||
[s6; Requires T to have pick constructor.&]
|
[s6; Requires T to have pick constructor.&]
|
||||||
[s6; Invalidates iterators and references to Vector.&]
|
[s6; Invalidates iterators and references to Vector.&]
|
||||||
[s7; [*C@3 x]-|Source instance of T that is to be picked.&]
|
[s7; [*C@3 x]-|Source instance of T that is to be picked.&]
|
||||||
|
[s7; [*/ Return value]-|Reference to new element in Vector&]
|
||||||
[s3;%- &]
|
[s3;%- &]
|
||||||
[s4;%- &]
|
[s4;%- &]
|
||||||
[s5;:Vector`:`:AddN`(int`):%- [@(0.0.255) void]_[* AddN]([@(0.0.255) int]_[*@3 n])&]
|
[s5;:Vector`:`:AddN`(int`):%- [@(0.0.255) void]_[* AddN]([@(0.0.255) int]_[*@3 n])&]
|
||||||
|
|
|
||||||
|
|
@ -39,7 +39,7 @@ int Ctrl::LoopLevel;
|
||||||
|
|
||||||
bool Ctrl::MemoryCheck;
|
bool Ctrl::MemoryCheck;
|
||||||
|
|
||||||
bool Ctrl::Painting;
|
bool Ctrl::painting;
|
||||||
|
|
||||||
void Ctrl::SetData(const Value&) {}
|
void Ctrl::SetData(const Value&) {}
|
||||||
Value Ctrl::GetData() const { return Value(); }
|
Value Ctrl::GetData() const { return Value(); }
|
||||||
|
|
|
||||||
|
|
@ -473,7 +473,7 @@ private:
|
||||||
static bool mouseinview;
|
static bool mouseinview;
|
||||||
static bool mouseinframe;
|
static bool mouseinframe;
|
||||||
static bool globalbackpaint;
|
static bool globalbackpaint;
|
||||||
static bool Painting;
|
static bool painting;
|
||||||
static int LoopLevel;
|
static int LoopLevel;
|
||||||
static Ctrl *LoopCtrl;
|
static Ctrl *LoopCtrl;
|
||||||
static int64 eventid;
|
static int64 eventid;
|
||||||
|
|
@ -1135,7 +1135,7 @@ public:
|
||||||
void RefreshFrame(int x, int y, int cx, int cy);
|
void RefreshFrame(int x, int y, int cx, int cy);
|
||||||
void RefreshFrame();
|
void RefreshFrame();
|
||||||
|
|
||||||
static bool IsPainting() { return Painting; }
|
static bool IsPainting() { return painting; }
|
||||||
|
|
||||||
void ScrollView(const Rect& r, int dx, int dy);
|
void ScrollView(const Rect& r, int dx, int dy);
|
||||||
void ScrollView(int x, int y, int cx, int cy, int dx, int dy);
|
void ScrollView(int x, int y, int cx, int cy, int dx, int dy);
|
||||||
|
|
|
||||||
|
|
@ -69,7 +69,7 @@ void SetWinceMouse(HWND hwnd, LPARAM lparam) {}
|
||||||
|
|
||||||
void AvoidPaintingCheck__()
|
void AvoidPaintingCheck__()
|
||||||
{
|
{
|
||||||
Ctrl::Painting = false;
|
Ctrl::painting = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool PassWindowsKey(int wParam);
|
bool PassWindowsKey(int wParam);
|
||||||
|
|
@ -77,7 +77,7 @@ bool PassWindowsKey(int wParam);
|
||||||
LRESULT Ctrl::WindowProc(UINT message, WPARAM wParam, LPARAM lParam) {
|
LRESULT Ctrl::WindowProc(UINT message, WPARAM wParam, LPARAM lParam) {
|
||||||
GuiLock __;
|
GuiLock __;
|
||||||
eventid++;
|
eventid++;
|
||||||
ASSERT_(!Painting, "WindowProc invoked while in Paint routine");
|
ASSERT_(!painting, "WindowProc invoked while in Paint routine");
|
||||||
// LLOG("Ctrl::WindowProc(" << message << ") in " << ::Name(this) << ", focus " << (void *)::GetFocus());
|
// LLOG("Ctrl::WindowProc(" << message << ") in " << ::Name(this) << ", focus " << (void *)::GetFocus());
|
||||||
Ptr<Ctrl> _this = this;
|
Ptr<Ctrl> _this = this;
|
||||||
HWND hwnd = GetHWND();
|
HWND hwnd = GetHWND();
|
||||||
|
|
@ -117,11 +117,11 @@ LRESULT Ctrl::WindowProc(UINT message, WPARAM wParam, LPARAM lParam) {
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
Painting = true;
|
painting = true;
|
||||||
#endif
|
#endif
|
||||||
UpdateArea(draw, Rect(ps.rcPaint));
|
UpdateArea(draw, Rect(ps.rcPaint));
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
Painting = false;
|
painting = false;
|
||||||
#endif
|
#endif
|
||||||
#ifndef PLATFORM_WINCE
|
#ifndef PLATFORM_WINCE
|
||||||
if(draw.PaletteMode() && SystemDraw::AutoPalette())
|
if(draw.PaletteMode() && SystemDraw::AutoPalette())
|
||||||
|
|
|
||||||
|
|
@ -363,8 +363,6 @@ bool PostgreSQLSession::ConnectionOK()
|
||||||
|
|
||||||
bool PostgreSQLSession::ReOpen()
|
bool PostgreSQLSession::ReOpen()
|
||||||
{
|
{
|
||||||
DLOG("Reopen!");
|
|
||||||
// Open(conns);
|
|
||||||
PQreset(conn);
|
PQreset(conn);
|
||||||
if(PQstatus(conn) != CONNECTION_OK)
|
if(PQstatus(conn) != CONNECTION_OK)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue