Safari Mobile Multi-Line <Select> aka GWT Multi-Line ListBox

让人想犯罪 __ 提交于 2019-12-23 07:03:26

问题


Working on a webapp here that must run on the iPad (so, Safari Mobile).

I have this code that works fine in just about anything except iPad:

<select class="gwt-ListBox" size="12" multiple="multiple">
    <option value="Bleeding Eyelashes">Bleeding Eyelashes</option>
    <option value="Smelly Pupils">Smelly Pupils</option>
    <option value="Bushy Eyebrows">Bushy Eyebrows</option>
    <option value="Green Vessels">Green Vessels</option>
    <option value="Sucky Noses">Sucky Noses</option>
</select>

What it's supposed to look like is a box with 12 lines ans 5 of them filled up. It works fine in FF, IE, Chrome, Safari Win. But, when I open it on iPad, it's just a single line!

Styling it with CSS doesn't work. It just makes the single line bigger if I set the height. Is there a way to make it behave the same way as in normal browsers, or do I nave to make a custom component?

Thanks.


回答1:


There is no way to do this. You have to implement your own component.

Source: http://developer.apple.com/library/safari/#documentation/AppleApplications/Reference/SafariWebContent/SafariWebContent.pdf (dead link)



来源:https://stackoverflow.com/questions/5376507/safari-mobile-multi-line-select-aka-gwt-multi-line-listbox

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!