Commit 15c91154c7c1bea4ef3ba4e5bcc55d184f873f38
1 parent
2f55e463
Exists in
master
correção no plugin
Showing
6 changed files
with
9 additions
and
8 deletions
Show diff stats
Clipboard/Clipboard.py
@@ -23,7 +23,7 @@ def clip(): | @@ -23,7 +23,7 @@ def clip(): | ||
23 | 23 | ||
24 | def bdragOn(): | 24 | def bdragOn(): |
25 | global process | 25 | global process |
26 | - process = subprocess.Popen("Bdrag") | 26 | + process = subprocess.Popen("bdrag") |
27 | 27 | ||
28 | def bdragOff(): | 28 | def bdragOff(): |
29 | process.kill() | 29 | process.kill() |
30 | \ No newline at end of file | 30 | \ No newline at end of file |
Clipboard/Clipboard.pyc
No preview for this file type
plugin/Plugin-x86/CorePlugin.dll
No preview for this file type
plugin/Plugin-x86/CorePlugin.lib
No preview for this file type
plugin/corePlugin.cpp
@@ -15,8 +15,7 @@ | @@ -15,8 +15,7 @@ | ||
15 | tradutor = new PyTradutor(); | 15 | tradutor = new PyTradutor(); |
16 | 16 | ||
17 | //Objeto usado para copiar texto da área de transferência | 17 | //Objeto usado para copiar texto da área de transferência |
18 | - clipboard = new PyClip(); | ||
19 | - clipboard->bdragOn(); | 18 | + clipboard.bdragOn(); |
20 | 19 | ||
21 | return 1; | 20 | return 1; |
22 | } | 21 | } |
@@ -24,15 +23,15 @@ | @@ -24,15 +23,15 @@ | ||
24 | EXPORT_API char* coreExecute() | 23 | EXPORT_API char* coreExecute() |
25 | { | 24 | { |
26 | //Copia área de transferência para input | 25 | //Copia área de transferência para input |
27 | - char *input = clipboard->clip(); | ||
28 | - | 26 | + char *input = clipboard.clip(); |
27 | + | ||
29 | //Retorna a tradução do texto para glosa | 28 | //Retorna a tradução do texto para glosa |
30 | return strlwr(tradutor->convertStringToGlosa(input)); | 29 | return strlwr(tradutor->convertStringToGlosa(input)); |
31 | } | 30 | } |
32 | 31 | ||
33 | EXPORT_API int coreFinalize() | 32 | EXPORT_API int coreFinalize() |
34 | { | 33 | { |
35 | - clipboard->bdragOff(); | 34 | + clipboard.bdragOff(); |
36 | delete tradutor; | 35 | delete tradutor; |
37 | return 1; | 36 | return 1; |
38 | } | 37 | } |
plugin/corePlugin.h
1 | #ifndef _COREPLUGIN_H | 1 | #ifndef _COREPLUGIN_H |
2 | #define _COREPLUGIN_H | 2 | #define _COREPLUGIN_H |
3 | 3 | ||
4 | -#include "pyTradutor.h" | 4 | +#include <iostream> |
5 | #include "pyClip.h" | 5 | #include "pyClip.h" |
6 | +#include "pyTradutor.h" | ||
6 | #include <string.h> | 7 | #include <string.h> |
7 | 8 | ||
9 | +using namespace std; | ||
8 | using namespace Tradutor; | 10 | using namespace Tradutor; |
9 | using namespace Clipboard; | 11 | using namespace Clipboard; |
10 | 12 | ||
@@ -14,7 +16,7 @@ extern "C" | @@ -14,7 +16,7 @@ extern "C" | ||
14 | PyTradutor *tradutor; | 16 | PyTradutor *tradutor; |
15 | 17 | ||
16 | //Usado para copiar texto da área de transferência | 18 | //Usado para copiar texto da área de transferência |
17 | - PyClip *clipboard; | 19 | + PyClip clipboard; |
18 | 20 | ||
19 | //Inicializa Objetos | 21 | //Inicializa Objetos |
20 | EXPORT_API int coreInitize(void); | 22 | EXPORT_API int coreInitize(void); |