title: How to access a specific value from a Map <Object> flutter
body: <p>Need to access a single value when the item is selected in the list.
  When the item is clicked, it prints the whole list of objects, instead the value of the selected object.
  For example, when user selects Spanish, should print SP instead of the list of objects.
  I have a class and a list for the languages, but for this question is not relevant.</p>
  <p>This is what I have achieved so far:</p>
  <pre><code> List &lt;Object&gt; Dictionary = [
  {'Spanish': 'SP'},
  {'Italian': 'IT'},
  {'German': 'DE'},
  {'Arab': 'AR'},
  {'Greek': 'GR'},
  {'Thai': 'TH'},
  {'Chinese': 'CH'},
  {'French': 'FR'}
  </code></pre>
  <p>];</p>
  <pre><code>  List&lt;Language&gt; newDataList;
    final finalList = dictionary.values.toList();
  
    onItemChanged(String value) {
      setState(() {
        newDataList = languages.where((lang) =&gt; lang.title.toLowerCase().contains(value.toLowerCase())).toList();
      });
    }
  
    @override
    initState() {
      super.initState();
      newDataList = [...languages];
    }
  
    @override
    Widget build(BuildContext context) {
      return Scaffold(
        body: Column(
          children: &lt;Widget&gt;[
            Padding(
              padding: const EdgeInsets.all(12.0),
              child: TextField(
                controller: _textController,
                decoration: InputDecoration(
                  icon: Icon(Icons.search),
                  hintText: 'Type languages',
                ),
                onChanged: onItemChanged,
              ),
            ),
            Expanded(
              child: ListView(
                padding: EdgeInsets.all(12.0),
                children: newDataList.map((data) {
                  return Ink(
                    color: data.selected ? TheBaseColors.lightGreen : Colors.transparent,
                    child: ListTile(
                        title: Text(data.title),
                        onTap: () {
                          setState(() {
                            data.selected = !data.selected;
  
                            print(&quot;${data.title} is now ${data.selected ? &quot;selected&quot; : &quot;not selected&quot;}&quot;);
                            print(Dictionary);
  
                          });
                        }),
                  );
                }).toList(),
              ),
            ),
            Expanded(
                child: Column(children: [
              Text('Selected languages :'),
              Expanded(
                  child: ListView(
                      children: newDataList.where((l) =&gt; l.selected).map((l) =&gt; Padding(child: Text(l.title), padding: EdgeInsets.only(right: 10))).toList()))
            ]))
          ],
        ),
      );
    }
  }
  </code></pre>
  <p>Tried dictionary.value, dictionary[value]</p>