aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/newview/llpanellogin.h
diff options
context:
space:
mode:
Diffstat (limited to 'linden/indra/newview/llpanellogin.h')
-rw-r--r--linden/indra/newview/llpanellogin.h102
1 files changed, 102 insertions, 0 deletions
diff --git a/linden/indra/newview/llpanellogin.h b/linden/indra/newview/llpanellogin.h
new file mode 100644
index 0000000..6e11f6f
--- /dev/null
+++ b/linden/indra/newview/llpanellogin.h
@@ -0,0 +1,102 @@
1/**
2 * @file llpanellogin.h
3 * @brief Login username entry fields.
4 *
5 * Copyright (c) 2002-2007, Linden Research, Inc.
6 *
7 * The source code in this file ("Source Code") is provided by Linden Lab
8 * to you under the terms of the GNU General Public License, version 2.0
9 * ("GPL"), unless you have obtained a separate licensing agreement
10 * ("Other License"), formally executed by you and Linden Lab. Terms of
11 * the GPL can be found in doc/GPL-license.txt in this distribution, or
12 * online at http://secondlife.com/developers/opensource/gplv2
13 *
14 * There are special exceptions to the terms and conditions of the GPL as
15 * it is applied to this Source Code. View the full text of the exception
16 * in the file doc/FLOSS-exception.txt in this software distribution, or
17 * online at http://secondlife.com/developers/opensource/flossexception
18 *
19 * By copying, modifying or distributing this software, you acknowledge
20 * that you have read and understood your obligations described above,
21 * and agree to abide by those obligations.
22 *
23 * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
24 * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
25 * COMPLETENESS OR PERFORMANCE.
26 */
27
28#ifndef LL_LLPANELLOGIN_H
29#define LL_LLPANELLOGIN_H
30
31#include "llpanel.h"
32
33#include "lldbstrings.h"
34#include "llmemory.h"
35#include "llviewerimage.h"
36#include "llstring.h"
37
38class LLTextBox;
39class LLLineEditor;
40class LLCheckBoxCtrl;
41class LLButton;
42class LLComboBox;
43
44class LLPanelLogin
45: public LLPanel
46{
47public:
48 LLPanelLogin(const LLRect &rect, BOOL show_server,
49 void (*callback)(S32 option, void* user_data),
50 void *callback_data);
51 ~LLPanelLogin();
52
53 virtual BOOL handleKeyHere(KEY key, MASK mask, BOOL called_from_parent);
54 virtual void draw();
55 virtual void setFocus( BOOL b );
56
57 static void show(const LLRect &rect, BOOL show_server,
58 void (*callback)(S32 option, void* user_data),
59 void* callback_data);
60
61 static void setFields(const std::string& firstname, const std::string& lastname,
62 const std::string& password, BOOL remember);
63
64 static void addServer(const char *server, S32 domain_name);
65 static void refreshLocation( bool force_visible );
66
67 static void getFields(LLString &firstname, LLString &lastname,
68 LLString &password, BOOL &remember);
69
70 static void getServer(LLString &server, S32& domain_name);
71 static void getLocation(LLString &location);
72
73 static void close();
74
75 void setSiteIsAlive( bool alive );
76
77 static void giveFocus();
78 static void mungePassword(LLUICtrl* caller, void* user_data);
79
80private:
81 static void onClickConnect(void*);
82 static void onClickNewAccount(void*);
83 static void newAccountAlertCallback(S32 option, void*);
84 static void onClickQuit(void*);
85 static void onClickVersion(void*);
86 static void onPassKey(LLLineEditor* caller, void* user_data);
87
88private:
89 LLPointer<LLViewerImage> mLogoImage;
90
91 void (*mCallback)(S32 option, void *userdata);
92 void* mCallbackData;
93
94 char mIncomingPassword[DB_USER_PASSWORD_BUF_SIZE];
95 char mMungedPassword[MD5HEX_STR_SIZE];
96
97 static LLPanelLogin* sInstance;
98 static BOOL sCapslockDidNotification;
99 BOOL mHtmlAvailable;
100};
101
102#endif