Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Developing U++ » UppHub » Modified Controls4U demo
Modified Controls4U demo [message #44598] Tue, 14 April 2015 16:19 Go to next message
deep is currently offline  deep
Messages: 263
Registered: July 2011
Location: Bangalore
Experienced Member
Hello,

I required to have different layouts displayed in same right side area based on selection from left panel.

I have attached the files.

Based on selection from ColumnList from left I replace the layout in RightPanel.
I am using switch case to display selected function.

How to create array of the functions so that I can run function in right panel based on selection index. Like I have done it for bottom display. Then no need of switch case.


Warm Regards

Deepak
Re: Modified Controls4U demo [message #44600 is a reply to message #44598] Wed, 15 April 2015 10:15 Go to previous messageGo to next message
deep is currently offline  deep
Messages: 263
Registered: July 2011
Location: Bangalore
Experienced Member
index.php?t=getfile&id=4767&private=0Image of the program
  • Attachment: Image3.png
    (Size: 365.93KB, Downloaded 581 times)


Warm Regards

Deepak
Re: Modified Controls4U demo [message #44601 is a reply to message #44600] Wed, 15 April 2015 10:28 Go to previous messageGo to next message
koldo is currently offline  koldo
Messages: 3355
Registered: August 2008
Senior Veteran
Hello Deep

Now Controls4U_demo is updated following your suggestions.


Best regards
Iñaki
Re: Modified Controls4U demo [message #44602 is a reply to message #44598] Wed, 15 April 2015 16:03 Go to previous messageGo to next message
deep is currently offline  deep
Messages: 263
Registered: July 2011
Location: Bangalore
Experienced Member
Hello Koldo,

I was not expecting change in demo itself.
I wanted to achieve something like this and I chose your demo for quick check.

Your demo has come out well. ctrl.Hide(), ctrl.Show() is new Discovery for me.

I checked the new demo.

I have small suggestion.

	for (int i = 0; i < controls.GetCount(); ++i) {
		rect.Add(controls[i]->SizePos());
		controls[i]->Hide();
	}


void Controls4U_Demo::OnGridSel() {
	static int last = 0 ;
	int row = grid.GetCursor();

	controls[last]->Hide();
	controls[row]->Show();
	last = row ;
}


Warm Regards

Deepak

[Updated on: Wed, 15 April 2015 16:07]

Report message to a moderator

Re: Modified Controls4U demo [message #44604 is a reply to message #44602] Thu, 16 April 2015 09:33 Go to previous message
koldo is currently offline  koldo
Messages: 3355
Registered: August 2008
Senior Veteran
Hello Deepak

Oh yes, your option is smarter, mine is more naïve Smile


Best regards
Iñaki

[Updated on: Thu, 16 April 2015 09:34]

Report message to a moderator

Previous Topic: Media Player errors
Next Topic: Functions4U_Demo does not build in Rel.8389 (UBUNTU 14.04)
Goto Forum:
  


Current Time: Fri Mar 29 08:27:10 CET 2024

Total time taken to generate the page: 0.01612 seconds