2
* This file is a part of the Cairo-Dock project
4
* Copyright : (C) see the 'copyright' file.
5
* E-mail : see the 'copyright' file.
7
* This program is free software; you can redistribute it and/or
8
* modify it under the terms of the GNU General Public License
9
* as published by the Free Software Foundation; either version 3
10
* of the License, or (at your option) any later version.
12
* This program is distributed in the hope that it will be useful,
13
* but WITHOUT ANY WARRANTY; without even the implied warranty of
14
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
* GNU General Public License for more details.
16
* You should have received a copy of the GNU General Public License
17
* along with this program. If not, see <http://www.gnu.org/licenses/>.
20
#ifndef __CD_DND2SHARE__
21
#define __CD_DND2SHARE__
23
#include <cairo-dock.h>
24
#include "applet-struct.h"
27
#define DND2SHARE_GENERIC_ERROR_MSG D_("Couldn't upload the file, check that your internet connection is active.")
28
#define DND2SHARE_SET_GENERIC_ERROR_WEBSITE(cWebsite) g_set_error (pError, 1, 1, \
29
D_("Couldn't upload the file to %s, check that your internet connection is active."), \
31
#define DND2SHARE_SET_GENERIC_ERROR_SERVICE(cService, cCommand) g_set_error (pError, 1, 1, \
32
D_("Couldn't upload the file to %s.\nCheck that your internet connection is active and '%s' is correctly installed and running"), \
36
void cd_dnd2share_free_uploaded_item (CDUploadedItem *pItem);
38
void cd_dnd2share_build_history (void);
40
void cd_dnd2share_clear_history (void);
43
void cd_dnd2share_launch_upload (const gchar *cFilePath, CDFileType iFileType);
46
void cd_dnd2share_clear_working_directory (void);
48
void cd_dnd2share_clear_copies_in_working_directory (void);
50
void cd_dnd2share_set_working_directory_size (guint iNbItems);
52
void cd_dnd2share_clean_working_directory (void);
55
void cd_dnd2share_copy_url_to_clipboard (const gchar *cURL);
56
void cd_dnd2share_copy_url_to_primary (const gchar *cURL);
58
gchar *cd_dnd2share_get_prefered_url_from_item (CDUploadedItem *pItem);
60
void cd_dnd2share_set_current_url_from_item (CDUploadedItem *pItem);
63
void cd_dnd2share_remove_one_item (CDUploadedItem *pItem);
66
void cd_dnd2share_register_new_backend (CDFileType iFileType, const gchar *cSiteName, int iNbUrls, const gchar **cUrlLabels, int iPreferedUrlType, CDUploadFunc pUploadFunc);
69
#endif // __CD_DND2SHARE__