Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 Create from usage issue

You must be registered to post a reply.
Click here to register.

Screensize:
UserName:
Password:
Format: BoldItalicizeUnderlineStrikethrough Align leftCenterAlign right Insert horizontal ruleUpload and insert imageInsert hyperlinkInsert email addressInsert codeInsert quoted textInsert listInsert Emoji
   
Message:

Forum code is on.
Html is off.

 
Check to subscribe to this topic.
   

T O P I C    R E V I E W
diarrhio Posted - Oct 12 2009 : 4:04:25 PM
If you have an object of some class, type in some method which you want to create, then do a Create from Usage, then the method will get added to the bottom of the class definition, complete ignoring any visibility (i.e. private, public) declarations you have. It should put the new method in a public section of the class declaration. Here is an example:

class A
{
public:
    void SomeMethod();

private:
    int m_SomeData;
};

void main()
{
    A aObject;

    // New method we want to create from usage
    a.NewMethod();
}

Now we right click on the "NewMethod" token above and select "Create from Usage". What we see is the following:
class A
{
public:
    void SomeMethod();

private:
    int m_SomeData;
    void NewMethod();
};

Rather than:
class A
{
public:
    void SomeMethod();
    void NewMethod();

private:
    int m_SomeData;
};


I am using build 1738 on Visual Studio 2005, SP1.

Thanks
6   L A T E S T    R E P L I E S    (Newest First)
sean Posted - Mar 16 2016 : 12:04:05 AM
case=29902 is fixed in build 2093
diarrhio Posted - Oct 13 2009 : 7:21:44 PM
Thank you. And thank you.
accord Posted - Oct 13 2009 : 2:59:27 PM
The details: it will retain the visibility of the function in which you type the new one. If you try to call a function which will be in an another class, "Create method" will create the declaration with public visibility.
feline Posted - Oct 13 2009 : 1:05:19 PM
This FAQ explains this:

http://docs.wholetomato.com?W318
diarrhio Posted - Oct 12 2009 : 7:45:47 PM
Just out of curiosity, what do these case numbers refer to? Is there some sort of bug/task tracker available for us to look at?
accord Posted - Oct 12 2009 : 6:33:39 PM
We are planning to improve this by retaining the visibility:

case=29902

I don't understand completely how it will be done, so added a question to the case.

© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000