Changeset 7171 in josm for trunk/data


Ignore:
Timestamp:
2014-05-23T08:02:13+02:00 (11 years ago)
Author:
simon04
Message:

fix #9682 #10048 - Presets: disable no value for some checkboxes in the preset dialog

This avoid that unneeded keys are created/suggested by JOSM, such as building=no

Location:
trunk/data
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/data/defaultpresets.xml

    r7118 r7171  
    118118  value_on: the value to set when checked (default is "yes")
    119119  value_off: the value to set when unchecked (default is "no")
     120  disable_off: whether the off value is disabled in the dialog, i.e., only unset or yes are provided
    120121  match: none/key/key!/keyvalue (default is "none", see below for more information)
    121122
     
    172173    </chunk>
    173174    <chunk id="highway_yesno_incline">
    174         <check key="bridge" text="Bridge" />
    175         <check key="tunnel" text="Tunnel" />
    176         <check key="cutting" text="Cutting" />
    177         <check key="embankment" text="Embankment" />
     175        <check key="bridge" text="Bridge" disable_off="true" />
     176        <check key="tunnel" text="Tunnel" disable_off="true" />
     177        <check key="cutting" text="Cutting" disable_off="true" />
     178        <check key="embankment" text="Embankment" disable_off="true" />
    178179        <combo key="incline" text="Incline" values="10%,-10%,10°,-10°,up,down"/>
    179180    </chunk>
     
    380381                <checkgroup columns="4">
    381382                    <check key="oneway" text="Oneway" default="on" />
    382                     <check key="bridge" text="Bridge" />
    383                     <check key="tunnel" text="Tunnel" />
    384                     <check key="cutting" text="Cutting" />
    385                     <check key="embankment" text="Embankment" />
     383                    <check key="bridge" text="Bridge" disable_off="true" />
     384                    <check key="tunnel" text="Tunnel" disable_off="true" />
     385                    <check key="cutting" text="Cutting" disable_off="true" />
     386                    <check key="embankment" text="Embankment" disable_off="true" />
    386387                    <check key="lit" text="Lit" />
    387388                    <check key="toll" text="Toll" />
     
    404405                <checkgroup columns="4">
    405406                    <check key="oneway" text="Oneway" default="on" />
    406                     <check key="bridge" text="Bridge" />
    407                     <check key="tunnel" text="Tunnel" />
    408                     <check key="cutting" text="Cutting" />
    409                     <check key="embankment" text="Embankment" />
     407                    <check key="bridge" text="Bridge" disable_off="true" />
     408                    <check key="tunnel" text="Tunnel" disable_off="true" />
     409                    <check key="cutting" text="Cutting" disable_off="true" />
     410                    <check key="embankment" text="Embankment" disable_off="true" />
    410411                    <check key="lit" text="Lit" />
    411412                    <check key="toll" text="Toll" />
     
    432433                    <check key="oneway" text="Oneway" default="on" />
    433434                    <check key="motorroad" text="Motorroad" default="on" />
    434                     <check key="bridge" text="Bridge" />
    435                     <check key="tunnel" text="Tunnel" />
    436                     <check key="cutting" text="Cutting" />
    437                     <check key="embankment" text="Embankment" />
     435                    <check key="bridge" text="Bridge" disable_off="true" />
     436                    <check key="tunnel" text="Tunnel" disable_off="true" />
     437                    <check key="cutting" text="Cutting" disable_off="true" />
     438                    <check key="embankment" text="Embankment" disable_off="true" />
    438439                    <check key="lit" text="Lit" />
    439440                    <check key="toll" text="Toll" />
     
    457458                    <check key="oneway" text="Oneway" default="on" />
    458459                    <check key="motorroad" text="Motorroad" default="on" />
    459                     <check key="bridge" text="Bridge" />
    460                     <check key="tunnel" text="Tunnel" />
    461                     <check key="cutting" text="Cutting" />
    462                     <check key="embankment" text="Embankment" />
     460                    <check key="bridge" text="Bridge" disable_off="true" />
     461                    <check key="tunnel" text="Tunnel" disable_off="true" />
     462                    <check key="cutting" text="Cutting" disable_off="true" />
     463                    <check key="embankment" text="Embankment" disable_off="true" />
    463464                    <check key="lit" text="Lit" />
    464465                    <check key="toll" text="Toll" />
     
    26302631            <key key="public_transport" value="station" />
    26312632            <text key="name" text="Name" />
    2632             <check key="area" text="Area" />
    2633             <check key="building" text="Building" />
     2633            <check key="area" text="Area" disable_off="true" />
     2634            <check key="building" text="Building" disable_off="true" />
    26342635            <text key="operator" text="Operator" />
    26352636            <text key="network" text="Network" />
  • trunk/data/tagging-preset.xsd

    r7118 r7171  
    247247                <attribute name="value_on" type="string" />
    248248                <attribute name="value_off" type="string" />
     249        <attribute name="disable_off" type="boolean" />
    249250                <attribute name="match" type="tns:match" />
    250251
Note: See TracChangeset for help on using the changeset viewer.