summaryrefslogtreecommitdiff
path: root/indra/newview/llviewermenufile.h
diff options
context:
space:
mode:
authorBrad Payne (Vir Linden) <vir@lindenlab.com>2018-06-21 15:49:53 +0100
committerBrad Payne (Vir Linden) <vir@lindenlab.com>2018-06-21 15:49:53 +0100
commit9d7b353cbb5c12cd74559a8f3a7365312f95d4d0 (patch)
treeb35c3e3eb0c9c93cea2c01248a3943d5c1277fa7 /indra/newview/llviewermenufile.h
parent8abfd8da4fb222382437f4b547567fabc6f75cf8 (diff)
parentdc07de2f4a4c49d1877bf743b6f0d209392f6eb6 (diff)
merge
Diffstat (limited to 'indra/newview/llviewermenufile.h')
-rw-r--r--indra/newview/llviewermenufile.h37
1 files changed, 32 insertions, 5 deletions
diff --git a/indra/newview/llviewermenufile.h b/indra/newview/llviewermenufile.h
index 6941b4dc0e..15bbdd1e2d 100644
--- a/indra/newview/llviewermenufile.h
+++ b/indra/newview/llviewermenufile.h
@@ -81,21 +81,48 @@ public:
static void cleanupClass();
static void clearDead();
- std::string mFile;
+ std::vector<std::string> mResponses;
+ std::string mProposedName;
- LLFilePicker::ELoadFilter mFilter;
+ LLFilePicker::ELoadFilter mLoadFilter;
+ LLFilePicker::ESaveFilter mSaveFilter;
+ bool mIsSaveDialog;
+ bool mIsGetMultiple;
- LLFilePickerThread(LLFilePicker::ELoadFilter filter)
- : LLThread("file picker"), mFilter(filter)
+ LLFilePickerThread(LLFilePicker::ELoadFilter filter, bool get_multiple = false)
+ : LLThread("file picker"), mLoadFilter(filter), mIsSaveDialog(false), mIsGetMultiple(get_multiple)
{
+ }
+ LLFilePickerThread(LLFilePicker::ESaveFilter filter, const std::string &proposed_name)
+ : LLThread("file picker"), mSaveFilter(filter), mIsSaveDialog(true), mProposedName(proposed_name)
+ {
}
void getFile();
virtual void run();
- virtual void notify(const std::string& filename) = 0;
+ virtual void notify(const std::vector<std::string>& filenames) = 0;
+};
+
+
+class LLFilePickerReplyThread : public LLFilePickerThread
+{
+public:
+
+ typedef boost::signals2::signal<void(const std::vector<std::string>& filenames, LLFilePicker::ELoadFilter load_filter, LLFilePicker::ESaveFilter save_filter)> file_picked_signal_t;
+
+ LLFilePickerReplyThread(const file_picked_signal_t::slot_type& cb, LLFilePicker::ELoadFilter filter, bool get_multiple);
+ LLFilePickerReplyThread(const file_picked_signal_t::slot_type& cb, LLFilePicker::ESaveFilter filter, const std::string &proposed_name);
+ ~LLFilePickerReplyThread();
+
+ virtual void notify(const std::vector<std::string>& filenames);
+
+private:
+ LLFilePicker::ELoadFilter mLoadFilter;
+ LLFilePicker::ESaveFilter mSaveFilter;
+ file_picked_signal_t* mFilePickedSignal;
};