Chat-O-Matic/application/views/SendTextView.h
Jaidyn Ann 89ff195c8d Set room topic/name through conversation view
If the user has permission to change a room's subject or name, they can
now edit the text views displaying them (toward the top of the window).
When enter is pressed, the changes will be sent to the protocol.

To do this, a BTextView subclass was added to libinterface
(splitting somewhat from SendTextView)― EnterTextView sends a message
containing the text to the given target when the user hits enter sans
modifiers.
2021-07-29 22:00:01 -05:00

29 lines
576 B
C++

/*
* Copyright 2021, Jaidyn Levesque <jadedctrl@teknik.io>
* All rights reserved. Distributed under the terms of the MIT license.
*/
#ifndef _SEND_TEXT_VIEW_H
#define _SEND_TEXT_VIEW_H
#include <libinterface/EnterTextView.h>
#include "ConversationView.h"
class SendTextView : public EnterTextView {
public:
SendTextView(const char* name, ConversationView* convView);
void KeyDown(const char* bytes, int32 numBytes);
private:
void _AutoComplete();
ConversationView* fConversationView;
int32 fCurrentIndex;
BString fCurrentWord;
};
#endif // _SEND_TEXT_VIEW_H