Thread: Drag and Drop not working
-
January 3rd, 2022, 03:58 #11
You really want to make sure that you are integrating with the CoreRPG language support too.
-
January 3rd, 2022, 04:26 #12
I have this
Code:<list_language name="lstLanguages"> <anchored> <left offset="8" /> <top offset="118" /> <bottom offset="-4" /> <size> <width>173</width> </size> </anchored> <class>char_language</class> <datasource>.languagelist</datasource> <allowcreate /> <allowdelete /> <acceptdrop> <class>language</class> <field>lstLanguages</field> </acceptdrop> </list_language>
Code:<acceptdrop> <class>skills</class> <field>*</field> </acceptdrop>
I've added the class item 'language' there, but it seems that is an invalid class, or at least that's an error I get in the sidebar item...
-
January 3rd, 2022, 05:18 #13
See the differences between my sample code and yours
Code:<acceptdrop> <class>skills</class> <field>*</field> </acceptdrop>
-
January 3rd, 2022, 07:46 #14
Supreme Deity
- Join Date
- Mar 2007
- Posts
- 20,540
I would really recommend for your first project that you not try to fiddle with the core objects so much. You are creating much more work for yourself, and as you learn more, you'll be able to make more edits as you figure things out.
Regards,
JPG
-
January 3rd, 2022, 18:03 #15
-
January 3rd, 2022, 18:06 #16
-
January 3rd, 2022, 18:53 #17
Supreme Deity
- Join Date
- Mar 2007
- Posts
- 20,540
If you put that value in there, it is literally looking for a database value named "lstLanguages" from any drop which is a "skills" record, which I'm thinking is not what you want. The "*" indicates to copy all fields on drop for that window display class.
If you want some specific behavior, you are better off overriding the onDrop event directly, and determining what type of object was dropped and what you want to do with it.
Regards,
JPG
-
January 3rd, 2022, 18:56 #18
So, it looks like the Languages sidebar item I created is not the same as the one in the Options menu. (see attached)
I can drag and drop from the Options one, but not from the sidebar one.
I assume this is how it's supposed to work, or that I set up the one in the sidebar wrong.
From dataLibrary
Code:LibraryData.aRecords["language"] = { bExport = true, aDataMap = { "language", "reference.language" }, aDisplayIcon = { "sidebar", "sidebar_down" }, sRecordDisplayClass = "language", }
Code:<string name="library_recordtype_label_language">Languages</string>
-
January 3rd, 2022, 21:54 #19
If your source is .languagelist then you are using the same list
This might be generated by the Ruleset Wizard but only based on what you put in it and the values are not all correct
Code:<acceptdrop> <class>skills</class> <field>lstLanguages</field> </acceptdrop>
-
January 4th, 2022, 03:36 #20
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks