Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush Python API
      • ZBrush GoZ API
      • Code Examples on Github
    • Forum
    • Downloads
    • Support
      • Support Procedures
      • Registered Developer Program
      • Plugin IDs
      • Contact Us
    • Categories
      • Overview
      • News & Information
      • Cinema 4D SDK Support
      • Cineware SDK Support
      • ZBrush 4D SDK Support
      • Bugs
      • General Talk
    • Unread
    • Recent
    • Tags
    • Users
    • Login

    Two pin icons. Why?

    SDK Help
    0
    8
    639
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • H
      Helper
      last edited by

      THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

      On 28/02/2004 at 16:35, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   8.100 
      Platform:      Mac OSX  ; 
      Language(s) :   C.O.F.F.E.E  ;

      ---------
      For all my plug-ins that have a dialog, when they first open, they show one blue pin icon on the top left. Ok, this is correct.
      But when I close the window and call the plug-in a second time I get two pins. Its like there is one window inside another.
      What can I be doing wrong?

      Rui Batista

      1 Reply Last reply Reply Quote 0
      • H
        Helper
        last edited by

        THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

        On 16/08/2009 at 15:19, xxxxxxxx wrote:

        I still couldn't find a solution for this.
        Let me add that I have a button in my dialog, named "Cancel" and, pressing it, it executes:

        Close();

        Apparently, this hides the window but it does not deletes it. So, when I evoque the plug-in again, the window now shows with two top bars (they don't have blue pins anymore, just the 4x4 grid).
        How can I make a window really CLOSE, not just hide?

        1 Reply Last reply Reply Quote 0
        • H
          Helper
          last edited by

          THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

          On 17/08/2009 at 03:23, xxxxxxxx wrote:

          Please post a simplified example showing the problem.

          cheers,
          Matthias

          1 Reply Last reply Reply Quote 0
          • H
            Helper
            last edited by

            THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

            On 17/08/2009 at 04:32, xxxxxxxx wrote:

            I found out that if I open my window as modal, with:

            Open(False,-1,-1)

            It works fine. It only works wrong if I open it as nonmodal, with:

            Open(True,-1,-1)

            Does this help or should I still show the problem, Matthias?

            Rui Batista

            1 Reply Last reply Reply Quote 0
            • H
              Helper
              last edited by

              THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

              On 18/08/2009 at 02:31, xxxxxxxx wrote:

              Quote: _Does this help or should I still show the problem, Matthias?
              >
              > * * *
              _


              Yes, please provide some code, maybe the dialog framework.

              It is working without problems in my tests.

              > \> include "c4d_symbols.h" \> \> \> // be sure to use a unique ID obtained from www.plugincafe.com \> var PLUGINID = 1000158; \> // be sure to use a unique ID obtained from www.plugincafe.com \> \> \> // definition of my dialog class \> class MyDialog : GeDialog \> { \>      public: \>           MyDialog(); \> \>           CreateLayout(); \>           Command(id,msg); \>           Message(msg); \>            \>      private: \>           var res; \> } \> \> MyDialog::MyDialog() \> { \>      super(PLUGINID); \>       \>      var root = GeGetRootFilename(); \>      root->RemoveLast(); \>      res = new(GeResource, root); \> } \> \> MyDialog::Message(msg) \> { \> //     switch (msg->GetId()) \>      { \>      } \>      return super::Message(msg); \> } \> \> MyDialog::CreateLayout() \> { \>      return LoadDialogResource(GUI_DEMO, res, 0); \> } \> \> MyDialog::Command(id,msg) \> { \> //     switch (id) \>      { \>      } \> } \> \> \> class MyMenuPlugin : MenuPlugin \> { \>      public: \>           MyMenuPlugin(); \> \>           GetID(); \>           GetName(); \>           GetHelp(); \>           Execute(doc); \> \>           RestoreLayout(secret); \> } \> \> MyMenuPlugin::MyMenuPlugin() \> { \>      super(); \> } \> \> MyMenuPlugin::GetID() \> { \>      return PLUGINID; \> } \> \> MyMenuPlugin::GetName() \> { \>      return "Gui Demo"; \> } \> \> MyMenuPlugin::GetHelp() \> { \>      return "Demonstrates usage of various GUI elements"; \> } \> \> var d; \> \> MyMenuPlugin::Execute(doc) \> { \>      d->Open(TRUE,-1,-1); \> } \> \> MyMenuPlugin::RestoreLayout(secret) \> { \>      if (!d) d = new(MyDialog); \>      d->RestoreLayout(secret); \> } \> \> \> main() \> { \>      d = new(MyDialog); \> \>      Register(MyMenuPlugin); \> } \>

              cheers,
              Matthias

              1 Reply Last reply Reply Quote 0
              • H
                Helper
                last edited by

                THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

                On 18/08/2009 at 04:20, xxxxxxxx wrote:

                It is working now. I was getting the dialog resource in the main() and not in the MyDialog() function.
                Now I have an additional problem. I can't seem to be able to initialize the values of the elements of the dialog.
                How can I access the container of the dialog inside the overloaded Init()?
                I was trying to use:

                bc=res->GetContainer();
                     bc->SetData(CHECK_TAGS,TRUE);

                And I defined bc as a public variable inside the MyDialog definition.
                But I keep getting a Member not found error at the line:

                bc->SetData(CHECK_TAGS,TRUE);

                1 Reply Last reply Reply Quote 0
                • H
                  Helper
                  last edited by

                  THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

                  On 18/08/2009 at 05:47, xxxxxxxx wrote:

                  Dialog elements are not accessed through containers but with their according set/get function. For a checkbox that would be SetCheckbox/GetCheckbox. Please check the GeBaseDialog class for these functions.

                  cheers,
                  Matthias

                  1 Reply Last reply Reply Quote 0
                  • H
                    Helper
                    last edited by

                    THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

                    On 18/08/2009 at 09:52, xxxxxxxx wrote:

                    Got it. Its working now 🙂

                    1 Reply Last reply Reply Quote 0
                    • First post
                      Last post