• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Bug: combo_box doesn't support min, max, precision, or validate

LEGEND ,
Jul 03, 2010 Jul 03, 2010

Copy link to clipboard

Copied

Combo boxes don't support the min, max, precision, or validate properties, contrary to what the documentation states in "Lightroom SDK 3.0\API Reference\modules\LrView edit view properties.html".

Here's a test program that shows the problems:

local LrDialogs = import 'LrDialogs'
local LrView = import 'LrView'
local f = LrView.osFactory()

local text = f:static_text {}

local function validate (view, value)
    text.title = "validate called from " .. view.label
    return true, value, nil
    end

LrDialogs.presentModalDialog {
    title = "Test", contents = f:column {
        text,
        f:row {
            f:static_text {title = "numeric:"},
            f:edit_field {min = 1, max = 10, precision = 0}},
        f:row {
            f:static_text {title = "numeric:"},
            f:combo_box {min = 1, max = 10, precision = 0,
                items = {1, 2, 3}}},
        f:row {
            f:static_text {title = "validate:"},
            f:edit_field {validate = validate,
                label = "edit_field"}},
        f:row {
            f:static_text {title = "validate:"},
            f:combo_box {validate = validate,
                label = "combo_box", items = {1, 2, 3}}}}}

I've reported this via the Web form.

TOPICS
SDK

Views

628

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jul 07, 2010 Jul 07, 2010

Copy link to clipboard

Copied

LATEST

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines