Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
appinventor-sources
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
xpstem
appinventor-sources
Commits
75b80b88
Commit
75b80b88
authored
Apr 14, 2020
by
Evan W. Patton
Committed by
Jeffrey Schiller
Apr 14, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove Column and Row properties from Form
Change-Id: I986ce001d40ff7ea4423e7a21d29e3fad3e2eabc
parent
01f7807f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
2 deletions
+13
-2
appinventor/appengine/src/com/google/appinventor/client/editor/simple/components/MockVisibleComponent.java
...client/editor/simple/components/MockVisibleComponent.java
+2
-2
appinventor/appengine/src/com/google/appinventor/client/editor/youngandroid/YaFormEditor.java
.../appinventor/client/editor/youngandroid/YaFormEditor.java
+11
-0
No files found.
appinventor/appengine/src/com/google/appinventor/client/editor/simple/components/MockVisibleComponent.java
View file @
75b80b88
...
...
@@ -47,8 +47,8 @@ public abstract class MockVisibleComponent extends MockComponent {
protected
static
final
String
PROPERTY_NAME_VISIBLE
=
"Visible"
;
protected
static
final
String
PROPERTY_NAME_WIDTH
=
"Width"
;
protected
static
final
String
PROPERTY_NAME_HEIGHT
=
"Height"
;
p
rotected
static
final
String
PROPERTY_NAME_COLUMN
=
"Column"
;
p
rotected
static
final
String
PROPERTY_NAME_ROW
=
"Row"
;
p
ublic
static
final
String
PROPERTY_NAME_COLUMN
=
"Column"
;
p
ublic
static
final
String
PROPERTY_NAME_ROW
=
"Row"
;
// Note: the values below are duplicated in Component.java
// If you change them here, change them there!
...
...
appinventor/appengine/src/com/google/appinventor/client/editor/youngandroid/YaFormEditor.java
View file @
75b80b88
...
...
@@ -25,6 +25,7 @@ import com.google.appinventor.client.editor.simple.components.FormChangeListener
import
com.google.appinventor.client.editor.simple.components.MockComponent
;
import
com.google.appinventor.client.editor.simple.components.MockContainer
;
import
com.google.appinventor.client.editor.simple.components.MockForm
;
import
com.google.appinventor.client.editor.simple.components.MockVisibleComponent
;
import
com.google.appinventor.client.editor.simple.components.utils.PropertiesUtil
;
import
com.google.appinventor.client.editor.simple.palette.DropTargetProvider
;
import
com.google.appinventor.client.editor.simple.palette.SimpleComponentDescriptor
;
...
...
@@ -637,6 +638,16 @@ public final class YaFormEditor extends SimpleEditor implements FormChangeListen
String
componentName
=
properties
.
get
(
"$Name"
).
asString
().
getString
();
mockComponent
.
changeProperty
(
"Name"
,
componentName
);
if
(
mockComponent
instanceof
MockForm
)
{
// A bug in an early version of multiselect resulted in Form gaining Row and Column
// properties, which are reserved for visible components that can appear in TableArrangements.
// Form doesn't have these properties, so we need to clean up the properties. The remove
// call here is idempotent--if the property is present, it is removed. If not present, the
// map remains unchanged.
properties
.
remove
(
MockVisibleComponent
.
PROPERTY_NAME_ROW
);
properties
.
remove
(
MockVisibleComponent
.
PROPERTY_NAME_COLUMN
);
}
// Set component properties
for
(
String
name
:
properties
.
keySet
())
{
if
(
name
.
charAt
(
0
)
!=
'$'
)
{
// Ignore special properties (name, type and nested components)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment