what the wrong in this .....!!!!

Pages: 12
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
// The Class declaration of our Http Connection system
class Fetcher : public eWindow
{
	/
		//else show a Messagebox with Error description.
		eString sMsg = "Error " + eString().sprintf("%d", err);
		eMessageBox msg(sMsg, _("User Abort"), eMessageBox::iconWarning|eMessageBox::btOK);
		msg.show();     msg.exec();     msg.hide();
	}
}
// internal download procedure (standard)
eHTTPDataSource * Fetcher::createDownloadSink(eHTTPConnection *conn)
{	dataSinkP = new eHTTPDownload(connectionP, (char *)tempPath.c_str());

	return(dataSinkP);

}

void eBibleMainWindow::downloadDone(int err)
{
	// set the flag that indicates that download is complete
	if(!downloadDoneFlag)
	{	downloadDoneFlag = 1;
		// create a buffer to read the temp file with download data.
		char buf[512];
		// declare the variables we will use in this function
		eString strview;
		// open temporary file cotaining the downloaded data 
  		FILE *f = fopen("/var/tmp/bdemo.sh", "rt");
   		if (f)
   		{
		
		label->hide();
		// Insert into the label the output we have stored in the variable strview
		label->setText(strview);
		// Show the label with the new text
		label->show();
		// hide the connection button
		ok->hide();
		// set the flag that indicates we are not in download state anymore
		inDownloadFlag = 0;

	}

}

eBibleMainWindow::~eBibleMainWindow()
{
	// we have to do almost nothing here. all widgets are automatically removed
	// since they are child of us. the eWidget-destructor will to this for us.
}

Last edited on
Where is eWindow declared?
closed account (z05DSL3A)

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
#ifndef __ewindow_h
#define __ewindow_h

#include <lib/gui/ewidget.h>
#include <lib/gui/decoration.h>

/**
 * \brief A (decorated) top level widget.
 *
 * An eWindow is whats actually seen as a window. It's top level (thus you cannot specify a parent),
 * and may have a (skinned) decoration. It's clientrect is usually a bit smaller since it has a titlebar
 * and a border.
 *
 */
class eWindow: public eWidget
{
	eDecoration deco;
	gColor fontColor, titleBarColor;
	static int globCancel;
	void init_eWindow();
protected:
	int borderTop, borderLeft, borderBottom, borderRight;
	int titleOffsetLeft, titleOffsetRight, titleOffsetTop, titleFontSize, titleHeight;
	void redrawWidget(gPainter *target, const eRect &where);
	void eraseBackground(gPainter *target, const eRect &where);
	void drawTitlebar(gPainter *target);
	void recalcClientRect();
	int eventHandler(const eWidgetEvent &event);
	void willShow();
	void willHide();
public:
	enum { OFF, ON };
	static void globalCancel(int mode) { globCancel=mode; }
	eRect getTitleBarRect();
	/**
	 * \brief Constructs the window
	 *
	 * \arg takefocus the \c eWidget::eWidget takefocus parameter. You don't need to set it if just
	 * one widget \e inside the parent needs focus. That widget can apply for it by itself.
	 */
	eWindow(int takefocus=0);
	
	/**
	 * destructs the window.
	 */
	~eWindow();
};

#endif 

http://cvs.tuxbox.org/tuxbox/apps/tuxbox/enigma ...
the declared class are :

class eBibleMainWindow
class Fetcher
You know what I don't know why I'm going crazy over this, I'm done commenting until you try replacing the "code" variable in Fetcher::fetch() with "MyCode".
please correct me in my programme i cant resolve the problem
please correct me in my programme i cant resolve the problem
closed account (z05DSL3A)
From what I have seen I can't see the problem, sorry.
Educated Guess

url = "http://www.host.com/activate.php/?code="+code;

Should be

url = eString("http://www.host.com/activate.php/?code=")+code;


Tim S.
At least wait a little more.

1
2
3
4
5
void Fetcher::fetch()
{
	// declare variable
	eString url, code;
	code = mytext->getText();
As far as I can see, there is no mytext that could be reachable from Fetcher (it is not a member or a parameter)
An eBibleMainWindow knows what is mytext.
Last edited on
Topic archived. No new replies allowed.
Pages: 12