49 std::string _file_name;
88 const std::string &
file_name()
const {
return _file_name;}
131 _more = (_buffer_size == _received);
168 bool more()
const {
return _more;}
int estimated_size() const
Estimated size of file.
Definition: loader.h:74
virtual bool accept_file(LoadEvent &event)
Override to see if the loader can accept a file.
Definition: loader.h:199
A library for creating RISC OS toolbox applications.
Definition: abouttobeshownlistener.cc:35
virtual void * data_buffer(const LoadEvent &event, int &buffer_size)
Set up buffer for application to application data transfer.
Definition: loader.h:214
virtual bool data_received(DataReceivedEvent &event)
Override to receive the file by in memory transfer from another application.
Definition: loader.h:236
void buffer_size(int size)
Set the buffer size for the next transmission from the other application.
Definition: loader.h:158
void buffer(void *buf)
Set the buffer address for the next bytes received.
Definition: loader.h:147
Gadget destination_gadget() const
Gadget for load (can be a null gadget if no gadget is involved).
Definition: loader.h:64
Class to handle file/data loading from the filer or an external application.
Definition: loader.h:179
void * buffer() const
Return the buffer the transmitted data has been copied too.
Definition: loader.h:142
int buffer_size() const
Return the buffer size of the current buffer.
Definition: loader.h:152
const std::string & file_name() const
File name of file.
Definition: loader.h:88
Class with details of buffer transferred from another application.
Definition: loader.h:113
LoadEvent(Object obj, Gadget gadget, int x, int y, int est, int type, const char *file_name, bool from_filer)
Constructor.
Definition: loader.cc:32
bool from_filer() const
Check if the load is from the filer.
Definition: loader.h:93
void update_file_details(const char *file_name, int size)
Update file details for load.
Definition: loader.h:106
int received() const
Number of bytes received.
Definition: loader.h:163
const Point & destination_point() const
Location for load (screen coordinates)
Definition: loader.h:69
bool opener() const
Returns true if this event is from an opener added to the main application.
Definition: loader.h:99
Class to manipulate a toolbox object.
Definition: object.h:51
virtual bool load_file(LoadEvent &event)=0
Override to do the actual file load.
Class to represent a position in two dimensional space.
Definition: point.h:37
Class with details of a file load operation.
Definition: loader.h:42
virtual void data_error(const LoadEvent &event)
Informs loader that an error occurred during application to application data transfer.
Definition: loader.h:244
bool null() const
Check if object has been initialised.
Definition: object.h:87
const LoadEvent & load_event() const
Return o LoadEvent that started the transfer.
Definition: loader.h:137
int file_type() const
File type of file.
Definition: loader.h:79
This is the base class for all Gadgets.
Definition: gadget.h:49
Object destination_object() const
Object the load is going to occur on.
Definition: loader.h:59
bool more() const
Return true if more data is to come.
Definition: loader.h:168
DataReceivedEvent(LoadEvent *event, void *buffer, int buffer_size, int received)
Construct with details of received buffer.
Definition: loader.h:125